@unicom-cloud/ui 0.8.100 → 0.8.102

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (301) hide show
  1. package/Badge.js +7 -54
  2. package/Copy.js +5 -4
  3. package/Details.js +13 -2
  4. package/Divider.js +3 -2
  5. package/Flex.js +14 -4
  6. package/LiquidFill.js +5 -4
  7. package/List.js +1 -1
  8. package/Loading.js +16 -3
  9. package/Marquee.js +5 -4
  10. package/QrCode.js +5 -4
  11. package/Space.js +3 -3
  12. package/Splitter.js +4 -3
  13. package/SuspenseFallbackTest.js +2 -4
  14. package/Tooltip.js +3 -4
  15. package/Tour.js +5 -4
  16. package/alert/index.js +60 -62
  17. package/anchor/Anchor.js +12 -12
  18. package/anchor/util.js +10 -10
  19. package/back-top/index.js +33 -34
  20. package/badge/index.js +109 -162
  21. package/calendar/index.js +85 -84
  22. package/card/index.js +63 -43
  23. package/color-picker/InputHex.js +3 -4
  24. package/color-picker/InputRgb.js +7 -8
  25. package/color-picker/Palette.js +3 -4
  26. package/color-picker/Panel.js +3 -4
  27. package/color-picker/colors.js +5 -5
  28. package/color-picker/hooks/useColorPicker.js +3 -4
  29. package/color-picker/utils.js +14 -15
  30. package/components/common/development/index.js +44 -29
  31. package/components/common/empty/index.js +35 -23
  32. package/components/common/flex/index.js +64 -0
  33. package/components/common/flex/interface.js +9 -0
  34. package/components/common/higher-order/with-speech-synthesis/index.js +79 -55
  35. package/components/common/space/index.js +71 -91
  36. package/components/common/suspense-fallback-test/index.js +16 -0
  37. package/components/common/utils/PqbCSSTransition.js +1 -1
  38. package/components/common/utils/constant.js +6 -3
  39. package/components/common/utils/reactDOM.js +6 -4
  40. package/components/common/utils/{scrollIntoView.js → scrollIntoViewIfNeeded.js} +1 -1
  41. package/components/common/utils/setPrimaryColor.js +18 -18
  42. package/components/common/utils/setTheme.js +8 -9
  43. package/components/common/utils/toArray.js +12 -0
  44. package/copy/index.js +3 -2
  45. package/details/index.js +102 -62
  46. package/dist/scroll-into-view-if-needed/compute/index.js +126 -0
  47. package/dist/scroll-into-view-if-needed/smooth/index.js +70 -0
  48. package/dist/scroll-into-view-if-needed/src/index.js +19 -19
  49. package/divider/index.js +27 -21
  50. package/empty/index.js +13 -13
  51. package/flex/index.js +43 -55
  52. package/flex/interface.js +1 -34
  53. package/form/FormItem.js +69 -65
  54. package/form/context.js +6 -7
  55. package/grid/Col-.js +86 -0
  56. package/grid/Col.js +156 -73
  57. package/grid/Grid.js +71 -67
  58. package/grid/Row.js +3 -3
  59. package/grid/index.js +13 -13
  60. package/icon/interface.js +1 -0
  61. package/icon-hover/interface.js +1 -0
  62. package/index.js +641 -663
  63. package/input/Textarea.js +1 -1
  64. package/input/autoSizeTextAreaHeight.js +7 -7
  65. package/liquid-fill/index.js +5 -4
  66. package/list/index.js +1 -1
  67. package/loading/index.js +72 -53
  68. package/loading/interface.js +1 -0
  69. package/marquee/index.js +5 -4
  70. package/menu/Item.js +9 -9
  71. package/modal/Modal.js +73 -74
  72. package/package.json +1 -1
  73. package/portal/interface.js +1 -0
  74. package/qr-code/index.js +5 -4
  75. package/segmented/index.js +47 -47
  76. package/space/index.js +41 -35
  77. package/speech-synthesis/interface.js +1 -0
  78. package/splitter/SplitBar.js +81 -79
  79. package/splitter/Splitter.js +92 -104
  80. package/splitter/hooks/useItems.js +1 -1
  81. package/splitter/hooks/useResizable.js +9 -18
  82. package/splitter/hooks/useResize.js +10 -10
  83. package/splitter/hooks/useSizes.js +28 -28
  84. package/splitter/index.js +5 -4
  85. package/statistic/index.js +10 -10
  86. package/style.css +1 -1
  87. package/suspense-fallback-test/index.js +2 -11
  88. package/suspense-fallback-test/interface.js +1 -0
  89. package/table/Table.js +376 -377
  90. package/table/hook/useThResizable.js +5 -4
  91. package/table/th-resizable/index.js +12 -11
  92. package/time-picker/util.js +8 -8
  93. package/tooltip/index.js +1 -2
  94. package/tour/index.js +5 -4
  95. package/tree/NodeList.js +1 -1
  96. package/trigger/index.js +67 -70
  97. package/types/common/development/index.d.ts +7 -1
  98. package/types/common/development/interface.d.ts +22 -0
  99. package/types/common/empty/index.d.ts +2 -1
  100. package/types/common/flex/index.d.ts +14 -0
  101. package/types/common/flex/interface.d.ts +62 -0
  102. package/types/common/higher-order/with-speech-synthesis/index.d.ts +6 -1
  103. package/types/common/higher-order/with-speech-synthesis/interface.d.ts +13 -0
  104. package/types/common/space/index.d.ts +4 -4
  105. package/types/common/space/interface.d.ts +10 -18
  106. package/types/common/suspense-fallback-test/index.d.ts +7 -0
  107. package/types/common/suspense-fallback-test/interface.d.ts +1 -0
  108. package/types/common/utils/PqbCSSTransition.d.ts +1 -1
  109. package/types/common/utils/constant.d.ts +1 -0
  110. package/types/common/utils/scrollIntoViewIfNeeded.d.ts +4 -0
  111. package/types/common/utils/toArray.d.ts +13 -0
  112. package/types/common/utils/tree.d.ts +1 -0
  113. package/types/common/utils/tween.d.ts +1 -0
  114. package/types/pc/alert/index.d.ts +2 -1
  115. package/types/pc/alert/interface.d.ts +7 -1
  116. package/types/pc/anchor/util.d.ts +1 -1
  117. package/types/pc/badge/Count.d.ts +1 -1
  118. package/types/pc/badge/interface.d.ts +2 -0
  119. package/types/pc/breadcrumb/Item.d.ts +1 -1
  120. package/types/pc/calendar/Month.d.ts +1 -1
  121. package/types/pc/calendar/WeekList.d.ts +1 -1
  122. package/types/pc/calendar/Year.d.ts +1 -1
  123. package/types/pc/calendar/header/Panel.d.ts +1 -1
  124. package/types/pc/calendar/header/index.d.ts +1 -1
  125. package/types/pc/calendar/index.d.ts +1 -1
  126. package/types/pc/calendar/interface.d.ts +2 -1
  127. package/types/pc/card/interface.d.ts +8 -0
  128. package/types/pc/cascader/interface.d.ts +1 -1
  129. package/types/pc/cascader/panel/List.d.ts +1 -1
  130. package/types/pc/cascader/panel/Option.d.ts +1 -1
  131. package/types/pc/cascader/panel/Search.d.ts +1 -1
  132. package/types/pc/checkbox/Group.d.ts +2 -2
  133. package/types/pc/checkbox/GroupBlock.d.ts +1 -1
  134. package/types/pc/checkbox/IconCheck.d.ts +1 -1
  135. package/types/pc/color-picker/InputRgb.d.ts +1 -1
  136. package/types/pc/color-picker/Palette.d.ts +1 -1
  137. package/types/pc/color-picker/hooks/useColorPicker.d.ts +7 -2
  138. package/types/pc/color-picker/utils.d.ts +6 -1
  139. package/types/pc/config-provider/ConfigProvider.d.ts +1 -1
  140. package/types/pc/config-provider/interface.d.ts +4 -0
  141. package/types/pc/copy/index.d.ts +1 -1
  142. package/types/pc/date-picker/panel/Body.d.ts +1 -1
  143. package/types/pc/date-picker/panel/Footer.d.ts +1 -1
  144. package/types/pc/date-picker/panel/Header.d.ts +1 -1
  145. package/types/pc/date-picker/panel/WeekList.d.ts +1 -1
  146. package/types/pc/date-picker/panel/date/index.d.ts +1 -1
  147. package/types/pc/date-picker/panel/month/index.d.ts +1 -1
  148. package/types/pc/date-picker/panel/quarter/index.d.ts +1 -1
  149. package/types/pc/date-picker/panel/range/index.d.ts +1 -1
  150. package/types/pc/date-picker/panel/week/index.d.ts +1 -1
  151. package/types/pc/date-picker/panel/year/index.d.ts +1 -1
  152. package/types/pc/descriptions/index.d.ts +1 -1
  153. package/types/pc/details/index.d.ts +3 -2
  154. package/types/pc/details/interface.d.ts +16 -0
  155. package/types/pc/development/index.d.ts +2 -1
  156. package/types/pc/development/interface.d.ts +15 -0
  157. package/types/pc/divider/index.d.ts +7 -2
  158. package/types/pc/draggable/Item.d.ts +1 -1
  159. package/types/pc/draggable/index.d.ts +1 -1
  160. package/types/pc/flex/index.d.ts +4 -4
  161. package/types/pc/flex/interface.d.ts +8 -53
  162. package/types/pc/form/Control.d.ts +1 -1
  163. package/types/pc/form/FormItem.d.ts +1 -1
  164. package/types/pc/form/FormList.d.ts +1 -1
  165. package/types/pc/form/IconSymbol.d.ts +1 -1
  166. package/types/pc/grid/Col-.d.ts +4 -0
  167. package/types/pc/grid/Col.d.ts +3 -2
  168. package/types/pc/grid/Grid.d.ts +2 -2
  169. package/types/pc/grid/Item.d.ts +3 -3
  170. package/types/pc/grid/Row.d.ts +2 -2
  171. package/types/pc/grid/hook/useResponsiveState.d.ts +2 -2
  172. package/types/pc/grid/interface.d.ts +13 -7
  173. package/types/pc/icon/addFromIconFontCn.d.ts +1 -7
  174. package/types/pc/icon/index.d.ts +2 -7
  175. package/types/pc/icon/interface.d.ts +13 -0
  176. package/types/pc/icon-hover/index.d.ts +2 -8
  177. package/types/pc/icon-hover/interface.d.ts +8 -0
  178. package/types/pc/image/ImageFooter.d.ts +1 -1
  179. package/types/pc/image/ImagePreviewArrow.d.ts +1 -1
  180. package/types/pc/image/TriggerForToolbar.d.ts +1 -1
  181. package/types/pc/index.d.ts +60 -51
  182. package/types/pc/loading/index.d.ts +4 -3
  183. package/types/pc/loading/interface.d.ts +6 -0
  184. package/types/pc/menu/Indent.d.ts +1 -1
  185. package/types/pc/menu/OverflowWrap.d.ts +1 -1
  186. package/types/pc/menu/sub-menu/Inline.d.ts +1 -1
  187. package/types/pc/menu/sub-menu/Pop.d.ts +1 -1
  188. package/types/pc/overflow-ellipsis/OverflowItem.d.ts +1 -1
  189. package/types/pc/overflow-ellipsis/index.d.ts +1 -1
  190. package/types/pc/pagination/PageItem.d.ts +3 -3
  191. package/types/pc/pagination/PageJumper.d.ts +1 -1
  192. package/types/pc/pagination/PageOption.d.ts +1 -1
  193. package/types/pc/portal/Portal.d.ts +2 -6
  194. package/types/pc/portal/index.d.ts +2 -9
  195. package/types/pc/portal/interface.d.ts +14 -0
  196. package/types/pc/progress/CircleProgress.d.ts +1 -1
  197. package/types/pc/progress/LineProgess.d.ts +1 -1
  198. package/types/pc/progress/StepProgress.d.ts +1 -1
  199. package/types/pc/radio/Group.d.ts +2 -2
  200. package/types/pc/radio/GroupBlock.d.ts +1 -1
  201. package/types/pc/radio/Radio.d.ts +1 -1
  202. package/types/pc/resize-box/ResizeTrigger.d.ts +1 -1
  203. package/types/pc/result/403.d.ts +1 -1
  204. package/types/pc/result/404.d.ts +1 -1
  205. package/types/pc/result/500.d.ts +1 -1
  206. package/types/pc/segmented/interface.d.ts +6 -6
  207. package/types/pc/skeleton/Image.d.ts +1 -1
  208. package/types/pc/skeleton/Text.d.ts +2 -1
  209. package/types/pc/slider/Button.d.ts +1 -1
  210. package/types/pc/slider/Input.d.ts +1 -1
  211. package/types/pc/slider/Tick.d.ts +1 -1
  212. package/types/pc/space/index.d.ts +6 -5
  213. package/types/pc/speech-synthesis/index.d.ts +3 -1
  214. package/types/pc/speech-synthesis/interface.d.ts +7 -0
  215. package/types/pc/spin/DotLoading.d.ts +1 -1
  216. package/types/pc/splitter/SplitBar.d.ts +0 -1
  217. package/types/pc/splitter/hooks/useResizable.d.ts +0 -1
  218. package/types/pc/splitter/hooks/useResize.d.ts +1 -2
  219. package/types/pc/splitter/index.d.ts +5 -4
  220. package/types/pc/splitter/interface.d.ts +16 -24
  221. package/types/pc/suspense-fallback-test/index.d.ts +2 -3
  222. package/types/pc/suspense-fallback-test/interface.d.ts +2 -0
  223. package/types/pc/table/ColGroup.d.ts +1 -1
  224. package/types/pc/table/summary/Cell.d.ts +1 -1
  225. package/types/pc/table/summary/Row.d.ts +1 -1
  226. package/types/pc/table/tbody/Td.d.ts +1 -1
  227. package/types/pc/table/tbody/index.d.ts +1 -1
  228. package/types/pc/table/tfoot/index.d.ts +1 -1
  229. package/types/pc/table/th-resizable/index.d.ts +1 -1
  230. package/types/pc/table/thead/Column.d.ts +1 -1
  231. package/types/pc/table/thead/index.d.ts +1 -1
  232. package/types/pc/tabs/TabContent.d.ts +1 -1
  233. package/types/pc/tabs/tab-header/DropdownIcon.d.ts +1 -1
  234. package/types/pc/tabs/tab-header/TabInk.d.ts +1 -1
  235. package/types/pc/tabs/tab-header/TabNavIcon.d.ts +1 -1
  236. package/types/pc/time-picker/Picker.d.ts +1 -1
  237. package/types/pc/time-picker/RangePicker.d.ts +1 -1
  238. package/types/pc/time-picker/TimeColumn.d.ts +1 -1
  239. package/types/pc/time-picker/TimePicker.d.ts +1 -1
  240. package/types/pc/time-picker/index.d.ts +1 -1
  241. package/types/pc/tour/index.d.ts +1 -1
  242. package/types/pc/transfer/Item.d.ts +1 -1
  243. package/types/pc/transfer/List.d.ts +1 -1
  244. package/types/pc/tree/Animation.d.ts +1 -1
  245. package/types/pc/typography/Operations.d.ts +1 -1
  246. package/types/pc/upload/interface.d.ts +1 -0
  247. package/types/pc/upload/list/index.d.ts +1 -1
  248. package/types/pc/utils/constant.d.ts +1 -2
  249. package/types/pc/utils/dayjs.d.ts +2 -1
  250. package/types/pc/utils/index.d.ts +2 -5
  251. package/types/pc/utils/scrollIntoViewIfNeeded.d.ts +3 -0
  252. package/types/pc/utils/toArray.d.ts +1 -5
  253. package/types/pc/utils/tree.d.ts +2 -1
  254. package/types/pc/utils/tween.d.ts +1 -1
  255. package/types/pc/verification-code/VerificationCode.d.ts +1 -1
  256. package/types/pc/virtual-list/VirtualList.d.ts +2 -38
  257. package/types/pc/virtual-list/index.d.ts +2 -1
  258. package/types/pc/virtual-list/interface.d.ts +56 -0
  259. package/types/pc/watermark/Watermark.d.ts +1 -1
  260. package/typography/Ellipsis.js +5 -4
  261. package/typography/Operations.js +5 -4
  262. package/upload/request.js +12 -13
  263. package/upload/request_.js +2 -3
  264. package/utils/constant.js +5 -5
  265. package/utils/dayjs.js +13 -12
  266. package/utils/index.js +261 -284
  267. package/utils/scrollIntoViewIfNeeded.js +12 -0
  268. package/utils/toArray.js +3 -10
  269. package/utils/tree.js +11 -9
  270. package/utils/tween.js +5 -5
  271. package/version/index.js +1 -1
  272. package/virtual-list/interface.js +1 -0
  273. package/components/common/space/toArray.js +0 -11
  274. package/components/common/utils/convertToDurationBasedOnTimeUnits.js +0 -6
  275. package/dist/compute-scroll-into-view/src/index.js +0 -126
  276. package/dist/tinycolor/chunk/BOzCVdr0.js +0 -182
  277. package/dist/tinycolor/customize/index.js +0 -12
  278. package/dist/tinycolor/src/conversion.js +0 -143
  279. package/dist/tinycolor/src/css-color-names.js +0 -153
  280. package/dist/tinycolor/src/format-input.js +0 -77
  281. package/dist/tinycolor/src/index.js +0 -388
  282. package/dist/tinycolor/src/util.js +0 -32
  283. package/flex/utils.js +0 -13
  284. package/loading/style/index.module.less.js +0 -4
  285. package/types/common/space/toArray.d.ts +0 -3
  286. package/types/common/utils/convertToDurationBasedOnTimeUnits.d.ts +0 -3
  287. package/types/common/utils/scrollIntoView.d.ts +0 -4
  288. package/types/common/utils/tinycolor.d.ts +0 -1
  289. package/types/pc/flex/utils.d.ts +0 -9
  290. package/types/pc/suspense-fallback-test/style/index.d.ts +0 -1
  291. package/types/pc/utils/color.d.ts +0 -1
  292. package/types/pc/utils/computeScrollIntoView.d.ts +0 -1
  293. package/types/pc/utils/convertToDurationBasedOnTimeUnits.d.ts +0 -3
  294. package/types/pc/utils/scrollIntoView.d.ts +0 -3
  295. package/types/pc/utils/tinycolor.d.ts +0 -1
  296. package/utils/color.js +0 -4
  297. package/utils/computeScrollIntoView.js +0 -6
  298. package/utils/convertToDurationBasedOnTimeUnits.js +0 -6
  299. package/utils/scrollIntoView.js +0 -6
  300. package/utils/tinycolor.js +0 -29
  301. /package/{suspense-fallback-test/style/index.less.js → development/interface.js} +0 -0
