naive-ui 2.23.2 → 2.24.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/README.zh-CN.md +1 -1
- package/es/_internal/clear/src/Clear.d.ts +8 -10
- package/es/_internal/close/src/Close.d.ts +11 -10
- package/es/_internal/fade-in-expand-transition/src/FadeInExpandTransition.d.ts +10 -20
- package/es/_internal/focus-detector/src/FocusDetector.d.ts +4 -7
- package/es/_internal/icon/src/Icon.d.ts +19 -20
- package/es/_internal/icon-switch-transition/src/IconSwitchTransition.d.ts +1 -1
- package/es/_internal/icons/Add.d.ts +1 -1
- package/es/_internal/icons/ArrowBack.d.ts +1 -1
- package/es/_internal/icons/ArrowDown.d.ts +1 -1
- package/es/_internal/icons/Attach.d.ts +1 -1
- package/es/_internal/icons/Backward.d.ts +1 -1
- package/es/_internal/icons/Cancel.d.ts +1 -1
- package/es/_internal/icons/Checkmark.d.ts +1 -1
- package/es/_internal/icons/ChevronDown.d.ts +1 -1
- package/es/_internal/icons/ChevronDownFilled.d.ts +1 -1
- package/es/_internal/icons/ChevronLeft.d.ts +1 -1
- package/es/_internal/icons/ChevronRight.d.ts +1 -1
- package/es/_internal/icons/Clear.d.ts +1 -1
- package/es/_internal/icons/Close.d.ts +1 -1
- package/es/_internal/icons/Date.d.ts +1 -1
- package/es/_internal/icons/Download.d.ts +1 -1
- package/es/_internal/icons/Empty.d.ts +1 -1
- package/es/_internal/icons/Error.d.ts +1 -1
- package/es/_internal/icons/Eye.d.ts +1 -1
- package/es/_internal/icons/EyeOff.d.ts +1 -1
- package/es/_internal/icons/FastBackward.d.ts +1 -1
- package/es/_internal/icons/FastForward.d.ts +1 -1
- package/es/_internal/icons/File.d.ts +1 -1
- package/es/_internal/icons/Filter.d.ts +1 -1
- package/es/_internal/icons/Forward.d.ts +1 -1
- package/es/_internal/icons/Info.d.ts +1 -1
- package/es/_internal/icons/More.d.ts +1 -1
- package/es/_internal/icons/Photo.d.ts +1 -1
- package/es/_internal/icons/Remove.d.ts +1 -1
- package/es/_internal/icons/Retry.d.ts +1 -1
- package/es/_internal/icons/RotateClockwise.d.ts +1 -1
- package/es/_internal/icons/RotateCounterclockwise.d.ts +1 -1
- package/es/_internal/icons/Search.d.ts +1 -1
- package/es/_internal/icons/Success.d.ts +1 -1
- package/es/_internal/icons/Switcher.d.ts +1 -1
- package/es/_internal/icons/Switcher.js +2 -3
- package/es/_internal/icons/Time.d.ts +1 -1
- package/es/_internal/icons/To.d.ts +1 -1
- package/es/_internal/icons/Trash.d.ts +1 -1
- package/es/_internal/icons/Warning.d.ts +1 -1
- package/es/_internal/icons/ZoomIn.d.ts +1 -1
- package/es/_internal/icons/ZoomOut.d.ts +1 -1
- package/es/_internal/icons/replaceable.d.ts +1 -1
- package/es/_internal/loading/src/Loading.d.ts +26 -16
- package/es/_internal/menu-mask/src/MenuMask.d.ts +6 -5
- package/es/_internal/scrollbar/src/ScrollBar.d.ts +54 -58
- package/es/_internal/scrollbar/src/ScrollBar.js +90 -68
- package/es/_internal/select-menu/src/SelectGroupHeader.d.ts +10 -7
- package/es/_internal/select-menu/src/SelectMenu.d.ts +67 -63
- package/es/_internal/select-menu/src/SelectMenu.js +22 -21
- package/es/_internal/select-menu/src/SelectOption.d.ts +10 -7
- package/es/_internal/select-menu/src/interface.d.ts +3 -3
- package/es/_internal/select-menu/src/interface.js +3 -2
- package/es/_internal/selection/src/Selection.d.ts +67 -69
- package/es/_internal/selection/src/Selection.js +25 -8
- package/es/_internal/selection/src/styles/index.cssr.js +2 -1
- package/es/_internal/selection/styles/_common.d.ts +1 -0
- package/es/_internal/selection/styles/_common.js +2 -1
- package/es/_internal/selection/styles/light.d.ts +2 -0
- package/es/_internal/slot-machine/src/SlotMachine.d.ts +18 -12
- package/es/_internal/slot-machine/src/SlotMachineNumber.d.ts +18 -12
- package/es/_internal/suffix/src/Suffix.d.ts +19 -14
- package/es/_internal/suffix/src/Suffix.js +7 -2
- package/es/_internal/wave/src/Wave.d.ts +6 -5
- package/es/_mixins/use-form-item.d.ts +2 -2
- package/es/_mixins/use-form-item.js +2 -1
- package/es/_mixins/use-locale.d.ts +1 -1
- package/es/_mixins/use-locale.js +1 -1
- package/es/_utils/index.d.ts +1 -1
- package/es/_utils/index.js +1 -1
- package/es/_utils/vue/create-injection-key.d.ts +2 -0
- package/es/_utils/vue/create-injection-key.js +3 -0
- package/es/_utils/vue/index.d.ts +2 -0
- package/es/_utils/vue/index.js +2 -0
- package/es/_utils/vue/resolve-slot.d.ts +2 -0
- package/es/_utils/vue/resolve-slot.js +20 -0
- package/es/affix/src/Affix.d.ts +26 -22
- package/es/alert/src/Alert.d.ts +34 -27
- package/es/alert/src/Alert.js +2 -4
- package/es/anchor/src/AnchorAdapter.d.ts +52 -47
- package/es/anchor/src/BaseAnchor.d.ts +25 -20
- package/es/anchor/src/Link.d.ts +6 -9
- package/es/anchor/src/Link.js +6 -5
- package/es/auto-complete/src/AutoComplete.d.ts +60 -67
- package/es/auto-complete/src/AutoComplete.js +13 -15
- package/es/avatar/src/Avatar.d.ts +27 -30
- package/es/avatar/src/AvatarGroup.d.ts +13 -17
- package/es/avatar/src/AvatarGroup.js +5 -2
- package/es/back-top/src/BackTop.d.ts +50 -35
- package/es/back-top/src/BackTop.js +2 -4
- package/es/badge/src/Badge.d.ts +31 -29
- package/es/badge/src/Badge.js +6 -5
- package/es/breadcrumb/src/Breadcrumb.d.ts +15 -18
- package/es/breadcrumb/src/Breadcrumb.js +2 -1
- package/es/breadcrumb/src/BreadcrumbItem.d.ts +4 -7
- package/es/button/src/Button.d.ts +53 -61
- package/es/button/src/Button.js +5 -2
- package/es/button/src/ButtonGroup.d.ts +10 -11
- package/es/button/src/ButtonGroup.js +2 -1
- package/es/calendar/src/Calendar.d.ts +24 -25
- package/es/calendar/src/Calendar.js +31 -6
- package/es/calendar/src/interface.d.ts +4 -0
- package/es/card/src/Card.d.ts +32 -37
- package/es/card/src/Card.js +6 -6
- package/es/carousel/index.d.ts +1 -0
- package/es/carousel/index.js +1 -0
- package/es/carousel/src/Carousel.d.ts +267 -41
- package/es/carousel/src/Carousel.js +679 -228
- package/es/carousel/src/CarouselArrow.d.ts +9 -0
- package/es/carousel/src/CarouselArrow.js +43 -0
- package/es/carousel/src/CarouselDots.d.ts +72 -0
- package/es/carousel/src/CarouselDots.js +118 -0
- package/es/carousel/src/CarouselItem.d.ts +11 -0
- package/es/carousel/src/CarouselItem.js +75 -0
- package/es/carousel/src/interface.d.ts +35 -0
- package/es/carousel/src/interface.js +3 -0
- package/es/carousel/src/styles/index.cssr.js +141 -38
- package/es/carousel/src/utils.d.ts +12 -0
- package/es/carousel/src/utils.js +58 -0
- package/es/carousel/styles/light.d.ts +3 -0
- package/es/carousel/styles/light.js +5 -2
- package/es/cascader/index.d.ts +1 -1
- package/es/cascader/src/Cascader.d.ts +109 -84
- package/es/cascader/src/Cascader.js +16 -27
- package/es/cascader/src/CascaderMenu.d.ts +34 -24
- package/es/cascader/src/CascaderMenu.js +2 -4
- package/es/cascader/src/CascaderOption.d.ts +8 -5
- package/es/cascader/src/CascaderOption.js +7 -4
- package/es/cascader/src/CascaderSelectMenu.d.ts +26 -20
- package/es/cascader/src/CascaderSubmenu.d.ts +16 -9
- package/es/cascader/src/interface.d.ts +7 -2
- package/es/cascader/src/interface.js +2 -1
- package/es/cascader/styles/light.d.ts +1 -0
- package/es/checkbox/index.d.ts +1 -0
- package/es/checkbox/src/Checkbox.d.ts +43 -43
- package/es/checkbox/src/Checkbox.js +17 -5
- package/es/checkbox/src/CheckboxGroup.d.ts +23 -24
- package/es/checkbox/src/CheckboxGroup.js +2 -2
- package/es/checkbox/src/interface.d.ts +4 -0
- package/es/checkbox/src/styles/index.cssr.js +1 -1
- package/es/code/src/Code.d.ts +27 -30
- package/es/code/src/Code.js +6 -3
- package/es/code/src/styles/index.cssr.js +5 -2
- package/es/collapse/src/Collapse.d.ts +35 -33
- package/es/collapse/src/Collapse.js +2 -2
- package/es/collapse/src/CollapseItem.d.ts +5 -9
- package/es/collapse/src/CollapseItem.js +8 -15
- package/es/collapse/src/CollapseItemContent.d.ts +11 -9
- package/es/collapse-transition/src/CollapseTransition.d.ts +18 -19
- package/es/color-picker/src/AlphaSlider.d.ts +19 -14
- package/es/color-picker/src/ColorInput.d.ts +34 -19
- package/es/color-picker/src/ColorInputUnit.d.ts +15 -11
- package/es/color-picker/src/ColorInputUnit.js +2 -2
- package/es/color-picker/src/ColorPicker.d.ts +55 -52
- package/es/color-picker/src/ColorPicker.js +17 -10
- package/es/color-picker/src/ColorPickerSwatches.d.ts +18 -11
- package/es/color-picker/src/ColorPickerTrigger.d.ts +15 -12
- package/es/color-picker/src/ColorPickerTrigger.js +23 -17
- package/es/color-picker/src/ColorPreview.d.ts +19 -11
- package/es/color-picker/src/HueSlider.d.ts +15 -12
- package/es/color-picker/src/Pallete.d.ts +23 -16
- package/es/color-picker/src/interface.d.ts +2 -0
- package/es/color-picker/src/styles/index.cssr.js +1 -0
- package/es/composables/use-theme-vars.d.ts +2 -1
- package/es/config-provider/src/ConfigProvider.d.ts +57 -37
- package/es/config-provider/src/ConfigProvider.js +6 -5
- package/es/config-provider/src/interface.d.ts +4 -1
- package/es/countdown/src/Countdown.d.ts +18 -17
- package/es/data-table/index.d.ts +1 -1
- package/es/data-table/src/DataTable.d.ts +114 -159
- package/es/data-table/src/DataTable.js +23 -49
- package/es/data-table/src/HeaderButton/FilterButton.d.ts +12 -7
- package/es/data-table/src/HeaderButton/FilterMenu.d.ts +36 -19
- package/es/data-table/src/HeaderButton/RenderFilter.d.ts +14 -9
- package/es/data-table/src/HeaderButton/RenderSorter.d.ts +10 -7
- package/es/data-table/src/HeaderButton/SortButton.d.ts +6 -5
- package/es/data-table/src/HeaderButton/SortButton.js +6 -6
- package/es/data-table/src/MainTable.d.ts +1 -1
- package/es/data-table/src/TableParts/Body.d.ts +13 -14
- package/es/data-table/src/TableParts/Body.js +2 -4
- package/es/data-table/src/TableParts/BodyCheckbox.d.ts +14 -9
- package/es/data-table/src/TableParts/Cell.d.ts +865 -855
- package/es/data-table/src/TableParts/ExpandTrigger.d.ts +11 -9
- package/es/data-table/src/TableParts/Header.d.ts +8 -5
- package/es/data-table/src/TableParts/SelectionMenu.d.ts +6 -5
- package/es/data-table/src/interface.d.ts +10 -7
- package/es/data-table/src/interface.js +2 -1
- package/es/data-table/src/styles/index.cssr.js +11 -8
- package/es/data-table/src/utils.js +4 -1
- package/es/data-table/styles/light.d.ts +1 -0
- package/es/date-picker/index.d.ts +1 -0
- package/es/date-picker/src/DatePicker.d.ts +87 -104
- package/es/date-picker/src/DatePicker.js +117 -112
- package/es/date-picker/src/interface.d.ts +23 -5
- package/es/date-picker/src/interface.js +2 -1
- package/es/date-picker/src/panel/date.d.ts +77 -34
- package/es/date-picker/src/panel/date.js +6 -7
- package/es/date-picker/src/panel/daterange.d.ts +31 -26
- package/es/date-picker/src/panel/daterange.js +6 -9
- package/es/date-picker/src/panel/datetime.d.ts +41 -30
- package/es/date-picker/src/panel/datetime.js +4 -5
- package/es/date-picker/src/panel/datetimerange.d.ts +31 -26
- package/es/date-picker/src/panel/datetimerange.js +5 -8
- package/es/date-picker/src/panel/month.d.ts +48 -32
- package/es/date-picker/src/panel/month.js +13 -4
- package/es/date-picker/src/panel/panelHeader.d.ts +2435 -0
- package/es/date-picker/src/panel/panelHeader.js +72 -0
- package/es/date-picker/src/panel/use-calendar.d.ts +16 -4
- package/es/date-picker/src/panel/use-calendar.js +44 -5
- package/es/date-picker/src/panel/use-dual-calendar.d.ts +6 -0
- package/es/date-picker/src/panel/use-dual-calendar.js +10 -1
- package/es/date-picker/src/panel/use-panel-common.d.ts +2 -0
- package/es/date-picker/src/panel/use-panel-common.js +7 -1
- package/es/date-picker/src/styles/index.cssr.js +5 -2
- package/es/descriptions/src/Descriptions.d.ts +33 -33
- package/es/descriptions/src/DescriptionsItem.d.ts +9 -12
- package/es/dialog/src/Dialog.d.ts +32 -43
- package/es/dialog/src/Dialog.js +27 -20
- package/es/dialog/src/DialogEnvironment.d.ts +41 -46
- package/es/dialog/src/DialogProvider.d.ts +7 -10
- package/es/dialog/src/DialogProvider.js +3 -3
- package/es/divider/src/Divider.d.ts +14 -19
- package/es/drawer/src/Drawer.d.ts +101 -104
- package/es/drawer/src/Drawer.js +43 -49
- package/es/drawer/src/DrawerBodyWrapper.d.ts +40 -16
- package/es/drawer/src/DrawerBodyWrapper.js +31 -14
- package/es/drawer/src/DrawerContent.d.ts +15 -20
- package/es/drawer/src/DrawerContent.js +6 -6
- package/es/drawer/src/interface.d.ts +3 -3
- package/es/drawer/src/interface.js +3 -2
- package/es/dropdown/src/Dropdown.d.ts +113 -99
- package/es/dropdown/src/Dropdown.js +2 -2
- package/es/dropdown/src/DropdownDivider.d.ts +6 -5
- package/es/dropdown/src/DropdownGroup.d.ts +14 -9
- package/es/dropdown/src/DropdownGroupHeader.d.ts +10 -7
- package/es/dropdown/src/DropdownMenu.d.ts +18 -16
- package/es/dropdown/src/DropdownMenu.js +2 -1
- package/es/dropdown/src/DropdownOption.d.ts +19 -14
- package/es/dropdown/src/DropdownOption.js +2 -2
- package/es/dropdown/src/DropdownRenderOption.d.ts +6 -5
- package/es/dynamic-input/src/DynamicInput.d.ts +50 -45
- package/es/dynamic-input/src/DynamicInput.js +2 -2
- package/es/dynamic-input/src/InputPreset.d.ts +16 -14
- package/es/dynamic-input/src/PairPreset.d.ts +23 -18
- package/es/dynamic-input/src/interface.d.ts +2 -2
- package/es/dynamic-input/src/interface.js +2 -1
- package/es/dynamic-tags/src/DynamicTags.d.ts +41 -41
- package/es/element/src/Element.d.ts +9 -12
- package/es/ellipsis/src/Ellipsis.d.ts +14 -19
- package/es/empty/src/Empty.d.ts +23 -24
- package/es/empty/src/Empty.js +5 -9
- package/es/form/src/Feedbacks.d.ts +8 -10
- package/es/form/src/Feedbacks.js +4 -1
- package/es/form/src/Form.d.ts +44 -44
- package/es/form/src/Form.js +17 -8
- package/es/form/src/FormItem.d.ts +45 -55
- package/es/form/src/FormItem.js +30 -14
- package/es/form/src/FormItemCol.d.ts +57 -60
- package/es/form/src/FormItemGridItem.d.ts +57 -66
- package/es/form/src/FormItemRow.d.ts +62 -65
- package/es/form/src/interface.d.ts +8 -4
- package/es/form/src/interface.js +3 -2
- package/es/form/src/styles/form-item.cssr.js +2 -0
- package/es/form/src/utils.d.ts +2 -2
- package/es/form/src/utils.js +29 -18
- package/es/global-style/src/GlobalStyle.d.ts +1 -1
- package/es/gradient-text/src/GradientText.d.ts +16 -23
- package/es/grid/src/Grid.d.ts +27 -22
- package/es/grid/src/Grid.js +2 -2
- package/es/grid/src/GridItem.d.ts +18 -18
- package/es/grid/src/GridItem.js +3 -2
- package/es/icon/src/Icon.d.ts +11 -18
- package/es/image/src/Image.d.ts +295 -39
- package/es/image/src/Image.js +4 -17
- package/es/image/src/ImageGroup.d.ts +274 -8
- package/es/image/src/ImageGroup.js +7 -9
- package/es/image/src/ImagePreview.d.ts +203 -18
- package/es/image/src/ImagePreview.js +59 -36
- package/es/image/src/interface.d.ts +94 -0
- package/es/image/src/interface.js +2 -1
- package/es/image/src/styles/index.cssr.js +8 -4
- package/es/image/styles/dark.js +8 -1
- package/es/image/styles/light.d.ts +32 -3
- package/es/image/styles/light.js +8 -1
- package/es/index.d.ts +1 -1
- package/es/index.js +1 -1
- package/es/input/src/Input.d.ts +108 -110
- package/es/input/src/Input.js +75 -34
- package/es/input/src/InputGroup.d.ts +5 -9
- package/es/input/src/InputGroupLabel.d.ts +16 -17
- package/es/input/src/InputGroupLabel.js +4 -3
- package/es/input/src/WordCount.d.ts +1 -1
- package/es/input/src/interface.d.ts +2 -2
- package/es/input/src/interface.js +2 -1
- package/es/input/src/styles/input.cssr.js +45 -62
- package/es/input-number/src/InputNumber.d.ts +59 -58
- package/es/input-number/src/utils.js +2 -2
- package/es/layout/src/Layout.d.ts +90 -65
- package/es/layout/src/Layout.js +2 -1
- package/es/layout/src/LayoutContent.d.ts +33 -31
- package/es/layout/src/LayoutFooter.d.ts +14 -19
- package/es/layout/src/LayoutHeader.d.ts +17 -19
- package/es/layout/src/LayoutSider.d.ts +64 -61
- package/es/layout/src/LayoutSider.js +2 -1
- package/es/layout/src/ToggleBar.d.ts +7 -8
- package/es/layout/src/ToggleButton.d.ts +7 -8
- package/es/layout/src/interface.d.ts +2 -2
- package/es/layout/src/interface.js +2 -1
- package/es/layout/src/styles/layout-sider.cssr.js +15 -7
- package/es/legacy-grid/src/Col.d.ts +18 -11
- package/es/legacy-grid/src/Row.d.ts +11 -13
- package/es/legacy-grid/src/Row.js +2 -2
- package/es/list/src/List.d.ts +19 -20
- package/es/list/src/List.js +7 -5
- package/es/list/src/ListItem.d.ts +1 -1
- package/es/list/src/ListItem.js +3 -3
- package/es/loading-bar/src/LoadingBar.d.ts +1 -1
- package/es/loading-bar/src/LoadingBarProvider.d.ts +22 -23
- package/es/loading-bar/src/LoadingBarProvider.js +7 -6
- package/es/locales/common/deDE.js +10 -0
- package/es/locales/common/enUS.d.ts +9 -0
- package/es/locales/common/enUS.js +10 -0
- package/es/locales/common/esAR.d.ts +109 -0
- package/es/locales/common/esAR.js +110 -0
- package/es/locales/common/frFR.js +10 -0
- package/es/locales/common/idID.js +10 -0
- package/es/locales/common/itIT.d.ts +3 -0
- package/es/locales/common/itIT.js +109 -0
- package/es/locales/common/jaJP.js +10 -0
- package/es/locales/common/nbNO.js +10 -0
- package/es/locales/common/ruRU.js +10 -0
- package/es/locales/common/ukUA.js +10 -0
- package/es/locales/common/zhCN.js +9 -0
- package/es/locales/common/zhTW.js +10 -0
- package/es/locales/date/esAR.d.ts +3 -0
- package/es/locales/date/esAR.js +6 -0
- package/es/locales/date/itIT.d.ts +3 -0
- package/es/locales/date/itIT.js +6 -0
- package/es/locales/index.d.ts +4 -0
- package/es/locales/index.js +4 -0
- package/es/log/src/Log.d.ts +48 -46
- package/es/log/src/Log.js +2 -2
- package/es/log/src/LogLine.d.ts +6 -5
- package/es/log/src/LogLoader.d.ts +6 -5
- package/es/mention/src/Mention.d.ts +55 -56
- package/es/mention/src/utils.js +0 -1
- package/es/menu/src/Menu.d.ts +87 -88
- package/es/menu/src/Menu.js +2 -2
- package/es/menu/src/MenuDivider.d.ts +1 -1
- package/es/menu/src/MenuOption.d.ts +22 -295
- package/es/menu/src/MenuOption.js +2 -1
- package/es/menu/src/MenuOptionContent.d.ts +33 -305
- package/es/menu/src/MenuOptionGroup.d.ts +20 -20
- package/es/menu/src/MenuOptionGroup.js +4 -3
- package/es/menu/src/Submenu.d.ts +35 -301
- package/es/menu/src/Submenu.js +4 -2
- package/es/menu/src/use-menu-child-props.d.ts +2 -1
- package/es/menu/src/use-menu-child.d.ts +5 -7
- package/es/menu/src/use-menu-child.js +0 -2
- package/es/message/index.d.ts +2 -1
- package/es/message/src/Message.d.ts +183 -31
- package/es/message/src/Message.js +13 -11
- package/es/message/src/MessageEnvironment.d.ts +28 -36
- package/es/message/src/MessageProvider.d.ts +29 -40
- package/es/message/src/MessageProvider.js +9 -9
- package/es/message/src/message-props.d.ts +5 -2
- package/es/message/src/types.d.ts +15 -0
- package/es/message/src/types.js +1 -0
- package/es/modal/src/BodyWrapper.d.ts +96 -72
- package/es/modal/src/BodyWrapper.js +12 -9
- package/es/modal/src/Modal.d.ts +127 -965
- package/es/modal/src/Modal.js +18 -5
- package/es/modal/src/interface.d.ts +3 -3
- package/es/modal/src/interface.js +3 -2
- package/es/notification/src/Notification.d.ts +20 -22
- package/es/notification/src/NotificationContainer.d.ts +10 -7
- package/es/notification/src/NotificationEnvironment.d.ts +32 -40
- package/es/notification/src/NotificationProvider.d.ts +32 -35
- package/es/notification/src/NotificationProvider.js +8 -8
- package/es/number-animation/src/NumberAnimation.d.ts +27 -15
- package/es/number-animation/src/NumberAnimation.js +19 -4
- package/es/page-header/index.d.ts +1 -1
- package/es/page-header/src/PageHeader.d.ts +13 -21
- package/es/page-header/src/PageHeader.js +4 -5
- package/es/pagination/index.d.ts +1 -1
- package/es/pagination/src/Pagination.d.ts +65 -61
- package/es/pagination/src/Pagination.js +66 -19
- package/es/pagination/src/interface.d.ts +10 -1
- package/es/pagination/src/utils.d.ts +2 -2
- package/es/pagination/src/utils.js +2 -4
- package/es/pagination/styles/light.d.ts +1 -0
- package/es/popconfirm/src/Popconfirm.d.ts +93 -85
- package/es/popconfirm/src/PopconfirmPanel.d.ts +16 -14
- package/es/popconfirm/src/PopconfirmPanel.js +4 -5
- package/es/popconfirm/src/interface.d.ts +2 -2
- package/es/popconfirm/src/interface.js +2 -1
- package/es/popover/src/Popover.d.ts +93 -77
- package/es/popover/src/Popover.js +24 -1
- package/es/popover/src/PopoverBody.d.ts +35 -51
- package/es/popover/src/PopoverBody.js +32 -47
- package/es/popover/src/interface.d.ts +2 -2
- package/es/popover/src/interface.js +2 -1
- package/es/popover/src/styles/index.cssr.js +9 -8
- package/es/popselect/src/Popselect.d.ts +139 -155
- package/es/popselect/src/Popselect.js +2 -2
- package/es/popselect/src/PopselectPanel.d.ts +24 -30
- package/es/popselect/src/interface.d.ts +2 -2
- package/es/popselect/src/interface.js +2 -1
- package/es/progress/src/Circle.d.ts +40 -26
- package/es/progress/src/Circle.js +8 -1
- package/es/progress/src/Line.d.ts +37 -32
- package/es/progress/src/Line.js +4 -1
- package/es/progress/src/MultipleCircle.d.ts +38 -21
- package/es/progress/src/Progress.d.ts +57 -50
- package/es/progress/src/Progress.js +2 -2
- package/es/progress/src/styles/index.cssr.js +16 -16
- package/es/radio/src/Radio.d.ts +30 -31
- package/es/radio/src/RadioButton.d.ts +24 -22
- package/es/radio/src/RadioGroup.d.ts +21 -27
- package/es/radio/src/styles/radio.cssr.js +4 -1
- package/es/radio/src/use-radio.d.ts +2 -2
- package/es/radio/src/use-radio.js +2 -2
- package/es/rate/src/Rate.d.ts +26 -31
- package/es/result/src/Result.d.ts +18 -21
- package/es/result/src/Result.js +9 -10
- package/es/result/src/styles/index.cssr.js +7 -7
- package/es/scrollbar/src/ScrollBar.d.ts +10 -17
- package/es/select/index.d.ts +1 -1
- package/es/select/src/Select.d.ts +134 -121
- package/es/select/src/Select.js +41 -64
- package/es/select/src/interface.d.ts +4 -0
- package/es/select/styles/light.d.ts +1 -0
- package/es/skeleton/src/Skeleton.d.ts +26 -31
- package/es/slider/src/Slider.d.ts +51 -51
- package/es/slider/src/Slider.js +2 -1
- package/es/space/src/Space.d.ts +24 -27
- package/es/spin/src/Spin.d.ts +28 -27
- package/es/statistic/src/Statistic.d.ts +11 -19
- package/es/statistic/src/Statistic.js +3 -3
- package/es/steps/src/Step.d.ts +9 -12
- package/es/steps/src/Step.js +5 -7
- package/es/steps/src/Steps.d.ts +20 -23
- package/es/steps/src/Steps.js +2 -2
- package/es/switch/src/Switch.d.ts +45 -40
- package/es/table/src/Table.d.ts +26 -25
- package/es/table/src/Tbody.d.ts +1 -1
- package/es/table/src/Td.d.ts +1 -1
- package/es/table/src/Th.d.ts +1 -1
- package/es/table/src/Thead.d.ts +1 -1
- package/es/table/src/Tr.d.ts +1 -1
- package/es/tabs/index.d.ts +1 -0
- package/es/tabs/src/Tab.d.ts +30 -37
- package/es/tabs/src/Tab.js +11 -4
- package/es/tabs/src/TabPane.d.ts +32 -38
- package/es/tabs/src/TabPane.js +14 -15
- package/es/tabs/src/Tabs.d.ts +39 -54
- package/es/tabs/src/Tabs.js +27 -24
- package/es/tabs/src/interface.d.ts +5 -2
- package/es/tabs/src/interface.js +2 -1
- package/es/tag/src/Tag.d.ts +42 -47
- package/es/tag/src/Tag.js +2 -2
- package/es/theme-editor/src/ThemeEditor.d.ts +1 -1
- package/es/theme-editor/src/ThemeEditor.js +161 -158
- package/es/themes/index.d.ts +1 -0
- package/es/themes/index.js +1 -0
- package/es/thing/src/Thing.d.ts +16 -23
- package/es/thing/src/Thing.js +20 -24
- package/es/time/src/Time.d.ts +18 -18
- package/es/time-picker/index.d.ts +1 -0
- package/es/time-picker/src/Panel.d.ts +75 -72
- package/es/time-picker/src/PanelCol.d.ts +15 -12
- package/es/time-picker/src/TimePicker.d.ts +110 -77
- package/es/time-picker/src/TimePicker.js +76 -70
- package/es/time-picker/src/interface.d.ts +10 -4
- package/es/time-picker/src/interface.js +2 -1
- package/es/timeline/src/Timeline.d.ts +21 -24
- package/es/timeline/src/Timeline.js +2 -1
- package/es/timeline/src/TimelineItem.d.ts +10 -14
- package/es/timeline/src/TimelineItem.js +4 -4
- package/es/tooltip/src/Tooltip.d.ts +85 -75
- package/es/transfer/src/Transfer.d.ts +39 -43
- package/es/transfer/src/TransferFilter.d.ts +17 -16
- package/es/transfer/src/TransferHeader.d.ts +11 -10
- package/es/transfer/src/TransferList.d.ts +35 -19
- package/es/transfer/src/TransferListItem.d.ts +18 -11
- package/es/transfer/src/interface.d.ts +2 -2
- package/es/transfer/src/interface.js +2 -1
- package/es/tree/src/MotionWrapper.d.ts +19 -14
- package/es/tree/src/Tree.d.ts +127 -134
- package/es/tree/src/Tree.js +4 -2
- package/es/tree/src/TreeNode.d.ts +10 -7
- package/es/tree/src/TreeNodeCheckbox.d.ts +11 -16
- package/es/tree/src/TreeNodeContent.d.ts +15 -18
- package/es/tree/src/TreeNodeSwitcher.d.ts +10 -14
- package/es/tree/src/TreeNodeSwitcher.js +25 -14
- package/es/tree/src/interface.d.ts +4 -2
- package/es/tree/src/interface.js +2 -1
- package/es/tree/src/styles/index.cssr.js +4 -2
- package/es/tree-select/src/TreeSelect.d.ts +112 -97
- package/es/tree-select/src/TreeSelect.js +2 -4
- package/es/tree-select/src/interface.d.ts +2 -2
- package/es/tree-select/src/interface.js +2 -1
- package/es/tree-select/styles/light.d.ts +1 -0
- package/es/typography/src/a.d.ts +8 -12
- package/es/typography/src/blockquote.d.ts +9 -15
- package/es/typography/src/create-header.d.ts +14 -19
- package/es/typography/src/headers.d.ts +84 -114
- package/es/typography/src/hr.d.ts +8 -12
- package/es/typography/src/li.d.ts +1 -1
- package/es/typography/src/ol.d.ts +9 -15
- package/es/typography/src/p.d.ts +9 -14
- package/es/typography/src/text.d.ts +24 -31
- package/es/typography/src/text.js +4 -3
- package/es/typography/src/ul.d.ts +9 -15
- package/es/upload/src/Upload.d.ts +95 -85
- package/es/upload/src/Upload.js +22 -10
- package/es/upload/src/UploadDragger.d.ts +1 -1
- package/es/upload/src/UploadFile.d.ts +18 -13
- package/es/upload/src/UploadFileList.d.ts +1 -1
- package/es/upload/src/UploadFileList.js +2 -2
- package/es/upload/src/UploadProgress.d.ts +11 -9
- package/es/upload/src/UploadTrigger.d.ts +3 -5
- package/es/upload/src/interface.d.ts +14 -6
- package/es/upload/src/interface.js +2 -1
- package/es/version.d.ts +1 -1
- package/es/version.js +1 -1
- package/lib/_internal/clear/src/Clear.d.ts +8 -10
- package/lib/_internal/close/src/Close.d.ts +11 -10
- package/lib/_internal/fade-in-expand-transition/src/FadeInExpandTransition.d.ts +10 -20
- package/lib/_internal/focus-detector/src/FocusDetector.d.ts +4 -7
- package/lib/_internal/icon/src/Icon.d.ts +19 -20
- package/lib/_internal/icon-switch-transition/src/IconSwitchTransition.d.ts +1 -1
- package/lib/_internal/icons/Add.d.ts +1 -1
- package/lib/_internal/icons/ArrowBack.d.ts +1 -1
- package/lib/_internal/icons/ArrowDown.d.ts +1 -1
- package/lib/_internal/icons/Attach.d.ts +1 -1
- package/lib/_internal/icons/Backward.d.ts +1 -1
- package/lib/_internal/icons/Cancel.d.ts +1 -1
- package/lib/_internal/icons/Checkmark.d.ts +1 -1
- package/lib/_internal/icons/ChevronDown.d.ts +1 -1
- package/lib/_internal/icons/ChevronDownFilled.d.ts +1 -1
- package/lib/_internal/icons/ChevronLeft.d.ts +1 -1
- package/lib/_internal/icons/ChevronRight.d.ts +1 -1
- package/lib/_internal/icons/Clear.d.ts +1 -1
- package/lib/_internal/icons/Close.d.ts +1 -1
- package/lib/_internal/icons/Date.d.ts +1 -1
- package/lib/_internal/icons/Download.d.ts +1 -1
- package/lib/_internal/icons/Empty.d.ts +1 -1
- package/lib/_internal/icons/Error.d.ts +1 -1
- package/lib/_internal/icons/Eye.d.ts +1 -1
- package/lib/_internal/icons/EyeOff.d.ts +1 -1
- package/lib/_internal/icons/FastBackward.d.ts +1 -1
- package/lib/_internal/icons/FastForward.d.ts +1 -1
- package/lib/_internal/icons/File.d.ts +1 -1
- package/lib/_internal/icons/Filter.d.ts +1 -1
- package/lib/_internal/icons/Forward.d.ts +1 -1
- package/lib/_internal/icons/Info.d.ts +1 -1
- package/lib/_internal/icons/More.d.ts +1 -1
- package/lib/_internal/icons/Photo.d.ts +1 -1
- package/lib/_internal/icons/Remove.d.ts +1 -1
- package/lib/_internal/icons/Retry.d.ts +1 -1
- package/lib/_internal/icons/RotateClockwise.d.ts +1 -1
- package/lib/_internal/icons/RotateCounterclockwise.d.ts +1 -1
- package/lib/_internal/icons/Search.d.ts +1 -1
- package/lib/_internal/icons/Success.d.ts +1 -1
- package/lib/_internal/icons/Switcher.d.ts +1 -1
- package/lib/_internal/icons/Switcher.js +2 -3
- package/lib/_internal/icons/Time.d.ts +1 -1
- package/lib/_internal/icons/To.d.ts +1 -1
- package/lib/_internal/icons/Trash.d.ts +1 -1
- package/lib/_internal/icons/Warning.d.ts +1 -1
- package/lib/_internal/icons/ZoomIn.d.ts +1 -1
- package/lib/_internal/icons/ZoomOut.d.ts +1 -1
- package/lib/_internal/icons/replaceable.d.ts +1 -1
- package/lib/_internal/loading/src/Loading.d.ts +26 -16
- package/lib/_internal/menu-mask/src/MenuMask.d.ts +6 -5
- package/lib/_internal/scrollbar/src/ScrollBar.d.ts +54 -58
- package/lib/_internal/scrollbar/src/ScrollBar.js +89 -67
- package/lib/_internal/select-menu/src/SelectGroupHeader.d.ts +10 -7
- package/lib/_internal/select-menu/src/SelectMenu.d.ts +67 -63
- package/lib/_internal/select-menu/src/SelectMenu.js +21 -20
- package/lib/_internal/select-menu/src/SelectOption.d.ts +10 -7
- package/lib/_internal/select-menu/src/interface.d.ts +3 -3
- package/lib/_internal/select-menu/src/interface.js +3 -2
- package/lib/_internal/selection/src/Selection.d.ts +67 -69
- package/lib/_internal/selection/src/Selection.js +25 -8
- package/lib/_internal/selection/src/styles/index.cssr.js +2 -1
- package/lib/_internal/selection/styles/_common.d.ts +1 -0
- package/lib/_internal/selection/styles/_common.js +2 -1
- package/lib/_internal/selection/styles/light.d.ts +2 -0
- package/lib/_internal/slot-machine/src/SlotMachine.d.ts +18 -12
- package/lib/_internal/slot-machine/src/SlotMachineNumber.d.ts +18 -12
- package/lib/_internal/suffix/src/Suffix.d.ts +19 -14
- package/lib/_internal/suffix/src/Suffix.js +7 -2
- package/lib/_internal/wave/src/Wave.d.ts +6 -5
- package/lib/_mixins/use-form-item.d.ts +2 -2
- package/lib/_mixins/use-form-item.js +2 -1
- package/lib/_mixins/use-locale.d.ts +1 -1
- package/lib/_mixins/use-locale.js +2 -2
- package/lib/_utils/index.d.ts +1 -1
- package/lib/_utils/index.js +2 -1
- package/lib/_utils/vue/create-injection-key.d.ts +2 -0
- package/lib/_utils/vue/create-injection-key.js +7 -0
- package/lib/_utils/vue/index.d.ts +2 -0
- package/lib/_utils/vue/index.js +5 -1
- package/lib/_utils/vue/resolve-slot.d.ts +2 -0
- package/lib/_utils/vue/resolve-slot.js +24 -0
- package/lib/affix/src/Affix.d.ts +26 -22
- package/lib/alert/src/Alert.d.ts +34 -27
- package/lib/alert/src/Alert.js +1 -3
- package/lib/anchor/src/AnchorAdapter.d.ts +52 -47
- package/lib/anchor/src/BaseAnchor.d.ts +25 -20
- package/lib/anchor/src/Link.d.ts +6 -9
- package/lib/anchor/src/Link.js +4 -3
- package/lib/auto-complete/src/AutoComplete.d.ts +60 -67
- package/lib/auto-complete/src/AutoComplete.js +14 -16
- package/lib/avatar/src/Avatar.d.ts +27 -30
- package/lib/avatar/src/AvatarGroup.d.ts +13 -17
- package/lib/avatar/src/AvatarGroup.js +5 -2
- package/lib/back-top/src/BackTop.d.ts +50 -35
- package/lib/back-top/src/BackTop.js +1 -3
- package/lib/badge/src/Badge.d.ts +31 -29
- package/lib/badge/src/Badge.js +5 -4
- package/lib/breadcrumb/src/Breadcrumb.d.ts +15 -18
- package/lib/breadcrumb/src/Breadcrumb.js +2 -1
- package/lib/breadcrumb/src/BreadcrumbItem.d.ts +4 -7
- package/lib/button/src/Button.d.ts +53 -61
- package/lib/button/src/Button.js +4 -1
- package/lib/button/src/ButtonGroup.d.ts +10 -11
- package/lib/button/src/ButtonGroup.js +2 -1
- package/lib/calendar/src/Calendar.d.ts +24 -25
- package/lib/calendar/src/Calendar.js +30 -5
- package/lib/calendar/src/interface.d.ts +4 -0
- package/lib/card/src/Card.d.ts +32 -37
- package/lib/card/src/Card.js +5 -5
- package/lib/carousel/index.d.ts +1 -0
- package/lib/carousel/index.js +3 -1
- package/lib/carousel/src/Carousel.d.ts +267 -41
- package/lib/carousel/src/Carousel.js +677 -226
- package/lib/carousel/src/CarouselArrow.d.ts +9 -0
- package/lib/carousel/src/CarouselArrow.js +45 -0
- package/lib/carousel/src/CarouselDots.d.ts +72 -0
- package/lib/carousel/src/CarouselDots.js +120 -0
- package/lib/carousel/src/CarouselItem.d.ts +11 -0
- package/lib/carousel/src/CarouselItem.js +77 -0
- package/lib/carousel/src/interface.d.ts +35 -0
- package/lib/carousel/src/interface.js +7 -0
- package/lib/carousel/src/styles/index.cssr.js +141 -38
- package/lib/carousel/src/utils.d.ts +12 -0
- package/lib/carousel/src/utils.js +69 -0
- package/lib/carousel/styles/light.d.ts +3 -0
- package/lib/carousel/styles/light.js +5 -2
- package/lib/cascader/index.d.ts +1 -1
- package/lib/cascader/src/Cascader.d.ts +109 -84
- package/lib/cascader/src/Cascader.js +16 -27
- package/lib/cascader/src/CascaderMenu.d.ts +34 -24
- package/lib/cascader/src/CascaderMenu.js +1 -3
- package/lib/cascader/src/CascaderOption.d.ts +8 -5
- package/lib/cascader/src/CascaderOption.js +7 -4
- package/lib/cascader/src/CascaderSelectMenu.d.ts +26 -20
- package/lib/cascader/src/CascaderSubmenu.d.ts +16 -9
- package/lib/cascader/src/interface.d.ts +7 -2
- package/lib/cascader/src/interface.js +2 -1
- package/lib/cascader/styles/light.d.ts +1 -0
- package/lib/checkbox/index.d.ts +1 -0
- package/lib/checkbox/src/Checkbox.d.ts +43 -43
- package/lib/checkbox/src/Checkbox.js +16 -4
- package/lib/checkbox/src/CheckboxGroup.d.ts +23 -24
- package/lib/checkbox/src/CheckboxGroup.js +1 -1
- package/lib/checkbox/src/interface.d.ts +4 -0
- package/lib/checkbox/src/styles/index.cssr.js +1 -1
- package/lib/code/src/Code.d.ts +27 -30
- package/lib/code/src/Code.js +6 -3
- package/lib/code/src/styles/index.cssr.js +4 -1
- package/lib/collapse/src/Collapse.d.ts +35 -33
- package/lib/collapse/src/Collapse.js +1 -1
- package/lib/collapse/src/CollapseItem.d.ts +5 -9
- package/lib/collapse/src/CollapseItem.js +7 -14
- package/lib/collapse/src/CollapseItemContent.d.ts +11 -9
- package/lib/collapse-transition/src/CollapseTransition.d.ts +18 -19
- package/lib/color-picker/src/AlphaSlider.d.ts +19 -14
- package/lib/color-picker/src/ColorInput.d.ts +34 -19
- package/lib/color-picker/src/ColorInputUnit.d.ts +15 -11
- package/lib/color-picker/src/ColorInputUnit.js +1 -1
- package/lib/color-picker/src/ColorPicker.d.ts +55 -52
- package/lib/color-picker/src/ColorPicker.js +17 -10
- package/lib/color-picker/src/ColorPickerSwatches.d.ts +18 -11
- package/lib/color-picker/src/ColorPickerTrigger.d.ts +15 -12
- package/lib/color-picker/src/ColorPickerTrigger.js +22 -16
- package/lib/color-picker/src/ColorPreview.d.ts +19 -11
- package/lib/color-picker/src/HueSlider.d.ts +15 -12
- package/lib/color-picker/src/Pallete.d.ts +23 -16
- package/lib/color-picker/src/interface.d.ts +2 -0
- package/lib/color-picker/src/styles/index.cssr.js +1 -0
- package/lib/composables/use-theme-vars.d.ts +2 -1
- package/lib/config-provider/src/ConfigProvider.d.ts +57 -37
- package/lib/config-provider/src/ConfigProvider.js +4 -3
- package/lib/config-provider/src/interface.d.ts +4 -1
- package/lib/countdown/src/Countdown.d.ts +18 -17
- package/lib/data-table/index.d.ts +1 -1
- package/lib/data-table/src/DataTable.d.ts +114 -159
- package/lib/data-table/src/DataTable.js +21 -47
- package/lib/data-table/src/HeaderButton/FilterButton.d.ts +12 -7
- package/lib/data-table/src/HeaderButton/FilterMenu.d.ts +36 -19
- package/lib/data-table/src/HeaderButton/RenderFilter.d.ts +14 -9
- package/lib/data-table/src/HeaderButton/RenderSorter.d.ts +10 -7
- package/lib/data-table/src/HeaderButton/SortButton.d.ts +6 -5
- package/lib/data-table/src/HeaderButton/SortButton.js +6 -6
- package/lib/data-table/src/MainTable.d.ts +1 -1
- package/lib/data-table/src/TableParts/Body.d.ts +13 -14
- package/lib/data-table/src/TableParts/Body.js +1 -3
- package/lib/data-table/src/TableParts/BodyCheckbox.d.ts +14 -9
- package/lib/data-table/src/TableParts/Cell.d.ts +865 -855
- package/lib/data-table/src/TableParts/ExpandTrigger.d.ts +11 -9
- package/lib/data-table/src/TableParts/Header.d.ts +8 -5
- package/lib/data-table/src/TableParts/SelectionMenu.d.ts +6 -5
- package/lib/data-table/src/interface.d.ts +10 -7
- package/lib/data-table/src/interface.js +2 -1
- package/lib/data-table/src/styles/index.cssr.js +11 -8
- package/lib/data-table/src/utils.js +3 -0
- package/lib/data-table/styles/light.d.ts +1 -0
- package/lib/date-picker/index.d.ts +1 -0
- package/lib/date-picker/src/DatePicker.d.ts +87 -104
- package/lib/date-picker/src/DatePicker.js +114 -109
- package/lib/date-picker/src/interface.d.ts +23 -5
- package/lib/date-picker/src/interface.js +2 -1
- package/lib/date-picker/src/panel/date.d.ts +77 -34
- package/lib/date-picker/src/panel/date.js +8 -6
- package/lib/date-picker/src/panel/daterange.d.ts +31 -26
- package/lib/date-picker/src/panel/daterange.js +8 -8
- package/lib/date-picker/src/panel/datetime.d.ts +41 -30
- package/lib/date-picker/src/panel/datetime.js +6 -4
- package/lib/date-picker/src/panel/datetimerange.d.ts +31 -26
- package/lib/date-picker/src/panel/datetimerange.js +7 -7
- package/lib/date-picker/src/panel/month.d.ts +48 -32
- package/lib/date-picker/src/panel/month.js +12 -3
- package/lib/date-picker/src/panel/panelHeader.d.ts +2435 -0
- package/lib/date-picker/src/panel/panelHeader.js +77 -0
- package/lib/date-picker/src/panel/use-calendar.d.ts +16 -4
- package/lib/date-picker/src/panel/use-calendar.js +43 -4
- package/lib/date-picker/src/panel/use-dual-calendar.d.ts +6 -0
- package/lib/date-picker/src/panel/use-dual-calendar.js +10 -1
- package/lib/date-picker/src/panel/use-panel-common.d.ts +2 -0
- package/lib/date-picker/src/panel/use-panel-common.js +7 -1
- package/lib/date-picker/src/styles/index.cssr.js +5 -2
- package/lib/descriptions/src/Descriptions.d.ts +33 -33
- package/lib/descriptions/src/DescriptionsItem.d.ts +9 -12
- package/lib/dialog/src/Dialog.d.ts +32 -43
- package/lib/dialog/src/Dialog.js +26 -19
- package/lib/dialog/src/DialogEnvironment.d.ts +41 -46
- package/lib/dialog/src/DialogProvider.d.ts +7 -10
- package/lib/dialog/src/DialogProvider.js +2 -2
- package/lib/divider/src/Divider.d.ts +14 -19
- package/lib/drawer/src/Drawer.d.ts +101 -104
- package/lib/drawer/src/Drawer.js +41 -47
- package/lib/drawer/src/DrawerBodyWrapper.d.ts +40 -16
- package/lib/drawer/src/DrawerBodyWrapper.js +31 -14
- package/lib/drawer/src/DrawerContent.d.ts +15 -20
- package/lib/drawer/src/DrawerContent.js +6 -6
- package/lib/drawer/src/interface.d.ts +3 -3
- package/lib/drawer/src/interface.js +3 -2
- package/lib/dropdown/src/Dropdown.d.ts +113 -99
- package/lib/dropdown/src/Dropdown.js +1 -1
- package/lib/dropdown/src/DropdownDivider.d.ts +6 -5
- package/lib/dropdown/src/DropdownGroup.d.ts +14 -9
- package/lib/dropdown/src/DropdownGroupHeader.d.ts +10 -7
- package/lib/dropdown/src/DropdownMenu.d.ts +18 -16
- package/lib/dropdown/src/DropdownMenu.js +2 -1
- package/lib/dropdown/src/DropdownOption.d.ts +19 -14
- package/lib/dropdown/src/DropdownOption.js +1 -1
- package/lib/dropdown/src/DropdownRenderOption.d.ts +6 -5
- package/lib/dynamic-input/src/DynamicInput.d.ts +50 -45
- package/lib/dynamic-input/src/DynamicInput.js +1 -1
- package/lib/dynamic-input/src/InputPreset.d.ts +16 -14
- package/lib/dynamic-input/src/PairPreset.d.ts +23 -18
- package/lib/dynamic-input/src/interface.d.ts +2 -2
- package/lib/dynamic-input/src/interface.js +2 -1
- package/lib/dynamic-tags/src/DynamicTags.d.ts +41 -41
- package/lib/element/src/Element.d.ts +9 -12
- package/lib/ellipsis/src/Ellipsis.d.ts +14 -19
- package/lib/empty/src/Empty.d.ts +23 -24
- package/lib/empty/src/Empty.js +4 -8
- package/lib/form/src/Feedbacks.d.ts +8 -10
- package/lib/form/src/Feedbacks.js +4 -1
- package/lib/form/src/Form.d.ts +44 -44
- package/lib/form/src/Form.js +16 -7
- package/lib/form/src/FormItem.d.ts +45 -55
- package/lib/form/src/FormItem.js +29 -13
- package/lib/form/src/FormItemCol.d.ts +57 -60
- package/lib/form/src/FormItemGridItem.d.ts +57 -66
- package/lib/form/src/FormItemRow.d.ts +62 -65
- package/lib/form/src/interface.d.ts +8 -4
- package/lib/form/src/interface.js +3 -2
- package/lib/form/src/styles/form-item.cssr.js +2 -0
- package/lib/form/src/utils.d.ts +2 -2
- package/lib/form/src/utils.js +29 -18
- package/lib/global-style/src/GlobalStyle.d.ts +1 -1
- package/lib/gradient-text/src/GradientText.d.ts +16 -23
- package/lib/grid/src/Grid.d.ts +27 -22
- package/lib/grid/src/Grid.js +1 -1
- package/lib/grid/src/GridItem.d.ts +18 -18
- package/lib/grid/src/GridItem.js +2 -1
- package/lib/icon/src/Icon.d.ts +11 -18
- package/lib/image/src/Image.d.ts +295 -39
- package/lib/image/src/Image.js +4 -17
- package/lib/image/src/ImageGroup.d.ts +274 -8
- package/lib/image/src/ImageGroup.js +6 -8
- package/lib/image/src/ImagePreview.d.ts +203 -18
- package/lib/image/src/ImagePreview.js +57 -34
- package/lib/image/src/interface.d.ts +94 -0
- package/lib/image/src/interface.js +3 -0
- package/lib/image/src/styles/index.cssr.js +8 -4
- package/lib/image/styles/dark.js +8 -1
- package/lib/image/styles/light.d.ts +32 -3
- package/lib/image/styles/light.js +8 -1
- package/lib/index.d.ts +1 -1
- package/lib/index.js +2 -1
- package/lib/input/src/Input.d.ts +108 -110
- package/lib/input/src/Input.js +74 -33
- package/lib/input/src/InputGroup.d.ts +5 -9
- package/lib/input/src/InputGroupLabel.d.ts +16 -17
- package/lib/input/src/InputGroupLabel.js +3 -2
- package/lib/input/src/WordCount.d.ts +1 -1
- package/lib/input/src/interface.d.ts +2 -2
- package/lib/input/src/interface.js +2 -1
- package/lib/input/src/styles/input.cssr.js +45 -62
- package/lib/input-number/src/InputNumber.d.ts +59 -58
- package/lib/input-number/src/utils.js +2 -2
- package/lib/layout/src/Layout.d.ts +90 -65
- package/lib/layout/src/Layout.js +2 -1
- package/lib/layout/src/LayoutContent.d.ts +33 -31
- package/lib/layout/src/LayoutFooter.d.ts +14 -19
- package/lib/layout/src/LayoutHeader.d.ts +17 -19
- package/lib/layout/src/LayoutSider.d.ts +64 -61
- package/lib/layout/src/LayoutSider.js +2 -1
- package/lib/layout/src/ToggleBar.d.ts +7 -8
- package/lib/layout/src/ToggleButton.d.ts +7 -8
- package/lib/layout/src/interface.d.ts +2 -2
- package/lib/layout/src/interface.js +2 -1
- package/lib/layout/src/styles/layout-sider.cssr.js +15 -7
- package/lib/legacy-grid/src/Col.d.ts +18 -11
- package/lib/legacy-grid/src/Row.d.ts +11 -13
- package/lib/legacy-grid/src/Row.js +1 -1
- package/lib/list/src/List.d.ts +19 -20
- package/lib/list/src/List.js +6 -4
- package/lib/list/src/ListItem.d.ts +1 -1
- package/lib/list/src/ListItem.js +2 -2
- package/lib/loading-bar/src/LoadingBar.d.ts +1 -1
- package/lib/loading-bar/src/LoadingBarProvider.d.ts +22 -23
- package/lib/loading-bar/src/LoadingBarProvider.js +6 -5
- package/lib/locales/common/deDE.js +10 -0
- package/lib/locales/common/enUS.d.ts +9 -0
- package/lib/locales/common/enUS.js +10 -0
- package/lib/locales/common/esAR.d.ts +109 -0
- package/lib/locales/common/esAR.js +112 -0
- package/lib/locales/common/frFR.js +10 -0
- package/lib/locales/common/idID.js +10 -0
- package/lib/locales/common/itIT.d.ts +3 -0
- package/lib/locales/common/itIT.js +111 -0
- package/lib/locales/common/jaJP.js +10 -0
- package/lib/locales/common/nbNO.js +10 -0
- package/lib/locales/common/ruRU.js +10 -0
- package/lib/locales/common/ukUA.js +10 -0
- package/lib/locales/common/zhCN.js +9 -0
- package/lib/locales/common/zhTW.js +10 -0
- package/lib/locales/date/esAR.d.ts +3 -0
- package/lib/locales/date/esAR.js +11 -0
- package/lib/locales/date/itIT.d.ts +3 -0
- package/lib/locales/date/itIT.js +11 -0
- package/lib/locales/index.d.ts +4 -0
- package/lib/locales/index.js +9 -1
- package/lib/log/src/Log.d.ts +48 -46
- package/lib/log/src/Log.js +1 -1
- package/lib/log/src/LogLine.d.ts +6 -5
- package/lib/log/src/LogLoader.d.ts +6 -5
- package/lib/mention/src/Mention.d.ts +55 -56
- package/lib/mention/src/utils.js +0 -1
- package/lib/menu/src/Menu.d.ts +87 -88
- package/lib/menu/src/Menu.js +1 -1
- package/lib/menu/src/MenuDivider.d.ts +1 -1
- package/lib/menu/src/MenuOption.d.ts +22 -295
- package/lib/menu/src/MenuOption.js +2 -1
- package/lib/menu/src/MenuOptionContent.d.ts +33 -305
- package/lib/menu/src/MenuOptionGroup.d.ts +20 -20
- package/lib/menu/src/MenuOptionGroup.js +3 -2
- package/lib/menu/src/Submenu.d.ts +35 -301
- package/lib/menu/src/Submenu.js +4 -2
- package/lib/menu/src/use-menu-child-props.d.ts +2 -1
- package/lib/menu/src/use-menu-child.d.ts +5 -7
- package/lib/menu/src/use-menu-child.js +1 -3
- package/lib/message/index.d.ts +2 -1
- package/lib/message/src/Message.d.ts +183 -31
- package/lib/message/src/Message.js +13 -11
- package/lib/message/src/MessageEnvironment.d.ts +28 -36
- package/lib/message/src/MessageProvider.d.ts +29 -40
- package/lib/message/src/MessageProvider.js +7 -7
- package/lib/message/src/message-props.d.ts +5 -2
- package/lib/message/src/types.d.ts +15 -0
- package/lib/message/src/types.js +2 -0
- package/lib/modal/src/BodyWrapper.d.ts +96 -72
- package/lib/modal/src/BodyWrapper.js +12 -9
- package/lib/modal/src/Modal.d.ts +127 -965
- package/lib/modal/src/Modal.js +18 -5
- package/lib/modal/src/interface.d.ts +3 -3
- package/lib/modal/src/interface.js +3 -2
- package/lib/notification/src/Notification.d.ts +20 -22
- package/lib/notification/src/NotificationContainer.d.ts +10 -7
- package/lib/notification/src/NotificationEnvironment.d.ts +32 -40
- package/lib/notification/src/NotificationProvider.d.ts +32 -35
- package/lib/notification/src/NotificationProvider.js +6 -6
- package/lib/number-animation/src/NumberAnimation.d.ts +27 -15
- package/lib/number-animation/src/NumberAnimation.js +19 -4
- package/lib/page-header/index.d.ts +1 -1
- package/lib/page-header/src/PageHeader.d.ts +13 -21
- package/lib/page-header/src/PageHeader.js +4 -5
- package/lib/pagination/index.d.ts +1 -1
- package/lib/pagination/src/Pagination.d.ts +65 -61
- package/lib/pagination/src/Pagination.js +65 -18
- package/lib/pagination/src/interface.d.ts +10 -1
- package/lib/pagination/src/utils.d.ts +2 -2
- package/lib/pagination/src/utils.js +2 -4
- package/lib/pagination/styles/light.d.ts +1 -0
- package/lib/popconfirm/src/Popconfirm.d.ts +93 -85
- package/lib/popconfirm/src/PopconfirmPanel.d.ts +16 -14
- package/lib/popconfirm/src/PopconfirmPanel.js +3 -4
- package/lib/popconfirm/src/interface.d.ts +2 -2
- package/lib/popconfirm/src/interface.js +2 -1
- package/lib/popover/src/Popover.d.ts +93 -77
- package/lib/popover/src/Popover.js +23 -0
- package/lib/popover/src/PopoverBody.d.ts +35 -51
- package/lib/popover/src/PopoverBody.js +30 -45
- package/lib/popover/src/interface.d.ts +2 -2
- package/lib/popover/src/interface.js +2 -1
- package/lib/popover/src/styles/index.cssr.js +9 -8
- package/lib/popselect/src/Popselect.d.ts +139 -155
- package/lib/popselect/src/Popselect.js +2 -2
- package/lib/popselect/src/PopselectPanel.d.ts +24 -30
- package/lib/popselect/src/interface.d.ts +2 -2
- package/lib/popselect/src/interface.js +2 -1
- package/lib/progress/src/Circle.d.ts +40 -26
- package/lib/progress/src/Circle.js +8 -1
- package/lib/progress/src/Line.d.ts +37 -32
- package/lib/progress/src/Line.js +4 -1
- package/lib/progress/src/MultipleCircle.d.ts +38 -21
- package/lib/progress/src/Progress.d.ts +57 -50
- package/lib/progress/src/Progress.js +2 -2
- package/lib/progress/src/styles/index.cssr.js +16 -16
- package/lib/radio/src/Radio.d.ts +30 -31
- package/lib/radio/src/RadioButton.d.ts +24 -22
- package/lib/radio/src/RadioGroup.d.ts +21 -27
- package/lib/radio/src/styles/radio.cssr.js +4 -1
- package/lib/radio/src/use-radio.d.ts +2 -2
- package/lib/radio/src/use-radio.js +1 -1
- package/lib/rate/src/Rate.d.ts +26 -31
- package/lib/result/src/Result.d.ts +18 -21
- package/lib/result/src/Result.js +8 -9
- package/lib/result/src/styles/index.cssr.js +6 -6
- package/lib/scrollbar/src/ScrollBar.d.ts +10 -17
- package/lib/select/index.d.ts +1 -1
- package/lib/select/src/Select.d.ts +134 -121
- package/lib/select/src/Select.js +39 -62
- package/lib/select/src/interface.d.ts +4 -0
- package/lib/select/styles/light.d.ts +1 -0
- package/lib/skeleton/src/Skeleton.d.ts +26 -31
- package/lib/slider/src/Slider.d.ts +51 -51
- package/lib/slider/src/Slider.js +2 -1
- package/lib/space/src/Space.d.ts +24 -27
- package/lib/spin/src/Spin.d.ts +28 -27
- package/lib/statistic/src/Statistic.d.ts +11 -19
- package/lib/statistic/src/Statistic.js +2 -2
- package/lib/steps/src/Step.d.ts +9 -12
- package/lib/steps/src/Step.js +4 -6
- package/lib/steps/src/Steps.d.ts +20 -23
- package/lib/steps/src/Steps.js +1 -1
- package/lib/switch/src/Switch.d.ts +45 -40
- package/lib/table/src/Table.d.ts +26 -25
- package/lib/table/src/Tbody.d.ts +1 -1
- package/lib/table/src/Td.d.ts +1 -1
- package/lib/table/src/Th.d.ts +1 -1
- package/lib/table/src/Thead.d.ts +1 -1
- package/lib/table/src/Tr.d.ts +1 -1
- package/lib/tabs/index.d.ts +1 -0
- package/lib/tabs/src/Tab.d.ts +30 -37
- package/lib/tabs/src/Tab.js +10 -3
- package/lib/tabs/src/TabPane.d.ts +32 -38
- package/lib/tabs/src/TabPane.js +12 -13
- package/lib/tabs/src/Tabs.d.ts +39 -54
- package/lib/tabs/src/Tabs.js +27 -24
- package/lib/tabs/src/interface.d.ts +5 -2
- package/lib/tabs/src/interface.js +2 -1
- package/lib/tag/src/Tag.d.ts +42 -47
- package/lib/tag/src/Tag.js +1 -1
- package/lib/theme-editor/src/ThemeEditor.d.ts +1 -1
- package/lib/theme-editor/src/ThemeEditor.js +160 -157
- package/lib/themes/index.d.ts +1 -0
- package/lib/themes/index.js +3 -1
- package/lib/thing/src/Thing.d.ts +16 -23
- package/lib/thing/src/Thing.js +19 -23
- package/lib/time/src/Time.d.ts +18 -18
- package/lib/time-picker/index.d.ts +1 -0
- package/lib/time-picker/src/Panel.d.ts +75 -72
- package/lib/time-picker/src/PanelCol.d.ts +15 -12
- package/lib/time-picker/src/TimePicker.d.ts +110 -77
- package/lib/time-picker/src/TimePicker.js +76 -70
- package/lib/time-picker/src/interface.d.ts +10 -4
- package/lib/time-picker/src/interface.js +2 -1
- package/lib/timeline/src/Timeline.d.ts +21 -24
- package/lib/timeline/src/Timeline.js +2 -1
- package/lib/timeline/src/TimelineItem.d.ts +10 -14
- package/lib/timeline/src/TimelineItem.js +3 -3
- package/lib/tooltip/src/Tooltip.d.ts +85 -75
- package/lib/transfer/src/Transfer.d.ts +39 -43
- package/lib/transfer/src/TransferFilter.d.ts +17 -16
- package/lib/transfer/src/TransferHeader.d.ts +11 -10
- package/lib/transfer/src/TransferList.d.ts +35 -19
- package/lib/transfer/src/TransferListItem.d.ts +18 -11
- package/lib/transfer/src/interface.d.ts +2 -2
- package/lib/transfer/src/interface.js +2 -1
- package/lib/tree/src/MotionWrapper.d.ts +19 -14
- package/lib/tree/src/Tree.d.ts +127 -134
- package/lib/tree/src/Tree.js +4 -2
- package/lib/tree/src/TreeNode.d.ts +10 -7
- package/lib/tree/src/TreeNodeCheckbox.d.ts +11 -16
- package/lib/tree/src/TreeNodeContent.d.ts +15 -18
- package/lib/tree/src/TreeNodeSwitcher.d.ts +10 -14
- package/lib/tree/src/TreeNodeSwitcher.js +24 -13
- package/lib/tree/src/interface.d.ts +4 -2
- package/lib/tree/src/interface.js +2 -1
- package/lib/tree/src/styles/index.cssr.js +4 -2
- package/lib/tree-select/src/TreeSelect.d.ts +112 -97
- package/lib/tree-select/src/TreeSelect.js +1 -3
- package/lib/tree-select/src/interface.d.ts +2 -2
- package/lib/tree-select/src/interface.js +2 -1
- package/lib/tree-select/styles/light.d.ts +1 -0
- package/lib/typography/src/a.d.ts +8 -12
- package/lib/typography/src/blockquote.d.ts +9 -15
- package/lib/typography/src/create-header.d.ts +14 -19
- package/lib/typography/src/headers.d.ts +84 -114
- package/lib/typography/src/hr.d.ts +8 -12
- package/lib/typography/src/li.d.ts +1 -1
- package/lib/typography/src/ol.d.ts +9 -15
- package/lib/typography/src/p.d.ts +9 -14
- package/lib/typography/src/text.d.ts +24 -31
- package/lib/typography/src/text.js +3 -2
- package/lib/typography/src/ul.d.ts +9 -15
- package/lib/upload/src/Upload.d.ts +95 -85
- package/lib/upload/src/Upload.js +22 -10
- package/lib/upload/src/UploadDragger.d.ts +1 -1
- package/lib/upload/src/UploadFile.d.ts +18 -13
- package/lib/upload/src/UploadFileList.d.ts +1 -1
- package/lib/upload/src/UploadFileList.js +2 -2
- package/lib/upload/src/UploadProgress.d.ts +11 -9
- package/lib/upload/src/UploadTrigger.d.ts +3 -5
- package/lib/upload/src/interface.d.ts +14 -6
- package/lib/upload/src/interface.js +2 -1
- package/lib/version.d.ts +1 -1
- package/lib/version.js +1 -1
- package/package.json +24 -16
- package/volar.d.ts +144 -0
- package/web-types.json +539 -50
|
@@ -1,18 +1,17 @@
|
|
|
1
|
-
import { h, defineComponent, ref, Transition, computed, provide, watch, withDirectives, toRef, watchEffect
|
|
1
|
+
import { h, defineComponent, ref, Transition, computed, provide, watch, withDirectives, toRef, watchEffect } from 'vue';
|
|
2
2
|
import { VBinder, VTarget, VFollower } from 'vueuc';
|
|
3
3
|
import { clickoutside } from 'vdirs';
|
|
4
|
-
import { format, getTime, isValid
|
|
4
|
+
import { format, getTime, isValid } from 'date-fns';
|
|
5
5
|
import { useIsMounted, useMergedState } from 'vooks';
|
|
6
6
|
import { happensIn } from 'seemly';
|
|
7
7
|
import { NInput } from '../../input';
|
|
8
8
|
import { NBaseIcon } from '../../_internal';
|
|
9
9
|
import { useFormItem, useTheme, useConfig, useLocale } from '../../_mixins';
|
|
10
10
|
import { DateIcon, ToIcon } from '../../_internal/icons';
|
|
11
|
-
import { warn, call, useAdjustedTo, createKey } from '../../_utils';
|
|
11
|
+
import { warn, call, useAdjustedTo, createKey, warnOnce } from '../../_utils';
|
|
12
12
|
import { datePickerLight } from '../styles';
|
|
13
13
|
import { strictParse } from './utils';
|
|
14
14
|
import { uniCalendarValidation, dualCalendarValidation } from './validation-utils';
|
|
15
|
-
import { MONTH_ITEM_HEIGHT, START_YEAR } from './config';
|
|
16
15
|
import { datePickerInjectionKey } from './interface';
|
|
17
16
|
import DatetimePanel from './panel/datetime';
|
|
18
17
|
import DatetimerangePanel from './panel/datetimerange';
|
|
@@ -23,37 +22,33 @@ import style from './styles/index.cssr';
|
|
|
23
22
|
const datePickerProps = Object.assign(Object.assign({}, useTheme.props), { to: useAdjustedTo.propTo, bordered: {
|
|
24
23
|
type: Boolean,
|
|
25
24
|
default: undefined
|
|
26
|
-
}, clearable: Boolean, updateValueOnClose: Boolean, defaultValue: {
|
|
27
|
-
type: [Number, Array],
|
|
28
|
-
default: null
|
|
29
|
-
}, defaultTime: [Number, String, Array], disabled: {
|
|
25
|
+
}, clearable: Boolean, updateValueOnClose: Boolean, defaultValue: [Number, Array], defaultFormattedValue: [String, Array], defaultTime: [Number, String, Array], disabled: {
|
|
30
26
|
type: Boolean,
|
|
31
27
|
default: undefined
|
|
32
28
|
}, placement: {
|
|
33
29
|
type: String,
|
|
34
30
|
default: 'bottom-start'
|
|
35
|
-
}, value: [Number, Array], size: String, type: {
|
|
31
|
+
}, value: [Number, Array], formattedValue: [String, Array], size: String, type: {
|
|
36
32
|
type: String,
|
|
37
33
|
default: 'date'
|
|
38
|
-
}, separator: String, placeholder: String, startPlaceholder: String, endPlaceholder: String, format: String, dateFormat: String, timeFormat: String, actions: Array, shortcuts: Object, isDateDisabled: Function, isTimeDisabled: Function, show: {
|
|
34
|
+
}, valueFormat: String, separator: String, placeholder: String, startPlaceholder: String, endPlaceholder: String, format: String, dateFormat: String, timeFormat: String, actions: Array, shortcuts: Object, isDateDisabled: Function, isTimeDisabled: Function, show: {
|
|
39
35
|
type: Boolean,
|
|
40
36
|
default: undefined
|
|
41
|
-
}, ranges: Object, firstDayOfWeek: Number, inputReadonly: Boolean, closeOnSelect: Boolean, 'onUpdate:show': [Function, Array], onUpdateShow: [Function, Array], 'onUpdate:value': [Function, Array], onUpdateValue: [Function, Array], onFocus: [Function, Array], onBlur: [Function, Array],
|
|
37
|
+
}, ranges: Object, firstDayOfWeek: Number, inputReadonly: Boolean, closeOnSelect: Boolean, 'onUpdate:show': [Function, Array], onUpdateShow: [Function, Array], 'onUpdate:formattedValue': [Function, Array], onUpdateFormattedValue: [Function, Array], 'onUpdate:value': [Function, Array], onUpdateValue: [Function, Array], onFocus: [Function, Array], onBlur: [Function, Array],
|
|
42
38
|
// deprecated
|
|
43
|
-
onChange:
|
|
44
|
-
type: [Function, Array],
|
|
45
|
-
validator: () => {
|
|
46
|
-
if (process.env.NODE_ENV !== 'production') {
|
|
47
|
-
warn('data-picker', '`on-change` is deprecated, please use `on-update:value` instead.');
|
|
48
|
-
}
|
|
49
|
-
return true;
|
|
50
|
-
},
|
|
51
|
-
default: undefined
|
|
52
|
-
} });
|
|
39
|
+
onChange: [Function, Array] });
|
|
53
40
|
export default defineComponent({
|
|
54
41
|
name: 'DatePicker',
|
|
55
42
|
props: datePickerProps,
|
|
56
43
|
setup(props, { slots }) {
|
|
44
|
+
var _a;
|
|
45
|
+
if (process.env.NODE_ENV !== 'production') {
|
|
46
|
+
watchEffect(() => {
|
|
47
|
+
if (props.onChange !== undefined) {
|
|
48
|
+
warnOnce('data-picker', '`on-change` is deprecated, please use `on-update:value` instead.');
|
|
49
|
+
}
|
|
50
|
+
});
|
|
51
|
+
}
|
|
57
52
|
const { localeRef, dateLocaleRef } = useLocale('DatePicker');
|
|
58
53
|
const formItem = useFormItem(props);
|
|
59
54
|
const { mergedSizeRef, mergedDisabledRef } = formItem;
|
|
@@ -64,8 +59,58 @@ export default defineComponent({
|
|
|
64
59
|
const uncontrolledShowRef = ref(false);
|
|
65
60
|
const controlledShowRef = toRef(props, 'show');
|
|
66
61
|
const mergedShowRef = useMergedState(controlledShowRef, uncontrolledShowRef);
|
|
67
|
-
const
|
|
68
|
-
|
|
62
|
+
const dateFnsOptionsRef = computed(() => {
|
|
63
|
+
return {
|
|
64
|
+
locale: dateLocaleRef.value.locale
|
|
65
|
+
};
|
|
66
|
+
});
|
|
67
|
+
const mergedFormatRef = computed(() => {
|
|
68
|
+
const { format } = props;
|
|
69
|
+
if (format)
|
|
70
|
+
return format;
|
|
71
|
+
switch (props.type) {
|
|
72
|
+
case 'date':
|
|
73
|
+
case 'daterange':
|
|
74
|
+
return localeRef.value.dateFormat;
|
|
75
|
+
case 'datetime':
|
|
76
|
+
case 'datetimerange':
|
|
77
|
+
return localeRef.value.dateTimeFormat;
|
|
78
|
+
case 'year':
|
|
79
|
+
return localeRef.value.yearTypeFormat;
|
|
80
|
+
case 'month':
|
|
81
|
+
return localeRef.value.monthTypeFormat;
|
|
82
|
+
case 'quarter':
|
|
83
|
+
return localeRef.value.quarterFormat;
|
|
84
|
+
}
|
|
85
|
+
});
|
|
86
|
+
const mergedValueFormatRef = computed(() => {
|
|
87
|
+
var _a;
|
|
88
|
+
return (_a = props.valueFormat) !== null && _a !== void 0 ? _a : mergedFormatRef.value;
|
|
89
|
+
});
|
|
90
|
+
function getTimestampValue(value) {
|
|
91
|
+
if (value === null)
|
|
92
|
+
return null;
|
|
93
|
+
const { value: mergedValueFormat } = mergedValueFormatRef;
|
|
94
|
+
const { value: dateFnsOptions } = dateFnsOptionsRef;
|
|
95
|
+
if (Array.isArray(value)) {
|
|
96
|
+
return [
|
|
97
|
+
strictParse(value[0], mergedValueFormat, new Date(), dateFnsOptions).getTime(),
|
|
98
|
+
strictParse(value[1], mergedValueFormat, new Date(), dateFnsOptions).getTime()
|
|
99
|
+
];
|
|
100
|
+
}
|
|
101
|
+
return strictParse(value, mergedValueFormat, new Date(), dateFnsOptions).getTime();
|
|
102
|
+
}
|
|
103
|
+
const { defaultFormattedValue, defaultValue } = props;
|
|
104
|
+
const uncontrolledValueRef = ref((_a = (defaultFormattedValue !== undefined
|
|
105
|
+
? getTimestampValue(defaultFormattedValue)
|
|
106
|
+
: defaultValue)) !== null && _a !== void 0 ? _a : null);
|
|
107
|
+
const controlledValueRef = computed(() => {
|
|
108
|
+
const { formattedValue } = props;
|
|
109
|
+
if (formattedValue !== undefined) {
|
|
110
|
+
return getTimestampValue(formattedValue);
|
|
111
|
+
}
|
|
112
|
+
return props.value;
|
|
113
|
+
});
|
|
69
114
|
const mergedValueRef = useMergedState(controlledValueRef, uncontrolledValueRef);
|
|
70
115
|
// We don't change value unless blur or confirm is called
|
|
71
116
|
const pendingValueRef = ref(null);
|
|
@@ -76,11 +121,6 @@ export default defineComponent({
|
|
|
76
121
|
const rangeStartInputValueRef = ref('');
|
|
77
122
|
const rangeEndInputValueRef = ref('');
|
|
78
123
|
const themeRef = useTheme('DatePicker', 'DatePicker', style, datePickerLight, props, mergedClsPrefixRef);
|
|
79
|
-
const dateFnsOptionsRef = computed(() => {
|
|
80
|
-
return {
|
|
81
|
-
locale: dateLocaleRef.value.locale
|
|
82
|
-
};
|
|
83
|
-
});
|
|
84
124
|
const timePickerSizeRef = computed(() => {
|
|
85
125
|
var _a, _b;
|
|
86
126
|
return (((_b = (_a = NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.mergedComponentPropsRef.value) === null || _a === void 0 ? void 0 : _a.DatePicker) === null || _b === void 0 ? void 0 : _b.timePickerSize) || 'small');
|
|
@@ -139,25 +179,6 @@ export default defineComponent({
|
|
|
139
179
|
return props.endPlaceholder;
|
|
140
180
|
}
|
|
141
181
|
});
|
|
142
|
-
const mergedFormatRef = computed(() => {
|
|
143
|
-
const { format } = props;
|
|
144
|
-
if (format)
|
|
145
|
-
return format;
|
|
146
|
-
switch (props.type) {
|
|
147
|
-
case 'date':
|
|
148
|
-
case 'daterange':
|
|
149
|
-
return localeRef.value.dateFormat;
|
|
150
|
-
case 'datetime':
|
|
151
|
-
case 'datetimerange':
|
|
152
|
-
return localeRef.value.dateTimeFormat;
|
|
153
|
-
case 'year':
|
|
154
|
-
return localeRef.value.yearTypeFormat;
|
|
155
|
-
case 'month':
|
|
156
|
-
return localeRef.value.monthTypeFormat;
|
|
157
|
-
case 'quarter':
|
|
158
|
-
return localeRef.value.quarterFormat;
|
|
159
|
-
}
|
|
160
|
-
});
|
|
161
182
|
const mergedActionsRef = computed(() => {
|
|
162
183
|
const { actions, type } = props;
|
|
163
184
|
if (actions !== undefined)
|
|
@@ -190,19 +211,47 @@ export default defineComponent({
|
|
|
190
211
|
}
|
|
191
212
|
}
|
|
192
213
|
});
|
|
214
|
+
function getFormattedValue(value) {
|
|
215
|
+
if (value === null)
|
|
216
|
+
return null;
|
|
217
|
+
if (Array.isArray(value)) {
|
|
218
|
+
const { value: mergedValueFormat } = mergedValueFormatRef;
|
|
219
|
+
const { value: dateFnsOptions } = dateFnsOptionsRef;
|
|
220
|
+
return [
|
|
221
|
+
format(value[0], mergedValueFormat, dateFnsOptions),
|
|
222
|
+
format(value[1], mergedValueFormat, dateFnsOptionsRef.value)
|
|
223
|
+
];
|
|
224
|
+
}
|
|
225
|
+
else {
|
|
226
|
+
return format(value, mergedValueFormatRef.value, dateFnsOptionsRef.value);
|
|
227
|
+
}
|
|
228
|
+
}
|
|
193
229
|
function doUpdatePendingValue(value) {
|
|
194
230
|
pendingValueRef.value = value;
|
|
195
231
|
}
|
|
232
|
+
function doUpdateFormattedValue(value, timestampValue) {
|
|
233
|
+
const { 'onUpdate:formattedValue': _onUpdateFormattedValue, onUpdateFormattedValue } = props;
|
|
234
|
+
if (_onUpdateFormattedValue) {
|
|
235
|
+
call(_onUpdateFormattedValue, value, timestampValue);
|
|
236
|
+
}
|
|
237
|
+
if (onUpdateFormattedValue) {
|
|
238
|
+
call(onUpdateFormattedValue, value, timestampValue);
|
|
239
|
+
}
|
|
240
|
+
}
|
|
196
241
|
function doUpdateValue(value) {
|
|
197
242
|
const { 'onUpdate:value': _onUpdateValue, onUpdateValue, onChange } = props;
|
|
198
243
|
const { nTriggerFormChange, nTriggerFormInput } = formItem;
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
244
|
+
const formattedValue = getFormattedValue(value);
|
|
245
|
+
if (onUpdateValue) {
|
|
246
|
+
call(onUpdateValue, value, formattedValue);
|
|
247
|
+
}
|
|
248
|
+
if (_onUpdateValue) {
|
|
249
|
+
call(_onUpdateValue, value, formattedValue);
|
|
250
|
+
}
|
|
203
251
|
if (onChange)
|
|
204
|
-
call(onChange, value);
|
|
252
|
+
call(onChange, value, formattedValue);
|
|
205
253
|
uncontrolledValueRef.value = value;
|
|
254
|
+
doUpdateFormattedValue(formattedValue, value);
|
|
206
255
|
nTriggerFormChange();
|
|
207
256
|
nTriggerFormInput();
|
|
208
257
|
}
|
|
@@ -266,28 +315,6 @@ export default defineComponent({
|
|
|
266
315
|
disableUpdateOnClose
|
|
267
316
|
});
|
|
268
317
|
}
|
|
269
|
-
function scrollPickerColumns(value) {
|
|
270
|
-
if (!panelInstRef.value)
|
|
271
|
-
return;
|
|
272
|
-
const { monthScrollRef, yearScrollRef } = panelInstRef.value;
|
|
273
|
-
const { value: mergedValue } = mergedValueRef;
|
|
274
|
-
if (monthScrollRef) {
|
|
275
|
-
const monthIndex = value === undefined
|
|
276
|
-
? mergedValue === null
|
|
277
|
-
? getMonth(Date.now())
|
|
278
|
-
: getMonth(mergedValue)
|
|
279
|
-
: getMonth(value);
|
|
280
|
-
monthScrollRef.scrollTo({ top: monthIndex * MONTH_ITEM_HEIGHT });
|
|
281
|
-
}
|
|
282
|
-
if (yearScrollRef) {
|
|
283
|
-
const yearIndex = (value === undefined
|
|
284
|
-
? mergedValue === null
|
|
285
|
-
? getYear(Date.now())
|
|
286
|
-
: getYear(mergedValue)
|
|
287
|
-
: getYear(value)) - START_YEAR;
|
|
288
|
-
yearScrollRef.scrollTo({ top: yearIndex * MONTH_ITEM_HEIGHT });
|
|
289
|
-
}
|
|
290
|
-
}
|
|
291
318
|
// --- Panel update value
|
|
292
319
|
function handlePanelUpdateValue(value, doUpdate) {
|
|
293
320
|
if (doUpdate) {
|
|
@@ -412,10 +439,6 @@ export default defineComponent({
|
|
|
412
439
|
if (mergedDisabledRef.value || mergedShowRef.value)
|
|
413
440
|
return;
|
|
414
441
|
doUpdateShow(true);
|
|
415
|
-
const { type } = props;
|
|
416
|
-
if (type === 'month' || type === 'year' || type === 'quarter') {
|
|
417
|
-
void nextTick(scrollPickerColumns);
|
|
418
|
-
}
|
|
419
442
|
}
|
|
420
443
|
function closeCalendar({ returnFocus, disableUpdateOnClose }) {
|
|
421
444
|
var _a;
|
|
@@ -450,35 +473,22 @@ export default defineComponent({
|
|
|
450
473
|
// use pending value to do validation
|
|
451
474
|
const uniVaidation = uniCalendarValidation(props, pendingValueRef);
|
|
452
475
|
const dualValidation = dualCalendarValidation(props, pendingValueRef);
|
|
453
|
-
provide(datePickerInjectionKey, Object.assign(Object.assign(Object.assign({
|
|
454
|
-
mergedClsPrefixRef, mergedThemeRef: themeRef, timePickerSizeRef,
|
|
476
|
+
provide(datePickerInjectionKey, Object.assign(Object.assign(Object.assign({ mergedClsPrefixRef, mergedThemeRef: themeRef, timePickerSizeRef,
|
|
455
477
|
localeRef,
|
|
456
478
|
dateLocaleRef, firstDayOfWeekRef: toRef(props, 'firstDayOfWeek'), isDateDisabledRef: toRef(props, 'isDateDisabled'), rangesRef: toRef(props, 'ranges'), closeOnSelectRef: toRef(props, 'closeOnSelect'), updateValueOnCloseRef: toRef(props, 'updateValueOnClose') }, uniVaidation), dualValidation), { datePickerSlots: slots }));
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
479
|
+
const exposedMethods = {
|
|
480
|
+
focus: () => {
|
|
481
|
+
var _a;
|
|
482
|
+
(_a = inputInstRef.value) === null || _a === void 0 ? void 0 : _a.focus();
|
|
483
|
+
},
|
|
484
|
+
blur: () => {
|
|
485
|
+
var _a;
|
|
486
|
+
(_a = inputInstRef.value) === null || _a === void 0 ? void 0 : _a.blur();
|
|
487
|
+
}
|
|
488
|
+
};
|
|
489
|
+
return Object.assign(Object.assign({}, exposedMethods), { mergedClsPrefix: mergedClsPrefixRef, mergedBordered: mergedBorderedRef, namespace: namespaceRef, uncontrolledValue: uncontrolledValueRef, pendingValue: pendingValueRef, panelInstRef,
|
|
464
490
|
triggerElRef,
|
|
465
|
-
inputInstRef,
|
|
466
|
-
isMounted: useIsMounted(),
|
|
467
|
-
displayTime: singleInputValueRef,
|
|
468
|
-
displayStartTime: rangeStartInputValueRef,
|
|
469
|
-
displayEndTime: rangeEndInputValueRef,
|
|
470
|
-
mergedShow: mergedShowRef,
|
|
471
|
-
adjustedTo: useAdjustedTo(props),
|
|
472
|
-
isRange: isRangeRef,
|
|
473
|
-
localizedStartPlaceholder: localizedStartPlaceholderRef,
|
|
474
|
-
localizedEndPlaceholder: localizedEndPlaceholderRef,
|
|
475
|
-
mergedSize: mergedSizeRef,
|
|
476
|
-
mergedDisabled: mergedDisabledRef,
|
|
477
|
-
localizedPlacehoder: localizedPlacehoderRef,
|
|
478
|
-
isValueInvalid: uniVaidation.isValueInvalidRef,
|
|
479
|
-
isStartValueInvalid: dualValidation.isStartValueInvalidRef,
|
|
480
|
-
isEndValueInvalid: dualValidation.isEndValueInvalidRef,
|
|
481
|
-
handleClickOutside,
|
|
491
|
+
inputInstRef, isMounted: useIsMounted(), displayTime: singleInputValueRef, displayStartTime: rangeStartInputValueRef, displayEndTime: rangeEndInputValueRef, mergedShow: mergedShowRef, adjustedTo: useAdjustedTo(props), isRange: isRangeRef, localizedStartPlaceholder: localizedStartPlaceholderRef, localizedEndPlaceholder: localizedEndPlaceholderRef, mergedSize: mergedSizeRef, mergedDisabled: mergedDisabledRef, localizedPlacehoder: localizedPlacehoderRef, isValueInvalid: uniVaidation.isValueInvalidRef, isStartValueInvalid: dualValidation.isStartValueInvalidRef, isEndValueInvalid: dualValidation.isEndValueInvalidRef, handleClickOutside,
|
|
482
492
|
handleKeyDown,
|
|
483
493
|
handleClear,
|
|
484
494
|
handleTriggerClick,
|
|
@@ -491,18 +501,14 @@ export default defineComponent({
|
|
|
491
501
|
handleRangeUpdateValue,
|
|
492
502
|
handleSingleUpdateValue,
|
|
493
503
|
handlePanelUpdateValue,
|
|
494
|
-
handlePanelConfirm,
|
|
495
|
-
mergedTheme: themeRef,
|
|
496
|
-
actions: mergedActionsRef,
|
|
497
|
-
triggerCssVars: computed(() => {
|
|
504
|
+
handlePanelConfirm, mergedTheme: themeRef, actions: mergedActionsRef, triggerCssVars: computed(() => {
|
|
498
505
|
const { common: { cubicBezierEaseInOut }, self: { iconColor, iconColorDisabled } } = themeRef.value;
|
|
499
506
|
return {
|
|
500
507
|
'--n-bezier': cubicBezierEaseInOut,
|
|
501
508
|
'--n-icon-color': iconColor,
|
|
502
509
|
'--n-icon-color-disabled': iconColorDisabled
|
|
503
510
|
};
|
|
504
|
-
}),
|
|
505
|
-
cssVars: computed(() => {
|
|
511
|
+
}), cssVars: computed(() => {
|
|
506
512
|
const { type } = props;
|
|
507
513
|
const { common: { cubicBezierEaseInOut }, self: { calendarTitleFontSize, calendarDaysFontSize, itemFontSize, itemTextColor, itemColorDisabled, itemColorIncluded, itemColorHover, itemColorActive, itemBorderRadius, itemTextColorDisabled, itemTextColorActive, panelColor, panelTextColor, arrowColor, calendarTitleTextColor, panelActionDividerColor, panelHeaderDividerColor, calendarDaysDividerColor, panelBoxShadow, panelBorderRadius, calendarTitleFontWeight, panelExtraFooterPadding, panelActionPadding, itemSize, itemCellWidth, itemCellHeight, scrollItemWidth, scrollItemHeight, calendarTitlePadding, calendarTitleHeight, calendarDaysHeight, calendarDaysTextColor, arrowSize, panelHeaderPadding, calendarDividerColor, calendarTitleGridTempateColumns, iconColor, iconColorDisabled, scrollItemBorderRadius, [createKey('calendarLeftPadding', type)]: calendarLeftPadding, [createKey('calendarRightPadding', type)]: calendarRightPadding } } = themeRef.value;
|
|
508
514
|
return {
|
|
@@ -556,8 +562,7 @@ export default defineComponent({
|
|
|
556
562
|
'--n-icon-color': iconColor,
|
|
557
563
|
'--n-icon-color-disabled': iconColorDisabled
|
|
558
564
|
};
|
|
559
|
-
})
|
|
560
|
-
};
|
|
565
|
+
}) });
|
|
561
566
|
},
|
|
562
567
|
render() {
|
|
563
568
|
const { clearable } = this;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Ref, Slots } from 'vue';
|
|
2
2
|
import { VirtualListInst } from 'vueuc';
|
|
3
3
|
import { NLocale, NDateLocale } from '../../locales';
|
|
4
4
|
import type { ScrollbarInst } from '../../_internal';
|
|
@@ -8,9 +8,24 @@ import { DatePickerTheme } from '../styles/light';
|
|
|
8
8
|
import { uniCalendarValidation, dualCalendarValidation } from './validation-utils';
|
|
9
9
|
export declare type Value = number | [number, number];
|
|
10
10
|
export declare type DefaultTime = string | [string | undefined, string | undefined];
|
|
11
|
+
export declare type FormattedValue = string | [string, string];
|
|
11
12
|
export declare type Shortcuts = Record<string, number | (() => number)> | Record<string, [number, number] | (() => [number, number])>;
|
|
12
|
-
export declare type OnUpdateValue = (value: number & (number | null) & [
|
|
13
|
-
|
|
13
|
+
export declare type OnUpdateValue = (value: number & (number | null) & [
|
|
14
|
+
number,
|
|
15
|
+
number
|
|
16
|
+
] & ([number, number] | null), formattedValue: string & (string | null) & [
|
|
17
|
+
string,
|
|
18
|
+
string
|
|
19
|
+
] & ([string, string] | null)) => void;
|
|
20
|
+
export declare type OnUpdateFormattedValue = (value: string & (string | null) & [
|
|
21
|
+
string,
|
|
22
|
+
string
|
|
23
|
+
] & ([string, string] | null), timestampValue: number & (number | null) & [
|
|
24
|
+
number,
|
|
25
|
+
number
|
|
26
|
+
] & ([number, number] | null)) => void;
|
|
27
|
+
export declare type OnUpdateFormattedValueImpl = (value: string | [string, string] | null, timestampValue: number | [number, number] | null) => void;
|
|
28
|
+
export declare type OnUpdateValueImpl = (value: Value | null, formattedValue: string | [string, string] | null) => void;
|
|
14
29
|
export declare type OnPanelUpdateValue = (value: number & (number | null) & [
|
|
15
30
|
number,
|
|
16
31
|
number
|
|
@@ -35,9 +50,8 @@ export declare type DatePickerInjection = {
|
|
|
35
50
|
updateValueOnCloseRef: Ref<boolean>;
|
|
36
51
|
firstDayOfWeekRef: Ref<FirstDayOfWeek | undefined>;
|
|
37
52
|
datePickerSlots: Slots;
|
|
38
|
-
scrollPickerColumns: (value?: number) => void;
|
|
39
53
|
} & ReturnType<typeof uniCalendarValidation> & ReturnType<typeof dualCalendarValidation>;
|
|
40
|
-
export declare const datePickerInjectionKey: InjectionKey<DatePickerInjection>;
|
|
54
|
+
export declare const datePickerInjectionKey: import("vue").InjectionKey<DatePickerInjection>;
|
|
41
55
|
export declare type IsDateDisabled = IsSingleDateDisabled | IsRangeDateDisabled;
|
|
42
56
|
export declare type IsSingleDateDisabled = (date: number) => boolean;
|
|
43
57
|
export declare type IsRangeDateDisabled = (date: number, position: 'start' | 'end', value: [number, number] | null) => boolean;
|
|
@@ -49,3 +63,7 @@ export interface TimeValidator {
|
|
|
49
63
|
export declare type IsTimeDisabled = IsSingleTimeDisabled | IsRangeTimeDisabled;
|
|
50
64
|
export declare type IsSingleTimeDisabled = (date: number) => TimeValidator;
|
|
51
65
|
export declare type IsRangeTimeDisabled = (date: number, position: 'start' | 'end', value: [number, number]) => TimeValidator;
|
|
66
|
+
export interface DatePickerInst {
|
|
67
|
+
focus: () => void;
|
|
68
|
+
blur: () => void;
|
|
69
|
+
}
|
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
import { createInjectionKey } from '../../_utils';
|
|
2
|
+
export const datePickerInjectionKey = createInjectionKey('n-date-picker');
|
|
@@ -7,6 +7,12 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
7
7
|
readonly dateFormat: StringConstructor;
|
|
8
8
|
readonly timeFormat: {
|
|
9
9
|
readonly type: StringConstructor;
|
|
10
|
+
/**
|
|
11
|
+
* Date Panel
|
|
12
|
+
* Update picker value on:
|
|
13
|
+
* 1. item click
|
|
14
|
+
* 2. clear click
|
|
15
|
+
*/
|
|
10
16
|
readonly value: "HH:mm:ss";
|
|
11
17
|
};
|
|
12
18
|
readonly value: {
|
|
@@ -37,11 +43,14 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
37
43
|
[name: string]: import("vue").Slot | undefined;
|
|
38
44
|
}>;
|
|
39
45
|
monthScrollRef: import("vue").Ref<{
|
|
40
|
-
scrollTo: import("../../../_internal/scrollbar/src/ScrollBar").ScrollTo;
|
|
41
|
-
sync: () => void;
|
|
42
46
|
containerRef: HTMLElement | null;
|
|
43
47
|
contentRef: HTMLElement | null;
|
|
44
48
|
containerScrollTop: number;
|
|
49
|
+
syncUnifiedContainer: () => void;
|
|
50
|
+
scrollTo: import("../../../_internal/scrollbar/src/ScrollBar").ScrollTo;
|
|
51
|
+
sync: () => void;
|
|
52
|
+
handleMouseEnterWrapper: () => void;
|
|
53
|
+
handleMouseLeaveWrapper: () => void;
|
|
45
54
|
} | null>;
|
|
46
55
|
yearScrollRef: import("vue").Ref<{
|
|
47
56
|
listElRef: HTMLElement;
|
|
@@ -49,12 +58,19 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
49
58
|
scrollTo: import("vueuc/lib/virtual-list/src/VirtualList").ScrollTo;
|
|
50
59
|
} | null>;
|
|
51
60
|
scrollbarInstRef: import("vue").Ref<{
|
|
52
|
-
scrollTo: import("../../../_internal/scrollbar/src/ScrollBar").ScrollTo;
|
|
53
|
-
sync: () => void;
|
|
54
61
|
containerRef: HTMLElement | null;
|
|
55
62
|
contentRef: HTMLElement | null;
|
|
56
63
|
containerScrollTop: number;
|
|
64
|
+
syncUnifiedContainer: () => void;
|
|
65
|
+
scrollTo: import("../../../_internal/scrollbar/src/ScrollBar").ScrollTo;
|
|
66
|
+
sync: () => void;
|
|
67
|
+
handleMouseEnterWrapper: () => void;
|
|
68
|
+
handleMouseLeaveWrapper: () => void;
|
|
57
69
|
} | null>;
|
|
70
|
+
handleQuickMonthClick: (dateItem: import("../utils").MonthItem | import("../utils").YearItem | import("../utils").QuarterItem, updatePanelValue: (value: number) => void) => void;
|
|
71
|
+
scrollPickerColumns: (value?: number | undefined) => void;
|
|
72
|
+
calendarValue: import("vue").Ref<number>;
|
|
73
|
+
onUpdateCalendarValue: (value: number) => void;
|
|
58
74
|
mergedTheme: import("vue").Ref<{
|
|
59
75
|
common: {
|
|
60
76
|
baseColor: string;
|
|
@@ -199,7 +215,12 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
199
215
|
arrowSize: string;
|
|
200
216
|
panelHeaderPadding: string;
|
|
201
217
|
calendarDaysHeight: string;
|
|
202
|
-
calendarTitleGridTempateColumns: string;
|
|
218
|
+
calendarTitleGridTempateColumns: string; /**
|
|
219
|
+
* Date Panel
|
|
220
|
+
* Update picker value on:
|
|
221
|
+
* 1. item click
|
|
222
|
+
* 2. clear click
|
|
223
|
+
*/
|
|
203
224
|
calendarLeftPaddingDate: string;
|
|
204
225
|
calendarLeftPaddingDatetime: string;
|
|
205
226
|
calendarLeftPaddingDaterange: string;
|
|
@@ -476,7 +497,12 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
476
497
|
iconMarginLarge: string;
|
|
477
498
|
iconSizeTiny: string;
|
|
478
499
|
iconSizeSmall: string;
|
|
479
|
-
iconSizeMedium: string;
|
|
500
|
+
iconSizeMedium: string; /**
|
|
501
|
+
* Date Panel
|
|
502
|
+
* Update picker value on:
|
|
503
|
+
* 1. item click
|
|
504
|
+
* 2. clear click
|
|
505
|
+
*/
|
|
480
506
|
iconSizeLarge: string;
|
|
481
507
|
rippleDuration: string;
|
|
482
508
|
}, any>;
|
|
@@ -701,7 +727,12 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
701
727
|
iconMarginLarge: string;
|
|
702
728
|
iconSizeTiny: string;
|
|
703
729
|
iconSizeSmall: string;
|
|
704
|
-
iconSizeMedium: string;
|
|
730
|
+
iconSizeMedium: string; /**
|
|
731
|
+
* Date Panel
|
|
732
|
+
* Update picker value on:
|
|
733
|
+
* 1. item click
|
|
734
|
+
* 2. clear click
|
|
735
|
+
*/
|
|
705
736
|
iconSizeLarge: string;
|
|
706
737
|
rippleDuration: string;
|
|
707
738
|
}, any>;
|
|
@@ -988,7 +1019,12 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
988
1019
|
iconMarginLarge: string;
|
|
989
1020
|
iconSizeTiny: string;
|
|
990
1021
|
iconSizeSmall: string;
|
|
991
|
-
iconSizeMedium: string;
|
|
1022
|
+
iconSizeMedium: string; /**
|
|
1023
|
+
* Date Panel
|
|
1024
|
+
* Update picker value on:
|
|
1025
|
+
* 1. item click
|
|
1026
|
+
* 2. clear click
|
|
1027
|
+
*/
|
|
992
1028
|
iconSizeLarge: string;
|
|
993
1029
|
rippleDuration: string;
|
|
994
1030
|
}, any>> | undefined;
|
|
@@ -1107,6 +1143,8 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
1107
1143
|
restorePendingValue: () => void;
|
|
1108
1144
|
getShortcutValue: (shortcut: number | [number, number] | (() => number) | (() => [number, number])) => number | [number, number];
|
|
1109
1145
|
handleShortcutMouseleave: () => void;
|
|
1146
|
+
showMonthYearPanel: import("vue").Ref<boolean>;
|
|
1147
|
+
handleOpenQuickSelectMonthPanel: () => void;
|
|
1110
1148
|
isValueInvalid: import("vue").ComputedRef<boolean>;
|
|
1111
1149
|
isDateDisabled: import("vue").Ref<import("../interface").IsDateDisabled | undefined>;
|
|
1112
1150
|
isDateInvalid: import("vue").ComputedRef<boolean>;
|
|
@@ -1131,32 +1169,37 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
1131
1169
|
handleConfirmClick: () => void;
|
|
1132
1170
|
handleSingleShortcutMouseenter: (shortcut: number | [number, number] | (() => number) | (() => [number, number])) => void;
|
|
1133
1171
|
handleSingleShortcutClick: (shortcut: number | [number, number] | (() => number) | (() => [number, number])) => void;
|
|
1134
|
-
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<{
|
|
1135
|
-
readonly actions
|
|
1136
|
-
|
|
1137
|
-
|
|
1138
|
-
|
|
1139
|
-
readonly
|
|
1140
|
-
readonly
|
|
1141
|
-
readonly
|
|
1142
|
-
|
|
1143
|
-
|
|
1144
|
-
|
|
1145
|
-
|
|
1146
|
-
|
|
1147
|
-
|
|
1148
|
-
|
|
1149
|
-
|
|
1150
|
-
|
|
1151
|
-
|
|
1152
|
-
|
|
1153
|
-
|
|
1154
|
-
|
|
1155
|
-
|
|
1156
|
-
defaultTime
|
|
1157
|
-
|
|
1158
|
-
|
|
1159
|
-
|
|
1172
|
+
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
1173
|
+
readonly actions: {
|
|
1174
|
+
readonly type: import("vue").PropType<string[]>;
|
|
1175
|
+
readonly default: () => string[];
|
|
1176
|
+
};
|
|
1177
|
+
readonly active: BooleanConstructor;
|
|
1178
|
+
readonly dateFormat: StringConstructor;
|
|
1179
|
+
readonly timeFormat: {
|
|
1180
|
+
readonly type: StringConstructor;
|
|
1181
|
+
/**
|
|
1182
|
+
* Date Panel
|
|
1183
|
+
* Update picker value on:
|
|
1184
|
+
* 1. item click
|
|
1185
|
+
* 2. clear click
|
|
1186
|
+
*/
|
|
1187
|
+
readonly value: "HH:mm:ss";
|
|
1188
|
+
};
|
|
1189
|
+
readonly value: {
|
|
1190
|
+
readonly type: import("vue").PropType<import("../interface").Value | null>;
|
|
1191
|
+
readonly default: null;
|
|
1192
|
+
};
|
|
1193
|
+
readonly shortcuts: import("vue").PropType<import("../interface").Shortcuts>;
|
|
1194
|
+
readonly defaultTime: import("vue").PropType<import("../interface").DefaultTime>;
|
|
1195
|
+
readonly onConfirm: FunctionConstructor;
|
|
1196
|
+
readonly onClose: import("vue").PropType<import("../interface").OnClose>;
|
|
1197
|
+
readonly onTabOut: FunctionConstructor;
|
|
1198
|
+
readonly onUpdateValue: {
|
|
1199
|
+
readonly type: import("vue").PropType<import("../interface").OnPanelUpdateValue>;
|
|
1200
|
+
readonly required: true;
|
|
1201
|
+
};
|
|
1202
|
+
}>>, {
|
|
1160
1203
|
value: import("../interface").Value | null;
|
|
1161
1204
|
active: boolean;
|
|
1162
1205
|
actions: string[];
|
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
import { h, defineComponent,
|
|
2
|
-
import { NButton, NxButton } from '../../../button';
|
|
1
|
+
import { h, defineComponent, watchEffect } from 'vue';
|
|
3
2
|
import { BackwardIcon, FastBackwardIcon, ForwardIcon, FastForwardIcon } from '../../../_internal/icons';
|
|
3
|
+
import { NButton, NxButton } from '../../../button';
|
|
4
4
|
import { NBaseFocusDetector } from '../../../_internal';
|
|
5
|
-
import { useCalendar, useCalendarProps } from './use-calendar';
|
|
6
5
|
import { warnOnce } from '../../../_utils';
|
|
6
|
+
import { useCalendar, useCalendarProps } from './use-calendar';
|
|
7
|
+
import PanelHeader from './panelHeader';
|
|
7
8
|
/**
|
|
8
9
|
* Date Panel
|
|
9
10
|
* Update picker value on:
|
|
@@ -34,9 +35,7 @@ export default defineComponent({
|
|
|
34
35
|
h(FastBackwardIcon, null)),
|
|
35
36
|
h("div", { class: `${mergedClsPrefix}-date-panel-month__prev`, onClick: this.prevMonth },
|
|
36
37
|
h(BackwardIcon, null)),
|
|
37
|
-
h(
|
|
38
|
-
? `${this.calendarMonth} ${this.calendarYear}`
|
|
39
|
-
: `${this.calendarYear} ${this.calendarMonth}`),
|
|
38
|
+
h(PanelHeader, { monthBeforeYear: this.locale.monthBeforeYear, value: this.calendarValue, onUpdateValue: this.onUpdateCalendarValue, mergedClsPrefix: mergedClsPrefix, calendarMonth: this.calendarMonth, calendarYear: this.calendarYear }),
|
|
40
39
|
h("div", { class: `${mergedClsPrefix}-date-panel-month__next`, onClick: this.nextMonth },
|
|
41
40
|
h(ForwardIcon, null)),
|
|
42
41
|
h("div", { class: `${mergedClsPrefix}-date-panel-month__fast-next`, onClick: this.nextYear },
|
|
@@ -53,7 +52,7 @@ export default defineComponent({
|
|
|
53
52
|
], onClick: () => this.handleDateClick(dateItem) },
|
|
54
53
|
dateItem.dateObject.date,
|
|
55
54
|
dateItem.isCurrentDate ? (h("div", { class: `${mergedClsPrefix}-date-panel-date__sup` })) : null))))),
|
|
56
|
-
this.datePickerSlots.footer ? (h("div", { class: `${mergedClsPrefix}-date-panel-footer` },
|
|
55
|
+
this.datePickerSlots.footer ? (h("div", { class: `${mergedClsPrefix}-date-panel-footer` }, this.datePickerSlots.footer())) : null,
|
|
57
56
|
((_a = this.actions) === null || _a === void 0 ? void 0 : _a.length) || shortcuts ? (h("div", { class: `${mergedClsPrefix}-date-panel-actions` },
|
|
58
57
|
h("div", { class: `${mergedClsPrefix}-date-panel-actions__prefix` }, shortcuts &&
|
|
59
58
|
Object.keys(shortcuts).map((key) => {
|