@unicom-cloud/ui 0.8.54 → 0.8.56

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 (429) hide show
  1. package/Affix.js +36 -36
  2. package/Alert.js +41 -45
  3. package/Anchor.js +1 -1
  4. package/AutoComplete.js +40 -40
  5. package/Avatar.js +36 -36
  6. package/BackTop.js +26 -26
  7. package/Badge.js +43 -43
  8. package/Breadcrumb.js +17 -17
  9. package/Button.js +42 -42
  10. package/Calendar.js +54 -56
  11. package/Card.js +28 -28
  12. package/Carousel.js +42 -43
  13. package/Cascader.js +1 -1
  14. package/Checkbox.js +1 -1
  15. package/Collapse.js +1 -1
  16. package/ColorPicker.js +11 -580
  17. package/Comment.js +14 -14
  18. package/ConfigProvider.js +2 -2
  19. package/Copy.js +26 -26
  20. package/DatePicker.js +661 -670
  21. package/Descriptions.js +53 -53
  22. package/Divider.js +15 -15
  23. package/Draggable.js +16 -16
  24. package/Drawer.js +1 -1
  25. package/Dropdown.js +10 -10
  26. package/Empty.js +3 -3
  27. package/Form.js +10 -1410
  28. package/Grid.js +49 -49
  29. package/Icon.js +10 -10
  30. package/IconHover.js +2 -2
  31. package/Image.js +1 -1
  32. package/Input.js +1 -1
  33. package/InputNumber.js +7 -7
  34. package/InputTag.js +1 -1
  35. package/Layout.js +34 -34
  36. package/Link.js +26 -26
  37. package/List.js +39 -39
  38. package/Mentions.js +17 -17
  39. package/Menu.js +1 -1
  40. package/Message.js +3 -3
  41. package/Modal.js +1 -1
  42. package/Notice.js +4 -10
  43. package/Notification.js +3 -3
  44. package/OverflowEllipsis.js +18 -18
  45. package/PageHeader.js +26 -27
  46. package/Pagination.js +1 -1
  47. package/Picker.js +1 -1
  48. package/Popconfirm.js +15 -15
  49. package/Popover.js +22 -22
  50. package/Progress.js +18 -18
  51. package/Radio.js +2 -2
  52. package/Rate.js +40 -43
  53. package/ResizeBox.js +191 -192
  54. package/Result.js +17 -17
  55. package/Select.js +1 -1
  56. package/SelectView.js +56 -56
  57. package/Skeleton.js +35 -35
  58. package/Slider.js +81 -81
  59. package/Space.js +27 -27
  60. package/SpeechSynthesis.js +29 -32
  61. package/Spin.js +15 -15
  62. package/Statistic.js +54 -54
  63. package/Steps.js +44 -44
  64. package/Switch.js +39 -38
  65. package/Table.js +488 -488
  66. package/Tabs.js +1 -1
  67. package/Tag.js +13 -14
  68. package/TimePicker.js +68 -68
  69. package/Timeline.js +1 -1
  70. package/Tooltip.js +27 -28
  71. package/Transfer.js +29 -30
  72. package/Tree.js +1 -1
  73. package/TreeSelect.js +1 -1
  74. package/Trigger.js +53 -52
  75. package/Typography.js +2 -737
  76. package/Upload.js +1 -1
  77. package/VerificationCode.js +1 -1
  78. package/Version.js +1 -1
  79. package/Watermark.js +1 -1
  80. package/chunk/1mEO29GP.js +23 -0
  81. package/chunk/5pZ3ayqs.js +29 -0
  82. package/chunk/9Gh1afjL.js +23 -0
  83. package/chunk/B1S1OEw6.js +29 -0
  84. package/chunk/{RRWbBHK-.js → B2Bp3i5u.js} +221 -221
  85. package/chunk/B45v5S9k.js +209 -0
  86. package/chunk/B6fn5y_s.js +23 -0
  87. package/chunk/B9PsJar0.js +118 -0
  88. package/chunk/BA02BFUV.js +41 -0
  89. package/chunk/BCk8e9fj.js +29 -0
  90. package/chunk/BHK9zpXn.js +207 -0
  91. package/chunk/BHLTzWzi.js +29 -0
  92. package/chunk/BK1FKNAX.js +41 -0
  93. package/chunk/BM6dpkeM.js +32 -0
  94. package/chunk/{DQ3uFRJD.js → BP7xX86Q.js} +223 -202
  95. package/chunk/BWx1cVT_.js +66 -0
  96. package/chunk/BbI3gqVr.js +23 -0
  97. package/chunk/{CIc4yo9k.js → BbYzi8M0.js} +46 -46
  98. package/chunk/Be7oeWU8.js +34 -0
  99. package/chunk/BeM2hfks.js +88 -0
  100. package/chunk/BkHxm4sv.js +41 -0
  101. package/chunk/{BUQBof6z.js → Bl-ODC57.js} +206 -207
  102. package/chunk/BlKc_pDZ.js +678 -0
  103. package/chunk/{BzqZZHGK.js → Bny52uiG.js} +48 -48
  104. package/chunk/{PuuHmqnW.js → BpwDupra.js} +238 -238
  105. package/chunk/BqxwlITu.js +52 -0
  106. package/chunk/BuEC_zcc.js +278 -0
  107. package/chunk/{CqcZfQQ4.js → Bv8ZRDFt.js} +80 -80
  108. package/chunk/{DZGcv_9A.js → C-w9pFY-.js} +32 -32
  109. package/chunk/C2fspJbE.js +23 -0
  110. package/chunk/C7Okdv4u.js +34 -0
  111. package/chunk/C95ipQ6b.js +41 -0
  112. package/chunk/{BzMYgxgO.js → CF3Telny.js} +26 -26
  113. package/chunk/CPl52AZh.js +206 -0
  114. package/chunk/CXNW5Y2a.js +23 -0
  115. package/chunk/Cb_oWoGj.js +40 -0
  116. package/chunk/CcX2pBUh.js +46 -0
  117. package/chunk/{BdJcAQ0Q.js → CggcswbO.js} +18 -18
  118. package/chunk/CilQ012k.js +1796 -0
  119. package/chunk/CkAOsst1.js +73 -0
  120. package/chunk/CnY8SvgY.js +126 -0
  121. package/chunk/{CTSIr-Pr.js → CwXmtKib.js} +89 -101
  122. package/chunk/{C3I_L73_.js → CwjaGytU.js} +39 -40
  123. package/chunk/{DTgc2wl4.js → D6RTBH4C.js} +36 -36
  124. package/chunk/D6mVoX-C.js +116 -0
  125. package/chunk/D9TqtOhq.js +40 -0
  126. package/chunk/{qSJXQ1qu.js → DBJ8d0o0.js} +183 -189
  127. package/chunk/{RL1SNlng.js → DDda6s72.js} +16 -16
  128. package/chunk/{BH5fVprw.js → DJmWXheU.js} +9 -9
  129. package/chunk/DPvnQJ-H.js +52 -0
  130. package/chunk/DQXq1QT0.js +58 -0
  131. package/chunk/DRJO1GfY.js +855 -0
  132. package/chunk/DUxWiN2U.js +1465 -0
  133. package/chunk/DYZzQ2uT.js +29 -0
  134. package/chunk/{CK0H_Yi4.js → DafaH1Qt.js} +140 -138
  135. package/chunk/{ShWkfsJd.js → DalIRWr7.js} +21 -21
  136. package/chunk/{CzTYWtfa.js → Dg2DmtzA.js} +31 -30
  137. package/chunk/DhLbnw3R.js +29 -0
  138. package/chunk/{BmtF7P8U.js → DkIjpuBZ.js} +170 -170
  139. package/chunk/Do1aMgY3.js +12 -0
  140. package/chunk/Dtnux4qL.js +38 -0
  141. package/chunk/{Niaq_og8.js → Dw4SJ4o1.js} +219 -225
  142. package/chunk/{DbtCtriE.js → DxNRWF67.js} +30 -31
  143. package/chunk/JnyGFb5j.js +284 -0
  144. package/chunk/Lk60-jkf.js +1098 -0
  145. package/chunk/V_IcWDFx.js +49 -0
  146. package/chunk/{DG7VgAhL.js → WkB0MERB.js} +107 -108
  147. package/chunk/bsawGxt8.js +32 -0
  148. package/chunk/cUuQh7L_.js +46 -0
  149. package/chunk/fqgc8r6C.js +29 -0
  150. package/chunk/m_kOQCiU.js +29 -0
  151. package/chunk/sl8s35SK.js +29 -0
  152. package/chunk/{Dki1RB5p.js → t51ig1FZ.js} +154 -155
  153. package/chunk/{BC0PujUD.js → yvbAFxtk.js} +119 -121
  154. package/hooks/index.js +52 -246
  155. package/hooks/useForceUpdate.js +6 -6
  156. package/hooks/useIntersectionObserver.js +12 -10
  157. package/hooks/useKeyboardEvent.js +7 -7
  158. package/hooks/useMedia.js +9 -12
  159. package/hooks/useMergeValue.js +10 -8
  160. package/hooks/useResizeObserver.js +16 -0
  161. package/hooks/useUpdateEffect.js +7 -9
  162. package/hooks/useWindowSize.js +16 -20
  163. package/icons.js +6003 -0
  164. package/index.js +377 -472
  165. package/locale/en-US.js +20 -6
  166. package/locale/ja-JP.js +4 -2
  167. package/locale/ko-KR.js +2 -2
  168. package/locale/pt-BR.js +3 -3
  169. package/locale/pt-PT.js +3 -3
  170. package/locale/tr-TR.js +11 -3
  171. package/locale/zh-CN.js +6 -0
  172. package/locale/zh-HK.js +2 -0
  173. package/locale/zh-TW.js +2 -0
  174. package/package.json +1 -1
  175. package/style.css +1 -1
  176. package/types/anchor/util.d.ts +1 -0
  177. package/types/button/index.d.ts +2 -2
  178. package/types/color-picker/colors.d.ts +1 -1
  179. package/types/date-picker/util.d.ts +1 -1
  180. package/types/hooks/index.d.ts +3 -101
  181. package/types/hooks/useForceUpdate.d.ts +1 -2
  182. package/types/hooks/useIntersectionObserver.d.ts +1 -1
  183. package/types/hooks/useKeyboardEvent.d.ts +2 -2
  184. package/types/hooks/useMergeProps.d.ts +1 -1
  185. package/types/hooks/useResizeObserver.d.ts +5 -0
  186. package/types/hooks/useUpdateEffect.d.ts +2 -3
  187. package/types/hooks/useWindowSize.d.ts +1 -1
  188. package/types/icons.d.ts +4 -0
  189. package/types/index.d.ts +12 -2
  190. package/types/locale/en-US.d.ts +4 -0
  191. package/types/locale/interface.d.ts +2 -0
  192. package/types/locale/ja-JP.d.ts +4 -0
  193. package/types/locale/zh-CN.d.ts +4 -0
  194. package/types/locale/zh-HK.d.ts +4 -0
  195. package/types/locale/zh-TW.d.ts +4 -0
  196. package/types/modal/config.d.ts +1 -1
  197. package/types/version/index.d.ts +1 -1
  198. package/utils/CSSTransition.js +1 -1
  199. package/utils/className.js +2 -3
  200. package/utils/contextHolder.js +2 -2
  201. package/utils/copy.js +2 -3
  202. package/utils/is.js +127 -90
  203. package/utils/reactDOM.js +17 -15
  204. package/utils/responsiveObserve.js +16 -16
  205. package/utils/saveAs.js +2 -3
  206. package/utils/scrollIntoView.js +1 -1
  207. package/chunk/BdYAMaw9.js +0 -6
  208. package/chunk/CiZVOdJ3.js +0 -122
  209. package/chunk/DdtfPvgk.js +0 -272
  210. package/chunk/I4RV9SKZ.js +0 -135
  211. package/chunk/TXCrI0jN.js +0 -20
  212. package/chunk/i1A7W8Qt.js +0 -277
  213. package/chunk/xPzFRQJn.js +0 -740
  214. package/hooks/useAsync.js +0 -13
  215. package/hooks/useAsyncFn.js +0 -15
  216. package/hooks/useAsyncRetry.js +0 -17
  217. package/hooks/useAudio.js +0 -5
  218. package/hooks/useBeforeUnload.js +0 -18
  219. package/hooks/useBoolean.js +0 -4
  220. package/hooks/useClickAway.js +0 -22
  221. package/hooks/useCopyToClipboard.js +0 -51
  222. package/hooks/useCounter.js +0 -45
  223. package/hooks/useCreation.js +0 -17
  224. package/hooks/useCustomCompareEffect.js +0 -15
  225. package/hooks/useDebounce.js +0 -9
  226. package/hooks/useDefault.js +0 -10
  227. package/hooks/useDrop.js +0 -44
  228. package/hooks/useDropArea.js +0 -45
  229. package/hooks/useEffectOnce.js +0 -7
  230. package/hooks/useEffectState.js +0 -9
  231. package/hooks/useEnsuredForwardedRef.js +0 -17
  232. package/hooks/useError.js +0 -13
  233. package/hooks/useEvent.js +0 -13
  234. package/hooks/useEventListener.js +0 -39
  235. package/hooks/useFavicon.js +0 -16
  236. package/hooks/useFirstMountState.js +0 -8
  237. package/hooks/useFullscreen.js +0 -39
  238. package/hooks/useGeolocation.js +0 -38
  239. package/hooks/useGetSet.js +0 -18
  240. package/hooks/useGetSetState.js +0 -12
  241. package/hooks/useHash.js +0 -26
  242. package/hooks/useHover.js +0 -16
  243. package/hooks/useHoverDirty.js +0 -17
  244. package/hooks/useIdle.js +0 -34
  245. package/hooks/useIntersection.js +0 -19
  246. package/hooks/useIsomorphicLayoutEffect2.js +0 -6
  247. package/hooks/useKey.js +0 -16
  248. package/hooks/useKeyPress.js +0 -13
  249. package/hooks/useKeyPressEvent.js +0 -11
  250. package/hooks/useLatest.js +0 -8
  251. package/hooks/useLifecycles.js +0 -9
  252. package/hooks/useList.js +0 -67
  253. package/hooks/useLocalStorage.js +0 -42
  254. package/hooks/useLocation.js +0 -51
  255. package/hooks/useLockBodyScroll.js +0 -55
  256. package/hooks/useLogger.js +0 -10
  257. package/hooks/useLongPress.js +0 -24
  258. package/hooks/useMap.js +0 -31
  259. package/hooks/useMeasure.js +0 -34
  260. package/hooks/useMeasureDirty.js +0 -24
  261. package/hooks/useMediaDevices.js +0 -26
  262. package/hooks/useMediatedState.js +0 -14
  263. package/hooks/useMethods.js +0 -14
  264. package/hooks/useMotion.js +0 -56
  265. package/hooks/useMount.js +0 -9
  266. package/hooks/useMountedState.js +0 -10
  267. package/hooks/useMouse.js +0 -44
  268. package/hooks/useMouseHovered.js +0 -9
  269. package/hooks/useMouseWheel.js +0 -14
  270. package/hooks/useMultiStateValidator.js +0 -19
  271. package/hooks/useNetworkState.js +0 -31
  272. package/hooks/useNumber.js +0 -4
  273. package/hooks/useObservable.js +0 -12
  274. package/hooks/useOrientation.js +0 -30
  275. package/hooks/usePageLeave.js +0 -19
  276. package/hooks/usePermission.js +0 -19
  277. package/hooks/usePinchZoom.js +0 -40
  278. package/hooks/usePreviousDistinct.js +0 -10
  279. package/hooks/usePromise.js +0 -19
  280. package/hooks/useQueue.js +0 -25
  281. package/hooks/useRaf.js +0 -24
  282. package/hooks/useRafLoop.js +0 -24
  283. package/hooks/useRafState.js +0 -15
  284. package/hooks/useReactive.js +0 -21
  285. package/hooks/useRendersCount.js +0 -7
  286. package/hooks/useScroll.js +0 -27
  287. package/hooks/useScrolling.js +0 -23
  288. package/hooks/useSearchParam.js +0 -18
  289. package/hooks/useSessionStorage.js +0 -29
  290. package/hooks/useSet.js +0 -15
  291. package/hooks/useSetState.js +0 -16
  292. package/hooks/useSize.js +0 -58
  293. package/hooks/useSlider.js +0 -48
  294. package/hooks/useSpeech.js +0 -45
  295. package/hooks/useStartTyping.js +0 -30
  296. package/hooks/useStateList.js +0 -37
  297. package/hooks/useStateValidator.js +0 -17
  298. package/hooks/useStateWithHistory.js +0 -46
  299. package/hooks/useSyncState.js +0 -14
  300. package/hooks/useThrottle.js +0 -21
  301. package/hooks/useThrottleFn.js +0 -21
  302. package/hooks/useTimeout.js +0 -17
  303. package/hooks/useTimeoutFn.js +0 -16
  304. package/hooks/useTitle.js +0 -18
  305. package/hooks/useToggle.js +0 -5
  306. package/hooks/useTween.js +0 -11
  307. package/hooks/useUnmount.js +0 -9
  308. package/hooks/useUnmountPromise.js +0 -20
  309. package/hooks/useUpdate.js +0 -10
  310. package/hooks/useUpdateTimeout.js +0 -9
  311. package/hooks/useUpsert.js +0 -16
  312. package/hooks/useVibrate.js +0 -21
  313. package/hooks/useVideo.js +0 -5
  314. package/hooks/useWindowScroll.js +0 -29
  315. package/types/hooks/component/UseKey.d.ts +0 -2
  316. package/types/hooks/factory/createBreakpoint.d.ts +0 -4
  317. package/types/hooks/factory/createGlobalState.d.ts +0 -7
  318. package/types/hooks/factory/createHTMLMediaHook.d.ts +0 -33
  319. package/types/hooks/factory/createMemo.d.ts +0 -2
  320. package/types/hooks/factory/createReducer.d.ts +0 -8
  321. package/types/hooks/factory/createReducerContext.d.ts +0 -5
  322. package/types/hooks/factory/createRenderProp.d.ts +0 -1
  323. package/types/hooks/factory/createRouter.d.ts +0 -7
  324. package/types/hooks/factory/createStateContext.d.ts +0 -5
  325. package/types/hooks/misc/hookState.d.ts +0 -8
  326. package/types/hooks/misc/parseTimeRanges.d.ts +0 -4
  327. package/types/hooks/misc/types.d.ts +0 -2
  328. package/types/hooks/misc/util.d.ts +0 -5
  329. package/types/hooks/useAsync.d.ts +0 -20
  330. package/types/hooks/useAsyncFn.d.ts +0 -23
  331. package/types/hooks/useAsyncRetry.d.ts +0 -27
  332. package/types/hooks/useAudio.d.ts +0 -11
  333. package/types/hooks/useBeforeUnload.d.ts +0 -2
  334. package/types/hooks/useBoolean.d.ts +0 -2
  335. package/types/hooks/useClickAway.d.ts +0 -3
  336. package/types/hooks/useCopyToClipboard.d.ts +0 -7
  337. package/types/hooks/useCounter.d.ts +0 -9
  338. package/types/hooks/useCreation.d.ts +0 -2
  339. package/types/hooks/useCustomCompareEffect.d.ts +0 -4
  340. package/types/hooks/useDebounce.d.ts +0 -3
  341. package/types/hooks/useDefault.d.ts +0 -2
  342. package/types/hooks/useDrop.d.ts +0 -17
  343. package/types/hooks/useDropArea.d.ts +0 -18
  344. package/types/hooks/useEffectOnce.d.ts +0 -3
  345. package/types/hooks/useEffectState.d.ts +0 -2
  346. package/types/hooks/useEnsuredForwardedRef.d.ts +0 -3
  347. package/types/hooks/useError.d.ts +0 -2
  348. package/types/hooks/useEvent.d.ts +0 -13
  349. package/types/hooks/useEventListener.d.ts +0 -2
  350. package/types/hooks/useFavicon.d.ts +0 -2
  351. package/types/hooks/useFirstMountState.d.ts +0 -1
  352. package/types/hooks/useFullscreen.d.ts +0 -10
  353. package/types/hooks/useGeolocation.d.ts +0 -21
  354. package/types/hooks/useGetSet.d.ts +0 -3
  355. package/types/hooks/useGetSetState.d.ts +0 -2
  356. package/types/hooks/useHash.d.ts +0 -2
  357. package/types/hooks/useHover.d.ts +0 -4
  358. package/types/hooks/useHoverDirty.d.ts +0 -3
  359. package/types/hooks/useIdle.d.ts +0 -2
  360. package/types/hooks/useIntersection.d.ts +0 -3
  361. package/types/hooks/useIsomorphicLayoutEffect2.d.ts +0 -3
  362. package/types/hooks/useKey.d.ts +0 -12
  363. package/types/hooks/useKeyPress.d.ts +0 -3
  364. package/types/hooks/useKeyPressEvent.d.ts +0 -3
  365. package/types/hooks/useLatest.d.ts +0 -4
  366. package/types/hooks/useLifecycles.d.ts +0 -2
  367. package/types/hooks/useList.d.ts +0 -18
  368. package/types/hooks/useLocalStorage.d.ts +0 -10
  369. package/types/hooks/useLocation.d.ts +0 -16
  370. package/types/hooks/useLockBodyScroll.d.ts +0 -8
  371. package/types/hooks/useLogger.d.ts +0 -2
  372. package/types/hooks/useLongPress.d.ts +0 -12
  373. package/types/hooks/useMap.d.ts +0 -11
  374. package/types/hooks/useMeasure.d.ts +0 -9
  375. package/types/hooks/useMeasureDirty.d.ts +0 -11
  376. package/types/hooks/useMediaDevices.d.ts +0 -2
  377. package/types/hooks/useMediatedState.d.ts +0 -9
  378. package/types/hooks/useMethods.d.ts +0 -8
  379. package/types/hooks/useMotion.d.ts +0 -20
  380. package/types/hooks/useMount.d.ts +0 -2
  381. package/types/hooks/useMountedState.d.ts +0 -1
  382. package/types/hooks/useMouse.d.ts +0 -13
  383. package/types/hooks/useMouseHovered.d.ts +0 -8
  384. package/types/hooks/useMouseWheel.d.ts +0 -2
  385. package/types/hooks/useMultiStateValidator.d.ts +0 -9
  386. package/types/hooks/useNetworkState.d.ts +0 -22
  387. package/types/hooks/useNumber.d.ts +0 -2
  388. package/types/hooks/useObservable.d.ts +0 -8
  389. package/types/hooks/useOrientation.d.ts +0 -6
  390. package/types/hooks/usePageLeave.d.ts +0 -2
  391. package/types/hooks/usePermission.d.ts +0 -16
  392. package/types/hooks/usePinchZoom.d.ts +0 -18
  393. package/types/hooks/usePreviousDistinct.d.ts +0 -2
  394. package/types/hooks/usePromise.d.ts +0 -3
  395. package/types/hooks/useQueue.d.ts +0 -9
  396. package/types/hooks/useRaf.d.ts +0 -2
  397. package/types/hooks/useRafLoop.d.ts +0 -2
  398. package/types/hooks/useRafState.d.ts +0 -3
  399. package/types/hooks/useReactive.d.ts +0 -2
  400. package/types/hooks/useRendersCount.d.ts +0 -1
  401. package/types/hooks/useScroll.d.ts +0 -7
  402. package/types/hooks/useScrolling.d.ts +0 -3
  403. package/types/hooks/useSearchParam.d.ts +0 -3
  404. package/types/hooks/useSessionStorage.d.ts +0 -2
  405. package/types/hooks/useSet.d.ts +0 -11
  406. package/types/hooks/useSetState.d.ts +0 -2
  407. package/types/hooks/useSize.d.ts +0 -8
  408. package/types/hooks/useSlider.d.ts +0 -15
  409. package/types/hooks/useSpeech.d.ts +0 -16
  410. package/types/hooks/useStartTyping.d.ts +0 -2
  411. package/types/hooks/useStateList.d.ts +0 -9
  412. package/types/hooks/useStateValidator.d.ts +0 -8
  413. package/types/hooks/useStateWithHistory.d.ts +0 -18
  414. package/types/hooks/useSyncState.d.ts +0 -3
  415. package/types/hooks/useThrottle.d.ts +0 -2
  416. package/types/hooks/useThrottleFn.d.ts +0 -2
  417. package/types/hooks/useTimeout.d.ts +0 -2
  418. package/types/hooks/useTimeoutFn.d.ts +0 -2
  419. package/types/hooks/useTitle.d.ts +0 -6
  420. package/types/hooks/useToggle.d.ts +0 -2
  421. package/types/hooks/useTween.d.ts +0 -3
  422. package/types/hooks/useUnmount.d.ts +0 -2
  423. package/types/hooks/useUnmountPromise.d.ts +0 -3
  424. package/types/hooks/useUpdate.d.ts +0 -2
  425. package/types/hooks/useUpdateTimeout.d.ts +0 -2
  426. package/types/hooks/useUpsert.d.ts +0 -6
  427. package/types/hooks/useVibrate.d.ts +0 -4
  428. package/types/hooks/useVideo.d.ts +0 -11
  429. package/types/hooks/useWindowScroll.d.ts +0 -6
