@unicom-cloud/ui 0.8.77 → 0.8.79
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 +3 -3
- package/Alert.js +3 -3
- package/AutoComplete.js +5 -5
- package/BackTop.js +5 -5
- package/Badge.js +3 -3
- package/Breadcrumb.js +4 -4
- package/Button.js +2 -2
- package/Calendar.js +4 -4
- package/Card.js +2 -2
- package/Carousel.js +2 -2
- package/Cascader.js +1 -1
- package/Checkbox.js +1 -1
- package/Collapse.js +1 -1
- package/ColorPicker.js +3 -3
- package/Comment.js +2 -2
- package/ConfigProvider.js +1 -1
- package/Copy.js +4 -4
- package/DatePicker.js +1 -1
- package/Descriptions.js +2 -2
- package/Divider.js +2 -2
- package/Draggable.js +2 -2
- package/Dropdown.js +5 -5
- package/Empty.js +2 -2
- package/Icon.js +9 -5
- package/IconHover.js +2 -2
- package/Image.js +1 -1
- package/InputNumber.js +3 -3
- package/Layout.js +2 -2
- package/Link.js +3 -3
- package/List.js +4 -4
- package/Mentions.js +5 -5
- package/Menu.js +1 -1
- package/Message.js +3 -3
- package/Modal.js +1 -1
- package/Notice.js +9 -8
- package/Notification.js +3 -3
- package/OverflowEllipsis.js +2 -2
- package/PageHeader.js +3 -3
- package/Pagination.js +1 -1
- package/Popconfirm.js +3 -3
- package/Popover.js +3 -3
- package/Progress.js +2 -2
- package/Radio.js +1 -1
- package/Rate.js +3 -3
- package/ResizeBox.js +3 -3
- package/Result.js +2 -2
- package/Select.js +1 -1
- package/SelectView.js +5 -6
- package/Skeleton.js +2 -2
- package/Slider.js +4 -4
- package/Space.js +2 -2
- package/SpeechSynthesis.js +18 -20
- package/Spin.js +3 -3
- package/Statistic.js +3 -3
- package/Steps.js +2 -2
- package/Switch.js +7 -8
- package/Table.js +1 -1
- package/Tabs.js +1 -1
- package/Tag.js +3 -3
- package/Tooltip.js +3 -3
- package/Transfer.js +4 -4
- package/Tree.js +1 -1
- package/TreeSelect.js +1 -1
- package/Trigger.js +9 -10
- package/Typography.js +1 -1
- package/affix/index.js +17 -17
- package/alert/index.js +13 -13
- package/anchor/Anchor.js +40 -40
- package/anchor/Link.js +14 -14
- package/anchor/util.js +2 -2
- package/auto-complete/index.js +5 -5
- package/avatar/Avatar.js +17 -17
- package/avatar/Group.js +13 -13
- package/back-top/index.js +13 -13
- package/badge/Count.js +13 -13
- package/badge/index.js +21 -21
- package/breadcrumb/Item.js +25 -25
- package/breadcrumb/index.js +12 -12
- package/button/Group.js +6 -6
- package/button/index.js +30 -30
- package/calendar/Month.js +2 -2
- package/calendar/Year.js +1 -1
- package/calendar/index.js +4 -4
- package/card/Grid.js +13 -13
- package/card/Meta.js +13 -13
- package/card/index.js +29 -29
- package/carousel/Arrow.js +6 -6
- package/carousel/Indicator.js +27 -27
- package/carousel/index.js +24 -24
- package/cascader/Cascader.js +8 -8
- package/cascader/index.js +1 -1
- package/cascader/util.js +1 -1
- package/checkbox/Checkbox.js +4 -4
- package/checkbox/Group.js +4 -4
- package/checkbox/GroupBlock.js +3 -3
- package/checkbox/index.js +2 -2
- package/chunk/{ZrBrCzQX.js → B4WG1mhs.js} +6 -7
- package/chunk/{Cwm8LL5p.js → B4mZh-RK.js} +7245 -7249
- package/chunk/{CjqvxJml.js → BG7YGUsx.js} +32 -32
- package/chunk/{BhBEMwvI.js → BNevupAU.js} +18 -20
- package/chunk/BYdIoY50.js +17 -0
- package/chunk/{Cc_-i0o_.js → BZ3igxQN.js} +6 -7
- package/chunk/{uEGHykhe.js → BZ9g7J4R.js} +1 -1
- package/chunk/BsUZRQDT.js +23 -0
- package/chunk/{CBgu99gQ.js → C5X4hOkx.js} +130 -130
- package/chunk/{B0n0iRhF.js → CCKr5jj1.js} +1 -1
- package/chunk/{CNcLypMY.js → CQvM33Vg.js} +190 -189
- package/chunk/CXPOj2uy.js +19 -0
- package/chunk/{DAAff-FT.js → ClM74To2.js} +9 -10
- package/chunk/{RS6OAxzv.js → D-ap9qEk.js} +2 -2
- package/chunk/{tpmioyz1.js → DEiyXzBZ.js} +28 -28
- package/chunk/{CplLA01W.js → DEuVgCzp.js} +45 -52
- package/chunk/{BPQXH_5i.js → DYspELhF.js} +43 -43
- package/chunk/DxYoPlum.js +50 -0
- package/chunk/{BpYX5PN4.js → NPajzdOv.js} +2 -2
- package/chunk/{BBkdXHrJ.js → rT6qmv-Y.js} +1 -1
- package/chunk/{BC5fEyWK.js → yLRv5RIK.js} +61 -61
- package/chunk/{C_4I3haT.js → yhU2zeeu.js} +96 -96
- package/collapse/Collapse.js +4 -4
- package/collapse/Item.js +4 -4
- package/collapse/index.js +1 -1
- package/color-picker/ControlBar.js +22 -22
- package/color-picker/InputAlpha.js +1 -1
- package/color-picker/InputHex.js +1 -1
- package/color-picker/InputRgb.js +1 -1
- package/color-picker/Palette.js +1 -1
- package/color-picker/Panel.js +4 -4
- package/color-picker/index.js +3 -3
- package/comment/index.js +18 -18
- package/config-provider/ConfigProvider.js +2 -2
- package/config-provider/context.js +2 -2
- package/config-provider/index.js +2 -2
- package/copy/index.js +23 -23
- package/date-picker/Picker.js +41 -41
- package/date-picker/PickerRange.js +3 -3
- package/date-picker/index.js +1 -1
- package/descriptions/index.js +28 -28
- package/divider/index.js +15 -15
- package/draggable/Item.js +11 -11
- package/draggable/index.js +15 -15
- package/drawer/Drawer.js +31 -31
- package/dropdown/Button.js +1 -1
- package/dropdown/index.js +22 -22
- package/empty/index.js +2 -2
- package/form/Control.js +46 -46
- package/form/Form.js +12 -12
- package/form/FormItem.js +12 -12
- package/form/FormLabel.js +11 -11
- package/form/context.js +7 -6
- package/form/promisify.js +9 -10
- package/form/store.js +1 -1
- package/form/util.js +1 -1
- package/grid/Col.js +38 -38
- package/grid/Row.js +15 -15
- package/grid/grid-item.js +17 -17
- package/grid/grid.js +28 -28
- package/hooks/index.js +6 -6
- package/hooks/useInView.js +1 -1
- package/hooks/useIntersectionObserver.js +1 -1
- package/hooks/useKeyboardEvent.js +1 -1
- package/hooks/useMergeValue.js +1 -1
- package/hooks/useOverrideRef.js +1 -1
- package/hooks/usePrefersColorSchemeDark.js +1 -1
- package/hooks/useVerificationCode.js +30 -30
- package/icon/index.js +20 -16
- package/icon-hover/index.js +2 -2
- package/image/Image.js +22 -22
- package/image/ImageFooter.js +2 -2
- package/image/ImagePreview.js +11 -11
- package/image/ImagePreviewArrow.js +16 -16
- package/image/ImagePreviewGroup.js +2 -2
- package/image/ImagePreviewToolbar.js +7 -7
- package/image/TriggerForToolbar.js +7 -7
- package/image/index.js +1 -1
- package/index.js +547 -580
- package/input/Group.js +10 -10
- package/input/Input.js +213 -214
- package/input/InputElement.js +10 -11
- package/input/Password.js +4 -4
- package/input/Search.js +3 -3
- package/input/Textarea.js +7 -8
- package/input/useComposition.js +6 -6
- package/input-number/index.js +3 -3
- package/input-tag/InputTag.js +110 -111
- package/layout/Content.js +4 -4
- package/layout/Footer.js +6 -6
- package/layout/Header.js +8 -8
- package/layout/Sider.js +29 -29
- package/layout/index.js +16 -16
- package/link/index.js +27 -27
- package/list/Item.js +5 -5
- package/list/Meta.js +11 -11
- package/list/index.js +4 -4
- package/locale/en-US.js +1 -1
- package/locale/tr-TR.js +1 -1
- package/mentions/index.js +5 -5
- package/menu/Item.js +11 -11
- package/menu/ItemGroup.js +8 -8
- package/menu/Menu.js +5 -5
- package/menu/OverflowWrap.js +2 -2
- package/menu/index.js +2 -2
- package/message/index.js +3 -3
- package/message/useMessage.js +1 -1
- package/modal/Confirm.js +2 -2
- package/modal/Modal.js +7 -7
- package/modal/index.js +1 -1
- package/notice/index.js +9 -8
- package/notification/index.js +3 -3
- package/notification/useNotification.js +1 -1
- package/overflow-ellipsis/OverflowItem.js +6 -6
- package/overflow-ellipsis/index.js +27 -27
- package/package.json +1 -1
- package/page-header/index.js +3 -3
- package/pagination/PageItem.js +7 -7
- package/pagination/PageJumper.js +1 -1
- package/pagination/PageOption.js +3 -3
- package/pagination/Pagination.js +4 -4
- package/pagination/index.js +1 -1
- package/picker/Input.js +7 -7
- package/picker/InputRange.js +77 -77
- package/popconfirm/index.js +11 -11
- package/popover/index.js +21 -21
- package/progress/CircleProgress.js +14 -14
- package/progress/LineProgess.js +14 -14
- package/progress/StepProgress.js +9 -9
- package/progress/index.js +26 -26
- package/radio/Group.js +4 -4
- package/radio/GroupBlock.js +3 -3
- package/radio/Radio.js +4 -4
- package/radio/index.js +2 -2
- package/rate/index.js +16 -16
- package/resize-box/ResizeTrigger.js +27 -28
- package/resize-box/Split.js +21 -21
- package/resize-box/SplitGroup.js +40 -40
- package/resize-box/index.js +23 -23
- package/result/index.js +29 -29
- package/select/Option.js +2 -2
- package/select/Select.js +11 -12
- package/select/index.js +2 -2
- package/select/util.js +5 -5
- package/select-view/Core.js +104 -106
- package/select-view/index.js +22 -23
- package/skeleton/Image.js +14 -14
- package/skeleton/Text.js +16 -16
- package/skeleton/index.js +11 -11
- package/slider/Button.js +4 -4
- package/slider/Dot.js +9 -9
- package/slider/Input.js +20 -20
- package/slider/Tick.js +14 -14
- package/slider/index.js +103 -103
- package/slider/util.js +3 -3
- package/space/index.js +14 -14
- package/speech-synthesis/index.js +26 -28
- package/spin/DotLoading.js +1 -1
- package/spin/index.js +16 -16
- package/statistic/Countdown.js +17 -17
- package/statistic/index.js +32 -32
- package/steps/Step.js +8 -8
- package/steps/index.js +17 -17
- package/style.css +1 -1
- package/switch/index.js +32 -33
- package/table/Table.js +5 -5
- package/table/index.js +1 -1
- package/tabs/Tab.js +4 -4
- package/tabs/TabContent.js +3 -3
- package/tabs/TabPane.js +11 -11
- package/tabs/index.js +2 -2
- package/tabs/util.js +1 -1
- package/tag/index.js +16 -16
- package/time-picker/Picker.js +50 -50
- package/time-picker/TimeColumn.js +8 -8
- package/time-picker/TimePicker.js +32 -32
- package/time-picker/util.js +1 -1
- package/timeline/Item.js +15 -15
- package/timeline/Timeline.js +24 -24
- package/tooltip/index.js +23 -23
- package/transfer/Item.js +4 -4
- package/transfer/List.js +4 -4
- package/transfer/index.js +4 -4
- package/tree/Animation.js +3 -3
- package/tree/Node.js +3 -3
- package/tree/NodeList.js +2 -2
- package/tree/Tree.js +4 -4
- package/tree/index.js +1 -1
- package/tree-select/List.js +2 -2
- package/tree-select/Select.js +8 -9
- package/tree-select/index.js +2 -2
- package/trigger/getPopupStyle.js +18 -19
- package/trigger/index.js +32 -33
- package/types/button/index.d.ts +2 -2
- package/types/color-picker/colors.d.ts +1 -1
- package/types/date-picker/util.d.ts +1 -1
- package/types/icon/index.d.ts +3 -1
- package/types/index.d.ts +1 -1
- package/types/menu/context.d.ts +1 -1
- package/typography/Base.js +33 -35
- package/typography/EditContent.js +16 -16
- package/typography/Ellipsis.js +24 -26
- package/typography/Operations.js +1 -1
- package/typography/Paragraph.js +8 -8
- package/typography/Typography.js +7 -7
- package/typography/index.js +1 -1
- package/upload/TriggerNode.js +8 -8
- package/upload/Upload.js +64 -65
- package/upload/Uploader.js +12 -12
- package/upload/request.js +13 -12
- package/upload/request_.js +5 -6
- package/utils/PqbCSSTransition.js +1 -1
- package/utils/caseName.js +4 -3
- package/utils/className.js +4 -3
- package/utils/constant.js +3 -3
- package/utils/contextHolder.js +1 -1
- package/utils/copy.js +5 -4
- package/utils/fileToURL.js +4 -3
- package/utils/index.js +261 -298
- package/utils/is.js +78 -115
- package/utils/keyboardCode.js +4 -26
- package/utils/math.js +10 -32
- package/utils/react19Adapter.js +1 -1
- package/utils/reactDOM.js +1 -1
- package/utils/saveAs.js +4 -3
- package/utils/screenfull.js +4 -3
- package/utils/scrollIntoView.js +1 -1
- package/utils/setDarkTheme.js +1 -1
- package/utils/tree.js +7 -83
- package/utils/tween.js +1 -1
- package/utils/validate.js +1 -1
- package/verification-code/VerificationCode.js +25 -25
- package/version/index.js +1 -1
- package/virtual-list/VirtualList.js +1 -1
- package/watermark/Watermark.js +8 -8
- package/chunk/ATwvJ8j2.js +0 -6
- package/chunk/BFmckYou.js +0 -25
- package/chunk/Bl7BnD1R.js +0 -119
- package/chunk/Bmvhjhzq.js +0 -24
- package/chunk/BrOW642m.js +0 -130
- package/chunk/C0pRaDCf.js +0 -96
- package/chunk/CBzE-PUr.js +0 -23
- package/chunk/CUFsOxJ2.js +0 -10
- package/chunk/Ce1j9KTi.js +0 -6
- package/chunk/D0Dlbc2g.js +0 -41
- package/chunk/DRTWRsgI.js +0 -34
- package/chunk/DeV0v__J.js +0 -20
- package/chunk/DohlrJ4S.js +0 -50
- package/chunk/XTEsYGuF.js +0 -17
- package/chunk/yl4BU7Sd.js +0 -1068
|
@@ -1,24 +1,18 @@
|
|
|
1
1
|
import { jsx as p } from "react/jsx-runtime";
|
|
2
2
|
import { memo as C, forwardRef as I, useState as x, useEffect as S, useImperativeHandle as U } from "react";
|
|
3
|
-
import "../chunk/
|
|
3
|
+
import "../chunk/B4WG1mhs.js";
|
|
4
4
|
import "../utils/dom.js";
|
|
5
|
-
import "
|
|
6
|
-
import "../chunk/
|
|
7
|
-
import "../chunk/
|
|
5
|
+
import "@unicom-cloud/utils/constant/keyboardCode";
|
|
6
|
+
import "../chunk/ClM74To2.js";
|
|
7
|
+
import "../chunk/BZ3igxQN.js";
|
|
8
|
+
import "@unicom-cloud/utils/constant";
|
|
8
9
|
import "lodash/debounce";
|
|
9
|
-
import "
|
|
10
|
-
import "
|
|
11
|
-
import "lodash/kebabCase.js";
|
|
12
|
-
import "lodash/lowerFirst.js";
|
|
13
|
-
import "lodash/snakeCase.js";
|
|
14
|
-
import "lodash/startCase.js";
|
|
15
|
-
import "lodash/upperFirst.js";
|
|
16
|
-
import "lodash/uniq.js";
|
|
17
|
-
import "../chunk/C0pRaDCf.js";
|
|
18
|
-
import "lodash/isPlainObject.js";
|
|
10
|
+
import "@unicom-cloud/utils/case-name";
|
|
11
|
+
import "@unicom-cloud/utils/class-name";
|
|
19
12
|
import "../chunk/9TSjT7x_.js";
|
|
20
|
-
import "
|
|
13
|
+
import "@unicom-cloud/utils/clipboard-copy";
|
|
21
14
|
import "../chunk/tamGhTJp.js";
|
|
15
|
+
import "@unicom-cloud/utils/file/fileToURL";
|
|
22
16
|
import "lodash/escapeRegExp";
|
|
23
17
|
import "lodash/isArray";
|
|
24
18
|
import "lodash/isNumber";
|
|
@@ -38,12 +32,16 @@ import "lodash/startCase";
|
|
|
38
32
|
import "lodash/throttle";
|
|
39
33
|
import "lodash/uniq";
|
|
40
34
|
import "lodash/upperFirst";
|
|
41
|
-
import "
|
|
35
|
+
import "@unicom-cloud/utils/math";
|
|
42
36
|
import "lodash/isPlainObject";
|
|
43
37
|
import "../chunk/BJ9_azwQ.js";
|
|
44
|
-
import "
|
|
38
|
+
import "@unicom-cloud/utils/file/saveAs";
|
|
39
|
+
import "@unicom-cloud/utils/screenfull";
|
|
40
|
+
import "@unicom-cloud/utils/constant/ui";
|
|
41
|
+
import "@unicom-cloud/utils/tree";
|
|
42
|
+
import "@unicom-cloud/utils/is";
|
|
45
43
|
import "uuid";
|
|
46
|
-
import "../chunk/
|
|
44
|
+
import "../chunk/DEuVgCzp.js";
|
|
47
45
|
import g from "@unicom-cloud/icons/IconUiMute";
|
|
48
46
|
import v from "@unicom-cloud/icons/IconUiPauseCircleFill";
|
|
49
47
|
import B from "@unicom-cloud/icons/IconUiPlayCircleFill";
|
|
@@ -51,14 +49,14 @@ import F from "@unicom-cloud/icons/IconUiSound";
|
|
|
51
49
|
import H from "../button/index.js";
|
|
52
50
|
function R(a) {
|
|
53
51
|
function m(d, y) {
|
|
54
|
-
const { useButton: k = !0, buttonProps:
|
|
52
|
+
const { useButton: k = !0, buttonProps: i, ...o } = d ?? {}, [s, n] = x(!1);
|
|
55
53
|
function u() {
|
|
56
|
-
var
|
|
57
|
-
(t = (
|
|
54
|
+
var e, t;
|
|
55
|
+
(t = (e = window.speechSynthesis) == null ? void 0 : e.cancel) == null || t.call(e);
|
|
58
56
|
}
|
|
59
57
|
function w() {
|
|
60
58
|
var c, r, h;
|
|
61
|
-
let
|
|
59
|
+
let e = ((c = o.getText) == null ? void 0 : c.call(o)) || o.text, t = new SpeechSynthesisUtterance(e);
|
|
62
60
|
t.onstart = function() {
|
|
63
61
|
n(!0);
|
|
64
62
|
}, t.onerror = () => {
|
|
@@ -73,14 +71,14 @@ function R(a) {
|
|
|
73
71
|
n(!1);
|
|
74
72
|
}, (h = (r = window.speechSynthesis) == null ? void 0 : r.speak) == null || h.call(r, t);
|
|
75
73
|
}
|
|
76
|
-
function f(
|
|
74
|
+
function f(e) {
|
|
77
75
|
var t;
|
|
78
|
-
u(), s || w(), (t =
|
|
76
|
+
u(), s || w(), (t = i == null ? void 0 : i.onClick) == null || t.call(i, e);
|
|
79
77
|
}
|
|
80
78
|
let l;
|
|
81
79
|
if (window.speechSynthesis && window.SpeechSynthesisUtterance)
|
|
82
80
|
if (k) {
|
|
83
|
-
let { label:
|
|
81
|
+
let { label: e, text: t, children: c, ...r } = i ?? {};
|
|
84
82
|
l = /* @__PURE__ */ p(
|
|
85
83
|
a,
|
|
86
84
|
{
|
|
@@ -90,7 +88,7 @@ function R(a) {
|
|
|
90
88
|
icon: s ? /* @__PURE__ */ p(g, {}) : /* @__PURE__ */ p(F, {}),
|
|
91
89
|
...r,
|
|
92
90
|
onClick: f,
|
|
93
|
-
children:
|
|
91
|
+
children: e || t || c
|
|
94
92
|
}
|
|
95
93
|
);
|
|
96
94
|
} else
|
|
@@ -101,10 +99,10 @@ function R(a) {
|
|
|
101
99
|
}
|
|
102
100
|
return C(I(m));
|
|
103
101
|
}
|
|
104
|
-
const
|
|
102
|
+
const vt = R(function(m) {
|
|
105
103
|
return S(() => () => {
|
|
106
104
|
}, []), /* @__PURE__ */ p(H, { ...m, children: m.children });
|
|
107
105
|
});
|
|
108
106
|
export {
|
|
109
|
-
|
|
107
|
+
vt as default
|
|
110
108
|
};
|
package/spin/DotLoading.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as s } from "react/jsx-runtime";
|
|
2
2
|
import m from "lodash/isNumber";
|
|
3
3
|
import { useContext as a } from "react";
|
|
4
|
-
import { a as l } from "../chunk/
|
|
4
|
+
import { a as l } from "../chunk/CQvM33Vg.js";
|
|
5
5
|
function g(t) {
|
|
6
6
|
const { getPrefixCls: r } = a(l), i = `${r("spin")}-dot`, n = {
|
|
7
7
|
width: t.size,
|
package/spin/index.js
CHANGED
|
@@ -1,38 +1,38 @@
|
|
|
1
|
-
import { jsx as n, jsxs as c, Fragment as
|
|
1
|
+
import { jsx as n, jsxs as c, Fragment as N } from "react/jsx-runtime";
|
|
2
2
|
import E from "@unicom-cloud/icons/IconUiLoading";
|
|
3
3
|
import I from "lodash/debounce";
|
|
4
4
|
import $, { useContext as j, useState as w, useCallback as P, useRef as D, useImperativeHandle as F, useEffect as H } from "react";
|
|
5
|
-
import { a as M } from "../chunk/
|
|
5
|
+
import { a as M } from "../chunk/CQvM33Vg.js";
|
|
6
6
|
import { u as U } from "../chunk/BFTV6myl.js";
|
|
7
|
-
import
|
|
8
|
-
import { c as _ } from "../chunk/
|
|
7
|
+
import h from "@unicom-cloud/utils/class-name";
|
|
8
|
+
import { c as _ } from "../chunk/ClM74To2.js";
|
|
9
9
|
import q from "./DotLoading.js";
|
|
10
10
|
function A(y, S) {
|
|
11
|
-
const { getPrefixCls: x, componentConfig:
|
|
11
|
+
const { getPrefixCls: x, componentConfig: t } = j(M), v = U(y, {}, t == null ? void 0 : t.Spin), {
|
|
12
12
|
style: C,
|
|
13
13
|
className: L,
|
|
14
14
|
children: r,
|
|
15
|
-
loading:
|
|
15
|
+
loading: i,
|
|
16
16
|
size: a,
|
|
17
17
|
icon: d,
|
|
18
18
|
element: b,
|
|
19
19
|
tip: o,
|
|
20
20
|
dot: R,
|
|
21
|
-
delay:
|
|
21
|
+
delay: s,
|
|
22
22
|
block: z = !1,
|
|
23
23
|
...k
|
|
24
|
-
} = v, [m, p] = w(
|
|
24
|
+
} = v, [m, p] = w(s ? !1 : i), l = P(I(p, s), [s]), f = s ? m : i, e = x("spin"), u = D(null);
|
|
25
25
|
F(S, () => ({
|
|
26
26
|
// 潘启宝添加于 2023年10月23日 星期一 10时52分55秒 CST
|
|
27
27
|
dom: u.current,
|
|
28
28
|
loading: m,
|
|
29
29
|
setLoading: p,
|
|
30
|
-
debouncedSetLoading:
|
|
31
|
-
})), H(() => (
|
|
32
|
-
|
|
33
|
-
}), [
|
|
30
|
+
debouncedSetLoading: l
|
|
31
|
+
})), H(() => (s && l(i), () => {
|
|
32
|
+
l && l.cancel();
|
|
33
|
+
}), [i]);
|
|
34
34
|
const g = /* @__PURE__ */ n("span", { className: `${e}-icon`, children: d ? $.cloneElement(d, {
|
|
35
|
-
className:
|
|
35
|
+
className: h(`${e.replace("-spin", "-icon")}-loading`),
|
|
36
36
|
style: {
|
|
37
37
|
fontSize: a
|
|
38
38
|
}
|
|
@@ -41,7 +41,7 @@ function A(y, S) {
|
|
|
41
41
|
"div",
|
|
42
42
|
{
|
|
43
43
|
ref: u,
|
|
44
|
-
className:
|
|
44
|
+
className: h(
|
|
45
45
|
e,
|
|
46
46
|
{
|
|
47
47
|
[`${e}-block`]: z,
|
|
@@ -52,10 +52,10 @@ function A(y, S) {
|
|
|
52
52
|
),
|
|
53
53
|
style: C,
|
|
54
54
|
...k,
|
|
55
|
-
children: _(r) ? /* @__PURE__ */ c(
|
|
55
|
+
children: _(r) ? /* @__PURE__ */ c(N, { children: [
|
|
56
56
|
g,
|
|
57
57
|
o ? /* @__PURE__ */ n("div", { className: `${e}-tip`, children: o }) : null
|
|
58
|
-
] }) : /* @__PURE__ */ c(
|
|
58
|
+
] }) : /* @__PURE__ */ c(N, { children: [
|
|
59
59
|
/* @__PURE__ */ n("div", { className: `${e}-children`, children: r }),
|
|
60
60
|
f && /* @__PURE__ */ n(
|
|
61
61
|
"div",
|
package/statistic/Countdown.js
CHANGED
|
@@ -2,36 +2,36 @@ import { jsxs as M, jsx as r } from "react/jsx-runtime";
|
|
|
2
2
|
import T from "dayjs";
|
|
3
3
|
import _ from "lodash/isFunction";
|
|
4
4
|
import { forwardRef as E, useContext as F, useState as d, useRef as O, useEffect as P } from "react";
|
|
5
|
-
import { a as b } from "../chunk/
|
|
6
|
-
import
|
|
5
|
+
import { a as b } from "../chunk/CQvM33Vg.js";
|
|
6
|
+
import k from "@unicom-cloud/utils/class-name";
|
|
7
7
|
import { g as v, a as w } from "../chunk/tamGhTJp.js";
|
|
8
|
-
import { getDateString as
|
|
8
|
+
import { getDateString as N } from "./util.js";
|
|
9
9
|
function q(a, h) {
|
|
10
|
-
const { getPrefixCls:
|
|
11
|
-
className:
|
|
12
|
-
style:
|
|
10
|
+
const { getPrefixCls: p } = F(b), {
|
|
11
|
+
className: x,
|
|
12
|
+
style: C,
|
|
13
13
|
title: i,
|
|
14
|
-
styleValue:
|
|
14
|
+
styleValue: g,
|
|
15
15
|
value: y,
|
|
16
16
|
onFinish: n,
|
|
17
17
|
renderFormat: l,
|
|
18
18
|
format: e = "HH:mm:ss",
|
|
19
19
|
start: D = !0
|
|
20
|
-
} = a, o = v(y, e) || T(), S = v(a.now, e), t =
|
|
20
|
+
} = a, o = v(y, e) || T(), S = v(a.now, e), t = p("statistic"), [c, $] = d(
|
|
21
21
|
o.diff(S, "millisecond")
|
|
22
|
-
), [f,
|
|
23
|
-
|
|
22
|
+
), [f, j] = d(
|
|
23
|
+
N(Math.max(c, 0), e)
|
|
24
24
|
), s = O(null), m = () => {
|
|
25
25
|
clearInterval(s.current), s.current = null;
|
|
26
|
-
},
|
|
26
|
+
}, V = () => {
|
|
27
27
|
s.current = setInterval(() => {
|
|
28
28
|
const H = o.diff(w()), u = o.diff(w(), "millisecond");
|
|
29
29
|
u <= 0 && (m(), n == null || n());
|
|
30
|
-
const I =
|
|
31
|
-
|
|
30
|
+
const I = N(Math.max(u, 0), e);
|
|
31
|
+
j(I), $(H);
|
|
32
32
|
}, 1e3 / 30);
|
|
33
33
|
};
|
|
34
|
-
P(() => (!s.current && D && o.valueOf() >= Date.now() &&
|
|
34
|
+
P(() => (!s.current && D && o.valueOf() >= Date.now() && V(), () => {
|
|
35
35
|
m();
|
|
36
36
|
}), [a.start]);
|
|
37
37
|
const R = _(l) ? l(c, f) : f;
|
|
@@ -39,11 +39,11 @@ function q(a, h) {
|
|
|
39
39
|
"div",
|
|
40
40
|
{
|
|
41
41
|
ref: h,
|
|
42
|
-
className: k(`${t}`, `${t}-countdown`,
|
|
43
|
-
style:
|
|
42
|
+
className: k(`${t}`, `${t}-countdown`, x),
|
|
43
|
+
style: C,
|
|
44
44
|
children: [
|
|
45
45
|
i && /* @__PURE__ */ r("div", { className: `${t}-title`, children: i }),
|
|
46
|
-
/* @__PURE__ */ r("div", { className: `${t}-content`, children: /* @__PURE__ */ r("div", { className: `${t}-value`, style:
|
|
46
|
+
/* @__PURE__ */ r("div", { className: `${t}-content`, children: /* @__PURE__ */ r("div", { className: `${t}-value`, style: g, children: R }) })
|
|
47
47
|
]
|
|
48
48
|
}
|
|
49
49
|
);
|
package/statistic/index.js
CHANGED
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
import { jsxs as l, Fragment as O, jsx as a } from "react/jsx-runtime";
|
|
2
|
-
import { y as W, q as z } from "../chunk/
|
|
2
|
+
import { y as W, q as z } from "../chunk/BNevupAU.js";
|
|
3
3
|
import A from "dayjs";
|
|
4
4
|
import B from "lodash/isFunction";
|
|
5
5
|
import c from "lodash/isNumber";
|
|
6
6
|
import { forwardRef as G, useContext as J, useRef as b, useState as K, useEffect as Q, useImperativeHandle as T, useMemo as X } from "react";
|
|
7
|
-
import { a as Y } from "../chunk/
|
|
7
|
+
import { a as Y } from "../chunk/CQvM33Vg.js";
|
|
8
8
|
import { u as Z } from "../chunk/BFTV6myl.js";
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
import { o as
|
|
12
|
-
import
|
|
13
|
-
function
|
|
9
|
+
import ee from "../skeleton/index.js";
|
|
10
|
+
import te from "@unicom-cloud/utils/class-name";
|
|
11
|
+
import { o as re } from "../chunk/BKKEev13.js";
|
|
12
|
+
import oe from "./Countdown.js";
|
|
13
|
+
function ie(D, R) {
|
|
14
14
|
const U = {
|
|
15
15
|
countFrom: 0,
|
|
16
16
|
countDuration: 2e3
|
|
17
|
-
}, { getPrefixCls: P, componentConfig: m, rtl: V } = J(Y),
|
|
17
|
+
}, { getPrefixCls: P, componentConfig: m, rtl: V } = J(Y), e = Z(
|
|
18
18
|
D,
|
|
19
19
|
U,
|
|
20
20
|
m == null ? void 0 : m.Statistic
|
|
@@ -27,16 +27,16 @@ function it(D, R) {
|
|
|
27
27
|
precision: s,
|
|
28
28
|
prefix: d,
|
|
29
29
|
suffix: u,
|
|
30
|
-
format:
|
|
31
|
-
renderFormat:
|
|
30
|
+
format: f,
|
|
31
|
+
renderFormat: $,
|
|
32
32
|
styleValue: _,
|
|
33
33
|
styleDecimal: k,
|
|
34
34
|
loading: q,
|
|
35
35
|
...E
|
|
36
|
-
} =
|
|
37
|
-
"value" in
|
|
38
|
-
), r = P("statistic"), v = (i =
|
|
39
|
-
const { countDuration: x } =
|
|
36
|
+
} = e, n = b(), F = b(), [t, p] = K(
|
|
37
|
+
"value" in e ? e.value : void 0
|
|
38
|
+
), r = P("statistic"), v = (i = e.countFrom, o = e.value) => {
|
|
39
|
+
const { countDuration: x } = e;
|
|
40
40
|
i !== o && (n.current = new W({
|
|
41
41
|
from: {
|
|
42
42
|
value: i
|
|
@@ -47,44 +47,44 @@ function it(D, R) {
|
|
|
47
47
|
duration: x,
|
|
48
48
|
easing: z,
|
|
49
49
|
onUpdate: (L) => {
|
|
50
|
-
|
|
50
|
+
p(L.value.toFixed(s));
|
|
51
51
|
},
|
|
52
52
|
onFinish: () => {
|
|
53
|
-
|
|
53
|
+
p(o);
|
|
54
54
|
}
|
|
55
55
|
}), n.current.start());
|
|
56
56
|
};
|
|
57
|
-
Q(() => (
|
|
57
|
+
Q(() => (e.countUp ? (n.current && n.current.stop(), t !== e.value ? v(Number(t), e.value) : v()) : p(e.value), () => {
|
|
58
58
|
n.current && n.current.stop(), n.current = null;
|
|
59
|
-
}), [
|
|
59
|
+
}), [e.value]), T(R, () => ({
|
|
60
60
|
countUp: v,
|
|
61
|
-
getRootDOMNode: () =>
|
|
61
|
+
getRootDOMNode: () => F.current
|
|
62
62
|
}));
|
|
63
63
|
const { int: H, decimal: N } = X(() => {
|
|
64
|
-
let i =
|
|
65
|
-
|
|
64
|
+
let i = t;
|
|
65
|
+
f && (i = A(t).format(f)), c(s) && s >= 0 && (i = Number(t).toFixed(s));
|
|
66
66
|
let o = String(i).split(".")[0];
|
|
67
67
|
const x = String(i).split(".")[1];
|
|
68
|
-
return g && c(Number(
|
|
68
|
+
return g && c(Number(t)) && (o = Number(o).toLocaleString("en-US")), {
|
|
69
69
|
int: o,
|
|
70
70
|
decimal: x
|
|
71
71
|
};
|
|
72
|
-
}, [
|
|
72
|
+
}, [f, g, s, t]), I = B($) ? $ : (i, o) => o, w = c(Number(t)), C = /* @__PURE__ */ l(O, { children: [
|
|
73
73
|
d != null ? /* @__PURE__ */ a("span", { className: `${r}-value-prefix`, children: d }) : null,
|
|
74
|
-
I(
|
|
74
|
+
I(t, w ? H : t)
|
|
75
75
|
] });
|
|
76
76
|
return /* @__PURE__ */ l(
|
|
77
77
|
"div",
|
|
78
78
|
{
|
|
79
|
-
className:
|
|
79
|
+
className: te(`${r}`, { [`${r}-rtl`]: V }, j),
|
|
80
80
|
style: M,
|
|
81
|
-
...
|
|
82
|
-
ref:
|
|
81
|
+
...re(E, ["value", "countUp", "countFrom", "countDuration"]),
|
|
82
|
+
ref: F,
|
|
83
83
|
children: [
|
|
84
84
|
h && /* @__PURE__ */ a("div", { className: `${r}-title`, children: h }),
|
|
85
85
|
/* @__PURE__ */ l("div", { className: `${r}-content`, children: [
|
|
86
86
|
/* @__PURE__ */ a(
|
|
87
|
-
|
|
87
|
+
ee,
|
|
88
88
|
{
|
|
89
89
|
animation: !0,
|
|
90
90
|
loading: !!q,
|
|
@@ -97,7 +97,7 @@ function it(D, R) {
|
|
|
97
97
|
className: `${r}-value-decimal`,
|
|
98
98
|
style: k,
|
|
99
99
|
children: [
|
|
100
|
-
c(Number(
|
|
100
|
+
c(Number(t)) && N !== void 0 && `.${N}`,
|
|
101
101
|
u != null ? /* @__PURE__ */ a("span", { className: `${r}-value-suffix`, children: u }) : null
|
|
102
102
|
]
|
|
103
103
|
}
|
|
@@ -111,10 +111,10 @@ function it(D, R) {
|
|
|
111
111
|
}
|
|
112
112
|
);
|
|
113
113
|
}
|
|
114
|
-
const
|
|
114
|
+
const ne = G(ie), y = ne;
|
|
115
115
|
y.displayName = "Statistic";
|
|
116
|
-
y.Countdown =
|
|
116
|
+
y.Countdown = oe;
|
|
117
117
|
export {
|
|
118
|
-
|
|
118
|
+
oe as StatisticCountdown,
|
|
119
119
|
y as default
|
|
120
120
|
};
|
package/steps/Step.js
CHANGED
|
@@ -2,7 +2,7 @@ import { jsx as s, jsxs as h } from "react/jsx-runtime";
|
|
|
2
2
|
import R from "@unicom-cloud/icons/IconUiCheck";
|
|
3
3
|
import W from "@unicom-cloud/icons/IconUiClose";
|
|
4
4
|
import { forwardRef as q } from "react";
|
|
5
|
-
import
|
|
5
|
+
import z from "@unicom-cloud/utils/class-name";
|
|
6
6
|
function A(x, S) {
|
|
7
7
|
const {
|
|
8
8
|
style: C,
|
|
@@ -16,11 +16,11 @@ function A(x, S) {
|
|
|
16
16
|
icon: l,
|
|
17
17
|
nextStepError: w,
|
|
18
18
|
type: p,
|
|
19
|
-
customDot:
|
|
19
|
+
customDot: N,
|
|
20
20
|
labelPlacement: y,
|
|
21
|
-
disabled:
|
|
22
|
-
onClick:
|
|
23
|
-
onChange:
|
|
21
|
+
disabled: u,
|
|
22
|
+
onClick: a,
|
|
23
|
+
onChange: m,
|
|
24
24
|
direction: I,
|
|
25
25
|
id: $,
|
|
26
26
|
lineless: j
|
|
@@ -32,7 +32,7 @@ function A(x, S) {
|
|
|
32
32
|
return l ? n = l : c === "finish" ? n = /* @__PURE__ */ s(R, {}) : c === "error" && (n = /* @__PURE__ */ s(W, {})), /* @__PURE__ */ s("div", { className: `${e}-icon`, children: n });
|
|
33
33
|
}
|
|
34
34
|
function D(c) {
|
|
35
|
-
|
|
35
|
+
u || (o !== i && (m == null || m(i, $)), a == null || a(i, $, c));
|
|
36
36
|
}
|
|
37
37
|
let t;
|
|
38
38
|
d ? t = d : (o < i && (t = "wait"), o === i && (t = "process"), o > i && (t = "finish"));
|
|
@@ -42,11 +42,11 @@ function A(x, S) {
|
|
|
42
42
|
{
|
|
43
43
|
[`${e}-item-custom`]: !!l,
|
|
44
44
|
[`${e}-item-next-error`]: w,
|
|
45
|
-
[`${e}-item-disabled`]:
|
|
45
|
+
[`${e}-item-disabled`]: u,
|
|
46
46
|
[`${e}-item-active`]: i === o
|
|
47
47
|
},
|
|
48
48
|
b
|
|
49
|
-
), U = k(t), v = /* @__PURE__ */ s("div", { className: `${e}-item-icon`, children: U }), P =
|
|
49
|
+
), U = k(t), v = /* @__PURE__ */ s("div", { className: `${e}-item-icon`, children: U }), P = N ? N(v, {
|
|
50
50
|
index: i,
|
|
51
51
|
status: t,
|
|
52
52
|
title: f,
|
package/steps/index.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { jsx as w } from "react/jsx-runtime";
|
|
2
2
|
import d, { forwardRef as D, useContext as R } from "react";
|
|
3
|
-
import { a as k } from "../chunk/
|
|
3
|
+
import { a as k } from "../chunk/CQvM33Vg.js";
|
|
4
4
|
import { u as A } from "../chunk/BFTV6myl.js";
|
|
5
|
-
import
|
|
5
|
+
import E from "@unicom-cloud/utils/class-name";
|
|
6
6
|
import { a as j } from "../chunk/ClqoGc3r.js";
|
|
7
7
|
import F from "./Step.js";
|
|
8
8
|
const I = {
|
|
@@ -13,33 +13,33 @@ const I = {
|
|
|
13
13
|
labelPlacement: "horizontal"
|
|
14
14
|
};
|
|
15
15
|
function L($, y) {
|
|
16
|
-
const { getPrefixCls: z, componentConfig: a, rtl: C } = R(k),
|
|
16
|
+
const { getPrefixCls: z, componentConfig: a, rtl: C } = R(k), i = A(
|
|
17
17
|
$,
|
|
18
18
|
I,
|
|
19
19
|
a == null ? void 0 : a.Steps
|
|
20
20
|
), {
|
|
21
21
|
className: P,
|
|
22
22
|
style: h,
|
|
23
|
-
children:
|
|
23
|
+
children: N,
|
|
24
24
|
current: n = 1,
|
|
25
25
|
status: p,
|
|
26
26
|
onChange: c,
|
|
27
27
|
type: e,
|
|
28
|
-
size:
|
|
28
|
+
size: b,
|
|
29
29
|
direction: m,
|
|
30
|
-
labelPlacement:
|
|
31
|
-
customDot:
|
|
30
|
+
labelPlacement: g,
|
|
31
|
+
customDot: v,
|
|
32
32
|
lineless: f
|
|
33
|
-
} =
|
|
34
|
-
let o =
|
|
33
|
+
} = i, t = z("steps");
|
|
34
|
+
let o = g;
|
|
35
35
|
e === "dot" && (o = m === "vertical" ? "horizontal" : "vertical"), e === "navigation" && (o = "horizontal");
|
|
36
|
-
let
|
|
37
|
-
(e === "navigation" || e === "arrow") && (
|
|
36
|
+
let l = m;
|
|
37
|
+
(e === "navigation" || e === "arrow") && (l = "horizontal");
|
|
38
38
|
const x = E(
|
|
39
39
|
t,
|
|
40
|
-
`${t}-${
|
|
40
|
+
`${t}-${l}`,
|
|
41
41
|
`${t}-label-${o}`,
|
|
42
|
-
`${t}-size-${
|
|
42
|
+
`${t}-size-${b}`,
|
|
43
43
|
{
|
|
44
44
|
[`${t}-change-onclick`]: typeof c == "function",
|
|
45
45
|
[`${t}-mode-${e}`]: e !== "default",
|
|
@@ -54,8 +54,8 @@ function L($, y) {
|
|
|
54
54
|
ref: y,
|
|
55
55
|
style: h,
|
|
56
56
|
className: x,
|
|
57
|
-
...j(
|
|
58
|
-
children: d.Children.toArray(
|
|
57
|
+
...j(i),
|
|
58
|
+
children: d.Children.toArray(N).filter(
|
|
59
59
|
(r) => r && r.type && r.type.displayName === "Step"
|
|
60
60
|
).map((r, s) => {
|
|
61
61
|
if (s += 1, r) {
|
|
@@ -65,9 +65,9 @@ function L($, y) {
|
|
|
65
65
|
index: s,
|
|
66
66
|
current: n,
|
|
67
67
|
status: n === s ? p : void 0,
|
|
68
|
-
customDot:
|
|
68
|
+
customDot: v,
|
|
69
69
|
labelPlacement: o,
|
|
70
|
-
direction:
|
|
70
|
+
direction: l,
|
|
71
71
|
onChange: c,
|
|
72
72
|
lineless: f,
|
|
73
73
|
...r.props
|