@unicom-cloud/ui 0.8.81 → 0.8.83

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 (280) hide show
  1. package/Affix.js +1 -1
  2. package/Alert.js +1 -1
  3. package/AutoComplete.js +2 -2
  4. package/BackTop.js +2 -2
  5. package/Badge.js +1 -1
  6. package/Breadcrumb.js +2 -2
  7. package/Button.js +1 -1
  8. package/Calendar.js +2 -2
  9. package/Card.js +1 -1
  10. package/Carousel.js +1 -1
  11. package/Cascader.js +1 -1
  12. package/Checkbox.js +1 -1
  13. package/Collapse.js +1 -1
  14. package/ColorPicker.js +2 -2
  15. package/Comment.js +1 -1
  16. package/ConfigProvider.js +5 -4
  17. package/Copy.js +1 -1
  18. package/DatePicker.js +7 -7
  19. package/Descriptions.js +1 -1
  20. package/Divider.js +1 -1
  21. package/Draggable.js +1 -1
  22. package/Dropdown.js +1 -1
  23. package/Empty.js +1 -1
  24. package/Icon.js +1 -1
  25. package/IconHover.js +1 -1
  26. package/Image.js +1 -1
  27. package/Input.js +11 -10
  28. package/InputNumber.js +1 -1
  29. package/Layout.js +1 -1
  30. package/Link.js +1 -1
  31. package/List.js +2 -2
  32. package/Mentions.js +2 -2
  33. package/Menu.js +1 -1
  34. package/Message.js +1 -1
  35. package/Modal.js +1 -1
  36. package/Notice.js +1 -1
  37. package/Notification.js +5 -5
  38. package/OverflowEllipsis.js +1 -1
  39. package/PageHeader.js +1 -1
  40. package/Pagination.js +1 -1
  41. package/Popconfirm.js +1 -1
  42. package/Popover.js +1 -1
  43. package/Progress.js +1 -1
  44. package/Radio.js +1 -1
  45. package/Rate.js +1 -1
  46. package/ResizeBox.js +1 -1
  47. package/Result.js +1 -1
  48. package/Select.js +1 -1
  49. package/Skeleton.js +1 -1
  50. package/Slider.js +1 -1
  51. package/Space.js +1 -1
  52. package/SpeechSynthesis.js +1 -1
  53. package/Spin.js +1 -1
  54. package/Statistic.js +2 -2
  55. package/Steps.js +1 -1
  56. package/Switch.js +1 -1
  57. package/Table.js +1 -1
  58. package/Tabs.js +1 -1
  59. package/Tag.js +1 -1
  60. package/Tooltip.js +1 -1
  61. package/Transfer.js +2 -2
  62. package/Tree.js +1 -1
  63. package/TreeSelect.js +1 -1
  64. package/Trigger.js +1 -1
  65. package/Typography.js +1 -1
  66. package/affix/index.js +60 -57
  67. package/alert/index.js +53 -53
  68. package/anchor/Anchor.js +72 -72
  69. package/anchor/Link.js +27 -27
  70. package/anchor/util.js +1 -1
  71. package/auto-complete/index.js +2 -2
  72. package/avatar/Avatar.js +31 -31
  73. package/avatar/Group.js +25 -25
  74. package/back-top/index.js +30 -30
  75. package/badge/index.js +37 -37
  76. package/breadcrumb/index.js +26 -26
  77. package/button/Group.js +7 -7
  78. package/button/index.js +29 -29
  79. package/calendar/index.js +2 -2
  80. package/card/Grid.js +12 -12
  81. package/card/Meta.js +17 -17
  82. package/card/index.js +44 -44
  83. package/carousel/Arrow.js +19 -19
  84. package/carousel/Indicator.js +25 -25
  85. package/carousel/index.js +77 -77
  86. package/cascader/Cascader.js +2 -2
  87. package/cascader/index.js +1 -1
  88. package/cascader/util.js +1 -1
  89. package/checkbox/Checkbox.js +2 -2
  90. package/checkbox/Group.js +2 -2
  91. package/checkbox/GroupBlock.js +2 -2
  92. package/checkbox/index.js +2 -2
  93. package/chunk/B6r8jPCd.js +6 -0
  94. package/chunk/{DLBfXSnU.js → BmulTYLW.js} +2880 -2878
  95. package/chunk/C9oo3EJI.js +692 -0
  96. package/chunk/{C5X4hOkx.js → CVSWh4ZZ.js} +80 -80
  97. package/chunk/DILUZgXW.js +1464 -0
  98. package/chunk/DSRHFFrc.js +53 -0
  99. package/chunk/{yLRv5RIK.js → DdJVL_4g.js} +181 -181
  100. package/chunk/{DYspELhF.js → DlHiTTJO.js} +223 -223
  101. package/chunk/{BG7YGUsx.js → R-uQJib2.js} +119 -119
  102. package/chunk/{DEiyXzBZ.js → ev6oHWqY.js} +63 -63
  103. package/chunk/{BNevupAU.js → uKZyjtff.js} +5 -4
  104. package/collapse/Collapse.js +2 -2
  105. package/collapse/Item.js +2 -2
  106. package/collapse/index.js +1 -1
  107. package/color-picker/ControlBar.js +36 -36
  108. package/color-picker/InputAlpha.js +11 -11
  109. package/color-picker/InputHex.js +24 -24
  110. package/color-picker/InputRgb.js +23 -23
  111. package/color-picker/Palette.js +18 -18
  112. package/color-picker/Panel.js +2 -2
  113. package/color-picker/index.js +2 -2
  114. package/comment/index.js +31 -31
  115. package/config-provider/ConfigProvider.js +5 -3
  116. package/config-provider/context.js +2 -2
  117. package/config-provider/index.js +4 -3
  118. package/copy/index.js +28 -28
  119. package/date-picker/Picker.js +276 -276
  120. package/date-picker/{PickerRange.js → RangePicker.js} +2 -2
  121. package/date-picker/index.js +26 -27
  122. package/descriptions/index.js +33 -33
  123. package/divider/index.js +12 -12
  124. package/draggable/index.js +23 -23
  125. package/drawer/Drawer.js +81 -81
  126. package/dropdown/Button.js +1 -1
  127. package/dropdown/index.js +56 -56
  128. package/empty/index.js +1 -1
  129. package/form/Form.js +76 -76
  130. package/form/FormItem.js +64 -64
  131. package/form/context.js +1 -1
  132. package/grid/Col.js +53 -53
  133. package/grid/Row.js +34 -34
  134. package/grid/grid-item.js +29 -29
  135. package/grid/grid.js +50 -50
  136. package/icon/index.js +20 -19
  137. package/icon-hover/index.js +1 -1
  138. package/image/Image.js +86 -86
  139. package/image/ImagePreview.js +2 -2
  140. package/image/ImagePreviewArrow.js +22 -22
  141. package/image/ImagePreviewGroup.js +1 -1
  142. package/image/index.js +1 -1
  143. package/index.js +498 -493
  144. package/input/Button.js +11 -0
  145. package/input/Group.js +8 -8
  146. package/input/Input.js +488 -434
  147. package/input/InputElement.js +1 -1
  148. package/input/Password.js +1 -1
  149. package/input/Search.js +1 -1
  150. package/input/Textarea.js +1 -1
  151. package/input/index.js +9 -8
  152. package/input-number/index.js +1 -1
  153. package/input-tag/InputTag.js +40 -40
  154. package/layout/Content.js +7 -7
  155. package/layout/Footer.js +9 -9
  156. package/layout/Header.js +7 -7
  157. package/layout/Sider.js +55 -55
  158. package/layout/index.js +32 -32
  159. package/link/index.js +35 -35
  160. package/list/Item.js +29 -29
  161. package/list/Meta.js +12 -12
  162. package/list/index.js +2 -2
  163. package/mentions/index.js +2 -2
  164. package/menu/Menu.js +2 -2
  165. package/menu/OverflowWrap.js +1 -1
  166. package/menu/index.js +2 -2
  167. package/message/index.js +1 -1
  168. package/message/useMessage.js +1 -1
  169. package/modal/Confirm.js +2 -2
  170. package/modal/Modal.js +2 -2
  171. package/modal/index.js +1 -1
  172. package/notice/index.js +1 -1
  173. package/notification/index.js +5 -5
  174. package/notification/useNotification.js +1 -1
  175. package/overflow-ellipsis/OverflowItem.js +12 -12
  176. package/overflow-ellipsis/index.js +24 -24
  177. package/package.json +1 -1
  178. package/page-header/index.js +38 -38
  179. package/pagination/PageItem.js +16 -16
  180. package/pagination/PageJumper.js +1 -1
  181. package/pagination/PageOption.js +2 -2
  182. package/pagination/Pagination.js +2 -2
  183. package/pagination/index.js +1 -1
  184. package/picker/Input.js +69 -69
  185. package/picker/InputRange.js +111 -111
  186. package/popconfirm/index.js +61 -61
  187. package/popover/index.js +35 -35
  188. package/progress/index.js +22 -22
  189. package/radio/Group.js +2 -2
  190. package/radio/GroupBlock.js +2 -2
  191. package/radio/Radio.js +2 -2
  192. package/radio/index.js +2 -2
  193. package/rate/index.js +49 -49
  194. package/resize-box/ResizeTrigger.js +34 -34
  195. package/resize-box/Split.js +56 -56
  196. package/resize-box/SplitGroup.js +55 -55
  197. package/resize-box/index.js +51 -51
  198. package/result/index.js +41 -41
  199. package/select/Option.js +1 -1
  200. package/select/Select.js +2 -2
  201. package/select/index.js +2 -2
  202. package/select/util.js +1 -1
  203. package/select-view/Core.js +125 -125
  204. package/skeleton/index.js +20 -20
  205. package/slider/Button.js +57 -57
  206. package/slider/index.js +116 -116
  207. package/space/index.js +46 -44
  208. package/speech-synthesis/index.js +1 -1
  209. package/spin/DotLoading.js +10 -10
  210. package/spin/index.js +44 -44
  211. package/statistic/Countdown.js +34 -34
  212. package/statistic/index.js +67 -67
  213. package/steps/index.js +55 -55
  214. package/style.css +1 -1
  215. package/switch/index.js +54 -54
  216. package/table/Table.js +3 -3
  217. package/table/index.js +1 -1
  218. package/tabs/Tab.js +2 -2
  219. package/tabs/TabContent.js +2 -2
  220. package/tabs/TabPane.js +12 -12
  221. package/tabs/index.js +2 -2
  222. package/tag/index.js +45 -45
  223. package/time-picker/Picker.js +76 -76
  224. package/time-picker/TimePicker.js +136 -136
  225. package/time-picker/index.js +8 -8
  226. package/time-picker/util.js +5 -5
  227. package/timeline/Item.js +47 -47
  228. package/timeline/Timeline.js +41 -41
  229. package/tooltip/index.js +29 -29
  230. package/transfer/Item.js +2 -2
  231. package/transfer/List.js +2 -2
  232. package/transfer/index.js +2 -2
  233. package/tree/Animation.js +2 -2
  234. package/tree/Node.js +2 -2
  235. package/tree/NodeList.js +1 -1
  236. package/tree/Tree.js +2 -2
  237. package/tree/index.js +1 -1
  238. package/tree-select/List.js +1 -1
  239. package/tree-select/Select.js +2 -2
  240. package/tree-select/index.js +2 -2
  241. package/trigger/index.js +60 -60
  242. package/types/config-provider/ConfigProvider.d.ts +2 -2
  243. package/types/config-provider/context.d.ts +1 -1
  244. package/types/date-picker/index.d.ts +8 -9
  245. package/types/date-picker/interface.d.ts +9 -9
  246. package/types/index.d.ts +2 -2
  247. package/types/input/Button.d.ts +5 -0
  248. package/types/input/Input.d.ts +4 -1
  249. package/types/input/interface.d.ts +7 -0
  250. package/types/picker/Input.d.ts +2 -2
  251. package/types/space/index.d.ts +2 -1
  252. package/types/utils/index.d.ts +1 -0
  253. package/types/utils/names.d.ts +1 -1
  254. package/types/utils/setTheme.d.ts +2 -0
  255. package/typography/Base.js +53 -53
  256. package/typography/Ellipsis.js +10 -8
  257. package/typography/Operations.js +28 -28
  258. package/typography/Paragraph.js +8 -8
  259. package/typography/Typography.js +7 -7
  260. package/typography/index.js +1 -1
  261. package/upload/TriggerNode.js +47 -47
  262. package/upload/Upload.js +184 -184
  263. package/upload/request.js +1 -1
  264. package/upload/request_.js +1 -1
  265. package/utils/constant.js +1 -1
  266. package/utils/contextHolder.js +3 -3
  267. package/utils/dom.js +1 -1
  268. package/utils/index.js +116 -114
  269. package/utils/names.js +1 -1
  270. package/utils/setDarkTheme.js +23 -22
  271. package/utils/setPrimaryColor.js +22 -16
  272. package/utils/setTheme.js +9 -0
  273. package/utils/tween.js +1 -1
  274. package/verification-code/VerificationCode.js +49 -49
  275. package/version/index.js +1 -1
  276. package/watermark/Watermark.js +24 -24
  277. package/chunk/CQvM33Vg.js +0 -724
  278. package/chunk/D0ZWT7db.js +0 -5
  279. package/chunk/yhU2zeeu.js +0 -1461
  280. /package/types/date-picker/{PickerRange.d.ts → RangePicker.d.ts} +0 -0
