summaryrefslogtreecommitdiff
path: root/app/assets/javascripts/environments/components/environment_terminal_button.js
diff options
context:
space:
mode:
Diffstat (limited to 'app/assets/javascripts/environments/components/environment_terminal_button.js')
-rw-r--r--app/assets/javascripts/environments/components/environment_terminal_button.js9
1 files changed, 5 insertions, 4 deletions
diff --git a/app/assets/javascripts/environments/components/environment_terminal_button.js b/app/assets/javascripts/environments/components/environment_terminal_button.js
index e86607e78f4..66a71faa02f 100644
--- a/app/assets/javascripts/environments/components/environment_terminal_button.js
+++ b/app/assets/javascripts/environments/components/environment_terminal_button.js
@@ -2,13 +2,13 @@
* Renders a terminal button to open a web terminal.
* Used in environments table.
*/
-const Vue = require('vue');
-const terminalIconSvg = require('icons/_icon_terminal.svg');
+import terminalIconSvg from 'icons/_icon_terminal.svg';
-module.exports = Vue.component('terminal-button-component', {
+export default {
props: {
terminalPath: {
type: String,
+ required: false,
default: '',
},
},
@@ -19,8 +19,9 @@ module.exports = Vue.component('terminal-button-component', {
template: `
<a class="btn terminal-button"
+ title="Open web terminal"
:href="terminalPath">
${terminalIconSvg}
</a>
`,
-});
+};