temporally removed multiselect component to separate it
This commit is contained in:
parent
349dc2d787
commit
73c78b7658
1 changed files with 3 additions and 8 deletions
|
|
@ -6,8 +6,7 @@
|
||||||
>
|
>
|
||||||
<label for="selector-select" class="text-sm">{{ label }}</label>
|
<label for="selector-select" class="text-sm">{{ label }}</label>
|
||||||
|
|
||||||
<component
|
<Select
|
||||||
:is="isCompareModeEnabled ? 'MultiSelect' : 'Select'"
|
|
||||||
id="selector-select"
|
id="selector-select"
|
||||||
v-model="currentValue"
|
v-model="currentValue"
|
||||||
:options="items"
|
:options="items"
|
||||||
|
|
@ -15,13 +14,9 @@
|
||||||
class="font-serif"
|
class="font-serif"
|
||||||
data-icon="chevron-single-down"
|
data-icon="chevron-single-down"
|
||||||
checkmark
|
checkmark
|
||||||
:display="isCompareModeEnabled ? 'chip' : undefined"
|
|
||||||
>
|
>
|
||||||
<template #value="slotProps">
|
<template #value="slotProps">
|
||||||
<p v-if="isCompareModeEnabled && Array.isArray(currentValue)">
|
<p v-if="currentValue && !Array.isArray(currentValue)">
|
||||||
{{ currentValue.length }} selected
|
|
||||||
</p>
|
|
||||||
<p v-else-if="currentValue && !Array.isArray(currentValue)">
|
|
||||||
{{ currentValue.title }}
|
{{ currentValue.title }}
|
||||||
</p>
|
</p>
|
||||||
<p v-else>Select...</p>
|
<p v-else>Select...</p>
|
||||||
|
|
@ -36,7 +31,7 @@
|
||||||
/>
|
/>
|
||||||
<p>{{ slotProps.option.title }}</p>
|
<p>{{ slotProps.option.title }}</p>
|
||||||
</template>
|
</template>
|
||||||
</component>
|
</Select>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue