@unicom-cloud/ui 0.8.78 → 0.8.80

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 (345) hide show
  1. package/Affix.js +3 -3
  2. package/Alert.js +3 -3
  3. package/AutoComplete.js +5 -5
  4. package/BackTop.js +5 -5
  5. package/Badge.js +3 -3
  6. package/Breadcrumb.js +4 -4
  7. package/Button.js +2 -2
  8. package/Calendar.js +4 -4
  9. package/Card.js +2 -2
  10. package/Carousel.js +2 -2
  11. package/Cascader.js +1 -1
  12. package/Checkbox.js +1 -1
  13. package/Collapse.js +1 -1
  14. package/ColorPicker.js +3 -3
  15. package/Comment.js +2 -2
  16. package/ConfigProvider.js +1 -1
  17. package/Copy.js +4 -4
  18. package/DatePicker.js +1 -1
  19. package/Descriptions.js +2 -2
  20. package/Divider.js +2 -2
  21. package/Draggable.js +2 -2
  22. package/Dropdown.js +5 -5
  23. package/Empty.js +2 -2
  24. package/Icon.js +9 -5
  25. package/IconHover.js +2 -2
  26. package/Image.js +1 -1
  27. package/InputNumber.js +3 -3
  28. package/Layout.js +2 -2
  29. package/Link.js +3 -3
  30. package/List.js +4 -4
  31. package/Mentions.js +5 -5
  32. package/Menu.js +1 -1
  33. package/Message.js +3 -3
  34. package/Modal.js +1 -1
  35. package/Notice.js +9 -8
  36. package/Notification.js +3 -3
  37. package/OverflowEllipsis.js +2 -2
  38. package/PageHeader.js +3 -3
  39. package/Pagination.js +1 -1
  40. package/Popconfirm.js +3 -3
  41. package/Popover.js +3 -3
  42. package/Progress.js +2 -2
  43. package/Radio.js +1 -1
  44. package/Rate.js +3 -3
  45. package/ResizeBox.js +3 -3
  46. package/Result.js +2 -2
  47. package/Select.js +1 -1
  48. package/SelectView.js +5 -6
  49. package/Skeleton.js +2 -2
  50. package/Slider.js +4 -4
  51. package/Space.js +2 -2
  52. package/SpeechSynthesis.js +18 -20
  53. package/Spin.js +3 -3
  54. package/Statistic.js +3 -3
  55. package/Steps.js +2 -2
  56. package/Switch.js +7 -8
  57. package/Table.js +1 -1
  58. package/Tabs.js +1 -1
  59. package/Tag.js +3 -3
  60. package/Tooltip.js +3 -3
  61. package/Transfer.js +4 -4
  62. package/Tree.js +1 -1
  63. package/TreeSelect.js +1 -1
  64. package/Trigger.js +9 -10
  65. package/Typography.js +1 -1
  66. package/affix/index.js +17 -17
  67. package/alert/index.js +13 -13
  68. package/anchor/Anchor.js +40 -40
  69. package/anchor/Link.js +14 -14
  70. package/anchor/util.js +2 -2
  71. package/auto-complete/index.js +5 -5
  72. package/avatar/Avatar.js +17 -17
  73. package/avatar/Group.js +13 -13
  74. package/back-top/index.js +18 -18
  75. package/badge/Count.js +13 -13
  76. package/badge/index.js +21 -21
  77. package/breadcrumb/Item.js +25 -25
  78. package/breadcrumb/index.js +12 -12
  79. package/button/Group.js +6 -6
  80. package/button/index.js +30 -30
  81. package/calendar/Month.js +2 -2
  82. package/calendar/Year.js +1 -1
  83. package/calendar/index.js +4 -4
  84. package/card/Grid.js +13 -13
  85. package/card/Meta.js +13 -13
  86. package/card/index.js +29 -29
  87. package/carousel/Arrow.js +6 -6
  88. package/carousel/Indicator.js +27 -27
  89. package/carousel/index.js +24 -24
  90. package/cascader/Cascader.js +8 -8
  91. package/cascader/index.js +1 -1
  92. package/cascader/util.js +1 -1
  93. package/checkbox/Checkbox.js +4 -4
  94. package/checkbox/Group.js +4 -4
  95. package/checkbox/GroupBlock.js +3 -3
  96. package/checkbox/index.js +2 -2
  97. package/chunk/{ZrBrCzQX.js → B4WG1mhs.js} +6 -7
  98. package/chunk/{CjqvxJml.js → BG7YGUsx.js} +32 -32
  99. package/chunk/BYdIoY50.js +17 -0
  100. package/chunk/{Cc_-i0o_.js → BZ3igxQN.js} +6 -7
  101. package/chunk/{uEGHykhe.js → BZ9g7J4R.js} +1 -1
  102. package/chunk/BsUZRQDT.js +23 -0
  103. package/chunk/{CBgu99gQ.js → C5X4hOkx.js} +130 -130
  104. package/chunk/{B0n0iRhF.js → CCKr5jj1.js} +1 -1
  105. package/chunk/{CNcLypMY.js → CQvM33Vg.js} +190 -189
  106. package/chunk/CXPOj2uy.js +19 -0
  107. package/chunk/{DAAff-FT.js → ClM74To2.js} +9 -10
  108. package/chunk/{RS6OAxzv.js → D-ap9qEk.js} +2 -2
  109. package/chunk/{Cwm8LL5p.js → D73Vr7fa.js} +7197 -7202
  110. package/chunk/{tpmioyz1.js → DEiyXzBZ.js} +28 -28
  111. package/chunk/{CplLA01W.js → DEuVgCzp.js} +45 -52
  112. package/chunk/{BPQXH_5i.js → DYspELhF.js} +43 -43
  113. package/chunk/DxYoPlum.js +50 -0
  114. package/chunk/{BpYX5PN4.js → NPajzdOv.js} +2 -2
  115. package/chunk/{BBkdXHrJ.js → rT6qmv-Y.js} +1 -1
  116. package/chunk/{BhBEMwvI.js → uKZyjtff.js} +20 -21
  117. package/chunk/{BC5fEyWK.js → yLRv5RIK.js} +61 -61
  118. package/chunk/{C_4I3haT.js → yhU2zeeu.js} +96 -96
  119. package/collapse/Collapse.js +4 -4
  120. package/collapse/Item.js +4 -4
  121. package/collapse/index.js +1 -1
  122. package/color-picker/ControlBar.js +22 -22
  123. package/color-picker/InputAlpha.js +1 -1
  124. package/color-picker/InputHex.js +1 -1
  125. package/color-picker/InputRgb.js +1 -1
  126. package/color-picker/Palette.js +1 -1
  127. package/color-picker/Panel.js +4 -4
  128. package/color-picker/index.js +3 -3
  129. package/comment/index.js +18 -18
  130. package/config-provider/ConfigProvider.js +2 -2
  131. package/config-provider/context.js +2 -2
  132. package/config-provider/index.js +2 -2
  133. package/copy/index.js +23 -23
  134. package/date-picker/Picker.js +41 -41
  135. package/date-picker/PickerRange.js +3 -3
  136. package/date-picker/index.js +1 -1
  137. package/descriptions/index.js +28 -28
  138. package/divider/index.js +15 -15
  139. package/draggable/Item.js +11 -11
  140. package/draggable/index.js +15 -15
  141. package/drawer/Drawer.js +31 -31
  142. package/dropdown/Button.js +1 -1
  143. package/dropdown/index.js +22 -22
  144. package/empty/index.js +2 -2
  145. package/form/Control.js +46 -46
  146. package/form/Form.js +12 -12
  147. package/form/FormItem.js +12 -12
  148. package/form/FormLabel.js +11 -11
  149. package/form/context.js +7 -6
  150. package/form/promisify.js +9 -10
  151. package/form/store.js +1 -1
  152. package/form/util.js +1 -1
  153. package/grid/Col.js +38 -38
  154. package/grid/Row.js +15 -15
  155. package/grid/grid-item.js +17 -17
  156. package/grid/grid.js +28 -28
  157. package/hooks/index.js +6 -6
  158. package/hooks/useInView.js +1 -1
  159. package/hooks/useIntersectionObserver.js +1 -1
  160. package/hooks/useKeyboardEvent.js +1 -1
  161. package/hooks/useMergeValue.js +1 -1
  162. package/hooks/useOverrideRef.js +1 -1
  163. package/hooks/usePrefersColorSchemeDark.js +1 -1
  164. package/hooks/useVerificationCode.js +30 -30
  165. package/icon/index.js +20 -16
  166. package/icon-hover/index.js +2 -2
  167. package/image/Image.js +22 -22
  168. package/image/ImageFooter.js +2 -2
  169. package/image/ImagePreview.js +11 -11
  170. package/image/ImagePreviewArrow.js +16 -16
  171. package/image/ImagePreviewGroup.js +2 -2
  172. package/image/ImagePreviewToolbar.js +7 -7
  173. package/image/TriggerForToolbar.js +7 -7
  174. package/image/index.js +1 -1
  175. package/index.js +539 -572
  176. package/input/Group.js +10 -10
  177. package/input/Input.js +213 -214
  178. package/input/InputElement.js +10 -11
  179. package/input/Password.js +4 -4
  180. package/input/Search.js +3 -3
  181. package/input/Textarea.js +7 -8
  182. package/input/useComposition.js +6 -6
  183. package/input-number/index.js +3 -3
  184. package/input-tag/InputTag.js +110 -111
  185. package/layout/Content.js +4 -4
  186. package/layout/Footer.js +6 -6
  187. package/layout/Header.js +8 -8
  188. package/layout/Sider.js +29 -29
  189. package/layout/index.js +16 -16
  190. package/link/index.js +27 -27
  191. package/list/Item.js +5 -5
  192. package/list/Meta.js +11 -11
  193. package/list/index.js +4 -4
  194. package/locale/en-US.js +1 -1
  195. package/locale/tr-TR.js +1 -1
  196. package/mentions/index.js +5 -5
  197. package/menu/Item.js +11 -11
  198. package/menu/ItemGroup.js +8 -8
  199. package/menu/Menu.js +5 -5
  200. package/menu/OverflowWrap.js +2 -2
  201. package/menu/index.js +2 -2
  202. package/message/index.js +3 -3
  203. package/message/useMessage.js +1 -1
  204. package/modal/Confirm.js +2 -2
  205. package/modal/Modal.js +7 -7
  206. package/modal/index.js +1 -1
  207. package/notice/index.js +9 -8
  208. package/notification/index.js +3 -3
  209. package/notification/useNotification.js +1 -1
  210. package/overflow-ellipsis/OverflowItem.js +6 -6
  211. package/overflow-ellipsis/index.js +27 -27
  212. package/package.json +1 -1
  213. package/page-header/index.js +3 -3
  214. package/pagination/PageItem.js +7 -7
  215. package/pagination/PageJumper.js +1 -1
  216. package/pagination/PageOption.js +3 -3
  217. package/pagination/Pagination.js +4 -4
  218. package/pagination/index.js +1 -1
  219. package/picker/Input.js +7 -7
  220. package/picker/InputRange.js +77 -77
  221. package/popconfirm/index.js +11 -11
  222. package/popover/index.js +21 -21
  223. package/progress/CircleProgress.js +14 -14
  224. package/progress/LineProgess.js +14 -14
  225. package/progress/StepProgress.js +9 -9
  226. package/progress/index.js +26 -26
  227. package/radio/Group.js +4 -4
  228. package/radio/GroupBlock.js +3 -3
  229. package/radio/Radio.js +4 -4
  230. package/radio/index.js +2 -2
  231. package/rate/index.js +16 -16
  232. package/resize-box/ResizeTrigger.js +27 -28
  233. package/resize-box/Split.js +21 -21
  234. package/resize-box/SplitGroup.js +40 -40
  235. package/resize-box/index.js +23 -23
  236. package/result/index.js +29 -29
  237. package/select/Option.js +2 -2
  238. package/select/Select.js +11 -12
  239. package/select/index.js +2 -2
  240. package/select/util.js +5 -5
  241. package/select-view/Core.js +104 -106
  242. package/select-view/index.js +22 -23
  243. package/skeleton/Image.js +14 -14
  244. package/skeleton/Text.js +16 -16
  245. package/skeleton/index.js +11 -11
  246. package/slider/Button.js +4 -4
  247. package/slider/Dot.js +9 -9
  248. package/slider/Input.js +20 -20
  249. package/slider/Tick.js +14 -14
  250. package/slider/index.js +103 -103
  251. package/slider/util.js +3 -3
  252. package/space/index.js +14 -14
  253. package/speech-synthesis/index.js +26 -28
  254. package/spin/DotLoading.js +1 -1
  255. package/spin/index.js +16 -16
  256. package/statistic/Countdown.js +17 -17
  257. package/statistic/index.js +40 -40
  258. package/steps/Step.js +8 -8
  259. package/steps/index.js +17 -17
  260. package/switch/index.js +32 -33
  261. package/table/Table.js +5 -5
  262. package/table/index.js +1 -1
  263. package/tabs/Tab.js +4 -4
  264. package/tabs/TabContent.js +3 -3
  265. package/tabs/TabPane.js +11 -11
  266. package/tabs/index.js +2 -2
  267. package/tabs/util.js +1 -1
  268. package/tag/index.js +16 -16
  269. package/time-picker/Picker.js +50 -50
  270. package/time-picker/TimeColumn.js +8 -8
  271. package/time-picker/TimePicker.js +32 -32
  272. package/time-picker/util.js +5 -5
  273. package/timeline/Item.js +15 -15
  274. package/timeline/Timeline.js +24 -24
  275. package/tooltip/index.js +23 -23
  276. package/transfer/Item.js +4 -4
  277. package/transfer/List.js +4 -4
  278. package/transfer/index.js +4 -4
  279. package/tree/Animation.js +3 -3
  280. package/tree/Node.js +3 -3
  281. package/tree/NodeList.js +2 -2
  282. package/tree/Tree.js +4 -4
  283. package/tree/index.js +1 -1
  284. package/tree-select/List.js +2 -2
  285. package/tree-select/Select.js +8 -9
  286. package/tree-select/index.js +2 -2
  287. package/trigger/getPopupStyle.js +18 -19
  288. package/trigger/index.js +32 -33
  289. package/types/button/index.d.ts +2 -2
  290. package/types/color-picker/colors.d.ts +1 -1
  291. package/types/date-picker/util.d.ts +1 -1
  292. package/types/icon/index.d.ts +3 -1
  293. package/types/index.d.ts +1 -1
  294. package/types/menu/context.d.ts +1 -1
  295. package/typography/Base.js +33 -35
  296. package/typography/EditContent.js +16 -16
  297. package/typography/Ellipsis.js +25 -26
  298. package/typography/Operations.js +1 -1
  299. package/typography/Paragraph.js +8 -8
  300. package/typography/Typography.js +7 -7
  301. package/typography/index.js +1 -1
  302. package/upload/TriggerNode.js +8 -8
  303. package/upload/Upload.js +64 -65
  304. package/upload/Uploader.js +12 -12
  305. package/upload/request.js +13 -12
  306. package/upload/request_.js +5 -6
  307. package/utils/PqbCSSTransition.js +1 -1
  308. package/utils/caseName.js +4 -3
  309. package/utils/className.js +4 -3
  310. package/utils/constant.js +3 -3
  311. package/utils/contextHolder.js +1 -1
  312. package/utils/copy.js +5 -4
  313. package/utils/fileToURL.js +4 -3
  314. package/utils/index.js +262 -299
  315. package/utils/is.js +78 -115
  316. package/utils/keyboardCode.js +4 -26
  317. package/utils/math.js +10 -32
  318. package/utils/react19Adapter.js +1 -1
  319. package/utils/reactDOM.js +1 -1
  320. package/utils/saveAs.js +4 -3
  321. package/utils/screenfull.js +4 -3
  322. package/utils/scrollIntoView.js +1 -1
  323. package/utils/setDarkTheme.js +1 -1
  324. package/utils/tree.js +7 -83
  325. package/utils/tween.js +1 -1
  326. package/utils/validate.js +1 -1
  327. package/verification-code/VerificationCode.js +25 -25
  328. package/version/index.js +1 -1
  329. package/virtual-list/VirtualList.js +1 -1
  330. package/watermark/Watermark.js +8 -8
  331. package/chunk/ATwvJ8j2.js +0 -6
  332. package/chunk/BFmckYou.js +0 -25
  333. package/chunk/Bl7BnD1R.js +0 -119
  334. package/chunk/Bmvhjhzq.js +0 -24
  335. package/chunk/BrOW642m.js +0 -130
  336. package/chunk/C0pRaDCf.js +0 -96
  337. package/chunk/CBzE-PUr.js +0 -23
  338. package/chunk/CUFsOxJ2.js +0 -10
  339. package/chunk/Ce1j9KTi.js +0 -6
  340. package/chunk/D0Dlbc2g.js +0 -41
  341. package/chunk/DRTWRsgI.js +0 -34
  342. package/chunk/DeV0v__J.js +0 -20
  343. package/chunk/DohlrJ4S.js +0 -50
  344. package/chunk/XTEsYGuF.js +0 -17
  345. package/chunk/yl4BU7Sd.js +0 -1068