@@ -2,7 +2,7 @@ import { jsx as u, jsxs as ee } from "react/jsx-runtime";
2
2
  import fe from "lodash/isFunction";
3
3
  import ke from "lodash/isPlainObject";
4
4
  import te, { useContext as ie, useRef as V, useState as we, useEffect as L, useMemo as ae, useCallback as at, useImperativeHandle as ct } from "react";
5
- import { a as Oe, I as me } from "./CQvM33Vg.js";
5
+ import { a as Oe, I as me } from "./C9oo3EJI.js";
6
6
  import { u as st } from "./B4YRLi8r.js";
7
7
  import { u as lt } from "./BFTV6myl.js";
8
8
  import { u as dt } from "./CXPOj2uy.js";
@@ -19,7 +19,7 @@ import { setTransformStyle as pt } from "../utils/style.js";
19
19
  import Ye from "@unicom-cloud/icons/IconUiDown";
20
20
  import je from "lodash/isNull";
21
21
  import bt from "../dropdown/index.js";
22
- import { M as Ae } from "./C5X4hOkx.js";
22
+ import { M as Ae } from "./CVSWh4ZZ.js";
23
23
  import gt from "lodash/isEqualWith";
24
24
  import vt from "../utils/throttleByRaf.js";
25
25
  import Me from "@unicom-cloud/icons/IconUiLeft";