package/table/Table.js CHANGED
@@ -1,36 +1,35 @@
1
- import { jsx as a, jsxs as T, Fragment as Fe } from "react/jsx-runtime";
2
- import { Tween as no } from "../dist/tween/src/tween.js";
3
- import { quintInOut as so } from "../dist/tween/src/easing.js";
4
- import io from "lodash/debounce";
5
- import A from "lodash/isArray";
6
- import Je from "lodash/isNumber";
7
- import p from "lodash/isPlainObject";
8
- import lo from "lodash/throttle";
9
- import co, { forwardRef as ao, useContext as fo, useMemo as ne, useRef as w, useState as V, useImperativeHandle as uo, useCallback as po, useEffect as Qe } from "react";
1
+ import { jsx as a, jsxs as F, Fragment as ve } from "react/jsx-runtime";
2
+ import { Tween as sr } from "../dist/tween/src/tween.js";
3
+ import lr from "../dist/tween/src/easing.js";
4
+ import ir from "lodash/debounce";
5
+ import cr from "lodash/throttle";
6
+ import ar, { forwardRef as dr, useContext as fr, useMemo as le, useRef as w, useState as V, useImperativeHandle as ur, useCallback as pr, useEffect as Je } from "react";
10
7
  import "../config-provider/ConfigProvider.js";
