Skip to content

Commit 2daaf64

Browse files
committed
feat: initial project name inplementation
1 parent 94488ce commit 2daaf64

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

packages/app/src/components/page/editor/project/new/EditorProjectNew.vue

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,11 @@
55
ref="main"
66
class="left-0 top-0 p-5 flex z-max flex-col w-full bg-rgba-blur lg:w-1/2 h-full lg:h-3/4 bg-theme-background-1 wb-text wb-scroll overflow-y-auto rounded shadow-2xl wb-scroll"
77
>
8-
<EditorAbsoluteHeader :title="t('editor.new.title')" @close="onClose" />
8+
<EditorAbsoluteHeader :title="t('editor.new.title')" @close="onClose" />
9+
<div class="flex gap-5 text-center flex-col justify-center items-center rounded-lg">
10+
<p class="pt-3 text-lg">{{ t('editor.new.name') }}</p>
11+
<InputText ref="input" class="bg-theme-background-2 py-2 px-3 text-white" placeholder="" v-model="name" />
12+
</div>
913
<p class="my-10 text-lg font-raleway text-center">
1014
{{ t('editor.new.description1')
1115
}}<b>{{ t('editor.new.description2') }}</b
@@ -92,6 +96,7 @@
9296
import { useAbsoluteStore } from '@/store/absolute'
9397
import { useContextStore } from '@/store/context'
9498
import { useProject } from '@/use/project'
99+
import { ref } from 'vue'
95100
import { useI18n } from 'vue-i18n'
96101
97102
const ABSOLUTE = useAbsoluteStore()
@@ -100,7 +105,9 @@
100105
const { t } = useI18n()
101106
const project = useProject()
102107
108+
const name = ref('')
109+
103110
const onClose = () => {
104-
if (CONTEXT.entities.length > 0) ABSOLUTE.project.new = false
111+
if (CONTEXT.entities.length > 0 && name.value.length >= 6) ABSOLUTE.project.new = false
105112
}
106113
</script>

0 commit comments

Comments
 (0)