diff --git a/components/Editor.vue b/components/Editor.vue
index 282454b..ffb3ffd 100644
--- a/components/Editor.vue
+++ b/components/Editor.vue
@@ -5,10 +5,10 @@
class="flex items-center justify-between w-full overflow-auto bg-ui-gray-700"
>
@@ -24,10 +24,10 @@
@@ -113,6 +113,25 @@
+
+
+
+
+ $emit('update:filename', event.target.value)"
+ class="w-full text-xs font-medium border-0 rounded-lg cursor-pointer text-ui-gray-400 bg-ui-gray-800 hover:bg-ui-gray-900 focus:bg-ui-gray-900 focus:outline-none focus:ring-0"
+ />
+
+
+
(editors[index].tabSize = size)"
@update:language="(lang) => (editors[index].language = lang)"
+ @update:filename="(filename) => (editors[index].filename = filename)"
/>
@@ -44,6 +47,7 @@
dusk="preview"
ref="preview"
:tab="tab"
+ :filenames="filenames"
:code="code"
:languages="languages"
class="flex flex-col justify-between w-full h-full overflow-auto"
@@ -140,6 +144,10 @@ export default {
}));
},
+ filenames() {
+ return this.editors.map(({ filename }) => filename);
+ },
+
canRemoveEditor() {
return this.editors.length > 1;
},
@@ -233,6 +241,7 @@ export default {
id: uuid(),
tabSize: 4,
language: language,
+ filename: '',
value: language === 'php' ? ' (settings.title = title)"
/>
@@ -366,6 +367,7 @@ export default {
props: {
tab: Object,
code: Array,
+ filenames: Array,
languages: Array,
},
diff --git a/components/Window.vue b/components/Window.vue
index 7db6687..4ac6017 100644
--- a/components/Window.vue
+++ b/components/Window.vue
@@ -32,7 +32,7 @@
type="text"
ref="title"
v-model="title"
- class="w-full p-0 text-sm font-medium text-center truncate bg-transparent border-0 shadow-none focus:ring-0"
+ class="w-full p-0 text-sm font-medium text-center truncate bg-transparent border-0 shadow-none focus:ring-0"
@blur="editingTitle = false"
/>
@@ -45,6 +45,10 @@
:key="index"
:style="{ padding: `${settings.padding}px` }"
>
+
+ {{ filenames[index] }}
+
+