naive-ui 2.28.3 → 2.29.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/es/_internal/clear/src/Clear.js +6 -3
- package/es/_internal/clear/src/styles/index.cssr.js +5 -2
- package/es/_internal/loading/src/styles/index.cssr.js +1 -1
- package/es/_internal/menu-mask/src/styles/index.cssr.js +1 -1
- package/es/_internal/scrollbar/src/styles/index.cssr.js +1 -1
- package/es/_internal/select-menu/src/SelectMenu.d.ts +2 -0
- package/es/_internal/select-menu/src/styles/index.cssr.js +1 -1
- package/es/_internal/selection/src/Selection.d.ts +5 -3
- package/es/_internal/selection/src/styles/index.cssr.js +2 -0
- package/es/_internal/slot-machine/src/styles/index.cssr.js +2 -2
- package/es/_internal/suffix/src/Suffix.js +1 -1
- package/es/_mixins/use-style.js +11 -7
- package/es/_mixins/use-theme.js +9 -7
- package/es/_styles/common/_common.d.ts +2 -0
- package/es/_styles/common/_common.js +2 -0
- package/es/_styles/common/light.d.ts +2 -0
- package/es/_styles/transitions/fade-down.cssr.d.ts +1 -1
- package/es/_styles/transitions/fade-down.cssr.js +1 -1
- package/es/_styles/transitions/fade-in-height-expand.cssr.d.ts +1 -1
- package/es/_styles/transitions/fade-in-height-expand.cssr.js +1 -1
- package/es/_styles/transitions/fade-in-scale-up.cssr.d.ts +1 -1
- package/es/_styles/transitions/fade-in-scale-up.cssr.js +1 -1
- package/es/_styles/transitions/fade-in-width-expand.cssr.d.ts +1 -1
- package/es/_styles/transitions/fade-in-width-expand.cssr.js +1 -1
- package/es/_styles/transitions/fade-in.cssr.d.ts +1 -1
- package/es/_styles/transitions/fade-in.cssr.js +1 -1
- package/es/_styles/transitions/fade-up-width-expand.cssr.d.ts +1 -1
- package/es/_styles/transitions/fade-up-width-expand.cssr.js +1 -1
- package/es/_styles/transitions/icon-switch.cssr.d.ts +1 -1
- package/es/_styles/transitions/icon-switch.cssr.js +1 -1
- package/es/_styles/transitions/slide-in-from-bottom.d.ts +1 -1
- package/es/_styles/transitions/slide-in-from-bottom.js +1 -1
- package/es/_styles/transitions/slide-in-from-left.d.ts +1 -1
- package/es/_styles/transitions/slide-in-from-left.js +1 -1
- package/es/_styles/transitions/slide-in-from-right.d.ts +1 -1
- package/es/_styles/transitions/slide-in-from-right.js +1 -1
- package/es/_styles/transitions/slide-in-from-top.d.ts +1 -1
- package/es/_styles/transitions/slide-in-from-top.js +1 -1
- package/es/_utils/naive/prop.d.ts +10 -1
- package/es/_utils/naive/prop.js +3 -0
- package/es/alert/src/Alert.d.ts +2 -0
- package/es/alert/src/styles/index.cssr.js +2 -2
- package/es/auto-complete/src/AutoComplete.d.ts +2 -0
- package/es/auto-complete/src/styles/index.cssr.js +1 -1
- package/es/avatar-group/src/AvatarGroup.d.ts +2 -0
- package/es/back-top/src/styles/index.cssr.js +1 -1
- package/es/badge/src/styles/index.cssr.js +1 -1
- package/es/button/src/styles/index.cssr.js +2 -2
- package/es/calendar/src/Calendar.d.ts +2 -0
- package/es/calendar/src/Calendar.js +3 -3
- package/es/card/src/Card.d.ts +2 -0
- package/es/cascader/src/Cascader.d.ts +2 -0
- package/es/cascader/src/CascaderMenu.d.ts +2 -0
- package/es/cascader/src/CascaderOption.d.ts +2 -0
- package/es/cascader/src/CascaderSelectMenu.d.ts +2 -0
- package/es/cascader/src/CascaderSubmenu.d.ts +2 -0
- package/es/cascader/src/styles/index.cssr.js +1 -1
- package/es/checkbox/src/Checkbox.d.ts +2 -0
- package/es/checkbox/src/styles/index.cssr.js +1 -1
- package/es/collapse/src/Collapse.d.ts +2 -0
- package/es/collapse/src/styles/index.cssr.js +1 -1
- package/es/collapse-transition/src/styles/index.cssr.js +1 -1
- package/es/color-picker/src/ColorInputUnit.d.ts +2 -0
- package/es/color-picker/src/ColorPicker.d.ts +3 -0
- package/es/color-picker/src/ColorPicker.js +7 -1
- package/es/color-picker/src/interface.d.ts +2 -0
- package/es/color-picker/src/styles/index.cssr.js +1 -1
- package/es/config-provider/src/ConfigProvider.d.ts +4 -0
- package/es/config-provider/src/ConfigProvider.js +4 -1
- package/es/config-provider/src/internal-interface.d.ts +1 -0
- package/es/data-table/src/DataTable.d.ts +422 -140
- package/es/data-table/src/HeaderButton/FilterButton.d.ts +44 -14
- package/es/data-table/src/HeaderButton/FilterMenu.d.ts +44 -14
- package/es/data-table/src/TableParts/Body.d.ts +44 -14
- package/es/data-table/src/TableParts/Cell.d.ts +88 -28
- package/es/data-table/src/TableParts/Header.d.ts +44 -14
- package/es/data-table/src/styles/index.cssr.js +2 -2
- package/es/data-table/styles/light.d.ts +42 -14
- package/es/date-picker/src/DatePicker.d.ts +2 -0
- package/es/date-picker/src/DatePicker.js +20 -7
- package/es/date-picker/src/panel/date.d.ts +2 -0
- package/es/date-picker/src/panel/daterange.d.ts +2 -0
- package/es/date-picker/src/panel/datetime.d.ts +2 -0
- package/es/date-picker/src/panel/datetimerange.d.ts +2 -0
- package/es/date-picker/src/panel/month.d.ts +2 -0
- package/es/date-picker/src/panel/monthrange.d.ts +2 -0
- package/es/date-picker/src/panel/panelHeader.d.ts +4 -0
- package/es/date-picker/src/panel/use-calendar.d.ts +2 -0
- package/es/date-picker/src/panel/use-calendar.js +1 -1
- package/es/date-picker/src/panel/use-dual-calendar.d.ts +2 -0
- package/es/date-picker/src/panel/use-dual-calendar.js +1 -1
- package/es/date-picker/src/panel/use-panel-common.d.ts +2 -0
- package/es/date-picker/src/styles/index.cssr.js +6 -1
- package/es/date-picker/src/utils.d.ts +2 -2
- package/es/date-picker/src/utils.js +1 -1
- package/es/date-picker/src/validation-utils.js +1 -1
- package/es/dialog/src/Dialog.d.ts +2 -0
- package/es/dialog/src/DialogProvider.d.ts +4 -0
- package/es/drawer/src/Drawer.d.ts +2 -0
- package/es/drawer/src/DrawerBodyWrapper.d.ts +2 -0
- package/es/drawer/src/DrawerContent.d.ts +2 -0
- package/es/drawer/src/styles/index.cssr.js +5 -5
- package/es/dropdown/src/Dropdown.d.ts +2 -0
- package/es/dropdown/src/styles/index.cssr.js +1 -1
- package/es/dynamic-input/src/DynamicInput.d.ts +2 -0
- package/es/dynamic-input/src/InputPreset.d.ts +2 -0
- package/es/dynamic-input/src/PairPreset.d.ts +2 -0
- package/es/dynamic-tags/src/DynamicTags.d.ts +45 -13
- package/es/dynamic-tags/src/DynamicTags.js +4 -1
- package/es/dynamic-tags/styles/light.d.ts +3 -0
- package/es/ellipsis/src/Ellipsis.d.ts +2 -0
- package/es/form/src/styles/form-item.cssr.js +1 -1
- package/es/global-style/src/GlobalStyle.js +3 -1
- package/es/image/src/styles/index.cssr.js +3 -3
- package/es/input/src/Input.d.ts +2 -0
- package/es/input/src/Input.js +18 -11
- package/es/input/src/styles/input.cssr.js +1 -5
- package/es/input-number/src/InputNumber.d.ts +2 -0
- package/es/layout/src/Layout.d.ts +4 -0
- package/es/layout/src/LayoutContent.d.ts +2 -0
- package/es/layout/src/LayoutSider.d.ts +2 -0
- package/es/loading-bar/src/styles/index.cssr.js +1 -1
- package/es/locales/common/nlNL.d.ts +3 -0
- package/es/locales/common/nlNL.js +111 -0
- package/es/locales/date/deDE.js +1 -1
- package/es/locales/date/enGB.js +1 -1
- package/es/locales/date/enUS.d.ts +2 -2
- package/es/locales/date/enUS.js +1 -1
- package/es/locales/date/eo.js +1 -1
- package/es/locales/date/esAR.js +1 -1
- package/es/locales/date/frFR.js +1 -1
- package/es/locales/date/idID.js +1 -1
- package/es/locales/date/itIT.js +1 -1
- package/es/locales/date/jaJP.js +1 -1
- package/es/locales/date/koKR.js +1 -1
- package/es/locales/date/nbNO.js +1 -1
- package/es/locales/date/nlNL.d.ts +3 -0
- package/es/locales/date/nlNL.js +6 -0
- package/es/locales/date/plPL.js +1 -1
- package/es/locales/date/ptBR.js +1 -1
- package/es/locales/date/ruRU.js +1 -1
- package/es/locales/date/skSK.js +1 -1
- package/es/locales/date/thTH.js +1 -1
- package/es/locales/date/ukUA.js +1 -1
- package/es/locales/date/zhCN.js +1 -1
- package/es/locales/date/zhTW.js +1 -1
- package/es/locales/index.d.ts +2 -0
- package/es/locales/index.js +2 -0
- package/es/log/src/Log.d.ts +2 -0
- package/es/log/src/styles/index.cssr.js +1 -1
- package/es/mention/src/Mention.d.ts +2 -0
- package/es/mention/src/styles/index.cssr.js +2 -2
- package/es/menu/src/Menu.d.ts +2 -0
- package/es/menu/src/MenuOption.d.ts +2 -0
- package/es/menu/src/MenuOptionContent.js +1 -1
- package/es/menu/src/Submenu.d.ts +2 -0
- package/es/menu/src/styles/index.cssr.js +2 -2
- package/es/message/src/styles/index.cssr.js +3 -3
- package/es/modal/src/BodyWrapper.d.ts +2 -0
- package/es/modal/src/styles/index.cssr.js +2 -2
- package/es/notification/index.d.ts +2 -1
- package/es/notification/src/Notification.js +18 -17
- package/es/notification/src/NotificationContainer.d.ts +7 -2
- package/es/notification/src/NotificationContainer.js +17 -5
- package/es/notification/src/NotificationEnvironment.d.ts +3 -2
- package/es/notification/src/NotificationEnvironment.js +9 -1
- package/es/notification/src/NotificationProvider.d.ts +3 -3
- package/es/notification/src/NotificationProvider.js +5 -2
- package/es/notification/src/styles/index.cssr.js +41 -11
- package/es/pagination/src/Pagination.d.ts +446 -151
- package/es/pagination/src/Pagination.js +22 -13
- package/es/pagination/src/interface.d.ts +1 -0
- package/es/pagination/src/styles/index.cssr.js +38 -39
- package/es/pagination/styles/_common.d.ts +33 -13
- package/es/pagination/styles/_common.js +33 -13
- package/es/pagination/styles/light.d.ts +84 -28
- package/es/pagination/styles/light.js +6 -2
- package/es/popconfirm/src/Popconfirm.d.ts +2 -0
- package/es/popover/src/PopoverBody.js +6 -6
- package/es/popover/src/styles/index.cssr.js +22 -21
- package/es/popselect/src/Popselect.d.ts +35 -12
- package/es/popselect/src/Popselect.js +1 -0
- package/es/popselect/src/PopselectPanel.d.ts +10 -1
- package/es/popselect/src/PopselectPanel.js +21 -4
- package/es/popselect/src/interface.d.ts +3 -1
- package/es/popselect/src/styles/index.cssr.d.ts +2 -0
- package/es/popselect/src/styles/index.cssr.js +5 -0
- package/es/popselect/styles/light.d.ts +7 -1
- package/es/popselect/styles/light.js +8 -1
- package/es/select/src/Select.d.ts +3 -1
- package/es/select/src/Select.js +1 -1
- package/es/select/src/interface.d.ts +1 -1
- package/es/select/src/styles/index.cssr.js +1 -1
- package/es/slider/src/styles/index.cssr.js +1 -1
- package/es/spin/src/styles/index.cssr.js +1 -1
- package/es/steps/src/styles/index.cssr.js +1 -1
- package/es/switch/src/styles/index.cssr.js +1 -1
- package/es/tabs/src/styles/index.cssr.js +5 -4
- package/es/tag/src/Tag.d.ts +31 -4
- package/es/tag/src/common-props.d.ts +1 -1
- package/es/tag/styles/_common.d.ts +1 -0
- package/es/tag/styles/_common.js +1 -0
- package/es/tag/styles/dark.js +3 -3
- package/es/tag/styles/light.d.ts +3 -0
- package/es/tag/styles/light.js +3 -3
- package/es/theme-editor/src/ThemeEditor.d.ts +2 -0
- package/es/theme-editor/src/ThemeEditor.js +113 -125
- package/es/time/src/Time.js +2 -2
- package/es/time-picker/src/Panel.d.ts +2 -0
- package/es/time-picker/src/TimePicker.d.ts +2 -0
- package/es/time-picker/src/TimePicker.js +7 -2
- package/es/time-picker/src/styles/index.cssr.js +1 -1
- package/es/time-picker/src/utils.js +1 -1
- package/es/tooltip/src/Tooltip.d.ts +2 -0
- package/es/transfer/src/Transfer.d.ts +2 -0
- package/es/transfer/src/TransferFilter.d.ts +2 -0
- package/es/transfer/src/TransferFilter.js +1 -1
- package/es/transfer/src/TransferList.d.ts +2 -0
- package/es/transfer/src/TransferListItem.d.ts +2 -0
- package/es/transfer/src/styles/index.cssr.js +1 -2
- package/es/tree/src/Tree.d.ts +2 -0
- package/es/tree/src/TreeNodeCheckbox.d.ts +2 -0
- package/es/tree/src/styles/index.cssr.js +2 -2
- package/es/tree-select/src/TreeSelect.d.ts +3 -1
- package/es/tree-select/src/TreeSelect.js +1 -1
- package/es/tree-select/src/styles/index.cssr.js +1 -1
- package/es/upload/src/Upload.d.ts +2 -0
- package/es/upload/src/Upload.js +16 -3
- package/es/upload/src/UploadFile.d.ts +2 -0
- package/es/upload/src/UploadProgress.d.ts +2 -0
- package/es/upload/src/interface.d.ts +2 -0
- package/es/upload/src/styles/index.cssr.js +4 -4
- package/es/upload/src/utils.d.ts +6 -0
- package/es/upload/src/utils.js +38 -1
- package/es/version.d.ts +1 -1
- package/es/version.js +1 -1
- package/lib/_internal/clear/src/Clear.js +6 -3
- package/lib/_internal/clear/src/styles/index.cssr.js +5 -8
- package/lib/_internal/loading/src/styles/index.cssr.js +3 -9
- package/lib/_internal/menu-mask/src/styles/index.cssr.js +2 -8
- package/lib/_internal/scrollbar/src/styles/index.cssr.js +2 -8
- package/lib/_internal/select-menu/src/SelectMenu.d.ts +2 -0
- package/lib/_internal/select-menu/src/styles/index.cssr.js +2 -8
- package/lib/_internal/selection/src/Selection.d.ts +5 -3
- package/lib/_internal/selection/src/styles/index.cssr.js +2 -0
- package/lib/_internal/slot-machine/src/styles/index.cssr.js +4 -10
- package/lib/_internal/suffix/src/Suffix.js +1 -1
- package/lib/_mixins/use-style.js +10 -6
- package/lib/_mixins/use-theme.js +9 -7
- package/lib/_styles/common/_common.d.ts +2 -0
- package/lib/_styles/common/_common.js +2 -0
- package/lib/_styles/common/light.d.ts +2 -0
- package/lib/_styles/transitions/fade-down.cssr.d.ts +1 -1
- package/lib/_styles/transitions/fade-down.cssr.js +3 -2
- package/lib/_styles/transitions/fade-in-height-expand.cssr.d.ts +1 -1
- package/lib/_styles/transitions/fade-in-height-expand.cssr.js +3 -2
- package/lib/_styles/transitions/fade-in-scale-up.cssr.d.ts +1 -1
- package/lib/_styles/transitions/fade-in-scale-up.cssr.js +3 -2
- package/lib/_styles/transitions/fade-in-width-expand.cssr.d.ts +1 -1
- package/lib/_styles/transitions/fade-in-width-expand.cssr.js +3 -2
- package/lib/_styles/transitions/fade-in.cssr.d.ts +1 -1
- package/lib/_styles/transitions/fade-in.cssr.js +3 -2
- package/lib/_styles/transitions/fade-up-width-expand.cssr.d.ts +1 -1
- package/lib/_styles/transitions/fade-up-width-expand.cssr.js +2 -1
- package/lib/_styles/transitions/icon-switch.cssr.d.ts +1 -1
- package/lib/_styles/transitions/icon-switch.cssr.js +3 -2
- package/lib/_styles/transitions/slide-in-from-bottom.d.ts +1 -1
- package/lib/_styles/transitions/slide-in-from-bottom.js +3 -2
- package/lib/_styles/transitions/slide-in-from-left.d.ts +1 -1
- package/lib/_styles/transitions/slide-in-from-left.js +3 -2
- package/lib/_styles/transitions/slide-in-from-right.d.ts +1 -1
- package/lib/_styles/transitions/slide-in-from-right.js +3 -2
- package/lib/_styles/transitions/slide-in-from-top.d.ts +1 -1
- package/lib/_styles/transitions/slide-in-from-top.js +3 -2
- package/lib/_utils/naive/prop.d.ts +10 -1
- package/lib/_utils/naive/prop.js +3 -0
- package/lib/alert/src/Alert.d.ts +2 -0
- package/lib/alert/src/styles/index.cssr.js +2 -8
- package/lib/auto-complete/src/AutoComplete.d.ts +2 -0
- package/lib/auto-complete/src/styles/index.cssr.js +2 -8
- package/lib/avatar-group/src/AvatarGroup.d.ts +2 -0
- package/lib/back-top/src/styles/index.cssr.js +2 -8
- package/lib/badge/src/styles/index.cssr.js +3 -9
- package/lib/button/src/styles/index.cssr.js +4 -10
- package/lib/calendar/src/Calendar.d.ts +2 -0
- package/lib/calendar/src/Calendar.js +2 -2
- package/lib/card/src/Card.d.ts +2 -0
- package/lib/cascader/src/Cascader.d.ts +2 -0
- package/lib/cascader/src/CascaderMenu.d.ts +2 -0
- package/lib/cascader/src/CascaderOption.d.ts +2 -0
- package/lib/cascader/src/CascaderSelectMenu.d.ts +2 -0
- package/lib/cascader/src/CascaderSubmenu.d.ts +2 -0
- package/lib/cascader/src/styles/index.cssr.js +3 -9
- package/lib/checkbox/src/Checkbox.d.ts +2 -0
- package/lib/checkbox/src/styles/index.cssr.js +2 -8
- package/lib/collapse/src/Collapse.d.ts +2 -0
- package/lib/collapse/src/styles/index.cssr.js +2 -8
- package/lib/collapse-transition/src/styles/index.cssr.js +2 -8
- package/lib/color-picker/src/ColorInputUnit.d.ts +2 -0
- package/lib/color-picker/src/ColorPicker.d.ts +3 -0
- package/lib/color-picker/src/ColorPicker.js +7 -1
- package/lib/color-picker/src/interface.d.ts +2 -0
- package/lib/color-picker/src/styles/index.cssr.js +2 -8
- package/lib/config-provider/src/ConfigProvider.d.ts +4 -0
- package/lib/config-provider/src/ConfigProvider.js +4 -1
- package/lib/config-provider/src/internal-interface.d.ts +1 -0
- package/lib/data-table/src/DataTable.d.ts +422 -140
- package/lib/data-table/src/HeaderButton/FilterButton.d.ts +44 -14
- package/lib/data-table/src/HeaderButton/FilterMenu.d.ts +44 -14
- package/lib/data-table/src/TableParts/Body.d.ts +44 -14
- package/lib/data-table/src/TableParts/Cell.d.ts +88 -28
- package/lib/data-table/src/TableParts/Header.d.ts +44 -14
- package/lib/data-table/src/styles/index.cssr.js +5 -11
- package/lib/data-table/styles/light.d.ts +42 -14
- package/lib/date-picker/src/DatePicker.d.ts +2 -0
- package/lib/date-picker/src/DatePicker.js +18 -5
- package/lib/date-picker/src/panel/date.d.ts +2 -0
- package/lib/date-picker/src/panel/daterange.d.ts +2 -0
- package/lib/date-picker/src/panel/datetime.d.ts +2 -0
- package/lib/date-picker/src/panel/datetimerange.d.ts +2 -0
- package/lib/date-picker/src/panel/month.d.ts +2 -0
- package/lib/date-picker/src/panel/monthrange.d.ts +2 -0
- package/lib/date-picker/src/panel/panelHeader.d.ts +4 -0
- package/lib/date-picker/src/panel/use-calendar.d.ts +2 -0
- package/lib/date-picker/src/panel/use-dual-calendar.d.ts +2 -0
- package/lib/date-picker/src/panel/use-panel-common.d.ts +2 -0
- package/lib/date-picker/src/styles/index.cssr.js +7 -8
- package/lib/date-picker/src/utils.d.ts +2 -2
- package/lib/dialog/src/Dialog.d.ts +2 -0
- package/lib/dialog/src/DialogProvider.d.ts +4 -0
- package/lib/drawer/src/Drawer.d.ts +2 -0
- package/lib/drawer/src/DrawerBodyWrapper.d.ts +2 -0
- package/lib/drawer/src/DrawerContent.d.ts +2 -0
- package/lib/drawer/src/styles/index.cssr.js +7 -13
- package/lib/dropdown/src/Dropdown.d.ts +2 -0
- package/lib/dropdown/src/styles/index.cssr.js +2 -8
- package/lib/dynamic-input/src/DynamicInput.d.ts +2 -0
- package/lib/dynamic-input/src/InputPreset.d.ts +2 -0
- package/lib/dynamic-input/src/PairPreset.d.ts +2 -0
- package/lib/dynamic-tags/src/DynamicTags.d.ts +45 -13
- package/lib/dynamic-tags/src/DynamicTags.js +4 -1
- package/lib/dynamic-tags/styles/light.d.ts +3 -0
- package/lib/ellipsis/src/Ellipsis.d.ts +2 -0
- package/lib/form/src/styles/form-item.cssr.js +2 -8
- package/lib/global-style/src/GlobalStyle.js +3 -1
- package/lib/image/src/styles/index.cssr.js +5 -11
- package/lib/input/src/Input.d.ts +2 -0
- package/lib/input/src/Input.js +18 -11
- package/lib/input/src/styles/input.cssr.js +1 -5
- package/lib/input-number/src/InputNumber.d.ts +2 -0
- package/lib/layout/src/Layout.d.ts +4 -0
- package/lib/layout/src/LayoutContent.d.ts +2 -0
- package/lib/layout/src/LayoutSider.d.ts +2 -0
- package/lib/loading-bar/src/styles/index.cssr.js +2 -8
- package/lib/locales/common/nlNL.d.ts +3 -0
- package/lib/locales/common/nlNL.js +113 -0
- package/lib/locales/date/enUS.d.ts +2 -2
- package/lib/locales/date/nlNL.d.ts +3 -0
- package/lib/locales/date/nlNL.js +11 -0
- package/lib/locales/index.d.ts +2 -0
- package/lib/locales/index.js +5 -1
- package/lib/log/src/Log.d.ts +2 -0
- package/lib/log/src/styles/index.cssr.js +2 -8
- package/lib/mention/src/Mention.d.ts +2 -0
- package/lib/mention/src/styles/index.cssr.js +2 -8
- package/lib/menu/src/Menu.d.ts +2 -0
- package/lib/menu/src/MenuOption.d.ts +2 -0
- package/lib/menu/src/MenuOptionContent.js +1 -1
- package/lib/menu/src/Submenu.d.ts +2 -0
- package/lib/menu/src/styles/index.cssr.js +3 -9
- package/lib/message/src/styles/index.cssr.js +4 -10
- package/lib/modal/src/BodyWrapper.d.ts +2 -0
- package/lib/modal/src/styles/index.cssr.js +4 -10
- package/lib/notification/index.d.ts +2 -1
- package/lib/notification/src/Notification.js +18 -17
- package/lib/notification/src/NotificationContainer.d.ts +7 -2
- package/lib/notification/src/NotificationContainer.js +16 -4
- package/lib/notification/src/NotificationEnvironment.d.ts +3 -2
- package/lib/notification/src/NotificationEnvironment.js +8 -0
- package/lib/notification/src/NotificationProvider.d.ts +3 -3
- package/lib/notification/src/NotificationProvider.js +5 -2
- package/lib/notification/src/styles/index.cssr.js +41 -11
- package/lib/pagination/src/Pagination.d.ts +446 -151
- package/lib/pagination/src/Pagination.js +19 -10
- package/lib/pagination/src/interface.d.ts +1 -0
- package/lib/pagination/src/styles/index.cssr.js +38 -39
- package/lib/pagination/styles/_common.d.ts +33 -13
- package/lib/pagination/styles/_common.js +33 -13
- package/lib/pagination/styles/light.d.ts +84 -28
- package/lib/pagination/styles/light.js +6 -2
- package/lib/popconfirm/src/Popconfirm.d.ts +2 -0
- package/lib/popover/src/PopoverBody.js +6 -6
- package/lib/popover/src/styles/index.cssr.js +22 -21
- package/lib/popselect/src/Popselect.d.ts +35 -12
- package/lib/popselect/src/Popselect.js +1 -0
- package/lib/popselect/src/PopselectPanel.d.ts +10 -1
- package/lib/popselect/src/PopselectPanel.js +23 -3
- package/lib/popselect/src/interface.d.ts +3 -1
- package/lib/popselect/src/styles/index.cssr.d.ts +2 -0
- package/lib/popselect/src/styles/index.cssr.js +12 -0
- package/lib/popselect/styles/light.d.ts +7 -1
- package/lib/popselect/styles/light.js +10 -1
- package/lib/select/src/Select.d.ts +3 -1
- package/lib/select/src/Select.js +1 -1
- package/lib/select/src/interface.d.ts +1 -1
- package/lib/select/src/styles/index.cssr.js +2 -8
- package/lib/slider/src/styles/index.cssr.js +3 -9
- package/lib/spin/src/styles/index.cssr.js +2 -8
- package/lib/steps/src/styles/index.cssr.js +4 -10
- package/lib/switch/src/styles/index.cssr.js +3 -9
- package/lib/tabs/src/styles/index.cssr.js +5 -4
- package/lib/tag/src/Tag.d.ts +31 -4
- package/lib/tag/src/common-props.d.ts +1 -1
- package/lib/tag/styles/_common.d.ts +1 -0
- package/lib/tag/styles/_common.js +1 -0
- package/lib/tag/styles/dark.js +3 -3
- package/lib/tag/styles/light.d.ts +3 -0
- package/lib/tag/styles/light.js +3 -3
- package/lib/theme-editor/src/ThemeEditor.d.ts +2 -0
- package/lib/theme-editor/src/ThemeEditor.js +113 -125
- package/lib/time/src/Time.js +6 -3
- package/lib/time-picker/src/Panel.d.ts +2 -0
- package/lib/time-picker/src/TimePicker.d.ts +2 -0
- package/lib/time-picker/src/TimePicker.js +6 -1
- package/lib/time-picker/src/styles/index.cssr.js +2 -8
- package/lib/tooltip/src/Tooltip.d.ts +2 -0
- package/lib/transfer/src/Transfer.d.ts +2 -0
- package/lib/transfer/src/TransferFilter.d.ts +2 -0
- package/lib/transfer/src/TransferFilter.js +1 -1
- package/lib/transfer/src/TransferList.d.ts +2 -0
- package/lib/transfer/src/TransferListItem.d.ts +2 -0
- package/lib/transfer/src/styles/index.cssr.js +2 -9
- package/lib/tree/src/Tree.d.ts +2 -0
- package/lib/tree/src/TreeNodeCheckbox.d.ts +2 -0
- package/lib/tree/src/styles/index.cssr.js +6 -12
- package/lib/tree-select/src/TreeSelect.d.ts +3 -1
- package/lib/tree-select/src/TreeSelect.js +1 -1
- package/lib/tree-select/src/styles/index.cssr.js +2 -8
- package/lib/upload/src/Upload.d.ts +2 -0
- package/lib/upload/src/Upload.js +15 -2
- package/lib/upload/src/UploadFile.d.ts +2 -0
- package/lib/upload/src/UploadProgress.d.ts +2 -0
- package/lib/upload/src/interface.d.ts +2 -0
- package/lib/upload/src/styles/index.cssr.js +4 -10
- package/lib/upload/src/utils.d.ts +6 -0
- package/lib/upload/src/utils.js +40 -2
- package/lib/version.d.ts +1 -1
- package/lib/version.js +1 -1
- package/package.json +13 -13
- package/volar.d.ts +24 -24
- package/web-types.json +23 -1
|
@@ -2071,12 +2071,14 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
2071
2071
|
borderRadius: string;
|
|
2072
2072
|
borderRadiusSmall: string;
|
|
2073
2073
|
fontSize: string;
|
|
2074
|
+
fontSizeMini: string;
|
|
2074
2075
|
fontSizeTiny: string;
|
|
2075
2076
|
fontSizeSmall: string;
|
|
2076
2077
|
fontSizeMedium: string;
|
|
2077
2078
|
fontSizeLarge: string;
|
|
2078
2079
|
fontSizeHuge: string;
|
|
2079
2080
|
lineHeight: string;
|
|
2081
|
+
heightMini: string;
|
|
2080
2082
|
heightTiny: string;
|
|
2081
2083
|
heightSmall: string;
|
|
2082
2084
|
heightMedium: string;
|
|
@@ -382,6 +382,7 @@ exports.default = (0, vue_1.defineComponent)({
|
|
|
382
382
|
if (mergedShowRef.value) {
|
|
383
383
|
const panelEl = (_a = panelInstRef.value) === null || _a === void 0 ? void 0 : _a.$el;
|
|
384
384
|
if (!(panelEl === null || panelEl === void 0 ? void 0 : panelEl.contains(e.relatedTarget))) {
|
|
385
|
+
deriveInputValue();
|
|
385
386
|
doBlur(e);
|
|
386
387
|
closePanel({
|
|
387
388
|
returnFocus: false
|
|
@@ -389,6 +390,7 @@ exports.default = (0, vue_1.defineComponent)({
|
|
|
389
390
|
}
|
|
390
391
|
}
|
|
391
392
|
else {
|
|
393
|
+
deriveInputValue();
|
|
392
394
|
doBlur(e);
|
|
393
395
|
}
|
|
394
396
|
}
|
|
@@ -508,6 +510,7 @@ exports.default = (0, vue_1.defineComponent)({
|
|
|
508
510
|
function handleMenuFocusOut(e) {
|
|
509
511
|
if (isInternalFocusSwitch(e))
|
|
510
512
|
return;
|
|
513
|
+
deriveInputValue();
|
|
511
514
|
doBlur(e);
|
|
512
515
|
closePanel({
|
|
513
516
|
returnFocus: false
|
|
@@ -640,7 +643,9 @@ exports.default = (0, vue_1.defineComponent)({
|
|
|
640
643
|
(0, vue_1.h)(vueuc_1.VTarget, null, {
|
|
641
644
|
default: () => ((0, vue_1.h)(input_1.NInput, { ref: "inputInstRef", status: this.mergedStatus, value: this.displayTimeString, bordered: this.mergedBordered, passivelyActivated: true, attrSize: this.mergedAttrSize, theme: this.mergedTheme.peers.Input, themeOverrides: this.mergedTheme.peerOverrides.Input, stateful: this.stateful, size: this.mergedSize, placeholder: this.localizedPlaceholder, clearable: this.clearable, disabled: this.mergedDisabled, textDecoration: this.isValueInvalid ? 'line-through' : undefined, onFocus: this.handleTimeInputFocus, onBlur: this.handleTimeInputBlur, onActivate: this.handleTimeInputActivate, onDeactivate: this.handleTimeInputDeactivate, onUpdateValue: this.handleTimeInputUpdateValue, onClear: this.handleTimeInputClear, internalDeactivateOnEnter: true, internalForceFocus: this.mergedShow, readonly: this.inputReadonly || this.mergedDisabled, onClick: this.handleTriggerClick }, this.showIcon
|
|
642
645
|
? {
|
|
643
|
-
[this.clearable
|
|
646
|
+
[this.clearable
|
|
647
|
+
? 'clear-icon-placeholder'
|
|
648
|
+
: 'suffix']: () => ((0, vue_1.h)(_internal_1.NBaseIcon, { clsPrefix: mergedClsPrefix, class: `${mergedClsPrefix}-time-picker-icon` }, {
|
|
644
649
|
default: () => $slots.icon ? $slots.icon() : (0, vue_1.h)(icons_1.TimeIcon, null)
|
|
645
650
|
}))
|
|
646
651
|
}
|
|
@@ -1,18 +1,12 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
var __importDefault = this && this.__importDefault || function (mod) {
|
|
4
|
-
return mod && mod.__esModule ? mod : {
|
|
5
|
-
"default": mod
|
|
6
|
-
};
|
|
7
|
-
};
|
|
8
|
-
|
|
9
3
|
Object.defineProperty(exports, "__esModule", {
|
|
10
4
|
value: true
|
|
11
5
|
});
|
|
12
6
|
|
|
13
7
|
const cssr_1 = require("../../../_utils/cssr");
|
|
14
8
|
|
|
15
|
-
const fade_in_scale_up_cssr_1 =
|
|
9
|
+
const fade_in_scale_up_cssr_1 = require("../../../_styles/transitions/fade-in-scale-up.cssr"); // vars:
|
|
16
10
|
// --n-icon-color
|
|
17
11
|
// --n-icon-color-disabled
|
|
18
12
|
// --n-bezier
|
|
@@ -51,7 +45,7 @@ exports.default = (0, cssr_1.c)([(0, cssr_1.cB)('time-picker', `
|
|
|
51
45
|
overflow: hidden;
|
|
52
46
|
background-color: var(--n-panel-color);
|
|
53
47
|
box-shadow: var(--n-panel-box-shadow);
|
|
54
|
-
`, [(0, fade_in_scale_up_cssr_1.
|
|
48
|
+
`, [(0, fade_in_scale_up_cssr_1.fadeInScaleUpTransition)(), (0, cssr_1.cB)('time-picker-actions', `
|
|
55
49
|
padding: var(--n-panel-action-padding);
|
|
56
50
|
align-items: center;
|
|
57
51
|
display: flex;
|
|
@@ -396,12 +396,14 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
396
396
|
borderRadius: string;
|
|
397
397
|
borderRadiusSmall: string;
|
|
398
398
|
fontSize: string;
|
|
399
|
+
fontSizeMini: string;
|
|
399
400
|
fontSizeTiny: string;
|
|
400
401
|
fontSizeSmall: string;
|
|
401
402
|
fontSizeMedium: string;
|
|
402
403
|
fontSizeLarge: string;
|
|
403
404
|
fontSizeHuge: string;
|
|
404
405
|
lineHeight: string;
|
|
406
|
+
heightMini: string;
|
|
405
407
|
heightTiny: string;
|
|
406
408
|
heightSmall: string;
|
|
407
409
|
heightMedium: string;
|
|
@@ -2178,12 +2178,14 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
2178
2178
|
borderRadius: string;
|
|
2179
2179
|
borderRadiusSmall: string;
|
|
2180
2180
|
fontSize: string;
|
|
2181
|
+
fontSizeMini: string;
|
|
2181
2182
|
fontSizeTiny: string;
|
|
2182
2183
|
fontSizeSmall: string;
|
|
2183
2184
|
fontSizeMedium: string;
|
|
2184
2185
|
fontSizeLarge: string;
|
|
2185
2186
|
fontSizeHuge: string;
|
|
2186
2187
|
lineHeight: string;
|
|
2188
|
+
heightMini: string;
|
|
2187
2189
|
heightTiny: string;
|
|
2188
2190
|
heightSmall: string;
|
|
2189
2191
|
heightMedium: string;
|
|
@@ -107,12 +107,14 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
107
107
|
borderRadius: string;
|
|
108
108
|
borderRadiusSmall: string;
|
|
109
109
|
fontSize: string;
|
|
110
|
+
fontSizeMini: string;
|
|
110
111
|
fontSizeTiny: string;
|
|
111
112
|
fontSizeSmall: string;
|
|
112
113
|
fontSizeMedium: string;
|
|
113
114
|
fontSizeLarge: string;
|
|
114
115
|
fontSizeHuge: string;
|
|
115
116
|
lineHeight: string;
|
|
117
|
+
heightMini: string;
|
|
116
118
|
heightTiny: string;
|
|
117
119
|
heightSmall: string;
|
|
118
120
|
heightMedium: string;
|
|
@@ -36,7 +36,7 @@ exports.default = (0, vue_1.defineComponent)({
|
|
|
36
36
|
const { mergedTheme, mergedClsPrefix } = this;
|
|
37
37
|
return ((0, vue_1.h)("div", { class: `${mergedClsPrefix}-transfer-filter` },
|
|
38
38
|
(0, vue_1.h)(input_1.NInput, { value: this.value, onUpdateValue: this.onUpdateValue, disabled: this.disabled, theme: mergedTheme.peers.Input, themeOverrides: mergedTheme.peerOverrides.Input, clearable: true, size: "small", placeholder: this.placeholder, onFocus: this.onFocus, onBlur: this.onBlur }, {
|
|
39
|
-
clear: () => ((0, vue_1.h)(_internal_1.NBaseIcon, { clsPrefix: mergedClsPrefix, class: `${mergedClsPrefix}-transfer-icon` }, { default: () => (0, vue_1.h)(icons_1.SearchIcon, null) }))
|
|
39
|
+
'clear-icon-placeholder': () => ((0, vue_1.h)(_internal_1.NBaseIcon, { clsPrefix: mergedClsPrefix, class: `${mergedClsPrefix}-transfer-icon` }, { default: () => (0, vue_1.h)(icons_1.SearchIcon, null) }))
|
|
40
40
|
})));
|
|
41
41
|
}
|
|
42
42
|
});
|
|
@@ -120,12 +120,14 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
120
120
|
borderRadius: string;
|
|
121
121
|
borderRadiusSmall: string;
|
|
122
122
|
fontSize: string;
|
|
123
|
+
fontSizeMini: string;
|
|
123
124
|
fontSizeTiny: string;
|
|
124
125
|
fontSizeSmall: string;
|
|
125
126
|
fontSizeMedium: string;
|
|
126
127
|
fontSizeLarge: string;
|
|
127
128
|
fontSizeHuge: string;
|
|
128
129
|
lineHeight: string;
|
|
130
|
+
heightMini: string;
|
|
129
131
|
heightTiny: string;
|
|
130
132
|
heightSmall: string;
|
|
131
133
|
heightMedium: string;
|
|
@@ -107,12 +107,14 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
107
107
|
borderRadius: string;
|
|
108
108
|
borderRadiusSmall: string;
|
|
109
109
|
fontSize: string;
|
|
110
|
+
fontSizeMini: string;
|
|
110
111
|
fontSizeTiny: string;
|
|
111
112
|
fontSizeSmall: string;
|
|
112
113
|
fontSizeMedium: string;
|
|
113
114
|
fontSizeLarge: string;
|
|
114
115
|
fontSizeHuge: string;
|
|
115
116
|
lineHeight: string;
|
|
117
|
+
heightMini: string;
|
|
116
118
|
heightTiny: string;
|
|
117
119
|
heightSmall: string;
|
|
118
120
|
heightMedium: string;
|
|
@@ -1,18 +1,12 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
var __importDefault = this && this.__importDefault || function (mod) {
|
|
4
|
-
return mod && mod.__esModule ? mod : {
|
|
5
|
-
"default": mod
|
|
6
|
-
};
|
|
7
|
-
};
|
|
8
|
-
|
|
9
3
|
Object.defineProperty(exports, "__esModule", {
|
|
10
4
|
value: true
|
|
11
5
|
});
|
|
12
6
|
|
|
13
7
|
const cssr_1 = require("../../../_utils/cssr");
|
|
14
8
|
|
|
15
|
-
const fade_in_cssr_1 =
|
|
9
|
+
const fade_in_cssr_1 = require("../../../_styles/transitions/fade-in.cssr");
|
|
16
10
|
|
|
17
11
|
const animation = (0, cssr_1.c)([(0, cssr_1.c)('@keyframes transfer-slide-in-from-left', `
|
|
18
12
|
0% {
|
|
@@ -126,7 +120,6 @@ exports.default = (0, cssr_1.c)([(0, cssr_1.cB)('transfer', `
|
|
|
126
120
|
flex-basis: 0;
|
|
127
121
|
flex-grow: 1;
|
|
128
122
|
box-sizing: border-box;
|
|
129
|
-
overflow: hidden;
|
|
130
123
|
position: relative;
|
|
131
124
|
display: flex;
|
|
132
125
|
flex-direction: column;
|
|
@@ -158,7 +151,7 @@ exports.default = (0, cssr_1.c)([(0, cssr_1.cB)('transfer', `
|
|
|
158
151
|
left: 50%;
|
|
159
152
|
top: 50%;
|
|
160
153
|
transform: translateY(-50%) translateX(-50%);
|
|
161
|
-
`, [(0, fade_in_cssr_1.
|
|
154
|
+
`, [(0, fade_in_cssr_1.fadeInTransition)()]), (0, cssr_1.cB)('transfer-list-content', `
|
|
162
155
|
padding: 0;
|
|
163
156
|
margin: 0;
|
|
164
157
|
position: relative;
|
package/lib/tree/src/Tree.d.ts
CHANGED
|
@@ -728,12 +728,14 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
728
728
|
borderRadius: string;
|
|
729
729
|
borderRadiusSmall: string;
|
|
730
730
|
fontSize: string;
|
|
731
|
+
fontSizeMini: string;
|
|
731
732
|
fontSizeTiny: string;
|
|
732
733
|
fontSizeSmall: string;
|
|
733
734
|
fontSizeMedium: string;
|
|
734
735
|
fontSizeLarge: string;
|
|
735
736
|
fontSizeHuge: string;
|
|
736
737
|
lineHeight: string;
|
|
738
|
+
heightMini: string;
|
|
737
739
|
heightTiny: string;
|
|
738
740
|
heightSmall: string;
|
|
739
741
|
heightMedium: string;
|
|
@@ -102,12 +102,14 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
102
102
|
borderRadius: string;
|
|
103
103
|
borderRadiusSmall: string;
|
|
104
104
|
fontSize: string;
|
|
105
|
+
fontSizeMini: string;
|
|
105
106
|
fontSizeTiny: string;
|
|
106
107
|
fontSizeSmall: string;
|
|
107
108
|
fontSizeMedium: string;
|
|
108
109
|
fontSizeLarge: string;
|
|
109
110
|
fontSizeHuge: string;
|
|
110
111
|
lineHeight: string;
|
|
112
|
+
heightMini: string;
|
|
111
113
|
heightTiny: string;
|
|
112
114
|
heightSmall: string;
|
|
113
115
|
heightMedium: string;
|
|
@@ -1,20 +1,14 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
var __importDefault = this && this.__importDefault || function (mod) {
|
|
4
|
-
return mod && mod.__esModule ? mod : {
|
|
5
|
-
"default": mod
|
|
6
|
-
};
|
|
7
|
-
};
|
|
8
|
-
|
|
9
3
|
Object.defineProperty(exports, "__esModule", {
|
|
10
4
|
value: true
|
|
11
5
|
});
|
|
12
6
|
|
|
13
7
|
const cssr_1 = require("../../../_utils/cssr");
|
|
14
8
|
|
|
15
|
-
const icon_switch_cssr_1 =
|
|
9
|
+
const icon_switch_cssr_1 = require("../../../_styles/transitions/icon-switch.cssr");
|
|
16
10
|
|
|
17
|
-
const fade_in_height_expand_cssr_1 =
|
|
11
|
+
const fade_in_height_expand_cssr_1 = require("../../../_styles/transitions/fade-in-height-expand.cssr"); // vars:
|
|
18
12
|
// --n-arrow-color
|
|
19
13
|
// --n-bezier
|
|
20
14
|
// --n-font-size
|
|
@@ -39,9 +33,9 @@ exports.default = (0, cssr_1.cB)('tree', `
|
|
|
39
33
|
flex-grow: 0;
|
|
40
34
|
flex-shrink: 0;
|
|
41
35
|
height: 0;
|
|
42
|
-
`), (0, cssr_1.cB)('tree-motion-wrapper', [(0, cssr_1.cM)('expand', [(0, fade_in_height_expand_cssr_1.
|
|
36
|
+
`), (0, cssr_1.cB)('tree-motion-wrapper', [(0, cssr_1.cM)('expand', [(0, fade_in_height_expand_cssr_1.fadeInHeightExpandTransition)({
|
|
43
37
|
duration: '0.2s'
|
|
44
|
-
})]), (0, cssr_1.cM)('collapse', [(0, fade_in_height_expand_cssr_1.
|
|
38
|
+
})]), (0, cssr_1.cM)('collapse', [(0, fade_in_height_expand_cssr_1.fadeInHeightExpandTransition)({
|
|
45
39
|
duration: '0.2s',
|
|
46
40
|
reverse: true
|
|
47
41
|
})])]), (0, cssr_1.cB)('tree-node-wrapper', `
|
|
@@ -98,14 +92,14 @@ exports.default = (0, cssr_1.cB)('tree', `
|
|
|
98
92
|
color: var(--n-arrow-color);
|
|
99
93
|
transition: color .3s var(--n-bezier);
|
|
100
94
|
font-size: 14px;
|
|
101
|
-
`, [(0, cssr_1.cB)('icon', [(0, icon_switch_cssr_1.
|
|
95
|
+
`, [(0, cssr_1.cB)('icon', [(0, icon_switch_cssr_1.iconSwitchTransition)()]), (0, cssr_1.cB)('base-loading', `
|
|
102
96
|
color: var(--n-loading-color);
|
|
103
97
|
position: absolute;
|
|
104
98
|
left: 0;
|
|
105
99
|
top: 0;
|
|
106
100
|
right: 0;
|
|
107
101
|
bottom: 0;
|
|
108
|
-
`, [(0, icon_switch_cssr_1.
|
|
102
|
+
`, [(0, icon_switch_cssr_1.iconSwitchTransition)()]), (0, cssr_1.cB)('base-icon', [(0, icon_switch_cssr_1.iconSwitchTransition)()])]), (0, cssr_1.cM)('hide', {
|
|
109
103
|
visibility: 'hidden'
|
|
110
104
|
}), (0, cssr_1.cM)('expanded', {
|
|
111
105
|
transform: 'rotate(90deg)'
|
|
@@ -1145,7 +1145,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
1145
1145
|
focused: import("vue").Ref<boolean>;
|
|
1146
1146
|
menuPadding: import("vue").ComputedRef<string>;
|
|
1147
1147
|
mergedPlaceholder: import("vue").ComputedRef<string>;
|
|
1148
|
-
mergedExpandedKeys: import("vue").ComputedRef<Key[]>;
|
|
1148
|
+
mergedExpandedKeys: import("vue").ComputedRef<Key[] | undefined>;
|
|
1149
1149
|
treeSelectedKeys: import("vue").ComputedRef<Key[]>;
|
|
1150
1150
|
treeCheckedKeys: import("vue").ComputedRef<Key[]>;
|
|
1151
1151
|
mergedSize: import("vue").ComputedRef<"small" | "medium" | "large">;
|
|
@@ -1264,12 +1264,14 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
1264
1264
|
borderRadius: string;
|
|
1265
1265
|
borderRadiusSmall: string;
|
|
1266
1266
|
fontSize: string;
|
|
1267
|
+
fontSizeMini: string;
|
|
1267
1268
|
fontSizeTiny: string;
|
|
1268
1269
|
fontSizeSmall: string;
|
|
1269
1270
|
fontSizeMedium: string;
|
|
1270
1271
|
fontSizeLarge: string;
|
|
1271
1272
|
fontSizeHuge: string;
|
|
1272
1273
|
lineHeight: string;
|
|
1274
|
+
heightMini: string;
|
|
1273
1275
|
heightTiny: string;
|
|
1274
1276
|
heightSmall: string;
|
|
1275
1277
|
heightMedium: string;
|
|
@@ -109,7 +109,7 @@ exports.default = (0, vue_1.defineComponent)({
|
|
|
109
109
|
// The same logic as tree, now it's not that complex so I don't extract a
|
|
110
110
|
// function to reuse it.
|
|
111
111
|
const uncontrolledExpandedKeysRef = (0, vue_1.ref)(props.defaultExpandAll
|
|
112
|
-
?
|
|
112
|
+
? undefined // leave it, n-tree will handle it
|
|
113
113
|
: props.defaultExpandedKeys || props.expandedKeys);
|
|
114
114
|
const controlledExpandedKeysRef = (0, vue_1.toRef)(props, 'expandedKeys');
|
|
115
115
|
const mergedExpandedKeysRef = (0, vooks_1.useMergedState)(controlledExpandedKeysRef, uncontrolledExpandedKeysRef);
|
|
@@ -1,16 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
var __importDefault = this && this.__importDefault || function (mod) {
|
|
4
|
-
return mod && mod.__esModule ? mod : {
|
|
5
|
-
"default": mod
|
|
6
|
-
};
|
|
7
|
-
};
|
|
8
|
-
|
|
9
3
|
Object.defineProperty(exports, "__esModule", {
|
|
10
4
|
value: true
|
|
11
5
|
});
|
|
12
6
|
|
|
13
|
-
const fade_in_scale_up_cssr_1 =
|
|
7
|
+
const fade_in_scale_up_cssr_1 = require("../../../_styles/transitions/fade-in-scale-up.cssr");
|
|
14
8
|
|
|
15
9
|
const cssr_1 = require("../../../_utils/cssr"); // vars:
|
|
16
10
|
// --n-bezier
|
|
@@ -49,4 +43,4 @@ exports.default = (0, cssr_1.c)([(0, cssr_1.cB)('tree-select', `
|
|
|
49
43
|
border-color .3s var(--n-bezier);
|
|
50
44
|
border-top: 1px solid var(--n-action-divider-color);
|
|
51
45
|
color: var(--n-action-text-color);
|
|
52
|
-
`), (0, fade_in_scale_up_cssr_1.
|
|
46
|
+
`), (0, fade_in_scale_up_cssr_1.fadeInScaleUpTransition)()])]);
|
|
@@ -1731,12 +1731,14 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
1731
1731
|
borderRadius: string;
|
|
1732
1732
|
borderRadiusSmall: string;
|
|
1733
1733
|
fontSize: string;
|
|
1734
|
+
fontSizeMini: string;
|
|
1734
1735
|
fontSizeTiny: string;
|
|
1735
1736
|
fontSizeSmall: string;
|
|
1736
1737
|
fontSizeMedium: string;
|
|
1737
1738
|
fontSizeLarge: string;
|
|
1738
1739
|
fontSizeHuge: string;
|
|
1739
1740
|
lineHeight: string;
|
|
1741
|
+
heightMini: string;
|
|
1740
1742
|
heightTiny: string;
|
|
1741
1743
|
heightSmall: string;
|
|
1742
1744
|
heightMedium: string;
|
package/lib/upload/src/Upload.js
CHANGED
|
@@ -244,7 +244,11 @@ exports.default = (0, vue_1.defineComponent)({
|
|
|
244
244
|
function handleFileInputChange(e) {
|
|
245
245
|
const target = e.target;
|
|
246
246
|
handleFileAddition(target.files
|
|
247
|
-
? Array.from(target.files).map((file) => ({
|
|
247
|
+
? Array.from(target.files).map((file) => ({
|
|
248
|
+
file,
|
|
249
|
+
entry: null,
|
|
250
|
+
source: 'input'
|
|
251
|
+
}))
|
|
248
252
|
: null, e);
|
|
249
253
|
// May have bug! set to null?
|
|
250
254
|
target.value = '';
|
|
@@ -265,7 +269,15 @@ exports.default = (0, vue_1.defineComponent)({
|
|
|
265
269
|
fileAndEntries = mergedMultipleRef.value
|
|
266
270
|
? fileAndEntries
|
|
267
271
|
: [fileAndEntries[0]];
|
|
268
|
-
const { max } = props;
|
|
272
|
+
const { max, accept } = props;
|
|
273
|
+
fileAndEntries = fileAndEntries.filter(({ file, source }) => {
|
|
274
|
+
if (source === 'dnd' && (accept === null || accept === void 0 ? void 0 : accept.trim())) {
|
|
275
|
+
return (0, utils_1.matchType)(file.name, file.type, accept);
|
|
276
|
+
}
|
|
277
|
+
else {
|
|
278
|
+
return true;
|
|
279
|
+
}
|
|
280
|
+
});
|
|
269
281
|
if (max) {
|
|
270
282
|
fileAndEntries = fileAndEntries.slice(0, max - mergedFileListRef.value.length);
|
|
271
283
|
}
|
|
@@ -441,6 +453,7 @@ exports.default = (0, vue_1.defineComponent)({
|
|
|
441
453
|
maxReachedRef,
|
|
442
454
|
fileListStyleRef: (0, vue_1.toRef)(props, 'fileListStyle'),
|
|
443
455
|
abstractRef: (0, vue_1.toRef)(props, 'abstract'),
|
|
456
|
+
acceptRef: (0, vue_1.toRef)(props, 'accept'),
|
|
444
457
|
cssVarsRef: inlineThemeDisabled ? undefined : cssVarsRef,
|
|
445
458
|
themeClassRef: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.themeClass,
|
|
446
459
|
onRender: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.onRender,
|
|
@@ -104,12 +104,14 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
104
104
|
borderRadius: string;
|
|
105
105
|
borderRadiusSmall: string;
|
|
106
106
|
fontSize: string;
|
|
107
|
+
fontSizeMini: string;
|
|
107
108
|
fontSizeTiny: string;
|
|
108
109
|
fontSizeSmall: string;
|
|
109
110
|
fontSizeMedium: string;
|
|
110
111
|
fontSizeLarge: string;
|
|
111
112
|
fontSizeHuge: string;
|
|
112
113
|
lineHeight: string;
|
|
114
|
+
heightMini: string;
|
|
113
115
|
heightTiny: string;
|
|
114
116
|
heightSmall: string;
|
|
115
117
|
heightMedium: string;
|
|
@@ -100,12 +100,14 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
100
100
|
borderRadius: string;
|
|
101
101
|
borderRadiusSmall: string;
|
|
102
102
|
fontSize: string;
|
|
103
|
+
fontSizeMini: string;
|
|
103
104
|
fontSizeTiny: string;
|
|
104
105
|
fontSizeSmall: string;
|
|
105
106
|
fontSizeMedium: string;
|
|
106
107
|
fontSizeLarge: string;
|
|
107
108
|
fontSizeHuge: string;
|
|
108
109
|
lineHeight: string;
|
|
110
|
+
heightMini: string;
|
|
109
111
|
heightTiny: string;
|
|
110
112
|
heightSmall: string;
|
|
111
113
|
heightMedium: string;
|
|
@@ -71,6 +71,7 @@ export interface UploadInjection {
|
|
|
71
71
|
cssVarsRef: undefined | Ref<CSSProperties>;
|
|
72
72
|
themeClassRef: undefined | Ref<string>;
|
|
73
73
|
mergedDirectoryDndRef: Ref<boolean>;
|
|
74
|
+
acceptRef: Ref<string | undefined>;
|
|
74
75
|
onRender: undefined | (() => void);
|
|
75
76
|
submit: (fileId?: string) => void;
|
|
76
77
|
getFileThumbnailUrl: (file: SettledFileInfo) => Promise<string>;
|
|
@@ -116,4 +117,5 @@ export declare type OnError = ({ file, event }: {
|
|
|
116
117
|
export interface FileAndEntry {
|
|
117
118
|
file: File;
|
|
118
119
|
entry: FileSystemFileEntry | null;
|
|
120
|
+
source: 'dnd' | 'input';
|
|
119
121
|
}
|
|
@@ -1,20 +1,14 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
var __importDefault = this && this.__importDefault || function (mod) {
|
|
4
|
-
return mod && mod.__esModule ? mod : {
|
|
5
|
-
"default": mod
|
|
6
|
-
};
|
|
7
|
-
};
|
|
8
|
-
|
|
9
3
|
Object.defineProperty(exports, "__esModule", {
|
|
10
4
|
value: true
|
|
11
5
|
});
|
|
12
6
|
|
|
13
7
|
const cssr_1 = require("../../../_utils/cssr");
|
|
14
8
|
|
|
15
|
-
const fade_in_height_expand_cssr_1 =
|
|
9
|
+
const fade_in_height_expand_cssr_1 = require("../../../_styles/transitions/fade-in-height-expand.cssr");
|
|
16
10
|
|
|
17
|
-
const icon_switch_cssr_1 =
|
|
11
|
+
const icon_switch_cssr_1 = require("../../../_styles/transitions/icon-switch.cssr");
|
|
18
12
|
|
|
19
13
|
exports.default = (0, cssr_1.c)([(0, cssr_1.cB)('upload', 'width: 100%;', [(0, cssr_1.cM)('dragger-inside', [(0, cssr_1.cE)('trigger', `
|
|
20
14
|
display: block;
|
|
@@ -78,7 +72,7 @@ exports.default = (0, cssr_1.c)([(0, cssr_1.cB)('upload', 'width: 100%;', [(0, c
|
|
|
78
72
|
padding: 0px 12px 0 6px;
|
|
79
73
|
transition: background-color .3s var(--n-bezier);
|
|
80
74
|
border-radius: var(--n-border-radius);
|
|
81
|
-
`, [(0, fade_in_height_expand_cssr_1.
|
|
75
|
+
`, [(0, fade_in_height_expand_cssr_1.fadeInHeightExpandTransition)(), (0, cssr_1.cB)('progress', [(0, fade_in_height_expand_cssr_1.fadeInHeightExpandTransition)({
|
|
82
76
|
foldPadding: true
|
|
83
77
|
})]), (0, cssr_1.c)('&:hover', `
|
|
84
78
|
background-color: var(--n-item-color-hover);
|
|
@@ -199,7 +193,7 @@ exports.default = (0, cssr_1.c)([(0, cssr_1.cB)('upload', 'width: 100%;', [(0, c
|
|
|
199
193
|
opacity: 0;
|
|
200
194
|
`, [(0, cssr_1.cB)('button', [(0, cssr_1.c)('&:not(:last-child)', {
|
|
201
195
|
marginRight: '4px'
|
|
202
|
-
}), (0, cssr_1.cB)('base-icon', [(0, cssr_1.c)('svg', [(0, icon_switch_cssr_1.
|
|
196
|
+
}), (0, cssr_1.cB)('base-icon', [(0, cssr_1.c)('svg', [(0, icon_switch_cssr_1.iconSwitchTransition)()])])]), (0, cssr_1.cM)('image-type', `
|
|
203
197
|
position: relative;
|
|
204
198
|
max-width: 80px;
|
|
205
199
|
width: auto;
|
|
@@ -10,3 +10,9 @@ export declare function isFileSystemDirectoryEntry(item: FileSystemEntry | FileS
|
|
|
10
10
|
export declare function isFileSystemFileEntry(item: FileSystemEntry | FileSystemFileEntry | FileSystemDirectoryEntry): item is FileSystemFileEntry;
|
|
11
11
|
export declare function getFilesFromEntries(entries: readonly FileSystemEntry[] | Array<FileSystemEntry | null>, directory: boolean): Promise<FileAndEntry[]>;
|
|
12
12
|
export declare function createSettledFileInfo(fileInfo: FileInfo): SettledFileInfo;
|
|
13
|
+
/**
|
|
14
|
+
* This is a rather simple version. I may fix it later to make it more accurate.
|
|
15
|
+
* I've looked at https://github.com/broofa/mime, however it doesn't has a esm
|
|
16
|
+
* version, so I can't simply use it.
|
|
17
|
+
*/
|
|
18
|
+
export declare function matchType(name: string, mimeType: string, accept: string): boolean;
|
package/lib/upload/src/utils.js
CHANGED
|
@@ -9,7 +9,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
9
9
|
});
|
|
10
10
|
};
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.createSettledFileInfo = exports.getFilesFromEntries = exports.isFileSystemFileEntry = exports.isFileSystemDirectoryEntry = exports.environmentSupportFile = exports.createImageDataUrl = exports.isImageFile = exports.isImageFileType = void 0;
|
|
12
|
+
exports.matchType = exports.createSettledFileInfo = exports.getFilesFromEntries = exports.isFileSystemFileEntry = exports.isFileSystemDirectoryEntry = exports.environmentSupportFile = exports.createImageDataUrl = exports.isImageFile = exports.isImageFileType = void 0;
|
|
13
13
|
const isImageFileType = (type) => type.includes('image/');
|
|
14
14
|
exports.isImageFileType = isImageFileType;
|
|
15
15
|
const getExtname = (url = '') => {
|
|
@@ -107,7 +107,7 @@ function getFilesFromEntries(entries, directory) {
|
|
|
107
107
|
else if (isFileSystemFileEntry(entry)) {
|
|
108
108
|
lock();
|
|
109
109
|
entry.file((file) => {
|
|
110
|
-
fileAndEntries.push({ file, entry });
|
|
110
|
+
fileAndEntries.push({ file, entry, source: 'dnd' });
|
|
111
111
|
unlock();
|
|
112
112
|
}, () => {
|
|
113
113
|
unlock();
|
|
@@ -140,3 +140,41 @@ function createSettledFileInfo(fileInfo) {
|
|
|
140
140
|
};
|
|
141
141
|
}
|
|
142
142
|
exports.createSettledFileInfo = createSettledFileInfo;
|
|
143
|
+
/**
|
|
144
|
+
* This is a rather simple version. I may fix it later to make it more accurate.
|
|
145
|
+
* I've looked at https://github.com/broofa/mime, however it doesn't has a esm
|
|
146
|
+
* version, so I can't simply use it.
|
|
147
|
+
*/
|
|
148
|
+
function matchType(name, mimeType, accept) {
|
|
149
|
+
name = name.toLowerCase();
|
|
150
|
+
mimeType = mimeType.toLocaleLowerCase();
|
|
151
|
+
accept = accept.toLocaleLowerCase();
|
|
152
|
+
const acceptAtoms = accept
|
|
153
|
+
.split(',')
|
|
154
|
+
.map((acceptAtom) => acceptAtom.trim())
|
|
155
|
+
.filter(Boolean);
|
|
156
|
+
return acceptAtoms.some((acceptAtom) => {
|
|
157
|
+
if (acceptAtom.startsWith('.')) {
|
|
158
|
+
// suffix
|
|
159
|
+
if (name.endsWith(acceptAtom))
|
|
160
|
+
return true;
|
|
161
|
+
}
|
|
162
|
+
else if (acceptAtom.includes('/')) {
|
|
163
|
+
// mime type
|
|
164
|
+
const [type, subtype] = mimeType.split('/');
|
|
165
|
+
const [acceptType, acceptSubtype] = acceptAtom.split('/');
|
|
166
|
+
if (acceptType === '*' || (type && acceptType && acceptType === type)) {
|
|
167
|
+
if (acceptSubtype === '*' ||
|
|
168
|
+
(subtype && acceptSubtype && acceptSubtype === subtype)) {
|
|
169
|
+
return true;
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
}
|
|
173
|
+
else {
|
|
174
|
+
// invalid type
|
|
175
|
+
return true;
|
|
176
|
+
}
|
|
177
|
+
return false;
|
|
178
|
+
});
|
|
179
|
+
}
|
|
180
|
+
exports.matchType = matchType;
|
package/lib/version.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
declare const _default: "2.
|
|
1
|
+
declare const _default: "2.29.0";
|
|
2
2
|
export default _default;
|
package/lib/version.js
CHANGED