vft 0.0.249 → 0.0.252
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/index.css +1 -1
- package/es/components/alert/alert.vue.d.ts +1 -11
- package/es/components/alert/alert.vue2.js +13 -65
- package/es/components/alert/index.d.ts +28 -76
- package/es/components/autocomplete/autocomplete.vue.d.ts +14 -14
- package/es/components/autocomplete/autocomplete.vue2.js +194 -199
- package/es/components/autocomplete/index.d.ts +42 -42
- package/es/components/backtop/backtop.vue.d.ts +1 -15
- package/es/components/backtop/backtop.vue2.js +17 -106
- package/es/components/backtop/index.d.ts +3 -9
- package/es/components/backtop/types.d.ts +14 -0
- package/es/components/backtop/types.js +1 -0
- package/es/components/button/button-custom.d.ts +1 -1
- package/es/components/button/button.vue.d.ts +3 -50
- package/es/components/button/button.vue2.js +1 -1
- package/es/components/button/index.d.ts +39 -40
- package/es/components/button/types.d.ts +47 -1
- package/es/components/button/use-button.d.ts +5 -5
- package/es/components/card/index.d.ts +3 -3
- package/es/components/carousel/carousel.vue.d.ts +1 -1
- package/es/components/carousel/index.d.ts +18 -18
- package/es/components/carousel/use-carousel.js +2 -3
- package/es/components/checkbox/checkbox-group.vue.d.ts +1 -1
- package/es/components/checkbox/index.d.ts +42 -42
- package/es/components/color-picker/components/hue-slider.vue.d.ts +3 -3
- package/es/components/color-picker/components/predefine.vue.d.ts +3 -3
- package/es/components/color-picker/components/sv-panel.vue.d.ts +3 -3
- package/es/components/config-provider/hooks/use-global-config.d.ts +3 -3
- package/es/components/context-menu/context-menu.vue2.js +36 -124
- package/es/components/context-menu/index.js +5 -101
- package/es/components/context-menu/types.d.ts +1 -1
- package/es/components/context-menu/types.js +1 -98
- package/es/components/date-picker/composables/use-basic-date-table.d.ts +188 -0
- package/es/components/date-picker/composables/use-basic-date-table.js +183 -0
- package/es/components/date-picker/composables/use-month-range-header.d.ts +1 -1
- package/es/components/date-picker/composables/use-panel-date-range.d.ts +29 -0
- package/es/components/date-picker/composables/use-panel-date-range.js +72 -0
- package/es/components/date-picker/composables/use-range-picker.d.ts +46 -42
- package/es/components/date-picker/composables/use-range-picker.js +65 -52
- package/es/components/date-picker/composables/use-shortcut.js +4 -4
- package/es/components/date-picker/composables/use-year-range-header.d.ts +16 -0
- package/es/components/date-picker/composables/use-year-range-header.js +35 -0
- package/es/components/date-picker/constants.d.ts +2 -15
- package/es/components/date-picker/constants.js +3 -16
- package/es/components/date-picker/date-picker-com/basic-cell-render.d.ts +3 -1
- package/es/components/date-picker/date-picker-com/basic-cell-render.js +16 -19
- package/es/components/date-picker/date-picker-com/basic-date-table.vue.d.ts +14 -23
- package/es/components/date-picker/date-picker-com/basic-date-table.vue2.js +73 -176
- package/es/components/date-picker/date-picker-com/basic-month-table.vue.d.ts +2 -2
- package/es/components/date-picker/date-picker-com/basic-month-table.vue2.js +93 -71
- package/es/components/date-picker/date-picker-com/basic-year-table.vue.d.ts +50 -9
- package/es/components/date-picker/date-picker-com/basic-year-table.vue2.js +108 -57
- package/es/components/date-picker/date-picker-com/panel-date-pick.vue.d.ts +13 -3
- package/es/components/date-picker/date-picker-com/panel-date-pick.vue2.js +329 -277
- package/es/components/date-picker/date-picker-com/panel-date-range.vue.d.ts +16 -3
- package/es/components/date-picker/date-picker-com/panel-date-range.vue2.js +422 -281
- package/es/components/date-picker/date-picker-com/panel-month-range.vue.d.ts +6 -3
- package/es/components/date-picker/date-picker-com/panel-month-range.vue2.js +137 -113
- package/es/components/date-picker/date-picker-com/panel-year-range.vue.d.ts +35 -0
- package/es/components/date-picker/date-picker-com/panel-year-range.vue.js +4 -0
- package/es/components/date-picker/date-picker-com/panel-year-range.vue2.js +210 -0
- package/es/components/date-picker/date-picker.d.ts +70 -40
- package/es/components/date-picker/date-picker.js +59 -50
- package/es/components/date-picker/date-picker.type.d.ts +2 -1
- package/es/components/date-picker/index.d.ts +126 -68
- package/es/components/date-picker/index.js +7 -7
- package/es/components/date-picker/instance.d.ts +9 -0
- package/es/components/date-picker/instance.js +1 -0
- package/es/components/date-picker/panel-utils.d.ts +48 -0
- package/es/components/date-picker/panel-utils.js +9 -6
- package/es/components/date-picker/props/basic-cell.d.ts +2 -1
- package/es/components/date-picker/props/basic-date-table.d.ts +7 -2
- package/es/components/date-picker/props/basic-date-table.js +6 -5
- package/es/components/date-picker/props/basic-month-table.d.ts +3 -2
- package/es/components/date-picker/props/basic-year-table.d.ts +23 -5
- package/es/components/date-picker/props/basic-year-table.js +5 -6
- package/es/components/date-picker/props/date-picker.d.ts +26 -12
- package/es/components/date-picker/props/date-picker.js +3 -0
- package/es/components/date-picker/props/panel-date-pick.d.ts +6 -1
- package/es/components/date-picker/props/panel-date-range.d.ts +7 -1
- package/es/components/date-picker/props/panel-month-range.d.ts +3 -1
- package/es/components/date-picker/props/panel-month-range.js +7 -3
- package/es/components/date-picker/props/panel-year-range.d.ts +14 -0
- package/es/components/date-picker/props/panel-year-range.js +17 -0
- package/es/components/date-picker/props/shared.d.ts +9 -2
- package/es/components/date-picker/props/shared.js +29 -12
- package/es/components/date-picker/style/css.d.ts +4 -0
- package/es/components/date-picker/style/css.js +5 -0
- package/es/components/date-picker/utils.d.ts +9 -2
- package/es/components/date-picker/utils.js +66 -33
- package/es/components/date-time-select/date-time-select.vue2.js +1 -1
- package/es/components/date-time-select/index.d.ts +1 -0
- package/es/components/date-time-select/types.d.ts +4 -0
- package/es/components/dialog/dialog-content.vue2.js +2 -3
- package/es/components/dropdown/dropdown-item-impl.vue.d.ts +4 -4
- package/es/components/dropdown/dropdown-item-impl.vue.js +12 -12
- package/es/components/dropdown/dropdown-item-impl.vue2.js +6 -6
- package/es/components/dropdown/dropdown.vue.d.ts +6 -29
- package/es/components/dropdown/dropdown.vue2.js +146 -149
- package/es/components/footer-layout/footer-layout.vue2.js +19 -108
- package/es/components/form/form-item.vue.d.ts +2 -3
- package/es/components/form/form-item.vue2.js +140 -135
- package/es/components/form/form-label-wrap.js +27 -27
- package/es/components/form/form.vue2.js +71 -65
- package/es/components/form/hooks/use-form-common-props.js +3 -4
- package/es/components/form/hooks/use-form-item.js +12 -13
- package/es/components/form/index.d.ts +75 -48
- package/es/components/form/types.d.ts +7 -1
- package/es/components/form/utils.d.ts +1 -1
- package/es/components/form/utils.js +33 -28
- package/es/components/header-layout/header-layout.vue2.js +26 -114
- package/es/components/icon/icon.vue2.js +20 -19
- package/es/components/icon/index.d.ts +0 -1
- package/es/components/icon/index.js +3 -4
- package/es/components/index.js +323 -319
- package/es/components/input/input.vue2.js +4 -4
- package/es/components/link/index.d.ts +3 -3
- package/es/components/md-code-demo/md-code-demo.js +12 -13
- package/es/components/md-container/md-container.vue2.js +52 -138
- package/es/components/md-vue-playground/md-vue-playground.vue2.js +17 -17
- package/es/components/menu/index.js +1 -1
- package/es/components/menu/menu-item.vue.d.ts +1 -1
- package/es/components/menu/menu-item.vue2.js +45 -132
- package/es/components/menu/sub-menu.vue.d.ts +2 -1
- package/es/components/menu/sub-menu.vue2.js +76 -163
- package/es/components/modal/index.d.ts +33 -45
- package/es/components/modal/modal-footer-action.vue2.js +26 -112
- package/es/components/modal/modal.vue.d.ts +2 -2
- package/es/components/multiple-tabs/multiple-tabs.vue2.js +57 -144
- package/es/components/multiple-tabs/tab-content.vue2.js +19 -113
- package/es/components/multiple-tabs/use/use-tab-dropdown.js +37 -132
- package/es/components/popconfirm/index.d.ts +24 -24
- package/es/components/popconfirm/popconfirm.vue.d.ts +2 -2
- package/es/components/popover/index.d.ts +5 -5
- package/es/components/popover/popover.vue.d.ts +2 -2
- package/es/components/popper/composables/use-content.js +2 -3
- package/es/components/popper/trigger.vue2.js +7 -8
- package/es/components/progress/index.d.ts +3 -3
- package/es/components/result/result.vue.d.ts +1 -1
- package/es/components/result/result.vue2.js +20 -109
- package/es/components/roving-focus-group/index.js +11 -11
- package/es/components/roving-focus-group/roving-focus-group.vue.js +5 -5
- package/es/components/roving-focus-group/roving-focus-item.vue2.js +2 -3
- package/es/components/scrollbar/index.js +9 -10
- package/es/components/select/defaults.d.ts +99 -15
- package/es/components/select/defaults.js +90 -12
- package/es/components/select/group-item.vue.d.ts +10 -5
- package/es/components/select/group-item.vue.js +9 -19
- package/es/components/select/group-item.vue2.js +4 -2
- package/es/components/select/index.d.ts +2782 -0
- package/es/components/select/index.js +2 -2
- package/es/components/select/option-item.vue.d.ts +40 -26
- package/es/components/select/option-item.vue.js +12 -12
- package/es/components/select/option-item.vue2.js +15 -12
- package/es/components/select/select-dropdown.d.ts +29 -3
- package/es/components/select/select-dropdown.js +120 -129
- package/es/components/select/select.types.d.ts +19 -11
- package/es/components/select/select.vue.d.ts +2778 -0
- package/es/components/select/select.vue.js +261 -251
- package/es/components/select/select.vue2.js +49 -45
- package/es/components/select/token.d.ts +10 -12
- package/es/components/select/token.js +4 -2
- package/es/components/select/useAllowCreate.d.ts +3 -3
- package/es/components/select/useAllowCreate.js +32 -29
- package/es/components/select/useOption.d.ts +3 -3
- package/es/components/select/useProps.d.ts +21 -0
- package/es/components/select/useProps.js +22 -0
- package/es/components/select/useSelect.d.ts +940 -121
- package/es/components/select/useSelect.js +396 -302
- package/es/components/side-menu/side-menu.vue2.js +77 -165
- package/es/components/steps/index.d.ts +12 -12
- package/es/components/super-form/component-map.js +52 -141
- package/es/components/super-form/style/css.js +4 -4
- package/es/components/super-form/super-form-action.vue2.js +39 -126
- package/es/components/super-form/super-form-item.vue2.js +161 -248
- package/es/components/super-form/super-form.vue.d.ts +1 -1
- package/es/components/super-form/super-form.vue2.js +116 -202
- package/es/components/super-form/types.d.ts +3 -1
- package/es/components/switch/index.d.ts +6 -6
- package/es/components/table/field.js +82 -176
- package/es/components/table/index.d.ts +24 -24
- package/es/components/table/table.vue.d.ts +1 -1
- package/es/components/tabs/tab-nav.vue.d.ts +2 -2
- package/es/components/tabs/tab-nav.vue2.js +98 -187
- package/es/components/tabs/tabs.vue.d.ts +2 -1
- package/es/components/time-picker/common/picker-range-trigger.vue.d.ts +84 -0
- package/es/components/time-picker/common/picker-range-trigger.vue.js +4 -0
- package/es/components/time-picker/common/picker-range-trigger.vue2.js +100 -0
- package/es/components/time-picker/common/picker.vue.d.ts +71 -41
- package/es/components/time-picker/common/picker.vue2.js +285 -289
- package/es/components/time-picker/common/props.d.ts +76 -12
- package/es/components/time-picker/common/props.js +78 -35
- package/es/components/time-picker/composables/use-time-panel.d.ts +4 -4
- package/es/components/time-picker/composables/use-time-picker.d.ts +28 -29
- package/es/components/time-picker/constants.d.ts +5 -0
- package/es/components/time-picker/constants.js +15 -10
- package/es/components/time-picker/index.d.ts +120 -74
- package/es/components/time-picker/index.js +28 -23
- package/es/components/time-picker/props/basic-time-spinner.d.ts +5 -4
- package/es/components/time-picker/props/panel-time-picker.d.ts +2 -1
- package/es/components/time-picker/props/panel-time-range.d.ts +2 -1
- package/es/components/time-picker/props/shared.d.ts +4 -5
- package/es/components/time-picker/style/css.d.ts +3 -0
- package/es/components/time-picker/style/css.js +3 -0
- package/es/components/time-picker/style/index.d.ts +3 -0
- package/es/components/time-picker/style/index.js +3 -0
- package/es/components/time-picker/time-picker-com/basic-time-spinner.vue.d.ts +6 -6
- package/es/components/time-picker/time-picker-com/basic-time-spinner.vue2.js +135 -128
- package/es/components/time-picker/time-picker-com/panel-time-pick.vue.d.ts +4 -4
- package/es/components/time-picker/time-picker-com/panel-time-pick.vue2.js +36 -35
- package/es/components/time-picker/time-picker-com/panel-time-range.vue.d.ts +4 -4
- package/es/components/time-picker/time-picker-com/panel-time-range.vue2.js +109 -108
- package/es/components/time-picker/time-picker.d.ts +60 -37
- package/es/components/time-picker/time-picker.js +28 -30
- package/es/components/time-picker/utils.d.ts +5 -2
- package/es/components/time-picker/utils.js +17 -16
- package/es/components/time-select/time-select.vue.d.ts +1 -1
- package/es/components/timeline/index.d.ts +6 -6
- package/es/components/tooltip/content.vue2.js +47 -48
- package/es/components/tooltip/index.d.ts +3 -3
- package/es/components/tooltip/tooltip.vue.d.ts +1 -1
- package/es/components/tooltip/tooltip.vue2.js +77 -78
- package/es/components/tooltip/utils.js +4 -5
- package/es/components/tree/tree-node.vue.d.ts +33 -33
- package/es/components/tree/tree-node.vue.js +11 -11
- package/es/components/tree/tree-node.vue2.js +15 -15
- package/es/components/upload/index.d.ts +15 -15
- package/es/components/upload/upload-content.vue.d.ts +1 -1
- package/es/components/upload/upload.vue.d.ts +1 -1
- package/es/components/virtual-list/builders/build-grid.d.ts +9 -9
- package/es/components/virtual-list/builders/build-grid.js +222 -214
- package/es/components/virtual-list/builders/build-list.d.ts +13 -13
- package/es/components/virtual-list/builders/build-list.js +206 -198
- package/es/components/virtual-list/components/dynamic-size-grid.d.ts +6 -6
- package/es/components/virtual-list/components/dynamic-size-grid.js +12 -12
- package/es/components/virtual-list/components/dynamic-size-list.d.ts +13 -12
- package/es/components/virtual-list/components/dynamic-size-list.js +7 -7
- package/es/components/virtual-list/components/fixed-size-grid.d.ts +6 -6
- package/es/components/virtual-list/components/fixed-size-list.d.ts +13 -12
- package/es/components/virtual-list/components/fixed-size-list.js +8 -8
- package/es/components/virtual-list/components/scrollbar.js +59 -66
- package/es/components/virtual-list/defaults.d.ts +0 -4
- package/es/components/virtual-list/defaults.js +11 -15
- package/es/components/virtual-list/hooks/use-cache.d.ts +1 -1
- package/es/components/virtual-list/hooks/use-cache.js +6 -6
- package/es/components/virtual-list/hooks/use-wheel.js +1 -1
- package/es/components/virtual-list/index.d.ts +6 -4
- package/es/components/virtual-list/index.js +4 -4
- package/es/components/virtual-list/props.d.ts +11 -7
- package/es/components/virtual-list/props.js +24 -30
- package/es/components/virtual-list/types.d.ts +1 -1
- package/es/components/virtual-list/utils.d.ts +1 -2
- package/es/components/virtual-list/utils.js +16 -18
- package/es/hooks/index.d.ts +3 -1
- package/es/hooks/index.js +49 -46
- package/es/hooks/use-calc-input-width/index.d.ts +7 -0
- package/es/hooks/use-calc-input-width/index.js +17 -0
- package/es/hooks/use-composition/index.d.ts +12 -0
- package/es/hooks/use-composition/index.js +28 -0
- package/es/hooks/use-delayed-toggle/index.d.ts +8 -4
- package/es/hooks/use-delayed-toggle/index.js +52 -17
- package/es/hooks/use-empty-values/index.d.ts +16 -0
- package/es/hooks/use-empty-values/index.js +37 -0
- package/es/hooks/use-focus-controller/index.d.ts +27 -0
- package/es/hooks/use-focus-controller/index.js +38 -0
- package/es/hooks/use-id/index.d.ts +1 -1
- package/es/hooks/use-id/index.js +11 -11
- package/es/hooks/use-namespace/index.d.ts +5 -6
- package/es/hooks/use-namespace/index.js +13 -15
- package/es/index.js +459 -451
- package/es/package.json.d.ts +2 -2
- package/es/package.json.js +1 -1
- package/es/utils/helper.d.ts +1 -0
- package/es/utils/helper.js +3 -2
- package/es/utils/index.js +49 -48
- package/lib/components/alert/alert.vue.d.ts +1 -11
- package/lib/components/alert/alert.vue2.cjs +1 -1
- package/lib/components/alert/index.d.ts +28 -76
- package/lib/components/autocomplete/autocomplete.vue.d.ts +14 -14
- package/lib/components/autocomplete/autocomplete.vue2.cjs +1 -1
- package/lib/components/autocomplete/index.d.ts +42 -42
- package/lib/components/backtop/backtop.vue.d.ts +1 -15
- package/lib/components/backtop/backtop.vue2.cjs +1 -1
- package/lib/components/backtop/index.d.ts +3 -9
- package/lib/components/backtop/types.cjs +1 -0
- package/lib/components/backtop/types.d.ts +14 -0
- package/lib/components/button/button-custom.d.ts +1 -1
- package/lib/components/button/button.vue.d.ts +3 -50
- package/lib/components/button/button.vue2.cjs +1 -1
- package/lib/components/button/index.d.ts +39 -40
- package/lib/components/button/types.d.ts +47 -1
- package/lib/components/button/use-button.d.ts +5 -5
- package/lib/components/card/index.d.ts +3 -3
- package/lib/components/carousel/carousel.vue.d.ts +1 -1
- package/lib/components/carousel/index.d.ts +18 -18
- package/lib/components/carousel/use-carousel.cjs +1 -1
- package/lib/components/checkbox/checkbox-group.vue.d.ts +1 -1
- package/lib/components/checkbox/index.d.ts +42 -42
- package/lib/components/color-picker/components/hue-slider.vue.d.ts +3 -3
- package/lib/components/color-picker/components/predefine.vue.d.ts +3 -3
- package/lib/components/color-picker/components/sv-panel.vue.d.ts +3 -3
- package/lib/components/config-provider/hooks/use-global-config.d.ts +3 -3
- package/lib/components/context-menu/context-menu.vue2.cjs +1 -1
- package/lib/components/context-menu/index.cjs +1 -1
- package/lib/components/context-menu/types.cjs +1 -1
- package/lib/components/context-menu/types.d.ts +1 -1
- package/lib/components/date-picker/composables/use-basic-date-table.cjs +1 -0
- package/lib/components/date-picker/composables/use-basic-date-table.d.ts +188 -0
- package/lib/components/date-picker/composables/use-month-range-header.d.ts +1 -1
- package/lib/components/date-picker/composables/use-panel-date-range.cjs +1 -0
- package/lib/components/date-picker/composables/use-panel-date-range.d.ts +29 -0
- package/lib/components/date-picker/composables/use-range-picker.cjs +1 -1
- package/lib/components/date-picker/composables/use-range-picker.d.ts +46 -42
- package/lib/components/date-picker/composables/use-shortcut.cjs +1 -1
- package/lib/components/date-picker/composables/use-year-range-header.cjs +1 -0
- package/lib/components/date-picker/composables/use-year-range-header.d.ts +16 -0
- package/lib/components/date-picker/constants.cjs +1 -1
- package/lib/components/date-picker/constants.d.ts +2 -15
- package/lib/components/date-picker/date-picker-com/basic-cell-render.cjs +1 -1
- package/lib/components/date-picker/date-picker-com/basic-cell-render.d.ts +3 -1
- package/lib/components/date-picker/date-picker-com/basic-date-table.vue.d.ts +14 -23
- package/lib/components/date-picker/date-picker-com/basic-date-table.vue2.cjs +1 -1
- package/lib/components/date-picker/date-picker-com/basic-month-table.vue.d.ts +2 -2
- package/lib/components/date-picker/date-picker-com/basic-month-table.vue2.cjs +1 -1
- package/lib/components/date-picker/date-picker-com/basic-year-table.vue.d.ts +50 -9
- package/lib/components/date-picker/date-picker-com/basic-year-table.vue2.cjs +1 -1
- package/lib/components/date-picker/date-picker-com/panel-date-pick.vue.d.ts +13 -3
- package/lib/components/date-picker/date-picker-com/panel-date-pick.vue2.cjs +1 -1
- package/lib/components/date-picker/date-picker-com/panel-date-range.vue.d.ts +16 -3
- package/lib/components/date-picker/date-picker-com/panel-date-range.vue2.cjs +1 -1
- package/lib/components/date-picker/date-picker-com/panel-month-range.vue.d.ts +6 -3
- package/lib/components/date-picker/date-picker-com/panel-month-range.vue2.cjs +1 -1
- package/lib/components/date-picker/date-picker-com/panel-year-range.vue.cjs +1 -0
- package/lib/components/date-picker/date-picker-com/panel-year-range.vue.d.ts +35 -0
- package/lib/components/date-picker/date-picker-com/panel-year-range.vue2.cjs +1 -0
- package/lib/components/date-picker/date-picker.cjs +1 -1
- package/lib/components/date-picker/date-picker.d.ts +70 -40
- package/lib/components/date-picker/date-picker.type.d.ts +2 -1
- package/lib/components/date-picker/index.cjs +1 -1
- package/lib/components/date-picker/index.d.ts +126 -68
- package/lib/components/date-picker/instance.cjs +1 -0
- package/lib/components/date-picker/instance.d.ts +9 -0
- package/lib/components/date-picker/panel-utils.cjs +1 -1
- package/lib/components/date-picker/panel-utils.d.ts +48 -0
- package/lib/components/date-picker/props/basic-cell.d.ts +2 -1
- package/lib/components/date-picker/props/basic-date-table.cjs +1 -1
- package/lib/components/date-picker/props/basic-date-table.d.ts +7 -2
- package/lib/components/date-picker/props/basic-month-table.d.ts +3 -2
- package/lib/components/date-picker/props/basic-year-table.cjs +1 -1
- package/lib/components/date-picker/props/basic-year-table.d.ts +23 -5
- package/lib/components/date-picker/props/date-picker.d.ts +26 -12
- package/lib/components/date-picker/props/panel-date-pick.d.ts +6 -1
- package/lib/components/date-picker/props/panel-date-range.d.ts +7 -1
- package/lib/components/date-picker/props/panel-month-range.cjs +1 -1
- package/lib/components/date-picker/props/panel-month-range.d.ts +3 -1
- package/lib/components/date-picker/props/panel-year-range.cjs +1 -0
- package/lib/components/date-picker/props/panel-year-range.d.ts +14 -0
- package/lib/components/date-picker/props/shared.cjs +1 -1
- package/lib/components/date-picker/props/shared.d.ts +9 -2
- package/lib/components/date-picker/style/css.cjs +1 -1
- package/lib/components/date-picker/style/css.d.ts +4 -0
- package/lib/components/date-picker/utils.cjs +1 -1
- package/lib/components/date-picker/utils.d.ts +9 -2
- package/lib/components/date-time-select/date-time-select.vue2.cjs +1 -1
- package/lib/components/date-time-select/index.d.ts +1 -0
- package/lib/components/date-time-select/types.d.ts +4 -0
- package/lib/components/dialog/dialog-content.vue2.cjs +1 -1
- package/lib/components/dropdown/dropdown-item-impl.vue.cjs +1 -1
- package/lib/components/dropdown/dropdown-item-impl.vue.d.ts +4 -4
- package/lib/components/dropdown/dropdown-item-impl.vue2.cjs +1 -1
- package/lib/components/dropdown/dropdown.vue.d.ts +6 -29
- package/lib/components/dropdown/dropdown.vue2.cjs +1 -1
- package/lib/components/footer-layout/footer-layout.vue2.cjs +1 -1
- package/lib/components/form/form-item.vue.d.ts +2 -3
- package/lib/components/form/form-item.vue2.cjs +1 -1
- package/lib/components/form/form-label-wrap.cjs +1 -1
- package/lib/components/form/form.vue2.cjs +1 -1
- package/lib/components/form/hooks/use-form-common-props.cjs +1 -1
- package/lib/components/form/hooks/use-form-item.cjs +1 -1
- package/lib/components/form/index.d.ts +75 -48
- package/lib/components/form/types.d.ts +7 -1
- package/lib/components/form/utils.cjs +1 -1
- package/lib/components/form/utils.d.ts +1 -1
- package/lib/components/header-layout/header-layout.vue2.cjs +1 -1
- package/lib/components/icon/icon.vue2.cjs +1 -1
- package/lib/components/icon/index.cjs +1 -1
- package/lib/components/icon/index.d.ts +0 -1
- package/lib/components/index.cjs +1 -1
- package/lib/components/input/input.vue2.cjs +1 -1
- package/lib/components/link/index.d.ts +3 -3
- package/lib/components/md-code-demo/md-code-demo.cjs +1 -1
- package/lib/components/md-container/md-container.vue2.cjs +1 -1
- package/lib/components/md-vue-playground/md-vue-playground.vue2.cjs +1 -1
- package/lib/components/menu/menu-item.vue.d.ts +1 -1
- package/lib/components/menu/menu-item.vue2.cjs +1 -1
- package/lib/components/menu/sub-menu.vue.d.ts +2 -1
- package/lib/components/menu/sub-menu.vue2.cjs +1 -1
- package/lib/components/modal/index.d.ts +33 -45
- package/lib/components/modal/modal-footer-action.vue2.cjs +1 -1
- package/lib/components/modal/modal.vue.d.ts +2 -2
- package/lib/components/multiple-tabs/multiple-tabs.vue2.cjs +1 -1
- package/lib/components/multiple-tabs/tab-content.vue2.cjs +1 -1
- package/lib/components/multiple-tabs/use/use-tab-dropdown.cjs +1 -1
- package/lib/components/popconfirm/index.d.ts +24 -24
- package/lib/components/popconfirm/popconfirm.vue.d.ts +2 -2
- package/lib/components/popover/index.d.ts +5 -5
- package/lib/components/popover/popover.vue.d.ts +2 -2
- package/lib/components/popper/composables/use-content.cjs +1 -1
- package/lib/components/popper/trigger.vue2.cjs +1 -1
- package/lib/components/progress/index.d.ts +3 -3
- package/lib/components/result/result.vue.d.ts +1 -1
- package/lib/components/result/result.vue2.cjs +1 -1
- package/lib/components/roving-focus-group/roving-focus-item.vue2.cjs +1 -1
- package/lib/components/scrollbar/index.cjs +1 -1
- package/lib/components/select/defaults.cjs +1 -1
- package/lib/components/select/defaults.d.ts +99 -15
- package/lib/components/select/group-item.vue.cjs +1 -1
- package/lib/components/select/group-item.vue.d.ts +10 -5
- package/lib/components/select/group-item.vue2.cjs +1 -1
- package/lib/components/select/index.cjs +1 -1
- package/lib/components/select/index.d.ts +2782 -0
- package/lib/components/select/option-item.vue.cjs +1 -1
- package/lib/components/select/option-item.vue.d.ts +40 -26
- package/lib/components/select/option-item.vue2.cjs +1 -1
- package/lib/components/select/select-dropdown.cjs +1 -1
- package/lib/components/select/select-dropdown.d.ts +29 -3
- package/lib/components/select/select.types.d.ts +19 -11
- package/lib/components/select/select.vue.cjs +1 -1
- package/lib/components/select/select.vue.d.ts +2778 -0
- package/lib/components/select/select.vue2.cjs +1 -1
- package/lib/components/select/token.cjs +1 -1
- package/lib/components/select/token.d.ts +10 -12
- package/lib/components/select/useAllowCreate.cjs +1 -1
- package/lib/components/select/useAllowCreate.d.ts +3 -3
- package/lib/components/select/useOption.d.ts +3 -3
- package/lib/components/select/useProps.cjs +1 -0
- package/lib/components/select/useProps.d.ts +21 -0
- package/lib/components/select/useSelect.cjs +1 -1
- package/lib/components/select/useSelect.d.ts +940 -121
- package/lib/components/side-menu/side-menu.vue2.cjs +1 -1
- package/lib/components/steps/index.d.ts +12 -12
- package/lib/components/super-form/component-map.cjs +1 -1
- package/lib/components/super-form/style/css.cjs +1 -1
- package/lib/components/super-form/super-form-action.vue2.cjs +1 -1
- package/lib/components/super-form/super-form-item.vue2.cjs +1 -1
- package/lib/components/super-form/super-form.vue.d.ts +1 -1
- package/lib/components/super-form/super-form.vue2.cjs +1 -1
- package/lib/components/super-form/types.d.ts +3 -1
- package/lib/components/switch/index.d.ts +6 -6
- package/lib/components/table/field.cjs +1 -1
- package/lib/components/table/index.d.ts +24 -24
- package/lib/components/table/table.vue.d.ts +1 -1
- package/lib/components/tabs/tab-nav.vue.d.ts +2 -2
- package/lib/components/tabs/tab-nav.vue2.cjs +1 -1
- package/lib/components/tabs/tabs.vue.d.ts +2 -1
- package/lib/components/time-picker/common/picker-range-trigger.vue.cjs +1 -0
- package/lib/components/time-picker/common/picker-range-trigger.vue.d.ts +84 -0
- package/lib/components/time-picker/common/picker-range-trigger.vue2.cjs +1 -0
- package/lib/components/time-picker/common/picker.vue.d.ts +71 -41
- package/lib/components/time-picker/common/picker.vue2.cjs +1 -1
- package/lib/components/time-picker/common/props.cjs +1 -1
- package/lib/components/time-picker/common/props.d.ts +76 -12
- package/lib/components/time-picker/composables/use-time-panel.d.ts +4 -4
- package/lib/components/time-picker/composables/use-time-picker.d.ts +28 -29
- package/lib/components/time-picker/constants.cjs +1 -1
- package/lib/components/time-picker/constants.d.ts +5 -0
- package/lib/components/time-picker/index.cjs +1 -1
- package/lib/components/time-picker/index.d.ts +120 -74
- package/lib/components/time-picker/props/basic-time-spinner.d.ts +5 -4
- package/lib/components/time-picker/props/panel-time-picker.d.ts +2 -1
- package/lib/components/time-picker/props/panel-time-range.d.ts +2 -1
- package/lib/components/time-picker/props/shared.d.ts +4 -5
- package/lib/components/time-picker/style/css.cjs +1 -1
- package/lib/components/time-picker/style/css.d.ts +3 -0
- package/lib/components/time-picker/style/index.cjs +1 -1
- package/lib/components/time-picker/style/index.d.ts +3 -0
- package/lib/components/time-picker/time-picker-com/basic-time-spinner.vue.d.ts +6 -6
- package/lib/components/time-picker/time-picker-com/basic-time-spinner.vue2.cjs +1 -1
- package/lib/components/time-picker/time-picker-com/panel-time-pick.vue.d.ts +4 -4
- package/lib/components/time-picker/time-picker-com/panel-time-pick.vue2.cjs +1 -1
- package/lib/components/time-picker/time-picker-com/panel-time-range.vue.d.ts +4 -4
- package/lib/components/time-picker/time-picker-com/panel-time-range.vue2.cjs +1 -1
- package/lib/components/time-picker/time-picker.cjs +1 -1
- package/lib/components/time-picker/time-picker.d.ts +60 -37
- package/lib/components/time-picker/utils.cjs +1 -1
- package/lib/components/time-picker/utils.d.ts +5 -2
- package/lib/components/time-select/time-select.vue.d.ts +1 -1
- package/lib/components/timeline/index.d.ts +6 -6
- package/lib/components/tooltip/content.vue2.cjs +1 -1
- package/lib/components/tooltip/index.d.ts +3 -3
- package/lib/components/tooltip/tooltip.vue.d.ts +1 -1
- package/lib/components/tooltip/tooltip.vue2.cjs +1 -1
- package/lib/components/tooltip/utils.cjs +1 -1
- package/lib/components/tree/tree-node.vue.cjs +1 -1
- package/lib/components/tree/tree-node.vue.d.ts +33 -33
- package/lib/components/tree/tree-node.vue2.cjs +1 -1
- package/lib/components/upload/index.d.ts +15 -15
- package/lib/components/upload/upload-content.vue.d.ts +1 -1
- package/lib/components/upload/upload.vue.d.ts +1 -1
- package/lib/components/virtual-list/builders/build-grid.cjs +1 -1
- package/lib/components/virtual-list/builders/build-grid.d.ts +9 -9
- package/lib/components/virtual-list/builders/build-list.cjs +1 -1
- package/lib/components/virtual-list/builders/build-list.d.ts +13 -13
- package/lib/components/virtual-list/components/dynamic-size-grid.cjs +1 -1
- package/lib/components/virtual-list/components/dynamic-size-grid.d.ts +6 -6
- package/lib/components/virtual-list/components/dynamic-size-list.cjs +1 -1
- package/lib/components/virtual-list/components/dynamic-size-list.d.ts +13 -12
- package/lib/components/virtual-list/components/fixed-size-grid.d.ts +6 -6
- package/lib/components/virtual-list/components/fixed-size-list.cjs +1 -1
- package/lib/components/virtual-list/components/fixed-size-list.d.ts +13 -12
- package/lib/components/virtual-list/components/scrollbar.cjs +1 -1
- package/lib/components/virtual-list/defaults.cjs +1 -1
- package/lib/components/virtual-list/defaults.d.ts +0 -4
- package/lib/components/virtual-list/hooks/use-cache.cjs +1 -1
- package/lib/components/virtual-list/hooks/use-cache.d.ts +1 -1
- package/lib/components/virtual-list/hooks/use-wheel.cjs +1 -1
- package/lib/components/virtual-list/index.cjs +1 -1
- package/lib/components/virtual-list/index.d.ts +6 -4
- package/lib/components/virtual-list/props.cjs +1 -1
- package/lib/components/virtual-list/props.d.ts +11 -7
- package/lib/components/virtual-list/types.d.ts +1 -1
- package/lib/components/virtual-list/utils.cjs +1 -1
- package/lib/components/virtual-list/utils.d.ts +1 -2
- package/lib/hooks/index.cjs +1 -1
- package/lib/hooks/index.d.ts +3 -1
- package/lib/hooks/use-calc-input-width/index.cjs +1 -0
- package/lib/hooks/use-calc-input-width/index.d.ts +7 -0
- package/lib/hooks/use-composition/index.cjs +1 -0
- package/lib/hooks/use-composition/index.d.ts +12 -0
- package/lib/hooks/use-delayed-toggle/index.cjs +1 -1
- package/lib/hooks/use-delayed-toggle/index.d.ts +8 -4
- package/lib/hooks/use-empty-values/index.cjs +1 -0
- package/lib/hooks/use-empty-values/index.d.ts +16 -0
- package/lib/hooks/use-focus-controller/index.cjs +1 -0
- package/lib/hooks/use-focus-controller/index.d.ts +27 -0
- package/lib/hooks/use-id/index.cjs +2 -2
- package/lib/hooks/use-id/index.d.ts +1 -1
- package/lib/hooks/use-namespace/index.cjs +1 -1
- package/lib/hooks/use-namespace/index.d.ts +5 -6
- package/lib/index.cjs +1 -1
- package/lib/package.json.cjs +1 -1
- package/lib/package.json.d.ts +2 -2
- package/lib/utils/helper.cjs +1 -1
- package/lib/utils/helper.d.ts +1 -0
- package/lib/utils/index.cjs +1 -1
- package/package.json +5 -5
- package/theme-style/index.css +1 -1
- package/theme-style/src/common/var.scss +41 -0
- package/theme-style/src/date-picker/date-picker.scss +31 -31
- package/theme-style/src/date-picker/date-range-picker.scss +60 -37
- package/theme-style/src/date-picker/date-table.scss +20 -20
- package/theme-style/src/date-picker/month-table.scss +40 -25
- package/theme-style/src/date-picker/picker-panel.scss +27 -28
- package/theme-style/src/date-picker/picker.scss +60 -56
- package/theme-style/src/date-picker/time-picker.scss +21 -21
- package/theme-style/src/date-picker/time-range-picker.scss +6 -6
- package/theme-style/src/date-picker/time-spinner.scss +24 -22
- package/theme-style/src/date-picker/year-table.scss +61 -14
- package/theme-style/src/option-group.scss +7 -28
- package/theme-style/src/option.scss +46 -12
- package/theme-style/src/select-dropdown-v2.scss +31 -37
- package/theme-style/src/select.scss +136 -220
- package/theme-style/src/tabs.scss +6 -66
- package/theme-style/src/tabss.scss +4 -4
- package/theme-style/vft-date-picker.css +1 -1
- package/theme-style/vft-option-group.css +1 -1
- package/theme-style/vft-option.css +1 -1
- package/theme-style/vft-select-dropdown-v2.css +1 -1
- package/theme-style/vft-select.css +1 -1
- package/theme-style/vft-tabs.css +1 -1
- package/theme-style/vft-tabss.css +1 -1
- package/theme-style/vft-time-picker.css +1 -1
- package/theme-style/vft-time-select.css +1 -1
- package/web-types.json +1 -1
- package/es/components/select/useInput.d.ts +0 -5
- package/es/components/select/useInput.js +0 -20
- package/es/components/select/util.d.ts +0 -2
- package/es/components/select/util.js +0 -18
- package/lib/components/select/useInput.cjs +0 -1
- package/lib/components/select/useInput.d.ts +0 -5
- package/lib/components/select/util.cjs +0 -1
- package/lib/components/select/util.d.ts +0 -2
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import dayjs from 'dayjs';
|
|
2
2
|
declare function __VLS_template(): {
|
|
3
3
|
sidebar?(_: {
|
|
4
4
|
class: string;
|
|
@@ -6,21 +6,24 @@ declare function __VLS_template(): {
|
|
|
6
6
|
};
|
|
7
7
|
declare const __VLS_component: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
8
8
|
readonly unlinkPanels: BooleanConstructor;
|
|
9
|
+
readonly visible: BooleanConstructor;
|
|
9
10
|
readonly parsedValue: {
|
|
10
|
-
readonly type: import("vue").PropType<Dayjs[]>;
|
|
11
|
+
readonly type: import("vue").PropType<dayjs.Dayjs[]>;
|
|
11
12
|
readonly required: false;
|
|
12
13
|
readonly validator: ((val: unknown) => boolean) | undefined;
|
|
13
14
|
__epPropKey: true;
|
|
14
15
|
};
|
|
15
16
|
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
16
17
|
readonly unlinkPanels: BooleanConstructor;
|
|
18
|
+
readonly visible: BooleanConstructor;
|
|
17
19
|
readonly parsedValue: {
|
|
18
|
-
readonly type: import("vue").PropType<Dayjs[]>;
|
|
20
|
+
readonly type: import("vue").PropType<dayjs.Dayjs[]>;
|
|
19
21
|
readonly required: false;
|
|
20
22
|
readonly validator: ((val: unknown) => boolean) | undefined;
|
|
21
23
|
__epPropKey: true;
|
|
22
24
|
};
|
|
23
25
|
}>> & Readonly<{}>, {
|
|
26
|
+
readonly visible: boolean;
|
|
24
27
|
readonly unlinkPanels: boolean;
|
|
25
28
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
26
29
|
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, ReturnType<typeof __VLS_template>>;
|
|
@@ -1,163 +1,187 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import {
|
|
5
|
-
import
|
|
6
|
-
import {
|
|
7
|
-
import
|
|
8
|
-
|
|
1
|
+
import { defineComponent as j, ref as S, inject as K, toRef as V, computed as L, watch as re, createElementBlock as m, openBlock as p, normalizeClass as o, unref as e, createElementVNode as l, renderSlot as le, createCommentVNode as w, Fragment as se, renderList as ie, toDisplayString as E, createVNode as f } from "vue";
|
|
2
|
+
import U from "dayjs";
|
|
3
|
+
import { VftIcon as C } from "../../icon/index.js";
|
|
4
|
+
import { isArray as de } from "@vft/utils";
|
|
5
|
+
import "../../time-picker/index.js";
|
|
6
|
+
import { isValidRange as ce, correctlyParseUserInput as ue, getDefaultValue as me } from "../utils.js";
|
|
7
|
+
import { panelMonthRangeEmits as pe, panelMonthRangeProps as fe } from "../props/panel-month-range.js";
|
|
8
|
+
import { useMonthRangeHeader as ge } from "../composables/use-month-range-header.js";
|
|
9
|
+
import { useRangePicker as be } from "../composables/use-range-picker.js";
|
|
10
|
+
import { ROOT_PICKER_IS_DEFAULT_FORMAT_INJECTION_KEY as ve } from "../constants.js";
|
|
11
|
+
import $ from "./basic-month-table.vue2.js";
|
|
12
|
+
import { PICKER_BASE_INJECTION_KEY as he } from "../../time-picker/constants.js";
|
|
13
|
+
const ke = ["onClick"], Ce = ["disabled"], Pe = ["disabled"], P = "year", ye = j({
|
|
9
14
|
name: "DatePickerMonthRange"
|
|
10
|
-
}),
|
|
11
|
-
...
|
|
12
|
-
props:
|
|
13
|
-
emits:
|
|
14
|
-
setup(
|
|
15
|
-
const
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
15
|
+
}), Be = /* @__PURE__ */ j({
|
|
16
|
+
...ye,
|
|
17
|
+
props: fe,
|
|
18
|
+
emits: pe,
|
|
19
|
+
setup(z, { emit: J }) {
|
|
20
|
+
const i = z, d = J, b = S("zh-cn"), y = K(he), H = K(
|
|
21
|
+
ve
|
|
22
|
+
), { shortcuts: I, disabledDate: N } = y.props, D = V(y.props, "format"), Y = V(y.props, "defaultValue"), c = S(U().locale(b.value)), u = S(U().locale(b.value).add(1, P)), {
|
|
23
|
+
minDate: v,
|
|
24
|
+
maxDate: h,
|
|
25
|
+
rangeState: R,
|
|
26
|
+
ppNs: r,
|
|
27
|
+
drpNs: g,
|
|
28
|
+
handleChangeRange: T,
|
|
29
|
+
handleRangeConfirm: q,
|
|
30
|
+
handleShortcutClick: G,
|
|
31
|
+
onSelect: _,
|
|
32
|
+
onReset: Q
|
|
33
|
+
} = be(i, {
|
|
34
|
+
defaultValue: Y,
|
|
35
|
+
leftDate: c,
|
|
28
36
|
rightDate: u,
|
|
29
|
-
unit:
|
|
30
|
-
onParsedValueChanged:
|
|
31
|
-
}),
|
|
32
|
-
leftPrevYear:
|
|
33
|
-
rightNextYear:
|
|
34
|
-
leftNextYear:
|
|
35
|
-
rightPrevYear:
|
|
36
|
-
leftLabel:
|
|
37
|
-
rightLabel:
|
|
38
|
-
leftYear:
|
|
39
|
-
rightYear:
|
|
40
|
-
} =
|
|
41
|
-
unlinkPanels:
|
|
42
|
-
leftDate:
|
|
37
|
+
unit: P,
|
|
38
|
+
onParsedValueChanged: oe
|
|
39
|
+
}), x = L(() => !!I.length), {
|
|
40
|
+
leftPrevYear: A,
|
|
41
|
+
rightNextYear: B,
|
|
42
|
+
leftNextYear: M,
|
|
43
|
+
rightPrevYear: O,
|
|
44
|
+
leftLabel: W,
|
|
45
|
+
rightLabel: X,
|
|
46
|
+
leftYear: Z,
|
|
47
|
+
rightYear: ee
|
|
48
|
+
} = ge({
|
|
49
|
+
unlinkPanels: V(i, "unlinkPanels"),
|
|
50
|
+
leftDate: c,
|
|
43
51
|
rightDate: u
|
|
44
|
-
}),
|
|
45
|
-
const n =
|
|
46
|
-
|
|
47
|
-
},
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
+
}), k = L(() => i.unlinkPanels && ee.value > Z.value + 1), F = (t, a = !0) => {
|
|
53
|
+
const n = t.minDate, s = t.maxDate;
|
|
54
|
+
h.value === s && v.value === n || (d("calendar-change", [n.toDate(), s && s.toDate()]), h.value = s, v.value = n, a && q());
|
|
55
|
+
}, te = () => {
|
|
56
|
+
c.value = me(e(Y), {
|
|
57
|
+
lang: e(b),
|
|
58
|
+
unit: "year",
|
|
59
|
+
unlinkPanels: i.unlinkPanels
|
|
60
|
+
})[0], u.value = c.value.add(1, "year"), d("pick", null);
|
|
61
|
+
}, ae = (t) => de(t) ? t.map((a) => a.format(D.value)) : t.format(D.value), ne = (t) => ue(
|
|
62
|
+
t,
|
|
63
|
+
D.value,
|
|
64
|
+
b.value,
|
|
65
|
+
H
|
|
66
|
+
);
|
|
67
|
+
function oe(t, a) {
|
|
68
|
+
if (i.unlinkPanels && a) {
|
|
69
|
+
const n = t?.year() || 0, s = a.year();
|
|
70
|
+
u.value = n === s ? a.add(1, P) : a;
|
|
52
71
|
} else
|
|
53
|
-
u.value =
|
|
72
|
+
u.value = c.value.add(1, P);
|
|
54
73
|
}
|
|
55
|
-
return
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
74
|
+
return re(
|
|
75
|
+
() => i.visible,
|
|
76
|
+
(t) => {
|
|
77
|
+
!t && R.value.selecting && (Q(i.parsedValue), _(!1));
|
|
78
|
+
}
|
|
79
|
+
), d("set-picker-option", ["isValidValue", ce]), d("set-picker-option", ["formatToString", ae]), d("set-picker-option", ["parseUserInput", ne]), d("set-picker-option", ["handleClear", te]), (t, a) => (p(), m("div", {
|
|
80
|
+
class: o([
|
|
81
|
+
e(r).b(),
|
|
82
|
+
e(g).b(),
|
|
59
83
|
{
|
|
60
|
-
"has-sidebar": !!
|
|
84
|
+
"has-sidebar": !!t.$slots.sidebar || x.value
|
|
61
85
|
}
|
|
62
86
|
])
|
|
63
87
|
}, [
|
|
64
88
|
l("div", {
|
|
65
|
-
class:
|
|
89
|
+
class: o(e(r).e("body-wrapper"))
|
|
66
90
|
}, [
|
|
67
|
-
|
|
68
|
-
class:
|
|
91
|
+
le(t.$slots, "sidebar", {
|
|
92
|
+
class: o(e(r).e("sidebar"))
|
|
69
93
|
}),
|
|
70
|
-
|
|
94
|
+
x.value ? (p(), m("div", {
|
|
71
95
|
key: 0,
|
|
72
|
-
class:
|
|
96
|
+
class: o(e(r).e("sidebar"))
|
|
73
97
|
}, [
|
|
74
|
-
(
|
|
98
|
+
(p(!0), m(se, null, ie(e(I), (n, s) => (p(), m("button", {
|
|
75
99
|
key: s,
|
|
76
100
|
type: "button",
|
|
77
|
-
class:
|
|
78
|
-
onClick: (
|
|
79
|
-
},
|
|
80
|
-
], 2)) :
|
|
101
|
+
class: o(e(r).e("shortcut")),
|
|
102
|
+
onClick: (De) => e(G)(n)
|
|
103
|
+
}, E(n.text), 11, ke))), 128))
|
|
104
|
+
], 2)) : w("", !0),
|
|
81
105
|
l("div", {
|
|
82
|
-
class:
|
|
106
|
+
class: o(e(r).e("body"))
|
|
83
107
|
}, [
|
|
84
108
|
l("div", {
|
|
85
|
-
class:
|
|
109
|
+
class: o([[e(r).e("content"), e(g).e("content")], "is-left"])
|
|
86
110
|
}, [
|
|
87
111
|
l("div", {
|
|
88
|
-
class:
|
|
112
|
+
class: o(e(g).e("header"))
|
|
89
113
|
}, [
|
|
90
114
|
l("button", {
|
|
91
115
|
type: "button",
|
|
92
|
-
class:
|
|
93
|
-
onClick:
|
|
94
|
-
(...n) => e(
|
|
116
|
+
class: o([e(r).e("icon-btn"), "d-arrow-left"]),
|
|
117
|
+
onClick: a[0] || (a[0] = //@ts-ignore
|
|
118
|
+
(...n) => e(A) && e(A)(...n))
|
|
95
119
|
}, [
|
|
96
|
-
|
|
120
|
+
f(e(C), { icon: "icon-d-arrow-left" })
|
|
97
121
|
], 2),
|
|
98
|
-
|
|
122
|
+
t.unlinkPanels ? (p(), m("button", {
|
|
99
123
|
key: 0,
|
|
100
124
|
type: "button",
|
|
101
|
-
disabled: !
|
|
102
|
-
class:
|
|
103
|
-
e(
|
|
104
|
-
{ [e(
|
|
125
|
+
disabled: !k.value,
|
|
126
|
+
class: o([[
|
|
127
|
+
e(r).e("icon-btn"),
|
|
128
|
+
{ [e(r).is("disabled")]: !k.value }
|
|
105
129
|
], "d-arrow-right"]),
|
|
106
|
-
onClick:
|
|
107
|
-
(...n) => e(
|
|
130
|
+
onClick: a[1] || (a[1] = //@ts-ignore
|
|
131
|
+
(...n) => e(M) && e(M)(...n))
|
|
108
132
|
}, [
|
|
109
|
-
|
|
110
|
-
], 10,
|
|
111
|
-
l("div", null,
|
|
133
|
+
f(e(C), { icon: "icon-d-arrow-right" })
|
|
134
|
+
], 10, Ce)) : w("", !0),
|
|
135
|
+
l("div", null, E(e(W)), 1)
|
|
112
136
|
], 2),
|
|
113
|
-
|
|
137
|
+
f($, {
|
|
114
138
|
"selection-mode": "range",
|
|
115
|
-
date:
|
|
116
|
-
"min-date": e(
|
|
117
|
-
"max-date": e(
|
|
118
|
-
"range-state": e(
|
|
119
|
-
"disabled-date": e(
|
|
120
|
-
onChangerange: e(
|
|
121
|
-
onPick:
|
|
122
|
-
onSelect: e(
|
|
139
|
+
date: c.value,
|
|
140
|
+
"min-date": e(v),
|
|
141
|
+
"max-date": e(h),
|
|
142
|
+
"range-state": e(R),
|
|
143
|
+
"disabled-date": e(N),
|
|
144
|
+
onChangerange: e(T),
|
|
145
|
+
onPick: F,
|
|
146
|
+
onSelect: e(_)
|
|
123
147
|
}, null, 8, ["date", "min-date", "max-date", "range-state", "disabled-date", "onChangerange", "onSelect"])
|
|
124
148
|
], 2),
|
|
125
149
|
l("div", {
|
|
126
|
-
class:
|
|
150
|
+
class: o([[e(r).e("content"), e(g).e("content")], "is-right"])
|
|
127
151
|
}, [
|
|
128
152
|
l("div", {
|
|
129
|
-
class:
|
|
153
|
+
class: o(e(g).e("header"))
|
|
130
154
|
}, [
|
|
131
|
-
|
|
155
|
+
t.unlinkPanels ? (p(), m("button", {
|
|
132
156
|
key: 0,
|
|
133
157
|
type: "button",
|
|
134
|
-
disabled: !
|
|
135
|
-
class:
|
|
136
|
-
onClick:
|
|
137
|
-
(...n) => e(
|
|
158
|
+
disabled: !k.value,
|
|
159
|
+
class: o([[e(r).e("icon-btn"), { "is-disabled": !k.value }], "d-arrow-left"]),
|
|
160
|
+
onClick: a[2] || (a[2] = //@ts-ignore
|
|
161
|
+
(...n) => e(O) && e(O)(...n))
|
|
138
162
|
}, [
|
|
139
|
-
|
|
140
|
-
], 10,
|
|
163
|
+
f(e(C), { icon: "icon-d-arrow-left" })
|
|
164
|
+
], 10, Pe)) : w("", !0),
|
|
141
165
|
l("button", {
|
|
142
166
|
type: "button",
|
|
143
|
-
class:
|
|
144
|
-
onClick:
|
|
145
|
-
(...n) => e(
|
|
167
|
+
class: o([e(r).e("icon-btn"), "d-arrow-right"]),
|
|
168
|
+
onClick: a[3] || (a[3] = //@ts-ignore
|
|
169
|
+
(...n) => e(B) && e(B)(...n))
|
|
146
170
|
}, [
|
|
147
|
-
|
|
171
|
+
f(e(C), { icon: "icon-d-arrow-right" })
|
|
148
172
|
], 2),
|
|
149
|
-
l("div", null,
|
|
173
|
+
l("div", null, E(e(X)), 1)
|
|
150
174
|
], 2),
|
|
151
|
-
|
|
175
|
+
f($, {
|
|
152
176
|
"selection-mode": "range",
|
|
153
177
|
date: u.value,
|
|
154
|
-
"min-date": e(
|
|
155
|
-
"max-date": e(
|
|
156
|
-
"range-state": e(
|
|
157
|
-
"disabled-date": e(
|
|
158
|
-
onChangerange: e(
|
|
159
|
-
onPick:
|
|
160
|
-
onSelect: e(
|
|
178
|
+
"min-date": e(v),
|
|
179
|
+
"max-date": e(h),
|
|
180
|
+
"range-state": e(R),
|
|
181
|
+
"disabled-date": e(N),
|
|
182
|
+
onChangerange: e(T),
|
|
183
|
+
onPick: F,
|
|
184
|
+
onSelect: e(_)
|
|
161
185
|
}, null, 8, ["date", "min-date", "max-date", "range-state", "disabled-date", "onChangerange", "onSelect"])
|
|
162
186
|
], 2)
|
|
163
187
|
], 2)
|
|
@@ -166,5 +190,5 @@ const ie = ["onClick"], de = ["disabled"], ce = ["disabled"], k = "year", ue = I
|
|
|
166
190
|
}
|
|
167
191
|
});
|
|
168
192
|
export {
|
|
169
|
-
|
|
193
|
+
Be as default
|
|
170
194
|
};
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import dayjs from 'dayjs';
|
|
2
|
+
declare function __VLS_template(): {
|
|
3
|
+
sidebar?(_: {
|
|
4
|
+
class: string;
|
|
5
|
+
}): any;
|
|
6
|
+
};
|
|
7
|
+
declare const __VLS_component: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
8
|
+
readonly unlinkPanels: BooleanConstructor;
|
|
9
|
+
readonly visible: BooleanConstructor;
|
|
10
|
+
readonly parsedValue: {
|
|
11
|
+
readonly type: import("vue").PropType<dayjs.Dayjs[]>;
|
|
12
|
+
readonly required: false;
|
|
13
|
+
readonly validator: ((val: unknown) => boolean) | undefined;
|
|
14
|
+
__epPropKey: true;
|
|
15
|
+
};
|
|
16
|
+
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
17
|
+
readonly unlinkPanels: BooleanConstructor;
|
|
18
|
+
readonly visible: BooleanConstructor;
|
|
19
|
+
readonly parsedValue: {
|
|
20
|
+
readonly type: import("vue").PropType<dayjs.Dayjs[]>;
|
|
21
|
+
readonly required: false;
|
|
22
|
+
readonly validator: ((val: unknown) => boolean) | undefined;
|
|
23
|
+
__epPropKey: true;
|
|
24
|
+
};
|
|
25
|
+
}>> & Readonly<{}>, {
|
|
26
|
+
readonly visible: boolean;
|
|
27
|
+
readonly unlinkPanels: boolean;
|
|
28
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
29
|
+
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, ReturnType<typeof __VLS_template>>;
|
|
30
|
+
export default _default;
|
|
31
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
32
|
+
new (): {
|
|
33
|
+
$slots: S;
|
|
34
|
+
};
|
|
35
|
+
};
|
|
@@ -0,0 +1,210 @@
|
|
|
1
|
+
import { defineComponent as M, ref as E, inject as z, toRef as I, computed as h, useSlots as ce, watch as ue, createElementBlock as u, openBlock as m, normalizeClass as r, createElementVNode as l, unref as e, renderSlot as me, createCommentVNode as N, Fragment as pe, renderList as fe, toDisplayString as L, createVNode as p } from "vue";
|
|
2
|
+
import J from "dayjs";
|
|
3
|
+
import { isArray as ge } from "@vft/utils";
|
|
4
|
+
import { VftIcon as y } from "../../icon/index.js";
|
|
5
|
+
import "../../time-picker/index.js";
|
|
6
|
+
import { panelYearRangeEmits as ve, panelYearRangeProps as be } from "../props/panel-year-range.js";
|
|
7
|
+
import { useYearRangeHeader as he } from "../composables/use-year-range-header.js";
|
|
8
|
+
import { useRangePicker as ke } from "../composables/use-range-picker.js";
|
|
9
|
+
import { isValidRange as Ce, correctlyParseUserInput as Pe, getDefaultValue as we } from "../utils.js";
|
|
10
|
+
import { ROOT_PICKER_IS_DEFAULT_FORMAT_INJECTION_KEY as Re } from "../constants.js";
|
|
11
|
+
import H from "./basic-year-table.vue2.js";
|
|
12
|
+
import { PICKER_BASE_INJECTION_KEY as ye } from "../../time-picker/constants.js";
|
|
13
|
+
const De = ["onClick"], _e = ["disabled"], Se = ["disabled"], f = 10, k = "year", Ye = M({
|
|
14
|
+
name: "DatePickerYearRange"
|
|
15
|
+
}), $e = /* @__PURE__ */ M({
|
|
16
|
+
...Ye,
|
|
17
|
+
props: be,
|
|
18
|
+
emits: ve,
|
|
19
|
+
setup(q, { emit: G }) {
|
|
20
|
+
const i = q, d = G, C = E("zh-cn"), g = E(J().locale(C.value)), c = E(J().locale(C.value).add(f, k)), Q = z(
|
|
21
|
+
Re
|
|
22
|
+
), D = z(ye), { shortcuts: x, disabledDate: v } = D.props, _ = I(D.props, "format"), K = I(D.props, "defaultValue"), {
|
|
23
|
+
minDate: P,
|
|
24
|
+
maxDate: w,
|
|
25
|
+
rangeState: S,
|
|
26
|
+
ppNs: o,
|
|
27
|
+
drpNs: b,
|
|
28
|
+
handleChangeRange: T,
|
|
29
|
+
handleRangeConfirm: W,
|
|
30
|
+
handleShortcutClick: X,
|
|
31
|
+
onSelect: Y,
|
|
32
|
+
onReset: Z
|
|
33
|
+
} = ke(i, {
|
|
34
|
+
defaultValue: K,
|
|
35
|
+
leftDate: g,
|
|
36
|
+
rightDate: c,
|
|
37
|
+
step: f,
|
|
38
|
+
unit: k,
|
|
39
|
+
onParsedValueChanged: de
|
|
40
|
+
}), {
|
|
41
|
+
leftPrevYear: A,
|
|
42
|
+
rightNextYear: O,
|
|
43
|
+
leftNextYear: F,
|
|
44
|
+
rightPrevYear: U,
|
|
45
|
+
leftLabel: ee,
|
|
46
|
+
rightLabel: te,
|
|
47
|
+
leftYear: ae,
|
|
48
|
+
rightYear: ne
|
|
49
|
+
} = he({
|
|
50
|
+
unlinkPanels: I(i, "unlinkPanels"),
|
|
51
|
+
leftDate: g,
|
|
52
|
+
rightDate: c
|
|
53
|
+
}), $ = h(() => !!x.length), re = h(() => [
|
|
54
|
+
o.b(),
|
|
55
|
+
b.b(),
|
|
56
|
+
{
|
|
57
|
+
"has-sidebar": !!ce().sidebar || $.value
|
|
58
|
+
}
|
|
59
|
+
]), V = h(() => ({
|
|
60
|
+
content: [o.e("content"), b.e("content"), "is-left"],
|
|
61
|
+
arrowLeftBtn: [o.e("icon-btn"), "d-arrow-left"],
|
|
62
|
+
arrowRightBtn: [
|
|
63
|
+
o.e("icon-btn"),
|
|
64
|
+
{ [o.is("disabled")]: !R.value },
|
|
65
|
+
"d-arrow-right"
|
|
66
|
+
]
|
|
67
|
+
})), B = h(() => ({
|
|
68
|
+
content: [o.e("content"), b.e("content"), "is-right"],
|
|
69
|
+
arrowLeftBtn: [
|
|
70
|
+
o.e("icon-btn"),
|
|
71
|
+
{ "is-disabled": !R.value },
|
|
72
|
+
"d-arrow-left"
|
|
73
|
+
],
|
|
74
|
+
arrowRightBtn: [o.e("icon-btn"), "d-arrow-right"]
|
|
75
|
+
})), R = h(() => i.unlinkPanels && ne.value > ae.value + 1), j = (t, a = !0) => {
|
|
76
|
+
const n = t.minDate, s = t.maxDate;
|
|
77
|
+
w.value === s && P.value === n || (d("calendar-change", [n.toDate(), s && s.toDate()]), w.value = s, P.value = n, a && W());
|
|
78
|
+
}, oe = (t) => Pe(
|
|
79
|
+
t,
|
|
80
|
+
_.value,
|
|
81
|
+
C.value,
|
|
82
|
+
Q
|
|
83
|
+
), le = (t) => ge(t) ? t.map((a) => a.format(_.value)) : t.format(_.value), se = (t) => Ce(t) && (v ? !v(t[0].toDate()) && !v(t[1].toDate()) : !0), ie = () => {
|
|
84
|
+
const t = we(e(K), {
|
|
85
|
+
lang: e(C),
|
|
86
|
+
step: f,
|
|
87
|
+
unit: k,
|
|
88
|
+
unlinkPanels: i.unlinkPanels
|
|
89
|
+
});
|
|
90
|
+
g.value = t[0], c.value = t[1], d("pick", null);
|
|
91
|
+
};
|
|
92
|
+
function de(t, a) {
|
|
93
|
+
if (i.unlinkPanels && a) {
|
|
94
|
+
const n = t?.year() || 0, s = a.year();
|
|
95
|
+
c.value = n + f > s ? a.add(f, k) : a;
|
|
96
|
+
} else
|
|
97
|
+
c.value = g.value.add(f, k);
|
|
98
|
+
}
|
|
99
|
+
return ue(
|
|
100
|
+
() => i.visible,
|
|
101
|
+
(t) => {
|
|
102
|
+
!t && S.value.selecting && (Z(i.parsedValue), Y(!1));
|
|
103
|
+
}
|
|
104
|
+
), d("set-picker-option", ["isValidValue", se]), d("set-picker-option", ["parseUserInput", oe]), d("set-picker-option", ["formatToString", le]), d("set-picker-option", ["handleClear", ie]), (t, a) => (m(), u("div", {
|
|
105
|
+
class: r(re.value)
|
|
106
|
+
}, [
|
|
107
|
+
l("div", {
|
|
108
|
+
class: r(e(o).e("body-wrapper"))
|
|
109
|
+
}, [
|
|
110
|
+
me(t.$slots, "sidebar", {
|
|
111
|
+
class: r(e(o).e("sidebar"))
|
|
112
|
+
}),
|
|
113
|
+
$.value ? (m(), u("div", {
|
|
114
|
+
key: 0,
|
|
115
|
+
class: r(e(o).e("sidebar"))
|
|
116
|
+
}, [
|
|
117
|
+
(m(!0), u(pe, null, fe(e(x), (n, s) => (m(), u("button", {
|
|
118
|
+
key: s,
|
|
119
|
+
type: "button",
|
|
120
|
+
class: r(e(o).e("shortcut")),
|
|
121
|
+
onClick: (Ve) => e(X)(n)
|
|
122
|
+
}, L(n.text), 11, De))), 128))
|
|
123
|
+
], 2)) : N("", !0),
|
|
124
|
+
l("div", {
|
|
125
|
+
class: r(e(o).e("body"))
|
|
126
|
+
}, [
|
|
127
|
+
l("div", {
|
|
128
|
+
class: r(V.value.content)
|
|
129
|
+
}, [
|
|
130
|
+
l("div", {
|
|
131
|
+
class: r(e(b).e("header"))
|
|
132
|
+
}, [
|
|
133
|
+
l("button", {
|
|
134
|
+
type: "button",
|
|
135
|
+
class: r(V.value.arrowLeftBtn),
|
|
136
|
+
onClick: a[0] || (a[0] = //@ts-ignore
|
|
137
|
+
(...n) => e(A) && e(A)(...n))
|
|
138
|
+
}, [
|
|
139
|
+
p(e(y), { icon: "icon-d-arrow-left" })
|
|
140
|
+
], 2),
|
|
141
|
+
t.unlinkPanels ? (m(), u("button", {
|
|
142
|
+
key: 0,
|
|
143
|
+
type: "button",
|
|
144
|
+
disabled: !R.value,
|
|
145
|
+
class: r(V.value.arrowRightBtn),
|
|
146
|
+
onClick: a[1] || (a[1] = //@ts-ignore
|
|
147
|
+
(...n) => e(F) && e(F)(...n))
|
|
148
|
+
}, [
|
|
149
|
+
p(e(y), { icon: "icon-d-arrow-right" })
|
|
150
|
+
], 10, _e)) : N("", !0),
|
|
151
|
+
l("div", null, L(e(ee)), 1)
|
|
152
|
+
], 2),
|
|
153
|
+
p(H, {
|
|
154
|
+
"selection-mode": "range",
|
|
155
|
+
date: g.value,
|
|
156
|
+
"min-date": e(P),
|
|
157
|
+
"max-date": e(w),
|
|
158
|
+
"range-state": e(S),
|
|
159
|
+
"disabled-date": e(v),
|
|
160
|
+
onChangerange: e(T),
|
|
161
|
+
onPick: j,
|
|
162
|
+
onSelect: e(Y)
|
|
163
|
+
}, null, 8, ["date", "min-date", "max-date", "range-state", "disabled-date", "onChangerange", "onSelect"])
|
|
164
|
+
], 2),
|
|
165
|
+
l("div", {
|
|
166
|
+
class: r(B.value.content)
|
|
167
|
+
}, [
|
|
168
|
+
l("div", {
|
|
169
|
+
class: r(e(b).e("header"))
|
|
170
|
+
}, [
|
|
171
|
+
t.unlinkPanels ? (m(), u("button", {
|
|
172
|
+
key: 0,
|
|
173
|
+
type: "button",
|
|
174
|
+
disabled: !R.value,
|
|
175
|
+
class: r(B.value.arrowLeftBtn),
|
|
176
|
+
onClick: a[2] || (a[2] = //@ts-ignore
|
|
177
|
+
(...n) => e(U) && e(U)(...n))
|
|
178
|
+
}, [
|
|
179
|
+
p(e(y), { icon: "icon-d-arrow-left" })
|
|
180
|
+
], 10, Se)) : N("", !0),
|
|
181
|
+
l("button", {
|
|
182
|
+
type: "button",
|
|
183
|
+
class: r(B.value.arrowRightBtn),
|
|
184
|
+
onClick: a[3] || (a[3] = //@ts-ignore
|
|
185
|
+
(...n) => e(O) && e(O)(...n))
|
|
186
|
+
}, [
|
|
187
|
+
p(e(y), { icon: "icon-d-arrow-right" })
|
|
188
|
+
], 2),
|
|
189
|
+
l("div", null, L(e(te)), 1)
|
|
190
|
+
], 2),
|
|
191
|
+
p(H, {
|
|
192
|
+
"selection-mode": "range",
|
|
193
|
+
date: c.value,
|
|
194
|
+
"min-date": e(P),
|
|
195
|
+
"max-date": e(w),
|
|
196
|
+
"range-state": e(S),
|
|
197
|
+
"disabled-date": e(v),
|
|
198
|
+
onChangerange: e(T),
|
|
199
|
+
onPick: j,
|
|
200
|
+
onSelect: e(Y)
|
|
201
|
+
}, null, 8, ["date", "min-date", "max-date", "range-state", "disabled-date", "onChangerange", "onSelect"])
|
|
202
|
+
], 2)
|
|
203
|
+
], 2)
|
|
204
|
+
], 2)
|
|
205
|
+
], 2));
|
|
206
|
+
}
|
|
207
|
+
});
|
|
208
|
+
export {
|
|
209
|
+
$e as default
|
|
210
|
+
};
|