package/ResizeBox.js CHANGED
@@ -1,66 +1,65 @@
1
- import { jsx as m, jsxs as ft } from "react/jsx-runtime";
1
+ import { jsx as g, jsxs as ut } from "react/jsx-runtime";
2
2
  import vt from "lodash/isNumber";
3
- import Bt, { useContext as ut, useRef as F, useEffect as lt, forwardRef as Ct, useState as st, useImperativeHandle as Nt } from "react";
4
- import { a as mt } from "./chunk/xPzFRQJn.js";
5
- import Yt from "./hooks/useMergeProps.js";
6
- import Tt from "./hooks/useMergeValue.js";
7
- import S from "@unicom-cloud/utils/class-name";
8
- import { on as $, off as y } from "./utils/dom.js";
9
- import zt from "./utils/omit.js";
10
- import Ft from "@unicom-cloud/icons/IconUiCaretDown";
11
- import bt from "@unicom-cloud/icons/IconUiCaretLeft";
12
- import It from "@unicom-cloud/icons/IconUiCaretRight";
13
- import kt from "@unicom-cloud/icons/IconUiCaretUp";
14
- import Ut from "@unicom-cloud/icons/IconUiDragDot";
15
- import Vt from "@unicom-cloud/icons/IconUiDragDotVertical";
3
+ import Wt, { useContext as ft, useRef as F, useEffect as lt, forwardRef as Ct, useState as ct, useImperativeHandle as zt } from "react";
4
+ import { b as gt } from "./chunk/DUxWiN2U.js";
5
+ import Bt from "./hooks/useMergeProps.js";
6
+ import It from "./hooks/useMergeValue.js";
7
+ import { y as P } from "./chunk/Do1aMgY3.js";
8
+ import { on as y, off as $ } from "./utils/dom.js";
9
+ import Mt from "./utils/omit.js";
10
+ import { I as Yt } from "./chunk/BM6dpkeM.js";
11
+ import { I as Tt, a as bt } from "./chunk/DQXq1QT0.js";
12
+ import { I as Ft } from "./chunk/bsawGxt8.js";
13
+ import { I as kt } from "./chunk/BA02BFUV.js";
14
+ import { I as Ut } from "./chunk/C95ipQ6b.js";
16
15
  import wt from "lodash/isFunction";