11
- import mo from "../components/common/hooks/useIsomorphicLayoutEffect.js";
12
- import Ze from "../components/common/hooks/useMergeProps.js";
13
- import et from "../components/common/hooks/useUpdateEffect.js";
14
- import tt from "../pagination/Pagination.js";
15
- import go from "../spin/index.js";
16
- import ot from "@unicom-cloud/utils/class-name";
17
- import { on as se, off as ie } from "../components/common/utils/dom.js";
18
- import { pickDataAttributes as yo } from "../components/common/utils/pick.js";
19
- import { resizeObserver as ho } from "../components/common/utils/resizeObserver.js";
20
- import le from "./ColGroup.js";
21
- import bo from "./hook/useColumns.js";
22
- import Co from "./hook/useComponent.js";
23
- import xo from "./hook/useExpand.js";
24
- import So from "./hook/useRowSelection.js";
25
- import wo from "./hook/useSorter.js";
26
- import Po from "./hook/useStickyClassNames.js";
27
- import To from "./hook/useStickyOffsets.js";
28
- import $o from "./tbody/index.js";
29
- import Fo from "./tfoot/index.js";
30
- import No from "./thead/index.js";
31
- import { deepCloneData as vo, getOriginData as C, getSorterPriority as rt, getSorterFn as nt, getScrollBarHeight as Do, getScrollBarWidth as Bo } from "./util.js";
32
- import Lo from "../config-provider/context.js";
33
- const zo = [], Ro = [], Ho = {
8
+ import mr from "../components/common/hooks/useIsomorphicLayoutEffect.js";
9
+ import Qe from "../components/common/hooks/useMergeProps.js";
10
+ import Ze from "../components/common/hooks/useUpdateEffect.js";
11
+ import et from "../pagination/Pagination.js";
12
+ import gr from "../spin/index.js";
13
+ import tt from "@unicom-cloud/utils/class-name";
14
+ import { on as ie, off as ce } from "../components/common/utils/dom.js";
15
+ import "../components/common/utils/is.js";
16
+ import { pickDataAttributes as hr } from "../components/common/utils/pick.js";
17
+ import { resizeObserver as yr } from "../components/common/utils/resizeObserver.js";
18
+ import ae from "./ColGroup.js";
19
+ import br from "./hook/useColumns.js";
20
+ import Cr from "./hook/useComponent.js";
21
+ import xr from "./hook/useExpand.js";
22
+ import Sr from "./hook/useRowSelection.js";
23
+ import wr from "./hook/useSorter.js";
24
+ import Tr from "./hook/useStickyClassNames.js";
25
+ import Fr from "./hook/useStickyOffsets.js";
26
+ import Pr from "./tbody/index.js";
27
+ import $r from "./tfoot/index.js";
28
+ import Nr from "./thead/index.js";
29
+ import { deepCloneData as vr, getOriginData as C, getSorterPriority as rt, getSorterFn as ot, getScrollBarHeight as Dr, getScrollBarWidth as Br } from "./util.js";
30
+ import Lr from "../config-provider/context.js";
31
+ import { isPlainObject as p, isFunction as $, isNumber as nt, isArray as M } from "@unicom-cloud/utils/is";
32
+ const zr = [], Rr = [], Hr = {
34
33
  showHeader: !0,
35
34
  border: !0,
36
35
  hover: !0,
@@ -40,322 +39,321 @@ const zo = [], Ro = [], Ho = {
40
39
  indentSize: 15,
41
40
  showSorterTooltip: !0
42
41
  };
43
- function ko(ce, st) {
42
+ function Er(de, st) {
44
43
  const {
45
- getPrefixCls: it,
46
- loadingElement: lt,
47
- size: Ne,
44
+ getPrefixCls: lt,
45
+ loadingElement: it,
46
+ size: De,
48
47
  tablePagination: ct,
49
48
  renderEmpty: at,
50
- componentConfig: ae,
51
- rtl: F
52
- } = fo(Lo), b = Ze(
53
- ce,
54
- Ho,
55
- ae?.Table
56
- ), N = Ze(
57
- p(ce?.pagination) ? ce?.pagination : {},
58
- p(ae?.Table?.pagination) ? ae?.Table?.pagination : {},
49
+ componentConfig: fe,
50
+ rtl: N
51
+ } = fr(Lr), m = Qe(
52
+ de,
53
+ Hr,
54
+ fe?.Table
55
+ ), v = Qe(
56
+ p(de?.pagination) ? de?.pagination : {},
57
+ p(fe?.Table?.pagination) ? fe?.Table?.pagination : {},
59
58
  ct || {}
60
59
  ), {
61
- style: ft,
62
- className: dt,
60
+ style: dt,
61
+ className: ft,
63
62
  component: ut,
64
- border: h,
65
- borderCell: fe,
66
- columns: ve = Ro,
67
- data: m = zo,
68
- scroll: i,
63
+ border: b,
64
+ borderCell: ue,
65
+ columns: Be = Rr,
66
+ data: g = zr,
67
+ scroll: l,
69
68
  noDataElement: pt,
70
69
  showHeader: mt,
71
70
  stripe: gt,
72
- hover: yt,
73
- pagination: P,
74
- onChange: M,
71
+ hover: ht,
72
+ pagination: T,
73
+ onChange: Y,
75
74
  pagePosition: x,
76
- childrenColumnName: H,
77
- indentSize: ht,
75
+ childrenColumnName: E,
76
+ indentSize: yt,
78
77
  rowSelection: k,
79
78
  tableLayoutFixed: bt,
80
- header: De,
79
+ header: Le,
81
80
  // 潘启宝添加
82
- footer: Be,
83
- virtualized: v,
84
- renderPagination: Le,
85
- summary: de,
86
- rowKey: Y
87
- } = b, ze = ne(
88
- () => vo(m, H),
89
- [m, H]
90
- ), n = it?.("table"), ue = b.size || (["default", "middle", "small", "mini"].indexOf(Ne) > -1 ? Ne : "default"), D = w(null), u = w(null), pe = w(null), g = w(null), E = w(null), me = w(null), K = w(null), j = w(0), ge = w(!1), [Re, f] = bo(b), { currentFilters: Ct, defaultSorters: xt } = zt(), [O, ye] = V(1), [St, wt] = V(
91
- N.pageSize || N.defaultPageSize || 10
92
- ), [He, ke] = V(Ct), [Pt, Tt] = V(0), [$t, Ft] = V([]), he = To(f), [Nt, Ee] = Po(
93
- Re,
94
- f,
81
+ footer: ze,
82
+ virtualized: D,
83
+ renderPagination: Re,
84
+ summary: pe,
85
+ rowKey: K
86
+ } = m, He = le(
87
+ () => vr(g, E),
88
+ [g, E]
89
+ ), n = lt?.("table"), me = m.size || (["default", "middle", "small", "mini"].indexOf(De) > -1 ? De : "default"), B = w(null), u = w(null), ge = w(null), h = w(null), O = w(null), he = w(null), j = w(null), q = w(0), ye = w(!1), [Ee, d] = br(m), { currentFilters: Ct, defaultSorters: xt } = zt(), [W, be] = V(1), [St, wt] = V(
90
+ v.pageSize || v.defaultPageSize || 10
91
+ ), [ke, Oe] = V(Ct), [Tt, Ft] = V(0), [Pt, $t] = V([]), Ce = Fr(d), [Nt, We] = Tr(
92
+ Ee,
93
+ d,
95
94
  n
96
95
  ), {
97
- currentSorter: W,
98
- activeSorters: d,
96
+ currentSorter: I,
97
+ activeSorters: f,
99
98
  getNextActiveSorters: vt,
100
99
  updateStateSorters: Dt
101
- } = wo(f, xt), { ComponentTable: q, ComponentBodyWrapper: Bt, ComponentHeaderWrapper: Lt } = Co(ut), be = ne(() => typeof Y == "function" ? (e) => Y(C(e)) : (e) => e[Y], [Y]);
100
+ } = wr(d, xt), { ComponentTable: U, ComponentBodyWrapper: Bt, ComponentHeaderWrapper: Lt } = Cr(ut), xe = le(() => $(K) ? (e) => K(C(e)) : (e) => e[K], [K]);
102
101
  function zt() {
103
102
  const e = {};
104
103
  let t = [];
105
- return f.forEach((o) => {
106
- const r = o.dataIndex || o.key;
107
- if (o.defaultFilters && (e[r] = o.defaultFilters), o.filteredValue && (e[r] = o.filteredValue), "defaultSortOrder" in o || "sortOrder" in o) {
108
- const s = rt(o.sorter), c = "sortOrder" in o ? o.sortOrder : o.defaultSortOrder, l = {
109
- field: r,
104
+ return d.forEach((r) => {
105
+ const o = r.dataIndex || r.key;
106
+ if (r.defaultFilters && (e[o] = r.defaultFilters), r.filteredValue && (e[o] = r.filteredValue), "defaultSortOrder" in r || "sortOrder" in r) {
107
+ const s = rt(r.sorter), c = "sortOrder" in r ? r.sortOrder : r.defaultSortOrder, i = {
108
+ field: o,
110
109
  direction: c,
111
- sorterFn: nt(o.sorter),
110
+ sorterFn: ot(r.sorter),
112
111
  priority: s
113
112
  };
114
- c ? Je(s) ? t.every(
115
- (y) => Je(y.priority) || !y.direction
116
- ) && t.push(l) : t.every((y) => !y.direction) ? t.push(l) : t = [l] : t.push(l);
113
+ c ? nt(s) ? t.every(
114
+ (y) => nt(y.priority) || !y.direction
115
+ ) && t.push(i) : t.every((y) => !y.direction) ? t.push(i) : t = [i] : t.push(i);
117
116
  }
118
117
  }), { currentFilters: e, defaultSorters: t };
119
118
  }
120
- const U = ne(() => {
121
- const e = f.filter(
122
- (o) => "filteredValue" in o
119
+ const G = le(() => {
120
+ const e = d.filter(
121
+ (r) => "filteredValue" in r
123
122
  ), t = {};
124
- return e.length && e.forEach((o, r) => {
125
- const s = o.key || o.dataIndex || r;
126
- s !== void 0 && (t[s] = o.filteredValue);
123
+ return e.length && e.forEach((r, o) => {
124
+ const s = r.key || r.dataIndex || o;
125
+ s !== void 0 && (t[s] = r.filteredValue);
127
126
  }), t;
128
- }, [f]), $ = ne(() => Object.keys(U).length ? U : He, [He, U]);
127
+ }, [d]), P = le(() => Object.keys(G).length ? G : ke, [ke, G]);
129
128
  function Rt(e, t) {
130
- const o = Ve(t);
131
- if (!o)
129
+ const r = Ye(t);
130
+ if (!r)
132
131
  return;
133
- const r = {
132
+ const o = {
134
133
  direction: e,
135
134
  field: t,
136
- sorterFn: nt(o.sorter),
137
- priority: rt(o.sorter)
138
- }, s = vt(r);
139
- Dt(r, s);
140
- const c = Q(
141
- r,
135
+ sorterFn: ot(r.sorter),
136
+ priority: rt(r.sorter)
137
+ }, s = vt(o);
138
+ Dt(o, s);
139
+ const c = Z(
140
+ o,
142
141
  s,
143
- $
144
- ), l = I(c);
145
- M?.(L(c), r, $, {
146
- currentData: C(l),
142
+ P
143
+ ), i = _(c);
144
+ Y?.(z(c), o, P, {
145
+ currentData: C(i),
147
146
  currentAllData: C(c),
148
147
  action: "sort"
149
148
  });
150
149
  }
151
150
  function Ht(e) {
152
- const t = function(r, s) {
153
- return (c, l) => {
154
- const y = r(c, l);
151
+ const t = function(o, s) {
152
+ return (c, i) => {
153
+ const y = o(c, i);
155
154
  return s === "descend" ? -y : y;
156
155
  };
157
- }, o = [...e];
158
- return o.sort((r, s) => s.priority - r.priority), (r, s) => {
159
- for (let c = 0, l = o.length; c < l; c++) {
160
- const { sorterFn: y, direction: $e } = o[c];
161
- if (typeof y != "function")
162
- continue;
163
- const re = t(y, $e)(r, s);
164
- if (re !== 0)
165
- return re;
156
+ }, r = [...e];
157
+ return r.sort((o, s) => s.priority - o.priority), (o, s) => {
158
+ for (let c = 0, i = r.length; c < i; c++) {
159
+ const { sorterFn: y, direction: Ne } = r[c];
160
+ if (!$(y)) continue;
161
+ const se = t(y, Ne)(o, s);
162
+ if (se !== 0)
163
+ return se;
166
164
  }
167
165
  return 0;
168
166
  };
169
167
  }
170
- function kt(e, t) {
171
- const o = {
172
- ...$,
168
+ function Et(e, t) {
169
+ const r = {
170
+ ...P,
173
171
  [e.dataIndex]: t
174
- }, r = {
175
- ...o,
176
- ...U
172
+ }, o = {
173
+ ...r,
174
+ ...G
177
175
  };
178
- if (A(t) && t.length) {
179
- ke(r);
180
- const s = Q(
181
- W,
182
- d,
183
- o
184
- ), c = I(s);
185
- M?.(
186
- L(s),
187
- d.length === 1 ? d[0] : d,
188
- o,
176
+ if (M(t) && t.length) {
177
+ Oe(o);
178
+ const s = Z(
179
+ I,
180
+ f,
181
+ r
182
+ ), c = _(s);
183
+ Y?.(
184
+ z(s),
185
+ f.length === 1 ? f[0] : f,
186
+ r,
189
187
  {
190
188
  currentData: C(c),
191
189
  currentAllData: C(s),
192
190
  action: "filter"
193
191
  }
194
192
  );
195
- } else A(t) && !t.length && Oe(e);
193
+ } else M(t) && !t.length && Ie(e);
196
194
  }
197
- function Oe({ dataIndex: e }) {
195
+ function Ie({ dataIndex: e }) {
198
196
  const t = {
199
- ...$
197
+ ...P
200
198
  };
201
- delete t[e], ke(t);
202
- const o = Q(
203
- W,
204
- d,
199
+ delete t[e], Oe(t);
200
+ const r = Z(
201
+ I,
202
+ f,
205
203
  t
206
- ), r = I(o);
207
- M?.(
208
- L(o),
209
- d.length === 1 ? d[0] : d,
204
+ ), o = _(r);
205
+ Y?.(
206
+ z(r),
207
+ f.length === 1 ? f[0] : f,
210
208
  t,
211
209
  {
212
- currentData: C(r),
213
- currentAllData: C(o),
210
+ currentData: C(o),
211
+ currentAllData: C(r),
214
212
  action: "filter"
215
213
  }
216
214
  );
217
215
  }
218
- const G = !!f.find((e) => e.fixed === "left"), X = !!f.find((e) => e.fixed === "right"), J = G || X;
219
- function Q(e, t, o) {
220
- let r = (ze || []).slice();
221
- Object.keys(o).forEach((c) => {
222
- if (o[c] && o[c].length) {
223
- const l = Ve(c);
224
- l && typeof l.onFilter == "function" && (r = r.filter((y) => o[c].reduce(
225
- ($e, re) => $e || l.onFilter(re, y),
216
+ const X = !!d.find((e) => e.fixed === "left"), J = !!d.find((e) => e.fixed === "right"), Q = X || J;
217
+ function Z(e, t, r) {
218
+ let o = (He || []).slice();
219
+ Object.keys(r).forEach((c) => {
220
+ if (r[c] && r[c].length) {
221
+ const i = Ye(c);
222
+ i && $(i.onFilter) && (o = o.filter((y) => r[c].reduce(
223
+ (Ne, se) => Ne || i.onFilter(se, y),
226
224
  !1
227
225
  )));
228
226
  }
229
227
  });
230
- const s = (c) => c.slice().sort(Ht(t)).map((l) => A(l[H]) ? {
231
- ...l,
232
- [H]: s(l[H])
233
- } : l);
234
- return e.direction && typeof e.sorterFn == "function" || t.length ? s(r) : r;
228
+ const s = (c) => c.slice().sort(Ht(t)).map((i) => M(i[E]) ? {
229
+ ...i,
230
+ [E]: s(i[E])
231
+ } : i);
232
+ return e.direction && $(e.sorterFn) || t.length ? s(o) : o;
235
233
  }
236
- const B = Q(
237
- W,
238
- d,
239
- $
234
+ const L = Z(
235
+ I,
236
+ f,
237
+ P
240
238
  );
241
- function L(e = B) {
242
- const t = N.pageSize || St || 10, o = ue === "middle" ? "default" : ue;
243
- let r = "top";
244
- x === "tl" || x === "bl" ? r = "bottom" : r = "top";
245
- const s = A(e) ? e.length : 0, c = Math.ceil(s / t) < O ? 1 : O;
246
- c !== O && ye(c);
247
- let l = {
248
- size: o,
239
+ function z(e = L) {
240
+ const t = v.pageSize || St || 10, r = me === "middle" ? "default" : me;
241
+ let o = "top";
242
+ x === "tl" || x === "bl" ? o = "bottom" : o = "top";
243
+ const s = M(e) ? e.length : 0, c = Math.ceil(s / t) < W ? 1 : W;
244
+ c !== W && be(c);
245
+ let i = {
246
+ size: r,
249
247
  total: s,
250
248
  pageSize: t,
251
249
  current: c,
252
250
  selectProps: {
253
251
  triggerProps: {
254
- position: r
252
+ position: o
255
253
  }
256
254
  }
257
255
  };
258
- return typeof P == "object" && P.selectProps && (l.selectProps = {
259
- ...l.selectProps,
260
- ...P.selectProps
261
- }), p(P) && (l = {
262
- ...l,
263
- ...P
264
- }), p(N) && (l = {
265
- ...l,
266
- ...N
267
- }), l.onChange = Kt, l;
256
+ return typeof T == "object" && T.selectProps && (i.selectProps = {
257
+ ...i.selectProps,
258
+ ...T.selectProps
259
+ }), p(T) && (i = {
260
+ ...i,
261
+ ...T
262
+ }), p(v) && (i = {
263
+ ...i,
264
+ ...v
265
+ }), i.onChange = Kt, i;
268
266
  }
269
- const Z = L(), z = I();
270
- function I(e = B, t = Z) {
271
- const { current: o = 0, pageSize: r = 10 } = t;
272
- return P === !1 || p(P) && m.length <= r ? e : e.slice((o - 1) * r, o * r);
267
+ const ee = z(), R = _();
268
+ function _(e = L, t = ee) {
269
+ const { current: r = 0, pageSize: o = 10 } = t;
270
+ return T === !1 || p(T) && g.length <= o ? e : e.slice((r - 1) * o, r * o);
273
271
  }
274
- const We = io(Ie, 100), S = !!(i && i.y), _ = de?.(C(B)), Ce = de && co.isValidElement(_) && _.props.fixed, Et = S && Ce;
275
- mo(() => {
276
- Ie(), se(window, "resize", We);
277
- const e = D.current, t = u.current, o = g.current;
278
- t && se(t, "scroll", R);
279
- const r = e && e.parentNode;
280
- return e && r && se(r, "scroll", R), o && se(o, "scroll", R), () => {
281
- ie(window, "resize", We), t && ie(t, "scroll", R), r && ie(r, "scroll", R), o && ie(o, "scroll", R);
272
+ const _e = ir(Ae, 100), S = !!(l && l.y), A = pe?.(C(L)), Se = pe && ar.isValidElement(A) && A.props.fixed, kt = S && Se;
273
+ mr(() => {
274
+ Ae(), ie(window, "resize", _e);
275
+ const e = B.current, t = u.current, r = h.current;
276
+ t && ie(t, "scroll", H);
277
+ const o = e && e.parentNode;
278
+ return e && o && ie(o, "scroll", H), r && ie(r, "scroll", H), () => {
279
+ ce(window, "resize", _e), t && ce(t, "scroll", H), o && ce(o, "scroll", H), r && ce(r, "scroll", H);
282
280
  };
283
281
  }, [
284
- G,
285
282
  X,
286
- i?.x,
287
- i?.y,
288
- f.length,
289
- m
290
- ]), et(() => {
291
- const { total: e, pageSize: t } = L(m);
292
- Math.ceil(e / t) < O && ye(1);
293
- }, [m?.length]), et(() => {
294
- ee();
295
- }, [m, G, X, F]), uo(st, () => ({
296
- getRootDomElement: xe,
283
+ J,
284
+ l?.x,
285
+ l?.y,
286
+ d.length,
287
+ g
288
+ ]), Ze(() => {
289
+ const { total: e, pageSize: t } = z(g);
290
+ Math.ceil(e / t) < W && be(1);
291
+ }, [g?.length]), Ze(() => {
292
+ te();
293
+ }, [g, X, J, N]), ur(st, () => ({
294
+ getRootDomElement: we,
297
295
  scrollIntoView: (e) => {
298
- me.current && me.current.scrollTo({ key: e });
296
+ he.current && he.current.scrollTo({ key: e });
299
297
  },
300
- getRootDOMNode: xe
298
+ getRootDOMNode: we
301
299
  }));
302
- function xe() {
303
- return E.current;
300
+ function we() {
301
+ return O.current;
304
302
  }
305
- function Ie() {
306
- ee();
307
- const e = xe();
308
- if (e && (J || i && i.x)) {
309
- const o = (e.querySelector(`.${n}-body`) || e.querySelector(`.${n}-content-inner`))?.getBoundingClientRect?.()?.width;
310
- Tt(o);
303
+ function Ae() {
304
+ te();
305
+ const e = we();
306
+ if (e && (Q || l && l.x)) {
307
+ const r = (e.querySelector(`.${n}-body`) || e.querySelector(`.${n}-content-inner`))?.getBoundingClientRect?.()?.width;
308
+ Ft(r);
311
309
  }
312
310
  }
313
- const Ot = po(
314
- lo(() => {
315
- const e = E.current, t = S ? u.current : K.current && K.current.parentNode;
311
+ const Ot = pr(
312
+ cr(() => {
313
+ const e = O.current, t = S ? u.current : j.current && j.current.parentNode;
316
314
  if (t) {
317
- const o = F ? -t.scrollLeft : t.scrollLeft, r = o === 0, s = o + 1 >= t.children[0].getBoundingClientRect().width - t.getBoundingClientRect().width;
318
- r && s ? te(
315
+ const r = N ? -t.scrollLeft : t.scrollLeft, o = r === 0, s = r + 1 >= t.children[0].getBoundingClientRect().width - t.getBoundingClientRect().width;
316
+ o && s ? re(
319
317
  e.classList,
320
318
  `${n}-scroll-position-both`
321
- ) : r ? te(
319
+ ) : o ? re(
322
320
  e.classList,
323
- `${n}-scroll-position-${F ? "right" : "left"}`
324
- ) : s ? te(
321
+ `${n}-scroll-position-${N ? "right" : "left"}`
322
+ ) : s ? re(
325
323
  e.classList,
326
- `${n}-scroll-position-${F ? "left" : "right"}`
327
- ) : te(
324
+ `${n}-scroll-position-${N ? "left" : "right"}`
325
+ ) : re(
328
326
  e.classList,
329
327
  `${n}-scroll-position-middle`
330
328
  );
331
329
  } else
332
- e && Ae(e.classList);
330
+ e && Me(e.classList);
333
331
  }, 100),
334
- [E.current, u.current, S, F]
332
+ [O.current, u.current, S, N]
335
333
  );
336
- function ee() {
337
- if (J || i && p(i) && i.x) {
338
- const e = E.current;
339
- e && (G && _e(
334
+ function te() {
335
+ if (Q || l && p(l) && l.x) {
336
+ const e = O.current;
337
+ e && (X && Ve(
340
338
  e.classList,
341
339
  `${n}-has-fixed-col-left`
342
- ), X && _e(
340
+ ), J && Ve(
343
341
  e.classList,
344
342
  `${n}-has-fixed-col-right`
345
343
  )), Ot();
346
344
  }
347
345
  }
348
- function _e(e, t) {
346
+ function Ve(e, t) {
349
347
  e.contains(t) || e.add(t);
350
348
  }
351
- function Ae(e) {
349
+ function Me(e) {
352
350
  e.remove(`${n}-scroll-position-both`), e.remove(`${n}-scroll-position-left`), e.remove(`${n}-scroll-position-right`), e.remove(`${n}-scroll-position-middle`);
353
351
  }
354
- function te(e, t) {
355
- e.contains(t) || (Ae(e), e.add(t));
352
+ function re(e, t) {
353
+ e.contains(t) || (Me(e), e.add(t));
356
354
  }
357
355
  const {
358
- selectedRowKeys: Se,
356
+ selectedRowKeys: Te,
359
357
  indeterminateKeys: Wt,
360
358
  onCheckAll: It,
361
359
  onCheck: _t,
@@ -363,264 +361,265 @@ function ko(ce, st) {
363
361
  setSelectedRowKeys: Vt,
364
362
  allSelectedRowKeys: Mt,
365
363
  flattenData: Yt
366
- } = So(b, z, ze, be);
367
- function Ve(e) {
368
- return f.find((t, o) => typeof t.key < "u" ? typeof t.key == "number" && typeof e == "string" ? t.key.toString() === e : t.key === e : typeof t.dataIndex < "u" ? t.dataIndex === e : typeof e == "number" ? o === e : !1);
364
+ } = Sr(m, R, He, xe);
365
+ function Ye(e) {
366
+ return d.find((t, r) => typeof t.key < "u" ? typeof t.key == "number" && typeof e == "string" ? t.key.toString() === e : t.key === e : typeof t.dataIndex < "u" ? t.dataIndex === e : typeof e == "number" ? r === e : !1);
369
367
  }
370
368
  function Kt(e, t) {
371
- ye(e), wt(t), e !== O && jt(), k && !k.checkCrossPage && Se.length && (Vt([]), k.onChange?.([], []));
372
- const o = { ...L(), current: e, pageSize: t };
373
- M?.(
374
- o,
375
- d.length === 1 ? d[0] : d,
376
- $,
369
+ be(e), wt(t), e !== W && jt(), k && !k.checkCrossPage && Te.length && (Vt([]), k.onChange?.([], []));
370
+ const r = { ...z(), current: e, pageSize: t };
371
+ Y?.(
372
+ r,
373
+ f.length === 1 ? f[0] : f,
374
+ P,
377
375
  {
378
376
  currentData: C(
379
- I(B, o)
377
+ _(L, r)
380
378
  ),
381
- currentAllData: C(B),
379
+ currentAllData: C(L),
382
380
  action: "paginate"
383
381
  }
384
- ), N.onChange?.(e, t);
382
+ ), v.onChange?.(e, t);
385
383
  }
386
384
  function jt() {
387
385
  if (!u.current)
388
386
  return;
389
387
  const t = u.current.scrollTop;
390
- new no({
388
+ new sr({
391
389
  from: { scrollTop: t },
392
390
  to: { scrollTop: 0 },
393
- easing: so,
391
+ easing: lr.quintInOut,
394
392
  duration: 300,
395
- onUpdate: (r) => {
396
- u.current && (u.current.scrollTop = r.scrollTop);
393
+ onUpdate: (o) => {
394
+ u.current && (u.current.scrollTop = o.scrollTop);
397
395
  }
398
396
  }).start();
399
397
  }
400
- function R(e) {
401
- const { target: t } = e, o = u.current, r = D.current && D.current.parentNode, s = g.current;
402
- t.scrollLeft !== j.current && (r && (r.scrollLeft = t.scrollLeft), o && (o.scrollLeft = t.scrollLeft), s && (s.scrollLeft = t.scrollLeft), ee()), j.current = e.target.scrollLeft;
398
+ function H(e) {
399
+ const { target: t } = e, r = u.current, o = B.current && B.current.parentNode, s = h.current;
400
+ t.scrollLeft !== q.current && (o && (o.scrollLeft = t.scrollLeft), r && (r.scrollLeft = t.scrollLeft), s && (s.scrollLeft = t.scrollLeft), te()), q.current = e.target.scrollLeft;
403
401
  }
404
402
  function qt(e) {
405
- const { target: t } = e, o = K.current;
406
- t.scrollLeft !== j.current && (o.scrollLeft = t.scrollLeft, ee()), j.current = e.target.scrollLeft;
403
+ const { target: t } = e, r = j.current;
404
+ t.scrollLeft !== q.current && (r.scrollLeft = t.scrollLeft, te()), q.current = e.target.scrollLeft;
407
405
  }
408
- const [Me, Ut] = xo(
409
- b,
406
+ const [Ke, Ut] = xr(
407
+ m,
410
408
  Yt,
411
- be
409
+ xe
412
410
  );
413
- let Ye = {}, we = {};
414
- i && (i.x && (typeof i.x == "number" || typeof i.x == "string") && (we = {
415
- width: i.x
416
- }), i.y && (typeof i.y == "number" || typeof i.y == "string") && (Ye = {
417
- maxHeight: i.y
411
+ let je = {}, Fe = {};
412
+ l && (l.x && (typeof l.x == "number" || typeof l.x == "string") && (Fe = {
413
+ width: l.x
414
+ }), l.y && (typeof l.y == "number" || typeof l.y == "string") && (je = {
415
+ maxHeight: l.y
418
416
  }));
419
417
  function Gt() {
420
418
  requestAnimationFrame((e) => {
421
- const t = D.current && D.current.parentNode, o = Do(t);
422
- o && o > 0 && (t.style.marginBottom = `-${o}px`, t.style.paddingBottom = "0px", g.current && (g.current.style.marginBottom = `-${o}px`, g.current.style.paddingBottom = "0px")), setTimeout(() => {
423
- const r = u.current;
424
- Bo(r) ? (ge.current = !0, t && (t.style.overflowY = "scroll", t.style.scrollSnapType = "y mandatory"), g.current && (g.current.style.overflowY = "scroll", g.current.style.overflowY = "y mandatory")) : t && ge.current && (ge.current = !1, t.style.overflowY = "auto", t.style.overflowY = "y mandatory", g.current && (g.current.style.overflowY = "auto", g.current.style.overflowY = "y mandatory"));
419
+ const t = B.current && B.current.parentNode, r = Dr(t);
420
+ r && r > 0 && (t.style.marginBottom = `-${r}px`, t.style.paddingBottom = "0px", h.current && (h.current.style.marginBottom = `-${r}px`, h.current.style.paddingBottom = "0px")), setTimeout(() => {
421
+ const o = u.current;
422
+ Br(o) ? (ye.current = !0, t && (t.style.overflowY = "scroll", t.style.scrollSnapType = "y mandatory"), h.current && (h.current.style.overflowY = "scroll", h.current.style.overflowY = "y mandatory")) : t && ye.current && (ye.current = !1, t.style.overflowY = "auto", t.style.overflowY = "y mandatory", h.current && (h.current.style.overflowY = "auto", h.current.style.overflowY = "y mandatory"));
425
423
  }, 0);
426
424
  });
427
425
  }
428
- const Ke = /* @__PURE__ */ a(
429
- No,
426
+ const qe = /* @__PURE__ */ a(
427
+ Nr,
430
428
  {
431
- ...b,
432
- activeSorters: d,
433
- currentSorter: W,
434
- selectedRowKeys: Se,
435
- currentFilters: $,
429
+ ...m,
430
+ activeSorters: f,
431
+ currentSorter: I,
432
+ selectedRowKeys: Te,
433
+ currentFilters: P,
436
434
  onCheckAll: It,
437
435
  onSort: Rt,
438
- data: z,
439
- onHandleFilter: kt,
440
- onHandleFilterReset: Oe,
436
+ data: R,
437
+ onHandleFilter: Et,
438
+ onHandleFilterReset: Ie,
441
439
  prefixCls: n,
442
440
  allSelectedRowKeys: Mt,
443
- groupColumns: Re,
444
- stickyOffsets: he,
441
+ groupColumns: Ee,
442
+ stickyOffsets: Ce,
445
443
  groupStickyClassNames: Nt
446
444
  }
447
445
  );
448
446
  function Xt() {
449
- const e = p(i) && i.x === "max-content";
450
- return S || v ? /* @__PURE__ */ a(Lt, { className: `${n}-header`, children: /* @__PURE__ */ T(
451
- q,
447
+ const e = p(l) && l.x === "max-content";
448
+ return S || D ? /* @__PURE__ */ a(Lt, { className: `${n}-header`, children: /* @__PURE__ */ F(
449
+ U,
452
450
  {
453
- ref: D,
454
- style: e ? {} : we,
451
+ ref: B,
452
+ style: e ? {} : Fe,
455
453
  children: [
456
454
  /* @__PURE__ */ a(
457
- le,
455
+ ae,
458
456
  {
459
- columns: f,
457
+ columns: d,
460
458
  prefixCls: n,
461
459
  producer: !1,
462
- columnWidths: e && i.y ? $t : null
460
+ columnWidths: e && l.y ? Pt : null
463
461
  }
464
462
  ),
465
- Ke
463
+ qe
466
464
  ]
467
465
  }
468
- ) }) : Ke;
466
+ ) }) : qe;
469
467
  }
470
- const je = _ && /* @__PURE__ */ a(
471
- Fo,
468
+ const Ue = A && /* @__PURE__ */ a(
469
+ $r,
472
470
  {
473
471
  prefixCls: n,
474
- summary: de,
475
- data: z,
476
- columns: f,
477
- stickyOffsets: he,
478
- stickyClassNames: Ee
472
+ summary: pe,
473
+ data: R,
474
+ columns: d,
475
+ stickyOffsets: Ce,
476
+ stickyClassNames: We
479
477
  }
480
- ), qe = /* @__PURE__ */ a(
481
- $o,
478
+ ), Ge = /* @__PURE__ */ a(
479
+ Pr,
482
480
  {
483
- ...b,
484
- saveRef: (e) => pe.current = e,
485
- selectedRowKeys: Se,
481
+ ...m,
482
+ saveRef: (e) => ge.current = e,
483
+ selectedRowKeys: Te,
486
484
  indeterminateKeys: Wt,
487
- expandedRowKeys: Me,
485
+ expandedRowKeys: Ke,
488
486
  onCheck: _t,
489
487
  onCheckRadio: At,
490
488
  onClickExpandBtn: Ut,
491
- columns: f,
492
- data: z,
489
+ columns: d,
490
+ data: R,
493
491
  prefixCls: n,
494
- hasFixedColumn: J,
495
- tableViewWidth: Pt,
496
- indentSize: ht,
492
+ hasFixedColumn: Q,
493
+ tableViewWidth: Tt,
494
+ indentSize: yt,
497
495
  noDataElement: pt || at("Table"),
498
- activeSorters: d,
499
- currentSorter: W,
500
- stickyOffsets: he,
501
- stickyClassNames: Ee,
502
- getRowKey: be,
496
+ activeSorters: f,
497
+ currentSorter: I,
498
+ stickyOffsets: Ce,
499
+ stickyClassNames: We,
500
+ getRowKey: xe,
503
501
  saveVirtualListRef: (e) => {
504
- v && (me.current = e, u.current = e?.dom);
502
+ D && (he.current = e, u.current = e?.dom);
505
503
  },
506
- ___dangerouslySetInnerHTML___: b.___dangerouslySetInnerHTML___
504
+ ___dangerouslySetInnerHTML___: m.___dangerouslySetInnerHTML___
507
505
  }
508
- ), Ue = !v && !Et ? /* @__PURE__ */ T(Fe, { children: [
509
- qe,
510
- je
511
- ] }) : qe;
512
- if (Qe(() => {
513
- const e = u.current || pe.current, t = ho([e], Gt);
506
+ ), Xe = !D && !kt ? /* @__PURE__ */ F(ve, { children: [
507
+ Ge,
508
+ Ue
509
+ ] }) : Ge;
510
+ if (Je(() => {
511
+ const e = u.current || ge.current, t = yr([e], Gt);
514
512
  return () => {
515
513
  t();
516
514
  };
517
- }, [u.current, pe.current]), Qe(() => (console.table(m), () => {
518
- }), [m]), !ve.length) return null;
515
+ }, [u.current, ge.current]), Je(() => (m.consoleTable && console.table(g), () => {
516
+ }), [g, m.consoleTable]), !Be.length) return null;
519
517
  function Jt() {
520
- const e = p(i) && i.x === "max-content" && !!i.y && A(m) && m.length > 0;
521
- return S && !v ? /* @__PURE__ */ a(
518
+ const e = p(l) && l.x === "max-content" && !!l.y && M(g) && g.length > 0;
519
+ return S && !D ? /* @__PURE__ */ a(
522
520
  Bt,
523
521
  {
524
522
  ref: u,
525
523
  className: `${n}-body`,
526
- style: Ye,
527
- children: /* @__PURE__ */ T(q, { style: we, children: [
524
+ style: je,
525
+ children: /* @__PURE__ */ F(U, { style: Fe, children: [
528
526
  /* @__PURE__ */ a(
529
- le,
527
+ ae,
530
528
  {
531
- columns: f,
529
+ columns: d,
532
530
  prefixCls: n,
533
531
  producer: e,
534
- onSetColumnWidths: Ft,
535
- expandedRowKeys: Me,
536
- data: m
532
+ onSetColumnWidths: $t,
533
+ expandedRowKeys: Ke,
534
+ data: g
537
535
  }
538
536
  ),
539
- Ue
537
+ Xe
540
538
  ] })
541
539
  }
542
- ) : Ue;
540
+ ) : Xe;
543
541
  }
544
542
  function Qt() {
545
543
  let e = {};
546
- i && p(i) && i.x && (e = {
547
- width: i.x
544
+ l && p(l) && l.x && (e = {
545
+ width: l.x
548
546
  });
549
- const t = /* @__PURE__ */ a("div", { className: `${n}-tfoot`, ref: g, children: /* @__PURE__ */ T(q, { style: e, children: [
550
- /* @__PURE__ */ a(le, { columns: f, prefixCls: n }),
551
- je
552
- ] }) }), o = _ && S && Ce === "top", r = _ && S && Ce === "bottom", s = /* @__PURE__ */ T(Fe, { children: [
547
+ const t = /* @__PURE__ */ a("div", { className: `${n}-tfoot`, ref: h, children: /* @__PURE__ */ F(U, { style: e, children: [
548
+ /* @__PURE__ */ a(ae, { columns: d, prefixCls: n }),
549
+ Ue
550
+ ] }) }), r = A && S && Se === "top", o = A && S && Se === "bottom", s = /* @__PURE__ */ F(ve, { children: [
553
551
  mt ? Xt() : null,
554
- o && t,
552
+ r && t,
555
553
  Jt(),
556
- r && t
557
- ] });
558
- return /* @__PURE__ */ T(Fe, { children: [
559
- typeof De == "function" && /* @__PURE__ */ a("div", { className: `${n}-header-`, children: De(z) }),
554
+ o && t
555
+ ] }), c = $(Le) && Le(R), i = $(ze) && ze(R);
556
+ return /* @__PURE__ */ F(ve, { children: [
557
+ !!c && /* @__PURE__ */ a("div", { className: `${n}-header-`, children: c }),
560
558
  /* @__PURE__ */ a("div", { className: `${n}-container`, children: /* @__PURE__ */ a("div", { className: `${n}-content-scroll`, children: /* @__PURE__ */ a(
561
559
  "div",
562
560
  {
563
561
  className: `${n}-content-inner`,
564
562
  onScroll: S ? void 0 : qt,
565
- children: S || v ? s : /* @__PURE__ */ T(q, { ref: K, style: e, children: [
566
- /* @__PURE__ */ a(le, { prefixCls: n, columns: f }),
563
+ children: S || D ? s : /* @__PURE__ */ F(U, { ref: j, style: e, children: [
564
+ /* @__PURE__ */ a(ae, { prefixCls: n, columns: d }),
567
565
  s
568
566
  ] })
569
567
  }
570
568
  ) }) }),
571
- typeof Be == "function" && /* @__PURE__ */ a("div", { className: `${n}-footer`, children: Be(z) })
569
+ !!i && /* @__PURE__ */ a("div", { className: `${n}-footer`, children: i })
572
570
  ] });
573
571
  }
574
- const Zt = p(h) ? h.wrapper : h, Pe = p(h) ? h.cell : fe, eo = p(h) ? h.cell || h.headerCell : fe, to = p(h) ? h.cell || h.bodyCell : fe, oo = ot(
572
+ const Zt = p(b) ? b.wrapper : b, Pe = p(b) ? b.cell : ue, er = p(b) ? b.cell || b.headerCell : ue, tr = p(b) ? b.cell || b.bodyCell : ue, rr = tt(
575
573
  n,
576
- `${n}-size-${ue}`,
574
+ `${n}-size-${me}`,
577
575
  {
578
576
  [`${n}-border`]: Zt,
579
577
  [`${n}-border-cell`]: Pe,
580
- [`${n}-border-header-cell`]: !Pe && eo,
581
- [`${n}-border-body-cell`]: !Pe && to,
578
+ [`${n}-border-header-cell`]: !Pe && er,
579
+ [`${n}-border-body-cell`]: !Pe && tr,
582
580
  [`${n}-stripe`]: gt,
583
- [`${n}-hover`]: yt,
581
+ [`${n}-hover`]: ht,
584
582
  [`${n}-type-radio`]: k && k.type === "radio",
585
- [`${n}-layout-fixed`]: bt || i && (i.x || i.y) || ve.find((e) => e.ellipsis),
586
- [`${n}-fixed-column`]: J,
587
- [`${n}-virtualized`]: v,
588
- [`${n}-rtl`]: F
583
+ [`${n}-layout-fixed`]: bt || l && (l.x || l.y) || Be.find((e) => e.ellipsis),
584
+ [`${n}-fixed-column`]: Q,
585
+ [`${n}-virtualized`]: D,
586
+ [`${n}-rtl`]: N
589
587
  },
590
- dt
591
- ), Te = x === "tl" || x === "tr" || x === "topCenter", ro = ot(`${n}-pagination`, {
588
+ ft
589
+ ), $e = x === "tl" || x === "tr" || x === "topCenter", or = tt(`${n}-pagination`, {
592
590
  [`${n}-pagination-left`]: x === "tl" || x === "bl",
593
591
  [`${n}-pagination-center`]: x === "topCenter" || x === "bottomCenter",
594
- [`${n}-pagination-top`]: Te
592
+ [`${n}-pagination-top`]: $e
595
593
  });
596
- let oe = b.loading;
594
+ let oe = m.loading;
597
595
  typeof oe == "boolean" && (oe = { loading: oe });
598
- const Ge = typeof Le == "function" ? Le(/* @__PURE__ */ a(tt, { ...Z })) : /* @__PURE__ */ a("div", { className: ro, children: /* @__PURE__ */ a(tt, { ...Z }) }), Xe = P !== !1 && (B.length !== 0 || Z.total > 0);
599
- return /* @__PURE__ */ a(
596
+ const nr = T !== !1 && (L.length !== 0 || ee?.total > 0);
597
+ let ne;
598
+ return nr && ($(Re) ? ne = Re(/* @__PURE__ */ a(et, { ...ee })) : ne = /* @__PURE__ */ a("div", { className: or, children: /* @__PURE__ */ a(et, { ...ee }) })), /* @__PURE__ */ a(
600
599
  "div",
601
600
  {
602
- ref: E,
603
- style: ft,
604
- className: oo,
605
- ...yo(b),
606
- children: /* @__PURE__ */ T(
607
- go,
601
+ ref: O,
602
+ style: dt,
603
+ className: rr,
604
+ ...hr(m),
605
+ children: /* @__PURE__ */ F(
606
+ gr,
608
607
  {
609
608
  className: `${n}-spin`,
610
- element: lt,
609
+ element: it,
611
610
  ...oe,
612
611
  children: [
613
- Xe && Te && Ge,
612
+ $e && ne,
614
613
  Qt(),
615
- Xe && !Te && Ge
614
+ !$e && ne
616
615
  ]
617
616
  }
618
617
  )
619
618
  }
620
619
  );
621
620
  }
622
- const Eo = ao(ko);
623
- Eo.displayName = "Table";
621
+ const kr = dr(Er);
622
+ kr.displayName = "Table";
624
623
  export {
625
- Eo as default
624
+ kr as default
626
625
  };