@cniot/android-pda-components 2.0.0-beta.2 → 2.0.0-beta.4
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/build/assets/index.0a54fcd3.js +964 -0
- package/build/assets/{index.47962a04.css → index.87e75c31.css} +1 -1
- package/build/index.html +2 -2
- package/doc/all-v2-components/index.jsx +1 -1
- package/es/index.cjs.js +6 -6
- package/es/index.es.js +1039 -661
- package/es/style.css +1 -1
- package/package.json +1 -1
- package/build/assets/index.158dfbf4.js +0 -964
- package/doc/test/flow/index.js +0 -46
- package/doc/test/flow/pages/index.js +0 -82
- package/doc/test/flow/utils/index.js +0 -37
- package/doc/test/i18n/index.js +0 -95
- package/doc/test/i18n/strings/en-US.json +0 -1
- package/doc/test/i18n/strings/index.js +0 -8
- package/doc/test/i18n/strings/zh-CN.json +0 -1
- package/doc/test/index.jsx +0 -46
- package/doc/test/pages/popup/index.jsx +0 -22
- package/doc/test/pages/popup/index.less +0 -0
- package/doc/test/pages/scan/index.jsx +0 -192
- package/doc/test/pages/scan/index.less +0 -0
package/es/index.es.js
CHANGED
|
@@ -70,7 +70,7 @@ var _classnames_2_5_1_classnames = { exports: {} };
|
|
|
70
70
|
})();
|
|
71
71
|
})(_classnames_2_5_1_classnames);
|
|
72
72
|
var classNames = _classnames_2_5_1_classnames.exports;
|
|
73
|
-
var index$
|
|
73
|
+
var index$12 = "";
|
|
74
74
|
function getTypeClass$2(type) {
|
|
75
75
|
return {
|
|
76
76
|
center: "op-overlay center",
|
|
@@ -106,7 +106,7 @@ function Overlay$1(props) {
|
|
|
106
106
|
}
|
|
107
107
|
}, props.children) : null;
|
|
108
108
|
}
|
|
109
|
-
var index$
|
|
109
|
+
var index$11 = "";
|
|
110
110
|
const blankFunc$6 = () => {
|
|
111
111
|
};
|
|
112
112
|
class PdaTitle extends React__default.Component {
|
|
@@ -285,7 +285,7 @@ var _keycode_2_2_1_keycode = { exports: {} };
|
|
|
285
285
|
}
|
|
286
286
|
})(_keycode_2_2_1_keycode, _keycode_2_2_1_keycode.exports);
|
|
287
287
|
var keycode = _keycode_2_2_1_keycode.exports;
|
|
288
|
-
var index
|
|
288
|
+
var index$10 = "";
|
|
289
289
|
function Button$2(props) {
|
|
290
290
|
const { type = "default", onClick, className = "", tabIndex = 1, dataClick = "" } = props;
|
|
291
291
|
let opt = {};
|
|
@@ -308,7 +308,7 @@ Button$2.Group = ButtonGroup$1;
|
|
|
308
308
|
const SPECIAL_KEY_MAP = ["fn"];
|
|
309
309
|
const empty$3 = () => {
|
|
310
310
|
};
|
|
311
|
-
function index
|
|
311
|
+
function index$$(props) {
|
|
312
312
|
const {
|
|
313
313
|
onBack,
|
|
314
314
|
icon,
|
|
@@ -514,7 +514,7 @@ function onAddEventListerScanBarcode$1(fn) {
|
|
|
514
514
|
document.removeEventListener("BarcodeScan", callback);
|
|
515
515
|
};
|
|
516
516
|
}
|
|
517
|
-
var index$
|
|
517
|
+
var index$_ = "";
|
|
518
518
|
class PdaInfoCard$2 extends React__default.Component {
|
|
519
519
|
constructor(props) {
|
|
520
520
|
super(props);
|
|
@@ -593,7 +593,7 @@ class PdaInfoCard$2 extends React__default.Component {
|
|
|
593
593
|
}
|
|
594
594
|
}
|
|
595
595
|
PdaInfoCard$2.IMAGE_1 = `${window.PDA_IMAGE_PATH}O1CN01qYuxip1ME9zhdL9XG_!!6000000001402-2-tps-150-150.png`;
|
|
596
|
-
var index$
|
|
596
|
+
var index$Z = "";
|
|
597
597
|
class PdaListItem extends React__default.Component {
|
|
598
598
|
constructor(props) {
|
|
599
599
|
super(props);
|
|
@@ -639,7 +639,7 @@ class PdaListItem extends React__default.Component {
|
|
|
639
639
|
}));
|
|
640
640
|
}
|
|
641
641
|
}
|
|
642
|
-
var index$
|
|
642
|
+
var index$Y = "";
|
|
643
643
|
function empty$2() {
|
|
644
644
|
}
|
|
645
645
|
function Confirm$1(props) {
|
|
@@ -684,7 +684,7 @@ function Confirm$1(props) {
|
|
|
684
684
|
dataClick: item.dataClick
|
|
685
685
|
}, item.label))) : null));
|
|
686
686
|
}
|
|
687
|
-
var index$
|
|
687
|
+
var index$X = "";
|
|
688
688
|
function WindVaneLog(param) {
|
|
689
689
|
const params = {
|
|
690
690
|
domain: "logger",
|
|
@@ -777,12 +777,12 @@ function Toast$1(props) {
|
|
|
777
777
|
className: "toast-message"
|
|
778
778
|
}, message)) : null;
|
|
779
779
|
}
|
|
780
|
-
const defaultProps$
|
|
780
|
+
const defaultProps$m = {
|
|
781
781
|
maskClickable: true,
|
|
782
782
|
stopPropagation: ["click"]
|
|
783
783
|
};
|
|
784
784
|
const InternalToast = (p2) => {
|
|
785
|
-
const props = mergeProps$1(defaultProps$
|
|
785
|
+
const props = mergeProps$1(defaultProps$m, p2);
|
|
786
786
|
const {
|
|
787
787
|
maskClickable,
|
|
788
788
|
content,
|
|
@@ -814,12 +814,12 @@ function unmount$1(container) {
|
|
|
814
814
|
container.parentNode.removeChild(container);
|
|
815
815
|
}
|
|
816
816
|
}
|
|
817
|
-
const defaultProps$
|
|
817
|
+
const defaultProps$l = {
|
|
818
818
|
duration: 2e3
|
|
819
819
|
};
|
|
820
820
|
function show$1(p2) {
|
|
821
821
|
const props = mergeProps$1(
|
|
822
|
-
defaultProps$
|
|
822
|
+
defaultProps$l,
|
|
823
823
|
p2
|
|
824
824
|
);
|
|
825
825
|
let timer = 0;
|
|
@@ -953,7 +953,7 @@ function confirm$1(props) {
|
|
|
953
953
|
onClick: onNext
|
|
954
954
|
}));
|
|
955
955
|
}
|
|
956
|
-
var index$
|
|
956
|
+
var index$W = "";
|
|
957
957
|
function getTypeClass(type) {
|
|
958
958
|
return {
|
|
959
959
|
center: "op-overlay center",
|
|
@@ -989,7 +989,7 @@ function Overlay(props) {
|
|
|
989
989
|
}
|
|
990
990
|
}, props.children) : null;
|
|
991
991
|
}
|
|
992
|
-
var index$
|
|
992
|
+
var index$V = "";
|
|
993
993
|
function Prompt$1(props) {
|
|
994
994
|
const inputRef = React__default.useRef();
|
|
995
995
|
const { data = {}, onNext } = props;
|
|
@@ -1066,7 +1066,7 @@ function splitMessage(message) {
|
|
|
1066
1066
|
var msg = String(message).split("by Error:");
|
|
1067
1067
|
return msg[1] || msg[0];
|
|
1068
1068
|
}
|
|
1069
|
-
var index$
|
|
1069
|
+
var index$U = "";
|
|
1070
1070
|
function NotFound(props) {
|
|
1071
1071
|
return /* @__PURE__ */ React__default.createElement("div", {
|
|
1072
1072
|
style: { padding: "20%" }
|
|
@@ -1074,7 +1074,7 @@ function NotFound(props) {
|
|
|
1074
1074
|
style: { fontSize: "60%" }
|
|
1075
1075
|
}, "Not found")), /* @__PURE__ */ React__default.createElement("div", null, props.action.getPage()));
|
|
1076
1076
|
}
|
|
1077
|
-
var index$
|
|
1077
|
+
var index$T = "";
|
|
1078
1078
|
function Loading$2(props) {
|
|
1079
1079
|
const [showLoading, setShowLoading] = React__default.useState(props.visible);
|
|
1080
1080
|
const edgeService = props.edgeService;
|
|
@@ -1143,7 +1143,7 @@ function Debug$1() {
|
|
|
1143
1143
|
console.warn('Please stop using "Debug" Components');
|
|
1144
1144
|
return null;
|
|
1145
1145
|
}
|
|
1146
|
-
var index$
|
|
1146
|
+
var index$S = {
|
|
1147
1147
|
Alert: Alert$1,
|
|
1148
1148
|
Start,
|
|
1149
1149
|
Toast: toast,
|
|
@@ -1154,7 +1154,7 @@ var index$R = {
|
|
|
1154
1154
|
Loading: Loading$2,
|
|
1155
1155
|
PlaySound: PlaySound$1
|
|
1156
1156
|
};
|
|
1157
|
-
var index$
|
|
1157
|
+
var index$R = "";
|
|
1158
1158
|
function Presentation(props) {
|
|
1159
1159
|
const {
|
|
1160
1160
|
image: image2 = Presentation.IMAGE_1,
|
|
@@ -1176,7 +1176,7 @@ Presentation.IMAGE_1 = `${window.PDA_IMAGE_PATH}O1CN019Ivkor1ksy3pMGDsz_!!600000
|
|
|
1176
1176
|
Presentation.IMAGE_2 = `${window.PDA_IMAGE_PATH}O1CN01lhSunu1X4VPw1Mlas_!!6000000002870-2-tps-352-158.png`;
|
|
1177
1177
|
Presentation.IMAGE_3 = `${window.PDA_IMAGE_PATH}O1CN01mreYXo1XfbUsQ7hip_!!6000000002951-2-tps-322-144.png`;
|
|
1178
1178
|
Presentation.IMAGE_4 = `${window.PDA_IMAGE_PATH}O1CN017gNM8F1Fmmcfti7Dg_!!6000000000530-1-tps-414-286.gif`;
|
|
1179
|
-
var index$
|
|
1179
|
+
var index$Q = "";
|
|
1180
1180
|
function empty$1() {
|
|
1181
1181
|
}
|
|
1182
1182
|
function List$3(props) {
|
|
@@ -1231,7 +1231,7 @@ function DefaultItem(props) {
|
|
|
1231
1231
|
}, extra));
|
|
1232
1232
|
}
|
|
1233
1233
|
List$3.Item = DefaultItem;
|
|
1234
|
-
var index$
|
|
1234
|
+
var index$P = "";
|
|
1235
1235
|
const blankFunc$5 = () => {
|
|
1236
1236
|
};
|
|
1237
1237
|
class BaseLayoutContainer extends React__default.Component {
|
|
@@ -1621,7 +1621,7 @@ class BaseLayout extends React__default.Component {
|
|
|
1621
1621
|
});
|
|
1622
1622
|
}
|
|
1623
1623
|
}
|
|
1624
|
-
var index$
|
|
1624
|
+
var index$O = "";
|
|
1625
1625
|
const blankFunc$1 = () => {
|
|
1626
1626
|
};
|
|
1627
1627
|
function Keyborard(props) {
|
|
@@ -1712,7 +1712,7 @@ function WakeKeyborard(props) {
|
|
|
1712
1712
|
}) : null);
|
|
1713
1713
|
}
|
|
1714
1714
|
WakeKeyborard.Keyborard = Keyborard;
|
|
1715
|
-
const classPrefix$
|
|
1715
|
+
const classPrefix$r = "image-uploader";
|
|
1716
1716
|
class PreviewItem extends Component {
|
|
1717
1717
|
constructor(props) {
|
|
1718
1718
|
super(props);
|
|
@@ -1720,7 +1720,7 @@ class PreviewItem extends Component {
|
|
|
1720
1720
|
}
|
|
1721
1721
|
renderDelete() {
|
|
1722
1722
|
return /* @__PURE__ */ React__default.createElement("span", {
|
|
1723
|
-
className: `${classPrefix$
|
|
1723
|
+
className: `${classPrefix$r}-cell-delete`,
|
|
1724
1724
|
onClick: this.props.onDelete
|
|
1725
1725
|
}, /* @__PURE__ */ React__default.createElement("img", {
|
|
1726
1726
|
className: "uploader-delete-icon",
|
|
@@ -1733,20 +1733,20 @@ class PreviewItem extends Component {
|
|
|
1733
1733
|
return /* @__PURE__ */ React__default.createElement("div", {
|
|
1734
1734
|
className: "image-space-item"
|
|
1735
1735
|
}, /* @__PURE__ */ React__default.createElement("div", {
|
|
1736
|
-
className: `${classPrefix$
|
|
1736
|
+
className: `${classPrefix$r}-cell`,
|
|
1737
1737
|
style: { width: box, height: box }
|
|
1738
1738
|
}, /* @__PURE__ */ React__default.createElement("div", {
|
|
1739
|
-
className: `${classPrefix$
|
|
1739
|
+
className: `${classPrefix$r}-cell-image`,
|
|
1740
1740
|
style: { width: box, height: box }
|
|
1741
1741
|
}, /* @__PURE__ */ React__default.createElement("img", {
|
|
1742
|
-
className: `${classPrefix$
|
|
1742
|
+
className: `${classPrefix$r}-img`,
|
|
1743
1743
|
src,
|
|
1744
1744
|
fit: "cover",
|
|
1745
1745
|
onClick: onView
|
|
1746
1746
|
})), deletable && this.renderDelete()));
|
|
1747
1747
|
}
|
|
1748
1748
|
}
|
|
1749
|
-
const classPrefix$
|
|
1749
|
+
const classPrefix$q = "image-uploader";
|
|
1750
1750
|
class UploadeButton extends Component {
|
|
1751
1751
|
constructor(props) {
|
|
1752
1752
|
super(props);
|
|
@@ -1757,10 +1757,10 @@ class UploadeButton extends Component {
|
|
|
1757
1757
|
return /* @__PURE__ */ React__default.createElement("div", {
|
|
1758
1758
|
className: `image-space-item`
|
|
1759
1759
|
}, /* @__PURE__ */ React__default.createElement("div", {
|
|
1760
|
-
className: `${classPrefix$
|
|
1760
|
+
className: `${classPrefix$q}-upload-button-wrap`,
|
|
1761
1761
|
onClick: this.props.onUpload
|
|
1762
1762
|
}, /* @__PURE__ */ React__default.createElement("span", {
|
|
1763
|
-
className: `${classPrefix$
|
|
1763
|
+
className: `${classPrefix$q}-upload-button image-uploader-cell`,
|
|
1764
1764
|
style: { width: box, height: box }
|
|
1765
1765
|
}, /* @__PURE__ */ React__default.createElement("img", {
|
|
1766
1766
|
className: "uploader-add-icon",
|
|
@@ -1769,8 +1769,8 @@ class UploadeButton extends Component {
|
|
|
1769
1769
|
}))));
|
|
1770
1770
|
}
|
|
1771
1771
|
}
|
|
1772
|
-
var index$
|
|
1773
|
-
const classPrefix$
|
|
1772
|
+
var index$N = "";
|
|
1773
|
+
const classPrefix$p = "image-viewer";
|
|
1774
1774
|
class ImageViewer extends Component {
|
|
1775
1775
|
constructor(props) {
|
|
1776
1776
|
super(props);
|
|
@@ -1857,9 +1857,9 @@ class ImageViewer extends Component {
|
|
|
1857
1857
|
}, /* @__PURE__ */ React__default.createElement("div", {
|
|
1858
1858
|
className: `v-mask-content`
|
|
1859
1859
|
}, /* @__PURE__ */ React__default.createElement("div", {
|
|
1860
|
-
className: `${classPrefix$
|
|
1860
|
+
className: `${classPrefix$p}-content`
|
|
1861
1861
|
}, /* @__PURE__ */ React__default.createElement("div", {
|
|
1862
|
-
className: `${classPrefix$
|
|
1862
|
+
className: `${classPrefix$p}-slides`
|
|
1863
1863
|
}, /* @__PURE__ */ React__default.createElement("div", {
|
|
1864
1864
|
className: "image-viewer-indicator"
|
|
1865
1865
|
}, currentIndex + 1, " / ", images.length), /* @__PURE__ */ React__default.createElement("div", {
|
|
@@ -1899,10 +1899,10 @@ class ImageViewer extends Component {
|
|
|
1899
1899
|
}, /* @__PURE__ */ React__default.createElement("path", {
|
|
1900
1900
|
d: "M384 127.5l256.5 256.5-256.5 256.5-45-45 178.5-180h-390v-63h390l-178.5-180z"
|
|
1901
1901
|
})))) : null))), loading2 ? /* @__PURE__ */ React__default.createElement("div", {
|
|
1902
|
-
className: `${classPrefix$
|
|
1902
|
+
className: `${classPrefix$p}-loading`,
|
|
1903
1903
|
onClick: this.onClose
|
|
1904
1904
|
}, /* @__PURE__ */ React__default.createElement("div", {
|
|
1905
|
-
className: `${classPrefix$
|
|
1905
|
+
className: `${classPrefix$p}-loading-reactor`
|
|
1906
1906
|
}, /* @__PURE__ */ React__default.createElement("svg", {
|
|
1907
1907
|
viewBox: "0 0 32 32",
|
|
1908
1908
|
width: "36",
|
|
@@ -1916,7 +1916,7 @@ class ImageViewer extends Component {
|
|
|
1916
1916
|
})))) : null) : null);
|
|
1917
1917
|
}
|
|
1918
1918
|
}
|
|
1919
|
-
const classPrefix$
|
|
1919
|
+
const classPrefix$o = "image-uploader";
|
|
1920
1920
|
class ImageUploader extends Component {
|
|
1921
1921
|
constructor(props) {
|
|
1922
1922
|
super(props);
|
|
@@ -2030,7 +2030,7 @@ class ImageUploader extends Component {
|
|
|
2030
2030
|
} = this.props;
|
|
2031
2031
|
const { images } = this.state;
|
|
2032
2032
|
return /* @__PURE__ */ React__default.createElement(React__default.Fragment, null, /* @__PURE__ */ React__default.createElement("div", {
|
|
2033
|
-
className: `${classPrefix$
|
|
2033
|
+
className: `${classPrefix$o}`
|
|
2034
2034
|
}, /* @__PURE__ */ React__default.createElement("input", {
|
|
2035
2035
|
type: "file",
|
|
2036
2036
|
name: "file",
|
|
@@ -2038,7 +2038,7 @@ class ImageUploader extends Component {
|
|
|
2038
2038
|
id: "inputFile",
|
|
2039
2039
|
style: { display: "none" }
|
|
2040
2040
|
}), /* @__PURE__ */ React__default.createElement("div", {
|
|
2041
|
-
className: `${classPrefix$
|
|
2041
|
+
className: `${classPrefix$o}-wrap`
|
|
2042
2042
|
}, images && images.map((item, index2) => {
|
|
2043
2043
|
return /* @__PURE__ */ React__default.createElement(PreviewItem, {
|
|
2044
2044
|
src: item.url,
|
|
@@ -2052,9 +2052,9 @@ class ImageUploader extends Component {
|
|
|
2052
2052
|
box,
|
|
2053
2053
|
onUpload: this.onClickAdd
|
|
2054
2054
|
}) : null)), loading2 ? /* @__PURE__ */ React__default.createElement("div", {
|
|
2055
|
-
className: `${classPrefix$
|
|
2055
|
+
className: `${classPrefix$o}-loading`
|
|
2056
2056
|
}, /* @__PURE__ */ React__default.createElement("div", {
|
|
2057
|
-
className: `${classPrefix$
|
|
2057
|
+
className: `${classPrefix$o}-loading-reactor`
|
|
2058
2058
|
}, /* @__PURE__ */ React__default.createElement("svg", {
|
|
2059
2059
|
viewBox: "0 0 32 32",
|
|
2060
2060
|
width: "36",
|
|
@@ -2128,9 +2128,9 @@ function takePhotoMethod2(compressSize = 200) {
|
|
|
2128
2128
|
);
|
|
2129
2129
|
});
|
|
2130
2130
|
}
|
|
2131
|
+
var index$M = "";
|
|
2131
2132
|
var index$L = "";
|
|
2132
2133
|
var index$K = "";
|
|
2133
|
-
var index$J = "";
|
|
2134
2134
|
class PdaInfoCard$1 extends React__default.Component {
|
|
2135
2135
|
constructor(props) {
|
|
2136
2136
|
super(props);
|
|
@@ -2185,7 +2185,7 @@ class PdaInfoCard extends React__default.Component {
|
|
|
2185
2185
|
}
|
|
2186
2186
|
}
|
|
2187
2187
|
__publicField(PdaInfoCard, "Step", PdaInfoCard$1);
|
|
2188
|
-
var index$
|
|
2188
|
+
var index$J = "";
|
|
2189
2189
|
class PdaFinishCard extends React__default.Component {
|
|
2190
2190
|
constructor(props) {
|
|
2191
2191
|
super(props);
|
|
@@ -2239,7 +2239,7 @@ class PdaFinishCard extends React__default.Component {
|
|
|
2239
2239
|
}
|
|
2240
2240
|
PdaFinishCard.SUCCESS = `${window.PDA_IMAGE_PATH}O1CN01OL2UYg24792knbTtC_!!6000000007343-1-tps-506-415.gif`;
|
|
2241
2241
|
PdaFinishCard.ERROR_SUCCESS = `${window.PDA_IMAGE_PATH}O1CN01p5Oc5t1VMFWtBomQc_!!6000000002638-1-tps-600-456.gif`;
|
|
2242
|
-
var index$
|
|
2242
|
+
var index$I = "";
|
|
2243
2243
|
class PdaDistanceCard extends React__default.Component {
|
|
2244
2244
|
constructor(props) {
|
|
2245
2245
|
super(props);
|
|
@@ -2280,7 +2280,7 @@ class PdaDistanceCard extends React__default.Component {
|
|
|
2280
2280
|
}, /* @__PURE__ */ React__default.createElement("p", null, "\u8FDC"), /* @__PURE__ */ React__default.createElement("p", null, "\u8FD1")));
|
|
2281
2281
|
}
|
|
2282
2282
|
}
|
|
2283
|
-
var index$
|
|
2283
|
+
var index$H = "";
|
|
2284
2284
|
function SubCard(props) {
|
|
2285
2285
|
const { title, context, name, tag, attrs = [], style } = props;
|
|
2286
2286
|
return /* @__PURE__ */ React__default.createElement("div", {
|
|
@@ -2306,7 +2306,7 @@ function SubCard(props) {
|
|
|
2306
2306
|
}, text);
|
|
2307
2307
|
})));
|
|
2308
2308
|
}
|
|
2309
|
-
var index$
|
|
2309
|
+
var index$G = "";
|
|
2310
2310
|
function SelectCard(props) {
|
|
2311
2311
|
const { title, label, select = true, onClick = (e2) => {
|
|
2312
2312
|
} } = props;
|
|
@@ -2319,10 +2319,10 @@ function SelectCard(props) {
|
|
|
2319
2319
|
className: "select-icon"
|
|
2320
2320
|
}) : null, " "));
|
|
2321
2321
|
}
|
|
2322
|
-
var index$
|
|
2322
|
+
var index$F = "";
|
|
2323
2323
|
function empty() {
|
|
2324
2324
|
}
|
|
2325
|
-
function index$
|
|
2325
|
+
function index$E(props) {
|
|
2326
2326
|
const { dataSource = [], onClickItem = empty } = props;
|
|
2327
2327
|
let tabIndex = 1;
|
|
2328
2328
|
return /* @__PURE__ */ React__default.createElement("div", {
|
|
@@ -2350,7 +2350,7 @@ function index$D(props) {
|
|
|
2350
2350
|
})));
|
|
2351
2351
|
}));
|
|
2352
2352
|
}
|
|
2353
|
-
var index$
|
|
2353
|
+
var index$D = "";
|
|
2354
2354
|
function usePersistFn(fn) {
|
|
2355
2355
|
var fnRef = useRef(fn);
|
|
2356
2356
|
fnRef.current = fn;
|
|
@@ -2676,7 +2676,7 @@ function InfiniteScroll(props) {
|
|
|
2676
2676
|
className: "pda-infinite-scroll-view"
|
|
2677
2677
|
}, /* @__PURE__ */ React__default.createElement("span", null, notMoreText)));
|
|
2678
2678
|
}
|
|
2679
|
-
var index$
|
|
2679
|
+
var index$C = "";
|
|
2680
2680
|
function ActionSheet(props) {
|
|
2681
2681
|
const {
|
|
2682
2682
|
className = "",
|
|
@@ -2724,14 +2724,14 @@ function ActionSheet(props) {
|
|
|
2724
2724
|
}, item.title);
|
|
2725
2725
|
})) : null));
|
|
2726
2726
|
}
|
|
2727
|
-
var index$
|
|
2727
|
+
var index$B = "";
|
|
2728
2728
|
function Tag(props) {
|
|
2729
2729
|
const { className = void 0, label = "label", type = "success" } = props;
|
|
2730
2730
|
return /* @__PURE__ */ React__default.createElement("div", {
|
|
2731
2731
|
className: classNames({ [className]: true, "pda-tag": true, ["pda-tag-" + type]: true })
|
|
2732
2732
|
}, label);
|
|
2733
2733
|
}
|
|
2734
|
-
var index$
|
|
2734
|
+
var index$A = "";
|
|
2735
2735
|
function SimpleCard(props) {
|
|
2736
2736
|
const { className = "", title = "", content = "", type = "default", onClick = () => {
|
|
2737
2737
|
} } = props;
|
|
@@ -2744,7 +2744,7 @@ function SimpleCard(props) {
|
|
|
2744
2744
|
className: "simple-card-content"
|
|
2745
2745
|
}, content)) : null;
|
|
2746
2746
|
}
|
|
2747
|
-
var index$
|
|
2747
|
+
var index$z = "";
|
|
2748
2748
|
function SimpleCardBlock(props) {
|
|
2749
2749
|
const { className = void 0, dataSource = [], title = "", tag } = props;
|
|
2750
2750
|
return /* @__PURE__ */ React__default.createElement("div", {
|
|
@@ -2766,9 +2766,9 @@ function SimpleCardBlock(props) {
|
|
|
2766
2766
|
});
|
|
2767
2767
|
})) : null);
|
|
2768
2768
|
}
|
|
2769
|
-
var index$
|
|
2769
|
+
var index$y = "";
|
|
2770
2770
|
function LatticeMouth(props) {
|
|
2771
|
-
const { row = 3, col = 3, dataSource = [] } = props;
|
|
2771
|
+
const { row = 3, col = 3, dataSource = [], onClick } = props;
|
|
2772
2772
|
return /* @__PURE__ */ React__default.createElement("div", {
|
|
2773
2773
|
className: "lattice-mouth"
|
|
2774
2774
|
}, Array.from(Array(row)).map(function(_, rowIndex) {
|
|
@@ -2776,11 +2776,11 @@ function LatticeMouth(props) {
|
|
|
2776
2776
|
className: "lattice-mouth-row",
|
|
2777
2777
|
key: rowIndex
|
|
2778
2778
|
}, Array.from(Array(col)).map(
|
|
2779
|
-
(_2, colIndex) => renderItem(dataSource, rowIndex, colIndex, col)
|
|
2779
|
+
(_2, colIndex) => renderItem(dataSource, rowIndex, colIndex, col, onClick)
|
|
2780
2780
|
));
|
|
2781
2781
|
}));
|
|
2782
2782
|
}
|
|
2783
|
-
function renderItem(dataSource, rowIndex, colIndex, col) {
|
|
2783
|
+
function renderItem(dataSource, rowIndex, colIndex, col, onClick) {
|
|
2784
2784
|
const {
|
|
2785
2785
|
color = "",
|
|
2786
2786
|
value,
|
|
@@ -2790,7 +2790,10 @@ function renderItem(dataSource, rowIndex, colIndex, col) {
|
|
|
2790
2790
|
return /* @__PURE__ */ React__default.createElement("div", {
|
|
2791
2791
|
className: `lattice-mouth-item ${color}`,
|
|
2792
2792
|
style,
|
|
2793
|
-
key: colIndex
|
|
2793
|
+
key: colIndex,
|
|
2794
|
+
onClick: () => {
|
|
2795
|
+
onClick && onClick(rowIndex, colIndex, value, label);
|
|
2796
|
+
}
|
|
2794
2797
|
}, /* @__PURE__ */ React__default.createElement("div", {
|
|
2795
2798
|
className: "lattice-mouth-value"
|
|
2796
2799
|
}, value), /* @__PURE__ */ React__default.createElement("div", {
|
|
@@ -2800,7 +2803,7 @@ function renderItem(dataSource, rowIndex, colIndex, col) {
|
|
|
2800
2803
|
function getDataSourceItem$1(dataSource, rowIndex, colIndex, col) {
|
|
2801
2804
|
return dataSource[rowIndex * col + colIndex];
|
|
2802
2805
|
}
|
|
2803
|
-
var index$
|
|
2806
|
+
var index$x = "";
|
|
2804
2807
|
const DARK_STYLE = {
|
|
2805
2808
|
"--base-font-size": "20px",
|
|
2806
2809
|
"--background-color": "#282828",
|
|
@@ -2879,8 +2882,8 @@ function SplitContent(props) {
|
|
|
2879
2882
|
className: "card-content"
|
|
2880
2883
|
}, content[0]);
|
|
2881
2884
|
}
|
|
2882
|
-
var index$
|
|
2883
|
-
function index$
|
|
2885
|
+
var index$w = "";
|
|
2886
|
+
function index$v(props) {
|
|
2884
2887
|
const {
|
|
2885
2888
|
label = "\u8BF7\u9009\u62E9",
|
|
2886
2889
|
dataSource = [],
|
|
@@ -3012,7 +3015,7 @@ function Loading(props) {
|
|
|
3012
3015
|
"p-id": "2179"
|
|
3013
3016
|
})), /* @__PURE__ */ React__default.createElement("div", null, text)));
|
|
3014
3017
|
}
|
|
3015
|
-
var index$
|
|
3018
|
+
var index$u = "";
|
|
3016
3019
|
function getRightValue(value, max, min) {
|
|
3017
3020
|
if (value !== "") {
|
|
3018
3021
|
if (typeof min === "number") {
|
|
@@ -3026,7 +3029,7 @@ function getRightValue(value, max, min) {
|
|
|
3026
3029
|
return value;
|
|
3027
3030
|
}
|
|
3028
3031
|
}
|
|
3029
|
-
function index$
|
|
3032
|
+
function index$t(props) {
|
|
3030
3033
|
const {
|
|
3031
3034
|
label = "",
|
|
3032
3035
|
autoFocus = true,
|
|
@@ -3295,18 +3298,42 @@ function getVariableByJSON(params, engine) {
|
|
|
3295
3298
|
class Filed extends JSONWatch {
|
|
3296
3299
|
constructor(defaultData, validate = {}) {
|
|
3297
3300
|
super(defaultData);
|
|
3298
|
-
|
|
3299
|
-
|
|
3301
|
+
this.validateStatusMap = {};
|
|
3302
|
+
this.validatorMap = {};
|
|
3303
|
+
}
|
|
3304
|
+
getProps(key, { validator } = {}) {
|
|
3305
|
+
const realValidator = typeof validator !== "function" && validator !== "required" ? null : (val) => {
|
|
3306
|
+
if (validator === "required") {
|
|
3307
|
+
validator = (val2) => {
|
|
3308
|
+
return val2 == null || val2 === "" ? "\u5FC5\u586B" : null;
|
|
3309
|
+
};
|
|
3310
|
+
}
|
|
3311
|
+
this.validateStatusMap[key] = validator == null ? void 0 : validator(val);
|
|
3312
|
+
};
|
|
3313
|
+
this.validatorMap[key] = realValidator;
|
|
3300
3314
|
return {
|
|
3301
3315
|
value: this.get(key),
|
|
3302
3316
|
onChange: (value) => {
|
|
3303
3317
|
if (value && value.target && value.preventDefault) {
|
|
3304
3318
|
value = value.target.value;
|
|
3305
3319
|
}
|
|
3320
|
+
realValidator == null ? void 0 : realValidator(value);
|
|
3306
3321
|
this.set(key, value);
|
|
3307
3322
|
}
|
|
3308
3323
|
};
|
|
3309
3324
|
}
|
|
3325
|
+
getValidateStatus(key) {
|
|
3326
|
+
return this.validateStatusMap[key];
|
|
3327
|
+
}
|
|
3328
|
+
validate() {
|
|
3329
|
+
var _a, _b;
|
|
3330
|
+
(_b = (_a = Object.entries(this.validatorMap)) == null ? void 0 : _a.forEach) == null ? void 0 : _b.call(_a, ([key, _validator]) => {
|
|
3331
|
+
_validator == null ? void 0 : _validator(this.get(key));
|
|
3332
|
+
});
|
|
3333
|
+
const errorMessages = Object.entries(this.validateStatusMap).filter(([key, _validatorMessage]) => _validatorMessage);
|
|
3334
|
+
errorMessages.length > 0 && this.emit("$updated");
|
|
3335
|
+
return errorMessages.length === 0 ? Promise.resolve() : Promise.reject(Object.fromEntries(errorMessages));
|
|
3336
|
+
}
|
|
3310
3337
|
getValue(key) {
|
|
3311
3338
|
return this.get(key);
|
|
3312
3339
|
}
|
|
@@ -3317,7 +3344,7 @@ class Filed extends JSONWatch {
|
|
|
3317
3344
|
this.set(key, value);
|
|
3318
3345
|
}
|
|
3319
3346
|
}
|
|
3320
|
-
function index$
|
|
3347
|
+
function index$s(defaultData, validate) {
|
|
3321
3348
|
const [, forceUpdate] = React__default.useState({});
|
|
3322
3349
|
const [filed] = React__default.useState(() => {
|
|
3323
3350
|
return new Filed(defaultData, validate);
|
|
@@ -3327,8 +3354,8 @@ function index$r(defaultData, validate) {
|
|
|
3327
3354
|
});
|
|
3328
3355
|
return filed;
|
|
3329
3356
|
}
|
|
3330
|
-
var index$
|
|
3331
|
-
function index$
|
|
3357
|
+
var index$r = "";
|
|
3358
|
+
function index$q(props) {
|
|
3332
3359
|
const {
|
|
3333
3360
|
label = "",
|
|
3334
3361
|
defaultValue,
|
|
@@ -3365,7 +3392,7 @@ function index$p(props) {
|
|
|
3365
3392
|
}
|
|
3366
3393
|
})));
|
|
3367
3394
|
}
|
|
3368
|
-
var index$
|
|
3395
|
+
var index$p = "";
|
|
3369
3396
|
var global$1 = "";
|
|
3370
3397
|
const canUseDom$1 = !!(typeof window !== "undefined" && typeof document !== "undefined" && window.document && window.document.createElement);
|
|
3371
3398
|
if (canUseDom$1) {
|
|
@@ -3750,11 +3777,11 @@ var useUnmount = function(fn) {
|
|
|
3750
3777
|
}, []);
|
|
3751
3778
|
};
|
|
3752
3779
|
var useUnmount$1 = useUnmount;
|
|
3753
|
-
function isObject$
|
|
3780
|
+
function isObject$3(value) {
|
|
3754
3781
|
var type = typeof value;
|
|
3755
3782
|
return value != null && (type == "object" || type == "function");
|
|
3756
3783
|
}
|
|
3757
|
-
var isObject_1 = isObject$
|
|
3784
|
+
var isObject_1 = isObject$3;
|
|
3758
3785
|
var freeGlobal$1 = typeof commonjsGlobal == "object" && commonjsGlobal && commonjsGlobal.Object === Object && commonjsGlobal;
|
|
3759
3786
|
var _freeGlobal = freeGlobal$1;
|
|
3760
3787
|
var freeGlobal = _freeGlobal;
|
|
@@ -3832,7 +3859,7 @@ function isSymbol$1(value) {
|
|
|
3832
3859
|
return typeof value == "symbol" || isObjectLike(value) && baseGetTag(value) == symbolTag;
|
|
3833
3860
|
}
|
|
3834
3861
|
var isSymbol_1 = isSymbol$1;
|
|
3835
|
-
var baseTrim = _baseTrim, isObject$
|
|
3862
|
+
var baseTrim = _baseTrim, isObject$2 = isObject_1, isSymbol = isSymbol_1;
|
|
3836
3863
|
var NAN = 0 / 0;
|
|
3837
3864
|
var reIsBadHex = /^[-+]0x[0-9a-f]+$/i;
|
|
3838
3865
|
var reIsBinary = /^0b[01]+$/i;
|
|
@@ -3845,9 +3872,9 @@ function toNumber$1(value) {
|
|
|
3845
3872
|
if (isSymbol(value)) {
|
|
3846
3873
|
return NAN;
|
|
3847
3874
|
}
|
|
3848
|
-
if (isObject$
|
|
3875
|
+
if (isObject$2(value)) {
|
|
3849
3876
|
var other = typeof value.valueOf == "function" ? value.valueOf() : value;
|
|
3850
|
-
value = isObject$
|
|
3877
|
+
value = isObject$2(other) ? other + "" : other;
|
|
3851
3878
|
}
|
|
3852
3879
|
if (typeof value != "string") {
|
|
3853
3880
|
return value === 0 ? value : +value;
|
|
@@ -3857,16 +3884,16 @@ function toNumber$1(value) {
|
|
|
3857
3884
|
return isBinary || reIsOctal.test(value) ? freeParseInt(value.slice(2), isBinary ? 2 : 8) : reIsBadHex.test(value) ? NAN : +value;
|
|
3858
3885
|
}
|
|
3859
3886
|
var toNumber_1 = toNumber$1;
|
|
3860
|
-
var isObject = isObject_1, now = now_1, toNumber = toNumber_1;
|
|
3861
|
-
var FUNC_ERROR_TEXT = "Expected a function";
|
|
3887
|
+
var isObject$1 = isObject_1, now = now_1, toNumber = toNumber_1;
|
|
3888
|
+
var FUNC_ERROR_TEXT$1 = "Expected a function";
|
|
3862
3889
|
var nativeMax = Math.max, nativeMin = Math.min;
|
|
3863
|
-
function debounce(func, wait, options) {
|
|
3890
|
+
function debounce$1(func, wait, options) {
|
|
3864
3891
|
var lastArgs, lastThis, maxWait, result, timerId, lastCallTime, lastInvokeTime = 0, leading = false, maxing = false, trailing = true;
|
|
3865
3892
|
if (typeof func != "function") {
|
|
3866
|
-
throw new TypeError(FUNC_ERROR_TEXT);
|
|
3893
|
+
throw new TypeError(FUNC_ERROR_TEXT$1);
|
|
3867
3894
|
}
|
|
3868
3895
|
wait = toNumber(wait) || 0;
|
|
3869
|
-
if (isObject(options)) {
|
|
3896
|
+
if (isObject$1(options)) {
|
|
3870
3897
|
leading = !!options.leading;
|
|
3871
3898
|
maxing = "maxWait" in options;
|
|
3872
3899
|
maxWait = maxing ? nativeMax(toNumber(options.maxWait) || 0, wait) : maxWait;
|
|
@@ -3941,10 +3968,27 @@ function debounce(func, wait, options) {
|
|
|
3941
3968
|
debounced.flush = flush2;
|
|
3942
3969
|
return debounced;
|
|
3943
3970
|
}
|
|
3944
|
-
var debounce_1 = debounce;
|
|
3945
|
-
var debounce$1 = debounce_1;
|
|
3971
|
+
var debounce_1 = debounce$1;
|
|
3946
3972
|
var isBrowser$1 = !!(typeof window !== "undefined" && window.document && window.document.createElement);
|
|
3947
3973
|
var isBrowser$2 = isBrowser$1;
|
|
3974
|
+
var debounce = debounce_1, isObject = isObject_1;
|
|
3975
|
+
var FUNC_ERROR_TEXT = "Expected a function";
|
|
3976
|
+
function throttle(func, wait, options) {
|
|
3977
|
+
var leading = true, trailing = true;
|
|
3978
|
+
if (typeof func != "function") {
|
|
3979
|
+
throw new TypeError(FUNC_ERROR_TEXT);
|
|
3980
|
+
}
|
|
3981
|
+
if (isObject(options)) {
|
|
3982
|
+
leading = "leading" in options ? !!options.leading : leading;
|
|
3983
|
+
trailing = "trailing" in options ? !!options.trailing : trailing;
|
|
3984
|
+
}
|
|
3985
|
+
return debounce(func, wait, {
|
|
3986
|
+
"leading": leading,
|
|
3987
|
+
"maxWait": wait,
|
|
3988
|
+
"trailing": trailing
|
|
3989
|
+
});
|
|
3990
|
+
}
|
|
3991
|
+
var throttle_1 = throttle;
|
|
3948
3992
|
var useUpdate = function() {
|
|
3949
3993
|
var _a = __read(useState({}), 2), setState = _a[1];
|
|
3950
3994
|
return useCallback(function() {
|
|
@@ -4006,7 +4050,7 @@ var createEffectWithTarget = function(useEffectType) {
|
|
|
4006
4050
|
var createEffectWithTarget$1 = createEffectWithTarget;
|
|
4007
4051
|
var useEffectWithTarget = createEffectWithTarget$1(useEffect);
|
|
4008
4052
|
var useEffectWithTarget$1 = useEffectWithTarget;
|
|
4009
|
-
var dayjs_min
|
|
4053
|
+
var dayjs_min = { exports: {} };
|
|
4010
4054
|
(function(module, exports) {
|
|
4011
4055
|
!function(t2, e2) {
|
|
4012
4056
|
module.exports = e2();
|
|
@@ -4295,8 +4339,8 @@ var dayjs_min$1 = { exports: {} };
|
|
|
4295
4339
|
return O(1e3 * t3);
|
|
4296
4340
|
}, O.en = D[g2], O.Ls = D, O.p = {}, O;
|
|
4297
4341
|
});
|
|
4298
|
-
})(dayjs_min
|
|
4299
|
-
var dayjs
|
|
4342
|
+
})(dayjs_min);
|
|
4343
|
+
var dayjs = dayjs_min.exports;
|
|
4300
4344
|
function isNodeOrWeb() {
|
|
4301
4345
|
var freeGlobal2 = (typeof global === "undefined" ? "undefined" : typeof global) == "object" && global && global.Object === Object && global;
|
|
4302
4346
|
var freeSelf2 = typeof self == "object" && self && self.Object === Object && self;
|
|
@@ -4315,7 +4359,7 @@ function useDebounceFn(fn, options) {
|
|
|
4315
4359
|
var fnRef = useLatest(fn);
|
|
4316
4360
|
var wait = (_a = options === null || options === void 0 ? void 0 : options.wait) !== null && _a !== void 0 ? _a : 1e3;
|
|
4317
4361
|
var debounced = useMemo(function() {
|
|
4318
|
-
return
|
|
4362
|
+
return debounce_1(function() {
|
|
4319
4363
|
var args = [];
|
|
4320
4364
|
for (var _i = 0; _i < arguments.length; _i++) {
|
|
4321
4365
|
args[_i] = arguments[_i];
|
|
@@ -4493,7 +4537,7 @@ var _reactFastCompare_3_2_2_reactFastCompare = function isEqual(a, b2) {
|
|
|
4493
4537
|
if (options.root && options.root.nodeType != 1 && options.root.nodeType != 9) {
|
|
4494
4538
|
throw new Error("root must be a Document or Element");
|
|
4495
4539
|
}
|
|
4496
|
-
this._checkForIntersections =
|
|
4540
|
+
this._checkForIntersections = throttle2(
|
|
4497
4541
|
this._checkForIntersections.bind(this),
|
|
4498
4542
|
this.THROTTLE_TIMEOUT
|
|
4499
4543
|
);
|
|
@@ -4838,7 +4882,7 @@ var _reactFastCompare_3_2_2_reactFastCompare = function isEqual(a, b2) {
|
|
|
4838
4882
|
function now2() {
|
|
4839
4883
|
return window.performance && performance.now && performance.now();
|
|
4840
4884
|
}
|
|
4841
|
-
function
|
|
4885
|
+
function throttle2(fn, timeout) {
|
|
4842
4886
|
var timer = null;
|
|
4843
4887
|
return function() {
|
|
4844
4888
|
if (!timer) {
|
|
@@ -5023,6 +5067,33 @@ var useUnmountedRef = function() {
|
|
|
5023
5067
|
return unmountedRef;
|
|
5024
5068
|
};
|
|
5025
5069
|
var useUnmountedRef$1 = useUnmountedRef;
|
|
5070
|
+
function useThrottleFn(fn, options) {
|
|
5071
|
+
var _a;
|
|
5072
|
+
if (isDev$2) {
|
|
5073
|
+
if (!isFunction(fn)) {
|
|
5074
|
+
console.error("useThrottleFn expected parameter is a function, got ".concat(typeof fn));
|
|
5075
|
+
}
|
|
5076
|
+
}
|
|
5077
|
+
var fnRef = useLatest(fn);
|
|
5078
|
+
var wait = (_a = options === null || options === void 0 ? void 0 : options.wait) !== null && _a !== void 0 ? _a : 1e3;
|
|
5079
|
+
var throttled = useMemo(function() {
|
|
5080
|
+
return throttle_1(function() {
|
|
5081
|
+
var args = [];
|
|
5082
|
+
for (var _i = 0; _i < arguments.length; _i++) {
|
|
5083
|
+
args[_i] = arguments[_i];
|
|
5084
|
+
}
|
|
5085
|
+
return fnRef.current.apply(fnRef, __spreadArray([], __read(args), false));
|
|
5086
|
+
}, wait, options);
|
|
5087
|
+
}, []);
|
|
5088
|
+
useUnmount$1(function() {
|
|
5089
|
+
throttled.cancel();
|
|
5090
|
+
});
|
|
5091
|
+
return {
|
|
5092
|
+
run: throttled,
|
|
5093
|
+
cancel: throttled.cancel,
|
|
5094
|
+
flush: throttled.flush
|
|
5095
|
+
};
|
|
5096
|
+
}
|
|
5026
5097
|
var mask = "";
|
|
5027
5098
|
const MIN_DISTANCE = 10;
|
|
5028
5099
|
function getDirection(x, y) {
|
|
@@ -8425,7 +8496,7 @@ function withStopPropagation(events, element) {
|
|
|
8425
8496
|
}
|
|
8426
8497
|
return React__default.cloneElement(element, props);
|
|
8427
8498
|
}
|
|
8428
|
-
const classPrefix$
|
|
8499
|
+
const classPrefix$n = `adm-mask`;
|
|
8429
8500
|
const opacityRecord = {
|
|
8430
8501
|
default: 0.55,
|
|
8431
8502
|
thin: 0.35,
|
|
@@ -8435,7 +8506,7 @@ const colorRecord$2 = {
|
|
|
8435
8506
|
black: "0, 0, 0",
|
|
8436
8507
|
white: "255, 255, 255"
|
|
8437
8508
|
};
|
|
8438
|
-
const defaultProps$
|
|
8509
|
+
const defaultProps$k = {
|
|
8439
8510
|
visible: true,
|
|
8440
8511
|
destroyOnClose: false,
|
|
8441
8512
|
forceRender: false,
|
|
@@ -8446,7 +8517,7 @@ const defaultProps$h = {
|
|
|
8446
8517
|
stopPropagation: ["click"]
|
|
8447
8518
|
};
|
|
8448
8519
|
const Mask$1 = (p2) => {
|
|
8449
|
-
const props = mergeProps(defaultProps$
|
|
8520
|
+
const props = mergeProps(defaultProps$k, p2);
|
|
8450
8521
|
const {
|
|
8451
8522
|
locale
|
|
8452
8523
|
} = useConfig();
|
|
@@ -8487,7 +8558,7 @@ const Mask$1 = (p2) => {
|
|
|
8487
8558
|
}
|
|
8488
8559
|
});
|
|
8489
8560
|
const node = withStopPropagation(props.stopPropagation, withNativeProps(props, React__default.createElement(animated.div, {
|
|
8490
|
-
className: classPrefix$
|
|
8561
|
+
className: classPrefix$n,
|
|
8491
8562
|
ref,
|
|
8492
8563
|
"aria-hidden": true,
|
|
8493
8564
|
style: Object.assign(Object.assign({}, props.style), {
|
|
@@ -8502,12 +8573,12 @@ const Mask$1 = (p2) => {
|
|
|
8502
8573
|
}
|
|
8503
8574
|
}
|
|
8504
8575
|
}, props.onMaskClick && React__default.createElement("div", {
|
|
8505
|
-
className: `${classPrefix$
|
|
8576
|
+
className: `${classPrefix$n}-aria-button`,
|
|
8506
8577
|
role: "button",
|
|
8507
8578
|
"aria-label": locale.Mask.name,
|
|
8508
8579
|
onClick: props.onMaskClick
|
|
8509
8580
|
}), React__default.createElement("div", {
|
|
8510
|
-
className: `${classPrefix$
|
|
8581
|
+
className: `${classPrefix$n}-content`
|
|
8511
8582
|
}, props.children))));
|
|
8512
8583
|
return React__default.createElement(ShouldRender, {
|
|
8513
8584
|
active,
|
|
@@ -10333,8 +10404,8 @@ function useWheel(handler, config2) {
|
|
|
10333
10404
|
wheel: handler
|
|
10334
10405
|
}, config2 || {}, "wheel");
|
|
10335
10406
|
}
|
|
10336
|
-
const classPrefix$
|
|
10337
|
-
const defaultProps$
|
|
10407
|
+
const classPrefix$m = `adm-popup`;
|
|
10408
|
+
const defaultProps$j = Object.assign(Object.assign({}, defaultPopupBaseProps), {
|
|
10338
10409
|
closeOnSwipe: false,
|
|
10339
10410
|
position: "bottom"
|
|
10340
10411
|
});
|
|
@@ -10343,8 +10414,8 @@ const Popup$1 = (p2) => {
|
|
|
10343
10414
|
locale,
|
|
10344
10415
|
popup: componentConfig = {}
|
|
10345
10416
|
} = useConfig();
|
|
10346
|
-
const props = mergeProps(defaultProps$
|
|
10347
|
-
const bodyCls = classNames(`${classPrefix$
|
|
10417
|
+
const props = mergeProps(defaultProps$j, componentConfig, p2);
|
|
10418
|
+
const bodyCls = classNames(`${classPrefix$m}-body`, props.bodyClassName, `${classPrefix$m}-body-position-${props.position}`);
|
|
10348
10419
|
const [active, setActive] = useState(props.visible);
|
|
10349
10420
|
const ref = useRef(null);
|
|
10350
10421
|
useLockScroll(ref, props.disableBodyScroll && active ? "strict" : false);
|
|
@@ -10391,7 +10462,7 @@ const Popup$1 = (p2) => {
|
|
|
10391
10462
|
});
|
|
10392
10463
|
const maskVisible = useInnerVisible(active && props.visible);
|
|
10393
10464
|
const node = withStopPropagation(props.stopPropagation, withNativeProps(props, React__default.createElement("div", Object.assign({
|
|
10394
|
-
className: classPrefix$
|
|
10465
|
+
className: classPrefix$m,
|
|
10395
10466
|
onClick: props.onClick,
|
|
10396
10467
|
style: {
|
|
10397
10468
|
display: active ? void 0 : "none",
|
|
@@ -10434,7 +10505,7 @@ const Popup$1 = (p2) => {
|
|
|
10434
10505
|
}),
|
|
10435
10506
|
ref
|
|
10436
10507
|
}, props.showCloseButton && React__default.createElement("a", {
|
|
10437
|
-
className: classNames(`${classPrefix$
|
|
10508
|
+
className: classNames(`${classPrefix$m}-close-icon`, "adm-plain-anchor"),
|
|
10438
10509
|
onClick: () => {
|
|
10439
10510
|
var _a;
|
|
10440
10511
|
(_a = props.onClose) === null || _a === void 0 ? void 0 : _a.call(props);
|
|
@@ -10450,10 +10521,10 @@ const Popup$1 = (p2) => {
|
|
|
10450
10521
|
};
|
|
10451
10522
|
var Popup = Popup$1;
|
|
10452
10523
|
var safeArea = "";
|
|
10453
|
-
const classPrefix$
|
|
10524
|
+
const classPrefix$l = "adm-safe-area";
|
|
10454
10525
|
const SafeArea$1 = (props) => {
|
|
10455
10526
|
return withNativeProps(props, React__default.createElement("div", {
|
|
10456
|
-
className: classNames(classPrefix$
|
|
10527
|
+
className: classNames(classPrefix$l, `${classPrefix$l}-position-${props.position}`)
|
|
10457
10528
|
}));
|
|
10458
10529
|
};
|
|
10459
10530
|
var SafeArea = SafeArea$1;
|
|
@@ -10573,25 +10644,27 @@ function renderImperatively(element) {
|
|
|
10573
10644
|
}));
|
|
10574
10645
|
return {
|
|
10575
10646
|
close: () => __awaiter(this, void 0, void 0, function* () {
|
|
10576
|
-
var _a;
|
|
10647
|
+
var _a, _b, _c;
|
|
10577
10648
|
if (!wrapperRef.current) {
|
|
10578
10649
|
unmount2();
|
|
10650
|
+
(_b = (_a = element.props).afterClose) === null || _b === void 0 ? void 0 : _b.call(_a);
|
|
10579
10651
|
} else {
|
|
10580
|
-
(
|
|
10652
|
+
(_c = wrapperRef.current) === null || _c === void 0 ? void 0 : _c.close();
|
|
10581
10653
|
}
|
|
10582
10654
|
}),
|
|
10583
10655
|
replace: (element2) => {
|
|
10584
10656
|
var _a;
|
|
10585
10657
|
(_a = wrapperRef.current) === null || _a === void 0 ? void 0 : _a.replace(element2);
|
|
10586
|
-
}
|
|
10658
|
+
},
|
|
10659
|
+
isRendered: () => !!wrapperRef.current
|
|
10587
10660
|
};
|
|
10588
10661
|
}
|
|
10589
10662
|
var autoCenter = "";
|
|
10590
|
-
const classPrefix$
|
|
10663
|
+
const classPrefix$k = "adm-auto-center";
|
|
10591
10664
|
const AutoCenter$1 = (props) => withNativeProps(props, React__default.createElement("div", {
|
|
10592
|
-
className: classPrefix$
|
|
10665
|
+
className: classPrefix$k
|
|
10593
10666
|
}, React__default.createElement("div", {
|
|
10594
|
-
className: `${classPrefix$
|
|
10667
|
+
className: `${classPrefix$k}-content`
|
|
10595
10668
|
}, props.children)));
|
|
10596
10669
|
var AutoCenter = AutoCenter$1;
|
|
10597
10670
|
var image = "";
|
|
@@ -10652,20 +10725,20 @@ const BrokenImageIcon = () => React__default.createElement("svg", {
|
|
|
10652
10725
|
fill: "#DBDBDB",
|
|
10653
10726
|
fillRule: "nonzero"
|
|
10654
10727
|
}));
|
|
10655
|
-
const classPrefix$
|
|
10656
|
-
const defaultProps$
|
|
10728
|
+
const classPrefix$j = `adm-image`;
|
|
10729
|
+
const defaultProps$i = {
|
|
10657
10730
|
fit: "fill",
|
|
10658
10731
|
placeholder: React__default.createElement("div", {
|
|
10659
|
-
className: `${classPrefix$
|
|
10732
|
+
className: `${classPrefix$j}-tip`
|
|
10660
10733
|
}, React__default.createElement(ImageIcon, null)),
|
|
10661
10734
|
fallback: React__default.createElement("div", {
|
|
10662
|
-
className: `${classPrefix$
|
|
10735
|
+
className: `${classPrefix$j}-tip`
|
|
10663
10736
|
}, React__default.createElement(BrokenImageIcon, null)),
|
|
10664
10737
|
lazy: false,
|
|
10665
10738
|
draggable: false
|
|
10666
10739
|
};
|
|
10667
10740
|
const Image$1 = staged_1((p2) => {
|
|
10668
|
-
const props = mergeProps(defaultProps$
|
|
10741
|
+
const props = mergeProps(defaultProps$i, p2);
|
|
10669
10742
|
const [loaded, setLoaded] = useState(false);
|
|
10670
10743
|
const [failed, setFailed] = useState(false);
|
|
10671
10744
|
const ref = useRef(null);
|
|
@@ -10692,7 +10765,7 @@ const Image$1 = staged_1((p2) => {
|
|
|
10692
10765
|
const img = React__default.createElement("img", {
|
|
10693
10766
|
ref: imgRef,
|
|
10694
10767
|
id: props.id,
|
|
10695
|
-
className: `${classPrefix$
|
|
10768
|
+
className: `${classPrefix$j}-img`,
|
|
10696
10769
|
src,
|
|
10697
10770
|
alt: props.alt,
|
|
10698
10771
|
onClick: props.onClick,
|
|
@@ -10732,7 +10805,7 @@ const Image$1 = staged_1((p2) => {
|
|
|
10732
10805
|
}
|
|
10733
10806
|
return withNativeProps(props, React__default.createElement("div", {
|
|
10734
10807
|
ref,
|
|
10735
|
-
className: classPrefix$
|
|
10808
|
+
className: classPrefix$j,
|
|
10736
10809
|
style,
|
|
10737
10810
|
onClick: props.onContainerClick
|
|
10738
10811
|
}, props.lazy && !initialized && React__default.createElement(LazyDetector, {
|
|
@@ -10742,25 +10815,56 @@ const Image$1 = staged_1((p2) => {
|
|
|
10742
10815
|
}), renderInner()));
|
|
10743
10816
|
});
|
|
10744
10817
|
var Image = Image$1;
|
|
10818
|
+
var badge = "";
|
|
10819
|
+
const classPrefix$i = `adm-badge`;
|
|
10820
|
+
const dot = React__default.createElement(React__default.Fragment, null);
|
|
10821
|
+
const Badge$1 = (props) => {
|
|
10822
|
+
const {
|
|
10823
|
+
content,
|
|
10824
|
+
color,
|
|
10825
|
+
children
|
|
10826
|
+
} = props;
|
|
10827
|
+
const isDot = content === dot;
|
|
10828
|
+
const badgeClass = classNames(classPrefix$i, {
|
|
10829
|
+
[`${classPrefix$i}-fixed`]: !!children,
|
|
10830
|
+
[`${classPrefix$i}-dot`]: isDot,
|
|
10831
|
+
[`${classPrefix$i}-bordered`]: props.bordered
|
|
10832
|
+
});
|
|
10833
|
+
const element = content || content === 0 ? withNativeProps(props, React__default.createElement("div", {
|
|
10834
|
+
className: badgeClass,
|
|
10835
|
+
style: {
|
|
10836
|
+
"--color": color
|
|
10837
|
+
}
|
|
10838
|
+
}, !isDot && React__default.createElement("div", {
|
|
10839
|
+
className: `${classPrefix$i}-content`
|
|
10840
|
+
}, content))) : null;
|
|
10841
|
+
return children ? React__default.createElement("div", {
|
|
10842
|
+
className: classNames(`${classPrefix$i}-wrapper`, props.wrapperClassName),
|
|
10843
|
+
style: props.wrapperStyle
|
|
10844
|
+
}, children, element) : element;
|
|
10845
|
+
};
|
|
10846
|
+
var Badge = attachPropertiesToComponent(Badge$1, {
|
|
10847
|
+
dot
|
|
10848
|
+
});
|
|
10745
10849
|
var button = "";
|
|
10746
10850
|
var dotLoading = "";
|
|
10747
|
-
const classPrefix$
|
|
10851
|
+
const classPrefix$h = `adm-dot-loading`;
|
|
10748
10852
|
const colorRecord$1 = {
|
|
10749
10853
|
default: "var(--adm-color-weak)",
|
|
10750
10854
|
primary: "var(--adm-color-primary)",
|
|
10751
10855
|
white: "var(--adm-color-white)"
|
|
10752
10856
|
};
|
|
10753
|
-
const defaultProps$
|
|
10857
|
+
const defaultProps$h = {
|
|
10754
10858
|
color: "default"
|
|
10755
10859
|
};
|
|
10756
10860
|
const DotLoading$1 = memo((p2) => {
|
|
10757
10861
|
var _a;
|
|
10758
|
-
const props = mergeProps(defaultProps$
|
|
10862
|
+
const props = mergeProps(defaultProps$h, p2);
|
|
10759
10863
|
return withNativeProps(props, React__default.createElement("div", {
|
|
10760
10864
|
style: {
|
|
10761
10865
|
color: (_a = colorRecord$1[props.color]) !== null && _a !== void 0 ? _a : props.color
|
|
10762
10866
|
},
|
|
10763
|
-
className: classNames("adm-loading", classPrefix$
|
|
10867
|
+
className: classNames("adm-loading", classPrefix$h)
|
|
10764
10868
|
}, React__default.createElement("svg", {
|
|
10765
10869
|
height: "1em",
|
|
10766
10870
|
viewBox: "0 0 100 40",
|
|
@@ -10804,8 +10908,8 @@ function isPromise(obj) {
|
|
|
10804
10908
|
function isIOS() {
|
|
10805
10909
|
return canUseDom$1 ? /ios|iphone|ipad|ipod/.test(navigator.userAgent.toLowerCase()) : false;
|
|
10806
10910
|
}
|
|
10807
|
-
const classPrefix$
|
|
10808
|
-
const defaultProps$
|
|
10911
|
+
const classPrefix$g = `adm-button`;
|
|
10912
|
+
const defaultProps$g = {
|
|
10809
10913
|
color: "default",
|
|
10810
10914
|
fill: "solid",
|
|
10811
10915
|
block: false,
|
|
@@ -10818,7 +10922,7 @@ const defaultProps$d = {
|
|
|
10818
10922
|
size: "middle"
|
|
10819
10923
|
};
|
|
10820
10924
|
const Button$1 = forwardRef((p2, ref) => {
|
|
10821
|
-
const props = mergeProps(defaultProps$
|
|
10925
|
+
const props = mergeProps(defaultProps$g, p2);
|
|
10822
10926
|
const [innerLoading, setInnerLoading] = useState(false);
|
|
10823
10927
|
const nativeButtonRef = useRef(null);
|
|
10824
10928
|
const loading2 = props.loading === "auto" ? innerLoading : props.loading;
|
|
@@ -10847,24 +10951,24 @@ const Button$1 = forwardRef((p2, ref) => {
|
|
|
10847
10951
|
ref: nativeButtonRef,
|
|
10848
10952
|
type: props.type,
|
|
10849
10953
|
onClick: handleClick,
|
|
10850
|
-
className: classNames(classPrefix$
|
|
10851
|
-
[`${classPrefix$
|
|
10852
|
-
[`${classPrefix$
|
|
10853
|
-
[`${classPrefix$
|
|
10854
|
-
[`${classPrefix$
|
|
10855
|
-
[`${classPrefix$
|
|
10856
|
-
[`${classPrefix$
|
|
10857
|
-
[`${classPrefix$
|
|
10858
|
-
[`${classPrefix$
|
|
10859
|
-
[`${classPrefix$
|
|
10860
|
-
}, `${classPrefix$
|
|
10954
|
+
className: classNames(classPrefix$g, {
|
|
10955
|
+
[`${classPrefix$g}-${props.color}`]: props.color,
|
|
10956
|
+
[`${classPrefix$g}-block`]: props.block,
|
|
10957
|
+
[`${classPrefix$g}-disabled`]: disabled,
|
|
10958
|
+
[`${classPrefix$g}-fill-outline`]: props.fill === "outline",
|
|
10959
|
+
[`${classPrefix$g}-fill-none`]: props.fill === "none",
|
|
10960
|
+
[`${classPrefix$g}-mini`]: props.size === "mini",
|
|
10961
|
+
[`${classPrefix$g}-small`]: props.size === "small",
|
|
10962
|
+
[`${classPrefix$g}-large`]: props.size === "large",
|
|
10963
|
+
[`${classPrefix$g}-loading`]: loading2
|
|
10964
|
+
}, `${classPrefix$g}-shape-${props.shape}`),
|
|
10861
10965
|
disabled,
|
|
10862
10966
|
onMouseDown: props.onMouseDown,
|
|
10863
10967
|
onMouseUp: props.onMouseUp,
|
|
10864
10968
|
onTouchStart: props.onTouchStart,
|
|
10865
10969
|
onTouchEnd: props.onTouchEnd
|
|
10866
10970
|
}, loading2 ? React__default.createElement("div", {
|
|
10867
|
-
className: `${classPrefix$
|
|
10971
|
+
className: `${classPrefix$g}-loading-wrapper`
|
|
10868
10972
|
}, props.loadingIcon, props.loadingText) : React__default.createElement("span", null, props.children)));
|
|
10869
10973
|
});
|
|
10870
10974
|
var Button = Button$1;
|
|
@@ -11211,6 +11315,50 @@ function _defineProperty(e2, r2, t2) {
|
|
|
11211
11315
|
writable: true
|
|
11212
11316
|
}) : e2[r2] = t2, e2;
|
|
11213
11317
|
}
|
|
11318
|
+
function useResizeEffect(effect, targetRef) {
|
|
11319
|
+
const fn = useMemoizedFn(effect);
|
|
11320
|
+
useIsomorphicLayoutEffect$2(() => {
|
|
11321
|
+
const target = targetRef.current;
|
|
11322
|
+
if (!target)
|
|
11323
|
+
return;
|
|
11324
|
+
if (window.ResizeObserver) {
|
|
11325
|
+
let animationFrame;
|
|
11326
|
+
const observer = new ResizeObserver(() => {
|
|
11327
|
+
animationFrame = window.requestAnimationFrame(() => fn(target));
|
|
11328
|
+
});
|
|
11329
|
+
observer.observe(target);
|
|
11330
|
+
return () => {
|
|
11331
|
+
window.cancelAnimationFrame(animationFrame);
|
|
11332
|
+
observer.disconnect();
|
|
11333
|
+
};
|
|
11334
|
+
} else {
|
|
11335
|
+
fn(target);
|
|
11336
|
+
}
|
|
11337
|
+
}, [targetRef]);
|
|
11338
|
+
}
|
|
11339
|
+
function observe(element, options, callback) {
|
|
11340
|
+
if (element && typeof MutationObserver !== "undefined") {
|
|
11341
|
+
let observer = new MutationObserver(() => {
|
|
11342
|
+
callback();
|
|
11343
|
+
});
|
|
11344
|
+
observer.observe(element, options);
|
|
11345
|
+
return () => {
|
|
11346
|
+
if (observer) {
|
|
11347
|
+
observer.disconnect();
|
|
11348
|
+
observer = null;
|
|
11349
|
+
}
|
|
11350
|
+
};
|
|
11351
|
+
}
|
|
11352
|
+
return () => {
|
|
11353
|
+
};
|
|
11354
|
+
}
|
|
11355
|
+
function useMutationEffect(effect, targetRef, options) {
|
|
11356
|
+
const fn = useMemoizedFn(effect);
|
|
11357
|
+
useEffect(() => {
|
|
11358
|
+
const cleanup = observe(targetRef.current, options, fn);
|
|
11359
|
+
return cleanup;
|
|
11360
|
+
}, [targetRef]);
|
|
11361
|
+
}
|
|
11214
11362
|
function bound(position, min, max) {
|
|
11215
11363
|
let ret = position;
|
|
11216
11364
|
if (min !== void 0) {
|
|
@@ -11221,6 +11369,20 @@ function bound(position, min, max) {
|
|
|
11221
11369
|
}
|
|
11222
11370
|
return ret;
|
|
11223
11371
|
}
|
|
11372
|
+
function traverseReactNode(children, fn) {
|
|
11373
|
+
let i = 0;
|
|
11374
|
+
function handle(target) {
|
|
11375
|
+
React__default.Children.forEach(target, (child) => {
|
|
11376
|
+
if (!_reactIs_18_3_1_reactIs.exports.isFragment(child)) {
|
|
11377
|
+
fn(child, i);
|
|
11378
|
+
i += 1;
|
|
11379
|
+
} else {
|
|
11380
|
+
handle(child.props.children);
|
|
11381
|
+
}
|
|
11382
|
+
});
|
|
11383
|
+
}
|
|
11384
|
+
handle(children);
|
|
11385
|
+
}
|
|
11224
11386
|
var picker = "";
|
|
11225
11387
|
function rubberband(distance, dimension, constant) {
|
|
11226
11388
|
return distance * dimension * constant / (dimension + constant * distance);
|
|
@@ -11249,7 +11411,7 @@ function measureCSSLength(raw) {
|
|
|
11249
11411
|
return 0;
|
|
11250
11412
|
}
|
|
11251
11413
|
}
|
|
11252
|
-
const classPrefix$
|
|
11414
|
+
const classPrefix$f = `adm-picker-view`;
|
|
11253
11415
|
const Wheel = memo((props) => {
|
|
11254
11416
|
const {
|
|
11255
11417
|
value,
|
|
@@ -11416,13 +11578,13 @@ const Wheel = memo((props) => {
|
|
|
11416
11578
|
const previous = column[previousIndex];
|
|
11417
11579
|
const next = column[nextIndex];
|
|
11418
11580
|
return React__default.createElement("div", {
|
|
11419
|
-
className: `${classPrefix$
|
|
11581
|
+
className: `${classPrefix$f}-column-accessible`
|
|
11420
11582
|
}, React__default.createElement("div", {
|
|
11421
|
-
className: `${classPrefix$
|
|
11583
|
+
className: `${classPrefix$f}-column-accessible-current`,
|
|
11422
11584
|
role: "button",
|
|
11423
11585
|
"aria-label": current ? `\u5F53\u524D\u9009\u62E9\u7684\u662F\uFF1A${current.label}` : "\u5F53\u524D\u672A\u9009\u62E9"
|
|
11424
11586
|
}, "-"), React__default.createElement("div", {
|
|
11425
|
-
className: `${classPrefix$
|
|
11587
|
+
className: `${classPrefix$f}-column-accessible-button`,
|
|
11426
11588
|
onClick: () => {
|
|
11427
11589
|
if (!previous)
|
|
11428
11590
|
return;
|
|
@@ -11431,7 +11593,7 @@ const Wheel = memo((props) => {
|
|
|
11431
11593
|
role: previous ? "button" : "text",
|
|
11432
11594
|
"aria-label": !previous ? "\u6CA1\u6709\u4E0A\u4E00\u9879" : `\u9009\u62E9\u4E0A\u4E00\u9879\uFF1A${previous.label}`
|
|
11433
11595
|
}, "-"), React__default.createElement("div", {
|
|
11434
|
-
className: `${classPrefix$
|
|
11596
|
+
className: `${classPrefix$f}-column-accessible-button`,
|
|
11435
11597
|
onClick: () => {
|
|
11436
11598
|
if (!next)
|
|
11437
11599
|
return;
|
|
@@ -11442,16 +11604,16 @@ const Wheel = memo((props) => {
|
|
|
11442
11604
|
}, "-"));
|
|
11443
11605
|
}
|
|
11444
11606
|
return React__default.createElement("div", {
|
|
11445
|
-
className: `${classPrefix$
|
|
11607
|
+
className: `${classPrefix$f}-column`
|
|
11446
11608
|
}, React__default.createElement("div", {
|
|
11447
|
-
className: `${classPrefix$
|
|
11609
|
+
className: `${classPrefix$f}-item-height-measure`,
|
|
11448
11610
|
ref: itemHeightMeasureRef
|
|
11449
11611
|
}), React__default.createElement(animated.div, {
|
|
11450
11612
|
ref: rootRef,
|
|
11451
11613
|
style: {
|
|
11452
11614
|
translateY: y
|
|
11453
11615
|
},
|
|
11454
|
-
className: `${classPrefix$
|
|
11616
|
+
className: `${classPrefix$f}-column-wheel`,
|
|
11455
11617
|
"aria-hidden": true
|
|
11456
11618
|
}, column.map((item, index2) => {
|
|
11457
11619
|
var _a;
|
|
@@ -11465,14 +11627,14 @@ const Wheel = memo((props) => {
|
|
|
11465
11627
|
return React__default.createElement("div", {
|
|
11466
11628
|
key: (_a = item.key) !== null && _a !== void 0 ? _a : item.value,
|
|
11467
11629
|
"data-selected": selected,
|
|
11468
|
-
className: classNames(`${classPrefix$
|
|
11469
|
-
[`${classPrefix$
|
|
11630
|
+
className: classNames(`${classPrefix$f}-column-item`, {
|
|
11631
|
+
[`${classPrefix$f}-column-item-active`]: selected
|
|
11470
11632
|
}),
|
|
11471
11633
|
onClick: handleClick,
|
|
11472
11634
|
"aria-hidden": !selected,
|
|
11473
11635
|
"aria-label": selected ? "active" : ""
|
|
11474
11636
|
}, React__default.createElement("div", {
|
|
11475
|
-
className: `${classPrefix$
|
|
11637
|
+
className: `${classPrefix$f}-column-item-label`
|
|
11476
11638
|
}, renderLabel(item)));
|
|
11477
11639
|
})), renderAccessible());
|
|
11478
11640
|
}, (prev, next) => {
|
|
@@ -11596,19 +11758,19 @@ function subscribe(onStoreChange) {
|
|
|
11596
11758
|
function useMotionReduced() {
|
|
11597
11759
|
return shim.exports.useSyncExternalStore(subscribe, isMotionReduced, isMotionReduced);
|
|
11598
11760
|
}
|
|
11599
|
-
const classPrefix$
|
|
11761
|
+
const classPrefix$e = "adm-spin-loading";
|
|
11600
11762
|
const colorRecord = {
|
|
11601
11763
|
default: "var(--adm-color-weak)",
|
|
11602
11764
|
primary: "var(--adm-color-primary)",
|
|
11603
11765
|
white: "var(--adm-color-white)"
|
|
11604
11766
|
};
|
|
11605
|
-
const defaultProps$
|
|
11767
|
+
const defaultProps$f = {
|
|
11606
11768
|
color: "default"
|
|
11607
11769
|
};
|
|
11608
11770
|
const circumference = 15 * 3.14159265358979 * 2;
|
|
11609
11771
|
const SpinLoading$1 = memo((p2) => {
|
|
11610
11772
|
var _a;
|
|
11611
|
-
const props = mergeProps(defaultProps$
|
|
11773
|
+
const props = mergeProps(defaultProps$f, p2);
|
|
11612
11774
|
const motionReduced = useMotionReduced();
|
|
11613
11775
|
const {
|
|
11614
11776
|
percent
|
|
@@ -11628,16 +11790,16 @@ const SpinLoading$1 = memo((p2) => {
|
|
|
11628
11790
|
}
|
|
11629
11791
|
});
|
|
11630
11792
|
return withNativeProps(props, React__default.createElement(animated.div, {
|
|
11631
|
-
className: classPrefix$
|
|
11793
|
+
className: classPrefix$e,
|
|
11632
11794
|
style: {
|
|
11633
11795
|
"--color": (_a = colorRecord[props.color]) !== null && _a !== void 0 ? _a : props.color,
|
|
11634
11796
|
"--percent": percent
|
|
11635
11797
|
}
|
|
11636
11798
|
}, React__default.createElement("svg", {
|
|
11637
|
-
className: `${classPrefix$
|
|
11799
|
+
className: `${classPrefix$e}-svg`,
|
|
11638
11800
|
viewBox: "0 0 32 32"
|
|
11639
11801
|
}, React__default.createElement(animated.circle, {
|
|
11640
|
-
className: `${classPrefix$
|
|
11802
|
+
className: `${classPrefix$e}-fill`,
|
|
11641
11803
|
fill: "transparent",
|
|
11642
11804
|
strokeWidth: "2",
|
|
11643
11805
|
strokeDasharray: circumference,
|
|
@@ -11649,17 +11811,17 @@ const SpinLoading$1 = memo((p2) => {
|
|
|
11649
11811
|
}))));
|
|
11650
11812
|
});
|
|
11651
11813
|
var SpinLoading = SpinLoading$1;
|
|
11652
|
-
const classPrefix$
|
|
11653
|
-
const defaultProps$
|
|
11814
|
+
const classPrefix$d = `adm-picker-view`;
|
|
11815
|
+
const defaultProps$e = {
|
|
11654
11816
|
defaultValue: [],
|
|
11655
11817
|
renderLabel: defaultRenderLabel,
|
|
11656
11818
|
mouseWheel: false,
|
|
11657
11819
|
loadingContent: React__default.createElement("div", {
|
|
11658
|
-
className: `${classPrefix$
|
|
11820
|
+
className: `${classPrefix$d}-loading-content`
|
|
11659
11821
|
}, React__default.createElement(SpinLoading, null))
|
|
11660
11822
|
};
|
|
11661
11823
|
const PickerView$1 = memo((p2) => {
|
|
11662
|
-
const props = mergeProps(defaultProps$
|
|
11824
|
+
const props = mergeProps(defaultProps$e, p2);
|
|
11663
11825
|
const [innerValue, setInnerValue] = useState(props.value === void 0 ? props.defaultValue : props.value);
|
|
11664
11826
|
useEffect(() => {
|
|
11665
11827
|
if (props.value === void 0)
|
|
@@ -11700,7 +11862,7 @@ const PickerView$1 = memo((p2) => {
|
|
|
11700
11862
|
});
|
|
11701
11863
|
}, []);
|
|
11702
11864
|
return withNativeProps(props, React__default.createElement("div", {
|
|
11703
|
-
className: `${classPrefix$
|
|
11865
|
+
className: `${classPrefix$d}`
|
|
11704
11866
|
}, props.loading ? props.loadingContent : React__default.createElement(React__default.Fragment, null, columns.map((column, index2) => React__default.createElement(Wheel, {
|
|
11705
11867
|
key: index2,
|
|
11706
11868
|
index: index2,
|
|
@@ -11710,20 +11872,20 @@ const PickerView$1 = memo((p2) => {
|
|
|
11710
11872
|
renderLabel: props.renderLabel,
|
|
11711
11873
|
mouseWheel: props.mouseWheel
|
|
11712
11874
|
})), React__default.createElement("div", {
|
|
11713
|
-
className: `${classPrefix$
|
|
11875
|
+
className: `${classPrefix$d}-mask`
|
|
11714
11876
|
}, React__default.createElement("div", {
|
|
11715
|
-
className: `${classPrefix$
|
|
11877
|
+
className: `${classPrefix$d}-mask-top`
|
|
11716
11878
|
}), React__default.createElement("div", {
|
|
11717
|
-
className: `${classPrefix$
|
|
11879
|
+
className: `${classPrefix$d}-mask-middle`
|
|
11718
11880
|
}), React__default.createElement("div", {
|
|
11719
|
-
className: `${classPrefix$
|
|
11881
|
+
className: `${classPrefix$d}-mask-bottom`
|
|
11720
11882
|
})))));
|
|
11721
11883
|
});
|
|
11722
11884
|
PickerView$1.displayName = "PickerView";
|
|
11723
11885
|
var pickerView = "";
|
|
11724
11886
|
var PickerView = PickerView$1;
|
|
11725
|
-
const classPrefix$
|
|
11726
|
-
const defaultProps$
|
|
11887
|
+
const classPrefix$c = `adm-picker`;
|
|
11888
|
+
const defaultProps$d = {
|
|
11727
11889
|
defaultValue: [],
|
|
11728
11890
|
closeOnMaskClick: true,
|
|
11729
11891
|
renderLabel: defaultRenderLabel,
|
|
@@ -11735,7 +11897,7 @@ const Picker$1 = memo(forwardRef((p2, ref) => {
|
|
|
11735
11897
|
const {
|
|
11736
11898
|
locale
|
|
11737
11899
|
} = useConfig();
|
|
11738
|
-
const props = mergeProps(defaultProps$
|
|
11900
|
+
const props = mergeProps(defaultProps$d, {
|
|
11739
11901
|
confirmText: locale.common.confirm,
|
|
11740
11902
|
cancelText: locale.common.cancel
|
|
11741
11903
|
}, p2);
|
|
@@ -11788,22 +11950,22 @@ const Picker$1 = memo(forwardRef((p2, ref) => {
|
|
|
11788
11950
|
}
|
|
11789
11951
|
});
|
|
11790
11952
|
const pickerElement = withNativeProps(props, React__default.createElement("div", {
|
|
11791
|
-
className: classPrefix$
|
|
11953
|
+
className: classPrefix$c
|
|
11792
11954
|
}, React__default.createElement("div", {
|
|
11793
|
-
className: `${classPrefix$
|
|
11955
|
+
className: `${classPrefix$c}-header`
|
|
11794
11956
|
}, React__default.createElement("a", {
|
|
11795
11957
|
role: "button",
|
|
11796
|
-
className: `${classPrefix$
|
|
11958
|
+
className: `${classPrefix$c}-header-button`,
|
|
11797
11959
|
onClick: () => {
|
|
11798
11960
|
var _a2;
|
|
11799
11961
|
(_a2 = props.onCancel) === null || _a2 === void 0 ? void 0 : _a2.call(props);
|
|
11800
11962
|
setVisible(false);
|
|
11801
11963
|
}
|
|
11802
11964
|
}, props.cancelText), React__default.createElement("div", {
|
|
11803
|
-
className: `${classPrefix$
|
|
11965
|
+
className: `${classPrefix$c}-header-title`
|
|
11804
11966
|
}, props.title), React__default.createElement("a", {
|
|
11805
11967
|
role: "button",
|
|
11806
|
-
className: classNames(`${classPrefix$
|
|
11968
|
+
className: classNames(`${classPrefix$c}-header-button`, props.loading && `${classPrefix$c}-header-button-disabled`),
|
|
11807
11969
|
onClick: () => {
|
|
11808
11970
|
if (props.loading)
|
|
11809
11971
|
return;
|
|
@@ -11812,7 +11974,7 @@ const Picker$1 = memo(forwardRef((p2, ref) => {
|
|
|
11812
11974
|
},
|
|
11813
11975
|
"aria-disabled": props.loading
|
|
11814
11976
|
}, props.confirmText)), React__default.createElement("div", {
|
|
11815
|
-
className: `${classPrefix$
|
|
11977
|
+
className: `${classPrefix$c}-body`
|
|
11816
11978
|
}, React__default.createElement(PickerView, {
|
|
11817
11979
|
loading: props.loading,
|
|
11818
11980
|
loadingContent: props.loadingContent,
|
|
@@ -11824,7 +11986,7 @@ const Picker$1 = memo(forwardRef((p2, ref) => {
|
|
|
11824
11986
|
}))));
|
|
11825
11987
|
const popupElement = React__default.createElement(Popup, {
|
|
11826
11988
|
style: props.popupStyle,
|
|
11827
|
-
className: classNames(`${classPrefix$
|
|
11989
|
+
className: classNames(`${classPrefix$c}-popup`, props.popupClassName),
|
|
11828
11990
|
visible,
|
|
11829
11991
|
position: "bottom",
|
|
11830
11992
|
onMaskClick: () => {
|
|
@@ -11880,90 +12042,345 @@ function prompt$1(props) {
|
|
|
11880
12042
|
var Picker = attachPropertiesToComponent(Picker$1, {
|
|
11881
12043
|
prompt: prompt$1
|
|
11882
12044
|
});
|
|
11883
|
-
var
|
|
11884
|
-
|
|
11885
|
-
const
|
|
11886
|
-
|
|
11887
|
-
mode: "default"
|
|
12045
|
+
var tabs = "";
|
|
12046
|
+
const classPrefix$b = `adm-tabs`;
|
|
12047
|
+
const Tab = () => {
|
|
12048
|
+
return null;
|
|
11888
12049
|
};
|
|
11889
|
-
const
|
|
11890
|
-
|
|
11891
|
-
|
|
11892
|
-
|
|
11893
|
-
|
|
11894
|
-
|
|
12050
|
+
const defaultProps$c = {
|
|
12051
|
+
activeLineMode: "auto",
|
|
12052
|
+
stretch: true,
|
|
12053
|
+
direction: "ltr"
|
|
12054
|
+
};
|
|
12055
|
+
const Tabs$1 = (p2) => {
|
|
12056
|
+
var _a;
|
|
12057
|
+
const props = mergeProps(defaultProps$c, p2);
|
|
12058
|
+
const tabListContainerRef = useRef(null);
|
|
12059
|
+
const activeLineRef = useRef(null);
|
|
12060
|
+
const keyToIndexRecord = {};
|
|
12061
|
+
let firstActiveKey = null;
|
|
12062
|
+
const panes = [];
|
|
12063
|
+
const isRTL = props.direction === "rtl";
|
|
12064
|
+
traverseReactNode(props.children, (child, index2) => {
|
|
12065
|
+
if (!isValidElement(child))
|
|
12066
|
+
return;
|
|
12067
|
+
const key = child.key;
|
|
12068
|
+
if (typeof key !== "string")
|
|
12069
|
+
return;
|
|
12070
|
+
if (index2 === 0) {
|
|
12071
|
+
firstActiveKey = key;
|
|
12072
|
+
}
|
|
12073
|
+
const length = panes.push(child);
|
|
12074
|
+
keyToIndexRecord[key] = length - 1;
|
|
12075
|
+
});
|
|
12076
|
+
const [activeKey, setActiveKey] = usePropsValue({
|
|
12077
|
+
value: props.activeKey,
|
|
12078
|
+
defaultValue: (_a = props.defaultActiveKey) !== null && _a !== void 0 ? _a : firstActiveKey,
|
|
12079
|
+
onChange: (v2) => {
|
|
12080
|
+
var _a2;
|
|
12081
|
+
if (v2 === null)
|
|
12082
|
+
return;
|
|
12083
|
+
(_a2 = props.onChange) === null || _a2 === void 0 ? void 0 : _a2.call(props, v2);
|
|
12084
|
+
}
|
|
12085
|
+
});
|
|
12086
|
+
const [{
|
|
12087
|
+
x,
|
|
12088
|
+
width
|
|
12089
|
+
}, inkApi] = useSpring(() => ({
|
|
12090
|
+
x: 0,
|
|
12091
|
+
width: 0,
|
|
12092
|
+
config: {
|
|
12093
|
+
tension: 300,
|
|
12094
|
+
clamp: true
|
|
11895
12095
|
}
|
|
11896
12096
|
}));
|
|
11897
|
-
|
|
11898
|
-
|
|
11899
|
-
|
|
11900
|
-
|
|
11901
|
-
|
|
11902
|
-
|
|
11903
|
-
|
|
11904
|
-
|
|
11905
|
-
|
|
11906
|
-
|
|
11907
|
-
|
|
11908
|
-
|
|
11909
|
-
|
|
11910
|
-
|
|
11911
|
-
|
|
11912
|
-
|
|
11913
|
-
|
|
11914
|
-
|
|
11915
|
-
|
|
11916
|
-
|
|
11917
|
-
|
|
11918
|
-
|
|
11919
|
-
|
|
11920
|
-
|
|
11921
|
-
|
|
11922
|
-
|
|
11923
|
-
|
|
11924
|
-
|
|
11925
|
-
|
|
11926
|
-
|
|
11927
|
-
|
|
11928
|
-
|
|
11929
|
-
|
|
11930
|
-
|
|
11931
|
-
|
|
11932
|
-
|
|
11933
|
-
|
|
11934
|
-
|
|
11935
|
-
|
|
11936
|
-
|
|
11937
|
-
|
|
11938
|
-
|
|
11939
|
-
|
|
11940
|
-
|
|
11941
|
-
|
|
11942
|
-
|
|
11943
|
-
|
|
11944
|
-
|
|
11945
|
-
|
|
11946
|
-
|
|
11947
|
-
|
|
11948
|
-
|
|
11949
|
-
|
|
11950
|
-
multiple: false,
|
|
11951
|
-
defaultValue: [],
|
|
11952
|
-
activeIcon: React__default.createElement(CheckOutline, null)
|
|
11953
|
-
};
|
|
11954
|
-
const CheckList$1 = (props) => {
|
|
11955
|
-
const {
|
|
11956
|
-
checkList: componentConfig = {}
|
|
11957
|
-
} = useConfig();
|
|
11958
|
-
const mergedProps = mergeProps(defaultProps$8, componentConfig, props);
|
|
11959
|
-
const [value, setValue] = usePropsValue(mergedProps);
|
|
11960
|
-
function check(val) {
|
|
11961
|
-
if (mergedProps.multiple) {
|
|
11962
|
-
setValue([...value, val]);
|
|
12097
|
+
const [{
|
|
12098
|
+
scrollLeft
|
|
12099
|
+
}, scrollApi] = useSpring(() => ({
|
|
12100
|
+
scrollLeft: 0,
|
|
12101
|
+
config: {
|
|
12102
|
+
tension: 300,
|
|
12103
|
+
clamp: true
|
|
12104
|
+
}
|
|
12105
|
+
}));
|
|
12106
|
+
const [{
|
|
12107
|
+
leftMaskOpacity,
|
|
12108
|
+
rightMaskOpacity
|
|
12109
|
+
}, maskApi] = useSpring(() => ({
|
|
12110
|
+
leftMaskOpacity: 0,
|
|
12111
|
+
rightMaskOpacity: 0,
|
|
12112
|
+
config: {
|
|
12113
|
+
clamp: true
|
|
12114
|
+
}
|
|
12115
|
+
}));
|
|
12116
|
+
function animate(immediate = false, fromMutation = false) {
|
|
12117
|
+
const container = tabListContainerRef.current;
|
|
12118
|
+
if (!container)
|
|
12119
|
+
return;
|
|
12120
|
+
const activeIndex = keyToIndexRecord[activeKey];
|
|
12121
|
+
if (activeIndex === void 0) {
|
|
12122
|
+
inkApi.start({
|
|
12123
|
+
x: 0,
|
|
12124
|
+
width: 0,
|
|
12125
|
+
immediate: true
|
|
12126
|
+
});
|
|
12127
|
+
return;
|
|
12128
|
+
}
|
|
12129
|
+
const activeLine = activeLineRef.current;
|
|
12130
|
+
if (!activeLine)
|
|
12131
|
+
return;
|
|
12132
|
+
const activeTabWrapper = container.children.item(activeIndex + 1);
|
|
12133
|
+
const activeTab = activeTabWrapper.children.item(0);
|
|
12134
|
+
const activeTabLeft = activeTab.offsetLeft;
|
|
12135
|
+
const activeTabWidth = activeTab.offsetWidth;
|
|
12136
|
+
const activeTabWrapperLeft = activeTabWrapper.offsetLeft;
|
|
12137
|
+
const activeTabWrapperWidth = activeTabWrapper.offsetWidth;
|
|
12138
|
+
const containerWidth = container.offsetWidth;
|
|
12139
|
+
const containerScrollWidth = container.scrollWidth;
|
|
12140
|
+
const containerScrollLeft = container.scrollLeft;
|
|
12141
|
+
const activeLineWidth = activeLine.offsetWidth;
|
|
12142
|
+
let x2 = 0;
|
|
12143
|
+
let width2 = 0;
|
|
12144
|
+
if (props.activeLineMode === "auto") {
|
|
12145
|
+
x2 = activeTabLeft;
|
|
12146
|
+
width2 = activeTabWidth;
|
|
12147
|
+
} else if (props.activeLineMode === "full") {
|
|
12148
|
+
x2 = activeTabWrapperLeft;
|
|
12149
|
+
width2 = activeTabWrapperWidth;
|
|
11963
12150
|
} else {
|
|
11964
|
-
|
|
12151
|
+
x2 = activeTabLeft + (activeTabWidth - activeLineWidth) / 2;
|
|
11965
12152
|
}
|
|
11966
|
-
|
|
12153
|
+
if (isRTL) {
|
|
12154
|
+
const w = ["auto", "full"].includes(props.activeLineMode) ? width2 : activeLineWidth;
|
|
12155
|
+
x2 = -(containerWidth - x2 - w);
|
|
12156
|
+
}
|
|
12157
|
+
inkApi.start({
|
|
12158
|
+
x: x2,
|
|
12159
|
+
width: width2,
|
|
12160
|
+
immediate
|
|
12161
|
+
});
|
|
12162
|
+
const maxScrollDistance = containerScrollWidth - containerWidth;
|
|
12163
|
+
if (maxScrollDistance <= 0)
|
|
12164
|
+
return;
|
|
12165
|
+
let nextScrollLeft = 0;
|
|
12166
|
+
if (isRTL) {
|
|
12167
|
+
nextScrollLeft = -bound(containerWidth / 2 - activeTabLeft + activeTabWidth / 2 - activeLineWidth, 0, maxScrollDistance);
|
|
12168
|
+
} else {
|
|
12169
|
+
nextScrollLeft = bound(activeTabLeft - (containerWidth - activeTabWidth) / 2, 0, maxScrollDistance);
|
|
12170
|
+
}
|
|
12171
|
+
if (!fromMutation || props.autoScroll !== false) {
|
|
12172
|
+
scrollApi.start({
|
|
12173
|
+
scrollLeft: nextScrollLeft,
|
|
12174
|
+
from: {
|
|
12175
|
+
scrollLeft: containerScrollLeft
|
|
12176
|
+
},
|
|
12177
|
+
immediate
|
|
12178
|
+
});
|
|
12179
|
+
}
|
|
12180
|
+
}
|
|
12181
|
+
useIsomorphicLayoutEffect$2(() => {
|
|
12182
|
+
animate(!x.isAnimating);
|
|
12183
|
+
}, []);
|
|
12184
|
+
useIsomorphicUpdateLayoutEffect(() => {
|
|
12185
|
+
animate();
|
|
12186
|
+
}, [activeKey, isRTL, props.activeLineMode]);
|
|
12187
|
+
useResizeEffect(() => {
|
|
12188
|
+
animate(!x.isAnimating);
|
|
12189
|
+
}, tabListContainerRef);
|
|
12190
|
+
useMutationEffect(() => {
|
|
12191
|
+
animate(!x.isAnimating, true);
|
|
12192
|
+
}, tabListContainerRef, {
|
|
12193
|
+
subtree: true,
|
|
12194
|
+
childList: true,
|
|
12195
|
+
characterData: true
|
|
12196
|
+
});
|
|
12197
|
+
const {
|
|
12198
|
+
run: updateMask
|
|
12199
|
+
} = useThrottleFn((immediate = false) => {
|
|
12200
|
+
const container = tabListContainerRef.current;
|
|
12201
|
+
if (!container)
|
|
12202
|
+
return;
|
|
12203
|
+
const scrollLeft2 = container.scrollLeft;
|
|
12204
|
+
let showLeftMask = false;
|
|
12205
|
+
let showRightMask = false;
|
|
12206
|
+
if (isRTL) {
|
|
12207
|
+
showLeftMask = Math.round(-scrollLeft2) + container.offsetWidth < container.scrollWidth;
|
|
12208
|
+
showRightMask = scrollLeft2 < 0;
|
|
12209
|
+
} else {
|
|
12210
|
+
showLeftMask = scrollLeft2 > 0;
|
|
12211
|
+
showRightMask = scrollLeft2 + container.offsetWidth < container.scrollWidth;
|
|
12212
|
+
}
|
|
12213
|
+
maskApi.start({
|
|
12214
|
+
leftMaskOpacity: showLeftMask ? 1 : 0,
|
|
12215
|
+
rightMaskOpacity: showRightMask ? 1 : 0,
|
|
12216
|
+
immediate
|
|
12217
|
+
});
|
|
12218
|
+
}, {
|
|
12219
|
+
wait: 100,
|
|
12220
|
+
trailing: true,
|
|
12221
|
+
leading: true
|
|
12222
|
+
});
|
|
12223
|
+
useIsomorphicLayoutEffect$2(() => {
|
|
12224
|
+
updateMask(true);
|
|
12225
|
+
}, []);
|
|
12226
|
+
return withNativeProps(props, React__default.createElement("div", {
|
|
12227
|
+
className: classPrefix$b,
|
|
12228
|
+
style: {
|
|
12229
|
+
direction: props.direction
|
|
12230
|
+
}
|
|
12231
|
+
}, React__default.createElement("div", {
|
|
12232
|
+
className: `${classPrefix$b}-header`
|
|
12233
|
+
}, React__default.createElement(animated.div, {
|
|
12234
|
+
className: classNames(`${classPrefix$b}-header-mask`, `${classPrefix$b}-header-mask-left`),
|
|
12235
|
+
style: {
|
|
12236
|
+
opacity: leftMaskOpacity
|
|
12237
|
+
}
|
|
12238
|
+
}), React__default.createElement(animated.div, {
|
|
12239
|
+
className: classNames(`${classPrefix$b}-header-mask`, `${classPrefix$b}-header-mask-right`),
|
|
12240
|
+
style: {
|
|
12241
|
+
opacity: rightMaskOpacity
|
|
12242
|
+
}
|
|
12243
|
+
}), React__default.createElement(animated.div, {
|
|
12244
|
+
className: `${classPrefix$b}-tab-list`,
|
|
12245
|
+
ref: tabListContainerRef,
|
|
12246
|
+
scrollLeft,
|
|
12247
|
+
onScroll: updateMask,
|
|
12248
|
+
role: "tablist"
|
|
12249
|
+
}, React__default.createElement(animated.div, {
|
|
12250
|
+
ref: activeLineRef,
|
|
12251
|
+
className: `${classPrefix$b}-tab-line`,
|
|
12252
|
+
style: {
|
|
12253
|
+
width: props.activeLineMode === "fixed" ? "var(--fixed-active-line-width, 30px)" : width,
|
|
12254
|
+
x
|
|
12255
|
+
}
|
|
12256
|
+
}), panes.map((pane) => withNativeProps(pane.props, React__default.createElement("div", {
|
|
12257
|
+
key: pane.key,
|
|
12258
|
+
className: classNames(`${classPrefix$b}-tab-wrapper`, {
|
|
12259
|
+
[`${classPrefix$b}-tab-wrapper-stretch`]: props.stretch
|
|
12260
|
+
})
|
|
12261
|
+
}, React__default.createElement("div", {
|
|
12262
|
+
onClick: () => {
|
|
12263
|
+
const {
|
|
12264
|
+
key
|
|
12265
|
+
} = pane;
|
|
12266
|
+
if (pane.props.disabled)
|
|
12267
|
+
return;
|
|
12268
|
+
if (key === void 0 || key === null) {
|
|
12269
|
+
return;
|
|
12270
|
+
}
|
|
12271
|
+
setActiveKey(key.toString());
|
|
12272
|
+
},
|
|
12273
|
+
className: classNames(`${classPrefix$b}-tab`, {
|
|
12274
|
+
[`${classPrefix$b}-tab-active`]: pane.key === activeKey,
|
|
12275
|
+
[`${classPrefix$b}-tab-disabled`]: pane.props.disabled
|
|
12276
|
+
}),
|
|
12277
|
+
role: "tab",
|
|
12278
|
+
"aria-selected": pane.key === activeKey
|
|
12279
|
+
}, pane.props.title)))))), panes.map((pane) => {
|
|
12280
|
+
if (pane.props.children === void 0) {
|
|
12281
|
+
return null;
|
|
12282
|
+
}
|
|
12283
|
+
const active = pane.key === activeKey;
|
|
12284
|
+
return React__default.createElement(ShouldRender, {
|
|
12285
|
+
key: pane.key,
|
|
12286
|
+
active,
|
|
12287
|
+
forceRender: pane.props.forceRender,
|
|
12288
|
+
destroyOnClose: pane.props.destroyOnClose
|
|
12289
|
+
}, React__default.createElement("div", {
|
|
12290
|
+
className: `${classPrefix$b}-content`,
|
|
12291
|
+
style: {
|
|
12292
|
+
display: active ? "block" : "none"
|
|
12293
|
+
}
|
|
12294
|
+
}, pane.props.children));
|
|
12295
|
+
})));
|
|
12296
|
+
};
|
|
12297
|
+
var Tabs = attachPropertiesToComponent(Tabs$1, {
|
|
12298
|
+
Tab
|
|
12299
|
+
});
|
|
12300
|
+
var checkList = "";
|
|
12301
|
+
var list = "";
|
|
12302
|
+
const classPrefix$a = `adm-list`;
|
|
12303
|
+
const defaultProps$b = {
|
|
12304
|
+
mode: "default"
|
|
12305
|
+
};
|
|
12306
|
+
const List$1 = forwardRef((p2, ref) => {
|
|
12307
|
+
const props = mergeProps(defaultProps$b, p2);
|
|
12308
|
+
const nativeElementRef = useRef(null);
|
|
12309
|
+
useImperativeHandle(ref, () => ({
|
|
12310
|
+
get nativeElement() {
|
|
12311
|
+
return nativeElementRef.current;
|
|
12312
|
+
}
|
|
12313
|
+
}));
|
|
12314
|
+
return withNativeProps(props, React__default.createElement("div", {
|
|
12315
|
+
className: classNames(classPrefix$a, `${classPrefix$a}-${props.mode}`),
|
|
12316
|
+
ref: nativeElementRef
|
|
12317
|
+
}, props.header && React__default.createElement("div", {
|
|
12318
|
+
className: `${classPrefix$a}-header`
|
|
12319
|
+
}, props.header), React__default.createElement("div", {
|
|
12320
|
+
className: `${classPrefix$a}-body`
|
|
12321
|
+
}, React__default.createElement("div", {
|
|
12322
|
+
className: `${classPrefix$a}-body-inner`
|
|
12323
|
+
}, props.children))));
|
|
12324
|
+
});
|
|
12325
|
+
function isNodeWithContent(node) {
|
|
12326
|
+
return node !== void 0 && node !== null && node !== false;
|
|
12327
|
+
}
|
|
12328
|
+
const classPrefix$9 = `adm-list-item`;
|
|
12329
|
+
const ListItem$1 = (props) => {
|
|
12330
|
+
var _a, _b;
|
|
12331
|
+
const {
|
|
12332
|
+
arrow,
|
|
12333
|
+
arrowIcon
|
|
12334
|
+
} = props;
|
|
12335
|
+
const {
|
|
12336
|
+
list: componentConfig = {}
|
|
12337
|
+
} = useConfig();
|
|
12338
|
+
const clickable = (_a = props.clickable) !== null && _a !== void 0 ? _a : !!props.onClick;
|
|
12339
|
+
const showArrow = (_b = arrow !== null && arrow !== void 0 ? arrow : arrowIcon) !== null && _b !== void 0 ? _b : clickable;
|
|
12340
|
+
const mergedArrowIcon = mergeProp(componentConfig.arrowIcon, arrow !== true ? arrow : null, arrowIcon !== true ? arrowIcon : null);
|
|
12341
|
+
const content = React__default.createElement("div", {
|
|
12342
|
+
className: `${classPrefix$9}-content`
|
|
12343
|
+
}, isNodeWithContent(props.prefix) && React__default.createElement("div", {
|
|
12344
|
+
className: `${classPrefix$9}-content-prefix`
|
|
12345
|
+
}, props.prefix), React__default.createElement("div", {
|
|
12346
|
+
className: `${classPrefix$9}-content-main`
|
|
12347
|
+
}, isNodeWithContent(props.title) && React__default.createElement("div", {
|
|
12348
|
+
className: `${classPrefix$9}-title`
|
|
12349
|
+
}, props.title), props.children, isNodeWithContent(props.description) && React__default.createElement("div", {
|
|
12350
|
+
className: `${classPrefix$9}-description`
|
|
12351
|
+
}, props.description)), isNodeWithContent(props.extra) && React__default.createElement("div", {
|
|
12352
|
+
className: `${classPrefix$9}-content-extra`
|
|
12353
|
+
}, props.extra), showArrow && React__default.createElement("div", {
|
|
12354
|
+
className: `${classPrefix$9}-content-arrow`
|
|
12355
|
+
}, mergedArrowIcon || React__default.createElement(RightOutline, null)));
|
|
12356
|
+
return withNativeProps(props, React__default.createElement(clickable ? "a" : "div", {
|
|
12357
|
+
className: classNames(`${classPrefix$9}`, clickable ? ["adm-plain-anchor"] : [], props.disabled && `${classPrefix$9}-disabled`),
|
|
12358
|
+
onClick: props.disabled ? void 0 : props.onClick
|
|
12359
|
+
}, content));
|
|
12360
|
+
};
|
|
12361
|
+
var List = attachPropertiesToComponent(List$1, {
|
|
12362
|
+
Item: ListItem$1
|
|
12363
|
+
});
|
|
12364
|
+
const CheckListContext = createContext(null);
|
|
12365
|
+
const classPrefix$8 = "adm-check-list";
|
|
12366
|
+
const defaultProps$a = {
|
|
12367
|
+
multiple: false,
|
|
12368
|
+
defaultValue: [],
|
|
12369
|
+
activeIcon: React__default.createElement(CheckOutline, null)
|
|
12370
|
+
};
|
|
12371
|
+
const CheckList$1 = (props) => {
|
|
12372
|
+
const {
|
|
12373
|
+
checkList: componentConfig = {}
|
|
12374
|
+
} = useConfig();
|
|
12375
|
+
const mergedProps = mergeProps(defaultProps$a, componentConfig, props);
|
|
12376
|
+
const [value, setValue] = usePropsValue(mergedProps);
|
|
12377
|
+
function check(val) {
|
|
12378
|
+
if (mergedProps.multiple) {
|
|
12379
|
+
setValue([...value, val]);
|
|
12380
|
+
} else {
|
|
12381
|
+
setValue([val]);
|
|
12382
|
+
}
|
|
12383
|
+
}
|
|
11967
12384
|
function uncheck(val) {
|
|
11968
12385
|
setValue(value.filter((item) => item !== val));
|
|
11969
12386
|
}
|
|
@@ -11985,10 +12402,10 @@ const CheckList$1 = (props) => {
|
|
|
11985
12402
|
}
|
|
11986
12403
|
}, withNativeProps(mergedProps, React__default.createElement(List, {
|
|
11987
12404
|
mode: mergedProps.mode,
|
|
11988
|
-
className: classPrefix$
|
|
12405
|
+
className: classPrefix$8
|
|
11989
12406
|
}, mergedProps.children)));
|
|
11990
12407
|
};
|
|
11991
|
-
const classPrefix$
|
|
12408
|
+
const classPrefix$7 = `adm-check-list-item`;
|
|
11992
12409
|
const CheckListItem = (props) => {
|
|
11993
12410
|
const context = useContext(CheckListContext);
|
|
11994
12411
|
if (context === null) {
|
|
@@ -12000,11 +12417,11 @@ const CheckListItem = (props) => {
|
|
|
12000
12417
|
const defaultExtra = active ? context.activeIcon : null;
|
|
12001
12418
|
const renderExtra = context.extra ? context.extra(active) : defaultExtra;
|
|
12002
12419
|
const extra = React__default.createElement("div", {
|
|
12003
|
-
className: `${classPrefix$
|
|
12420
|
+
className: `${classPrefix$7}-extra`
|
|
12004
12421
|
}, renderExtra);
|
|
12005
12422
|
return withNativeProps(props, React__default.createElement(List.Item, {
|
|
12006
12423
|
title: props.title,
|
|
12007
|
-
className: classNames(classPrefix$
|
|
12424
|
+
className: classNames(classPrefix$7, readOnly && `${classPrefix$7}-readonly`, active && `${classPrefix$7}-active`),
|
|
12008
12425
|
description: props.description,
|
|
12009
12426
|
prefix: props.prefix,
|
|
12010
12427
|
onClick: (e2) => {
|
|
@@ -12028,15 +12445,15 @@ var CheckList = attachPropertiesToComponent(CheckList$1, {
|
|
|
12028
12445
|
Item: CheckListItem
|
|
12029
12446
|
});
|
|
12030
12447
|
var centerPopup = "";
|
|
12031
|
-
const classPrefix$
|
|
12032
|
-
const defaultProps$
|
|
12448
|
+
const classPrefix$6 = "adm-center-popup";
|
|
12449
|
+
const defaultProps$9 = Object.assign(Object.assign({}, defaultPopupBaseProps), {
|
|
12033
12450
|
getContainer: null
|
|
12034
12451
|
});
|
|
12035
12452
|
const CenterPopup$1 = (props) => {
|
|
12036
12453
|
const {
|
|
12037
12454
|
popup: componentConfig = {}
|
|
12038
12455
|
} = useConfig();
|
|
12039
|
-
const mergedProps = mergeProps(defaultProps$
|
|
12456
|
+
const mergedProps = mergeProps(defaultProps$9, componentConfig, props);
|
|
12040
12457
|
const unmountedRef = useUnmountedRef$1();
|
|
12041
12458
|
const style = useSpring({
|
|
12042
12459
|
scale: mergedProps.visible ? 1 : 0.8,
|
|
@@ -12069,11 +12486,11 @@ const CenterPopup$1 = (props) => {
|
|
|
12069
12486
|
useLockScroll(ref, mergedProps.disableBodyScroll && active);
|
|
12070
12487
|
const maskVisible = useInnerVisible(active && mergedProps.visible);
|
|
12071
12488
|
const body = React__default.createElement("div", {
|
|
12072
|
-
className: classNames(`${classPrefix$
|
|
12489
|
+
className: classNames(`${classPrefix$6}-body`, mergedProps.bodyClassName),
|
|
12073
12490
|
style: mergedProps.bodyStyle
|
|
12074
12491
|
}, mergedProps.children);
|
|
12075
12492
|
const node = withStopPropagation(mergedProps.stopPropagation, withNativeProps(mergedProps, React__default.createElement("div", {
|
|
12076
|
-
className: classPrefix$
|
|
12493
|
+
className: classPrefix$6,
|
|
12077
12494
|
style: {
|
|
12078
12495
|
display: active ? void 0 : "none",
|
|
12079
12496
|
pointerEvents: active ? void 0 : "none"
|
|
@@ -12090,11 +12507,11 @@ const CenterPopup$1 = (props) => {
|
|
|
12090
12507
|
}
|
|
12091
12508
|
},
|
|
12092
12509
|
style: mergedProps.maskStyle,
|
|
12093
|
-
className: classNames(`${classPrefix$
|
|
12510
|
+
className: classNames(`${classPrefix$6}-mask`, mergedProps.maskClassName),
|
|
12094
12511
|
disableBodyScroll: false,
|
|
12095
12512
|
stopPropagation: mergedProps.stopPropagation
|
|
12096
12513
|
}), React__default.createElement("div", {
|
|
12097
|
-
className: `${classPrefix$
|
|
12514
|
+
className: `${classPrefix$6}-wrap`,
|
|
12098
12515
|
role: mergedProps.role,
|
|
12099
12516
|
"aria-label": mergedProps["aria-label"]
|
|
12100
12517
|
}, React__default.createElement(animated.div, {
|
|
@@ -12103,7 +12520,7 @@ const CenterPopup$1 = (props) => {
|
|
|
12103
12520
|
}),
|
|
12104
12521
|
ref
|
|
12105
12522
|
}, mergedProps.showCloseButton && React__default.createElement("a", {
|
|
12106
|
-
className: classNames(`${classPrefix$
|
|
12523
|
+
className: classNames(`${classPrefix$6}-close`, "adm-plain-anchor"),
|
|
12107
12524
|
onClick: () => {
|
|
12108
12525
|
var _a;
|
|
12109
12526
|
(_a = mergedProps.onClose) === null || _a === void 0 ? void 0 : _a.call(mergedProps);
|
|
@@ -12116,6 +12533,45 @@ const CenterPopup$1 = (props) => {
|
|
|
12116
12533
|
}, renderToContainer(mergedProps.getContainer, node));
|
|
12117
12534
|
};
|
|
12118
12535
|
var CenterPopup = CenterPopup$1;
|
|
12536
|
+
const CheckIcon = memo((props) => {
|
|
12537
|
+
return withNativeProps(props, React__default.createElement("svg", {
|
|
12538
|
+
viewBox: "0 0 40 40"
|
|
12539
|
+
}, React__default.createElement("path", {
|
|
12540
|
+
d: "M31.5541766,15 L28.0892433,15 L28.0892434,15 C27.971052,15 27.8576674,15.044522 27.7740471,15.1239792 L18.2724722,24.1625319 L13.2248725,19.3630279 L13.2248725,19.3630279 C13.1417074,19.2834412 13.0287551,19.2384807 12.9107898,19.2380079 L9.44474455,19.2380079 L9.44474454,19.2380079 C9.19869815,19.2384085 8.99957935,19.4284738 9,19.66253 C9,19.7747587 9.04719253,19.8823283 9.13066188,19.9616418 L17.0907466,27.5338228 C17.4170809,27.8442545 17.8447695,28 18.2713393,28 L18.2980697,28 C18.7168464,27.993643 19.133396,27.8378975 19.4530492,27.5338228 L31.8693384,15.7236361 L31.8693384,15.7236361 C32.0434167,15.5582251 32.0435739,15.2898919 31.8696892,15.1242941 C31.7860402,15.0446329 31.6725052,15 31.5541421,15 L31.5541766,15 Z",
|
|
12541
|
+
fill: "currentColor"
|
|
12542
|
+
})));
|
|
12543
|
+
});
|
|
12544
|
+
const NativeInput = (props) => {
|
|
12545
|
+
const inputRef = useRef(null);
|
|
12546
|
+
const handleClick = useMemoizedFn((e2) => {
|
|
12547
|
+
e2.stopPropagation();
|
|
12548
|
+
e2.stopImmediatePropagation();
|
|
12549
|
+
const latestChecked = e2.target.checked;
|
|
12550
|
+
if (latestChecked === props.checked)
|
|
12551
|
+
return;
|
|
12552
|
+
props.onChange(latestChecked);
|
|
12553
|
+
});
|
|
12554
|
+
useEffect(() => {
|
|
12555
|
+
if (props.disabled)
|
|
12556
|
+
return;
|
|
12557
|
+
if (!inputRef.current)
|
|
12558
|
+
return;
|
|
12559
|
+
const input2 = inputRef.current;
|
|
12560
|
+
input2.addEventListener("click", handleClick);
|
|
12561
|
+
return () => {
|
|
12562
|
+
input2.removeEventListener("click", handleClick);
|
|
12563
|
+
};
|
|
12564
|
+
}, [props.disabled, props.onChange]);
|
|
12565
|
+
return React__default.createElement("input", {
|
|
12566
|
+
ref: inputRef,
|
|
12567
|
+
type: props.type,
|
|
12568
|
+
checked: props.checked,
|
|
12569
|
+
onChange: () => {
|
|
12570
|
+
},
|
|
12571
|
+
disabled: props.disabled,
|
|
12572
|
+
id: props.id
|
|
12573
|
+
});
|
|
12574
|
+
};
|
|
12119
12575
|
var datePicker = "";
|
|
12120
12576
|
var isoWeeksInYear$1 = { exports: {} };
|
|
12121
12577
|
(function(module, exports) {
|
|
@@ -12145,10 +12601,10 @@ var isLeapYear$1 = { exports: {} };
|
|
|
12145
12601
|
})(isLeapYear$1);
|
|
12146
12602
|
var isLeapYear = isLeapYear$1.exports;
|
|
12147
12603
|
const TILL_NOW = "TILL_NOW";
|
|
12148
|
-
dayjs
|
|
12149
|
-
dayjs
|
|
12150
|
-
dayjs
|
|
12151
|
-
const precisionRankRecord$
|
|
12604
|
+
dayjs.extend(isoWeek);
|
|
12605
|
+
dayjs.extend(isoWeeksInYear);
|
|
12606
|
+
dayjs.extend(isLeapYear);
|
|
12607
|
+
const precisionRankRecord$2 = {
|
|
12152
12608
|
year: 0,
|
|
12153
12609
|
month: 1,
|
|
12154
12610
|
day: 2,
|
|
@@ -12156,7 +12612,7 @@ const precisionRankRecord$1 = {
|
|
|
12156
12612
|
minute: 4,
|
|
12157
12613
|
second: 5
|
|
12158
12614
|
};
|
|
12159
|
-
function generateDatePickerColumns$
|
|
12615
|
+
function generateDatePickerColumns$3(selected, min, max, precision, renderLabel, filter, tillNow) {
|
|
12160
12616
|
const ret = [];
|
|
12161
12617
|
const minYear = min.getFullYear();
|
|
12162
12618
|
const minMonth = min.getMonth() + 1;
|
|
@@ -12170,9 +12626,9 @@ function generateDatePickerColumns$2(selected, min, max, precision, renderLabel,
|
|
|
12170
12626
|
const maxHour = max.getHours();
|
|
12171
12627
|
const maxMinute = max.getMinutes();
|
|
12172
12628
|
const maxSecond = max.getSeconds();
|
|
12173
|
-
const rank = precisionRankRecord$
|
|
12629
|
+
const rank = precisionRankRecord$2[precision];
|
|
12174
12630
|
const selectedYear = parseInt(selected[0]);
|
|
12175
|
-
const firstDayInSelectedMonth = dayjs
|
|
12631
|
+
const firstDayInSelectedMonth = dayjs(convertStringArrayToDate$3([selected[0], selected[1], "1"]));
|
|
12176
12632
|
const selectedMonth = parseInt(selected[1]);
|
|
12177
12633
|
const selectedDay = parseInt(selected[2]);
|
|
12178
12634
|
const selectedHour = parseInt(selected[3]);
|
|
@@ -12192,19 +12648,19 @@ function generateDatePickerColumns$2(selected, min, max, precision, renderLabel,
|
|
|
12192
12648
|
for (let i = from; i <= to2; i++) {
|
|
12193
12649
|
column.push(i);
|
|
12194
12650
|
}
|
|
12195
|
-
const prefix2 = selected.slice(0, precisionRankRecord$
|
|
12651
|
+
const prefix2 = selected.slice(0, precisionRankRecord$2[precision2]);
|
|
12196
12652
|
const currentFilter = filter === null || filter === void 0 ? void 0 : filter[precision2];
|
|
12197
12653
|
if (currentFilter && typeof currentFilter === "function") {
|
|
12198
12654
|
column = column.filter((i) => currentFilter(i, {
|
|
12199
12655
|
get date() {
|
|
12200
12656
|
const stringArray = [...prefix2, i.toString()];
|
|
12201
|
-
return convertStringArrayToDate$
|
|
12657
|
+
return convertStringArrayToDate$3(stringArray);
|
|
12202
12658
|
}
|
|
12203
12659
|
}));
|
|
12204
12660
|
}
|
|
12205
12661
|
return column;
|
|
12206
12662
|
};
|
|
12207
|
-
if (rank >= precisionRankRecord$
|
|
12663
|
+
if (rank >= precisionRankRecord$2.year) {
|
|
12208
12664
|
const lower = minYear;
|
|
12209
12665
|
const upper = maxYear;
|
|
12210
12666
|
const years = generateColumn(lower, upper, "year");
|
|
@@ -12213,7 +12669,7 @@ function generateDatePickerColumns$2(selected, min, max, precision, renderLabel,
|
|
|
12213
12669
|
value: v2.toString()
|
|
12214
12670
|
})));
|
|
12215
12671
|
}
|
|
12216
|
-
if (rank >= precisionRankRecord$
|
|
12672
|
+
if (rank >= precisionRankRecord$2.month) {
|
|
12217
12673
|
const lower = isInMinYear ? minMonth : 1;
|
|
12218
12674
|
const upper = isInMaxYear ? maxMonth : 12;
|
|
12219
12675
|
const months = generateColumn(lower, upper, "month");
|
|
@@ -12222,7 +12678,7 @@ function generateDatePickerColumns$2(selected, min, max, precision, renderLabel,
|
|
|
12222
12678
|
value: v2.toString()
|
|
12223
12679
|
})));
|
|
12224
12680
|
}
|
|
12225
|
-
if (rank >= precisionRankRecord$
|
|
12681
|
+
if (rank >= precisionRankRecord$2.day) {
|
|
12226
12682
|
const lower = isInMinMonth ? minDay : 1;
|
|
12227
12683
|
const upper = isInMaxMonth ? maxDay : firstDayInSelectedMonth.daysInMonth();
|
|
12228
12684
|
const days = generateColumn(lower, upper, "day");
|
|
@@ -12231,7 +12687,7 @@ function generateDatePickerColumns$2(selected, min, max, precision, renderLabel,
|
|
|
12231
12687
|
value: v2.toString()
|
|
12232
12688
|
})));
|
|
12233
12689
|
}
|
|
12234
|
-
if (rank >= precisionRankRecord$
|
|
12690
|
+
if (rank >= precisionRankRecord$2.hour) {
|
|
12235
12691
|
const lower = isInMinDay ? minHour : 0;
|
|
12236
12692
|
const upper = isInMaxDay ? maxHour : 23;
|
|
12237
12693
|
const hours = generateColumn(lower, upper, "hour");
|
|
@@ -12240,7 +12696,7 @@ function generateDatePickerColumns$2(selected, min, max, precision, renderLabel,
|
|
|
12240
12696
|
value: v2.toString()
|
|
12241
12697
|
})));
|
|
12242
12698
|
}
|
|
12243
|
-
if (rank >= precisionRankRecord$
|
|
12699
|
+
if (rank >= precisionRankRecord$2.minute) {
|
|
12244
12700
|
const lower = isInMinHour ? minMinute : 0;
|
|
12245
12701
|
const upper = isInMaxHour ? maxMinute : 59;
|
|
12246
12702
|
const minutes = generateColumn(lower, upper, "minute");
|
|
@@ -12249,7 +12705,7 @@ function generateDatePickerColumns$2(selected, min, max, precision, renderLabel,
|
|
|
12249
12705
|
value: v2.toString()
|
|
12250
12706
|
})));
|
|
12251
12707
|
}
|
|
12252
|
-
if (rank >= precisionRankRecord$
|
|
12708
|
+
if (rank >= precisionRankRecord$2.second) {
|
|
12253
12709
|
const lower = isInMinMinute ? minSecond : 0;
|
|
12254
12710
|
const upper = isInMaxMinute ? maxSecond : 59;
|
|
12255
12711
|
const seconds = generateColumn(lower, upper, "second");
|
|
@@ -12271,12 +12727,12 @@ function generateDatePickerColumns$2(selected, min, max, precision, renderLabel,
|
|
|
12271
12727
|
}
|
|
12272
12728
|
return ret;
|
|
12273
12729
|
}
|
|
12274
|
-
function convertDateToStringArray$
|
|
12730
|
+
function convertDateToStringArray$3(date) {
|
|
12275
12731
|
if (!date)
|
|
12276
12732
|
return [];
|
|
12277
12733
|
return [date.getFullYear().toString(), (date.getMonth() + 1).toString(), date.getDate().toString(), date.getHours().toString(), date.getMinutes().toString(), date.getSeconds().toString()];
|
|
12278
12734
|
}
|
|
12279
|
-
function convertStringArrayToDate$
|
|
12735
|
+
function convertStringArrayToDate$3(value) {
|
|
12280
12736
|
var _a, _b, _c, _d, _e, _f;
|
|
12281
12737
|
const yearString = (_a = value[0]) !== null && _a !== void 0 ? _a : "1900";
|
|
12282
12738
|
const monthString = (_b = value[1]) !== null && _b !== void 0 ? _b : "1";
|
|
@@ -12286,9 +12742,104 @@ function convertStringArrayToDate$2(value) {
|
|
|
12286
12742
|
const secondString = (_f = value[5]) !== null && _f !== void 0 ? _f : "0";
|
|
12287
12743
|
return new Date(parseInt(yearString), parseInt(monthString) - 1, parseInt(dateString), parseInt(hourString), parseInt(minuteString), parseInt(secondString));
|
|
12288
12744
|
}
|
|
12289
|
-
|
|
12290
|
-
|
|
12291
|
-
|
|
12745
|
+
var quarterOfYear$1 = { exports: {} };
|
|
12746
|
+
(function(module, exports) {
|
|
12747
|
+
!function(t2, n2) {
|
|
12748
|
+
module.exports = n2();
|
|
12749
|
+
}(commonjsGlobal, function() {
|
|
12750
|
+
var t2 = "month", n2 = "quarter";
|
|
12751
|
+
return function(e2, i) {
|
|
12752
|
+
var r2 = i.prototype;
|
|
12753
|
+
r2.quarter = function(t3) {
|
|
12754
|
+
return this.$utils().u(t3) ? Math.ceil((this.month() + 1) / 3) : this.month(this.month() % 3 + 3 * (t3 - 1));
|
|
12755
|
+
};
|
|
12756
|
+
var s = r2.add;
|
|
12757
|
+
r2.add = function(e3, i2) {
|
|
12758
|
+
return e3 = Number(e3), this.$utils().p(i2) === n2 ? this.add(3 * e3, t2) : s.bind(this)(e3, i2);
|
|
12759
|
+
};
|
|
12760
|
+
var u2 = r2.startOf;
|
|
12761
|
+
r2.startOf = function(e3, i2) {
|
|
12762
|
+
var r3 = this.$utils(), s2 = !!r3.u(i2) || i2;
|
|
12763
|
+
if (r3.p(e3) === n2) {
|
|
12764
|
+
var o = this.quarter() - 1;
|
|
12765
|
+
return s2 ? this.month(3 * o).startOf(t2).startOf("day") : this.month(3 * o + 2).endOf(t2).endOf("day");
|
|
12766
|
+
}
|
|
12767
|
+
return u2.bind(this)(e3, i2);
|
|
12768
|
+
};
|
|
12769
|
+
};
|
|
12770
|
+
});
|
|
12771
|
+
})(quarterOfYear$1);
|
|
12772
|
+
var quarterOfYear = quarterOfYear$1.exports;
|
|
12773
|
+
dayjs.extend(quarterOfYear);
|
|
12774
|
+
const precisionRankRecord$1 = {
|
|
12775
|
+
year: 0,
|
|
12776
|
+
quarter: 1
|
|
12777
|
+
};
|
|
12778
|
+
function generateDatePickerColumns$2(selected, min, max, precision, renderLabel, filter) {
|
|
12779
|
+
const ret = [];
|
|
12780
|
+
const minYear = min.getFullYear();
|
|
12781
|
+
const maxYear = max.getFullYear();
|
|
12782
|
+
const rank = precisionRankRecord$1[precision];
|
|
12783
|
+
const selectedYear = parseInt(selected[0]);
|
|
12784
|
+
const isInMinYear = selectedYear === minYear;
|
|
12785
|
+
const isInMaxYear = selectedYear === maxYear;
|
|
12786
|
+
const minDay = dayjs(min);
|
|
12787
|
+
const maxDay = dayjs(max);
|
|
12788
|
+
const minQuarter = minDay.quarter();
|
|
12789
|
+
const maxQuarter = maxDay.quarter();
|
|
12790
|
+
const generateColumn = (from, to2, precision2) => {
|
|
12791
|
+
let column = [];
|
|
12792
|
+
for (let i = from; i <= to2; i++) {
|
|
12793
|
+
column.push(i);
|
|
12794
|
+
}
|
|
12795
|
+
const prefix2 = selected.slice(0, precisionRankRecord$1[precision2]);
|
|
12796
|
+
const currentFilter = filter === null || filter === void 0 ? void 0 : filter[precision2];
|
|
12797
|
+
if (currentFilter && typeof currentFilter === "function") {
|
|
12798
|
+
column = column.filter((i) => currentFilter(i, {
|
|
12799
|
+
get date() {
|
|
12800
|
+
const stringArray = [...prefix2, i.toString()];
|
|
12801
|
+
return convertStringArrayToDate$2(stringArray);
|
|
12802
|
+
}
|
|
12803
|
+
}));
|
|
12804
|
+
}
|
|
12805
|
+
return column;
|
|
12806
|
+
};
|
|
12807
|
+
if (rank >= precisionRankRecord$1.year) {
|
|
12808
|
+
const lower = minYear;
|
|
12809
|
+
const upper = maxYear;
|
|
12810
|
+
const years = generateColumn(lower, upper, "year");
|
|
12811
|
+
ret.push(years.map((v2) => ({
|
|
12812
|
+
label: renderLabel("year", v2),
|
|
12813
|
+
value: v2.toString()
|
|
12814
|
+
})));
|
|
12815
|
+
}
|
|
12816
|
+
if (rank >= precisionRankRecord$1.quarter) {
|
|
12817
|
+
const lower = isInMinYear ? minQuarter : 1;
|
|
12818
|
+
const upper = isInMaxYear ? maxQuarter : 4;
|
|
12819
|
+
const quarters = generateColumn(lower, upper, "quarter");
|
|
12820
|
+
ret.push(quarters.map((v2) => ({
|
|
12821
|
+
label: renderLabel("quarter", v2),
|
|
12822
|
+
value: v2.toString()
|
|
12823
|
+
})));
|
|
12824
|
+
}
|
|
12825
|
+
return ret;
|
|
12826
|
+
}
|
|
12827
|
+
function convertDateToStringArray$2(date) {
|
|
12828
|
+
if (!date)
|
|
12829
|
+
return [];
|
|
12830
|
+
const day = dayjs(date);
|
|
12831
|
+
return [day.year().toString(), day.quarter().toString()];
|
|
12832
|
+
}
|
|
12833
|
+
function convertStringArrayToDate$2(value) {
|
|
12834
|
+
var _a, _b;
|
|
12835
|
+
const yearString = (_a = value[0]) !== null && _a !== void 0 ? _a : "1900";
|
|
12836
|
+
const quarterString = (_b = value[1]) !== null && _b !== void 0 ? _b : "1";
|
|
12837
|
+
const day = dayjs().year(parseInt(yearString)).quarter(parseInt(quarterString)).hour(0).minute(0).second(0);
|
|
12838
|
+
return day.toDate();
|
|
12839
|
+
}
|
|
12840
|
+
dayjs.extend(isoWeek);
|
|
12841
|
+
dayjs.extend(isoWeeksInYear);
|
|
12842
|
+
dayjs.extend(isLeapYear);
|
|
12292
12843
|
const precisionRankRecord = {
|
|
12293
12844
|
year: 0,
|
|
12294
12845
|
week: 1,
|
|
@@ -12302,8 +12853,8 @@ function generateDatePickerColumns$1(selected, min, max, precision, renderLabel,
|
|
|
12302
12853
|
const selectedYear = parseInt(selected[0]);
|
|
12303
12854
|
const isInMinYear = selectedYear === minYear;
|
|
12304
12855
|
const isInMaxYear = selectedYear === maxYear;
|
|
12305
|
-
const minDay = dayjs
|
|
12306
|
-
const maxDay = dayjs
|
|
12856
|
+
const minDay = dayjs(min);
|
|
12857
|
+
const maxDay = dayjs(max);
|
|
12307
12858
|
const minWeek = minDay.isoWeek();
|
|
12308
12859
|
const maxWeek = maxDay.isoWeek();
|
|
12309
12860
|
const minWeekday = minDay.isoWeekday();
|
|
@@ -12311,7 +12862,7 @@ function generateDatePickerColumns$1(selected, min, max, precision, renderLabel,
|
|
|
12311
12862
|
const selectedWeek = parseInt(selected[1]);
|
|
12312
12863
|
const isInMinWeek = isInMinYear && selectedWeek === minWeek;
|
|
12313
12864
|
const isInMaxWeek = isInMaxYear && selectedWeek === maxWeek;
|
|
12314
|
-
const selectedYearWeeks = dayjs
|
|
12865
|
+
const selectedYearWeeks = dayjs(`${selectedYear}-01-01`).isoWeeksInYear();
|
|
12315
12866
|
const generateColumn = (from, to2, precision2) => {
|
|
12316
12867
|
let column = [];
|
|
12317
12868
|
for (let i = from; i <= to2; i++) {
|
|
@@ -12361,7 +12912,7 @@ function generateDatePickerColumns$1(selected, min, max, precision, renderLabel,
|
|
|
12361
12912
|
function convertDateToStringArray$1(date) {
|
|
12362
12913
|
if (!date)
|
|
12363
12914
|
return [];
|
|
12364
|
-
const day = dayjs
|
|
12915
|
+
const day = dayjs(date);
|
|
12365
12916
|
return [day.isoWeekYear().toString(), day.isoWeek().toString(), day.isoWeekday().toString()];
|
|
12366
12917
|
}
|
|
12367
12918
|
function convertStringArrayToDate$1(value) {
|
|
@@ -12369,7 +12920,7 @@ function convertStringArrayToDate$1(value) {
|
|
|
12369
12920
|
const yearString = (_a = value[0]) !== null && _a !== void 0 ? _a : "1900";
|
|
12370
12921
|
const weekString = (_b = value[1]) !== null && _b !== void 0 ? _b : "1";
|
|
12371
12922
|
const weekdayString = (_c = value[2]) !== null && _c !== void 0 ? _c : "1";
|
|
12372
|
-
const day = dayjs
|
|
12923
|
+
const day = dayjs().year(parseInt(yearString)).isoWeek(parseInt(weekString)).isoWeekday(parseInt(weekdayString)).hour(0).minute(0).second(0);
|
|
12373
12924
|
return day.toDate();
|
|
12374
12925
|
}
|
|
12375
12926
|
const precisionLengthRecord = {
|
|
@@ -12383,9 +12934,11 @@ const precisionLengthRecord = {
|
|
|
12383
12934
|
const convertDateToStringArray = (date, precision) => {
|
|
12384
12935
|
if (precision.includes("week")) {
|
|
12385
12936
|
return convertDateToStringArray$1(date);
|
|
12937
|
+
} else if (precision.includes("quarter")) {
|
|
12938
|
+
return convertDateToStringArray$2(date);
|
|
12386
12939
|
} else {
|
|
12387
12940
|
const datePrecision = precision;
|
|
12388
|
-
const stringArray = convertDateToStringArray$
|
|
12941
|
+
const stringArray = convertDateToStringArray$3(date);
|
|
12389
12942
|
return stringArray.slice(0, precisionLengthRecord[datePrecision]);
|
|
12390
12943
|
}
|
|
12391
12944
|
};
|
|
@@ -12397,15 +12950,19 @@ const convertStringArrayToDate = (value, precision) => {
|
|
|
12397
12950
|
}
|
|
12398
12951
|
if (precision.includes("week")) {
|
|
12399
12952
|
return convertStringArrayToDate$1(value);
|
|
12400
|
-
} else {
|
|
12953
|
+
} else if (precision.includes("quarter")) {
|
|
12401
12954
|
return convertStringArrayToDate$2(value);
|
|
12955
|
+
} else {
|
|
12956
|
+
return convertStringArrayToDate$3(value);
|
|
12402
12957
|
}
|
|
12403
12958
|
};
|
|
12404
12959
|
const generateDatePickerColumns = (selected, min, max, precision, renderLabel, filter, tillNow) => {
|
|
12405
12960
|
if (precision.startsWith("week")) {
|
|
12406
12961
|
return generateDatePickerColumns$1(selected, min, max, precision, renderLabel, filter);
|
|
12962
|
+
} else if (precision.startsWith("quarter")) {
|
|
12963
|
+
return generateDatePickerColumns$2(selected, min, max, precision, renderLabel, filter);
|
|
12407
12964
|
} else {
|
|
12408
|
-
return generateDatePickerColumns$
|
|
12965
|
+
return generateDatePickerColumns$3(selected, min, max, precision, renderLabel, filter, tillNow);
|
|
12409
12966
|
}
|
|
12410
12967
|
};
|
|
12411
12968
|
function useRenderLabel(renderLabel) {
|
|
@@ -12429,14 +12986,14 @@ function useRenderLabel(renderLabel) {
|
|
|
12429
12986
|
}, [renderLabel]);
|
|
12430
12987
|
}
|
|
12431
12988
|
const thisYear = new Date().getFullYear();
|
|
12432
|
-
const defaultProps$
|
|
12989
|
+
const defaultProps$8 = {
|
|
12433
12990
|
min: new Date(new Date().setFullYear(thisYear - 10)),
|
|
12434
12991
|
max: new Date(new Date().setFullYear(thisYear + 10)),
|
|
12435
12992
|
precision: "day",
|
|
12436
12993
|
defaultValue: null
|
|
12437
12994
|
};
|
|
12438
12995
|
const DatePicker$1 = forwardRef((p2, ref) => {
|
|
12439
|
-
const props = mergeProps(defaultProps$
|
|
12996
|
+
const props = mergeProps(defaultProps$8, p2);
|
|
12440
12997
|
const {
|
|
12441
12998
|
renderLabel
|
|
12442
12999
|
} = props;
|
|
@@ -12551,14 +13108,14 @@ const DialogActionButton = (props) => {
|
|
|
12551
13108
|
disabled: action.disabled
|
|
12552
13109
|
}, action.text));
|
|
12553
13110
|
};
|
|
12554
|
-
const defaultProps$
|
|
13111
|
+
const defaultProps$7 = {
|
|
12555
13112
|
actions: [],
|
|
12556
13113
|
closeOnAction: false,
|
|
12557
13114
|
closeOnMaskClick: false,
|
|
12558
13115
|
getContainer: null
|
|
12559
13116
|
};
|
|
12560
13117
|
const Dialog$1 = (p2) => {
|
|
12561
|
-
const props = mergeProps(defaultProps$
|
|
13118
|
+
const props = mergeProps(defaultProps$7, p2);
|
|
12562
13119
|
const element = React__default.createElement(React__default.Fragment, null, !!props.image && React__default.createElement("div", {
|
|
12563
13120
|
className: cls("image-container")
|
|
12564
13121
|
}, React__default.createElement(Image, {
|
|
@@ -12649,7 +13206,7 @@ function alert(p2) {
|
|
|
12649
13206
|
}));
|
|
12650
13207
|
});
|
|
12651
13208
|
}
|
|
12652
|
-
const defaultProps$
|
|
13209
|
+
const defaultProps$6 = {
|
|
12653
13210
|
confirmText: "\u786E\u8BA4",
|
|
12654
13211
|
cancelText: "\u53D6\u6D88"
|
|
12655
13212
|
};
|
|
@@ -12657,7 +13214,7 @@ function confirm(p2) {
|
|
|
12657
13214
|
const {
|
|
12658
13215
|
locale
|
|
12659
13216
|
} = getDefaultConfig();
|
|
12660
|
-
const props = mergeProps(defaultProps$
|
|
13217
|
+
const props = mergeProps(defaultProps$6, {
|
|
12661
13218
|
confirmText: locale.common.confirm,
|
|
12662
13219
|
cancelText: locale.common.cancel
|
|
12663
13220
|
}, p2);
|
|
@@ -12740,8 +13297,8 @@ function useInputHandleKeyDown({
|
|
|
12740
13297
|
}, [enterKeyHint]);
|
|
12741
13298
|
return handleKeydown;
|
|
12742
13299
|
}
|
|
12743
|
-
const classPrefix$
|
|
12744
|
-
const defaultProps$
|
|
13300
|
+
const classPrefix$5 = `adm-input`;
|
|
13301
|
+
const defaultProps$5 = {
|
|
12745
13302
|
defaultValue: "",
|
|
12746
13303
|
clearIcon: React__default.createElement(CloseCircleFill, null),
|
|
12747
13304
|
onlyShowClearWhenFocus: true
|
|
@@ -12751,7 +13308,7 @@ const Input$1 = forwardRef((props, ref) => {
|
|
|
12751
13308
|
locale,
|
|
12752
13309
|
input: componentConfig = {}
|
|
12753
13310
|
} = useConfig();
|
|
12754
|
-
const mergedProps = mergeProps(defaultProps$
|
|
13311
|
+
const mergedProps = mergeProps(defaultProps$5, componentConfig, props);
|
|
12755
13312
|
const [value, setValue] = usePropsValue(mergedProps);
|
|
12756
13313
|
const [hasFocus, setHasFocus] = useState(false);
|
|
12757
13314
|
const compositionStartRef = useRef(false);
|
|
@@ -12800,10 +13357,10 @@ const Input$1 = forwardRef((props, ref) => {
|
|
|
12800
13357
|
}
|
|
12801
13358
|
})();
|
|
12802
13359
|
return withNativeProps(mergedProps, React__default.createElement("div", {
|
|
12803
|
-
className: classNames(`${classPrefix$
|
|
13360
|
+
className: classNames(`${classPrefix$5}`, mergedProps.disabled && `${classPrefix$5}-disabled`)
|
|
12804
13361
|
}, React__default.createElement("input", {
|
|
12805
13362
|
ref: nativeInputRef,
|
|
12806
|
-
className: `${classPrefix$
|
|
13363
|
+
className: `${classPrefix$5}-element`,
|
|
12807
13364
|
value,
|
|
12808
13365
|
onChange: (e2) => {
|
|
12809
13366
|
setValue(e2.target.value);
|
|
@@ -12819,6 +13376,7 @@ const Input$1 = forwardRef((props, ref) => {
|
|
|
12819
13376
|
checkValue();
|
|
12820
13377
|
(_a = mergedProps.onBlur) === null || _a === void 0 ? void 0 : _a.call(mergedProps, e2);
|
|
12821
13378
|
},
|
|
13379
|
+
onPaste: mergedProps.onPaste,
|
|
12822
13380
|
id: mergedProps.id,
|
|
12823
13381
|
placeholder: mergedProps.placeholder,
|
|
12824
13382
|
disabled: mergedProps.disabled,
|
|
@@ -12856,7 +13414,7 @@ const Input$1 = forwardRef((props, ref) => {
|
|
|
12856
13414
|
"aria-valuemin": mergedProps["aria-valuemin"],
|
|
12857
13415
|
"aria-label": mergedProps["aria-label"]
|
|
12858
13416
|
}), shouldShowClear && React__default.createElement("div", {
|
|
12859
|
-
className: `${classPrefix$
|
|
13417
|
+
className: `${classPrefix$5}-clear`,
|
|
12860
13418
|
onMouseDown: (e2) => {
|
|
12861
13419
|
e2.preventDefault();
|
|
12862
13420
|
},
|
|
@@ -12874,7 +13432,7 @@ const Input$1 = forwardRef((props, ref) => {
|
|
|
12874
13432
|
});
|
|
12875
13433
|
var Input = Input$1;
|
|
12876
13434
|
var navBar = "";
|
|
12877
|
-
const classPrefix$
|
|
13435
|
+
const classPrefix$4 = `adm-nav-bar`;
|
|
12878
13436
|
const defaultBackIcon = React__default.createElement(LeftOutline, null);
|
|
12879
13437
|
const NavBar$1 = (props) => {
|
|
12880
13438
|
const {
|
|
@@ -12889,33 +13447,33 @@ const NavBar$1 = (props) => {
|
|
|
12889
13447
|
const mergedDefaultBackIcon = componentConfig.backIcon || defaultBackIcon;
|
|
12890
13448
|
const mergedBackIcon = mergeProp(defaultBackIcon, componentConfig.backIcon, backArrow === true ? mergedDefaultBackIcon : backArrow, backIcon === true ? mergedDefaultBackIcon : backIcon);
|
|
12891
13449
|
return withNativeProps(mergedProps, React__default.createElement("div", {
|
|
12892
|
-
className: classNames(classPrefix$
|
|
13450
|
+
className: classNames(classPrefix$4)
|
|
12893
13451
|
}, React__default.createElement("div", {
|
|
12894
|
-
className: `${classPrefix$
|
|
13452
|
+
className: `${classPrefix$4}-left`,
|
|
12895
13453
|
role: "button"
|
|
12896
13454
|
}, back !== null && React__default.createElement("div", {
|
|
12897
|
-
className: `${classPrefix$
|
|
13455
|
+
className: `${classPrefix$4}-back`,
|
|
12898
13456
|
onClick: mergedProps.onBack
|
|
12899
13457
|
}, mergedBackIcon && React__default.createElement("span", {
|
|
12900
|
-
className: `${classPrefix$
|
|
13458
|
+
className: `${classPrefix$4}-back-arrow`
|
|
12901
13459
|
}, mergedBackIcon), React__default.createElement("span", {
|
|
12902
13460
|
"aria-hidden": "true"
|
|
12903
13461
|
}, back)), mergedProps.left), React__default.createElement("div", {
|
|
12904
|
-
className: `${classPrefix$
|
|
13462
|
+
className: `${classPrefix$4}-title`
|
|
12905
13463
|
}, mergedProps.children), React__default.createElement("div", {
|
|
12906
|
-
className: `${classPrefix$
|
|
13464
|
+
className: `${classPrefix$4}-right`
|
|
12907
13465
|
}, mergedProps.right)));
|
|
12908
13466
|
};
|
|
12909
13467
|
var NavBar = NavBar$1;
|
|
12910
13468
|
var progressBar = "";
|
|
12911
|
-
const classPrefix$
|
|
12912
|
-
const defaultProps$
|
|
13469
|
+
const classPrefix$3 = `adm-progress-bar`;
|
|
13470
|
+
const defaultProps$4 = {
|
|
12913
13471
|
percent: 0,
|
|
12914
13472
|
rounded: true,
|
|
12915
13473
|
text: false
|
|
12916
13474
|
};
|
|
12917
13475
|
const ProgressBar$1 = (p2) => {
|
|
12918
|
-
const props = mergeProps(defaultProps$
|
|
13476
|
+
const props = mergeProps(defaultProps$4, p2);
|
|
12919
13477
|
const fillStyle = {
|
|
12920
13478
|
width: `${props.percent}%`
|
|
12921
13479
|
};
|
|
@@ -12929,43 +13487,144 @@ const ProgressBar$1 = (p2) => {
|
|
|
12929
13487
|
return props.text;
|
|
12930
13488
|
}();
|
|
12931
13489
|
return withNativeProps(props, React__default.createElement("div", {
|
|
12932
|
-
className: classNames(classPrefix$
|
|
13490
|
+
className: classNames(classPrefix$3, props.rounded && `${classPrefix$3}-rounded`)
|
|
12933
13491
|
}, React__default.createElement("div", {
|
|
12934
|
-
className: `${classPrefix$
|
|
13492
|
+
className: `${classPrefix$3}-trail`
|
|
12935
13493
|
}, React__default.createElement("div", {
|
|
12936
|
-
className: `${classPrefix$
|
|
13494
|
+
className: `${classPrefix$3}-fill`,
|
|
12937
13495
|
style: fillStyle
|
|
12938
13496
|
})), isNodeWithContent(textElement) && React__default.createElement("div", {
|
|
12939
|
-
className: `${classPrefix$
|
|
13497
|
+
className: `${classPrefix$3}-text`
|
|
12940
13498
|
}, textElement)));
|
|
12941
13499
|
};
|
|
12942
13500
|
var ProgressBar = ProgressBar$1;
|
|
12943
|
-
var
|
|
12944
|
-
const
|
|
12945
|
-
const defaultProps$
|
|
12946
|
-
|
|
12947
|
-
|
|
12948
|
-
showCancelButton: false,
|
|
12949
|
-
defaultValue: "",
|
|
12950
|
-
clearOnCancel: true
|
|
13501
|
+
var radio = "";
|
|
13502
|
+
const RadioGroupContext = createContext(null);
|
|
13503
|
+
const defaultProps$3 = {
|
|
13504
|
+
disabled: false,
|
|
13505
|
+
defaultValue: null
|
|
12951
13506
|
};
|
|
12952
|
-
const
|
|
12953
|
-
const
|
|
12954
|
-
|
|
12955
|
-
|
|
12956
|
-
|
|
12957
|
-
|
|
12958
|
-
cancelText: locale.common.cancel
|
|
12959
|
-
}, props);
|
|
12960
|
-
const searchIcon = mergeProp(React__default.createElement(SearchOutline, null), componentConfig.searchIcon, props.icon, props.searchIcon);
|
|
12961
|
-
const [value, setValue] = usePropsValue(mergedProps);
|
|
12962
|
-
const [hasFocus, setHasFocus] = useState(false);
|
|
12963
|
-
const inputRef = useRef(null);
|
|
12964
|
-
const composingRef = useRef(false);
|
|
12965
|
-
useImperativeHandle(ref, () => ({
|
|
12966
|
-
clear: () => {
|
|
13507
|
+
const Group = (p2) => {
|
|
13508
|
+
const props = mergeProps(defaultProps$3, p2);
|
|
13509
|
+
const [value, setValue] = usePropsValue({
|
|
13510
|
+
value: props.value,
|
|
13511
|
+
defaultValue: props.defaultValue,
|
|
13512
|
+
onChange: (v2) => {
|
|
12967
13513
|
var _a;
|
|
12968
|
-
|
|
13514
|
+
if (v2 === null)
|
|
13515
|
+
return;
|
|
13516
|
+
(_a = props.onChange) === null || _a === void 0 ? void 0 : _a.call(props, v2);
|
|
13517
|
+
}
|
|
13518
|
+
});
|
|
13519
|
+
return React__default.createElement(
|
|
13520
|
+
RadioGroupContext.Provider,
|
|
13521
|
+
{
|
|
13522
|
+
value: {
|
|
13523
|
+
value: value === null ? [] : [value],
|
|
13524
|
+
check: (v2) => {
|
|
13525
|
+
setValue(v2);
|
|
13526
|
+
},
|
|
13527
|
+
uncheck: () => {
|
|
13528
|
+
},
|
|
13529
|
+
disabled: props.disabled
|
|
13530
|
+
}
|
|
13531
|
+
},
|
|
13532
|
+
props.children
|
|
13533
|
+
);
|
|
13534
|
+
};
|
|
13535
|
+
const classPrefix$2 = `adm-radio`;
|
|
13536
|
+
const defaultProps$2 = {
|
|
13537
|
+
defaultChecked: false
|
|
13538
|
+
};
|
|
13539
|
+
const Radio = (p2) => {
|
|
13540
|
+
const props = mergeProps(defaultProps$2, p2);
|
|
13541
|
+
const groupContext = useContext(RadioGroupContext);
|
|
13542
|
+
let [checked, setChecked] = usePropsValue({
|
|
13543
|
+
value: props.checked,
|
|
13544
|
+
defaultValue: props.defaultChecked,
|
|
13545
|
+
onChange: props.onChange
|
|
13546
|
+
});
|
|
13547
|
+
let disabled = props.disabled;
|
|
13548
|
+
const {
|
|
13549
|
+
value
|
|
13550
|
+
} = props;
|
|
13551
|
+
if (groupContext && value !== void 0) {
|
|
13552
|
+
if (isDev) {
|
|
13553
|
+
if (p2.checked !== void 0) {
|
|
13554
|
+
devWarning("Radio", "When used within `Radio.Group`, the `checked` prop of `Radio` will not work.");
|
|
13555
|
+
}
|
|
13556
|
+
if (p2.defaultChecked !== void 0) {
|
|
13557
|
+
devWarning("Radio", "When used within `Radio.Group`, the `defaultChecked` prop of `Radio` will not work.");
|
|
13558
|
+
}
|
|
13559
|
+
}
|
|
13560
|
+
checked = groupContext.value.includes(value);
|
|
13561
|
+
setChecked = (innerChecked) => {
|
|
13562
|
+
var _a;
|
|
13563
|
+
if (innerChecked) {
|
|
13564
|
+
groupContext.check(value);
|
|
13565
|
+
} else {
|
|
13566
|
+
groupContext.uncheck(value);
|
|
13567
|
+
}
|
|
13568
|
+
(_a = props.onChange) === null || _a === void 0 ? void 0 : _a.call(props, innerChecked);
|
|
13569
|
+
};
|
|
13570
|
+
disabled = disabled || groupContext.disabled;
|
|
13571
|
+
}
|
|
13572
|
+
const renderIcon = () => {
|
|
13573
|
+
if (props.icon) {
|
|
13574
|
+
return React__default.createElement("div", {
|
|
13575
|
+
className: `${classPrefix$2}-custom-icon`
|
|
13576
|
+
}, props.icon(checked));
|
|
13577
|
+
}
|
|
13578
|
+
return React__default.createElement("div", {
|
|
13579
|
+
className: `${classPrefix$2}-icon`
|
|
13580
|
+
}, checked && React__default.createElement(CheckIcon, null));
|
|
13581
|
+
};
|
|
13582
|
+
return withNativeProps(props, React__default.createElement("label", {
|
|
13583
|
+
onClick: props.onClick,
|
|
13584
|
+
className: classNames(classPrefix$2, {
|
|
13585
|
+
[`${classPrefix$2}-checked`]: checked,
|
|
13586
|
+
[`${classPrefix$2}-disabled`]: disabled,
|
|
13587
|
+
[`${classPrefix$2}-block`]: props.block
|
|
13588
|
+
})
|
|
13589
|
+
}, React__default.createElement(NativeInput, {
|
|
13590
|
+
type: "radio",
|
|
13591
|
+
checked,
|
|
13592
|
+
onChange: setChecked,
|
|
13593
|
+
disabled,
|
|
13594
|
+
id: props.id
|
|
13595
|
+
}), renderIcon(), props.children && React__default.createElement("div", {
|
|
13596
|
+
className: `${classPrefix$2}-content`
|
|
13597
|
+
}, props.children)));
|
|
13598
|
+
};
|
|
13599
|
+
var index$o = attachPropertiesToComponent(Radio, {
|
|
13600
|
+
Group
|
|
13601
|
+
});
|
|
13602
|
+
var searchBar = "";
|
|
13603
|
+
const classPrefix$1 = `adm-search-bar`;
|
|
13604
|
+
const defaultProps$1 = {
|
|
13605
|
+
clearable: true,
|
|
13606
|
+
onlyShowClearWhenFocus: false,
|
|
13607
|
+
showCancelButton: false,
|
|
13608
|
+
defaultValue: "",
|
|
13609
|
+
clearOnCancel: true
|
|
13610
|
+
};
|
|
13611
|
+
const SearchBar$1 = forwardRef((props, ref) => {
|
|
13612
|
+
const {
|
|
13613
|
+
locale,
|
|
13614
|
+
searchBar: componentConfig = {}
|
|
13615
|
+
} = useConfig();
|
|
13616
|
+
const mergedProps = mergeProps(defaultProps$1, componentConfig, {
|
|
13617
|
+
cancelText: locale.common.cancel
|
|
13618
|
+
}, props);
|
|
13619
|
+
const searchIcon = mergeProp(React__default.createElement(SearchOutline, null), componentConfig.searchIcon, props.icon, props.searchIcon);
|
|
13620
|
+
const [value, setValue] = usePropsValue(mergedProps);
|
|
13621
|
+
const [hasFocus, setHasFocus] = useState(false);
|
|
13622
|
+
const inputRef = useRef(null);
|
|
13623
|
+
const composingRef = useRef(false);
|
|
13624
|
+
useImperativeHandle(ref, () => ({
|
|
13625
|
+
clear: () => {
|
|
13626
|
+
var _a;
|
|
13627
|
+
return (_a = inputRef.current) === null || _a === void 0 ? void 0 : _a.clear();
|
|
12969
13628
|
},
|
|
12970
13629
|
focus: () => {
|
|
12971
13630
|
var _a;
|
|
@@ -13021,6 +13680,7 @@ const SearchBar$1 = forwardRef((props, ref) => {
|
|
|
13021
13680
|
value,
|
|
13022
13681
|
onChange: setValue,
|
|
13023
13682
|
maxLength: mergedProps.maxLength,
|
|
13683
|
+
autoFocus: mergedProps.autoFocus,
|
|
13024
13684
|
placeholder: mergedProps.placeholder,
|
|
13025
13685
|
clearable: mergedProps.clearable,
|
|
13026
13686
|
onlyShowClearWhenFocus: mergedProps.onlyShowClearWhenFocus,
|
|
@@ -13614,6 +14274,16 @@ function InnerStepper(p2, ref) {
|
|
|
13614
14274
|
}
|
|
13615
14275
|
const Stepper$1 = forwardRef(InnerStepper);
|
|
13616
14276
|
var Stepper = Stepper$1;
|
|
14277
|
+
function useFieldV2(defaultData, validate) {
|
|
14278
|
+
const [, forceUpdate] = React__default.useState({});
|
|
14279
|
+
const [filed] = React__default.useState(() => {
|
|
14280
|
+
return new Filed(defaultData, validate);
|
|
14281
|
+
});
|
|
14282
|
+
React__default.useEffect(() => {
|
|
14283
|
+
filed.on("$updated", () => forceUpdate({}));
|
|
14284
|
+
}, []);
|
|
14285
|
+
return filed;
|
|
14286
|
+
}
|
|
13617
14287
|
var index$n = "";
|
|
13618
14288
|
function TagV2(props) {
|
|
13619
14289
|
const { className = "", type, fontBold, color, backgroundColor } = props;
|
|
@@ -13644,7 +14314,8 @@ function ButtonV2(props) {
|
|
|
13644
14314
|
fullWidth,
|
|
13645
14315
|
...resetProps
|
|
13646
14316
|
} = props;
|
|
13647
|
-
function handleClick() {
|
|
14317
|
+
function handleClick(e2) {
|
|
14318
|
+
e2.stopPropagation();
|
|
13648
14319
|
if (!disabled && typeof onClick === "function")
|
|
13649
14320
|
onClick();
|
|
13650
14321
|
}
|
|
@@ -13654,7 +14325,7 @@ function ButtonV2(props) {
|
|
|
13654
14325
|
"op-pda-button-v2": true,
|
|
13655
14326
|
"not-text": !text,
|
|
13656
14327
|
[type]: true,
|
|
13657
|
-
|
|
14328
|
+
disabled,
|
|
13658
14329
|
"full-width": fullWidth,
|
|
13659
14330
|
[className]: className
|
|
13660
14331
|
}),
|
|
@@ -13687,11 +14358,7 @@ function PopupV2(props) {
|
|
|
13687
14358
|
className: "popup-wrap-inner"
|
|
13688
14359
|
}, /* @__PURE__ */ React__default.createElement("div", {
|
|
13689
14360
|
className: "title"
|
|
13690
|
-
}, title),
|
|
13691
|
-
className: "close-btn",
|
|
13692
|
-
fontSize: 20,
|
|
13693
|
-
onClick: onClose
|
|
13694
|
-
}), children));
|
|
14361
|
+
}, title), children));
|
|
13695
14362
|
}
|
|
13696
14363
|
var index$k = "";
|
|
13697
14364
|
function HeaderV2(props) {
|
|
@@ -13825,7 +14492,6 @@ function ScanV2(props) {
|
|
|
13825
14492
|
}, [onChange]);
|
|
13826
14493
|
React__default.useEffect(() => {
|
|
13827
14494
|
var _a;
|
|
13828
|
-
console.log(`eee===`);
|
|
13829
14495
|
inputRef.current.focus();
|
|
13830
14496
|
(_a = inputRef.current) == null ? void 0 : _a.setAttribute("readonly", true);
|
|
13831
14497
|
setTimeout(() => {
|
|
@@ -13927,14 +14593,12 @@ const CardType = {
|
|
|
13927
14593
|
className: "header-desc"
|
|
13928
14594
|
}, headerExtra == null ? void 0 : headerExtra.desc), /* @__PURE__ */ React__default.createElement("div", {
|
|
13929
14595
|
className: "header-tag"
|
|
13930
|
-
}, (headerExtra == null ? void 0 : headerExtra.tags) && ((_b = (_a = headerExtra.tags) == null ? void 0 : _a.map) == null ? void 0 : _b.call(
|
|
13931
|
-
|
|
13932
|
-
|
|
13933
|
-
|
|
13934
|
-
|
|
13935
|
-
|
|
13936
|
-
}, tag == null ? void 0 : tag.text)
|
|
13937
|
-
))), (headerExtra == null ? void 0 : headerExtra.showRightIcon) && /* @__PURE__ */ React__default.createElement("div", {
|
|
14596
|
+
}, (headerExtra == null ? void 0 : headerExtra.tags) && ((_b = (_a = headerExtra.tags) == null ? void 0 : _a.map) == null ? void 0 : _b.call(_a, (tag) => /* @__PURE__ */ React__default.createElement(TagV2, {
|
|
14597
|
+
key: tag == null ? void 0 : tag.text,
|
|
14598
|
+
type: tag == null ? void 0 : tag.type,
|
|
14599
|
+
fontBold: true,
|
|
14600
|
+
backgroundColor: tag == null ? void 0 : tag.backgroundColor
|
|
14601
|
+
}, tag == null ? void 0 : tag.text)))), (headerExtra == null ? void 0 : headerExtra.showRightIcon) && /* @__PURE__ */ React__default.createElement("div", {
|
|
13938
14602
|
className: "header-right-icon"
|
|
13939
14603
|
}, /* @__PURE__ */ React__default.createElement(RightOutline, null))));
|
|
13940
14604
|
},
|
|
@@ -13970,13 +14634,10 @@ const CardType = {
|
|
|
13970
14634
|
className: "header-goods-attrs"
|
|
13971
14635
|
}, (_b = (_a = header == null ? void 0 : header.attrs) == null ? void 0 : _a.map) == null ? void 0 : _b.call(_a, (attr) => /* @__PURE__ */ React__default.createElement("div", null, attr))), /* @__PURE__ */ React__default.createElement("div", {
|
|
13972
14636
|
className: "header-goods-tags"
|
|
13973
|
-
}, (_d = (_c = header == null ? void 0 : header.tags) == null ? void 0 : _c.map) == null ? void 0 : _d.call(
|
|
13974
|
-
|
|
13975
|
-
|
|
13976
|
-
|
|
13977
|
-
backgroundColor: tag == null ? void 0 : tag.backgroundColor
|
|
13978
|
-
}, tag == null ? void 0 : tag.text)
|
|
13979
|
-
))));
|
|
14637
|
+
}, (_d = (_c = header == null ? void 0 : header.tags) == null ? void 0 : _c.map) == null ? void 0 : _d.call(_c, (tag) => /* @__PURE__ */ React__default.createElement(TagV2, {
|
|
14638
|
+
type: tag == null ? void 0 : tag.type,
|
|
14639
|
+
backgroundColor: tag == null ? void 0 : tag.backgroundColor
|
|
14640
|
+
}, tag == null ? void 0 : tag.text)))));
|
|
13980
14641
|
},
|
|
13981
14642
|
renderCardContent: renderNormalContent,
|
|
13982
14643
|
renderCardFooter({ footer }) {
|
|
@@ -13998,7 +14659,10 @@ const CardType = {
|
|
|
13998
14659
|
renderCardFooter({ footer }) {
|
|
13999
14660
|
return /* @__PURE__ */ React__default.createElement("div", {
|
|
14000
14661
|
className: "footer-list",
|
|
14001
|
-
style: {
|
|
14662
|
+
style: {
|
|
14663
|
+
backgroundSize: "cover",
|
|
14664
|
+
backgroundImage: "url(https://img.alicdn.com/imgextra/i3/O1CN01wZqZW31J3gLuAwBJJ_!!6000000000973-2-tps-624-80.png)"
|
|
14665
|
+
}
|
|
14002
14666
|
}, footer);
|
|
14003
14667
|
}
|
|
14004
14668
|
},
|
|
@@ -14014,9 +14678,9 @@ const CardType = {
|
|
|
14014
14678
|
className: "content-tip"
|
|
14015
14679
|
}, /* @__PURE__ */ React__default.createElement("div", {
|
|
14016
14680
|
className: "content"
|
|
14017
|
-
}, /* @__PURE__ */ React__default.createElement("div", {
|
|
14681
|
+
}, (content == null ? void 0 : content.label) ? /* @__PURE__ */ React__default.createElement("div", {
|
|
14018
14682
|
className: "label"
|
|
14019
|
-
}, content == null ? void 0 : content.label), /* @__PURE__ */ React__default.createElement("div", {
|
|
14683
|
+
}, content == null ? void 0 : content.label) : null, /* @__PURE__ */ React__default.createElement("div", {
|
|
14020
14684
|
className: "value"
|
|
14021
14685
|
}, content == null ? void 0 : content.value)), (content == null ? void 0 : content.tag) && (((_a = content.tag) == null ? void 0 : _a.type) || ((_b = content.tag) == null ? void 0 : _b.text) ? /* @__PURE__ */ React__default.createElement("div", {
|
|
14022
14686
|
className: `tag ${((_c = content.tag) == null ? void 0 : _c.type) || "time"}`
|
|
@@ -14049,7 +14713,7 @@ function CardV2(props) {
|
|
|
14049
14713
|
style
|
|
14050
14714
|
}, /* @__PURE__ */ React__default.createElement("div", {
|
|
14051
14715
|
className: "card-body"
|
|
14052
|
-
}, typeof renderHeader === "function" ? renderHeader() : header && ((_b = (_a = CardType[type]) == null ? void 0 : _a.renderCardHeader) == null ? void 0 : _b.call(_a, props)), children ? children : typeof
|
|
14716
|
+
}, typeof renderHeader === "function" ? renderHeader() : header && ((_b = (_a = CardType[type]) == null ? void 0 : _a.renderCardHeader) == null ? void 0 : _b.call(_a, props)), children ? children : typeof renderContent === "function" ? renderContent() : (_d = (_c = CardType[type]) == null ? void 0 : _c.renderCardContent) == null ? void 0 : _d.call(_c, props), typeof renderFooter === "function" ? renderFooter() : footer && ((_f = (_e = CardType[type]) == null ? void 0 : _e.renderCardFooter) == null ? void 0 : _f.call(_e, props)), renderFooter));
|
|
14053
14717
|
}
|
|
14054
14718
|
function valueLineBreak(value) {
|
|
14055
14719
|
if ((typeof value === "string" || Array.isArray(value)) && String(value).indexOf(",") > -1) {
|
|
@@ -14194,7 +14858,9 @@ function SelectV2(props) {
|
|
|
14194
14858
|
onChange,
|
|
14195
14859
|
defaultValue,
|
|
14196
14860
|
value: aValue,
|
|
14197
|
-
hasBorder
|
|
14861
|
+
hasBorder,
|
|
14862
|
+
disabled,
|
|
14863
|
+
readOnly
|
|
14198
14864
|
} = props;
|
|
14199
14865
|
const [value, setValue] = React__default.useState(
|
|
14200
14866
|
aValue === void 0 ? defaultValue : aValue
|
|
@@ -14205,8 +14871,10 @@ function SelectV2(props) {
|
|
|
14205
14871
|
return /* @__PURE__ */ React__default.createElement("div", {
|
|
14206
14872
|
className: "op-pda-select-v2"
|
|
14207
14873
|
}, /* @__PURE__ */ React__default.createElement("div", {
|
|
14208
|
-
className: `select-input ${hasBorder ? "has-border" : ""}`,
|
|
14209
|
-
onClick: () =>
|
|
14874
|
+
className: `select-input ${hasBorder ? "has-border" : ""} ${readOnly ? "read-only" : disabled ? "disabled" : ""}`,
|
|
14875
|
+
onClick: () => {
|
|
14876
|
+
!disabled && !readOnly && setVisible(true);
|
|
14877
|
+
}
|
|
14210
14878
|
}, /* @__PURE__ */ React__default.createElement("div", {
|
|
14211
14879
|
className: "select-input-label"
|
|
14212
14880
|
}, label), /* @__PURE__ */ React__default.createElement("div", {
|
|
@@ -14215,7 +14883,7 @@ function SelectV2(props) {
|
|
|
14215
14883
|
className: "select-input-current-label"
|
|
14216
14884
|
}, curLabel) : /* @__PURE__ */ React__default.createElement("span", {
|
|
14217
14885
|
className: "select-input-placeholder"
|
|
14218
|
-
}, " ", placeholder), /* @__PURE__ */ React__default.createElement(RightOutline, {
|
|
14886
|
+
}, " ", placeholder), !readOnly && /* @__PURE__ */ React__default.createElement(RightOutline, {
|
|
14219
14887
|
fontSize: 18,
|
|
14220
14888
|
className: "select-input-icon"
|
|
14221
14889
|
}))), /* @__PURE__ */ React__default.createElement(Popup, {
|
|
@@ -14321,7 +14989,7 @@ function FinishCardV2(props) {
|
|
|
14321
14989
|
}, title), /* @__PURE__ */ React__default.createElement(CardV2, {
|
|
14322
14990
|
header: infoTitle,
|
|
14323
14991
|
dataSource: infoList
|
|
14324
|
-
}))
|
|
14992
|
+
})));
|
|
14325
14993
|
}
|
|
14326
14994
|
FinishCardV2.SUCCESS = `${window.PDA_IMAGE_PATH}O1CN01OL2UYg24792knbTtC_!!6000000007343-1-tps-506-415.gif`;
|
|
14327
14995
|
FinishCardV2.ERROR_SUCCESS = `${window.PDA_IMAGE_PATH}O1CN01p5Oc5t1VMFWtBomQc_!!6000000002638-1-tps-600-456.gif`;
|
|
@@ -14347,6 +15015,7 @@ function InputV2(props) {
|
|
|
14347
15015
|
return /* @__PURE__ */ React__default.createElement("div", {
|
|
14348
15016
|
className: `op-pda-input-v2 ${hasBorder ? "has-border" : ""}`
|
|
14349
15017
|
}, /* @__PURE__ */ React__default.createElement(Input, {
|
|
15018
|
+
placeholder: "\u8BF7\u8F93\u5165",
|
|
14350
15019
|
...props
|
|
14351
15020
|
}));
|
|
14352
15021
|
}
|
|
@@ -14544,297 +15213,6 @@ const PageFlowSystemPagesV2 = {
|
|
|
14544
15213
|
PlaySound,
|
|
14545
15214
|
Debug
|
|
14546
15215
|
};
|
|
14547
|
-
var dayjs_min = { exports: {} };
|
|
14548
|
-
(function(module, exports) {
|
|
14549
|
-
!function(t2, e2) {
|
|
14550
|
-
module.exports = e2();
|
|
14551
|
-
}(commonjsGlobal, function() {
|
|
14552
|
-
var t2 = 1e3, e2 = 6e4, n2 = 36e5, r2 = "millisecond", i = "second", s = "minute", u2 = "hour", a = "day", o = "week", c6 = "month", f2 = "quarter", h2 = "year", d2 = "date", l2 = "Invalid Date", $ = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, y = /\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g, M = { name: "en", weekdays: "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"), months: "January_February_March_April_May_June_July_August_September_October_November_December".split("_"), ordinal: function(t3) {
|
|
14553
|
-
var e3 = ["th", "st", "nd", "rd"], n3 = t3 % 100;
|
|
14554
|
-
return "[" + t3 + (e3[(n3 - 20) % 10] || e3[n3] || e3[0]) + "]";
|
|
14555
|
-
} }, m2 = function(t3, e3, n3) {
|
|
14556
|
-
var r3 = String(t3);
|
|
14557
|
-
return !r3 || r3.length >= e3 ? t3 : "" + Array(e3 + 1 - r3.length).join(n3) + t3;
|
|
14558
|
-
}, v2 = { s: m2, z: function(t3) {
|
|
14559
|
-
var e3 = -t3.utcOffset(), n3 = Math.abs(e3), r3 = Math.floor(n3 / 60), i2 = n3 % 60;
|
|
14560
|
-
return (e3 <= 0 ? "+" : "-") + m2(r3, 2, "0") + ":" + m2(i2, 2, "0");
|
|
14561
|
-
}, m: function t3(e3, n3) {
|
|
14562
|
-
if (e3.date() < n3.date())
|
|
14563
|
-
return -t3(n3, e3);
|
|
14564
|
-
var r3 = 12 * (n3.year() - e3.year()) + (n3.month() - e3.month()), i2 = e3.clone().add(r3, c6), s2 = n3 - i2 < 0, u3 = e3.clone().add(r3 + (s2 ? -1 : 1), c6);
|
|
14565
|
-
return +(-(r3 + (n3 - i2) / (s2 ? i2 - u3 : u3 - i2)) || 0);
|
|
14566
|
-
}, a: function(t3) {
|
|
14567
|
-
return t3 < 0 ? Math.ceil(t3) || 0 : Math.floor(t3);
|
|
14568
|
-
}, p: function(t3) {
|
|
14569
|
-
return { M: c6, y: h2, w: o, d: a, D: d2, h: u2, m: s, s: i, ms: r2, Q: f2 }[t3] || String(t3 || "").toLowerCase().replace(/s$/, "");
|
|
14570
|
-
}, u: function(t3) {
|
|
14571
|
-
return void 0 === t3;
|
|
14572
|
-
} }, g2 = "en", D = {};
|
|
14573
|
-
D[g2] = M;
|
|
14574
|
-
var p2 = "$isDayjsObject", S = function(t3) {
|
|
14575
|
-
return t3 instanceof _ || !(!t3 || !t3[p2]);
|
|
14576
|
-
}, w = function t3(e3, n3, r3) {
|
|
14577
|
-
var i2;
|
|
14578
|
-
if (!e3)
|
|
14579
|
-
return g2;
|
|
14580
|
-
if ("string" == typeof e3) {
|
|
14581
|
-
var s2 = e3.toLowerCase();
|
|
14582
|
-
D[s2] && (i2 = s2), n3 && (D[s2] = n3, i2 = s2);
|
|
14583
|
-
var u3 = e3.split("-");
|
|
14584
|
-
if (!i2 && u3.length > 1)
|
|
14585
|
-
return t3(u3[0]);
|
|
14586
|
-
} else {
|
|
14587
|
-
var a2 = e3.name;
|
|
14588
|
-
D[a2] = e3, i2 = a2;
|
|
14589
|
-
}
|
|
14590
|
-
return !r3 && i2 && (g2 = i2), i2 || !r3 && g2;
|
|
14591
|
-
}, O = function(t3, e3) {
|
|
14592
|
-
if (S(t3))
|
|
14593
|
-
return t3.clone();
|
|
14594
|
-
var n3 = "object" == typeof e3 ? e3 : {};
|
|
14595
|
-
return n3.date = t3, n3.args = arguments, new _(n3);
|
|
14596
|
-
}, b2 = v2;
|
|
14597
|
-
b2.l = w, b2.i = S, b2.w = function(t3, e3) {
|
|
14598
|
-
return O(t3, { locale: e3.$L, utc: e3.$u, x: e3.$x, $offset: e3.$offset });
|
|
14599
|
-
};
|
|
14600
|
-
var _ = function() {
|
|
14601
|
-
function M2(t3) {
|
|
14602
|
-
this.$L = w(t3.locale, null, true), this.parse(t3), this.$x = this.$x || t3.x || {}, this[p2] = true;
|
|
14603
|
-
}
|
|
14604
|
-
var m3 = M2.prototype;
|
|
14605
|
-
return m3.parse = function(t3) {
|
|
14606
|
-
this.$d = function(t4) {
|
|
14607
|
-
var e3 = t4.date, n3 = t4.utc;
|
|
14608
|
-
if (null === e3)
|
|
14609
|
-
return new Date(NaN);
|
|
14610
|
-
if (b2.u(e3))
|
|
14611
|
-
return new Date();
|
|
14612
|
-
if (e3 instanceof Date)
|
|
14613
|
-
return new Date(e3);
|
|
14614
|
-
if ("string" == typeof e3 && !/Z$/i.test(e3)) {
|
|
14615
|
-
var r3 = e3.match($);
|
|
14616
|
-
if (r3) {
|
|
14617
|
-
var i2 = r3[2] - 1 || 0, s2 = (r3[7] || "0").substring(0, 3);
|
|
14618
|
-
return n3 ? new Date(Date.UTC(r3[1], i2, r3[3] || 1, r3[4] || 0, r3[5] || 0, r3[6] || 0, s2)) : new Date(r3[1], i2, r3[3] || 1, r3[4] || 0, r3[5] || 0, r3[6] || 0, s2);
|
|
14619
|
-
}
|
|
14620
|
-
}
|
|
14621
|
-
return new Date(e3);
|
|
14622
|
-
}(t3), this.init();
|
|
14623
|
-
}, m3.init = function() {
|
|
14624
|
-
var t3 = this.$d;
|
|
14625
|
-
this.$y = t3.getFullYear(), this.$M = t3.getMonth(), this.$D = t3.getDate(), this.$W = t3.getDay(), this.$H = t3.getHours(), this.$m = t3.getMinutes(), this.$s = t3.getSeconds(), this.$ms = t3.getMilliseconds();
|
|
14626
|
-
}, m3.$utils = function() {
|
|
14627
|
-
return b2;
|
|
14628
|
-
}, m3.isValid = function() {
|
|
14629
|
-
return !(this.$d.toString() === l2);
|
|
14630
|
-
}, m3.isSame = function(t3, e3) {
|
|
14631
|
-
var n3 = O(t3);
|
|
14632
|
-
return this.startOf(e3) <= n3 && n3 <= this.endOf(e3);
|
|
14633
|
-
}, m3.isAfter = function(t3, e3) {
|
|
14634
|
-
return O(t3) < this.startOf(e3);
|
|
14635
|
-
}, m3.isBefore = function(t3, e3) {
|
|
14636
|
-
return this.endOf(e3) < O(t3);
|
|
14637
|
-
}, m3.$g = function(t3, e3, n3) {
|
|
14638
|
-
return b2.u(t3) ? this[e3] : this.set(n3, t3);
|
|
14639
|
-
}, m3.unix = function() {
|
|
14640
|
-
return Math.floor(this.valueOf() / 1e3);
|
|
14641
|
-
}, m3.valueOf = function() {
|
|
14642
|
-
return this.$d.getTime();
|
|
14643
|
-
}, m3.startOf = function(t3, e3) {
|
|
14644
|
-
var n3 = this, r3 = !!b2.u(e3) || e3, f3 = b2.p(t3), l3 = function(t4, e4) {
|
|
14645
|
-
var i2 = b2.w(n3.$u ? Date.UTC(n3.$y, e4, t4) : new Date(n3.$y, e4, t4), n3);
|
|
14646
|
-
return r3 ? i2 : i2.endOf(a);
|
|
14647
|
-
}, $2 = function(t4, e4) {
|
|
14648
|
-
return b2.w(n3.toDate()[t4].apply(n3.toDate("s"), (r3 ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(e4)), n3);
|
|
14649
|
-
}, y2 = this.$W, M3 = this.$M, m4 = this.$D, v3 = "set" + (this.$u ? "UTC" : "");
|
|
14650
|
-
switch (f3) {
|
|
14651
|
-
case h2:
|
|
14652
|
-
return r3 ? l3(1, 0) : l3(31, 11);
|
|
14653
|
-
case c6:
|
|
14654
|
-
return r3 ? l3(1, M3) : l3(0, M3 + 1);
|
|
14655
|
-
case o:
|
|
14656
|
-
var g3 = this.$locale().weekStart || 0, D2 = (y2 < g3 ? y2 + 7 : y2) - g3;
|
|
14657
|
-
return l3(r3 ? m4 - D2 : m4 + (6 - D2), M3);
|
|
14658
|
-
case a:
|
|
14659
|
-
case d2:
|
|
14660
|
-
return $2(v3 + "Hours", 0);
|
|
14661
|
-
case u2:
|
|
14662
|
-
return $2(v3 + "Minutes", 1);
|
|
14663
|
-
case s:
|
|
14664
|
-
return $2(v3 + "Seconds", 2);
|
|
14665
|
-
case i:
|
|
14666
|
-
return $2(v3 + "Milliseconds", 3);
|
|
14667
|
-
default:
|
|
14668
|
-
return this.clone();
|
|
14669
|
-
}
|
|
14670
|
-
}, m3.endOf = function(t3) {
|
|
14671
|
-
return this.startOf(t3, false);
|
|
14672
|
-
}, m3.$set = function(t3, e3) {
|
|
14673
|
-
var n3, o2 = b2.p(t3), f3 = "set" + (this.$u ? "UTC" : ""), l3 = (n3 = {}, n3[a] = f3 + "Date", n3[d2] = f3 + "Date", n3[c6] = f3 + "Month", n3[h2] = f3 + "FullYear", n3[u2] = f3 + "Hours", n3[s] = f3 + "Minutes", n3[i] = f3 + "Seconds", n3[r2] = f3 + "Milliseconds", n3)[o2], $2 = o2 === a ? this.$D + (e3 - this.$W) : e3;
|
|
14674
|
-
if (o2 === c6 || o2 === h2) {
|
|
14675
|
-
var y2 = this.clone().set(d2, 1);
|
|
14676
|
-
y2.$d[l3]($2), y2.init(), this.$d = y2.set(d2, Math.min(this.$D, y2.daysInMonth())).$d;
|
|
14677
|
-
} else
|
|
14678
|
-
l3 && this.$d[l3]($2);
|
|
14679
|
-
return this.init(), this;
|
|
14680
|
-
}, m3.set = function(t3, e3) {
|
|
14681
|
-
return this.clone().$set(t3, e3);
|
|
14682
|
-
}, m3.get = function(t3) {
|
|
14683
|
-
return this[b2.p(t3)]();
|
|
14684
|
-
}, m3.add = function(r3, f3) {
|
|
14685
|
-
var d3, l3 = this;
|
|
14686
|
-
r3 = Number(r3);
|
|
14687
|
-
var $2 = b2.p(f3), y2 = function(t3) {
|
|
14688
|
-
var e3 = O(l3);
|
|
14689
|
-
return b2.w(e3.date(e3.date() + Math.round(t3 * r3)), l3);
|
|
14690
|
-
};
|
|
14691
|
-
if ($2 === c6)
|
|
14692
|
-
return this.set(c6, this.$M + r3);
|
|
14693
|
-
if ($2 === h2)
|
|
14694
|
-
return this.set(h2, this.$y + r3);
|
|
14695
|
-
if ($2 === a)
|
|
14696
|
-
return y2(1);
|
|
14697
|
-
if ($2 === o)
|
|
14698
|
-
return y2(7);
|
|
14699
|
-
var M3 = (d3 = {}, d3[s] = e2, d3[u2] = n2, d3[i] = t2, d3)[$2] || 1, m4 = this.$d.getTime() + r3 * M3;
|
|
14700
|
-
return b2.w(m4, this);
|
|
14701
|
-
}, m3.subtract = function(t3, e3) {
|
|
14702
|
-
return this.add(-1 * t3, e3);
|
|
14703
|
-
}, m3.format = function(t3) {
|
|
14704
|
-
var e3 = this, n3 = this.$locale();
|
|
14705
|
-
if (!this.isValid())
|
|
14706
|
-
return n3.invalidDate || l2;
|
|
14707
|
-
var r3 = t3 || "YYYY-MM-DDTHH:mm:ssZ", i2 = b2.z(this), s2 = this.$H, u3 = this.$m, a2 = this.$M, o2 = n3.weekdays, c7 = n3.months, f3 = n3.meridiem, h3 = function(t4, n4, i3, s3) {
|
|
14708
|
-
return t4 && (t4[n4] || t4(e3, r3)) || i3[n4].slice(0, s3);
|
|
14709
|
-
}, d3 = function(t4) {
|
|
14710
|
-
return b2.s(s2 % 12 || 12, t4, "0");
|
|
14711
|
-
}, $2 = f3 || function(t4, e4, n4) {
|
|
14712
|
-
var r4 = t4 < 12 ? "AM" : "PM";
|
|
14713
|
-
return n4 ? r4.toLowerCase() : r4;
|
|
14714
|
-
};
|
|
14715
|
-
return r3.replace(y, function(t4, r4) {
|
|
14716
|
-
return r4 || function(t5) {
|
|
14717
|
-
switch (t5) {
|
|
14718
|
-
case "YY":
|
|
14719
|
-
return String(e3.$y).slice(-2);
|
|
14720
|
-
case "YYYY":
|
|
14721
|
-
return b2.s(e3.$y, 4, "0");
|
|
14722
|
-
case "M":
|
|
14723
|
-
return a2 + 1;
|
|
14724
|
-
case "MM":
|
|
14725
|
-
return b2.s(a2 + 1, 2, "0");
|
|
14726
|
-
case "MMM":
|
|
14727
|
-
return h3(n3.monthsShort, a2, c7, 3);
|
|
14728
|
-
case "MMMM":
|
|
14729
|
-
return h3(c7, a2);
|
|
14730
|
-
case "D":
|
|
14731
|
-
return e3.$D;
|
|
14732
|
-
case "DD":
|
|
14733
|
-
return b2.s(e3.$D, 2, "0");
|
|
14734
|
-
case "d":
|
|
14735
|
-
return String(e3.$W);
|
|
14736
|
-
case "dd":
|
|
14737
|
-
return h3(n3.weekdaysMin, e3.$W, o2, 2);
|
|
14738
|
-
case "ddd":
|
|
14739
|
-
return h3(n3.weekdaysShort, e3.$W, o2, 3);
|
|
14740
|
-
case "dddd":
|
|
14741
|
-
return o2[e3.$W];
|
|
14742
|
-
case "H":
|
|
14743
|
-
return String(s2);
|
|
14744
|
-
case "HH":
|
|
14745
|
-
return b2.s(s2, 2, "0");
|
|
14746
|
-
case "h":
|
|
14747
|
-
return d3(1);
|
|
14748
|
-
case "hh":
|
|
14749
|
-
return d3(2);
|
|
14750
|
-
case "a":
|
|
14751
|
-
return $2(s2, u3, true);
|
|
14752
|
-
case "A":
|
|
14753
|
-
return $2(s2, u3, false);
|
|
14754
|
-
case "m":
|
|
14755
|
-
return String(u3);
|
|
14756
|
-
case "mm":
|
|
14757
|
-
return b2.s(u3, 2, "0");
|
|
14758
|
-
case "s":
|
|
14759
|
-
return String(e3.$s);
|
|
14760
|
-
case "ss":
|
|
14761
|
-
return b2.s(e3.$s, 2, "0");
|
|
14762
|
-
case "SSS":
|
|
14763
|
-
return b2.s(e3.$ms, 3, "0");
|
|
14764
|
-
case "Z":
|
|
14765
|
-
return i2;
|
|
14766
|
-
}
|
|
14767
|
-
return null;
|
|
14768
|
-
}(t4) || i2.replace(":", "");
|
|
14769
|
-
});
|
|
14770
|
-
}, m3.utcOffset = function() {
|
|
14771
|
-
return 15 * -Math.round(this.$d.getTimezoneOffset() / 15);
|
|
14772
|
-
}, m3.diff = function(r3, d3, l3) {
|
|
14773
|
-
var $2, y2 = this, M3 = b2.p(d3), m4 = O(r3), v3 = (m4.utcOffset() - this.utcOffset()) * e2, g3 = this - m4, D2 = function() {
|
|
14774
|
-
return b2.m(y2, m4);
|
|
14775
|
-
};
|
|
14776
|
-
switch (M3) {
|
|
14777
|
-
case h2:
|
|
14778
|
-
$2 = D2() / 12;
|
|
14779
|
-
break;
|
|
14780
|
-
case c6:
|
|
14781
|
-
$2 = D2();
|
|
14782
|
-
break;
|
|
14783
|
-
case f2:
|
|
14784
|
-
$2 = D2() / 3;
|
|
14785
|
-
break;
|
|
14786
|
-
case o:
|
|
14787
|
-
$2 = (g3 - v3) / 6048e5;
|
|
14788
|
-
break;
|
|
14789
|
-
case a:
|
|
14790
|
-
$2 = (g3 - v3) / 864e5;
|
|
14791
|
-
break;
|
|
14792
|
-
case u2:
|
|
14793
|
-
$2 = g3 / n2;
|
|
14794
|
-
break;
|
|
14795
|
-
case s:
|
|
14796
|
-
$2 = g3 / e2;
|
|
14797
|
-
break;
|
|
14798
|
-
case i:
|
|
14799
|
-
$2 = g3 / t2;
|
|
14800
|
-
break;
|
|
14801
|
-
default:
|
|
14802
|
-
$2 = g3;
|
|
14803
|
-
}
|
|
14804
|
-
return l3 ? $2 : b2.a($2);
|
|
14805
|
-
}, m3.daysInMonth = function() {
|
|
14806
|
-
return this.endOf(c6).$D;
|
|
14807
|
-
}, m3.$locale = function() {
|
|
14808
|
-
return D[this.$L];
|
|
14809
|
-
}, m3.locale = function(t3, e3) {
|
|
14810
|
-
if (!t3)
|
|
14811
|
-
return this.$L;
|
|
14812
|
-
var n3 = this.clone(), r3 = w(t3, e3, true);
|
|
14813
|
-
return r3 && (n3.$L = r3), n3;
|
|
14814
|
-
}, m3.clone = function() {
|
|
14815
|
-
return b2.w(this.$d, this);
|
|
14816
|
-
}, m3.toDate = function() {
|
|
14817
|
-
return new Date(this.valueOf());
|
|
14818
|
-
}, m3.toJSON = function() {
|
|
14819
|
-
return this.isValid() ? this.toISOString() : null;
|
|
14820
|
-
}, m3.toISOString = function() {
|
|
14821
|
-
return this.$d.toISOString();
|
|
14822
|
-
}, m3.toString = function() {
|
|
14823
|
-
return this.$d.toUTCString();
|
|
14824
|
-
}, M2;
|
|
14825
|
-
}(), k2 = _.prototype;
|
|
14826
|
-
return O.prototype = k2, [["$ms", r2], ["$s", i], ["$m", s], ["$H", u2], ["$W", a], ["$M", c6], ["$y", h2], ["$D", d2]].forEach(function(t3) {
|
|
14827
|
-
k2[t3[1]] = function(e3) {
|
|
14828
|
-
return this.$g(e3, t3[0], t3[1]);
|
|
14829
|
-
};
|
|
14830
|
-
}), O.extend = function(t3, e3) {
|
|
14831
|
-
return t3.$i || (t3(e3, _, O), t3.$i = true), O;
|
|
14832
|
-
}, O.locale = w, O.isDayjs = S, O.unix = function(t3) {
|
|
14833
|
-
return O(1e3 * t3);
|
|
14834
|
-
}, O.en = D[g2], O.Ls = D, O.p = {}, O;
|
|
14835
|
-
});
|
|
14836
|
-
})(dayjs_min);
|
|
14837
|
-
var dayjs = dayjs_min.exports;
|
|
14838
15216
|
var index = "";
|
|
14839
15217
|
function DatePickerV2(props) {
|
|
14840
15218
|
const {
|
|
@@ -14888,4 +15266,4 @@ function getFormatDate(val, format, initialValue) {
|
|
|
14888
15266
|
return returnValue;
|
|
14889
15267
|
}
|
|
14890
15268
|
const ListItem = PdaListItem;
|
|
14891
|
-
export { ActionSheet, index$
|
|
15269
|
+
export { ActionSheet, index$E as AppList, Badge as BadgeV2, BaseLayout, Button$2 as Button, ButtonV2, List$2 as Card, CardV2, Confirm$1 as Confirm, index$q as DatePicker, DatePickerV2, PdaDistanceCard as DistanceCard, PdaFinishCard as FinishCard, FinishCardV2, FooterV2, index$$ as Header, HeaderV2, IllustrationV2, ImageUploader, ImageUploaderV2, ImageViewer, InfiniteScroll, PdaInfoCard$2 as InfoCard, index$t as InputItem, InputV2, Keyborard, LatticeMouth, LatticeMouthV2, LayoutV2, List$3 as List, ListItem, List as ListV2, Loading, MenuListV2, NumberPickerV2, Overlay$1 as Overlay, PDA_IMAGE_PATH, index$S as PageFlowSystemPages, PageFlowSystemPagesV2, index$v as Picker, PopupV2, Presentation, ProgressBar as ProgressBarV2, index$o as RadioV2, ScanV2, SelectCard, SelectV2, SimpleCard, SimpleCardBlock, PdaInfoCard as Steps, SubCard, TableV2, Tabs as TabsV2, Tag, TagV2, PdaListItem as TaskCard, TaskCardV2, TaskInputV2, PdaTitle as Title, Toast$1 as Toast, WakeKeyborard, index$s as useFiled, useFieldV2 as useFiledV2 };
|