@aloudata/aloudata-design 2.19.5 → 3.0.0-beta.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/AMenu/index.d.ts +34 -3
- package/dist/AMenu/index.js +53 -2
- package/dist/AMenu/index.js.map +1 -0
- package/dist/AProgress/index.d.ts +17 -2
- package/dist/AProgress/index.js +82 -2
- package/dist/AProgress/index.js.map +1 -0
- package/dist/Alert/index.d.ts +16 -3
- package/dist/Alert/index.js +91 -2
- package/dist/Alert/index.js.map +1 -0
- package/dist/App/index.d.ts +6 -2
- package/dist/App/index.js +22 -31
- package/dist/App/index.js.map +1 -0
- package/dist/Avatar/component/Avatar/helper.d.ts +1 -1
- package/dist/Avatar/component/Avatar/helper.js +49 -82
- package/dist/Avatar/component/Avatar/helper.js.map +1 -0
- package/dist/Avatar/component/Avatar/index.d.ts +7 -69
- package/dist/Avatar/component/Avatar/index.js +71 -66
- package/dist/Avatar/component/Avatar/index.js.map +1 -0
- package/dist/Avatar/component/Avatar/type.d.ts +10 -1
- package/dist/Avatar/component/Avatar/type.js +19 -15
- package/dist/Avatar/component/Avatar/type.js.map +1 -0
- package/dist/Avatar/index.d.ts +14 -1
- package/dist/Avatar/index.js +32 -4
- package/dist/Avatar/index.js.map +1 -0
- package/dist/Badge/index.d.ts +2 -2
- package/dist/Badge/index.js +46 -24
- package/dist/Badge/index.js.map +1 -0
- package/dist/Breadcrumb/index.d.ts +20 -4
- package/dist/Breadcrumb/index.js +62 -31
- package/dist/Breadcrumb/index.js.map +1 -0
- package/dist/Button/index.d.ts +17 -39
- package/dist/Button/index.js +175 -94
- package/dist/Button/index.js.map +1 -0
- package/dist/Card/index.d.ts +35 -2
- package/dist/Card/index.js +72 -2
- package/dist/Card/index.js.map +1 -0
- package/dist/Carousel/index.d.ts +34 -3
- package/dist/Carousel/index.js +103 -2
- package/dist/Carousel/index.js.map +1 -0
- package/dist/Checkbox/component/CheckboxGroup/index.d.ts +1 -4
- package/dist/Checkbox/component/CheckboxGroup/index.js +2 -22
- package/dist/Checkbox/index.d.ts +6 -6
- package/dist/Checkbox/index.js +110 -37
- package/dist/Checkbox/index.js.map +1 -0
- package/dist/Checkbox/type.d.ts +24 -83
- package/dist/Checkbox/type.js +2 -5
- package/dist/Col/index.d.ts +21 -3
- package/dist/Col/index.js +111 -2
- package/dist/Col/index.js.map +1 -0
- package/dist/Collapse/index.d.ts +42 -5
- package/dist/Collapse/index.js +130 -19
- package/dist/Collapse/index.js.map +1 -0
- package/dist/ColorPicker/ComplexColorPicker/ColorAlphaInput.d.ts +2 -2
- package/dist/ColorPicker/ComplexColorPicker/ColorAlphaInput.js +29 -42
- package/dist/ColorPicker/ComplexColorPicker/ColorAlphaInput.js.map +1 -0
- package/dist/ColorPicker/ComplexColorPicker/ColorHexInput.d.ts +2 -2
- package/dist/ColorPicker/ComplexColorPicker/ColorHexInput.js +29 -44
- package/dist/ColorPicker/ComplexColorPicker/ColorHexInput.js.map +1 -0
- package/dist/ColorPicker/ComplexColorPicker/ColorHsbInput.d.ts +2 -2
- package/dist/ColorPicker/ComplexColorPicker/ColorHsbInput.js +54 -72
- package/dist/ColorPicker/ComplexColorPicker/ColorHsbInput.js.map +1 -0
- package/dist/ColorPicker/ComplexColorPicker/ColorInput.d.ts +3 -3
- package/dist/ColorPicker/ComplexColorPicker/ColorInput.js +74 -74
- package/dist/ColorPicker/ComplexColorPicker/ColorInput.js.map +1 -0
- package/dist/ColorPicker/ComplexColorPicker/ColorRgbInput.d.ts +2 -2
- package/dist/ColorPicker/ComplexColorPicker/ColorRgbInput.js +51 -63
- package/dist/ColorPicker/ComplexColorPicker/ColorRgbInput.js.map +1 -0
- package/dist/ColorPicker/ComplexColorPicker/ColorSteppers.d.ts +2 -3
- package/dist/ColorPicker/ComplexColorPicker/ColorSteppers.js +27 -44
- package/dist/ColorPicker/ComplexColorPicker/ColorSteppers.js.map +1 -0
- package/dist/ColorPicker/ComplexColorPicker/index.d.ts +1 -2
- package/dist/ColorPicker/ComplexColorPicker/index.js +72 -89
- package/dist/ColorPicker/ComplexColorPicker/index.js.map +1 -0
- package/dist/ColorPicker/color.d.ts +2 -2
- package/dist/ColorPicker/color.js +72 -125
- package/dist/ColorPicker/color.js.map +1 -0
- package/dist/ColorPicker/constant.js +47 -3
- package/dist/ColorPicker/constant.js.map +1 -0
- package/dist/ColorPicker/hooks/useColor.d.ts +2 -2
- package/dist/ColorPicker/hooks/useColor.js +21 -31
- package/dist/ColorPicker/hooks/useColor.js.map +1 -0
- package/dist/ColorPicker/index.d.ts +3 -3
- package/dist/ColorPicker/index.js +159 -204
- package/dist/ColorPicker/index.js.map +1 -0
- package/dist/ColorPicker/interface.d.ts +8 -5
- package/dist/ColorPicker/interface.js +9 -6
- package/dist/ColorPicker/interface.js.map +1 -0
- package/dist/ColorPicker/util.d.ts +3 -3
- package/dist/ColorPicker/util.js +20 -61
- package/dist/ColorPicker/util.js.map +1 -0
- package/dist/ConfigProvider/DisabledContext.d.ts +3 -0
- package/dist/ConfigProvider/DisabledContext.js +7 -0
- package/dist/ConfigProvider/DisabledContext.js.map +1 -0
- package/dist/ConfigProvider/getUserList.d.ts +1 -1
- package/dist/ConfigProvider/getUserList.js +12 -24
- package/dist/ConfigProvider/getUserList.js.map +1 -0
- package/dist/ConfigProvider/hooks/useGetUserList.d.ts +4 -4
- package/dist/ConfigProvider/hooks/useGetUserList.js +14 -14
- package/dist/ConfigProvider/hooks/useGetUserList.js.map +1 -0
- package/dist/ConfigProvider/index.d.ts +33 -13
- package/dist/ConfigProvider/index.js +34 -44
- package/dist/ConfigProvider/index.js.map +1 -0
- package/dist/ConfigProvider/sizeContext.js +12 -12
- package/dist/ConfigProvider/sizeContext.js.map +1 -0
- package/dist/DataPreviewTable/components/Body/Cell.d.ts +3 -3
- package/dist/DataPreviewTable/components/Body/Cell.js +35 -37
- package/dist/DataPreviewTable/components/Body/Cell.js.map +1 -0
- package/dist/DataPreviewTable/components/Body/Error.d.ts +2 -2
- package/dist/DataPreviewTable/components/Body/Error.js +21 -19
- package/dist/DataPreviewTable/components/Body/Error.js.map +1 -0
- package/dist/DataPreviewTable/components/Body/index.d.ts +2 -2
- package/dist/DataPreviewTable/components/Body/index.js +37 -51
- package/dist/DataPreviewTable/components/Body/index.js.map +1 -0
- package/dist/DataPreviewTable/components/DragBar/Mask.d.ts +1 -2
- package/dist/DataPreviewTable/components/DragBar/Mask.js +31 -29
- package/dist/DataPreviewTable/components/DragBar/Mask.js.map +1 -0
- package/dist/DataPreviewTable/components/DragBar/index.d.ts +2 -2
- package/dist/DataPreviewTable/components/DragBar/index.js +58 -76
- package/dist/DataPreviewTable/components/DragBar/index.js.map +1 -0
- package/dist/DataPreviewTable/components/Header/index.d.ts +1 -2
- package/dist/DataPreviewTable/components/Header/index.js +43 -50
- package/dist/DataPreviewTable/components/Header/index.js.map +1 -0
- package/dist/DataPreviewTable/constant.js +2 -6
- package/dist/DataPreviewTable/constant.js.map +1 -0
- package/dist/DataPreviewTable/hooks/useDirection.js +164 -215
- package/dist/DataPreviewTable/hooks/useDirection.js.map +1 -0
- package/dist/DataPreviewTable/index.d.ts +2 -2
- package/dist/DataPreviewTable/index.js +105 -131
- package/dist/DataPreviewTable/index.js.map +1 -0
- package/dist/DataPreviewTable/interface.d.ts +1 -1
- package/dist/DataPreviewTable/interface.js +14 -9
- package/dist/DataPreviewTable/interface.js.map +1 -0
- package/dist/DataPreviewTable/utils/findRange.js +41 -63
- package/dist/DataPreviewTable/utils/findRange.js.map +1 -0
- package/dist/DataPreviewTable/utils/getColumnOffsetsFromWidths.js +13 -8
- package/dist/DataPreviewTable/utils/getColumnOffsetsFromWidths.js.map +1 -0
- package/dist/DataPreviewTable/utils/getColumnRange.js +11 -21
- package/dist/DataPreviewTable/utils/getColumnRange.js.map +1 -0
- package/dist/DataPreviewTable/utils/getRowRange.js +15 -22
- package/dist/DataPreviewTable/utils/getRowRange.js.map +1 -0
- package/dist/DataPreviewTable/utils/getTableLayout.js +19 -17
- package/dist/DataPreviewTable/utils/getTableLayout.js.map +1 -0
- package/dist/DatePicker/index.d.ts +39 -67
- package/dist/DatePicker/index.js +77 -206
- package/dist/DatePicker/index.js.map +1 -0
- package/dist/Divider/index.d.ts +1 -2
- package/dist/Divider/index.js +34 -19
- package/dist/Divider/index.js.map +1 -0
- package/dist/DoubleCircleIcon/index.d.ts +6 -7
- package/dist/DoubleCircleIcon/index.js +2 -34
- package/dist/Drawer/index.d.ts +27 -3
- package/dist/Drawer/index.js +93 -2
- package/dist/Drawer/index.js.map +1 -0
- package/dist/Dropdown/index.d.ts +4 -5
- package/dist/Dropdown/index.js +145 -189
- package/dist/Dropdown/index.js.map +1 -0
- package/dist/Empty/image/Data.d.ts +1 -2
- package/dist/Empty/image/Data.js +267 -219
- package/dist/Empty/image/Data.js.map +1 -0
- package/dist/Empty/image/Search.d.ts +1 -2
- package/dist/Empty/image/Search.js +15 -10
- package/dist/Empty/image/Search.js.map +1 -0
- package/dist/Empty/image/SearchSmall.d.ts +1 -2
- package/dist/Empty/image/SearchSmall.js +34 -27
- package/dist/Empty/image/SearchSmall.js.map +1 -0
- package/dist/Empty/image/User.d.ts +1 -2
- package/dist/Empty/image/User.js +249 -196
- package/dist/Empty/image/User.js.map +1 -0
- package/dist/Empty/image/WorkBook.d.ts +1 -2
- package/dist/Empty/image/WorkBook.js +246 -202
- package/dist/Empty/image/WorkBook.js.map +1 -0
- package/dist/Empty/index.js +62 -70
- package/dist/Empty/index.js.map +1 -0
- package/dist/Form/FormItemContext.d.ts +27 -0
- package/dist/Form/FormItemContext.js +8 -0
- package/dist/Form/FormItemContext.js.map +1 -0
- package/dist/Form/hooks/useFormItemStatus.d.ts +6 -0
- package/dist/Form/hooks/useFormItemStatus.js +2 -0
- package/dist/Form/index.d.ts +95 -19
- package/dist/Form/index.js +257 -60
- package/dist/Form/index.js.map +1 -0
- package/dist/HighlightText/index.d.ts +2 -2
- package/dist/HighlightText/index.js +27 -28
- package/dist/HighlightText/index.js.map +1 -0
- package/dist/Icon/components/AlertTriangleDuotone.d.ts +1 -1
- package/dist/Icon/components/AlertTriangleDuotone.js +35 -35
- package/dist/Icon/components/AlertTriangleDuotone.js.map +1 -0
- package/dist/Icon/components/AlertTriangleLine.d.ts +1 -1
- package/dist/Icon/components/AlertTriangleLine.js +35 -35
- package/dist/Icon/components/AlertTriangleLine.js.map +1 -0
- package/dist/Icon/components/ArrowDownFill.d.ts +1 -1
- package/dist/Icon/components/ArrowDownFill.js +35 -35
- package/dist/Icon/components/ArrowDownFill.js.map +1 -0
- package/dist/Icon/components/ArrowDownLightLine.d.ts +1 -1
- package/dist/Icon/components/ArrowDownLightLine.js +35 -35
- package/dist/Icon/components/ArrowDownLightLine.js.map +1 -0
- package/dist/Icon/components/ArrowDownRightFill.js +35 -35
- package/dist/Icon/components/ArrowDownRightFill.js.map +1 -0
- package/dist/Icon/components/ArrowRightLightLine.d.ts +1 -1
- package/dist/Icon/components/ArrowRightLightLine.js +35 -35
- package/dist/Icon/components/ArrowRightLightLine.js.map +1 -0
- package/dist/Icon/components/AttentionCircleFill.d.ts +1 -1
- package/dist/Icon/components/AttentionCircleFill.js +35 -35
- package/dist/Icon/components/AttentionCircleFill.js.map +1 -0
- package/dist/Icon/components/AttentionTriangleFill.d.ts +1 -1
- package/dist/Icon/components/AttentionTriangleFill.js +35 -35
- package/dist/Icon/components/AttentionTriangleFill.js.map +1 -0
- package/dist/Icon/components/AttentionTriangleLightLine.d.ts +1 -1
- package/dist/Icon/components/AttentionTriangleLightLine.js +35 -35
- package/dist/Icon/components/AttentionTriangleLightLine.js.map +1 -0
- package/dist/Icon/components/CancelCircleDuotone.d.ts +1 -1
- package/dist/Icon/components/CancelCircleDuotone.js +39 -38
- package/dist/Icon/components/CancelCircleDuotone.js.map +1 -0
- package/dist/Icon/components/CancelledCircleFill.js +35 -35
- package/dist/Icon/components/CancelledCircleFill.js.map +1 -0
- package/dist/Icon/components/CheckCircleDuotone.d.ts +1 -1
- package/dist/Icon/components/CheckCircleDuotone.js +39 -38
- package/dist/Icon/components/CheckCircleDuotone.js.map +1 -0
- package/dist/Icon/components/CheckCircleFill.d.ts +1 -1
- package/dist/Icon/components/CheckCircleFill.js +35 -35
- package/dist/Icon/components/CheckCircleFill.js.map +1 -0
- package/dist/Icon/components/CheckCircleLightLine.d.ts +1 -1
- package/dist/Icon/components/CheckCircleLightLine.js +37 -38
- package/dist/Icon/components/CheckCircleLightLine.js.map +1 -0
- package/dist/Icon/components/CheckLightLine.d.ts +1 -1
- package/dist/Icon/components/CheckLightLine.js +35 -35
- package/dist/Icon/components/CheckLightLine.js.map +1 -0
- package/dist/Icon/components/ChevronDownLine.d.ts +1 -1
- package/dist/Icon/components/ChevronDownLine.js +35 -35
- package/dist/Icon/components/ChevronDownLine.js.map +1 -0
- package/dist/Icon/components/ChevronLeftLine.d.ts +1 -1
- package/dist/Icon/components/ChevronLeftLine.js +35 -35
- package/dist/Icon/components/ChevronLeftLine.js.map +1 -0
- package/dist/Icon/components/ChevronRightLine.d.ts +1 -1
- package/dist/Icon/components/ChevronRightLine.js +35 -35
- package/dist/Icon/components/ChevronRightLine.js.map +1 -0
- package/dist/Icon/components/CircleLightLine.d.ts +1 -1
- package/dist/Icon/components/CircleLightLine.js +37 -38
- package/dist/Icon/components/CircleLightLine.js.map +1 -0
- package/dist/Icon/components/CloseCircleFill.d.ts +1 -1
- package/dist/Icon/components/CloseCircleFill.js +35 -35
- package/dist/Icon/components/CloseCircleFill.js.map +1 -0
- package/dist/Icon/components/CloseCircleLightLine.d.ts +1 -1
- package/dist/Icon/components/CloseCircleLightLine.js +35 -35
- package/dist/Icon/components/CloseCircleLightLine.js.map +1 -0
- package/dist/Icon/components/CloseCircleRightFill.js +35 -35
- package/dist/Icon/components/CloseCircleRightFill.js.map +1 -0
- package/dist/Icon/components/CloseLLine.d.ts +1 -1
- package/dist/Icon/components/CloseLLine.js +35 -35
- package/dist/Icon/components/CloseLLine.js.map +1 -0
- package/dist/Icon/components/CloseLightLine.d.ts +1 -1
- package/dist/Icon/components/CloseLightLine.js +35 -35
- package/dist/Icon/components/CloseLightLine.js.map +1 -0
- package/dist/Icon/components/CloseMLine.d.ts +1 -1
- package/dist/Icon/components/CloseMLine.js +35 -35
- package/dist/Icon/components/CloseMLine.js.map +1 -0
- package/dist/Icon/components/DangerFill.d.ts +1 -1
- package/dist/Icon/components/DangerFill.js +35 -35
- package/dist/Icon/components/DangerFill.js.map +1 -0
- package/dist/Icon/components/DragLightLine.d.ts +1 -1
- package/dist/Icon/components/DragLightLine.js +35 -35
- package/dist/Icon/components/DragLightLine.js.map +1 -0
- package/dist/Icon/components/DragLine.d.ts +1 -1
- package/dist/Icon/components/DragLine.js +35 -35
- package/dist/Icon/components/DragLine.js.map +1 -0
- package/dist/Icon/components/Ellipsis.js +35 -35
- package/dist/Icon/components/Ellipsis.js.map +1 -0
- package/dist/Icon/components/EyeOffLine.d.ts +1 -1
- package/dist/Icon/components/EyeOffLine.js +35 -35
- package/dist/Icon/components/EyeOffLine.js.map +1 -0
- package/dist/Icon/components/EyeOnLine.d.ts +1 -1
- package/dist/Icon/components/EyeOnLine.js +45 -42
- package/dist/Icon/components/EyeOnLine.js.map +1 -0
- package/dist/Icon/components/FoldDownFill.d.ts +1 -1
- package/dist/Icon/components/FoldDownFill.js +36 -38
- package/dist/Icon/components/FoldDownFill.js.map +1 -0
- package/dist/Icon/components/FoldUpFill.d.ts +1 -1
- package/dist/Icon/components/FoldUpFill.js +36 -38
- package/dist/Icon/components/FoldUpFill.js.map +1 -0
- package/dist/Icon/components/InProgressFill.js +37 -38
- package/dist/Icon/components/InProgressFill.js.map +1 -0
- package/dist/Icon/components/InfoCircleDuotone.d.ts +1 -1
- package/dist/Icon/components/InfoCircleDuotone.js +35 -35
- package/dist/Icon/components/InfoCircleDuotone.js.map +1 -0
- package/dist/Icon/components/InfoCircleLine.d.ts +1 -1
- package/dist/Icon/components/InfoCircleLine.js +35 -35
- package/dist/Icon/components/InfoCircleLine.js.map +1 -0
- package/dist/Icon/components/InformationCircleFill.d.ts +1 -1
- package/dist/Icon/components/InformationCircleFill.js +35 -35
- package/dist/Icon/components/InformationCircleFill.js.map +1 -0
- package/dist/Icon/components/InformationCircleLightLine.d.ts +1 -1
- package/dist/Icon/components/InformationCircleLightLine.js +37 -38
- package/dist/Icon/components/InformationCircleLightLine.js.map +1 -0
- package/dist/Icon/components/Loading2Line.d.ts +1 -1
- package/dist/Icon/components/Loading2Line.js +35 -35
- package/dist/Icon/components/Loading2Line.js.map +1 -0
- package/dist/Icon/components/LoadingDuotone.js +38 -39
- package/dist/Icon/components/LoadingDuotone.js.map +1 -0
- package/dist/Icon/components/LoadingLine.d.ts +1 -1
- package/dist/Icon/components/LoadingLine.js +35 -35
- package/dist/Icon/components/LoadingLine.js.map +1 -0
- package/dist/Icon/components/MoreVerticalLine.d.ts +1 -1
- package/dist/Icon/components/MoreVerticalLine.js +35 -35
- package/dist/Icon/components/MoreVerticalLine.js.map +1 -0
- package/dist/Icon/components/SearchLine.d.ts +1 -1
- package/dist/Icon/components/SearchLine.js +35 -35
- package/dist/Icon/components/SearchLine.js.map +1 -0
- package/dist/Icon/components/SignLightLine.d.ts +1 -1
- package/dist/Icon/components/SignLightLine.js +35 -35
- package/dist/Icon/components/SignLightLine.js.map +1 -0
- package/dist/Icon/components/SortAscendingOrderColor.js +37 -36
- package/dist/Icon/components/SortAscendingOrderColor.js.map +1 -0
- package/dist/Icon/components/SortColor.js +33 -33
- package/dist/Icon/components/SortColor.js.map +1 -0
- package/dist/Icon/components/SortDescendingOrderColor.js +37 -36
- package/dist/Icon/components/SortDescendingOrderColor.js.map +1 -0
- package/dist/Icon/components/TimesLightLine.d.ts +1 -1
- package/dist/Icon/components/TimesLightLine.js +35 -35
- package/dist/Icon/components/TimesLightLine.js.map +1 -0
- package/dist/Icon/components/TrashLightLine.d.ts +1 -1
- package/dist/Icon/components/TrashLightLine.js +37 -38
- package/dist/Icon/components/TrashLightLine.js.map +1 -0
- package/dist/Icon/components/TriangleLightLine.d.ts +1 -1
- package/dist/Icon/components/TriangleLightLine.js +35 -35
- package/dist/Icon/components/TriangleLightLine.js.map +1 -0
- package/dist/Icon/components/User.d.ts +1 -1
- package/dist/Icon/components/User.js +42 -41
- package/dist/Icon/components/User.js.map +1 -0
- package/dist/Icon/components/UserGroup.d.ts +1 -1
- package/dist/Icon/components/UserGroup.js +40 -39
- package/dist/Icon/components/UserGroup.js.map +1 -0
- package/dist/Icon/components/createFromScripts.js +2 -29
- package/dist/Icon/index.d.ts +52 -52
- package/dist/Icon/index.js +52 -52
- package/dist/IconButton/index.d.ts +1 -1
- package/dist/IconButton/index.js +92 -106
- package/dist/IconButton/index.js.map +1 -0
- package/dist/Input/components/Input/index.d.ts +19 -53
- package/dist/Input/components/Input/index.js +115 -62
- package/dist/Input/components/Input/index.js.map +1 -0
- package/dist/Input/components/Password/index.d.ts +4 -13
- package/dist/Input/components/Password/index.js +34 -37
- package/dist/Input/components/Password/index.js.map +1 -0
- package/dist/Input/components/TextArea/index.d.ts +16 -44
- package/dist/Input/components/TextArea/index.js +78 -44
- package/dist/Input/components/TextArea/index.js.map +1 -0
- package/dist/Input/index.d.ts +6 -7
- package/dist/Input/index.js +11 -7
- package/dist/Input/index.js.map +1 -0
- package/dist/InputNumber/index.d.ts +2 -3
- package/dist/InputNumber/index.js +123 -44
- package/dist/InputNumber/index.js.map +1 -0
- package/dist/InputNumber/type.d.ts +7 -126
- package/dist/InputNumber/type.js +2 -1
- package/dist/InputSearch/index.d.ts +3 -2
- package/dist/InputSearch/index.js +107 -154
- package/dist/InputSearch/index.js.map +1 -0
- package/dist/Layout/index.d.ts +28 -3
- package/dist/Layout/index.js +74 -2
- package/dist/Layout/index.js.map +1 -0
- package/dist/List/Item.d.ts +1 -1
- package/dist/List/Item.js +56 -73
- package/dist/List/Item.js.map +1 -0
- package/dist/List/index.d.ts +2 -2
- package/dist/List/index.js +93 -129
- package/dist/List/index.js.map +1 -0
- package/dist/LogicTree/DisplayLogicTree.d.ts +3 -3
- package/dist/LogicTree/DisplayLogicTree.js +16 -14
- package/dist/LogicTree/DisplayLogicTree.js.map +1 -0
- package/dist/LogicTree/components/DisplayLogicItem/index.d.ts +2 -2
- package/dist/LogicTree/components/DisplayLogicItem/index.js +69 -85
- package/dist/LogicTree/components/DisplayLogicItem/index.js.map +1 -0
- package/dist/LogicTree/components/LogicItem/index.d.ts +1 -2
- package/dist/LogicTree/components/LogicItem/index.js +296 -388
- package/dist/LogicTree/components/LogicItem/index.js.map +1 -0
- package/dist/LogicTree/helper.d.ts +1 -1
- package/dist/LogicTree/helper.js +119 -182
- package/dist/LogicTree/helper.js.map +1 -0
- package/dist/LogicTree/index.d.ts +5 -6
- package/dist/LogicTree/index.js +100 -143
- package/dist/LogicTree/index.js.map +1 -0
- package/dist/LogicTree/type.js +14 -9
- package/dist/LogicTree/type.js.map +1 -0
- package/dist/MemberPicker/components/MemberSelection.d.ts +2 -2
- package/dist/MemberPicker/components/MemberSelection.js +138 -169
- package/dist/MemberPicker/components/MemberSelection.js.map +1 -0
- package/dist/MemberPicker/components/MultipleOption.d.ts +1 -2
- package/dist/MemberPicker/components/MultipleOption.js +66 -70
- package/dist/MemberPicker/components/MultipleOption.js.map +1 -0
- package/dist/MemberPicker/components/NickLabel.d.ts +1 -1
- package/dist/MemberPicker/components/NickLabel.js +25 -23
- package/dist/MemberPicker/components/NickLabel.js.map +1 -0
- package/dist/MemberPicker/components/Panel.d.ts +2 -2
- package/dist/MemberPicker/components/Panel.js +158 -192
- package/dist/MemberPicker/components/Panel.js.map +1 -0
- package/dist/MemberPicker/components/PanelWrapper.d.ts +3 -3
- package/dist/MemberPicker/components/PanelWrapper.js +99 -151
- package/dist/MemberPicker/components/PanelWrapper.js.map +1 -0
- package/dist/MemberPicker/components/SelectedMemberTags.d.ts +2 -2
- package/dist/MemberPicker/components/SelectedMemberTags.js +81 -82
- package/dist/MemberPicker/components/SelectedMemberTags.js.map +1 -0
- package/dist/MemberPicker/components/SelectorFooter.d.ts +2 -2
- package/dist/MemberPicker/components/SelectorFooter.js +36 -43
- package/dist/MemberPicker/components/SelectorFooter.js.map +1 -0
- package/dist/MemberPicker/components/SingleOption.d.ts +1 -2
- package/dist/MemberPicker/components/SingleOption.js +62 -66
- package/dist/MemberPicker/components/SingleOption.js.map +1 -0
- package/dist/MemberPicker/components/UserGroupSelection.d.ts +2 -2
- package/dist/MemberPicker/components/UserGroupSelection.js +163 -229
- package/dist/MemberPicker/components/UserGroupSelection.js.map +1 -0
- package/dist/MemberPicker/index.d.ts +3 -3
- package/dist/MemberPicker/index.js +279 -380
- package/dist/MemberPicker/index.js.map +1 -0
- package/dist/MemberPicker/interface.d.ts +2 -2
- package/dist/MemberPicker/interface.js +11 -6
- package/dist/MemberPicker/interface.js.map +1 -0
- package/dist/MemberPicker/tests/mockPort.js +2 -147
- package/dist/MemberPicker/utils/getUsersWithUserId.js +10 -23
- package/dist/MemberPicker/utils/getUsersWithUserId.js.map +1 -0
- package/dist/MemberPicker/utils/index.d.ts +1 -2
- package/dist/MemberPicker/utils/index.js +18 -14
- package/dist/MemberPicker/utils/index.js.map +1 -0
- package/dist/Menu/index.d.ts +2 -2
- package/dist/Menu/index.js +113 -125
- package/dist/Menu/index.js.map +1 -0
- package/dist/Modal/index.d.ts +69 -25
- package/dist/Modal/index.js +329 -339
- package/dist/Modal/index.js.map +1 -0
- package/dist/OverflowCount/index.d.ts +2 -17
- package/dist/OverflowCount/index.js +88 -75
- package/dist/OverflowCount/index.js.map +1 -0
- package/dist/Pagination/PageSizeChanger.d.ts +1 -1
- package/dist/Pagination/PageSizeChanger.js +30 -49
- package/dist/Pagination/PageSizeChanger.js.map +1 -0
- package/dist/Pagination/index.d.ts +2 -3
- package/dist/Pagination/index.js +144 -196
- package/dist/Pagination/index.js.map +1 -0
- package/dist/Pagination/types.js +2 -1
- package/dist/Popconfirm/index.d.ts +17 -5
- package/dist/Popconfirm/index.js +100 -50
- package/dist/Popconfirm/index.js.map +1 -0
- package/dist/Popover/index.d.ts +22 -4
- package/dist/Popover/index.js +92 -17
- package/dist/Popover/index.js.map +1 -0
- package/dist/Progress/index.d.ts +1 -1
- package/dist/Progress/index.js +46 -74
- package/dist/Progress/index.js.map +1 -0
- package/dist/Radio/components/Group/index.d.ts +3 -3
- package/dist/Radio/components/Group/index.js +51 -63
- package/dist/Radio/components/Group/index.js.map +1 -0
- package/dist/Radio/components/Radio/index.d.ts +1 -2
- package/dist/Radio/components/Radio/index.js +84 -109
- package/dist/Radio/components/Radio/index.js.map +1 -0
- package/dist/Radio/index.d.ts +4 -5
- package/dist/Radio/index.js +9 -4
- package/dist/Radio/index.js.map +1 -0
- package/dist/Radio/interface/radio.js +2 -1
- package/dist/Radio/interface/radioGroup.d.ts +1 -1
- package/dist/Radio/interface/radioGroup.js +2 -1
- package/dist/RenameInput/index.d.ts +2 -2
- package/dist/RenameInput/index.js +94 -129
- package/dist/RenameInput/index.js.map +1 -0
- package/dist/Result/index.d.ts +5 -5
- package/dist/Result/index.js +122 -116
- package/dist/Result/index.js.map +1 -0
- package/dist/Result/noFound.d.ts +1 -1
- package/dist/Result/noFound.js +36 -33
- package/dist/Result/noFound.js.map +1 -0
- package/dist/Result/serverError.d.ts +1 -1
- package/dist/Result/serverError.js +36 -33
- package/dist/Result/serverError.js.map +1 -0
- package/dist/Result/unauthorized.d.ts +1 -1
- package/dist/Result/unauthorized.js +36 -34
- package/dist/Result/unauthorized.js.map +1 -0
- package/dist/Row/index.d.ts +11 -2
- package/dist/Row/index.js +42 -2
- package/dist/Row/index.js.map +1 -0
- package/dist/ScrollArea/index.d.ts +1 -1
- package/dist/ScrollArea/index.js +44 -58
- package/dist/ScrollArea/index.js.map +1 -0
- package/dist/{AldSelect → Select}/BaseSelect.d.ts +13 -3
- package/dist/Select/BaseSelect.js +206 -0
- package/dist/Select/BaseSelect.js.map +1 -0
- package/dist/{AldSelect → Select}/SelectTrigger.d.ts +3 -3
- package/dist/Select/SelectTrigger.js +60 -0
- package/dist/Select/SelectTrigger.js.map +1 -0
- package/dist/{AldSelect → Select}/Selector/MultipleResponsiveSelectedSection.d.ts +2 -2
- package/dist/Select/Selector/MultipleResponsiveSelectedSection.js +48 -0
- package/dist/Select/Selector/MultipleResponsiveSelectedSection.js.map +1 -0
- package/dist/{AldSelect → Select}/Selector/MultipleSelector.d.ts +3 -3
- package/dist/Select/Selector/MultipleSelector.js +128 -0
- package/dist/Select/Selector/MultipleSelector.js.map +1 -0
- package/dist/{AldSelect → Select}/Selector/index.d.ts +2 -2
- package/dist/Select/Selector/index.js +25 -0
- package/dist/Select/Selector/index.js.map +1 -0
- package/dist/{AldSelect → Select}/components/PopupContent.d.ts +2 -2
- package/dist/Select/components/PopupContent.js +25 -0
- package/dist/Select/components/PopupContent.js.map +1 -0
- package/dist/{AldSelect → Select}/components/SearchBox.d.ts +2 -2
- package/dist/Select/components/SearchBox.js +23 -0
- package/dist/Select/components/SearchBox.js.map +1 -0
- package/dist/{AldSelect → Select}/components/Suffix.d.ts +2 -2
- package/dist/Select/components/Suffix.js +36 -0
- package/dist/Select/components/Suffix.js.map +1 -0
- package/dist/Select/hooks/useCache.js +35 -0
- package/dist/Select/hooks/useCache.js.map +1 -0
- package/dist/Select/hooks/useDisplayMenu.js +42 -0
- package/dist/Select/hooks/useDisplayMenu.js.map +1 -0
- package/dist/{AldSelect → Select}/hooks/useLayoutEffect.d.ts +2 -1
- package/dist/Select/hooks/useLayoutEffect.js +2 -0
- package/dist/{AldSelect → Select}/hooks/useOptions.d.ts +1 -1
- package/dist/Select/hooks/useOptions.js +60 -0
- package/dist/Select/hooks/useOptions.js.map +1 -0
- package/dist/{AldSelect → Select}/index.d.ts +2 -2
- package/dist/Select/index.js +151 -0
- package/dist/Select/index.js.map +1 -0
- package/dist/{AldSelect → Select}/interface.d.ts +2 -2
- package/dist/Select/interface.js +2 -0
- package/dist/{AldSelect → Select}/utils/commonUtil.d.ts +0 -1
- package/dist/Select/utils/commonUtil.js +38 -0
- package/dist/Select/utils/commonUtil.js.map +1 -0
- package/dist/Select/utils/getWidthStyle.js +11 -0
- package/dist/Select/utils/getWidthStyle.js.map +1 -0
- package/dist/Select/utils/keyUtil.js +2 -0
- package/dist/{AldSelect → Select}/utils/valueUtil.d.ts +2 -3
- package/dist/Select/utils/valueUtil.js +16 -0
- package/dist/Select/utils/valueUtil.js.map +1 -0
- package/dist/Skeleton/index.d.ts +56 -2
- package/dist/Skeleton/index.js +130 -2
- package/dist/Skeleton/index.js.map +1 -0
- package/dist/Slider/index.d.ts +34 -4
- package/dist/Slider/index.js +98 -8
- package/dist/Slider/index.js.map +1 -0
- package/dist/Space/CompactContext.d.ts +20 -0
- package/dist/Space/CompactContext.js +24 -0
- package/dist/Space/CompactContext.js.map +1 -0
- package/dist/Space/index.d.ts +28 -3
- package/dist/Space/index.js +64 -2
- package/dist/Space/index.js.map +1 -0
- package/dist/Spin/CustomIcon/index.d.ts +3 -3
- package/dist/Spin/CustomIcon/index.js +27 -38
- package/dist/Spin/CustomIcon/index.js.map +1 -0
- package/dist/Spin/index.d.ts +2 -2
- package/dist/Spin/index.js +47 -62
- package/dist/Spin/index.js.map +1 -0
- package/dist/StatusLight/index.d.ts +2 -2
- package/dist/StatusLight/index.js +73 -58
- package/dist/StatusLight/index.js.map +1 -0
- package/dist/Steps/components/CustomDot/index.d.ts +4 -2
- package/dist/Steps/components/CustomDot/index.js +2 -8
- package/dist/Steps/components/ProcessIcon/index.d.ts +1 -2
- package/dist/Steps/components/ProcessIcon/index.js +39 -24
- package/dist/Steps/components/ProcessIcon/index.js.map +1 -0
- package/dist/Steps/components/Step/index.d.ts +2 -14
- package/dist/Steps/components/Step/index.js +28 -41
- package/dist/Steps/components/Step/index.js.map +1 -0
- package/dist/Steps/index.d.ts +13 -33
- package/dist/Steps/index.js +79 -30
- package/dist/Steps/index.js.map +1 -0
- package/dist/Steps/matchMedia.mock.js +2 -18
- package/dist/Switch/index.d.ts +5 -36
- package/dist/Switch/index.js +62 -67
- package/dist/Switch/index.js.map +1 -0
- package/dist/Switch/test/index.js +2 -43
- package/dist/Table/components/Cell.d.ts +1 -2
- package/dist/Table/components/Cell.js +40 -41
- package/dist/Table/components/Cell.js.map +1 -0
- package/dist/Table/components/DndWrapper.d.ts +1 -1
- package/dist/Table/components/DndWrapper.js +27 -35
- package/dist/Table/components/DndWrapper.js.map +1 -0
- package/dist/Table/components/ErrorBoundary.d.ts +4 -2
- package/dist/Table/components/ErrorBoundary.js +33 -61
- package/dist/Table/components/ErrorBoundary.js.map +1 -0
- package/dist/Table/components/ExpandCell.d.ts +2 -2
- package/dist/Table/components/ExpandCell.js +61 -62
- package/dist/Table/components/ExpandCell.js.map +1 -0
- package/dist/Table/components/Footer/index.d.ts +1 -2
- package/dist/Table/components/Footer/index.js +75 -81
- package/dist/Table/components/Footer/index.js.map +1 -0
- package/dist/Table/components/Header.d.ts +1 -2
- package/dist/Table/components/Header.js +62 -68
- package/dist/Table/components/Header.js.map +1 -0
- package/dist/Table/helper.d.ts +6 -7
- package/dist/Table/helper.js +101 -155
- package/dist/Table/helper.js.map +1 -0
- package/dist/Table/hooks/useExpandable.d.ts +1 -1
- package/dist/Table/hooks/useExpandable.js +125 -172
- package/dist/Table/hooks/useExpandable.js.map +1 -0
- package/dist/Table/hooks/useFixed.d.ts +1 -2
- package/dist/Table/hooks/useFixed.js +45 -54
- package/dist/Table/hooks/useFixed.js.map +1 -0
- package/dist/Table/hooks/useRowDnd.d.ts +1 -1
- package/dist/Table/hooks/useRowDnd.js +156 -260
- package/dist/Table/hooks/useRowDnd.js.map +1 -0
- package/dist/Table/hooks/useRowSelection.d.ts +1 -1
- package/dist/Table/hooks/useRowSelection.js +268 -389
- package/dist/Table/hooks/useRowSelection.js.map +1 -0
- package/dist/Table/hooks/useScroll.d.ts +3 -4
- package/dist/Table/hooks/useScroll.js +92 -137
- package/dist/Table/hooks/useScroll.js.map +1 -0
- package/dist/Table/index.d.ts +3 -3
- package/dist/Table/index.js +442 -514
- package/dist/Table/index.js.map +1 -0
- package/dist/Table/tests/helper.d.ts +1 -1
- package/dist/Table/tests/helper.js +2 -41
- package/dist/Table/types.d.ts +1 -1
- package/dist/Table/types.js +2 -1
- package/dist/Tabs/TabPane.d.ts +2 -14
- package/dist/Tabs/TabPane.js +13 -6
- package/dist/Tabs/TabPane.js.map +1 -0
- package/dist/Tabs/index.d.ts +26 -52
- package/dist/Tabs/index.js +187 -78
- package/dist/Tabs/index.js.map +1 -0
- package/dist/Tag/index.d.ts +3 -3
- package/dist/Tag/index.js +119 -144
- package/dist/Tag/index.js.map +1 -0
- package/dist/TextLink/index.d.ts +10 -2
- package/dist/TextLink/index.js +49 -24
- package/dist/TextLink/index.js.map +1 -0
- package/dist/Tooltip/index.d.ts +2 -47
- package/dist/Tooltip/index.js +124 -34
- package/dist/Tooltip/index.js.map +1 -0
- package/dist/Tour/index.d.ts +29 -3
- package/dist/Tour/index.js +79 -2
- package/dist/Tour/index.js.map +1 -0
- package/dist/Tree/DirectoryTree.d.ts +3 -4
- package/dist/Tree/DirectoryTree.js +91 -161
- package/dist/Tree/DirectoryTree.js.map +1 -0
- package/dist/Tree/Tree.d.ts +3 -4
- package/dist/Tree/Tree.js +2 -205
- package/dist/Tree/Tree2.js +146 -0
- package/dist/Tree/Tree2.js.map +1 -0
- package/dist/Tree/index.d.ts +7 -10
- package/dist/Tree/index.js +10 -6
- package/dist/Tree/index.js.map +1 -0
- package/dist/Tree/utils/dictUtil.d.ts +1 -1
- package/dist/Tree/utils/dictUtil.js +49 -69
- package/dist/Tree/utils/dictUtil.js.map +1 -0
- package/dist/Tree/utils/dropIndicator.d.ts +1 -2
- package/dist/Tree/utils/dropIndicator.js +31 -35
- package/dist/Tree/utils/dropIndicator.js.map +1 -0
- package/dist/Tree/utils/iconUtil.d.ts +1 -1
- package/dist/Tree/utils/iconUtil.js +61 -65
- package/dist/Tree/utils/iconUtil.js.map +1 -0
- package/dist/Typography/index.d.ts +53 -2
- package/dist/Typography/index.js +85 -2
- package/dist/Typography/index.js.map +1 -0
- package/dist/Upload/index.d.ts +78 -4
- package/dist/Upload/index.js +334 -2
- package/dist/Upload/index.js.map +1 -0
- package/dist/User/index.d.ts +4 -2
- package/dist/User/index.js +31 -26
- package/dist/User/index.js.map +1 -0
- package/dist/Watermark/index.d.ts +2 -2
- package/dist/Watermark/index.js +61 -4
- package/dist/Watermark/index.js.map +1 -0
- package/dist/_utils/SimpleOverflow.d.ts +14 -0
- package/dist/_utils/SimpleOverflow.js +61 -0
- package/dist/_utils/SimpleOverflow.js.map +1 -0
- package/dist/_utils/getUniqId.js +12 -11
- package/dist/_utils/getUniqId.js.map +1 -0
- package/dist/_utils/hooks/useControlledState.js +2 -42
- package/dist/_utils/hooks/useId.js +15 -18
- package/dist/_utils/hooks/useId.js.map +1 -0
- package/dist/_utils/motion.d.ts +2 -3
- package/dist/_utils/motion.js +28 -49
- package/dist/_utils/motion.js.map +1 -0
- package/dist/_utils/prefixCls.d.ts +1 -3
- package/dist/_utils/prefixCls.js +13 -14
- package/dist/_utils/prefixCls.js.map +1 -0
- package/dist/_utils/reactNode.js +17 -15
- package/dist/_utils/reactNode.js.map +1 -0
- package/dist/_utils/statusUtils.d.ts +3 -0
- package/dist/_utils/statusUtils.js +2 -0
- package/dist/_utils/type.js +2 -22
- package/dist/aloudata-design.css +2 -0
- package/dist/index.d.ts +125 -113
- package/dist/index.js +73 -70
- package/dist/lib/utils.d.ts +2 -0
- package/dist/lib/utils.js +10 -0
- package/dist/lib/utils.js.map +1 -0
- package/dist/locale/default.d.ts +5 -3
- package/dist/locale/default.js +18 -17
- package/dist/locale/default.js.map +1 -0
- package/dist/locale/en_US.d.ts +1 -0
- package/dist/locale/en_US.js +63 -69
- package/dist/locale/en_US.js.map +1 -0
- package/dist/locale/zh_CN.d.ts +1 -0
- package/dist/locale/zh_CN.js +63 -69
- package/dist/locale/zh_CN.js.map +1 -0
- package/dist/message/index.js +91 -81
- package/dist/message/index.js.map +1 -0
- package/dist/notification/index.d.ts +1 -1
- package/dist/notification/index.js +209 -218
- package/dist/notification/index.js.map +1 -0
- package/dist/select_structure.png +0 -0
- package/dist/select_use_tip1.png +0 -0
- package/dist/select_use_tip2.png +0 -0
- package/dist/select_use_tip3.png +0 -0
- package/dist/select_use_tip4.png +0 -0
- package/package.json +58 -56
- package/dist/AMenu/style/index.d.ts +0 -2
- package/dist/AMenu/style/index.js +0 -2
- package/dist/AMenu/style/index.less +0 -1
- package/dist/AProgress/style/index.d.ts +0 -2
- package/dist/AProgress/style/index.js +0 -2
- package/dist/AProgress/style/index.less +0 -1
- package/dist/AldSelect/BaseSelect.js +0 -275
- package/dist/AldSelect/SelectTrigger.js +0 -76
- package/dist/AldSelect/Selector/MultipleResponsiveSelectedSection.js +0 -52
- package/dist/AldSelect/Selector/MultipleSelector.js +0 -171
- package/dist/AldSelect/Selector/index.js +0 -30
- package/dist/AldSelect/components/PopupContent.js +0 -28
- package/dist/AldSelect/components/SearchBox.js +0 -23
- package/dist/AldSelect/components/Suffix.js +0 -37
- package/dist/AldSelect/hooks/useCache.js +0 -50
- package/dist/AldSelect/hooks/useDisplayMenu.js +0 -61
- package/dist/AldSelect/hooks/useLayoutEffect.js +0 -17
- package/dist/AldSelect/hooks/useOptions.js +0 -74
- package/dist/AldSelect/index.js +0 -259
- package/dist/AldSelect/interface.js +0 -1
- package/dist/AldSelect/style/color.less +0 -71
- package/dist/AldSelect/style/index.d.ts +0 -1
- package/dist/AldSelect/style/index.js +0 -1
- package/dist/AldSelect/style/index.less +0 -180
- package/dist/AldSelect/style/size.less +0 -72
- package/dist/AldSelect/utils/commonUtil.js +0 -46
- package/dist/AldSelect/utils/getWidthStyle.js +0 -18
- package/dist/AldSelect/utils/keyUtil.js +0 -10
- package/dist/AldSelect/utils/valueUtil.js +0 -131
- package/dist/Alert/style/index.d.ts +0 -2
- package/dist/Alert/style/index.js +0 -2
- package/dist/Alert/style/index.less +0 -1
- package/dist/App/style/index.d.ts +0 -2
- package/dist/App/style/index.js +0 -2
- package/dist/App/style/index.less +0 -1
- package/dist/Avatar/style/index.d.ts +0 -2
- package/dist/Avatar/style/index.js +0 -2
- package/dist/Avatar/style/index.less +0 -23
- package/dist/Badge/style/index.d.ts +0 -2
- package/dist/Badge/style/index.js +0 -2
- package/dist/Badge/style/index.less +0 -50
- package/dist/Breadcrumb/style/index.d.ts +0 -2
- package/dist/Breadcrumb/style/index.js +0 -2
- package/dist/Breadcrumb/style/index.less +0 -37
- package/dist/Button/style/index.d.ts +0 -2
- package/dist/Button/style/index.js +0 -2
- package/dist/Button/style/index.less +0 -24
- package/dist/Button/style/reset.less +0 -9
- package/dist/Button/style/size.less +0 -102
- package/dist/Button/style/type.less +0 -286
- package/dist/Button/style/variables.less +0 -124
- package/dist/Card/style/index.d.ts +0 -2
- package/dist/Card/style/index.js +0 -2
- package/dist/Card/style/index.less +0 -1
- package/dist/Carousel/style/index.d.ts +0 -2
- package/dist/Carousel/style/index.js +0 -2
- package/dist/Carousel/style/index.less +0 -1
- package/dist/Checkbox/style/index.d.ts +0 -2
- package/dist/Checkbox/style/index.js +0 -2
- package/dist/Checkbox/style/index.less +0 -235
- package/dist/Col/style/index.d.ts +0 -2
- package/dist/Col/style/index.js +0 -2
- package/dist/Col/style/index.less +0 -1
- package/dist/Collapse/style/index.d.ts +0 -2
- package/dist/Collapse/style/index.js +0 -2
- package/dist/Collapse/style/index.less +0 -107
- package/dist/ColorPicker/alpha.svg +0 -54
- package/dist/ColorPicker/style/complex.less +0 -199
- package/dist/ColorPicker/style/index.d.ts +0 -2
- package/dist/ColorPicker/style/index.js +0 -2
- package/dist/ColorPicker/style/index.less +0 -190
- package/dist/ConfigProvider/defaultRenderEmpty.d.ts +0 -4
- package/dist/ConfigProvider/defaultRenderEmpty.js +0 -34
- package/dist/ConfigProvider/style/index.d.ts +0 -2
- package/dist/ConfigProvider/style/index.js +0 -2
- package/dist/ConfigProvider/style/index.less +0 -1
- package/dist/DONT-USE-THIS-FILE-NAME +0 -7
- package/dist/DataPreviewTable/style/index.d.ts +0 -2
- package/dist/DataPreviewTable/style/index.js +0 -2
- package/dist/DataPreviewTable/style/index.less +0 -158
- package/dist/DatePicker/style/index.d.ts +0 -2
- package/dist/DatePicker/style/index.js +0 -2
- package/dist/DatePicker/style/index.less +0 -14
- package/dist/Divider/style/index.d.ts +0 -2
- package/dist/Divider/style/index.js +0 -2
- package/dist/Divider/style/index.less +0 -40
- package/dist/DoubleCircleIcon/style/index.less +0 -55
- package/dist/Drawer/style/index.d.ts +0 -2
- package/dist/Drawer/style/index.js +0 -2
- package/dist/Drawer/style/index.less +0 -1
- package/dist/Dropdown/style/index.d.ts +0 -2
- package/dist/Dropdown/style/index.js +0 -2
- package/dist/Dropdown/style/index.less +0 -24
- package/dist/Empty/style/index.d.ts +0 -1
- package/dist/Empty/style/index.js +0 -1
- package/dist/Empty/style/index.less +0 -74
- package/dist/Form/style/index.d.ts +0 -3
- package/dist/Form/style/index.js +0 -3
- package/dist/Form/style/index.less +0 -130
- package/dist/HighlightText/style/index.d.ts +0 -2
- package/dist/HighlightText/style/index.js +0 -2
- package/dist/HighlightText/style/index.less +0 -5
- package/dist/Icon/antdIconfont.d.ts +0 -4
- package/dist/Icon/antdIconfont.js +0 -2
- package/dist/Icon/index.less +0 -24
- package/dist/Icon/style/index.d.ts +0 -2
- package/dist/Icon/style/index.js +0 -2
- package/dist/Icon/style/index.less +0 -24
- package/dist/Icon/svg/Arrow-Right-light-line.svg +0 -5
- package/dist/Icon/svg/Cancelled-Circle-fill.svg +0 -6
- package/dist/Icon/svg/Close-Circle-light-line.svg +0 -5
- package/dist/Icon/svg/In-Progress-fill.svg +0 -8
- package/dist/Icon/svg/Loading-duotone.svg +0 -7
- package/dist/Icon/svg/Sign-light-line.svg +0 -3
- package/dist/Icon/svg/Sort-Ascending-order-Color.svg +0 -5
- package/dist/Icon/svg/Sort-Color.svg +0 -5
- package/dist/Icon/svg/Sort-Descending-order-Color.svg +0 -5
- package/dist/Icon/svg/Times-light-line.svg +0 -5
- package/dist/Icon/svg/Trash-light-line.svg +0 -8
- package/dist/Icon/svg/alert-triangle-duotone.svg +0 -5
- package/dist/Icon/svg/alert-triangle-line.svg +0 -5
- package/dist/Icon/svg/arrow-down-fill.svg +0 -5
- package/dist/Icon/svg/arrow-down-light-line.svg +0 -5
- package/dist/Icon/svg/arrow-down-right-fill.svg +0 -5
- package/dist/Icon/svg/attention-circle-fill.svg +0 -5
- package/dist/Icon/svg/attention-triangle-fill.svg +0 -5
- package/dist/Icon/svg/attention-triangle-light-line.svg +0 -5
- package/dist/Icon/svg/cancel-circle-duotone.svg +0 -8
- package/dist/Icon/svg/check-circle-duotone.svg +0 -8
- package/dist/Icon/svg/check-circle-fill.svg +0 -5
- package/dist/Icon/svg/check-circle-light-line.svg +0 -8
- package/dist/Icon/svg/check-light-line.svg +0 -5
- package/dist/Icon/svg/chevron-down-line.svg +0 -7
- package/dist/Icon/svg/chevron-left-line.svg +0 -7
- package/dist/Icon/svg/chevron-right-line.svg +0 -7
- package/dist/Icon/svg/circle-light-line.svg +0 -9
- package/dist/Icon/svg/close-L-line.svg +0 -3
- package/dist/Icon/svg/close-circle-fill.svg +0 -5
- package/dist/Icon/svg/close-circle-right-fill.svg +0 -5
- package/dist/Icon/svg/close-light-line.svg +0 -5
- package/dist/Icon/svg/close-m-line.svg +0 -7
- package/dist/Icon/svg/danger-fill.svg +0 -5
- package/dist/Icon/svg/drag-light-line.svg +0 -5
- package/dist/Icon/svg/drag-line.svg +0 -7
- package/dist/Icon/svg/ellipsis.svg +0 -6
- package/dist/Icon/svg/eye-off-line.svg +0 -7
- package/dist/Icon/svg/eye-on-line.svg +0 -15
- package/dist/Icon/svg/fold-down-fill.svg +0 -8
- package/dist/Icon/svg/fold-up-fill.svg +0 -8
- package/dist/Icon/svg/info-circle-duotone.svg +0 -5
- package/dist/Icon/svg/info-circle-line.svg +0 -5
- package/dist/Icon/svg/information-circle-fill.svg +0 -5
- package/dist/Icon/svg/information-circle-light-line.svg +0 -9
- package/dist/Icon/svg/loading-2-line.svg +0 -8
- package/dist/Icon/svg/loading-line.svg +0 -7
- package/dist/Icon/svg/more-vertical-line.svg +0 -7
- package/dist/Icon/svg/search-line.svg +0 -7
- package/dist/Icon/svg/triangle-light-line.svg +0 -5
- package/dist/Icon/svg/user.svg +0 -4
- package/dist/Icon/svg/userGroup.svg +0 -7
- package/dist/IconButton/style/index.d.ts +0 -2
- package/dist/IconButton/style/index.js +0 -2
- package/dist/IconButton/style/index.less +0 -148
- package/dist/Input/style/index.d.ts +0 -2
- package/dist/Input/style/index.js +0 -2
- package/dist/Input/style/index.less +0 -13
- package/dist/Input/style/reset.less +0 -22
- package/dist/Input/style/size.less +0 -82
- package/dist/Input/style/status.less +0 -99
- package/dist/InputNumber/style/index.d.ts +0 -2
- package/dist/InputNumber/style/index.js +0 -2
- package/dist/InputNumber/style/index.less +0 -330
- package/dist/InputSearch/style/index.d.ts +0 -2
- package/dist/InputSearch/style/index.js +0 -2
- package/dist/InputSearch/style/index.less +0 -91
- package/dist/Layout/style/index.d.ts +0 -2
- package/dist/Layout/style/index.js +0 -2
- package/dist/Layout/style/index.less +0 -1
- package/dist/List/style/index.d.ts +0 -2
- package/dist/List/style/index.js +0 -2
- package/dist/List/style/index.less +0 -120
- package/dist/LogicTree/style/DisplayLogicItem.less +0 -54
- package/dist/LogicTree/style/LoginItem.less +0 -206
- package/dist/LogicTree/style/index.d.ts +0 -2
- package/dist/LogicTree/style/index.js +0 -2
- package/dist/LogicTree/style/index.less +0 -12
- package/dist/MemberPicker/assets/default_user_photo.svg +0 -7
- package/dist/MemberPicker/style/index.d.ts +0 -2
- package/dist/MemberPicker/style/index.js +0 -2
- package/dist/MemberPicker/style/index.less +0 -365
- package/dist/Menu/style/index.d.ts +0 -2
- package/dist/Menu/style/index.js +0 -2
- package/dist/Menu/style/index.less +0 -146
- package/dist/Modal/style/index.d.ts +0 -2
- package/dist/Modal/style/index.js +0 -2
- package/dist/Modal/style/index.less +0 -7
- package/dist/Modal/style/modal.less +0 -191
- package/dist/Modal/style/modalConfirm.less +0 -89
- package/dist/Modal/style/polyfill/animate.less +0 -244
- package/dist/Modal/style/polyfill/index.less +0 -54
- package/dist/OverflowCount/style/index.d.ts +0 -2
- package/dist/OverflowCount/style/index.js +0 -2
- package/dist/OverflowCount/style/index.less +0 -52
- package/dist/Pagination/style/index.d.ts +0 -2
- package/dist/Pagination/style/index.js +0 -2
- package/dist/Pagination/style/index.less +0 -45
- package/dist/Popconfirm/style/index.d.ts +0 -2
- package/dist/Popconfirm/style/index.js +0 -2
- package/dist/Popconfirm/style/index.less +0 -81
- package/dist/Popover/style/index.d.ts +0 -2
- package/dist/Popover/style/index.js +0 -2
- package/dist/Popover/style/index.less +0 -73
- package/dist/Progress/style/index.d.ts +0 -2
- package/dist/Progress/style/index.js +0 -2
- package/dist/Progress/style/index.less +0 -57
- package/dist/Radio/style/index.d.ts +0 -2
- package/dist/Radio/style/index.js +0 -2
- package/dist/Radio/style/index.less +0 -603
- package/dist/RenameInput/style/index.d.ts +0 -2
- package/dist/RenameInput/style/index.js +0 -2
- package/dist/RenameInput/style/index.less +0 -66
- package/dist/Result/style/index.d.ts +0 -2
- package/dist/Result/style/index.js +0 -2
- package/dist/Result/style/index.less +0 -104
- package/dist/Row/style/index.d.ts +0 -2
- package/dist/Row/style/index.js +0 -2
- package/dist/Row/style/index.less +0 -1
- package/dist/ScrollArea/style/index.d.ts +0 -2
- package/dist/ScrollArea/style/index.js +0 -2
- package/dist/ScrollArea/style/index.less +0 -54
- package/dist/Skeleton/style/index.d.ts +0 -2
- package/dist/Skeleton/style/index.js +0 -2
- package/dist/Skeleton/style/index.less +0 -91
- package/dist/Slider/style/index.d.ts +0 -2
- package/dist/Slider/style/index.js +0 -2
- package/dist/Slider/style/index.less +0 -68
- package/dist/Space/style/index.d.ts +0 -2
- package/dist/Space/style/index.js +0 -2
- package/dist/Space/style/index.less +0 -1
- package/dist/Spin/style/customIcon.less +0 -69
- package/dist/Spin/style/index.d.ts +0 -2
- package/dist/Spin/style/index.js +0 -2
- package/dist/Spin/style/index.less +0 -24
- package/dist/StatusLight/style/index.d.ts +0 -2
- package/dist/StatusLight/style/index.js +0 -2
- package/dist/StatusLight/style/index.less +0 -99
- package/dist/Steps/style/index.d.ts +0 -2
- package/dist/Steps/style/index.js +0 -2
- package/dist/Steps/style/index.less +0 -350
- package/dist/Switch/style/index.d.ts +0 -2
- package/dist/Switch/style/index.js +0 -2
- package/dist/Switch/style/index.less +0 -212
- package/dist/Switch/style/status.less +0 -12
- package/dist/Table/style/index.d.ts +0 -2
- package/dist/Table/style/index.js +0 -2
- package/dist/Table/style/index.less +0 -421
- package/dist/Tabs/style/index.d.ts +0 -2
- package/dist/Tabs/style/index.js +0 -2
- package/dist/Tabs/style/index.less +0 -262
- package/dist/Tag/style/index.d.ts +0 -2
- package/dist/Tag/style/index.js +0 -2
- package/dist/Tag/style/index.less +0 -69
- package/dist/TextLink/style/index.d.ts +0 -2
- package/dist/TextLink/style/index.js +0 -2
- package/dist/TextLink/style/index.less +0 -15
- package/dist/TextLink/style/size.less +0 -37
- package/dist/TextLink/style/type.less +0 -60
- package/dist/Tooltip/style/index.d.ts +0 -2
- package/dist/Tooltip/style/index.js +0 -2
- package/dist/Tooltip/style/index.less +0 -25
- package/dist/Tour/style/index.d.ts +0 -2
- package/dist/Tour/style/index.js +0 -2
- package/dist/Tour/style/index.less +0 -1
- package/dist/Tree/demo/asyncLoad/index.d.ts +0 -3
- package/dist/Tree/demo/asyncLoad/index.js +0 -76
- package/dist/Tree/demo/basic/index.d.ts +0 -3
- package/dist/Tree/demo/basic/index.js +0 -42
- package/dist/Tree/demo/directoryTree/index.d.ts +0 -3
- package/dist/Tree/demo/directoryTree/index.js +0 -40
- package/dist/Tree/demo/drag/index.d.ts +0 -3
- package/dist/Tree/demo/drag/index.js +0 -118
- package/dist/Tree/demo/filter/index.d.ts +0 -3
- package/dist/Tree/demo/filter/index.js +0 -64
- package/dist/Tree/style/checkbox.less +0 -237
- package/dist/Tree/style/directory.less +0 -68
- package/dist/Tree/style/indent.less +0 -11
- package/dist/Tree/style/index.d.ts +0 -2
- package/dist/Tree/style/index.js +0 -2
- package/dist/Tree/style/index.less +0 -173
- package/dist/Tree/style/mixin.less +0 -322
- package/dist/Tree/style/reset.less +0 -26
- package/dist/Tree/style/rtl.less +0 -68
- package/dist/Tree/style/var.less +0 -42
- package/dist/Typography/style/index.d.ts +0 -2
- package/dist/Typography/style/index.js +0 -2
- package/dist/Typography/style/index.less +0 -1
- package/dist/Upload/style/index.d.ts +0 -2
- package/dist/Upload/style/index.js +0 -2
- package/dist/Upload/style/index.less +0 -1
- package/dist/User/style/index.d.ts +0 -2
- package/dist/User/style/index.js +0 -2
- package/dist/User/style/index.less +0 -49
- package/dist/Watermark/style/index.d.ts +0 -2
- package/dist/Watermark/style/index.js +0 -2
- package/dist/Watermark/style/index.less +0 -1
- package/dist/_utils/hooks/usePrefixCls.d.ts +0 -2
- package/dist/_utils/hooks/usePrefixCls.js +0 -10
- package/dist/_utils/transformIconToBase64Url.d.ts +0 -2
- package/dist/_utils/transformIconToBase64Url.js +0 -6
- package/dist/ald.min.css +0 -5
- package/dist/index.less +0 -64
- package/dist/message/style/index.d.ts +0 -2
- package/dist/message/style/index.js +0 -2
- package/dist/message/style/index.less +0 -73
- package/dist/notification/demo/index.d.ts +0 -3
- package/dist/notification/demo/index.js +0 -43
- package/dist/notification/style/index.d.ts +0 -2
- package/dist/notification/style/index.js +0 -2
- package/dist/notification/style/index.less +0 -53
- package/dist/style/color/bezierEasing.less +0 -110
- package/dist/style/color/colorPalette.less +0 -84
- package/dist/style/color/colors.less +0 -162
- package/dist/style/color/tinyColor.less +0 -1184
- package/dist/style/components/toastify.css +0 -855
- package/dist/style/core/index.less +0 -2
- package/dist/style/core/motion/fade.less +0 -34
- package/dist/style/core/motion/move.less +0 -129
- package/dist/style/core/motion/other.less +0 -48
- package/dist/style/core/motion/slide.less +0 -131
- package/dist/style/core/motion/zoom.less +0 -179
- package/dist/style/core/motion.less +0 -22
- package/dist/style/index.d.ts +0 -1
- package/dist/style/index.js +0 -1
- package/dist/style/index.less +0 -31
- package/dist/style/mixins/index.less +0 -27
- package/dist/style/mixins/motion.less +0 -33
- package/dist/style/themes/default/default.less +0 -24
- package/dist/style/themes/default/index.less +0 -34
- package/dist/style/themes/default/scrollBar.less +0 -21
- package/dist/style/themes/default/themeColor.module.less +0 -437
- package/dist/style/themes/default/themeColor.module.less.d.ts +0 -182
- package/dist/style/var/default.css +0 -1271
- /package/dist/{AldSelect → Select}/hooks/useCache.d.ts +0 -0
- /package/dist/{AldSelect → Select}/hooks/useDisplayMenu.d.ts +0 -0
- /package/dist/{AldSelect → Select}/utils/getWidthStyle.d.ts +0 -0
- /package/dist/{AldSelect → Select}/utils/keyUtil.d.ts +0 -0
|
@@ -1,131 +1,105 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import Header from "./components/Header";
|
|
10
|
-
import
|
|
11
|
-
import
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
}, /*#__PURE__*/React.createElement(Progress, {
|
|
107
|
-
className: "ald-data-preview-progress",
|
|
108
|
-
loading: !!loading,
|
|
109
|
-
ref: progressRef
|
|
110
|
-
}), /*#__PURE__*/React.createElement(Header, {
|
|
111
|
-
contentWidth: contentWidth,
|
|
112
|
-
headerHeight: realHeaderHeight,
|
|
113
|
-
columns: tableColumns,
|
|
114
|
-
columnLayout: columnLayout,
|
|
115
|
-
setWidth: setColumnsWidth,
|
|
116
|
-
columnRange: columnRange
|
|
117
|
-
})), dataStatus === 'pending' && tableColumns.length > 0 && /*#__PURE__*/React.createElement("div", {
|
|
118
|
-
className: "ald-data-preview-loading"
|
|
119
|
-
}, /*#__PURE__*/React.createElement(Spin, null)), dataStatus === 'success' && /*#__PURE__*/React.createElement(Body, {
|
|
120
|
-
columns: tableColumns,
|
|
121
|
-
columnRange: columnRange,
|
|
122
|
-
columnLayout: columnLayout,
|
|
123
|
-
datasource: datasource,
|
|
124
|
-
rowRange: rowRange,
|
|
125
|
-
headerHeight: realHeaderHeight
|
|
126
|
-
}), dataStatus === 'error' && /*#__PURE__*/React.createElement(Error, {
|
|
127
|
-
errorMsg: errorMsg,
|
|
128
|
-
wrapWidth: ((_wrapRef$current5 = wrapRef.current) === null || _wrapRef$current5 === void 0 ? void 0 : _wrapRef$current5.clientWidth) || 0
|
|
129
|
-
})));
|
|
130
|
-
});
|
|
131
|
-
export default /*#__PURE__*/memo(DataPreviewTable);
|
|
1
|
+
import { cn } from "../lib/utils.js";
|
|
2
|
+
import { LocaleContext, getTranslator } from "../locale/default.js";
|
|
3
|
+
import ScrollArea_default from "../ScrollArea/index.js";
|
|
4
|
+
/* empty css */
|
|
5
|
+
import Progress_default from "../Progress/index.js";
|
|
6
|
+
import CustomSpin from "../Spin/index.js";
|
|
7
|
+
import Body_default from "./components/Body/index.js";
|
|
8
|
+
import Error_default from "./components/Body/Error.js";
|
|
9
|
+
import Header from "./components/Header/index.js";
|
|
10
|
+
import useDirection from "./hooks/useDirection.js";
|
|
11
|
+
import { forwardRef, memo, useContext, useImperativeHandle, useMemo, useRef } from "react";
|
|
12
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
13
|
+
var DataPreviewTable_default = memo(forwardRef(function(props, ref) {
|
|
14
|
+
const { locale } = useContext(LocaleContext);
|
|
15
|
+
const t = getTranslator(locale);
|
|
16
|
+
const { columns = [], datasource = [], width, height, headerHeight = 0, loading, dataStatus, errorMsg = t.DataPreviewTable.dataLoadFailed } = props;
|
|
17
|
+
const realHeaderHeight = Math.max(headerHeight, 32);
|
|
18
|
+
const contentHeight = useMemo(() => {
|
|
19
|
+
return datasource.length * 20 + realHeaderHeight;
|
|
20
|
+
}, [datasource, realHeaderHeight]);
|
|
21
|
+
const wrapRef = useRef(null);
|
|
22
|
+
const progressRef = useRef(null);
|
|
23
|
+
const { columnRange, rowRange, onScroll, columnLayout, setColumnsWidth, tableColumns, contentWidth } = useDirection(columns, wrapRef);
|
|
24
|
+
useImperativeHandle(ref, () => ({
|
|
25
|
+
scrollToColumnInView: (columnId) => {
|
|
26
|
+
const columnPos = columnLayout[columnId];
|
|
27
|
+
if (!columnPos) return;
|
|
28
|
+
const { scrollLeft } = wrapRef.current;
|
|
29
|
+
const { left, width } = columnPos;
|
|
30
|
+
const containerWidth = wrapRef.current?.clientWidth || 0;
|
|
31
|
+
if (left < scrollLeft) wrapRef.current?.scrollTo({
|
|
32
|
+
left,
|
|
33
|
+
behavior: "smooth"
|
|
34
|
+
});
|
|
35
|
+
else if (left + width > scrollLeft + containerWidth) wrapRef.current?.scrollTo({
|
|
36
|
+
left: left + width - containerWidth,
|
|
37
|
+
behavior: "smooth"
|
|
38
|
+
});
|
|
39
|
+
},
|
|
40
|
+
progressRestart: () => {
|
|
41
|
+
progressRef.current?.restart();
|
|
42
|
+
}
|
|
43
|
+
}));
|
|
44
|
+
const skeletonRows = useMemo(() => {
|
|
45
|
+
if (!wrapRef.current) return 0;
|
|
46
|
+
const rows = Math.ceil(((wrapRef.current?.clientHeight || 0) - realHeaderHeight) / 20);
|
|
47
|
+
return rows - 1 < 0 ? 0 : rows - 1;
|
|
48
|
+
}, [realHeaderHeight]);
|
|
49
|
+
return /* @__PURE__ */ jsx(ScrollArea_default, {
|
|
50
|
+
ref: wrapRef,
|
|
51
|
+
style: {
|
|
52
|
+
width,
|
|
53
|
+
height,
|
|
54
|
+
willChange: "transform"
|
|
55
|
+
},
|
|
56
|
+
onViewportScroll: () => {
|
|
57
|
+
onScroll();
|
|
58
|
+
},
|
|
59
|
+
className: cn(props.className, "ald-data-preview-table", { "ald-data-preview-table-show-skeleton": dataStatus === "pending" }),
|
|
60
|
+
children: /* @__PURE__ */ jsxs("div", {
|
|
61
|
+
style: {
|
|
62
|
+
height: dataStatus === "pending" ? skeletonRows * 20 + realHeaderHeight : contentHeight,
|
|
63
|
+
position: "relative",
|
|
64
|
+
width: "fit-content"
|
|
65
|
+
},
|
|
66
|
+
children: [
|
|
67
|
+
/* @__PURE__ */ jsxs("div", {
|
|
68
|
+
className: "ald-data-preview-sticky",
|
|
69
|
+
children: [/* @__PURE__ */ jsx(Progress_default, {
|
|
70
|
+
className: "ald-data-preview-progress",
|
|
71
|
+
loading: !!loading,
|
|
72
|
+
ref: progressRef
|
|
73
|
+
}), /* @__PURE__ */ jsx(Header, {
|
|
74
|
+
contentWidth,
|
|
75
|
+
headerHeight: realHeaderHeight,
|
|
76
|
+
columns: tableColumns,
|
|
77
|
+
columnLayout,
|
|
78
|
+
setWidth: setColumnsWidth,
|
|
79
|
+
columnRange
|
|
80
|
+
})]
|
|
81
|
+
}),
|
|
82
|
+
dataStatus === "pending" && tableColumns.length > 0 && /* @__PURE__ */ jsx("div", {
|
|
83
|
+
className: "ald-data-preview-loading",
|
|
84
|
+
children: /* @__PURE__ */ jsx(CustomSpin, {})
|
|
85
|
+
}),
|
|
86
|
+
dataStatus === "success" && /* @__PURE__ */ jsx(Body_default, {
|
|
87
|
+
columns: tableColumns,
|
|
88
|
+
columnRange,
|
|
89
|
+
columnLayout,
|
|
90
|
+
datasource,
|
|
91
|
+
rowRange,
|
|
92
|
+
headerHeight: realHeaderHeight
|
|
93
|
+
}),
|
|
94
|
+
dataStatus === "error" && /* @__PURE__ */ jsx(Error_default, {
|
|
95
|
+
errorMsg,
|
|
96
|
+
wrapWidth: wrapRef.current?.clientWidth || 0
|
|
97
|
+
})
|
|
98
|
+
]
|
|
99
|
+
})
|
|
100
|
+
});
|
|
101
|
+
}));
|
|
102
|
+
//#endregion
|
|
103
|
+
export { DataPreviewTable_default as default };
|
|
104
|
+
|
|
105
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","names":[],"sources":["../../src/DataPreviewTable/index.tsx"],"sourcesContent":["import { cn } from '../lib/utils';\nimport './data-preview-table.css';\nimport React, {\n forwardRef,\n memo,\n useContext,\n useImperativeHandle,\n useMemo,\n useRef,\n} from 'react';\nimport Progress, { IProgressRef } from '../Progress';\nimport ScrollArea from '../ScrollArea';\nimport Spin from '../Spin';\nimport { LocaleContext, getTranslator } from '../locale/default';\nimport Body from './components/Body';\nimport Error from './components/Body/Error';\nimport Header from './components/Header';\nimport { CELL_HEIGHT, DEFAULT_HEADER_HEIGHT } from './constant';\nimport useDirection from './hooks/useDirection';\nimport { DataPreviewTableRef, ITableProps } from './interface';\n\nconst DataPreviewTable = forwardRef(function (\n props: ITableProps,\n ref: React.Ref<DataPreviewTableRef>,\n) {\n const { locale } = useContext(LocaleContext);\n const t = getTranslator(locale);\n\n const {\n columns = [],\n datasource = [],\n width,\n height,\n headerHeight = 0,\n loading,\n dataStatus,\n errorMsg = t.DataPreviewTable.dataLoadFailed,\n } = props;\n\n const realHeaderHeight = Math.max(headerHeight, DEFAULT_HEADER_HEIGHT);\n const contentHeight = useMemo(() => {\n return datasource.length * CELL_HEIGHT + realHeaderHeight;\n }, [datasource, realHeaderHeight]);\n const wrapRef = useRef<HTMLDivElement>(null);\n const progressRef = useRef<IProgressRef>(null);\n const {\n columnRange,\n rowRange,\n onScroll,\n columnLayout,\n setColumnsWidth,\n tableColumns,\n contentWidth,\n } = useDirection(columns, wrapRef);\n\n useImperativeHandle(ref, () => ({\n scrollToColumnInView: (columnId: string) => {\n // 实现scrollTo方法\n const columnPos = columnLayout[columnId];\n if (!columnPos) return;\n // 根据容器的宽度,容器的scrollLeft,columnPos,判断当前列是否在可视区域内\n const { scrollLeft } = wrapRef.current as HTMLDivElement;\n const { left, width } = columnPos;\n const containerWidth = wrapRef.current?.clientWidth || 0;\n if (left < scrollLeft) {\n // 左边不可见\n wrapRef.current?.scrollTo({\n left,\n behavior: 'smooth',\n });\n } else if (left + width > scrollLeft + containerWidth) {\n // 右边不可见\n wrapRef.current?.scrollTo({\n left: left + width - containerWidth,\n behavior: 'smooth',\n });\n }\n },\n progressRestart: () => {\n progressRef.current?.restart();\n },\n }));\n\n const skeletonRows = useMemo(() => {\n if (!wrapRef.current) return 0;\n const rows = Math.ceil(\n ((wrapRef.current?.clientHeight || 0) - realHeaderHeight) / CELL_HEIGHT,\n );\n return rows - 1 < 0 ? 0 : rows - 1;\n }, [realHeaderHeight]);\n\n return (\n <ScrollArea\n ref={wrapRef}\n style={{ width, height, willChange: 'transform' }}\n onViewportScroll={() => {\n // const { scrollTop, scrollLeft } = e.target as HTMLDivElement;\n onScroll();\n }}\n className={cn(props.className, 'ald-data-preview-table', {\n 'ald-data-preview-table-show-skeleton': dataStatus === 'pending',\n })}\n >\n <div\n style={{\n height:\n dataStatus === 'pending'\n ? skeletonRows * CELL_HEIGHT + realHeaderHeight\n : contentHeight,\n position: 'relative',\n width: 'fit-content',\n }}\n >\n <div className=\"ald-data-preview-sticky\">\n <Progress\n className=\"ald-data-preview-progress\"\n loading={!!loading}\n ref={progressRef}\n ></Progress>\n <Header\n contentWidth={contentWidth}\n headerHeight={realHeaderHeight}\n columns={tableColumns}\n columnLayout={columnLayout}\n setWidth={setColumnsWidth}\n columnRange={columnRange}\n />\n </div>\n {dataStatus === 'pending' && tableColumns.length > 0 && (\n <div className=\"ald-data-preview-loading\">\n <Spin />\n </div>\n )}\n {dataStatus === 'success' && (\n <Body\n columns={tableColumns}\n columnRange={columnRange}\n columnLayout={columnLayout}\n datasource={datasource}\n rowRange={rowRange}\n headerHeight={realHeaderHeight}\n />\n )}\n {dataStatus === 'error' && (\n <Error\n errorMsg={errorMsg}\n wrapWidth={wrapRef.current?.clientWidth || 0}\n />\n )}\n </div>\n </ScrollArea>\n );\n});\n\nexport default memo(DataPreviewTable);\n"],"mappings":";;;;;;;;;;;;AA0JA,IAAA,2BAAe,KArIU,WAAW,SAClC,OACA,KACA;CACA,MAAM,EAAE,WAAW,WAAW,cAAc;CAC5C,MAAM,IAAI,cAAc,OAAO;CAE/B,MAAM,EACJ,UAAU,EAAE,EACZ,aAAa,EAAE,EACf,OACA,QACA,eAAe,GACf,SACA,YACA,WAAW,EAAE,iBAAiB,mBAC5B;CAEJ,MAAM,mBAAmB,KAAK,IAAI,cAAA,GAAoC;CACtE,MAAM,gBAAgB,cAAc;AAClC,SAAO,WAAW,SAAA,KAAuB;IACxC,CAAC,YAAY,iBAAiB,CAAC;CAClC,MAAM,UAAU,OAAuB,KAAK;CAC5C,MAAM,cAAc,OAAqB,KAAK;CAC9C,MAAM,EACJ,aACA,UACA,UACA,cACA,iBACA,cACA,iBACE,aAAa,SAAS,QAAQ;AAElC,qBAAoB,YAAY;EAC9B,uBAAuB,aAAqB;GAE1C,MAAM,YAAY,aAAa;AAC/B,OAAI,CAAC,UAAW;GAEhB,MAAM,EAAE,eAAe,QAAQ;GAC/B,MAAM,EAAE,MAAM,UAAU;GACxB,MAAM,iBAAiB,QAAQ,SAAS,eAAe;AACvD,OAAI,OAAO,WAET,SAAQ,SAAS,SAAS;IACxB;IACA,UAAU;IACX,CAAC;YACO,OAAO,QAAQ,aAAa,eAErC,SAAQ,SAAS,SAAS;IACxB,MAAM,OAAO,QAAQ;IACrB,UAAU;IACX,CAAC;;EAGN,uBAAuB;AACrB,eAAY,SAAS,SAAS;;EAEjC,EAAE;CAEH,MAAM,eAAe,cAAc;AACjC,MAAI,CAAC,QAAQ,QAAS,QAAO;EAC7B,MAAM,OAAO,KAAK,OACd,QAAQ,SAAS,gBAAgB,KAAK,oBAAA,GACzC;AACD,SAAO,OAAO,IAAI,IAAI,IAAI,OAAO;IAChC,CAAC,iBAAiB,CAAC;AAEtB,QACE,oBAAC,oBAAD;EACE,KAAK;EACL,OAAO;GAAE;GAAO;GAAQ,YAAY;GAAa;EACjD,wBAAwB;AAEtB,aAAU;;EAEZ,WAAW,GAAG,MAAM,WAAW,0BAA0B,EACvD,wCAAwC,eAAe,WACxD,CAAC;YAEF,qBAAC,OAAD;GACE,OAAO;IACL,QACE,eAAe,YACX,eAAA,KAA6B,mBAC7B;IACN,UAAU;IACV,OAAO;IACR;aARH;IAUE,qBAAC,OAAD;KAAK,WAAU;eAAf,CACE,oBAAC,kBAAD;MACE,WAAU;MACV,SAAS,CAAC,CAAC;MACX,KAAK;MACK,CAAA,EACZ,oBAAC,QAAD;MACgB;MACd,cAAc;MACd,SAAS;MACK;MACd,UAAU;MACG;MACb,CAAA,CACE;;IACL,eAAe,aAAa,aAAa,SAAS,KACjD,oBAAC,OAAD;KAAK,WAAU;eACb,oBAAC,YAAD,EAAQ,CAAA;KACJ,CAAA;IAEP,eAAe,aACd,oBAAC,cAAD;KACE,SAAS;KACI;KACC;KACF;KACF;KACV,cAAc;KACd,CAAA;IAEH,eAAe,WACd,oBAAC,eAAD;KACY;KACV,WAAW,QAAQ,SAAS,eAAe;KAC3C,CAAA;IAEA;;EACK,CAAA;EAEf,CAEmC"}
|
|
@@ -1,10 +1,15 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
//#region src/DataPreviewTable/interface.ts
|
|
2
|
+
var EScrollHorizontalDirection = /* @__PURE__ */ function(EScrollHorizontalDirection) {
|
|
3
|
+
EScrollHorizontalDirection["SCROLL_TO_LEFT"] = "toLeft";
|
|
4
|
+
EScrollHorizontalDirection["SCROLL_TO_RIGHT"] = "toRight";
|
|
5
|
+
return EScrollHorizontalDirection;
|
|
5
6
|
}({});
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
}({});
|
|
7
|
+
var EScrollVerticalDirection = /* @__PURE__ */ function(EScrollVerticalDirection) {
|
|
8
|
+
EScrollVerticalDirection["SCROLL_TO_TOP"] = "toTop";
|
|
9
|
+
EScrollVerticalDirection["SCROLL_TO_BOTTOM"] = "toBottom";
|
|
10
|
+
return EScrollVerticalDirection;
|
|
11
|
+
}({});
|
|
12
|
+
//#endregion
|
|
13
|
+
export { EScrollHorizontalDirection, EScrollVerticalDirection };
|
|
14
|
+
|
|
15
|
+
//# sourceMappingURL=interface.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"interface.js","names":[],"sources":["../../src/DataPreviewTable/interface.ts"],"sourcesContent":["import React, { CSSProperties } from 'react';\n\nexport interface ITableProps {\n columns?: PreviewColumn[];\n datasource?: TValue[][];\n // onHeaderContextMenu?: (e: MouseEvent, column: PreviewColumn) => void; //响应右键\n // onCellContextMenu?: (\n // e: MouseEvent,\n // value: TValue,\n // column: PreviewColumn,\n // ) => void; //响应右键\n width?: CSSProperties['width']; //容器宽度\n height?: CSSProperties['height']; //容器高度\n headerHeight?: number; // header 高度,不能小于最小高度\n dataStatus?: 'pending' | 'success' | 'error';\n loading?: boolean;\n errorMsg?: string | React.ReactNode;\n className?: string;\n}\nexport interface DataPreviewTableRef {\n scrollToColumnInView: (columnId: string) => void;\n progressRestart: () => void;\n}\nexport type Align = 'left' | 'center' | 'right';\nexport interface PreviewColumn {\n icon?: React.ReactNode;\n name: string;\n id: string;\n defaultWidth?: number;\n renderHeader?: (column: Omit<PreviewColumn, 'render'>) => React.ReactElement; //自定义列头\n align?: Align;\n render?: (value: TValue) => React.ReactElement;\n}\nexport type TValue = string | null | number | boolean;\nexport interface IColumnLayout {\n [key: string]: {\n width: number;\n left: number;\n };\n}\n\nexport interface IScrollData {\n scrollLeft: number;\n scrollTop: number;\n direction: IScrollDirection;\n}\nexport interface IScrollDirection {\n horizontal: EScrollHorizontalDirection;\n vertical: EScrollVerticalDirection;\n current: EScrollHorizontalDirection | EScrollVerticalDirection | 'init';\n}\nexport enum EScrollHorizontalDirection {\n SCROLL_TO_LEFT = 'toLeft',\n SCROLL_TO_RIGHT = 'toRight',\n}\nexport enum EScrollVerticalDirection {\n SCROLL_TO_TOP = 'toTop',\n SCROLL_TO_BOTTOM = 'toBottom',\n}\n"],"mappings":";AAmDA,IAAY,6BAAL,yBAAA,4BAAA;AACL,4BAAA,oBAAA;AACA,4BAAA,qBAAA;;KACD;AACD,IAAY,2BAAL,yBAAA,0BAAA;AACL,0BAAA,mBAAA;AACA,0BAAA,sBAAA;;KACD"}
|
|
@@ -1,68 +1,46 @@
|
|
|
1
|
-
|
|
1
|
+
//#region src/DataPreviewTable/utils/findRange.ts
|
|
2
2
|
var FIRST_INDEX = 0;
|
|
3
3
|
var BINARY_NUMBER = 2;
|
|
4
4
|
/**
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
right = arr.length - 1;
|
|
23
|
-
while (left <= right) {
|
|
24
|
-
var midIndex = Math.floor((left + right) / BINARY_NUMBER);
|
|
25
|
-
var mid = arr[midIndex];
|
|
26
|
-
if (mid < targetNumber) {
|
|
27
|
-
left = midIndex + 1;
|
|
28
|
-
} else if (mid === targetNumber) {
|
|
29
|
-
return midIndex;
|
|
30
|
-
} else {
|
|
31
|
-
right = midIndex - 1;
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
return left;
|
|
5
|
+
* @param arr 有序数组
|
|
6
|
+
* @param targetNumber 当前数字
|
|
7
|
+
* @returns 数组中第一个大于等于目标数字的index,最大为arr.length-1 如果数组为空,返回-1
|
|
8
|
+
*/
|
|
9
|
+
function findLastIndex(arr, targetNumber) {
|
|
10
|
+
if (arr.length === 0) return -1;
|
|
11
|
+
if (targetNumber >= arr[arr.length - 1]) return arr.length - 1;
|
|
12
|
+
if (targetNumber <= arr[FIRST_INDEX]) return FIRST_INDEX;
|
|
13
|
+
let left = 0, right = arr.length - 1;
|
|
14
|
+
while (left <= right) {
|
|
15
|
+
const midIndex = Math.floor((left + right) / BINARY_NUMBER);
|
|
16
|
+
const mid = arr[midIndex];
|
|
17
|
+
if (mid < targetNumber) left = midIndex + 1;
|
|
18
|
+
else if (mid === targetNumber) return midIndex;
|
|
19
|
+
else right = midIndex - 1;
|
|
20
|
+
}
|
|
21
|
+
return left;
|
|
35
22
|
}
|
|
36
23
|
/**
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
right = midIndex - 1;
|
|
61
|
-
} else if (mid === targetNumber) {
|
|
62
|
-
return midIndex;
|
|
63
|
-
} else {
|
|
64
|
-
left = midIndex + 1;
|
|
65
|
-
}
|
|
66
|
-
}
|
|
67
|
-
return right;
|
|
68
|
-
}
|
|
24
|
+
*
|
|
25
|
+
* @param arr 有序数组
|
|
26
|
+
* @param targetNumber 当前数字
|
|
27
|
+
* @returns 返回数组中第一个小于等于目标数字的index,用于查找起始位置 ,最小为0 如果数组为空返回-1
|
|
28
|
+
*/
|
|
29
|
+
function findFirstIndex(arr, targetNumber) {
|
|
30
|
+
if (arr.length === 0) return -1;
|
|
31
|
+
if (targetNumber >= arr[arr.length - 1]) return arr.length - 1;
|
|
32
|
+
if (targetNumber <= arr[FIRST_INDEX]) return FIRST_INDEX;
|
|
33
|
+
let left = 0, right = arr.length - 1;
|
|
34
|
+
while (left <= right) {
|
|
35
|
+
const midIndex = Math.floor((left + right) / BINARY_NUMBER);
|
|
36
|
+
const mid = arr[midIndex];
|
|
37
|
+
if (mid > targetNumber) right = midIndex - 1;
|
|
38
|
+
else if (mid === targetNumber) return midIndex;
|
|
39
|
+
else left = midIndex + 1;
|
|
40
|
+
}
|
|
41
|
+
return right;
|
|
42
|
+
}
|
|
43
|
+
//#endregion
|
|
44
|
+
export { findFirstIndex, findLastIndex };
|
|
45
|
+
|
|
46
|
+
//# sourceMappingURL=findRange.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"findRange.js","names":[],"sources":["../../../src/DataPreviewTable/utils/findRange.ts"],"sourcesContent":["import { UNDEFINED_INDEX } from '../constant';\n\nconst FIRST_INDEX = 0;\nconst BINARY_NUMBER = 2;\n/**\n * @param arr 有序数组\n * @param targetNumber 当前数字\n * @returns 数组中第一个大于等于目标数字的index,最大为arr.length-1 如果数组为空,返回-1\n */\nexport function findLastIndex(arr: number[], targetNumber: number): number {\n if (arr.length === 0) {\n return UNDEFINED_INDEX;\n }\n const last = arr[arr.length - 1];\n if (targetNumber >= last) {\n return arr.length - 1;\n }\n const first = arr[FIRST_INDEX];\n if (targetNumber <= first) {\n return FIRST_INDEX;\n }\n let left = 0,\n right = arr.length - 1;\n while (left <= right) {\n const midIndex = Math.floor((left + right) / BINARY_NUMBER);\n const mid = arr[midIndex];\n if (mid < targetNumber) {\n left = midIndex + 1;\n } else if (mid === targetNumber) {\n return midIndex;\n } else {\n right = midIndex - 1;\n }\n }\n return left;\n}\n/**\n *\n * @param arr 有序数组\n * @param targetNumber 当前数字\n * @returns 返回数组中第一个小于等于目标数字的index,用于查找起始位置 ,最小为0 如果数组为空返回-1\n */\nexport function findFirstIndex(arr: number[], targetNumber: number): number {\n if (arr.length === 0) {\n return UNDEFINED_INDEX;\n }\n const last = arr[arr.length - 1];\n if (targetNumber >= last) {\n return arr.length - 1;\n }\n const first = arr[FIRST_INDEX];\n if (targetNumber <= first) {\n return FIRST_INDEX;\n }\n let left = 0,\n right = arr.length - 1;\n while (left <= right) {\n const midIndex = Math.floor((left + right) / BINARY_NUMBER);\n const mid = arr[midIndex];\n if (mid > targetNumber) {\n right = midIndex - 1;\n } else if (mid === targetNumber) {\n return midIndex;\n } else {\n left = midIndex + 1;\n }\n }\n return right;\n}\n"],"mappings":";AAEA,IAAM,cAAc;AACpB,IAAM,gBAAgB;;;;;;AAMtB,SAAgB,cAAc,KAAe,cAA8B;AACzE,KAAI,IAAI,WAAW,EACjB,QAAA;AAGF,KAAI,gBADS,IAAI,IAAI,SAAS,GAE5B,QAAO,IAAI,SAAS;AAGtB,KAAI,gBADU,IAAI,aAEhB,QAAO;CAET,IAAI,OAAO,GACT,QAAQ,IAAI,SAAS;AACvB,QAAO,QAAQ,OAAO;EACpB,MAAM,WAAW,KAAK,OAAO,OAAO,SAAS,cAAc;EAC3D,MAAM,MAAM,IAAI;AAChB,MAAI,MAAM,aACR,QAAO,WAAW;WACT,QAAQ,aACjB,QAAO;MAEP,SAAQ,WAAW;;AAGvB,QAAO;;;;;;;;AAQT,SAAgB,eAAe,KAAe,cAA8B;AAC1E,KAAI,IAAI,WAAW,EACjB,QAAA;AAGF,KAAI,gBADS,IAAI,IAAI,SAAS,GAE5B,QAAO,IAAI,SAAS;AAGtB,KAAI,gBADU,IAAI,aAEhB,QAAO;CAET,IAAI,OAAO,GACT,QAAQ,IAAI,SAAS;AACvB,QAAO,QAAQ,OAAO;EACpB,MAAM,WAAW,KAAK,OAAO,OAAO,SAAS,cAAc;EAC3D,MAAM,MAAM,IAAI;AAChB,MAAI,MAAM,aACR,SAAQ,WAAW;WACV,QAAQ,aACjB,QAAO;MAEP,QAAO,WAAW;;AAGtB,QAAO"}
|
|
@@ -1,8 +1,13 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
}
|
|
1
|
+
//#region src/DataPreviewTable/utils/getColumnOffsetsFromWidths.ts
|
|
2
|
+
function getColumnOffsetsFromWidths_default(columnsWidth) {
|
|
3
|
+
let offset = 0;
|
|
4
|
+
return columnsWidth.map((width) => {
|
|
5
|
+
const currentOffset = offset;
|
|
6
|
+
offset += width;
|
|
7
|
+
return currentOffset;
|
|
8
|
+
});
|
|
9
|
+
}
|
|
10
|
+
//#endregion
|
|
11
|
+
export { getColumnOffsetsFromWidths_default as default };
|
|
12
|
+
|
|
13
|
+
//# sourceMappingURL=getColumnOffsetsFromWidths.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"getColumnOffsetsFromWidths.js","names":[],"sources":["../../../src/DataPreviewTable/utils/getColumnOffsetsFromWidths.ts"],"sourcesContent":["export default function (columnsWidth: number[]) {\n let offset = 0;\n return columnsWidth.map((width) => {\n const currentOffset = offset;\n offset += width;\n return currentOffset;\n });\n}\n"],"mappings":";AAAA,SAAA,mCAAyB,cAAwB;CAC/C,IAAI,SAAS;AACb,QAAO,aAAa,KAAK,UAAU;EACjC,MAAM,gBAAgB;AACtB,YAAU;AACV,SAAO;GACP"}
|
|
@@ -1,21 +1,11 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
var lastIndex = findLastIndex(columnsOffsets, scrollLeft + wrapWidth);
|
|
13
|
-
return [firstIndex, lastIndex];
|
|
14
|
-
}
|
|
15
|
-
if (direction === EScrollHorizontalDirection.SCROLL_TO_RIGHT || direction === 'init') {
|
|
16
|
-
// 往右滚动
|
|
17
|
-
var _firstIndex = findFirstIndex(columnsOffsets, scrollLeft);
|
|
18
|
-
var _lastIndex = findLastIndex(columnsOffsets, scrollLeft + PRE_RENDER_RANGE + wrapWidth);
|
|
19
|
-
return [_firstIndex, _lastIndex];
|
|
20
|
-
}
|
|
21
|
-
});
|
|
1
|
+
import { EScrollHorizontalDirection } from "../interface.js";
|
|
2
|
+
import { findFirstIndex, findLastIndex } from "./findRange.js";
|
|
3
|
+
//#region src/DataPreviewTable/utils/getColumnRange.ts
|
|
4
|
+
var getColumnRange_default = ({ direction, wrapWidth, scrollLeft, columnsOffsets }) => {
|
|
5
|
+
if (direction === EScrollHorizontalDirection.SCROLL_TO_LEFT) return [findFirstIndex(columnsOffsets, scrollLeft - 100), findLastIndex(columnsOffsets, scrollLeft + wrapWidth)];
|
|
6
|
+
if (direction === EScrollHorizontalDirection.SCROLL_TO_RIGHT || direction === "init") return [findFirstIndex(columnsOffsets, scrollLeft), findLastIndex(columnsOffsets, scrollLeft + 100 + wrapWidth)];
|
|
7
|
+
};
|
|
8
|
+
//#endregion
|
|
9
|
+
export { getColumnRange_default as default };
|
|
10
|
+
|
|
11
|
+
//# sourceMappingURL=getColumnRange.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"getColumnRange.js","names":[],"sources":["../../../src/DataPreviewTable/utils/getColumnRange.ts"],"sourcesContent":["import { PRE_RENDER_RANGE } from '../constant';\nimport { EScrollHorizontalDirection, IScrollDirection } from '../interface';\nimport { findFirstIndex, findLastIndex } from './findRange';\nexport default ({\n direction,\n wrapWidth,\n scrollLeft,\n columnsOffsets,\n}: {\n direction: IScrollDirection['current'];\n wrapWidth: number;\n scrollLeft: number;\n columnsOffsets: number[];\n}) => {\n if (direction === EScrollHorizontalDirection.SCROLL_TO_LEFT) {\n // 往左滚动\n const firstIndex = findFirstIndex(\n columnsOffsets,\n scrollLeft - PRE_RENDER_RANGE,\n );\n\n const lastIndex = findLastIndex(columnsOffsets, scrollLeft + wrapWidth);\n return [firstIndex, lastIndex] as [number, number];\n }\n if (\n direction === EScrollHorizontalDirection.SCROLL_TO_RIGHT ||\n direction === 'init'\n ) {\n // 往右滚动\n const firstIndex = findFirstIndex(columnsOffsets, scrollLeft);\n const lastIndex = findLastIndex(\n columnsOffsets,\n scrollLeft + PRE_RENDER_RANGE + wrapWidth,\n );\n return [firstIndex, lastIndex] as [number, number];\n }\n};\n"],"mappings":";;;AAGA,IAAA,0BAAgB,EACd,WACA,WACA,YACA,qBAMI;AACJ,KAAI,cAAc,2BAA2B,eAQ3C,QAAO,CANY,eACjB,gBACA,aAAA,IACD,EAEiB,cAAc,gBAAgB,aAAa,UAAU,CACzC;AAEhC,KACE,cAAc,2BAA2B,mBACzC,cAAc,OAQd,QAAO,CALY,eAAe,gBAAgB,WAAW,EAC3C,cAChB,gBACA,aAAA,MAAgC,UACjC,CAC6B"}
|
|
@@ -1,22 +1,15 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
if (direction === EScrollVerticalDirection.SCROLL_TO_BOTTOM || direction === 'init') {
|
|
17
|
-
// 往下滚动
|
|
18
|
-
var _firstIndex = Math.floor(scrollTop / CELL_HEIGHT);
|
|
19
|
-
var _lastIndex = Math.ceil((scrollTop + wrapHeight + PRE_RENDER_RANGE) / CELL_HEIGHT) + 1;
|
|
20
|
-
return [_firstIndex, _lastIndex];
|
|
21
|
-
}
|
|
22
|
-
});
|
|
1
|
+
import { EScrollVerticalDirection } from "../interface.js";
|
|
2
|
+
//#region src/DataPreviewTable/utils/getRowRange.ts
|
|
3
|
+
var getRowRange_default = ({ direction, wrapHeight, scrollTop }) => {
|
|
4
|
+
if (direction === EScrollVerticalDirection.SCROLL_TO_TOP) {
|
|
5
|
+
let firstIndex = Math.floor((scrollTop - 100) / 20);
|
|
6
|
+
if (firstIndex < 0) firstIndex = 0;
|
|
7
|
+
const lastIndex = Math.ceil((scrollTop + wrapHeight) / 20) + 1;
|
|
8
|
+
return [firstIndex, lastIndex];
|
|
9
|
+
}
|
|
10
|
+
if (direction === EScrollVerticalDirection.SCROLL_TO_BOTTOM || direction === "init") return [Math.floor(scrollTop / 20), Math.ceil((scrollTop + wrapHeight + 100) / 20) + 1];
|
|
11
|
+
};
|
|
12
|
+
//#endregion
|
|
13
|
+
export { getRowRange_default as default };
|
|
14
|
+
|
|
15
|
+
//# sourceMappingURL=getRowRange.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"getRowRange.js","names":[],"sources":["../../../src/DataPreviewTable/utils/getRowRange.ts"],"sourcesContent":["import { CELL_HEIGHT, PRE_RENDER_RANGE } from '../constant';\nimport { EScrollVerticalDirection, IScrollDirection } from '../interface';\nexport default ({\n direction,\n wrapHeight,\n scrollTop,\n}: {\n direction: IScrollDirection['current'];\n wrapHeight: number;\n scrollTop: number;\n}) => {\n if (direction === EScrollVerticalDirection.SCROLL_TO_TOP) {\n // 往上滚动\n let firstIndex = Math.floor((scrollTop - PRE_RENDER_RANGE) / CELL_HEIGHT);\n if (firstIndex < 0) {\n firstIndex = 0;\n }\n const lastIndex = Math.ceil((scrollTop + wrapHeight) / CELL_HEIGHT) + 1;\n return [firstIndex, lastIndex] as [number, number];\n }\n if (\n direction === EScrollVerticalDirection.SCROLL_TO_BOTTOM ||\n direction === 'init'\n ) {\n // 往下滚动\n const firstIndex = Math.floor(scrollTop / CELL_HEIGHT);\n const lastIndex =\n Math.ceil((scrollTop + wrapHeight + PRE_RENDER_RANGE) / CELL_HEIGHT) + 1;\n return [firstIndex, lastIndex] as [number, number];\n }\n};\n"],"mappings":";;AAEA,IAAA,uBAAgB,EACd,WACA,YACA,gBAKI;AACJ,KAAI,cAAc,yBAAyB,eAAe;EAExD,IAAI,aAAa,KAAK,OAAO,YAAA,OAAA,GAA4C;AACzE,MAAI,aAAa,EACf,cAAa;EAEf,MAAM,YAAY,KAAK,MAAM,YAAY,cAAA,GAA0B,GAAG;AACtE,SAAO,CAAC,YAAY,UAAU;;AAEhC,KACE,cAAc,yBAAyB,oBACvC,cAAc,OAMd,QAAO,CAHY,KAAK,MAAM,YAAA,GAAwB,EAEpD,KAAK,MAAM,YAAY,aAAA,OAAA,GAA6C,GAAG,EAC3C"}
|
|
@@ -1,17 +1,19 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
}
|
|
1
|
+
//#region src/DataPreviewTable/utils/getTableLayout.ts
|
|
2
|
+
var getTableLayout_default = (tableColumns, columnsWidth) => {
|
|
3
|
+
if (columnsWidth.length !== tableColumns.length) throw new Error("columnsWidth.length !== tableColumns.length");
|
|
4
|
+
const columnLayout = {};
|
|
5
|
+
let left = 0;
|
|
6
|
+
tableColumns.forEach((column, index) => {
|
|
7
|
+
const columnWidth = columnsWidth[index] || column.defaultWidth || 100;
|
|
8
|
+
columnLayout[column.id] = {
|
|
9
|
+
width: columnWidth,
|
|
10
|
+
left
|
|
11
|
+
};
|
|
12
|
+
left += columnWidth;
|
|
13
|
+
});
|
|
14
|
+
return columnLayout;
|
|
15
|
+
};
|
|
16
|
+
//#endregion
|
|
17
|
+
export { getTableLayout_default as default };
|
|
18
|
+
|
|
19
|
+
//# sourceMappingURL=getTableLayout.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"getTableLayout.js","names":[],"sources":["../../../src/DataPreviewTable/utils/getTableLayout.ts"],"sourcesContent":["import { DEFAULT_COLUMN_WIDTH } from '../constant';\nimport { IColumnLayout, PreviewColumn } from '../interface';\n\nexport default (tableColumns: PreviewColumn[], columnsWidth: number[]) => {\n if (columnsWidth.length !== tableColumns.length) {\n throw new Error('columnsWidth.length !== tableColumns.length');\n }\n const columnLayout: IColumnLayout = {};\n let left = 0;\n tableColumns.forEach((column, index) => {\n const columnWidth =\n columnsWidth[index] || column.defaultWidth || DEFAULT_COLUMN_WIDTH;\n columnLayout[column.id] = {\n width: columnWidth,\n left,\n };\n left += columnWidth;\n });\n return columnLayout;\n};\n"],"mappings":";AAGA,IAAA,0BAAgB,cAA+B,iBAA2B;AACxE,KAAI,aAAa,WAAW,aAAa,OACvC,OAAM,IAAI,MAAM,8CAA8C;CAEhE,MAAM,eAA8B,EAAE;CACtC,IAAI,OAAO;AACX,cAAa,SAAS,QAAQ,UAAU;EACtC,MAAM,cACJ,aAAa,UAAU,OAAO,gBAAA;AAChC,eAAa,OAAO,MAAM;GACxB,OAAO;GACP;GACD;AACD,UAAQ;GACR;AACF,QAAO"}
|