@@ -0,0 +1,50 @@
1
+ import { jsxs as p, jsx as o } from "react/jsx-runtime";
2
+ import g from "@unicom-cloud/icons/IconUiMore";
3
+ import n from "@unicom-cloud/utils/class-name";
4
+ import { TriggerForToolbar as F } from "../image/TriggerForToolbar.js";
5
+ function x(r) {
6
+ const { title: a, description: l, actions: t } = r, i = a || l, e = t && t.length;
7
+ return [i || e, i, e];
8
+ }
9
+ const j = (r) => {
10
+ const { style: a, className: l, title: t, description: i, actions: e, prefixCls: s, simple: m } = r, [$, N, d] = x({
11
+ title: t,
12
+ description: i,
13
+ actions: e
14
+ });
15
+ if (!$)
16
+ return null;
17
+ const c = `${s}-footer`, f = n(c, l, {
18
+ [`${c}-with-actions`]: d
19
+ }), u = () => {
20
+ const h = /* @__PURE__ */ o("div", { className: `${s}-actions-list`, children: e.map((v, w) => /* @__PURE__ */ o("div", { className: `${s}-actions-item`, children: v }, `${w}`)) });
21
+ return m ? /* @__PURE__ */ o("div", { className: `${s}-actions-list`, children: /* @__PURE__ */ o(F, { prefixCls: s, popup: () => h, children: /* @__PURE__ */ o(
22
+ "div",
23
+ {
24
+ className: n(
25
+ `${s}-actions-item`,
26
+ `${s}-actions-item-trigger`
27
+ ),
28
+ children: /* @__PURE__ */ o("span", { children: /* @__PURE__ */ o(g, {}) })
29
+ }
30
+ ) }) }) : h;
31
+ };
32
+ return /* @__PURE__ */ p("div", { className: f, style: a, children: [
33
+ N && /* @__PURE__ */ p("div", { className: n(`${c}-block`, `${s}-caption`), children: [
34
+ t && /* @__PURE__ */ o("div", { className: `${s}-caption-title`, title: t, children: t }),
35
+ i && !m && /* @__PURE__ */ o(
36
+ "div",
37
+ {
38
+ className: `${s}-caption-description`,
39
+ title: i,
40
+ children: i
41
+ }
42
+ )
43
+ ] }),
44
+ d && /* @__PURE__ */ o("div", { className: n(`${c}-block`, `${s}-actions`), children: u() })
45
+ ] });
46
+ };
47
+ export {
48
+ j as I,
49
+ x as u
50
+ };
@@ -1,8 +1,8 @@
1
1
  import { jsx as d } from "react/jsx-runtime";
