@eslamdevui/ui 3.2.0-beta.1 → 3.2.0-beta.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.nuxt/ui/alert.ts +5 -0
- package/.nuxt/ui/badge.ts +5 -0
- package/.nuxt/ui/button-group.ts +13 -0
- package/.nuxt/ui/button.ts +5 -0
- package/.nuxt/ui/carousel.ts +5 -0
- package/.nuxt/ui/content/content-navigation.ts +339 -0
- package/.nuxt/ui/content/content-search-button.ts +6 -0
- package/.nuxt/ui/content/content-search.ts +6 -0
- package/.nuxt/ui/content/content-surround.ts +39 -0
- package/.nuxt/ui/content/content-toc.ts +150 -0
- package/.nuxt/ui/content/index.ts +5 -0
- package/.nuxt/ui/content-surround.ts +5 -0
- package/.nuxt/ui/content-toc.ts +6 -6
- package/.nuxt/ui/dashboard-navbar.ts +5 -0
- package/.nuxt/ui/dashboard-sidebar-collapse.ts +5 -0
- package/.nuxt/ui/dashboard-sidebar-toggle.ts +5 -0
- package/.nuxt/ui/dashboard-sidebar.ts +10 -0
- package/.nuxt/ui/error.ts +9 -0
- package/.nuxt/ui/index.ts +48 -1
- package/.nuxt/ui/input-menu.ts +9 -0
- package/.nuxt/ui/input-number.ts +5 -0
- package/.nuxt/ui/input-tags.ts +9 -0
- package/.nuxt/ui/input.ts +9 -0
- package/.nuxt/ui/prose/a.ts +6 -0
- package/.nuxt/ui/prose/accordion-item.ts +3 -0
- package/.nuxt/ui/prose/accordion.ts +6 -0
- package/.nuxt/ui/prose/badge.ts +3 -0
- package/.nuxt/ui/prose/blockquote.ts +3 -0
- package/.nuxt/ui/prose/callout.ts +129 -0
- package/.nuxt/ui/prose/card-group.ts +3 -0
- package/.nuxt/ui/prose/card.ts +119 -0
- package/.nuxt/ui/prose/code-collapse.ts +19 -0
- package/.nuxt/ui/prose/code-group.ts +13 -0
- package/.nuxt/ui/prose/code-icon.ts +66 -0
- package/.nuxt/ui/prose/code-preview.ts +14 -0
- package/.nuxt/ui/prose/code-tree.ts +28 -0
- package/.nuxt/ui/prose/code.ts +27 -0
- package/.nuxt/ui/prose/collapsible.ts +12 -0
- package/.nuxt/ui/prose/em.ts +3 -0
- package/.nuxt/ui/prose/field-group.ts +3 -0
- package/.nuxt/ui/prose/field.ts +11 -0
- package/.nuxt/ui/prose/h1.ts +6 -0
- package/.nuxt/ui/prose/h2.ts +14 -0
- package/.nuxt/ui/prose/h3.ts +14 -0
- package/.nuxt/ui/prose/h4.ts +6 -0
- package/.nuxt/ui/prose/hr.ts +3 -0
- package/.nuxt/ui/prose/icon.ts +3 -0
- package/.nuxt/ui/prose/img.ts +3 -0
- package/.nuxt/ui/prose/index.ts +41 -0
- package/.nuxt/ui/prose/kbd.ts +3 -0
- package/.nuxt/ui/prose/li.ts +3 -0
- package/.nuxt/ui/prose/ol.ts +3 -0
- package/.nuxt/ui/prose/p.ts +3 -0
- package/.nuxt/ui/prose/pre.ts +17 -0
- package/.nuxt/ui/prose/steps.ts +19 -0
- package/.nuxt/ui/prose/strong.ts +3 -0
- package/.nuxt/ui/prose/table.ts +6 -0
- package/.nuxt/ui/prose/tabs-item.ts +3 -0
- package/.nuxt/ui/prose/tabs.ts +5 -0
- package/.nuxt/ui/prose/tbody.ts +3 -0
- package/.nuxt/ui/prose/td.ts +3 -0
- package/.nuxt/ui/prose/th.ts +3 -0
- package/.nuxt/ui/prose/thead.ts +3 -0
- package/.nuxt/ui/prose/tr.ts +3 -0
- package/.nuxt/ui/prose/ul.ts +3 -0
- package/.nuxt/ui/select-menu.ts +9 -0
- package/.nuxt/ui/select.ts +9 -0
- package/.nuxt/ui/textarea.ts +9 -0
- package/.nuxt/ui/toast.ts +5 -0
- package/LICENSE.md +9 -9
- package/README.md +147 -147
- package/cli/commands/make/component.mjs +95 -95
- package/cli/commands/make/index.mjs +14 -14
- package/cli/commands/make/locale.mjs +64 -64
- package/cli/index.mjs +15 -15
- package/cli/package.json +13 -13
- package/cli/templates.mjs +236 -228
- package/cli/utils.mjs +31 -31
- package/dist/module.json +1 -1
- package/dist/module.mjs +18 -13
- package/dist/runtime/components/Accordion.vue +36 -36
- package/dist/runtime/components/Alert.vue +46 -46
- package/dist/runtime/components/App.vue +10 -10
- package/dist/runtime/components/Avatar.vue +27 -27
- package/dist/runtime/components/AvatarGroup.vue +4 -4
- package/dist/runtime/components/Badge.vue +16 -16
- package/dist/runtime/components/Breadcrumb.vue +32 -32
- package/dist/runtime/components/Button.vue +28 -28
- package/dist/runtime/components/ButtonGroup.vue +3 -3
- package/dist/runtime/components/Calendar.vue +74 -74
- package/dist/runtime/components/Card.vue +13 -13
- package/dist/runtime/components/Carousel.vue +58 -58
- package/dist/runtime/components/ChatMessage.vue +35 -35
- package/dist/runtime/components/ChatMessages.vue +71 -71
- package/dist/runtime/components/ChatMessages.vue.d.ts +1 -2
- package/dist/runtime/components/ChatPrompt.vue +30 -31
- package/dist/runtime/components/ChatPrompt.vue.d.ts +4 -4
- package/dist/runtime/components/ChatPromptSubmit.vue +10 -10
- package/dist/runtime/components/Checkbox.vue +33 -33
- package/dist/runtime/components/CheckboxGroup.vue +32 -32
- package/dist/runtime/components/Chip.vue +11 -11
- package/dist/runtime/components/Collapsible.vue +9 -9
- package/dist/runtime/components/ColorPicker.vue +30 -30
- package/dist/runtime/components/CommandPalette.vue +117 -117
- package/dist/runtime/components/Container.vue +3 -3
- package/dist/runtime/components/ContextMenu.vue +22 -22
- package/dist/runtime/components/ContextMenuContent.vue +105 -105
- package/dist/runtime/components/DashboardGroup.vue +3 -3
- package/dist/runtime/components/DashboardNavbar.vue +41 -41
- package/dist/runtime/components/DashboardNavbar.vue.d.ts +1 -1
- package/dist/runtime/components/DashboardPanel.vue +29 -29
- package/dist/runtime/components/DashboardPanel.vue.d.ts +1 -1
- package/dist/runtime/components/DashboardResizeHandle.vue +7 -7
- package/dist/runtime/components/DashboardSearch.vue +24 -25
- package/dist/runtime/components/DashboardSearch.vue.d.ts +3 -3
- package/dist/runtime/components/DashboardSearchButton.vue +63 -41
- package/dist/runtime/components/DashboardSearchButton.vue.d.ts +7 -1
- package/dist/runtime/components/DashboardSidebar.vue +77 -77
- package/dist/runtime/components/DashboardSidebarCollapse.vue +7 -7
- package/dist/runtime/components/DashboardSidebarCollapse.vue.d.ts +1 -1
- package/dist/runtime/components/DashboardSidebarToggle.vue +14 -17
- package/dist/runtime/components/DashboardSidebarToggle.vue.d.ts +4 -6
- package/dist/runtime/components/Drawer.vue +55 -55
- package/dist/runtime/components/DropdownMenu.vue +24 -24
- package/dist/runtime/components/DropdownMenuContent.vue +107 -107
- package/dist/runtime/components/Error.vue +57 -0
- package/dist/runtime/components/Error.vue.d.ts +52 -0
- package/dist/runtime/components/Form.vue +8 -8
- package/dist/runtime/components/Form.vue.d.ts +1 -1
- package/dist/runtime/components/FormField.vue +37 -37
- package/dist/runtime/components/Icon.vue +1 -1
- package/dist/runtime/components/Input.vue +34 -34
- package/dist/runtime/components/InputMenu.vue +163 -163
- package/dist/runtime/components/InputNumber.vue +49 -49
- package/dist/runtime/components/InputTags.vue +55 -55
- package/dist/runtime/components/Kbd.vue +5 -5
- package/dist/runtime/components/Link.vue +14 -14
- package/dist/runtime/components/LinkBase.vue +8 -8
- package/dist/runtime/components/Modal.vue +69 -69
- package/dist/runtime/components/NavigationMenu.vue +166 -166
- package/dist/runtime/components/OverlayProvider.vue +9 -9
- package/dist/runtime/components/Pagination.vue +47 -47
- package/dist/runtime/components/PinInput.vue +20 -20
- package/dist/runtime/components/Popover.vue +17 -17
- package/dist/runtime/components/Progress.vue +19 -19
- package/dist/runtime/components/RadioGroup.vue +43 -43
- package/dist/runtime/components/Select.vue +96 -96
- package/dist/runtime/components/SelectMenu.vue +130 -130
- package/dist/runtime/components/Separator.vue +15 -15
- package/dist/runtime/components/Skeleton.vue +10 -10
- package/dist/runtime/components/Slideover.vue +76 -76
- package/dist/runtime/components/Slider.vue +27 -27
- package/dist/runtime/components/Stepper.vue +51 -51
- package/dist/runtime/components/Switch.vue +33 -33
- package/dist/runtime/components/Table.vue +77 -77
- package/dist/runtime/components/Tabs.vue +37 -37
- package/dist/runtime/components/Textarea.vue +33 -33
- package/dist/runtime/components/Timeline.vue +38 -38
- package/dist/runtime/components/Toast.vue +69 -69
- package/dist/runtime/components/Toaster.vue +28 -28
- package/dist/runtime/components/Tooltip.vue +19 -19
- package/dist/runtime/components/Tree.vue +60 -60
- package/dist/runtime/components/color-mode/ColorModeAvatar.vue +2 -2
- package/dist/runtime/components/color-mode/ColorModeAvatar.vue.d.ts +2 -2
- package/dist/runtime/components/color-mode/ColorModeButton.vue +16 -16
- package/dist/runtime/components/color-mode/ColorModeButton.vue.d.ts +3 -3
- package/dist/runtime/components/color-mode/ColorModeImage.vue +2 -2
- package/dist/runtime/components/color-mode/ColorModeSelect.vue +19 -19
- package/dist/runtime/components/color-mode/ColorModeSelect.vue.d.ts +1 -1
- package/dist/runtime/components/color-mode/ColorModeSwitch.vue +19 -19
- package/dist/runtime/components/color-mode/ColorModeSwitch.vue.d.ts +1 -1
- package/dist/runtime/components/content/ContentNavigation.vue +175 -0
- package/dist/runtime/components/content/ContentNavigation.vue.d.ts +53 -0
- package/dist/runtime/components/content/ContentSearch.vue +184 -0
- package/dist/runtime/components/content/ContentSearch.vue.d.ts +111 -0
- package/dist/runtime/components/content/ContentSearchButton.vue +95 -0
- package/dist/runtime/components/content/ContentSearchButton.vue.d.ts +12 -0
- package/dist/runtime/components/content/ContentSurround.vue +61 -0
- package/dist/runtime/components/content/ContentSurround.vue.d.ts +59 -0
- package/dist/runtime/components/content/ContentToc.vue +146 -0
- package/dist/runtime/components/content/ContentToc.vue.d.ts +88 -0
- package/dist/runtime/components/locale/LocaleSelect.vue +20 -20
- package/dist/runtime/components/locale/LocaleSelect.vue.d.ts +1 -1
- package/dist/runtime/components/prose/A.vue +24 -0
- package/dist/runtime/components/prose/A.vue.d.ts +15 -0
- package/dist/runtime/components/prose/Accordion.vue +43 -0
- package/dist/runtime/components/prose/Accordion.vue.d.ts +16 -0
- package/dist/runtime/components/prose/AccordionItem.vue +25 -0
- package/dist/runtime/components/prose/AccordionItem.vue.d.ts +15 -0
- package/dist/runtime/components/prose/Badge.vue +21 -0
- package/dist/runtime/components/prose/Badge.vue.d.ts +13 -0
- package/dist/runtime/components/prose/Blockquote.vue +21 -0
- package/dist/runtime/components/prose/Blockquote.vue.d.ts +13 -0
- package/dist/runtime/components/prose/Callout.vue +60 -0
- package/dist/runtime/components/prose/Callout.vue.d.ts +26 -0
- package/dist/runtime/components/prose/Card.vue +83 -0
- package/dist/runtime/components/prose/Card.vue.d.ts +30 -0
- package/dist/runtime/components/prose/CardGroup.vue +21 -0
- package/dist/runtime/components/prose/CardGroup.vue.d.ts +13 -0
- package/dist/runtime/components/prose/Code.vue +23 -0
- package/dist/runtime/components/prose/Code.vue.d.ts +22 -0
- package/dist/runtime/components/prose/CodeCollapse.vue +44 -0
- package/dist/runtime/components/prose/CodeCollapse.vue.d.ts +46 -0
- package/dist/runtime/components/prose/CodeGroup.vue +70 -0
- package/dist/runtime/components/prose/CodeGroup.vue.d.ts +37 -0
- package/dist/runtime/components/prose/CodeIcon.vue +28 -0
- package/dist/runtime/components/prose/CodeIcon.vue.d.ts +24 -0
- package/dist/runtime/components/prose/CodePreview.vue +28 -0
- package/dist/runtime/components/prose/CodePreview.vue.d.ts +19 -0
- package/dist/runtime/components/prose/CodeTree.vue +160 -0
- package/dist/runtime/components/prose/CodeTree.vue.d.ts +30 -0
- package/dist/runtime/components/prose/Collapsible.vue +41 -0
- package/dist/runtime/components/prose/Collapsible.vue.d.ts +38 -0
- package/dist/runtime/components/prose/Em.vue +19 -0
- package/dist/runtime/components/prose/Em.vue.d.ts +13 -0
- package/dist/runtime/components/prose/Field.vue +48 -0
- package/dist/runtime/components/prose/Field.vue.d.ts +39 -0
- package/dist/runtime/components/prose/FieldGroup.vue +23 -0
- package/dist/runtime/components/prose/FieldGroup.vue.d.ts +18 -0
- package/dist/runtime/components/prose/H1.vue +28 -0
- package/dist/runtime/components/prose/H1.vue.d.ts +19 -0
- package/dist/runtime/components/prose/H2.vue +32 -0
- package/dist/runtime/components/prose/H2.vue.d.ts +19 -0
- package/dist/runtime/components/prose/H3.vue +32 -0
- package/dist/runtime/components/prose/H3.vue.d.ts +19 -0
- package/dist/runtime/components/prose/H4.vue +28 -0
- package/dist/runtime/components/prose/H4.vue.d.ts +19 -0
- package/dist/runtime/components/prose/Hr.vue +18 -0
- package/dist/runtime/components/prose/Hr.vue.d.ts +5 -0
- package/dist/runtime/components/prose/Icon.vue +19 -0
- package/dist/runtime/components/prose/Icon.vue.d.ts +6 -0
- package/dist/runtime/components/prose/Img.vue +40 -0
- package/dist/runtime/components/prose/Img.vue.d.ts +9 -0
- package/dist/runtime/components/prose/Kbd.vue +19 -0
- package/dist/runtime/components/prose/Kbd.vue.d.ts +6 -0
- package/dist/runtime/components/prose/Li.vue +21 -0
- package/dist/runtime/components/prose/Li.vue.d.ts +13 -0
- package/dist/runtime/components/prose/Ol.vue +21 -0
- package/dist/runtime/components/prose/Ol.vue.d.ts +13 -0
- package/dist/runtime/components/prose/P.vue +21 -0
- package/dist/runtime/components/prose/P.vue.d.ts +13 -0
- package/dist/runtime/components/prose/Pre.vue +63 -0
- package/dist/runtime/components/prose/Pre.vue.d.ts +25 -0
- package/dist/runtime/components/prose/Script.vue +12 -0
- package/dist/runtime/components/prose/Script.vue.d.ts +12 -0
- package/dist/runtime/components/prose/Steps.vue +22 -0
- package/dist/runtime/components/prose/Steps.vue.d.ts +22 -0
- package/dist/runtime/components/prose/Strong.vue +21 -0
- package/dist/runtime/components/prose/Strong.vue.d.ts +13 -0
- package/dist/runtime/components/prose/Table.vue +24 -0
- package/dist/runtime/components/prose/Table.vue.d.ts +18 -0
- package/dist/runtime/components/prose/Tabs.vue +78 -0
- package/dist/runtime/components/prose/Tabs.vue.d.ts +36 -0
- package/dist/runtime/components/prose/TabsItem.vue +25 -0
- package/dist/runtime/components/prose/TabsItem.vue.d.ts +15 -0
- package/dist/runtime/components/prose/Tbody.vue +21 -0
- package/dist/runtime/components/prose/Tbody.vue.d.ts +13 -0
- package/dist/runtime/components/prose/Td.vue +21 -0
- package/dist/runtime/components/prose/Td.vue.d.ts +13 -0
- package/dist/runtime/components/prose/Th.vue +21 -0
- package/dist/runtime/components/prose/Th.vue.d.ts +13 -0
- package/dist/runtime/components/prose/Thead.vue +21 -0
- package/dist/runtime/components/prose/Thead.vue.d.ts +13 -0
- package/dist/runtime/components/prose/Tr.vue +21 -0
- package/dist/runtime/components/prose/Tr.vue.d.ts +13 -0
- package/dist/runtime/components/prose/Ul.vue +21 -0
- package/dist/runtime/components/prose/Ul.vue.d.ts +13 -0
- package/dist/runtime/components/prose/callout/Caution.vue +11 -0
- package/dist/runtime/components/prose/callout/Caution.vue.d.ts +14 -0
- package/dist/runtime/components/prose/callout/Note.vue +11 -0
- package/dist/runtime/components/prose/callout/Note.vue.d.ts +14 -0
- package/dist/runtime/components/prose/callout/Tip.vue +11 -0
- package/dist/runtime/components/prose/callout/Tip.vue.d.ts +14 -0
- package/dist/runtime/components/prose/callout/Warning.vue +11 -0
- package/dist/runtime/components/prose/callout/Warning.vue.d.ts +14 -0
- package/dist/runtime/composables/useAvatarGroup.d.ts +1 -1
- package/dist/runtime/composables/useComponentIcons.d.ts +1 -1
- package/dist/runtime/composables/useFormField.d.ts +2 -2
- package/dist/runtime/composables/usePortal.d.ts +1 -1
- package/dist/runtime/composables/useResizable.d.ts +1 -1
- package/dist/runtime/inertia/components/Link.vue +12 -12
- package/dist/runtime/inertia/components/LinkBase.vue +15 -15
- package/dist/runtime/types/app.config.d.ts +6 -6
- package/dist/runtime/types/content.d.ts +4 -1
- package/dist/runtime/types/content.js +4 -0
- package/dist/runtime/types/index.d.ts +1 -0
- package/dist/runtime/types/index.js +1 -0
- package/dist/runtime/types/prose.d.ts +42 -1
- package/dist/runtime/types/prose.js +42 -0
- package/dist/runtime/types/tv.d.ts +2 -2
- package/dist/runtime/utils/index.d.ts +1 -1
- package/dist/runtime/utils/index.js +13 -4
- package/dist/runtime/vue/components/Icon.vue +1 -1
- package/dist/runtime/vue/components/Link.vue +31 -31
- package/dist/runtime/vue/components/color-mode/ColorModeButton.vue +7 -7
- package/dist/runtime/vue/components/color-mode/ColorModeSelect.vue +7 -7
- package/dist/runtime/vue/components/color-mode/ColorModeSwitch.vue +7 -7
- package/dist/shared/{ui.BcVNrqyb.mjs → ui.DQZ75GCP.mjs} +183 -180
- package/dist/unplugin.mjs +9 -9
- package/dist/vite.mjs +1 -1
- package/package.json +8 -9
- package/vue-plugin.d.ts +5 -5
|
@@ -207,167 +207,167 @@ defineExpose({
|
|
|
207
207
|
</script>
|
|
208
208
|
|
|
209
209
|
<template>
|
|
210
|
-
<DefineCreateItemTemplate>
|
|
211
|
-
<ComboboxGroup :class="ui.group({ class: props.ui?.group })">
|
|
212
|
-
<ComboboxItem
|
|
213
|
-
:class="ui.item({ class: props.ui?.item })"
|
|
214
|
-
:value="searchTerm"
|
|
215
|
-
@select.prevent="emits('create', searchTerm)"
|
|
216
|
-
>
|
|
217
|
-
<span :class="ui.itemLabel({ class: props.ui?.itemLabel })">
|
|
218
|
-
<slot name="create-item-label" :item="searchTerm">
|
|
219
|
-
{{ t("inputMenu.create", { label: searchTerm }) }}
|
|
220
|
-
</slot>
|
|
221
|
-
</span>
|
|
222
|
-
</ComboboxItem>
|
|
223
|
-
</ComboboxGroup>
|
|
224
|
-
</DefineCreateItemTemplate>
|
|
225
|
-
|
|
226
|
-
<ComboboxRoot
|
|
227
|
-
:id="id"
|
|
228
|
-
v-slot="{ modelValue, open }"
|
|
229
|
-
v-bind="rootProps"
|
|
230
|
-
:name="name"
|
|
231
|
-
:disabled="disabled"
|
|
232
|
-
:class="ui.root({ class: [props.ui?.root, props.class] })"
|
|
233
|
-
:as-child="!!multiple"
|
|
234
|
-
ignore-filter
|
|
235
|
-
@update:model-value="onUpdate"
|
|
236
|
-
@update:open="onUpdateOpen"
|
|
237
|
-
@keydown.enter="$event.preventDefault()"
|
|
238
|
-
>
|
|
239
|
-
<ComboboxAnchor :as-child="!multiple" :class="ui.base({ class: props.ui?.base })">
|
|
240
|
-
<TagsInputRoot
|
|
241
|
-
v-if="multiple"
|
|
242
|
-
v-slot="{ modelValue: tags }"
|
|
243
|
-
:model-value="modelValue"
|
|
244
|
-
:disabled="disabled"
|
|
245
|
-
:required="required"
|
|
246
|
-
delimiter=""
|
|
247
|
-
as-child
|
|
248
|
-
@blur="onBlur"
|
|
249
|
-
@focus="onFocus"
|
|
250
|
-
@remove-tag="onRemoveTag"
|
|
251
|
-
>
|
|
252
|
-
<TagsInputItem v-for="(item, index) in tags" :key="index" :value="item" :class="ui.tagsItem({ class: [props.ui?.tagsItem, isInputItem(item) && item.ui?.tagsItem] })">
|
|
253
|
-
<TagsInputItemText :class="ui.tagsItemText({ class: [props.ui?.tagsItemText, isInputItem(item) && item.ui?.tagsItemText] })">
|
|
254
|
-
<slot name="tags-item-text" :item="item" :index="index">
|
|
255
|
-
{{ displayValue(item) }}
|
|
256
|
-
</slot>
|
|
257
|
-
</TagsInputItemText>
|
|
258
|
-
|
|
259
|
-
<TagsInputItemDelete :class="ui.tagsItemDelete({ class: [props.ui?.tagsItemDelete, isInputItem(item) && item.ui?.tagsItemDelete] })" :disabled="disabled">
|
|
260
|
-
<slot name="tags-item-delete" :item="item" :index="index">
|
|
261
|
-
<UIcon :name="deleteIcon || appConfig.ui.icons.close" :class="ui.tagsItemDeleteIcon({ class: [props.ui?.tagsItemDeleteIcon, isInputItem(item) && item.ui?.tagsItemDeleteIcon] })" />
|
|
262
|
-
</slot>
|
|
263
|
-
</TagsInputItemDelete>
|
|
264
|
-
</TagsInputItem>
|
|
265
|
-
|
|
266
|
-
<ComboboxInput v-model="searchTerm" as-child>
|
|
267
|
-
<TagsInputInput
|
|
268
|
-
ref="inputRef"
|
|
269
|
-
v-bind="{ ...$attrs, ...ariaAttrs }"
|
|
270
|
-
:placeholder="placeholder"
|
|
271
|
-
:class="ui.tagsInput({ class: props.ui?.tagsInput })"
|
|
272
|
-
@keydown.enter.prevent
|
|
273
|
-
/>
|
|
274
|
-
</ComboboxInput>
|
|
275
|
-
</TagsInputRoot>
|
|
276
|
-
|
|
277
|
-
<ComboboxInput
|
|
278
|
-
v-else
|
|
279
|
-
ref="inputRef"
|
|
280
|
-
:display-value="displayValue"
|
|
281
|
-
v-bind="{ ...$attrs, ...ariaAttrs }"
|
|
282
|
-
:type="type"
|
|
283
|
-
:placeholder="placeholder"
|
|
284
|
-
:required="required"
|
|
285
|
-
@blur="onBlur"
|
|
286
|
-
@focus="onFocus"
|
|
287
|
-
@update:model-value="searchTerm = $event"
|
|
288
|
-
/>
|
|
289
|
-
|
|
290
|
-
<span v-if="isLeading || !!avatar || !!slots.leading" :class="ui.leading({ class: props.ui?.leading })">
|
|
291
|
-
<slot name="leading" :model-value="modelValue" :open="open" :ui="ui">
|
|
292
|
-
<UIcon v-if="isLeading && leadingIconName" :name="leadingIconName" :class="ui.leadingIcon({ class: props.ui?.leadingIcon })" />
|
|
293
|
-
<UAvatar v-else-if="!!avatar" :size="props.ui?.itemLeadingAvatarSize || ui.itemLeadingAvatarSize()" v-bind="avatar" :class="ui.itemLeadingAvatar({ class: props.ui?.itemLeadingAvatar })" />
|
|
294
|
-
</slot>
|
|
295
|
-
</span>
|
|
296
|
-
|
|
297
|
-
<ComboboxTrigger v-if="isTrailing || !!slots.trailing" :class="ui.trailing({ class: props.ui?.trailing })">
|
|
298
|
-
<slot name="trailing" :model-value="modelValue" :open="open" :ui="ui">
|
|
299
|
-
<UIcon v-if="trailingIconName" :name="trailingIconName" :class="ui.trailingIcon({ class: props.ui?.trailingIcon })" />
|
|
300
|
-
</slot>
|
|
301
|
-
</ComboboxTrigger>
|
|
302
|
-
</ComboboxAnchor>
|
|
303
|
-
|
|
304
|
-
<ComboboxPortal v-bind="portalProps">
|
|
305
|
-
<ComboboxContent :class="ui.content({ class: props.ui?.content })" v-bind="contentProps">
|
|
306
|
-
<slot name="content-top" />
|
|
307
|
-
|
|
308
|
-
<ComboboxEmpty :class="ui.empty({ class: props.ui?.empty })">
|
|
309
|
-
<slot name="empty" :search-term="searchTerm">
|
|
310
|
-
{{ searchTerm ? t("inputMenu.noMatch", { searchTerm }) : t("inputMenu.noData") }}
|
|
311
|
-
</slot>
|
|
312
|
-
</ComboboxEmpty>
|
|
313
|
-
|
|
314
|
-
<div role="presentation" :class="ui.viewport({ class: props.ui?.viewport })">
|
|
315
|
-
<ReuseCreateItemTemplate v-if="createItem && createItemPosition === 'top'" />
|
|
316
|
-
|
|
317
|
-
<ComboboxGroup v-for="(group, groupIndex) in filteredGroups" :key="`group-${groupIndex}`" :class="ui.group({ class: props.ui?.group })">
|
|
318
|
-
<template v-for="(item, index) in group" :key="`group-${groupIndex}-${index}`">
|
|
319
|
-
<ComboboxLabel v-if="isInputItem(item) && item.type === 'label'" :class="ui.label({ class: [props.ui?.label, item.ui?.label, item.class] })">
|
|
320
|
-
{{ get(item, props.labelKey) }}
|
|
321
|
-
</ComboboxLabel>
|
|
322
|
-
|
|
323
|
-
<ComboboxSeparator v-else-if="isInputItem(item) && item.type === 'separator'" :class="ui.separator({ class: [props.ui?.separator, item.ui?.separator, item.class] })" />
|
|
324
|
-
|
|
325
|
-
<ComboboxItem
|
|
326
|
-
v-else
|
|
327
|
-
:class="ui.item({ class: [props.ui?.item, isInputItem(item) && item.ui?.item, isInputItem(item) && item.class] })"
|
|
328
|
-
:disabled="isInputItem(item) && item.disabled"
|
|
329
|
-
:value="props.valueKey && isInputItem(item) ? get(item, props.valueKey) : item"
|
|
330
|
-
@select="onSelect($event, item)"
|
|
331
|
-
>
|
|
332
|
-
<slot name="item" :item="item" :index="index">
|
|
333
|
-
<slot name="item-leading" :item="item" :index="index">
|
|
334
|
-
<UIcon v-if="isInputItem(item) && item.icon" :name="item.icon" :class="ui.itemLeadingIcon({ class: [props.ui?.itemLeadingIcon, item.ui?.itemLeadingIcon] })" />
|
|
335
|
-
<UAvatar v-else-if="isInputItem(item) && item.avatar" :size="item.ui?.itemLeadingAvatarSize || props.ui?.itemLeadingAvatarSize || ui.itemLeadingAvatarSize()" v-bind="item.avatar" :class="ui.itemLeadingAvatar({ class: [props.ui?.itemLeadingAvatar, item.ui?.itemLeadingAvatar] })" />
|
|
336
|
-
<UChip
|
|
337
|
-
v-else-if="isInputItem(item) && item.chip"
|
|
338
|
-
:size="item.ui?.itemLeadingChipSize || props.ui?.itemLeadingChipSize || ui.itemLeadingChipSize()"
|
|
339
|
-
inset
|
|
340
|
-
standalone
|
|
341
|
-
v-bind="item.chip"
|
|
342
|
-
:class="ui.itemLeadingChip({ class: [props.ui?.itemLeadingChip, item.ui?.itemLeadingChip] })"
|
|
343
|
-
/>
|
|
344
|
-
</slot>
|
|
345
|
-
|
|
346
|
-
<span :class="ui.itemLabel({ class: [props.ui?.itemLabel, isInputItem(item) && item.ui?.itemLabel] })">
|
|
347
|
-
<slot name="item-label" :item="item" :index="index">
|
|
348
|
-
{{ isInputItem(item) ? get(item, props.labelKey) : item }}
|
|
349
|
-
</slot>
|
|
350
|
-
</span>
|
|
351
|
-
|
|
352
|
-
<span :class="ui.itemTrailing({ class: [props.ui?.itemTrailing, isInputItem(item) && item.ui?.itemTrailing] })">
|
|
353
|
-
<slot name="item-trailing" :item="item" :index="index" />
|
|
354
|
-
|
|
355
|
-
<ComboboxItemIndicator as-child>
|
|
356
|
-
<UIcon :name="selectedIcon || appConfig.ui.icons.check" :class="ui.itemTrailingIcon({ class: [props.ui?.itemTrailingIcon, isInputItem(item) && item.ui?.itemTrailingIcon] })" />
|
|
357
|
-
</ComboboxItemIndicator>
|
|
358
|
-
</span>
|
|
359
|
-
</slot>
|
|
360
|
-
</ComboboxItem>
|
|
361
|
-
</template>
|
|
362
|
-
</ComboboxGroup>
|
|
363
|
-
|
|
364
|
-
<ReuseCreateItemTemplate v-if="createItem && createItemPosition === 'bottom'" />
|
|
365
|
-
</div>
|
|
366
|
-
|
|
367
|
-
<slot name="content-bottom" />
|
|
368
|
-
|
|
369
|
-
<ComboboxArrow v-if="!!arrow" v-bind="arrowProps" :class="ui.arrow({ class: props.ui?.arrow })" />
|
|
370
|
-
</ComboboxContent>
|
|
371
|
-
</ComboboxPortal>
|
|
372
|
-
</ComboboxRoot>
|
|
210
|
+
<DefineCreateItemTemplate>
|
|
211
|
+
<ComboboxGroup :class="ui.group({ class: props.ui?.group })">
|
|
212
|
+
<ComboboxItem
|
|
213
|
+
:class="ui.item({ class: props.ui?.item })"
|
|
214
|
+
:value="searchTerm"
|
|
215
|
+
@select.prevent="emits('create', searchTerm)"
|
|
216
|
+
>
|
|
217
|
+
<span :class="ui.itemLabel({ class: props.ui?.itemLabel })">
|
|
218
|
+
<slot name="create-item-label" :item="searchTerm">
|
|
219
|
+
{{ t("inputMenu.create", { label: searchTerm }) }}
|
|
220
|
+
</slot>
|
|
221
|
+
</span>
|
|
222
|
+
</ComboboxItem>
|
|
223
|
+
</ComboboxGroup>
|
|
224
|
+
</DefineCreateItemTemplate>
|
|
225
|
+
|
|
226
|
+
<ComboboxRoot
|
|
227
|
+
:id="id"
|
|
228
|
+
v-slot="{ modelValue, open }"
|
|
229
|
+
v-bind="rootProps"
|
|
230
|
+
:name="name"
|
|
231
|
+
:disabled="disabled"
|
|
232
|
+
:class="ui.root({ class: [props.ui?.root, props.class] })"
|
|
233
|
+
:as-child="!!multiple"
|
|
234
|
+
ignore-filter
|
|
235
|
+
@update:model-value="onUpdate"
|
|
236
|
+
@update:open="onUpdateOpen"
|
|
237
|
+
@keydown.enter="$event.preventDefault()"
|
|
238
|
+
>
|
|
239
|
+
<ComboboxAnchor :as-child="!multiple" :class="ui.base({ class: props.ui?.base })">
|
|
240
|
+
<TagsInputRoot
|
|
241
|
+
v-if="multiple"
|
|
242
|
+
v-slot="{ modelValue: tags }"
|
|
243
|
+
:model-value="modelValue"
|
|
244
|
+
:disabled="disabled"
|
|
245
|
+
:required="required"
|
|
246
|
+
delimiter=""
|
|
247
|
+
as-child
|
|
248
|
+
@blur="onBlur"
|
|
249
|
+
@focus="onFocus"
|
|
250
|
+
@remove-tag="onRemoveTag"
|
|
251
|
+
>
|
|
252
|
+
<TagsInputItem v-for="(item, index) in tags" :key="index" :value="item" :class="ui.tagsItem({ class: [props.ui?.tagsItem, isInputItem(item) && item.ui?.tagsItem] })">
|
|
253
|
+
<TagsInputItemText :class="ui.tagsItemText({ class: [props.ui?.tagsItemText, isInputItem(item) && item.ui?.tagsItemText] })">
|
|
254
|
+
<slot name="tags-item-text" :item="item" :index="index">
|
|
255
|
+
{{ displayValue(item) }}
|
|
256
|
+
</slot>
|
|
257
|
+
</TagsInputItemText>
|
|
258
|
+
|
|
259
|
+
<TagsInputItemDelete :class="ui.tagsItemDelete({ class: [props.ui?.tagsItemDelete, isInputItem(item) && item.ui?.tagsItemDelete] })" :disabled="disabled">
|
|
260
|
+
<slot name="tags-item-delete" :item="item" :index="index">
|
|
261
|
+
<UIcon :name="deleteIcon || appConfig.ui.icons.close" :class="ui.tagsItemDeleteIcon({ class: [props.ui?.tagsItemDeleteIcon, isInputItem(item) && item.ui?.tagsItemDeleteIcon] })" />
|
|
262
|
+
</slot>
|
|
263
|
+
</TagsInputItemDelete>
|
|
264
|
+
</TagsInputItem>
|
|
265
|
+
|
|
266
|
+
<ComboboxInput v-model="searchTerm" as-child>
|
|
267
|
+
<TagsInputInput
|
|
268
|
+
ref="inputRef"
|
|
269
|
+
v-bind="{ ...$attrs, ...ariaAttrs }"
|
|
270
|
+
:placeholder="placeholder"
|
|
271
|
+
:class="ui.tagsInput({ class: props.ui?.tagsInput })"
|
|
272
|
+
@keydown.enter.prevent
|
|
273
|
+
/>
|
|
274
|
+
</ComboboxInput>
|
|
275
|
+
</TagsInputRoot>
|
|
276
|
+
|
|
277
|
+
<ComboboxInput
|
|
278
|
+
v-else
|
|
279
|
+
ref="inputRef"
|
|
280
|
+
:display-value="displayValue"
|
|
281
|
+
v-bind="{ ...$attrs, ...ariaAttrs }"
|
|
282
|
+
:type="type"
|
|
283
|
+
:placeholder="placeholder"
|
|
284
|
+
:required="required"
|
|
285
|
+
@blur="onBlur"
|
|
286
|
+
@focus="onFocus"
|
|
287
|
+
@update:model-value="searchTerm = $event"
|
|
288
|
+
/>
|
|
289
|
+
|
|
290
|
+
<span v-if="isLeading || !!avatar || !!slots.leading" :class="ui.leading({ class: props.ui?.leading })">
|
|
291
|
+
<slot name="leading" :model-value="modelValue" :open="open" :ui="ui">
|
|
292
|
+
<UIcon v-if="isLeading && leadingIconName" :name="leadingIconName" :class="ui.leadingIcon({ class: props.ui?.leadingIcon })" />
|
|
293
|
+
<UAvatar v-else-if="!!avatar" :size="props.ui?.itemLeadingAvatarSize || ui.itemLeadingAvatarSize()" v-bind="avatar" :class="ui.itemLeadingAvatar({ class: props.ui?.itemLeadingAvatar })" />
|
|
294
|
+
</slot>
|
|
295
|
+
</span>
|
|
296
|
+
|
|
297
|
+
<ComboboxTrigger v-if="isTrailing || !!slots.trailing" :class="ui.trailing({ class: props.ui?.trailing })">
|
|
298
|
+
<slot name="trailing" :model-value="modelValue" :open="open" :ui="ui">
|
|
299
|
+
<UIcon v-if="trailingIconName" :name="trailingIconName" :class="ui.trailingIcon({ class: props.ui?.trailingIcon })" />
|
|
300
|
+
</slot>
|
|
301
|
+
</ComboboxTrigger>
|
|
302
|
+
</ComboboxAnchor>
|
|
303
|
+
|
|
304
|
+
<ComboboxPortal v-bind="portalProps">
|
|
305
|
+
<ComboboxContent :class="ui.content({ class: props.ui?.content })" v-bind="contentProps">
|
|
306
|
+
<slot name="content-top" />
|
|
307
|
+
|
|
308
|
+
<ComboboxEmpty :class="ui.empty({ class: props.ui?.empty })">
|
|
309
|
+
<slot name="empty" :search-term="searchTerm">
|
|
310
|
+
{{ searchTerm ? t("inputMenu.noMatch", { searchTerm }) : t("inputMenu.noData") }}
|
|
311
|
+
</slot>
|
|
312
|
+
</ComboboxEmpty>
|
|
313
|
+
|
|
314
|
+
<div role="presentation" :class="ui.viewport({ class: props.ui?.viewport })">
|
|
315
|
+
<ReuseCreateItemTemplate v-if="createItem && createItemPosition === 'top'" />
|
|
316
|
+
|
|
317
|
+
<ComboboxGroup v-for="(group, groupIndex) in filteredGroups" :key="`group-${groupIndex}`" :class="ui.group({ class: props.ui?.group })">
|
|
318
|
+
<template v-for="(item, index) in group" :key="`group-${groupIndex}-${index}`">
|
|
319
|
+
<ComboboxLabel v-if="isInputItem(item) && item.type === 'label'" :class="ui.label({ class: [props.ui?.label, item.ui?.label, item.class] })">
|
|
320
|
+
{{ get(item, props.labelKey) }}
|
|
321
|
+
</ComboboxLabel>
|
|
322
|
+
|
|
323
|
+
<ComboboxSeparator v-else-if="isInputItem(item) && item.type === 'separator'" :class="ui.separator({ class: [props.ui?.separator, item.ui?.separator, item.class] })" />
|
|
324
|
+
|
|
325
|
+
<ComboboxItem
|
|
326
|
+
v-else
|
|
327
|
+
:class="ui.item({ class: [props.ui?.item, isInputItem(item) && item.ui?.item, isInputItem(item) && item.class] })"
|
|
328
|
+
:disabled="isInputItem(item) && item.disabled"
|
|
329
|
+
:value="props.valueKey && isInputItem(item) ? get(item, props.valueKey) : item"
|
|
330
|
+
@select="onSelect($event, item)"
|
|
331
|
+
>
|
|
332
|
+
<slot name="item" :item="item" :index="index">
|
|
333
|
+
<slot name="item-leading" :item="item" :index="index">
|
|
334
|
+
<UIcon v-if="isInputItem(item) && item.icon" :name="item.icon" :class="ui.itemLeadingIcon({ class: [props.ui?.itemLeadingIcon, item.ui?.itemLeadingIcon] })" />
|
|
335
|
+
<UAvatar v-else-if="isInputItem(item) && item.avatar" :size="item.ui?.itemLeadingAvatarSize || props.ui?.itemLeadingAvatarSize || ui.itemLeadingAvatarSize()" v-bind="item.avatar" :class="ui.itemLeadingAvatar({ class: [props.ui?.itemLeadingAvatar, item.ui?.itemLeadingAvatar] })" />
|
|
336
|
+
<UChip
|
|
337
|
+
v-else-if="isInputItem(item) && item.chip"
|
|
338
|
+
:size="item.ui?.itemLeadingChipSize || props.ui?.itemLeadingChipSize || ui.itemLeadingChipSize()"
|
|
339
|
+
inset
|
|
340
|
+
standalone
|
|
341
|
+
v-bind="item.chip"
|
|
342
|
+
:class="ui.itemLeadingChip({ class: [props.ui?.itemLeadingChip, item.ui?.itemLeadingChip] })"
|
|
343
|
+
/>
|
|
344
|
+
</slot>
|
|
345
|
+
|
|
346
|
+
<span :class="ui.itemLabel({ class: [props.ui?.itemLabel, isInputItem(item) && item.ui?.itemLabel] })">
|
|
347
|
+
<slot name="item-label" :item="item" :index="index">
|
|
348
|
+
{{ isInputItem(item) ? get(item, props.labelKey) : item }}
|
|
349
|
+
</slot>
|
|
350
|
+
</span>
|
|
351
|
+
|
|
352
|
+
<span :class="ui.itemTrailing({ class: [props.ui?.itemTrailing, isInputItem(item) && item.ui?.itemTrailing] })">
|
|
353
|
+
<slot name="item-trailing" :item="item" :index="index" />
|
|
354
|
+
|
|
355
|
+
<ComboboxItemIndicator as-child>
|
|
356
|
+
<UIcon :name="selectedIcon || appConfig.ui.icons.check" :class="ui.itemTrailingIcon({ class: [props.ui?.itemTrailingIcon, isInputItem(item) && item.ui?.itemTrailingIcon] })" />
|
|
357
|
+
</ComboboxItemIndicator>
|
|
358
|
+
</span>
|
|
359
|
+
</slot>
|
|
360
|
+
</ComboboxItem>
|
|
361
|
+
</template>
|
|
362
|
+
</ComboboxGroup>
|
|
363
|
+
|
|
364
|
+
<ReuseCreateItemTemplate v-if="createItem && createItemPosition === 'bottom'" />
|
|
365
|
+
</div>
|
|
366
|
+
|
|
367
|
+
<slot name="content-bottom" />
|
|
368
|
+
|
|
369
|
+
<ComboboxArrow v-if="!!arrow" v-bind="arrowProps" :class="ui.arrow({ class: props.ui?.arrow })" />
|
|
370
|
+
</ComboboxContent>
|
|
371
|
+
</ComboboxPortal>
|
|
372
|
+
</ComboboxRoot>
|
|
373
373
|
</template>
|
|
@@ -92,53 +92,53 @@ defineExpose({
|
|
|
92
92
|
</script>
|
|
93
93
|
|
|
94
94
|
<template>
|
|
95
|
-
<NumberFieldRoot
|
|
96
|
-
v-bind="rootProps"
|
|
97
|
-
:id="id"
|
|
98
|
-
:class="ui.root({ class: [props.ui?.root, props.class] })"
|
|
99
|
-
:name="name"
|
|
100
|
-
:disabled="disabled"
|
|
101
|
-
:locale="locale"
|
|
102
|
-
@update:model-value="onUpdate"
|
|
103
|
-
>
|
|
104
|
-
<NumberFieldInput
|
|
105
|
-
v-bind="{ ...$attrs, ...ariaAttrs }"
|
|
106
|
-
ref="inputRef"
|
|
107
|
-
:placeholder="placeholder"
|
|
108
|
-
:required="required"
|
|
109
|
-
:class="ui.base({ class: props.ui?.base })"
|
|
110
|
-
@blur="onBlur"
|
|
111
|
-
@focus="emitFormFocus"
|
|
112
|
-
/>
|
|
113
|
-
|
|
114
|
-
<div :class="ui.increment({ class: props.ui?.increment })">
|
|
115
|
-
<NumberFieldIncrement as-child :disabled="disabled || incrementDisabled">
|
|
116
|
-
<slot name="increment">
|
|
117
|
-
<UButton
|
|
118
|
-
:icon="incrementIcon"
|
|
119
|
-
:color="color"
|
|
120
|
-
:size="size"
|
|
121
|
-
variant="link"
|
|
122
|
-
:aria-label="t('inputNumber.increment')"
|
|
123
|
-
v-bind="typeof increment === 'object' ? increment : void 0"
|
|
124
|
-
/>
|
|
125
|
-
</slot>
|
|
126
|
-
</NumberFieldIncrement>
|
|
127
|
-
</div>
|
|
128
|
-
|
|
129
|
-
<div :class="ui.decrement({ class: props.ui?.decrement })">
|
|
130
|
-
<NumberFieldDecrement as-child :disabled="disabled || decrementDisabled">
|
|
131
|
-
<slot name="decrement">
|
|
132
|
-
<UButton
|
|
133
|
-
:icon="decrementIcon"
|
|
134
|
-
:color="color"
|
|
135
|
-
:size="size"
|
|
136
|
-
variant="link"
|
|
137
|
-
:aria-label="t('inputNumber.decrement')"
|
|
138
|
-
v-bind="typeof decrement === 'object' ? decrement : void 0"
|
|
139
|
-
/>
|
|
140
|
-
</slot>
|
|
141
|
-
</NumberFieldDecrement>
|
|
142
|
-
</div>
|
|
143
|
-
</NumberFieldRoot>
|
|
95
|
+
<NumberFieldRoot
|
|
96
|
+
v-bind="rootProps"
|
|
97
|
+
:id="id"
|
|
98
|
+
:class="ui.root({ class: [props.ui?.root, props.class] })"
|
|
99
|
+
:name="name"
|
|
100
|
+
:disabled="disabled"
|
|
101
|
+
:locale="locale"
|
|
102
|
+
@update:model-value="onUpdate"
|
|
103
|
+
>
|
|
104
|
+
<NumberFieldInput
|
|
105
|
+
v-bind="{ ...$attrs, ...ariaAttrs }"
|
|
106
|
+
ref="inputRef"
|
|
107
|
+
:placeholder="placeholder"
|
|
108
|
+
:required="required"
|
|
109
|
+
:class="ui.base({ class: props.ui?.base })"
|
|
110
|
+
@blur="onBlur"
|
|
111
|
+
@focus="emitFormFocus"
|
|
112
|
+
/>
|
|
113
|
+
|
|
114
|
+
<div :class="ui.increment({ class: props.ui?.increment })">
|
|
115
|
+
<NumberFieldIncrement as-child :disabled="disabled || incrementDisabled">
|
|
116
|
+
<slot name="increment">
|
|
117
|
+
<UButton
|
|
118
|
+
:icon="incrementIcon"
|
|
119
|
+
:color="color"
|
|
120
|
+
:size="size"
|
|
121
|
+
variant="link"
|
|
122
|
+
:aria-label="t('inputNumber.increment')"
|
|
123
|
+
v-bind="typeof increment === 'object' ? increment : void 0"
|
|
124
|
+
/>
|
|
125
|
+
</slot>
|
|
126
|
+
</NumberFieldIncrement>
|
|
127
|
+
</div>
|
|
128
|
+
|
|
129
|
+
<div :class="ui.decrement({ class: props.ui?.decrement })">
|
|
130
|
+
<NumberFieldDecrement as-child :disabled="disabled || decrementDisabled">
|
|
131
|
+
<slot name="decrement">
|
|
132
|
+
<UButton
|
|
133
|
+
:icon="decrementIcon"
|
|
134
|
+
:color="color"
|
|
135
|
+
:size="size"
|
|
136
|
+
variant="link"
|
|
137
|
+
:aria-label="t('inputNumber.decrement')"
|
|
138
|
+
v-bind="typeof decrement === 'object' ? decrement : void 0"
|
|
139
|
+
/>
|
|
140
|
+
</slot>
|
|
141
|
+
</NumberFieldDecrement>
|
|
142
|
+
</div>
|
|
143
|
+
</NumberFieldRoot>
|
|
144
144
|
</template>
|
|
@@ -101,59 +101,59 @@ defineExpose({
|
|
|
101
101
|
</script>
|
|
102
102
|
|
|
103
103
|
<template>
|
|
104
|
-
<TagsInputRoot
|
|
105
|
-
:id="id"
|
|
106
|
-
v-slot="{ modelValue: tags }"
|
|
107
|
-
:model-value="modelValue"
|
|
108
|
-
:default-value="defaultValue"
|
|
109
|
-
:class="ui.root({ class: [ui.base({ class: props.ui?.base }), props.ui?.root, props.class] })"
|
|
110
|
-
v-bind="rootProps"
|
|
111
|
-
:name="name"
|
|
112
|
-
:disabled="disabled"
|
|
113
|
-
@update:model-value="onUpdate"
|
|
114
|
-
@blur="onBlur"
|
|
115
|
-
@focus="onFocus"
|
|
116
|
-
>
|
|
117
|
-
<TagsInputItem
|
|
118
|
-
v-for="(item, index) in tags"
|
|
119
|
-
:key="index"
|
|
120
|
-
:value="item"
|
|
121
|
-
:class="ui.item({ class: [props.ui?.item] })"
|
|
122
|
-
>
|
|
123
|
-
<TagsInputItemText :class="ui.itemText({ class: [props.ui?.itemText] })">
|
|
124
|
-
<slot v-if="!!slots['item-text']" name="item-text" :item="item" :index="index" />
|
|
125
|
-
</TagsInputItemText>
|
|
126
|
-
|
|
127
|
-
<TagsInputItemDelete
|
|
128
|
-
:class="ui.itemDelete({ class: [props.ui?.itemDelete] })"
|
|
129
|
-
:disabled="disabled"
|
|
130
|
-
>
|
|
131
|
-
<slot name="item-delete" :item="item" :index="index">
|
|
132
|
-
<UIcon :name="deleteIcon || appConfig.ui.icons.close" :class="ui.itemDeleteIcon({ class: [props.ui?.itemDeleteIcon] })" />
|
|
133
|
-
</slot>
|
|
134
|
-
</TagsInputItemDelete>
|
|
135
|
-
</TagsInputItem>
|
|
136
|
-
|
|
137
|
-
<TagsInputInput
|
|
138
|
-
ref="inputRef"
|
|
139
|
-
v-bind="{ ...$attrs, ...ariaAttrs }"
|
|
140
|
-
:placeholder="placeholder"
|
|
141
|
-
:class="ui.input({ class: props.ui?.input })"
|
|
142
|
-
/>
|
|
143
|
-
|
|
144
|
-
<slot />
|
|
145
|
-
|
|
146
|
-
<span v-if="isLeading || !!avatar || !!slots.leading" :class="ui.leading({ class: props.ui?.leading })">
|
|
147
|
-
<slot name="leading">
|
|
148
|
-
<UIcon v-if="isLeading && leadingIconName" :name="leadingIconName" :class="ui.leadingIcon({ class: props.ui?.leadingIcon })" />
|
|
149
|
-
<UAvatar v-else-if="!!avatar" :size="props.ui?.leadingAvatarSize || ui.leadingAvatarSize()" v-bind="avatar" :class="ui.leadingAvatar({ class: props.ui?.leadingAvatar })" />
|
|
150
|
-
</slot>
|
|
151
|
-
</span>
|
|
152
|
-
|
|
153
|
-
<span v-if="isTrailing || !!slots.trailing" :class="ui.trailing({ class: props.ui?.trailing })">
|
|
154
|
-
<slot name="trailing">
|
|
155
|
-
<UIcon v-if="trailingIconName" :name="trailingIconName" :class="ui.trailingIcon({ class: props.ui?.trailingIcon })" />
|
|
156
|
-
</slot>
|
|
157
|
-
</span>
|
|
158
|
-
</TagsInputRoot>
|
|
104
|
+
<TagsInputRoot
|
|
105
|
+
:id="id"
|
|
106
|
+
v-slot="{ modelValue: tags }"
|
|
107
|
+
:model-value="modelValue"
|
|
108
|
+
:default-value="defaultValue"
|
|
109
|
+
:class="ui.root({ class: [ui.base({ class: props.ui?.base }), props.ui?.root, props.class] })"
|
|
110
|
+
v-bind="rootProps"
|
|
111
|
+
:name="name"
|
|
112
|
+
:disabled="disabled"
|
|
113
|
+
@update:model-value="onUpdate"
|
|
114
|
+
@blur="onBlur"
|
|
115
|
+
@focus="onFocus"
|
|
116
|
+
>
|
|
117
|
+
<TagsInputItem
|
|
118
|
+
v-for="(item, index) in tags"
|
|
119
|
+
:key="index"
|
|
120
|
+
:value="item"
|
|
121
|
+
:class="ui.item({ class: [props.ui?.item] })"
|
|
122
|
+
>
|
|
123
|
+
<TagsInputItemText :class="ui.itemText({ class: [props.ui?.itemText] })">
|
|
124
|
+
<slot v-if="!!slots['item-text']" name="item-text" :item="item" :index="index" />
|
|
125
|
+
</TagsInputItemText>
|
|
126
|
+
|
|
127
|
+
<TagsInputItemDelete
|
|
128
|
+
:class="ui.itemDelete({ class: [props.ui?.itemDelete] })"
|
|
129
|
+
:disabled="disabled"
|
|
130
|
+
>
|
|
131
|
+
<slot name="item-delete" :item="item" :index="index">
|
|
132
|
+
<UIcon :name="deleteIcon || appConfig.ui.icons.close" :class="ui.itemDeleteIcon({ class: [props.ui?.itemDeleteIcon] })" />
|
|
133
|
+
</slot>
|
|
134
|
+
</TagsInputItemDelete>
|
|
135
|
+
</TagsInputItem>
|
|
136
|
+
|
|
137
|
+
<TagsInputInput
|
|
138
|
+
ref="inputRef"
|
|
139
|
+
v-bind="{ ...$attrs, ...ariaAttrs }"
|
|
140
|
+
:placeholder="placeholder"
|
|
141
|
+
:class="ui.input({ class: props.ui?.input })"
|
|
142
|
+
/>
|
|
143
|
+
|
|
144
|
+
<slot />
|
|
145
|
+
|
|
146
|
+
<span v-if="isLeading || !!avatar || !!slots.leading" :class="ui.leading({ class: props.ui?.leading })">
|
|
147
|
+
<slot name="leading">
|
|
148
|
+
<UIcon v-if="isLeading && leadingIconName" :name="leadingIconName" :class="ui.leadingIcon({ class: props.ui?.leadingIcon })" />
|
|
149
|
+
<UAvatar v-else-if="!!avatar" :size="props.ui?.leadingAvatarSize || ui.leadingAvatarSize()" v-bind="avatar" :class="ui.leadingAvatar({ class: props.ui?.leadingAvatar })" />
|
|
150
|
+
</slot>
|
|
151
|
+
</span>
|
|
152
|
+
|
|
153
|
+
<span v-if="isTrailing || !!slots.trailing" :class="ui.trailing({ class: props.ui?.trailing })">
|
|
154
|
+
<slot name="trailing">
|
|
155
|
+
<UIcon v-if="trailingIconName" :name="trailingIconName" :class="ui.trailingIcon({ class: props.ui?.trailingIcon })" />
|
|
156
|
+
</slot>
|
|
157
|
+
</span>
|
|
158
|
+
</TagsInputRoot>
|
|
159
159
|
</template>
|
|
@@ -22,9 +22,9 @@ const ui = computed(() => tv({ extend: tv(theme), ...appConfig.ui?.kbd || {} }))
|
|
|
22
22
|
</script>
|
|
23
23
|
|
|
24
24
|
<template>
|
|
25
|
-
<Primitive :as="as" :class="ui({ variant, size, class: props.class })">
|
|
26
|
-
<slot>
|
|
27
|
-
{{ getKbdKey(value) }}
|
|
28
|
-
</slot>
|
|
29
|
-
</Primitive>
|
|
25
|
+
<Primitive :as="as" :class="ui({ variant, size, class: props.class })">
|
|
26
|
+
<slot>
|
|
27
|
+
{{ getKbdKey(value) }}
|
|
28
|
+
</slot>
|
|
29
|
+
</Primitive>
|
|
30
30
|
</template>
|
|
@@ -87,9 +87,9 @@ function resolveLinkClass({ route: route2, isActive, isExactActive }) {
|
|
|
87
87
|
</script>
|
|
88
88
|
|
|
89
89
|
<template>
|
|
90
|
-
<NuxtLink v-slot="{ href, navigate, route: linkRoute, rel, target, isExternal, isActive, isExactActive }" v-bind="nuxtLinkProps" :to="to" custom>
|
|
91
|
-
<template v-if="custom">
|
|
92
|
-
<slot
|
|
90
|
+
<NuxtLink v-slot="{ href, navigate, route: linkRoute, rel, target, isExternal, isActive, isExactActive }" v-bind="nuxtLinkProps" :to="to" custom>
|
|
91
|
+
<template v-if="custom">
|
|
92
|
+
<slot
|
|
93
93
|
v-bind="{
|
|
94
94
|
...$attrs,
|
|
95
95
|
...exact && isExactActive ? { 'aria-current': props.ariaCurrentValue } : {},
|
|
@@ -102,11 +102,11 @@ function resolveLinkClass({ route: route2, isActive, isExactActive }) {
|
|
|
102
102
|
target,
|
|
103
103
|
isExternal,
|
|
104
104
|
active: isLinkActive({ route: linkRoute, isActive, isExactActive })
|
|
105
|
-
}"
|
|
106
|
-
/>
|
|
107
|
-
</template>
|
|
108
|
-
<ULinkBase
|
|
109
|
-
v-else
|
|
105
|
+
}"
|
|
106
|
+
/>
|
|
107
|
+
</template>
|
|
108
|
+
<ULinkBase
|
|
109
|
+
v-else
|
|
110
110
|
v-bind="{
|
|
111
111
|
...$attrs,
|
|
112
112
|
...exact && isExactActive ? { 'aria-current': props.ariaCurrentValue } : {},
|
|
@@ -118,10 +118,10 @@ function resolveLinkClass({ route: route2, isActive, isExactActive }) {
|
|
|
118
118
|
rel,
|
|
119
119
|
target,
|
|
120
120
|
isExternal
|
|
121
|
-
}"
|
|
122
|
-
:class="resolveLinkClass({ route: linkRoute, isActive, isExactActive })"
|
|
123
|
-
>
|
|
124
|
-
<slot :active="isLinkActive({ route: linkRoute, isActive, isExactActive })" />
|
|
125
|
-
</ULinkBase>
|
|
126
|
-
</NuxtLink>
|
|
121
|
+
}"
|
|
122
|
+
:class="resolveLinkClass({ route: linkRoute, isActive, isExactActive })"
|
|
123
|
+
>
|
|
124
|
+
<slot :active="isLinkActive({ route: linkRoute, isActive, isExactActive })" />
|
|
125
|
+
</ULinkBase>
|
|
126
|
+
</NuxtLink>
|
|
127
127
|
</template>
|
|
@@ -34,7 +34,7 @@ function onClickWrapper(e) {
|
|
|
34
34
|
</script>
|
|
35
35
|
|
|
36
36
|
<template>
|
|
37
|
-
<Primitive
|
|
37
|
+
<Primitive
|
|
38
38
|
v-bind="href ? {
|
|
39
39
|
'as': 'a',
|
|
40
40
|
'href': disabled ? void 0 : href,
|
|
@@ -47,11 +47,11 @@ function onClickWrapper(e) {
|
|
|
47
47
|
disabled
|
|
48
48
|
} : {
|
|
49
49
|
as
|
|
50
|
-
}"
|
|
51
|
-
:rel="rel"
|
|
52
|
-
:target="target"
|
|
53
|
-
@click="onClickWrapper"
|
|
54
|
-
>
|
|
55
|
-
<slot />
|
|
56
|
-
</Primitive>
|
|
50
|
+
}"
|
|
51
|
+
:rel="rel"
|
|
52
|
+
:target="target"
|
|
53
|
+
@click="onClickWrapper"
|
|
54
|
+
>
|
|
55
|
+
<slot />
|
|
56
|
+
</Primitive>
|
|
57
57
|
</template>
|