@unicom-cloud/ui 0.8.41
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/Affix.js +124 -0
- package/Alert.js +112 -0
- package/Anchor.js +6 -0
- package/AutoComplete.js +155 -0
- package/Avatar.js +157 -0
- package/BackTop.js +85 -0
- package/Badge.js +178 -0
- package/Breadcrumb.js +144 -0
- package/Button.js +141 -0
- package/Calendar.js +577 -0
- package/Card.js +139 -0
- package/Carousel.js +382 -0
- package/Cascader.js +10 -0
- package/Checkbox.js +5 -0
- package/Collapse.js +5 -0
- package/ColorPicker.js +588 -0
- package/Comment.js +74 -0
- package/ConfigProvider.js +8 -0
- package/Copy.js +65 -0
- package/DatePicker.js +2006 -0
- package/Descriptions.js +179 -0
- package/Divider.js +41 -0
- package/Draggable.js +92 -0
- package/Drawer.js +6 -0
- package/Dropdown.js +186 -0
- package/Empty.js +10 -0
- package/Form.js +1420 -0
- package/Grid.js +250 -0
- package/Icon.js +57 -0
- package/IconHover.js +8 -0
- package/Image.js +6 -0
- package/Input.js +7 -0
- package/InputNumber.js +19 -0
- package/InputTag.js +6 -0
- package/Layout.js +57 -0
- package/Link.js +63 -0
- package/List.js +320 -0
- package/Loading.js +62 -0
- package/Mentions.js +172 -0
- package/Menu.js +9 -0
- package/Message.js +12 -0
- package/Modal.js +6 -0
- package/Notice.js +15 -0
- package/Notification.js +13 -0
- package/NotificationBase.js +54 -0
- package/OverflowEllipsis.js +99 -0
- package/PageHeader.js +121 -0
- package/Pagination.js +13 -0
- package/Picker.js +6 -0
- package/Popconfirm.js +134 -0
- package/Popover.js +81 -0
- package/Portal.js +35 -0
- package/Progress.js +367 -0
- package/Radio.js +7 -0
- package/Rate.js +129 -0
- package/ResizeBox.js +559 -0
- package/Result.js +1437 -0
- package/Select.js +10 -0
- package/SelectView.js +347 -0
- package/Skeleton.js +97 -0
- package/Slider.js +784 -0
- package/Space.js +93 -0
- package/SpeechSynthesis.js +53 -0
- package/Spin.js +97 -0
- package/Statistic.js +192 -0
- package/Steps.js +149 -0
- package/SuspenseFallbackTest.js +11 -0
- package/Switch.js +116 -0
- package/Table.js +2001 -0
- package/Tabs.js +10 -0
- package/Tag.js +108 -0
- package/TimePicker.js +278 -0
- package/Timeline.js +5 -0
- package/Tooltip.js +127 -0
- package/Transfer.js +461 -0
- package/Tree.js +6 -0
- package/TreeSelect.js +9 -0
- package/Trigger.js +858 -0
- package/Typography.js +723 -0
- package/Upload.js +10 -0
- package/VerificationCode.js +7 -0
- package/Version.js +5 -0
- package/VirtualList.js +5 -0
- package/Watermark.js +4 -0
- package/chunk/B-h-HjBo.js +1000 -0
- package/chunk/BGGDhLVD.js +966 -0
- package/chunk/BGzBxiWE.js +517 -0
- package/chunk/BTvIp2Ol.js +229 -0
- package/chunk/BVC51EZ7.js +232 -0
- package/chunk/BdWYJb9B.js +769 -0
- package/chunk/BdYAMaw9.js +6 -0
- package/chunk/Bl5t8Z6F.js +946 -0
- package/chunk/C6Kfwj0f.js +1 -0
- package/chunk/CA-kzjHQ.js +66 -0
- package/chunk/CEMQTMlX.js +798 -0
- package/chunk/CICfjLap.js +605 -0
- package/chunk/CUK6MU72.js +694 -0
- package/chunk/Cpp8T23i.js +271 -0
- package/chunk/CuIVS4do.js +277 -0
- package/chunk/CwIyJM0N.js +261 -0
- package/chunk/CwewmGEF.js +516 -0
- package/chunk/DF-4xm4m.js +375 -0
- package/chunk/DP2rzg_V.js +1 -0
- package/chunk/DQ_eXwj8.js +877 -0
- package/chunk/DYwvc9zo.js +165 -0
- package/chunk/Da4Rq2D4.js +226 -0
- package/chunk/Dc_89PVN.js +736 -0
- package/chunk/DdK6eiNS.js +240 -0
- package/chunk/DhodcKwW.js +167 -0
- package/chunk/GfGTdWbJ.js +162 -0
- package/chunk/I4RV9SKZ.js +135 -0
- package/chunk/K6Dvbx-E.js +1 -0
- package/chunk/Kt5-772l.js +450 -0
- package/chunk/RnTpOC5-.js +1 -0
- package/chunk/TXCrI0jN.js +20 -0
- package/chunk/cRoKuTbN.js +129 -0
- package/chunk/ehTyphn0.js +335 -0
- package/chunk/kAbgUN-k.js +80 -0
- package/chunk/l0sNRNKZ.js +1 -0
- package/chunk/vpaTr5dz.js +984 -0
- package/hooks/index.js +6 -0
- package/hooks/use-verification-code.js +72 -0
- package/hooks/use-watermark.js +175 -0
- package/hooks/useAsync.js +13 -0
- package/hooks/useAsyncFn.js +15 -0
- package/hooks/useAsyncRetry.js +17 -0
- package/hooks/useAudio.js +5 -0
- package/hooks/useBeforeUnload.js +18 -0
- package/hooks/useBoolean.js +4 -0
- package/hooks/useClickAway.js +22 -0
- package/hooks/useComputedState.js +11 -0
- package/hooks/useCopyToClipboard.js +51 -0
- package/hooks/useCounter.js +45 -0
- package/hooks/useCreate.js +8 -0
- package/hooks/useCreation.js +19 -0
- package/hooks/useCustomCompareEffect.js +15 -0
- package/hooks/useDebounce.js +9 -0
- package/hooks/useDefault.js +10 -0
- package/hooks/useDrop.js +44 -0
- package/hooks/useDropArea.js +45 -0
- package/hooks/useEffectOnce.js +7 -0
- package/hooks/useEffectState.js +9 -0
- package/hooks/useEnsuredForwardedRef.js +17 -0
- package/hooks/useError.js +13 -0
- package/hooks/useEvent.js +13 -0
- package/hooks/useEventListener.js +41 -0
- package/hooks/useFavicon.js +17 -0
- package/hooks/useFirstMountState.js +8 -0
- package/hooks/useForceUpdate.js +8 -0
- package/hooks/useFullscreen.js +40 -0
- package/hooks/useGeolocation.js +38 -0
- package/hooks/useGetSet.js +18 -0
- package/hooks/useGetSetState.js +12 -0
- package/hooks/useHash.js +26 -0
- package/hooks/useHover.js +16 -0
- package/hooks/useHoverDirty.js +17 -0
- package/hooks/useId.js +11 -0
- package/hooks/useIdle.js +34 -0
- package/hooks/useInView.js +31 -0
- package/hooks/useIntersection.js +19 -0
- package/hooks/useIntersectionObserver.js +23 -0
- package/hooks/useInterval.js +19 -0
- package/hooks/useIsFirstRender.js +10 -0
- package/hooks/useIsomorphicLayoutEffect.js +6 -0
- package/hooks/useIsomorphicLayoutEffect2.js +6 -0
- package/hooks/useKey.js +16 -0
- package/hooks/useKeyPress.js +13 -0
- package/hooks/useKeyPressEvent.js +11 -0
- package/hooks/useKeyboardEvent.js +17 -0
- package/hooks/useLatest.js +8 -0
- package/hooks/useLifecycles.js +9 -0
- package/hooks/useList.js +67 -0
- package/hooks/useLocalStorage.js +41 -0
- package/hooks/useLocation.js +51 -0
- package/hooks/useLockBodyScroll.js +56 -0
- package/hooks/useLogger.js +10 -0
- package/hooks/useLongPress.js +24 -0
- package/hooks/useMap.js +31 -0
- package/hooks/useMeasure.js +34 -0
- package/hooks/useMeasureDirty.js +24 -0
- package/hooks/useMedia.js +19 -0
- package/hooks/useMediaDevices.js +26 -0
- package/hooks/useMediatedState.js +14 -0
- package/hooks/useMergeProps.js +19 -0
- package/hooks/useMergeValue.js +18 -0
- package/hooks/useMethods.js +14 -0
- package/hooks/useMotion.js +56 -0
- package/hooks/useMount.js +9 -0
- package/hooks/useMountedState.js +10 -0
- package/hooks/useMouse.js +44 -0
- package/hooks/useMouseHovered.js +9 -0
- package/hooks/useMouseWheel.js +14 -0
- package/hooks/useMultiStateValidator.js +19 -0
- package/hooks/useNetworkState.js +31 -0
- package/hooks/useNumber.js +4 -0
- package/hooks/useObservable.js +12 -0
- package/hooks/useOrientation.js +31 -0
- package/hooks/useOverflowHidden.js +26 -0
- package/hooks/usePageLeave.js +19 -0
- package/hooks/usePermission.js +19 -0
- package/hooks/usePinchZoom.js +40 -0
- package/hooks/usePrevious.js +10 -0
- package/hooks/usePreviousDistinct.js +10 -0
- package/hooks/usePromise.js +19 -0
- package/hooks/useQueue.js +25 -0
- package/hooks/useRaf.js +24 -0
- package/hooks/useRafLoop.js +24 -0
- package/hooks/useRafState.js +15 -0
- package/hooks/useReactive.js +21 -0
- package/hooks/useRefs.js +10 -0
- package/hooks/useRendersCount.js +7 -0
- package/hooks/useScroll.js +27 -0
- package/hooks/useScrolling.js +23 -0
- package/hooks/useSearchParam.js +18 -0
- package/hooks/useSessionStorage.js +28 -0
- package/hooks/useSet.js +15 -0
- package/hooks/useSetState.js +16 -0
- package/hooks/useSize.js +58 -0
- package/hooks/useSlider.js +48 -0
- package/hooks/useSpeech.js +45 -0
- package/hooks/useStartTyping.js +30 -0
- package/hooks/useStateCallback.js +16 -0
- package/hooks/useStateList.js +38 -0
- package/hooks/useStateValidator.js +17 -0
- package/hooks/useStateWithHistory.js +46 -0
- package/hooks/useStateWithPromise.js +25 -0
- package/hooks/useSyncState.js +14 -0
- package/hooks/useThrottle.js +21 -0
- package/hooks/useThrottleFn.js +21 -0
- package/hooks/useTimeout.js +18 -0
- package/hooks/useTimeoutFn.js +16 -0
- package/hooks/useTitle.js +18 -0
- package/hooks/useToggle.js +5 -0
- package/hooks/useTween.js +11 -0
- package/hooks/useUnmount.js +9 -0
- package/hooks/useUnmountPromise.js +20 -0
- package/hooks/useUpdate.js +10 -0
- package/hooks/useUpdateEffect.js +12 -0
- package/hooks/useUpdateTimeout.js +9 -0
- package/hooks/useUpsert.js +16 -0
- package/hooks/useVibrate.js +21 -0
- package/hooks/useVideo.js +5 -0
- package/hooks/useWatch.js +11 -0
- package/hooks/useWindowScroll.js +29 -0
- package/hooks/useWindowSize.js +25 -0
- package/index.js +397 -0
- package/locale/ar-EG.js +167 -0
- package/locale/de-DE.js +167 -0
- package/locale/default.js +4 -0
- package/locale/en-US.js +174 -0
- package/locale/es-ES.js +167 -0
- package/locale/fr-FR.js +167 -0
- package/locale/id-ID.js +167 -0
- package/locale/interface.js +1 -0
- package/locale/it-IT.js +167 -0
- package/locale/ja-JP.js +220 -0
- package/locale/ko-KR.js +167 -0
- package/locale/ms-MY.js +167 -0
- package/locale/pt-BR.js +167 -0
- package/locale/pt-PT.js +167 -0
- package/locale/ru-RU.js +167 -0
- package/locale/th-TH.js +167 -0
- package/locale/tr-TR.js +169 -0
- package/locale/vi-VN.js +167 -0
- package/locale/zh-CN.js +221 -0
- package/locale/zh-HK.js +221 -0
- package/locale/zh-TW.js +220 -0
- package/package.json +25 -0
- package/style.css +1 -0
- package/types/Popover/index.d.ts +7 -0
- package/types/Popover/interface.d.ts +8 -0
- package/types/Popover/style/index.d.ts +3 -0
- package/types/affix/index.d.ts +9 -0
- package/types/affix/interface.d.ts +12 -0
- package/types/affix/style/index.d.ts +2 -0
- package/types/alert/index.d.ts +5 -0
- package/types/alert/interface.d.ts +17 -0
- package/types/alert/style/index.d.ts +2 -0
- package/types/anchor/Anchor.d.ts +9 -0
- package/types/anchor/Link.d.ts +6 -0
- package/types/anchor/context.d.ts +11 -0
- package/types/anchor/index.d.ts +4 -0
- package/types/anchor/interface.d.ts +24 -0
- package/types/anchor/style/index.d.ts +3 -0
- package/types/anchor/util.d.ts +4 -0
- package/types/auto-complete/index.d.ts +11 -0
- package/types/auto-complete/interface.d.ts +36 -0
- package/types/auto-complete/style/index.d.ts +4 -0
- package/types/avatar/Avatar.d.ts +6 -0
- package/types/avatar/Group.d.ts +6 -0
- package/types/avatar/context.d.ts +3 -0
- package/types/avatar/index.d.ts +9 -0
- package/types/avatar/interface.d.ts +24 -0
- package/types/avatar/style/index.d.ts +3 -0
- package/types/back-top/index.d.ts +8 -0
- package/types/back-top/interface.d.ts +11 -0
- package/types/back-top/style/index.d.ts +2 -0
- package/types/badge/Count.d.ts +7 -0
- package/types/badge/index.d.ts +7 -0
- package/types/badge/interface.d.ts +17 -0
- package/types/badge/style/index.d.ts +2 -0
- package/types/breadcrumb/Item.d.ts +8 -0
- package/types/breadcrumb/index.d.ts +9 -0
- package/types/breadcrumb/interface.d.ts +31 -0
- package/types/breadcrumb/style/index.d.ts +3 -0
- package/types/button/Group.d.ts +5 -0
- package/types/button/index.d.ts +16 -0
- package/types/button/interface.d.ts +37 -0
- package/types/button/style/index.d.ts +2 -0
- package/types/calendar/Month.d.ts +15 -0
- package/types/calendar/WeekList.d.ts +10 -0
- package/types/calendar/Year.d.ts +13 -0
- package/types/calendar/header/Panel.d.ts +2 -0
- package/types/calendar/header/index.d.ts +2 -0
- package/types/calendar/hook/useCellClassName.d.ts +1 -0
- package/types/calendar/index.d.ts +8 -0
- package/types/calendar/interface.d.ts +41 -0
- package/types/calendar/style/index.d.ts +4 -0
- package/types/card/Grid.d.ts +5 -0
- package/types/card/Meta.d.ts +5 -0
- package/types/card/index.d.ts +11 -0
- package/types/card/interface.d.ts +32 -0
- package/types/card/style/index.d.ts +3 -0
- package/types/carousel/Arrow.d.ts +4 -0
- package/types/carousel/Indicator.d.ts +4 -0
- package/types/carousel/index.d.ts +6 -0
- package/types/carousel/interface.d.ts +52 -0
- package/types/carousel/style/index.d.ts +2 -0
- package/types/cascader/Cascader.d.ts +17 -0
- package/types/cascader/base/node.d.ts +48 -0
- package/types/cascader/base/store.d.ts +26 -0
- package/types/cascader/hook/useRefCurrent.d.ts +3 -0
- package/types/cascader/index.d.ts +5 -0
- package/types/cascader/interface.d.ts +105 -0
- package/types/cascader/panel/List.d.ts +4 -0
- package/types/cascader/panel/Option.d.ts +23 -0
- package/types/cascader/panel/Search.d.ts +28 -0
- package/types/cascader/style/index.d.ts +6 -0
- package/types/cascader/util.d.ts +23 -0
- package/types/checkbox/Checkbox.d.ts +14 -0
- package/types/checkbox/Group.d.ts +17 -0
- package/types/checkbox/index.d.ts +5 -0
- package/types/checkbox/interface.d.ts +36 -0
- package/types/checkbox/style/index.d.ts +2 -0
- package/types/checkbox/useCheckbox.d.ts +13 -0
- package/types/collapse/Collapse.d.ts +14 -0
- package/types/collapse/Item.d.ts +7 -0
- package/types/collapse/index.d.ts +4 -0
- package/types/collapse/interface.d.ts +27 -0
- package/types/collapse/style/index.d.ts +2 -0
- package/types/color-picker/ControlBar.d.ts +11 -0
- package/types/color-picker/InputAlpha.d.ts +7 -0
- package/types/color-picker/InputHex.d.ts +11 -0
- package/types/color-picker/InputRgb.d.ts +10 -0
- package/types/color-picker/Palette.d.ts +7 -0
- package/types/color-picker/Panel.d.ts +20 -0
- package/types/color-picker/colors.d.ts +2 -0
- package/types/color-picker/hooks/useColorPicker.d.ts +37 -0
- package/types/color-picker/hooks/useControlBlock.d.ts +11 -0
- package/types/color-picker/index.d.ts +6 -0
- package/types/color-picker/interface.d.ts +49 -0
- package/types/color-picker/style/index.d.ts +4 -0
- package/types/comment/index.d.ts +7 -0
- package/types/comment/interface.d.ts +14 -0
- package/types/comment/style/index.d.ts +2 -0
- package/types/config-provider/ConfigProvider.d.ts +10 -0
- package/types/config-provider/context.d.ts +3 -0
- package/types/config-provider/index.d.ts +5 -0
- package/types/config-provider/interface.d.ts +168 -0
- package/types/config-provider/style/index.d.ts +1 -0
- package/types/copy/index.d.ts +8 -0
- package/types/copy/interface.d.ts +9 -0
- package/types/copy/style/index.d.ts +3 -0
- package/types/date-picker/Picker.d.ts +18 -0
- package/types/date-picker/PickerRange.d.ts +7 -0
- package/types/date-picker/context.d.ts +7 -0
- package/types/date-picker/hook/useCellClassName.d.ts +1 -0
- package/types/date-picker/index.d.ts +5 -0
- package/types/date-picker/interface.d.ts +159 -0
- package/types/date-picker/panel/Body.d.ts +30 -0
- package/types/date-picker/panel/Footer.d.ts +1 -0
- package/types/date-picker/panel/Header.d.ts +20 -0
- package/types/date-picker/panel/Shortcut.d.ts +3 -0
- package/types/date-picker/panel/WeekList.d.ts +8 -0
- package/types/date-picker/panel/date/index.d.ts +24 -0
- package/types/date-picker/panel/month/index.d.ts +17 -0
- package/types/date-picker/panel/quarter/index.d.ts +17 -0
- package/types/date-picker/panel/range/index.d.ts +28 -0
- package/types/date-picker/panel/week/index.d.ts +16 -0
- package/types/date-picker/panel/year/index.d.ts +16 -0
- package/types/date-picker/style/index.d.ts +7 -0
- package/types/date-picker/util.d.ts +9 -0
- package/types/descriptions/index.d.ts +8 -0
- package/types/descriptions/interface.d.ts +29 -0
- package/types/descriptions/style/index.d.ts +2 -0
- package/types/divider/index.d.ts +6 -0
- package/types/divider/interface.d.ts +8 -0
- package/types/divider/style/index.d.ts +2 -0
- package/types/draggable/Item.d.ts +3 -0
- package/types/draggable/index.d.ts +4 -0
- package/types/draggable/interface.d.ts +22 -0
- package/types/draggable/style/index.d.ts +2 -0
- package/types/drawer/Drawer.d.ts +5 -0
- package/types/drawer/index.d.ts +4 -0
- package/types/drawer/interface.d.ts +36 -0
- package/types/drawer/style/index.d.ts +3 -0
- package/types/dropdown/Button.d.ts +4 -0
- package/types/dropdown/index.d.ts +9 -0
- package/types/dropdown/interface.d.ts +28 -0
- package/types/dropdown/style/index.d.ts +4 -0
- package/types/empty/index.d.ts +6 -0
- package/types/empty/interface.d.ts +8 -0
- package/types/empty/style/index.d.ts +2 -0
- package/types/form/Control.d.ts +55 -0
- package/types/form/Form.d.ts +6 -0
- package/types/form/FormItem.d.ts +7 -0
- package/types/form/FormItemTip.d.ts +8 -0
- package/types/form/FormLabel.d.ts +9 -0
- package/types/form/FormList.d.ts +6 -0
- package/types/form/FormProvider.d.ts +4 -0
- package/types/form/IconSymbol.d.ts +3 -0
- package/types/form/context.d.ts +15 -0
- package/types/form/hook/useContext.d.ts +7 -0
- package/types/form/hook/useState.d.ts +3 -0
- package/types/form/hook/useWatch.d.ts +3 -0
- package/types/form/index.d.ts +26 -0
- package/types/form/interface.d.ts +228 -0
- package/types/form/promisify.d.ts +2 -0
- package/types/form/store.d.ts +89 -0
- package/types/form/style/index.d.ts +3 -0
- package/types/form/useForm.d.ts +3 -0
- package/types/form/util.d.ts +14 -0
- package/types/grid/Col.d.ts +4 -0
- package/types/grid/Row.d.ts +4 -0
- package/types/grid/context.d.ts +19 -0
- package/types/grid/grid-item.d.ts +7 -0
- package/types/grid/grid.d.ts +5 -0
- package/types/grid/hook/useResponsiveState.d.ts +2 -0
- package/types/grid/index.d.ts +11 -0
- package/types/grid/interface.d.ts +76 -0
- package/types/grid/style/index.d.ts +2 -0
- package/types/grid/util.d.ts +11 -0
- package/types/hooks/component/UseKey.d.ts +2 -0
- package/types/hooks/factory/createBreakpoint.d.ts +4 -0
- package/types/hooks/factory/createGlobalState.d.ts +7 -0
- package/types/hooks/factory/createHTMLMediaHook.d.ts +33 -0
- package/types/hooks/factory/createMemo.d.ts +2 -0
- package/types/hooks/factory/createReducer.d.ts +8 -0
- package/types/hooks/factory/createReducerContext.d.ts +5 -0
- package/types/hooks/factory/createRenderProp.d.ts +1 -0
- package/types/hooks/factory/createRouter.d.ts +7 -0
- package/types/hooks/factory/createStateContext.d.ts +5 -0
- package/types/hooks/index.d.ts +2 -0
- package/types/hooks/misc/hookState.d.ts +8 -0
- package/types/hooks/misc/parseTimeRanges.d.ts +4 -0
- package/types/hooks/misc/types.d.ts +2 -0
- package/types/hooks/misc/util.d.ts +5 -0
- package/types/hooks/use-verification-code/index.d.ts +2 -0
- package/types/hooks/use-verification-code/interface.d.ts +22 -0
- package/types/hooks/use-watermark/index.d.ts +2 -0
- package/types/hooks/use-watermark/interface.d.ts +22 -0
- package/types/hooks/use-watermark/utils.d.ts +1 -0
- package/types/hooks/useAsync.d.ts +20 -0
- package/types/hooks/useAsyncFn.d.ts +23 -0
- package/types/hooks/useAsyncRetry.d.ts +27 -0
- package/types/hooks/useAudio.d.ts +11 -0
- package/types/hooks/useBeforeUnload.d.ts +2 -0
- package/types/hooks/useBoolean.d.ts +2 -0
- package/types/hooks/useClickAway.d.ts +3 -0
- package/types/hooks/useComputedState.d.ts +4 -0
- package/types/hooks/useCopyToClipboard.d.ts +10 -0
- package/types/hooks/useCounter.d.ts +9 -0
- package/types/hooks/useCreate.d.ts +1 -0
- package/types/hooks/useCreation.d.ts +2 -0
- package/types/hooks/useCustomCompareEffect.d.ts +4 -0
- package/types/hooks/useDebounce.d.ts +3 -0
- package/types/hooks/useDefault.d.ts +2 -0
- package/types/hooks/useDrop.d.ts +17 -0
- package/types/hooks/useDropArea.d.ts +17 -0
- package/types/hooks/useEffectOnce.d.ts +3 -0
- package/types/hooks/useEffectState.d.ts +2 -0
- package/types/hooks/useEnsuredForwardedRef.d.ts +3 -0
- package/types/hooks/useError.d.ts +2 -0
- package/types/hooks/useEvent.d.ts +13 -0
- package/types/hooks/useEventListener.d.ts +2 -0
- package/types/hooks/useFavicon.d.ts +2 -0
- package/types/hooks/useFirstMountState.d.ts +1 -0
- package/types/hooks/useForceUpdate.d.ts +2 -0
- package/types/hooks/useFullscreen.d.ts +10 -0
- package/types/hooks/useGeolocation.d.ts +21 -0
- package/types/hooks/useGetSet.d.ts +3 -0
- package/types/hooks/useGetSetState.d.ts +2 -0
- package/types/hooks/useHash.d.ts +2 -0
- package/types/hooks/useHover.d.ts +4 -0
- package/types/hooks/useHoverDirty.d.ts +3 -0
- package/types/hooks/useId.d.ts +1 -0
- package/types/hooks/useIdle.d.ts +2 -0
- package/types/hooks/useInView.d.ts +11 -0
- package/types/hooks/useIntersection.d.ts +3 -0
- package/types/hooks/useIntersectionObserver.d.ts +7 -0
- package/types/hooks/useInterval.d.ts +2 -0
- package/types/hooks/useIsFirstRender.d.ts +1 -0
- package/types/hooks/useIsomorphicLayoutEffect.d.ts +3 -0
- package/types/hooks/useIsomorphicLayoutEffect2.d.ts +3 -0
- package/types/hooks/useKey.d.ts +12 -0
- package/types/hooks/useKeyPress.d.ts +3 -0
- package/types/hooks/useKeyPressEvent.d.ts +3 -0
- package/types/hooks/useKeyboardEvent.d.ts +14 -0
- package/types/hooks/useLatest.d.ts +4 -0
- package/types/hooks/useLifecycles.d.ts +2 -0
- package/types/hooks/useList.d.ts +18 -0
- package/types/hooks/useLocalStorage.d.ts +10 -0
- package/types/hooks/useLocation.d.ts +16 -0
- package/types/hooks/useLockBodyScroll.d.ts +8 -0
- package/types/hooks/useLogger.d.ts +2 -0
- package/types/hooks/useLongPress.d.ts +12 -0
- package/types/hooks/useMap.d.ts +11 -0
- package/types/hooks/useMeasure.d.ts +9 -0
- package/types/hooks/useMeasureDirty.d.ts +11 -0
- package/types/hooks/useMedia.d.ts +2 -0
- package/types/hooks/useMediaDevices.d.ts +2 -0
- package/types/hooks/useMediatedState.d.ts +9 -0
- package/types/hooks/useMergeProps.d.ts +4 -0
- package/types/hooks/useMergeValue.d.ts +5 -0
- package/types/hooks/useMethods.d.ts +8 -0
- package/types/hooks/useMotion.d.ts +20 -0
- package/types/hooks/useMount.d.ts +2 -0
- package/types/hooks/useMountedState.d.ts +1 -0
- package/types/hooks/useMouse.d.ts +13 -0
- package/types/hooks/useMouseHovered.d.ts +8 -0
- package/types/hooks/useMouseWheel.d.ts +2 -0
- package/types/hooks/useMultiStateValidator.d.ts +9 -0
- package/types/hooks/useNetworkState.d.ts +22 -0
- package/types/hooks/useNumber.d.ts +2 -0
- package/types/hooks/useObservable.d.ts +8 -0
- package/types/hooks/useOrientation.d.ts +6 -0
- package/types/hooks/useOverflowHidden.d.ts +5 -0
- package/types/hooks/usePageLeave.d.ts +2 -0
- package/types/hooks/usePermission.d.ts +16 -0
- package/types/hooks/usePinchZoom.d.ts +18 -0
- package/types/hooks/usePrevious.d.ts +2 -0
- package/types/hooks/usePreviousDistinct.d.ts +2 -0
- package/types/hooks/usePromise.d.ts +3 -0
- package/types/hooks/useQueue.d.ts +9 -0
- package/types/hooks/useRaf.d.ts +2 -0
- package/types/hooks/useRafLoop.d.ts +2 -0
- package/types/hooks/useRafState.d.ts +3 -0
- package/types/hooks/useReactive.d.ts +2 -0
- package/types/hooks/useRefs.d.ts +1 -0
- package/types/hooks/useRendersCount.d.ts +1 -0
- package/types/hooks/useScroll.d.ts +7 -0
- package/types/hooks/useScrolling.d.ts +3 -0
- package/types/hooks/useSearchParam.d.ts +3 -0
- package/types/hooks/useSessionStorage.d.ts +2 -0
- package/types/hooks/useSet.d.ts +11 -0
- package/types/hooks/useSetState.d.ts +2 -0
- package/types/hooks/useSize.d.ts +8 -0
- package/types/hooks/useSlider.d.ts +15 -0
- package/types/hooks/useSpeech.d.ts +16 -0
- package/types/hooks/useStartTyping.d.ts +2 -0
- package/types/hooks/useStateCallback.d.ts +5 -0
- package/types/hooks/useStateList.d.ts +9 -0
- package/types/hooks/useStateValidator.d.ts +8 -0
- package/types/hooks/useStateWithHistory.d.ts +18 -0
- package/types/hooks/useStateWithPromise.d.ts +2 -0
- package/types/hooks/useSyncState.d.ts +3 -0
- package/types/hooks/useThrottle.d.ts +2 -0
- package/types/hooks/useThrottleFn.d.ts +2 -0
- package/types/hooks/useTimeout.d.ts +2 -0
- package/types/hooks/useTimeoutFn.d.ts +2 -0
- package/types/hooks/useTitle.d.ts +6 -0
- package/types/hooks/useToggle.d.ts +2 -0
- package/types/hooks/useTween.d.ts +3 -0
- package/types/hooks/useUnmount.d.ts +2 -0
- package/types/hooks/useUnmountPromise.d.ts +3 -0
- package/types/hooks/useUpdate.d.ts +2 -0
- package/types/hooks/useUpdateEffect.d.ts +3 -0
- package/types/hooks/useUpdateTimeout.d.ts +2 -0
- package/types/hooks/useUpsert.d.ts +6 -0
- package/types/hooks/useVibrate.d.ts +4 -0
- package/types/hooks/useVideo.d.ts +11 -0
- package/types/hooks/useWatch.d.ts +2 -0
- package/types/hooks/useWindowScroll.d.ts +6 -0
- package/types/hooks/useWindowSize.d.ts +5 -0
- package/types/icon/addFromIconFontCn.d.ts +9 -0
- package/types/icon/index.d.ts +18 -0
- package/types/icon/style/index.d.ts +0 -0
- package/types/icon-hover/index.d.ts +11 -0
- package/types/icon-hover/style/index.d.ts +2 -0
- package/types/image/Image.d.ts +11 -0
- package/types/image/ImageFooter.d.ts +13 -0
- package/types/image/ImagePreview.d.ts +6 -0
- package/types/image/ImagePreviewArrow.d.ts +9 -0
- package/types/image/ImagePreviewGroup.d.ts +10 -0
- package/types/image/ImagePreviewToolbar.d.ts +14 -0
- package/types/image/TriggerForToolbar.d.ts +10 -0
- package/types/image/index.d.ts +4 -0
- package/types/image/interface.d.ts +58 -0
- package/types/image/previewGroupContext.d.ts +24 -0
- package/types/image/style/index.d.ts +2 -0
- package/types/image/util/getFixTranslate.d.ts +1 -0
- package/types/image/util/getScale.d.ts +13 -0
- package/types/image/util/hook/useImageStatus.d.ts +11 -0
- package/types/image/util/hook/useShowFooter.d.ts +8 -0
- package/types/index.d.ts +197 -0
- package/types/input/Group.d.ts +7 -0
- package/types/input/Input.d.ts +23 -0
- package/types/input/InputElement.d.ts +4 -0
- package/types/input/Number.d.ts +2 -0
- package/types/input/Password.d.ts +5 -0
- package/types/input/Search.d.ts +5 -0
- package/types/input/Tag.d.ts +2 -0
- package/types/input/Textarea.d.ts +9 -0
- package/types/input/autoSizeTextAreaHeight.d.ts +5 -0
- package/types/input/index.d.ts +8 -0
- package/types/input/interface.d.ts +93 -0
- package/types/input/style/index.d.ts +3 -0
- package/types/input/useComposition.d.ts +17 -0
- package/types/input-number/decimal.d.ts +16 -0
- package/types/input-number/index.d.ts +7 -0
- package/types/input-number/interface.d.ts +37 -0
- package/types/input-number/style/index.d.ts +3 -0
- package/types/input-number/useSelectionRange.d.ts +4 -0
- package/types/input-number/util.d.ts +13 -0
- package/types/input-tag/InputTag.d.ts +9 -0
- package/types/input-tag/index.d.ts +4 -0
- package/types/input-tag/interface.d.ts +60 -0
- package/types/input-tag/style/index.d.ts +3 -0
- package/types/layout/Content.d.ts +3 -0
- package/types/layout/Footer.d.ts +3 -0
- package/types/layout/Header.d.ts +3 -0
- package/types/layout/Sider.d.ts +10 -0
- package/types/layout/index.d.ts +18 -0
- package/types/layout/interface.d.ts +39 -0
- package/types/layout/style/index.d.ts +4 -0
- package/types/link/index.d.ts +7 -0
- package/types/link/interface.d.ts +9 -0
- package/types/link/style/index.d.ts +2 -0
- package/types/list/Item.d.ts +7 -0
- package/types/list/Meta.d.ts +4 -0
- package/types/list/index.d.ts +13 -0
- package/types/list/interface.d.ts +57 -0
- package/types/list/style/index.d.ts +6 -0
- package/types/loading/index.d.ts +3 -0
- package/types/loading/style/index.d.ts +2 -0
- package/types/locale/ar-EG.d.ts +228 -0
- package/types/locale/de-DE.d.ts +228 -0
- package/types/locale/default.d.ts +2 -0
- package/types/locale/en-US.d.ts +279 -0
- package/types/locale/es-ES.d.ts +228 -0
- package/types/locale/fr-FR.d.ts +228 -0
- package/types/locale/id-ID.d.ts +228 -0
- package/types/locale/interface.d.ts +39 -0
- package/types/locale/it-IT.d.ts +228 -0
- package/types/locale/ja-JP.d.ts +281 -0
- package/types/locale/ko-KR.d.ts +228 -0
- package/types/locale/ms-MY.d.ts +228 -0
- package/types/locale/pt-BR.d.ts +228 -0
- package/types/locale/pt-PT.d.ts +228 -0
- package/types/locale/ru-RU.d.ts +228 -0
- package/types/locale/th-TH.d.ts +228 -0
- package/types/locale/tr-TR.d.ts +274 -0
- package/types/locale/vi-VN.d.ts +228 -0
- package/types/locale/zh-CN.d.ts +281 -0
- package/types/locale/zh-HK.d.ts +281 -0
- package/types/locale/zh-TW.d.ts +281 -0
- package/types/mentions/index.d.ts +6 -0
- package/types/mentions/interface.d.ts +26 -0
- package/types/mentions/style/index.d.ts +2 -0
- package/types/mentions/util.d.ts +9 -0
- package/types/menu/Indent.d.ts +5 -0
- package/types/menu/Item.d.ts +5 -0
- package/types/menu/ItemGroup.d.ts +5 -0
- package/types/menu/Menu.d.ts +12 -0
- package/types/menu/OverflowWrap.d.ts +9 -0
- package/types/menu/context.d.ts +15 -0
- package/types/menu/index.d.ts +4 -0
- package/types/menu/interface.d.ts +77 -0
- package/types/menu/style/index.d.ts +4 -0
- package/types/menu/sub-menu/Inline.d.ts +5 -0
- package/types/menu/sub-menu/Pop.d.ts +5 -0
- package/types/menu/sub-menu/index.d.ts +5 -0
- package/types/menu/util.d.ts +16 -0
- package/types/message/index.d.ts +33 -0
- package/types/message/interface.d.ts +30 -0
- package/types/message/style/index.d.ts +2 -0
- package/types/message/useMessage.d.ts +6 -0
- package/types/modal/Confirm.d.ts +14 -0
- package/types/modal/Modal.d.ts +19 -0
- package/types/modal/config.d.ts +10 -0
- package/types/modal/index.d.ts +4 -0
- package/types/modal/interface.d.ts +55 -0
- package/types/modal/style/index.d.ts +3 -0
- package/types/modal/use-modal/Hook.d.ts +7 -0
- package/types/modal/use-modal/index.d.ts +4 -0
- package/types/notice/index.d.ts +48 -0
- package/types/notice/style/index.d.ts +2 -0
- package/types/notification/index.d.ts +29 -0
- package/types/notification/interface.d.ts +26 -0
- package/types/notification/style/index.d.ts +2 -0
- package/types/notification/useNotification.d.ts +6 -0
- package/types/notification-base/index.d.ts +16 -0
- package/types/notification-base/style/index.d.ts +2 -0
- package/types/overflow-ellipsis/OverflowItem.d.ts +10 -0
- package/types/overflow-ellipsis/index.d.ts +11 -0
- package/types/page-header/index.d.ts +8 -0
- package/types/page-header/interface.d.ts +14 -0
- package/types/page-header/style/index.d.ts +3 -0
- package/types/pagination/PageItem.d.ts +52 -0
- package/types/pagination/PageJumper.d.ts +13 -0
- package/types/pagination/PageOption.d.ts +15 -0
- package/types/pagination/Pagination.d.ts +11 -0
- package/types/pagination/index.d.ts +4 -0
- package/types/pagination/interface.d.ts +34 -0
- package/types/pagination/style/index.d.ts +4 -0
- package/types/picker/Input.d.ts +31 -0
- package/types/picker/InputRange.d.ts +35 -0
- package/types/picker/index.d.ts +4 -0
- package/types/picker/style/index.d.ts +2 -0
- package/types/popconfirm/index.d.ts +7 -0
- package/types/popconfirm/interface.d.ts +28 -0
- package/types/popconfirm/style/index.d.ts +5 -0
- package/types/portal/Portal.d.ts +7 -0
- package/types/portal/index.d.ts +10 -0
- package/types/progress/CircleProgress.d.ts +8 -0
- package/types/progress/LineProgess.d.ts +2 -0
- package/types/progress/StepProgress.d.ts +2 -0
- package/types/progress/index.d.ts +5 -0
- package/types/progress/interface.d.ts +22 -0
- package/types/progress/style/index.d.ts +3 -0
- package/types/radio/Group.d.ts +10 -0
- package/types/radio/Radio.d.ts +11 -0
- package/types/radio/index.d.ts +6 -0
- package/types/radio/interface.d.ts +39 -0
- package/types/radio/style/index.d.ts +2 -0
- package/types/rate/index.d.ts +6 -0
- package/types/rate/interface.d.ts +17 -0
- package/types/rate/style/index.d.ts +3 -0
- package/types/resize-box/ResizeTrigger.d.ts +24 -0
- package/types/resize-box/Split.d.ts +4 -0
- package/types/resize-box/SplitGroup.d.ts +4 -0
- package/types/resize-box/index.d.ts +13 -0
- package/types/resize-box/interface.d.ts +73 -0
- package/types/resize-box/style/index.d.ts +2 -0
- package/types/result/403.d.ts +1 -0
- package/types/result/404.d.ts +1 -0
- package/types/result/500.d.ts +1 -0
- package/types/result/index.d.ts +7 -0
- package/types/result/interface.d.ts +11 -0
- package/types/result/style/index.d.ts +2 -0
- package/types/select/OptGroup.d.ts +6 -0
- package/types/select/Option.d.ts +6 -0
- package/types/select/Select.d.ts +10 -0
- package/types/select/index.d.ts +4 -0
- package/types/select/interface.d.ts +102 -0
- package/types/select/style/index.d.ts +6 -0
- package/types/select/util.d.ts +26 -0
- package/types/select-view/Core.d.ts +12 -0
- package/types/select-view/index.d.ts +12 -0
- package/types/select-view/interface.d.ts +60 -0
- package/types/select-view/style/index.d.ts +2 -0
- package/types/skeleton/Image.d.ts +2 -0
- package/types/skeleton/Text.d.ts +2 -0
- package/types/skeleton/index.d.ts +8 -0
- package/types/skeleton/interface.d.ts +24 -0
- package/types/skeleton/style/index.d.ts +2 -0
- package/types/slider/Button.d.ts +21 -0
- package/types/slider/Dot.d.ts +17 -0
- package/types/slider/Input.d.ts +15 -0
- package/types/slider/Mark.d.ts +16 -0
- package/types/slider/Tick.d.ts +14 -0
- package/types/slider/hook/useInterval.d.ts +24 -0
- package/types/slider/hook/useLegalValue.d.ts +15 -0
- package/types/slider/index.d.ts +6 -0
- package/types/slider/interface.d.ts +32 -0
- package/types/slider/style/index.d.ts +5 -0
- package/types/slider/util.d.ts +11 -0
- package/types/space/index.d.ts +5 -0
- package/types/space/interface.d.ts +12 -0
- package/types/space/style/index.d.ts +2 -0
- package/types/space/toArray.d.ts +1 -0
- package/types/speech-synthesis/index.d.ts +1 -0
- package/types/spin/DotLoading.d.ts +5 -0
- package/types/spin/index.d.ts +6 -0
- package/types/spin/interface.d.ts +14 -0
- package/types/spin/style/index.d.ts +2 -0
- package/types/statistic/Countdown.d.ts +4 -0
- package/types/statistic/index.d.ts +8 -0
- package/types/statistic/interface.d.ts +33 -0
- package/types/statistic/style/index.d.ts +3 -0
- package/types/statistic/util.d.ts +1 -0
- package/types/steps/Step.d.ts +4 -0
- package/types/steps/index.d.ts +9 -0
- package/types/steps/interface.d.ts +42 -0
- package/types/steps/style/index.d.ts +2 -0
- package/types/suspense-fallback-test/index.d.ts +3 -0
- package/types/suspense-fallback-test/style/index.d.ts +2 -0
- package/types/switch/index.d.ts +11 -0
- package/types/switch/interface.d.ts +17 -0
- package/types/switch/style/index.d.ts +2 -0
- package/types/table/ColGroup.d.ts +13 -0
- package/types/table/Table.d.ts +10 -0
- package/types/table/constant.d.ts +2 -0
- package/types/table/hook/useColumns.d.ts +3 -0
- package/types/table/hook/useComponent.d.ts +30 -0
- package/types/table/hook/useExpand.d.ts +3 -0
- package/types/table/hook/useRowSelection.d.ts +12 -0
- package/types/table/hook/useSorter.d.ts +7 -0
- package/types/table/hook/useStickyClassNames.d.ts +3 -0
- package/types/table/hook/useStickyOffsets.d.ts +3 -0
- package/types/table/index.d.ts +9 -0
- package/types/table/interface.d.ts +295 -0
- package/types/table/style/index.d.ts +11 -0
- package/types/table/summary/Cell.d.ts +12 -0
- package/types/table/summary/Row.d.ts +7 -0
- package/types/table/summary/context.d.ts +9 -0
- package/types/table/summary/index.d.ts +8 -0
- package/types/table/tbody/Td.d.ts +25 -0
- package/types/table/tbody/Tr.d.ts +16 -0
- package/types/table/tbody/index.d.ts +3 -0
- package/types/table/tfoot/index.d.ts +3 -0
- package/types/table/thead/Column.d.ts +3 -0
- package/types/table/thead/index.d.ts +3 -0
- package/types/table/util.d.ts +17 -0
- package/types/tabs/Tab.d.ts +18 -0
- package/types/tabs/TabContent.d.ts +9 -0
- package/types/tabs/TabPane.d.ts +8 -0
- package/types/tabs/hook/useDomSize.d.ts +11 -0
- package/types/tabs/hook/useHeaderScroll.d.ts +9 -0
- package/types/tabs/index.d.ts +4 -0
- package/types/tabs/interface.d.ts +66 -0
- package/types/tabs/style/index.d.ts +3 -0
- package/types/tabs/tab-header/DropdownIcon.d.ts +1 -0
- package/types/tabs/tab-header/TabInk.d.ts +11 -0
- package/types/tabs/tab-header/TabNavIcon.d.ts +17 -0
- package/types/tabs/tab-header/TabTitle.d.ts +17 -0
- package/types/tabs/tab-header/index.d.ts +4 -0
- package/types/tabs/util.d.ts +12 -0
- package/types/tag/index.d.ts +5 -0
- package/types/tag/interface.d.ts +19 -0
- package/types/tag/style/index.d.ts +2 -0
- package/types/time-picker/Picker.d.ts +15 -0
- package/types/time-picker/RangePicker.d.ts +12 -0
- package/types/time-picker/TimeColumn.d.ts +17 -0
- package/types/time-picker/TimePicker.d.ts +24 -0
- package/types/time-picker/context.d.ts +6 -0
- package/types/time-picker/index.d.ts +5 -0
- package/types/time-picker/interface.d.ts +62 -0
- package/types/time-picker/style/index.d.ts +5 -0
- package/types/time-picker/util.d.ts +7 -0
- package/types/timeline/Item.d.ts +7 -0
- package/types/timeline/Timeline.d.ts +10 -0
- package/types/timeline/index.d.ts +4 -0
- package/types/timeline/interface.d.ts +26 -0
- package/types/timeline/style/index.d.ts +2 -0
- package/types/tooltip/index.d.ts +10 -0
- package/types/tooltip/interface.d.ts +23 -0
- package/types/tooltip/style/index.d.ts +3 -0
- package/types/transfer/Item.d.ts +3 -0
- package/types/transfer/List.d.ts +5 -0
- package/types/transfer/index.d.ts +6 -0
- package/types/transfer/interface.d.ts +91 -0
- package/types/transfer/style/index.d.ts +6 -0
- package/types/tree/Animation.d.ts +4 -0
- package/types/tree/Context.d.ts +28 -0
- package/types/tree/Node.d.ts +12 -0
- package/types/tree/NodeList.d.ts +2 -0
- package/types/tree/Tree.d.ts +73 -0
- package/types/tree/index.d.ts +8 -0
- package/types/tree/interface.d.ts +152 -0
- package/types/tree/style/index.d.ts +3 -0
- package/types/tree/util.d.ts +13 -0
- package/types/tree-select/List.d.ts +11 -0
- package/types/tree-select/Select.d.ts +12 -0
- package/types/tree-select/hook/useKeyCache.d.ts +6 -0
- package/types/tree-select/hook/useStateValue.d.ts +22 -0
- package/types/tree-select/hook/useTreeData.d.ts +3 -0
- package/types/tree-select/index.d.ts +4 -0
- package/types/tree-select/interface.d.ts +79 -0
- package/types/tree-select/style/index.d.ts +5 -0
- package/types/tree-select/util.d.ts +1 -0
- package/types/trigger/Portal.d.ts +7 -0
- package/types/trigger/getPopupStyle.d.ts +20 -0
- package/types/trigger/index.d.ts +125 -0
- package/types/trigger/interface.d.ts +71 -0
- package/types/trigger/style/index.d.ts +2 -0
- package/types/typography/Base.d.ts +7 -0
- package/types/typography/EditContent.d.ts +2 -0
- package/types/typography/Ellipsis.d.ts +6 -0
- package/types/typography/Operations.d.ts +3 -0
- package/types/typography/Paragraph.d.ts +6 -0
- package/types/typography/Text.d.ts +6 -0
- package/types/typography/Title.d.ts +6 -0
- package/types/typography/Typography.d.ts +3 -0
- package/types/typography/index.d.ts +12 -0
- package/types/typography/interface.d.ts +97 -0
- package/types/typography/style/index.d.ts +5 -0
- package/types/typography/useCssEllipsis.d.ts +6 -0
- package/types/typography/useEllipsis.d.ts +21 -0
- package/types/upload/TriggerNode.d.ts +4 -0
- package/types/upload/Upload.d.ts +12 -0
- package/types/upload/Uploader.d.ts +15 -0
- package/types/upload/index.d.ts +4 -0
- package/types/upload/interface.d.ts +126 -0
- package/types/upload/list/PictureItem.d.ts +8 -0
- package/types/upload/list/TextItem.d.ts +8 -0
- package/types/upload/list/UploadProgress.d.ts +14 -0
- package/types/upload/list/index.d.ts +6 -0
- package/types/upload/request.d.ts +3 -0
- package/types/upload/style/index.d.ts +6 -0
- package/types/upload/util.d.ts +4 -0
- package/types/utils/className.d.ts +2 -0
- package/types/utils/constant.d.ts +3 -0
- package/types/utils/contextHolder.d.ts +9 -0
- package/types/utils/dayjs.d.ts +21 -0
- package/types/utils/dom.d.ts +6 -0
- package/types/utils/fillNBSP.d.ts +1 -0
- package/types/utils/getHighlightText.d.ts +5 -0
- package/types/utils/getHotkeyHandler.d.ts +8 -0
- package/types/utils/getStringLength.d.ts +1 -0
- package/types/utils/include.d.ts +1 -0
- package/types/utils/is.d.ts +23 -0
- package/types/utils/keyCode.d.ts +45 -0
- package/types/utils/mergeProp.d.ts +1 -0
- package/types/utils/mergedToString.d.ts +1 -0
- package/types/utils/omit.d.ts +1 -0
- package/types/utils/pad.d.ts +2 -0
- package/types/utils/pick.d.ts +4 -0
- package/types/utils/raf.d.ts +3 -0
- package/types/utils/reactDOM.d.ts +5 -0
- package/types/utils/responsiveObserve.d.ts +15 -0
- package/types/utils/scrollIntoView.d.ts +2 -0
- package/types/utils/style.d.ts +3 -0
- package/types/utils/throttleByRaf.d.ts +4 -0
- package/types/utils/throttleByRafV2.d.ts +4 -0
- package/types/utils/type.d.ts +4 -0
- package/types/utils/warning.d.ts +1 -0
- package/types/verification-code/VerificationCode.d.ts +7 -0
- package/types/verification-code/index.d.ts +5 -0
- package/types/verification-code/interface.d.ts +25 -0
- package/types/verification-code/style/index.d.ts +3 -0
- package/types/version/index.d.ts +2 -0
- package/types/virtual-list/Filler.d.ts +10 -0
- package/types/virtual-list/VirtualList.d.ts +39 -0
- package/types/virtual-list/index.d.ts +4 -0
- package/types/virtual-list/style/index.d.ts +2 -0
- package/types/virtual-list/util/algorithm.d.ts +6 -0
- package/types/virtual-list/util/item.d.ts +44 -0
- package/types/watermark/Watermark.d.ts +4 -0
- package/types/watermark/index.d.ts +5 -0
- package/types/watermark/interface.d.ts +21 -0
- package/types/watermark/style/index.d.ts +1 -0
- package/utils/className.js +5 -0
- package/utils/constant.js +23 -0
- package/utils/contextHolder.js +6 -0
- package/utils/dayjs.js +174 -0
- package/utils/dom.js +47 -0
- package/utils/fillNBSP.js +6 -0
- package/utils/getHighlightText.js +41 -0
- package/utils/getHotkeyHandler.js +27 -0
- package/utils/getStringLength.js +9 -0
- package/utils/include.js +9 -0
- package/utils/is.js +94 -0
- package/utils/keyCode.js +48 -0
- package/utils/mergeProp.js +11 -0
- package/utils/mergedToString.js +14 -0
- package/utils/omit.js +11 -0
- package/utils/pad.js +18 -0
- package/utils/pick.js +17 -0
- package/utils/raf.js +19 -0
- package/utils/reactDOM.js +36 -0
- package/utils/responsiveObserve.js +65 -0
- package/utils/scrollIntoView.js +22 -0
- package/utils/style.js +39 -0
- package/utils/throttleByRaf.js +15 -0
- package/utils/throttleByRafV2.js +16 -0
- package/utils/type.js +1 -0
- package/utils/warning.js +6 -0
package/Table.js
ADDED
|
@@ -0,0 +1,2001 @@
|
|
|
1
|
+
import "./chunk/DP2rzg_V.js";
|
|
2
|
+
import "./chunk/C6Kfwj0f.js";
|
|
3
|
+
import { C as It } from "./chunk/BVC51EZ7.js";
|
|
4
|
+
import { a as Xe } from "./chunk/Dc_89PVN.js";
|
|
5
|
+
import "./chunk/RnTpOC5-.js";
|
|
6
|
+
import "./Tag.js";
|
|
7
|
+
import "./chunk/DF-4xm4m.js";
|
|
8
|
+
import Fn from "./Trigger.js";
|
|
9
|
+
import "./chunk/BdWYJb9B.js";
|
|
10
|
+
import { P as Qt } from "./chunk/Kt5-772l.js";
|
|
11
|
+
import { R as rn } from "./chunk/DYwvc9zo.js";
|
|
12
|
+
import Ln from "./Space.js";
|
|
13
|
+
import On from "./Spin.js";
|
|
14
|
+
import sn from "./Tooltip.js";
|
|
15
|
+
import { jsx as a, jsxs as ue, Fragment as yt } from "react/jsx-runtime";
|
|
16
|
+
import { Tween as Bn, quintInOut as Kn } from "@unicom-cloud/utils/tween";
|
|
17
|
+
import Dn from "lodash/debounce";
|
|
18
|
+
import ie from "lodash/isArray";
|
|
19
|
+
import He from "lodash/isNumber";
|
|
20
|
+
import q from "lodash/isPlainObject";
|
|
21
|
+
import Hn from "lodash/throttle";
|
|
22
|
+
import Pe, { useRef as xe, useEffect as nt, useMemo as de, useCallback as tt, useState as we, useContext as We, forwardRef as Pt, createElement as ln, createContext as Wn, useImperativeHandle as Mn } from "react";
|
|
23
|
+
import zn from "./hooks/useIsomorphicLayoutEffect.js";
|
|
24
|
+
import Jt from "./hooks/useMergeProps.js";
|
|
25
|
+
import Tt from "./hooks/useUpdateEffect.js";
|
|
26
|
+
import ne from "@unicom-cloud/utils/class-name";
|
|
27
|
+
import { on as ut, off as ht } from "./utils/dom.js";
|
|
28
|
+
import Un, { pickDataAttributes as Vn } from "./utils/pick.js";
|
|
29
|
+
import jn from "lodash/merge";
|
|
30
|
+
import Yn from "lodash/isNull";
|
|
31
|
+
import Ye from "lodash/isString";
|
|
32
|
+
import qn from "lodash/isUndefined";
|
|
33
|
+
import { V as Gn } from "./chunk/BGzBxiWE.js";
|
|
34
|
+
import Xn from "@unicom-cloud/icons/IconUiMinus";
|
|
35
|
+
import Qn from "@unicom-cloud/icons/IconUiPlus";
|
|
36
|
+
import xt from "lodash/get";
|
|
37
|
+
import kt from "lodash/isFunction";
|
|
38
|
+
import Jn from "./hooks/useForceUpdate.js";
|
|
39
|
+
import Zn from "./utils/mergedToString.js";
|
|
40
|
+
import eo from "@unicom-cloud/icons/IconUiCaretDown";
|
|
41
|
+
import to from "@unicom-cloud/icons/IconUiCaretUp";
|
|
42
|
+
import no from "@unicom-cloud/icons/IconUiFilter";
|
|
43
|
+
import Zt from "./Button.js";
|
|
44
|
+
import oo from "./hooks/useMergeValue.js";
|
|
45
|
+
import ro from "./utils/omit.js";
|
|
46
|
+
const qe = "table_internal_selection_key", Ge = "table_internal_expand_key";
|
|
47
|
+
function St(t) {
|
|
48
|
+
return typeof t == "number" || typeof t == "string" ? {
|
|
49
|
+
width: t
|
|
50
|
+
} : {};
|
|
51
|
+
}
|
|
52
|
+
function mt(t) {
|
|
53
|
+
var y;
|
|
54
|
+
const o = xe(), {
|
|
55
|
+
prefixCls: r,
|
|
56
|
+
columns: h,
|
|
57
|
+
columnWidths: e,
|
|
58
|
+
producer: d,
|
|
59
|
+
expandedRowKeys: c,
|
|
60
|
+
data: l,
|
|
61
|
+
onSetColumnWidths: s
|
|
62
|
+
} = t;
|
|
63
|
+
nt(() => {
|
|
64
|
+
if (d && o.current) {
|
|
65
|
+
const N = Array.from(
|
|
66
|
+
o.current.querySelectorAll("col") || []
|
|
67
|
+
).filter(
|
|
68
|
+
(g) => !g.classList.contains(`${r}-expand-icon-col`) && !g.classList.contains(`${r}-selection-col`)
|
|
69
|
+
).map((g) => {
|
|
70
|
+
const { width: T } = g.getBoundingClientRect();
|
|
71
|
+
return T;
|
|
72
|
+
});
|
|
73
|
+
s == null || s(N);
|
|
74
|
+
}
|
|
75
|
+
}, [d, s, r, c, l, h]);
|
|
76
|
+
let C = 0;
|
|
77
|
+
return /* @__PURE__ */ a("colgroup", { ref: o, children: (y = h == null ? void 0 : h.map) == null ? void 0 : y.call(h, (m, N) => {
|
|
78
|
+
if (m.title === Ge)
|
|
79
|
+
return /* @__PURE__ */ a(
|
|
80
|
+
"col",
|
|
81
|
+
{
|
|
82
|
+
className: `${r}-expand-icon-col`,
|
|
83
|
+
style: St(m.width)
|
|
84
|
+
},
|
|
85
|
+
Ge
|
|
86
|
+
);
|
|
87
|
+
if (m.title === qe)
|
|
88
|
+
return /* @__PURE__ */ a(
|
|
89
|
+
"col",
|
|
90
|
+
{
|
|
91
|
+
className: `${r}-selection-col`,
|
|
92
|
+
style: St(m.width)
|
|
93
|
+
},
|
|
94
|
+
qe
|
|
95
|
+
);
|
|
96
|
+
let g;
|
|
97
|
+
return m.width ? g = m.width : !d && e && (g = e[C]), C++, /* @__PURE__ */ a("col", { style: St(g) }, m.key ?? N);
|
|
98
|
+
}) });
|
|
99
|
+
}
|
|
100
|
+
const en = {
|
|
101
|
+
table: "table",
|
|
102
|
+
header: {
|
|
103
|
+
operations: ({ selectionNode: t, expandNode: o }) => [
|
|
104
|
+
{
|
|
105
|
+
name: "expandNode",
|
|
106
|
+
node: o
|
|
107
|
+
},
|
|
108
|
+
{
|
|
109
|
+
name: "selectionNode",
|
|
110
|
+
node: t
|
|
111
|
+
}
|
|
112
|
+
],
|
|
113
|
+
wrapper: "div",
|
|
114
|
+
thead: "thead",
|
|
115
|
+
row: "tr",
|
|
116
|
+
th: "th",
|
|
117
|
+
cell: "div"
|
|
118
|
+
},
|
|
119
|
+
body: {
|
|
120
|
+
operations: ({ selectionNode: t, expandNode: o }) => [
|
|
121
|
+
{
|
|
122
|
+
name: "expandNode",
|
|
123
|
+
node: o
|
|
124
|
+
},
|
|
125
|
+
{
|
|
126
|
+
name: "selectionNode",
|
|
127
|
+
node: t
|
|
128
|
+
}
|
|
129
|
+
],
|
|
130
|
+
wrapper: "div",
|
|
131
|
+
tbody: "tbody",
|
|
132
|
+
row: "tr",
|
|
133
|
+
td: "td",
|
|
134
|
+
cell: "span"
|
|
135
|
+
}
|
|
136
|
+
};
|
|
137
|
+
function Me(t) {
|
|
138
|
+
const o = de(
|
|
139
|
+
() => q(t) ? jn({}, en, t) : en,
|
|
140
|
+
[t]
|
|
141
|
+
);
|
|
142
|
+
return {
|
|
143
|
+
getHeaderComponentOperations: o.header.operations,
|
|
144
|
+
getBodyComponentOperations: o.body.operations,
|
|
145
|
+
ComponentTable: o.table,
|
|
146
|
+
ComponentHeaderWrapper: o.header.wrapper,
|
|
147
|
+
ComponentThead: o.header.thead,
|
|
148
|
+
ComponentHeaderRow: o.header.row,
|
|
149
|
+
ComponentTh: o.header.th,
|
|
150
|
+
ComponentHeaderCell: o.header.cell,
|
|
151
|
+
ComponentBodyWrapper: o.body.wrapper,
|
|
152
|
+
ComponentTbody: o.body.tbody,
|
|
153
|
+
ComponentBodyRow: o.body.row,
|
|
154
|
+
ComponentTd: o.body.td,
|
|
155
|
+
ComponentBodyCell: o.body.cell
|
|
156
|
+
};
|
|
157
|
+
}
|
|
158
|
+
function tn(t, o) {
|
|
159
|
+
const r = [];
|
|
160
|
+
function h(e) {
|
|
161
|
+
e && e.length > 0 && e.forEach((d) => {
|
|
162
|
+
d[o] ? h(d[o]) : r.push({ ...d, key: d.dataIndex || d.key });
|
|
163
|
+
});
|
|
164
|
+
}
|
|
165
|
+
return h(t), r;
|
|
166
|
+
}
|
|
167
|
+
function cn(t, o) {
|
|
168
|
+
let r = 0;
|
|
169
|
+
return t && t.length > 0 && t.forEach((h) => {
|
|
170
|
+
const e = cn(h[o], o) + 1;
|
|
171
|
+
r = Math.max(e, r);
|
|
172
|
+
}), r;
|
|
173
|
+
}
|
|
174
|
+
function so(t) {
|
|
175
|
+
const {
|
|
176
|
+
component: o,
|
|
177
|
+
rowSelection: r,
|
|
178
|
+
expandedRowRender: h,
|
|
179
|
+
expandProps: e = {},
|
|
180
|
+
columns: d = [],
|
|
181
|
+
childrenColumnName: c
|
|
182
|
+
} = t, l = de(() => d || [], [d]), s = de(
|
|
183
|
+
() => tn(l, c),
|
|
184
|
+
[l, c]
|
|
185
|
+
), C = r && r.type === "checkbox" || r && !("type" in r), y = r && r.type === "radio", { width: m } = e, N = !!h, g = C || y, { getHeaderComponentOperations: T, getBodyComponentOperations: _ } = Me(o), S = de(
|
|
186
|
+
() => T({
|
|
187
|
+
selectionNode: g ? "holder_node" : "",
|
|
188
|
+
expandNode: N ? "holder_node" : ""
|
|
189
|
+
}),
|
|
190
|
+
[
|
|
191
|
+
g,
|
|
192
|
+
N,
|
|
193
|
+
T
|
|
194
|
+
]
|
|
195
|
+
), w = de(
|
|
196
|
+
() => _({
|
|
197
|
+
selectionNode: g ? "holder_node" : "",
|
|
198
|
+
expandNode: N ? "holder_node" : ""
|
|
199
|
+
}),
|
|
200
|
+
[
|
|
201
|
+
g,
|
|
202
|
+
N,
|
|
203
|
+
_
|
|
204
|
+
]
|
|
205
|
+
), p = r && r.fixed, k = r && r.columnWidth, B = tt(
|
|
206
|
+
(K, P, E) => {
|
|
207
|
+
const I = {}, D = [];
|
|
208
|
+
K.forEach((x, A) => {
|
|
209
|
+
const $ = { ...x };
|
|
210
|
+
(!("key" in x) || typeof x.key > "u") && ($.key = $.dataIndex || A), A === 0 ? ($.$$isFirstColumn = !0, $.fixed === "left" && (I.fixed = $.fixed)) : $.$$isFirstColumn = !1, D.push($);
|
|
211
|
+
});
|
|
212
|
+
const H = N && {
|
|
213
|
+
key: Ge,
|
|
214
|
+
title: Ge,
|
|
215
|
+
width: m,
|
|
216
|
+
$$isOperation: !0
|
|
217
|
+
}, O = g && {
|
|
218
|
+
key: qe,
|
|
219
|
+
title: qe,
|
|
220
|
+
width: k,
|
|
221
|
+
$$isOperation: !0
|
|
222
|
+
};
|
|
223
|
+
return p && (I.fixed = "left"), (typeof E != "number" || E === 0) && [...P].reverse().forEach((x, A) => {
|
|
224
|
+
if (x.node) {
|
|
225
|
+
const $ = S.filter((R) => R.node).length - A - 1;
|
|
226
|
+
x.name === "expandNode" ? D.unshift({
|
|
227
|
+
...H,
|
|
228
|
+
...I,
|
|
229
|
+
$$columnIndex: $
|
|
230
|
+
}) : x.name === "selectionNode" ? D.unshift({
|
|
231
|
+
...O,
|
|
232
|
+
...I,
|
|
233
|
+
$$columnIndex: $
|
|
234
|
+
}) : D.unshift({
|
|
235
|
+
...x,
|
|
236
|
+
...I,
|
|
237
|
+
title: x.name,
|
|
238
|
+
key: x.name,
|
|
239
|
+
$$isOperation: !0,
|
|
240
|
+
width: x.width || 40,
|
|
241
|
+
$$columnIndex: $
|
|
242
|
+
});
|
|
243
|
+
}
|
|
244
|
+
}), D;
|
|
245
|
+
},
|
|
246
|
+
[
|
|
247
|
+
m,
|
|
248
|
+
N,
|
|
249
|
+
g,
|
|
250
|
+
k,
|
|
251
|
+
p,
|
|
252
|
+
S
|
|
253
|
+
]
|
|
254
|
+
), G = de(
|
|
255
|
+
() => B(s, w),
|
|
256
|
+
[s, B, w]
|
|
257
|
+
), ee = de(
|
|
258
|
+
() => cn(l, c),
|
|
259
|
+
[l, c]
|
|
260
|
+
);
|
|
261
|
+
return [de(() => {
|
|
262
|
+
const K = Array.isArray(S) ? S.filter((D) => D.node).length : 0;
|
|
263
|
+
if (ee === 1) {
|
|
264
|
+
const D = l.map((H, O) => ({
|
|
265
|
+
...H,
|
|
266
|
+
$$columnIndex: O + K
|
|
267
|
+
}));
|
|
268
|
+
return [B(D, S, 0)];
|
|
269
|
+
}
|
|
270
|
+
let P = K;
|
|
271
|
+
const E = [], I = (D, H = 0) => {
|
|
272
|
+
E[H] = E[H] || [], D.forEach((O) => {
|
|
273
|
+
const x = { ...O };
|
|
274
|
+
x[c] ? (x.colSpan = tn(
|
|
275
|
+
O[c],
|
|
276
|
+
c
|
|
277
|
+
).length, x.$$columnIndex = [P], E[H].push(x), I(x[c], H + 1), x.$$columnIndex.push(P - 1)) : (x.rowSpan = ee - H, x.$$columnIndex = P++, E[H].push(x));
|
|
278
|
+
}), E[H] = B(
|
|
279
|
+
E[H],
|
|
280
|
+
S,
|
|
281
|
+
H
|
|
282
|
+
);
|
|
283
|
+
};
|
|
284
|
+
return I(l), E;
|
|
285
|
+
}, [
|
|
286
|
+
l,
|
|
287
|
+
c,
|
|
288
|
+
ee,
|
|
289
|
+
B,
|
|
290
|
+
S
|
|
291
|
+
]), G];
|
|
292
|
+
}
|
|
293
|
+
function Rt(t) {
|
|
294
|
+
return He(t) ? t : Ye(t) && t.includes("px") ? +t.replace("px", "") : t;
|
|
295
|
+
}
|
|
296
|
+
function io(t) {
|
|
297
|
+
return t ? t.offsetHeight - t.clientHeight : 0;
|
|
298
|
+
}
|
|
299
|
+
function lo(t) {
|
|
300
|
+
return t ? t.offsetWidth - t.clientWidth : 0;
|
|
301
|
+
}
|
|
302
|
+
function vt(t, o) {
|
|
303
|
+
return ie(t[o]) && t[o].length;
|
|
304
|
+
}
|
|
305
|
+
function co(t, o) {
|
|
306
|
+
function r(h) {
|
|
307
|
+
if (!h)
|
|
308
|
+
return [];
|
|
309
|
+
const e = [];
|
|
310
|
+
return h.forEach((d) => {
|
|
311
|
+
if (!q(d))
|
|
312
|
+
e.push(d);
|
|
313
|
+
else {
|
|
314
|
+
const c = { ...d };
|
|
315
|
+
c.__ORIGIN_DATA = d;
|
|
316
|
+
const l = c[o];
|
|
317
|
+
q(c) && l && ie(l) && (c[o] = r(l)), e.push(c);
|
|
318
|
+
}
|
|
319
|
+
}), e;
|
|
320
|
+
}
|
|
321
|
+
return r(t);
|
|
322
|
+
}
|
|
323
|
+
function te(t) {
|
|
324
|
+
return q(t) ? t.__ORIGIN_DATA : !t || !ie(t) ? t : t.map((o) => !q(o) || !("__ORIGIN_DATA" in o) ? o : o.__ORIGIN_DATA);
|
|
325
|
+
}
|
|
326
|
+
function ao(t, o, r = [], h = [], e, d, c) {
|
|
327
|
+
const l = new Set(r), s = new Set(h);
|
|
328
|
+
function C(y) {
|
|
329
|
+
o ? (l.add(e(y)), s.delete(e(y))) : l.delete(e(y)), ie(y[d]) && y[d].forEach((m) => {
|
|
330
|
+
C(m);
|
|
331
|
+
});
|
|
332
|
+
}
|
|
333
|
+
return c ? (C(t), At(
|
|
334
|
+
t,
|
|
335
|
+
l,
|
|
336
|
+
s,
|
|
337
|
+
e,
|
|
338
|
+
d
|
|
339
|
+
)) : o ? l.add(e(t)) : l.delete(e(t)), {
|
|
340
|
+
selectedRowKeys: [...l],
|
|
341
|
+
indeterminateKeys: [...s]
|
|
342
|
+
};
|
|
343
|
+
}
|
|
344
|
+
function fo(t, o = [], r, h, e) {
|
|
345
|
+
if (!e)
|
|
346
|
+
return {
|
|
347
|
+
selectedRowKeys: o,
|
|
348
|
+
indeterminateKeys: []
|
|
349
|
+
};
|
|
350
|
+
const d = new Set(o), c = /* @__PURE__ */ new Set([]);
|
|
351
|
+
function l(s) {
|
|
352
|
+
d.add(r(s)), c.delete(r(s)), ie(s[h]) && s[h].forEach((C) => {
|
|
353
|
+
l(C);
|
|
354
|
+
});
|
|
355
|
+
}
|
|
356
|
+
return o.forEach((s) => {
|
|
357
|
+
const C = t.find((y) => r(y) === s);
|
|
358
|
+
!qn(C) && !Yn(C) && (l(C), At(
|
|
359
|
+
C,
|
|
360
|
+
d,
|
|
361
|
+
c,
|
|
362
|
+
r,
|
|
363
|
+
h
|
|
364
|
+
));
|
|
365
|
+
}), {
|
|
366
|
+
selectedRowKeys: [...d],
|
|
367
|
+
indeterminateKeys: [...c]
|
|
368
|
+
};
|
|
369
|
+
}
|
|
370
|
+
function At(t, o, r, h, e) {
|
|
371
|
+
if (t.__INTERNAL_PARENT) {
|
|
372
|
+
const d = h(t.__INTERNAL_PARENT);
|
|
373
|
+
if (ie(t.__INTERNAL_PARENT[e])) {
|
|
374
|
+
const c = t.__INTERNAL_PARENT[e].length;
|
|
375
|
+
let l = 0, s = !1;
|
|
376
|
+
t.__INTERNAL_PARENT[e].forEach((C) => {
|
|
377
|
+
o.has(h(C)) && (l += 1), r.has(h(C)) && (r.add(d), s = !0);
|
|
378
|
+
}), c === l ? (o.add(d), r.delete(d)) : l > 0 && c > l ? (o.delete(d), r.add(d)) : l === 0 && (o.delete(d), s || r.delete(d));
|
|
379
|
+
}
|
|
380
|
+
At(
|
|
381
|
+
t.__INTERNAL_PARENT,
|
|
382
|
+
o,
|
|
383
|
+
r,
|
|
384
|
+
h,
|
|
385
|
+
e
|
|
386
|
+
);
|
|
387
|
+
}
|
|
388
|
+
}
|
|
389
|
+
function _t(t) {
|
|
390
|
+
return typeof t == "function" ? t : typeof t == "object" && typeof t.compare == "function" ? t.compare : null;
|
|
391
|
+
}
|
|
392
|
+
function Et(t) {
|
|
393
|
+
if (typeof t == "object" && typeof t.multiple == "number")
|
|
394
|
+
return t.multiple;
|
|
395
|
+
}
|
|
396
|
+
function po(t, o, r) {
|
|
397
|
+
const {
|
|
398
|
+
defaultExpandedRowKeys: h,
|
|
399
|
+
defaultExpandAllRows: e,
|
|
400
|
+
expandedRowRender: d,
|
|
401
|
+
onExpand: c,
|
|
402
|
+
onExpandedRowsChange: l,
|
|
403
|
+
childrenColumnName: s = "children",
|
|
404
|
+
expandProps: C
|
|
405
|
+
} = t, [y, m] = we(
|
|
406
|
+
g()
|
|
407
|
+
), N = t.expandedRowKeys || y;
|
|
408
|
+
function g() {
|
|
409
|
+
let S = [];
|
|
410
|
+
return t.expandedRowKeys ? S = t.expandedRowKeys : h ? S = h : e && (S = o.map((w, p) => {
|
|
411
|
+
const k = te(w);
|
|
412
|
+
return C && "rowExpandable" in C && typeof C.rowExpandable == "function" ? C.rowExpandable(k) && r(w) : typeof d == "function" ? d(k, p) && r(w) : vt(w, s) && r(w);
|
|
413
|
+
}).filter((w) => w)), S;
|
|
414
|
+
}
|
|
415
|
+
function T(S) {
|
|
416
|
+
const w = N.indexOf(S) === -1, p = w ? N.concat(S) : N.filter((B) => S !== B), k = o.filter((B) => p.indexOf(r(B)) !== -1).map((B) => r(B));
|
|
417
|
+
m(k), _(S, w), l == null || l(k);
|
|
418
|
+
}
|
|
419
|
+
function _(S, w) {
|
|
420
|
+
c == null || c(
|
|
421
|
+
te(o.find((p) => r(p) === S)),
|
|
422
|
+
w
|
|
423
|
+
);
|
|
424
|
+
}
|
|
425
|
+
return [N, T];
|
|
426
|
+
}
|
|
427
|
+
function nn(t) {
|
|
428
|
+
return [...new Set(t)];
|
|
429
|
+
}
|
|
430
|
+
function uo(t, o, r, h) {
|
|
431
|
+
const { rowSelection: e, childrenColumnName: d } = t, c = e == null ? void 0 : e.selectedRowKeys, l = e == null ? void 0 : e.onSelectAll, s = e == null ? void 0 : e.onSelect, C = e == null ? void 0 : e.onChange, y = e == null ? void 0 : e.pureKeys, m = typeof (e == null ? void 0 : e.checkStrictly) == "boolean" ? !e.checkStrictly : !1, N = e == null ? void 0 : e.preserveSelectedRowKeys;
|
|
432
|
+
function g() {
|
|
433
|
+
const x = [], A = [], $ = (F) => {
|
|
434
|
+
ie(F) && F.length && F.forEach((f) => {
|
|
435
|
+
const v = h(f);
|
|
436
|
+
(e && typeof e.checkboxProps == "function" ? e.checkboxProps(te(f)) : {}).disabled || x.push(v), vt(f, t.childrenColumnName) && $(f[t.childrenColumnName]);
|
|
437
|
+
});
|
|
438
|
+
};
|
|
439
|
+
$(o);
|
|
440
|
+
const R = (F, f) => {
|
|
441
|
+
ie(F) && F.length && F.forEach((v) => {
|
|
442
|
+
if (f && m && (v.__INTERNAL_PARENT = f), A.push(v), vt(v, t.childrenColumnName)) {
|
|
443
|
+
const Y = { ...v };
|
|
444
|
+
R(v[t.childrenColumnName], Y);
|
|
445
|
+
}
|
|
446
|
+
});
|
|
447
|
+
};
|
|
448
|
+
return R(r, void 0), {
|
|
449
|
+
allSelectedRowKeys: x,
|
|
450
|
+
flattenData: A
|
|
451
|
+
};
|
|
452
|
+
}
|
|
453
|
+
const { allSelectedRowKeys: T, flattenData: _ } = g(), [S, w] = we([]), [p, k] = we([]), B = fo(
|
|
454
|
+
_,
|
|
455
|
+
nn(c || S),
|
|
456
|
+
h,
|
|
457
|
+
d,
|
|
458
|
+
m
|
|
459
|
+
), G = m && !c ? S : B.selectedRowKeys, ee = m && !c ? p : B.indeterminateKeys, [V, K] = we(
|
|
460
|
+
y ? [] : P(G)
|
|
461
|
+
);
|
|
462
|
+
function P(x, A) {
|
|
463
|
+
const $ = A ? V.concat(_) : _, R = new Map($.map((F) => [h(F), F]));
|
|
464
|
+
return x.map((F) => R.get(F)).filter((F) => F);
|
|
465
|
+
}
|
|
466
|
+
const E = new Set(_.map((x) => h(x)));
|
|
467
|
+
function I(x) {
|
|
468
|
+
return N ? x : x.filter((A) => E.has(A));
|
|
469
|
+
}
|
|
470
|
+
function D(x) {
|
|
471
|
+
let A = [], $ = [];
|
|
472
|
+
if (x)
|
|
473
|
+
A = I(
|
|
474
|
+
nn(G.concat(T))
|
|
475
|
+
);
|
|
476
|
+
else {
|
|
477
|
+
const F = new Set(T);
|
|
478
|
+
A = I(
|
|
479
|
+
G.filter((f) => !F.has(f))
|
|
480
|
+
);
|
|
481
|
+
}
|
|
482
|
+
y || ($ = P(A, !0));
|
|
483
|
+
const R = te($);
|
|
484
|
+
w(A), K($), k([]), C == null || C(A, R), l == null || l(x, R);
|
|
485
|
+
}
|
|
486
|
+
function H(x, A) {
|
|
487
|
+
const { selectedRowKeys: $, indeterminateKeys: R } = ao(
|
|
488
|
+
A,
|
|
489
|
+
x,
|
|
490
|
+
G,
|
|
491
|
+
p,
|
|
492
|
+
h,
|
|
493
|
+
d,
|
|
494
|
+
m
|
|
495
|
+
), F = I($), f = P(F, !0), v = te(f);
|
|
496
|
+
w(F), K(f), k(R), s == null || s(x, te(A), v), C == null || C(F, v);
|
|
497
|
+
}
|
|
498
|
+
function O(x, A) {
|
|
499
|
+
const $ = [_.find((F) => h(F) === x)], R = te($);
|
|
500
|
+
w([x]), s == null || s(!0, te(A), R), C == null || C([x], R);
|
|
501
|
+
}
|
|
502
|
+
return {
|
|
503
|
+
selectedRowKeys: G,
|
|
504
|
+
indeterminateKeys: ee,
|
|
505
|
+
onCheckAll: D,
|
|
506
|
+
onCheck: H,
|
|
507
|
+
onCheckRadio: O,
|
|
508
|
+
setSelectedRowKeys: w,
|
|
509
|
+
allSelectedRowKeys: T,
|
|
510
|
+
flattenData: _
|
|
511
|
+
};
|
|
512
|
+
}
|
|
513
|
+
function ho(t, o) {
|
|
514
|
+
const [r, h] = we(o), [e, d] = we({}), c = xe(t), l = tt(
|
|
515
|
+
(y) => {
|
|
516
|
+
const { field: m, direction: N } = y;
|
|
517
|
+
return r.find((g) => g.field === m) ? N ? r.map(
|
|
518
|
+
(g) => g.field === m ? y : g
|
|
519
|
+
) : r.filter((g) => g.field !== m) : N ? !He(y.priority) || r.find((g) => !He(g.priority)) ? [y] : [...r, y] : [...r];
|
|
520
|
+
},
|
|
521
|
+
[r]
|
|
522
|
+
), s = tt((y) => {
|
|
523
|
+
const m = y.filter((g) => "sortOrder" in g);
|
|
524
|
+
let N = [];
|
|
525
|
+
return m.forEach((g) => {
|
|
526
|
+
const T = Et(g.sorter), _ = g.sortOrder, S = {
|
|
527
|
+
field: g.dataIndex || g.key,
|
|
528
|
+
direction: _,
|
|
529
|
+
sorterFn: _t(g.sorter),
|
|
530
|
+
priority: T
|
|
531
|
+
};
|
|
532
|
+
_ ? He(T) ? N.every((w) => He(w.priority) || !w.direction) && N.push(S) : N.every((w) => !w.direction) ? N.push(S) : N = [S] : N.push(S);
|
|
533
|
+
}), N;
|
|
534
|
+
}, []), C = tt(
|
|
535
|
+
(y, m) => {
|
|
536
|
+
s(t).length || (h(m), d(y));
|
|
537
|
+
},
|
|
538
|
+
[t, s, h, d]
|
|
539
|
+
);
|
|
540
|
+
return Tt(() => {
|
|
541
|
+
const y = c.current, m = s(y), N = s(t), g = m.map(
|
|
542
|
+
(_) => _.field
|
|
543
|
+
), T = N.filter((_) => m.find(
|
|
544
|
+
({ field: w, direction: p }) => _.field === w && _.direction !== p
|
|
545
|
+
) ? !0 : !g.includes(_.field));
|
|
546
|
+
T && T.length && (h(N), d({})), c.current = t;
|
|
547
|
+
}, [
|
|
548
|
+
t,
|
|
549
|
+
s,
|
|
550
|
+
l,
|
|
551
|
+
d,
|
|
552
|
+
h
|
|
553
|
+
]), {
|
|
554
|
+
currentSorter: e,
|
|
555
|
+
activeSorters: r,
|
|
556
|
+
getNextActiveSorters: l,
|
|
557
|
+
updateStateSorters: C
|
|
558
|
+
};
|
|
559
|
+
}
|
|
560
|
+
function mo(t, o, r) {
|
|
561
|
+
const h = o.map((l) => l.fixed);
|
|
562
|
+
function e(l, s) {
|
|
563
|
+
return ne({
|
|
564
|
+
[`${r}-col-fixed-left`]: l.fixed === "left",
|
|
565
|
+
[`${r}-col-fixed-right`]: l.fixed === "right",
|
|
566
|
+
[`${r}-col-fixed-left-last`]: l.fixed === "left" && (q(o[s + 1]) ? o[s + 1].fixed !== "left" : !0),
|
|
567
|
+
[`${r}-col-fixed-right-first`]: l.fixed === "right" && (q(o[s - 1]) ? o[s - 1].fixed !== "right" : !0)
|
|
568
|
+
});
|
|
569
|
+
}
|
|
570
|
+
const d = de(() => o.map(
|
|
571
|
+
(l, s) => e(l, s)
|
|
572
|
+
), [h.join("-")]);
|
|
573
|
+
return [de(
|
|
574
|
+
() => t.map((l) => l.map((s, C) => {
|
|
575
|
+
let y = C;
|
|
576
|
+
const m = s.$$columnIndex;
|
|
577
|
+
return Array.isArray(m) && m.length === 2 ? y = s.fixed === "right" ? m[0] : m[1] : typeof m == "number" && (y = m), e(s, y);
|
|
578
|
+
})),
|
|
579
|
+
[
|
|
580
|
+
t.map((l) => `|${l.map((s) => s.fixed || "undefined").join("-")}|`).join("_")
|
|
581
|
+
]
|
|
582
|
+
), d];
|
|
583
|
+
}
|
|
584
|
+
function yo(t) {
|
|
585
|
+
const o = t.map((e) => Rt(e.width)), r = t.map((e) => e.fixed);
|
|
586
|
+
return de(() => t.map((e) => {
|
|
587
|
+
let d = 0;
|
|
588
|
+
return e.fixed === "left" && t.some((c) => {
|
|
589
|
+
if (c.fixed === "left") {
|
|
590
|
+
if (c.key === e.key)
|
|
591
|
+
return !0;
|
|
592
|
+
let l = Rt(c.width);
|
|
593
|
+
const s = c.$$isOperation ? l || 40 : l;
|
|
594
|
+
return d += s, !1;
|
|
595
|
+
}
|
|
596
|
+
return !1;
|
|
597
|
+
}), e.fixed === "right" && [...t].reverse().some((c) => {
|
|
598
|
+
if (c.fixed === "right") {
|
|
599
|
+
if (c.key === e.key)
|
|
600
|
+
return !0;
|
|
601
|
+
let l = Rt(c.width);
|
|
602
|
+
const s = c.$$isOperation ? l || 40 : l;
|
|
603
|
+
return d += s, !1;
|
|
604
|
+
}
|
|
605
|
+
return !1;
|
|
606
|
+
}), d;
|
|
607
|
+
}), [o.join("-"), r.join("-")]);
|
|
608
|
+
}
|
|
609
|
+
function xo(t) {
|
|
610
|
+
return t && !Pe.isValidElement(t) && q(t);
|
|
611
|
+
}
|
|
612
|
+
function go(t) {
|
|
613
|
+
var le, fe, he, pe, me, z, be, Ne, re;
|
|
614
|
+
const o = Jn(), {
|
|
615
|
+
component: r,
|
|
616
|
+
InnerComponentTd: h,
|
|
617
|
+
column: e,
|
|
618
|
+
columnIndex: d,
|
|
619
|
+
prefixCls: c,
|
|
620
|
+
stickyClassName: l,
|
|
621
|
+
stickyOffset: s,
|
|
622
|
+
currentSorter: C,
|
|
623
|
+
virtualized: y,
|
|
624
|
+
record: m,
|
|
625
|
+
trIndex: N,
|
|
626
|
+
level: g,
|
|
627
|
+
placeholder: T = "-",
|
|
628
|
+
indentSize: _,
|
|
629
|
+
renderExpandIcon: S,
|
|
630
|
+
rowKey: w,
|
|
631
|
+
recordHaveChildren: p,
|
|
632
|
+
haveTreeData: k
|
|
633
|
+
} = t, { rtl: B } = We(Xe), { ComponentBodyCell: G } = Me(r), ee = xe(null), V = xe(null), K = xe(null), P = xe(null), E = ne(
|
|
634
|
+
`${c}-td`,
|
|
635
|
+
l,
|
|
636
|
+
{
|
|
637
|
+
[`${c}-col-sorted`]: C && C.direction && C.field === (e == null ? void 0 : e.dataIndex)
|
|
638
|
+
},
|
|
639
|
+
e == null ? void 0 : e.className
|
|
640
|
+
);
|
|
641
|
+
let I = {}, D, H, O = {};
|
|
642
|
+
(e == null ? void 0 : e.fixed) === "left" && (O[B ? "right" : "left"] = s), (e == null ? void 0 : e.fixed) === "right" && (O[B ? "left" : "right"] = s), q(e == null ? void 0 : e.cellStyle) && (O = {
|
|
643
|
+
...O,
|
|
644
|
+
...e == null ? void 0 : e.cellStyle
|
|
645
|
+
}), q(e == null ? void 0 : e.bodyCellStyle) && (O = {
|
|
646
|
+
...O,
|
|
647
|
+
...e == null ? void 0 : e.bodyCellStyle
|
|
648
|
+
}), kt(e == null ? void 0 : e.bodyCellStyle) && (O = {
|
|
649
|
+
...O,
|
|
650
|
+
...((le = e == null ? void 0 : e.bodyCellStyle) == null ? void 0 : le.call(e, m, N)) ?? {}
|
|
651
|
+
}), e != null && e.align && (O.textAlign = e == null ? void 0 : e.align), y && e.width && (O.width = e.width, O.minWidth = e.width, O.maxWidth = e.width);
|
|
652
|
+
const { onHandleSave: x, ...A } = e != null && e.onCell ? (e == null ? void 0 : e.onCell(m, N, e)) ?? {} : { onHandleSave: () => {
|
|
653
|
+
} }, $ = e == null ? void 0 : e.render;
|
|
654
|
+
let R = de(() => $ == null ? void 0 : $(
|
|
655
|
+
xt(m, e == null ? void 0 : e.dataIndex),
|
|
656
|
+
te(m),
|
|
657
|
+
N
|
|
658
|
+
), [m, e, N]);
|
|
659
|
+
if (kt($) || (R = xt(m, (e == null ? void 0 : e.dataIndex) ?? "")), xo(R) && (I = R == null ? void 0 : R.props, D = I == null ? void 0 : I.rowSpan, H = I == null ? void 0 : I.colSpan, R = R == null ? void 0 : R.children), D === 0 || H === 0)
|
|
660
|
+
return null;
|
|
661
|
+
Ye(R) && (R = R.trim()), !R && R !== 0 && (R = (e == null ? void 0 : e.placeholder) ?? T ?? "-");
|
|
662
|
+
const F = e != null && e.ellipsis && Ye(R) ? {
|
|
663
|
+
// title: cellChildren // 暂时不需要title属性了,因为单独加了tooltip组件,潘启宝2023年4月1日于广东省惠州市
|
|
664
|
+
} : {}, f = k && (e == null ? void 0 : e.$$isFirstColumn), v = f && p;
|
|
665
|
+
let Y = f && g > 0 ? _ * g : 0;
|
|
666
|
+
f && !p && (Y += 20);
|
|
667
|
+
const W = `${d}-${N}-${Y}-${v}`, J = /* @__PURE__ */ a(
|
|
668
|
+
"div",
|
|
669
|
+
{
|
|
670
|
+
ref: ee,
|
|
671
|
+
className: ne(`${c}-cell`, {
|
|
672
|
+
[`${c}-cell-text-ellipsis`]: e == null ? void 0 : e.ellipsis
|
|
673
|
+
}),
|
|
674
|
+
...F,
|
|
675
|
+
children: /* @__PURE__ */ ue(
|
|
676
|
+
G,
|
|
677
|
+
{
|
|
678
|
+
ref: V,
|
|
679
|
+
className: `${c}-cell-wrap-value`,
|
|
680
|
+
...Ye(G) ? {} : {
|
|
681
|
+
rowData: te(m),
|
|
682
|
+
column: e,
|
|
683
|
+
onHandleSave: x,
|
|
684
|
+
...A
|
|
685
|
+
},
|
|
686
|
+
children: [
|
|
687
|
+
!!Y && /* @__PURE__ */ a(
|
|
688
|
+
"span",
|
|
689
|
+
{
|
|
690
|
+
ref: K,
|
|
691
|
+
className: `${c}-cell-indent`,
|
|
692
|
+
style: { paddingLeft: Y }
|
|
693
|
+
}
|
|
694
|
+
),
|
|
695
|
+
!!v && /* @__PURE__ */ a(
|
|
696
|
+
"span",
|
|
697
|
+
{
|
|
698
|
+
ref: P,
|
|
699
|
+
className: `${c}-cell-expand-icon`,
|
|
700
|
+
children: S(m, w)
|
|
701
|
+
}
|
|
702
|
+
),
|
|
703
|
+
t.___dangerouslySetInnerHTML___ ? /* @__PURE__ */ a(
|
|
704
|
+
"span",
|
|
705
|
+
{
|
|
706
|
+
dangerouslySetInnerHTML: {
|
|
707
|
+
__html: R
|
|
708
|
+
}
|
|
709
|
+
}
|
|
710
|
+
) : R
|
|
711
|
+
]
|
|
712
|
+
},
|
|
713
|
+
W
|
|
714
|
+
)
|
|
715
|
+
},
|
|
716
|
+
W
|
|
717
|
+
);
|
|
718
|
+
let oe = /* @__PURE__ */ a(
|
|
719
|
+
h,
|
|
720
|
+
{
|
|
721
|
+
className: E,
|
|
722
|
+
style: O,
|
|
723
|
+
...Un(A, [
|
|
724
|
+
"onClick",
|
|
725
|
+
"onDoubleClick",
|
|
726
|
+
"onContextMenu",
|
|
727
|
+
"onMouseOver",
|
|
728
|
+
"onMouseEnter",
|
|
729
|
+
"onMouseLeave",
|
|
730
|
+
"onMouseMove",
|
|
731
|
+
"onMouseDown",
|
|
732
|
+
"onMouseUp"
|
|
733
|
+
]),
|
|
734
|
+
...I,
|
|
735
|
+
children: J
|
|
736
|
+
},
|
|
737
|
+
(e == null ? void 0 : e.key) || (e == null ? void 0 : e.dataIndex) || d
|
|
738
|
+
);
|
|
739
|
+
if ((e == null ? void 0 : e.showTooltip) !== !1 && (e != null && e.ellipsis)) {
|
|
740
|
+
const ce = (he = (fe = ee.current) == null ? void 0 : fe.getBoundingClientRect) == null ? void 0 : he.call(fe), X = (me = (pe = V.current) == null ? void 0 : pe.getBoundingClientRect) == null ? void 0 : me.call(pe), ye = (be = (z = K.current) == null ? void 0 : z.getBoundingClientRect) == null ? void 0 : be.call(z), Re = (re = (Ne = P.current) == null ? void 0 : Ne.getBoundingClientRect) == null ? void 0 : re.call(Ne), ge = (ce == null ? void 0 : ce.width) ?? 0, _e = (X == null ? void 0 : X.width) ?? 0, Ae = (ye == null ? void 0 : ye.width) ?? 0, Fe = (Re == null ? void 0 : Re.width) ?? 0;
|
|
741
|
+
_e + (Ae ?? Y) + Fe > ge && (oe = /* @__PURE__ */ a(sn, { content: Zn(oe), children: oe }));
|
|
742
|
+
}
|
|
743
|
+
return nt(() => (o(), () => {
|
|
744
|
+
}), [ee.current, V.current]), oe;
|
|
745
|
+
}
|
|
746
|
+
const Co = Pe.memo(go);
|
|
747
|
+
function wo(t, o) {
|
|
748
|
+
const {
|
|
749
|
+
expandedRowRender: r,
|
|
750
|
+
onClickExpandBtn: h,
|
|
751
|
+
columns: e,
|
|
752
|
+
component: d,
|
|
753
|
+
onCheck: c,
|
|
754
|
+
onCheckRadio: l,
|
|
755
|
+
prefixCls: s,
|
|
756
|
+
selectedRowKeys: C,
|
|
757
|
+
indeterminateKeys: y,
|
|
758
|
+
rowClassName: m,
|
|
759
|
+
onRow: N,
|
|
760
|
+
rowSelection: g,
|
|
761
|
+
indentSize: T = 16,
|
|
762
|
+
activeSorters: _,
|
|
763
|
+
virtualized: S,
|
|
764
|
+
stickyOffsets: w,
|
|
765
|
+
stickyClassNames: p,
|
|
766
|
+
getRowKey: k,
|
|
767
|
+
placeholder: B,
|
|
768
|
+
expandProps: G = { strictTreeData: !0 },
|
|
769
|
+
data: ee,
|
|
770
|
+
expandedRowKeys: V,
|
|
771
|
+
childrenColumnName: K,
|
|
772
|
+
record: P,
|
|
773
|
+
index: E,
|
|
774
|
+
type: I,
|
|
775
|
+
shouldRowExpand: D,
|
|
776
|
+
level: H
|
|
777
|
+
} = t, { rtl: O } = We(Xe), x = te(P), { ...A } = (N == null ? void 0 : N(x, E)) || {}, $ = k(P), R = I === "radio" ? C.slice(0, 1) : C, F = $ || E, f = R.indexOf($) > -1, v = V.indexOf($) > -1, Y = y.indexOf($) > -1, W = ne(
|
|
778
|
+
`${s}-tr`,
|
|
779
|
+
{
|
|
780
|
+
[`${s}-row-checked`]: f,
|
|
781
|
+
[`${s}-row-expanded`]: v
|
|
782
|
+
},
|
|
783
|
+
m == null ? void 0 : m(x, E)
|
|
784
|
+
), J = g && typeof g.checkboxProps == "function" ? g.checkboxProps(x) : {}, oe = ne(`${s}-td`, `${s}-operation`), le = (U) => ne(oe, `${s}-${U}`, {
|
|
785
|
+
[`${s}-selection-col`]: S && I === "checkbox" || I === "radio",
|
|
786
|
+
[`${s}-expand-icon-col`]: S && r
|
|
787
|
+
});
|
|
788
|
+
function fe(U) {
|
|
789
|
+
return G.strictTreeData ? ie(U[K]) && U[K].length : U[K] !== void 0;
|
|
790
|
+
}
|
|
791
|
+
function he() {
|
|
792
|
+
return ee.find((U) => fe(U));
|
|
793
|
+
}
|
|
794
|
+
const pe = D(P, E), me = fe(P), z = he() && !r, be = z && me, re = G.expandRowByClick && (pe || be) ? {
|
|
795
|
+
onClick: (U) => {
|
|
796
|
+
var Ce;
|
|
797
|
+
h($), (Ce = A == null ? void 0 : A.onClick) == null || Ce.call(A, U);
|
|
798
|
+
}
|
|
799
|
+
} : {}, { ComponentBodyRow: ce, ComponentTd: X, getBodyComponentOperations: ye } = Me(d), Re = S ? "div" : ce, ge = S ? "div" : X, _e = {
|
|
800
|
+
className: W,
|
|
801
|
+
key: F,
|
|
802
|
+
...A,
|
|
803
|
+
...re
|
|
804
|
+
}, Ae = Ye(ce) ? _e : { ..._e, record: P, index: E };
|
|
805
|
+
function Fe(U, Ce) {
|
|
806
|
+
const { icon: Te } = G, Be = !!~V.indexOf(Ce), Ke = {
|
|
807
|
+
onClick: (Le) => {
|
|
808
|
+
Le.stopPropagation(), h(Ce);
|
|
809
|
+
}
|
|
810
|
+
};
|
|
811
|
+
return typeof Te == "function" ? Te({ expanded: Be, record: U, ...Ke }) : /* @__PURE__ */ a("button", { ...Ke, type: "button", children: Be ? /* @__PURE__ */ a(Xn, {}) : /* @__PURE__ */ a(Qn, {}) });
|
|
812
|
+
}
|
|
813
|
+
const Oe = r && /* @__PURE__ */ a(ge, { className: le("expand-icon-cell"), children: pe && Fe(P, $) }), Se = g && g.renderCell;
|
|
814
|
+
let M;
|
|
815
|
+
const ae = /* @__PURE__ */ a(
|
|
816
|
+
It,
|
|
817
|
+
{
|
|
818
|
+
value: $,
|
|
819
|
+
onChange: (U) => c(U, P),
|
|
820
|
+
checked: f,
|
|
821
|
+
indeterminate: Y,
|
|
822
|
+
...J
|
|
823
|
+
}
|
|
824
|
+
), Z = /* @__PURE__ */ a(
|
|
825
|
+
rn,
|
|
826
|
+
{
|
|
827
|
+
onChange: () => l($, P),
|
|
828
|
+
value: $,
|
|
829
|
+
checked: f,
|
|
830
|
+
...J
|
|
831
|
+
}
|
|
832
|
+
);
|
|
833
|
+
I === "checkbox" && (M = /* @__PURE__ */ a(ge, { className: le("checkbox"), children: Se ? Se(ae, f, x) : ae })), I === "radio" && (M = /* @__PURE__ */ a(ge, { className: le("radio"), children: Se ? Se(Z, f, x) : Z }));
|
|
834
|
+
const se = ye({
|
|
835
|
+
selectionNode: M,
|
|
836
|
+
expandNode: Oe
|
|
837
|
+
});
|
|
838
|
+
return /* @__PURE__ */ a(Re, { ...Ae, ref: o, children: e.map((U, Ce) => {
|
|
839
|
+
var Le, ot, De, ke;
|
|
840
|
+
const Te = `${U.key}-${U.dataIndex}-${U.title}-${Ce}`, Be = w[Ce], Ke = p[Ce];
|
|
841
|
+
if (U.$$isOperation) {
|
|
842
|
+
let Ee = U.node, Qe = !0;
|
|
843
|
+
U.title === qe && (Ee = (Le = se.find((ze) => ze.name === "selectionNode")) == null ? void 0 : Le.node, Qe = !1), U.title === Ge && (Ee = (ot = se.find((ze) => ze.name === "expandNode")) == null ? void 0 : ot.node, Qe = !1);
|
|
844
|
+
const ve = typeof Ee == "function" ? Ee(P) : Ee;
|
|
845
|
+
return Pe.cloneElement(ve, {
|
|
846
|
+
key: Te || Ce,
|
|
847
|
+
...ve.props,
|
|
848
|
+
className: ne(
|
|
849
|
+
Qe ? oe : "",
|
|
850
|
+
(De = ve == null ? void 0 : ve.props) == null ? void 0 : De.className,
|
|
851
|
+
Ke
|
|
852
|
+
),
|
|
853
|
+
style: {
|
|
854
|
+
...(ke = ve == null ? void 0 : ve.props) == null ? void 0 : ke.style,
|
|
855
|
+
...U.fixed === "left" ? {
|
|
856
|
+
[O ? "right" : "left"]: Be
|
|
857
|
+
} : {},
|
|
858
|
+
width: U.width,
|
|
859
|
+
minWidth: U.width
|
|
860
|
+
}
|
|
861
|
+
});
|
|
862
|
+
}
|
|
863
|
+
return /* @__PURE__ */ a(
|
|
864
|
+
Co,
|
|
865
|
+
{
|
|
866
|
+
prefixCls: s,
|
|
867
|
+
virtualized: S,
|
|
868
|
+
component: d,
|
|
869
|
+
currentSorter: _.find(
|
|
870
|
+
(Ee) => Ee.field === (U.dataIndex || U.key)
|
|
871
|
+
),
|
|
872
|
+
placeholder: B,
|
|
873
|
+
indentSize: T,
|
|
874
|
+
stickyClassName: Ke,
|
|
875
|
+
stickyOffset: Be,
|
|
876
|
+
InnerComponentTd: ge,
|
|
877
|
+
column: U,
|
|
878
|
+
columnIndex: Ce,
|
|
879
|
+
record: P,
|
|
880
|
+
trIndex: E,
|
|
881
|
+
level: H,
|
|
882
|
+
haveTreeData: z,
|
|
883
|
+
recordHaveChildren: me,
|
|
884
|
+
rowKey: $,
|
|
885
|
+
renderExpandIcon: Fe,
|
|
886
|
+
___dangerouslySetInnerHTML___: t.___dangerouslySetInnerHTML___
|
|
887
|
+
},
|
|
888
|
+
Te
|
|
889
|
+
);
|
|
890
|
+
}) });
|
|
891
|
+
}
|
|
892
|
+
const on = Pt(wo), No = Pt(function({
|
|
893
|
+
record: o,
|
|
894
|
+
index: r,
|
|
895
|
+
virtualized: h,
|
|
896
|
+
tbodyProps: e
|
|
897
|
+
}, d) {
|
|
898
|
+
const {
|
|
899
|
+
prefixCls: c,
|
|
900
|
+
columns: l,
|
|
901
|
+
indentSize: s = 16,
|
|
902
|
+
childrenColumnName: C = "children",
|
|
903
|
+
expandProps: y = {},
|
|
904
|
+
rowSelection: m,
|
|
905
|
+
hasFixedColumn: N,
|
|
906
|
+
tableViewWidth: g,
|
|
907
|
+
getRowKey: T,
|
|
908
|
+
expandedRowKeys: _,
|
|
909
|
+
expandedRowRender: S
|
|
910
|
+
} = e;
|
|
911
|
+
let w;
|
|
912
|
+
m && "type" in m ? w = m.type : m && !("type" in m) && (w = "checkbox");
|
|
913
|
+
const p = S && ((E, I) => S(te(E), I)), k = (E) => ie(E[C]) && E[C].length, B = (E, I) => "rowExpandable" in y && typeof y.rowExpandable == "function" ? y.rowExpandable(E) : (p == null ? void 0 : p(E, I)) !== null, G = (E, I) => {
|
|
914
|
+
const D = [], H = {
|
|
915
|
+
...e,
|
|
916
|
+
type: w,
|
|
917
|
+
shouldRowExpand: B
|
|
918
|
+
};
|
|
919
|
+
D.push(
|
|
920
|
+
/* @__PURE__ */ a(
|
|
921
|
+
on,
|
|
922
|
+
{
|
|
923
|
+
ref: d,
|
|
924
|
+
...H,
|
|
925
|
+
record: E,
|
|
926
|
+
level: 0,
|
|
927
|
+
index: I
|
|
928
|
+
},
|
|
929
|
+
T(E)
|
|
930
|
+
)
|
|
931
|
+
);
|
|
932
|
+
const O = (x, A, $ = 0) => {
|
|
933
|
+
ie(x) && x.length && x.forEach((R, F) => {
|
|
934
|
+
_.indexOf(A) !== -1 && (D.push(
|
|
935
|
+
/* @__PURE__ */ ln(
|
|
936
|
+
on,
|
|
937
|
+
{
|
|
938
|
+
...H,
|
|
939
|
+
key: T(R),
|
|
940
|
+
record: R,
|
|
941
|
+
level: $ + 1,
|
|
942
|
+
index: F
|
|
943
|
+
}
|
|
944
|
+
)
|
|
945
|
+
), k(R) && O(R[C], T(R), $ + 1));
|
|
946
|
+
});
|
|
947
|
+
};
|
|
948
|
+
return p || O(E[C], T(E)), D;
|
|
949
|
+
}, ee = T(o), V = B(o, r) && _.indexOf(ee) !== -1, K = h ? "div" : "tr", P = h ? "div" : "td";
|
|
950
|
+
return /* @__PURE__ */ ue(Pe.Fragment, { children: [
|
|
951
|
+
G(o, r),
|
|
952
|
+
V && /* @__PURE__ */ a(
|
|
953
|
+
K,
|
|
954
|
+
{
|
|
955
|
+
className: ne(`${c}-tr`, `${c}-expand-content`),
|
|
956
|
+
children: /* @__PURE__ */ a(
|
|
957
|
+
P,
|
|
958
|
+
{
|
|
959
|
+
className: ne(`${c}-td`),
|
|
960
|
+
style: { paddingLeft: s },
|
|
961
|
+
colSpan: l.length,
|
|
962
|
+
children: N ? /* @__PURE__ */ a(
|
|
963
|
+
"div",
|
|
964
|
+
{
|
|
965
|
+
className: `${c}-expand-fixed-row`,
|
|
966
|
+
style: { width: g },
|
|
967
|
+
children: p == null ? void 0 : p(o, r)
|
|
968
|
+
}
|
|
969
|
+
) : p == null ? void 0 : p(o, r)
|
|
970
|
+
}
|
|
971
|
+
)
|
|
972
|
+
},
|
|
973
|
+
`${ee}-expanded`
|
|
974
|
+
)
|
|
975
|
+
] }, ee);
|
|
976
|
+
});
|
|
977
|
+
function $o(t) {
|
|
978
|
+
const {
|
|
979
|
+
data: o,
|
|
980
|
+
columns: r,
|
|
981
|
+
prefixCls: h,
|
|
982
|
+
component: e,
|
|
983
|
+
noDataElement: d,
|
|
984
|
+
scroll: c,
|
|
985
|
+
tableViewWidth: l,
|
|
986
|
+
virtualized: s,
|
|
987
|
+
virtualListProps: C,
|
|
988
|
+
getRowKey: y,
|
|
989
|
+
saveVirtualListRef: m
|
|
990
|
+
} = t, { ComponentTbody: N } = Me(e);
|
|
991
|
+
let g = {}, T = {};
|
|
992
|
+
c && (c.x && (typeof c.x == "number" || typeof c.x == "string") && (g = {
|
|
993
|
+
width: c.x
|
|
994
|
+
}), c.y && (typeof c.y == "number" || typeof c.y == "string") && (T = {
|
|
995
|
+
maxHeight: c.y
|
|
996
|
+
}));
|
|
997
|
+
const _ = {
|
|
998
|
+
className: `${h}-no-data`
|
|
999
|
+
};
|
|
1000
|
+
l && (_.className = `${h}-no-data ${h}-expand-fixed-row`, _.style = { width: l });
|
|
1001
|
+
const S = /* @__PURE__ */ a("tr", { className: ne(`${h}-tr`, `${h}-empty-row`), children: /* @__PURE__ */ a("td", { className: `${h}-td`, colSpan: r.length, children: /* @__PURE__ */ a("div", { ..._, children: d }) }) }), w = (p, k) => {
|
|
1002
|
+
const B = y(p) || k;
|
|
1003
|
+
return /* @__PURE__ */ a(
|
|
1004
|
+
No,
|
|
1005
|
+
{
|
|
1006
|
+
record: p,
|
|
1007
|
+
index: k,
|
|
1008
|
+
virtualized: s,
|
|
1009
|
+
tbodyProps: t
|
|
1010
|
+
},
|
|
1011
|
+
B
|
|
1012
|
+
);
|
|
1013
|
+
};
|
|
1014
|
+
return s ? o.length > 0 ? /* @__PURE__ */ a(
|
|
1015
|
+
Gn,
|
|
1016
|
+
{
|
|
1017
|
+
data: o,
|
|
1018
|
+
height: T.maxHeight,
|
|
1019
|
+
isStaticItemHeight: !1,
|
|
1020
|
+
outerStyle: { ...g, minWidth: "100%", overflow: "visible" },
|
|
1021
|
+
innerStyle: { right: "auto", minWidth: "100%" },
|
|
1022
|
+
className: `${h}-body`,
|
|
1023
|
+
ref: (p) => m(p),
|
|
1024
|
+
itemKey: y,
|
|
1025
|
+
...C,
|
|
1026
|
+
children: w
|
|
1027
|
+
}
|
|
1028
|
+
) : /* @__PURE__ */ a("div", { className: `${h}-body`, children: /* @__PURE__ */ a("table", { children: /* @__PURE__ */ a("tbody", { children: S }) }) }) : /* @__PURE__ */ a(N, { children: o.length > 0 ? o.map(w) : S });
|
|
1029
|
+
}
|
|
1030
|
+
const an = Wn({});
|
|
1031
|
+
function bo(t) {
|
|
1032
|
+
const { summary: o, data: r, prefixCls: h, columns: e, stickyOffsets: d, stickyClassNames: c } = t;
|
|
1033
|
+
return /* @__PURE__ */ a("tfoot", { className: `${h}-tfoot`, children: /* @__PURE__ */ a(
|
|
1034
|
+
an.Provider,
|
|
1035
|
+
{
|
|
1036
|
+
value: { columns: e, stickyOffsets: d, stickyClassNames: c, prefixCls: h },
|
|
1037
|
+
children: o(te(r))
|
|
1038
|
+
}
|
|
1039
|
+
) });
|
|
1040
|
+
}
|
|
1041
|
+
function So(t, o) {
|
|
1042
|
+
return t === "ascend" ? o.Table.sortAscend : t === "descend" ? o.Table.sortDescend : o.Table.cancelSort;
|
|
1043
|
+
}
|
|
1044
|
+
const Ro = { bottom: 0 };
|
|
1045
|
+
function To({
|
|
1046
|
+
onSort: t,
|
|
1047
|
+
onFilter: o,
|
|
1048
|
+
onHandleFilter: r,
|
|
1049
|
+
onHandleFilterReset: h,
|
|
1050
|
+
currentFilters: e = {},
|
|
1051
|
+
currentSorter: d,
|
|
1052
|
+
_key: c,
|
|
1053
|
+
dataIndex: l,
|
|
1054
|
+
title: s,
|
|
1055
|
+
sorter: C,
|
|
1056
|
+
sortDirections: y = ["ascend", "descend"],
|
|
1057
|
+
filters: m = [],
|
|
1058
|
+
columnFixedStyle: N,
|
|
1059
|
+
className: g,
|
|
1060
|
+
cellStyle: T,
|
|
1061
|
+
headerCellStyle: _,
|
|
1062
|
+
rowSpan: S,
|
|
1063
|
+
colSpan: w,
|
|
1064
|
+
headerCellProps: p,
|
|
1065
|
+
prefixCls: k,
|
|
1066
|
+
align: B = "left",
|
|
1067
|
+
component: G,
|
|
1068
|
+
filterIcon: ee,
|
|
1069
|
+
filterDropdown: V,
|
|
1070
|
+
filterMultiple: K = !0,
|
|
1071
|
+
ellipsis: P,
|
|
1072
|
+
filterDropdownProps: E,
|
|
1073
|
+
onFilterDropdownVisibleChange: I,
|
|
1074
|
+
column: D,
|
|
1075
|
+
showSorterTooltip: H,
|
|
1076
|
+
index: O
|
|
1077
|
+
}) {
|
|
1078
|
+
const { locale: x, rtl: A } = We(Xe), $ = c || l || O, [R, F, f] = oo([], {
|
|
1079
|
+
value: e[$] || []
|
|
1080
|
+
}), [v, Y] = we(!1), [W, J] = we(!1), oe = C && ie(y) && y.length, le = oe ? fe() : void 0;
|
|
1081
|
+
nt(() => {
|
|
1082
|
+
F(e[$] || []);
|
|
1083
|
+
}, [e, $]), nt(() => {
|
|
1084
|
+
R && R !== f && F(R);
|
|
1085
|
+
}, [v]);
|
|
1086
|
+
function fe() {
|
|
1087
|
+
const M = d && d.direction;
|
|
1088
|
+
if (!M || d && d.field !== $)
|
|
1089
|
+
return y[0];
|
|
1090
|
+
const ae = y.indexOf(M);
|
|
1091
|
+
if (ae < y.length)
|
|
1092
|
+
return y[ae + 1];
|
|
1093
|
+
}
|
|
1094
|
+
function he() {
|
|
1095
|
+
R && (r == null || r(
|
|
1096
|
+
{ onFilter: o, filters: m, dataIndex: $ },
|
|
1097
|
+
f
|
|
1098
|
+
), me(!1));
|
|
1099
|
+
}
|
|
1100
|
+
function pe() {
|
|
1101
|
+
h({ dataIndex: $ }), me(!1);
|
|
1102
|
+
}
|
|
1103
|
+
function me(M) {
|
|
1104
|
+
Y(M), I == null || I(M);
|
|
1105
|
+
}
|
|
1106
|
+
function z(M, ae) {
|
|
1107
|
+
let Z = [...f];
|
|
1108
|
+
if (K)
|
|
1109
|
+
ae ? Z = Z.concat(M) : Z.splice(
|
|
1110
|
+
Z.findIndex((se) => se === M),
|
|
1111
|
+
1
|
|
1112
|
+
);
|
|
1113
|
+
else if (Z.length > 0)
|
|
1114
|
+
if (Z[0] !== M)
|
|
1115
|
+
Z = [M];
|
|
1116
|
+
else
|
|
1117
|
+
return;
|
|
1118
|
+
else
|
|
1119
|
+
Z = [M];
|
|
1120
|
+
F(Z);
|
|
1121
|
+
}
|
|
1122
|
+
function be(M) {
|
|
1123
|
+
F(M || f), Y(!1), r == null || r(
|
|
1124
|
+
{ filters: m, onFilter: o, dataIndex: $ },
|
|
1125
|
+
M || f
|
|
1126
|
+
);
|
|
1127
|
+
}
|
|
1128
|
+
function Ne() {
|
|
1129
|
+
return typeof V == "function" ? V({
|
|
1130
|
+
filterKeys: f,
|
|
1131
|
+
setFilterKeys: (M, ae) => {
|
|
1132
|
+
F(M), ae == null || ae();
|
|
1133
|
+
},
|
|
1134
|
+
confirm: be
|
|
1135
|
+
}) : /* @__PURE__ */ ue("div", { className: `${k}-filters-popup`, children: [
|
|
1136
|
+
/* @__PURE__ */ a("div", { className: `${k}-filters-list`, children: m.map((M) => {
|
|
1137
|
+
const ae = f.findIndex((Z) => Z === M.value) !== -1;
|
|
1138
|
+
return /* @__PURE__ */ a("div", { className: `${k}-filters-item`, children: K ? /* @__PURE__ */ a(
|
|
1139
|
+
It,
|
|
1140
|
+
{
|
|
1141
|
+
checked: ae,
|
|
1142
|
+
onChange: (Z) => z(M.value, Z),
|
|
1143
|
+
children: M.text
|
|
1144
|
+
}
|
|
1145
|
+
) : /* @__PURE__ */ a(
|
|
1146
|
+
rn,
|
|
1147
|
+
{
|
|
1148
|
+
checked: ae,
|
|
1149
|
+
onChange: (Z) => z(M.value, Z),
|
|
1150
|
+
children: M.text
|
|
1151
|
+
}
|
|
1152
|
+
) }, M.value);
|
|
1153
|
+
}) }),
|
|
1154
|
+
/* @__PURE__ */ ue(Ln, { className: `${k}-filters-btn`, children: [
|
|
1155
|
+
/* @__PURE__ */ a(Zt, { onClick: pe, size: "mini", children: x.Table.resetText }),
|
|
1156
|
+
/* @__PURE__ */ a(Zt, { onClick: he, type: "primary", size: "mini", children: x.Table.okText })
|
|
1157
|
+
] })
|
|
1158
|
+
] });
|
|
1159
|
+
}
|
|
1160
|
+
const re = (M) => ne(`${k}-sorter-icon`, {
|
|
1161
|
+
[`${k}-sorter-icon-active`]: d && d.direction === M && d.field === $
|
|
1162
|
+
}), ce = ne(`${k}-filters`, {
|
|
1163
|
+
[`${k}-filters-open`]: v,
|
|
1164
|
+
[`${k}-filters-active`]: R && R.length
|
|
1165
|
+
});
|
|
1166
|
+
let X = {
|
|
1167
|
+
...N
|
|
1168
|
+
};
|
|
1169
|
+
q(T) && (X = {
|
|
1170
|
+
...X,
|
|
1171
|
+
...T
|
|
1172
|
+
}), q(_) && (X = {
|
|
1173
|
+
...X,
|
|
1174
|
+
..._
|
|
1175
|
+
}), kt(_) && (X = {
|
|
1176
|
+
...X,
|
|
1177
|
+
..._()
|
|
1178
|
+
}), B && B !== "left" && (X.textAlign = B);
|
|
1179
|
+
const ye = {
|
|
1180
|
+
style: X,
|
|
1181
|
+
key: c || $
|
|
1182
|
+
};
|
|
1183
|
+
w && w > 1 && (ye.colSpan = w), S && S > 1 && (ye.rowSpan = S);
|
|
1184
|
+
const { ComponentTh: Re, ComponentHeaderCell: ge } = Me(G), _e = ie(m) && m.length > 0 || typeof V == "function", Ae = P && typeof s == "string" ? { title: s } : {}, Fe = E && E.triggerProps, Oe = /* @__PURE__ */ ue(yt, { children: [
|
|
1185
|
+
oe ? /* @__PURE__ */ a(
|
|
1186
|
+
sn,
|
|
1187
|
+
{
|
|
1188
|
+
content: So(le, x),
|
|
1189
|
+
disabled: !H,
|
|
1190
|
+
...q(H) ? H : {},
|
|
1191
|
+
children: /* @__PURE__ */ ue(
|
|
1192
|
+
"div",
|
|
1193
|
+
{
|
|
1194
|
+
className: `${k}-cell-with-sorter`,
|
|
1195
|
+
onMouseEnter: () => {
|
|
1196
|
+
J(!0);
|
|
1197
|
+
},
|
|
1198
|
+
onMouseLeave: () => {
|
|
1199
|
+
J(!1);
|
|
1200
|
+
},
|
|
1201
|
+
onClick: () => t(le, $),
|
|
1202
|
+
children: [
|
|
1203
|
+
/* @__PURE__ */ a("span", { className: `${k}-th-item-title`, ...Ae, children: s }),
|
|
1204
|
+
oe && /* @__PURE__ */ ue(
|
|
1205
|
+
"div",
|
|
1206
|
+
{
|
|
1207
|
+
className: ne(`${k}-sorter`, {
|
|
1208
|
+
[`${k}-sorter-direction-one`]: y.length === 1
|
|
1209
|
+
}),
|
|
1210
|
+
children: [
|
|
1211
|
+
y.indexOf("ascend") !== -1 && /* @__PURE__ */ a("div", { className: re("ascend"), children: /* @__PURE__ */ a(to, {}) }),
|
|
1212
|
+
y.indexOf("descend") !== -1 && /* @__PURE__ */ a("div", { className: re("descend"), children: /* @__PURE__ */ a(eo, {}) })
|
|
1213
|
+
]
|
|
1214
|
+
}
|
|
1215
|
+
)
|
|
1216
|
+
]
|
|
1217
|
+
}
|
|
1218
|
+
)
|
|
1219
|
+
}
|
|
1220
|
+
) : /* @__PURE__ */ a("span", { className: `${k}-th-item-title`, ...Ae, children: s }),
|
|
1221
|
+
_e && /* @__PURE__ */ a(
|
|
1222
|
+
Fn,
|
|
1223
|
+
{
|
|
1224
|
+
popup: Ne,
|
|
1225
|
+
trigger: "click",
|
|
1226
|
+
classNames: "slideDynamicOrigin",
|
|
1227
|
+
position: A ? "bl" : "br",
|
|
1228
|
+
popupAlign: Ro,
|
|
1229
|
+
popupVisible: v,
|
|
1230
|
+
onVisibleChange: me,
|
|
1231
|
+
...Fe,
|
|
1232
|
+
children: /* @__PURE__ */ a("div", { className: ce, children: ee || /* @__PURE__ */ a(no, {}) })
|
|
1233
|
+
}
|
|
1234
|
+
)
|
|
1235
|
+
] }), Se = ne(`${k}-th-item`, {
|
|
1236
|
+
[`${k}-cell-text-ellipsis`]: P,
|
|
1237
|
+
[`${k}-cell-mouseenter`]: W,
|
|
1238
|
+
[`${k}-cell-next-${le}`]: W && le,
|
|
1239
|
+
[`${k}-col-has-sorter`]: oe,
|
|
1240
|
+
[`${k}-col-has-filter`]: _e
|
|
1241
|
+
});
|
|
1242
|
+
return w !== 0 && /* @__PURE__ */ a(
|
|
1243
|
+
Re,
|
|
1244
|
+
{
|
|
1245
|
+
className: ne(
|
|
1246
|
+
`${k}-th`,
|
|
1247
|
+
{
|
|
1248
|
+
[`${k}-col-sorted`]: d && d.direction && d.field === $
|
|
1249
|
+
},
|
|
1250
|
+
g
|
|
1251
|
+
),
|
|
1252
|
+
...ye,
|
|
1253
|
+
...p,
|
|
1254
|
+
children: Ye(ge) ? /* @__PURE__ */ a(ge, { className: Se, children: Oe }) : /* @__PURE__ */ a(
|
|
1255
|
+
ge,
|
|
1256
|
+
{
|
|
1257
|
+
className: Se,
|
|
1258
|
+
column: D,
|
|
1259
|
+
children: Oe
|
|
1260
|
+
}
|
|
1261
|
+
)
|
|
1262
|
+
}
|
|
1263
|
+
);
|
|
1264
|
+
}
|
|
1265
|
+
function ko(t) {
|
|
1266
|
+
const {
|
|
1267
|
+
activeSorters: o,
|
|
1268
|
+
expandedRowRender: r,
|
|
1269
|
+
expandProps: h = {},
|
|
1270
|
+
onSort: e,
|
|
1271
|
+
onHandleFilter: d,
|
|
1272
|
+
onHandleFilterReset: c,
|
|
1273
|
+
onHeaderRow: l,
|
|
1274
|
+
prefixCls: s,
|
|
1275
|
+
currentFilters: C,
|
|
1276
|
+
component: y,
|
|
1277
|
+
data: m,
|
|
1278
|
+
selectedRowKeys: N,
|
|
1279
|
+
rowSelection: g,
|
|
1280
|
+
allSelectedRowKeys: T = [],
|
|
1281
|
+
groupColumns: _,
|
|
1282
|
+
stickyOffsets: S,
|
|
1283
|
+
groupStickyClassNames: w,
|
|
1284
|
+
showSorterTooltip: p
|
|
1285
|
+
} = t, { rtl: k } = We(Xe), { ComponentThead: B, ComponentHeaderRow: G, getHeaderComponentOperations: ee } = Me(y), V = g && (g.type === "checkbox" || !("type" in g)), K = g && "checkAll" in g ? g.checkAll : !0, P = g && g.type === "radio", { columnTitle: E } = h, I = de(() => {
|
|
1286
|
+
const O = new Set(T);
|
|
1287
|
+
return N.filter((x) => O.has(x));
|
|
1288
|
+
}, [N, T]), D = _.length > 1 ? { rowSpan: _.length } : {}, H = ne(`${s}-th`, `${s}-operation`);
|
|
1289
|
+
return /* @__PURE__ */ a(B, { children: _.map((O, x) => {
|
|
1290
|
+
const A = l == null ? void 0 : l(O, x), $ = (V || P) && x === 0 && /* @__PURE__ */ a(
|
|
1291
|
+
"th",
|
|
1292
|
+
{
|
|
1293
|
+
className: ne(
|
|
1294
|
+
H,
|
|
1295
|
+
`${s}-${P ? "radio" : "checkbox"}`
|
|
1296
|
+
),
|
|
1297
|
+
children: /* @__PURE__ */ ue("div", { className: `${s}-th-item`, children: [
|
|
1298
|
+
K && !P ? /* @__PURE__ */ a(
|
|
1299
|
+
It,
|
|
1300
|
+
{
|
|
1301
|
+
indeterminate: m && I.length > 0 && I.length !== T.length,
|
|
1302
|
+
checked: m && I.length !== 0 && I.length === T.length,
|
|
1303
|
+
disabled: !T.length,
|
|
1304
|
+
onChange: t.onCheckAll
|
|
1305
|
+
}
|
|
1306
|
+
) : null,
|
|
1307
|
+
g && g.columnTitle
|
|
1308
|
+
] })
|
|
1309
|
+
}
|
|
1310
|
+
), R = r && /* @__PURE__ */ a("th", { className: ne(H, `${s}-expand`), children: E && /* @__PURE__ */ a("div", { className: `${s}-th-item`, children: E }) }), F = w[x], f = ee({
|
|
1311
|
+
selectionNode: $,
|
|
1312
|
+
expandNode: R
|
|
1313
|
+
});
|
|
1314
|
+
return /* @__PURE__ */ ln(
|
|
1315
|
+
G,
|
|
1316
|
+
{
|
|
1317
|
+
...A,
|
|
1318
|
+
key: x,
|
|
1319
|
+
className: `${s}-tr`
|
|
1320
|
+
},
|
|
1321
|
+
O.map((v, Y) => {
|
|
1322
|
+
var pe, me, z, be, Ne;
|
|
1323
|
+
const W = v.$$columnIndex;
|
|
1324
|
+
let J = 0;
|
|
1325
|
+
Array.isArray(W) && W.length === 2 ? J = v.fixed === "right" ? S[W[1]] : S[W[0]] : typeof W == "number" && (J = S[W] || 0);
|
|
1326
|
+
const oe = F[Y];
|
|
1327
|
+
if (v.$$isOperation) {
|
|
1328
|
+
let re = v.node, ce = !0;
|
|
1329
|
+
v.title === qe && (re = (pe = f.find(
|
|
1330
|
+
(ye) => ye.name === "selectionNode"
|
|
1331
|
+
)) == null ? void 0 : pe.node, ce = !1), v.title === Ge && (re = (me = f.find(
|
|
1332
|
+
(ye) => ye.name === "expandNode"
|
|
1333
|
+
)) == null ? void 0 : me.node, ce = !1);
|
|
1334
|
+
const X = re;
|
|
1335
|
+
return Pe.cloneElement(X, {
|
|
1336
|
+
key: v.key || Y,
|
|
1337
|
+
...X.props,
|
|
1338
|
+
...D,
|
|
1339
|
+
className: ne(
|
|
1340
|
+
ce ? H : "",
|
|
1341
|
+
(z = X == null ? void 0 : X.props) == null ? void 0 : z.className,
|
|
1342
|
+
oe
|
|
1343
|
+
),
|
|
1344
|
+
style: {
|
|
1345
|
+
...(be = X == null ? void 0 : X.props) == null ? void 0 : be.style,
|
|
1346
|
+
...v.fixed === "left" ? {
|
|
1347
|
+
[k ? "right" : "left"]: J
|
|
1348
|
+
} : {},
|
|
1349
|
+
width: v.width,
|
|
1350
|
+
minWidth: v.width
|
|
1351
|
+
}
|
|
1352
|
+
});
|
|
1353
|
+
}
|
|
1354
|
+
const le = (Ne = v == null ? void 0 : v.onHeaderCell) == null ? void 0 : Ne.call(v, v, Y), fe = ne(oe, v.className), he = {};
|
|
1355
|
+
return v.fixed === "left" && (he[k ? "right" : "left"] = J), v.fixed === "right" && (he[k ? "left" : "right"] = J), /* @__PURE__ */ a(
|
|
1356
|
+
To,
|
|
1357
|
+
{
|
|
1358
|
+
index: Y,
|
|
1359
|
+
onSort: e,
|
|
1360
|
+
onHandleFilter: d,
|
|
1361
|
+
onHandleFilterReset: c,
|
|
1362
|
+
currentSorter: o.find(
|
|
1363
|
+
(re) => re.field === (v.dataIndex || v.key)
|
|
1364
|
+
),
|
|
1365
|
+
currentFilters: C,
|
|
1366
|
+
_key: v.key || v.dataIndex || Y,
|
|
1367
|
+
...v,
|
|
1368
|
+
column: v,
|
|
1369
|
+
headerCellProps: le,
|
|
1370
|
+
prefixCls: s,
|
|
1371
|
+
component: y,
|
|
1372
|
+
className: fe,
|
|
1373
|
+
columnFixedStyle: he,
|
|
1374
|
+
showSorterTooltip: p
|
|
1375
|
+
},
|
|
1376
|
+
v.key
|
|
1377
|
+
);
|
|
1378
|
+
})
|
|
1379
|
+
);
|
|
1380
|
+
}) });
|
|
1381
|
+
}
|
|
1382
|
+
const vo = [], _o = [], Eo = {
|
|
1383
|
+
showHeader: !0,
|
|
1384
|
+
border: !0,
|
|
1385
|
+
hover: !0,
|
|
1386
|
+
rowKey: "key",
|
|
1387
|
+
pagePosition: "br",
|
|
1388
|
+
childrenColumnName: "children",
|
|
1389
|
+
indentSize: 15,
|
|
1390
|
+
showSorterTooltip: !0
|
|
1391
|
+
};
|
|
1392
|
+
function Io(t, o) {
|
|
1393
|
+
var Gt, Xt;
|
|
1394
|
+
const {
|
|
1395
|
+
getPrefixCls: r,
|
|
1396
|
+
loadingElement: h,
|
|
1397
|
+
size: e,
|
|
1398
|
+
tablePagination: d,
|
|
1399
|
+
renderEmpty: c,
|
|
1400
|
+
componentConfig: l,
|
|
1401
|
+
rtl: s
|
|
1402
|
+
} = We(Xe), C = Jt(
|
|
1403
|
+
t,
|
|
1404
|
+
Eo,
|
|
1405
|
+
l == null ? void 0 : l.Table
|
|
1406
|
+
), y = Jt(
|
|
1407
|
+
q(t == null ? void 0 : t.pagination) ? t == null ? void 0 : t.pagination : {},
|
|
1408
|
+
q((Gt = l == null ? void 0 : l.Table) == null ? void 0 : Gt.pagination) ? (Xt = l == null ? void 0 : l.Table) == null ? void 0 : Xt.pagination : {},
|
|
1409
|
+
d || {}
|
|
1410
|
+
), {
|
|
1411
|
+
style: m,
|
|
1412
|
+
className: N,
|
|
1413
|
+
component: g,
|
|
1414
|
+
border: T,
|
|
1415
|
+
borderCell: _,
|
|
1416
|
+
columns: S = _o,
|
|
1417
|
+
data: w = vo,
|
|
1418
|
+
scroll: p,
|
|
1419
|
+
noDataElement: k,
|
|
1420
|
+
showHeader: B,
|
|
1421
|
+
stripe: G,
|
|
1422
|
+
hover: ee,
|
|
1423
|
+
pagination: V,
|
|
1424
|
+
onChange: K,
|
|
1425
|
+
pagePosition: P,
|
|
1426
|
+
childrenColumnName: E,
|
|
1427
|
+
indentSize: I,
|
|
1428
|
+
rowSelection: D,
|
|
1429
|
+
tableLayoutFixed: H,
|
|
1430
|
+
footer: O,
|
|
1431
|
+
virtualized: x,
|
|
1432
|
+
renderPagination: A,
|
|
1433
|
+
summary: $,
|
|
1434
|
+
rowKey: R
|
|
1435
|
+
} = C, F = de(
|
|
1436
|
+
() => co(w, E),
|
|
1437
|
+
[w, E]
|
|
1438
|
+
), f = r("table"), v = C.size || (["default", "middle", "small"].indexOf(e) > -1 ? e : "default"), Y = xe(null), W = xe(null), J = xe(null), oe = xe(null), le = xe(null), fe = xe(null), he = xe(0), pe = xe(!1), [me, z] = so(C), { currentFilters: be, defaultSorters: Ne } = ot(), [re, ce] = we(1), [X, ye] = we(
|
|
1439
|
+
y.pageSize || y.defaultPageSize || 10
|
|
1440
|
+
), [Re, ge] = we(be), [_e, Ae] = we(0), [Fe, Oe] = we([]), Se = yo(z), [M, ae] = mo(
|
|
1441
|
+
me,
|
|
1442
|
+
z,
|
|
1443
|
+
f
|
|
1444
|
+
), {
|
|
1445
|
+
currentSorter: Z,
|
|
1446
|
+
activeSorters: se,
|
|
1447
|
+
getNextActiveSorters: U,
|
|
1448
|
+
updateStateSorters: Ce
|
|
1449
|
+
} = ho(z, Ne), { ComponentTable: Te, ComponentBodyWrapper: Be, ComponentHeaderWrapper: Ke } = Me(g), Le = de(() => typeof R == "function" ? (n) => R(te(n)) : (n) => n[R], [R]);
|
|
1450
|
+
function ot() {
|
|
1451
|
+
const n = {};
|
|
1452
|
+
let i = [];
|
|
1453
|
+
return z.forEach((u) => {
|
|
1454
|
+
const b = u.dataIndex || u.key;
|
|
1455
|
+
if (u.defaultFilters && (n[b] = u.defaultFilters), u.filteredValue && (n[b] = u.filteredValue), "defaultSortOrder" in u || "sortOrder" in u) {
|
|
1456
|
+
const L = Et(u.sorter), Q = "sortOrder" in u ? u.sortOrder : u.defaultSortOrder, j = {
|
|
1457
|
+
field: b,
|
|
1458
|
+
direction: Q,
|
|
1459
|
+
sorterFn: _t(u.sorter),
|
|
1460
|
+
priority: L
|
|
1461
|
+
};
|
|
1462
|
+
Q ? He(L) ? i.every(
|
|
1463
|
+
($e) => He($e.priority) || !$e.direction
|
|
1464
|
+
) && i.push(j) : i.every(($e) => !$e.direction) ? i.push(j) : i = [j] : i.push(j);
|
|
1465
|
+
}
|
|
1466
|
+
}), { currentFilters: n, defaultSorters: i };
|
|
1467
|
+
}
|
|
1468
|
+
const De = de(() => {
|
|
1469
|
+
const n = z.filter(
|
|
1470
|
+
(u) => "filteredValue" in u
|
|
1471
|
+
), i = {};
|
|
1472
|
+
return n.length && n.forEach((u, b) => {
|
|
1473
|
+
const L = u.key || u.dataIndex || b;
|
|
1474
|
+
L !== void 0 && (i[L] = u.filteredValue);
|
|
1475
|
+
}), i;
|
|
1476
|
+
}, [z]), ke = de(() => Object.keys(De).length ? De : Re, [Re, De]);
|
|
1477
|
+
function Ee(n, i) {
|
|
1478
|
+
const u = Ht(i);
|
|
1479
|
+
if (!u)
|
|
1480
|
+
return;
|
|
1481
|
+
const b = {
|
|
1482
|
+
direction: n,
|
|
1483
|
+
field: i,
|
|
1484
|
+
sorterFn: _t(u.sorter),
|
|
1485
|
+
priority: Et(u.sorter)
|
|
1486
|
+
}, L = U(b);
|
|
1487
|
+
Ce(b, L);
|
|
1488
|
+
const Q = lt(
|
|
1489
|
+
b,
|
|
1490
|
+
L,
|
|
1491
|
+
ke
|
|
1492
|
+
), j = Ze(Q);
|
|
1493
|
+
K == null || K(Ve(Q), b, ke, {
|
|
1494
|
+
currentData: te(j),
|
|
1495
|
+
currentAllData: te(Q),
|
|
1496
|
+
action: "sort"
|
|
1497
|
+
});
|
|
1498
|
+
}
|
|
1499
|
+
function Qe(n) {
|
|
1500
|
+
const i = function(b, L) {
|
|
1501
|
+
return (Q, j) => {
|
|
1502
|
+
const $e = b(Q, j);
|
|
1503
|
+
return L === "descend" ? -$e : $e;
|
|
1504
|
+
};
|
|
1505
|
+
}, u = [...n];
|
|
1506
|
+
return u.sort((b, L) => L.priority - b.priority), (b, L) => {
|
|
1507
|
+
for (let Q = 0, j = u.length; Q < j; Q++) {
|
|
1508
|
+
const { sorterFn: $e, direction: bt } = u[Q];
|
|
1509
|
+
if (typeof $e != "function")
|
|
1510
|
+
continue;
|
|
1511
|
+
const pt = i($e, bt)(b, L);
|
|
1512
|
+
if (pt !== 0)
|
|
1513
|
+
return pt;
|
|
1514
|
+
}
|
|
1515
|
+
return 0;
|
|
1516
|
+
};
|
|
1517
|
+
}
|
|
1518
|
+
function ve(n, i) {
|
|
1519
|
+
const u = {
|
|
1520
|
+
...ke,
|
|
1521
|
+
[n.dataIndex]: i
|
|
1522
|
+
}, b = {
|
|
1523
|
+
...u,
|
|
1524
|
+
...De
|
|
1525
|
+
};
|
|
1526
|
+
if (ie(i) && i.length) {
|
|
1527
|
+
ge(b);
|
|
1528
|
+
const L = lt(
|
|
1529
|
+
Z,
|
|
1530
|
+
se,
|
|
1531
|
+
u
|
|
1532
|
+
), Q = Ze(L);
|
|
1533
|
+
K == null || K(
|
|
1534
|
+
Ve(L),
|
|
1535
|
+
se.length === 1 ? se[0] : se,
|
|
1536
|
+
u,
|
|
1537
|
+
{
|
|
1538
|
+
currentData: te(Q),
|
|
1539
|
+
currentAllData: te(L),
|
|
1540
|
+
action: "filter"
|
|
1541
|
+
}
|
|
1542
|
+
);
|
|
1543
|
+
} else
|
|
1544
|
+
ie(i) && !i.length && ze(n);
|
|
1545
|
+
}
|
|
1546
|
+
function ze({ dataIndex: n }) {
|
|
1547
|
+
const i = {
|
|
1548
|
+
...ke
|
|
1549
|
+
};
|
|
1550
|
+
delete i[n], ge(i);
|
|
1551
|
+
const u = lt(
|
|
1552
|
+
Z,
|
|
1553
|
+
se,
|
|
1554
|
+
i
|
|
1555
|
+
), b = Ze(u);
|
|
1556
|
+
K == null || K(
|
|
1557
|
+
Ve(u),
|
|
1558
|
+
se.length === 1 ? se[0] : se,
|
|
1559
|
+
i,
|
|
1560
|
+
{
|
|
1561
|
+
currentData: te(b),
|
|
1562
|
+
currentAllData: te(u),
|
|
1563
|
+
action: "filter"
|
|
1564
|
+
}
|
|
1565
|
+
);
|
|
1566
|
+
}
|
|
1567
|
+
const rt = !!z.find((n) => n.fixed === "left"), st = !!z.find((n) => n.fixed === "right"), it = rt || st;
|
|
1568
|
+
function lt(n, i, u) {
|
|
1569
|
+
let b = (F || []).slice();
|
|
1570
|
+
Object.keys(u).forEach((Q) => {
|
|
1571
|
+
if (u[Q] && u[Q].length) {
|
|
1572
|
+
const j = Ht(Q);
|
|
1573
|
+
j && typeof j.onFilter == "function" && (b = b.filter(($e) => u[Q].reduce(
|
|
1574
|
+
(bt, pt) => bt || j.onFilter(pt, $e),
|
|
1575
|
+
!1
|
|
1576
|
+
)));
|
|
1577
|
+
}
|
|
1578
|
+
});
|
|
1579
|
+
const L = (Q) => Q.slice().sort(Qe(i)).map((j) => ie(j[E]) ? {
|
|
1580
|
+
...j,
|
|
1581
|
+
[E]: L(j[E])
|
|
1582
|
+
} : j);
|
|
1583
|
+
return n.direction && typeof n.sorterFn == "function" || i.length ? L(b) : b;
|
|
1584
|
+
}
|
|
1585
|
+
const Ue = lt(
|
|
1586
|
+
Z,
|
|
1587
|
+
se,
|
|
1588
|
+
ke
|
|
1589
|
+
);
|
|
1590
|
+
function Ve(n = Ue) {
|
|
1591
|
+
const i = y.pageSize || X || 10, u = v === "middle" ? "default" : v;
|
|
1592
|
+
let b = "top";
|
|
1593
|
+
P === "tl" || P === "bl" ? b = "bottom" : b = "top";
|
|
1594
|
+
const L = ie(n) ? n.length : 0, Q = Math.ceil(L / i) < re ? 1 : re;
|
|
1595
|
+
Q !== re && ce(Q);
|
|
1596
|
+
let j = {
|
|
1597
|
+
size: u,
|
|
1598
|
+
total: L,
|
|
1599
|
+
pageSize: i,
|
|
1600
|
+
current: Q,
|
|
1601
|
+
selectProps: {
|
|
1602
|
+
triggerProps: {
|
|
1603
|
+
position: b
|
|
1604
|
+
}
|
|
1605
|
+
}
|
|
1606
|
+
};
|
|
1607
|
+
return typeof V == "object" && V.selectProps && (j.selectProps = {
|
|
1608
|
+
...j.selectProps,
|
|
1609
|
+
...V.selectProps
|
|
1610
|
+
}), q(V) && (j = {
|
|
1611
|
+
...j,
|
|
1612
|
+
...V
|
|
1613
|
+
}), q(y) && (j = {
|
|
1614
|
+
...j,
|
|
1615
|
+
...y
|
|
1616
|
+
}), j.onChange = Nn, j;
|
|
1617
|
+
}
|
|
1618
|
+
const ct = Ve(), Je = Ze();
|
|
1619
|
+
function Ze(n = Ue, i = ct) {
|
|
1620
|
+
const { current: u = 0, pageSize: b = 10 } = i;
|
|
1621
|
+
return V === !1 || q(V) && w.length <= b ? n : n.slice((u - 1) * b, u * b);
|
|
1622
|
+
}
|
|
1623
|
+
const Lt = Dn(Bt, 100), Ie = !!(p && p.y), et = $ == null ? void 0 : $(te(Ue)), gt = $ && Pe.isValidElement(et) && et.props.fixed, pn = Ie && gt;
|
|
1624
|
+
zn(() => {
|
|
1625
|
+
Bt(), ut(window, "resize", Lt);
|
|
1626
|
+
const n = Y.current, i = W.current, u = J.current;
|
|
1627
|
+
i && ut(i, "scroll", je);
|
|
1628
|
+
const b = n && n.parentNode;
|
|
1629
|
+
return n && b && ut(b, "scroll", je), u && ut(u, "scroll", je), () => {
|
|
1630
|
+
ht(window, "resize", Lt), i && ht(i, "scroll", je), b && ht(b, "scroll", je), u && ht(u, "scroll", je);
|
|
1631
|
+
};
|
|
1632
|
+
}, [
|
|
1633
|
+
rt,
|
|
1634
|
+
st,
|
|
1635
|
+
p == null ? void 0 : p.x,
|
|
1636
|
+
p == null ? void 0 : p.y,
|
|
1637
|
+
z.length,
|
|
1638
|
+
w
|
|
1639
|
+
]), Tt(() => {
|
|
1640
|
+
const { total: n, pageSize: i } = Ve(w);
|
|
1641
|
+
Math.ceil(n / i) < re && ce(1);
|
|
1642
|
+
}, [w == null ? void 0 : w.length]), Tt(() => {
|
|
1643
|
+
at();
|
|
1644
|
+
}, [w, rt, st, s]), Mn(o, () => ({
|
|
1645
|
+
getRootDomElement: Ot,
|
|
1646
|
+
scrollIntoView: (n) => {
|
|
1647
|
+
le.current && le.current.scrollTo({ key: n });
|
|
1648
|
+
}
|
|
1649
|
+
}));
|
|
1650
|
+
function Ot() {
|
|
1651
|
+
return oe.current;
|
|
1652
|
+
}
|
|
1653
|
+
function Bt() {
|
|
1654
|
+
var i, u;
|
|
1655
|
+
at();
|
|
1656
|
+
const n = Ot();
|
|
1657
|
+
if (n && (it || p && p.x)) {
|
|
1658
|
+
const b = n.querySelector(`.${f}-body`) || n.querySelector(`.${f}-content-inner`), L = (u = (i = b == null ? void 0 : b.getBoundingClientRect) == null ? void 0 : i.call(b)) == null ? void 0 : u.width;
|
|
1659
|
+
Ae(L);
|
|
1660
|
+
}
|
|
1661
|
+
}
|
|
1662
|
+
const un = tt(
|
|
1663
|
+
Hn(() => {
|
|
1664
|
+
const n = oe.current, i = Ie ? W.current : fe.current && fe.current.parentNode;
|
|
1665
|
+
if (i) {
|
|
1666
|
+
const u = s ? -i.scrollLeft : i.scrollLeft, b = u === 0, L = u + 1 >= i.children[0].getBoundingClientRect().width - i.getBoundingClientRect().width;
|
|
1667
|
+
b && L ? dt(
|
|
1668
|
+
n.classList,
|
|
1669
|
+
`${f}-scroll-position-both`
|
|
1670
|
+
) : b ? dt(
|
|
1671
|
+
n.classList,
|
|
1672
|
+
`${f}-scroll-position-${s ? "right" : "left"}`
|
|
1673
|
+
) : L ? dt(
|
|
1674
|
+
n.classList,
|
|
1675
|
+
`${f}-scroll-position-${s ? "left" : "right"}`
|
|
1676
|
+
) : dt(
|
|
1677
|
+
n.classList,
|
|
1678
|
+
`${f}-scroll-position-middle`
|
|
1679
|
+
);
|
|
1680
|
+
} else
|
|
1681
|
+
n && Dt(n.classList);
|
|
1682
|
+
}, 100),
|
|
1683
|
+
[oe.current, W.current, Ie, s]
|
|
1684
|
+
);
|
|
1685
|
+
function at() {
|
|
1686
|
+
if (it || p && q(p) && p.x) {
|
|
1687
|
+
const n = oe.current;
|
|
1688
|
+
n && (rt && Kt(
|
|
1689
|
+
n.classList,
|
|
1690
|
+
`${f}-has-fixed-col-left`
|
|
1691
|
+
), st && Kt(
|
|
1692
|
+
n.classList,
|
|
1693
|
+
`${f}-has-fixed-col-right`
|
|
1694
|
+
)), un();
|
|
1695
|
+
}
|
|
1696
|
+
}
|
|
1697
|
+
function Kt(n, i) {
|
|
1698
|
+
n.contains(i) || n.add(i);
|
|
1699
|
+
}
|
|
1700
|
+
function Dt(n) {
|
|
1701
|
+
n.remove(`${f}-scroll-position-both`), n.remove(`${f}-scroll-position-left`), n.remove(`${f}-scroll-position-right`), n.remove(`${f}-scroll-position-middle`);
|
|
1702
|
+
}
|
|
1703
|
+
function dt(n, i) {
|
|
1704
|
+
n.contains(i) || (Dt(n), n.add(i));
|
|
1705
|
+
}
|
|
1706
|
+
const {
|
|
1707
|
+
selectedRowKeys: Ct,
|
|
1708
|
+
indeterminateKeys: hn,
|
|
1709
|
+
onCheckAll: mn,
|
|
1710
|
+
onCheck: yn,
|
|
1711
|
+
onCheckRadio: xn,
|
|
1712
|
+
setSelectedRowKeys: gn,
|
|
1713
|
+
allSelectedRowKeys: Cn,
|
|
1714
|
+
flattenData: wn
|
|
1715
|
+
} = uo(C, Je, F, Le);
|
|
1716
|
+
function Ht(n) {
|
|
1717
|
+
return z.find((i, u) => typeof i.key < "u" ? typeof i.key == "number" && typeof n == "string" ? i.key.toString() === n : i.key === n : typeof i.dataIndex < "u" ? i.dataIndex === n : typeof n == "number" ? u === n : !1);
|
|
1718
|
+
}
|
|
1719
|
+
function Nn(n, i) {
|
|
1720
|
+
var b, L;
|
|
1721
|
+
ce(n), ye(i), n !== re && $n(), D && !D.checkCrossPage && Ct.length && (gn([]), (b = D.onChange) == null || b.call(D, [], []));
|
|
1722
|
+
const u = { ...Ve(), current: n, pageSize: i };
|
|
1723
|
+
K == null || K(
|
|
1724
|
+
u,
|
|
1725
|
+
se.length === 1 ? se[0] : se,
|
|
1726
|
+
ke,
|
|
1727
|
+
{
|
|
1728
|
+
currentData: te(
|
|
1729
|
+
Ze(Ue, u)
|
|
1730
|
+
),
|
|
1731
|
+
currentAllData: te(Ue),
|
|
1732
|
+
action: "paginate"
|
|
1733
|
+
}
|
|
1734
|
+
), (L = y.onChange) == null || L.call(y, n, i);
|
|
1735
|
+
}
|
|
1736
|
+
function $n() {
|
|
1737
|
+
if (!W.current)
|
|
1738
|
+
return;
|
|
1739
|
+
const i = W.current.scrollTop;
|
|
1740
|
+
new Bn({
|
|
1741
|
+
from: { scrollTop: i },
|
|
1742
|
+
to: { scrollTop: 0 },
|
|
1743
|
+
easing: Kn,
|
|
1744
|
+
duration: 300,
|
|
1745
|
+
onUpdate: (b) => {
|
|
1746
|
+
W.current && (W.current.scrollTop = b.scrollTop);
|
|
1747
|
+
}
|
|
1748
|
+
}).start();
|
|
1749
|
+
}
|
|
1750
|
+
function je(n) {
|
|
1751
|
+
const { target: i } = n, u = W.current, b = Y.current && Y.current.parentNode, L = J.current;
|
|
1752
|
+
i.scrollLeft !== he.current && (b && (b.scrollLeft = i.scrollLeft), u && (u.scrollLeft = i.scrollLeft), L && (L.scrollLeft = i.scrollLeft), at()), he.current = n.target.scrollLeft;
|
|
1753
|
+
}
|
|
1754
|
+
function bn(n) {
|
|
1755
|
+
const { target: i } = n, u = fe.current;
|
|
1756
|
+
i.scrollLeft !== he.current && (u.scrollLeft = i.scrollLeft, at()), he.current = n.target.scrollLeft;
|
|
1757
|
+
}
|
|
1758
|
+
const [Wt, Sn] = po(
|
|
1759
|
+
C,
|
|
1760
|
+
wn,
|
|
1761
|
+
Le
|
|
1762
|
+
);
|
|
1763
|
+
let Mt = {}, wt = {};
|
|
1764
|
+
p && (p.x && (typeof p.x == "number" || typeof p.x == "string") && (wt = {
|
|
1765
|
+
width: p.x
|
|
1766
|
+
}), p.y && (typeof p.y == "number" || typeof p.y == "string") && (Mt = {
|
|
1767
|
+
maxHeight: p.y
|
|
1768
|
+
}));
|
|
1769
|
+
function Rn() {
|
|
1770
|
+
const n = Y.current && Y.current.parentNode, i = io(n);
|
|
1771
|
+
i && i > 0 && (n.style.marginBottom = `-${i}px`, n.style.paddingBottom = "0px", J.current && (J.current.style.marginBottom = `-${i}px`, J.current.style.paddingBottom = "0px")), setTimeout(() => {
|
|
1772
|
+
const u = W.current;
|
|
1773
|
+
lo(u) ? (pe.current = !0, n && (n.style.overflowY = "scroll"), J.current && (J.current.style.overflowY = "scroll")) : n && pe.current && (pe.current = !1, n.style.overflowY = "auto", J.current && (J.current.style.overflowY = "auto"));
|
|
1774
|
+
});
|
|
1775
|
+
}
|
|
1776
|
+
const zt = /* @__PURE__ */ a(
|
|
1777
|
+
ko,
|
|
1778
|
+
{
|
|
1779
|
+
...C,
|
|
1780
|
+
activeSorters: se,
|
|
1781
|
+
currentSorter: Z,
|
|
1782
|
+
selectedRowKeys: Ct,
|
|
1783
|
+
currentFilters: ke,
|
|
1784
|
+
onCheckAll: mn,
|
|
1785
|
+
onSort: Ee,
|
|
1786
|
+
data: Je,
|
|
1787
|
+
onHandleFilter: ve,
|
|
1788
|
+
onHandleFilterReset: ze,
|
|
1789
|
+
prefixCls: f,
|
|
1790
|
+
allSelectedRowKeys: Cn,
|
|
1791
|
+
groupColumns: me,
|
|
1792
|
+
stickyOffsets: Se,
|
|
1793
|
+
groupStickyClassNames: M
|
|
1794
|
+
}
|
|
1795
|
+
);
|
|
1796
|
+
function Tn() {
|
|
1797
|
+
const n = q(p) && p.x === "max-content";
|
|
1798
|
+
return Ie || x ? /* @__PURE__ */ a(Ke, { className: `${f}-header`, children: /* @__PURE__ */ ue(
|
|
1799
|
+
Te,
|
|
1800
|
+
{
|
|
1801
|
+
ref: Y,
|
|
1802
|
+
style: n ? {} : wt,
|
|
1803
|
+
children: [
|
|
1804
|
+
/* @__PURE__ */ a(
|
|
1805
|
+
mt,
|
|
1806
|
+
{
|
|
1807
|
+
columns: z,
|
|
1808
|
+
prefixCls: f,
|
|
1809
|
+
producer: !1,
|
|
1810
|
+
columnWidths: n && p.y ? Fe : null
|
|
1811
|
+
}
|
|
1812
|
+
),
|
|
1813
|
+
zt
|
|
1814
|
+
]
|
|
1815
|
+
}
|
|
1816
|
+
) }) : zt;
|
|
1817
|
+
}
|
|
1818
|
+
const Ut = et && /* @__PURE__ */ a(
|
|
1819
|
+
bo,
|
|
1820
|
+
{
|
|
1821
|
+
prefixCls: f,
|
|
1822
|
+
summary: $,
|
|
1823
|
+
data: Je,
|
|
1824
|
+
columns: z,
|
|
1825
|
+
stickyOffsets: Se,
|
|
1826
|
+
stickyClassNames: ae
|
|
1827
|
+
}
|
|
1828
|
+
), Vt = /* @__PURE__ */ a(
|
|
1829
|
+
$o,
|
|
1830
|
+
{
|
|
1831
|
+
...C,
|
|
1832
|
+
selectedRowKeys: Ct,
|
|
1833
|
+
indeterminateKeys: hn,
|
|
1834
|
+
expandedRowKeys: Wt,
|
|
1835
|
+
onCheck: yn,
|
|
1836
|
+
onCheckRadio: xn,
|
|
1837
|
+
onClickExpandBtn: Sn,
|
|
1838
|
+
columns: z,
|
|
1839
|
+
data: Je,
|
|
1840
|
+
prefixCls: f,
|
|
1841
|
+
hasFixedColumn: it,
|
|
1842
|
+
tableViewWidth: _e,
|
|
1843
|
+
indentSize: I,
|
|
1844
|
+
noDataElement: k || c("Table"),
|
|
1845
|
+
activeSorters: se,
|
|
1846
|
+
currentSorter: Z,
|
|
1847
|
+
stickyOffsets: Se,
|
|
1848
|
+
stickyClassNames: ae,
|
|
1849
|
+
getRowKey: Le,
|
|
1850
|
+
saveVirtualListRef: (n) => {
|
|
1851
|
+
x && (le.current = n, W.current = n == null ? void 0 : n.dom);
|
|
1852
|
+
},
|
|
1853
|
+
___dangerouslySetInnerHTML___: C.___dangerouslySetInnerHTML___
|
|
1854
|
+
}
|
|
1855
|
+
), jt = !x && !pn ? /* @__PURE__ */ ue(yt, { children: [
|
|
1856
|
+
Vt,
|
|
1857
|
+
Ut
|
|
1858
|
+
] }) : Vt;
|
|
1859
|
+
nt(() => {
|
|
1860
|
+
let n;
|
|
1861
|
+
return W.current && (n = new ResizeObserver(Rn), n.observe(W.current)), () => {
|
|
1862
|
+
var i, u;
|
|
1863
|
+
W.current && ((i = n == null ? void 0 : n.unobserve) == null || i.call(n, W.current)), (u = n == null ? void 0 : n.disconnect) == null || u.call(n), n = null;
|
|
1864
|
+
};
|
|
1865
|
+
}, [W.current]);
|
|
1866
|
+
function kn() {
|
|
1867
|
+
const n = q(p) && p.x === "max-content" && !!p.y && ie(w) && w.length > 0;
|
|
1868
|
+
return Ie && !x ? /* @__PURE__ */ a(
|
|
1869
|
+
Be,
|
|
1870
|
+
{
|
|
1871
|
+
ref: W,
|
|
1872
|
+
className: `${f}-body`,
|
|
1873
|
+
style: Mt,
|
|
1874
|
+
children: /* @__PURE__ */ ue(Te, { style: wt, children: [
|
|
1875
|
+
/* @__PURE__ */ a(
|
|
1876
|
+
mt,
|
|
1877
|
+
{
|
|
1878
|
+
columns: z,
|
|
1879
|
+
prefixCls: f,
|
|
1880
|
+
producer: n,
|
|
1881
|
+
onSetColumnWidths: Oe,
|
|
1882
|
+
expandedRowKeys: Wt,
|
|
1883
|
+
data: w
|
|
1884
|
+
}
|
|
1885
|
+
),
|
|
1886
|
+
jt
|
|
1887
|
+
] })
|
|
1888
|
+
}
|
|
1889
|
+
) : jt;
|
|
1890
|
+
}
|
|
1891
|
+
function vn() {
|
|
1892
|
+
let n = {};
|
|
1893
|
+
p && q(p) && p.x && (n = {
|
|
1894
|
+
width: p.x
|
|
1895
|
+
});
|
|
1896
|
+
const i = /* @__PURE__ */ a("div", { className: `${f}-tfoot`, ref: J, children: /* @__PURE__ */ ue(Te, { style: n, children: [
|
|
1897
|
+
/* @__PURE__ */ a(mt, { columns: z, prefixCls: f }),
|
|
1898
|
+
Ut
|
|
1899
|
+
] }) }), u = et && Ie && gt === "top", b = et && Ie && gt === "bottom", L = /* @__PURE__ */ ue(yt, { children: [
|
|
1900
|
+
B ? Tn() : null,
|
|
1901
|
+
u && i,
|
|
1902
|
+
kn(),
|
|
1903
|
+
b && i
|
|
1904
|
+
] });
|
|
1905
|
+
return /* @__PURE__ */ ue(yt, { children: [
|
|
1906
|
+
/* @__PURE__ */ a("div", { className: `${f}-container`, children: /* @__PURE__ */ a("div", { className: `${f}-content-scroll`, children: /* @__PURE__ */ a(
|
|
1907
|
+
"div",
|
|
1908
|
+
{
|
|
1909
|
+
className: `${f}-content-inner`,
|
|
1910
|
+
onScroll: Ie ? void 0 : bn,
|
|
1911
|
+
children: Ie || x ? L : /* @__PURE__ */ ue(Te, { ref: fe, style: n, children: [
|
|
1912
|
+
/* @__PURE__ */ a(mt, { prefixCls: f, columns: z }),
|
|
1913
|
+
L
|
|
1914
|
+
] })
|
|
1915
|
+
}
|
|
1916
|
+
) }) }),
|
|
1917
|
+
typeof O == "function" && /* @__PURE__ */ a("div", { className: `${f}-footer`, children: O(Je) })
|
|
1918
|
+
] });
|
|
1919
|
+
}
|
|
1920
|
+
if (!S.length)
|
|
1921
|
+
return null;
|
|
1922
|
+
const _n = q(T) ? T.wrapper : T, Nt = q(T) ? T.cell : _, En = q(T) ? T.cell || T.headerCell : _, In = q(T) ? T.cell || T.bodyCell : _, Pn = ne(
|
|
1923
|
+
f,
|
|
1924
|
+
`${f}-size-${v}`,
|
|
1925
|
+
{
|
|
1926
|
+
[`${f}-border`]: _n,
|
|
1927
|
+
[`${f}-border-cell`]: Nt,
|
|
1928
|
+
[`${f}-border-header-cell`]: !Nt && En,
|
|
1929
|
+
[`${f}-border-body-cell`]: !Nt && In,
|
|
1930
|
+
[`${f}-stripe`]: G,
|
|
1931
|
+
[`${f}-hover`]: ee,
|
|
1932
|
+
[`${f}-type-radio`]: D && D.type === "radio",
|
|
1933
|
+
[`${f}-layout-fixed`]: H || p && (p.x || p.y) || S.find((n) => n.ellipsis),
|
|
1934
|
+
[`${f}-fixed-column`]: it,
|
|
1935
|
+
[`${f}-virtualized`]: x,
|
|
1936
|
+
[`${f}-rtl`]: s
|
|
1937
|
+
},
|
|
1938
|
+
N
|
|
1939
|
+
), $t = P === "tl" || P === "tr" || P === "topCenter", An = ne(`${f}-pagination`, {
|
|
1940
|
+
[`${f}-pagination-left`]: P === "tl" || P === "bl",
|
|
1941
|
+
[`${f}-pagination-center`]: P === "topCenter" || P === "bottomCenter",
|
|
1942
|
+
[`${f}-pagination-top`]: $t
|
|
1943
|
+
});
|
|
1944
|
+
let ft = C.loading;
|
|
1945
|
+
typeof ft == "boolean" && (ft = { loading: ft });
|
|
1946
|
+
const Yt = typeof A == "function" ? A(/* @__PURE__ */ a(Qt, { ...ct })) : /* @__PURE__ */ a("div", { className: An, children: /* @__PURE__ */ a(Qt, { ...ct }) }), qt = V !== !1 && (Ue.length !== 0 || ct.total > 0);
|
|
1947
|
+
return /* @__PURE__ */ a(
|
|
1948
|
+
"div",
|
|
1949
|
+
{
|
|
1950
|
+
ref: oe,
|
|
1951
|
+
style: m,
|
|
1952
|
+
className: Pn,
|
|
1953
|
+
...Vn(C),
|
|
1954
|
+
children: /* @__PURE__ */ ue(
|
|
1955
|
+
On,
|
|
1956
|
+
{
|
|
1957
|
+
className: `${f}-spin`,
|
|
1958
|
+
element: h,
|
|
1959
|
+
...ft,
|
|
1960
|
+
children: [
|
|
1961
|
+
qt && $t && Yt,
|
|
1962
|
+
vn(),
|
|
1963
|
+
qt && !$t && Yt
|
|
1964
|
+
]
|
|
1965
|
+
}
|
|
1966
|
+
)
|
|
1967
|
+
}
|
|
1968
|
+
);
|
|
1969
|
+
}
|
|
1970
|
+
const dn = Pt(Io);
|
|
1971
|
+
dn.displayName = "Table";
|
|
1972
|
+
function fn(t) {
|
|
1973
|
+
const { children: o, ...r } = t;
|
|
1974
|
+
return /* @__PURE__ */ a("td", { ...ro(r, ["$$PqbTableSummaryCell"]), children: o });
|
|
1975
|
+
}
|
|
1976
|
+
fn.__PQB_TABLE_SUMMARY_CELL__ = !0;
|
|
1977
|
+
function Po(t) {
|
|
1978
|
+
const { rtl: o } = We(Xe), { columns: r, stickyOffsets: h, stickyClassNames: e, prefixCls: d } = We(an), { children: c, ...l } = t, s = Pe.Children.map(
|
|
1979
|
+
c,
|
|
1980
|
+
(y) => y.props.colSpan || 1
|
|
1981
|
+
), C = Pe.Children.map(c, (y, m) => {
|
|
1982
|
+
var B, G;
|
|
1983
|
+
const N = y, g = xt(N, "type.__PQB_TABLE_SUMMARY_CELL__") || xt(N, "props.$$PqbTableSummaryCell"), T = (B = N == null ? void 0 : N.props) == null ? void 0 : B.style, _ = (G = N == null ? void 0 : N.props) == null ? void 0 : G.className, w = s.slice(0, m).reduce((ee, V) => ee + V, 0), p = r[w].fixed === "left" ? { [o ? "right" : "left"]: h[w] } : r[w].fixed === "right" ? { [o ? "left" : "right"]: h[w] } : {}, k = r[w].fixed === "left" || r[w].fixed === "right" ? e[w] : "";
|
|
1984
|
+
return g ? Pe.cloneElement(N, {
|
|
1985
|
+
...N.props,
|
|
1986
|
+
className: ne(`${d}-td`, k, _),
|
|
1987
|
+
style: { ...T, ...p }
|
|
1988
|
+
}) : y;
|
|
1989
|
+
});
|
|
1990
|
+
return /* @__PURE__ */ a("tr", { ...l, children: C });
|
|
1991
|
+
}
|
|
1992
|
+
function Ft(t) {
|
|
1993
|
+
return t.children;
|
|
1994
|
+
}
|
|
1995
|
+
Ft.Row = Po;
|
|
1996
|
+
Ft.Cell = fn;
|
|
1997
|
+
const Ao = dn;
|
|
1998
|
+
Ao.Summary = Ft;
|
|
1999
|
+
export {
|
|
2000
|
+
Ao as default
|
|
2001
|
+
};
|