mirror of
https://github.com/ArthurDanjou/ui.git
synced 2026-02-01 20:57:57 +01:00
chore(SelectCustom): add slot on button
This commit is contained in:
@@ -8,8 +8,10 @@
|
|||||||
<input :value="modelValue" :required="required" class="absolute inset-0 w-px opacity-0 cursor-default">
|
<input :value="modelValue" :required="required" class="absolute inset-0 w-px opacity-0 cursor-default">
|
||||||
|
|
||||||
<ListboxButton :class="selectCustomClass">
|
<ListboxButton :class="selectCustomClass">
|
||||||
<span v-if="modelValue && modelValue[textAttribute]" class="block truncate">{{ modelValue[textAttribute] }}</span>
|
<slot>
|
||||||
<span v-else class="block truncate u-text-gray-400">{{ placeholder }}</span>
|
<span v-if="modelValue" class="block truncate">{{ modelValue[textAttribute] }}</span>
|
||||||
|
<span v-else class="block truncate u-text-gray-400">{{ placeholder }}</span>
|
||||||
|
</slot>
|
||||||
<span :class="iconWrapperClass">
|
<span :class="iconWrapperClass">
|
||||||
<Icon name="heroicons-solid:selector" :class="iconClass" aria-hidden="true" />
|
<Icon name="heroicons-solid:selector" :class="iconClass" aria-hidden="true" />
|
||||||
</span>
|
</span>
|
||||||
|
|||||||
Reference in New Issue
Block a user