antdv-next 1.2.2 → 1.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/_util/ActionButton.d.ts +2 -2
- package/dist/_util/ContextIsolator.d.ts +3 -3
- package/dist/_util/PurePanel.d.ts +3 -3
- package/dist/_util/hooks/useClosable.d.ts +7 -7
- package/dist/_util/hooks/useMergeSemantic.d.ts +4 -4
- package/dist/_util/hooks/useMergedMask.d.ts +3 -3
- package/dist/_util/instance.d.ts +2 -2
- package/dist/_util/responsiveObserver.d.ts +2 -2
- package/dist/_util/statusUtils.d.ts +1 -1
- package/dist/_util/vueNode.d.ts +4 -9
- package/dist/_util/wave/WaveEffect.d.ts +5 -5
- package/dist/_util/wave/index.d.ts +2 -2
- package/dist/_util/wave/style.d.ts +2 -2
- package/dist/_util/wave/util.d.ts +1 -1
- package/dist/_util/wave/util.js +1 -1
- package/dist/_util/zindexContext.d.ts +2 -2
- package/dist/affix/index.d.ts +3 -3
- package/dist/affix/style/index.d.ts +2 -2
- package/dist/alert/Alert.d.ts +17 -10
- package/dist/alert/Alert.js +9 -3
- package/dist/alert/style/index.d.ts +3 -3
- package/dist/anchor/Anchor.d.ts +3 -3
- package/dist/anchor/Anchor.js +2 -2
- package/dist/anchor/AnchorLink.d.ts +9 -4
- package/dist/anchor/AnchorLink.js +5 -1
- package/dist/anchor/style/index.d.ts +2 -2
- package/dist/antd-with-locales.esm.js +14614 -14290
- package/dist/antd-with-locales.js +73 -80
- package/dist/antd.css +1 -1
- package/dist/antd.esm.js +10754 -10431
- package/dist/antd.js +70 -77
- package/dist/app/App.d.ts +2 -2
- package/dist/app/App.js +6 -1
- package/dist/app/context.d.ts +2 -2
- package/dist/app/style/index.d.ts +2 -2
- package/dist/auto-complete/index.d.ts +6 -6
- package/dist/auto-complete/index.js +1 -1
- package/dist/avatar/Avatar.d.ts +5 -5
- package/dist/avatar/AvatarGroup.d.ts +2 -2
- package/dist/avatar/style/index.d.ts +3 -3
- package/dist/badge/Ribbon.d.ts +4 -4
- package/dist/badge/ScrollNumber.d.ts +2 -2
- package/dist/badge/SingleNumber.d.ts +2 -2
- package/dist/badge/index.d.ts +6 -6
- package/dist/badge/style/index.d.ts +7 -2
- package/dist/badge/style/index.js +4 -3
- package/dist/badge/style/ribbon.d.ts +2 -2
- package/dist/border-beam/BorderBeam.d.ts +19 -0
- package/dist/border-beam/BorderBeam.js +82 -0
- package/dist/border-beam/hooks/useBorderSize.d.ts +12 -0
- package/dist/border-beam/hooks/useBorderSize.js +42 -0
- package/dist/border-beam/index.d.ts +3 -0
- package/dist/border-beam/index.js +7 -0
- package/dist/border-beam/style/index.d.ts +7 -0
- package/dist/border-beam/style/index.js +59 -0
- package/dist/border-beam/util.d.ts +11 -0
- package/dist/border-beam/util.js +35 -0
- package/dist/breadcrumb/Breadcrumb.d.ts +7 -7
- package/dist/breadcrumb/BreadcrumbItem.d.ts +7 -7
- package/dist/breadcrumb/BreadcrumbSeparator.d.ts +2 -2
- package/dist/breadcrumb/style/index.d.ts +2 -2
- package/dist/breadcrumb/useItemRender.d.ts +2 -2
- package/dist/button/Button.d.ts +4 -4
- package/dist/button/Button.js +1 -0
- package/dist/button/DefaultLoadingIcon.d.ts +2 -2
- package/dist/button/IconWrapper.d.ts +2 -2
- package/dist/button/buttonHelper.d.ts +1 -1
- package/dist/button/style/compact.d.ts +4 -4
- package/dist/button/style/index.d.ts +2 -2
- package/dist/button/style/index.js +5 -0
- package/dist/calendar/Header.d.ts +2 -2
- package/dist/calendar/generateCalendar.d.ts +12 -10
- package/dist/calendar/generateCalendar.js +8 -2
- package/dist/calendar/index.d.ts +2 -2
- package/dist/calendar/style/index.d.ts +2 -2
- package/dist/card/Card.d.ts +11 -11
- package/dist/card/CardGrid.d.ts +2 -2
- package/dist/card/CardMeta.d.ts +6 -6
- package/dist/card/style/index.d.ts +2 -2
- package/dist/carousel/index.d.ts +5 -5
- package/dist/carousel/style/index.d.ts +2 -2
- package/dist/cascader/Panel.d.ts +2 -2
- package/dist/cascader/hooks/useBase.d.ts +5 -5
- package/dist/cascader/hooks/useCheckable.d.ts +2 -2
- package/dist/cascader/index.d.ts +4 -4
- package/dist/cascader/index.js +11 -2
- package/dist/cascader/style/index.d.ts +2 -2
- package/dist/cascader/style/panel.d.ts +2 -2
- package/dist/checkbox/Checkbox.d.ts +2 -2
- package/dist/checkbox/Group.d.ts +4 -4
- package/dist/checkbox/style/index.d.ts +4 -4
- package/dist/collapse/Collapse.d.ts +5 -5
- package/dist/collapse/CollapsePanel.d.ts +5 -5
- package/dist/collapse/style/index.d.ts +2 -2
- package/dist/color-picker/ColorPicker.d.ts +2 -2
- package/dist/color-picker/ColorPickerPanel.d.ts +2 -2
- package/dist/color-picker/components/ColorAlphaInput.d.ts +2 -2
- package/dist/color-picker/components/ColorClear.d.ts +2 -2
- package/dist/color-picker/components/ColorHexInput.d.ts +2 -2
- package/dist/color-picker/components/ColorHsbInput.d.ts +2 -2
- package/dist/color-picker/components/ColorInput.d.ts +2 -2
- package/dist/color-picker/components/ColorPresets.d.ts +2 -2
- package/dist/color-picker/components/ColorRgbInput.d.ts +2 -2
- package/dist/color-picker/components/ColorSlider.d.ts +3 -3
- package/dist/color-picker/components/ColorSteppers.d.ts +2 -2
- package/dist/color-picker/components/ColorTrigger.d.ts +2 -2
- package/dist/color-picker/components/PanelPicker/GradientColorBar.d.ts +2 -2
- package/dist/color-picker/components/PanelPicker/index.d.ts +2 -2
- package/dist/color-picker/components/PanelPresets.d.ts +2 -2
- package/dist/color-picker/context.d.ts +3 -3
- package/dist/color-picker/hooks/useModeColor.d.ts +4 -4
- package/dist/color-picker/interface.d.ts +2 -2
- package/dist/color-picker/style/index.d.ts +2 -2
- package/dist/components.d.ts +4 -1
- package/dist/components.js +3 -1
- package/dist/config-provider/DisabledContext.d.ts +2 -2
- package/dist/config-provider/SizeContext.d.ts +2 -2
- package/dist/config-provider/context.d.ts +67 -34
- package/dist/config-provider/defaultRenderEmpty.d.ts +2 -2
- package/dist/config-provider/hooks/useCSSVarCls.d.ts +2 -2
- package/dist/config-provider/hooks/useConfig.d.ts +3 -3
- package/dist/config-provider/hooks/useSize.d.ts +2 -2
- package/dist/config-provider/hooks/useTheme.d.ts +2 -2
- package/dist/config-provider/index.d.ts +4 -4
- package/dist/config-provider/index.js +2 -0
- package/dist/date-picker/PickerButton.d.ts +2 -2
- package/dist/date-picker/generatePicker/SuffixIcon.d.ts +5 -5
- package/dist/date-picker/generatePicker/SuffixIcon.js +1 -1
- package/dist/date-picker/generatePicker/generateRangePicker.d.ts +4 -4
- package/dist/date-picker/generatePicker/generateSinglePicker.d.ts +9 -9
- package/dist/date-picker/generatePicker/generateSinglePicker.js +4 -0
- package/dist/date-picker/generatePicker/index.d.ts +8 -8
- package/dist/date-picker/generatePicker/useComponents.d.ts +11 -11
- package/dist/date-picker/index.d.ts +13 -13
- package/dist/date-picker/style/index.d.ts +2 -2
- package/dist/date-picker/style/index.js +13 -3
- package/dist/date-picker/util.d.ts +3 -3
- package/dist/descriptions/Cell.d.ts +5 -5
- package/dist/descriptions/Item.d.ts +5 -5
- package/dist/descriptions/Row.d.ts +2 -2
- package/dist/descriptions/Row.js +3 -3
- package/dist/descriptions/hooks/useItems.d.ts +13 -13
- package/dist/descriptions/hooks/useRow.d.ts +2 -2
- package/dist/descriptions/index.d.ts +5 -5
- package/dist/descriptions/style/index.d.ts +2 -2
- package/dist/divider/index.d.ts +2 -2
- package/dist/divider/style/index.d.ts +2 -2
- package/dist/drawer/DrawerPanel.d.ts +7 -7
- package/dist/drawer/index.d.ts +3 -3
- package/dist/drawer/index.js +5 -2
- package/dist/drawer/style/index.d.ts +2 -2
- package/dist/drawer/useFocusable.d.ts +2 -2
- package/dist/dropdown/dropdown.d.ts +2 -2
- package/dist/dropdown/style/index.d.ts +2 -2
- package/dist/dropdown/style/index.js +1 -1
- package/dist/empty/empty.d.ts +2 -2
- package/dist/empty/index.d.ts +8 -8
- package/dist/empty/simple.d.ts +2 -2
- package/dist/empty/style/index.d.ts +2 -2
- package/dist/flex/index.d.ts +2 -2
- package/dist/flex/style/index.d.ts +2 -2
- package/dist/float-button/BackTop.d.ts +2 -2
- package/dist/float-button/BackTop.js +5 -0
- package/dist/float-button/FloatButton.d.ts +8 -7
- package/dist/float-button/FloatButton.js +6 -0
- package/dist/float-button/FloatButtonGroup.d.ts +4 -4
- package/dist/float-button/FloatButtonGroup.js +5 -0
- package/dist/float-button/PurePanel.d.ts +2 -2
- package/dist/float-button/PurePanel.js +10 -0
- package/dist/float-button/context.d.ts +3 -3
- package/dist/float-button/style/index.d.ts +2 -2
- package/dist/form/ErrorList.d.ts +8 -4
- package/dist/form/ErrorList.js +13 -2
- package/dist/form/Form.d.ts +9 -2
- package/dist/form/Form.js +10 -4
- package/dist/form/FormItem/ItemHolder.d.ts +3 -3
- package/dist/form/FormItem/StatusProvider.d.ts +2 -2
- package/dist/form/FormItem/index.d.ts +2 -2
- package/dist/form/FormItemInput.d.ts +6 -6
- package/dist/form/FormItemInput.js +6 -2
- package/dist/form/FormItemLabel.d.ts +7 -7
- package/dist/form/context.d.ts +7 -7
- package/dist/form/hooks/useVariant.d.ts +2 -2
- package/dist/form/style/fallbackCmp.d.ts +4 -4
- package/dist/form/style/index.d.ts +2 -2
- package/dist/grid/col.d.ts +2 -2
- package/dist/grid/index.d.ts +2 -2
- package/dist/grid/row.d.ts +2 -2
- package/dist/grid/style/index.d.ts +3 -3
- package/dist/image/PreviewGroup.d.ts +12 -12
- package/dist/image/hooks/useMergedPreviewConfig.d.ts +6 -6
- package/dist/image/hooks/usePreviewConfig.d.ts +10 -10
- package/dist/image/index.d.ts +12 -5
- package/dist/image/style/index.d.ts +2 -2
- package/dist/index.d.ts +3 -1
- package/dist/index.js +2 -1
- package/dist/input/Group.d.ts +3 -3
- package/dist/input/Input.d.ts +10 -7
- package/dist/input/Input.js +8 -2
- package/dist/input/OTP/OTPInput.d.ts +3 -3
- package/dist/input/OTP/OTPInput.js +4 -0
- package/dist/input/OTP/index.d.ts +4 -4
- package/dist/input/Password.d.ts +4 -4
- package/dist/input/Password.js +4 -0
- package/dist/input/Search.d.ts +14 -4
- package/dist/input/Search.js +19 -2
- package/dist/input/TextArea.d.ts +2 -2
- package/dist/input/index.d.ts +6 -6
- package/dist/input/style/index.d.ts +3 -3
- package/dist/input/style/otp.d.ts +2 -2
- package/dist/input/style/search.d.ts +2 -2
- package/dist/input/style/textarea.d.ts +2 -2
- package/dist/input/style/variants.js +14 -8
- package/dist/input-number/index.d.ts +9 -9
- package/dist/input-number/style/index.d.ts +2 -2
- package/dist/layout/Sider.d.ts +2 -2
- package/dist/layout/index.d.ts +5 -5
- package/dist/layout/layout.d.ts +5 -5
- package/dist/layout/style/index.d.ts +2 -2
- package/dist/layout/style/sider.d.ts +2 -2
- package/dist/locale/index.d.ts +2 -2
- package/dist/locale/useLocale.d.ts +2 -2
- package/dist/masonry/Masonry.d.ts +3 -3
- package/dist/masonry/MasonryItem.d.ts +4 -4
- package/dist/masonry/hooks/usePositions.d.ts +2 -2
- package/dist/masonry/style/index.d.ts +2 -2
- package/dist/mentions/index.d.ts +6 -6
- package/dist/mentions/index.js +7 -1
- package/dist/mentions/style/index.d.ts +2 -2
- package/dist/menu/MenuContext.d.ts +3 -3
- package/dist/menu/MenuDivider.d.ts +2 -2
- package/dist/menu/MenuItem.d.ts +5 -5
- package/dist/menu/MenuItemGroup.d.ts +4 -4
- package/dist/menu/OverrideContext.d.ts +5 -5
- package/dist/menu/SubMenu.d.ts +4 -4
- package/dist/menu/index.d.ts +3 -3
- package/dist/menu/menu.d.ts +2 -2
- package/dist/menu/style/index.d.ts +2 -2
- package/dist/menu/style/index.js +11 -3
- package/dist/menu/style/vertical.js +2 -1
- package/dist/message/PureList.d.ts +28 -0
- package/dist/message/PureList.js +75 -0
- package/dist/message/PurePanel.d.ts +17 -9
- package/dist/message/PurePanel.js +33 -38
- package/dist/message/index.d.ts +3 -0
- package/dist/message/index.js +3 -1
- package/dist/message/interface.d.ts +11 -5
- package/dist/message/style/index.d.ts +12 -6
- package/dist/message/style/index.js +102 -98
- package/dist/message/useMessage.d.ts +3 -3
- package/dist/message/useMessage.js +18 -14
- package/dist/message/util.js +1 -1
- package/dist/modal/ConfirmDialog.d.ts +4 -4
- package/dist/modal/Modal.d.ts +2 -2
- package/dist/modal/Modal.js +7 -3
- package/dist/modal/PurePanel.d.ts +2 -2
- package/dist/modal/components/ConfirmCancelBtn.d.ts +4 -4
- package/dist/modal/components/ConfirmOkBtn.d.ts +4 -4
- package/dist/modal/components/NormalCancelBtn.d.ts +4 -4
- package/dist/modal/components/NormalOkBtn.d.ts +4 -4
- package/dist/modal/interface.d.ts +22 -14
- package/dist/modal/shared.d.ts +4 -4
- package/dist/modal/style/confirm.d.ts +4 -4
- package/dist/modal/style/index.d.ts +4 -4
- package/dist/modal/useModal/HookModal.d.ts +3 -3
- package/dist/notification/PureList.d.ts +32 -0
- package/dist/notification/PureList.js +72 -0
- package/dist/notification/PurePanel.d.ts +16 -13
- package/dist/notification/PurePanel.js +42 -19
- package/dist/notification/index.d.ts +3 -0
- package/dist/notification/index.js +3 -1
- package/dist/notification/interface.d.ts +8 -8
- package/dist/notification/style/index.d.ts +27 -26
- package/dist/notification/style/index.js +104 -174
- package/dist/notification/style/notification.d.ts +23 -0
- package/dist/notification/style/notification.js +195 -0
- package/dist/notification/style/placement.d.ts +1 -0
- package/dist/notification/style/placement.js +125 -60
- package/dist/notification/useNotification.d.ts +3 -3
- package/dist/notification/useNotification.js +22 -14
- package/dist/notification/util.d.ts +14 -4
- package/dist/notification/util.js +18 -52
- package/dist/package.js +1 -1
- package/dist/package.json.d.ts +12 -12
- package/dist/pagination/Pagination.d.ts +2 -2
- package/dist/pagination/interface.d.ts +7 -7
- package/dist/pagination/style/bordered.d.ts +4 -4
- package/dist/pagination/style/index.d.ts +2 -2
- package/dist/popconfirm/PurePanel.d.ts +6 -7
- package/dist/popconfirm/PurePanel.js +4 -1
- package/dist/popconfirm/index.d.ts +16 -12
- package/dist/popconfirm/style/index.d.ts +2 -2
- package/dist/popover/PurePanel.d.ts +7 -7
- package/dist/popover/index.d.ts +5 -5
- package/dist/popover/style/index.d.ts +2 -2
- package/dist/progress/Circle.d.ts +3 -3
- package/dist/progress/Line.d.ts +3 -3
- package/dist/progress/Steps.d.ts +2 -2
- package/dist/progress/progress.d.ts +2 -2
- package/dist/progress/style/index.d.ts +2 -2
- package/dist/qrcode/QrcodeStatus.d.ts +2 -2
- package/dist/qrcode/index.d.ts +2 -2
- package/dist/qrcode/style/index.d.ts +2 -2
- package/dist/radio/group.d.ts +2 -2
- package/dist/radio/index.d.ts +3 -3
- package/dist/radio/radio.d.ts +2 -2
- package/dist/radio/radioButton.d.ts +2 -2
- package/dist/radio/style/index.d.ts +2 -2
- package/dist/rate/index.d.ts +2 -2
- package/dist/rate/style/index.d.ts +2 -2
- package/dist/result/index.d.ts +7 -7
- package/dist/result/noFound.d.ts +2 -2
- package/dist/result/serverError.d.ts +2 -2
- package/dist/result/style/index.d.ts +4 -4
- package/dist/result/style/index.js +1 -1
- package/dist/result/unauthorized.d.ts +2 -2
- package/dist/segmented/index.d.ts +4 -4
- package/dist/segmented/index.js +1 -1
- package/dist/segmented/style/index.d.ts +2 -2
- package/dist/select/index.d.ts +8 -8
- package/dist/select/index.js +1 -1
- package/dist/select/style/dropdown.js +1 -1
- package/dist/select/style/index.d.ts +2 -2
- package/dist/select/style/select-input.js +10 -5
- package/dist/select/useIcons.d.ts +5 -5
- package/dist/select/usePopupRender.d.ts +2 -2
- package/dist/skeleton/Avatar.d.ts +2 -2
- package/dist/skeleton/Button.d.ts +2 -2
- package/dist/skeleton/Element.d.ts +2 -2
- package/dist/skeleton/Image.d.ts +2 -2
- package/dist/skeleton/Input.d.ts +2 -2
- package/dist/skeleton/Node.d.ts +2 -2
- package/dist/skeleton/Paragraph.d.ts +2 -2
- package/dist/skeleton/Skeleton.d.ts +2 -2
- package/dist/skeleton/Title.d.ts +2 -2
- package/dist/skeleton/style/index.d.ts +2 -2
- package/dist/slider/SliderTooltip.d.ts +3 -3
- package/dist/slider/index.d.ts +2 -2
- package/dist/slider/style/index.d.ts +2 -2
- package/dist/space/Addon.d.ts +2 -2
- package/dist/space/Compact.d.ts +6 -6
- package/dist/space/Item.d.ts +2 -2
- package/dist/space/index.d.ts +6 -6
- package/dist/space/style/addon.d.ts +2 -2
- package/dist/space/style/compact.d.ts +2 -2
- package/dist/space/style/index.d.ts +16 -3
- package/dist/spin/Indicator/Looper.d.ts +2 -2
- package/dist/spin/Indicator/Progress.d.ts +2 -2
- package/dist/spin/Indicator/index.d.ts +4 -4
- package/dist/spin/index.d.ts +7 -7
- package/dist/spin/style/index.d.ts +2 -2
- package/dist/spin/usePercent.d.ts +2 -2
- package/dist/splitter/Panel.d.ts +3 -3
- package/dist/splitter/Panel.js +14 -3
- package/dist/splitter/SplitBar.d.ts +2 -2
- package/dist/splitter/Splitter.d.ts +2 -2
- package/dist/splitter/Splitter.js +8 -2
- package/dist/splitter/hooks/useResizable.d.ts +2 -2
- package/dist/splitter/hooks/useResize.d.ts +2 -2
- package/dist/splitter/hooks/useSizes.d.ts +2 -2
- package/dist/splitter/index.d.ts +2 -2
- package/dist/splitter/interface.d.ts +21 -4
- package/dist/splitter/style/index.d.ts +2 -2
- package/dist/statistic/Number.d.ts +2 -2
- package/dist/statistic/Statistic.d.ts +6 -6
- package/dist/statistic/Timer.d.ts +2 -2
- package/dist/statistic/index.d.ts +2 -2
- package/dist/statistic/style/index.d.ts +3 -3
- package/dist/steps/PanelArrow.d.ts +2 -2
- package/dist/steps/ProgressIcon.d.ts +2 -2
- package/dist/steps/index.d.ts +8 -8
- package/dist/steps/style/index.d.ts +3 -3
- package/dist/style/compact-item-vertical.js +2 -1
- package/dist/style/compact-item.js +6 -6
- package/dist/switch/index.d.ts +5 -5
- package/dist/switch/style/index.d.ts +2 -2
- package/dist/table/Column.d.ts +2 -2
- package/dist/table/ColumnGroup.d.ts +2 -2
- package/dist/table/ExpandIcon.d.ts +2 -2
- package/dist/table/InternalTable.d.ts +2 -2
- package/dist/table/InternalTable.js +6 -4
- package/dist/table/TableMeasureRowContext.d.ts +3 -3
- package/dist/table/hooks/useFilledColumns.d.ts +14 -0
- package/dist/table/hooks/useFilledColumns.js +41 -0
- package/dist/table/hooks/useFilter/FilterSearch.d.ts +2 -2
- package/dist/table/hooks/useFilter/FilterWrapper.d.ts +3 -3
- package/dist/table/hooks/useFilter/index.d.ts +21 -21
- package/dist/table/hooks/usePagination.d.ts +2 -2
- package/dist/table/hooks/useSelection.d.ts +2 -2
- package/dist/table/hooks/useSorter.d.ts +2 -2
- package/dist/table/style/index.d.ts +2 -2
- package/dist/tabs/TabPane.d.ts +2 -2
- package/dist/tabs/hooks/useLegacyItems.d.ts +2 -2
- package/dist/tabs/index.d.ts +9 -7
- package/dist/tabs/style/index.d.ts +2 -2
- package/dist/tag/CheckableTag.d.ts +4 -4
- package/dist/tag/CheckableTagGroup.d.ts +4 -4
- package/dist/tag/hooks/useColor.d.ts +2 -2
- package/dist/tag/index.d.ts +7 -5
- package/dist/tag/index.js +7 -2
- package/dist/tag/style/index.d.ts +2 -2
- package/dist/tag/style/presetCmp.d.ts +4 -4
- package/dist/tag/style/statusCmp.d.ts +4 -4
- package/dist/theme/context.d.ts +2 -2
- package/dist/theme/index.d.ts +4 -4
- package/dist/theme/interface/alias.d.ts +14 -0
- package/dist/theme/interface/components.d.ts +118 -116
- package/dist/theme/interface/maps/colors.d.ts +14 -0
- package/dist/theme/interface/maps/font.d.ts +5 -5
- package/dist/theme/themes/default/theme.d.ts +2 -2
- package/dist/theme/themes/shared/genColorMapToken.js +2 -0
- package/dist/theme/useToken.js +1 -1
- package/dist/theme/util/alias.js +2 -0
- package/dist/theme/util/genStyleUtils.d.ts +6 -6
- package/dist/time-picker/index.d.ts +6 -6
- package/dist/time-picker/index.js +4 -0
- package/dist/timeline/Timeline.d.ts +11 -11
- package/dist/timeline/TimelineItem.d.ts +2 -2
- package/dist/timeline/style/index.d.ts +2 -2
- package/dist/tooltip/PurePanel.d.ts +2 -2
- package/dist/tooltip/UniqueProvider/MotionContent.d.ts +2 -2
- package/dist/tooltip/UniqueProvider/index.d.ts +2 -2
- package/dist/tooltip/index.d.ts +5 -5
- package/dist/tooltip/style/index.d.ts +2 -2
- package/dist/tour/PurePanel.d.ts +2 -2
- package/dist/tour/index.d.ts +2 -2
- package/dist/tour/index.js +5 -0
- package/dist/tour/interface.d.ts +6 -4
- package/dist/tour/panelRender.d.ts +2 -2
- package/dist/tour/panelRender.js +4 -9
- package/dist/tour/style/index.d.ts +2 -2
- package/dist/transfer/Actions.d.ts +4 -4
- package/dist/transfer/ListBody.d.ts +2 -2
- package/dist/transfer/ListItem.d.ts +4 -4
- package/dist/transfer/Section.d.ts +2 -2
- package/dist/transfer/Transfer.d.ts +2 -2
- package/dist/transfer/Transfer.js +34 -4
- package/dist/transfer/hooks/useData.d.ts +2 -2
- package/dist/transfer/interface.d.ts +47 -15
- package/dist/transfer/search.d.ts +4 -4
- package/dist/transfer/style/index.d.ts +2 -2
- package/dist/tree/DirectoryTree.d.ts +2 -2
- package/dist/tree/DirectoryTree.js +0 -4
- package/dist/tree/Tree.d.ts +10 -8
- package/dist/tree/Tree.js +0 -4
- package/dist/tree/style/index.d.ts +2 -2
- package/dist/tree/utils/dropIndicator.d.ts +2 -2
- package/dist/tree/utils/iconUtil.d.ts +4 -4
- package/dist/tree-select/index.d.ts +8 -6
- package/dist/tree-select/index.js +1 -1
- package/dist/tree-select/style/index.d.ts +2 -2
- package/dist/typography/Base/CopyBtn.d.ts +2 -2
- package/dist/typography/Base/Ellipsis.d.ts +5 -5
- package/dist/typography/Base/EllipsisTooltip.d.ts +2 -2
- package/dist/typography/Base/index.d.ts +2 -2
- package/dist/typography/Base/index.js +31 -26
- package/dist/typography/Editable.d.ts +11 -4
- package/dist/typography/Editable.js +18 -3
- package/dist/typography/Link.d.ts +2 -2
- package/dist/typography/Link.js +4 -0
- package/dist/typography/Paragraph.d.ts +2 -2
- package/dist/typography/Paragraph.js +4 -0
- package/dist/typography/Text.d.ts +2 -2
- package/dist/typography/Text.js +4 -0
- package/dist/typography/Title.d.ts +2 -2
- package/dist/typography/Title.js +4 -0
- package/dist/typography/Typography.d.ts +2 -2
- package/dist/typography/hooks/useCopyClick.d.ts +3 -3
- package/dist/typography/hooks/useMergedConfig.d.ts +2 -2
- package/dist/typography/hooks/useTooltipProps.d.ts +2 -2
- package/dist/typography/index.d.ts +5 -5
- package/dist/typography/interface.d.ts +25 -17
- package/dist/typography/style/index.d.ts +2 -2
- package/dist/upload/Dragger.d.ts +3 -3
- package/dist/upload/Upload.d.ts +2 -2
- package/dist/upload/UploadList/ListItem.d.ts +2 -2
- package/dist/upload/UploadList/index.d.ts +2 -2
- package/dist/upload/index.d.ts +3 -3
- package/dist/upload/style/index.d.ts +2 -2
- package/dist/upload/utils.js +1 -1
- package/dist/watermark/context.d.ts +2 -2
- package/dist/watermark/index.d.ts +2 -2
- package/dist/watermark/index.js +4 -3
- package/package.json +65 -29
- package/web-tags.json +1251 -1233
- package/web-types.json +3794 -3750
- package/dist/notification/style/pure-panel.d.ts +0 -12
- package/dist/notification/style/pure-panel.js +0 -18
- package/dist/notification/style/stack.d.ts +0 -9
- package/dist/notification/style/stack.js +0 -88
|
@@ -1,173 +1,14 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { genStyleHooks } from "../../theme/util/genStyleUtils.js";
|
|
1
|
+
import { resetComponent } from "../../style/index.js";
|
|
2
|
+
import { genStyleHooks, genSubStyleComponent } from "../../theme/util/genStyleUtils.js";
|
|
3
3
|
import { mergeToken } from "../../theme/internal.js";
|
|
4
4
|
import { CONTAINER_MAX_OFFSET } from "../../_util/hooks/useZIndex.js";
|
|
5
|
+
import notification_default, { genPurePanelStyle } from "./notification.js";
|
|
5
6
|
import placement_default from "./placement.js";
|
|
6
|
-
import
|
|
7
|
-
import { Keyframes, unit } from "@antdv-next/cssinjs";
|
|
7
|
+
import { unit } from "@antdv-next/cssinjs";
|
|
8
8
|
|
|
9
9
|
//#region src/notification/style/index.ts
|
|
10
|
-
const
|
|
11
|
-
|
|
12
|
-
const noticeCls = `${componentCls}-notice`;
|
|
13
|
-
return {
|
|
14
|
-
position: "relative",
|
|
15
|
-
marginBottom: notificationMarginBottom,
|
|
16
|
-
marginInlineStart: "auto",
|
|
17
|
-
background: notificationBg,
|
|
18
|
-
borderRadius: borderRadiusLG,
|
|
19
|
-
boxShadow,
|
|
20
|
-
[noticeCls]: {
|
|
21
|
-
padding: notificationPadding,
|
|
22
|
-
width,
|
|
23
|
-
maxWidth: `calc(100vw - ${unit(token.calc(notificationMarginEdge).mul(2).equal())})`,
|
|
24
|
-
lineHeight,
|
|
25
|
-
wordWrap: "break-word",
|
|
26
|
-
borderRadius: borderRadiusLG,
|
|
27
|
-
overflow: "hidden",
|
|
28
|
-
"&-success": colorSuccessBg ? { background: colorSuccessBg } : {},
|
|
29
|
-
"&-error": colorErrorBg ? { background: colorErrorBg } : {},
|
|
30
|
-
"&-info": colorInfoBg ? { background: colorInfoBg } : {},
|
|
31
|
-
"&-warning": colorWarningBg ? { background: colorWarningBg } : {}
|
|
32
|
-
},
|
|
33
|
-
[`${noticeCls}-title`]: {
|
|
34
|
-
marginBottom: token.marginXS,
|
|
35
|
-
color: colorTextHeading,
|
|
36
|
-
fontSize: fontSizeLG,
|
|
37
|
-
lineHeight: token.lineHeightLG
|
|
38
|
-
},
|
|
39
|
-
[`${noticeCls}-description`]: {
|
|
40
|
-
fontSize,
|
|
41
|
-
color: colorText,
|
|
42
|
-
marginTop: token.marginXS,
|
|
43
|
-
"&:first-child": {
|
|
44
|
-
marginTop: 0,
|
|
45
|
-
marginInlineEnd: token.marginSM
|
|
46
|
-
}
|
|
47
|
-
},
|
|
48
|
-
[`${noticeCls}-closable ${noticeCls}-title`]: { paddingInlineEnd: token.paddingLG },
|
|
49
|
-
[`${noticeCls}-with-icon ${noticeCls}-title`]: {
|
|
50
|
-
marginBottom: token.marginXS,
|
|
51
|
-
marginInlineStart: token.calc(token.marginSM).add(notificationIconSize).equal(),
|
|
52
|
-
fontSize: fontSizeLG
|
|
53
|
-
},
|
|
54
|
-
[`${noticeCls}-with-icon ${noticeCls}-description`]: {
|
|
55
|
-
marginInlineStart: token.calc(token.marginSM).add(notificationIconSize).equal(),
|
|
56
|
-
fontSize
|
|
57
|
-
},
|
|
58
|
-
[`${noticeCls}-icon`]: {
|
|
59
|
-
position: "absolute",
|
|
60
|
-
fontSize: notificationIconSize,
|
|
61
|
-
lineHeight: 1,
|
|
62
|
-
[`&-success${iconCls}`]: { color: colorSuccess },
|
|
63
|
-
[`&-info${iconCls}`]: { color: colorInfo },
|
|
64
|
-
[`&-warning${iconCls}`]: { color: colorWarning },
|
|
65
|
-
[`&-error${iconCls}`]: { color: colorError }
|
|
66
|
-
},
|
|
67
|
-
[`${noticeCls}-close`]: {
|
|
68
|
-
position: "absolute",
|
|
69
|
-
top: token.notificationPaddingVertical,
|
|
70
|
-
insetInlineEnd: token.notificationPaddingHorizontal,
|
|
71
|
-
color: token.colorIcon,
|
|
72
|
-
outline: "none",
|
|
73
|
-
width: token.notificationCloseButtonSize,
|
|
74
|
-
height: token.notificationCloseButtonSize,
|
|
75
|
-
borderRadius: token.borderRadiusSM,
|
|
76
|
-
transition: ["color", "background-color"].map((prop) => `${prop} ${motionDurationMid}`).join(", "),
|
|
77
|
-
display: "flex",
|
|
78
|
-
alignItems: "center",
|
|
79
|
-
justifyContent: "center",
|
|
80
|
-
background: "none",
|
|
81
|
-
border: "none",
|
|
82
|
-
"&:hover": {
|
|
83
|
-
color: token.colorIconHover,
|
|
84
|
-
backgroundColor: token.colorBgTextHover
|
|
85
|
-
},
|
|
86
|
-
"&:active": { backgroundColor: token.colorBgTextActive },
|
|
87
|
-
...genFocusStyle(token)
|
|
88
|
-
},
|
|
89
|
-
[`${noticeCls}-progress`]: {
|
|
90
|
-
position: "absolute",
|
|
91
|
-
display: "block",
|
|
92
|
-
appearance: "none",
|
|
93
|
-
inlineSize: `calc(100% - ${unit(borderRadiusLG)} * 2)`,
|
|
94
|
-
left: {
|
|
95
|
-
_skip_check_: true,
|
|
96
|
-
value: borderRadiusLG
|
|
97
|
-
},
|
|
98
|
-
right: {
|
|
99
|
-
_skip_check_: true,
|
|
100
|
-
value: borderRadiusLG
|
|
101
|
-
},
|
|
102
|
-
bottom: 0,
|
|
103
|
-
blockSize: notificationProgressHeight,
|
|
104
|
-
border: 0,
|
|
105
|
-
"&, &::-webkit-progress-bar": {
|
|
106
|
-
borderRadius: borderRadiusLG,
|
|
107
|
-
backgroundColor: `rgba(0, 0, 0, 0.04)`
|
|
108
|
-
},
|
|
109
|
-
"&::-moz-progress-bar": { background: progressBg },
|
|
110
|
-
"&::-webkit-progress-value": {
|
|
111
|
-
borderRadius: borderRadiusLG,
|
|
112
|
-
background: progressBg
|
|
113
|
-
}
|
|
114
|
-
},
|
|
115
|
-
[`${noticeCls}-actions`]: {
|
|
116
|
-
float: "right",
|
|
117
|
-
marginTop: token.marginSM
|
|
118
|
-
}
|
|
119
|
-
};
|
|
120
|
-
};
|
|
121
|
-
const genNotificationStyle = (token) => {
|
|
122
|
-
const { componentCls, notificationMarginBottom, notificationMarginEdge, motionDurationMid, motionEaseInOut } = token;
|
|
123
|
-
const noticeCls = `${componentCls}-notice`;
|
|
124
|
-
const fadeOut = new Keyframes("antNotificationFadeOut", {
|
|
125
|
-
"0%": {
|
|
126
|
-
maxHeight: token.animationMaxHeight,
|
|
127
|
-
marginBottom: notificationMarginBottom
|
|
128
|
-
},
|
|
129
|
-
"100%": {
|
|
130
|
-
maxHeight: 0,
|
|
131
|
-
marginBottom: 0,
|
|
132
|
-
paddingTop: 0,
|
|
133
|
-
paddingBottom: 0,
|
|
134
|
-
opacity: 0
|
|
135
|
-
}
|
|
136
|
-
});
|
|
137
|
-
return [{ [componentCls]: {
|
|
138
|
-
...resetComponent(token),
|
|
139
|
-
position: "fixed",
|
|
140
|
-
zIndex: token.zIndexPopup,
|
|
141
|
-
marginRight: {
|
|
142
|
-
value: notificationMarginEdge,
|
|
143
|
-
_skip_check_: true
|
|
144
|
-
},
|
|
145
|
-
[`${componentCls}-hook-holder`]: { position: "relative" },
|
|
146
|
-
[`${componentCls}-fade-appear-prepare`]: { opacity: "0 !important" },
|
|
147
|
-
[`${componentCls}-fade-enter, ${componentCls}-fade-appear`]: {
|
|
148
|
-
animationDuration: token.motionDurationMid,
|
|
149
|
-
animationTimingFunction: motionEaseInOut,
|
|
150
|
-
animationFillMode: "both",
|
|
151
|
-
opacity: 0,
|
|
152
|
-
animationPlayState: "paused"
|
|
153
|
-
},
|
|
154
|
-
[`${componentCls}-fade-leave`]: {
|
|
155
|
-
animationTimingFunction: motionEaseInOut,
|
|
156
|
-
animationFillMode: "both",
|
|
157
|
-
animationDuration: motionDurationMid,
|
|
158
|
-
animationPlayState: "paused"
|
|
159
|
-
},
|
|
160
|
-
[`${componentCls}-fade-enter${componentCls}-fade-enter-active, ${componentCls}-fade-appear${componentCls}-fade-appear-active`]: { animationPlayState: "running" },
|
|
161
|
-
[`${componentCls}-fade-leave${componentCls}-fade-leave-active`]: {
|
|
162
|
-
animationName: fadeOut,
|
|
163
|
-
animationPlayState: "running"
|
|
164
|
-
},
|
|
165
|
-
"&-rtl": {
|
|
166
|
-
direction: "rtl",
|
|
167
|
-
[`${noticeCls}-actions`]: { float: "left" }
|
|
168
|
-
}
|
|
169
|
-
} }, { [componentCls]: { [`${noticeCls}-wrapper`]: genNoticeStyle(token) } }];
|
|
170
|
-
};
|
|
10
|
+
const DEFAULT_COLLAPSED_STACK_VISIBLE_COUNT = 3;
|
|
11
|
+
/** Provide default public ComponentToken values for Notification. */
|
|
171
12
|
function prepareComponentToken(token) {
|
|
172
13
|
return {
|
|
173
14
|
zIndexPopup: token.zIndexPopupBase + CONTAINER_MAX_OFFSET + 50,
|
|
@@ -179,6 +20,7 @@ function prepareComponentToken(token) {
|
|
|
179
20
|
colorWarningBg: void 0
|
|
180
21
|
};
|
|
181
22
|
}
|
|
23
|
+
/** Derive internal Notification style tokens from alias and component tokens. */
|
|
182
24
|
const prepareNotificationToken = (token) => {
|
|
183
25
|
const notificationPaddingVertical = token.paddingMD;
|
|
184
26
|
const notificationPaddingHorizontal = token.paddingLG;
|
|
@@ -191,19 +33,107 @@ const prepareNotificationToken = (token) => {
|
|
|
191
33
|
notificationMarginBottom: token.margin,
|
|
192
34
|
notificationPadding: `${unit(token.paddingMD)} ${unit(token.paddingContentHorizontalLG)}`,
|
|
193
35
|
notificationMarginEdge: token.marginLG,
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
notificationProgressHeight: 2
|
|
36
|
+
notificationProgressHeight: 2,
|
|
37
|
+
notificationMotionOffset: 64
|
|
197
38
|
});
|
|
198
39
|
};
|
|
199
|
-
|
|
200
|
-
|
|
40
|
+
/** Build a clip-path inset that keeps stack shadows visible. */
|
|
41
|
+
function getStackNoticeClipPath(offset) {
|
|
42
|
+
return `inset(${offset} ${offset} ${offset} ${offset})`;
|
|
43
|
+
}
|
|
44
|
+
/** Generate shared list content and motion base styles. */
|
|
45
|
+
const genNotificationListContentStyle = (token) => {
|
|
46
|
+
const { componentCls, motionDurationMid, motionDurationSlow, motionEaseInOut } = token;
|
|
47
|
+
const listContentCls = `${`${componentCls}-list`}-content`;
|
|
48
|
+
return {
|
|
49
|
+
[listContentCls]: {
|
|
50
|
+
position: "relative",
|
|
51
|
+
display: "flex",
|
|
52
|
+
flexShrink: 0,
|
|
53
|
+
flexDirection: "column",
|
|
54
|
+
gap: token.notificationMarginBottom,
|
|
55
|
+
width: "100%",
|
|
56
|
+
willChange: "height, transform",
|
|
57
|
+
transition: "none",
|
|
58
|
+
[`&${listContentCls}-decrease`]: { transition: `height calc(${motionDurationSlow} * 2) ${motionEaseInOut} ${motionDurationMid}` }
|
|
59
|
+
},
|
|
60
|
+
[`${componentCls}-fade`]: {
|
|
61
|
+
backfaceVisibility: "hidden",
|
|
62
|
+
willChange: "transform, opacity"
|
|
63
|
+
}
|
|
64
|
+
};
|
|
65
|
+
};
|
|
66
|
+
/** Generate the root holder, list, stack, and RTL styles for notifications. */
|
|
67
|
+
function genNotificationListStyle(token, config) {
|
|
68
|
+
const { componentCls, notificationMarginEdge } = token;
|
|
69
|
+
const notificationMarginEdgeVar = "--notification-margin-edge";
|
|
70
|
+
const noticeCls = `${componentCls}-notice`;
|
|
71
|
+
const listCls = `${componentCls}-list`;
|
|
72
|
+
const listWidth = config.listWidthKey ? token.calc(token[config.listWidthKey]).add(token.calc(notificationMarginEdge).mul(2)).equal() : "100%";
|
|
73
|
+
const noticeBeyondStackVisibleCountCls = `${noticeCls}:nth-last-child(n + ${(config.stackVisibleCount ?? DEFAULT_COLLAPSED_STACK_VISIBLE_COUNT) + 1})`;
|
|
74
|
+
const stackNoticeClipPath = getStackNoticeClipPath(unit(token.calc(token.marginXXL).mul(-1).equal()));
|
|
75
|
+
return { [componentCls]: {
|
|
76
|
+
...resetComponent(token),
|
|
77
|
+
[notificationMarginEdgeVar]: unit(notificationMarginEdge),
|
|
78
|
+
position: "fixed",
|
|
79
|
+
zIndex: token.zIndexPopup,
|
|
80
|
+
width: listWidth,
|
|
81
|
+
maxWidth: "100vw",
|
|
82
|
+
height: "100vh",
|
|
83
|
+
overflow: "hidden",
|
|
84
|
+
overscrollBehavior: "contain",
|
|
85
|
+
[`${componentCls}-hook-holder`]: { position: "relative" },
|
|
86
|
+
[`&${listCls}`]: {
|
|
87
|
+
maxHeight: "100vh",
|
|
88
|
+
padding: `var(${notificationMarginEdgeVar})`,
|
|
89
|
+
overflowX: "hidden",
|
|
90
|
+
overflowY: "auto",
|
|
91
|
+
overscrollBehavior: "contain",
|
|
92
|
+
scrollbarWidth: "none",
|
|
93
|
+
msOverflowStyle: "none",
|
|
94
|
+
pointerEvents: "none",
|
|
95
|
+
"&::-webkit-scrollbar": {
|
|
96
|
+
display: "none",
|
|
97
|
+
width: 0,
|
|
98
|
+
height: 0
|
|
99
|
+
}
|
|
100
|
+
},
|
|
101
|
+
...genNotificationListContentStyle(token),
|
|
102
|
+
[`&${componentCls}-stack`]: {
|
|
103
|
+
[noticeCls]: { clipPath: stackNoticeClipPath },
|
|
104
|
+
[`&:not(${componentCls}-stack-expanded)`]: {
|
|
105
|
+
[noticeCls]: { "--notification-scale": "calc(1 - min(var(--notification-index, 0), 2) * 0.06)" },
|
|
106
|
+
[`${noticeCls}:not(${noticeCls}-stack-in-threshold)`]: {
|
|
107
|
+
opacity: 0,
|
|
108
|
+
pointerEvents: "none"
|
|
109
|
+
},
|
|
110
|
+
[noticeBeyondStackVisibleCountCls]: {
|
|
111
|
+
opacity: 0,
|
|
112
|
+
pointerEvents: "none"
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
},
|
|
116
|
+
"&-rtl": {
|
|
117
|
+
direction: "rtl",
|
|
118
|
+
[`${noticeCls}-actions`]: { float: "left" }
|
|
119
|
+
}
|
|
120
|
+
} };
|
|
121
|
+
}
|
|
122
|
+
/** Register the PurePanel sub-style component for Notification. */
|
|
123
|
+
const PurePanelStyle = genSubStyleComponent(["Notification", "PurePanel"], (token) => genPurePanelStyle(prepareNotificationToken(token)), prepareComponentToken);
|
|
124
|
+
/** Compose the shared list, item, and placement styles. */
|
|
125
|
+
function sharedGenerateStyle(token, config) {
|
|
126
|
+
const itemStyle = config.itemStyle ?? notification_default;
|
|
201
127
|
return [
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
128
|
+
genNotificationListStyle(token, config),
|
|
129
|
+
itemStyle(token),
|
|
130
|
+
placement_default(token)
|
|
205
131
|
];
|
|
132
|
+
}
|
|
133
|
+
/** Register the main style hook for Notification. */
|
|
134
|
+
var style_default = genStyleHooks("Notification", (token) => {
|
|
135
|
+
return sharedGenerateStyle(prepareNotificationToken(token), { listWidthKey: "width" });
|
|
206
136
|
}, prepareComponentToken);
|
|
207
137
|
|
|
208
138
|
//#endregion
|
|
209
|
-
export { style_default as default,
|
|
139
|
+
export { PurePanelStyle, style_default as default, prepareNotificationToken, sharedGenerateStyle };
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { NotificationToken } from "./index.js";
|
|
2
|
+
import { GenerateStyle } from "../../theme/interface/index.js";
|
|
3
|
+
import "../../theme/internal.js";
|
|
4
|
+
import { CSSObject } from "@antdv-next/cssinjs";
|
|
5
|
+
|
|
6
|
+
//#region src/notification/style/notification.d.ts
|
|
7
|
+
interface NotificationItemSharedStyleConfig {
|
|
8
|
+
width: number | string;
|
|
9
|
+
iconFontSize: number | string;
|
|
10
|
+
titleFontSize: number | string;
|
|
11
|
+
titleLineHeight: number | string;
|
|
12
|
+
contentStyle: CSSObject;
|
|
13
|
+
noticeStyle?: CSSObject;
|
|
14
|
+
typeStyle?: boolean;
|
|
15
|
+
}
|
|
16
|
+
/** Generate item styles shared by Notification and Message notice cards. */
|
|
17
|
+
declare function genListItemSharedStyle(token: NotificationToken, config: NotificationItemSharedStyleConfig): CSSObject;
|
|
18
|
+
/** Generate standalone PurePanel styles for Notification. */
|
|
19
|
+
declare function genPurePanelStyle(token: NotificationToken): CSSObject;
|
|
20
|
+
/** Wrap Notification item styles under the component root selector. */
|
|
21
|
+
declare const genNotificationStyle: GenerateStyle<NotificationToken, CSSObject>;
|
|
22
|
+
//#endregion
|
|
23
|
+
export { genNotificationStyle as default, genListItemSharedStyle, genPurePanelStyle };
|
|
@@ -0,0 +1,195 @@
|
|
|
1
|
+
import { genFocusStyle } from "../../style/index.js";
|
|
2
|
+
import { genCssVar } from "../../theme/util/genStyleUtils.js";
|
|
3
|
+
import { unit } from "@antdv-next/cssinjs";
|
|
4
|
+
|
|
5
|
+
//#region src/notification/style/notification.ts
|
|
6
|
+
/** Generate motion transitions shared by notification-like notice cards. */
|
|
7
|
+
function genNotificationItemMotionStyle(token) {
|
|
8
|
+
const { motionDurationMid, motionEaseInOut } = token;
|
|
9
|
+
const transition = `${motionDurationMid} ${motionEaseInOut}`;
|
|
10
|
+
return {
|
|
11
|
+
transform: "scale(var(--notification-scale, 1))",
|
|
12
|
+
transition: [
|
|
13
|
+
"transform",
|
|
14
|
+
"inset",
|
|
15
|
+
"clip-path",
|
|
16
|
+
"opacity"
|
|
17
|
+
].map((property) => `${property} ${transition}`).join(", ")
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
/** Generate item styles shared by Notification and Message notice cards. */
|
|
21
|
+
function genListItemSharedStyle(token, config) {
|
|
22
|
+
const { componentCls, antCls, colorSuccess, colorInfo, colorWarning, colorError, colorTextHeading, colorText, boxShadow, borderRadiusLG, fontSize, lineHeight, notificationBg, notificationPadding, notificationMarginEdge, margin, calc } = token;
|
|
23
|
+
const noticeCls = `${componentCls}-notice`;
|
|
24
|
+
const [varName, varRef] = genCssVar(antCls, "notification");
|
|
25
|
+
return {
|
|
26
|
+
[noticeCls]: {
|
|
27
|
+
position: "absolute",
|
|
28
|
+
width: config.width,
|
|
29
|
+
maxWidth: `calc(100vw - ${unit(calc(notificationMarginEdge).mul(2).equal())})`,
|
|
30
|
+
padding: notificationPadding,
|
|
31
|
+
pointerEvents: "auto",
|
|
32
|
+
[varName("icon-font-size")]: config.iconFontSize,
|
|
33
|
+
[varName("title-font-size")]: config.titleFontSize,
|
|
34
|
+
[varName("title-line-height")]: config.titleLineHeight,
|
|
35
|
+
boxSizing: "border-box",
|
|
36
|
+
color: colorText,
|
|
37
|
+
background: notificationBg,
|
|
38
|
+
borderRadius: borderRadiusLG,
|
|
39
|
+
boxShadow,
|
|
40
|
+
fontSize,
|
|
41
|
+
lineHeight,
|
|
42
|
+
wordWrap: "break-word",
|
|
43
|
+
overflow: "visible",
|
|
44
|
+
...genNotificationItemMotionStyle(token),
|
|
45
|
+
...config.noticeStyle,
|
|
46
|
+
"&::after": {
|
|
47
|
+
position: "absolute",
|
|
48
|
+
insetInline: 0,
|
|
49
|
+
top: calc(margin).mul(-1).equal(),
|
|
50
|
+
height: margin,
|
|
51
|
+
content: "\"\""
|
|
52
|
+
},
|
|
53
|
+
...config.typeStyle && {
|
|
54
|
+
"&-success": { background: varRef("color-success-bg", notificationBg) },
|
|
55
|
+
"&-error": { background: varRef("color-error-bg", notificationBg) },
|
|
56
|
+
"&-info": { background: varRef("color-info-bg", notificationBg) },
|
|
57
|
+
"&-warning": { background: varRef("color-warning-bg", notificationBg) }
|
|
58
|
+
}
|
|
59
|
+
},
|
|
60
|
+
[`${noticeCls}-wrapper`]: {
|
|
61
|
+
display: "flex",
|
|
62
|
+
...config.contentStyle
|
|
63
|
+
},
|
|
64
|
+
[`${noticeCls}-title`]: {
|
|
65
|
+
color: colorTextHeading,
|
|
66
|
+
fontSize: varRef("title-font-size"),
|
|
67
|
+
lineHeight: varRef("title-line-height")
|
|
68
|
+
},
|
|
69
|
+
[`${noticeCls}-icon`]: {
|
|
70
|
+
flex: "none",
|
|
71
|
+
fontSize: varRef("icon-font-size"),
|
|
72
|
+
lineHeight: 1,
|
|
73
|
+
[`&${noticeCls}-icon-success`]: { color: colorSuccess },
|
|
74
|
+
[`&${noticeCls}-icon-info, &${noticeCls}-icon-loading`]: { color: colorInfo },
|
|
75
|
+
[`&${noticeCls}-icon-warning`]: { color: colorWarning },
|
|
76
|
+
[`&${noticeCls}-icon-error`]: { color: colorError }
|
|
77
|
+
}
|
|
78
|
+
};
|
|
79
|
+
}
|
|
80
|
+
/** Generate the complete notice item styles for Notification. */
|
|
81
|
+
function genNotificationItemStyle(token) {
|
|
82
|
+
const { componentCls, progressBg, notificationProgressHeight, fontSize, borderRadiusLG, width, notificationIconSize, colorText, motionDurationMid, fontSizeLG, lineHeightLG, marginSM, marginXS, paddingLG, notificationPaddingVertical, notificationPaddingHorizontal, notificationCloseButtonSize, colorIcon, borderRadiusSM, colorIconHover, colorBgTextHover, colorBgTextActive } = token;
|
|
83
|
+
const noticeCls = `${componentCls}-notice`;
|
|
84
|
+
return {
|
|
85
|
+
...genListItemSharedStyle(token, {
|
|
86
|
+
width,
|
|
87
|
+
iconFontSize: notificationIconSize,
|
|
88
|
+
titleFontSize: fontSizeLG,
|
|
89
|
+
titleLineHeight: lineHeightLG,
|
|
90
|
+
contentStyle: {
|
|
91
|
+
alignItems: "flex-start",
|
|
92
|
+
gap: marginSM
|
|
93
|
+
},
|
|
94
|
+
typeStyle: true
|
|
95
|
+
}),
|
|
96
|
+
[`${noticeCls}-section`]: {
|
|
97
|
+
display: "flex",
|
|
98
|
+
flexDirection: "column",
|
|
99
|
+
flex: "auto",
|
|
100
|
+
gap: marginXS,
|
|
101
|
+
minWidth: 0
|
|
102
|
+
},
|
|
103
|
+
[`${noticeCls}-description`]: {
|
|
104
|
+
color: colorText,
|
|
105
|
+
fontSize
|
|
106
|
+
},
|
|
107
|
+
[`${noticeCls}-closable ${noticeCls}-title`]: { paddingInlineEnd: paddingLG },
|
|
108
|
+
[`${noticeCls}-closable ${noticeCls}-description`]: { paddingInlineEnd: paddingLG },
|
|
109
|
+
[`${noticeCls}-closable ${noticeCls}-title + ${noticeCls}-description`]: { paddingInlineEnd: 0 },
|
|
110
|
+
[`${noticeCls}-close`]: {
|
|
111
|
+
position: "absolute",
|
|
112
|
+
top: notificationPaddingVertical,
|
|
113
|
+
insetInlineEnd: notificationPaddingHorizontal,
|
|
114
|
+
display: "flex",
|
|
115
|
+
alignItems: "center",
|
|
116
|
+
justifyContent: "center",
|
|
117
|
+
width: notificationCloseButtonSize,
|
|
118
|
+
height: notificationCloseButtonSize,
|
|
119
|
+
color: colorIcon,
|
|
120
|
+
background: "none",
|
|
121
|
+
border: "none",
|
|
122
|
+
borderRadius: borderRadiusSM,
|
|
123
|
+
outline: "none",
|
|
124
|
+
transition: ["color", "background-color"].map((prop) => `${prop} ${motionDurationMid}`).join(", "),
|
|
125
|
+
"&:hover": {
|
|
126
|
+
color: colorIconHover,
|
|
127
|
+
backgroundColor: colorBgTextHover
|
|
128
|
+
},
|
|
129
|
+
"&:active": { backgroundColor: colorBgTextActive },
|
|
130
|
+
...genFocusStyle(token)
|
|
131
|
+
},
|
|
132
|
+
[`${noticeCls}-progress`]: {
|
|
133
|
+
position: "absolute",
|
|
134
|
+
bottom: 0,
|
|
135
|
+
display: "block",
|
|
136
|
+
appearance: "none",
|
|
137
|
+
inlineSize: `calc(100% - ${unit(borderRadiusLG)} * 2)`,
|
|
138
|
+
blockSize: notificationProgressHeight,
|
|
139
|
+
border: 0,
|
|
140
|
+
left: {
|
|
141
|
+
_skip_check_: true,
|
|
142
|
+
value: borderRadiusLG
|
|
143
|
+
},
|
|
144
|
+
right: {
|
|
145
|
+
_skip_check_: true,
|
|
146
|
+
value: borderRadiusLG
|
|
147
|
+
},
|
|
148
|
+
"&, &::-webkit-progress-bar": {
|
|
149
|
+
borderRadius: borderRadiusLG,
|
|
150
|
+
backgroundColor: "rgba(0, 0, 0, 0.04)"
|
|
151
|
+
},
|
|
152
|
+
"&::-moz-progress-bar": { background: progressBg },
|
|
153
|
+
"&::-webkit-progress-value": {
|
|
154
|
+
borderRadius: borderRadiusLG,
|
|
155
|
+
background: progressBg
|
|
156
|
+
}
|
|
157
|
+
},
|
|
158
|
+
[`${noticeCls}-actions`]: {
|
|
159
|
+
float: "right",
|
|
160
|
+
marginTop: marginSM
|
|
161
|
+
}
|
|
162
|
+
};
|
|
163
|
+
}
|
|
164
|
+
/** Generate standalone PurePanel styles for Notification. */
|
|
165
|
+
function genPurePanelStyle(token) {
|
|
166
|
+
const { componentCls, width } = token;
|
|
167
|
+
const noticeCls = `${componentCls}-notice`;
|
|
168
|
+
const actionsCls = `${noticeCls}-actions`;
|
|
169
|
+
const notificationItemStyle = genNotificationItemStyle(token);
|
|
170
|
+
return { [`${noticeCls}-pure-panel`]: {
|
|
171
|
+
width,
|
|
172
|
+
maxWidth: "100%",
|
|
173
|
+
...notificationItemStyle,
|
|
174
|
+
[noticeCls]: {
|
|
175
|
+
...notificationItemStyle[noticeCls],
|
|
176
|
+
position: "relative",
|
|
177
|
+
width: "100%",
|
|
178
|
+
maxWidth: "100%"
|
|
179
|
+
},
|
|
180
|
+
[actionsCls]: {
|
|
181
|
+
...notificationItemStyle[actionsCls],
|
|
182
|
+
float: "none",
|
|
183
|
+
textAlign: "end"
|
|
184
|
+
}
|
|
185
|
+
} };
|
|
186
|
+
}
|
|
187
|
+
/** Wrap Notification item styles under the component root selector. */
|
|
188
|
+
const genNotificationStyle = (token) => {
|
|
189
|
+
const { componentCls } = token;
|
|
190
|
+
return { [componentCls]: genNotificationItemStyle(token) };
|
|
191
|
+
};
|
|
192
|
+
var notification_default = genNotificationStyle;
|
|
193
|
+
|
|
194
|
+
//#endregion
|
|
195
|
+
export { notification_default as default, genListItemSharedStyle, genPurePanelStyle };
|
|
@@ -4,6 +4,7 @@ import "../../theme/internal.js";
|
|
|
4
4
|
import { CSSObject } from "@antdv-next/cssinjs";
|
|
5
5
|
|
|
6
6
|
//#region src/notification/style/placement.d.ts
|
|
7
|
+
/** Wrap placement styles under the component root selector. */
|
|
7
8
|
declare const genNotificationPlacementStyle: GenerateStyle<NotificationToken, CSSObject>;
|
|
8
9
|
//#endregion
|
|
9
10
|
export { genNotificationPlacementStyle as default };
|