@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/Slider.js CHANGED
@@ -1,22 +1,22 @@
1
1
  import { jsx as I, jsxs as ge } from "react/jsx-runtime";
2
- import { minus as pe, times as we, plus as oe, divide as Re } from "@unicom-cloud/utils/math";
2
+ import { i as pe, o as we, u as oe, d as Re } from "./chunk/Lk60-jkf.js";
3
3
  import he from "lodash/isArray";
4
- import L from "lodash/isFunction";
4
+ import E from "lodash/isFunction";
5
5
  import re from "lodash/isPlainObject";
6
- import _, { useState as Se, useContext as Ee, useMemo as Z, useRef as S, useEffect as Le, createElement as De, useCallback as H, forwardRef as st } from "react";
7
- import { a as Be } from "./chunk/xPzFRQJn.js";
6
+ import _, { useState as Se, useContext as Le, useMemo as Z, useRef as S, useEffect as Ee, createElement as De, useCallback as H, forwardRef as st } from "react";
7
+ import { b as Be } from "./chunk/DUxWiN2U.js";
8
8
  import at from "./hooks/useMergeProps.js";
9
9
  import Fe from "./hooks/useMergeValue.js";
10
10
  import ut from "./hooks/useUpdateEffect.js";
11
- import Y from "@unicom-cloud/utils/class-name";
11
+ import { y as Y } from "./chunk/Do1aMgY3.js";
12
12
  import { on as U, off as W } from "./utils/dom.js";
13
13
  import lt from "./utils/omit.js";
14
14
  import ne from "lodash/isNumber";
15
15
  import ct from "lodash/isString";
16
16
  import ft from "./hooks/useKeyboardEvent.js";
17
17
  import mt from "./Trigger.js";
18
- import { a as Te } from "./chunk/BUQBof6z.js";
19
- import { isEmptyObject as dt } from "@unicom-cloud/utils/is";
18
+ import { a as Te } from "./chunk/Bl-ODC57.js";
19
+ import { z as dt } from "./chunk/BeM2hfks.js";
20
20
  import gt from "lodash/isUndefined";