17
16
  import "./utils/is.js";
18
- import { isPlainObject as Pt } from "@unicom-cloud/utils/is";
19
- import _t from "./hooks/useIsomorphicLayoutEffect.js";
20
- import ct from "lodash/isPlainObject";
21
- import Lt from "lodash/isString";
17
+ import "./chunk/BeM2hfks.js";
18
+ import st from "lodash/isPlainObject";
19
+ import Vt from "./hooks/useIsomorphicLayoutEffect.js";
20
+ import _t from "lodash/isString";
22
21
  import St from "lodash/isUndefined";
23
- function Mt(r) {
22
+ function Nt(r) {
24
23
  const {
25
24
  className: ot,
26
- direction: g,
25
+ direction: m,
27
26
  icon: q,
28
27
  onMouseDown: J,
29
28
  onResize: x,
30
29
  children: K,
31
- collapsible: N = {},
30
+ collapsible: z = {},
32
31
  resizable: X = !0,
33
- renderChildren: b,
32
+ renderChildren: T,
34
33
  ...Q
35
- } = r, { getPrefixCls: rt, rtl: z } = ut(mt), d = rt("resizebox-trigger"), D = g === "horizontal", M = z && !D, T = S(
34
+ } = r, { getPrefixCls: rt, rtl: M } = ft(gt), d = rt("resizebox-trigger"), D = m === "horizontal", N = M && !D, I = P(
36
35
  d,
37
36
  `${d}-${D ? "horizontal" : "vertical"}`,
38
37
  { [`${d}-not-resizable`]: !X },
39
- { [`${d}-rtl`]: z },
38
+ { [`${d}-rtl`]: M },
40
39
  ot
41
- ), l = F(), k = M ? [/* @__PURE__ */ m(It, {}, "prev"), /* @__PURE__ */ m(bt, {}, "next")] : [/* @__PURE__ */ m(bt, {}, "prev"), /* @__PURE__ */ m(It, {}, "next")], I = Pt(N.prev) ? {
42
- ...N.prev,
43
- icon: N.prev.icon || (D ? /* @__PURE__ */ m(kt, {}) : k[0])
44
- } : {}, E = Pt(N.next) ? {
45
- ...N.next,
46
- icon: N.next.icon || (D ? /* @__PURE__ */ m(Ft, {}) : k[1])
47
- } : {}, U = () => I.icon && !I.collapsed || E.collapsed ? /* @__PURE__ */ m(
40
+ ), l = F(), k = N ? [/* @__PURE__ */ g(Tt, {}, "prev"), /* @__PURE__ */ g(bt, {}, "next")] : [/* @__PURE__ */ g(bt, {}, "prev"), /* @__PURE__ */ g(Tt, {}, "next")], b = st(z.prev) ? {
41
+ ...z.prev,
42
+ icon: z.prev.icon || (D ? /* @__PURE__ */ g(Ft, {}) : k[0])
43
+ } : {}, E = st(z.next) ? {
44
+ ...z.next,
45
+ icon: z.next.icon || (D ? /* @__PURE__ */ g(Yt, {}) : k[1])
46
+ } : {}, U = () => b.icon && !b.collapsed || E.collapsed ? /* @__PURE__ */ g(
48
47
  "span",
49
48
  {
50
- className: S(`${d}-icon`, S(`${d}-prev`)),
51
- onClick: I.onClick,
52
- children: I.icon
49
+ className: P(`${d}-icon`, P(`${d}-prev`)),
50
+ onClick: b.onClick,
51
+ children: b.icon
53
52
  }
54
- ) : /* @__PURE__ */ m("span", { className: S(`${d}-icon-empty`) }), tt = () => E.icon && !E.collapsed || I.collapsed ? /* @__PURE__ */ m(
53
+ ) : /* @__PURE__ */ g("span", { className: P(`${d}-icon-empty`) }), tt = () => E.icon && !E.collapsed || b.collapsed ? /* @__PURE__ */ g(
55
54
  "span",
56
55
  {
57
- className: S(`${d}-icon`, S(`${d}-next`)),
56
+ className: P(`${d}-icon`, P(`${d}-next`)),
58
57
  onClick: E.onClick,
59
58
  children: E.icon
60
59
  }
61
- ) : /* @__PURE__ */ m("span", { className: S(`${d}-icon-empty`) }), w = () => X ? /* @__PURE__ */ m("span", { className: `${d}-icon`, children: q || (D ? /* @__PURE__ */ m(Ut, {}) : /* @__PURE__ */ m(Vt, {})) }) : /* @__PURE__ */ m("span", { className: S(`${d}-icon-empty`) }), O = U(), f = w(), h = tt(), V = () => /* @__PURE__ */ ft("div", { className: `${d}-icon-wrapper`, children: [
60
+ ) : /* @__PURE__ */ g("span", { className: P(`${d}-icon-empty`) }), w = () => X ? /* @__PURE__ */ g("span", { className: `${d}-icon`, children: q || (D ? /* @__PURE__ */ g(kt, {}) : /* @__PURE__ */ g(Ut, {})) }) : /* @__PURE__ */ g("span", { className: P(`${d}-icon-empty`) }), O = U(), u = w(), h = tt(), V = () => /* @__PURE__ */ ut("div", { className: `${d}-icon-wrapper`, children: [
62
61
  O,
63
- f,
62
+ u,
64
63
  h
65
64
  ] });
66
65
  return X ? (lt(() => {
@@ -69,37 +68,37 @@ function Mt(r) {
69
68
  var H, _;
70
69
  l.current && ((H = i == null ? void 0 : i.unobserve) == null || H.call(i, l.current)), (_ = i == null ? void 0 : i.disconnect) == null || _.call(i), i = null;
71
70
  };
72
- }, [l.current]), /* @__PURE__ */ m(
71
+ }, [l.current]), /* @__PURE__ */ g(
73
72
  "div",
74
73
  {
75
74
  ref: l,
76
- ...zt(Q, ["style"]),
77
- className: T,
75
+ ...Mt(Q, ["style"]),
76
+ className: I,
78
77
  onMouseDown: J,
79
- children: wt(b) ? b(O, f, h) : K || V()
78
+ children: wt(T) ? T(O, u, h) : K || V()
80
79
  }
81
- )) : /* @__PURE__ */ m("div", { className: T, children: wt(b) ? b(O, f, h) : K || V() });
80
+ )) : /* @__PURE__ */ g("div", { className: I, children: wt(T) ? T(O, u, h) : K || V() });
82
81
  }
