@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
package/form/Control.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
var M = Object.defineProperty;
|
|
2
|
-
var
|
|
3
|
-
var s = (p, g, e) =>
|
|
2
|
+
var N = (p, g, e) => g in p ? M(p, g, { enumerable: !0, configurable: !0, writable: !0, value: e }) : p[g] = e;
|
|
3
|
+
var s = (p, g, e) => N(p, typeof g != "symbol" ? g + "" : g, e);
|
|
4
4
|
import { jsx as m, jsxs as E } from "react/jsx-runtime";
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import
|
|
5
|
+
import P from "@unicom-cloud/icons/IconUiCheckCircleFill";
|
|
6
|
+
import W from "@unicom-cloud/icons/IconUiCloseCircleFill";
|
|
7
|
+
import $ from "@unicom-cloud/icons/IconUiExclamationCircleFill";
|
|
8
8
|
import L from "@unicom-cloud/icons/IconUiLoading";
|
|
9
9
|
import V from "lodash/get";
|
|
10
10
|
import b from "lodash/isArray";
|
|
@@ -14,13 +14,13 @@ import F from "lodash/isFunction";
|
|
|
14
14
|
import _ from "lodash/isNil";
|
|
15
15
|
import j from "lodash/set";
|
|
16
16
|
import I, { Component as z, isValidElement as A } from "react";
|
|
17
|
-
import
|
|
17
|
+
import G from "@unicom-cloud/utils/class-name";
|
|
18
18
|
import U from "../utils/warning.js";
|
|
19
19
|
import { FormItemContext as O } from "./context.js";
|
|
20
20
|
import { isFieldMatch as C, schemaValidate as k, isSyntheticEvent as q, ID_SUFFIX as B } from "./util.js";
|
|
21
21
|
class x extends z {
|
|
22
22
|
constructor(e, t) {
|
|
23
|
-
var i,
|
|
23
|
+
var i, o, l;
|
|
24
24
|
super(e);
|
|
25
25
|
s(this, "context");
|
|
26
26
|
// 校验信息
|
|
@@ -78,12 +78,12 @@ class x extends z {
|
|
|
78
78
|
return e ? t.getInnerMethods(!0).innerGetFieldValue(e) : void 0;
|
|
79
79
|
});
|
|
80
80
|
s(this, "onStoreChange", (e, t) => {
|
|
81
|
-
const i = b(t.field) ? t.field : [t.field], { field:
|
|
82
|
-
if (r &&
|
|
81
|
+
const i = b(t.field) ? t.field : [t.field], { field: o, shouldUpdate: l, dependencies: r } = this.props, a = (d) => {
|
|
82
|
+
if (r && l && U(!0, "`shouldUpdate` of the `Form.Item` will be ignored."), r)
|
|
83
83
|
b(r) && r.some((n) => C(n, i)) && this.isTouched() && this.validateField();
|
|
84
|
-
else if (
|
|
84
|
+
else if (l) {
|
|
85
85
|
let n = !1;
|
|
86
|
-
F(
|
|
86
|
+
F(l) ? n = l(t.prev, t.current, {
|
|
87
87
|
field: t.field,
|
|
88
88
|
...d
|
|
89
89
|
}) : n = !y(t.prev, t.current), n && this.updateFormItem();
|
|
@@ -91,10 +91,10 @@ class x extends z {
|
|
|
91
91
|
};
|
|
92
92
|
switch (e) {
|
|
93
93
|
case "reset":
|
|
94
|
-
this.toggleTouched(!1), this.toggleValidateStatus(void 0), this.setErrors(null), this.setWarnings(null), r ||
|
|
94
|
+
this.toggleTouched(!1), this.toggleValidateStatus(void 0), this.setErrors(null), this.setWarnings(null), r || l ? a() : this.updateFormItem();
|
|
95
95
|
break;
|
|
96
96
|
case "innerSetValue":
|
|
97
|
-
if (C(
|
|
97
|
+
if (C(o, i)) {
|
|
98
98
|
this.toggleTouched(!0), this.updateFormItem();
|
|
99
99
|
return;
|
|
100
100
|
}
|
|
@@ -104,10 +104,10 @@ class x extends z {
|
|
|
104
104
|
});
|
|
105
105
|
break;
|
|
106
106
|
case "setFieldValue":
|
|
107
|
-
if (C(
|
|
107
|
+
if (C(o, i)) {
|
|
108
108
|
this.toggleTouched(!0), t.data && "touched" in t.data && this.toggleTouched(t.data.touched), t.data && "warnings" in t.data && this.setWarnings(
|
|
109
109
|
_(t.data.warnings) ? [] : [].concat(t.data.warnings)
|
|
110
|
-
), t.data && "errors" in t.data ? this.setErrors(t.data.errors) : y(V(t.prev,
|
|
110
|
+
), t.data && "errors" in t.data ? this.setErrors(t.data.errors) : y(V(t.prev, o), V(t.current, o)) || this.setErrors(null), this.updateFormItem();
|
|
111
111
|
return;
|
|
112
112
|
}
|
|
113
113
|
a();
|
|
@@ -119,16 +119,16 @@ class x extends z {
|
|
|
119
119
|
if (!e) return;
|
|
120
120
|
const { store: i } = this.context;
|
|
121
121
|
i.getInnerMethods(!0).innerSetFieldValue(e, t);
|
|
122
|
-
const
|
|
123
|
-
j(
|
|
122
|
+
const l = {};
|
|
123
|
+
j(l, e, t), (a = (r = this.props) == null ? void 0 : r.onValuesChange) == null || a.call(r, l, {
|
|
124
124
|
...i.getFieldsValue()
|
|
125
125
|
});
|
|
126
126
|
});
|
|
127
127
|
// 仅仅校验下值,不做任何状态变更
|
|
128
128
|
s(this, "validateFieldOnly", () => {
|
|
129
|
-
const { validateMessages: e } = this.context, { field: t, rules: i } = this.props,
|
|
130
|
-
return k(t,
|
|
131
|
-
({ error:
|
|
129
|
+
const { validateMessages: e } = this.context, { field: t, rules: i } = this.props, o = this.getFieldValue();
|
|
130
|
+
return k(t, o, i, e).then(
|
|
131
|
+
({ error: l, warning: r }) => Promise.resolve({ error: l, value: o, warning: r, field: t })
|
|
132
132
|
);
|
|
133
133
|
});
|
|
134
134
|
/**
|
|
@@ -137,26 +137,26 @@ class x extends z {
|
|
|
137
137
|
* @returns
|
|
138
138
|
*/
|
|
139
139
|
s(this, "validateField", (e) => {
|
|
140
|
-
const { validateTrigger: t, validateMessages: i } = this.context, { field:
|
|
140
|
+
const { validateTrigger: t, validateMessages: i } = this.context, { field: o, rules: l, validateTrigger: r } = this.props, a = this.getFieldValue(), d = () => {
|
|
141
141
|
var c;
|
|
142
142
|
const h = this.errors || ((c = this.warnings) == null ? void 0 : c.length);
|
|
143
143
|
this.toggleValidateStatus("validating"), this.setErrors(null), this.setWarnings(null), h && this.updateFormItem();
|
|
144
|
-
}, n = e ? (
|
|
144
|
+
}, n = e ? (l || []).filter((h) => [].concat(
|
|
145
145
|
h.validateTrigger || r || t
|
|
146
|
-
).indexOf(e) > -1) :
|
|
147
|
-
return n && n.length &&
|
|
146
|
+
).indexOf(e) > -1) : l;
|
|
147
|
+
return n && n.length && o ? (d(), k(o, a, n, i).then(
|
|
148
148
|
({ error: h, warning: c }) => {
|
|
149
149
|
var u;
|
|
150
|
-
return this.setErrors(h ? h[
|
|
150
|
+
return this.setErrors(h ? h[o] : null), this.setWarnings(c || null), this.toggleValidateStatus(
|
|
151
151
|
this.errors ? "error" : (u = this.warnings) != null && u.length ? "warning" : "success"
|
|
152
|
-
), this.updateFormItem(), Promise.resolve({ error: h, value: a, field:
|
|
152
|
+
), this.updateFormItem(), Promise.resolve({ error: h, value: a, field: o });
|
|
153
153
|
}
|
|
154
|
-
)) : Promise.resolve({ error: null, value: a, field:
|
|
154
|
+
)) : Promise.resolve({ error: null, value: a, field: o });
|
|
155
155
|
});
|
|
156
156
|
// 每次 render 都会作为 onChange 传递给 children,需要保证引用地址不变
|
|
157
157
|
// 所以 handleTrigger 需要声明在类上,并且直接作为 children.props.onChange
|
|
158
158
|
s(this, "handleTrigger", (e, ...t) => {
|
|
159
|
-
const i = this.childrenElement || this.props.children, { store:
|
|
159
|
+
const i = this.childrenElement || this.props.children, { store: o } = this.context, { field: l, trigger: r, normalize: a, getValueFromEvent: d } = this.props, n = F(d) ? d(e, ...t) : e;
|
|
160
160
|
let h = n;
|
|
161
161
|
if (q(n)) {
|
|
162
162
|
U(
|
|
@@ -165,9 +165,9 @@ class x extends z {
|
|
|
165
165
|
), n.stopPropagation();
|
|
166
166
|
return;
|
|
167
167
|
}
|
|
168
|
-
typeof a == "function" && (h = a(n,
|
|
169
|
-
...
|
|
170
|
-
})), this.toggleTouched(!0), this.innerSetFieldValue(
|
|
168
|
+
typeof a == "function" && (h = a(n, o.getFieldValue(l), {
|
|
169
|
+
...o.getFieldsValue()
|
|
170
|
+
})), this.toggleTouched(!0), this.innerSetFieldValue(l, h), this.validateField(r), A(i) && i.props && i.props[r] && (this.props.isFormList || i.props[r](h, ...t));
|
|
171
171
|
});
|
|
172
172
|
s(this, "getChild", () => {
|
|
173
173
|
const { children: e } = this.props, { store: t } = this.context;
|
|
@@ -184,8 +184,8 @@ class x extends z {
|
|
|
184
184
|
)), this.childrenElement = i, i;
|
|
185
185
|
});
|
|
186
186
|
if ("initialValue" in e && this.hasFieldProps()) {
|
|
187
|
-
const r = (
|
|
188
|
-
(
|
|
187
|
+
const r = (o = (i = t == null ? void 0 : t.store) == null ? void 0 : i.getInnerMethods) == null ? void 0 : o.call(i, !0);
|
|
188
|
+
(l = r == null ? void 0 : r.innerSetInitialValue) == null || l.call(r, e.field, e.initialValue);
|
|
189
189
|
}
|
|
190
190
|
}
|
|
191
191
|
componentDidMount() {
|
|
@@ -210,16 +210,16 @@ class x extends z {
|
|
|
210
210
|
getValidateTrigger() {
|
|
211
211
|
const e = this.props.validateTrigger || this.context.validateTrigger || "onChange", t = this.props.rules || [];
|
|
212
212
|
let i = [];
|
|
213
|
-
return t.map((
|
|
214
|
-
i = i.concat(
|
|
213
|
+
return t.map((o) => {
|
|
214
|
+
i = i.concat(o.validateTrigger || e);
|
|
215
215
|
}), Array.from(new Set(i));
|
|
216
216
|
}
|
|
217
217
|
renderControl(e, t) {
|
|
218
218
|
var T;
|
|
219
219
|
const {
|
|
220
220
|
field: i,
|
|
221
|
-
trigger:
|
|
222
|
-
triggerPropName:
|
|
221
|
+
trigger: o = "onChange",
|
|
222
|
+
triggerPropName: l = "value",
|
|
223
223
|
validateStatus: r,
|
|
224
224
|
formatter: a
|
|
225
225
|
} = this.props, { store: d, disabled: n } = this.context, h = "disabled" in this.props ? this.props.disabled : n, c = I.Children.only(e), u = {
|
|
@@ -231,25 +231,25 @@ class x extends z {
|
|
|
231
231
|
var f, w;
|
|
232
232
|
this.validateField(S), (w = (f = c.props) == null ? void 0 : f[S]) == null || w.call(f, D);
|
|
233
233
|
};
|
|
234
|
-
}), u[
|
|
234
|
+
}), u[o] = this.handleTrigger, h !== void 0 && !("disabled" in c.props) && (u.disabled = h);
|
|
235
235
|
let v = V(d.getInnerMethods(!0).innerGetStore(), i);
|
|
236
|
-
return F(a) && (v = a(v)), u[
|
|
236
|
+
return F(a) && (v = a(v)), u[l] = v, !r && this.errors && (u.error = !0), I.cloneElement(c, u);
|
|
237
237
|
}
|
|
238
238
|
render() {
|
|
239
|
-
const { noStyle: e, field: t, isFormList: i, hasFeedback:
|
|
239
|
+
const { noStyle: e, field: t, isFormList: i, hasFeedback: o } = this.props, l = this.getValidateStatus(), { prefixCls: r, getFormElementId: a } = this.context;
|
|
240
240
|
let d = this.getChild();
|
|
241
241
|
const n = this.hasFieldProps() ? a == null ? void 0 : a(t) : void 0;
|
|
242
242
|
return this.hasFieldProps() && !i && I.Children.count(d) === 1 && (d = this.renderControl(d, n)), e ? d : /* @__PURE__ */ m("div", { className: `${r}-item-control-wrapper`, children: /* @__PURE__ */ m("div", { className: `${r}-item-control`, id: n, children: /* @__PURE__ */ E("div", { className: `${r}-item-control-children`, children: [
|
|
243
243
|
d,
|
|
244
|
-
|
|
244
|
+
l && o && /* @__PURE__ */ E(
|
|
245
245
|
"div",
|
|
246
246
|
{
|
|
247
|
-
className: `${r}-item-feedback ${r}-item-feedback-${
|
|
247
|
+
className: `${r}-item-feedback ${r}-item-feedback-${l}`,
|
|
248
248
|
children: [
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
249
|
+
l === "warning" && /* @__PURE__ */ m($, {}),
|
|
250
|
+
l === "success" && /* @__PURE__ */ m(P, {}),
|
|
251
|
+
l === "error" && /* @__PURE__ */ m(W, {}),
|
|
252
|
+
l === "validating" && /* @__PURE__ */ m(L, {})
|
|
253
253
|
]
|
|
254
254
|
}
|
|
255
255
|
)
|
package/form/Form.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { jsx as
|
|
1
|
+
import { jsx as p } from "react/jsx-runtime";
|
|
2
2
|
import { p as k } from "../chunk/Coz3rCng.js";
|
|
3
3
|
import v from "lodash/isPlainObject";
|
|
4
4
|
import O from "lodash/merge";
|
|
5
5
|
import { forwardRef as A, useContext as $, useRef as _, useEffect as H, useImperativeHandle as U } from "react";
|
|
6
|
-
import { a as W, b as X } from "../chunk/
|
|
6
|
+
import { a as W, b as X } from "../chunk/CQvM33Vg.js";
|
|
7
7
|
import { u as B } from "../chunk/5_U1CBIu.js";
|
|
8
8
|
import { u as G } from "../chunk/BFTV6myl.js";
|
|
9
|
-
import
|
|
9
|
+
import J from "@unicom-cloud/utils/class-name";
|
|
10
10
|
import { o as K } from "../chunk/BKKEev13.js";
|
|
11
11
|
import { FormProviderContext as L, FormContext as Q } from "./context.js";
|
|
12
12
|
import Y from "./useForm.js";
|
|
@@ -25,7 +25,7 @@ const ee = {
|
|
|
25
25
|
validateTrigger: "onChange"
|
|
26
26
|
}, oe = (a, u) => {
|
|
27
27
|
var h, S;
|
|
28
|
-
const i = $(W), t = $(L),
|
|
28
|
+
const i = $(W), t = $(L), d = _(null), [l] = Y(
|
|
29
29
|
a.form
|
|
30
30
|
), e = G(
|
|
31
31
|
a,
|
|
@@ -40,8 +40,8 @@ const ee = {
|
|
|
40
40
|
requiredSymbol: w,
|
|
41
41
|
labelAlign: I,
|
|
42
42
|
disabled: M,
|
|
43
|
-
colon:
|
|
44
|
-
className:
|
|
43
|
+
colon: N,
|
|
44
|
+
className: z,
|
|
45
45
|
validateTrigger: T,
|
|
46
46
|
prefixCls: x,
|
|
47
47
|
validateMessages: E,
|
|
@@ -53,7 +53,7 @@ const ee = {
|
|
|
53
53
|
let o;
|
|
54
54
|
return t.register && (o = t.register(e.id, l)), o;
|
|
55
55
|
}, [e.id, l]), l.scrollToField = (o, n) => {
|
|
56
|
-
const r =
|
|
56
|
+
const r = d.current, s = e.id;
|
|
57
57
|
if (!r)
|
|
58
58
|
return;
|
|
59
59
|
let c = r.querySelector(
|
|
@@ -99,7 +99,7 @@ const ee = {
|
|
|
99
99
|
requiredSymbol: w,
|
|
100
100
|
labelAlign: I,
|
|
101
101
|
disabled: M,
|
|
102
|
-
colon:
|
|
102
|
+
colon: N,
|
|
103
103
|
labelCol: y,
|
|
104
104
|
wrapperCol: V,
|
|
105
105
|
layout: g,
|
|
@@ -116,12 +116,12 @@ const ee = {
|
|
|
116
116
|
return U(u, () => ({
|
|
117
117
|
...l,
|
|
118
118
|
getRootDOMNode() {
|
|
119
|
-
return
|
|
119
|
+
return d.current;
|
|
120
120
|
}
|
|
121
|
-
})), /* @__PURE__ */
|
|
121
|
+
})), /* @__PURE__ */ p(X, { ...i, childrenName: "Form", size: b, children: /* @__PURE__ */ p(j.Provider, { value: D, children: /* @__PURE__ */ p(
|
|
122
122
|
R,
|
|
123
123
|
{
|
|
124
|
-
ref:
|
|
124
|
+
ref: d,
|
|
125
125
|
...K(P, [
|
|
126
126
|
"form",
|
|
127
127
|
"size",
|
|
@@ -140,7 +140,7 @@ const ee = {
|
|
|
140
140
|
`${m}-${g}`,
|
|
141
141
|
`${m}-size-${b}`,
|
|
142
142
|
{ [`${m}-rtl`]: q },
|
|
143
|
-
|
|
143
|
+
z
|
|
144
144
|
),
|
|
145
145
|
style: e.style,
|
|
146
146
|
onSubmit: (o) => {
|
package/form/FormItem.js
CHANGED
|
@@ -4,28 +4,28 @@ import ge from "lodash/isArray";
|
|
|
4
4
|
import he from "lodash/isFunction";
|
|
5
5
|
import y from "lodash/isPlainObject";
|
|
6
6
|
import w from "lodash/isUndefined";
|
|
7
|
-
import { a as Ce } from "../chunk/
|
|
7
|
+
import { a as Ce } from "../chunk/CQvM33Vg.js";
|
|
8
8
|
import Y from "../grid/index.js";
|
|
9
9
|
import { u as ye } from "../chunk/BFTV6myl.js";
|
|
10
|
-
import { P as ve } from "../chunk/
|
|
11
|
-
import
|
|
10
|
+
import { P as ve } from "../chunk/NPajzdOv.js";
|
|
11
|
+
import v from "@unicom-cloud/utils/class-name";
|
|
12
12
|
import { o as we } from "../chunk/BKKEev13.js";
|
|
13
13
|
import I from "./Control.js";
|
|
14
14
|
import Fe from "./FormLabel.js";
|
|
15
15
|
import { FormItemContext as J, FormListContext as $e, FormContext as Q } from "./context.js";
|
|
16
16
|
import { VALIDATE_STATUS as T } from "./interface.js";
|
|
17
17
|
import { formatValidateMsg as xe } from "./util.js";
|
|
18
|
-
const Ie = Y.Row, X = Y.Col,
|
|
18
|
+
const Ie = Y.Row, X = Y.Col, Ne = ({
|
|
19
19
|
prefixCls: g,
|
|
20
20
|
help: h,
|
|
21
21
|
errors: e,
|
|
22
|
-
warnings:
|
|
22
|
+
warnings: N
|
|
23
23
|
}) => {
|
|
24
24
|
const C = e.map((p, d) => {
|
|
25
25
|
if (p)
|
|
26
26
|
return /* @__PURE__ */ i("div", { role: "alert", children: p.message }, d);
|
|
27
27
|
}), c = [];
|
|
28
|
-
|
|
28
|
+
N.map((p, d) => {
|
|
29
29
|
c.push(
|
|
30
30
|
/* @__PURE__ */ i("div", { role: "alert", className: `${g}-message-help-warning`, children: p }, d)
|
|
31
31
|
);
|
|
@@ -53,13 +53,13 @@ const Ie = Y.Row, X = Y.Col, Se = ({
|
|
|
53
53
|
)
|
|
54
54
|
}
|
|
55
55
|
);
|
|
56
|
-
},
|
|
56
|
+
}, Se = {
|
|
57
57
|
trigger: "onChange",
|
|
58
58
|
triggerPropName: "value"
|
|
59
59
|
}, Pe = (g, h) => {
|
|
60
60
|
var U, _, z;
|
|
61
|
-
const e = ye(g,
|
|
62
|
-
if (
|
|
61
|
+
const e = ye(g, Se), { getPrefixCls: N, prefixCls: C } = x(Ce), c = x(J), m = x($e), [u, p] = W(null), [d, A] = W(null), r = x(Q), l = r.prefixCls || N("form"), D = e.layout || r.layout, Z = e.labelAlign || r.labelAlign, S = fe(!1), ee = (s, t = {}) => {
|
|
62
|
+
if (S.current)
|
|
63
63
|
return;
|
|
64
64
|
const { errors: a, warnings: f } = t || {};
|
|
65
65
|
p((b) => {
|
|
@@ -70,8 +70,8 @@ const Ie = Y.Row, X = Y.Col, Se = ({
|
|
|
70
70
|
return f && f.length ? o[s] = f : delete o[s], o;
|
|
71
71
|
});
|
|
72
72
|
}, re = y(e.noStyle) && e.noStyle.showErrorTip && c.updateFormItem ? c.updateFormItem : ee;
|
|
73
|
-
be(() => (
|
|
74
|
-
|
|
73
|
+
be(() => (S.current = !1, () => {
|
|
74
|
+
S.current = !0, p(null), A(null);
|
|
75
75
|
}), []);
|
|
76
76
|
const te = {
|
|
77
77
|
...r,
|
|
@@ -217,7 +217,7 @@ const Ie = Y.Row, X = Y.Col, Se = ({
|
|
|
217
217
|
children: [
|
|
218
218
|
O(),
|
|
219
219
|
/* @__PURE__ */ i(
|
|
220
|
-
|
|
220
|
+
Ne,
|
|
221
221
|
{
|
|
222
222
|
prefixCls: l,
|
|
223
223
|
help: e.help,
|
package/form/FormLabel.js
CHANGED
|
@@ -4,40 +4,40 @@ import R from "lodash/isArray";
|
|
|
4
4
|
import I from "lodash/isPlainObject";
|
|
5
5
|
import U, { isValidElement as N } from "react";
|
|
6
6
|
import g from "../tooltip/index.js";
|
|
7
|
-
import
|
|
7
|
+
import x from "@unicom-cloud/utils/class-name";
|
|
8
8
|
import y from "./IconSymbol.js";
|
|
9
9
|
import { ID_SUFFIX as C } from "./util.js";
|
|
10
10
|
const X = ({
|
|
11
|
-
htmlFor:
|
|
12
|
-
showColon:
|
|
11
|
+
htmlFor: i,
|
|
12
|
+
showColon: m,
|
|
13
13
|
label: c,
|
|
14
|
-
requiredSymbol:
|
|
14
|
+
requiredSymbol: n,
|
|
15
15
|
required: F,
|
|
16
16
|
rules: l,
|
|
17
17
|
prefix: a,
|
|
18
18
|
tooltip: o
|
|
19
19
|
}) => {
|
|
20
|
-
const $ = R(l) && l.some((e) => e && e.required), p = I(
|
|
20
|
+
const $ = R(l) && l.some((e) => e && e.required), p = I(n) ? n.position : "end", f = (F || $) && !!n && /* @__PURE__ */ r("strong", { className: `${a}-form-item-symbol`, children: /* @__PURE__ */ r(y, {}) }), b = () => {
|
|
21
21
|
if (!o)
|
|
22
22
|
return null;
|
|
23
23
|
const e = `${a}-form-item-tooltip`;
|
|
24
|
-
let
|
|
24
|
+
let s = {}, d = /* @__PURE__ */ r(P, { className: e });
|
|
25
25
|
if (!I(o) || N(o))
|
|
26
|
-
|
|
26
|
+
s = {
|
|
27
27
|
content: o
|
|
28
28
|
};
|
|
29
29
|
else {
|
|
30
30
|
const { icon: t, ...h } = o;
|
|
31
|
-
|
|
31
|
+
s = h, t && (d = N(t) ? U.cloneElement(t, {
|
|
32
32
|
className: x(
|
|
33
33
|
e,
|
|
34
34
|
t.props.className
|
|
35
35
|
)
|
|
36
36
|
}) : t);
|
|
37
37
|
}
|
|
38
|
-
return /* @__PURE__ */ r(g, { ...
|
|
38
|
+
return /* @__PURE__ */ r(g, { ...s, children: d });
|
|
39
39
|
};
|
|
40
|
-
return c ? /* @__PURE__ */ u("label", { htmlFor:
|
|
40
|
+
return c ? /* @__PURE__ */ u("label", { htmlFor: i && `${i}${C}`, children: [
|
|
41
41
|
p !== "end" && f,
|
|
42
42
|
" ",
|
|
43
43
|
c,
|
|
@@ -46,7 +46,7 @@ const X = ({
|
|
|
46
46
|
" ",
|
|
47
47
|
f
|
|
48
48
|
] }),
|
|
49
|
-
|
|
49
|
+
m ? m === !0 ? ":" : m : ""
|
|
50
50
|
] }) : null;
|
|
51
51
|
};
|
|
52
52
|
export {
|
package/form/context.js
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { createContext as t } from "react";
|
|
2
2
|
import { N as e } from "../chunk/D0ZWT7db.js";
|
|
3
|
-
|
|
3
|
+
import "@unicom-cloud/utils/constant/ui";
|
|
4
|
+
const i = t({
|
|
4
5
|
layout: "horizontal",
|
|
5
6
|
labelCol: { span: 5, offset: 0 },
|
|
6
7
|
labelAlign: "right",
|
|
@@ -34,10 +35,10 @@ const o = t({
|
|
|
34
35
|
innerGetStoreStatus: e
|
|
35
36
|
})
|
|
36
37
|
}
|
|
37
|
-
}),
|
|
38
|
+
}), s = t({}), a = t({}), n = t({});
|
|
38
39
|
export {
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
40
|
+
i as FormContext,
|
|
41
|
+
s as FormItemContext,
|
|
42
|
+
n as FormListContext,
|
|
43
|
+
a as FormProviderContext
|
|
43
44
|
};
|
package/form/promisify.js
CHANGED
|
@@ -1,9 +1,8 @@
|
|
|
1
|
-
var
|
|
2
|
-
var c = (e, t, r) => t in e ?
|
|
1
|
+
var p = Object.defineProperty;
|
|
2
|
+
var c = (e, t, r) => t in e ? p(e, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : e[t] = r;
|
|
3
3
|
var n = (e, t, r) => c(e, typeof t != "symbol" ? t + "" : t, r);
|
|
4
|
-
import "../chunk/
|
|
5
|
-
import "
|
|
6
|
-
import m from "lodash/isFunction.js";
|
|
4
|
+
import "../chunk/ClM74To2.js";
|
|
5
|
+
import { isFunction as m } from "@unicom-cloud/utils/is";
|
|
7
6
|
class a extends Error {
|
|
8
7
|
constructor(r) {
|
|
9
8
|
super("form validate error, get errors by error.errors");
|
|
@@ -11,23 +10,23 @@ class a extends Error {
|
|
|
11
10
|
this.errors = r;
|
|
12
11
|
}
|
|
13
12
|
}
|
|
14
|
-
function
|
|
13
|
+
function _(e) {
|
|
15
14
|
return Object.defineProperty((...r) => {
|
|
16
15
|
if (m(r[r.length - 1]))
|
|
17
16
|
return e.apply(this, r);
|
|
18
17
|
{
|
|
19
18
|
const i = (s, l) => {
|
|
20
|
-
const
|
|
19
|
+
const u = (o, f) => {
|
|
21
20
|
if (o)
|
|
22
21
|
return l(new a(o));
|
|
23
|
-
s(
|
|
22
|
+
s(f);
|
|
24
23
|
};
|
|
25
|
-
return r[r.length] =
|
|
24
|
+
return r[r.length] = u, r.length++, e.apply(this, r);
|
|
26
25
|
};
|
|
27
26
|
return new Promise(i);
|
|
28
27
|
}
|
|
29
28
|
}, "name", { value: e.name });
|
|
30
29
|
}
|
|
31
30
|
export {
|
|
32
|
-
|
|
31
|
+
_ as default
|
|
33
32
|
};
|
package/form/store.js
CHANGED
|
@@ -9,7 +9,7 @@ import E from "lodash/isPlainObject";
|
|
|
9
9
|
import _ from "lodash/merge";
|
|
10
10
|
import w from "lodash/omit";
|
|
11
11
|
import L from "lodash/setWith";
|
|
12
|
-
import { d as I } from "../chunk/
|
|
12
|
+
import { d as I } from "../chunk/ClM74To2.js";
|
|
13
13
|
import { SubmitStatus as d } from "./interface.js";
|
|
14
14
|
import B from "./promisify.js";
|
|
15
15
|
import { iterativelyGetKeys as T, cloneDeep as m, set as o } from "./util.js";
|
package/form/util.js
CHANGED
package/grid/Col.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import { forwardRef as
|
|
5
|
-
import { a as
|
|
6
|
-
import { u as
|
|
7
|
-
import
|
|
8
|
-
import { RowContext as
|
|
1
|
+
import { jsx as F } from "react/jsx-runtime";
|
|
2
|
+
import H from "lodash/isNumber";
|
|
3
|
+
import T from "lodash/isPlainObject";
|
|
4
|
+
import { forwardRef as q, useContext as S, useMemo as C } from "react";
|
|
5
|
+
import { a as D } from "../chunk/CQvM33Vg.js";
|
|
6
|
+
import { u as I } from "../chunk/BFTV6myl.js";
|
|
7
|
+
import J from "@unicom-cloud/utils/class-name";
|
|
8
|
+
import { RowContext as K } from "./context.js";
|
|
9
9
|
const Q = {
|
|
10
10
|
span: 24
|
|
11
11
|
};
|
|
@@ -13,17 +13,17 @@ function v(i) {
|
|
|
13
13
|
return typeof i == "string" && /\d+[px|%|em|rem|]{1}/.test(i) ? `0 0 ${i}` : i;
|
|
14
14
|
}
|
|
15
15
|
function U(i, w) {
|
|
16
|
-
const { getPrefixCls: A, componentConfig:
|
|
16
|
+
const { getPrefixCls: A, componentConfig: f, rtl: G } = S(D), L = I(
|
|
17
17
|
i,
|
|
18
18
|
Q,
|
|
19
|
-
|
|
20
|
-
), { gutter: p, div: $ } = S(
|
|
19
|
+
f == null ? void 0 : f["Grid.Col"]
|
|
20
|
+
), { gutter: p, div: $ } = S(K), {
|
|
21
21
|
className: M,
|
|
22
|
-
style:
|
|
23
|
-
children:
|
|
24
|
-
span:
|
|
25
|
-
offset:
|
|
26
|
-
order:
|
|
22
|
+
style: N,
|
|
23
|
+
children: O,
|
|
24
|
+
span: V,
|
|
25
|
+
offset: a,
|
|
26
|
+
order: u,
|
|
27
27
|
pull: c,
|
|
28
28
|
push: m,
|
|
29
29
|
xs: x,
|
|
@@ -33,52 +33,52 @@ function U(i, w) {
|
|
|
33
33
|
xl: P,
|
|
34
34
|
xxl: b,
|
|
35
35
|
xxxl: j,
|
|
36
|
-
flex:
|
|
37
|
-
...
|
|
36
|
+
flex: e,
|
|
37
|
+
...k
|
|
38
38
|
} = L;
|
|
39
|
-
function
|
|
39
|
+
function z(r, o) {
|
|
40
40
|
const R = { xs: x, sm: g, md: y, lg: h, xl: P, xxl: b, xxxl: j };
|
|
41
41
|
return Object.keys(R).forEach((n) => {
|
|
42
42
|
const t = R[n];
|
|
43
|
-
|
|
43
|
+
H(t) ? t >= 0 && (o[`${r}-${n}-${t}`] = !0) : T(t) && (o[`${r}-${n}-${t.span}`] = t.span, o[`${r}-${n}-offset-${t.offset}`] = t.offset, o[`${r}-${n}-order-${t.order}`] = t.order, o[`${r}-${n}-pull-${t.pull}`] = t.pull, o[`${r}-${n}-push-${t.push}`] = t.push);
|
|
44
44
|
}), o;
|
|
45
45
|
}
|
|
46
46
|
const s = A("col");
|
|
47
|
-
let
|
|
47
|
+
let d = {
|
|
48
48
|
[`${s}`]: !$,
|
|
49
|
-
[`${s}-order-${
|
|
50
|
-
[`${s}-${
|
|
51
|
-
[`${s}-offset-${
|
|
49
|
+
[`${s}-order-${u}`]: u,
|
|
50
|
+
[`${s}-${V}`]: !$ && !x && !g && !y && !h && !P && !b && !j,
|
|
51
|
+
[`${s}-offset-${a}`]: a,
|
|
52
52
|
[`${s}-pull-${c}`]: c,
|
|
53
53
|
[`${s}-push-${m}`]: m,
|
|
54
54
|
[`${s}-rtl`]: G
|
|
55
55
|
};
|
|
56
|
-
|
|
57
|
-
const
|
|
56
|
+
d = z(s, d);
|
|
57
|
+
const B = J(e ? s : d, M), l = {};
|
|
58
58
|
if (Array.isArray(p) && !$) {
|
|
59
59
|
const r = p[0] && p[0] / 2 || 0, o = p[1] && p[1] / 2 || 0;
|
|
60
|
-
r && (
|
|
60
|
+
r && (l.paddingLeft = r, l.paddingRight = r), o && (l.paddingTop = o, l.paddingBottom = o);
|
|
61
61
|
}
|
|
62
|
-
const
|
|
63
|
-
() => v(
|
|
64
|
-
[
|
|
62
|
+
const E = C(
|
|
63
|
+
() => v(e) ? { flex: v(e) } : {},
|
|
64
|
+
[e]
|
|
65
65
|
);
|
|
66
|
-
return /* @__PURE__ */
|
|
66
|
+
return /* @__PURE__ */ F(
|
|
67
67
|
"div",
|
|
68
68
|
{
|
|
69
69
|
ref: w,
|
|
70
|
-
...
|
|
70
|
+
...k,
|
|
71
71
|
style: {
|
|
72
|
-
...
|
|
73
|
-
...
|
|
74
|
-
...
|
|
72
|
+
...N,
|
|
73
|
+
...l,
|
|
74
|
+
...E
|
|
75
75
|
},
|
|
76
|
-
className:
|
|
77
|
-
children:
|
|
76
|
+
className: B,
|
|
77
|
+
children: O
|
|
78
78
|
}
|
|
79
79
|
);
|
|
80
80
|
}
|
|
81
|
-
const W =
|
|
81
|
+
const W = q(U);
|
|
82
82
|
W.displayName = "Col";
|
|
83
83
|
export {
|
|
84
84
|
W as default
|