@soybeanjs/headless 0.15.5 → 0.17.0
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/dist/components/_icon/types.d.ts +9 -0
- package/dist/components/accordion/types.d.ts +87 -0
- package/dist/components/affix/types.d.ts +39 -0
- package/dist/components/alert/types.d.ts +78 -0
- package/dist/components/anchor/anchor-compact.js +1 -1
- package/dist/components/anchor/{anchor-compact-item.js → anchor-item-compact.js} +1 -1
- package/dist/components/anchor/anchor-item-compact.vue.d.ts +8 -0
- package/dist/components/anchor/anchor-link.js +1 -1
- package/dist/components/anchor/anchor-root.vue.d.ts +1 -1
- package/dist/components/anchor/index.d.ts +5 -4
- package/dist/components/anchor/index.js +1 -1
- package/dist/components/anchor/types.d.ts +122 -10
- package/dist/components/arrow/types.d.ts +3 -0
- package/dist/components/aspect-ratio/types.d.ts +3 -0
- package/dist/components/autocomplete/autocomplete-compact.js +1 -1
- package/dist/components/autocomplete/autocomplete-compact.vue.d.ts +2 -2
- package/dist/components/autocomplete/autocomplete-input.js +1 -1
- package/dist/components/autocomplete/autocomplete-input.vue.d.ts +2 -2
- package/dist/components/autocomplete/autocomplete-root.js +1 -1
- package/dist/components/autocomplete/autocomplete-root.vue.d.ts +15 -5
- package/dist/components/autocomplete/context.d.ts +2 -2
- package/dist/components/autocomplete/context.js +1 -1
- package/dist/components/autocomplete/index.d.ts +17 -13
- package/dist/components/autocomplete/index.js +1 -1
- package/dist/components/autocomplete/types.d.ts +159 -32
- package/dist/components/avatar/types.d.ts +18 -0
- package/dist/components/backtop/backtop.vue.d.ts +9 -3
- package/dist/components/backtop/index.d.ts +2 -2
- package/dist/components/backtop/types.d.ts +19 -12
- package/dist/components/badge/types.d.ts +21 -0
- package/dist/components/bottom-sheet/bottom-sheet-compact.js +1 -1
- package/dist/components/bottom-sheet/bottom-sheet-root-nested.js +1 -1
- package/dist/components/bottom-sheet/bottom-sheet-root-nested.vue.d.ts +2 -2
- package/dist/components/bottom-sheet/bottom-sheet-root.js +1 -1
- package/dist/components/bottom-sheet/types.d.ts +99 -0
- package/dist/components/breadcrumb/index.d.ts +2 -2
- package/dist/components/breadcrumb/types.d.ts +103 -1
- package/dist/components/button/types.d.ts +16 -1
- package/dist/components/calendar/calendar-cell-trigger.js +1 -0
- package/dist/components/calendar/calendar-cell-trigger.vue.d.ts +28 -0
- package/dist/components/calendar/calendar-cell.js +1 -0
- package/dist/components/{autocomplete/autocomplete-anchor.vue.d.ts → calendar/calendar-cell.vue.d.ts} +3 -3
- package/dist/components/calendar/calendar-compact.js +1 -0
- package/dist/components/calendar/calendar-compact.vue.d.ts +23 -0
- package/dist/components/calendar/calendar-grid-body.js +1 -0
- package/dist/components/{combobox/combobox-item-indicator.vue.d.ts → calendar/calendar-grid-body.vue.d.ts} +3 -3
- package/dist/components/calendar/calendar-grid-head.js +1 -0
- package/dist/components/calendar/calendar-grid-head.vue.d.ts +21 -0
- package/dist/components/calendar/calendar-grid-row.js +1 -0
- package/dist/components/calendar/calendar-grid-row.vue.d.ts +21 -0
- package/dist/components/calendar/calendar-grid.js +1 -0
- package/dist/components/calendar/calendar-grid.vue.d.ts +21 -0
- package/dist/components/calendar/calendar-head-cell.js +1 -0
- package/dist/components/calendar/calendar-head-cell.vue.d.ts +21 -0
- package/dist/components/calendar/calendar-header.js +1 -0
- package/dist/components/calendar/calendar-header.vue.d.ts +21 -0
- package/dist/components/calendar/calendar-heading.js +1 -0
- package/dist/components/calendar/calendar-heading.vue.d.ts +22 -0
- package/dist/components/calendar/calendar-next.js +1 -0
- package/dist/components/calendar/calendar-next.vue.d.ts +24 -0
- package/dist/components/calendar/calendar-prev.js +1 -0
- package/dist/components/calendar/calendar-prev.vue.d.ts +24 -0
- package/dist/components/calendar/calendar-root.js +1 -0
- package/dist/components/calendar/calendar-root.vue.d.ts +25 -0
- package/dist/components/calendar/context.d.ts +9 -0
- package/dist/components/calendar/context.js +1 -0
- package/dist/components/calendar/index.d.ts +16 -0
- package/dist/components/calendar/index.js +1 -0
- package/dist/components/calendar/types.d.ts +528 -0
- package/dist/components/calendar/use-calendar.d.ts +45 -0
- package/dist/components/calendar/use-calendar.js +1 -0
- package/dist/components/card/card-compact.js +1 -0
- package/dist/components/card/card-compact.vue.d.ts +19 -0
- package/dist/components/card/card-root.vue.d.ts +1 -1
- package/dist/components/card/index.d.ts +10 -9
- package/dist/components/card/index.js +1 -1
- package/dist/components/card/types.d.ts +112 -1
- package/dist/components/carousel/carousel-root.vue.d.ts +39 -2
- package/dist/components/carousel/index.d.ts +4 -2
- package/dist/components/carousel/types.d.ts +50 -8
- package/dist/components/checkbox/checkbox-group-root.js +1 -1
- package/dist/components/checkbox/checkbox-root.js +1 -1
- package/dist/components/checkbox/types.d.ts +111 -0
- package/dist/components/clipboard/types.d.ts +42 -0
- package/dist/components/collapsible/collapsible-root.vue.d.ts +1 -1
- package/dist/components/collapsible/types.d.ts +18 -0
- package/dist/components/color-area/color-area-root.vue.d.ts +4 -4
- package/dist/components/color-area/types.d.ts +60 -0
- package/dist/components/color-field/color-field-root.vue.d.ts +3 -3
- package/dist/components/color-field/types.d.ts +51 -0
- package/dist/components/color-picker/color-picker-root.vue.d.ts +4 -4
- package/dist/components/color-picker/types.d.ts +39 -0
- package/dist/components/color-slider/color-slider-root.vue.d.ts +4 -4
- package/dist/components/color-slider/types.d.ts +60 -0
- package/dist/components/color-swatch/types.d.ts +9 -0
- package/dist/components/color-swatch-picker/color-swatch-picker-root.vue.d.ts +2 -2
- package/dist/components/color-swatch-picker/types.d.ts +27 -0
- package/dist/components/combobox/combobox-arrow.js +1 -1
- package/dist/components/combobox/combobox-arrow.vue.d.ts +2 -2
- package/dist/components/combobox/combobox-compact.js +1 -1
- package/dist/components/combobox/combobox-compact.vue.d.ts +2 -2
- package/dist/components/combobox/combobox-content-impl.js +1 -1
- package/dist/components/combobox/combobox-group.vue.d.ts +2 -2
- package/dist/components/combobox/combobox-input.js +1 -1
- package/dist/components/combobox/combobox-item.js +1 -1
- package/dist/components/combobox/combobox-root.js +1 -1
- package/dist/components/combobox/combobox-root.vue.d.ts +2 -2
- package/dist/components/combobox/combobox-trigger.js +1 -1
- package/dist/components/combobox/combobox-virtualizer.js +1 -1
- package/dist/components/combobox/context.js +1 -1
- package/dist/components/combobox/index.d.ts +12 -10
- package/dist/components/combobox/index.js +1 -1
- package/dist/components/combobox/types.d.ts +247 -20
- package/dist/components/command/command-compact.js +1 -1
- package/dist/components/command/command-compact.vue.d.ts +2 -2
- package/dist/components/command/types.d.ts +148 -1
- package/dist/components/config-provider/config-provider.vue.d.ts +1 -1
- package/dist/components/config-provider/types.d.ts +3 -0
- package/dist/components/context-menu/context-menu-checkbox-compact.js +1 -1
- package/dist/components/context-menu/context-menu-checkbox-compact.vue.d.ts +2 -2
- package/dist/components/context-menu/context-menu-compact.js +1 -1
- package/dist/components/context-menu/context-menu-compact.vue.d.ts +2 -2
- package/dist/components/context-menu/context-menu-radio-compact.js +1 -1
- package/dist/components/context-menu/context-menu-radio-compact.vue.d.ts +2 -2
- package/dist/components/context-menu/context-menu-root.js +1 -1
- package/dist/components/context-menu/context-menu-wrapper-compact.js +1 -1
- package/dist/components/context-menu/context-menu-wrapper-compact.vue.d.ts +2 -2
- package/dist/components/context-menu/index.d.ts +2 -2
- package/dist/components/context-menu/index.js +1 -1
- package/dist/components/context-menu/types.d.ts +78 -0
- package/dist/components/date-field/context.d.ts +9 -0
- package/dist/components/date-field/context.js +1 -0
- package/dist/components/date-field/date-field-compact.js +1 -0
- package/dist/components/date-field/date-field-compact.vue.d.ts +15 -0
- package/dist/components/date-field/date-field-input.js +1 -0
- package/dist/components/date-field/date-field-input.vue.d.ts +21 -0
- package/dist/components/date-field/date-field-root.js +1 -0
- package/dist/components/date-field/date-field-root.vue.d.ts +42 -0
- package/dist/components/date-field/index.d.ts +6 -0
- package/dist/components/date-field/index.js +1 -0
- package/dist/components/date-field/types.d.ts +214 -0
- package/dist/components/date-picker/context.d.ts +9 -0
- package/dist/components/date-picker/context.js +1 -0
- package/dist/components/date-picker/date-picker-compact.js +1 -0
- package/dist/components/date-picker/date-picker-compact.vue.d.ts +27 -0
- package/dist/components/date-picker/date-picker-content.js +1 -0
- package/dist/components/date-picker/date-picker-content.vue.d.ts +33 -0
- package/dist/components/date-picker/date-picker-root.js +1 -0
- package/dist/components/date-picker/date-picker-root.vue.d.ts +38 -0
- package/dist/components/date-picker/index.d.ts +9 -0
- package/dist/components/date-picker/index.js +1 -0
- package/dist/components/date-picker/types.d.ts +290 -0
- package/dist/components/date-range-field/context.d.ts +9 -0
- package/dist/components/date-range-field/context.js +1 -0
- package/dist/components/date-range-field/date-range-field-compact.js +1 -0
- package/dist/components/date-range-field/date-range-field-compact.vue.d.ts +29 -0
- package/dist/components/date-range-field/date-range-field-input.js +1 -0
- package/dist/components/date-range-field/date-range-field-input.vue.d.ts +22 -0
- package/dist/components/date-range-field/date-range-field-root.js +1 -0
- package/dist/components/date-range-field/date-range-field-root.vue.d.ts +55 -0
- package/dist/components/date-range-field/index.d.ts +6 -0
- package/dist/components/date-range-field/index.js +1 -0
- package/dist/components/date-range-field/types.d.ts +280 -0
- package/dist/components/date-range-picker/context.d.ts +9 -0
- package/dist/components/date-range-picker/context.js +1 -0
- package/dist/components/date-range-picker/date-range-picker-compact.js +1 -0
- package/dist/components/date-range-picker/date-range-picker-compact.vue.d.ts +31 -0
- package/dist/components/date-range-picker/date-range-picker-popup.js +1 -0
- package/dist/components/date-range-picker/date-range-picker-popup.vue.d.ts +21 -0
- package/dist/components/date-range-picker/date-range-picker-root.js +1 -0
- package/dist/components/date-range-picker/date-range-picker-root.vue.d.ts +50 -0
- package/dist/components/date-range-picker/date-range-picker-trigger.js +1 -0
- package/dist/components/date-range-picker/date-range-picker-trigger.vue.d.ts +21 -0
- package/dist/components/date-range-picker/index.d.ts +7 -0
- package/dist/components/date-range-picker/index.js +1 -0
- package/dist/components/date-range-picker/types.d.ts +282 -0
- package/dist/components/dialog/dialog-compact.js +1 -1
- package/dist/components/dialog/dialog-compact.vue.d.ts +6 -6
- package/dist/components/dialog/dialog-root.js +1 -1
- package/dist/components/dialog/types.d.ts +196 -2
- package/dist/components/dropdown-menu/dropdown-menu-checkbox-compact.js +1 -1
- package/dist/components/dropdown-menu/dropdown-menu-checkbox-compact.vue.d.ts +2 -2
- package/dist/components/dropdown-menu/dropdown-menu-compact.js +1 -1
- package/dist/components/dropdown-menu/dropdown-menu-compact.vue.d.ts +2 -2
- package/dist/components/dropdown-menu/dropdown-menu-radio-compact.js +1 -1
- package/dist/components/dropdown-menu/dropdown-menu-radio-compact.vue.d.ts +2 -2
- package/dist/components/dropdown-menu/dropdown-menu-root.js +1 -1
- package/dist/components/dropdown-menu/dropdown-menu-root.vue.d.ts +1 -1
- package/dist/components/dropdown-menu/dropdown-menu-wrapper-compact.js +1 -1
- package/dist/components/dropdown-menu/dropdown-menu-wrapper-compact.vue.d.ts +2 -2
- package/dist/components/dropdown-menu/index.d.ts +2 -2
- package/dist/components/dropdown-menu/index.js +1 -1
- package/dist/components/dropdown-menu/types.d.ts +84 -0
- package/dist/components/editable/editable-compact.js +1 -0
- package/dist/components/editable/editable-compact.vue.d.ts +23 -0
- package/dist/components/editable/editable-root.vue.d.ts +1 -1
- package/dist/components/editable/index.d.ts +8 -7
- package/dist/components/editable/index.js +1 -1
- package/dist/components/editable/types.d.ts +151 -2
- package/dist/components/empty/types.d.ts +24 -0
- package/dist/components/form/core/types.d.ts +396 -13
- package/dist/components/form/types.d.ts +27 -0
- package/dist/components/hover-card/hover-card-compact.js +1 -0
- package/dist/components/hover-card/hover-card-compact.vue.d.ts +30 -0
- package/dist/components/hover-card/hover-card-positioner-impl.js +1 -1
- package/dist/components/hover-card/hover-card-positioner.js +1 -1
- package/dist/components/hover-card/hover-card-positioner.vue.d.ts +1 -0
- package/dist/components/hover-card/hover-card-root.vue.d.ts +1 -1
- package/dist/components/hover-card/index.d.ts +8 -7
- package/dist/components/hover-card/index.js +1 -1
- package/dist/components/hover-card/types.d.ts +72 -1
- package/dist/components/input/input-root.js +1 -1
- package/dist/components/input/types.d.ts +21 -0
- package/dist/components/input-number/types.d.ts +30 -0
- package/dist/components/input-otp/index.d.ts +1 -2
- package/dist/components/input-otp/index.js +1 -1
- package/dist/components/input-otp/input-otp-compact.vue.d.ts +2 -2
- package/dist/components/input-otp/input-otp-root.vue.d.ts +3 -3
- package/dist/components/input-otp/types.d.ts +186 -0
- package/dist/components/kbd/types.d.ts +6 -0
- package/dist/components/label/types.d.ts +3 -0
- package/dist/components/layout/layout-classic-compact.vue.d.ts +1 -1
- package/dist/components/layout/layout-compact.vue.d.ts +1 -1
- package/dist/components/layout/layout-root.vue.d.ts +1 -1
- package/dist/components/layout/types.d.ts +124 -10
- package/dist/components/link/link.vue.d.ts +1 -1
- package/dist/components/link/types.d.ts +12 -0
- package/dist/components/list/types.d.ts +21 -0
- package/dist/components/listbox/index.js +1 -1
- package/dist/components/listbox/listbox-root.js +1 -1
- package/dist/components/listbox/listbox-root.vue.d.ts +2 -2
- package/dist/components/listbox/types.d.ts +66 -0
- package/dist/components/menu/hooks.js +1 -1
- package/dist/components/menu/index.d.ts +2 -2
- package/dist/components/menu/index.js +1 -1
- package/dist/components/menu/menu-checkbox-options-compact.js +1 -1
- package/dist/components/menu/menu-option-compact.js +1 -1
- package/dist/components/menu/menu-option-compact.vue.d.ts +2 -2
- package/dist/components/menu/menu-options-compact.js +1 -1
- package/dist/components/menu/menu-options-compact.vue.d.ts +2 -2
- package/dist/components/menu/menu-radio-options-compact.js +1 -1
- package/dist/components/menu/menu-root.js +1 -1
- package/dist/components/menu/types.d.ts +267 -3
- package/dist/components/menubar/index.js +1 -1
- package/dist/components/menubar/menubar-compact.js +1 -1
- package/dist/components/menubar/menubar-compact.vue.d.ts +2 -2
- package/dist/components/menubar/types.d.ts +72 -0
- package/dist/components/month-picker/context.d.ts +9 -0
- package/dist/components/month-picker/context.js +1 -0
- package/dist/components/month-picker/index.d.ts +6 -0
- package/dist/components/month-picker/index.js +1 -0
- package/dist/components/month-picker/month-picker-popup.js +1 -0
- package/dist/components/month-picker/month-picker-popup.vue.d.ts +36 -0
- package/dist/components/month-picker/month-picker-root.js +1 -0
- package/dist/components/month-picker/month-picker-root.vue.d.ts +39 -0
- package/dist/components/month-picker/month-picker-trigger.js +1 -0
- package/dist/components/{autocomplete/autocomplete-trigger.vue.d.ts → month-picker/month-picker-trigger.vue.d.ts} +3 -3
- package/dist/components/month-picker/types.d.ts +202 -0
- package/dist/components/month-range-picker/context.d.ts +9 -0
- package/dist/components/month-range-picker/context.js +1 -0
- package/dist/components/month-range-picker/index.d.ts +6 -0
- package/dist/components/month-range-picker/index.js +1 -0
- package/dist/components/month-range-picker/month-range-picker-popup.js +1 -0
- package/dist/components/month-range-picker/month-range-picker-popup.vue.d.ts +39 -0
- package/dist/components/month-range-picker/month-range-picker-root.js +1 -0
- package/dist/components/month-range-picker/month-range-picker-root.vue.d.ts +43 -0
- package/dist/components/month-range-picker/month-range-picker-trigger.js +1 -0
- package/dist/components/month-range-picker/month-range-picker-trigger.vue.d.ts +21 -0
- package/dist/components/month-range-picker/types.d.ts +234 -0
- package/dist/components/navigation-menu/index.d.ts +12 -11
- package/dist/components/navigation-menu/index.js +1 -1
- package/dist/components/navigation-menu/navigation-menu-compact.js +1 -0
- package/dist/components/navigation-menu/navigation-menu-compact.vue.d.ts +34 -0
- package/dist/components/navigation-menu/navigation-menu-root.vue.d.ts +1 -1
- package/dist/components/navigation-menu/types.d.ts +153 -2
- package/dist/components/page-tabs/types.d.ts +24 -0
- package/dist/components/pagination/index.d.ts +11 -10
- package/dist/components/pagination/index.js +1 -1
- package/dist/components/pagination/pagination-compact.js +1 -0
- package/dist/components/pagination/pagination-compact.vue.d.ts +23 -0
- package/dist/components/pagination/types.d.ts +117 -1
- package/dist/components/popover/context.d.ts +9 -0
- package/dist/components/popover/context.js +1 -1
- package/dist/components/popover/index.d.ts +10 -9
- package/dist/components/popover/index.js +1 -1
- package/dist/components/popover/popover-compact.js +1 -0
- package/dist/components/popover/popover-compact.vue.d.ts +36 -0
- package/dist/components/popover/popover-root.js +1 -1
- package/dist/components/popover/popover-root.vue.d.ts +0 -2
- package/dist/components/popover/popover-trigger.js +1 -1
- package/dist/components/popover/types.d.ts +111 -6
- package/dist/components/popper/index.js +1 -1
- package/dist/components/popper/popper-anchor.js +1 -1
- package/dist/components/popper/popper-positioner.vue.d.ts +2 -2
- package/dist/components/popper/types.d.ts +22 -1
- package/dist/components/portal/types.d.ts +3 -0
- package/dist/components/primitive/types.d.ts +6 -0
- package/dist/components/progress/types.d.ts +81 -0
- package/dist/components/radio-group/types.d.ts +66 -0
- package/dist/components/range-calendar/context.d.ts +9 -0
- package/dist/components/range-calendar/context.js +1 -0
- package/dist/components/range-calendar/index.d.ts +16 -0
- package/dist/components/range-calendar/index.js +1 -0
- package/dist/components/range-calendar/range-calendar-cell-trigger.js +1 -0
- package/dist/components/range-calendar/range-calendar-cell-trigger.vue.d.ts +33 -0
- package/dist/components/range-calendar/range-calendar-cell.js +1 -0
- package/dist/components/range-calendar/range-calendar-cell.vue.d.ts +21 -0
- package/dist/components/range-calendar/range-calendar-compact.js +1 -0
- package/dist/components/range-calendar/range-calendar-compact.vue.d.ts +25 -0
- package/dist/components/range-calendar/range-calendar-grid-body.js +1 -0
- package/dist/components/range-calendar/range-calendar-grid-body.vue.d.ts +21 -0
- package/dist/components/range-calendar/range-calendar-grid-head.js +1 -0
- package/dist/components/range-calendar/range-calendar-grid-head.vue.d.ts +21 -0
- package/dist/components/range-calendar/range-calendar-grid-row.js +1 -0
- package/dist/components/range-calendar/range-calendar-grid-row.vue.d.ts +21 -0
- package/dist/components/range-calendar/range-calendar-grid.js +1 -0
- package/dist/components/range-calendar/range-calendar-grid.vue.d.ts +21 -0
- package/dist/components/range-calendar/range-calendar-head-cell.js +1 -0
- package/dist/components/range-calendar/range-calendar-head-cell.vue.d.ts +21 -0
- package/dist/components/range-calendar/range-calendar-header.js +1 -0
- package/dist/components/range-calendar/range-calendar-header.vue.d.ts +21 -0
- package/dist/components/range-calendar/range-calendar-heading.js +1 -0
- package/dist/components/range-calendar/range-calendar-heading.vue.d.ts +22 -0
- package/dist/components/range-calendar/range-calendar-next.js +1 -0
- package/dist/components/range-calendar/range-calendar-next.vue.d.ts +24 -0
- package/dist/components/range-calendar/range-calendar-prev.js +1 -0
- package/dist/components/range-calendar/range-calendar-prev.vue.d.ts +24 -0
- package/dist/components/range-calendar/range-calendar-root.js +1 -0
- package/dist/components/range-calendar/range-calendar-root.vue.d.ts +55 -0
- package/dist/components/range-calendar/types.d.ts +488 -0
- package/dist/components/range-calendar/use-range-calendar.js +1 -0
- package/dist/components/roving-focus/types.d.ts +18 -0
- package/dist/components/scroll-area/types.d.ts +33 -0
- package/dist/components/segment/types.d.ts +36 -0
- package/dist/components/select/select-content.vue.d.ts +1 -1
- package/dist/components/select/types.d.ts +240 -0
- package/dist/components/separator/types.d.ts +12 -0
- package/dist/components/skeleton/types.d.ts +3 -0
- package/dist/components/slider/slider-root.vue.d.ts +2 -2
- package/dist/components/slider/types.d.ts +90 -0
- package/dist/components/splitter/splitter-group.vue.d.ts +1 -1
- package/dist/components/splitter/types.d.ts +114 -0
- package/dist/components/stepper/index.d.ts +10 -9
- package/dist/components/stepper/index.js +1 -1
- package/dist/components/stepper/stepper-compact.js +1 -0
- package/dist/components/stepper/stepper-compact.vue.d.ts +19 -0
- package/dist/components/stepper/stepper-root.vue.d.ts +2 -2
- package/dist/components/stepper/types.d.ts +136 -2
- package/dist/components/switch/types.d.ts +21 -0
- package/dist/components/table/table-compact.vue.d.ts +2 -2
- package/dist/components/table/types.d.ts +819 -0
- package/dist/components/tabs/tabs-root.vue.d.ts +1 -1
- package/dist/components/tabs/types.d.ts +75 -0
- package/dist/components/tag/types.d.ts +12 -0
- package/dist/components/tags-input/types.d.ts +63 -0
- package/dist/components/textarea/types.d.ts +27 -0
- package/dist/components/time-field/context.d.ts +9 -0
- package/dist/components/time-field/context.js +1 -0
- package/dist/components/time-field/index.d.ts +5 -0
- package/dist/components/time-field/index.js +1 -0
- package/dist/components/time-field/time-field-input.js +1 -0
- package/dist/components/time-field/time-field-input.vue.d.ts +21 -0
- package/dist/components/time-field/time-field-root.js +1 -0
- package/dist/components/time-field/time-field-root.vue.d.ts +43 -0
- package/dist/components/time-field/types.d.ts +201 -0
- package/dist/components/time-picker/context.d.ts +9 -0
- package/dist/components/time-picker/context.js +1 -0
- package/dist/components/time-picker/index.d.ts +6 -0
- package/dist/components/time-picker/index.js +1 -0
- package/dist/components/time-picker/time-picker-popup.js +1 -0
- package/dist/components/time-picker/time-picker-popup.vue.d.ts +27 -0
- package/dist/components/time-picker/time-picker-root.js +1 -0
- package/dist/components/time-picker/time-picker-root.vue.d.ts +45 -0
- package/dist/components/time-picker/time-picker-trigger.js +1 -0
- package/dist/components/time-picker/time-picker-trigger.vue.d.ts +21 -0
- package/dist/components/time-picker/types.d.ts +224 -0
- package/dist/components/time-range-field/context.d.ts +9 -0
- package/dist/components/time-range-field/context.js +1 -0
- package/dist/components/time-range-field/index.d.ts +6 -0
- package/dist/components/time-range-field/index.js +1 -0
- package/dist/components/time-range-field/time-range-field-compact.js +1 -0
- package/dist/components/time-range-field/time-range-field-compact.vue.d.ts +29 -0
- package/dist/components/time-range-field/time-range-field-input.js +1 -0
- package/dist/components/time-range-field/time-range-field-input.vue.d.ts +22 -0
- package/dist/components/time-range-field/time-range-field-root.js +1 -0
- package/dist/components/time-range-field/time-range-field-root.vue.d.ts +53 -0
- package/dist/components/time-range-field/types.d.ts +280 -0
- package/dist/components/time-range-picker/context.d.ts +9 -0
- package/dist/components/time-range-picker/context.js +1 -0
- package/dist/components/time-range-picker/index.d.ts +7 -0
- package/dist/components/time-range-picker/index.js +1 -0
- package/dist/components/time-range-picker/time-range-picker-compact.js +1 -0
- package/dist/components/time-range-picker/time-range-picker-compact.vue.d.ts +31 -0
- package/dist/components/time-range-picker/time-range-picker-popup.js +1 -0
- package/dist/components/time-range-picker/time-range-picker-popup.vue.d.ts +30 -0
- package/dist/components/time-range-picker/time-range-picker-root.js +1 -0
- package/dist/components/time-range-picker/time-range-picker-root.vue.d.ts +50 -0
- package/dist/components/time-range-picker/time-range-picker-trigger.js +1 -0
- package/dist/components/time-range-picker/time-range-picker-trigger.vue.d.ts +21 -0
- package/dist/components/time-range-picker/types.d.ts +304 -0
- package/dist/components/toast/shared.js +1 -1
- package/dist/components/toast/toaster.vue.d.ts +2 -2
- package/dist/components/toast/types.d.ts +224 -4
- package/dist/components/toggle/toggle.vue.d.ts +1 -1
- package/dist/components/toggle/types.d.ts +9 -0
- package/dist/components/toggle-group/types.d.ts +15 -0
- package/dist/components/toolbar/types.d.ts +48 -0
- package/dist/components/tooltip/index.js +1 -1
- package/dist/components/tooltip/tooltip-popup.js +1 -1
- package/dist/components/tooltip/tooltip-root.vue.d.ts +1 -1
- package/dist/components/tooltip/types.d.ts +27 -0
- package/dist/components/tree/types.d.ts +75 -0
- package/dist/components/tree-menu/tree-menu-root.vue.d.ts +1 -1
- package/dist/components/tree-menu/types.d.ts +60 -0
- package/dist/components/virtualizer/types.d.ts +33 -0
- package/dist/components/visually-hidden/types.d.ts +30 -0
- package/dist/components/year-picker/context.d.ts +9 -0
- package/dist/components/year-picker/context.js +1 -0
- package/dist/components/year-picker/index.d.ts +6 -0
- package/dist/components/year-picker/index.js +1 -0
- package/dist/components/year-picker/types.d.ts +207 -0
- package/dist/components/year-picker/year-picker-popup.js +1 -0
- package/dist/components/year-picker/year-picker-popup.vue.d.ts +36 -0
- package/dist/components/year-picker/year-picker-root.js +1 -0
- package/dist/components/year-picker/year-picker-root.vue.d.ts +39 -0
- package/dist/components/year-picker/year-picker-trigger.js +1 -0
- package/dist/components/year-picker/year-picker-trigger.vue.d.ts +21 -0
- package/dist/components/year-range-picker/context.d.ts +9 -0
- package/dist/components/year-range-picker/context.js +1 -0
- package/dist/components/year-range-picker/index.d.ts +6 -0
- package/dist/components/year-range-picker/index.js +1 -0
- package/dist/components/year-range-picker/types.d.ts +239 -0
- package/dist/components/year-range-picker/year-range-picker-popup.js +1 -0
- package/dist/components/year-range-picker/year-range-picker-popup.vue.d.ts +39 -0
- package/dist/components/year-range-picker/year-range-picker-root.js +1 -0
- package/dist/components/year-range-picker/year-range-picker-root.vue.d.ts +43 -0
- package/dist/components/year-range-picker/year-range-picker-trigger.js +1 -0
- package/dist/components/year-range-picker/year-range-picker-trigger.vue.d.ts +21 -0
- package/dist/composables/use-collection.js +1 -1
- package/dist/composables/use-hide-others.d.ts +2 -1
- package/dist/composables/use-hide-others.js +1 -1
- package/dist/constants/components.d.ts +19 -5
- package/dist/constants/components.js +1 -1
- package/dist/constants/index.d.ts +2 -1
- package/dist/constants/index.js +1 -1
- package/dist/{components/input-otp → constants}/regexp.d.ts +1 -1
- package/dist/date/comparators.d.ts +24 -14
- package/dist/date/comparators.js +1 -1
- package/dist/date/formatter.d.ts +27 -0
- package/dist/date/formatter.js +1 -0
- package/dist/date/index.d.ts +10 -4
- package/dist/date/index.js +1 -1
- package/dist/date/parser.d.ts +34 -0
- package/dist/date/parser.js +1 -0
- package/dist/date/parts.d.ts +15 -0
- package/dist/date/parts.js +1 -0
- package/dist/date/placeholders.d.ts +23 -0
- package/dist/date/placeholders.js +1 -0
- package/dist/date/segment.d.ts +7 -0
- package/dist/date/segment.js +1 -0
- package/dist/date/types.d.ts +34 -21
- package/dist/date/use-date-field.d.ts +50 -0
- package/dist/date/use-date-field.js +1 -0
- package/dist/date/utils.d.ts +15 -1
- package/dist/date/utils.js +1 -1
- package/dist/index.d.ts +460 -375
- package/dist/index.js +1 -1
- package/dist/namespaced/index.d.ts +884 -725
- package/dist/namespaced/index.js +1 -1
- package/dist/node_modules/.pnpm/@soybeanjs_utils@0.1.1/node_modules/@soybeanjs/utils/dist/index.js +1 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/Alignment.d.ts +4 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/Animations.d.ts +11 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/Axis.d.ts +16 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/Counter.d.ts +9 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/DragHandler.d.ts +13 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/DragTracker.d.ts +4 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/EmblaCarousel.d.ts +31 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/Engine.d.ts +67 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/EventHandler.d.ts +29 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/EventStore.d.ts +10 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/Limit.d.ts +13 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/NodeRects.d.ts +11 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/Options.d.ts +43 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/OptionsHandler.d.ts +11 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/PercentOfView.d.ts +6 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/Plugins.d.ts +20 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/ResizeHandler.d.ts +11 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/ScrollBody.d.ts +14 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/ScrollBounds.d.ts +8 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/ScrollContain.d.ts +4 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/ScrollLooper.d.ts +6 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/ScrollProgress.d.ts +6 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/ScrollTarget.d.ts +12 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/ScrollTo.d.ts +7 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/SlideFocus.d.ts +10 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/SlideLooper.d.ts +19 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/SlideRegistry.d.ts +6 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/SlidesHandler.d.ts +11 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/SlidesInView.d.ts +9 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/SlidesToScroll.d.ts +7 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/Translate.d.ts +8 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/Vector1d.d.ts +9 -0
- package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/components/utils.d.ts +4 -0
- package/dist/resolver/index.js +1 -1
- package/dist/shared/index.d.ts +3 -2
- package/dist/shared/index.js +1 -1
- package/dist/shared/string.d.ts +1 -34
- package/dist/shared/string.js +1 -1
- package/dist/shared/time-picker.d.ts +30 -0
- package/dist/shared/time-picker.js +1 -0
- package/dist/types/common.d.ts +9 -1
- package/dist/types/dom.d.ts +3 -1
- package/dist/types/event.d.ts +10 -1
- package/dist/types/index.d.ts +5 -4
- package/dist/types/index.js +0 -0
- package/dist/types/vue.d.ts +4 -1
- package/package.json +13 -8
- package/dist/components/autocomplete/autocomplete-anchor.js +0 -1
- package/dist/components/autocomplete/autocomplete-content.js +0 -1
- package/dist/components/autocomplete/autocomplete-content.vue.d.ts +0 -24
- package/dist/components/autocomplete/autocomplete-group-label.js +0 -1
- package/dist/components/autocomplete/autocomplete-group-label.vue.d.ts +0 -18
- package/dist/components/autocomplete/autocomplete-group.js +0 -1
- package/dist/components/autocomplete/autocomplete-group.vue.d.ts +0 -18
- package/dist/components/autocomplete/autocomplete-item-indicator.js +0 -1
- package/dist/components/autocomplete/autocomplete-item-indicator.vue.d.ts +0 -18
- package/dist/components/autocomplete/autocomplete-item.js +0 -1
- package/dist/components/autocomplete/autocomplete-item.vue.d.ts +0 -26
- package/dist/components/autocomplete/autocomplete-separator.js +0 -1
- package/dist/components/autocomplete/autocomplete-separator.vue.d.ts +0 -18
- package/dist/components/autocomplete/autocomplete-trigger.js +0 -1
- package/dist/components/autocomplete/autocomplete-viewport.js +0 -1
- package/dist/components/autocomplete/autocomplete-viewport.vue.d.ts +0 -18
- package/dist/components/combobox/combobox-anchor.js +0 -1
- package/dist/components/combobox/combobox-anchor.vue.d.ts +0 -18
- package/dist/components/combobox/combobox-group-label.js +0 -1
- package/dist/components/combobox/combobox-group-label.vue.d.ts +0 -18
- package/dist/components/combobox/combobox-item-indicator.js +0 -1
- package/dist/node_modules/.pnpm/@soybeanjs_utils@0.1.0/node_modules/@soybeanjs/utils/dist/index.js +0 -1
- /package/dist/{components/input-otp → constants}/regexp.js +0 -0
|
@@ -0,0 +1,528 @@
|
|
|
1
|
+
import { Direction, UiClass } from "../../types/common.js";
|
|
2
|
+
import { PropsToContext } from "../../types/vue.js";
|
|
3
|
+
import { PrimitiveProps } from "../primitive/types.js";
|
|
4
|
+
import { Grid, Matcher } from "../../date/types.js";
|
|
5
|
+
import { WeekDayFormat, WeekStartsOn } from "../../date/calendar.js";
|
|
6
|
+
import { Formatter } from "../../date/formatter.js";
|
|
7
|
+
import { SelectOptionData } from "../select/types.js";
|
|
8
|
+
import { ButtonHTMLAttributes, ComputedRef, HTMLAttributes, ShallowRef } from "vue";
|
|
9
|
+
import { DateValue } from "@internationalized/date";
|
|
10
|
+
|
|
11
|
+
//#region src/components/calendar/types.d.ts
|
|
12
|
+
/**
|
|
13
|
+
* Model value type for the calendar component.
|
|
14
|
+
*/
|
|
15
|
+
type CalendarModelValue<M extends boolean = false> = M extends true ? DateValue[] | undefined : DateValue | undefined;
|
|
16
|
+
/**
|
|
17
|
+
* Props for the calendar root component.
|
|
18
|
+
*/
|
|
19
|
+
interface CalendarRootProps<M extends boolean = false> extends PrimitiveProps, /** @vue-ignore */Omit<HTMLAttributes, 'placeholder'> {
|
|
20
|
+
/**
|
|
21
|
+
* Default value.
|
|
22
|
+
*/
|
|
23
|
+
defaultValue?: CalendarModelValue<M>;
|
|
24
|
+
/**
|
|
25
|
+
* Default placeholder.
|
|
26
|
+
*/
|
|
27
|
+
defaultPlaceholder?: DateValue;
|
|
28
|
+
/**
|
|
29
|
+
* Placeholder.
|
|
30
|
+
*/
|
|
31
|
+
placeholder?: DateValue;
|
|
32
|
+
/**
|
|
33
|
+
* Whether paged navigation.
|
|
34
|
+
*/
|
|
35
|
+
pagedNavigation?: boolean;
|
|
36
|
+
/**
|
|
37
|
+
* Whether prevent deselect.
|
|
38
|
+
*/
|
|
39
|
+
preventDeselect?: boolean;
|
|
40
|
+
/**
|
|
41
|
+
* Week starts on.
|
|
42
|
+
*/
|
|
43
|
+
weekStartsOn?: WeekStartsOn;
|
|
44
|
+
/**
|
|
45
|
+
* Weekday format.
|
|
46
|
+
*/
|
|
47
|
+
weekdayFormat?: WeekDayFormat;
|
|
48
|
+
/**
|
|
49
|
+
* Calendar label.
|
|
50
|
+
*/
|
|
51
|
+
calendarLabel?: string;
|
|
52
|
+
/**
|
|
53
|
+
* Whether fixed weeks.
|
|
54
|
+
*/
|
|
55
|
+
fixedWeeks?: boolean;
|
|
56
|
+
/**
|
|
57
|
+
* Max value.
|
|
58
|
+
*/
|
|
59
|
+
maxValue?: DateValue;
|
|
60
|
+
/**
|
|
61
|
+
* Min value.
|
|
62
|
+
*/
|
|
63
|
+
minValue?: DateValue;
|
|
64
|
+
/**
|
|
65
|
+
* Locale.
|
|
66
|
+
*/
|
|
67
|
+
locale?: string;
|
|
68
|
+
/**
|
|
69
|
+
* Number of months.
|
|
70
|
+
*/
|
|
71
|
+
numberOfMonths?: number;
|
|
72
|
+
/**
|
|
73
|
+
* Whether the component is disabled.
|
|
74
|
+
*/
|
|
75
|
+
disabled?: boolean;
|
|
76
|
+
/**
|
|
77
|
+
* Whether the component is readonly.
|
|
78
|
+
*/
|
|
79
|
+
readonly?: boolean;
|
|
80
|
+
/**
|
|
81
|
+
* Whether initial focus.
|
|
82
|
+
*/
|
|
83
|
+
initialFocus?: boolean;
|
|
84
|
+
/**
|
|
85
|
+
* Whether the date is disabled.
|
|
86
|
+
*/
|
|
87
|
+
isDateDisabled?: Matcher;
|
|
88
|
+
/**
|
|
89
|
+
* Whether the date is unavailable.
|
|
90
|
+
*/
|
|
91
|
+
isDateUnavailable?: Matcher;
|
|
92
|
+
/**
|
|
93
|
+
* Reading direction of the component.
|
|
94
|
+
*/
|
|
95
|
+
dir?: Direction;
|
|
96
|
+
/**
|
|
97
|
+
* Next page.
|
|
98
|
+
*/
|
|
99
|
+
nextPage?: (placeholder: DateValue) => DateValue;
|
|
100
|
+
/**
|
|
101
|
+
* Prev page.
|
|
102
|
+
*/
|
|
103
|
+
prevPage?: (placeholder: DateValue) => DateValue;
|
|
104
|
+
/**
|
|
105
|
+
* Current model value.
|
|
106
|
+
*/
|
|
107
|
+
modelValue?: CalendarModelValue<M>;
|
|
108
|
+
/**
|
|
109
|
+
* Whether multiple values are supported.
|
|
110
|
+
*/
|
|
111
|
+
multiple?: M;
|
|
112
|
+
/**
|
|
113
|
+
* Whether to disable days outside current view.
|
|
114
|
+
*/
|
|
115
|
+
disableDaysOutsideCurrentView?: boolean;
|
|
116
|
+
}
|
|
117
|
+
/**
|
|
118
|
+
* Emits for the calendar root component.
|
|
119
|
+
*/
|
|
120
|
+
type CalendarRootEmits<M extends boolean = false> = {
|
|
121
|
+
/**
|
|
122
|
+
* Emitted when the model value changes.
|
|
123
|
+
*/
|
|
124
|
+
'update:modelValue': [date: CalendarModelValue<M>];
|
|
125
|
+
/**
|
|
126
|
+
* Emitted when the placeholder value changes.
|
|
127
|
+
*/
|
|
128
|
+
'update:placeholder': [date: DateValue];
|
|
129
|
+
};
|
|
130
|
+
/**
|
|
131
|
+
* Props for the calendar header component.
|
|
132
|
+
*/
|
|
133
|
+
interface CalendarHeaderProps extends PrimitiveProps, /** @vue-ignore */Omit<HTMLAttributes, 'placeholder'> {}
|
|
134
|
+
/**
|
|
135
|
+
* Props for the calendar heading component.
|
|
136
|
+
*/
|
|
137
|
+
interface CalendarHeadingProps extends PrimitiveProps, /** @vue-ignore */Omit<HTMLAttributes, 'placeholder'> {}
|
|
138
|
+
/**
|
|
139
|
+
* Props for the calendar grid component.
|
|
140
|
+
*/
|
|
141
|
+
interface CalendarGridProps extends PrimitiveProps, /** @vue-ignore */Omit<HTMLAttributes, 'placeholder'> {}
|
|
142
|
+
/**
|
|
143
|
+
* Props for the calendar grid head component.
|
|
144
|
+
*/
|
|
145
|
+
interface CalendarGridHeadProps extends PrimitiveProps, /** @vue-ignore */Omit<HTMLAttributes, 'placeholder'> {}
|
|
146
|
+
/**
|
|
147
|
+
* Props for the calendar grid body component.
|
|
148
|
+
*/
|
|
149
|
+
interface CalendarGridBodyProps extends PrimitiveProps, /** @vue-ignore */Omit<HTMLAttributes, 'placeholder'> {}
|
|
150
|
+
/**
|
|
151
|
+
* Props for the calendar grid row component.
|
|
152
|
+
*/
|
|
153
|
+
interface CalendarGridRowProps extends PrimitiveProps, /** @vue-ignore */Omit<HTMLAttributes, 'placeholder'> {}
|
|
154
|
+
/**
|
|
155
|
+
* Props for the calendar head cell component.
|
|
156
|
+
*/
|
|
157
|
+
interface CalendarHeadCellProps extends PrimitiveProps, /** @vue-ignore */Omit<HTMLAttributes, 'placeholder'> {}
|
|
158
|
+
/**
|
|
159
|
+
* Props for the calendar cell component.
|
|
160
|
+
*/
|
|
161
|
+
interface CalendarCellProps extends PrimitiveProps, /** @vue-ignore */Omit<HTMLAttributes, 'placeholder'> {
|
|
162
|
+
/**
|
|
163
|
+
* Date.
|
|
164
|
+
*/
|
|
165
|
+
date: DateValue;
|
|
166
|
+
}
|
|
167
|
+
/**
|
|
168
|
+
* Props for the calendar cell trigger component.
|
|
169
|
+
*/
|
|
170
|
+
interface CalendarCellTriggerProps extends PrimitiveProps, /** @vue-ignore */Omit<HTMLAttributes, 'placeholder'> {
|
|
171
|
+
/**
|
|
172
|
+
* Day.
|
|
173
|
+
*/
|
|
174
|
+
day: DateValue;
|
|
175
|
+
/**
|
|
176
|
+
* Month.
|
|
177
|
+
*/
|
|
178
|
+
month: DateValue;
|
|
179
|
+
}
|
|
180
|
+
/**
|
|
181
|
+
* Props for the calendar prev component.
|
|
182
|
+
*/
|
|
183
|
+
interface CalendarPrevProps extends PrimitiveProps, /** @vue-ignore */ButtonHTMLAttributes {
|
|
184
|
+
/**
|
|
185
|
+
* Prev page.
|
|
186
|
+
*/
|
|
187
|
+
prevPage?: (placeholder: DateValue) => DateValue;
|
|
188
|
+
}
|
|
189
|
+
/**
|
|
190
|
+
* Props for the calendar next component.
|
|
191
|
+
*/
|
|
192
|
+
interface CalendarNextProps extends PrimitiveProps, /** @vue-ignore */ButtonHTMLAttributes {
|
|
193
|
+
/**
|
|
194
|
+
* Next page.
|
|
195
|
+
*/
|
|
196
|
+
nextPage?: (placeholder: DateValue) => DateValue;
|
|
197
|
+
}
|
|
198
|
+
/**
|
|
199
|
+
* Context for the calendar root component.
|
|
200
|
+
*/
|
|
201
|
+
interface CalendarRootContext extends PropsToContext<CalendarRootProps, 'disableDaysOutsideCurrentView' | 'disabled' | 'fixedWeeks' | 'initialFocus' | 'numberOfMonths' | 'pagedNavigation' | 'preventDeselect' | 'readonly'> {
|
|
202
|
+
/**
|
|
203
|
+
* Locale used by the component context.
|
|
204
|
+
*/
|
|
205
|
+
locale: ComputedRef<string>;
|
|
206
|
+
/**
|
|
207
|
+
* Reading direction of the component.
|
|
208
|
+
*/
|
|
209
|
+
dir: ComputedRef<Direction>;
|
|
210
|
+
/**
|
|
211
|
+
* Week starts on used by the component context.
|
|
212
|
+
*/
|
|
213
|
+
weekStartsOn: ComputedRef<WeekStartsOn>;
|
|
214
|
+
/**
|
|
215
|
+
* Weekday format used by the component context.
|
|
216
|
+
*/
|
|
217
|
+
weekdayFormat: ComputedRef<WeekDayFormat>;
|
|
218
|
+
/**
|
|
219
|
+
* Current model value.
|
|
220
|
+
*/
|
|
221
|
+
modelValue: ShallowRef<DateValue | DateValue[] | undefined>;
|
|
222
|
+
/**
|
|
223
|
+
* Whether multiple values are supported.
|
|
224
|
+
*/
|
|
225
|
+
multiple: ComputedRef<boolean>;
|
|
226
|
+
/**
|
|
227
|
+
* Placeholder used by the component context.
|
|
228
|
+
*/
|
|
229
|
+
placeholder: ShallowRef<DateValue>;
|
|
230
|
+
/**
|
|
231
|
+
* Grid used by the component context.
|
|
232
|
+
*/
|
|
233
|
+
grid: ShallowRef<Grid<DateValue>[]>;
|
|
234
|
+
/**
|
|
235
|
+
* Parent element used by the component context.
|
|
236
|
+
*/
|
|
237
|
+
parentElement: ShallowRef<HTMLElement | undefined>;
|
|
238
|
+
/**
|
|
239
|
+
* Full calendar label used by the component context.
|
|
240
|
+
*/
|
|
241
|
+
fullCalendarLabel: ComputedRef<string>;
|
|
242
|
+
/**
|
|
243
|
+
* Heading value used by the component context.
|
|
244
|
+
*/
|
|
245
|
+
headingValue: ComputedRef<string>;
|
|
246
|
+
/**
|
|
247
|
+
* Whether the current value is invalid.
|
|
248
|
+
*/
|
|
249
|
+
isInvalid: ComputedRef<boolean>;
|
|
250
|
+
/**
|
|
251
|
+
* Min value used by the component context.
|
|
252
|
+
*/
|
|
253
|
+
minValue: ComputedRef<DateValue | undefined>;
|
|
254
|
+
/**
|
|
255
|
+
* Max value used by the component context.
|
|
256
|
+
*/
|
|
257
|
+
maxValue: ComputedRef<DateValue | undefined>;
|
|
258
|
+
/**
|
|
259
|
+
* Whether the placeholder is focusable.
|
|
260
|
+
*/
|
|
261
|
+
isPlaceholderFocusable: ComputedRef<boolean>;
|
|
262
|
+
/**
|
|
263
|
+
* First focusable date used by the component context.
|
|
264
|
+
*/
|
|
265
|
+
firstFocusableDate: ComputedRef<DateValue | undefined>;
|
|
266
|
+
/**
|
|
267
|
+
* Whether the component has selected date.
|
|
268
|
+
*/
|
|
269
|
+
hasSelectedDate: ComputedRef<boolean>;
|
|
270
|
+
/**
|
|
271
|
+
* Whether the selected date is disabled.
|
|
272
|
+
*/
|
|
273
|
+
isSelectedDateDisabled: ComputedRef<boolean>;
|
|
274
|
+
/**
|
|
275
|
+
* Formatter used by the component context.
|
|
276
|
+
*/
|
|
277
|
+
formatter: Formatter;
|
|
278
|
+
/**
|
|
279
|
+
* Callback invoked when the date changes.
|
|
280
|
+
*/
|
|
281
|
+
onDateChange: (date: DateValue) => void;
|
|
282
|
+
/**
|
|
283
|
+
* Callback invoked when the placeholder changes.
|
|
284
|
+
*/
|
|
285
|
+
onPlaceholderChange: (date: DateValue) => void;
|
|
286
|
+
/**
|
|
287
|
+
* Whether the date is disabled.
|
|
288
|
+
*/
|
|
289
|
+
isDateDisabled: Matcher;
|
|
290
|
+
/**
|
|
291
|
+
* Whether the date is selected.
|
|
292
|
+
*/
|
|
293
|
+
isDateSelected: Matcher;
|
|
294
|
+
/**
|
|
295
|
+
* Whether the date is unavailable.
|
|
296
|
+
*/
|
|
297
|
+
isDateUnavailable?: Matcher;
|
|
298
|
+
/**
|
|
299
|
+
* Whether an outside visible view.
|
|
300
|
+
*/
|
|
301
|
+
isOutsideVisibleView: (date: DateValue) => boolean;
|
|
302
|
+
/**
|
|
303
|
+
* Prev page used by the component context.
|
|
304
|
+
*/
|
|
305
|
+
prevPage: (prevPageFunc?: (date: DateValue) => DateValue) => void;
|
|
306
|
+
/**
|
|
307
|
+
* Next page used by the component context.
|
|
308
|
+
*/
|
|
309
|
+
nextPage: (nextPageFunc?: (date: DateValue) => DateValue) => void;
|
|
310
|
+
/**
|
|
311
|
+
* Whether the previous button is disabled.
|
|
312
|
+
*/
|
|
313
|
+
isPrevButtonDisabled: (prevPageFunc?: (date: DateValue) => DateValue) => boolean;
|
|
314
|
+
/**
|
|
315
|
+
* Whether the next button is disabled.
|
|
316
|
+
*/
|
|
317
|
+
isNextButtonDisabled: (nextPageFunc?: (date: DateValue) => DateValue) => boolean;
|
|
318
|
+
}
|
|
319
|
+
/**
|
|
320
|
+
* Slot props for the calendar root component.
|
|
321
|
+
*/
|
|
322
|
+
interface CalendarRootSlotProps<M extends boolean = false> {
|
|
323
|
+
/**
|
|
324
|
+
* Date exposed in the slot scope.
|
|
325
|
+
*/
|
|
326
|
+
date: DateValue;
|
|
327
|
+
/**
|
|
328
|
+
* Placeholder exposed in the slot scope.
|
|
329
|
+
*/
|
|
330
|
+
placeholder: DateValue;
|
|
331
|
+
/**
|
|
332
|
+
* Grid exposed in the slot scope.
|
|
333
|
+
*/
|
|
334
|
+
grid: Grid<DateValue>[];
|
|
335
|
+
/**
|
|
336
|
+
* Week days exposed in the slot scope.
|
|
337
|
+
*/
|
|
338
|
+
weekDays: string[];
|
|
339
|
+
/**
|
|
340
|
+
* Week starts on exposed in the slot scope.
|
|
341
|
+
*/
|
|
342
|
+
weekStartsOn: number;
|
|
343
|
+
/**
|
|
344
|
+
* Locale exposed in the slot scope.
|
|
345
|
+
*/
|
|
346
|
+
locale: string;
|
|
347
|
+
/**
|
|
348
|
+
* Whether fixed weeks.
|
|
349
|
+
*/
|
|
350
|
+
fixedWeeks: boolean;
|
|
351
|
+
/**
|
|
352
|
+
* Current model value.
|
|
353
|
+
*/
|
|
354
|
+
modelValue: CalendarModelValue<M>;
|
|
355
|
+
/**
|
|
356
|
+
* Formatter exposed in the slot scope.
|
|
357
|
+
*/
|
|
358
|
+
formatter: Formatter;
|
|
359
|
+
/**
|
|
360
|
+
* Min value exposed in the slot scope.
|
|
361
|
+
*/
|
|
362
|
+
minValue: DateValue | undefined;
|
|
363
|
+
/**
|
|
364
|
+
* Max value exposed in the slot scope.
|
|
365
|
+
*/
|
|
366
|
+
maxValue: DateValue | undefined;
|
|
367
|
+
/**
|
|
368
|
+
* Whether the component is disabled.
|
|
369
|
+
*/
|
|
370
|
+
disabled: boolean;
|
|
371
|
+
/**
|
|
372
|
+
* Callback invoked when the placeholder changes.
|
|
373
|
+
*/
|
|
374
|
+
onPlaceholderChange: (date: DateValue) => void;
|
|
375
|
+
}
|
|
376
|
+
/**
|
|
377
|
+
* Slot props for the calendar heading component.
|
|
378
|
+
*/
|
|
379
|
+
interface CalendarHeadingSlotProps {
|
|
380
|
+
/**
|
|
381
|
+
* Heading value exposed in the slot scope.
|
|
382
|
+
*/
|
|
383
|
+
headingValue: string;
|
|
384
|
+
/**
|
|
385
|
+
* Month value exposed in the slot scope.
|
|
386
|
+
*/
|
|
387
|
+
monthValue: string;
|
|
388
|
+
/**
|
|
389
|
+
* Year value exposed in the slot scope.
|
|
390
|
+
*/
|
|
391
|
+
yearValue: string;
|
|
392
|
+
/**
|
|
393
|
+
* Selected month exposed in the slot scope.
|
|
394
|
+
*/
|
|
395
|
+
selectedMonth: number;
|
|
396
|
+
/**
|
|
397
|
+
* Selected year exposed in the slot scope.
|
|
398
|
+
*/
|
|
399
|
+
selectedYear: number;
|
|
400
|
+
/**
|
|
401
|
+
* Month options exposed in the slot scope.
|
|
402
|
+
*/
|
|
403
|
+
monthOptions: SelectOptionData<number>[];
|
|
404
|
+
/**
|
|
405
|
+
* Year options exposed in the slot scope.
|
|
406
|
+
*/
|
|
407
|
+
yearOptions: SelectOptionData<number>[];
|
|
408
|
+
/**
|
|
409
|
+
* Callback invoked when the month changes.
|
|
410
|
+
*/
|
|
411
|
+
onMonthChange: (value: number | undefined) => void;
|
|
412
|
+
/**
|
|
413
|
+
* Callback invoked when the year changes.
|
|
414
|
+
*/
|
|
415
|
+
onYearChange: (value: number | undefined) => void;
|
|
416
|
+
}
|
|
417
|
+
/**
|
|
418
|
+
* Available UI slots for the calendar component.
|
|
419
|
+
*/
|
|
420
|
+
type CalendarUiSlot = 'root' | 'header' | 'heading' | 'prev' | 'next' | 'grid' | 'gridHead' | 'gridBody' | 'gridRow' | 'headCell' | 'cell' | 'cellTrigger';
|
|
421
|
+
/**
|
|
422
|
+
* UI class overrides for the calendar component.
|
|
423
|
+
*/
|
|
424
|
+
type CalendarUi = UiClass<CalendarUiSlot>;
|
|
425
|
+
/**
|
|
426
|
+
* Props for the calendar compact component.
|
|
427
|
+
*/
|
|
428
|
+
interface CalendarCompactProps<M extends boolean = false> extends CalendarRootProps<M> {
|
|
429
|
+
/**
|
|
430
|
+
* Props forwarded to the header element.
|
|
431
|
+
*/
|
|
432
|
+
headerProps?: CalendarHeaderProps;
|
|
433
|
+
/**
|
|
434
|
+
* Props forwarded to the heading element.
|
|
435
|
+
*/
|
|
436
|
+
headingProps?: CalendarHeadingProps;
|
|
437
|
+
/**
|
|
438
|
+
* Props forwarded to the prev element.
|
|
439
|
+
*/
|
|
440
|
+
prevProps?: CalendarPrevProps;
|
|
441
|
+
/**
|
|
442
|
+
* Props forwarded to the next element.
|
|
443
|
+
*/
|
|
444
|
+
nextProps?: CalendarNextProps;
|
|
445
|
+
/**
|
|
446
|
+
* Props forwarded to the grid element.
|
|
447
|
+
*/
|
|
448
|
+
gridProps?: CalendarGridProps;
|
|
449
|
+
/**
|
|
450
|
+
* Props forwarded to the grid head element.
|
|
451
|
+
*/
|
|
452
|
+
gridHeadProps?: CalendarGridHeadProps;
|
|
453
|
+
/**
|
|
454
|
+
* Props forwarded to the grid body element.
|
|
455
|
+
*/
|
|
456
|
+
gridBodyProps?: CalendarGridBodyProps;
|
|
457
|
+
/**
|
|
458
|
+
* Props forwarded to the grid row element.
|
|
459
|
+
*/
|
|
460
|
+
gridRowProps?: CalendarGridRowProps;
|
|
461
|
+
/**
|
|
462
|
+
* Props forwarded to the head cell element.
|
|
463
|
+
*/
|
|
464
|
+
headCellProps?: CalendarHeadCellProps;
|
|
465
|
+
/**
|
|
466
|
+
* Props forwarded to the cell element.
|
|
467
|
+
*/
|
|
468
|
+
cellProps?: Omit<CalendarCellProps, 'date'>;
|
|
469
|
+
/**
|
|
470
|
+
* Props forwarded to the cell trigger element.
|
|
471
|
+
*/
|
|
472
|
+
cellTriggerProps?: Omit<CalendarCellTriggerProps, 'day' | 'month'>;
|
|
473
|
+
}
|
|
474
|
+
/**
|
|
475
|
+
* Emits for the calendar compact component.
|
|
476
|
+
*/
|
|
477
|
+
type CalendarCompactEmits<M extends boolean = false> = CalendarRootEmits<M>;
|
|
478
|
+
/**
|
|
479
|
+
* Slots for the calendar compact component.
|
|
480
|
+
*/
|
|
481
|
+
type CalendarCompactSlots<M extends boolean = false> = {
|
|
482
|
+
/**
|
|
483
|
+
* Custom content for the default slot.
|
|
484
|
+
*/
|
|
485
|
+
default?: (props: {
|
|
486
|
+
modelValue: CalendarModelValue<M>;
|
|
487
|
+
}) => any;
|
|
488
|
+
/**
|
|
489
|
+
* Custom content for the prev slot.
|
|
490
|
+
*/
|
|
491
|
+
prev?: (props: {
|
|
492
|
+
disabled: boolean;
|
|
493
|
+
}) => any;
|
|
494
|
+
/**
|
|
495
|
+
* Custom content for the heading slot.
|
|
496
|
+
*/
|
|
497
|
+
heading?: (props: CalendarHeadingSlotProps) => any;
|
|
498
|
+
/**
|
|
499
|
+
* Custom content for the next slot.
|
|
500
|
+
*/
|
|
501
|
+
next?: (props: {
|
|
502
|
+
disabled: boolean;
|
|
503
|
+
}) => any;
|
|
504
|
+
/**
|
|
505
|
+
* Custom content for the head cell slot.
|
|
506
|
+
*/
|
|
507
|
+
'head-cell'?: (props: {
|
|
508
|
+
date: DateValue;
|
|
509
|
+
index: number;
|
|
510
|
+
label: string;
|
|
511
|
+
}) => any;
|
|
512
|
+
/**
|
|
513
|
+
* Custom content for the day slot.
|
|
514
|
+
*/
|
|
515
|
+
day?: (props: {
|
|
516
|
+
day: DateValue;
|
|
517
|
+
month: DateValue;
|
|
518
|
+
dayValue: string;
|
|
519
|
+
disabled: boolean;
|
|
520
|
+
selected: boolean;
|
|
521
|
+
unavailable: boolean;
|
|
522
|
+
today: boolean;
|
|
523
|
+
outsideView: boolean;
|
|
524
|
+
outsideVisibleView: boolean;
|
|
525
|
+
}) => any;
|
|
526
|
+
};
|
|
527
|
+
//#endregion
|
|
528
|
+
export { CalendarCellProps, CalendarCellTriggerProps, CalendarCompactEmits, CalendarCompactProps, CalendarCompactSlots, CalendarGridBodyProps, CalendarGridHeadProps, CalendarGridProps, CalendarGridRowProps, CalendarHeadCellProps, CalendarHeaderProps, CalendarHeadingProps, CalendarHeadingSlotProps, CalendarModelValue, CalendarNextProps, CalendarPrevProps, CalendarRootContext, CalendarRootEmits, CalendarRootProps, CalendarRootSlotProps, CalendarUi, CalendarUiSlot };
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import { Grid, Matcher } from "../../date/types.js";
|
|
2
|
+
import { WeekDayFormat, WeekStartsOn } from "../../date/calendar.js";
|
|
3
|
+
import { Formatter } from "../../date/formatter.js";
|
|
4
|
+
import * as _$vue from "vue";
|
|
5
|
+
import { Ref, ShallowRef } from "vue";
|
|
6
|
+
import * as _$_internationalized_date0 from "@internationalized/date";
|
|
7
|
+
import { DateValue } from "@internationalized/date";
|
|
8
|
+
|
|
9
|
+
//#region src/components/calendar/use-calendar.d.ts
|
|
10
|
+
interface UseCalendarProps {
|
|
11
|
+
locale: Ref<string>;
|
|
12
|
+
placeholder: ShallowRef<DateValue>;
|
|
13
|
+
weekStartsOn: Ref<WeekStartsOn>;
|
|
14
|
+
fixedWeeks: Ref<boolean>;
|
|
15
|
+
numberOfMonths: Ref<number>;
|
|
16
|
+
minValue: Ref<DateValue | undefined>;
|
|
17
|
+
maxValue: Ref<DateValue | undefined>;
|
|
18
|
+
disabled: Ref<boolean>;
|
|
19
|
+
weekdayFormat: Ref<WeekDayFormat>;
|
|
20
|
+
pagedNavigation: Ref<boolean>;
|
|
21
|
+
isDateDisabled?: Matcher;
|
|
22
|
+
isDateUnavailable?: Matcher;
|
|
23
|
+
calendarLabel: Ref<string | undefined>;
|
|
24
|
+
nextPage: Ref<((placeholder: DateValue) => DateValue) | undefined>;
|
|
25
|
+
prevPage: Ref<((placeholder: DateValue) => DateValue) | undefined>;
|
|
26
|
+
}
|
|
27
|
+
declare function useCalendar(props: UseCalendarProps): {
|
|
28
|
+
isDateDisabled: (dateObj: DateValue) => boolean;
|
|
29
|
+
isDateUnavailable: (date: DateValue) => boolean;
|
|
30
|
+
isNextButtonDisabled: (nextPageFunc?: (date: DateValue) => DateValue) => boolean;
|
|
31
|
+
isPrevButtonDisabled: (prevPageFunc?: (date: DateValue) => DateValue) => boolean;
|
|
32
|
+
grid: ShallowRef<Grid<DateValue>[], Grid<DateValue>[]>;
|
|
33
|
+
weekdays: _$vue.ComputedRef<string[]>;
|
|
34
|
+
visibleView: _$vue.ComputedRef<DateValue[]>;
|
|
35
|
+
isOutsideVisibleView: (date: DateValue) => boolean;
|
|
36
|
+
formatter: Formatter;
|
|
37
|
+
nextPage: (nextPageFunc?: (date: DateValue) => DateValue) => void;
|
|
38
|
+
prevPage: (prevPageFunc?: (date: DateValue) => DateValue) => void;
|
|
39
|
+
headingValue: _$vue.ComputedRef<string>;
|
|
40
|
+
fullCalendarLabel: _$vue.ComputedRef<string>;
|
|
41
|
+
isPlaceholderFocusable: _$vue.ComputedRef<boolean>;
|
|
42
|
+
firstFocusableDate: _$vue.ComputedRef<_$_internationalized_date0.CalendarDate | _$_internationalized_date0.CalendarDateTime | _$_internationalized_date0.ZonedDateTime | undefined>;
|
|
43
|
+
};
|
|
44
|
+
//#endregion
|
|
45
|
+
export { useCalendar };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{getDaysInMonth as e,isAfter as t,isBefore as n,toDate as r}from"../../date/comparators.js";import{createMonths as i}from"../../date/calendar.js";import{useDateFormatter as a}from"../../date/formatter.js";import"../../date/index.js";import{computed as o,shallowRef as s,watch as c}from"vue";import{isEqualMonth as l,isSameDay as u,isSameMonth as d}from"@internationalized/date";function f(e){function t(t){return Array.isArray(e.date.value)?e.date.value.some(e=>u(e,t)):e.date.value?u(e.date.value,t):!1}return{isDateSelected:t,isInvalid:o(()=>Array.isArray(e.date.value)?e.date.value.length?e.date.value.some(t=>e.isDateDisabled?.(t)||e.isDateUnavailable?.(t)):!1:e.date.value?!!(e.isDateDisabled?.(e.date.value)||e.isDateUnavailable?.(e.date.value)):!1),hasSelectedDate:o(()=>Array.isArray(e.date.value)?e.date.value.length>0:!!e.date.value),isSelectedDateDisabled:o(()=>Array.isArray(e.date.value)?e.date.value.length?e.date.value.some(t=>e.isDateDisabled?.(t)):!1:e.date.value?!!e.isDateDisabled?.(e.date.value):!1)}}function p(t,n){let r=n(t),i=r.compare(t),a={};return i>=7&&(a.day=1),i>=e(t)&&(a.month=1),r.set({...a})}function m(t,n){let r=n(t),i=t.compare(r),a={};return i>=7&&(a.day=35),i>=e(t)&&(a.month=13),r.set({...a})}function h(u){let f=a(u.locale.value),h=o(()=>{let e={calendar:u.placeholder.value.calendar.identifier};return u.placeholder.value.calendar.identifier===`gregory`&&u.placeholder.value.era===`BC`&&(e.era=`short`),e}),g=s(i({dateObj:u.placeholder.value,weekStartsOn:u.weekStartsOn.value,locale:u.locale.value,fixedWeeks:u.fixedWeeks.value,numberOfMonths:u.numberOfMonths.value})),_=o(()=>g.value.map(e=>e.value));function v(e){return!_.value.some(t=>l(e,t))}let y=e=>{if(!u.maxValue.value||!g.value.length)return!1;if(u.disabled.value)return!0;let n=g.value.at(-1).value;return!e&&!u.nextPage.value?t(n.add({months:1}).set({day:1}),u.maxValue.value):t(p(n,e||u.nextPage.value),u.maxValue.value)},b=e=>{if(!u.minValue.value||!g.value.length)return!1;if(u.disabled.value)return!0;let t=g.value[0].value;return!e&&!u.prevPage.value?n(t.subtract({months:1}).set({day:35}),u.minValue.value):n(m(t,e||u.prevPage.value),u.minValue.value)};function x(e){return!!(u.isDateDisabled?.(e)||u.disabled.value||u.maxValue.value&&t(e,u.maxValue.value)||u.minValue.value&&n(e,u.minValue.value))}let S=e=>!!u.isDateUnavailable?.(e),C=o(()=>g.value.length?g.value[0].rows[0].map(e=>f.dayOfWeek(r(e),u.weekdayFormat.value)):[]),w=t=>{let n=g.value[0].value;if(!t&&!u.nextPage.value){let e=i({dateObj:n.add({months:u.pagedNavigation.value?u.numberOfMonths.value:1}),weekStartsOn:u.weekStartsOn.value,locale:u.locale.value,fixedWeeks:u.fixedWeeks.value,numberOfMonths:u.numberOfMonths.value});g.value=e,u.placeholder.value=e[0].value.set({day:1});return}let r=i({dateObj:(t||u.nextPage.value)(n),weekStartsOn:u.weekStartsOn.value,locale:u.locale.value,fixedWeeks:u.fixedWeeks.value,numberOfMonths:u.numberOfMonths.value});g.value=r;let a={};if(!t){let t=r[0].value.compare(n);t>=e(n)&&(a.day=1),t>=365&&(a.month=1)}u.placeholder.value=r[0].value.set({...a})},T=t=>{let n=g.value[0].value;if(!t&&!u.prevPage.value){let e=i({dateObj:n.subtract({months:u.pagedNavigation.value?u.numberOfMonths.value:1}),weekStartsOn:u.weekStartsOn.value,locale:u.locale.value,fixedWeeks:u.fixedWeeks.value,numberOfMonths:u.numberOfMonths.value});g.value=e,u.placeholder.value=e[0].value.set({day:1});return}let r=i({dateObj:(t||u.prevPage.value)(n),weekStartsOn:u.weekStartsOn.value,locale:u.locale.value,fixedWeeks:u.fixedWeeks.value,numberOfMonths:u.numberOfMonths.value});g.value=r;let a={};if(!t){let t=n.compare(r[0].value);t>=e(n)&&(a.day=1),t>=365&&(a.month=1)}u.placeholder.value=r[0].value.set({...a})};c(u.placeholder,e=>{_.value.some(t=>l(t,e))||(g.value=i({dateObj:e,weekStartsOn:u.weekStartsOn.value,locale:u.locale.value,fixedWeeks:u.fixedWeeks.value,numberOfMonths:u.numberOfMonths.value}))}),c([u.locale,u.weekStartsOn,u.fixedWeeks,u.numberOfMonths],()=>{g.value=i({dateObj:u.placeholder.value,weekStartsOn:u.weekStartsOn.value,locale:u.locale.value,fixedWeeks:u.fixedWeeks.value,numberOfMonths:u.numberOfMonths.value})});let E=o(()=>{if(!g.value.length)return``;if(u.locale.value!==f.getLocale()&&f.setLocale(u.locale.value),g.value.length===1)return f.fullMonthAndYear(r(g.value[0].value),h.value);let e=r(g.value[0].value),t=r(g.value.at(-1).value),n=f.fullMonth(e,h.value),i=f.fullMonth(t,h.value),a=f.fullYear(e,h.value),o=f.fullYear(t,h.value);return a===o?`${n} - ${i} ${o}`:`${n} ${a} - ${i} ${o}`});return{isDateDisabled:x,isDateUnavailable:S,isNextButtonDisabled:y,isPrevButtonDisabled:b,grid:g,weekdays:C,visibleView:_,isOutsideVisibleView:v,formatter:f,nextPage:w,prevPage:T,headingValue:E,fullCalendarLabel:o(()=>`${u.calendarLabel.value??`Event Date`}, ${E.value}`),isPlaceholderFocusable:o(()=>!(x(u.placeholder.value)||S(u.placeholder.value)||v(u.placeholder.value))),firstFocusableDate:o(()=>{for(let t of g.value){if(u.minValue.value&&n(t.value,u.minValue.value))continue;let r=e(t.value),i=u.minValue.value&&d(u.minValue.value,t.value)?u.minValue.value.day:1;for(let e=i;e<=r;e+=1){let n=t.value.set({day:e});if(!(x(n)||S(n)))return n}}})}}export{h as useCalendar,f as useCalendarState};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{useForwardListeners as e}from"../../composables/use-forward-listeners.js";import{useOmitProps as t}from"../../composables/use-props.js";import"../../composables/index.js";import n from"./card-root.js";import r from"./card-header.js";import i from"./card-title.js";import a from"./card-title-root.js";import o from"./card-description.js";import s from"./card-content.js";import c from"./card-footer.js";import{computed as l,createBlock as u,createCommentVNode as d,createTextVNode as f,createVNode as p,defineComponent as m,guardReactiveProps as h,mergeProps as g,normalizeProps as _,openBlock as v,renderSlot as y,toDisplayString as b,toHandlers as x,unref as S,useSlots as C,withCtx as w}from"vue";const T=m({name:`CardCompact`,__name:`card-compact`,props:{title:{},description:{},headerProps:{},contentProps:{},footerProps:{},titleRootProps:{},titleProps:{},descriptionProps:{},defaultOpen:{type:Boolean},open:{type:Boolean},disabled:{type:Boolean},unmountOnHide:{type:Boolean},asChild:{type:Boolean},as:{}},emits:[`update:open`],setup(m,{emit:T}){let E=m,D=T,O=C(),k=t(E,[`title`,`description`,`headerProps`,`contentProps`,`footerProps`,`titleRootProps`,`titleProps`,`descriptionProps`]),A=e(D),j=l(()=>!!(O.header||O.title||O.description||O.extra||E.title||E.description));return(e,t)=>(v(),u(n,g(S(k),x(S(A))),{default:w(()=>[j.value?(v(),u(r,_(g({key:0},m.headerProps)),{default:w(()=>[y(e.$slots,`header`,{},()=>[p(a,_(h(m.titleRootProps)),{default:w(()=>[y(e.$slots,`title-leading`),p(i,_(h(m.titleProps)),{default:w(()=>[y(e.$slots,`title`,{},()=>[f(b(m.title),1)])]),_:3},16),y(e.$slots,`title-trailing`)]),_:3},16),y(e.$slots,`extra`),O.description||m.description?(v(),u(o,_(g({key:0},m.descriptionProps)),{default:w(()=>[y(e.$slots,`description`,{},()=>[f(b(m.description),1)])]),_:3},16)):d(`v-if`,!0)])]),_:3},16)):d(`v-if`,!0),p(s,_(h(m.contentProps)),{default:w(()=>[y(e.$slots,`default`)]),_:3},16),O.footer?(v(),u(c,_(g({key:1},m.footerProps)),{default:w(()=>[y(e.$slots,`footer`)]),_:3},16)):d(`v-if`,!0)]),_:3},16))}});export{T as default};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { CardCompactProps, CardCompactSlots } from "./types.js";
|
|
2
|
+
import * as _$vue from "vue";
|
|
3
|
+
|
|
4
|
+
//#region src/components/card/card-compact.vue.d.ts
|
|
5
|
+
type __VLS_Slots = CardCompactSlots;
|
|
6
|
+
declare const __VLS_base: _$vue.DefineComponent<CardCompactProps, {}, {}, {}, {}, _$vue.ComponentOptionsMixin, _$vue.ComponentOptionsMixin, {
|
|
7
|
+
"update:open": (value: boolean) => any;
|
|
8
|
+
}, string, _$vue.PublicProps, Readonly<CardCompactProps> & Readonly<{
|
|
9
|
+
"onUpdate:open"?: ((value: boolean) => any) | undefined;
|
|
10
|
+
}>, {}, {}, {}, {}, string, _$vue.ComponentProvideOptions, false, {}, any>;
|
|
11
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
12
|
+
declare const _default: typeof __VLS_export;
|
|
13
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
14
|
+
new (): {
|
|
15
|
+
$slots: S;
|
|
16
|
+
};
|
|
17
|
+
};
|
|
18
|
+
//#endregion
|
|
19
|
+
export { _default };
|
|
@@ -11,8 +11,8 @@ declare const __VLS_base: _$vue.DefineComponent<CardRootProps, {}, {}, {}, {}, _
|
|
|
11
11
|
}, string, _$vue.PublicProps, Readonly<CardRootProps> & Readonly<{
|
|
12
12
|
"onUpdate:open"?: ((value: boolean) => any) | undefined;
|
|
13
13
|
}>, {
|
|
14
|
-
defaultOpen: boolean;
|
|
15
14
|
open: boolean;
|
|
15
|
+
defaultOpen: boolean;
|
|
16
16
|
}, {}, {}, {}, string, _$vue.ComponentProvideOptions, false, {}, any>;
|
|
17
17
|
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
18
18
|
declare const _default: typeof __VLS_export;
|
|
@@ -1,11 +1,12 @@
|
|
|
1
|
-
import { CardCollapsibleTriggerProps, CardContentProps, CardDescriptionProps, CardFooterProps, CardHeaderProps, CardRootEmits, CardRootProps, CardTitleProps, CardTitleRootProps, CardUi, CardUiSlot } from "./types.js";
|
|
2
|
-
import { _default as _default$
|
|
3
|
-
import { _default as _default$
|
|
4
|
-
import { _default as _default$
|
|
5
|
-
import { _default as _default$
|
|
6
|
-
import { _default as _default$
|
|
7
|
-
import { _default as _default$
|
|
8
|
-
import { _default as _default$
|
|
1
|
+
import { CardCollapsibleTriggerProps, CardCompactEmits, CardCompactProps, CardCompactSlots, CardContentProps, CardDescriptionProps, CardFooterProps, CardHeaderProps, CardRootEmits, CardRootProps, CardTitleProps, CardTitleRootProps, CardUi, CardUiSlot } from "./types.js";
|
|
2
|
+
import { _default as _default$6 } from "./card-root.vue.js";
|
|
3
|
+
import { _default as _default$5 } from "./card-header.vue.js";
|
|
4
|
+
import { _default as _default$7 } from "./card-title.vue.js";
|
|
5
|
+
import { _default as _default$8 } from "./card-title-root.vue.js";
|
|
6
|
+
import { _default as _default$3 } from "./card-description.vue.js";
|
|
7
|
+
import { _default as _default$2 } from "./card-content.vue.js";
|
|
8
|
+
import { _default as _default$4 } from "./card-footer.vue.js";
|
|
9
9
|
import { _default } from "./card-collapsible-trigger.vue.js";
|
|
10
|
+
import { _default as _default$1 } from "./card-compact.vue.js";
|
|
10
11
|
import { provideCardUi } from "./context.js";
|
|
11
|
-
export { _default as CardCollapsibleTrigger, type CardCollapsibleTriggerProps, _default$1 as CardContent, type CardContentProps, _default$
|
|
12
|
+
export { _default as CardCollapsibleTrigger, type CardCollapsibleTriggerProps, _default$1 as CardCompact, type CardCompactEmits, type CardCompactProps, type CardCompactSlots, _default$2 as CardContent, type CardContentProps, _default$3 as CardDescription, type CardDescriptionProps, _default$4 as CardFooter, type CardFooterProps, _default$5 as CardHeader, type CardHeaderProps, _default$6 as CardRoot, type CardRootEmits, type CardRootProps, _default$7 as CardTitle, type CardTitleProps, _default$8 as CardTitleRoot, type CardTitleRootProps, type CardUi, type CardUiSlot, provideCardUi };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import e from"./card-root.js";import{provideCardUi as t}from"./context.js";import n from"./card-header.js";import r from"./card-title.js";import i from"./card-title-root.js";import a from"./card-description.js";import o from"./card-content.js";import s from"./card-footer.js";import c from"./card-collapsible-trigger.js";export{c as CardCollapsibleTrigger,o as CardContent,a as CardDescription,s as CardFooter,n as CardHeader,e as CardRoot,r as CardTitle,i as CardTitleRoot,t as provideCardUi};
|
|
1
|
+
import e from"./card-root.js";import{provideCardUi as t}from"./context.js";import n from"./card-header.js";import r from"./card-title.js";import i from"./card-title-root.js";import a from"./card-description.js";import o from"./card-content.js";import s from"./card-footer.js";import c from"./card-collapsible-trigger.js";import l from"./card-compact.js";export{c as CardCollapsibleTrigger,l as CardCompact,o as CardContent,a as CardDescription,s as CardFooter,n as CardHeader,e as CardRoot,r as CardTitle,i as CardTitleRoot,t as provideCardUi};
|