21
21
  const pt = { maxWidth: 350 }, ht = {
22
22
  enter: 300,
@@ -33,7 +33,7 @@ const pt = { maxWidth: 350 }, ht = {
33
33
  prefixCls: r,
34
34
  value: s,
35
35
  vertical: d,
36
- tooltipVisible: k,
36
+ tooltipVisible: N,
37
37
  tooltipPosition: m,
38
38
  formatTooltip: b,
39
39
  getTooltipContainer: c,
@@ -41,13 +41,13 @@ const pt = { maxWidth: 350 }, ht = {
41
41
  onMoveEnd: h,
42
42
  onMoveBegin: f
43
43
  } = e, t = ft(), [g, w] = Se(!1), [v, i] = Fe(!1, {
44
- value: k
45
- }), { getPrefixCls: u } = Ee(Be), M = Z(
44
+ value: N
45
+ }), { getPrefixCls: u } = Le(Be), M = Z(
46
46
  () => m || (d ? "right" : "top"),
47
47
  [m, d]
48
48
  ), T = S(null), K = S(!1), z = S(!1), P = S(null);
49
49
  function ae(C) {
50
- C.stopPropagation(), !n && (ie(C), w(!0), U(window, "mousemove", E), U(window, "touchmove", E), U(window, "mouseup", R), U(window, "touchend", R), U(window, "contextmenu", R));
50
+ C.stopPropagation(), !n && (ie(C), w(!0), U(window, "mousemove", L), U(window, "touchmove", L), U(window, "mouseup", R), U(window, "touchend", R), U(window, "contextmenu", R));
51
51
  }
52
52
  function O() {
53
53
  K.current = !0, J(), v || (T.current = setTimeout(() => {
@@ -62,49 +62,49 @@ const pt = { maxWidth: 350 }, ht = {
62
62
  function ie(C) {
63
63
  var B;
64
64
  C.preventDefault();
65
- const N = document.activeElement;
66
- (B = N == null ? void 0 : N.blur) == null || B.call(N), L(f) && f();
65
+ const k = document.activeElement;
66
+ (B = k == null ? void 0 : k.blur) == null || B.call(k), E(f) && f();
67
67
  }
68
- function E(C) {
69
- z.current = !0, C.type === "touchstart" && (C.clientY = C.touches[0].clientY, C.clientX = C.touches[0].clientX), L(V) && V(C.clientX, C.clientY);
68
+ function L(C) {
69
+ z.current = !0, C.type === "touchstart" && (C.clientY = C.touches[0].clientY, C.clientX = C.touches[0].clientX), E(V) && V(C.clientX, C.clientY);
70
70
  }
71
71
  function R() {
72
- z.current = !1, w(!1), ue(), j(K.current), L(h) && h();
72
+ z.current = !1, w(!1), ue(), j(K.current), E(h) && h();
73
73
  }
74
74
  function ue() {
75
- J(), W(window, "mousemove", E), W(window, "touchmove", E), W(window, "mouseup", R), W(window, "touchend", R), W(window, "contextmenu", R);
75
+ J(), W(window, "mousemove", L), W(window, "touchmove", L), W(window, "mouseup", R), W(window, "touchend", R), W(window, "contextmenu", R);
76
76
  }
77
77
  function J() {
78
78
  T.current && (clearTimeout(T.current), T.current = null);
79
79
  }
80
80
  function j(C) {
81
81
  if (z.current) return;
82
- const N = "tooltipVisible" in e ? k : C;
83
- i(N);
82
+ const k = "tooltipVisible" in e ? N : C;
83
+ i(k);
84
84
  }
85
85
  function le() {
86
86
  K.current = !0, J();
87
87
  }
88
- const x = Z(() => L(b) ? b(s) : s, [b, s]);
88
+ const x = Z(() => E(b) ? b(s) : s, [b, s]);
89
89
  function ee(C) {
90
- const N = u("tooltip");
90
+ const k = u("tooltip");
91
91
  return /* @__PURE__ */ I(
92
92
  "div",
93
93
  {
94
94
  className: Y(
95
- `${N}-content`,
96
- `${N}-content-${C}`
95
+ `${k}-content`,
96
+ `${k}-content-${C}`
97
97
  ),
98
98
  onMouseLeave: D,
99
99
  onMouseEnter: le,
100
100
  onClick: (B) => {
101
101
  B.stopPropagation();
102
102
  },
103
- children: /* @__PURE__ */ I("div", { className: `${N}-content-inner`, children: x })
103
+ children: /* @__PURE__ */ I("div", { className: `${k}-content-inner`, children: x })
104
104
  }
105
105
  );
106
106
  }
107
- return Le(() => {
107
+ return Ee(() => {
108
108
  P && P.current && P.current.updatePopupPosition();
109
109
  }, [s]), /* @__PURE__ */ I(
110
110
  mt,
@@ -117,7 +117,7 @@ const pt = { maxWidth: 350 }, ht = {
117
117
  ref: P,
118
118
  popup: () => ee(M),
119
119
  popupVisible: v,
120
- disabled: k === !1,
120
+ disabled: N === !1,
121
121
  getPopupContainer: c,
122
122
  position: M,
123
123
  childrenPrefix: u("tooltip"),
@@ -140,20 +140,20 @@ const pt = { maxWidth: 350 }, ht = {
140
140
  "aria-valuetext": ct(x) || ne(x) ? String(x) : void 0,
141
141
  ...t({
142
142
  onArrowRight: (C) => {
143
- var N;
144
- C.preventDefault(), (N = e.onArrowEvent) == null || N.call(e, "addition");
143
+ var k;
144
+ C.preventDefault(), (k = e.onArrowEvent) == null || k.call(e, "addition");
145
145
  },
146
146
  onArrowUp: (C) => {
147
- var N;
148
- C.preventDefault(), (N = e.onArrowEvent) == null || N.call(e, "addition");
147
+ var k;
148
+ C.preventDefault(), (k = e.onArrowEvent) == null || k.call(e, "addition");
149
149
  },
150
150
  onArrowLeft: (C) => {
151
- var N;
152
- C.preventDefault(), (N = e.onArrowEvent) == null || N.call(e, "subtraction");
151
+ var k;
152
+ C.preventDefault(), (k = e.onArrowEvent) == null || k.call(e, "subtraction");
153
153
  },
154
154
  onArrowDown: (C) => {
155
- var N;
156
- C.preventDefault(), (N = e.onArrowEvent) == null || N.call(e, "subtraction");
155
+ var k;
156
+ C.preventDefault(), (k = e.onArrowEvent) == null || k.call(e, "subtraction");
157
157
  }
158
158
  })
159
159
  }
@@ -193,7 +193,7 @@ function Q(e, o) {
193
193
  (r) => e >= r.begin && e <= r.end
194
194
  );
195
195
  if (n) {
196
- const { beginOffset: r, begin: s, end: d, endOffset: k } = n, m = Mt(e, [s, d]), b = pe(k, r), c = we(m, b);
196
+ const { beginOffset: r, begin: s, end: d, endOffset: N } = n, m = Mt(e, [s, d]), b = pe(N, r), c = we(m, b);
197
197
  return oe(r, c);
198
198
  }
199
199
  }
@@ -204,24 +204,24 @@ function ve(e) {
204
204
  function xt(e) {
205
205
  return e.some((o, n) => o > e[n + 1]);
206
206
  }
207
- function Nt(e, o) {
207
+ function kt(e, o) {
208
208
  let n = o.indexOf(e);
209
209
  return n === -1 ? (n = ve(o.concat(e)).indexOf(e), [
210
210
  Math.max(n - 1, 0),
211
211
  Math.min(n, o.length - 1)
212
212
  ]) : [n, n + 1];
213
213
  }
214
- const kt = function(e) {
214
+ const Nt = function(e) {
215
215
  const {
216
216
  data: o = [],
217
217
  valueRange: n = [],
218
218
  vertical: r,
219
219
  prefixCls: s,
220
220
  reverse: d,
221
- intervalConfigs: k
221
+ intervalConfigs: N
222
222
  } = e;
223
223
  return o.length ? /* @__PURE__ */ I("div", { className: `${s}-dots`, children: o.map(({ key: m, content: b }) => {
224
- const c = X(Q(+m, k));
224
+ const c = X(Q(+m, N));
225
225
  return /* @__PURE__ */ I(
226
226
  "div",
227
227
  {
@@ -230,7 +230,7 @@ const kt = function(e) {
230
230
  ...r ? { [d ? "top" : "bottom"]: c } : { [d ? "right" : "left"]: c }
231
231
  },
232
232
  onMouseDown: (V) => {
233
- V.stopPropagation(), L(e.onMouseDown) && e.onMouseDown(parseFloat(m));
233
+ V.stopPropagation(), E(e.onMouseDown) && e.onMouseDown(parseFloat(m));
234
234
  },
235
235
  children: re(b) && b.dot ? b.dot : /* @__PURE__ */ I(
236
236
  "div",
@@ -244,14 +244,14 @@ const kt = function(e) {
244
244
  m
245
245
  );
246
246
  }) }) : null;
247
- }, It = _.memo(kt), yt = function(e) {
247
+ }, It = _.memo(Nt), yt = function(e) {
248
248
  const {
249
249
  value: o,
250
250
  range: n,
251
251
  min: r,
252
252
  max: s,
253
253
  step: d,
254
- disabled: k,
254
+ disabled: N,
255
255
  prefixCls: m,
256
256
  onChange: b,
257
257
  extra: c = []
@@ -259,9 +259,9 @@ const kt = function(e) {
259
259
  min: r,
260
260
  max: s,
261
261
  step: d,
262
- disabled: k
262
+ disabled: N
263
263
  }, [h, f] = Se(o), t = c[0], g = n ? c[1] : c[0];
264
- Le(() => {
264
+ Ee(() => {
265
265
  f(o);
266
266
  }, [o]);
267
267
  const w = (i) => {
@@ -313,8 +313,8 @@ const kt = function(e) {
313
313
  );
314
314
  }, $t = _.memo(yt), Ot = function(e) {
315
315
  const { data: o = [], vertical: n, prefixCls: r, reverse: s, intervalConfigs: d } = e;
316
- return o.length ? /* @__PURE__ */ I("div", { className: `${r}-marks`, children: o.map(({ key: k, content: m }) => {
317
- const b = X(Q(+k, d));
316
+ return o.length ? /* @__PURE__ */ I("div", { className: `${r}-marks`, children: o.map(({ key: N, content: m }) => {
317
+ const b = X(Q(+N, d));
318
318
  let c = null;
319
319
  return re(m) && de(m.text) ? c = m.text : de(m) && (c = m), de(c) && /* @__PURE__ */ I(
320
320
  "div",
@@ -323,11 +323,11 @@ const kt = function(e) {
323
323
  "aria-hidden": !0,
324
324
  style: n ? { [s ? "top" : "bottom"]: b } : { [s ? "right" : "left"]: b },
325
325
  onMouseDown: (V) => {
326
- V.stopPropagation(), L(e.onMouseDown) && e.onMouseDown(parseFloat(k));
326
+ V.stopPropagation(), E(e.onMouseDown) && e.onMouseDown(parseFloat(N));
327
327
  },
328
328
  children: c
329
329
  },
330
- k
330
+ N
331
331
  );
332
332
  }) }) : null;
333
333
  }, Pt = _.memo(Ot);
@@ -338,7 +338,7 @@ function At(e) {
338
338
  valueRange: r,
339
339
  prefixCls: s,
340
340
  vertical: d,
341
- reverse: k,
341
+ reverse: N,
342
342
  intervalConfigs: m
343
343
  } = e, b = /* @__PURE__ */ new Map(), c = (h) => {
344
344
  const { step: f, begin: t, end: g } = h, w = Math.floor((g - t) / f);
@@ -361,7 +361,7 @@ function At(e) {
361
361
  className: Y(`${s}-tick`, {
362
362
  [`${s}-tick-active`]: h.isActive
363
363
  }),
364
- style: d ? { [k ? "top" : "bottom"]: h.offset } : { [k ? "right" : "left"]: h.offset }
364
+ style: d ? { [N ? "top" : "bottom"]: h.offset } : { [N ? "right" : "left"]: h.offset }
365
365
  },
366
366
  f
367
367
  )) });
@@ -378,14 +378,14 @@ function Tt(e) {
378
378
  return o;
379
379
  }
380
380
  function Rt(e) {
381
- const { marks: o = {}, getIntervalConfig: n, max: r, min: s } = e, { markIntervals: d, markList: k } = Z(() => {
381
+ const { marks: o = {}, getIntervalConfig: n, max: r, min: s } = e, { markIntervals: d, markList: N } = Z(() => {
382
382
  const b = Object.keys(o).filter((f) => ne(+f) && +f >= s && +f <= r).sort((f, t) => +f > +t ? 1 : -1), c = b.map((f) => ({ key: f, content: o[f] }));
383
383
  let V = b.map((f) => +f);
384
384
  return V.length === 0 ? V = [s, r] : (V[0] > s && (V.unshift(s), c.unshift({ key: `${s}`, content: "" })), V.slice(-1)[0] < r && (V.push(r), c.push({ key: `${r}`, content: "" }))), { markIntervals: Tt(V), markList: c };
385
385
  }, [o, s, r]);
386
386
  return {
387
387
  intervalConfigs: Z(() => {
388
- if (!L(n))
388
+ if (!E(n))
389
389
  return [
390
390
  {
391
391
  begin: s,
@@ -430,11 +430,11 @@ function Rt(e) {
430
430
  f[M] && (u.beginOffset = f[M].endOffset), u.endOffset = Math.min(1, u.beginOffset + u.width), f.push(u);
431
431
  }), f;
432
432
  }, [n, d, r, s, e.step]),
433
- markList: k
433
+ markList: N
434
434
  };
435
435
  }
436
436
  function St(e) {
437
- const { isRange: o, min: n, max: r, onlyMarkValue: s, intervalConfigs: d, marks: k } = e, m = H(
437
+ const { isRange: o, min: n, max: r, onlyMarkValue: s, intervalConfigs: d, marks: N } = e, m = H(
438
438
  (t) => {
439
439
  const g = d.find((w) => t >= w.begin && t <= w.end);
440
440
  if (g) {
@@ -448,14 +448,14 @@ function St(e) {
448
448
  [d]
449
449
  ), b = H(
450
450
  (t) => {
451
- if (!re(k) || dt(k))
451
+ if (!re(N) || dt(N))
452
452
  return console.warn("marks must be an object when onlyMarkValue is true"), n;
453
- if (k[t])
453
+ if (N[t])
454
454
  return t;
455
- const g = Object.keys(k), w = g.map((i) => Math.abs(t - parseFloat(i))), v = w.indexOf(Math.min.apply(null, w));
455
+ const g = Object.keys(N), w = g.map((i) => Math.abs(t - parseFloat(i))), v = w.indexOf(Math.min.apply(null, w));
456
456
  return parseFloat(g[v]);
457
457
  },
458
- [k, n]
458
+ [N, n]
459
459
  ), c = H(
460
460
  (t) => gt(t) || t <= n ? n : t >= r ? r : s ? b(t) : m(t),
461
461
  [b, m, r, n, s]
@@ -492,18 +492,18 @@ function St(e) {
492
492
  getNextMarkValue: f
493
493
  };
494
494
  }
495
- const Et = {
495
+ const Lt = {
496
496
  max: 100,
497
497
  min: 0,
498
498
  step: 1
499
499
  };
500
- function Lt(e, o) {
501
- const { getPrefixCls: n, componentConfig: r, rtl: s } = Ee(Be), d = at(
500
+ function Et(e, o) {
501
+ const { getPrefixCls: n, componentConfig: r, rtl: s } = Le(Be), d = at(
502
502
  e,
503
- Et,
503
+ Lt,
504
504
  r == null ? void 0 : r.Slider
505
505
  ), {
506
- className: k,
506
+ className: N,
507
507
  style: m,
508
508
  tooltipVisible: b,
509
509
  tooltipPosition: c,
@@ -527,7 +527,7 @@ function Lt(e, o) {
527
527
  step: g,
528
528
  marks: v,
529
529
  getIntervalConfig: K
530
- }), { getLegalValue: E, getLegalRangeValue: R, isLegalValue: ue, getNextMarkValue: J } = St({
530
+ }), { getLegalValue: L, getLegalRangeValue: R, isLegalValue: ue, getNextMarkValue: J } = St({
531
531
  isRange: P,
532
532
  min: h,
533
533
  max: f,
@@ -547,7 +547,7 @@ function Lt(e, o) {
547
547
  ut(() => {
548
548
  ee.current = R(j);
549
549
  }, [j, R]), C.current && (x = ve(x));
550
- const N = x[x.length - 1], B = x[0], ce = M && !i && (!P || x.length < 3), We = Z(() => ce && (he(M) || re(M)) ? he(M) ? [...M] : [{ ...M }, { ...M }] : [], [ce, M]), $ = n("slider"), be = S(null), Ve = S({
550
+ const k = x[x.length - 1], B = x[0], ce = M && !i && (!P || x.length < 3), We = Z(() => ce && (he(M) || re(M)) ? he(M) ? [...M] : [{ ...M }, { ...M }] : [], [ce, M]), $ = n("slider"), be = S(null), Ve = S({
551
551
  left: 0,
552
552
  height: 0,
553
553
  top: 0,
@@ -558,15 +558,15 @@ function Lt(e, o) {
558
558
  return P ? a : a[a.length - 1];
559
559
  }
560
560
  function Xe(l) {
561
- const a = l.map((p) => E(p));
561
+ const a = l.map((p) => L(p));
562
562
  return ee.current = a, a;
563
563
  }
564
564
  function q(l, a) {
565
565
  const p = Xe(l), y = xe(p);
566
- le(y), a === "inputValueChange" ? C.current = p.some((A, G) => A > p[G]) : C.current = !1, L(d.onChange) && d.onChange(y);
566
+ le(y), a === "inputValueChange" ? C.current = p.some((A, G) => A > p[G]) : C.current = !1, E(d.onChange) && d.onChange(y);
567
567
  }
568
568
  function se() {
569
- if (L(d.onAfterChange)) {
569
+ if (E(d.onAfterChange)) {
570
570
  const l = xe(ee.current);
571
571
  d.onAfterChange(l);
572
572
  }
@@ -613,17 +613,17 @@ function Lt(e, o) {
613
613
  };
614
614
  return "tooltipPosition" in d && (l.tooltipPosition = c), "tooltipVisible" in d && (l.tooltipVisible = b), l;
615
615
  }
616
- function Ne() {
616
+ function ke() {
617
617
  Ve.current = be.current.getBoundingClientRect();
618
618
  }
619
619
  function qe(l) {
620
- Ne();
620
+ ke();
621
621
  const a = fe(l.clientX, l.clientY);
622
- ae.draggableBar && Ye(a) ? (Ce.current = E(a), U(window, "mousemove", ke), U(window, "mouseup", Ie)) : me(a);
622
+ ae.draggableBar && Ye(a) ? (Ce.current = L(a), U(window, "mousemove", Ne), U(window, "mouseup", Ie)) : me(a);
623
623
  }
624
624
  function me(l) {
625
625
  if (V) return;
626
- const a = E(l), [p, y] = Nt(a, x), A = x[p], G = x[y], F = x.slice(0);
626
+ const a = L(l), [p, y] = kt(a, x), A = x[p], G = x[y], F = x.slice(0);
627
627
  P && G - a > a - A ? (F[p] = a, q(F, "jumpToClick")) : (F[y] = a, q(F, "jumpToClick")), se();
628
628
  }
629
629
  function Ge(l) {
@@ -642,12 +642,12 @@ function Lt(e, o) {
642
642
  const p = x.slice(0);
643
643
  p[a] = J(x[a], l), q(p);
644
644
  }
645
- function ke(l) {
646
- const p = E(fe(l.clientX, l.clientY)) - Ce.current, y = x.map((A) => A + p);
645
+ function Ne(l) {
646
+ const p = L(fe(l.clientX, l.clientY)) - Ce.current, y = x.map((A) => A + p);
647
647
  y.every((A) => ue(A)) && q(y, "mousemove");
648
648
  }
649
649
  function Ie() {
650
- W(window, "mousemove", ke), W(window, "mouseup", Ie), se();
650
+ W(window, "mousemove", Ne), W(window, "mouseup", Ie), se();
651
651
  }
652
652
  return /* @__PURE__ */ I(
653
653
  "div",
@@ -668,7 +668,7 @@ function Lt(e, o) {
668
668
  [`${$}-reverse`]: O,
669
669
  [`${$}-rtl`]: s
670
670
  },
671
- k
671
+ N
672
672
  ),
673
673
  style: m,
674
674
  ref: o,
@@ -689,7 +689,7 @@ function Lt(e, o) {
689
689
  className: `${$}-bar`,
690
690
  style: Ke([
691
691
  Q(B, D),
692
- Q(N, D)
692
+ Q(k, D)
693
693
  ])
694
694
  }
695
695
  ),
@@ -699,7 +699,7 @@ function Lt(e, o) {
699
699
  intervalConfigs: D,
700
700
  min: h,
701
701
  max: f,
702
- valueRange: [B, N],
702
+ valueRange: [B, k],
703
703
  prefixCls: $,
704
704
  vertical: u,
705
705
  reverse: O
@@ -710,7 +710,7 @@ function Lt(e, o) {
710
710
  {
711
711
  data: ie,
712
712
  intervalConfigs: D,
713
- valueRange: [B, N],
713
+ valueRange: [B, k],
714
714
  vertical: u,
715
715
  prefixCls: $,
716
716
  reverse: O,
@@ -739,7 +739,7 @@ function Lt(e, o) {
739
739
  minValue: h,
740
740
  vertical: u,
741
741
  ...Je(),
742
- onMoveBegin: Ne,
742
+ onMoveBegin: ke,
743
743
  onMoving: (p, y) => He(p, y, a),
744
744
  onMoveEnd: Qe,
745
745
  onArrowEvent: (p) => Ze(p, a)
@@ -767,7 +767,7 @@ function Lt(e, o) {
767
767
  }
768
768
  );
769
769
  }
770
- const Ue = st(Lt);
770
+ const Ue = st(Et);
771
771
  Ue.displayName = "Slider";
772
772
  const rn = _.memo(Ue);
773
773
  export {
package/Space.js CHANGED
@@ -1,23 +1,23 @@
1
- import { jsx as d, jsxs as z } from "react/jsx-runtime";
2
- import A from "lodash/isArray";
3
- import M from "lodash/isNumber";
4
- import P, { forwardRef as b, useContext as j, Fragment as k } from "react";
5
- import { a as F } from "./chunk/xPzFRQJn.js";
1
+ import { jsx as d, jsxs as b } from "react/jsx-runtime";
2
+ import z from "lodash/isArray";
3
+ import A from "lodash/isNumber";
4
+ import M, { forwardRef as P, useContext as j, Fragment as k } from "react";
5
+ import { b as F } from "./chunk/DUxWiN2U.js";
6
6
  import D from "./hooks/useMergeProps.js";
7
- import E from "@unicom-cloud/utils/class-name";
7
+ import { y as E } from "./chunk/Do1aMgY3.js";
8
8
  import { isFragment as H } from "react-is";
9
- function h(c) {
10
- let s = [];
11
- return P.Children.forEach(c, (e) => {
12
- H(e) && e.props ? s = s.concat(h(e.props.children)) : e != null && s.push(e);
13
- }), s;
9
+ function v(c) {
10
+ let i = [];
11
+ return M.Children.forEach(c, (e) => {
12
+ H(e) && e.props ? i = i.concat(v(e.props.children)) : e != null && i.push(e);
13
+ }), i;
14
14
  }
15
15
  const O = {
16
16
  size: "small",
17
17
  direction: "horizontal"
18
18
  };
19
- function q(c, s) {
20
- const { getPrefixCls: e, componentConfig: l, rtl: $ } = j(F), v = D(
19
+ function q(c, i) {
20
+ const { getPrefixCls: e, componentConfig: l, rtl: y } = j(F), N = D(
21
21
  c,
22
22
  O,
23
23
  l == null ? void 0 : l.Space
@@ -25,24 +25,24 @@ function q(c, s) {
25
25
  className: C,
26
26
  style: S,
27
27
  children: x,
28
- size: i,
28
+ size: s,
29
29
  direction: m,
30
30
  align: w,
31
31
  wrap: p,
32
32
  split: f,
33
33
  ...B
34
- } = v, n = e("space"), y = w || (m === "horizontal" ? "center" : ""), L = E(
34
+ } = N, n = e("space"), $ = w || (m === "horizontal" ? "center" : ""), L = E(
35
35
  n,
36
36
  {
37
37
  [`${n}-${m}`]: m,
38
- [`${n}-align-${y}`]: y,
38
+ [`${n}-align-${$}`]: $,
39
39
  [`${n}-wrap`]: p,
40
- [`${n}-rtl`]: $
40
+ [`${n}-rtl`]: y
41
41
  },
42
42
  C
43
43
  );
44
44
  function u(r) {
45
- if (M(r))
45
+ if (A(r))
46
46
  return r;
47
47
  switch (r) {
48
48
  case "mini":
@@ -57,11 +57,11 @@ function q(c, s) {
57
57
  return 8;
58
58
  }
59
59
  }
60
- const N = h(x);
60
+ const h = v(x);
61
61
  function R(r) {
62
- const o = N.length === r + 1, a = $ ? "marginLeft" : "marginRight";
63
- if (typeof i == "string" || typeof i == "number") {
64
- const t = u(i);
62
+ const o = h.length === r + 1, a = y ? "marginLeft" : "marginRight";
63
+ if (typeof s == "string" || typeof s == "number") {
64
+ const t = u(s);
65
65
  return p ? o ? { marginBottom: t } : {
66
66
  [`${a}`]: t,
67
67
  marginBottom: t
@@ -69,23 +69,23 @@ function q(c, s) {
69
69
  [m === "vertical" ? "marginBottom" : a]: t
70
70
  };
71
71
  }
72
- if (A(i)) {
73
- const t = u(i[0]), g = u(i[1]);
72
+ if (z(s)) {
73
+ const t = u(s[0]), g = u(s[1]);
74
74
  return p ? o ? { marginBottom: g } : {
75
75
  [`${a}`]: t,
76
76
  marginBottom: g
77
77
  } : m === "vertical" ? { marginBottom: g } : { [`${a}`]: t };
78
78
  }
79
79
  }
80
- return /* @__PURE__ */ d("div", { ref: s, className: L, style: S, ...B, children: N.map((r, o) => {
80
+ return /* @__PURE__ */ d("div", { ref: i, className: L, style: S, ...B, children: h.map((r, o) => {
81
81
  const a = (r == null ? void 0 : r.key) || o, t = f != null && o > 0;
82
- return /* @__PURE__ */ z(k, { children: [
82
+ return /* @__PURE__ */ b(k, { children: [
83
83
  t && /* @__PURE__ */ d("div", { className: `${n}-item-split`, children: f }),
84
84
  /* @__PURE__ */ d("div", { className: `${n}-item`, style: R(o), children: r })
85
85
  ] }, a);
86
86
  }) });
87
87
  }
88
- const G = b(q);
88
+ const G = P(q);
89
89
  G.displayName = "Space";
90
90
  export {
91
91
  G as default
@@ -1,59 +1,56 @@
1
- import { jsx as s } from "react/jsx-runtime";
1
+ import { jsx as c } from "react/jsx-runtime";
2
2
  import "./chunk/l0sNRNKZ.js";
3
- import S from "@unicom-cloud/icons/IconUiMute";
4
- import d from "@unicom-cloud/icons/IconUiPauseCircleFill";
5
- import k from "@unicom-cloud/icons/IconUiPlayCircleFill";
6
- import p from "@unicom-cloud/icons/IconUiSound";
7
- import { useState as w, useEffect as y } from "react";
3
+ import { I as m, a as d, b as k, c as w } from "./chunk/B9PsJar0.js";
4
+ import { useState as y, useEffect as p } from "react";
8
5
  import C from "./Button.js";
9
- function j(t) {
10
- const { useButton: m = !0 } = t ?? {}, [r, c] = w(!1);
11
- function u() {
6
+ function g(t) {
7
+ const { useButton: h = !0 } = t ?? {}, [a, s] = y(!1);
8
+ function r() {
12
9
  var n, e;
13
10
  (e = (n = window.speechSynthesis) == null ? void 0 : n.cancel) == null || e.call(n);
14
11
  }
15
- function h() {
16
- var o, i, f;
17
- let n = ((o = t.getText) == null ? void 0 : o.call(t)) || t.text, e = new SpeechSynthesisUtterance(n);
12
+ function S() {
13
+ var i, o, f;
14
+ let n = ((i = t.getText) == null ? void 0 : i.call(t)) || t.text, e = new SpeechSynthesisUtterance(n);
18
15
  e.onstart = function() {
19
- c(!0);
16
+ s(!0);
20
17
  }, e.onerror = () => {
21
- c(!1);
18
+ s(!1);
22
19
  }, e.onmark = () => {
23
20
  }, e.onpause = () => {
24
- c(!1);
21
+ s(!1);
25
22
  }, e.onresume = () => {
26
- c(!0);
23
+ s(!0);
27
24
  }, e.onboundary = () => {
28
25
  }, e.onend = () => {
29
- c(!1);
30
- }, (f = (i = window.speechSynthesis) == null ? void 0 : i.speak) == null || f.call(i, e);
26
+ s(!1);
27
+ }, (f = (o = window.speechSynthesis) == null ? void 0 : o.speak) == null || f.call(o, e);
31
28
  }
32
- function a(n) {
33
- var e, o;
34
- u(), r || h(), (o = (e = t.buttonProps) == null ? void 0 : e.onClick) == null || o.call(e, n);
29
+ function u(n) {
30
+ var e, i;
31
+ r(), a || S(), (i = (e = t.buttonProps) == null ? void 0 : e.onClick) == null || i.call(e, n);
35
32
  }
36
33
  let l;
37
34
  if (window.speechSynthesis && window.SpeechSynthesisUtterance)
38
- if (m) {
39
- let { label: n, text: e, children: o, ...i } = t.buttonProps ?? {};
40
- l = /* @__PURE__ */ s(
35
+ if (h) {
36
+ let { label: n, text: e, children: i, ...o } = t.buttonProps ?? {};
37
+ l = /* @__PURE__ */ c(
41
38
  C,
42
39
  {
43
40
  type: "text",
44
41
  size: "mini",
45
- icon: r ? /* @__PURE__ */ s(S, {}) : /* @__PURE__ */ s(p, {}),
46
- ...i,
47
- onClick: a,
48
- children: n || e || o
42
+ icon: a ? /* @__PURE__ */ c(m, {}) : /* @__PURE__ */ c(d, {}),
43
+ ...o,
44
+ onClick: u,
45
+ children: n || e || i
49
46
  }
50
47
  );
51
48
  } else
52
- l = /* @__PURE__ */ s(r ? d : k, { ...t.iconProps, onClick: a });
53
- return y(() => () => {
54
- u();
49
+ l = /* @__PURE__ */ c(a ? k : w, { ...t.iconProps, onClick: u });
50
+ return p(() => () => {
51
+ r();
55
52
  }, []), l;
56
53
  }
57
54
  export {
58
- j as default
55
+ g as default
59
56
  };