83
- const dt = "horizontal", Dt = "vertical";
84
- function Gt(r, ot) {
82
+ const dt = "horizontal", Pt = "vertical";
83
+ function Lt(r, ot) {
85
84
  const {
86
- style: g,
85
+ style: m,
87
86
  className: q,
88
87
  component: J = "div",
89
88
  direction: x = "horizontal",
90
89
  icon: K,
91
- size: N = 0.5,
90
+ size: z = 0.5,
92
91
  min: X,
93
- max: b,
92
+ max: T,
94
93
  panes: Q,
95
94
  disabled: rt,
96
- trigger: z
97
- } = r, { getPrefixCls: d, rtl: D } = ut(mt), M = d("resizebox-split"), T = x.includes(dt), l = x.includes("reverse"), k = T && D, I = !T, E = S(
98
- M,
99
- `${M}-${T ? dt : Dt}`,
100
- { [`${M}-rtl`]: D },
95
+ trigger: M
96
+ } = r, { getPrefixCls: d, rtl: D } = ft(gt), N = d("resizebox-split"), I = x.includes(dt), l = x.includes("reverse"), k = I && D, b = !I, E = P(
97
+ N,
98
+ `${N}-${I ? dt : Pt}`,
99
+ { [`${N}-rtl`]: D },
101
100
  q
102
- ), [U, tt] = Q, w = typeof N == "string", [O, f] = st(parseFloat(N)), [h, V] = st(0), i = F({
101
+ ), [U, tt] = Q, w = typeof z == "string", [O, u] = ct(parseFloat(z)), [h, V] = ct(0), i = F({
103
102
  startX: 0,
104
103
  startY: 0,
105
104
  startWidth: 0,
@@ -107,16 +106,16 @@ function Gt(r, ot) {
107
106
  startOffset: 0,
108
107
  moving: !1
109
108
  }), H = F(), _ = F([]);
110
- Nt(ot, () => H.current, []);
109
+ zt(ot, () => H.current, []);
111
110
  function L(t, e) {
112
111
  return parseFloat(t) / parseFloat(e);
113
112
  }
114
113
  function W(t, e, n, o) {
115
- const s = typeof X == "string" ? L(parseFloat(X), t) : X || 0, a = typeof b == "string" ? L(parseFloat(b), t) : b || 1;
116
- let u = l ? -1 : 1;
117
- u *= k ? -1 : 1;
118
- let A = w ? e + (o - n) * u : L(
119
- t * e + (o - n) * u,
114
+ const s = typeof X == "string" ? L(parseFloat(X), t) : X || 0, a = typeof T == "string" ? L(parseFloat(T), t) : T || 1;
115
+ let f = l ? -1 : 1;
116
+ f *= k ? -1 : 1;
117
+ let A = w ? e + (o - n) * f : L(
118
+ t * e + (o - n) * f,
120
119
  t
121
120
  );
122
121
  const nt = w ? s * t : s, B = w ? a * t : a;
@@ -124,12 +123,12 @@ function Gt(r, ot) {
124
123
  }
125
124
  function G(t) {
126
125
  var e, n, o;
127
- (e = r.onMovingStart) == null || e.call(r), i.current.moving = !0, i.current.startX = t.pageX, i.current.startY = t.pageY, i.current.startWidth = (n = H.current) == null ? void 0 : n.offsetWidth, i.current.startHeight = (o = H.current) == null ? void 0 : o.offsetHeight, i.current.startOffset = O, $(window, "mousemove", j), $(window, "touchmove", j), $(window, "mouseup", Z), $(window, "touchend", Z), $(window, "contextmenu", Z), document.body.style.cursor = I ? "row-resize" : "col-resize";
126
+ (e = r.onMovingStart) == null || e.call(r), i.current.moving = !0, i.current.startX = t.pageX, i.current.startY = t.pageY, i.current.startWidth = (n = H.current) == null ? void 0 : n.offsetWidth, i.current.startHeight = (o = H.current) == null ? void 0 : o.offsetHeight, i.current.startOffset = O, y(window, "mousemove", j), y(window, "touchmove", j), y(window, "mouseup", Z), y(window, "touchend", Z), y(window, "contextmenu", Z), document.body.style.cursor = b ? "row-resize" : "col-resize";
128
127
  }
129
128
  function j(t) {
130
129
  var e;
131
130
  if (i.current.moving) {
132
- const n = T ? W(
131
+ const n = I ? W(
133
132
  i.current.startWidth,
134
133
  i.current.startOffset,
135
134
  i.current.startX,
@@ -140,15 +139,15 @@ function Gt(r, ot) {
140
139
  i.current.startY,
141
140
  t.pageY
142
141
  );
143
- f(n), (e = r.onMoving) == null || e.call(r, t, w ? `${n}px` : n);
142
+ u(n), (e = r.onMoving) == null || e.call(r, t, w ? `${n}px` : n);
144
143
  }
145
144
  }
146
145
  function Z() {
147
146
  var t;
148
- i.current.moving = !1, y(window, "mousemove", j), y(window, "touchmove", j), y(window, "mouseup", Z), y(window, "touchend", Z), y(window, "contextmenu", Z), document.body.style.cursor = "default", (t = r.onMovingEnd) == null || t.call(r);
147
+ i.current.moving = !1, $(window, "mousemove", j), $(window, "touchmove", j), $(window, "mouseup", Z), $(window, "touchend", Z), $(window, "contextmenu", Z), document.body.style.cursor = "default", (t = r.onMovingEnd) == null || t.call(r);
149
148
  }
150
149
  function it(t) {
151
- const { contentRect: e } = t[0], n = e[I ? "height" : "width"];
150
+ const { contentRect: e } = t[0], n = e[b ? "height" : "width"];
152
151
  V(n);
153
152
  }
154
153
  function c() {
@@ -158,79 +157,79 @@ function Gt(r, ot) {
158
157
  lt(() => {
159
158
  var t;
160
159
  (t = r.onPaneResize) == null || t.call(r, _.current);
161
- }, [O, h]), _t(() => {
162
- const t = parseFloat(N);
163
- O !== t && f(t);
164
- }, [N]);
165
- const v = J, p = /* @__PURE__ */ m(
160
+ }, [O, h]), Vt(() => {
161
+ const t = parseFloat(z);
162
+ O !== t && u(t);
163
+ }, [z]);
164
+ const v = J, p = /* @__PURE__ */ g(
166
165
  "div",
167
166
  {
168
- className: S(`${M}-pane`, "first-pane"),
167
+ className: P(`${N}-pane`, "first-pane"),
169
168
  style: { flexBasis: c() },
170
169
  ref: (t) => {
171
170
  _.current[0] = t;
172
171
  },
173
172
  children: U
174
173
  }
175
- ), R = /* @__PURE__ */ m(
174
+ ), R = /* @__PURE__ */ g(
176
175
  "div",
177
176
  {
178
- className: S(`${M}-pane`, "second-pane"),
177
+ className: P(`${N}-pane`, "second-pane"),
179
178
  ref: (t) => {
180
179
  _.current[1] = t;
181
180
  },
182
181
  children: tt
183
182
  }
184
- ), P = l ? [R, p] : [p, R];
185
- return /* @__PURE__ */ ft(v, { style: g, className: E, ref: H, children: [
186
- P[0],
187
- !rt && /* @__PURE__ */ m(
188
- Mt,
183
+ ), S = l ? [R, p] : [p, R];
184
+ return /* @__PURE__ */ ut(v, { style: m, className: E, ref: H, children: [
185
+ S[0],
186
+ !rt && /* @__PURE__ */ g(
187
+ Nt,
189
188
  {
190
- className: `${M}-trigger`,
191
- direction: I ? dt : Dt,
189
+ className: `${N}-trigger`,
190
+ direction: b ? dt : Pt,
192
191
  icon: K,
193
192
  onMouseDown: G,
194
193
  onResize: it,
195
- children: z
194
+ children: M
196
195
  }
197
196
  ),
198
- P[1]
197
+ S[1]
199
198
  ] });
200
199
  }
201
- const Ht = Ct(Gt);
202
- Ht.displayName = "ResizeBoxSplit";
203
- const ht = "horizontal", Et = "vertical";
204
- function jt(r, ot) {
200
+ const Et = Ct(Lt);
201
+ Et.displayName = "ResizeBoxSplit";
202
+ const ht = "horizontal", Dt = "vertical";
203
+ function Gt(r, ot) {
205
204
  const {
206
- panes: g,
205
+ panes: m,
207
206
  style: q,
208
207
  className: J,
209
208
  component: x = "div",
210
209
  direction: K = "horizontal",
211
- icon: N,
210
+ icon: z,
212
211
  ...X
213
- } = r, { getPrefixCls: b, rtl: Q } = ut(mt), rt = 1 / g.length, z = F(), d = F(
214
- new Array(g.length).fill({
212
+ } = r, { getPrefixCls: T, rtl: Q } = ft(gt), rt = 1 / m.length, M = F(), d = F(
213
+ new Array(m.length).fill({
215
214
  moving: !1,
216
215
  startOffset: 0,
217
216
  startPosition: 0
218
217
  })
219
- ), D = F([]), M = F(0), T = F([]), [l, k] = st(
220
- new Array(g.length).fill(rt)
221
- ), [I, E] = st(!1), [U, tt] = st(
222
- new Array(g.length).fill(0)
223
- ), [w, O] = st(
224
- new Array(Math.max(g.length - 1, 0)).fill({ prev: !1, next: !1 })
225
- ), f = b("resizebox-split-group"), h = K === ht, V = h && Q, i = !h, H = S(
226
- f,
227
- `${f}-${h ? ht : Et}`,
228
- { [`${f}-moving`]: I },
229
- { [`${f}-rtl`]: Q },
218
+ ), D = F([]), N = F(0), I = F([]), [l, k] = ct(
219
+ new Array(m.length).fill(rt)
220
+ ), [b, E] = ct(!1), [U, tt] = ct(
221
+ new Array(m.length).fill(0)
222
+ ), [w, O] = ct(
223
+ new Array(Math.max(m.length - 1, 0)).fill({ prev: !1, next: !1 })
224
+ ), u = T("resizebox-split-group"), h = K === ht, V = h && Q, i = !h, H = P(
225
+ u,
226
+ `${u}-${h ? ht : Dt}`,
227
+ { [`${u}-moving`]: b },
228
+ { [`${u}-rtl`]: Q },
230
229
  J
231
230
  ), _ = x, L = () => {
232
231
  let t = [];
233
- g.forEach((s) => {
232
+ m.forEach((s) => {
234
233
  const { size: a } = s;
235
234
  St(a) ? t.push(void 0) : t.push(G(a));
236
235
  });
@@ -241,26 +240,26 @@ function jt(r, ot) {
241
240
  return `calc(${l[t] * 100}% - ${(e + n) / 2}px)`;
242
241
  };
243
242
  function G(t) {
244
- const e = h ? z.current.offsetWidth : z.current.offsetHeight;
243
+ const e = h ? M.current.offsetWidth : M.current.offsetHeight;
245
244
  if (!t || vt(t) && t < 0)
246
245
  return 0;
247
- const n = Lt(t) ? parseFloat(t) / e : t;
246
+ const n = _t(t) ? parseFloat(t) / e : t;
248
247
  return Math.min(n, 1);
249
248
  }
250
249
  const j = (t) => {
251
- const e = Math.min(t + 1, g.length - 1), n = l[t] + l[e], o = G(g[t].min) || 0;
252
- let s = G(g[t].max) || n;
253
- const a = G(g[e].min) || 0;
254
- let u = G(g[e].max) || n;
255
- return s = Math.min(n - a, s), u = Math.min(n - o, u), {
250
+ const e = Math.min(t + 1, m.length - 1), n = l[t] + l[e], o = G(m[t].min) || 0;
251
+ let s = G(m[t].max) || n;
252
+ const a = G(m[e].min) || 0;
253
+ let f = G(m[e].max) || n;
254
+ return s = Math.min(n - a, s), f = Math.min(n - o, f), {
256
255
  currentMin: o,
257
256
  currentMax: s,
258
257
  nextMin: a,
259
- nextMax: u
258
+ nextMax: f
260
259
  };
261
260
  }, Z = (t, e, n) => {
262
- const o = M.current, s = o + 1, a = [...l], u = V ? -1 : 1, et = l[o], A = l[s], nt = et + A, { currentMin: B, currentMax: C } = j(o);
263
- let Y = t + G(`${(n - e) * u}px`);
261
+ const o = N.current, s = o + 1, a = [...l], f = V ? -1 : 1, et = l[o], A = l[s], nt = et + A, { currentMin: B, currentMax: C } = j(o);
262
+ let Y = t + G(`${(n - e) * f}px`);
264
263
  return Y = Math.max(B, Y), Y = Math.min(C, Y), a[o] = Y, a[s] = nt - Y, a;
265
264
  };
266
265
  function it(t, e) {
@@ -268,8 +267,8 @@ function jt(r, ot) {
268
267
  s[e] = o, tt(s);
269
268
  }
270
269
  const c = (t) => {
271
- let e = g[t].collapsible;
272
- ct(e) || (e = e ? { prev: !0, next: !0 } : {});
270
+ let e = m[t].collapsible;
271
+ st(e) || (e = e ? { prev: !0, next: !0 } : {});
273
272
  const { prev: n, next: o } = e;
274
273
  if (!n && !o)
275
274
  return {};
@@ -280,56 +279,56 @@ function jt(r, ot) {
280
279
  };
281
280
  function v(t, e) {
282
281
  var o;
283
- (o = r.onMovingStart) == null || o.call(r, e), M.current = e;
282
+ (o = r.onMovingStart) == null || o.call(r, e), N.current = e;
284
283
  const n = d.current[e];
285
- n.moving = !0, n.startOffset = l[e], n.startPosition = h ? t.pageX : t.pageY, E(!0), $(window, "mousemove", p), $(window, "touchmove", p), $(window, "mouseup", R), $(window, "touchend", R), $(window, "contextmenu", R), document.body.style.cursor = i ? "row-resize" : "col-resize";
284
+ n.moving = !0, n.startOffset = l[e], n.startPosition = h ? t.pageX : t.pageY, E(!0), y(window, "mousemove", p), y(window, "touchmove", p), y(window, "mouseup", R), y(window, "touchend", R), y(window, "contextmenu", R), document.body.style.cursor = i ? "row-resize" : "col-resize";
286
285
  }
287
286
  function p(t) {
288
287
  var s;
289
- const e = M.current, n = d.current[e], o = h ? z.current.offsetWidth : z.current.offsetHeight;
288
+ const e = N.current, n = d.current[e], o = h ? M.current.offsetWidth : M.current.offsetHeight;
290
289
  if (n.moving) {
291
290
  const a = Z(
292
291
  n.startOffset,
293
292
  n.startPosition,
294
293
  h ? t.pageX : t.pageY
295
294
  );
296
- k(a), T.current = a, (s = r == null ? void 0 : r.onMoving) == null || s.call(
295
+ k(a), I.current = a, (s = r == null ? void 0 : r.onMoving) == null || s.call(
297
296
  r,
298
297
  t,
299
- a.map((u) => `${u * o}px`),
298
+ a.map((f) => `${f * o}px`),
300
299
  e
301
300
  );
302
301
  }
303
302
  }
304
303
  function R() {
305
304
  var e;
306
- const t = M.current;
307
- d.current[t].moving = !1, E(!1), y(window, "mousemove", p), y(window, "touchmove", p), y(window, "mouseup", R), y(window, "touchend", R), y(window, "contextmenu", R), document.body.style.cursor = "default", (e = r.onMovingEnd) == null || e.call(r, t);
305
+ const t = N.current;
306
+ d.current[t].moving = !1, E(!1), $(window, "mousemove", p), $(window, "touchmove", p), $(window, "mouseup", R), $(window, "touchend", R), $(window, "contextmenu", R), document.body.style.cursor = "default", (e = r.onMovingEnd) == null || e.call(r, t);
308
307
  }
309
- function P(t, e, n, o) {
310
- var $t, yt;
311
- const s = e + 1, a = [...l], u = l[e], et = l[s], A = u + et, nt = h ? z.current.offsetWidth : z.current.offsetHeight, { currentMin: B, nextMin: C } = j(e);
312
- let Y = T.current[e], at = T.current[s], gt = w[e][n];
313
- n === "prev" ? (et !== C || at === C) && (Y = B, at = A - B, gt = !0) : (u !== B || Y === B) && (Y = A - C, at = C, gt = !0), a[e] = Y, a[s] = at, ($t = r == null ? void 0 : r.onMoving) == null || $t.call(
308
+ function S(t, e, n, o) {
309
+ var yt, $t;
310
+ const s = e + 1, a = [...l], f = l[e], et = l[s], A = f + et, nt = h ? M.current.offsetWidth : M.current.offsetHeight, { currentMin: B, nextMin: C } = j(e);
311
+ let Y = I.current[e], at = I.current[s], mt = w[e][n];
312
+ n === "prev" ? (et !== C || at === C) && (Y = B, at = A - B, mt = !0) : (f !== B || Y === B) && (Y = A - C, at = C, mt = !0), a[e] = Y, a[s] = at, (yt = r == null ? void 0 : r.onMoving) == null || yt.call(
314
313
  r,
315
314
  t,
316
- a.map((Wt) => `${Wt * nt}px`),
315
+ a.map((Xt) => `${Xt * nt}px`),
317
316
  e
318
- ), (yt = r.onMovingEnd) == null || yt.call(r, e), k(a), wt(o) && o(t, e, n, gt);
317
+ ), ($t = r.onMovingEnd) == null || $t.call(r, e), k(a), wt(o) && o(t, e, n, mt);
319
318
  }
320
319
  return lt(() => {
321
320
  const t = L();
322
- k(t), T.current = t;
323
- }, [JSON.stringify(g.map((t) => t.size))]), Nt(ot, () => z.current, []), lt(() => {
321
+ k(t), I.current = t;
322
+ }, [JSON.stringify(m.map((t) => t.size))]), zt(ot, () => M.current, []), lt(() => {
324
323
  const t = [];
325
324
  l.forEach((e, n) => {
326
- const o = { prev: !1, next: !1 }, s = n + 1, { currentMin: a, nextMin: u } = j(n);
327
- e === a ? o.prev = !0 : l[s] === u && (o.next = !0), t.push(o);
325
+ const o = { prev: !1, next: !1 }, s = n + 1, { currentMin: a, nextMin: f } = j(n);
326
+ e === a ? o.prev = !0 : l[s] === f && (o.next = !0), t.push(o);
328
327
  }), O(t);
329
- }, [l]), /* @__PURE__ */ m(
328
+ }, [l]), /* @__PURE__ */ g(
330
329
  _,
331
330
  {
332
- ...zt(X, [
331
+ ...Mt(X, [
333
332
  "onMovingStart",
334
333
  "onPaneResize",
335
334
  "onMoving",
@@ -337,41 +336,41 @@ function jt(r, ot) {
337
336
  ]),
338
337
  style: q,
339
338
  className: H,
340
- ref: z,
341
- children: g.map((t, e) => {
339
+ ref: M,
340
+ children: m.map((t, e) => {
342
341
  const {
343
342
  content: n,
344
343
  disabled: o,
345
344
  trigger: s,
346
345
  resizable: a = !0,
347
- collapsible: u = {}
348
- } = t, { hasPrev: et, hasNext: A } = c(e), nt = ct(u) && ct(u.prev) ? u.prev : {}, B = ct(u) && ct(u.next) ? u.next : {};
349
- return /* @__PURE__ */ ft(Bt.Fragment, { children: [
350
- /* @__PURE__ */ m(
346
+ collapsible: f = {}
347
+ } = t, { hasPrev: et, hasNext: A } = c(e), nt = st(f) && st(f.prev) ? f.prev : {}, B = st(f) && st(f.next) ? f.next : {};
348
+ return /* @__PURE__ */ ut(Wt.Fragment, { children: [
349
+ /* @__PURE__ */ g(
351
350
  "div",
352
351
  {
353
- className: `${f}-pane`,
352
+ className: `${u}-pane`,
354
353
  style: { flexBasis: W(e) },
355
354
  ref: (C) => D.current[e] = C,
356
355
  children: n
357
356
  }
358
357
  ),
359
- !o && e !== g.length - 1 && /* @__PURE__ */ m(
360
- Mt,
358
+ !o && e !== m.length - 1 && /* @__PURE__ */ g(
359
+ Nt,
361
360
  {
362
- className: `${f}-trigger`,
363
- direction: i ? ht : Et,
364
- icon: N,
361
+ className: `${u}-trigger`,
362
+ direction: i ? ht : Dt,
363
+ icon: z,
365
364
  onResize: (C) => it(C, e),
366
365
  onMouseDown: (C) => v(C, e),
367
366
  collapsible: {
368
367
  prev: et ? {
369
- onClick: (C) => P(C, e, "prev", nt.onClick),
368
+ onClick: (C) => S(C, e, "prev", nt.onClick),
370
369
  icon: nt.icon,
371
370
  collapsed: w[e].prev
372
371
  } : void 0,
373
372
  next: A ? {
374
- onClick: (C) => P(C, e, "next", B.onClick),
373
+ onClick: (C) => S(C, e, "next", B.onClick),
375
374
  icon: B.icon,
376
375
  collapsed: w[e].next
377
376
  } : void 0
@@ -385,19 +384,19 @@ function jt(r, ot) {
385
384
  }
386
385
  );
387
386
  }
388
- const At = Ct(jt);
389
- At.displayName = "ResizeBoxSplitGroup";
390
- const Xt = "left", pt = "right", xt = "top", Rt = "bottom", Zt = [
391
- Xt,
387
+ const Ht = Ct(Gt);
388
+ Ht.displayName = "ResizeBoxSplitGroup";
389
+ const At = "left", pt = "right", xt = "top", Rt = "bottom", jt = [
390
+ At,
392
391
  pt,
393
392
  xt,
394
393
  Rt
395
- ], qt = {
394
+ ], Zt = {
396
395
  component: "div",
397
396
  directions: ["right"],
398
397
  resizeIcons: {},
399
398
  resizeTriggers: {}
400
- }, Jt = (r) => {
399
+ }, qt = (r) => {
401
400
  switch (r) {
402
401
  case "left":
403
402
  return "right";
@@ -407,23 +406,23 @@ const Xt = "left", pt = "right", xt = "top", Rt = "bottom", Zt = [
407
406
  return r;
408
407
  }
409
408
  };
410
- function Kt(r, ot) {
411
- const { getPrefixCls: g, componentConfig: q, rtl: J } = ut(mt), x = Yt(
409
+ function Jt(r, ot) {
410
+ const { getPrefixCls: m, componentConfig: q, rtl: J } = ft(gt), x = Bt(
412
411
  r,
413
- qt,
412
+ Zt,
414
413
  q == null ? void 0 : q.ResizeBox
415
414
  ), {
416
415
  style: K,
417
- className: N,
416
+ className: z,
418
417
  component: X,
419
- directions: b,
418
+ directions: T,
420
419
  resizeIcons: Q,
421
420
  children: rt,
422
- resizeTriggers: z,
421
+ resizeTriggers: M,
423
422
  width: d,
424
423
  height: D,
425
- ...M
426
- } = x, T = J ? b.map((c) => Jt(c)) : b, l = g("resizebox"), k = S(l, { [`${l}-rtl`]: J }, N), [I, E] = st({}), [U, tt] = Tt(void 0, { value: d }), [w, O] = Tt(void 0, { value: D }), f = F({
424
+ ...N
425
+ } = x, I = J ? T.map((c) => qt(c)) : T, l = m("resizebox"), k = P(l, { [`${l}-rtl`]: J }, z), [b, E] = ct({}), [U, tt] = It(void 0, { value: d }), [w, O] = It(void 0, { value: D }), u = F({
427
426
  startX: 0,
428
427
  startY: 0,
429
428
  startWidth: 0,
@@ -437,7 +436,7 @@ function Kt(r, ot) {
437
436
  right: 0
438
437
  }
439
438
  }), h = F();
440
- Nt(ot, () => h.current, []);
439
+ zt(ot, () => h.current, []);
441
440
  function V(c) {
442
441
  return [xt, Rt].indexOf(c) > -1;
443
442
  }
@@ -457,36 +456,36 @@ function Kt(r, ot) {
457
456
  }
458
457
  function _(c, v) {
459
458
  var e, n, o;
460
- (e = x.onMovingStart) == null || e.call(x), f.current.moving = !0, f.current.startX = v.pageX, f.current.startY = v.pageY, f.current.direction = c;
461
- const { top: p, left: R, right: P, bottom: t } = f.current.padding;
462
- f.current.startWidth = i(
459
+ (e = x.onMovingStart) == null || e.call(x), u.current.moving = !0, u.current.startX = v.pageX, u.current.startY = v.pageY, u.current.direction = c;
460
+ const { top: p, left: R, right: S, bottom: t } = u.current.padding;
461
+ u.current.startWidth = i(
463
462
  (n = h.current) == null ? void 0 : n.clientWidth,
464
- R + P
465
- ), f.current.startHeight = i(
463
+ R + S
464
+ ), u.current.startHeight = i(
466
465
  (o = h.current) == null ? void 0 : o.clientHeight,
467
466
  p + t
468
- ), $(window, "mousemove", L), $(window, "touchmove", L), $(window, "mouseup", W), $(window, "touchend", W), $(window, "contextmenu", W), H(
467
+ ), y(window, "mousemove", L), y(window, "touchmove", L), y(window, "mouseup", W), y(window, "touchend", W), y(window, "contextmenu", W), H(
469
468
  V(c) ? "row-resize" : "col-resize"
470
469
  );
471
470
  }
472
471
  function L(c) {
473
472
  var s;
474
- if (!f.current.moving) return !1;
475
- const { startX: v, startY: p, startWidth: R, startHeight: P } = f.current;
476
- let t = R, e = P;
473
+ if (!u.current.moving) return !1;
474
+ const { startX: v, startY: p, startWidth: R, startHeight: S } = u.current;
475
+ let t = R, e = S;
477
476
  const n = c.pageX - v, o = c.pageY - p;
478
- switch (f.current.direction) {
479
- case Xt:
477
+ switch (u.current.direction) {
478
+ case At:
480
479
  t = R - n, tt(t);
481
480
  break;
482
481
  case pt:
483
482
  t = R + n, tt(t);
484
483
  break;
485
484
  case xt:
486
- e = P - o, O(e);
485
+ e = S - o, O(e);
487
486
  break;
488
487
  case Rt:
489
- e = P + o, O(e);
488
+ e = S + o, O(e);
490
489
  break;
491
490
  }
492
491
  (s = x.onMoving) == null || s.call(x, c, {
@@ -496,37 +495,37 @@ function Kt(r, ot) {
496
495
  }
497
496
  function W() {
498
497
  var c;
499
- f.current.moving = !1, G(), H(), (c = x.onMovingEnd) == null || c.call(x);
498
+ u.current.moving = !1, G(), H(), (c = x.onMovingEnd) == null || c.call(x);
500
499
  }
501
500
  function G() {
502
- y(window, "mousemove", L), y(window, "touchmove", L), y(window, "mouseup", W), y(window, "touchend", W), y(window, "contextmenu", W);
501
+ $(window, "mousemove", L), $(window, "touchmove", L), $(window, "mouseup", W), $(window, "touchend", W), $(window, "contextmenu", W);
503
502
  }
504
503
  function j(c, v) {
505
- const p = V(c), { contentRect: R } = v[0], P = `${c.slice(0, 1).toUpperCase()}${c.slice(1)}`, t = R[p ? "height" : "width"];
506
- f.current.padding[c] = t, E((e) => ({
504
+ const p = V(c), { contentRect: R } = v[0], S = `${c.slice(0, 1).toUpperCase()}${c.slice(1)}`, t = R[p ? "height" : "width"];
505
+ u.current.padding[c] = t, E((e) => ({
507
506
  ...e,
508
- [`padding${P}`]: t
507
+ [`padding${S}`]: t
509
508
  }));
510
509
  }
511
510
  const Z = {
512
- ...I,
511
+ ...b,
513
512
  ...K || {},
514
513
  ...vt(U) ? { width: U } : {},
515
514
  ...vt(w) ? { height: w } : {}
516
515
  };
517
- return /* @__PURE__ */ ft(
516
+ return /* @__PURE__ */ ut(
518
517
  X,
519
518
  {
520
- ...zt(M, ["onMovingStart", "onMoving", "onMovingEnd"]),
519
+ ...Mt(N, ["onMovingStart", "onMoving", "onMovingEnd"]),
521
520
  style: Z,
522
521
  className: k,
523
522
  ref: h,
524
523
  children: [
525
524
  rt,
526
- T.map((c) => {
527
- if (Zt.indexOf(c) !== -1)
528
- return /* @__PURE__ */ m(
529
- Mt,
525
+ I.map((c) => {
526
+ if (jt.indexOf(c) !== -1)
527
+ return /* @__PURE__ */ g(
528
+ Nt,
530
529
  {
531
530
  className: `${l}-direction-${c}`,
532
531
  direction: V(c) ? "horizontal" : "vertical",
@@ -537,7 +536,7 @@ function Kt(r, ot) {
537
536
  onResize: (v) => {
538
537
  j(c, v);
539
538
  },
540
- children: z[c]
539
+ children: M[c]
541
540
  },
542
541
  c
543
542
  );
@@ -546,9 +545,9 @@ function Kt(r, ot) {
546
545
  }
547
546
  );
548
547
  }
549
- const Qt = Ct(Kt), Ot = Qt;
550
- Ot.Split = Ht;
551
- Ot.SplitGroup = At;
548
+ const Kt = Ct(Jt), Ot = Kt;
549
+ Ot.Split = Et;
550
+ Ot.SplitGroup = Ht;
552
551
  Ot.displayName = "ResizeBox";
553
552
  export {
554
553
  Ot as default