useblocks 1.1.85-dev.9 → 1.1.102
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/CHANGELOG.md +91 -0
- package/README.md +74 -41
- package/compat-globals.js +1 -1
- package/iframe/.vite/manifest.json +4 -4
- package/iframe/css/sandbox.css +35 -1
- package/iframe/{iframe.bb6d921f.html → iframe-eblock.1c4e77a0.html} +2 -2
- package/iframe/{iframe-eblock.bb6d921f.html → iframe.1c4e77a0.html} +2 -2
- package/iframe/js/discussHandlers.Xh4-JUcT.js +88 -0
- package/iframe/js/{iframe-eblock.body.js → iframe-eblock.body.1c4e77a0.js} +1 -1
- package/iframe/js/iframe-eblock.js +2 -2
- package/iframe/js/iframe.body.1c4e77a0.js +319 -0
- package/iframe/js/iframe.js +2 -2
- package/package.json +8 -1
- package/runtime/THIRD_PARTY_LICENSES.txt +49 -42
- package/runtime/package.json +4 -1
- package/runtime/react/index.js +1 -1
- package/runtime/uuid/index.js +21 -0
- package/static/core/11b821ed.js +1 -0
- package/static/core/160bf060.js +104 -0
- package/static/core/1b68c0f0.js +1 -0
- package/static/core/1ed86ed3.js +1 -0
- package/static/core/26cc947d.js +1 -0
- package/static/core/{67f78cad.js → 3ec42945.js} +7 -7
- package/static/core/3fb172c7.js +1 -0
- package/static/core/448f03f8.js +1 -0
- package/static/core/44d2c046.js +1 -0
- package/static/core/{79749848.js → 4c8d0155.js} +5 -5
- package/static/core/53103851.js +4 -0
- package/static/core/{a767f327.js → 5d849eef.js} +1 -1
- package/static/core/5e7c221f.js +28 -0
- package/static/core/64be048b.js +27 -0
- package/static/core/{de07cade.js → 6a671446.js} +3 -3
- package/static/core/{db82c42b.js → 756874c6.js} +1 -1
- package/static/core/{4c3f5897.js → 847338a8.js} +2 -2
- package/static/core/91e07171.js +2 -0
- package/static/core/a2e57e5f.js +1 -0
- package/static/core/{a5996860.js → a6303cb2.js} +1 -1
- package/static/core/{9f137764.js → a98b6879.js} +1 -1
- package/static/core/ae22b7f6.js +93 -0
- package/static/core/{44a83e21.js → b653f9c5.js} +1 -1
- package/static/core/{cb46784e.js → b7aa9fec.js} +1 -1
- package/static/core/{d8bbcfbd.js → ca4dad9b.js} +2 -2
- package/static/core/{6faa23a1.js → cc180859.js} +1 -1
- package/static/core/d7666ad0.js +291 -0
- package/static/core/dcc37768.js +1 -0
- package/static/core/edf450a1.js +7 -0
- package/static/core/f1ee2bef.js +1 -0
- package/static/core/{1e3078da.js → f323e60e.js} +1 -1
- package/static/core/{175b5b0f.js → ff7d14e8.js} +1 -1
- package/static/esm/2490dab8.js +1 -0
- package/static/esm/668ee399.js +1 -0
- package/static/esm/971f1b2c.js +1 -0
- package/static/esm/f76c9d9d.js +1 -0
- package/static/umd/6639d610.js +1 -0
- package/static/umd-runtime/B7h7P1Np.js +1 -0
- package/static/umd-runtime/{DHIkHsbq.js → BAqQTgiL.js} +1 -1
- package/static/umd-runtime/{DiNHpyis.js → BB6AXfHj.js} +1 -1
- package/static/umd-runtime/{CnUGCoaH.js → BauvM4c_.js} +1 -1
- package/static/umd-runtime/{cL_ha9ef.js → CgVJ4rE0.js} +1 -1
- package/static/umd-runtime/Cvm7BS4_.js +341 -0
- package/static/umd-runtime/{BnE05QKl.js → D7DggGzi.js} +1 -1
- package/static/umd-runtime/{2iAslXEF.js → DBbch1O-.js} +1 -1
- package/static/umd-runtime/{Bcqtk2f7.js → Dqoi-pC_.js} +2 -2
- package/static/umd-runtime/{CDTBLHGd.js → G2k8ELiO.js} +3 -3
- package/static/umd-runtime/{CVtPwspX.js → SFp4nbvq.js} +1 -1
- package/static/umd-runtime/{DVB_-O4B.js → UsRzAWs2.js} +1 -1
- package/static/umd-runtime/runtime.2paN090q.js +1 -0
- package/static/umd-runtime/{ui-kit-icons.js → ui-kit-icons.DqlZwgBU.js} +1 -1
- package/static/umd-runtime/{ui-kit.js → ui-kit.CoVNet0I.js} +2 -2
- package/static/umd-runtime/{DP3QTW77.js → uk9LyZos.js} +1 -1
- package/ui-kit/icons.js +2 -0
- package/useblocks-core.1c4e77a0.js +859 -0
- package/useblocks-esm.js +11 -10
- package/{useblocks-po.bb6d921f.js → useblocks-po.1c4e77a0.js} +1 -1
- package/useblocks.d.ts +162 -28
- package/useblocks.js +39 -15
- package/vendor/@rc-component/cascader/package.json +1 -1
- package/vendor/@rc-component/dialog/es/Dialog/Content/Panel.js +3 -2
- package/vendor/@rc-component/dialog/package.json +1 -1
- package/vendor/@rc-component/image/es/Preview/index.js +3 -3
- package/vendor/@rc-component/image/package.json +1 -1
- package/vendor/@rc-component/input/es/BaseInput.js +3 -3
- package/vendor/@rc-component/input/es/Input.js +20 -27
- package/vendor/@rc-component/{textarea → input}/es/ResizableTextArea.js +5 -4
- package/vendor/@rc-component/{textarea → input}/es/TextArea.js +30 -40
- package/vendor/@rc-component/{textarea → input}/es/calculateNodeHeight.js +4 -4
- package/vendor/@rc-component/input/es/hooks/useCountDisplay.js +25 -0
- package/vendor/@rc-component/input/es/hooks/useCountExceed.js +25 -0
- package/vendor/@rc-component/input/es/hooks/useMergedValue.js +13 -0
- package/vendor/@rc-component/input/es/index.js +3 -1
- package/vendor/@rc-component/input/package.json +1 -1
- package/vendor/@rc-component/mentions/es/DropdownMenu.js +1 -1
- package/vendor/@rc-component/mentions/es/Mentions.js +35 -8
- package/vendor/@rc-component/mentions/package.json +1 -1
- package/vendor/@rc-component/menu/es/Menu.js +1 -0
- package/vendor/@rc-component/menu/es/MenuItem.js +1 -0
- package/vendor/@rc-component/menu/es/MenuItemGroup.js +1 -0
- package/vendor/@rc-component/menu/es/SubMenu/PopupTrigger.js +1 -0
- package/vendor/@rc-component/menu/es/SubMenu/index.js +1 -0
- package/vendor/@rc-component/menu/es/context/MenuContext.js +1 -0
- package/vendor/@rc-component/menu/es/hooks/useAccessibility.js +1 -0
- package/vendor/@rc-component/menu/es/hooks/useKeyRecords.js +1 -0
- package/vendor/@rc-component/menu/es/utils/commonUtil.js +1 -0
- package/vendor/@rc-component/menu/es/utils/nodeUtil.js +2 -1
- package/vendor/@rc-component/menu/es/utils/warnUtil.js +1 -0
- package/vendor/@rc-component/menu/package.json +1 -1
- package/vendor/@rc-component/notification/LICENSE +21 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/LICENSE +22 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/Children/toArray.js +15 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/Dom/canUseDom.js +6 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/Dom/contains.js +13 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/Dom/dynamicCSS.js +94 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/Dom/findDOMNode.js +14 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/Dom/focus.js +99 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/Dom/isVisible.js +18 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/Dom/shadow.js +12 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/Dom/styleChecker.js +2 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/KeyCode.js +499 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/Portal.js +28 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/React/isFragment.js +12 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/React/render.js +2 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/getScrollBarSize.js +2 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/hooks/useControlledState.js +3 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/hooks/useDelayState.js +4 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/hooks/useEvent.js +9 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/hooks/useId.js +23 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/hooks/useLayoutEffect.js +26 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/hooks/useMemo.js +12 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/hooks/useMergedState.js +4 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/hooks/useState.js +24 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/hooks/useSyncState.js +20 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/index.js +36 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/is.js +21 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/isEqual.js +35 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/isMobile.js +11 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/mergeProps.js +14 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/omit.js +1 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/pickAttrs.js +50 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/proxyObject.js +1 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/raf.js +36 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/ref.js +38 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/test/domHook.js +36 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/utils/get.js +11 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/utils/set.js +58 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/es/warning.js +46 -0
- package/vendor/@rc-component/notification/_/@rc-component/util/package.json +6 -0
- package/vendor/@rc-component/notification/es/Notification.js +129 -0
- package/vendor/@rc-component/notification/es/NotificationList/Content.js +33 -0
- package/vendor/@rc-component/notification/es/NotificationList/index.js +174 -0
- package/vendor/@rc-component/notification/es/NotificationProvider.js +4 -3
- package/vendor/@rc-component/notification/es/Notifications.js +28 -31
- package/vendor/@rc-component/notification/es/Progress.js +10 -0
- package/vendor/@rc-component/notification/es/hooks/useClosable.js +30 -0
- package/vendor/@rc-component/notification/es/hooks/useListPosition/index.js +50 -0
- package/vendor/@rc-component/notification/es/hooks/useListPosition/useSizes.js +33 -0
- package/vendor/@rc-component/notification/es/hooks/useNoticeTimer.js +58 -0
- package/vendor/@rc-component/notification/es/hooks/useNotification.js +27 -18
- package/vendor/@rc-component/notification/es/hooks/useStack.js +4 -4
- package/vendor/@rc-component/notification/es/index.js +4 -2
- package/vendor/@rc-component/notification/package.json +1 -1
- package/vendor/@rc-component/picker/es/PickerInput/Selector/SingleSelector/MultipleDates.js +13 -3
- package/vendor/@rc-component/picker/es/PickerInput/Selector/SingleSelector/index.js +3 -1
- package/vendor/@rc-component/picker/es/PickerInput/SinglePicker.js +2 -1
- package/vendor/@rc-component/picker/package.json +1 -1
- package/vendor/@rc-component/table/LICENSE +21 -0
- package/vendor/@rc-component/table/es/Body/MeasureCell.js +1 -0
- package/vendor/@rc-component/table/es/Body/MeasureRow.js +1 -0
- package/vendor/@rc-component/table/es/Cell/useCellRender.js +1 -0
- package/vendor/@rc-component/table/es/FixedHolder/index.js +1 -0
- package/vendor/@rc-component/table/es/Table.js +17 -9
- package/vendor/@rc-component/table/es/VirtualTable/BodyGrid.js +10 -4
- package/vendor/@rc-component/table/es/VirtualTable/BodyLine.js +13 -5
- package/vendor/@rc-component/table/es/hooks/useColumns/index.js +1 -0
- package/vendor/@rc-component/table/es/hooks/useExpand.js +1 -0
- package/vendor/@rc-component/table/es/hooks/useFixedInfo.js +1 -0
- package/vendor/@rc-component/table/es/hooks/useSticky.js +1 -0
- package/vendor/@rc-component/table/es/index.js +2 -1
- package/vendor/@rc-component/table/es/stickyScrollBar.js +1 -0
- package/vendor/@rc-component/table/es/utils/legacyUtil.js +1 -0
- package/vendor/@rc-component/table/es/utils/offsetUtil.js +1 -0
- package/vendor/@rc-component/table/package.json +1 -1
- package/vendor/@rc-component/tabs/es/TabNavList/OperationNode.js +4 -2
- package/vendor/@rc-component/tabs/es/TabNavList/TabNode.js +5 -4
- package/vendor/@rc-component/tabs/es/TabNavList/index.js +11 -4
- package/vendor/@rc-component/tabs/es/Tabs.js +1 -0
- package/vendor/@rc-component/tabs/es/hooks/useAnimateConfig.js +1 -0
- package/vendor/@rc-component/tabs/es/hooks/useIndicator.js +1 -0
- package/vendor/@rc-component/tabs/es/hooks/useUpdate.js +1 -0
- package/vendor/@rc-component/tabs/package.json +1 -1
- package/vendor/@rc-component/tour/es/TourStep/DefaultPanel.js +4 -1
- package/vendor/@rc-component/tour/package.json +1 -1
- package/vendor/@rc-component/tree/es/MotionTreeNode.js +1 -0
- package/vendor/@rc-component/tree/es/NodeList.js +2 -2
- package/vendor/@rc-component/tree/es/Tree.js +4 -5
- package/vendor/@rc-component/tree/es/TreeNode.js +7 -2
- package/vendor/@rc-component/tree/es/index.js +3 -0
- package/vendor/@rc-component/tree/es/useUnmount.js +1 -0
- package/vendor/@rc-component/tree/es/util.js +1 -0
- package/vendor/@rc-component/tree/es/utils/conductUtil.js +1 -0
- package/vendor/@rc-component/tree/es/utils/treeUtil.js +1 -0
- package/vendor/@rc-component/tree/package.json +1 -1
- package/vendor/@rc-component/tree-select/package.json +1 -1
- package/vendor/@rc-component/util/es/index.js +10 -10
- package/vendor/antd/es/_util/ActionButton.js +2 -3
- package/vendor/antd/es/_util/ContextIsolator.js +1 -1
- package/vendor/antd/es/_util/PurePanel.js +7 -4
- package/vendor/antd/es/_util/convertToTooltipProps.js +2 -2
- package/vendor/antd/es/_util/fallbackProp.js +15 -0
- package/vendor/antd/es/_util/gapSize.js +2 -1
- package/vendor/antd/es/_util/getRenderPropValue.js +2 -1
- package/vendor/antd/es/_util/getScroll.js +4 -4
- package/vendor/antd/es/_util/hooks/index.js +2 -2
- package/vendor/antd/es/_util/hooks/useAllowClear.js +25 -0
- package/vendor/antd/es/_util/hooks/useClosable.js +6 -5
- package/vendor/antd/es/_util/hooks/{useMergeSemantic.js → useMergeSemantic/index.js} +14 -24
- package/vendor/antd/es/_util/hooks/useMergeSemantic/utils.js +14 -0
- package/vendor/antd/es/_util/hooks/useMergedMask.js +2 -1
- package/vendor/antd/es/_util/is.js +27 -0
- package/vendor/antd/es/_util/motion.js +8 -8
- package/vendor/antd/es/_util/normalizeIcon.js +9 -0
- package/vendor/antd/es/_util/placements.js +2 -1
- package/vendor/antd/es/_util/reactNode.js +2 -1
- package/vendor/antd/es/_util/responsiveObserver.js +3 -2
- package/vendor/antd/es/_util/scrollTo.js +3 -1
- package/vendor/antd/es/_util/styleChecker.js +1 -0
- package/vendor/antd/es/_util/throttleByAnimationFrame.js +1 -0
- package/vendor/antd/es/_util/toList.js +1 -1
- package/vendor/antd/es/_util/wave/WaveEffect.js +3 -1
- package/vendor/antd/es/_util/wave/index.js +14 -4
- package/vendor/antd/es/_util/wave/util.js +5 -3
- package/vendor/antd/es/alert/Alert.js +12 -10
- package/vendor/antd/es/alert/ErrorBoundary.js +1 -1
- package/vendor/antd/es/alert/style/index.js +16 -10
- package/vendor/antd/es/anchor/Anchor.js +23 -16
- package/vendor/antd/es/anchor/AnchorLink.js +4 -4
- package/vendor/antd/es/app/App.js +7 -3
- package/vendor/antd/es/auto-complete/AutoComplete.js +7 -8
- package/vendor/antd/es/avatar/Avatar.js +5 -3
- package/vendor/antd/es/back-top/index.js +1 -0
- package/vendor/antd/es/badge/Badge.js +5 -6
- package/vendor/antd/es/badge/Ribbon.js +1 -2
- package/vendor/antd/es/badge/style/index.js +4 -3
- package/vendor/antd/es/border-beam/BorderBeam.js +42 -0
- package/vendor/antd/es/border-beam/BorderBeamEffect.js +24 -0
- package/vendor/antd/es/border-beam/hooks/useBorderSize.js +37 -0
- package/vendor/antd/es/border-beam/hooks/useChildDom.js +24 -0
- package/vendor/antd/es/border-beam/index.js +7 -0
- package/vendor/antd/es/border-beam/style/index.js +60 -0
- package/vendor/antd/es/border-beam/util.js +26 -0
- package/vendor/antd/es/breadcrumb/Breadcrumb.js +1 -2
- package/vendor/antd/es/breadcrumb/BreadcrumbItem.js +1 -1
- package/vendor/antd/es/breadcrumb/useItemRender.js +3 -2
- package/vendor/antd/es/button/Button.js +7 -6
- package/vendor/antd/es/button/buttonHelpers.js +4 -8
- package/vendor/antd/es/button/index.js +2 -2
- package/vendor/antd/es/button/style/index.js +5 -0
- package/vendor/antd/es/calendar/generateCalendar.js +20 -8
- package/vendor/antd/es/card/Card.js +5 -7
- package/vendor/antd/es/card/CardMeta.js +1 -2
- package/vendor/antd/es/carousel/index.js +2 -1
- package/vendor/antd/es/cascader/Panel.js +1 -1
- package/vendor/antd/es/cascader/index.js +23 -16
- package/vendor/antd/es/cascader/style/columns.js +6 -2
- package/vendor/antd/es/checkbox/Checkbox.js +2 -3
- package/vendor/antd/es/checkbox/Group.js +2 -1
- package/vendor/antd/es/checkbox/style/index.js +1 -5
- package/vendor/antd/es/checkbox/useBubbleLock.js +1 -0
- package/vendor/antd/es/collapse/Collapse.js +3 -3
- package/vendor/antd/es/collapse/style/index.js +1 -4
- package/vendor/antd/es/color-picker/ColorPicker.js +1 -2
- package/vendor/antd/es/color-picker/ColorPickerPanel.js +2 -1
- package/vendor/antd/es/color-picker/components/ColorTrigger.js +3 -1
- package/vendor/antd/es/color-picker/components/PanelPicker/index.js +1 -0
- package/vendor/antd/es/config-provider/hooks/useSize.js +3 -2
- package/vendor/antd/es/config-provider/hooks/useTheme.js +2 -0
- package/vendor/antd/es/config-provider/index.js +11 -3
- package/vendor/antd/es/date-picker/generatePicker/generateRangePicker.js +20 -10
- package/vendor/antd/es/date-picker/generatePicker/generateSinglePicker.js +17 -8
- package/vendor/antd/es/date-picker/generatePicker/useSuffixIcon.js +1 -1
- package/vendor/antd/es/date-picker/hooks/useMergedPickerSemantic.js +1 -2
- package/vendor/antd/es/date-picker/style/index.js +13 -3
- package/vendor/antd/es/date-picker/style/multiple.js +3 -4
- package/vendor/antd/es/date-picker/style/panel.js +5 -20
- package/vendor/antd/es/date-picker/util.js +14 -13
- package/vendor/antd/es/descriptions/Cell.js +2 -3
- package/vendor/antd/es/descriptions/hooks/useItems.js +2 -1
- package/vendor/antd/es/descriptions/index.js +3 -3
- package/vendor/antd/es/divider/index.js +3 -2
- package/vendor/antd/es/drawer/Drawer.js +10 -5
- package/vendor/antd/es/drawer/DrawerPanel.js +3 -2
- package/vendor/antd/es/dropdown/dropdown.js +11 -8
- package/vendor/antd/es/dropdown/style/index.js +2 -6
- package/vendor/antd/es/empty/index.js +1 -2
- package/vendor/antd/es/flex/index.js +2 -2
- package/vendor/antd/es/float-button/BackTop.js +1 -0
- package/vendor/antd/es/float-button/FloatButton.js +3 -3
- package/vendor/antd/es/float-button/FloatButtonGroup.js +2 -2
- package/vendor/antd/es/form/ErrorList.js +13 -6
- package/vendor/antd/es/form/Form.js +7 -6
- package/vendor/antd/es/form/FormItem/ItemHolder.js +1 -1
- package/vendor/antd/es/form/FormItem/index.js +6 -6
- package/vendor/antd/es/form/FormItemInput.js +5 -3
- package/vendor/antd/es/form/FormItemLabel.js +2 -1
- package/vendor/antd/es/form/FormList.js +1 -0
- package/vendor/antd/es/form/hooks/useChildren.js +4 -3
- package/vendor/antd/es/form/hooks/useForm.js +3 -1
- package/vendor/antd/es/form/hooks/useFrameState.js +1 -0
- package/vendor/antd/es/form/hooks/useItemRef.js +7 -5
- package/vendor/antd/es/form/style/index.js +1 -3
- package/vendor/antd/es/grid/col.js +5 -7
- package/vendor/antd/es/grid/hooks/useBreakpoint.js +1 -0
- package/vendor/antd/es/grid/hooks/useGutter.js +2 -1
- package/vendor/antd/es/grid/row.js +7 -6
- package/vendor/antd/es/image/PreviewGroup.js +1 -2
- package/vendor/antd/es/image/Progress.js +58 -0
- package/vendor/antd/es/image/hooks/useMergedPreviewConfig.js +3 -1
- package/vendor/antd/es/image/hooks/usePlaceholderConfig.js +15 -0
- package/vendor/antd/es/image/hooks/usePreviewConfig.js +3 -2
- package/vendor/antd/es/image/index.js +36 -5
- package/vendor/antd/es/image/style/index.js +114 -4
- package/vendor/antd/es/image/style/progressAnimation.js +26 -0
- package/vendor/antd/es/index.js +2 -1
- package/vendor/antd/es/input/Input.js +9 -4
- package/vendor/antd/es/input/OTP/OTPInput.js +1 -0
- package/vendor/antd/es/input/OTP/index.js +3 -3
- package/vendor/antd/es/input/Password.js +45 -26
- package/vendor/antd/es/input/Search.js +6 -5
- package/vendor/antd/es/input/TextArea.js +13 -7
- package/vendor/antd/es/input/style/index.js +17 -11
- package/vendor/antd/es/input/style/otp.js +2 -1
- package/vendor/antd/es/input/style/variants.js +16 -10
- package/vendor/antd/es/input-number/index.js +3 -3
- package/vendor/antd/es/input-number/style/index.js +9 -9
- package/vendor/antd/es/layout/Sider.js +3 -2
- package/vendor/antd/es/list/index.js +5 -3
- package/vendor/antd/es/locale/en_US.js +3 -1
- package/vendor/antd/es/locale/ru_RU.js +3 -1
- package/vendor/antd/es/locale/useLocale.js +2 -1
- package/vendor/antd/es/masonry/Masonry.js +4 -3
- package/vendor/antd/es/mentions/index.js +28 -14
- package/vendor/antd/es/menu/MenuItem.js +2 -1
- package/vendor/antd/es/menu/OverrideContext.js +1 -0
- package/vendor/antd/es/menu/SubMenu.js +1 -1
- package/vendor/antd/es/menu/menu.js +5 -5
- package/vendor/antd/es/menu/style/index.js +21 -36
- package/vendor/antd/es/menu/style/vertical.js +2 -1
- package/vendor/antd/es/message/PureList.js +49 -0
- package/vendor/antd/es/message/PurePanel.js +28 -36
- package/vendor/antd/es/message/index.js +6 -3
- package/vendor/antd/es/message/style/index.js +102 -99
- package/vendor/antd/es/message/useMessage.js +29 -33
- package/vendor/antd/es/message/util.js +1 -1
- package/vendor/antd/es/modal/ConfirmDialog.js +11 -9
- package/vendor/antd/es/modal/Modal.js +12 -7
- package/vendor/antd/es/modal/PurePanel.js +1 -2
- package/vendor/antd/es/modal/confirm.js +4 -3
- package/vendor/antd/es/modal/shared.js +3 -2
- package/vendor/antd/es/modal/useModal/HookModal.js +2 -1
- package/vendor/antd/es/notification/PureList.js +46 -0
- package/vendor/antd/es/notification/PurePanel.js +37 -56
- package/vendor/antd/es/notification/hooks/useStackConfig.js +13 -0
- package/vendor/antd/es/notification/index.js +3 -1
- package/vendor/antd/es/notification/style/index.js +103 -170
- package/vendor/antd/es/notification/style/notification.js +191 -0
- package/vendor/antd/es/notification/style/placement.js +117 -60
- package/vendor/antd/es/notification/useNotification.js +37 -40
- package/vendor/antd/es/notification/util.js +9 -50
- package/vendor/antd/es/pagination/Pagination.js +1 -2
- package/vendor/antd/es/pagination/useShowSizeChanger.js +2 -1
- package/vendor/antd/es/popconfirm/PurePanel.js +4 -1
- package/vendor/antd/es/popconfirm/index.js +1 -2
- package/vendor/antd/es/popover/PurePanel.js +1 -2
- package/vendor/antd/es/popover/index.js +1 -2
- package/vendor/antd/es/progress/Circle.js +2 -1
- package/vendor/antd/es/progress/progress.js +3 -3
- package/vendor/antd/es/progress/utils.js +4 -3
- package/vendor/antd/es/qr-code/index.js +4 -4
- package/vendor/antd/es/radio/group.js +4 -3
- package/vendor/antd/es/radio/radio.js +2 -2
- package/vendor/antd/es/radio/style/index.js +1 -1
- package/vendor/antd/es/rate/index.js +2 -4
- package/vendor/antd/es/result/index.js +6 -5
- package/vendor/antd/es/result/style/index.js +10 -6
- package/vendor/antd/es/segmented/index.js +5 -3
- package/vendor/antd/es/select/index.js +23 -12
- package/vendor/antd/es/select/style/dropdown.js +1 -1
- package/vendor/antd/es/select/style/select-input.js +23 -15
- package/vendor/antd/es/select/useIcons.js +43 -26
- package/vendor/antd/es/skeleton/Element.js +2 -1
- package/vendor/antd/es/skeleton/Skeleton.js +3 -3
- package/vendor/antd/es/slider/SliderTooltip.js +1 -0
- package/vendor/antd/es/slider/index.js +5 -3
- package/vendor/antd/es/slider/useRafLock.js +1 -0
- package/vendor/antd/es/space/Compact.js +1 -1
- package/vendor/antd/es/space/Item.js +1 -1
- package/vendor/antd/es/space/index.js +2 -2
- package/vendor/antd/es/space/style/addon.js +5 -2
- package/vendor/antd/es/spin/Indicator/Progress.js +2 -1
- package/vendor/antd/es/spin/index.js +1 -2
- package/vendor/antd/es/splitter/Panel.js +7 -3
- package/vendor/antd/es/splitter/SplitBar.js +5 -4
- package/vendor/antd/es/splitter/Splitter.js +9 -6
- package/vendor/antd/es/splitter/hooks/useItems.js +2 -1
- package/vendor/antd/es/splitter/hooks/useSizes.js +1 -1
- package/vendor/antd/es/splitter/style/index.js +8 -6
- package/vendor/antd/es/statistic/Number.js +8 -4
- package/vendor/antd/es/statistic/Statistic.js +14 -10
- package/vendor/antd/es/steps/index.js +4 -4
- package/vendor/antd/es/style/compact-item-vertical.js +2 -1
- package/vendor/antd/es/style/compact-item.js +6 -6
- package/vendor/antd/es/switch/index.js +1 -2
- package/vendor/antd/es/table/InternalTable.js +23 -14
- package/vendor/antd/es/table/hooks/useFilledColumns.js +23 -0
- package/vendor/antd/es/table/hooks/useFilter/FilterDropdown.js +22 -16
- package/vendor/antd/es/table/hooks/useFilter/FilterWrapper.js +1 -0
- package/vendor/antd/es/table/hooks/useFilter/index.js +34 -18
- package/vendor/antd/es/table/hooks/useLazyKVMap.js +2 -1
- package/vendor/antd/es/table/hooks/usePagination.js +7 -4
- package/vendor/antd/es/table/hooks/useSelection.js +32 -21
- package/vendor/antd/es/table/hooks/useSorter.js +10 -5
- package/vendor/antd/es/table/style/bordered.js +5 -27
- package/vendor/antd/es/table/style/empty.js +1 -4
- package/vendor/antd/es/table/style/index.js +1 -4
- package/vendor/antd/es/table/util.js +6 -6
- package/vendor/antd/es/tabs/hooks/useAnimateConfig.js +2 -1
- package/vendor/antd/es/tabs/index.js +1 -2
- package/vendor/antd/es/tag/CheckableTagGroup.js +8 -5
- package/vendor/antd/es/tag/hooks/useColor.js +4 -3
- package/vendor/antd/es/tag/index.js +13 -7
- package/vendor/antd/es/theme/themes/dark/colors.js +2 -1
- package/vendor/antd/es/theme/themes/default/colors.js +2 -1
- package/vendor/antd/es/theme/useToken.js +2 -2
- package/vendor/antd/es/theme/util/alias.js +34 -29
- package/vendor/antd/es/timeline/Timeline.js +3 -4
- package/vendor/antd/es/tooltip/PurePanel.js +1 -2
- package/vendor/antd/es/tooltip/UniqueProvider/index.js +2 -1
- package/vendor/antd/es/tooltip/index.js +9 -7
- package/vendor/antd/es/tour/PurePanel.js +2 -2
- package/vendor/antd/es/tour/index.js +1 -1
- package/vendor/antd/es/tour/panelRender.js +4 -2
- package/vendor/antd/es/transfer/ListBody.js +3 -1
- package/vendor/antd/es/transfer/ListItem.js +2 -1
- package/vendor/antd/es/transfer/Section.js +17 -8
- package/vendor/antd/es/transfer/index.js +51 -16
- package/vendor/antd/es/transfer/style/index.js +5 -1
- package/vendor/antd/es/tree/Tree.js +1 -2
- package/vendor/antd/es/tree/style/index.js +5 -1
- package/vendor/antd/es/tree/utils/iconUtil.js +5 -4
- package/vendor/antd/es/tree-select/index.js +3 -3
- package/vendor/antd/es/typography/Base/CopyBtn.js +3 -2
- package/vendor/antd/es/typography/Base/Ellipsis.js +3 -3
- package/vendor/antd/es/typography/Base/index.js +38 -31
- package/vendor/antd/es/typography/Editable.js +10 -4
- package/vendor/antd/es/typography/Link.js +1 -0
- package/vendor/antd/es/typography/Text.js +2 -1
- package/vendor/antd/es/typography/Typography.js +20 -10
- package/vendor/antd/es/typography/hooks/useCopyClick.js +2 -1
- package/vendor/antd/es/typography/hooks/useMergedConfig.js +13 -7
- package/vendor/antd/es/typography/hooks/useTooltipProps.js +2 -1
- package/vendor/antd/es/typography/hooks/useTypographySemantic.js +33 -0
- package/vendor/antd/es/typography/style/index.js +12 -27
- package/vendor/antd/es/typography/style/mixins.js +46 -13
- package/vendor/antd/es/upload/Upload.js +13 -7
- package/vendor/antd/es/upload/UploadList/ListItem.js +6 -5
- package/vendor/antd/es/upload/UploadList/index.js +4 -3
- package/vendor/antd/es/upload/utils.js +18 -1
- package/vendor/antd/es/version/version.js +1 -1
- package/vendor/antd/es/watermark/index.js +6 -4
- package/vendor/antd/es/watermark/useSingletonCache.js +1 -0
- package/vendor/antd/es/watermark/useWatermark.js +3 -3
- package/vendor/antd/package.json +1 -1
- package/vendor/useblocks-ui-kit/es/components/DataEntry/Input/index.js +1 -1
- package/vendor/useblocks-ui-kit/es/components/General/EmIcons/deprecationNotice.js +1 -1
- package/vendor/useblocks-ui-kit/package.json +1 -1
- package/vite/index.cjs +2 -2
- package/vite/index.js +2 -2
- package/iframe/js/discussHandlers.ozU2Hn_l.js +0 -87
- package/iframe/js/iframe.body.js +0 -319
- package/static/core/1c535081.js +0 -1
- package/static/core/1cee0d36.js +0 -1
- package/static/core/4fbdd8b6.js +0 -2
- package/static/core/55a38638.js +0 -93
- package/static/core/605c665e.js +0 -28
- package/static/core/68cbe23d.js +0 -1
- package/static/core/89431649.js +0 -7
- package/static/core/8b821a61.js +0 -1
- package/static/core/9718977a.js +0 -1
- package/static/core/b7e9202e.js +0 -27
- package/static/core/b877f7b4.js +0 -1
- package/static/core/baded0c1.js +0 -1
- package/static/core/c6cc104d.js +0 -4
- package/static/core/d70aac44.js +0 -291
- package/static/core/e0d71533.js +0 -100
- package/static/core/fb57f60b.js +0 -1
- package/static/core/fe756e4d.js +0 -1
- package/static/esm/349f9e2c.js +0 -1
- package/static/esm/50fbfdf6.js +0 -1
- package/static/media/icon-sets/lucide.json +0 -6275
- package/static/media/icon-sets/tabler.json +0 -19336
- package/static/umd-runtime/Cl8heeC3.js +0 -1
- package/static/umd-runtime/D0xo8o9c.js +0 -335
- package/static/umd-runtime/runtime.js +0 -1
- package/useblocks-core.bb6d921f.js +0 -859
- package/vendor/@rc-component/notification/es/Notice.js +0 -106
- package/vendor/@rc-component/notification/es/NoticeList.js +0 -98
- package/vendor/@rc-component/textarea/LICENSE.md +0 -9
- package/vendor/@rc-component/textarea/es/index.js +0 -6
- package/vendor/@rc-component/textarea/package.json +0 -6
- package/vendor/antd/es/_util/extendsObject.js +0 -12
- package/vendor/antd/es/_util/getAllowClear.js +0 -12
- package/vendor/antd/es/_util/isNonNullable.js +0 -6
- package/vendor/antd/es/_util/isPrimitive.js +0 -4
- package/vendor/antd/es/notification/style/pure-panel.js +0 -18
- package/vendor/antd/es/notification/style/stack.js +0 -85
- /package/static/monaco/{index.js → index.CO7s5UdA.js} +0 -0
- /package/static/umd-runtime/{delivery-libs.js → delivery-libs.3Svr0avG.js} +0 -0
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { clsx } from "../../../clsx/dist/clsx.js";
|
|
3
3
|
import { useComponentConfig } from "../config-provider/context.js";
|
|
4
|
-
import {
|
|
5
|
-
import "../_util/hooks/index.js";
|
|
4
|
+
import { isPlainObject } from "../_util/is.js";
|
|
5
|
+
import { useMergeSemantic } from "../_util/hooks/useMergeSemantic/index.js";
|
|
6
6
|
import Element from "./Element.js";
|
|
7
7
|
import style_default from "./style/index.js";
|
|
8
8
|
import SkeletonAvatar from "./Avatar.js";
|
|
@@ -15,7 +15,7 @@ import Title from "./Title.js";
|
|
|
15
15
|
import * as React$1 from "../../../react/index.js";
|
|
16
16
|
//#region node_modules/antd/es/skeleton/Skeleton.js
|
|
17
17
|
function getComponentProps(prop) {
|
|
18
|
-
if (prop
|
|
18
|
+
if (isPlainObject(prop)) return prop;
|
|
19
19
|
return {};
|
|
20
20
|
}
|
|
21
21
|
function getAvatarBasicProps(hasTitle, hasParagraph) {
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { composeRef } from "../../../@rc-component/util/es/ref.js";
|
|
3
3
|
import wrapperRaf from "../../../@rc-component/util/es/raf.js";
|
|
4
|
+
import "../../../@rc-component/util/es/index.js";
|
|
4
5
|
import Tooltip from "../tooltip/index.js";
|
|
5
6
|
import * as React$1 from "../../../react/index.js";
|
|
6
7
|
import { useRef } from "../../../react/index.js";
|
|
@@ -1,12 +1,14 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import wrapperRaf from "../../../@rc-component/util/es/raf.js";
|
|
3
|
+
import "../../../@rc-component/util/es/index.js";
|
|
3
4
|
import { clsx } from "../../../clsx/dist/clsx.js";
|
|
4
5
|
import { useComponentConfig } from "../config-provider/context.js";
|
|
6
|
+
import { isNumber } from "../_util/is.js";
|
|
7
|
+
import { useMergeSemantic } from "../_util/hooks/useMergeSemantic/index.js";
|
|
5
8
|
import "../_util/warning.js";
|
|
6
|
-
import
|
|
9
|
+
import DisabledContext from "../config-provider/DisabledContext.js";
|
|
7
10
|
import { useOrientation } from "../_util/hooks/useOrientation.js";
|
|
8
11
|
import "../_util/hooks/index.js";
|
|
9
|
-
import DisabledContext from "../config-provider/DisabledContext.js";
|
|
10
12
|
import es_default from "../../../@rc-component/slider/es/index.js";
|
|
11
13
|
import SliderInternalContext from "./Context.js";
|
|
12
14
|
import SliderTooltip from "./SliderTooltip.js";
|
|
@@ -16,7 +18,7 @@ import React from "../../../react/index.js";
|
|
|
16
18
|
//#region node_modules/antd/es/slider/index.js
|
|
17
19
|
function getTipFormatter(tipFormatter) {
|
|
18
20
|
if (tipFormatter || tipFormatter === null) return tipFormatter;
|
|
19
|
-
return (val) =>
|
|
21
|
+
return (val) => isNumber(val) ? val.toString() : "";
|
|
20
22
|
}
|
|
21
23
|
const Slider = /*#__PURE__*/ React.forwardRef((props, ref) => {
|
|
22
24
|
const { prefixCls: customizePrefixCls, range, className, rootClassName, style, disabled, tooltip = {}, onChangeComplete, classNames, styles, vertical, orientation, ...restProps } = props;
|
|
@@ -4,9 +4,9 @@ import "../../../@rc-component/util/es/index.js";
|
|
|
4
4
|
import { clsx } from "../../../clsx/dist/clsx.js";
|
|
5
5
|
import { ConfigContext } from "../config-provider/context.js";
|
|
6
6
|
import "../_util/warning.js";
|
|
7
|
+
import "../config-provider/index.js";
|
|
7
8
|
import { useOrientation } from "../_util/hooks/useOrientation.js";
|
|
8
9
|
import "../_util/hooks/index.js";
|
|
9
|
-
import "../config-provider/index.js";
|
|
10
10
|
import useSize from "../config-provider/hooks/useSize.js";
|
|
11
11
|
import compact_default from "./style/compact.js";
|
|
12
12
|
import * as React$1 from "../../../react/index.js";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { clsx } from "../../../clsx/dist/clsx.js";
|
|
3
|
-
import isNonNullable from "../_util/
|
|
3
|
+
import { isNonNullable } from "../_util/is.js";
|
|
4
4
|
import { SpaceContext } from "./context.js";
|
|
5
5
|
import * as React$1 from "../../../react/index.js";
|
|
6
6
|
//#region node_modules/antd/es/space/Item.js
|
|
@@ -3,9 +3,9 @@ import toArray from "../../../@rc-component/util/es/Children/toArray.js";
|
|
|
3
3
|
import "../../../@rc-component/util/es/index.js";
|
|
4
4
|
import { clsx } from "../../../clsx/dist/clsx.js";
|
|
5
5
|
import { useComponentConfig } from "../config-provider/context.js";
|
|
6
|
+
import { isNonNullable } from "../_util/is.js";
|
|
7
|
+
import { useMergeSemantic } from "../_util/hooks/useMergeSemantic/index.js";
|
|
6
8
|
import "../_util/warning.js";
|
|
7
|
-
import isNonNullable from "../_util/isNonNullable.js";
|
|
8
|
-
import { useMergeSemantic } from "../_util/hooks/useMergeSemantic.js";
|
|
9
9
|
import { useOrientation } from "../_util/hooks/useOrientation.js";
|
|
10
10
|
import "../_util/hooks/index.js";
|
|
11
11
|
import Compact from "./Compact.js";
|
|
@@ -1,15 +1,18 @@
|
|
|
1
|
+
import { resetComponent } from "../../style/index.js";
|
|
1
2
|
import { genCssVar, genStyleHooks } from "../../theme/util/genStyleUtils.js";
|
|
2
3
|
import "../../theme/internal.js";
|
|
3
4
|
import { genCompactItemStyle } from "../../style/compact-item.js";
|
|
4
5
|
//#region node_modules/antd/es/space/style/addon.js
|
|
5
6
|
const genSpaceAddonStyle = (token) => {
|
|
6
7
|
const { componentCls, borderRadius, paddingSM, colorBorder, paddingXS, fontSizeLG, fontSizeSM, borderRadiusLG, borderRadiusSM, colorBgContainerDisabled, lineWidth, antCls } = token;
|
|
7
|
-
const [varName, varRef] = genCssVar(antCls, "space");
|
|
8
|
+
const [varName, varRef] = genCssVar(antCls, "space-addon");
|
|
8
9
|
return { [componentCls]: [
|
|
9
10
|
{
|
|
11
|
+
...resetComponent(token),
|
|
10
12
|
display: "inline-flex",
|
|
11
13
|
alignItems: "center",
|
|
12
14
|
gap: 0,
|
|
15
|
+
whiteSpace: "nowrap",
|
|
13
16
|
paddingInline: paddingSM,
|
|
14
17
|
margin: 0,
|
|
15
18
|
borderWidth: lineWidth,
|
|
@@ -77,6 +80,6 @@ const genSpaceAddonStyle = (token) => {
|
|
|
77
80
|
}
|
|
78
81
|
] };
|
|
79
82
|
};
|
|
80
|
-
var addon_default = genStyleHooks(
|
|
83
|
+
var addon_default = genStyleHooks("Addon", (token) => [genSpaceAddonStyle(token), genCompactItemStyle(token, { focus: false })]);
|
|
81
84
|
//#endregion
|
|
82
85
|
export { addon_default as default };
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import useLayoutEffect$1 from "../../../../@rc-component/util/es/hooks/useLayoutEffect.js";
|
|
3
|
+
import "../../../../@rc-component/util/es/index.js";
|
|
3
4
|
import { clsx } from "../../../../clsx/dist/clsx.js";
|
|
4
5
|
import * as React$1 from "../../../../react/index.js";
|
|
5
6
|
//#region node_modules/antd/es/spin/Indicator/Progress.js
|
|
@@ -33,7 +34,7 @@ const Progress = ({ percent, prefixCls }) => {
|
|
|
33
34
|
strokeDashoffset: `${circumference / 4}`,
|
|
34
35
|
strokeDasharray: `${circumference * safePtg / 100} ${circumference * (100 - safePtg) / 100}`
|
|
35
36
|
};
|
|
36
|
-
return /*#__PURE__*/ React$1.createElement("span", { className: clsx(holderClassName, `${dotClassName}-progress`, safePtg <= 0
|
|
37
|
+
return /*#__PURE__*/ React$1.createElement("span", { className: clsx(holderClassName, `${dotClassName}-progress`, { [hideClassName]: safePtg <= 0 }) }, /*#__PURE__*/ React$1.createElement("svg", {
|
|
37
38
|
viewBox: `0 0 ${viewSize} ${viewSize}`,
|
|
38
39
|
role: "progressbar",
|
|
39
40
|
"aria-valuemin": 0,
|
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { clsx } from "../../../clsx/dist/clsx.js";
|
|
3
3
|
import { useComponentConfig } from "../config-provider/context.js";
|
|
4
|
+
import { useMergeSemantic } from "../_util/hooks/useMergeSemantic/index.js";
|
|
4
5
|
import "../_util/warning.js";
|
|
5
|
-
import { useMergeSemantic } from "../_util/hooks/useMergeSemantic.js";
|
|
6
|
-
import "../_util/hooks/index.js";
|
|
7
6
|
import useSize from "../config-provider/hooks/useSize.js";
|
|
8
7
|
import { debounce } from "../../../throttle-debounce/esm/index.js";
|
|
9
8
|
import Indicator from "./Indicator/index.js";
|
|
@@ -3,8 +3,12 @@ import { clsx } from "../../../clsx/dist/clsx.js";
|
|
|
3
3
|
import React, { forwardRef } from "../../../react/index.js";
|
|
4
4
|
//#region node_modules/antd/es/splitter/Panel.js
|
|
5
5
|
const InternalPanel = /*#__PURE__*/ forwardRef((props, ref) => {
|
|
6
|
-
const { prefixCls, className, children, size, style
|
|
7
|
-
const
|
|
6
|
+
const { prefixCls, className, children, destroyOnHidden = false, size, style, supportMotion } = props;
|
|
7
|
+
const isCollapsed = size === 0 || typeof size === "string" && Number.parseFloat(size) === 0;
|
|
8
|
+
const panelClassName = clsx(`${prefixCls}-panel`, {
|
|
9
|
+
[`${prefixCls}-panel-hidden`]: isCollapsed,
|
|
10
|
+
[`${prefixCls}-panel-transition`]: supportMotion
|
|
11
|
+
}, className);
|
|
8
12
|
const hasSize = size !== void 0;
|
|
9
13
|
return /*#__PURE__*/ React.createElement("div", {
|
|
10
14
|
ref,
|
|
@@ -14,7 +18,7 @@ const InternalPanel = /*#__PURE__*/ forwardRef((props, ref) => {
|
|
|
14
18
|
flexBasis: hasSize ? size : "auto",
|
|
15
19
|
flexGrow: hasSize ? 0 : 1
|
|
16
20
|
}
|
|
17
|
-
}, children);
|
|
21
|
+
}, !(destroyOnHidden && isCollapsed) && children);
|
|
18
22
|
});
|
|
19
23
|
const Panel = () => null;
|
|
20
24
|
//#endregion
|
|
@@ -4,15 +4,16 @@ import useLayoutEffect$1 from "../../../@rc-component/util/es/hooks/useLayoutEff
|
|
|
4
4
|
import "../../../@rc-component/util/es/index.js";
|
|
5
5
|
import { clsx } from "../../../clsx/dist/clsx.js";
|
|
6
6
|
import { genCssVar } from "../theme/util/genStyleUtils.js";
|
|
7
|
+
import { isNumber } from "../_util/is.js";
|
|
7
8
|
import RefIcon from "../../../@ant-design/icons/es/icons/RightOutlined.js";
|
|
8
9
|
import RefIcon$1 from "../../../@ant-design/icons/es/icons/DownOutlined.js";
|
|
9
10
|
import RefIcon$2 from "../../../@ant-design/icons/es/icons/LeftOutlined.js";
|
|
10
11
|
import RefIcon$3 from "../../../@ant-design/icons/es/icons/UpOutlined.js";
|
|
11
12
|
import React, { useRef, useState } from "../../../react/index.js";
|
|
12
13
|
//#region node_modules/antd/es/splitter/SplitBar.js
|
|
13
|
-
|
|
14
|
-
return
|
|
15
|
-
}
|
|
14
|
+
const getValidNumber = (num) => {
|
|
15
|
+
return isNumber(num) && Number.isFinite(num) ? Math.round(num) : 0;
|
|
16
|
+
};
|
|
16
17
|
const DOUBLE_CLICK_TIME_GAP = 300;
|
|
17
18
|
const SplitBar = (props) => {
|
|
18
19
|
const { prefixCls, rootPrefixCls, vertical, index, active, ariaNow, ariaMin, ariaMax, resizable, draggerIcon, draggerStyle, draggerClassName, collapsibleIcon, startCollapsible, endCollapsible, onDraggerDoubleClick, onOffsetStart, onOffsetUpdate, onOffsetEnd, onCollapse, lazy, containerSize, showStartCollapsibleIcon, showEndCollapsibleIcon } = props;
|
|
@@ -137,7 +138,7 @@ const SplitBar = (props) => {
|
|
|
137
138
|
className: clsx(`${splitBarPrefixCls}-preview`, { [`${splitBarPrefixCls}-preview-active`]: !!constrainedOffset }),
|
|
138
139
|
style: transformStyle
|
|
139
140
|
}), /*#__PURE__*/ React.createElement("div", {
|
|
140
|
-
style: draggerStyle,
|
|
141
|
+
style: draggerStyle?.default,
|
|
141
142
|
className: clsx(`${splitBarPrefixCls}-dragger`, {
|
|
142
143
|
[`${splitBarPrefixCls}-dragger-disabled`]: !resizable,
|
|
143
144
|
[`${splitBarPrefixCls}-dragger-active`]: active,
|
|
@@ -4,11 +4,12 @@ import "../../../@rc-component/util/es/index.js";
|
|
|
4
4
|
import RefResizeObserver from "../../../@rc-component/resize-observer/es/index.js";
|
|
5
5
|
import { clsx } from "../../../clsx/dist/clsx.js";
|
|
6
6
|
import { useComponentConfig } from "../config-provider/context.js";
|
|
7
|
+
import { isNumber } from "../_util/is.js";
|
|
8
|
+
import { useMergeSemantic } from "../_util/hooks/useMergeSemantic/index.js";
|
|
7
9
|
import "../_util/warning.js";
|
|
8
|
-
import
|
|
10
|
+
import useCSSVarCls from "../config-provider/hooks/useCSSVarCls.js";
|
|
9
11
|
import { useOrientation } from "../_util/hooks/useOrientation.js";
|
|
10
12
|
import "../_util/hooks/index.js";
|
|
11
|
-
import useCSSVarCls from "../config-provider/hooks/useCSSVarCls.js";
|
|
12
13
|
import { InternalPanel } from "./Panel.js";
|
|
13
14
|
import useItems from "./hooks/useItems.js";
|
|
14
15
|
import useResizable from "./hooks/useResizable.js";
|
|
@@ -19,7 +20,7 @@ import style_default from "./style/index.js";
|
|
|
19
20
|
import React, { useState } from "../../../react/index.js";
|
|
20
21
|
//#region node_modules/antd/es/splitter/Splitter.js
|
|
21
22
|
const Splitter = (props) => {
|
|
22
|
-
const { prefixCls: customizePrefixCls, className, classNames, style, styles, layout, orientation, vertical, children, draggerIcon, collapsibleIcon, rootClassName, onDraggerDoubleClick, onResizeStart, onResize, onResizeEnd, lazy } = props;
|
|
23
|
+
const { prefixCls: customizePrefixCls, className, classNames, collapsible, style, styles, layout, orientation, vertical, children, destroyOnHidden, draggerIcon, collapsibleIcon, rootClassName, onDraggerDoubleClick, onResizeStart, onResize, onResizeEnd, lazy } = props;
|
|
23
24
|
const { getPrefixCls, direction, className: contextClassName, style: contextStyle, classNames: contextClassNames, styles: contextStyles } = useComponentConfig("splitter");
|
|
24
25
|
const prefixCls = getPrefixCls("splitter", customizePrefixCls);
|
|
25
26
|
const rootPrefixCls = getPrefixCls();
|
|
@@ -97,7 +98,9 @@ const Splitter = (props) => {
|
|
|
97
98
|
const panel = /*#__PURE__*/ React.createElement(InternalPanel, {
|
|
98
99
|
...panelProps,
|
|
99
100
|
prefixCls,
|
|
100
|
-
size: panelSizes[idx]
|
|
101
|
+
size: panelSizes[idx],
|
|
102
|
+
supportMotion: collapsible?.motion && movingIndex === void 0,
|
|
103
|
+
destroyOnHidden: item.destroyOnHidden ?? destroyOnHidden
|
|
101
104
|
});
|
|
102
105
|
let splitBar = null;
|
|
103
106
|
const resizableInfo = resizableInfos[idx];
|
|
@@ -117,7 +120,7 @@ const Splitter = (props) => {
|
|
|
117
120
|
draggerStyle: mergedStyles.dragger,
|
|
118
121
|
draggerClassName: mergedClassNames.dragger,
|
|
119
122
|
draggerIcon,
|
|
120
|
-
collapsibleIcon,
|
|
123
|
+
collapsibleIcon: collapsible?.icon || collapsibleIcon,
|
|
121
124
|
ariaNow: stackSizes[idx] * 100,
|
|
122
125
|
ariaMin: Math.max(ariaMinStart, ariaMinEnd) * 100,
|
|
123
126
|
ariaMax: Math.min(ariaMaxStart, ariaMaxEnd) * 100,
|
|
@@ -138,7 +141,7 @@ const Splitter = (props) => {
|
|
|
138
141
|
});
|
|
139
142
|
}
|
|
140
143
|
return /*#__PURE__*/ React.createElement(React.Fragment, { key: `split-panel-${idx}` }, panel, splitBar);
|
|
141
|
-
}),
|
|
144
|
+
}), isNumber(movingIndex) && /*#__PURE__*/ React.createElement("div", {
|
|
142
145
|
"aria-hidden": true,
|
|
143
146
|
className: clsx(maskCls, `${maskCls}-${mergedOrientation}`)
|
|
144
147
|
})));
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import toArray from "../../../../@rc-component/util/es/Children/toArray.js";
|
|
2
2
|
import "../../../../@rc-component/util/es/index.js";
|
|
3
|
+
import { isPlainObject } from "../../_util/is.js";
|
|
3
4
|
import * as React$1 from "../../../../react/index.js";
|
|
4
5
|
//#region node_modules/antd/es/splitter/hooks/useItems.js
|
|
5
6
|
function getCollapsible(collapsible) {
|
|
6
|
-
if (collapsible
|
|
7
|
+
if (isPlainObject(collapsible)) return {
|
|
7
8
|
...collapsible,
|
|
8
9
|
showCollapsibleIcon: collapsible.showCollapsibleIcon === void 0 ? "auto" : collapsible.showCollapsibleIcon
|
|
9
10
|
};
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import { resetComponent } from "../../style/index.js";
|
|
2
2
|
import { genCssVar, genStyleHooks } from "../../theme/util/genStyleUtils.js";
|
|
3
3
|
import "../../theme/internal.js";
|
|
4
|
+
import { genNoMotionStyle } from "../../style/motion/util.js";
|
|
5
|
+
import "../../style/motion/index.js";
|
|
4
6
|
//#region node_modules/antd/es/splitter/style/index.js
|
|
5
7
|
const centerStyle = {
|
|
6
8
|
position: "absolute",
|
|
@@ -205,14 +207,14 @@ const genSplitterStyle = (token) => {
|
|
|
205
207
|
},
|
|
206
208
|
[splitPanelCls]: {
|
|
207
209
|
overflow: "auto",
|
|
208
|
-
padding: "0 1px",
|
|
209
210
|
scrollbarWidth: "thin",
|
|
210
211
|
boxSizing: "border-box",
|
|
211
|
-
"&-hidden": {
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
212
|
+
"&-hidden": { overflow: "hidden" },
|
|
213
|
+
[`&:has(${componentCls}:only-child)`]: { overflow: "hidden" },
|
|
214
|
+
"&-transition": {
|
|
215
|
+
transition: `flex-basis ${token.motionDurationSlow} ${token.motionEaseInOut}`,
|
|
216
|
+
...genNoMotionStyle()
|
|
217
|
+
}
|
|
216
218
|
}
|
|
217
219
|
} };
|
|
218
220
|
};
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
"use client";
|
|
2
|
+
import { isFunction, isNumber } from "../_util/is.js";
|
|
2
3
|
import * as React$1 from "../../../react/index.js";
|
|
3
4
|
//#region node_modules/antd/es/statistic/Number.js
|
|
4
5
|
const StatisticNumber = (props) => {
|
|
5
|
-
const { value, formatter, precision, decimalSeparator, groupSeparator = "", prefixCls } = props;
|
|
6
|
+
const { value, formatter, precision, decimalSeparator, groupSeparator = "", prefixCls, className, style } = props;
|
|
6
7
|
let valueNode;
|
|
7
|
-
if (
|
|
8
|
+
if (isFunction(formatter)) valueNode = formatter(value);
|
|
8
9
|
else {
|
|
9
10
|
const val = String(value);
|
|
10
11
|
const cells = val.match(/^(-?)(\d*)(\.(\d+))?$/);
|
|
@@ -14,7 +15,7 @@ const StatisticNumber = (props) => {
|
|
|
14
15
|
let int = cells[2] || "0";
|
|
15
16
|
let decimal = cells[4] || "";
|
|
16
17
|
int = int.replace(/\B(?=(\d{3})+(?!\d))/g, groupSeparator);
|
|
17
|
-
if (
|
|
18
|
+
if (isNumber(precision)) decimal = decimal.padEnd(precision, "0").slice(0, precision > 0 ? precision : 0);
|
|
18
19
|
if (decimal) decimal = `${decimalSeparator}${decimal}`;
|
|
19
20
|
valueNode = [/*#__PURE__*/ React$1.createElement("span", {
|
|
20
21
|
key: "int",
|
|
@@ -25,7 +26,10 @@ const StatisticNumber = (props) => {
|
|
|
25
26
|
}, decimal)];
|
|
26
27
|
}
|
|
27
28
|
}
|
|
28
|
-
return /*#__PURE__*/ React$1.createElement("span", {
|
|
29
|
+
return /*#__PURE__*/ React$1.createElement("span", {
|
|
30
|
+
className,
|
|
31
|
+
style
|
|
32
|
+
}, valueNode);
|
|
29
33
|
};
|
|
30
34
|
//#endregion
|
|
31
35
|
export { StatisticNumber as default };
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import pickAttrs from "../../../@rc-component/util/es/pickAttrs.js";
|
|
3
|
+
import "../../../@rc-component/util/es/index.js";
|
|
3
4
|
import { clsx } from "../../../clsx/dist/clsx.js";
|
|
4
5
|
import { useComponentConfig } from "../config-provider/context.js";
|
|
6
|
+
import { isFunction } from "../_util/is.js";
|
|
7
|
+
import { useMergeSemantic } from "../_util/hooks/useMergeSemantic/index.js";
|
|
5
8
|
import "../_util/warning.js";
|
|
6
|
-
import { useMergeSemantic } from "../_util/hooks/useMergeSemantic.js";
|
|
7
|
-
import "../_util/hooks/index.js";
|
|
8
9
|
import skeleton_default from "../skeleton/index.js";
|
|
9
10
|
import StatisticNumber from "./Number.js";
|
|
10
11
|
import style_default from "./style/index.js";
|
|
@@ -23,20 +24,23 @@ const Statistic = /*#__PURE__*/ React$1.forwardRef((props, ref) => {
|
|
|
23
24
|
value
|
|
24
25
|
};
|
|
25
26
|
const [mergedClassNames, mergedStyles] = useMergeSemantic([contextClassNames, classNames], [contextStyles, styles], { props: mergedProps });
|
|
27
|
+
const rootClassNames = clsx(prefixCls, { [`${prefixCls}-rtl`]: direction === "rtl" }, contextClassName, className, rootClassName, mergedClassNames.root, hashId, cssVarCls);
|
|
28
|
+
const headerClassNames = clsx(`${prefixCls}-header`, mergedClassNames.header);
|
|
29
|
+
const titleClassNames = clsx(`${prefixCls}-title`, mergedClassNames.title);
|
|
30
|
+
const contentClassNames = clsx(`${prefixCls}-content`, mergedClassNames.content);
|
|
31
|
+
const valueClassNames = clsx(`${prefixCls}-content-value`, mergedClassNames.value);
|
|
32
|
+
const prefixClassNames = clsx(`${prefixCls}-content-prefix`, mergedClassNames.prefix);
|
|
33
|
+
const suffixClassNames = clsx(`${prefixCls}-content-suffix`, mergedClassNames.suffix);
|
|
26
34
|
const valueNode = /*#__PURE__*/ React$1.createElement(StatisticNumber, {
|
|
27
35
|
decimalSeparator,
|
|
28
36
|
groupSeparator,
|
|
29
37
|
prefixCls,
|
|
30
38
|
formatter,
|
|
31
39
|
precision,
|
|
32
|
-
value
|
|
40
|
+
value,
|
|
41
|
+
className: valueClassNames,
|
|
42
|
+
style: mergedStyles.value
|
|
33
43
|
});
|
|
34
|
-
const rootClassNames = clsx(prefixCls, { [`${prefixCls}-rtl`]: direction === "rtl" }, contextClassName, className, rootClassName, mergedClassNames.root, hashId, cssVarCls);
|
|
35
|
-
const headerClassNames = clsx(`${prefixCls}-header`, mergedClassNames.header);
|
|
36
|
-
const titleClassNames = clsx(`${prefixCls}-title`, mergedClassNames.title);
|
|
37
|
-
const contentClassNames = clsx(`${prefixCls}-content`, mergedClassNames.content);
|
|
38
|
-
const prefixClassNames = clsx(`${prefixCls}-content-prefix`, mergedClassNames.prefix);
|
|
39
|
-
const suffixClassNames = clsx(`${prefixCls}-content-suffix`, mergedClassNames.suffix);
|
|
40
44
|
const internalRef = React$1.useRef(null);
|
|
41
45
|
React$1.useImperativeHandle(ref, () => ({ nativeElement: internalRef.current }));
|
|
42
46
|
const restProps = pickAttrs(rest, {
|
|
@@ -74,7 +78,7 @@ const Statistic = /*#__PURE__*/ React$1.forwardRef((props, ref) => {
|
|
|
74
78
|
}, prefix && /*#__PURE__*/ React$1.createElement("span", {
|
|
75
79
|
className: prefixClassNames,
|
|
76
80
|
style: mergedStyles.prefix
|
|
77
|
-
}, prefix), valueRender ? valueRender(valueNode) : valueNode, suffix && /*#__PURE__*/ React$1.createElement("span", {
|
|
81
|
+
}, prefix), isFunction(valueRender) ? valueRender(valueNode) : valueNode, suffix && /*#__PURE__*/ React$1.createElement("span", {
|
|
78
82
|
className: suffixClassNames,
|
|
79
83
|
style: mergedStyles.suffix
|
|
80
84
|
}, suffix))));
|
|
@@ -3,9 +3,9 @@ import { clsx } from "../../../clsx/dist/clsx.js";
|
|
|
3
3
|
import { useComponentConfig } from "../config-provider/context.js";
|
|
4
4
|
import { genCssVar } from "../theme/util/genStyleUtils.js";
|
|
5
5
|
import RefIcon from "../../../@ant-design/icons/es/icons/CloseOutlined.js";
|
|
6
|
+
import { isFunction } from "../_util/is.js";
|
|
7
|
+
import { useMergeSemantic } from "../_util/hooks/useMergeSemantic/index.js";
|
|
6
8
|
import "../_util/warning.js";
|
|
7
|
-
import { useMergeSemantic } from "../_util/hooks/useMergeSemantic.js";
|
|
8
|
-
import "../_util/hooks/index.js";
|
|
9
9
|
import { TARGET_CLS } from "../_util/wave/interface.js";
|
|
10
10
|
import Wave from "../_util/wave/index.js";
|
|
11
11
|
import useSize from "../config-provider/hooks/useSize.js";
|
|
@@ -49,7 +49,7 @@ const Steps = (props) => {
|
|
|
49
49
|
const isInline = mergedType === "inline";
|
|
50
50
|
const isDot = mergedType === "dot" || mergedType === "inline";
|
|
51
51
|
const legacyProgressDotRender = React$1.useMemo(() => {
|
|
52
|
-
return mergedType === "dot" &&
|
|
52
|
+
return mergedType === "dot" && isFunction(progressDot) ? progressDot : void 0;
|
|
53
53
|
}, [mergedType, progressDot]);
|
|
54
54
|
const mergedOrientation = React$1.useMemo(() => {
|
|
55
55
|
const nextOrientation = orientation || direction;
|
|
@@ -120,7 +120,7 @@ const Steps = (props) => {
|
|
|
120
120
|
item,
|
|
121
121
|
components: { Icon: StepIcon }
|
|
122
122
|
});
|
|
123
|
-
else if (
|
|
123
|
+
else if (isFunction(legacyProgressDotRender)) iconNode = legacyProgressDotRender(iconNode, {
|
|
124
124
|
index,
|
|
125
125
|
...item
|
|
126
126
|
});
|
|
@@ -4,7 +4,8 @@ function compactItemVerticalBorder(token, parentCls, prefixCls) {
|
|
|
4
4
|
[`&-item:not(${parentCls}-last-item)`]: { marginBottom: token.calc(token.lineWidth).mul(-1).equal() },
|
|
5
5
|
[`&-item:not(${prefixCls}-status-success)`]: { zIndex: 2 },
|
|
6
6
|
"&-item": {
|
|
7
|
-
"&:
|
|
7
|
+
"&:focus,&:active": { zIndex: 3 },
|
|
8
|
+
"&:hover": { zIndex: 4 },
|
|
8
9
|
"&[disabled]": { zIndex: 0 }
|
|
9
10
|
}
|
|
10
11
|
};
|
|
@@ -2,16 +2,16 @@
|
|
|
2
2
|
function compactItemBorder(token, parentCls, options, prefixCls) {
|
|
3
3
|
const { focusElCls, focus, borderElCls } = options;
|
|
4
4
|
const childCombinator = borderElCls ? "> *" : "";
|
|
5
|
-
const
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
].filter(Boolean).map((n) => `&:${n} ${childCombinator}`).join(",");
|
|
5
|
+
const suffix = childCombinator ? ` ${childCombinator}` : "";
|
|
6
|
+
const genEffects = (effects) => effects.filter(Boolean).map((n) => `&:${n}${suffix}`).join(",");
|
|
7
|
+
const hoverEffects = genEffects(["hover", focusElCls ? `hover${focusElCls}` : null]);
|
|
8
|
+
const focusEffects = genEffects([focus ? "focus" : null, "active"]);
|
|
10
9
|
return {
|
|
11
10
|
[`&-item:not(${parentCls}-last-item)`]: { marginInlineEnd: token.calc(token.lineWidth).mul(-1).equal() },
|
|
12
11
|
[`&-item:not(${prefixCls}-status-success)`]: { zIndex: 2 },
|
|
13
12
|
"&-item": {
|
|
14
|
-
[
|
|
13
|
+
[focusEffects]: { zIndex: 3 },
|
|
14
|
+
[hoverEffects]: { zIndex: 4 },
|
|
15
15
|
...focusElCls ? { [`&${focusElCls}`]: { zIndex: 3 } } : {},
|
|
16
16
|
[`&[disabled] ${childCombinator}`]: { zIndex: 0 }
|
|
17
17
|
}
|
|
@@ -3,9 +3,8 @@ import useControlledState from "../../../@rc-component/util/es/hooks/useControll
|
|
|
3
3
|
import "../../../@rc-component/util/es/index.js";
|
|
4
4
|
import { clsx } from "../../../clsx/dist/clsx.js";
|
|
5
5
|
import { useComponentConfig } from "../config-provider/context.js";
|
|
6
|
+
import { useMergeSemantic } from "../_util/hooks/useMergeSemantic/index.js";
|
|
6
7
|
import "../_util/warning.js";
|
|
7
|
-
import { useMergeSemantic } from "../_util/hooks/useMergeSemantic.js";
|
|
8
|
-
import "../_util/hooks/index.js";
|
|
9
8
|
import DisabledContext from "../config-provider/DisabledContext.js";
|
|
10
9
|
import RefIcon from "../../../@ant-design/icons/es/icons/LoadingOutlined.js";
|
|
11
10
|
import Wave from "../_util/wave/index.js";
|
|
@@ -5,16 +5,17 @@ import { clsx } from "../../../clsx/dist/clsx.js";
|
|
|
5
5
|
import { ConfigContext, useComponentConfig } from "../config-provider/context.js";
|
|
6
6
|
import useToken from "../theme/useToken.js";
|
|
7
7
|
import "../theme/internal.js";
|
|
8
|
+
import { isFunction, isNumber, isPlainObject } from "../_util/is.js";
|
|
9
|
+
import { useMergeSemantic } from "../_util/hooks/useMergeSemantic/index.js";
|
|
8
10
|
import { devUseWarning } from "../_util/warning.js";
|
|
11
|
+
import scrollTo from "../_util/scrollTo.js";
|
|
12
|
+
import useCSSVarCls from "../config-provider/hooks/useCSSVarCls.js";
|
|
9
13
|
import localeValues from "../locale/en_US.js";
|
|
10
14
|
import useLocale from "../locale/useLocale.js";
|
|
11
15
|
import "../locale/index.js";
|
|
12
|
-
import
|
|
16
|
+
import ConfigProvider from "../config-provider/index.js";
|
|
13
17
|
import { useProxyImperativeHandle } from "../_util/hooks/useProxyImperativeHandle.js";
|
|
14
18
|
import "../_util/hooks/index.js";
|
|
15
|
-
import scrollTo from "../_util/scrollTo.js";
|
|
16
|
-
import useCSSVarCls from "../config-provider/hooks/useCSSVarCls.js";
|
|
17
|
-
import ConfigProvider from "../config-provider/index.js";
|
|
18
19
|
import useSize from "../config-provider/hooks/useSize.js";
|
|
19
20
|
import DefaultRenderEmpty from "../config-provider/defaultRenderEmpty.js";
|
|
20
21
|
import useBreakpoint from "../grid/hooks/useBreakpoint.js";
|
|
@@ -27,6 +28,7 @@ import "../../../@rc-component/table/es/index.js";
|
|
|
27
28
|
import useSelection from "./hooks/useSelection.js";
|
|
28
29
|
import renderExpandIcon from "./ExpandIcon.js";
|
|
29
30
|
import useContainerWidth from "./hooks/useContainerWidth.js";
|
|
31
|
+
import useFilledColumns from "./hooks/useFilledColumns.js";
|
|
30
32
|
import useFilter, { getFilterData } from "./hooks/useFilter/index.js";
|
|
31
33
|
import useLazyKVMap from "./hooks/useLazyKVMap.js";
|
|
32
34
|
import usePagination, { getPaginationParam } from "./hooks/usePagination.js";
|
|
@@ -39,9 +41,10 @@ import * as React$1 from "../../../react/index.js";
|
|
|
39
41
|
//#region node_modules/antd/es/table/InternalTable.js
|
|
40
42
|
const EMPTY_LIST = [];
|
|
41
43
|
const InternalTable = (props, ref) => {
|
|
42
|
-
const { prefixCls: customizePrefixCls, className, rootClassName, style, classNames, styles, size: customizeSize, bordered, dropdownPrefixCls: customizeDropdownPrefixCls, dataSource, pagination, rowSelection, rowKey: customizeRowKey, rowClassName, columns, children, childrenColumnName: legacyChildrenColumnName, onChange, getPopupContainer, loading, expandIcon, expandable, expandedRowRender, expandIconColumnIndex, indentSize, scroll, sortDirections, locale, showSorterTooltip = { target: "full-header" }, virtual } = props;
|
|
44
|
+
const { prefixCls: customizePrefixCls, className, rootClassName, style, classNames, styles, size: customizeSize, bordered, dropdownPrefixCls: customizeDropdownPrefixCls, dataSource, pagination, rowSelection: customizeRowSelection, rowKey: customizeRowKey, rowClassName, column, columns, children, childrenColumnName: legacyChildrenColumnName, onChange, getPopupContainer, loading, expandIcon, expandable, expandedRowRender, expandIconColumnIndex, indentSize, scroll, sortDirections, locale, showSorterTooltip = { target: "full-header" }, virtual } = props;
|
|
43
45
|
devUseWarning("Table");
|
|
44
|
-
const
|
|
46
|
+
const rawColumns = React$1.useMemo(() => columns || convertChildrenToColumns(children), [columns, children]);
|
|
47
|
+
const baseColumns = useFilledColumns(rawColumns, column);
|
|
45
48
|
const needResponsive = React$1.useMemo(() => baseColumns.some((col) => col.responsive), [baseColumns]);
|
|
46
49
|
const screens = useBreakpoint(needResponsive);
|
|
47
50
|
const mergedColumns = React$1.useMemo(() => {
|
|
@@ -51,6 +54,7 @@ const InternalTable = (props, ref) => {
|
|
|
51
54
|
const tableProps = omit(props, [
|
|
52
55
|
"className",
|
|
53
56
|
"style",
|
|
57
|
+
"column",
|
|
54
58
|
"columns"
|
|
55
59
|
]);
|
|
56
60
|
const { locale: contextLocale = localeValues, table } = React$1.useContext(ConfigContext);
|
|
@@ -75,6 +79,12 @@ const InternalTable = (props, ref) => {
|
|
|
75
79
|
const prefixCls = getPrefixCls("table", customizePrefixCls);
|
|
76
80
|
const dropdownPrefixCls = getPrefixCls("dropdown", customizeDropdownPrefixCls);
|
|
77
81
|
const [, token] = useToken();
|
|
82
|
+
const mergedRowSelection = React$1.useMemo(() => {
|
|
83
|
+
return isPlainObject(customizeRowSelection) ? {
|
|
84
|
+
columnWidth: token.Table?.selectionColumnWidth,
|
|
85
|
+
...customizeRowSelection
|
|
86
|
+
} : customizeRowSelection;
|
|
87
|
+
}, [customizeRowSelection, token.Table?.selectionColumnWidth]);
|
|
78
88
|
const rootCls = useCSSVarCls(prefixCls);
|
|
79
89
|
const [hashId, cssVarCls] = style_default(prefixCls, rootCls);
|
|
80
90
|
const mergedExpandable = {
|
|
@@ -100,7 +110,7 @@ const InternalTable = (props, ref) => {
|
|
|
100
110
|
const rowKey = customizeRowKey || table?.rowKey || "key";
|
|
101
111
|
const mergedScroll = scroll ?? table?.scroll;
|
|
102
112
|
const getRowKey = React$1.useMemo(() => {
|
|
103
|
-
if (
|
|
113
|
+
if (isFunction(rowKey)) return rowKey;
|
|
104
114
|
return (record) => record?.[rowKey];
|
|
105
115
|
}, [rowKey]);
|
|
106
116
|
const [getRecordByKey] = useLazyKVMap(rawData, childrenColumnName, getRowKey);
|
|
@@ -213,16 +223,15 @@ const InternalTable = (props, ref) => {
|
|
|
213
223
|
childrenColumnName,
|
|
214
224
|
locale: tableLocale,
|
|
215
225
|
getPopupContainer: getPopupContainer || getContextPopupContainer
|
|
216
|
-
},
|
|
226
|
+
}, mergedRowSelection);
|
|
217
227
|
const internalRowClassName = (record, index, indent) => {
|
|
218
|
-
|
|
219
|
-
return clsx({ [`${prefixCls}-row-selected`]: selectedKeySet.has(getRowKey(record, index)) }, resolvedRowClassName);
|
|
228
|
+
return clsx({ [`${prefixCls}-row-selected`]: selectedKeySet.has(getRowKey(record, index)) }, isFunction(rowClassName) ? rowClassName(record, index, indent) : rowClassName);
|
|
220
229
|
};
|
|
221
230
|
mergedExpandable.__PARENT_RENDER_ICON__ = mergedExpandable.expandIcon;
|
|
222
231
|
mergedExpandable.expandIcon = mergedExpandable.expandIcon || expandIcon || renderExpandIcon(tableLocale);
|
|
223
|
-
if (expandType === "nest" && mergedExpandable.expandIconColumnIndex === void 0) mergedExpandable.expandIconColumnIndex =
|
|
224
|
-
else if (mergedExpandable.expandIconColumnIndex > 0 &&
|
|
225
|
-
if (
|
|
232
|
+
if (expandType === "nest" && mergedExpandable.expandIconColumnIndex === void 0) mergedExpandable.expandIconColumnIndex = mergedRowSelection ? 1 : 0;
|
|
233
|
+
else if (mergedExpandable.expandIconColumnIndex > 0 && mergedRowSelection) mergedExpandable.expandIconColumnIndex -= 1;
|
|
234
|
+
if (!isNumber(mergedExpandable.indentSize)) mergedExpandable.indentSize = isNumber(indentSize) ? indentSize : 15;
|
|
226
235
|
const transformColumns = React$1.useCallback((innerColumns) => transformTitleColumns(transformSelectionColumns(transformFilterColumns(transformSorterColumns(innerColumns)))), [
|
|
227
236
|
transformSorterColumns,
|
|
228
237
|
transformFilterColumns,
|
|
@@ -258,7 +267,7 @@ const InternalTable = (props, ref) => {
|
|
|
258
267
|
}
|
|
259
268
|
const spinProps = React$1.useMemo(() => {
|
|
260
269
|
if (typeof loading === "boolean") return { spinning: loading };
|
|
261
|
-
else if (
|
|
270
|
+
else if (isPlainObject(loading)) return {
|
|
262
271
|
spinning: true,
|
|
263
272
|
...loading
|
|
264
273
|
};
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import omit from "../../../../@rc-component/util/es/omit.js";
|
|
2
|
+
import mergeProps from "../../../../@rc-component/util/es/mergeProps.js";
|
|
3
|
+
import "../../../../@rc-component/util/es/index.js";
|
|
4
|
+
import { EXPAND_COLUMN } from "../../../../@rc-component/table/es/constant.js";
|
|
5
|
+
import "../../../../@rc-component/table/es/index.js";
|
|
6
|
+
import { SELECTION_COLUMN } from "./useSelection.js";
|
|
7
|
+
import * as React$1 from "../../../../react/index.js";
|
|
8
|
+
//#region node_modules/antd/es/table/hooks/useFilledColumns.js
|
|
9
|
+
const useFilledColumns = (columns, column) => React$1.useMemo(() => {
|
|
10
|
+
if (!column) return columns;
|
|
11
|
+
const fillColumns = (currentColumns) => currentColumns.map((col) => {
|
|
12
|
+
if (col === SELECTION_COLUMN || col === EXPAND_COLUMN) return col;
|
|
13
|
+
if ("children" in col && Array.isArray(col.children)) return {
|
|
14
|
+
...mergeProps(column, col),
|
|
15
|
+
children: fillColumns(col.children)
|
|
16
|
+
};
|
|
17
|
+
const columnWithoutChildren = omit(column, ["children"]);
|
|
18
|
+
return mergeProps(columnWithoutChildren, col);
|
|
19
|
+
});
|
|
20
|
+
return fillColumns(columns);
|
|
21
|
+
}, [columns, column]);
|
|
22
|
+
//#endregion
|
|
23
|
+
export { useFilledColumns as default };
|