2
2
  import { c as u } from "./BJ9_azwQ.js";
3
3
  import { useRef as f, useMemo as s, isValidElement as a, cloneElement as l } from "react";
4
- import { s as E } from "./DAAff-FT.js";
5
- import { f as R, c as x } from "./Cc_-i0o_.js";
4
+ import { s as E } from "./ClM74To2.js";
5
+ import { f as R, c as x } from "./BZ3igxQN.js";
6
6
  function O(r) {
7
7
  const { children: e, ...i } = r, o = f(), t = f(), c = s(() => r.nodeRef === void 0 && E(e) && a(e) ? (t.current = !0, l(e, {
8
8
  ref: (n) => {
@@ -1,4 +1,4 @@
1
- import { e } from "./Ce1j9KTi.js";
1
+ import { MATCH_MEDIA_PREFERS_COLOR_SCHEME_DARK as e } from "@unicom-cloud/utils/constant";
2
2
  import { useState as o, useEffect as s } from "react";
3
3
  function f() {
4
4
  const [r, n] = o(
@@ -1,7 +1,6 @@
1
- import "./C0pRaDCf.js";
2
- import M from "lodash/isFunction.js";
3
- import O from "lodash/isString.js";
4
- const a = (t) => (i) => Math.pow(i, t), n = (t) => (i) => 1 - Math.abs(Math.pow(i - 1, t)), r = (t) => (i) => i < 0.5 ? a(t)(i * 2) / 2 : n(t)(i * 2 - 1) / 2 + 0.5, q = (t) => t, y = a(2), b = n(2), g = r(2), F = a(3), P = n(3), k = r(3), w = a(4), T = n(4), v = r(4), A = a(5), D = n(5), S = r(5), U = (t) => 1 + Math.sin(Math.PI / 2 * t - Math.PI / 2), x = (t) => Math.sin(Math.PI / 2 * t), $ = (t) => (1 + Math.sin(Math.PI * t - Math.PI / 2)) / 2, u = (t) => t < 1 / 2.75 ? 7.5625 * t * t : t < 2 / 2.75 ? (t -= 1.5 / 2.75, 7.5625 * t * t + 0.75) : t < 2.5 / 2.75 ? (t -= 2.25 / 2.75, 7.5625 * t * t + 0.9375) : (t -= 2.625 / 2.75, 7.5625 * t * t + 0.984375), l = (t) => 1 - u(1 - t), B = (t) => t < 0.5 ? l(t * 2) * 0.5 : u(t * 2 - 1) * 0.5 + 0.5, d = {
1
+ import O from "lodash/isFunction";
2
+ import M from "lodash/isString";
3
+ const a = (t) => (i) => Math.pow(i, t), n = (t) => (i) => 1 - Math.abs(Math.pow(i - 1, t)), r = (t) => (i) => i < 0.5 ? a(t)(i * 2) / 2 : n(t)(i * 2 - 1) / 2 + 0.5, q = (t) => t, y = a(2), b = n(2), g = r(2), F = a(3), P = n(3), k = r(3), w = a(4), S = n(4), T = r(4), v = a(5), A = n(5), D = r(5), U = (t) => 1 + Math.sin(Math.PI / 2 * t - Math.PI / 2), x = (t) => Math.sin(Math.PI / 2 * t), B = (t) => (1 + Math.sin(Math.PI * t - Math.PI / 2)) / 2, u = (t) => t < 1 / 2.75 ? 7.5625 * t * t : t < 2 / 2.75 ? (t -= 1.5 / 2.75, 7.5625 * t * t + 0.75) : t < 2.5 / 2.75 ? (t -= 2.25 / 2.75, 7.5625 * t * t + 0.9375) : (t -= 2.625 / 2.75, 7.5625 * t * t + 0.984375), l = (t) => 1 - u(1 - t), $ = (t) => t < 0.5 ? l(t * 2) * 0.5 : u(t * 2 - 1) * 0.5 + 0.5, d = {
5
4
  linear: q,
6
5
  quadIn: y,
7
6
  quadOut: b,
@@ -10,19 +9,19 @@ const a = (t) => (i) => Math.pow(i, t), n = (t) => (i) => 1 - Math.abs(Math.pow(
10
9
  cubicOut: P,
11
10
  cubicInOut: k,
12
11
  quartIn: w,
13
- quartOut: T,
14
- quartInOut: v,
15
- quintIn: A,
16
- quintOut: D,
17
- quintInOut: S,
12
+ quartOut: S,
13
+ quartInOut: T,
14
+ quintIn: v,
15
+ quintOut: A,
16
+ quintInOut: D,
18
17
  sineIn: U,
19
18
  sineOut: x,
20
- sineInOut: $,
19
+ sineInOut: B,
21
20
  bounceOut: u,
22
21
  bounceIn: l,
23
- bounceInOut: B
22
+ bounceInOut: $
24
23
  };
25
- class E {
24
+ class C {
26
25
  constructor(i) {
27
26
  const {
28
27
  from: e,
@@ -31,15 +30,15 @@ class E {
31
30
  delay: c,
32
31
  easing: o,
33
32
  onStart: f,
34
- onUpdate: p,
35
- onFinish: I
33
+ onUpdate: I,
34
+ onFinish: p
36
35
  } = i;
37
36
  for (let h in e)
38
37
  s[h] === void 0 && (s[h] = e[h]);
39
38
  for (let h in s)
40
39
  e[h] === void 0 && (e[h] = s[h]);
41
- this.from = e, this.to = s, this.duration = m || 500, this.delay = c || 0, M(o) ? this.easing = o : O(o) && (this.easing = d[o]), this.easing || (this.easing = d.linear), this.onStart = f, this.onUpdate = p || function() {
42
- }, this.onFinish = I, this.startTime = Date.now() + this.delay, this.started = !1, this.finished = !1, this.timer = null, this.keys = {};
40
+ this.from = e, this.to = s, this.duration = m || 500, this.delay = c || 0, O(o) ? this.easing = o : M(o) && (this.easing = d[o]), this.easing || (this.easing = d.linear), this.onStart = f, this.onUpdate = I || function() {
41
+ }, this.onFinish = p, this.startTime = Date.now() + this.delay, this.started = !1, this.finished = !1, this.timer = null, this.keys = {};
43
42
  }
44
43
  update() {
45
44
  var i, e;
@@ -66,9 +65,9 @@ class E {
66
65
  }
67
66
  }
68
67
  export {
69
- v as b,
70
- S as f,
71
- T as q,
72
- d as x,
73
- E as y
68
+ C as I,
69
+ T as b,
70
+ D as f,
71
+ S as q,
72
+ d as x
74
73
  };
@@ -1,7 +1,7 @@
1
1
  var ht = Object.defineProperty;
2
2
  var vt = (a, t, o) => t in a ? ht(a, t, { enumerable: !0, configurable: !0, writable: !0, value: o }) : a[t] = o;
3
3
  var ye = (a, t, o) => vt(a, typeof t != "symbol" ? t + "" : t, o);
4
- import { jsx as s, jsxs as T } from "react/jsx-runtime";
4
+ import { jsx as s, jsxs as M } from "react/jsx-runtime";
5
5
  import xe from "@unicom-cloud/icons/IconUiClose";
6
6
  import bt from "@unicom-cloud/icons/IconUiCopy";
7
7
  import yt from "@unicom-cloud/icons/IconUiFullscreen";
@@ -13,27 +13,27 @@ import St from "@unicom-cloud/icons/IconUiRotateLeft";
13
13
  import wt from "@unicom-cloud/icons/IconUiRotateRight";
14
14
  import Pt from "@unicom-cloud/icons/IconUiZoomIn";
15
15
  import Lt from "@unicom-cloud/icons/IconUiZoomOut";
16
- import zt from "lodash/isUndefined";
17
- import { useState as g, forwardRef as Nt, useContext as ke, useRef as x, useMemo as Ce, useImperativeHandle as Mt, useCallback as Tt, useEffect as v } from "react";
18
- import { a as At, b as Ot } from "./CNcLypMY.js";
16
+ import Nt from "lodash/isUndefined";
17
+ import { useState as g, forwardRef as zt, useContext as ke, useRef as x, useMemo as Ce, useImperativeHandle as At, useCallback as Mt, useEffect as v } from "react";
18
+ import { a as Tt, b as Et } from "./CQvM33Vg.js";
19
19
  import "lodash/isEqualWith";
20
- import { u as Et } from "./DeV0v__J.js";
21
- import "./DAAff-FT.js";
22
- import { r as $t, d as Ut, y as Rt, n as Yt, o as Xt } from "./BrOW642m.js";
20
+ import { u as Ot } from "./CXPOj2uy.js";
21
+ import "./ClM74To2.js";
22
+ import { ArrowDown as $t, ArrowUp as Ut, ArrowLeft as Rt, ArrowRight as Yt, Esc as Dt } from "@unicom-cloud/utils/constant/keyboardCode";
23
23
  import "lodash/isNumber";
24
24
  import "lodash/merge";
25
- import { isServerRendering as Dt, on as J, off as Q } from "../utils/dom.js";
26
- import "./ZrBrCzQX.js";
25
+ import { isServerRendering as Xt, on as J, off as Q } from "../utils/dom.js";
26
+ import "./B4WG1mhs.js";
27
27
  import { u as Vt } from "./BFTV6myl.js";
28
28
  import { u as Bt } from "./DU1RCDfh.js";
29
- import { f as Ft } from "./Cc_-i0o_.js";
30
- import "./Ce1j9KTi.js";
29
+ import { f as Ft } from "./BZ3igxQN.js";
30
+ import "@unicom-cloud/utils/constant";
31
31
  import { u as Wt } from "./a3hR6zLw.js";
32
32
  import "lodash/debounce";
33
33
  import Zt from "../portal/index.js";
34
- import { P as Ie } from "./BpYX5PN4.js";
35
- import { p as Se } from "./CUFsOxJ2.js";
36
- import { p as jt } from "./D0Dlbc2g.js";
34
+ import { P as Ie } from "./NPajzdOv.js";
35
+ import Se from "@unicom-cloud/utils/class-name";
36
+ import jt from "@unicom-cloud/utils/clipboard-copy";
37
37
  import { r as Ht } from "./CIRG541s.js";
38
38
  import Gt from "../image/ImagePreviewArrow.js";
39
39
  import _t from "../image/ImagePreviewToolbar.js";
@@ -153,32 +153,32 @@ function oo(a, t) {
153
153
  setCurrentIndex: m,
154
154
  infinite: f,
155
155
  previewPropsMap: te
156
- } = ke(qt), Pe = o ? te.get(i) : {}, A = Vt(
156
+ } = ke(qt), Pe = o ? te.get(i) : {}, T = Vt(
157
157
  a,
158
158
  to,
159
159
  Pe
160
160
  ), {
161
161
  className: Le,
162
- style: ze,
163
- src: Ne,
164
- defaultVisible: Me,
165
- maskClosable: Te,
166
- closable: Ae,
167
- breakPoint: Oe,
168
- actions: Ee,
162
+ style: Ne,
163
+ src: ze,
164
+ defaultVisible: Ae,
165
+ maskClosable: Me,
166
+ closable: Te,
167
+ breakPoint: Ee,
168
+ actions: Oe,
169
169
  actionsLayout: $e,
170
170
  getPopupContainer: S,
171
- onVisibleChange: O,
172
- scales: E,
171
+ onVisibleChange: E,
172
+ scales: O,
173
173
  escToExit: oe,
174
174
  imgAttributes: Ue = {},
175
175
  imageRender: $,
176
176
  extra: Re = null,
177
177
  resetTranslate: ne
178
- } = A, w = o ? n.get(i) : Ne, [U, Ye] = g(w), [l, Xe] = Et(!1, {
179
- defaultValue: Me,
180
- value: A.visible
181
- }), re = ke(At), { getPrefixCls: De, locale: C, rtl: Ve } = re, ie = De("image"), u = `${ie}-preview`, Be = Se(
178
+ } = T, w = o ? n.get(i) : ze, [U, Ye] = g(w), [l, De] = Ot(!1, {
179
+ defaultValue: Ae,
180
+ value: T.visible
181
+ }), re = ke(Tt), { getPrefixCls: Xe, locale: C, rtl: Ve } = re, ie = Xe("image"), u = `${ie}-preview`, Be = Se(
182
182
  u,
183
183
  {
184
184
  [`${u}-hide`]: !l,
@@ -190,7 +190,7 @@ function oo(a, t) {
190
190
  pageY: 0,
191
191
  originX: 0,
192
192
  originY: 0
193
- }), { isLoading: We, isLoaded: Ze, setStatus: Y } = eo("loading"), [je, He] = g(!1), [p, X] = g({ x: 0, y: 0 }), [c, D] = g(1), [ae, ce] = g(!1), [L, V] = g(0), [h, le] = g(!1), y = Ce(() => new Qt(E), []), {
193
+ }), { isLoading: We, isLoaded: Ze, setStatus: Y } = eo("loading"), [je, He] = g(!1), [p, D] = g({ x: 0, y: 0 }), [c, X] = g(1), [ae, ce] = g(!1), [L, V] = g(0), [h, le] = g(!1), y = Ce(() => new Qt(O), []), {
194
194
  onLoad: B,
195
195
  onError: F,
196
196
  onMouseDown: W,
@@ -199,20 +199,20 @@ function oo(a, t) {
199
199
  ...qe
200
200
  } = Ue, me = !f && i <= 0, fe = !f && i >= n.size - 1;
201
201
  function Z() {
202
- X({ x: 0, y: 0 }), D(1), V(0);
202
+ D({ x: 0, y: 0 }), X(1), V(0);
203
203
  }
204
- Mt(t, () => ({
204
+ At(t, () => ({
205
205
  reset: Z,
206
206
  getRootDOMNode: () => se.current
207
207
  }));
208
- const [z, Ke] = g(), ue = Tt(() => z, [z]);
208
+ const [N, Ke] = g(), ue = Mt(() => N, [N]);
209
209
  v(() => {
210
210
  const e = S == null ? void 0 : S(), r = Ft(e) || document.body;
211
211
  Ke(r);
212
212
  }, [S]), Bt(ue, { hidden: l });
213
213
  const Je = Ce(
214
- () => !Dt && z === document.body,
215
- [z]
214
+ () => !Xt && N === document.body,
215
+ [N]
216
216
  );
217
217
  function de(e) {
218
218
  const r = n.size;
@@ -234,45 +234,45 @@ function oo(a, t) {
234
234
  !ae && ce(!0), G.current && clearTimeout(G.current), G.current = setTimeout(() => {
235
235
  ce(!1);
236
236
  }, 1e3);
237
- }, N = (e) => {
238
- c !== e && (D(e), tt());
237
+ }, z = (e) => {
238
+ c !== e && (X(e), tt());
239
239
  };
240
240
  function _() {
241
241
  const e = y.getNextScale(c, "zoomIn");
242
- N(e);
242
+ z(e);
243
243
  }
244
244
  function q() {
245
245
  const e = y.getNextScale(c, "zoomOut");
246
- N(e);
246
+ z(e);
247
247
  }
248
248
  function ot(e) {
249
249
  e.deltaY > 0 ? c >= y.minScale && q() : c <= y.maxScale && _();
250
250
  }
251
251
  function nt() {
252
- N(1);
252
+ z(1);
253
253
  }
254
254
  function rt() {
255
255
  const e = b.current.getBoundingClientRect(), r = P.current.getBoundingClientRect(), d = e.height / (r.height / c), k = e.width / (r.width / c), K = Math.max(d, k);
256
- N(K);
256
+ z(K);
257
257
  }
258
258
  function pe(e) {
259
- e.target === e.currentTarget && Te && M();
259
+ e.target === e.currentTarget && Me && A();
260
260
  }
261
261
  function it() {
262
262
  jt(U);
263
263
  }
264
264
  function ge() {
265
- M();
265
+ A();
266
266
  }
267
267
  function st(e) {
268
- M();
268
+ A();
269
269
  }
270
- function M() {
271
- l && (O == null || O(!1, l), zt(A.visible) && Xe(!1));
270
+ function A() {
271
+ l && (E == null || E(!1, l), Nt(T.visible) && De(!1));
272
272
  }
273
273
  function at(e) {
274
274
  if (e && e.length) {
275
- const d = e[0].contentRect.width < Oe;
275
+ const d = e[0].contentRect.width < Ee;
276
276
  He(d);
277
277
  }
278
278
  }
@@ -286,7 +286,7 @@ function oo(a, t) {
286
286
  p.y,
287
287
  c
288
288
  );
289
- (d !== p.x || k !== p.y) && X({
289
+ (d !== p.x || k !== p.y) && D({
290
290
  x: d,
291
291
  y: k
292
292
  });
@@ -295,7 +295,7 @@ function oo(a, t) {
295
295
  if (l && h) {
296
296
  (r = e.preventDefault) == null || r.call(e);
297
297
  const { originX: d, originY: k, pageX: K, pageY: dt } = I.current, pt = d + (e.pageX - K) / c, gt = k + (e.pageY - dt) / c;
298
- X({
298
+ D({
299
299
  x: pt,
300
300
  y: gt
301
301
  });
@@ -327,13 +327,13 @@ function oo(a, t) {
327
327
  }, [l]), v(() => {
328
328
  Ye(w), Y(w ? "loading" : "loaded"), Z();
329
329
  }, [w]), Wt(() => {
330
- y.updateScale(E), D(1);
331
- }, [E]), v(() => {
330
+ y.updateScale(O), X(1);
331
+ }, [O]), v(() => {
332
332
  const e = (r) => {
333
333
  if (r)
334
334
  switch (r.key) {
335
- case Xt.key:
336
- oe && M();
335
+ case Dt.key:
336
+ oe && A();
337
337
  break;
338
338
  case Yt.key:
339
339
  H();
@@ -452,17 +452,17 @@ function oo(a, t) {
452
452
  return ($ == null ? void 0 : $(e)) ?? e;
453
453
  };
454
454
  return /* @__PURE__ */ s(Zt, { visible: l, forceRender: !1, getContainer: ue, children: /* @__PURE__ */ s(
455
- Ot,
455
+ Et,
456
456
  {
457
457
  ...re,
458
458
  childrenName: "ImagePreview",
459
459
  getPopupContainer: () => b.current,
460
- children: /* @__PURE__ */ T(
460
+ children: /* @__PURE__ */ M(
461
461
  "div",
462
462
  {
463
463
  className: Be,
464
464
  style: {
465
- ...ze || {},
465
+ ...Ne || {},
466
466
  ...Je ? {} : { zIndex: "inherit", position: "absolute" }
467
467
  },
468
468
  ref: se,
@@ -485,14 +485,14 @@ function oo(a, t) {
485
485
  children: /* @__PURE__ */ s("div", { className: `${u}-mask`, onClick: st })
486
486
  }
487
487
  ),
488
- l && /* @__PURE__ */ T(
488
+ l && /* @__PURE__ */ M(
489
489
  "div",
490
490
  {
491
491
  ref: b,
492
492
  className: `${u}-wrapper`,
493
493
  onClick: pe,
494
494
  children: [
495
- /* @__PURE__ */ T(
495
+ /* @__PURE__ */ M(
496
496
  "div",
497
497
  {
498
498
  ref: Fe,
@@ -513,7 +513,7 @@ function oo(a, t) {
513
513
  appear: !0,
514
514
  classNames: "fadeImage",
515
515
  unmountOnExit: !0,
516
- children: /* @__PURE__ */ T("div", { className: `${u}-scale-value`, children: [
516
+ children: /* @__PURE__ */ M("div", { className: `${u}-scale-value`, children: [
517
517
  (c * 100).toFixed(0),
518
518
  "%"
519
519
  ] })
@@ -524,13 +524,13 @@ function oo(a, t) {
524
524
  {
525
525
  prefixCls: ie,
526
526
  previewPrefixCls: u,
527
- actions: Ee,
527
+ actions: Oe,
528
528
  actionsLayout: $e,
529
529
  defaultActions: ft,
530
530
  simple: je
531
531
  }
532
532
  ),
533
- Ae && /* @__PURE__ */ s(
533
+ Te && /* @__PURE__ */ s(
534
534
  "div",
535
535
  {
536
536
  className: `${u}-close-btn`,
@@ -560,7 +560,7 @@ function oo(a, t) {
560
560
  }
561
561
  ) });
562
562
  }
563
- const no = Nt(
563
+ const no = zt(
564
564
  oo
565
565
  );
566
566
  no.displayName = "ImagePreview";