@unicom-cloud/ui 0.8.81 → 0.8.82
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 +1 -1
- package/Alert.js +1 -1
- package/AutoComplete.js +2 -2
- package/BackTop.js +2 -2
- package/Badge.js +1 -1
- package/Breadcrumb.js +2 -2
- package/Button.js +1 -1
- package/Calendar.js +2 -2
- 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 +2 -2
- package/Comment.js +1 -1
- package/ConfigProvider.js +5 -4
- package/Copy.js +1 -1
- package/DatePicker.js +7 -7
- package/Descriptions.js +1 -1
- package/Divider.js +1 -1
- package/Draggable.js +1 -1
- package/Dropdown.js +1 -1
- package/Empty.js +1 -1
- package/Icon.js +1 -1
- package/IconHover.js +1 -1
- package/Image.js +1 -1
- package/InputNumber.js +1 -1
- package/Layout.js +1 -1
- package/Link.js +1 -1
- package/List.js +2 -2
- package/Mentions.js +2 -2
- package/Menu.js +1 -1
- package/Message.js +1 -1
- package/Modal.js +1 -1
- package/Notice.js +1 -1
- package/Notification.js +5 -5
- package/OverflowEllipsis.js +1 -1
- package/PageHeader.js +1 -1
- package/Pagination.js +1 -1
- package/Popconfirm.js +1 -1
- package/Popover.js +1 -1
- package/Progress.js +1 -1
- package/Radio.js +1 -1
- package/Rate.js +1 -1
- package/ResizeBox.js +1 -1
- package/Result.js +1 -1
- package/Select.js +1 -1
- package/Skeleton.js +1 -1
- package/Slider.js +1 -1
- package/Space.js +1 -1
- package/SpeechSynthesis.js +1 -1
- package/Spin.js +1 -1
- package/Statistic.js +2 -2
- package/Steps.js +1 -1
- package/Switch.js +1 -1
- package/Table.js +1 -1
- package/Tabs.js +1 -1
- package/Tag.js +1 -1
- package/Tooltip.js +1 -1
- package/Transfer.js +2 -2
- package/Tree.js +1 -1
- package/TreeSelect.js +1 -1
- package/Trigger.js +1 -1
- package/Typography.js +1 -1
- package/affix/index.js +60 -57
- package/alert/index.js +53 -53
- package/anchor/Anchor.js +72 -72
- package/anchor/Link.js +27 -27
- package/anchor/util.js +1 -1
- package/auto-complete/index.js +2 -2
- package/avatar/Avatar.js +31 -31
- package/avatar/Group.js +25 -25
- package/back-top/index.js +30 -30
- package/badge/index.js +37 -37
- package/breadcrumb/index.js +26 -26
- package/button/Group.js +7 -7
- package/button/index.js +29 -29
- package/calendar/index.js +2 -2
- package/card/Grid.js +12 -12
- package/card/Meta.js +17 -17
- package/card/index.js +44 -44
- package/carousel/Arrow.js +19 -19
- package/carousel/Indicator.js +25 -25
- package/carousel/index.js +77 -77
- package/cascader/Cascader.js +2 -2
- package/cascader/index.js +1 -1
- package/cascader/util.js +1 -1
- package/checkbox/Checkbox.js +2 -2
- package/checkbox/Group.js +2 -2
- package/checkbox/GroupBlock.js +2 -2
- package/checkbox/index.js +2 -2
- package/chunk/{yLRv5RIK.js → CQI1gsQs.js} +181 -181
- package/chunk/CmMehQON.js +1464 -0
- package/chunk/Cplu5dtQ.js +730 -0
- package/chunk/{C5X4hOkx.js → D0338Pbq.js} +80 -80
- package/chunk/{DYspELhF.js → DXDbeIai.js} +223 -223
- package/chunk/{DEiyXzBZ.js → DfrB26fI.js} +63 -63
- package/chunk/{BG7YGUsx.js → dKvAiKxr.js} +119 -119
- package/chunk/{BNevupAU.js → uKZyjtff.js} +5 -4
- package/chunk/{DLBfXSnU.js → w221i0nK.js} +2872 -2871
- package/collapse/Collapse.js +2 -2
- package/collapse/Item.js +2 -2
- package/collapse/index.js +1 -1
- package/color-picker/ControlBar.js +36 -36
- package/color-picker/InputAlpha.js +11 -11
- package/color-picker/InputHex.js +24 -24
- package/color-picker/InputRgb.js +23 -23
- package/color-picker/Palette.js +18 -18
- package/color-picker/Panel.js +2 -2
- package/color-picker/index.js +2 -2
- package/comment/index.js +31 -31
- package/config-provider/ConfigProvider.js +5 -4
- package/config-provider/context.js +2 -2
- package/config-provider/index.js +4 -3
- package/copy/index.js +28 -28
- package/date-picker/Picker.js +276 -276
- package/date-picker/{PickerRange.js → RangePicker.js} +2 -2
- package/date-picker/index.js +26 -27
- package/descriptions/index.js +33 -33
- package/divider/index.js +12 -12
- package/draggable/index.js +23 -23
- package/drawer/Drawer.js +81 -81
- package/dropdown/Button.js +1 -1
- package/dropdown/index.js +56 -56
- package/empty/index.js +1 -1
- package/form/Form.js +76 -76
- package/form/FormItem.js +64 -64
- package/grid/Col.js +53 -53
- package/grid/Row.js +34 -34
- package/grid/grid-item.js +29 -29
- package/grid/grid.js +50 -50
- package/icon/index.js +20 -19
- package/icon-hover/index.js +1 -1
- package/image/Image.js +86 -86
- package/image/ImagePreview.js +2 -2
- package/image/ImagePreviewArrow.js +22 -22
- package/image/ImagePreviewGroup.js +1 -1
- package/image/index.js +1 -1
- package/index.js +410 -408
- package/input/Group.js +8 -8
- package/input/Input.js +322 -322
- package/input/InputElement.js +1 -1
- package/input/Password.js +1 -1
- package/input/Search.js +1 -1
- package/input/Textarea.js +1 -1
- package/input-number/index.js +1 -1
- package/input-tag/InputTag.js +40 -40
- package/layout/Content.js +7 -7
- package/layout/Footer.js +9 -9
- package/layout/Header.js +7 -7
- package/layout/Sider.js +55 -55
- package/layout/index.js +32 -32
- package/link/index.js +35 -35
- package/list/Item.js +29 -29
- package/list/Meta.js +12 -12
- package/list/index.js +2 -2
- package/mentions/index.js +2 -2
- package/menu/Menu.js +2 -2
- package/menu/OverflowWrap.js +1 -1
- package/menu/index.js +2 -2
- package/message/index.js +1 -1
- package/message/useMessage.js +1 -1
- package/modal/Confirm.js +2 -2
- package/modal/Modal.js +2 -2
- package/modal/index.js +1 -1
- package/notice/index.js +1 -1
- package/notification/index.js +5 -5
- package/notification/useNotification.js +1 -1
- package/overflow-ellipsis/OverflowItem.js +12 -12
- package/overflow-ellipsis/index.js +24 -24
- package/package.json +1 -1
- package/page-header/index.js +38 -38
- package/pagination/PageItem.js +16 -16
- package/pagination/PageJumper.js +1 -1
- package/pagination/PageOption.js +2 -2
- package/pagination/Pagination.js +2 -2
- package/pagination/index.js +1 -1
- package/picker/Input.js +69 -69
- package/picker/InputRange.js +111 -111
- package/popconfirm/index.js +61 -61
- package/popover/index.js +35 -35
- package/progress/index.js +22 -22
- package/radio/Group.js +2 -2
- package/radio/GroupBlock.js +2 -2
- package/radio/Radio.js +2 -2
- package/radio/index.js +2 -2
- package/rate/index.js +49 -49
- package/resize-box/ResizeTrigger.js +34 -34
- package/resize-box/Split.js +56 -56
- package/resize-box/SplitGroup.js +55 -55
- package/resize-box/index.js +51 -51
- package/result/index.js +41 -41
- package/select/Option.js +1 -1
- package/select/Select.js +2 -2
- package/select/index.js +2 -2
- package/select/util.js +1 -1
- package/select-view/Core.js +125 -125
- package/skeleton/index.js +20 -20
- package/slider/Button.js +57 -57
- package/slider/index.js +116 -116
- package/space/index.js +46 -44
- package/speech-synthesis/index.js +1 -1
- package/spin/DotLoading.js +10 -10
- package/spin/index.js +44 -44
- package/statistic/Countdown.js +34 -34
- package/statistic/index.js +67 -67
- package/steps/index.js +55 -55
- package/style.css +1 -1
- package/switch/index.js +54 -54
- package/table/Table.js +3 -3
- package/table/index.js +1 -1
- package/tabs/Tab.js +2 -2
- package/tabs/TabContent.js +2 -2
- package/tabs/TabPane.js +12 -12
- package/tabs/index.js +2 -2
- package/tag/index.js +45 -45
- package/time-picker/Picker.js +76 -76
- package/time-picker/TimePicker.js +136 -136
- package/time-picker/index.js +8 -8
- package/time-picker/util.js +5 -5
- package/timeline/Item.js +47 -47
- package/timeline/Timeline.js +41 -41
- package/tooltip/index.js +29 -29
- package/transfer/Item.js +2 -2
- package/transfer/List.js +2 -2
- package/transfer/index.js +2 -2
- package/tree/Animation.js +2 -2
- package/tree/Node.js +2 -2
- package/tree/NodeList.js +1 -1
- package/tree/Tree.js +2 -2
- package/tree/index.js +1 -1
- package/tree-select/List.js +1 -1
- package/tree-select/Select.js +2 -2
- package/tree-select/index.js +2 -2
- package/trigger/index.js +60 -60
- package/types/config-provider/ConfigProvider.d.ts +2 -2
- package/types/config-provider/context.d.ts +1 -1
- package/types/date-picker/index.d.ts +8 -9
- package/types/date-picker/interface.d.ts +9 -9
- package/types/index.d.ts +1 -1
- package/types/picker/Input.d.ts +2 -2
- package/types/space/index.d.ts +2 -1
- package/types/utils/names.d.ts +1 -1
- package/typography/Base.js +53 -53
- package/typography/Ellipsis.js +9 -8
- package/typography/Operations.js +28 -28
- package/typography/Paragraph.js +8 -8
- package/typography/Typography.js +7 -7
- package/typography/index.js +1 -1
- package/upload/TriggerNode.js +47 -47
- package/upload/Upload.js +184 -184
- package/utils/contextHolder.js +3 -3
- package/utils/index.js +13 -13
- package/utils/names.js +1 -1
- package/utils/setPrimaryColor.js +18 -13
- package/utils/tween.js +1 -1
- package/verification-code/VerificationCode.js +49 -49
- package/version/index.js +1 -1
- package/watermark/Watermark.js +24 -24
- package/chunk/CQvM33Vg.js +0 -724
- package/chunk/yhU2zeeu.js +0 -1461
- /package/types/date-picker/{PickerRange.d.ts → RangePicker.d.ts} +0 -0
package/utils/contextHolder.js
CHANGED
package/utils/index.js
CHANGED
|
@@ -3,8 +3,8 @@ import { default as o } from "@unicom-cloud/utils/class-name";
|
|
|
3
3
|
import { c as m, y as l, R as p, e as f, d as n, j as d, k as c, S as u, N as x, n as g, a as y, b, C as S, H as R, T, l as C, A as h, p as E, W as N, w as A } from "../chunk/9TSjT7x_.js";
|
|
4
4
|
import { compareColorByRange as v } from "./tinycolor.js";
|
|
5
5
|
import { compute as D, compute as P } from "./computeScrollIntoView.js";
|
|
6
|
-
import { newArray as
|
|
7
|
-
import {
|
|
6
|
+
import { newArray as O, pickTriggerPropsFromRest as j } from "./constant.js";
|
|
7
|
+
import { e as H } from "../chunk/Cplu5dtQ.js";
|
|
8
8
|
import { default as F, default as V } from "@unicom-cloud/utils/clipboard-copy";
|
|
9
9
|
import { d as W, g as _, a as U, b as z, c as q, e as G, i as K, f as J, h as Y, m as Q, t as X, j as Z, k as $ } from "../chunk/tamGhTJp.js";
|
|
10
10
|
import { contains as ae, getScrollElements as se, isScrollElement as te, isServerRendering as re, off as oe, on as ie } from "./dom.js";
|
|
@@ -14,7 +14,7 @@ import { g as de } from "../chunk/B7M-FGia.js";
|
|
|
14
14
|
import { g as ue } from "../chunk/Dh7Osrvr.js";
|
|
15
15
|
import { g as ge } from "../chunk/DKHXj8Kf.js";
|
|
16
16
|
import { i as be } from "../chunk/CYhxqVkn.js";
|
|
17
|
-
import { i as Re, b as Te, a as Ce, c as he, d as Ee, e as Ne, f as Ae, g as ke, h as ve, j as Me, k as De, l as Pe, s as
|
|
17
|
+
import { i as Re, b as Te, a as Ce, c as he, d as Ee, e as Ne, f as Ae, g as ke, h as ve, j as Me, k as De, l as Pe, s as Ie } from "../chunk/ClM74To2.js";
|
|
18
18
|
import { default as je } from "lodash/camelCase";
|
|
19
19
|
import { default as He } from "lodash/capitalize";
|
|
20
20
|
import { default as Fe } from "lodash/cloneDeep";
|
|
@@ -37,7 +37,7 @@ import { m as Ea } from "../chunk/DH7HTOV_.js";
|
|
|
37
37
|
import { COMPONENT_NAMES as Aa } from "./names.js";
|
|
38
38
|
import { o as va } from "../chunk/BKKEev13.js";
|
|
39
39
|
import { padEnd as Da, padStart as Pa } from "./pad.js";
|
|
40
|
-
import { p as
|
|
40
|
+
import { p as Oa, a as ja } from "../chunk/ClqoGc3r.js";
|
|
41
41
|
import { P as Ha } from "../chunk/NPajzdOv.js";
|
|
42
42
|
import { c as Fa, f as Va } from "../chunk/BZ3igxQN.js";
|
|
43
43
|
import { c as Wa, m as _a, h as Ua, u as za, b as qa, b as Ga } from "../chunk/BJ9_azwQ.js";
|
|
@@ -50,14 +50,14 @@ import { setPrimaryColor as ls } from "./setPrimaryColor.js";
|
|
|
50
50
|
import { fixedWidth as fs, getStyle as ns, setTransformStyle as ds } from "./style.js";
|
|
51
51
|
import { default as us } from "./throttleByRaf.js";
|
|
52
52
|
import { findNodeBy as gs, getChildWithParentBy as ys, getItemBy as bs, getItemBy2 as Ss, getItemBy3 as Rs, getItemByID as Ts, getLabelFromDictionaryByValue as Cs } from "@unicom-cloud/utils/tree";
|
|
53
|
-
import { x as Es,
|
|
53
|
+
import { x as Es, I as Ns } from "../chunk/uKZyjtff.js";
|
|
54
54
|
import { v4 as ks, v4 as vs } from "uuid";
|
|
55
|
-
import { e as Ds, H as Ps, m as
|
|
55
|
+
import { e as Ds, H as Ps, m as Is } from "../chunk/DEuVgCzp.js";
|
|
56
56
|
import { default as js } from "./warning.js";
|
|
57
57
|
import * as e from "@unicom-cloud/utils/constant/keyboardCode";
|
|
58
58
|
import { N as Hs } from "../chunk/D0ZWT7db.js";
|
|
59
59
|
import { UI_PC_KEY as Fs, UI_PC_THEME_DARK_CLASS_NAME as Vs } from "@unicom-cloud/utils/constant/ui";
|
|
60
|
-
import { isArguments as Ws, isArray as _s, isArrayBuffer as Us, isArrayLike as zs, isArrayLikeObject as qs, isBlob as Gs, isBoolean as Ks, isBuffer as Js, isColor as Ys, isColor2 as Qs, isDate as Xs, isElement as Zs, isEmpty as $s, isEmptyArray as et, isEmptyObject as at, isEmptyValue as st, isEqual as tt, isEqualWith as rt, isError as ot, isFile as it, isFinite as mt, isFunction as lt, isInteger as pt, isJSON as ft, isLength as nt, isMap as dt, isMatch as ct, isMatchWith as ut, isNaN as xt, isNative as gt, isNil as yt, isNull as bt, isNumber as St, isObject as Rt, isObjectLike as Tt, isPlainObject as Ct, isPromise as ht, isReadableByteStreamControllerSupported as Et, isReadableStream as Nt, isReadableStreamDefaultControllerSupported as At, isReadableStreamSupported as kt, isReadableStreamSymbolAsyncIteratorSupported as vt, isRegExp as Mt, isSafeInteger as Dt, isSet as Pt, isString as
|
|
60
|
+
import { isArguments as Ws, isArray as _s, isArrayBuffer as Us, isArrayLike as zs, isArrayLikeObject as qs, isBlob as Gs, isBoolean as Ks, isBuffer as Js, isColor as Ys, isColor2 as Qs, isDate as Xs, isElement as Zs, isEmpty as $s, isEmptyArray as et, isEmptyObject as at, isEmptyValue as st, isEqual as tt, isEqualWith as rt, isError as ot, isFile as it, isFinite as mt, isFunction as lt, isInteger as pt, isJSON as ft, isLength as nt, isMap as dt, isMatch as ct, isMatchWith as ut, isNaN as xt, isNative as gt, isNil as yt, isNull as bt, isNumber as St, isObject as Rt, isObjectLike as Tt, isPlainObject as Ct, isPromise as ht, isReadableByteStreamControllerSupported as Et, isReadableStream as Nt, isReadableStreamDefaultControllerSupported as At, isReadableStreamSupported as kt, isReadableStreamSymbolAsyncIteratorSupported as vt, isRegExp as Mt, isSafeInteger as Dt, isSet as Pt, isString as It, isSymbol as Ot, isTypedArray as jt, isUndefined as Bt, isValidColor as Ht, isWeakMap as wt, isWeakSet as Ft } from "@unicom-cloud/utils/is";
|
|
61
61
|
import { isAsyncMode as Lt, isConcurrentMode as Wt, isContextConsumer as _t, isContextProvider as Ut, isElement as zt, isForwardRef as qt, isFragment as Gt, isLazy as Kt, isMemo as Jt, isPortal as Yt, isProfiler as Qt, isStrictMode as Xt, isSuspense as Zt, isValidElementType as $t } from "react-is";
|
|
62
62
|
export {
|
|
63
63
|
Aa as COMPONENT_NAMES,
|
|
@@ -197,9 +197,9 @@ export {
|
|
|
197
197
|
te as isScrollElement,
|
|
198
198
|
re as isServerRendering,
|
|
199
199
|
Pt as isSet,
|
|
200
|
-
|
|
200
|
+
It as isString,
|
|
201
201
|
De as isSupportRef,
|
|
202
|
-
|
|
202
|
+
Ot as isSymbol,
|
|
203
203
|
jt as isTypedArray,
|
|
204
204
|
Bt as isUndefined,
|
|
205
205
|
g as isValidCSSUnit,
|
|
@@ -218,7 +218,7 @@ export {
|
|
|
218
218
|
Q as methods,
|
|
219
219
|
ga as minus,
|
|
220
220
|
ya as multiply,
|
|
221
|
-
|
|
221
|
+
O as newArray,
|
|
222
222
|
y as numberInputToObject,
|
|
223
223
|
oe as off,
|
|
224
224
|
va as omit,
|
|
@@ -226,7 +226,7 @@ export {
|
|
|
226
226
|
Da as padEnd,
|
|
227
227
|
Pa as padStart,
|
|
228
228
|
b as parseIntFromHex,
|
|
229
|
-
|
|
229
|
+
Oa as pick,
|
|
230
230
|
ja as pickDataAttributes,
|
|
231
231
|
j as pickTriggerPropsFromRest,
|
|
232
232
|
ba as plus,
|
|
@@ -255,7 +255,7 @@ export {
|
|
|
255
255
|
ra as startCase,
|
|
256
256
|
A as stringInputToObject,
|
|
257
257
|
Sa as subtract,
|
|
258
|
-
|
|
258
|
+
Ie as supportRef,
|
|
259
259
|
ia as throttle,
|
|
260
260
|
us as throttleByRaf,
|
|
261
261
|
Ra as times,
|
|
@@ -267,6 +267,6 @@ export {
|
|
|
267
267
|
fa as upperFirst,
|
|
268
268
|
ks as uuid,
|
|
269
269
|
vs as uuidv4,
|
|
270
|
-
|
|
270
|
+
Is as validate,
|
|
271
271
|
js as warning
|
|
272
272
|
};
|
package/utils/names.js
CHANGED
package/utils/setPrimaryColor.js
CHANGED
|
@@ -1,26 +1,31 @@
|
|
|
1
|
-
import { R as o, c as
|
|
2
|
-
|
|
1
|
+
import { R as o, c as f } from "../chunk/9TSjT7x_.js";
|
|
2
|
+
import { UI_COMMON_PREFIX as p, UI_PC_PREFIX as y } from "@unicom-cloud/utils/constant/ui";
|
|
3
|
+
function P(e) {
|
|
3
4
|
const {
|
|
4
5
|
color: t,
|
|
5
6
|
element: n = window.document.documentElement,
|
|
6
|
-
isDark:
|
|
7
|
-
|
|
7
|
+
isDark: m = !1,
|
|
8
|
+
prefix: a = p
|
|
9
|
+
} = e ?? {}, l = {
|
|
8
10
|
color: t
|
|
9
|
-
},
|
|
10
|
-
new
|
|
11
|
-
n.style.setProperty(
|
|
11
|
+
}, i = m ? o.generateDark(l) : o.generate(l);
|
|
12
|
+
new f(t).equals(o.pqbblue.value) ? s() : i.forEach((c, r, u) => {
|
|
13
|
+
n.style.setProperty(
|
|
14
|
+
`--${a}-pqbblue-${r + 1}`,
|
|
15
|
+
c.toRgbArrayString()
|
|
16
|
+
);
|
|
12
17
|
});
|
|
13
18
|
function s() {
|
|
14
|
-
|
|
15
|
-
n.style.removeProperty(
|
|
19
|
+
i.forEach((c, r, u) => {
|
|
20
|
+
n.style.removeProperty(`--${a}-pqbblue-${r + 1}`);
|
|
16
21
|
});
|
|
17
22
|
}
|
|
18
23
|
return s;
|
|
19
24
|
}
|
|
20
|
-
function
|
|
21
|
-
return
|
|
25
|
+
function E(e) {
|
|
26
|
+
return P({ ...e, prefix: y });
|
|
22
27
|
}
|
|
23
28
|
export {
|
|
24
|
-
|
|
25
|
-
|
|
29
|
+
E as default,
|
|
30
|
+
E as setPrimaryColor
|
|
26
31
|
};
|
package/utils/tween.js
CHANGED
|
@@ -1,81 +1,81 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import
|
|
3
|
-
import { a as
|
|
4
|
-
import { u as
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import { useVerificationCode as
|
|
8
|
-
const
|
|
1
|
+
import { jsx as w, jsxs as x } from "react/jsx-runtime";
|
|
2
|
+
import F, { forwardRef as j, useContext as z, useRef as D, createElement as E } from "react";
|
|
3
|
+
import { a as K } from "../chunk/Cplu5dtQ.js";
|
|
4
|
+
import { u as L } from "../chunk/BFTV6myl.js";
|
|
5
|
+
import M from "../input/InputElement.js";
|
|
6
|
+
import g from "@unicom-cloud/utils/class-name";
|
|
7
|
+
import { useVerificationCode as _ } from "../hooks/useVerificationCode.js";
|
|
8
|
+
const q = {
|
|
9
9
|
length: 6
|
|
10
10
|
};
|
|
11
|
-
function
|
|
12
|
-
var d;
|
|
13
|
-
const
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
(d =
|
|
17
|
-
), { size: l, separator: r, status:
|
|
11
|
+
function y(h, A) {
|
|
12
|
+
var d, m, u;
|
|
13
|
+
const t = z(K), e = L(
|
|
14
|
+
h,
|
|
15
|
+
q,
|
|
16
|
+
(d = t.componentConfig) == null ? void 0 : d.VerificationCode
|
|
17
|
+
), { size: l, separator: r, status: f, length: v, masked: $, disabled: P } = e, c = D([]), { value: O, filledValue: V, getInputProps: k } = _({
|
|
18
18
|
defaultValue: e.defaultValue,
|
|
19
19
|
value: e.value,
|
|
20
|
-
length:
|
|
21
|
-
getInputRefList: () =>
|
|
20
|
+
length: v,
|
|
21
|
+
getInputRefList: () => c.current,
|
|
22
22
|
onChange: e.onChange,
|
|
23
23
|
onFinish: e.onFinish
|
|
24
|
-
}), a =
|
|
25
|
-
return /* @__PURE__ */
|
|
24
|
+
}), a = (m = t.getPrefixCls) == null ? void 0 : m.call(t, "verification-code"), n = (u = t.getPrefixCls) == null ? void 0 : u.call(t, "input");
|
|
25
|
+
return /* @__PURE__ */ w(
|
|
26
26
|
"div",
|
|
27
27
|
{
|
|
28
|
-
className:
|
|
29
|
-
[`${a}-rtl`]:
|
|
28
|
+
className: g(`${a}`, e.className, {
|
|
29
|
+
[`${a}-rtl`]: t.rtl
|
|
30
30
|
}),
|
|
31
31
|
style: e.style,
|
|
32
|
-
children:
|
|
33
|
-
const { onChange:
|
|
34
|
-
return /* @__PURE__ */
|
|
35
|
-
/* @__PURE__ */
|
|
36
|
-
|
|
32
|
+
children: V.map((I, s) => {
|
|
33
|
+
const { onChange: p, onClick: N, onPaste: R, onKeyDown: b, ...C } = k(s);
|
|
34
|
+
return /* @__PURE__ */ x(F.Fragment, { children: [
|
|
35
|
+
/* @__PURE__ */ E(
|
|
36
|
+
M,
|
|
37
37
|
{
|
|
38
38
|
disabled: e.disabled,
|
|
39
39
|
readOnly: e.readOnly,
|
|
40
|
-
className:
|
|
40
|
+
className: g(n, `${a}-input`, {
|
|
41
41
|
[`${n}-size-${l}`]: l,
|
|
42
|
-
[`${n}-${
|
|
43
|
-
[`${n}-disabled`]:
|
|
44
|
-
[`${n}-rtl`]:
|
|
42
|
+
[`${n}-${f}`]: f,
|
|
43
|
+
[`${n}-disabled`]: P,
|
|
44
|
+
[`${n}-rtl`]: t.rtl
|
|
45
45
|
}),
|
|
46
|
-
ref: (
|
|
47
|
-
|
|
46
|
+
ref: (o) => {
|
|
47
|
+
c.current[s] = o == null ? void 0 : o.dom;
|
|
48
48
|
},
|
|
49
|
-
...
|
|
50
|
-
key:
|
|
51
|
-
onClick: e.readOnly ? void 0 :
|
|
52
|
-
onPaste: e.readOnly ? void 0 :
|
|
53
|
-
onKeyDown: e.readOnly ? void 0 :
|
|
54
|
-
onChange: e.readOnly ? void 0 : (
|
|
49
|
+
...C,
|
|
50
|
+
key: C.key,
|
|
51
|
+
onClick: e.readOnly ? void 0 : N,
|
|
52
|
+
onPaste: e.readOnly ? void 0 : R,
|
|
53
|
+
onKeyDown: e.readOnly ? void 0 : b,
|
|
54
|
+
onChange: e.readOnly ? void 0 : (o) => {
|
|
55
55
|
if (e.validate) {
|
|
56
56
|
const i = e == null ? void 0 : e.validate({
|
|
57
|
-
inputValue:
|
|
57
|
+
inputValue: o,
|
|
58
58
|
index: s,
|
|
59
|
-
value:
|
|
59
|
+
value: O
|
|
60
60
|
});
|
|
61
|
-
i !== !1 &&
|
|
62
|
-
typeof i == "string" ? i :
|
|
61
|
+
i !== !1 && p(
|
|
62
|
+
typeof i == "string" ? i : o
|
|
63
63
|
);
|
|
64
64
|
} else
|
|
65
|
-
|
|
65
|
+
p(o);
|
|
66
66
|
},
|
|
67
|
-
type:
|
|
67
|
+
type: $ ? "password" : "text"
|
|
68
68
|
}
|
|
69
69
|
),
|
|
70
|
-
r == null ? void 0 : r({ index: s, character:
|
|
70
|
+
r == null ? void 0 : r({ index: s, character: I })
|
|
71
71
|
] }, s);
|
|
72
72
|
})
|
|
73
73
|
}
|
|
74
74
|
);
|
|
75
75
|
}
|
|
76
|
-
|
|
77
|
-
const
|
|
76
|
+
y.displayName = "VerificationCodeComponent";
|
|
77
|
+
const U = j(y);
|
|
78
78
|
export {
|
|
79
|
-
|
|
80
|
-
|
|
79
|
+
y as VerificationCodeComponent,
|
|
80
|
+
U as default
|
|
81
81
|
};
|
package/version/index.js
CHANGED
package/watermark/Watermark.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import { forwardRef as g, useContext as
|
|
3
|
-
import { a as
|
|
1
|
+
import { jsx as u } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef as g, useContext as p, useRef as d, useCallback as C, useEffect as h } from "react";
|
|
3
|
+
import { a as k } from "../chunk/Cplu5dtQ.js";
|
|
4
4
|
import { useWatermark as x } from "../hooks/useWatermark.js";
|
|
5
|
-
import { u as
|
|
6
|
-
import
|
|
7
|
-
const
|
|
5
|
+
import { u as w } from "../chunk/BFTV6myl.js";
|
|
6
|
+
import y from "@unicom-cloud/utils/class-name";
|
|
7
|
+
const N = {}, O = [
|
|
8
8
|
"zIndex",
|
|
9
9
|
"width",
|
|
10
10
|
"height",
|
|
@@ -16,21 +16,21 @@ const y = {}, N = [
|
|
|
16
16
|
"offset",
|
|
17
17
|
"getContainer"
|
|
18
18
|
];
|
|
19
|
-
function
|
|
20
|
-
var f;
|
|
21
|
-
const
|
|
19
|
+
function S(c, W) {
|
|
20
|
+
var f, m;
|
|
21
|
+
const e = p(k), t = w(
|
|
22
22
|
c,
|
|
23
|
-
|
|
24
|
-
(f =
|
|
25
|
-
), n =
|
|
26
|
-
var
|
|
27
|
-
return n.current || ((
|
|
28
|
-
}, [n.current, t.getContainer]), s =
|
|
23
|
+
N,
|
|
24
|
+
(f = e.componentConfig) == null ? void 0 : f.Watermark
|
|
25
|
+
), n = d(null), o = C(() => {
|
|
26
|
+
var r;
|
|
27
|
+
return n.current || ((r = t.getContainer) == null ? void 0 : r.call(t));
|
|
28
|
+
}, [n.current, t.getContainer]), s = O.reduce((r, a) => (a in t && (r[a] = t[a]), r), {}), { setWatermark: l } = x({
|
|
29
29
|
...s,
|
|
30
30
|
getContainer: o
|
|
31
31
|
});
|
|
32
|
-
|
|
33
|
-
|
|
32
|
+
h(() => {
|
|
33
|
+
l({
|
|
34
34
|
...s,
|
|
35
35
|
getContainer: o
|
|
36
36
|
});
|
|
@@ -46,12 +46,12 @@ function O(c, S) {
|
|
|
46
46
|
JSON.stringify(t.offset),
|
|
47
47
|
o
|
|
48
48
|
]);
|
|
49
|
-
const i =
|
|
50
|
-
return t.children ? /* @__PURE__ */
|
|
49
|
+
const i = (m = e.getPrefixCls) == null ? void 0 : m.call(e, "watermark");
|
|
50
|
+
return t.children ? /* @__PURE__ */ u(
|
|
51
51
|
"div",
|
|
52
52
|
{
|
|
53
|
-
className:
|
|
54
|
-
[`${i}-rtl`]:
|
|
53
|
+
className: y(`${i}`, t.className, {
|
|
54
|
+
[`${i}-rtl`]: e.rtl
|
|
55
55
|
}),
|
|
56
56
|
style: t.style,
|
|
57
57
|
ref: n,
|
|
@@ -59,8 +59,8 @@ function O(c, S) {
|
|
|
59
59
|
}
|
|
60
60
|
) : null;
|
|
61
61
|
}
|
|
62
|
-
const
|
|
62
|
+
const b = g(S);
|
|
63
63
|
export {
|
|
64
|
-
|
|
65
|
-
|
|
64
|
+
S as WatermarkComponent,
|
|
65
|
+
b as default
|
|
66
66
|
};
|