@@ -30,14 +30,14 @@ import { Enter as Tt } from "@unicom-cloud/utils/constant/keyboardCode";
30
30
  function wt(e) {
31
31
  const {
32
32
  animation: s,
33
- activeTab: a,
33
+ activeTab: o,
34
34
  prefixCls: n,
35
- paneChildren: o,
35
+ paneChildren: i,
36
36
  direction: b,
37
37
  lazyload: t,
38
38
  destroyOnHide: v
39
- } = e, g = o.findIndex((c) => c.key === a), m = ie(Pe), { rtl: w } = ie(Oe);
40
- if (o.every((c) => (c == null ? void 0 : c.props) && (!("children" in c.props) || c.props.children === null)))
39
+ } = e, g = i.findIndex((c) => c.key === o), m = ie(Ne), { rtl: w } = ie(Oe);
40
+ if (i.every((c) => (c == null ? void 0 : c.props) && (!("children" in c.props) || c.props.children === null)))
41
41
  return null;
42
42
  const l = X(`${n}-content-inner`, {
43
43
  [`${n}-animation`]: s
@@ -47,22 +47,22 @@ function wt(e) {
47
47
  {
48
48
  className: l,
49
49
  style: w ? { marginRight: `-${g * 100}%` } : { marginLeft: `-${g * 100}%` },
50
- children: o.map((c, x) => {
51
- const { tabpane: h, tab: p } = m.getIdPrefix(x), d = "destroyOnHide" in c.props ? c.props.destroyOnHide : v, i = c.key === a;
50
+ children: i.map((c, x) => {
51
+ const { tabpane: h, tab: p } = m.getIdPrefix(x), d = "destroyOnHide" in c.props ? c.props.destroyOnHide : v, a = c.key === o;
52
52
  return /* @__PURE__ */ u(
53
53
  "div",
54
54
  {
55
55
  className: X(`${n}-content-item`, {
56
- [`${n}-content-item-active`]: i
56
+ [`${n}-content-item-active`]: a
57
57
  }),
58
58
  role: "tabpanel",
59
59
  id: h,
60
- "aria-hidden": i ? void 0 : !0,
61
- tabIndex: i ? 0 : -1,
60
+ "aria-hidden": a ? void 0 : !0,
61
+ tabIndex: a ? 0 : -1,
62
62
  "aria-labelledby": p,
63
63
  children: g !== x && d ? null : te.cloneElement(c, {
64
64
  lazyload: t,
65
- isActive: i
65
+ isActive: a
66
66
  })
67
67
  },
68
68
  c.key
@@ -72,60 +72,60 @@ function wt(e) {
72
72
  ) });
73
73
  }
74
74
  function oe() {
75
- const e = V(), [s, a] = we({
75
+ const e = V(), [s, o] = we({
76
76
  height: 0,
77
77
  width: 0
78
78
  });
79
79
  return L(() => {
80
- e.current && a({
80
+ e.current && o({
81
81
  height: e.current.offsetHeight,
82
82
  width: e.current.offsetWidth,
83
83
  domRect: e.current.getBoundingClientRect()
84
84
  });
85
- }, []), [e, s, a];
85
+ }, []), [e, s, o];
86
86
  }
87
87
  function xt(e) {
88
88
  const {
89
89
  headerWrapperRef: s,
90
- headerOffset: a,
90
+ headerOffset: o,
91
91
  align: n,
92
- isScrollable: o,
92
+ isScrollable: i,
93
93
  direction: b,
94
94
  onScroll: t
95
95
  } = e;
96
- function v(d, i) {
96
+ function v(d, a) {
97
97
  let $ = 0;
98
- b === "vertical" ? $ = a + i : $ = n === "left" ? a + d : a - d, t == null || t($);
98
+ b === "vertical" ? $ = o + a : $ = n === "left" ? o + d : o - d, t == null || t($);
99
99
  }
100
100
  const g = V("x");
101
101
  function m(d) {
102
- if (!o)
102
+ if (!i)
103
103
  return;
104
104
  d.preventDefault();
105
- const { deltaX: i, deltaY: $ } = d;
106
- let N = 0;
107
- const I = Math.abs(i), S = Math.abs($);
108
- I === S ? N = g.current === "x" ? i : $ : I > S ? (N = i, g.current = "x") : (N = $, g.current = "y"), v(N, N);
105
+ const { deltaX: a, deltaY: $ } = d;
106
+ let P = 0;
107
+ const I = Math.abs(a), S = Math.abs($);
108
+ I === S ? P = g.current === "x" ? a : $ : I > S ? (P = a, g.current = "x") : (P = $, g.current = "y"), v(P, P);
109
109
  }
110
110
  const w = V({
111
111
  clientX: 0,
112
112
  clientY: 0
113
113
  }), l = (d) => d && d.touches && d.touches.length && d.touches[0], c = (d) => {
114
114
  d.cancelable && d.preventDefault();
115
- const i = l(d);
116
- if (!i)
115
+ const a = l(d);
116
+ if (!a)
117
117
  return;
118
- const { clientX: $, clientY: N } = w.current, I = i.clientX - $, S = i.clientY - N;
118
+ const { clientX: $, clientY: P } = w.current, I = a.clientX - $, S = a.clientY - P;
119
119
  v(-I, -S);
120
120
  }, x = () => {
121
121
  We(document.documentElement, "touchmove", c), We(document.documentElement, "touchend", x);
122
122
  }, h = (d) => {
123
- if (!o)
123
+ if (!i)
124
124
  return;
125
- const i = l(d);
126
- i && (w.current = {
127
- clientX: i.clientX,
128
- clientY: i.clientY
125
+ const a = l(d);
126
+ a && (w.current = {
127
+ clientX: a.clientX,
128
+ clientY: a.clientY
129
129
  }, le(document.documentElement, "touchmove", c, { passive: !1 }), le(window, "touchend", x, { passive: !1 }));
130
130
  }, p = V(null);
131
131
  p.current = { onWheel: m, onTouchStart: h }, L(() => {
@@ -149,20 +149,20 @@ function xt(e) {
149
149
  function kt(e) {
150
150
  const {
151
151
  prefixCls: s,
152
- currentOffset: a,
152
+ currentOffset: o,
153
153
  headerSize: n,
154
- headerWrapperSize: o,
154
+ headerWrapperSize: i,
155
155
  getTitleRef: b,
156
156
  paneChildren: t,
157
157
  direction: v,
158
158
  icon: g
159
- } = e, m = t.map((h) => h.key), w = v === "vertical" ? n.height : n.width, l = v === "vertical" ? o.height : o.width, c = ae(() => {
160
- const h = {}, p = o.domRect;
159
+ } = e, m = t.map((h) => h.key), w = v === "vertical" ? n.height : n.width, l = v === "vertical" ? i.height : i.width, c = ae(() => {
160
+ const h = {}, p = i.domRect;
161
161
  return m.map((d) => {
162
- const i = b(d);
163
- if (!i)
162
+ const a = b(d);
163
+ if (!a)
164
164
  return;
165
- const $ = i.getBoundingClientRect();
165
+ const $ = a.getBoundingClientRect();
166
166
  h[d] = {
167
167
  left: $.left - p.left,
168
168
  right: $.left - p.left + $.width,
@@ -173,14 +173,14 @@ function kt(e) {
173
173
  }, [m.join(","), w, l]), x = ae(() => {
174
174
  let h = -1, p = -1;
175
175
  for (const d in c) {
176
- const { left: i, right: $ } = c[d];
177
- if (i >= a && $ - a <= l && h === -1 && (h = m.indexOf(d), p = h), i >= a && $ - a > l) {
176
+ const { left: a, right: $ } = c[d];
177
+ if (a >= o && $ - o <= l && h === -1 && (h = m.indexOf(d), p = h), a >= o && $ - o > l) {
178
178
  p = m.indexOf(d);
179
179
  break;
180
180
  }
181
181
  }
182
182
  return [h, p];
183
- }, [c, m.join(","), a]);
183
+ }, [c, m.join(","), o]);
184
184
  return je(g) ? null : /* @__PURE__ */ u(
185
185
  bt,
186
186
  {
@@ -202,17 +202,17 @@ function kt(e) {
202
202
  }
203
203
  );
204
204
  }
205
- const Ot = (e, s, a) => {
205
+ const Ot = (e, s, o) => {
206
206
  let n = { left: "", width: "", top: "", height: "" };
207
207
  if (s) {
208
- const o = Ce(s, a);
208
+ const i = Ce(s, o);
209
209
  e === "vertical" ? n = {
210
- top: `${o.top}px`,
210
+ top: `${i.top}px`,
211
211
  height: `${s.offsetHeight}px`,
212
212
  left: "",
213
213
  width: ""
214
214
  } : n = {
215
- left: `${o.left}px`,
215
+ left: `${i.left}px`,
216
216
  width: `${s.offsetWidth}px`,
217
217
  top: "",
218
218
  height: ""
@@ -222,9 +222,9 @@ const Ot = (e, s, a) => {
222
222
  }, Ct = ({
223
223
  prefixCls: e,
224
224
  animation: s,
225
- disabled: a,
225
+ disabled: o,
226
226
  direction: n,
227
- getTitleRef: o,
227
+ getTitleRef: i,
228
228
  activeTab: b,
229
229
  getHeaderRef: t,
230
230
  inkBarSize: v
@@ -233,7 +233,7 @@ const Ot = (e, s, a) => {
233
233
  return L(() => {
234
234
  const w = vt(() => {
235
235
  var x;
236
- const l = o(b), c = Ot(
236
+ const l = i(b), c = Ot(
237
237
  n,
238
238
  l,
239
239
  t("headerRef").current
@@ -251,7 +251,7 @@ const Ot = (e, s, a) => {
251
251
  {
252
252
  className: X(`${e}-header-ink`, {
253
253
  [`${e}-header-ink-no-animation`]: !s,
254
- [`${e}-header-ink-disabled`]: a,
254
+ [`${e}-header-ink-disabled`]: o,
255
255
  [`${e}-header-ink-custom`]: v
256
256
  }),
257
257
  ref: g,
@@ -261,62 +261,62 @@ const Ot = (e, s, a) => {
261
261
  }, St = {
262
262
  prev: "left",
263
263
  next: "right"
264
- }, Pt = {
264
+ }, Nt = {
265
265
  prev: "up",
266
266
  next: "down"
267
267
  }, Be = (e) => {
268
268
  const {
269
269
  direction: s,
270
- headerSize: a,
270
+ headerSize: o,
271
271
  headerWrapperSize: n,
272
- prefixCls: o,
272
+ prefixCls: i,
273
273
  iconPos: b,
274
274
  currentOffset: t,
275
275
  align: v,
276
276
  rtl: g,
277
277
  icon: m
278
- } = e, { height: w, width: l } = n, { height: c, width: x } = a, h = c - w, p = x - l, d = {
278
+ } = e, { height: w, width: l } = n, { height: c, width: x } = o, h = c - w, p = x - l, d = {
279
279
  up: /* @__PURE__ */ u($t, {}),
280
280
  down: /* @__PURE__ */ u(Ye, {}),
281
281
  left: g ? /* @__PURE__ */ u(Ee, {}) : /* @__PURE__ */ u(Me, {}),
282
282
  right: g ? /* @__PURE__ */ u(Me, {}) : /* @__PURE__ */ u(Ee, {})
283
- }, i = (z) => {
283
+ }, a = (z) => {
284
284
  var f;
285
285
  z !== e.currentOffset && ((f = e == null ? void 0 : e.onChange) == null || f.call(e, z));
286
286
  }, $ = (z, f) => {
287
287
  z.preventDefault();
288
288
  let O;
289
- v === "left" ? O = f === "left" ? t - l : t + l : O = f === "left" ? t + l : t - l, i(O);
290
- }, N = (z, f) => {
289
+ v === "left" ? O = f === "left" ? t - l : t + l : O = f === "left" ? t + l : t - l, a(O);
290
+ }, P = (z, f) => {
291
291
  z.preventDefault();
292
292
  let O;
293
293
  if (f === "up")
294
294
  O = t - w;
295
295
  else if (O = t + w, O >= c)
296
296
  return;
297
- i(O);
297
+ a(O);
298
298
  }, I = ae(() => v === "left" ? t <= 0 : s === "vertical" ? t >= h : t >= p, [v, s, t, p, t]), S = ae(() => v === "left" ? s === "vertical" ? t >= h : t >= p : t <= 0, [v, s, h, p, t]);
299
299
  if (je(m))
300
300
  return null;
301
- const A = s === "horizontal" ? St[b] : Pt[b], _ = b === "prev" ? I : S, F = X(`${o}-${A}-icon`, {
302
- [`${o}-nav-icon-disabled`]: _
303
- }), Y = s === "vertical" ? N : $;
301
+ const A = s === "horizontal" ? St[b] : Nt[b], _ = b === "prev" ? I : S, F = X(`${i}-${A}-icon`, {
302
+ [`${i}-nav-icon-disabled`]: _
303
+ }), Y = s === "vertical" ? P : $;
304
304
  return /* @__PURE__ */ u(
305
305
  me,
306
306
  {
307
307
  disabled: _,
308
308
  className: F,
309
- prefix: o,
309
+ prefix: i,
310
310
  onClick: (z) => Y(z, A),
311
311
  children: m || d[A]
312
312
  }
313
313
  );
314
- }, Nt = ({
314
+ }, Pt = ({
315
315
  prefixCls: e,
316
316
  onDeleteTab: s,
317
- tabKey: a,
317
+ tabKey: o,
318
318
  isActive: n,
319
- onClickTab: o,
319
+ onClickTab: i,
320
320
  disabled: b = !1,
321
321
  title: t,
322
322
  editable: v,
@@ -326,10 +326,10 @@ const Ot = (e, s, a) => {
326
326
  getIdPrefix: l,
327
327
  index: c
328
328
  }, x) => {
329
- const h = fe(g) ? g : (i) => i, p = (i) => {
330
- i.stopPropagation(), !b && s();
331
- }, d = (i) => {
332
- b || o(i);
329
+ const h = fe(g) ? g : (a) => a, p = (a) => {
330
+ a.stopPropagation(), !b && s();
331
+ }, d = (a) => {
332
+ b || i(a);
333
333
  };
334
334
  return h(
335
335
  /* @__PURE__ */ ee(
@@ -348,8 +348,8 @@ const Ot = (e, s, a) => {
348
348
  id: l(c).tab,
349
349
  "aria-controls": l(c).tabpane,
350
350
  onClick: d,
351
- onKeyDown: (i) => {
352
- i.key === Tt.key && d(i);
351
+ onKeyDown: (a) => {
352
+ a.key === Tt.key && d(a);
353
353
  },
354
354
  children: [
355
355
  /* @__PURE__ */ u("span", { className: `${e}-header-title-text`, children: t }),
@@ -368,35 +368,35 @@ const Ot = (e, s, a) => {
368
368
  )
369
369
  ]
370
370
  },
371
- a
371
+ o
372
372
  ),
373
373
  {
374
- key: a,
374
+ key: o,
375
375
  isActive: n,
376
376
  disabled: b,
377
377
  editable: v
378
378
  }
379
379
  );
380
- }, It = te.forwardRef(Nt), Se = "vertical", ue = "right", he = "left", Le = {
380
+ }, It = te.forwardRef(Pt), Se = "vertical", ue = "right", he = "left", Le = {
381
381
  delete: !0,
382
382
  add: !0
383
383
  }, zt = ({
384
384
  direction: e,
385
385
  align: s = he,
386
- headerOffset: a
386
+ headerOffset: o
387
387
  }) => {
388
- let n = `translateX(${-a}px)`;
389
- return s === ue && (n = `translateX(${a}px)`), e === Se && (n = `translateY(${-a}px)`), pt(n);
388
+ let n = `translateX(${-o}px)`;
389
+ return s === ue && (n = `translateX(${o}px)`), e === Se && (n = `translateY(${-o}px)`), pt(n);
390
390
  }, Ht = ({
391
391
  direction: e,
392
392
  align: s = he,
393
- headerDom: a,
393
+ headerDom: o,
394
394
  headerWrapperDom: n
395
395
  }) => {
396
- const o = Ce(a, n);
397
- return e === Se ? -o.top : s === ue ? o.right : -o.left;
396
+ const i = Ce(o, n);
397
+ return e === Se ? -i.top : s === ue ? i.right : -i.left;
398
398
  }, xe = te.forwardRef((e, s) => {
399
- const a = ie(Pe), { rtl: n } = ie(Oe), o = { ...e, ...a }, [b, t, v] = oe(), [g, m, w] = oe(), [l, c, x] = oe(), [h, p, d] = oe(), [i, $, N] = oe(), I = V({}), [S, A] = we(0), [_, F] = we(!0), {
399
+ const o = ie(Ne), { rtl: n } = ie(Oe), i = { ...e, ...o }, [b, t, v] = oe(), [g, m, w] = oe(), [l, c, x] = oe(), [h, p, d] = oe(), [a, $, P] = oe(), I = V({}), [S, A] = we(0), [_, F] = we(!0), {
400
400
  paneChildren: Y,
401
401
  editable: z,
402
402
  prefixCls: f,
@@ -410,20 +410,20 @@ const Ot = (e, s, a) => {
410
410
  style: Fe,
411
411
  tabPosition: Ge,
412
412
  className: Ke,
413
- extra: Ne,
413
+ extra: Pe,
414
414
  animation: qe,
415
- icons: P,
415
+ icons: N,
416
416
  deleteButton: Je,
417
417
  addButton: Qe,
418
418
  renderTabTitle: Ze,
419
419
  scrollAfterEdit: Ie,
420
420
  scrollPosition: M = "auto",
421
421
  inkBarSize: et
422
- } = o, ze = ke(Ie) ? { ...Le, ...Ie } : Le, [tt, nt] = n ? [ue, he] : [he, ue], G = H === "capsule" ? nt : tt, j = ae(() => {
422
+ } = i, ze = ke(Ie) ? { ...Le, ...Ie } : Le, [tt, nt] = n ? [ue, he] : [he, ue], G = H === "capsule" ? nt : tt, j = ae(() => {
423
423
  const r = c.height - p.height - $.height, y = c.width - p.width - $.width;
424
- return o.direction === "vertical" ? r < m.height : y < m.width;
424
+ return i.direction === "vertical" ? r < m.height : y < m.width;
425
425
  }, [
426
- o.direction,
426
+ i.direction,
427
427
  c,
428
428
  p,
429
429
  m,
@@ -444,7 +444,7 @@ const Ot = (e, s, a) => {
444
444
  width: T.offsetWidth,
445
445
  domRect: T.getBoundingClientRect()
446
446
  });
447
- }, 200), K = ce(v), q = ce(w), J = ce(d), Q = ce(N), pe = at(
447
+ }, 200), K = ce(v), q = ce(w), J = ce(d), Q = ce(P), pe = at(
448
448
  (r) => {
449
449
  const y = C === Se ? m.height - t.height : m.width - t.width;
450
450
  let T = r;
@@ -505,16 +505,16 @@ const Ot = (e, s, a) => {
505
505
  headerOffset: S
506
506
  }), ge = j && R === "dropdown" && C !== "vertical", ve = j && !ge, se = z && (H === "card" || H === "card-gutter" || H === "line"), it = (r) => {
507
507
  var y;
508
- (y = o.onDeleteTab) == null || y.call(o, r.key), F(ze.delete);
508
+ (y = i.onDeleteTab) == null || y.call(i, r.key), F(ze.delete);
509
509
  }, He = () => {
510
510
  O == null || O(), F(ze.add);
511
511
  };
512
512
  L(() => {
513
- const r = de([i.current], Q);
513
+ const r = de([a.current], Q);
514
514
  return () => {
515
515
  r();
516
516
  };
517
- }, [i.current]), L(() => {
517
+ }, [a.current]), L(() => {
518
518
  const r = de([b.current], K);
519
519
  return () => {
520
520
  r();
@@ -537,10 +537,10 @@ const Ot = (e, s, a) => {
537
537
  "aria-label": "add tab",
538
538
  tabIndex: 0,
539
539
  role: "button",
540
- ref: i,
540
+ ref: a,
541
541
  onClick: He,
542
542
  ...Xe({ onPressEnter: He }),
543
- children: Qe || /* @__PURE__ */ u(me, { prefix: `${f}-add`, children: /* @__PURE__ */ u("span", { className: `${f}-add`, children: (P == null ? void 0 : P.add) || /* @__PURE__ */ u(ut, {}) }) })
543
+ children: Qe || /* @__PURE__ */ u(me, { prefix: `${f}-add`, children: /* @__PURE__ */ u("span", { className: `${f}-add`, children: (N == null ? void 0 : N.add) || /* @__PURE__ */ u(ut, {}) }) })
544
544
  }
545
545
  );
546
546
  return xt({
@@ -561,11 +561,11 @@ const Ot = (e, s, a) => {
561
561
  `${f}-header-nav-${Ge}`,
562
562
  `${f}-header-size-${_e}`,
563
563
  `${f}-header-nav-${H}`,
564
- { [`${f}-header-nav-sticky`]: o.headerSticky },
564
+ { [`${f}-header-nav-sticky`]: i.headerSticky },
565
565
  // 潘启宝添加
566
566
  Ke
567
567
  ),
568
- style: { ...Fe, ...o.headerSticky },
568
+ style: { ...Fe, ...i.headerSticky },
569
569
  ref: s,
570
570
  children: /* @__PURE__ */ ee(
571
571
  "div",
@@ -581,7 +581,7 @@ const Ot = (e, s, a) => {
581
581
  {
582
582
  iconPos: "prev",
583
583
  rtl: n,
584
- icon: P == null ? void 0 : P.prev,
584
+ icon: N == null ? void 0 : N.prev,
585
585
  prefixCls: f,
586
586
  currentOffset: S,
587
587
  headerSize: m,
@@ -614,13 +614,13 @@ const Ot = (e, s, a) => {
614
614
  renderTitle: e.children || Ze,
615
615
  onClickTab: () => {
616
616
  var T;
617
- (T = o.onClickTab) == null || T.call(o, r.key);
617
+ (T = i.onClickTab) == null || T.call(i, r.key);
618
618
  },
619
619
  isActive: ne === r.key,
620
620
  editable: se && r.props.closable !== !1,
621
- deleteIcon: P == null ? void 0 : P.delete,
621
+ deleteIcon: N == null ? void 0 : N.delete,
622
622
  deleteButton: Je,
623
- getIdPrefix: a.getIdPrefix,
623
+ getIdPrefix: o.getIdPrefix,
624
624
  index: y
625
625
  },
626
626
  y
@@ -651,7 +651,7 @@ const Ot = (e, s, a) => {
651
651
  prefixCls: f,
652
652
  rtl: n,
653
653
  iconPos: "next",
654
- icon: P == null ? void 0 : P.next,
654
+ icon: N == null ? void 0 : N.next,
655
655
  currentOffset: S,
656
656
  headerSize: m,
657
657
  headerWrapperSize: t,
@@ -663,20 +663,20 @@ const Ot = (e, s, a) => {
663
663
  ge && /* @__PURE__ */ u(
664
664
  kt,
665
665
  {
666
- onClickTab: o.onClickTab,
666
+ onClickTab: i.onClickTab,
667
667
  paneChildren: Y,
668
668
  prefixCls: f,
669
669
  currentOffset: S,
670
670
  headerSize: m,
671
- icon: P == null ? void 0 : P.dropdown,
671
+ icon: N == null ? void 0 : N.dropdown,
672
672
  headerWrapperSize: t,
673
673
  getTitleRef: (r) => I.current[r],
674
674
  direction: C
675
675
  }
676
676
  ),
677
- (se && j || Ne) && /* @__PURE__ */ ee("div", { className: `${f}-header-extra`, ref: h, children: [
677
+ (se && j || Pe) && /* @__PURE__ */ ee("div", { className: `${f}-header-extra`, ref: h, children: [
678
678
  j && Re(se),
679
- Ne
679
+ Pe
680
680
  ] })
681
681
  ]
682
682
  }
@@ -686,13 +686,13 @@ const Ot = (e, s, a) => {
686
686
  });
687
687
  xe.displayName = "TabHeader";
688
688
  const Rt = ["mini", "small", "default", "large"], Dt = (e) => {
689
- const { children: s } = e, a = [];
689
+ const { children: s } = e, o = [];
690
690
  return te.Children.forEach(s, (n) => {
691
- n && n.type && n.type.isTabPane && a.push(n);
692
- }), a;
691
+ n && n.type && n.type.isTabPane && o.push(n);
692
+ }), o;
693
693
  }, Wt = (e) => {
694
- const { direction: s, tabPosition: a, animation: n } = e;
695
- return s === "vertical" || a === "left" || a === "right" ? !1 : ke(n) ? "tabPane" in n ? n.tabPane : !1 : n;
694
+ const { direction: s, tabPosition: o, animation: n } = e;
695
+ return s === "vertical" || o === "left" || o === "right" ? !1 : ke(n) ? "tabPane" in n ? n.tabPane : !1 : n;
696
696
  }, At = {
697
697
  tabPosition: "top",
698
698
  type: "line",
@@ -701,31 +701,31 @@ const Rt = ["mini", "small", "default", "large"], Dt = (e) => {
701
701
  lazyload: !0,
702
702
  headerPadding: !0,
703
703
  scrollPosition: "auto"
704
- }, Pe = te.createContext({});
704
+ }, Ne = te.createContext({});
705
705
  function Mt(e, s) {
706
706
  const {
707
- getPrefixCls: a,
707
+ getPrefixCls: o,
708
708
  size: n,
709
- componentConfig: o,
709
+ componentConfig: i,
710
710
  rtl: b
711
711
  } = ie(Oe), t = lt(
712
712
  e,
713
713
  At,
714
- o == null ? void 0 : o.Tabs
714
+ i == null ? void 0 : i.Tabs
715
715
  ), v = Dt(t), g = V(null), [m, w] = dt(
716
716
  v[0] && v[0].key,
717
717
  {
718
718
  defaultValue: "defaultActiveTab" in t ? t.defaultActiveTab : void 0,
719
719
  value: "activeTab" in t ? t.activeTab : void 0
720
720
  }
721
- ), l = a("tabs"), c = t.size || (Rt.indexOf(n) > -1 ? n : "default"), {
721
+ ), l = o == null ? void 0 : o("tabs"), c = t.size || (Rt.indexOf(n) > -1 ? n : "default"), {
722
722
  animation: x,
723
723
  className: h,
724
724
  direction: p,
725
725
  style: d,
726
- type: i,
726
+ type: a,
727
727
  justify: $,
728
- destroyOnHide: N,
728
+ destroyOnHide: P,
729
729
  lazyload: I,
730
730
  headerSticky: S,
731
731
  // 潘启宝添加
@@ -755,7 +755,7 @@ function Mt(e, s) {
755
755
  activeTab: m,
756
756
  paneChildren: v,
757
757
  prefixCls: l,
758
- destroyOnHide: N,
758
+ destroyOnHide: P,
759
759
  lazyload: I
760
760
  }
761
761
  );
@@ -786,7 +786,7 @@ function Mt(e, s) {
786
786
  className: X(
787
787
  l,
788
788
  `${l}-${["left", "right"].indexOf(O) > -1 ? "vertical" : "horizontal"}`,
789
- `${l}-${i}`,
789
+ `${l}-${a}`,
790
790
  !!S && `${l}-sticky`,
791
791
  // 潘启宝添加
792
792
  `${l}-${O}`,
@@ -799,7 +799,7 @@ function Mt(e, s) {
799
799
  ),
800
800
  ref: g,
801
801
  children: /* @__PURE__ */ ee(
802
- Pe.Provider,
802
+ Ne.Provider,
803
803
  {
804
804
  value: {
805
805
  ...C,
@@ -838,6 +838,6 @@ Ue.displayName = "Tabs";
838
838
  Ue.TabPane = ft;
839
839
  export {
840
840
  Ue as T,
841
- Pe as a,
841
+ Ne as a,
842
842
  wt as b
843
843
  };