@unicom-cloud/ui 0.8.52 → 0.8.53
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.
- package/Affix.js +41 -40
- package/Alert.js +2 -2
- package/Anchor.js +1 -1
- package/AutoComplete.js +3 -3
- package/Avatar.js +1 -1
- package/BackTop.js +2 -2
- package/Badge.js +2 -2
- package/Breadcrumb.js +2 -2
- package/Button.js +1 -1
- package/Calendar.js +3 -3
- package/Card.js +1 -1
- package/Carousel.js +1 -1
- package/Cascader.js +1 -1
- package/Checkbox.js +1 -1
- package/Collapse.js +1 -1
- package/ColorPicker.js +3 -3
- package/Comment.js +1 -1
- package/ConfigProvider.js +2 -2
- package/Copy.js +1 -1
- package/DatePicker.js +1268 -1233
- package/Descriptions.js +1 -1
- package/Divider.js +1 -1
- package/Draggable.js +1 -1
- package/Drawer.js +1 -1
- package/Dropdown.js +1 -1
- package/Empty.js +1 -1
- package/Form.js +122 -117
- package/Grid.js +86 -83
- package/Icon.js +1 -1
- package/IconHover.js +1 -1
- package/Image.js +1 -1
- package/Input.js +1 -1
- package/InputNumber.js +2 -2
- package/InputTag.js +1 -1
- package/Layout.js +2 -2
- package/Link.js +1 -1
- package/List.js +3 -3
- package/Mentions.js +3 -3
- package/Menu.js +1 -1
- package/Message.js +2 -2
- package/Modal.js +1 -1
- package/Notice.js +1 -1
- package/Notification.js +2 -2
- package/OverflowEllipsis.js +1 -1
- package/PageHeader.js +1 -1
- package/Pagination.js +1 -1
- package/Picker.js +1 -1
- package/Popconfirm.js +1 -1
- package/Popover.js +1 -1
- package/Progress.js +1 -1
- package/Radio.js +2 -2
- package/Rate.js +1 -1
- package/ResizeBox.js +33 -32
- package/Result.js +1 -1
- package/Select.js +1 -1
- package/SelectView.js +142 -141
- package/Skeleton.js +1 -1
- package/Slider.js +2 -2
- package/Space.js +1 -1
- package/Spin.js +1 -1
- package/Statistic.js +1 -1
- package/Steps.js +1 -1
- package/Switch.js +15 -14
- package/Table.js +141 -133
- package/Tabs.js +1 -1
- package/Tag.js +111 -82
- package/TimePicker.js +3 -3
- package/Timeline.js +1 -1
- package/Tooltip.js +1 -1
- package/Transfer.js +3 -3
- package/Tree.js +1 -1
- package/TreeSelect.js +1 -1
- package/Trigger.js +31 -30
- package/Typography.js +25 -25
- package/Upload.js +1 -1
- package/VerificationCode.js +1 -1
- package/Version.js +1 -1
- package/Watermark.js +1 -1
- package/chunk/{CoevJNNj.js → -sV-N67P.js} +1 -1
- package/chunk/{CkIWpIl6.js → 8hWViek4.js} +1 -1
- package/chunk/{Ct7mcZuW.js → B8IzaBdN.js} +1 -1
- package/chunk/{DCe3olyi.js → BEVtQ2QL.js} +101 -99
- package/chunk/{tkU8zIK4.js → BEiJmFHq.js} +1 -1
- package/chunk/{CQvJK4kb.js → BOUZ7hSf.js} +12 -12
- package/chunk/{DMeJAY1S.js → BYMRs7t5.js} +6 -5
- package/chunk/{DWGwYNvC.js → CBaVCRtG.js} +2 -2
- package/chunk/{5PpvDpEt.js → CLU6Le34.js} +2 -2
- package/chunk/{dhljdm11.js → COWsswcW.js} +64 -63
- package/chunk/{B9nYZhXo.js → CRxPui7e.js} +2 -2
- package/chunk/CYyPBcnp.js +970 -0
- package/chunk/{DfvdYCUz.js → CccPQyYX.js} +1 -1
- package/chunk/{DUX5Hw8l.js → CmEyvBdT.js} +3 -3
- package/chunk/{Cku5-xbe.js → Cwp65v9h.js} +47 -46
- package/chunk/{I0bfWb5y.js → CyVLxv_U.js} +95 -93
- package/chunk/{Cw63stMm.js → Cz65nXZD.js} +18 -18
- package/chunk/D3pUE3-b.js +445 -0
- package/chunk/{9AJ-uN8F.js → D6BMh1k4.js} +1 -1
- package/chunk/{BHWpeAbb.js → DGK45cuc.js} +1 -1
- package/chunk/{CfqAfcA3.js → DNyP-r9G.js} +2 -2
- package/chunk/DQ3uFRJD.js +892 -0
- package/chunk/{4XXtB4ZV.js → DY9WA4bf.js} +1 -1
- package/chunk/{DG5zSZDd.js → DdVbiC4t.js} +2 -2
- package/chunk/{n58kSv9T.js → DfMf16uZ.js} +11 -5
- package/chunk/{z7sBNzI4.js → Lyg-9NEt.js} +17 -17
- package/chunk/{BXZYc88i.js → PRN8SqRA.js} +3 -3
- package/chunk/bcn23eHi.js +277 -0
- package/index.js +408 -346
- package/package.json +1 -23
- package/style.css +1 -1
- package/types/color-picker/colors.d.ts +1 -1
- package/types/date-picker/Picker.d.ts +4 -3
- package/types/date-picker/PickerRange.d.ts +3 -7
- package/types/date-picker/interface.d.ts +9 -1
- package/types/grid/index.d.ts +2 -1
- package/types/index.d.ts +1 -0
- package/types/pagination/interface.d.ts +1 -0
- package/types/picker/InputRange.d.ts +1 -1
- package/types/select/Select.d.ts +1 -1
- package/types/tag/interface.d.ts +7 -3
- package/types/utils/CSSTransition.d.ts +2 -1
- package/types/utils/is.d.ts +4 -17
- package/types/version/index.d.ts +1 -1
- package/utils/CSSTransition.js +1 -1
- package/utils/contextHolder.js +1 -1
- package/utils/is.js +102 -104
- package/utils/reactDOM.js +19 -19
- package/chunk/C61BEbHK.js +0 -263
- package/chunk/DXMtLuTP.js +0 -443
- package/chunk/m3_n9fBe.js +0 -961
- package/chunk/uUGMUxt_.js +0 -474
package/Tabs.js
CHANGED
package/Tag.js
CHANGED
|
@@ -1,13 +1,15 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import {
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
|
|
1
|
+
import { jsx as c, jsxs as T, Fragment as G } from "react/jsx-runtime";
|
|
2
|
+
import J from "@unicom-cloud/icons/IconUiClose";
|
|
3
|
+
import Q from "@unicom-cloud/icons/IconUiLoading";
|
|
4
|
+
import b from "lodash/isPlainObject";
|
|
5
|
+
import { forwardRef as W, useContext as X, useState as v } from "react";
|
|
6
|
+
import { a as Y, I as Z } from "./chunk/Lyg-9NEt.js";
|
|
7
|
+
import ee from "./hooks/useKeyboardEvent.js";
|
|
8
|
+
import oe from "./hooks/useMergeProps.js";
|
|
9
|
+
import ne from "./Popconfirm.js";
|
|
10
|
+
import re from "@unicom-cloud/utils/class-name";
|
|
11
|
+
import ie from "./utils/omit.js";
|
|
12
|
+
const te = [
|
|
11
13
|
"red",
|
|
12
14
|
"orangered",
|
|
13
15
|
"orange",
|
|
@@ -20,88 +22,115 @@ const Z = [
|
|
|
20
22
|
"purple",
|
|
21
23
|
"magenta",
|
|
22
24
|
"gray"
|
|
23
|
-
],
|
|
25
|
+
], ce = {
|
|
24
26
|
size: "default"
|
|
25
27
|
};
|
|
26
|
-
function
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
28
|
+
function se(_, j) {
|
|
29
|
+
var E;
|
|
30
|
+
const { getPrefixCls: z, componentConfig: l, rtl: H } = X(Y), L = ee(), i = oe(
|
|
31
|
+
_,
|
|
32
|
+
ce,
|
|
33
|
+
l == null ? void 0 : l.Tag
|
|
31
34
|
), {
|
|
32
|
-
className:
|
|
33
|
-
style:
|
|
34
|
-
children:
|
|
35
|
-
color:
|
|
36
|
-
closable:
|
|
37
|
-
checkable:
|
|
38
|
-
defaultChecked:
|
|
39
|
-
size:
|
|
40
|
-
onClose:
|
|
41
|
-
onCheck:
|
|
42
|
-
icon:
|
|
43
|
-
closeIcon:
|
|
44
|
-
bordered:
|
|
45
|
-
__closeIconProps:
|
|
46
|
-
...
|
|
47
|
-
} =
|
|
48
|
-
"visible" in
|
|
49
|
-
), [
|
|
50
|
-
"checked" in
|
|
51
|
-
), [
|
|
52
|
-
function
|
|
53
|
-
const
|
|
54
|
-
|
|
55
|
-
|
|
35
|
+
className: S,
|
|
36
|
+
style: w,
|
|
37
|
+
children: x,
|
|
38
|
+
color: t,
|
|
39
|
+
closable: e,
|
|
40
|
+
checkable: d,
|
|
41
|
+
defaultChecked: K,
|
|
42
|
+
size: N,
|
|
43
|
+
onClose: m,
|
|
44
|
+
onCheck: f,
|
|
45
|
+
icon: y,
|
|
46
|
+
closeIcon: p,
|
|
47
|
+
bordered: R,
|
|
48
|
+
__closeIconProps: U,
|
|
49
|
+
...V
|
|
50
|
+
} = i, o = z("tag"), [q, P] = v(
|
|
51
|
+
"visible" in i ? i.visible : !0
|
|
52
|
+
), [F, M] = v(
|
|
53
|
+
"checked" in i ? i.checked : K
|
|
54
|
+
), [h, g] = v(), I = "checked" in i ? i.checked : F, A = "visible" in i ? i.visible : q;
|
|
55
|
+
function u(n) {
|
|
56
|
+
const r = m == null ? void 0 : m(n);
|
|
57
|
+
r && r.then ? (g(!0), r.then(() => {
|
|
58
|
+
g(!1), P(!1);
|
|
56
59
|
}).catch(() => {
|
|
57
|
-
|
|
58
|
-
})) :
|
|
60
|
+
g(!1);
|
|
61
|
+
})) : P(!1);
|
|
59
62
|
}
|
|
60
|
-
function
|
|
61
|
-
const
|
|
62
|
-
"checked" in
|
|
63
|
+
function B() {
|
|
64
|
+
const n = !I;
|
|
65
|
+
"checked" in i || M(n), f == null || f(n);
|
|
63
66
|
}
|
|
64
|
-
const
|
|
65
|
-
|
|
67
|
+
const a = t && te.indexOf(t) !== -1 ? t : "", k = d ? I : !0, D = re(
|
|
68
|
+
o,
|
|
66
69
|
{
|
|
67
|
-
[`${
|
|
68
|
-
[`${
|
|
69
|
-
[`${
|
|
70
|
-
[`${
|
|
71
|
-
[`${
|
|
72
|
-
[`${
|
|
73
|
-
[`${
|
|
74
|
-
[`${
|
|
75
|
-
[`${
|
|
70
|
+
[`${o}-loading`]: h,
|
|
71
|
+
[`${o}-hide`]: !A,
|
|
72
|
+
[`${o}-${a}`]: a,
|
|
73
|
+
[`${o}-checkable`]: d,
|
|
74
|
+
[`${o}-checked`]: k,
|
|
75
|
+
[`${o}-size-${N}`]: N,
|
|
76
|
+
[`${o}-bordered`]: R,
|
|
77
|
+
[`${o}-custom-color`]: k && t && !a,
|
|
78
|
+
[`${o}-rtl`]: H
|
|
76
79
|
},
|
|
77
|
-
|
|
78
|
-
),
|
|
79
|
-
...
|
|
80
|
+
S
|
|
81
|
+
), C = {
|
|
82
|
+
...w
|
|
80
83
|
};
|
|
81
|
-
|
|
82
|
-
const
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
{
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
}
|
|
99
|
-
|
|
100
|
-
|
|
84
|
+
t && !a && k && (C.backgroundColor = t, C.borderColor = t);
|
|
85
|
+
const O = ie(V, ["visible"]);
|
|
86
|
+
d && (O.onClick = B);
|
|
87
|
+
let $ = /* @__PURE__ */ c(
|
|
88
|
+
Z,
|
|
89
|
+
{
|
|
90
|
+
prefix: o,
|
|
91
|
+
className: `${o}-close-btn`,
|
|
92
|
+
onClick: (n) => {
|
|
93
|
+
b(e == null ? void 0 : e.popconfirm) || u(n);
|
|
94
|
+
},
|
|
95
|
+
role: "button",
|
|
96
|
+
tabIndex: 0,
|
|
97
|
+
...L({
|
|
98
|
+
onPressEnter(n) {
|
|
99
|
+
b(e == null ? void 0 : e.popconfirm) || u(n);
|
|
100
|
+
}
|
|
101
|
+
}),
|
|
102
|
+
"aria-label": "Close",
|
|
103
|
+
...U,
|
|
104
|
+
children: p !== void 0 ? p : /* @__PURE__ */ c(J, {})
|
|
105
|
+
}
|
|
106
|
+
);
|
|
107
|
+
return b(e == null ? void 0 : e.popconfirm) && ($ = /* @__PURE__ */ c(
|
|
108
|
+
ne,
|
|
109
|
+
{
|
|
110
|
+
...e == null ? void 0 : e.popconfirm,
|
|
111
|
+
title: ((E = e == null ? void 0 : e.popconfirm) == null ? void 0 : E.title) || /* @__PURE__ */ T(G, { children: [
|
|
112
|
+
"确定要关闭 ",
|
|
113
|
+
x
|
|
114
|
+
] }),
|
|
115
|
+
onCancel: (n) => {
|
|
116
|
+
var r, s;
|
|
117
|
+
(s = (r = e == null ? void 0 : e.popconfirm) == null ? void 0 : r.onCancel) == null || s.call(r, n);
|
|
118
|
+
},
|
|
119
|
+
onOk: (n) => {
|
|
120
|
+
var r, s;
|
|
121
|
+
u(n), (s = (r = e == null ? void 0 : e.popconfirm) == null ? void 0 : r.onOk) == null || s.call(r, n);
|
|
122
|
+
},
|
|
123
|
+
children: $
|
|
124
|
+
}
|
|
125
|
+
)), /* @__PURE__ */ T("div", { ref: j, style: C, className: D, ...O, children: [
|
|
126
|
+
y && /* @__PURE__ */ c("span", { className: `${o}-icon`, children: y }),
|
|
127
|
+
/* @__PURE__ */ c("span", { className: `${o}-content`, children: x }),
|
|
128
|
+
!!e && !h && p !== null && $,
|
|
129
|
+
h && /* @__PURE__ */ c("span", { className: `${o}-loading-icon`, children: /* @__PURE__ */ c(Q, {}) })
|
|
101
130
|
] });
|
|
102
131
|
}
|
|
103
|
-
const
|
|
104
|
-
|
|
132
|
+
const ae = W(se);
|
|
133
|
+
ae.displayName = "Tag";
|
|
105
134
|
export {
|
|
106
|
-
|
|
135
|
+
ae as default
|
|
107
136
|
};
|
package/TimePicker.js
CHANGED
|
@@ -3,16 +3,16 @@ import Re from "@unicom-cloud/icons/IconUiClockCircle";
|
|
|
3
3
|
import { isDayjs as L } from "dayjs";
|
|
4
4
|
import p from "lodash/isArray";
|
|
5
5
|
import He, { useContext as pe, useState as z, useRef as ze } from "react";
|
|
6
|
-
import { a as Ae } from "./chunk/
|
|
6
|
+
import { a as Ae } from "./chunk/Lyg-9NEt.js";
|
|
7
7
|
import Ne from "./hooks/useMergeProps.js";
|
|
8
8
|
import ce from "./hooks/usePrevious.js";
|
|
9
9
|
import Oe from "./hooks/useUpdateEffect.js";
|
|
10
|
-
import { a as Ee, I as Fe } from "./chunk/
|
|
10
|
+
import { a as Ee, I as Fe } from "./chunk/bcn23eHi.js";
|
|
11
11
|
import $e from "./Trigger.js";
|
|
12
12
|
import Ue from "@unicom-cloud/utils/class-name";
|
|
13
13
|
import { getDayjsValue as B, toLocal as d, toTimezone as X, isValidTimeString as Q, getSortedDayjsArray as Be, isDayjsArrayChange as Le, isDayjsChange as Me } from "./utils/dayjs.js";
|
|
14
14
|
import { pickDataAttributes as We } from "./utils/pick.js";
|
|
15
|
-
import { P as me, g as _e, T as de } from "./chunk/
|
|
15
|
+
import { P as me, g as _e, T as de } from "./chunk/DY9WA4bf.js";
|
|
16
16
|
import qe from "./utils/omit.js";
|
|
17
17
|
function Ge(h) {
|
|
18
18
|
return h.format || "HH:mm:ss";
|
package/Timeline.js
CHANGED
package/Tooltip.js
CHANGED
|
@@ -2,7 +2,7 @@ import { jsx as a } from "react/jsx-runtime";
|
|
|
2
2
|
import F from "@unicom-cloud/utils/tinycolor";
|
|
3
3
|
import I from "lodash/isFunction";
|
|
4
4
|
import { forwardRef as S, useContext as j, useRef as z, useImperativeHandle as B, useMemo as W } from "react";
|
|
5
|
-
import { a as q } from "./chunk/
|
|
5
|
+
import { a as q } from "./chunk/Lyg-9NEt.js";
|
|
6
6
|
import G from "./hooks/useMergeProps.js";
|
|
7
7
|
import J, { EventsByTriggerNeed as K } from "./Trigger.js";
|
|
8
8
|
import P from "@unicom-cloud/utils/class-name";
|
package/Transfer.js
CHANGED
|
@@ -4,16 +4,16 @@ import Ie from "@unicom-cloud/icons/IconUiRight";
|
|
|
4
4
|
import ne from "lodash/isPlainObject";
|
|
5
5
|
import de, { useRef as le, useState as G, useEffect as ae, useContext as fe, useMemo as ce } from "react";
|
|
6
6
|
import ue from "./Button.js";
|
|
7
|
-
import { I as pe, a as me } from "./chunk/
|
|
7
|
+
import { I as pe, a as me } from "./chunk/Lyg-9NEt.js";
|
|
8
8
|
import Ke from "./hooks/useMergeProps.js";
|
|
9
9
|
import ie from "./hooks/useMergeValue.js";
|
|
10
10
|
import se from "@unicom-cloud/utils/class-name";
|
|
11
11
|
import { pickDataAttributes as xe } from "./utils/pick.js";
|
|
12
12
|
import Ce from "@unicom-cloud/icons/IconUiDelete";
|
|
13
13
|
import $e from "@unicom-cloud/icons/IconUiSearch";
|
|
14
|
-
import { C as oe } from "./chunk/
|
|
14
|
+
import { C as oe } from "./chunk/B8IzaBdN.js";
|
|
15
15
|
import ge from "./hooks/useKeyboardEvent.js";
|
|
16
|
-
import { I as ve } from "./chunk/
|
|
16
|
+
import { I as ve } from "./chunk/CyVLxv_U.js";
|
|
17
17
|
import Se from "./List.js";
|
|
18
18
|
import Ne from "@unicom-cloud/icons/IconUiClose";
|
|
19
19
|
import Te from "@unicom-cloud/icons/IconUiDragDotVertical";
|
package/Tree.js
CHANGED
package/TreeSelect.js
CHANGED
package/Trigger.js
CHANGED
|
@@ -2,29 +2,30 @@ var ot = Object.defineProperty;
|
|
|
2
2
|
var st = (h, l, t) => l in h ? ot(h, l, { enumerable: !0, configurable: !0, writable: !0, value: t }) : h[l] = t;
|
|
3
3
|
var s = (h, l, t) => st(h, typeof l != "symbol" ? l + "" : l, t);
|
|
4
4
|
import { jsx as H, jsxs as X } from "react/jsx-runtime";
|
|
5
|
-
import {
|
|
5
|
+
import { c as nt } from "./chunk/DQ3uFRJD.js";
|
|
6
6
|
import rt from "lodash/isArray";
|
|
7
7
|
import lt from "lodash/isEqual";
|
|
8
8
|
import W from "lodash/isFunction";
|
|
9
9
|
import A, { useRef as pt, useEffect as ht, PureComponent as ut, createRef as q } from "react";
|
|
10
|
-
import { a as at } from "./chunk/
|
|
10
|
+
import { a as at } from "./chunk/Lyg-9NEt.js";
|
|
11
11
|
import _ from "@unicom-cloud/utils/class-name";
|
|
12
12
|
import { isServerRendering as et, on as U, off as Y, getScrollElements as ct, isScrollElement as ft, contains as Q } from "./utils/dom.js";
|
|
13
|
-
import {
|
|
14
|
-
import { Esc as
|
|
15
|
-
import
|
|
16
|
-
import { pickDataAttributes as
|
|
17
|
-
import { caf as
|
|
18
|
-
import { findDOMNode as
|
|
19
|
-
import
|
|
20
|
-
import
|
|
21
|
-
import
|
|
13
|
+
import { supportRef as dt } from "./utils/is.js";
|
|
14
|
+
import { Esc as K } from "./utils/keyCode.js";
|
|
15
|
+
import gt from "./utils/mergeProp.js";
|
|
16
|
+
import { pickDataAttributes as mt } from "./utils/pick.js";
|
|
17
|
+
import { caf as G, raf as Pt } from "./utils/raf.js";
|
|
18
|
+
import { findDOMNode as bt, callbackOriginRef as yt } from "./utils/reactDOM.js";
|
|
19
|
+
import j from "./utils/throttleByRaf.js";
|
|
20
|
+
import wt from "react-dom";
|
|
21
|
+
import Tt from "./hooks/useIsFirstRender.js";
|
|
22
|
+
import { isArray as Ct, isPlainObject as J } from "@unicom-cloud/utils/is";
|
|
22
23
|
const Mt = (h) => {
|
|
23
24
|
const { getContainer: l, children: t } = h, e = pt();
|
|
24
|
-
return (
|
|
25
|
+
return (Tt() || e.current === null) && !et && (e.current = l()), ht(() => () => {
|
|
25
26
|
const n = e.current;
|
|
26
27
|
n && n.parentNode && (n.parentNode.removeChild(n), e.current = null);
|
|
27
|
-
}, []), e.current ?
|
|
28
|
+
}, []), e.current ? wt.createPortal(t, e.current) : null;
|
|
28
29
|
}, B = 0, I = (h, l) => {
|
|
29
30
|
const { position: t } = l, { width: e, height: i, left: n, right: r, top: u, bottom: y } = h.getBoundingClientRect(), o = l.boundaryDistance || {}, v = "left" in o && o.left || B, g = "top" in o && o.top || B;
|
|
30
31
|
let a, c, f, m;
|
|
@@ -60,7 +61,7 @@ const O = function(h, l, t) {
|
|
|
60
61
|
...h
|
|
61
62
|
} : i = { ...h };
|
|
62
63
|
for (const n in i)
|
|
63
|
-
if (
|
|
64
|
+
if (Ct(i[n])) {
|
|
64
65
|
let r = 0;
|
|
65
66
|
["top", "bottom"].indexOf(n) > -1 ? (r = 1, t = i[n][0]) : e = i[n][1], i[n] = i[n][r];
|
|
66
67
|
}
|
|
@@ -220,7 +221,7 @@ function Z(h, l) {
|
|
|
220
221
|
right: n
|
|
221
222
|
};
|
|
222
223
|
}
|
|
223
|
-
const
|
|
224
|
+
const Jt = [
|
|
224
225
|
"onClick",
|
|
225
226
|
"onMouseEnter",
|
|
226
227
|
"onMouseLeave",
|
|
@@ -336,8 +337,8 @@ class tt extends ut {
|
|
|
336
337
|
s(this, "childrenDomSize", {});
|
|
337
338
|
s(this, "getMergedProps", (t) => {
|
|
338
339
|
const { componentConfig: e } = this.context ?? {};
|
|
339
|
-
return
|
|
340
|
-
t &&
|
|
340
|
+
return gt(
|
|
341
|
+
t && J(t) ? t : this.props,
|
|
341
342
|
zt,
|
|
342
343
|
e == null ? void 0 : e.Trigger,
|
|
343
344
|
t && rt(t) ? t : void 0
|
|
@@ -345,7 +346,7 @@ class tt extends ut {
|
|
|
345
346
|
});
|
|
346
347
|
s(this, "getRootElement", () => {
|
|
347
348
|
var t, e;
|
|
348
|
-
return this.childrenDom =
|
|
349
|
+
return this.childrenDom = bt(
|
|
349
350
|
((e = (t = this.props).getTargetDOMNode) == null ? void 0 : e.call(t)) || this.rootElementRef,
|
|
350
351
|
this
|
|
351
352
|
), this.childrenDom;
|
|
@@ -384,7 +385,7 @@ class tt extends ut {
|
|
|
384
385
|
this.resizeObserver && this.observerContainer !== t && (this.offContainerResize(), t && this.resizeObserver.observe(t), this.observerContainer = t);
|
|
385
386
|
});
|
|
386
387
|
// getPopupContainer 改变时候触发
|
|
387
|
-
s(this, "handleUpdatePosition",
|
|
388
|
+
s(this, "handleUpdatePosition", j(() => {
|
|
388
389
|
this.updatePopupPosition();
|
|
389
390
|
}));
|
|
390
391
|
s(this, "isClickTrigger", () => {
|
|
@@ -505,7 +506,7 @@ class tt extends ut {
|
|
|
505
506
|
t
|
|
506
507
|
);
|
|
507
508
|
});
|
|
508
|
-
s(this, "update",
|
|
509
|
+
s(this, "update", j((t) => {
|
|
509
510
|
if (this.unmount || !this.state.popupVisible)
|
|
510
511
|
return;
|
|
511
512
|
const e = this.getPopupStyle();
|
|
@@ -576,11 +577,11 @@ class tt extends ut {
|
|
|
576
577
|
});
|
|
577
578
|
s(this, "onKeyDown", (t) => {
|
|
578
579
|
const e = t.key;
|
|
579
|
-
this.triggerPropsEvent("onKeyDown", t), e ===
|
|
580
|
+
this.triggerPropsEvent("onKeyDown", t), e === K.key && this.onPressEsc(t);
|
|
580
581
|
});
|
|
581
582
|
s(this, "onPressEsc", (t) => {
|
|
582
583
|
const { escToClose: e } = this.getMergedProps(["escToClose"]);
|
|
583
|
-
e && t && t.key ===
|
|
584
|
+
e && t && t.key === K.key && this.state.popupVisible && this.setPopupVisible(!1);
|
|
584
585
|
});
|
|
585
586
|
s(this, "onMouseEnter", (t) => {
|
|
586
587
|
const { mouseEnterDelay: e } = this.getMergedProps(["mouseEnterDelay"]);
|
|
@@ -672,14 +673,14 @@ class tt extends ut {
|
|
|
672
673
|
s(this, "rafId");
|
|
673
674
|
// 创建的dom节点插入getPopupContainer。
|
|
674
675
|
s(this, "appendToContainer", (t) => {
|
|
675
|
-
if (
|
|
676
|
+
if (G(this.rafId), this.isDidMount) {
|
|
676
677
|
const { getPopupContainer: e } = this.context, { getPopupContainer: i } = this.getMergedProps(["getPopupContainer"]), n = i || e, r = this.getRootElement(), u = n == null ? void 0 : n(r);
|
|
677
678
|
if (u) {
|
|
678
679
|
u.appendChild(t);
|
|
679
680
|
return;
|
|
680
681
|
}
|
|
681
682
|
}
|
|
682
|
-
this.rafId =
|
|
683
|
+
this.rafId = Pt(() => {
|
|
683
684
|
this.appendToContainer(t);
|
|
684
685
|
});
|
|
685
686
|
});
|
|
@@ -734,13 +735,13 @@ class tt extends ut {
|
|
|
734
735
|
if (lt(u, this.childrenDomSize) || (this.updatePopupPosition(), this.childrenDomSize = u), this.onContainerResize(), (i.updateOnScroll || i.containerScrollToClose) && this.onContainersScroll(i), this.handleWindowResize || (U(window, "resize", this.handleUpdatePosition), this.handleWindowResize = !0), !this.handleClickOutside) {
|
|
735
736
|
const y = W(r) && r();
|
|
736
737
|
y && (U(y, "mousedown", this.onClickOutside, {
|
|
737
|
-
capture:
|
|
738
|
+
capture: J(i.clickOutsideToClose) ? i.clickOutsideToClose.capture : !1
|
|
738
739
|
}), this.handleClickOutside = !0);
|
|
739
740
|
}
|
|
740
741
|
this.onResizeObserver2(), this.onResizeObserver3();
|
|
741
742
|
}
|
|
742
743
|
componentWillUnmount() {
|
|
743
|
-
this.unmount = !0, this.offClickOutside(), this.clearTimer(), this.offWindowResize(), this.offScrollListeners(), this.offContainerResize(),
|
|
744
|
+
this.unmount = !0, this.offClickOutside(), this.clearTimer(), this.offWindowResize(), this.offScrollListeners(), this.offContainerResize(), G(this.rafId), this.offResizeObserver2(), this.offResizeObserver3();
|
|
744
745
|
}
|
|
745
746
|
clearDelayTimer() {
|
|
746
747
|
this.delayTimer && (clearTimeout(this.delayTimer), this.delayTimer = null);
|
|
@@ -782,8 +783,8 @@ class tt extends ut {
|
|
|
782
783
|
i
|
|
783
784
|
), S = k && A.cloneElement(w, {
|
|
784
785
|
...d,
|
|
785
|
-
ref:
|
|
786
|
-
this.rootElementRef = P,
|
|
786
|
+
ref: dt(w) ? (P) => {
|
|
787
|
+
this.rootElementRef = P, yt(w, P);
|
|
787
788
|
} : void 0
|
|
788
789
|
}), L = /* @__PURE__ */ H(
|
|
789
790
|
nt,
|
|
@@ -831,7 +832,7 @@ class tt extends ut {
|
|
|
831
832
|
},
|
|
832
833
|
...x,
|
|
833
834
|
className: R,
|
|
834
|
-
...
|
|
835
|
+
...mt(this.props),
|
|
835
836
|
children: [
|
|
836
837
|
/* @__PURE__ */ H(
|
|
837
838
|
C.type,
|
|
@@ -876,6 +877,6 @@ class tt extends ut {
|
|
|
876
877
|
}
|
|
877
878
|
s(tt, "displayName", "Trigger"), s(tt, "contextType", at);
|
|
878
879
|
export {
|
|
879
|
-
|
|
880
|
+
Jt as EventsByTriggerNeed,
|
|
880
881
|
tt as default
|
|
881
882
|
};
|
package/Typography.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { jsxs as Y, jsx as l, Fragment as xt } from "react/jsx-runtime";
|
|
2
2
|
import it, { forwardRef as Z, useContext as lt, useRef as q, useState as X, useMemo as tt, useEffect as U, useCallback as vt, useImperativeHandle as St } from "react";
|
|
3
|
-
import { a as ct } from "./chunk/
|
|
3
|
+
import { a as ct } from "./chunk/Lyg-9NEt.js";
|
|
4
4
|
import bt from "./hooks/useMergeProps.js";
|
|
5
5
|
import gt from "./hooks/useMergeValue.js";
|
|
6
6
|
/* empty css */
|
|
7
|
-
import "./chunk/
|
|
7
|
+
import "./chunk/DQ3uFRJD.js";
|
|
8
8
|
import "lodash/isEqualWith";
|
|
9
|
-
import
|
|
9
|
+
import "./utils/is.js";
|
|
10
10
|
import Tt from "lodash/isNumber";
|
|
11
11
|
import "lodash/merge";
|
|
12
12
|
import { isServerRendering as Pt } from "./utils/dom.js";
|
|
@@ -21,7 +21,7 @@ import "@unicom-cloud/utils/tween/easing";
|
|
|
21
21
|
import D from "@unicom-cloud/utils/class-name";
|
|
22
22
|
import "./Affix.js";
|
|
23
23
|
import "./Alert.js";
|
|
24
|
-
import "./chunk/
|
|
24
|
+
import "./chunk/BEiJmFHq.js";
|
|
25
25
|
import "./AutoComplete.js";
|
|
26
26
|
import "./Avatar.js";
|
|
27
27
|
import "./BackTop.js";
|
|
@@ -31,42 +31,42 @@ import "./Button.js";
|
|
|
31
31
|
import "./Calendar.js";
|
|
32
32
|
import "./Card.js";
|
|
33
33
|
import "./Carousel.js";
|
|
34
|
-
import "./chunk/
|
|
35
|
-
import "./chunk/
|
|
36
|
-
import "./chunk/
|
|
34
|
+
import "./chunk/Cz65nXZD.js";
|
|
35
|
+
import "./chunk/B8IzaBdN.js";
|
|
36
|
+
import "./chunk/CLU6Le34.js";
|
|
37
37
|
import "./Comment.js";
|
|
38
38
|
import It from "./Copy.js";
|
|
39
39
|
import "./DatePicker.js";
|
|
40
40
|
import "./Descriptions.js";
|
|
41
41
|
import "./Divider.js";
|
|
42
|
-
import "./chunk/
|
|
42
|
+
import "./chunk/CBaVCRtG.js";
|
|
43
43
|
import "./Dropdown.js";
|
|
44
44
|
import "./Form.js";
|
|
45
45
|
import "./Grid.js";
|
|
46
|
-
import "./chunk/
|
|
46
|
+
import "./chunk/D6BMh1k4.js";
|
|
47
47
|
import "./Icon.js";
|
|
48
|
-
import "./chunk/
|
|
49
|
-
import { I as kt } from "./chunk/
|
|
50
|
-
import "./chunk/
|
|
48
|
+
import "./chunk/DdVbiC4t.js";
|
|
49
|
+
import { I as kt } from "./chunk/CyVLxv_U.js";
|
|
50
|
+
import "./chunk/COWsswcW.js";
|
|
51
51
|
import "./Layout.js";
|
|
52
52
|
import "./Link.js";
|
|
53
53
|
import "./List.js";
|
|
54
54
|
import "./Mentions.js";
|
|
55
|
-
import "./chunk/
|
|
56
|
-
import "./chunk/
|
|
55
|
+
import "./chunk/CmEyvBdT.js";
|
|
56
|
+
import "./chunk/BYMRs7t5.js";
|
|
57
57
|
import "./PageHeader.js";
|
|
58
|
-
import "./chunk/
|
|
58
|
+
import "./chunk/D3pUE3-b.js";
|
|
59
59
|
import "./Popconfirm.js";
|
|
60
60
|
import Lt from "./Popover.js";
|
|
61
61
|
import "./Portal.js";
|
|
62
62
|
import "./Progress.js";
|
|
63
63
|
import "./ColorPicker.js";
|
|
64
64
|
import "./Loading.js";
|
|
65
|
-
import "./chunk/
|
|
65
|
+
import "./chunk/8hWViek4.js";
|
|
66
66
|
import "./Rate.js";
|
|
67
67
|
import "./ResizeBox.js";
|
|
68
68
|
import "./Result.js";
|
|
69
|
-
import "./chunk/
|
|
69
|
+
import "./chunk/BEVtQ2QL.js";
|
|
70
70
|
import "./Skeleton.js";
|
|
71
71
|
import "./Slider.js";
|
|
72
72
|
import "./Space.js";
|
|
@@ -81,20 +81,20 @@ import "./Steps.js";
|
|
|
81
81
|
import "./SuspenseFallbackTest.js";
|
|
82
82
|
import "./Switch.js";
|
|
83
83
|
import "./Table.js";
|
|
84
|
-
import "./chunk/
|
|
84
|
+
import "./chunk/DNyP-r9G.js";
|
|
85
85
|
import "./Tag.js";
|
|
86
86
|
import "./TimePicker.js";
|
|
87
|
-
import "./chunk/
|
|
87
|
+
import "./chunk/CccPQyYX.js";
|
|
88
88
|
import ft from "./Tooltip.js";
|
|
89
89
|
import "./Transfer.js";
|
|
90
|
-
import "@unicom-cloud/utils/is";
|
|
90
|
+
import { isPlainObject as Q, isUndefined as ht } from "@unicom-cloud/utils/is";
|
|
91
91
|
import "lodash/get";
|
|
92
92
|
import "lodash/has";
|
|
93
93
|
import Rt from "lodash/isArray";
|
|
94
94
|
import "lodash/isFunction";
|
|
95
95
|
import Mt from "lodash/isUndefined";
|
|
96
|
-
import "./chunk/
|
|
97
|
-
import "./chunk/
|
|
96
|
+
import "./chunk/DfMf16uZ.js";
|
|
97
|
+
import "./chunk/BOUZ7hSf.js";
|
|
98
98
|
import "lodash/isEqual";
|
|
99
99
|
import "./utils/raf.js";
|
|
100
100
|
import yt from "./utils/throttleByRaf.js";
|
|
@@ -108,9 +108,9 @@ import mt from "lodash/isPlainObject";
|
|
|
108
108
|
import Dt from "./hooks/useKeyboardEvent.js";
|
|
109
109
|
import _t from "lodash/isString";
|
|
110
110
|
import dt from "./hooks/useIsomorphicLayoutEffect.js";
|
|
111
|
-
import "./chunk/
|
|
112
|
-
import "./chunk/
|
|
113
|
-
import "./chunk/
|
|
111
|
+
import "./chunk/CYyPBcnp.js";
|
|
112
|
+
import "./chunk/CRxPui7e.js";
|
|
113
|
+
import "./chunk/DGK45cuc.js";
|
|
114
114
|
const jt = {
|
|
115
115
|
rows: 1,
|
|
116
116
|
expandable: !0,
|
package/Upload.js
CHANGED
package/VerificationCode.js
CHANGED
package/Version.js
CHANGED
package/Watermark.js
CHANGED
|
@@ -4,7 +4,7 @@ import q from "@unicom-cloud/icons/IconUiRight";
|
|
|
4
4
|
import X from "lodash/isArray";
|
|
5
5
|
import w from "lodash/isNumber";
|
|
6
6
|
import { createContext as Y, forwardRef as Z, useContext as ee, useState as re, useRef as A, useEffect as F, useMemo as te } from "react";
|
|
7
|
-
import { a as ie } from "./
|
|
7
|
+
import { a as ie } from "./Lyg-9NEt.js";
|
|
8
8
|
import se from "../hooks/useMergeValue.js";
|
|
9
9
|
import oe from "../ResizeBox.js";
|
|
10
10
|
import H from "@unicom-cloud/utils/class-name";
|
|
@@ -2,7 +2,7 @@ import { jsx as i, jsxs as z, Fragment as O } from "react/jsx-runtime";
|
|
|
2
2
|
import j from "lodash/isFunction";
|
|
3
3
|
import w from "lodash/isNil";
|
|
4
4
|
import B, { createContext as H, useContext as G, useRef as L } from "react";
|
|
5
|
-
import { a as A, I as Q } from "./
|
|
5
|
+
import { a as A, I as Q } from "./Lyg-9NEt.js";
|
|
6
6
|
import D from "../hooks/useMergeProps.js";
|
|
7
7
|
import F from "../hooks/useMergeValue.js";
|
|
8
8
|
import I from "@unicom-cloud/utils/class-name";
|
|
@@ -4,7 +4,7 @@ import B from "@unicom-cloud/icons/IconUiMinus";
|
|
|
4
4
|
import I from "lodash/isFunction";
|
|
5
5
|
import J from "lodash/isNil";
|
|
6
6
|
import G, { createContext as K, useState as j, useContext as R, useCallback as F, useMemo as M, useRef as Q, useEffect as X } from "react";
|
|
7
|
-
import { a as U, I as Y } from "./
|
|
7
|
+
import { a as U, I as Y } from "./Lyg-9NEt.js";
|
|
8
8
|
import Z from "../hooks/useMergeProps.js";
|
|
9
9
|
import z from "../hooks/useMergeValue.js";
|
|
10
10
|
import D from "@unicom-cloud/utils/class-name";
|