✨ Add prompt for selecting a class
This commit is contained in:
91
src/components/initial-setup.vue
Normal file
91
src/components/initial-setup.vue
Normal file
@ -0,0 +1,91 @@
|
||||
<script setup>
|
||||
import CalendarIcon from "./icons/calendar-icon.vue";
|
||||
|
||||
defineProps({
|
||||
title: {
|
||||
required: true,
|
||||
type: String,
|
||||
},
|
||||
description: {
|
||||
required: true,
|
||||
type: String,
|
||||
},
|
||||
selectPrompt: {
|
||||
required: true,
|
||||
type: String,
|
||||
},
|
||||
options: {
|
||||
required: true,
|
||||
type: Array,
|
||||
},
|
||||
modelValue: {
|
||||
type: String,
|
||||
},
|
||||
});
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<div class="setup-wrapper">
|
||||
<div class="content">
|
||||
<CalendarIcon class="icon" />
|
||||
<span class="title">{{ title }}</span>
|
||||
<span class="description">{{ description }}</span>
|
||||
<select
|
||||
@input="(event) => $emit('update:modelValue', event.target.value)"
|
||||
>
|
||||
<option value="none">{{ selectPrompt }}</option>
|
||||
<option v-for="option in options" :value="option" :key="option">
|
||||
{{ option }}
|
||||
</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<style scoped>
|
||||
.setup-wrapper {
|
||||
position: absolute;
|
||||
left: 0;
|
||||
right: 0;
|
||||
top: 0;
|
||||
bottom: 0;
|
||||
margin: auto;
|
||||
width: max-content;
|
||||
height: max-content;
|
||||
max-width: 100%;
|
||||
}
|
||||
|
||||
.content {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
gap: 3px;
|
||||
max-width: 400px;
|
||||
padding: 30px;
|
||||
}
|
||||
|
||||
.icon {
|
||||
width: 100px;
|
||||
height: 100px;
|
||||
stroke-width: 1px;
|
||||
padding-bottom: 15px;
|
||||
}
|
||||
|
||||
span {
|
||||
word-wrap: normal;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
span.title {
|
||||
font-weight: bold;
|
||||
font-size: 18px;
|
||||
}
|
||||
|
||||
span.description {
|
||||
font-weight: 300;
|
||||
}
|
||||
|
||||
select {
|
||||
margin-top: 15px;
|
||||
}
|
||||
</style>
|
Reference in New Issue
Block a user