@soybeanjs/ui 0.13.8 → 0.15.0-beta.1
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/README.md +79 -147
- package/README.zh-CN.md +79 -147
- package/dist/components/accordion/accordion.js +1 -1
- package/dist/components/accordion/accordion.vue.d.ts +6 -34
- package/dist/components/accordion/index.d.ts +3 -3
- package/dist/components/accordion/types.d.ts +6 -25
- package/dist/components/affix/affix.js +1 -0
- package/dist/components/affix/affix.vue.d.ts +22 -0
- package/dist/components/affix/index.d.ts +4 -0
- package/dist/components/affix/index.js +1 -0
- package/dist/components/affix/types.d.ts +15 -0
- package/dist/components/affix/variants.js +1 -0
- package/dist/components/alert/alert.js +1 -1
- package/dist/components/alert/alert.vue.d.ts +4 -4
- package/dist/components/alert/variants.d.ts +3 -3
- package/dist/components/alert-dialog/alert-dialog-cancel.vue.d.ts +4 -4
- package/dist/components/alert-dialog/alert-dialog-confirm.vue.d.ts +4 -4
- package/dist/components/alert-dialog/alert-dialog.vue.d.ts +6 -6
- package/dist/components/anchor/anchor-item.js +1 -0
- package/dist/components/anchor/anchor.js +1 -0
- package/dist/components/anchor/anchor.vue.d.ts +23 -0
- package/dist/components/anchor/context.js +1 -0
- package/dist/components/anchor/index.d.ts +4 -0
- package/dist/components/anchor/index.js +1 -0
- package/dist/components/anchor/types.d.ts +34 -0
- package/dist/components/anchor/variants.js +1 -0
- package/dist/components/autocomplete/autocomplete-group-option.js +1 -0
- package/dist/components/autocomplete/autocomplete-option.js +1 -0
- package/dist/components/autocomplete/autocomplete-single-option.js +1 -0
- package/dist/components/autocomplete/autocomplete.js +1 -0
- package/dist/components/autocomplete/autocomplete.vue.d.ts +47 -0
- package/dist/components/autocomplete/context.js +1 -0
- package/dist/components/autocomplete/index.d.ts +4 -0
- package/dist/components/autocomplete/index.js +1 -0
- package/dist/components/autocomplete/shared.js +1 -0
- package/dist/components/autocomplete/types.d.ts +94 -0
- package/dist/components/autocomplete/variants.js +1 -0
- package/dist/components/avatar/avatar.vue.d.ts +7 -7
- package/dist/components/badge/badge.vue.d.ts +4 -4
- package/dist/components/badge/variants.d.ts +3 -3
- package/dist/components/bottom-sheet/bottom-sheet-close.js +1 -0
- package/dist/components/bottom-sheet/bottom-sheet-close.vue.d.ts +18 -0
- package/dist/components/bottom-sheet/bottom-sheet.js +1 -0
- package/dist/components/bottom-sheet/bottom-sheet.vue.d.ts +72 -0
- package/dist/components/bottom-sheet/index.d.ts +3 -0
- package/dist/components/bottom-sheet/index.js +1 -0
- package/dist/components/bottom-sheet/types.d.ts +31 -0
- package/dist/components/bottom-sheet/variants.js +1 -0
- package/dist/components/breadcrumb/breadcrumb.vue.d.ts +3 -3
- package/dist/components/button/button-group.vue.d.ts +6 -6
- package/dist/components/button/button-icon.vue.d.ts +3 -3
- package/dist/components/button/button-link.vue.d.ts +4 -4
- package/dist/components/button/button-loading.vue.d.ts +3 -3
- package/dist/components/button/button.vue.d.ts +4 -4
- package/dist/components/button/variants.d.ts +3 -3
- package/dist/components/card/card-collapsible-trigger.vue.d.ts +3 -3
- package/dist/components/card/card.js +1 -1
- package/dist/components/card/card.vue.d.ts +3 -3
- package/dist/components/carousel/carousel-content.js +1 -0
- package/dist/components/carousel/carousel-content.vue.d.ts +18 -0
- package/dist/components/carousel/carousel-item.js +1 -0
- package/dist/components/carousel/carousel-item.vue.d.ts +18 -0
- package/dist/components/carousel/carousel-next.js +1 -0
- package/dist/components/carousel/carousel-next.vue.d.ts +22 -0
- package/dist/components/carousel/carousel-previous.js +1 -0
- package/dist/components/carousel/carousel-previous.vue.d.ts +22 -0
- package/dist/components/carousel/carousel.js +1 -0
- package/dist/components/carousel/carousel.vue.d.ts +15 -0
- package/dist/components/carousel/index.d.ts +8 -0
- package/dist/components/carousel/index.js +1 -0
- package/dist/components/carousel/types.d.ts +10 -0
- package/dist/components/carousel/variants.js +1 -0
- package/dist/components/checkbox/checkbox-card-group.vue.d.ts +3 -3
- package/dist/components/checkbox/checkbox-card.vue.d.ts +8 -8
- package/dist/components/checkbox/checkbox-group.vue.d.ts +3 -3
- package/dist/components/checkbox/checkbox.vue.d.ts +12 -12
- package/dist/components/checkbox/variants.d.ts +3 -3
- package/dist/components/collapsible/collapsible.vue.d.ts +4 -4
- package/dist/components/color-area/color-area.js +1 -0
- package/dist/components/color-area/color-area.vue.d.ts +19 -0
- package/dist/components/color-area/index.d.ts +4 -0
- package/dist/components/color-area/index.js +1 -0
- package/dist/components/color-area/types.d.ts +14 -0
- package/dist/components/color-area/variants.js +1 -0
- package/dist/components/color-field/color-field.js +1 -0
- package/dist/components/color-field/color-field.vue.d.ts +15 -0
- package/dist/components/color-field/index.d.ts +4 -0
- package/dist/components/color-field/index.js +1 -0
- package/dist/components/color-field/types.d.ts +13 -0
- package/dist/components/color-field/variants.js +1 -0
- package/dist/components/color-picker/color-picker.js +1 -0
- package/dist/components/color-picker/color-picker.vue.d.ts +55 -0
- package/dist/components/color-picker/index.d.ts +2 -0
- package/dist/components/color-picker/index.js +1 -0
- package/dist/components/color-picker/shared.js +1 -0
- package/dist/components/color-picker/types.d.ts +47 -0
- package/dist/components/color-picker/variants.js +1 -0
- package/dist/components/color-slider/color-slider.js +1 -0
- package/dist/components/color-slider/color-slider.vue.d.ts +23 -0
- package/dist/components/color-slider/index.d.ts +4 -0
- package/dist/components/color-slider/index.js +1 -0
- package/dist/components/color-slider/types.d.ts +16 -0
- package/dist/components/color-swatch/color-swatch.js +1 -0
- package/dist/components/color-swatch/color-swatch.vue.d.ts +18 -0
- package/dist/components/color-swatch/index.d.ts +5 -0
- package/dist/components/color-swatch/index.js +1 -0
- package/dist/components/color-swatch/types.d.ts +16 -0
- package/dist/components/color-swatch/variants.d.ts +108 -0
- package/dist/components/color-swatch/variants.js +1 -0
- package/dist/components/color-swatch-picker/color-swatch-picker.js +1 -0
- package/dist/components/color-swatch-picker/color-swatch-picker.vue.d.ts +39 -0
- package/dist/components/color-swatch-picker/index.d.ts +5 -0
- package/dist/components/color-swatch-picker/index.js +1 -0
- package/dist/components/color-swatch-picker/types.d.ts +20 -0
- package/dist/components/color-swatch-picker/variants.d.ts +153 -0
- package/dist/components/color-swatch-picker/variants.js +1 -0
- package/dist/components/combobox/combobox-group-option.js +1 -0
- package/dist/components/combobox/combobox-option.js +1 -0
- package/dist/components/combobox/combobox-single-option.js +1 -0
- package/dist/components/combobox/combobox.js +1 -0
- package/dist/components/combobox/combobox.vue.d.ts +76 -0
- package/dist/components/combobox/index.d.ts +4 -0
- package/dist/components/combobox/index.js +1 -0
- package/dist/components/combobox/shared.js +1 -0
- package/dist/components/combobox/types.d.ts +68 -0
- package/dist/components/combobox/variants.js +1 -0
- package/dist/components/command/command.vue.d.ts +8 -8
- package/dist/components/config-provider/config-provider.js +1 -1
- package/dist/components/config-provider/config-provider.vue.d.ts +7 -7
- package/dist/components/config-provider/context.js +1 -1
- package/dist/components/config-provider/types.d.ts +14 -2
- package/dist/components/context-menu/context-menu-checkbox.js +1 -1
- package/dist/components/context-menu/context-menu-checkbox.vue.d.ts +14 -21
- package/dist/components/context-menu/context-menu-radio.js +1 -1
- package/dist/components/context-menu/context-menu-radio.vue.d.ts +14 -21
- package/dist/components/context-menu/context-menu-wrapper.js +1 -1
- package/dist/components/context-menu/context-menu-wrapper.vue.d.ts +16 -16
- package/dist/components/context-menu/context-menu.js +1 -1
- package/dist/components/context-menu/context-menu.vue.d.ts +13 -21
- package/dist/components/context-menu/index.d.ts +5 -7
- package/dist/components/context-menu/types.d.ts +14 -42
- package/dist/components/dialog/dialog-close.vue.d.ts +2 -2
- package/dist/components/dialog/dialog-pure.vue.d.ts +12 -12
- package/dist/components/dialog/dialog.vue.d.ts +12 -12
- package/dist/components/drawer/drawer-close.vue.d.ts +2 -2
- package/dist/components/drawer/drawer.vue.d.ts +12 -12
- package/dist/components/dropdown-menu/dropdown-menu-checkbox.js +1 -1
- package/dist/components/dropdown-menu/dropdown-menu-checkbox.vue.d.ts +14 -21
- package/dist/components/dropdown-menu/dropdown-menu-radio.js +1 -1
- package/dist/components/dropdown-menu/dropdown-menu-radio.vue.d.ts +14 -21
- package/dist/components/dropdown-menu/dropdown-menu-wrapper.js +1 -1
- package/dist/components/dropdown-menu/dropdown-menu-wrapper.vue.d.ts +16 -16
- package/dist/components/dropdown-menu/dropdown-menu.js +1 -1
- package/dist/components/dropdown-menu/dropdown-menu.vue.d.ts +13 -21
- package/dist/components/dropdown-menu/index.d.ts +2 -4
- package/dist/components/dropdown-menu/index.js +1 -1
- package/dist/components/dropdown-menu/types.d.ts +14 -38
- package/dist/components/editable/editable.js +1 -0
- package/dist/components/editable/editable.vue.d.ts +85 -0
- package/dist/components/editable/index.d.ts +4 -0
- package/dist/components/editable/index.js +1 -0
- package/dist/components/editable/types.d.ts +20 -0
- package/dist/components/editable/variants.js +1 -0
- package/dist/components/empty/empty.js +1 -0
- package/dist/components/empty/empty.vue.d.ts +21 -0
- package/dist/components/empty/index.d.ts +5 -0
- package/dist/components/empty/index.js +1 -0
- package/dist/components/empty/types.d.ts +20 -0
- package/dist/components/empty/variants.d.ts +57 -0
- package/dist/components/empty/variants.js +1 -0
- package/dist/components/form/form-field-base.vue.d.ts +3 -3
- package/dist/components/form/form.vue.d.ts +2 -2
- package/dist/components/form/use-form.d.ts +22 -22
- package/dist/components/form/variants.js +1 -1
- package/dist/components/hover-card/hover-card.js +1 -0
- package/dist/components/hover-card/hover-card.vue.d.ts +35 -0
- package/dist/components/hover-card/index.d.ts +4 -0
- package/dist/components/hover-card/index.js +1 -0
- package/dist/components/hover-card/types.d.ts +22 -0
- package/dist/components/hover-card/variants.js +1 -0
- package/dist/components/icon/icon.vue.d.ts +2 -2
- package/dist/components/icon/types.d.ts +3 -4
- package/dist/components/input/input.vue.d.ts +4 -4
- package/dist/components/input-number/input-number.vue.d.ts +4 -4
- package/dist/components/kbd/kbd.vue.d.ts +3 -3
- package/dist/components/kbd/variants.d.ts +3 -3
- package/dist/components/label/label.vue.d.ts +2 -2
- package/dist/components/layout/layout-trigger.vue.d.ts +2 -2
- package/dist/components/layout/layout.vue.d.ts +4 -4
- package/dist/components/link/link.vue.d.ts +4 -4
- package/dist/components/list/list-item.vue.d.ts +2 -2
- package/dist/components/list/list.vue.d.ts +2 -2
- package/dist/components/menu/context.js +1 -1
- package/dist/components/menu/index.d.ts +2 -7
- package/dist/components/menu/index.js +1 -1
- package/dist/components/menu/types.d.ts +9 -86
- package/dist/components/menu/variants.js +1 -1
- package/dist/components/menubar/index.d.ts +2 -0
- package/dist/components/menubar/index.js +1 -0
- package/dist/components/menubar/menubar.js +1 -0
- package/dist/components/menubar/menubar.vue.d.ts +32 -0
- package/dist/components/menubar/types.d.ts +17 -0
- package/dist/components/menubar/variants.js +1 -0
- package/dist/components/navigation-menu/navigation-menu.vue.d.ts +13 -13
- package/dist/components/page-tabs/page-tabs.vue.d.ts +4 -4
- package/dist/components/page-tabs/types.d.ts +1 -1
- package/dist/components/page-tabs/variants.d.ts +3 -3
- package/dist/components/pagination/pagination.js +1 -1
- package/dist/components/pagination/pagination.vue.d.ts +4 -4
- package/dist/components/pagination/variants.d.ts +3 -3
- package/dist/components/password/password.vue.d.ts +4 -4
- package/dist/components/popconfirm/popconfirm-cancel.js +1 -1
- package/dist/components/popconfirm/popconfirm-cancel.vue.d.ts +4 -4
- package/dist/components/popconfirm/popconfirm-confirm.js +1 -1
- package/dist/components/popconfirm/popconfirm-confirm.vue.d.ts +4 -4
- package/dist/components/popconfirm/popconfirm.vue.d.ts +14 -14
- package/dist/components/popover/popover.js +1 -1
- package/dist/components/popover/popover.vue.d.ts +11 -11
- package/dist/components/progress/context.d.ts +5 -0
- package/dist/components/progress/context.js +1 -0
- package/dist/components/progress/index.d.ts +8 -0
- package/dist/components/progress/index.js +1 -0
- package/dist/components/progress/loading-bar.js +1 -0
- package/dist/components/progress/loading-bar.vue.d.ts +25 -0
- package/dist/components/progress/progress-circle.js +1 -0
- package/dist/components/progress/progress-circle.vue.d.ts +29 -0
- package/dist/components/progress/progress.js +1 -0
- package/dist/components/progress/progress.vue.d.ts +30 -0
- package/dist/components/progress/shared.d.ts +7 -0
- package/dist/components/progress/shared.js +1 -0
- package/dist/components/progress/types.d.ts +43 -0
- package/dist/components/progress/variants.js +1 -0
- package/dist/components/radio-group/radio-card-group.vue.d.ts +3 -3
- package/dist/components/radio-group/radio-card.vue.d.ts +2 -2
- package/dist/components/radio-group/radio-group.vue.d.ts +3 -3
- package/dist/components/radio-group/radio.vue.d.ts +2 -2
- package/dist/components/radio-group/variants.d.ts +3 -3
- package/dist/components/scroll-area/index.d.ts +4 -0
- package/dist/components/scroll-area/index.js +1 -0
- package/dist/components/scroll-area/scroll-area.js +1 -0
- package/dist/components/scroll-area/scroll-area.vue.d.ts +18 -0
- package/dist/components/scroll-area/types.d.ts +15 -0
- package/dist/components/scroll-area/variants.js +1 -0
- package/dist/components/segment/segment.vue.d.ts +3 -3
- package/dist/components/select/select.vue.d.ts +8 -8
- package/dist/components/separator/separator.vue.d.ts +5 -5
- package/dist/components/separator/variants.d.ts +3 -3
- package/dist/components/skeleton/index.d.ts +3 -0
- package/dist/components/skeleton/index.js +1 -0
- package/dist/components/skeleton/skeleton.js +1 -0
- package/dist/components/skeleton/skeleton.vue.d.ts +20 -0
- package/dist/components/skeleton/types.d.ts +16 -0
- package/dist/components/skeleton/variants.d.ts +60 -0
- package/dist/components/skeleton/variants.js +1 -0
- package/dist/components/slider/index.d.ts +4 -0
- package/dist/components/slider/index.js +1 -0
- package/dist/components/slider/slider.js +1 -0
- package/dist/components/slider/slider.vue.d.ts +28 -0
- package/dist/components/slider/types.d.ts +16 -0
- package/dist/components/slider/variants.js +1 -0
- package/dist/components/spinner/index.d.ts +2 -0
- package/dist/components/spinner/index.js +1 -0
- package/dist/components/spinner/spinner.js +1 -0
- package/dist/components/spinner/spinner.vue.d.ts +10 -0
- package/dist/components/spinner/types.d.ts +19 -0
- package/dist/components/spinner/variants.js +1 -0
- package/dist/components/splitter/index.d.ts +5 -0
- package/dist/components/splitter/index.js +1 -0
- package/dist/components/splitter/splitter-group.js +1 -0
- package/dist/components/splitter/splitter-group.vue.d.ts +22 -0
- package/dist/components/splitter/splitter-panel.js +1 -0
- package/dist/components/splitter/splitter-panel.vue.d.ts +32 -0
- package/dist/components/splitter/splitter-resize-handle.js +1 -0
- package/dist/components/splitter/splitter-resize-handle.vue.d.ts +415 -0
- package/dist/components/splitter/types.d.ts +12 -0
- package/dist/components/splitter/variants.js +1 -0
- package/dist/components/stepper/index.d.ts +4 -0
- package/dist/components/stepper/index.js +1 -0
- package/dist/components/stepper/stepper.js +1 -0
- package/dist/components/stepper/stepper.vue.d.ts +121 -0
- package/dist/components/stepper/types.d.ts +26 -0
- package/dist/components/stepper/variants.js +1 -0
- package/dist/components/switch/switch.vue.d.ts +22 -22
- package/dist/components/switch/variants.d.ts +3 -3
- package/dist/components/table/hooks.d.ts +19 -19
- package/dist/components/table/hooks.js +1 -1
- package/dist/components/table/index.d.ts +1 -1
- package/dist/components/table/table-filter-popover.js +1 -0
- package/dist/components/table/table-radio.js +1 -1
- package/dist/components/table/table.js +1 -1
- package/dist/components/table/table.vue.d.ts +10 -6
- package/dist/components/table/types.d.ts +25 -83
- package/dist/components/table/variants.js +1 -1
- package/dist/components/tabs/tabs.vue.d.ts +3 -3
- package/dist/components/tabs/variants.d.ts +3 -3
- package/dist/components/tag/tag.vue.d.ts +4 -4
- package/dist/components/tag/variants.d.ts +3 -3
- package/dist/components/tags-input/index.d.ts +5 -0
- package/dist/components/tags-input/index.js +1 -0
- package/dist/components/tags-input/tags-input-item-delete.js +1 -0
- package/dist/components/tags-input/tags-input-item-delete.vue.d.ts +18 -0
- package/dist/components/tags-input/tags-input.js +1 -0
- package/dist/components/tags-input/tags-input.vue.d.ts +29 -0
- package/dist/components/tags-input/types.d.ts +12 -0
- package/dist/components/tags-input/variants.js +1 -0
- package/dist/components/textarea/textarea.vue.d.ts +4 -4
- package/dist/components/textarea/variants.d.ts +3 -3
- package/dist/components/toast/index.d.ts +4 -5
- package/dist/components/toast/index.js +1 -1
- package/dist/components/toast/styles.js +274 -0
- package/dist/components/toast/toaster.js +1 -0
- package/dist/components/toast/toaster.vue.d.ts +22 -0
- package/dist/components/toast/types.d.ts +5 -55
- package/dist/components/toast/variants.js +1 -1
- package/dist/components/toggle/index.d.ts +3 -0
- package/dist/components/toggle/index.js +1 -0
- package/dist/components/toggle/toggle.js +1 -0
- package/dist/components/toggle/toggle.vue.d.ts +30 -0
- package/dist/components/toggle/types.d.ts +14 -0
- package/dist/components/toggle/variants.d.ts +100 -0
- package/dist/components/toggle/variants.js +1 -0
- package/dist/components/toggle-group/index.d.ts +6 -0
- package/dist/components/toggle-group/index.js +1 -0
- package/dist/components/toggle-group/toggle-group-item.js +1 -0
- package/dist/components/toggle-group/toggle-group-item.vue.d.ts +22 -0
- package/dist/components/toggle-group/toggle-group.js +1 -0
- package/dist/components/toggle-group/toggle-group.vue.d.ts +24 -0
- package/dist/components/toggle-group/types.d.ts +15 -0
- package/dist/components/toggle-group/variants.d.ts +216 -0
- package/dist/components/toggle-group/variants.js +1 -0
- package/dist/components/toolbar/index.d.ts +4 -0
- package/dist/components/toolbar/index.js +1 -0
- package/dist/components/toolbar/toolbar.js +1 -0
- package/dist/components/toolbar/toolbar.vue.d.ts +18 -0
- package/dist/components/toolbar/types.d.ts +9 -0
- package/dist/components/toolbar/variants.js +1 -0
- package/dist/components/tooltip/tooltip.vue.d.ts +7 -7
- package/dist/components/tree/tree-virtualizer.vue.d.ts +7 -7
- package/dist/components/tree/tree.vue.d.ts +5 -5
- package/dist/components/tree-menu/tree-menu-option-slot.js +1 -1
- package/dist/components/tree-menu/tree-menu-styled-item.vue.d.ts +2 -2
- package/dist/components/tree-menu/tree-menu.vue.d.ts +3 -3
- package/dist/components/tree-menu/types.d.ts +1 -1
- package/dist/components/tree-menu/variants.js +1 -1
- package/dist/components/virtualizer/virtualizer.vue.d.ts +5 -5
- package/dist/constants/components.d.ts +27 -0
- package/dist/constants/components.js +1 -1
- package/dist/index.d.ts +179 -94
- package/dist/index.js +1 -1
- package/dist/nuxt/index.d.ts +2 -2
- package/dist/resolver/index.d.ts +2 -2
- package/dist/styles.css +600 -111
- package/dist/theme/config.js +1 -1
- package/package.json +21 -18
- package/dist/components/menu/menu-checkbox-options.js +0 -1
- package/dist/components/menu/menu-checkbox-options.vue.d.ts +0 -28
- package/dist/components/menu/menu-item-slot.js +0 -1
- package/dist/components/menu/menu-option.js +0 -1
- package/dist/components/menu/menu-option.vue.d.ts +0 -48
- package/dist/components/menu/menu-options.js +0 -1
- package/dist/components/menu/menu-options.vue.d.ts +0 -48
- package/dist/components/menu/menu-radio-options.js +0 -1
- package/dist/components/menu/menu-radio-options.vue.d.ts +0 -28
- package/dist/components/menu/shared.js +0 -1
- package/dist/components/table/shared.js +0 -1
- package/dist/components/toast/context.d.ts +0 -5
- package/dist/components/toast/context.js +0 -1
- package/dist/components/toast/shared.js +0 -1
- package/dist/components/toast/toast-provider.js +0 -1
- package/dist/components/toast/toast.js +0 -1
- package/dist/components/toast/toast.vue.d.ts +0 -21
- package/dist/components/toast/variants.d.ts +0 -60
|
@@ -1,36 +1,28 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import
|
|
3
|
-
import * as
|
|
4
|
-
import * as _soybeanjs_headless0 from "@soybeanjs/headless";
|
|
1
|
+
import { DropdownMenuProps, DropdownMenuSlots } from "./types.js";
|
|
2
|
+
import * as _$vue from "vue";
|
|
3
|
+
import * as _$_soybeanjs_headless0 from "@soybeanjs/headless";
|
|
5
4
|
import { DefinedValue } from "@soybeanjs/headless";
|
|
6
5
|
|
|
7
6
|
//#region src/components/dropdown-menu/dropdown-menu.vue.d.ts
|
|
8
|
-
declare const __VLS_export: <T extends DefinedValue = DefinedValue
|
|
9
|
-
props: vue.PublicProps & __VLS_PrettifyLocal<DropdownMenuProps<T
|
|
10
|
-
onSelect?: ((item:
|
|
7
|
+
declare const __VLS_export: <T extends DefinedValue = DefinedValue>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
|
|
8
|
+
props: _$vue.PublicProps & __VLS_PrettifyLocal<DropdownMenuProps<T> & {
|
|
9
|
+
onSelect?: ((item: _$_soybeanjs_headless0.MenuOptionData<T>, event: Event) => any) | undefined;
|
|
11
10
|
"onUpdate:open"?: ((value: boolean) => any) | undefined;
|
|
12
|
-
onEntryFocus?: ((event: Event) => any) | undefined;
|
|
13
11
|
onEscapeKeyDown?: ((event: KeyboardEvent) => any) | undefined;
|
|
14
|
-
onPointerDownOutside?: ((event: _soybeanjs_headless0.PointerDownOutsideEvent) => any) | undefined;
|
|
15
|
-
onFocusOutside?: ((event: _soybeanjs_headless0.FocusOutsideEvent) => any) | undefined;
|
|
16
|
-
onInteractOutside?: ((event: _soybeanjs_headless0.PointerDownOutsideEvent | _soybeanjs_headless0.FocusOutsideEvent) => any) | undefined;
|
|
12
|
+
onPointerDownOutside?: ((event: _$_soybeanjs_headless0.PointerDownOutsideEvent) => any) | undefined;
|
|
13
|
+
onFocusOutside?: ((event: _$_soybeanjs_headless0.FocusOutsideEvent) => any) | undefined;
|
|
14
|
+
onInteractOutside?: ((event: _$_soybeanjs_headless0.PointerDownOutsideEvent | _$_soybeanjs_headless0.FocusOutsideEvent) => any) | undefined;
|
|
17
15
|
onOpenAutoFocus?: ((event: Event) => any) | undefined;
|
|
18
16
|
onCloseAutoFocus?: ((event: Event) => any) | undefined;
|
|
17
|
+
onEntryFocus?: ((event: Event) => any) | undefined;
|
|
19
18
|
}> & (typeof globalThis extends {
|
|
20
19
|
__VLS_PROPS_FALLBACK: infer P;
|
|
21
20
|
} ? P : {});
|
|
22
21
|
expose: (exposed: {}) => void;
|
|
23
22
|
attrs: any;
|
|
24
|
-
slots:
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
'item-leading': (props: MenuOptionData<T>) => any;
|
|
28
|
-
'item-trailing': (props: MenuOptionData<T>) => any;
|
|
29
|
-
'item-trigger': (props: MenuOptionData<T>) => any;
|
|
30
|
-
'item-trigger-icon': (props: MenuOptionData<T>) => any;
|
|
31
|
-
};
|
|
32
|
-
emit: ((evt: "select", item: S, event: Event) => void) & ((evt: "update:open", value: boolean) => void) & ((evt: "entryFocus", event: Event) => void) & ((evt: "escapeKeyDown", event: KeyboardEvent) => void) & ((evt: "pointerDownOutside", event: _soybeanjs_headless0.PointerDownOutsideEvent) => void) & ((evt: "focusOutside", event: _soybeanjs_headless0.FocusOutsideEvent) => void) & ((evt: "interactOutside", event: _soybeanjs_headless0.PointerDownOutsideEvent | _soybeanjs_headless0.FocusOutsideEvent) => void) & ((evt: "openAutoFocus", event: Event) => void) & ((evt: "closeAutoFocus", event: Event) => void);
|
|
33
|
-
}>) => vue.VNode & {
|
|
23
|
+
slots: DropdownMenuSlots<T>;
|
|
24
|
+
emit: ((evt: "select", item: _$_soybeanjs_headless0.MenuOptionData<T>, event: Event) => void) & ((evt: "update:open", value: boolean) => void) & ((evt: "escapeKeyDown", event: KeyboardEvent) => void) & ((evt: "pointerDownOutside", event: _$_soybeanjs_headless0.PointerDownOutsideEvent) => void) & ((evt: "focusOutside", event: _$_soybeanjs_headless0.FocusOutsideEvent) => void) & ((evt: "interactOutside", event: _$_soybeanjs_headless0.PointerDownOutsideEvent | _$_soybeanjs_headless0.FocusOutsideEvent) => void) & ((evt: "openAutoFocus", event: Event) => void) & ((evt: "closeAutoFocus", event: Event) => void) & ((evt: "entryFocus", event: Event) => void);
|
|
25
|
+
}>) => _$vue.VNode & {
|
|
34
26
|
__ctx?: Awaited<typeof __VLS_setup>;
|
|
35
27
|
};
|
|
36
28
|
declare const _default: typeof __VLS_export;
|
|
@@ -1,7 +1,5 @@
|
|
|
1
|
-
import { DropdownMenuCheckboxEmits, DropdownMenuCheckboxProps, DropdownMenuEmits, DropdownMenuProps, DropdownMenuRadioEmits, DropdownMenuRadioProps, DropdownMenuWrapperEmits, DropdownMenuWrapperProps } from "./types.js";
|
|
1
|
+
import { DropdownMenuCheckboxEmits, DropdownMenuCheckboxProps, DropdownMenuCheckboxSlots, DropdownMenuEmits, DropdownMenuProps, DropdownMenuRadioEmits, DropdownMenuRadioProps, DropdownMenuRadioSlots, DropdownMenuSlots, DropdownMenuWrapperEmits, DropdownMenuWrapperProps } from "./types.js";
|
|
2
2
|
import { _default } from "./dropdown-menu.vue.js";
|
|
3
3
|
import { _default as _default$1 } from "./dropdown-menu-checkbox.vue.js";
|
|
4
4
|
import { _default as _default$2 } from "./dropdown-menu-radio.vue.js";
|
|
5
|
-
import { _default as _default$3 } from "./dropdown-menu-wrapper.vue.js";
|
|
6
|
-
import { DropdownMenuAnchorProps, DropdownMenuArrowProps, DropdownMenuCheckboxGroupEmits, DropdownMenuCheckboxGroupProps, DropdownMenuCheckboxItemEmits, DropdownMenuCheckboxItemProps, DropdownMenuContentEmits, DropdownMenuContentProps, DropdownMenuGroupLabelProps, DropdownMenuGroupProps, DropdownMenuItemEmits, DropdownMenuItemIndicatorProps, DropdownMenuItemProps, DropdownMenuPopupProps, DropdownMenuPortalProps, DropdownMenuRadioGroupEmits, DropdownMenuRadioGroupProps, DropdownMenuRadioItemEmits, DropdownMenuRadioItemProps, DropdownMenuRootEmits, DropdownMenuRootProps, DropdownMenuSeparatorProps, DropdownMenuSubContentEmits, DropdownMenuSubContentProps, DropdownMenuSubEmits, DropdownMenuSubProps, DropdownMenuSubTriggerProps, DropdownMenuTriggerProps, DropdownMenuTriggerType } from "@soybeanjs/headless/dropdown-menu";
|
|
7
|
-
export { type DropdownMenuAnchorProps, type DropdownMenuArrowProps, type DropdownMenuCheckboxGroupEmits, type DropdownMenuCheckboxGroupProps, type DropdownMenuCheckboxItemEmits, type DropdownMenuCheckboxItemProps, type DropdownMenuContentEmits, type DropdownMenuContentProps, type DropdownMenuGroupLabelProps, type DropdownMenuGroupProps, type DropdownMenuItemEmits, type DropdownMenuItemIndicatorProps, type DropdownMenuItemProps, type DropdownMenuPopupProps, type DropdownMenuPortalProps, type DropdownMenuRadioGroupEmits, type DropdownMenuRadioGroupProps, type DropdownMenuRadioItemEmits, type DropdownMenuRadioItemProps, type DropdownMenuRootEmits, type DropdownMenuRootProps, type DropdownMenuSeparatorProps, type DropdownMenuSubContentEmits, type DropdownMenuSubContentProps, type DropdownMenuSubEmits, type DropdownMenuSubProps, type DropdownMenuSubTriggerProps, type DropdownMenuTriggerProps, type DropdownMenuTriggerType };
|
|
5
|
+
import { _default as _default$3 } from "./dropdown-menu-wrapper.vue.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import"./dropdown-menu
|
|
1
|
+
import"./dropdown-menu.js";import"./dropdown-menu-checkbox.js";import"./dropdown-menu-radio.js";import"./dropdown-menu-wrapper.js";
|
|
@@ -1,41 +1,17 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import { AcceptableBooleanValue, ClassValue, DefinedValue, DropdownMenuArrowProps, DropdownMenuContentEmits, DropdownMenuContentProps, DropdownMenuPopupProps, DropdownMenuPortalProps, DropdownMenuRootEmits, DropdownMenuRootProps, DropdownMenuTriggerProps, Placement } from "@soybeanjs/headless";
|
|
1
|
+
import { MenuUiBaseProps } from "../menu/types.js";
|
|
2
|
+
import { AcceptableBooleanValue, DefinedValue, DropdownMenuCheckboxCompactEmits, DropdownMenuCheckboxCompactProps, DropdownMenuCheckboxCompactSlots, DropdownMenuCompactEmits, DropdownMenuCompactProps, DropdownMenuCompactSlots, DropdownMenuRadioCompactEmits, DropdownMenuRadioCompactProps, DropdownMenuRadioCompactSlots, DropdownMenuWrapperCompactEmits, DropdownMenuWrapperCompactProps } from "@soybeanjs/headless";
|
|
4
3
|
|
|
5
4
|
//#region src/components/dropdown-menu/types.d.ts
|
|
6
|
-
interface DropdownMenuWrapperProps extends
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
triggerProps?: DropdownMenuTriggerProps;
|
|
18
|
-
portalProps?: DropdownMenuPortalProps;
|
|
19
|
-
contentProps?: DropdownMenuContentProps;
|
|
20
|
-
popupProps?: DropdownMenuPopupProps;
|
|
21
|
-
arrowProps?: DropdownMenuArrowProps;
|
|
22
|
-
}
|
|
23
|
-
type DropdownMenuWrapperEmits = DropdownMenuRootEmits & DropdownMenuContentEmits;
|
|
24
|
-
interface DropdownMenuProps<T extends DefinedValue = DefinedValue, S extends MenuOptionData<T> = MenuOptionData<T>> extends Omit<DropdownMenuWrapperProps, 'indicatorPosition'>, MenuOptionsProps<T, S> {}
|
|
25
|
-
type DropdownMenuEmits<T extends MenuOptionData = MenuOptionData> = DropdownMenuWrapperEmits & MenuOptionsEmits<T>;
|
|
26
|
-
interface DropdownMenuCheckboxProps<T extends DefinedValue = DefinedValue, S extends MenuCheckboxOptionData<T> = MenuCheckboxOptionData<T>> extends DropdownMenuWrapperProps, MenuCheckboxOptionsProps<T, S> {
|
|
27
|
-
/**
|
|
28
|
-
* class of menu popup
|
|
29
|
-
*/
|
|
30
|
-
class?: ClassValue;
|
|
31
|
-
}
|
|
32
|
-
type DropdownMenuCheckboxEmits<T extends DefinedValue = DefinedValue, S extends MenuCheckboxOptionData<T> = MenuCheckboxOptionData<T>> = DropdownMenuWrapperEmits & MenuCheckboxOptionsEmits<T, S>;
|
|
33
|
-
interface DropdownMenuRadioProps<T extends AcceptableBooleanValue = AcceptableBooleanValue, S extends MenuRadioOptionData<T> = MenuRadioOptionData<T>> extends DropdownMenuWrapperProps, MenuRadioOptionsProps<T, S> {
|
|
34
|
-
/**
|
|
35
|
-
* class of menu popup
|
|
36
|
-
*/
|
|
37
|
-
class?: ClassValue;
|
|
38
|
-
}
|
|
39
|
-
type DropdownMenuRadioEmits<T extends AcceptableBooleanValue = AcceptableBooleanValue, S extends MenuRadioOptionData<T> = MenuRadioOptionData<T>> = DropdownMenuWrapperEmits & MenuRadioOptionsEmits<T, S>;
|
|
5
|
+
interface DropdownMenuWrapperProps extends MenuUiBaseProps, DropdownMenuWrapperCompactProps {}
|
|
6
|
+
type DropdownMenuWrapperEmits = DropdownMenuWrapperCompactEmits;
|
|
7
|
+
type DropdownMenuProps<T extends DefinedValue = DefinedValue> = Omit<MenuUiBaseProps, 'indicatorPosition'> & DropdownMenuCompactProps<T>;
|
|
8
|
+
type DropdownMenuEmits<T extends DefinedValue = DefinedValue> = DropdownMenuCompactEmits<T>;
|
|
9
|
+
type DropdownMenuSlots<T extends DefinedValue = DefinedValue> = DropdownMenuCompactSlots<T>;
|
|
10
|
+
type DropdownMenuCheckboxProps<T extends DefinedValue = DefinedValue> = MenuUiBaseProps & DropdownMenuCheckboxCompactProps<T>;
|
|
11
|
+
type DropdownMenuCheckboxEmits<T extends DefinedValue = DefinedValue> = DropdownMenuCheckboxCompactEmits<T>;
|
|
12
|
+
type DropdownMenuCheckboxSlots<T extends DefinedValue = DefinedValue> = DropdownMenuCheckboxCompactSlots<T>;
|
|
13
|
+
type DropdownMenuRadioProps<T extends AcceptableBooleanValue = AcceptableBooleanValue> = MenuUiBaseProps & DropdownMenuRadioCompactProps<T>;
|
|
14
|
+
type DropdownMenuRadioEmits<T extends AcceptableBooleanValue = AcceptableBooleanValue> = DropdownMenuRadioCompactEmits<T>;
|
|
15
|
+
type DropdownMenuRadioSlots<T extends AcceptableBooleanValue = AcceptableBooleanValue> = DropdownMenuRadioCompactSlots<T>;
|
|
40
16
|
//#endregion
|
|
41
|
-
export { DropdownMenuCheckboxEmits, DropdownMenuCheckboxProps, DropdownMenuEmits, DropdownMenuProps, DropdownMenuRadioEmits, DropdownMenuRadioProps, DropdownMenuWrapperEmits, DropdownMenuWrapperProps };
|
|
17
|
+
export { DropdownMenuCheckboxEmits, DropdownMenuCheckboxProps, DropdownMenuCheckboxSlots, DropdownMenuEmits, DropdownMenuProps, DropdownMenuRadioEmits, DropdownMenuRadioProps, DropdownMenuRadioSlots, DropdownMenuSlots, DropdownMenuWrapperEmits, DropdownMenuWrapperProps };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{mergeSlotVariants as e}from"../../theme/shared.js";import"../../theme/index.js";import t from"../icon/icon.js";import{editableVariants as n}from"./variants.js";import{computed as r,createBlock as i,createElementVNode as a,createVNode as o,defineComponent as s,guardReactiveProps as c,mergeProps as l,normalizeClass as u,normalizeProps as d,openBlock as f,renderSlot as p,toHandlers as m,unref as h,withCtx as g}from"vue";import{useForwardListeners as _,useOmitProps as v}from"@soybeanjs/headless/composables";import{EditableArea as y,EditableCancelTrigger as b,EditableEditTrigger as x,EditableInput as S,EditablePreview as C,EditableRoot as w,EditableSubmitTrigger as T,provideEditableUi as E}from"@soybeanjs/headless";const D=s({name:`SEditable`,__name:`editable`,props:{class:{},size:{},ui:{},areaProps:{},previewProps:{},inputProps:{},editTriggerProps:{},submitTriggerProps:{},cancelTriggerProps:{},defaultValue:{},modelValue:{},placeholder:{},dir:{},disabled:{type:Boolean},readonly:{type:Boolean},activationMode:{},selectOnFocus:{type:Boolean},submitMode:{},startWithEditMode:{type:Boolean},maxLength:{},autoResize:{type:Boolean},id:{},asChild:{type:Boolean},as:{},name:{},required:{type:Boolean}},emits:[`update:modelValue`,`submit`,`update:state`],setup(s,{emit:D}){let O=s,k=D,A=v(O,[`class`,`size`,`ui`,`areaProps`,`previewProps`,`inputProps`,`editTriggerProps`,`submitTriggerProps`,`cancelTriggerProps`]),j=_(k),M=r(()=>e(n({size:O.size}),O.ui,{root:O.class}));return E(M),(e,n)=>(f(),i(h(w),l(h(A),m(h(j))),{default:g(n=>[p(e.$slots,`default`,d(c(n)),()=>[o(h(y),d(c(s.areaProps)),{default:g(()=>[p(e.$slots,`preview`,d(c(n)),()=>[o(h(C),d(c(s.previewProps)),null,16)]),p(e.$slots,`input`,d(c(n)),()=>[o(h(S),d(c(s.inputProps)),null,16)]),a(`div`,{class:u(M.value.controls)},[p(e.$slots,`edit-trigger`,d(c(n)),()=>[o(h(x),d(c(s.editTriggerProps)),{default:g(()=>[o(t,{icon:`lucide:pencil-line`,"aria-hidden":!0})]),_:1},16)]),p(e.$slots,`submit-trigger`,d(c(n)),()=>[o(h(T),d(c(s.submitTriggerProps)),{default:g(()=>[o(t,{icon:`lucide:check`,"aria-hidden":!0})]),_:1},16)]),p(e.$slots,`cancel-trigger`,d(c(n)),()=>[o(h(b),d(c(s.cancelTriggerProps)),{default:g(()=>[o(t,{icon:`lucide:x`,"aria-hidden":!0})]),_:1},16)])],2)]),_:2},1040)])]),_:3},16))}});export{D as default};
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
import { EditableProps } from "./types.js";
|
|
2
|
+
import * as _$vue from "vue";
|
|
3
|
+
import * as _$_soybeanjs_headless0 from "@soybeanjs/headless";
|
|
4
|
+
|
|
5
|
+
//#region src/components/editable/editable.vue.d.ts
|
|
6
|
+
declare var __VLS_8: {
|
|
7
|
+
modelValue: string | undefined;
|
|
8
|
+
inputValue: string;
|
|
9
|
+
isEditing: boolean;
|
|
10
|
+
isEmpty: boolean;
|
|
11
|
+
edit: () => void;
|
|
12
|
+
cancel: () => void;
|
|
13
|
+
submit: () => void;
|
|
14
|
+
}, __VLS_16: {
|
|
15
|
+
modelValue: string | undefined;
|
|
16
|
+
inputValue: string;
|
|
17
|
+
isEditing: boolean;
|
|
18
|
+
isEmpty: boolean;
|
|
19
|
+
edit: () => void;
|
|
20
|
+
cancel: () => void;
|
|
21
|
+
submit: () => void;
|
|
22
|
+
}, __VLS_23: {
|
|
23
|
+
modelValue: string | undefined;
|
|
24
|
+
inputValue: string;
|
|
25
|
+
isEditing: boolean;
|
|
26
|
+
isEmpty: boolean;
|
|
27
|
+
edit: () => void;
|
|
28
|
+
cancel: () => void;
|
|
29
|
+
submit: () => void;
|
|
30
|
+
}, __VLS_30: {
|
|
31
|
+
modelValue: string | undefined;
|
|
32
|
+
inputValue: string;
|
|
33
|
+
isEditing: boolean;
|
|
34
|
+
isEmpty: boolean;
|
|
35
|
+
edit: () => void;
|
|
36
|
+
cancel: () => void;
|
|
37
|
+
submit: () => void;
|
|
38
|
+
}, __VLS_43: {
|
|
39
|
+
modelValue: string | undefined;
|
|
40
|
+
inputValue: string;
|
|
41
|
+
isEditing: boolean;
|
|
42
|
+
isEmpty: boolean;
|
|
43
|
+
edit: () => void;
|
|
44
|
+
cancel: () => void;
|
|
45
|
+
submit: () => void;
|
|
46
|
+
}, __VLS_56: {
|
|
47
|
+
modelValue: string | undefined;
|
|
48
|
+
inputValue: string;
|
|
49
|
+
isEditing: boolean;
|
|
50
|
+
isEmpty: boolean;
|
|
51
|
+
edit: () => void;
|
|
52
|
+
cancel: () => void;
|
|
53
|
+
submit: () => void;
|
|
54
|
+
};
|
|
55
|
+
type __VLS_Slots = {} & {
|
|
56
|
+
default?: (props: typeof __VLS_8) => any;
|
|
57
|
+
} & {
|
|
58
|
+
preview?: (props: typeof __VLS_16) => any;
|
|
59
|
+
} & {
|
|
60
|
+
input?: (props: typeof __VLS_23) => any;
|
|
61
|
+
} & {
|
|
62
|
+
'edit-trigger'?: (props: typeof __VLS_30) => any;
|
|
63
|
+
} & {
|
|
64
|
+
'submit-trigger'?: (props: typeof __VLS_43) => any;
|
|
65
|
+
} & {
|
|
66
|
+
'cancel-trigger'?: (props: typeof __VLS_56) => any;
|
|
67
|
+
};
|
|
68
|
+
declare const __VLS_base: _$vue.DefineComponent<EditableProps, {}, {}, {}, {}, _$vue.ComponentOptionsMixin, _$vue.ComponentOptionsMixin, {
|
|
69
|
+
submit: (value: string) => any;
|
|
70
|
+
"update:modelValue": (value: string) => any;
|
|
71
|
+
"update:state": (state: _$_soybeanjs_headless0.EditableEventState) => any;
|
|
72
|
+
}, string, _$vue.PublicProps, Readonly<EditableProps> & Readonly<{
|
|
73
|
+
onSubmit?: ((value: string) => any) | undefined;
|
|
74
|
+
"onUpdate:modelValue"?: ((value: string) => any) | undefined;
|
|
75
|
+
"onUpdate:state"?: ((state: _$_soybeanjs_headless0.EditableEventState) => any) | undefined;
|
|
76
|
+
}>, {}, {}, {}, {}, string, _$vue.ComponentProvideOptions, false, {}, any>;
|
|
77
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
78
|
+
declare const _default: typeof __VLS_export;
|
|
79
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
80
|
+
new (): {
|
|
81
|
+
$slots: S;
|
|
82
|
+
};
|
|
83
|
+
};
|
|
84
|
+
//#endregion
|
|
85
|
+
export { _default };
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { EditableEmits, EditableExtendedUi, EditableExtraUiSlot, EditableProps } from "./types.js";
|
|
2
|
+
import { _default } from "./editable.vue.js";
|
|
3
|
+
import { EditableActivationMode, EditableAreaProps, EditableCancelTriggerProps, EditableEditTriggerProps, EditableEventState, EditableInputProps, EditablePlaceholder, EditablePreviewProps, EditableRootEmits, EditableRootProps, EditableSubmitMode, EditableSubmitTriggerProps, EditableUi, EditableUiSlot, EditableViewState } from "@soybeanjs/headless/editable";
|
|
4
|
+
export { type EditableActivationMode, type EditableAreaProps, type EditableCancelTriggerProps, type EditableEditTriggerProps, type EditableEventState, type EditableInputProps, type EditablePlaceholder, type EditablePreviewProps, type EditableRootEmits, type EditableRootProps, type EditableSubmitMode, type EditableSubmitTriggerProps, type EditableUi, type EditableUiSlot, type EditableViewState };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import"./editable.js";
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { ThemeSize } from "../../theme/types.js";
|
|
2
|
+
import { ClassValue, EditableAreaProps, EditableCancelTriggerProps, EditableEditTriggerProps, EditableInputProps, EditablePreviewProps, EditableRootEmits, EditableRootProps, EditableSubmitTriggerProps, EditableUiSlot, UiClass } from "@soybeanjs/headless";
|
|
3
|
+
|
|
4
|
+
//#region src/components/editable/types.d.ts
|
|
5
|
+
type EditableExtraUiSlot = 'controls';
|
|
6
|
+
type EditableExtendedUi = UiClass<EditableUiSlot | EditableExtraUiSlot>;
|
|
7
|
+
interface EditableProps extends EditableRootProps {
|
|
8
|
+
class?: ClassValue;
|
|
9
|
+
size?: ThemeSize;
|
|
10
|
+
ui?: Partial<EditableExtendedUi>;
|
|
11
|
+
areaProps?: EditableAreaProps;
|
|
12
|
+
previewProps?: EditablePreviewProps;
|
|
13
|
+
inputProps?: EditableInputProps;
|
|
14
|
+
editTriggerProps?: EditableEditTriggerProps;
|
|
15
|
+
submitTriggerProps?: EditableSubmitTriggerProps;
|
|
16
|
+
cancelTriggerProps?: EditableCancelTriggerProps;
|
|
17
|
+
}
|
|
18
|
+
type EditableEmits = EditableRootEmits;
|
|
19
|
+
//#endregion
|
|
20
|
+
export { EditableEmits, EditableExtendedUi, EditableExtraUiSlot, EditableProps };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{tv as e}from"tailwind-variants";const t=e({slots:{root:`w-full`,area:[`grid w-full grid-cols-[minmax(0,1fr)_auto] items-center gap-2 rounded-md border border-solid border-input bg-background transition-all-150`,`focus-within:outline-none focus-within:ring-3 focus-within:ring-offset-background focus-within:ring-primary/30`,`data-[disabled]:cursor-not-allowed data-[disabled]:opacity-50`],preview:[`col-start-1 row-start-1 min-w-0 truncate text-foreground outline-none`,`data-[placeholder-shown]:text-muted-foreground`],input:[`col-start-1 row-start-1 min-w-0 w-full border-0 bg-transparent outline-none`,`placeholder:text-muted-foreground`,`disabled:cursor-not-allowed`],controls:`col-start-2 row-start-1 flex items-center gap-1`,editTrigger:[`inline-flex items-center justify-center rounded-md text-muted-foreground transition-colors`,`hover:bg-accent hover:text-accent-foreground`,`focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-primary/30`],submitTrigger:[`inline-flex items-center justify-center rounded-md text-muted-foreground transition-colors`,`hover:bg-accent hover:text-success`,`focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-primary/30`],cancelTrigger:[`inline-flex items-center justify-center rounded-md text-muted-foreground transition-colors`,`hover:bg-accent hover:text-destructive`,`focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-primary/30`]},variants:{size:{xs:{area:`min-h-6 px-1.5 py-1 text-2xs`,preview:`text-2xs`,input:`text-2xs`,controls:`gap-0.5`,editTrigger:`size-5 [&>svg]:size-3`,submitTrigger:`size-5 [&>svg]:size-3`,cancelTrigger:`size-5 [&>svg]:size-3`},sm:{area:`min-h-7 px-2 py-1 text-xs`,preview:`text-xs`,input:`text-xs`,editTrigger:`size-6 [&>svg]:size-3.5`,submitTrigger:`size-6 [&>svg]:size-3.5`,cancelTrigger:`size-6 [&>svg]:size-3.5`},md:{area:`min-h-8 px-2.5 py-1.5 text-sm`,preview:`text-sm`,input:`text-sm`,editTrigger:`size-7 [&>svg]:size-4`,submitTrigger:`size-7 [&>svg]:size-4`,cancelTrigger:`size-7 [&>svg]:size-4`},lg:{area:`min-h-9 px-3 py-1.5 text-base`,preview:`text-base`,input:`text-base`,editTrigger:`size-8 [&>svg]:size-4`,submitTrigger:`size-8 [&>svg]:size-4`,cancelTrigger:`size-8 [&>svg]:size-4`},xl:{area:`min-h-10 px-3.5 py-2 text-lg`,preview:`text-lg`,input:`text-lg`,editTrigger:`size-9 [&>svg]:size-5`,submitTrigger:`size-9 [&>svg]:size-5`,cancelTrigger:`size-9 [&>svg]:size-5`},"2xl":{area:`min-h-12 px-4 py-2.5 text-xl`,preview:`text-xl`,input:`text-xl`,editTrigger:`size-10 [&>svg]:size-5`,submitTrigger:`size-10 [&>svg]:size-5`,cancelTrigger:`size-10 [&>svg]:size-5`}}},defaultVariants:{size:`md`}});export{t as editableVariants};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{mergeSlotVariants as e}from"../../theme/shared.js";import"../../theme/index.js";import t from"../icon/icon.js";import{emptyVariants as n}from"./variants.js";import{computed as r,createBlock as i,createCommentVNode as a,createTextVNode as o,createVNode as s,defineComponent as c,guardReactiveProps as l,mergeProps as u,normalizeProps as d,openBlock as f,renderSlot as p,toDisplayString as m,unref as h,useSlots as g,withCtx as _}from"vue";import{useOmitProps as v}from"@soybeanjs/headless/composables";import{EmptyContent as y,EmptyDescription as b,EmptyHeader as x,EmptyMedia as S,EmptyRoot as C,EmptyTitle as w,provideEmptyUi as T}from"@soybeanjs/headless";const E=c({name:`SEmpty`,__name:`empty`,props:{class:{},ui:{},title:{},description:{},icon:{},mediaVariant:{},headerProps:{},mediaProps:{},contentProps:{},titleProps:{},descriptionProps:{}},setup(c){let E=c,D=v(E,[`class`,`ui`,`title`,`description`,`icon`,`mediaVariant`,`headerProps`,`mediaProps`,`contentProps`,`titleProps`,`descriptionProps`]),O=g(),k=r(()=>!!(O.title||O.description||E.title||E.description)),A=r(()=>!!(O.media||E.icon));return T(r(()=>e(n({mediaVariant:E.mediaVariant}),E.ui,{root:E.class}))),(e,n)=>(f(),i(h(C),d(l(h(D))),{default:_(()=>[A.value?(f(),i(h(S),d(u({key:0},c.mediaProps)),{default:_(()=>[p(e.$slots,`media`,{},()=>[s(t,{icon:c.icon},null,8,[`icon`])])]),_:3},16)):a(`v-if`,!0),s(h(y),d(l(c.contentProps)),{default:_(()=>[k.value?(f(),i(h(x),d(u({key:0},c.headerProps)),{default:_(()=>[O.title||c.title?(f(),i(h(w),d(u({key:0},c.titleProps)),{default:_(()=>[p(e.$slots,`title`,{},()=>[o(m(c.title),1)])]),_:3},16)):a(`v-if`,!0),O.description||c.description?(f(),i(h(b),d(u({key:1},c.descriptionProps)),{default:_(()=>[p(e.$slots,`description`,{},()=>[o(m(c.description),1)])]),_:3},16)):a(`v-if`,!0)]),_:3},16)):a(`v-if`,!0),p(e.$slots,`default`)]),_:3},16)]),_:3},16))}});export{E as default};
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { EmptyProps } from "./types.js";
|
|
2
|
+
import * as _$vue from "vue";
|
|
3
|
+
|
|
4
|
+
//#region src/components/empty/empty.vue.d.ts
|
|
5
|
+
type Slots = {
|
|
6
|
+
default?: () => any;
|
|
7
|
+
media?: () => any;
|
|
8
|
+
title?: () => any;
|
|
9
|
+
description?: () => any;
|
|
10
|
+
};
|
|
11
|
+
type __VLS_Slots = Slots;
|
|
12
|
+
declare const __VLS_base: _$vue.DefineComponent<EmptyProps, {}, {}, {}, {}, _$vue.ComponentOptionsMixin, _$vue.ComponentOptionsMixin, {}, string, _$vue.PublicProps, Readonly<EmptyProps> & Readonly<{}>, {}, {}, {}, {}, string, _$vue.ComponentProvideOptions, false, {}, any>;
|
|
13
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
14
|
+
declare const _default: typeof __VLS_export;
|
|
15
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
16
|
+
new (): {
|
|
17
|
+
$slots: S;
|
|
18
|
+
};
|
|
19
|
+
};
|
|
20
|
+
//#endregion
|
|
21
|
+
export { _default };
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { EmptyMediaVariant } from "./variants.js";
|
|
2
|
+
import { EmptyProps } from "./types.js";
|
|
3
|
+
import { _default } from "./empty.vue.js";
|
|
4
|
+
import { EmptyContentProps, EmptyDescriptionProps, EmptyHeaderProps, EmptyMediaProps, EmptyRootProps, EmptyTitleProps } from "@soybeanjs/headless/empty";
|
|
5
|
+
export { type EmptyContentProps, type EmptyDescriptionProps, type EmptyHeaderProps, type EmptyMediaProps, type EmptyRootProps, type EmptyTitleProps };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import"./empty.js";
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { IconValue } from "../icon/types.js";
|
|
2
|
+
import { EmptyMediaVariant } from "./variants.js";
|
|
3
|
+
import { ClassValue, EmptyContentProps, EmptyDescriptionProps, EmptyHeaderProps, EmptyMediaProps, EmptyRootProps, EmptyTitleProps, EmptyUi } from "@soybeanjs/headless";
|
|
4
|
+
|
|
5
|
+
//#region src/components/empty/types.d.ts
|
|
6
|
+
interface EmptyProps extends EmptyRootProps {
|
|
7
|
+
class?: ClassValue;
|
|
8
|
+
ui?: Partial<EmptyUi>;
|
|
9
|
+
title?: string;
|
|
10
|
+
description?: string;
|
|
11
|
+
icon?: IconValue;
|
|
12
|
+
mediaVariant?: EmptyMediaVariant;
|
|
13
|
+
headerProps?: EmptyHeaderProps;
|
|
14
|
+
mediaProps?: EmptyMediaProps;
|
|
15
|
+
contentProps?: EmptyContentProps;
|
|
16
|
+
titleProps?: EmptyTitleProps;
|
|
17
|
+
descriptionProps?: EmptyDescriptionProps;
|
|
18
|
+
}
|
|
19
|
+
//#endregion
|
|
20
|
+
export { EmptyProps };
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import * as _$tailwind_variants0 from "tailwind-variants";
|
|
2
|
+
import { VariantProps } from "tailwind-variants";
|
|
3
|
+
|
|
4
|
+
//#region src/components/empty/variants.d.ts
|
|
5
|
+
declare const emptyVariants: _$tailwind_variants0.TVReturnType<{
|
|
6
|
+
mediaVariant: {
|
|
7
|
+
default: {
|
|
8
|
+
media: string;
|
|
9
|
+
};
|
|
10
|
+
icon: {
|
|
11
|
+
media: string;
|
|
12
|
+
};
|
|
13
|
+
};
|
|
14
|
+
}, {
|
|
15
|
+
root: string;
|
|
16
|
+
header: string;
|
|
17
|
+
media: string;
|
|
18
|
+
content: string;
|
|
19
|
+
title: string;
|
|
20
|
+
description: string;
|
|
21
|
+
}, undefined, {
|
|
22
|
+
mediaVariant: {
|
|
23
|
+
default: {
|
|
24
|
+
media: string;
|
|
25
|
+
};
|
|
26
|
+
icon: {
|
|
27
|
+
media: string;
|
|
28
|
+
};
|
|
29
|
+
};
|
|
30
|
+
}, {
|
|
31
|
+
root: string;
|
|
32
|
+
header: string;
|
|
33
|
+
media: string;
|
|
34
|
+
content: string;
|
|
35
|
+
title: string;
|
|
36
|
+
description: string;
|
|
37
|
+
}, _$tailwind_variants0.TVReturnType<{
|
|
38
|
+
mediaVariant: {
|
|
39
|
+
default: {
|
|
40
|
+
media: string;
|
|
41
|
+
};
|
|
42
|
+
icon: {
|
|
43
|
+
media: string;
|
|
44
|
+
};
|
|
45
|
+
};
|
|
46
|
+
}, {
|
|
47
|
+
root: string;
|
|
48
|
+
header: string;
|
|
49
|
+
media: string;
|
|
50
|
+
content: string;
|
|
51
|
+
title: string;
|
|
52
|
+
description: string;
|
|
53
|
+
}, undefined, unknown, unknown, undefined>>;
|
|
54
|
+
type EmptyVariants = VariantProps<typeof emptyVariants>;
|
|
55
|
+
type EmptyMediaVariant = NonNullable<EmptyVariants['mediaVariant']>;
|
|
56
|
+
//#endregion
|
|
57
|
+
export { EmptyMediaVariant };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{tv as e}from"tailwind-variants";const t=e({slots:{root:`flex min-w-0 flex-1 flex-col items-center justify-center gap-6 rounded-lg border border-dashed p-6 text-center md:p-12`,header:`flex max-w-sm flex-col items-center gap-2 text-center`,media:`mb-2 flex shrink-0 items-center justify-center [&_svg]:pointer-events-none [&_svg]:shrink-0`,content:`flex w-full min-w-0 max-w-sm flex-col items-center gap-4 text-balance text-sm`,title:`m-0 text-lg font-medium tracking-tight`,description:`m-0 text-sm/relaxed text-muted-foreground [&>a]:underline [&>a]:underline-offset-4 [&>a:hover]:text-primary`},variants:{mediaVariant:{default:{media:`bg-transparent`},icon:{media:`size-10 rounded-lg bg-muted text-foreground [&_svg:not([class*=size-])]:size-6`}}},defaultVariants:{mediaVariant:`default`}});export{t as emptyVariants};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { FormFieldBaseProps } from "./types.js";
|
|
2
|
-
import * as vue from "vue";
|
|
2
|
+
import * as _$vue from "vue";
|
|
3
3
|
|
|
4
4
|
//#region src/components/form/form-field-base.vue.d.ts
|
|
5
5
|
declare var __VLS_14: {}, __VLS_22: {
|
|
@@ -14,9 +14,9 @@ type __VLS_Slots = {} & {
|
|
|
14
14
|
} & {
|
|
15
15
|
description?: (props: typeof __VLS_36) => any;
|
|
16
16
|
};
|
|
17
|
-
declare const __VLS_base: vue.DefineComponent<FormFieldBaseProps, {}, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {}, string, vue.PublicProps, Readonly<FormFieldBaseProps> & Readonly<{}>, {
|
|
17
|
+
declare const __VLS_base: _$vue.DefineComponent<FormFieldBaseProps, {}, {}, {}, {}, _$vue.ComponentOptionsMixin, _$vue.ComponentOptionsMixin, {}, string, _$vue.PublicProps, Readonly<FormFieldBaseProps> & Readonly<{}>, {
|
|
18
18
|
inline: boolean;
|
|
19
|
-
}, {}, {}, {}, string, vue.ComponentProvideOptions, false, {}, any>;
|
|
19
|
+
}, {}, {}, {}, string, _$vue.ComponentProvideOptions, false, {}, any>;
|
|
20
20
|
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
21
21
|
declare const _default: typeof __VLS_export;
|
|
22
22
|
type __VLS_WithSlots<T, S> = T & {
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { FormProps } from "./types.js";
|
|
2
|
-
import * as vue from "vue";
|
|
2
|
+
import * as _$vue from "vue";
|
|
3
3
|
|
|
4
4
|
//#region src/components/form/form.vue.d.ts
|
|
5
5
|
declare var __VLS_1: {};
|
|
6
6
|
type __VLS_Slots = {} & {
|
|
7
7
|
default?: (props: typeof __VLS_1) => any;
|
|
8
8
|
};
|
|
9
|
-
declare const __VLS_base: vue.DefineComponent<FormProps, {}, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {}, string, vue.PublicProps, Readonly<FormProps> & Readonly<{}>, {}, {}, {}, {}, string, vue.ComponentProvideOptions, false, {}, any>;
|
|
9
|
+
declare const __VLS_base: _$vue.DefineComponent<FormProps, {}, {}, {}, {}, _$vue.ComponentOptionsMixin, _$vue.ComponentOptionsMixin, {}, string, _$vue.PublicProps, Readonly<FormProps> & Readonly<{}>, {}, {}, {}, {}, string, _$vue.ComponentProvideOptions, false, {}, any>;
|
|
10
10
|
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
11
11
|
declare const _default: typeof __VLS_export;
|
|
12
12
|
type __VLS_WithSlots<T, S> = T & {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { FormFieldArrayComponent, FormFieldComponent } from "./types.js";
|
|
2
|
-
import * as vue from "vue";
|
|
3
|
-
import * as _soybeanjs_headless0 from "@soybeanjs/headless";
|
|
2
|
+
import * as _$vue from "vue";
|
|
3
|
+
import * as _$_soybeanjs_headless0 from "@soybeanjs/headless";
|
|
4
4
|
import { FormValues, InferStandardSchemaInput, Path, StandardSchemaV1, UseFormOptions } from "@soybeanjs/headless";
|
|
5
5
|
|
|
6
6
|
//#region src/components/form/use-form.d.ts
|
|
@@ -9,36 +9,36 @@ declare function useForm$1<S extends StandardSchemaV1<FormValues, FormValues>>(o
|
|
|
9
9
|
SFormFieldArray: FormFieldArrayComponent<InferStandardSchemaInput<S>>;
|
|
10
10
|
handleSubmit: (event?: Event) => void;
|
|
11
11
|
handleReset: (event?: Event) => void;
|
|
12
|
-
useFieldArray: <Name extends Path<InferStandardSchemaInput<S>>>(name: Name, opts?: _soybeanjs_headless0.FormRegisterOptions<_soybeanjs_headless0.PathValue<InferStandardSchemaInput<S>, Name>> | undefined) => vue.Ref<_soybeanjs_headless0.FormFieldArrayStates<InferStandardSchemaInput<S>, Name>, _soybeanjs_headless0.FormFieldArrayStates<InferStandardSchemaInput<S>, Name>>;
|
|
13
|
-
useField: <Name extends Path<InferStandardSchemaInput<S>>>(name: Name, opts?: _soybeanjs_headless0.FormRegisterOptions<_soybeanjs_headless0.PathValue<InferStandardSchemaInput<S>, Name>> | undefined) => vue.Ref<_soybeanjs_headless0.FormFieldState<InferStandardSchemaInput<S>, Name>, _soybeanjs_headless0.FormFieldState<InferStandardSchemaInput<S>, Name>>;
|
|
14
|
-
dirty: vue.ComputedRef<boolean>;
|
|
12
|
+
useFieldArray: <Name extends Path<InferStandardSchemaInput<S>>>(name: Name, opts?: _$_soybeanjs_headless0.FormRegisterOptions<_$_soybeanjs_headless0.PathValue<InferStandardSchemaInput<S>, Name>> | undefined) => _$vue.Ref<_$_soybeanjs_headless0.FormFieldArrayStates<InferStandardSchemaInput<S>, Name>, _$_soybeanjs_headless0.FormFieldArrayStates<InferStandardSchemaInput<S>, Name>>;
|
|
13
|
+
useField: <Name extends Path<InferStandardSchemaInput<S>>>(name: Name, opts?: _$_soybeanjs_headless0.FormRegisterOptions<_$_soybeanjs_headless0.PathValue<InferStandardSchemaInput<S>, Name>> | undefined) => _$vue.Ref<_$_soybeanjs_headless0.FormFieldState<InferStandardSchemaInput<S>, Name>, _$_soybeanjs_headless0.FormFieldState<InferStandardSchemaInput<S>, Name>>;
|
|
14
|
+
dirty: _$vue.ComputedRef<boolean>;
|
|
15
15
|
setSubmitting: (isSubmitting: boolean) => void;
|
|
16
|
-
registerField: <Name extends Path<InferStandardSchemaInput<S>>>(name: Name, opts?: _soybeanjs_headless0.FormRegisterOptions<_soybeanjs_headless0.PathValue<InferStandardSchemaInput<S>, Name>> | undefined) => vue.Ref<_soybeanjs_headless0.FormFieldState<InferStandardSchemaInput<S>, Name>, _soybeanjs_headless0.FormFieldState<InferStandardSchemaInput<S>, Name>>;
|
|
17
|
-
registerFieldArray: <Name extends Path<InferStandardSchemaInput<S>>>(name: Name, opts?: _soybeanjs_headless0.FormRegisterOptions<_soybeanjs_headless0.PathValue<InferStandardSchemaInput<S>, Name>> | undefined) => vue.Ref<_soybeanjs_headless0.FormFieldState<InferStandardSchemaInput<S>, Name>, _soybeanjs_headless0.FormFieldState<InferStandardSchemaInput<S>, Name>>;
|
|
16
|
+
registerField: <Name extends Path<InferStandardSchemaInput<S>>>(name: Name, opts?: _$_soybeanjs_headless0.FormRegisterOptions<_$_soybeanjs_headless0.PathValue<InferStandardSchemaInput<S>, Name>> | undefined) => _$vue.Ref<_$_soybeanjs_headless0.FormFieldState<InferStandardSchemaInput<S>, Name>, _$_soybeanjs_headless0.FormFieldState<InferStandardSchemaInput<S>, Name>>;
|
|
17
|
+
registerFieldArray: <Name extends Path<InferStandardSchemaInput<S>>>(name: Name, opts?: _$_soybeanjs_headless0.FormRegisterOptions<_$_soybeanjs_headless0.PathValue<InferStandardSchemaInput<S>, Name>> | undefined) => _$vue.Ref<_$_soybeanjs_headless0.FormFieldState<InferStandardSchemaInput<S>, Name>, _$_soybeanjs_headless0.FormFieldState<InferStandardSchemaInput<S>, Name>>;
|
|
18
18
|
validateField: <Name extends Path<InferStandardSchemaInput<S>>>(name: Name) => Promise<string | undefined | void>;
|
|
19
|
-
getFieldValue: <Name extends Path<InferStandardSchemaInput<S>>>(name: Name) => vue.WritableComputedRef<_soybeanjs_headless0.PathValue<InferStandardSchemaInput<S>, Name>, _soybeanjs_headless0.PathValue<InferStandardSchemaInput<S>, Name>>;
|
|
20
|
-
getFieldMeta: <Name extends Path<InferStandardSchemaInput<S>>>(name: Name) => vue.Ref<_soybeanjs_headless0.FormFieldMeta>;
|
|
19
|
+
getFieldValue: <Name extends Path<InferStandardSchemaInput<S>>>(name: Name) => _$vue.WritableComputedRef<_$_soybeanjs_headless0.PathValue<InferStandardSchemaInput<S>, Name>, _$_soybeanjs_headless0.PathValue<InferStandardSchemaInput<S>, Name>>;
|
|
20
|
+
getFieldMeta: <Name extends Path<InferStandardSchemaInput<S>>>(name: Name) => _$vue.Ref<_$_soybeanjs_headless0.FormFieldMeta>;
|
|
21
21
|
getFieldError: <Name extends Path<InferStandardSchemaInput<S>>>(name: Name) => string | undefined;
|
|
22
22
|
getFieldTouched: <Name extends Path<InferStandardSchemaInput<S>>>(name: Name) => boolean | undefined;
|
|
23
23
|
getFieldDirty: <Name extends Path<InferStandardSchemaInput<S>>>(name: Name) => boolean;
|
|
24
|
-
getFieldState: <Name extends Path<InferStandardSchemaInput<S>>>(name: Name) => vue.Ref<_soybeanjs_headless0.FormFieldState<InferStandardSchemaInput<S>, Name>, _soybeanjs_headless0.FormFieldState<InferStandardSchemaInput<S>, Name>>;
|
|
25
|
-
setValues: (values: InferStandardSchemaInput<S>, shouldValidate?: boolean) => Promise<void> | Promise<_soybeanjs_headless0.FormErrors<InferStandardSchemaInput<S>>>;
|
|
26
|
-
setErrors: (errors: _soybeanjs_headless0.FormErrors<InferStandardSchemaInput<S>>) => void;
|
|
27
|
-
setFieldValue: <Name extends Path<InferStandardSchemaInput<S>>>(name: Name, value: _soybeanjs_headless0.PathValue<InferStandardSchemaInput<S>, Name>, shouldValidate?: boolean) => Promise<void> | Promise<_soybeanjs_headless0.FormErrors<InferStandardSchemaInput<S>>>;
|
|
24
|
+
getFieldState: <Name extends Path<InferStandardSchemaInput<S>>>(name: Name) => _$vue.Ref<_$_soybeanjs_headless0.FormFieldState<InferStandardSchemaInput<S>, Name>, _$_soybeanjs_headless0.FormFieldState<InferStandardSchemaInput<S>, Name>>;
|
|
25
|
+
setValues: (values: InferStandardSchemaInput<S>, shouldValidate?: boolean) => Promise<void> | Promise<_$_soybeanjs_headless0.FormErrors<InferStandardSchemaInput<S>>>;
|
|
26
|
+
setErrors: (errors: _$_soybeanjs_headless0.FormErrors<InferStandardSchemaInput<S>>) => void;
|
|
27
|
+
setFieldValue: <Name extends Path<InferStandardSchemaInput<S>>>(name: Name, value: _$_soybeanjs_headless0.PathValue<InferStandardSchemaInput<S>, Name>, shouldValidate?: boolean) => Promise<void> | Promise<_$_soybeanjs_headless0.FormErrors<InferStandardSchemaInput<S>>>;
|
|
28
28
|
setFieldTouched: <Name extends Path<InferStandardSchemaInput<S>>>(name: Name, touched: boolean) => void;
|
|
29
29
|
setFieldError: <Name extends Path<InferStandardSchemaInput<S>>>(name: Name, error: string | undefined) => void;
|
|
30
|
-
setFieldArrayValue: <Name extends Path<InferStandardSchemaInput<S>>, Method extends (...args: any) => any>(name: Name, value: _soybeanjs_headless0.PathValue<InferStandardSchemaInput<S>, Name>, method: Method, args?: Partial<{
|
|
30
|
+
setFieldArrayValue: <Name extends Path<InferStandardSchemaInput<S>>, Method extends (...args: any) => any>(name: Name, value: _$_soybeanjs_headless0.PathValue<InferStandardSchemaInput<S>, Name>, method: Method, args?: Partial<{
|
|
31
31
|
argA: Parameters<Method>[1];
|
|
32
32
|
argB: Parameters<Method>[2];
|
|
33
|
-
}> | undefined, shouldSetValue?: boolean) => Promise<void> | Promise<_soybeanjs_headless0.FormErrors<InferStandardSchemaInput<S>>>;
|
|
34
|
-
validateForm: (values?: InferStandardSchemaInput<S> | undefined) => Promise<_soybeanjs_headless0.FormErrors<InferStandardSchemaInput<S>>>;
|
|
35
|
-
resetForm: (nextState?: _soybeanjs_headless0.FormResetState<InferStandardSchemaInput<S>> | undefined) => void;
|
|
33
|
+
}> | undefined, shouldSetValue?: boolean) => Promise<void> | Promise<_$_soybeanjs_headless0.FormErrors<InferStandardSchemaInput<S>>>;
|
|
34
|
+
validateForm: (values?: InferStandardSchemaInput<S> | undefined) => Promise<_$_soybeanjs_headless0.FormErrors<InferStandardSchemaInput<S>>>;
|
|
35
|
+
resetForm: (nextState?: _$_soybeanjs_headless0.FormResetState<InferStandardSchemaInput<S>> | undefined) => void;
|
|
36
36
|
values: InferStandardSchemaInput<S>;
|
|
37
|
-
touched: vue.Ref<_soybeanjs_headless0.FormTouched<InferStandardSchemaInput<S>>, _soybeanjs_headless0.FormTouched<InferStandardSchemaInput<S>>>;
|
|
38
|
-
errors: vue.Ref<_soybeanjs_headless0.FormErrors<InferStandardSchemaInput<S>>, _soybeanjs_headless0.FormErrors<InferStandardSchemaInput<S>>>;
|
|
39
|
-
submitCount: vue.ShallowRef<number>;
|
|
40
|
-
isSubmitting: vue.ShallowRef<boolean>;
|
|
41
|
-
isValidating: vue.ShallowRef<boolean>;
|
|
37
|
+
touched: _$vue.Ref<_$_soybeanjs_headless0.FormTouched<InferStandardSchemaInput<S>>, _$_soybeanjs_headless0.FormTouched<InferStandardSchemaInput<S>>>;
|
|
38
|
+
errors: _$vue.Ref<_$_soybeanjs_headless0.FormErrors<InferStandardSchemaInput<S>>, _$_soybeanjs_headless0.FormErrors<InferStandardSchemaInput<S>>>;
|
|
39
|
+
submitCount: _$vue.ShallowRef<number>;
|
|
40
|
+
isSubmitting: _$vue.ShallowRef<boolean>;
|
|
41
|
+
isValidating: _$vue.ShallowRef<boolean>;
|
|
42
42
|
};
|
|
43
43
|
//#endregion
|
|
44
44
|
export { useForm$1 as useForm };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{tv as e}from"tailwind-variants";const t=e({slots:{form:`grid`,field:`flex`,fieldArray:`flex`,label:`flex items-center whitespace-nowrap`,control:``,description:`text-muted-foreground m-0`,error:`font-medium text-destructive m-0`},variants:{size:{xs:{field:`text-2xs gap-x-2.25 gap-y-1.5`,fieldArray:`text-2xs gap-x-2.25 gap-y-1.5`,label:`gap-1.5`},sm:{field:`text-xs gap-x-2.5 gap-y-1.75`,fieldArray:`text-xs gap-x-2.5 gap-y-1.75`,label:`gap-1.75`},md:{field:`text-sm gap-x-3 gap-y-2`,fieldArray:`text-sm gap-x-3 gap-y-2`,label:`gap-2`},lg:{field:`text-base gap-x-3.75 gap-y-2.5`,fieldArray:`text-base gap-x-3.75 gap-y-2.5`,label:`gap-2.5`},xl:{field:`text-lg gap-x-4.5 gap-y-3`,fieldArray:`text-lg gap-x-4.5 gap-y-3`,label:`gap-3`},"2xl":{field:`text-xl gap-x-5.25 gap-y-3.5`,fieldArray:`text-xl gap-x-5.25 gap-y-3.5`,label:`gap-3.5`}},inline:{true:{field:`justify-between items-center`,fieldArray:`justify-between`,label:`justify-end`,control:`
|
|
1
|
+
import{tv as e}from"tailwind-variants";const t=e({slots:{form:`grid`,field:`flex`,fieldArray:`flex`,label:`flex items-center whitespace-nowrap`,control:``,description:`text-muted-foreground m-0`,error:`font-medium text-destructive m-0`},variants:{size:{xs:{field:`text-2xs gap-x-2.25 gap-y-1.5`,fieldArray:`text-2xs gap-x-2.25 gap-y-1.5`,label:`gap-1.5`},sm:{field:`text-xs gap-x-2.5 gap-y-1.75`,fieldArray:`text-xs gap-x-2.5 gap-y-1.75`,label:`gap-1.75`},md:{field:`text-sm gap-x-3 gap-y-2`,fieldArray:`text-sm gap-x-3 gap-y-2`,label:`gap-2`},lg:{field:`text-base gap-x-3.75 gap-y-2.5`,fieldArray:`text-base gap-x-3.75 gap-y-2.5`,label:`gap-2.5`},xl:{field:`text-lg gap-x-4.5 gap-y-3`,fieldArray:`text-lg gap-x-4.5 gap-y-3`,label:`gap-3`},"2xl":{field:`text-xl gap-x-5.25 gap-y-3.5`,fieldArray:`text-xl gap-x-5.25 gap-y-3.5`,label:`gap-3.5`}},inline:{true:{field:`justify-between items-center`,fieldArray:`justify-between`,label:`shrink-0 justify-end`,control:`grow-1 shrink-1 min-w-0`,description:`w-full`,error:`absolute left-0 top-full w-full`},false:{field:`flex-col`,fieldArray:`flex-col`}}},defaultVariants:{size:`md`,inline:!1}});export{t as formVariants};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{mergeSlotVariants as e}from"../../theme/shared.js";import"../../theme/index.js";import{hoverCardVariants as t}from"./variants.js";import{computed as n,createBlock as r,createCommentVNode as i,createVNode as a,defineComponent as o,guardReactiveProps as s,mergeProps as c,normalizeProps as l,openBlock as u,renderSlot as d,toHandlers as f,unref as p,withCtx as m}from"vue";import{useForwardListeners as h,useOmitProps as g}from"@soybeanjs/headless/composables";import{HoverCardArrow as _,HoverCardPopup as v,HoverCardPortal as y,HoverCardPositioner as b,HoverCardRoot as x,HoverCardTrigger as S,provideHoverCardUi as C}from"@soybeanjs/headless";const w=o({name:`SHoverCard`,__name:`hover-card`,props:{class:{},size:{},ui:{},placement:{},showArrow:{type:Boolean,default:!0},positionerProps:{},popupProps:{},triggerProps:{},portalProps:{},arrowProps:{},defaultOpen:{type:Boolean,default:!1},open:{type:Boolean,default:void 0},openDelay:{},closeDelay:{}},emits:[`update:open`,`escapeKeyDown`,`pointerDownOutside`,`focusOutside`],setup(o,{emit:w}){let T=o,E=w,D=g(T,[`class`,`size`,`ui`,`placement`,`showArrow`,`positionerProps`,`popupProps`,`triggerProps`,`portalProps`,`arrowProps`]),O=h(E),k=n(()=>e(t({size:T.size}),T.ui,{popup:T.class})),A=n(()=>({...T.positionerProps,placement:T.placement??T.positionerProps?.placement}));return C(k),(e,t)=>(u(),r(p(x),c(p(D),{"onUpdate:open":t[0]||=e=>E(`update:open`,e)}),{default:m(()=>[a(p(S),c(o.triggerProps,{"as-child":``}),{default:m(()=>[d(e.$slots,`trigger`)]),_:3},16),a(p(y),l(s(o.portalProps)),{default:m(()=>[a(p(b),c(A.value,f(p(O))),{default:m(()=>[a(p(v),l(s(o.popupProps)),{default:m(()=>[d(e.$slots,`default`),o.showArrow?(u(),r(p(_),l(c({key:0},o.arrowProps)),null,16)):i(`v-if`,!0)]),_:3},16)]),_:3},16)]),_:3},16)]),_:3},16))}});export{w as default};
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { HoverCardProps } from "./types.js";
|
|
2
|
+
import * as _$vue from "vue";
|
|
3
|
+
import * as _$_soybeanjs_headless0 from "@soybeanjs/headless";
|
|
4
|
+
|
|
5
|
+
//#region src/components/hover-card/hover-card.vue.d.ts
|
|
6
|
+
declare var __VLS_16: {}, __VLS_36: {};
|
|
7
|
+
type __VLS_Slots = {} & {
|
|
8
|
+
trigger?: (props: typeof __VLS_16) => any;
|
|
9
|
+
} & {
|
|
10
|
+
default?: (props: typeof __VLS_36) => any;
|
|
11
|
+
};
|
|
12
|
+
declare const __VLS_base: _$vue.DefineComponent<HoverCardProps, {}, {}, {}, {}, _$vue.ComponentOptionsMixin, _$vue.ComponentOptionsMixin, {
|
|
13
|
+
"update:open": (value: boolean) => any;
|
|
14
|
+
escapeKeyDown: (event: KeyboardEvent) => any;
|
|
15
|
+
pointerDownOutside: (event: _$_soybeanjs_headless0.PointerDownOutsideEvent) => any;
|
|
16
|
+
focusOutside: (event: _$_soybeanjs_headless0.FocusOutsideEvent) => any;
|
|
17
|
+
}, string, _$vue.PublicProps, Readonly<HoverCardProps> & Readonly<{
|
|
18
|
+
"onUpdate:open"?: ((value: boolean) => any) | undefined;
|
|
19
|
+
onEscapeKeyDown?: ((event: KeyboardEvent) => any) | undefined;
|
|
20
|
+
onPointerDownOutside?: ((event: _$_soybeanjs_headless0.PointerDownOutsideEvent) => any) | undefined;
|
|
21
|
+
onFocusOutside?: ((event: _$_soybeanjs_headless0.FocusOutsideEvent) => any) | undefined;
|
|
22
|
+
}>, {
|
|
23
|
+
open: boolean;
|
|
24
|
+
defaultOpen: boolean;
|
|
25
|
+
showArrow: boolean;
|
|
26
|
+
}, {}, {}, {}, string, _$vue.ComponentProvideOptions, false, {}, any>;
|
|
27
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
28
|
+
declare const _default: typeof __VLS_export;
|
|
29
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
30
|
+
new (): {
|
|
31
|
+
$slots: S;
|
|
32
|
+
};
|
|
33
|
+
};
|
|
34
|
+
//#endregion
|
|
35
|
+
export { _default };
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { HoverCardEmits, HoverCardProps } from "./types.js";
|
|
2
|
+
import { _default } from "./hover-card.vue.js";
|
|
3
|
+
import { HoverCardArrowProps, HoverCardPopupProps, HoverCardPortalProps, HoverCardPositionerEmits, HoverCardPositionerProps, HoverCardRootEmits, HoverCardRootProps, HoverCardTriggerProps, HoverCardUi, HoverCardUiSlot } from "@soybeanjs/headless/hover-card";
|
|
4
|
+
export { type HoverCardArrowProps, type HoverCardPopupProps, type HoverCardPortalProps, type HoverCardPositionerEmits, type HoverCardPositionerProps, type HoverCardRootEmits, type HoverCardRootProps, type HoverCardTriggerProps, type HoverCardUi, type HoverCardUiSlot };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import"./hover-card.js";
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { ThemeSize } from "../../theme/types.js";
|
|
2
|
+
import { ClassValue, HoverCardArrowProps, HoverCardPopupProps, HoverCardPortalProps, HoverCardPositionerEmits, HoverCardPositionerProps, HoverCardRootEmits, HoverCardRootProps, HoverCardTriggerProps, HoverCardUi, Placement } from "@soybeanjs/headless";
|
|
3
|
+
|
|
4
|
+
//#region src/components/hover-card/types.d.ts
|
|
5
|
+
interface HoverCardProps extends HoverCardRootProps {
|
|
6
|
+
/**
|
|
7
|
+
* class of popup
|
|
8
|
+
*/
|
|
9
|
+
class?: ClassValue;
|
|
10
|
+
size?: ThemeSize;
|
|
11
|
+
ui?: Partial<HoverCardUi>;
|
|
12
|
+
placement?: Placement;
|
|
13
|
+
showArrow?: boolean;
|
|
14
|
+
positionerProps?: HoverCardPositionerProps;
|
|
15
|
+
popupProps?: HoverCardPopupProps;
|
|
16
|
+
triggerProps?: HoverCardTriggerProps;
|
|
17
|
+
portalProps?: HoverCardPortalProps;
|
|
18
|
+
arrowProps?: HoverCardArrowProps;
|
|
19
|
+
}
|
|
20
|
+
type HoverCardEmits = HoverCardRootEmits & HoverCardPositionerEmits;
|
|
21
|
+
//#endregion
|
|
22
|
+
export { HoverCardEmits, HoverCardProps };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{tv as e}from"tailwind-variants";const t=e({slots:{positioner:`w-max`,popup:[`z-50 w-64 rounded-md border bg-popover text-popover-foreground shadow-md outline-none will-change-transform`,`data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95`,`data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95`,`data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2`],arrow:`w-1em h-0.5em fill-popover stroke-border`},variants:{size:{xs:{popup:`w-48 p-3 text-2xs`,arrow:`text-3xs`},sm:{popup:`w-56 p-3.5 text-xs`,arrow:`text-2xs`},md:{popup:`w-64 p-4 text-sm`,arrow:`text-xs`},lg:{popup:`w-72 p-4.5 text-base`,arrow:`text-sm`},xl:{popup:`w-80 p-5 text-lg`,arrow:`text-base`},"2xl":{popup:`w-96 p-5.5 text-xl`,arrow:`text-lg`}}},defaultVariants:{size:`md`}});export{t as hoverCardVariants};
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { IconProps } from "./types.js";
|
|
2
|
-
import * as vue from "vue";
|
|
2
|
+
import * as _$vue from "vue";
|
|
3
3
|
|
|
4
4
|
//#region src/components/icon/icon.vue.d.ts
|
|
5
|
-
declare const __VLS_export: vue.DefineComponent<IconProps, {}, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {}, string, vue.PublicProps, Readonly<IconProps> & Readonly<{}>, {}, {}, {}, {}, string, vue.ComponentProvideOptions, false, {}, any>;
|
|
5
|
+
declare const __VLS_export: _$vue.DefineComponent<IconProps, {}, {}, {}, {}, _$vue.ComponentOptionsMixin, _$vue.ComponentOptionsMixin, {}, string, _$vue.PublicProps, Readonly<IconProps> & Readonly<{}>, {}, {}, {}, {}, string, _$vue.ComponentProvideOptions, false, {}, any>;
|
|
6
6
|
declare const _default: typeof __VLS_export;
|
|
7
7
|
//#endregion
|
|
8
8
|
export { _default };
|
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { IconProps
|
|
1
|
+
import { IconValue } from "@soybeanjs/headless";
|
|
2
|
+
import { IconProps } from "@iconify/vue";
|
|
3
3
|
|
|
4
4
|
//#region src/components/icon/types.d.ts
|
|
5
|
-
type IconValue = VNode | Component | string | IconifyIcon | null | undefined;
|
|
6
5
|
interface IconProps$1 extends Omit<IconProps, 'icon'> {
|
|
7
6
|
icon: IconValue;
|
|
8
7
|
}
|
|
9
8
|
//#endregion
|
|
10
|
-
export { IconProps$1 as IconProps, IconValue };
|
|
9
|
+
export { IconProps$1 as IconProps, type IconValue };
|