antd-mobile 5.22.0 → 5.24.0
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/2x/bundle/antd-mobile.cjs.development.js +953 -709
- package/2x/bundle/antd-mobile.cjs.js +8 -8
- package/2x/bundle/antd-mobile.compatible.umd.js +6991 -6789
- package/2x/bundle/antd-mobile.es.development.js +953 -709
- package/2x/bundle/antd-mobile.es.js +5666 -5497
- package/2x/bundle/antd-mobile.umd.development.js +953 -709
- package/2x/bundle/antd-mobile.umd.js +8 -8
- package/2x/bundle/style.css +137 -41
- package/2x/cjs/components/avatar/avatar.js +2 -2
- package/2x/cjs/components/calendar/calendar.d.ts +3 -5
- package/2x/cjs/components/calendar/calendar.js +27 -5
- package/2x/cjs/components/calendar/convert.d.ts +6 -0
- package/2x/cjs/components/calendar/convert.js +9 -0
- package/2x/cjs/components/dialog/dialog-action-button.d.ts +2 -2
- package/2x/cjs/components/ellipsis/ellipsis.js +16 -7
- package/2x/cjs/components/empty/empty.d.ts +1 -0
- package/2x/cjs/components/empty/empty.js +1 -0
- package/2x/cjs/components/footer/footer.css +60 -0
- package/2x/cjs/components/footer/footer.d.ts +19 -0
- package/2x/cjs/components/footer/footer.js +83 -0
- package/2x/cjs/components/footer/index.d.ts +4 -0
- package/2x/cjs/components/footer/index.js +13 -0
- package/2x/cjs/components/form/form-item.css +0 -1
- package/2x/cjs/components/form/form.css +9 -3
- package/2x/cjs/components/form/form.d.ts +2 -2
- package/2x/cjs/components/form/index.css +9 -4
- package/2x/cjs/components/form/index.d.ts +1 -1
- package/2x/cjs/components/image-uploader/image-uploader.d.ts +11 -1
- package/2x/cjs/components/image-uploader/image-uploader.js +42 -25
- package/2x/cjs/components/image-uploader/index.d.ts +1 -1
- package/2x/cjs/components/image-uploader/preview-item.js +5 -0
- package/2x/cjs/components/image-viewer/slides.js +2 -2
- package/2x/cjs/components/page-indicator/page-indicator.css +1 -0
- package/2x/cjs/components/picker/index.d.ts +2 -2
- package/2x/cjs/components/picker/picker.d.ts +1 -1
- package/2x/cjs/components/picker-view/picker-view.css +9 -0
- package/2x/cjs/components/picker-view/wheel.js +8 -4
- package/2x/cjs/components/popover/popover.js +2 -2
- package/2x/cjs/components/rate/rate.css +6 -1
- package/2x/cjs/components/rate/rate.js +3 -1
- package/2x/cjs/components/slider/slider.css +15 -1
- package/2x/cjs/components/slider/slider.d.ts +1 -0
- package/2x/cjs/components/slider/slider.js +13 -2
- package/2x/cjs/components/slider/thumb.d.ts +1 -0
- package/2x/cjs/components/slider/thumb.js +4 -3
- package/2x/cjs/components/stepper/stepper.js +2 -1
- package/2x/cjs/components/swiper/swiper.js +9 -0
- package/2x/cjs/components/toast/toast.css +4 -3
- package/2x/cjs/index.d.ts +1 -0
- package/2x/cjs/index.js +8 -0
- package/2x/cjs/locales/zh-CN.js +1 -1
- package/2x/cjs/utils/measure-css-length.js +1 -1
- package/2x/es/components/avatar/avatar.js +1 -1
- package/2x/es/components/calendar/calendar.d.ts +3 -5
- package/2x/es/components/calendar/calendar.js +29 -6
- package/2x/es/components/calendar/convert.d.ts +6 -0
- package/2x/es/components/calendar/convert.js +4 -0
- package/2x/es/components/dialog/dialog-action-button.d.ts +2 -2
- package/2x/es/components/ellipsis/ellipsis.js +14 -8
- package/2x/es/components/empty/empty.d.ts +1 -0
- package/2x/es/components/empty/empty.js +2 -0
- package/2x/es/components/footer/footer.css +60 -0
- package/2x/es/components/footer/footer.d.ts +19 -0
- package/2x/es/components/footer/footer.js +66 -0
- package/2x/es/components/footer/index.d.ts +4 -0
- package/2x/es/components/footer/index.js +3 -0
- package/2x/es/components/form/form-item.css +0 -1
- package/2x/es/components/form/form.css +9 -3
- package/2x/es/components/form/form.d.ts +2 -2
- package/2x/es/components/form/index.css +9 -4
- package/2x/es/components/form/index.d.ts +1 -1
- package/2x/es/components/image-uploader/image-uploader.d.ts +11 -1
- package/2x/es/components/image-uploader/image-uploader.js +41 -25
- package/2x/es/components/image-uploader/index.d.ts +1 -1
- package/2x/es/components/image-uploader/preview-item.js +6 -1
- package/2x/es/components/image-viewer/slides.js +2 -2
- package/2x/es/components/page-indicator/page-indicator.css +1 -0
- package/2x/es/components/picker/index.d.ts +2 -2
- package/2x/es/components/picker/picker.d.ts +1 -1
- package/2x/es/components/picker-view/picker-view.css +9 -0
- package/2x/es/components/picker-view/wheel.js +8 -4
- package/2x/es/components/popover/popover.js +2 -2
- package/2x/es/components/rate/rate.css +6 -1
- package/2x/es/components/rate/rate.js +3 -1
- package/2x/es/components/slider/slider.css +15 -1
- package/2x/es/components/slider/slider.d.ts +1 -0
- package/2x/es/components/slider/slider.js +12 -2
- package/2x/es/components/slider/thumb.d.ts +1 -0
- package/2x/es/components/slider/thumb.js +4 -3
- package/2x/es/components/stepper/stepper.js +2 -1
- package/2x/es/components/swiper/swiper.js +9 -0
- package/2x/es/components/toast/toast.css +4 -3
- package/2x/es/index.d.ts +1 -0
- package/2x/es/index.js +1 -0
- package/2x/es/locales/zh-CN.js +1 -1
- package/2x/es/utils/measure-css-length.js +1 -1
- package/2x/package.json +2 -1
- package/2x/umd/antd-mobile.js +6991 -6789
- package/bundle/antd-mobile.cjs.development.js +953 -709
- package/bundle/antd-mobile.cjs.js +8 -8
- package/bundle/antd-mobile.compatible.umd.js +6991 -6789
- package/bundle/antd-mobile.es.development.js +953 -709
- package/bundle/antd-mobile.es.js +5666 -5497
- package/bundle/antd-mobile.umd.development.js +953 -709
- package/bundle/antd-mobile.umd.js +8 -8
- package/bundle/style.css +1 -1
- package/cjs/components/avatar/avatar.js +2 -2
- package/cjs/components/calendar/calendar.d.ts +3 -5
- package/cjs/components/calendar/calendar.js +27 -5
- package/cjs/components/calendar/convert.d.ts +6 -0
- package/cjs/components/calendar/convert.js +9 -0
- package/cjs/components/dialog/dialog-action-button.d.ts +2 -2
- package/cjs/components/ellipsis/ellipsis.js +16 -7
- package/cjs/components/empty/empty.d.ts +1 -0
- package/cjs/components/empty/empty.js +1 -0
- package/cjs/components/footer/footer.css +51 -0
- package/cjs/components/footer/footer.d.ts +19 -0
- package/cjs/components/footer/footer.js +83 -0
- package/cjs/components/footer/index.d.ts +4 -0
- package/cjs/components/footer/index.js +13 -0
- package/cjs/components/form/form-item.css +0 -1
- package/cjs/components/form/form.css +8 -3
- package/cjs/components/form/form.d.ts +2 -2
- package/cjs/components/form/index.css +8 -4
- package/cjs/components/form/index.d.ts +1 -1
- package/cjs/components/image-uploader/image-uploader.d.ts +11 -1
- package/cjs/components/image-uploader/image-uploader.js +42 -25
- package/cjs/components/image-uploader/index.d.ts +1 -1
- package/cjs/components/image-uploader/preview-item.js +5 -0
- package/cjs/components/image-viewer/slides.js +2 -2
- package/cjs/components/page-indicator/page-indicator.css +1 -0
- package/cjs/components/picker/index.d.ts +2 -2
- package/cjs/components/picker/picker.d.ts +1 -1
- package/cjs/components/picker-view/picker-view.css +8 -0
- package/cjs/components/picker-view/wheel.js +8 -4
- package/cjs/components/popover/popover.js +2 -2
- package/cjs/components/rate/rate.css +5 -1
- package/cjs/components/rate/rate.js +3 -1
- package/cjs/components/slider/slider.css +14 -1
- package/cjs/components/slider/slider.d.ts +1 -0
- package/cjs/components/slider/slider.js +13 -2
- package/cjs/components/slider/thumb.d.ts +1 -0
- package/cjs/components/slider/thumb.js +4 -3
- package/cjs/components/stepper/stepper.js +2 -1
- package/cjs/components/swiper/swiper.js +9 -0
- package/cjs/components/toast/toast.css +4 -3
- package/cjs/index.d.ts +1 -0
- package/cjs/index.js +8 -0
- package/cjs/locales/zh-CN.js +1 -1
- package/cjs/utils/measure-css-length.js +1 -1
- package/es/components/avatar/avatar.js +1 -1
- package/es/components/calendar/calendar.d.ts +3 -5
- package/es/components/calendar/calendar.js +29 -6
- package/es/components/calendar/convert.d.ts +6 -0
- package/es/components/calendar/convert.js +4 -0
- package/es/components/dialog/dialog-action-button.d.ts +2 -2
- package/es/components/ellipsis/ellipsis.js +14 -8
- package/es/components/empty/empty.d.ts +1 -0
- package/es/components/empty/empty.js +2 -0
- package/es/components/footer/footer.css +51 -0
- package/es/components/footer/footer.d.ts +19 -0
- package/es/components/footer/footer.js +66 -0
- package/es/components/footer/index.d.ts +4 -0
- package/es/components/footer/index.js +3 -0
- package/es/components/form/form-item.css +0 -1
- package/es/components/form/form.css +8 -3
- package/es/components/form/form.d.ts +2 -2
- package/es/components/form/index.css +8 -4
- package/es/components/form/index.d.ts +1 -1
- package/es/components/image-uploader/image-uploader.d.ts +11 -1
- package/es/components/image-uploader/image-uploader.js +41 -25
- package/es/components/image-uploader/index.d.ts +1 -1
- package/es/components/image-uploader/preview-item.js +6 -1
- package/es/components/image-viewer/slides.js +2 -2
- package/es/components/page-indicator/page-indicator.css +1 -0
- package/es/components/picker/index.d.ts +2 -2
- package/es/components/picker/picker.d.ts +1 -1
- package/es/components/picker-view/picker-view.css +8 -0
- package/es/components/picker-view/wheel.js +8 -4
- package/es/components/popover/popover.js +2 -2
- package/es/components/rate/rate.css +5 -1
- package/es/components/rate/rate.js +3 -1
- package/es/components/slider/slider.css +14 -1
- package/es/components/slider/slider.d.ts +1 -0
- package/es/components/slider/slider.js +12 -2
- package/es/components/slider/thumb.d.ts +1 -0
- package/es/components/slider/thumb.js +4 -3
- package/es/components/stepper/stepper.js +2 -1
- package/es/components/swiper/swiper.js +9 -0
- package/es/components/toast/toast.css +4 -3
- package/es/index.d.ts +1 -0
- package/es/index.js +1 -0
- package/es/locales/zh-CN.js +1 -1
- package/es/utils/measure-css-length.js +1 -1
- package/package.json +2 -1
- package/umd/antd-mobile.js +1 -1
|
@@ -289,7 +289,7 @@ const zhCN = mergeLocale(base, {
|
|
|
289
289
|
clear: "\u6E05\u9664"
|
|
290
290
|
},
|
|
291
291
|
Mask: {
|
|
292
|
-
name: "\
|
|
292
|
+
name: "\u80CC\u666F\u8499\u5C42"
|
|
293
293
|
},
|
|
294
294
|
Modal: {
|
|
295
295
|
ok: "\u6211\u77E5\u9053\u4E86"
|
|
@@ -6965,13 +6965,13 @@ function withStopPropagation(events, element) {
|
|
|
6965
6965
|
}
|
|
6966
6966
|
return React__default.cloneElement(element, props);
|
|
6967
6967
|
}
|
|
6968
|
-
const classPrefix$
|
|
6968
|
+
const classPrefix$1l = `adm-mask`;
|
|
6969
6969
|
const opacityRecord = {
|
|
6970
6970
|
default: 0.55,
|
|
6971
6971
|
thin: 0.35,
|
|
6972
6972
|
thick: 0.75
|
|
6973
6973
|
};
|
|
6974
|
-
const defaultProps$
|
|
6974
|
+
const defaultProps$13 = {
|
|
6975
6975
|
visible: true,
|
|
6976
6976
|
destroyOnClose: false,
|
|
6977
6977
|
forceRender: false,
|
|
@@ -6982,7 +6982,7 @@ const defaultProps$12 = {
|
|
|
6982
6982
|
stopPropagation: ["click"]
|
|
6983
6983
|
};
|
|
6984
6984
|
const Mask = (p) => {
|
|
6985
|
-
const props = mergeProps(defaultProps$
|
|
6985
|
+
const props = mergeProps(defaultProps$13, p);
|
|
6986
6986
|
const {
|
|
6987
6987
|
locale
|
|
6988
6988
|
} = useConfig();
|
|
@@ -7023,7 +7023,7 @@ const Mask = (p) => {
|
|
|
7023
7023
|
}
|
|
7024
7024
|
});
|
|
7025
7025
|
const node = withStopPropagation(props.stopPropagation, withNativeProps(props, React__default.createElement(animated.div, {
|
|
7026
|
-
className: classPrefix$
|
|
7026
|
+
className: classPrefix$1l,
|
|
7027
7027
|
ref,
|
|
7028
7028
|
style: Object.assign(Object.assign({}, props.style), {
|
|
7029
7029
|
background,
|
|
@@ -7037,12 +7037,12 @@ const Mask = (p) => {
|
|
|
7037
7037
|
}
|
|
7038
7038
|
}
|
|
7039
7039
|
}, props.onMaskClick && React__default.createElement("div", {
|
|
7040
|
-
className: `${classPrefix$
|
|
7040
|
+
className: `${classPrefix$1l}-aria-button`,
|
|
7041
7041
|
role: "button",
|
|
7042
7042
|
"aria-label": locale.Mask.name,
|
|
7043
7043
|
onClick: props.onMaskClick
|
|
7044
7044
|
}), React__default.createElement("div", {
|
|
7045
|
-
className: `${classPrefix$
|
|
7045
|
+
className: `${classPrefix$1l}-content`
|
|
7046
7046
|
}, props.children))));
|
|
7047
7047
|
return React__default.createElement(ShouldRender, {
|
|
7048
7048
|
active,
|
|
@@ -7659,13 +7659,13 @@ function useInnerVisible(outerVisible) {
|
|
|
7659
7659
|
}, [outerVisible]);
|
|
7660
7660
|
return innerVisible;
|
|
7661
7661
|
}
|
|
7662
|
-
const classPrefix$
|
|
7663
|
-
const defaultProps$
|
|
7662
|
+
const classPrefix$1k = `adm-popup`;
|
|
7663
|
+
const defaultProps$12 = Object.assign(Object.assign({}, defaultPopupBaseProps), {
|
|
7664
7664
|
position: "bottom"
|
|
7665
7665
|
});
|
|
7666
7666
|
const Popup = (p) => {
|
|
7667
|
-
const props = mergeProps(defaultProps$
|
|
7668
|
-
const bodyCls = classNames(`${classPrefix$
|
|
7667
|
+
const props = mergeProps(defaultProps$12, p);
|
|
7668
|
+
const bodyCls = classNames(`${classPrefix$1k}-body`, props.bodyClassName, `${classPrefix$1k}-body-position-${props.position}`);
|
|
7669
7669
|
const [active, setActive] = useState(props.visible);
|
|
7670
7670
|
useIsomorphicLayoutEffect$1(() => {
|
|
7671
7671
|
if (props.visible) {
|
|
@@ -7699,7 +7699,7 @@ const Popup = (p) => {
|
|
|
7699
7699
|
});
|
|
7700
7700
|
const maskVisible = useInnerVisible(active && props.visible);
|
|
7701
7701
|
const node = withStopPropagation(props.stopPropagation, withNativeProps(props, React__default.createElement("div", {
|
|
7702
|
-
className: classPrefix$
|
|
7702
|
+
className: classPrefix$1k,
|
|
7703
7703
|
onClick: props.onClick,
|
|
7704
7704
|
style: {
|
|
7705
7705
|
display: active ? void 0 : "none"
|
|
@@ -7740,7 +7740,7 @@ const Popup = (p) => {
|
|
|
7740
7740
|
}),
|
|
7741
7741
|
ref
|
|
7742
7742
|
}, props.showCloseButton && React__default.createElement("a", {
|
|
7743
|
-
className: classNames(`${classPrefix$
|
|
7743
|
+
className: classNames(`${classPrefix$1k}-close-icon`, "adm-plain-anchor"),
|
|
7744
7744
|
onClick: () => {
|
|
7745
7745
|
var _a;
|
|
7746
7746
|
(_a = props.onClose) === null || _a === void 0 ? void 0 : _a.call(props);
|
|
@@ -7753,10 +7753,10 @@ const Popup = (p) => {
|
|
|
7753
7753
|
}, renderToContainer(props.getContainer, node));
|
|
7754
7754
|
};
|
|
7755
7755
|
const safeArea = "";
|
|
7756
|
-
const classPrefix$
|
|
7756
|
+
const classPrefix$1j = "adm-safe-area";
|
|
7757
7757
|
const SafeArea = (props) => {
|
|
7758
7758
|
return withNativeProps(props, React__default.createElement("div", {
|
|
7759
|
-
className: classNames(classPrefix$
|
|
7759
|
+
className: classNames(classPrefix$1j, `${classPrefix$1j}-position-${props.position}`)
|
|
7760
7760
|
}));
|
|
7761
7761
|
};
|
|
7762
7762
|
const fullClone = Object.assign({}, ReactDOM);
|
|
@@ -7884,8 +7884,8 @@ function renderImperatively(element) {
|
|
|
7884
7884
|
}
|
|
7885
7885
|
};
|
|
7886
7886
|
}
|
|
7887
|
-
const classPrefix$
|
|
7888
|
-
const defaultProps$
|
|
7887
|
+
const classPrefix$1i = `adm-action-sheet`;
|
|
7888
|
+
const defaultProps$11 = {
|
|
7889
7889
|
visible: false,
|
|
7890
7890
|
actions: [],
|
|
7891
7891
|
cancelText: "",
|
|
@@ -7896,7 +7896,7 @@ const defaultProps$10 = {
|
|
|
7896
7896
|
forceRender: false
|
|
7897
7897
|
};
|
|
7898
7898
|
const ActionSheet = (p) => {
|
|
7899
|
-
const props = mergeProps(defaultProps$
|
|
7899
|
+
const props = mergeProps(defaultProps$11, p);
|
|
7900
7900
|
return React__default.createElement(Popup, {
|
|
7901
7901
|
visible: props.visible,
|
|
7902
7902
|
onMaskClick: () => {
|
|
@@ -7907,25 +7907,25 @@ const ActionSheet = (p) => {
|
|
|
7907
7907
|
}
|
|
7908
7908
|
},
|
|
7909
7909
|
afterClose: props.afterClose,
|
|
7910
|
-
className: classNames(`${classPrefix$
|
|
7910
|
+
className: classNames(`${classPrefix$1i}-popup`, props.popupClassName),
|
|
7911
7911
|
style: props.popupStyle,
|
|
7912
7912
|
getContainer: props.getContainer,
|
|
7913
7913
|
destroyOnClose: props.destroyOnClose,
|
|
7914
7914
|
forceRender: props.forceRender
|
|
7915
7915
|
}, withNativeProps(props, React__default.createElement("div", {
|
|
7916
|
-
className: classPrefix$
|
|
7916
|
+
className: classPrefix$1i
|
|
7917
7917
|
}, props.extra && React__default.createElement("div", {
|
|
7918
|
-
className: `${classPrefix$
|
|
7918
|
+
className: `${classPrefix$1i}-extra`
|
|
7919
7919
|
}, props.extra), React__default.createElement("div", {
|
|
7920
|
-
className: `${classPrefix$
|
|
7920
|
+
className: `${classPrefix$1i}-button-list`
|
|
7921
7921
|
}, props.actions.map((action, index2) => React__default.createElement("div", {
|
|
7922
7922
|
key: action.key,
|
|
7923
|
-
className: `${classPrefix$
|
|
7923
|
+
className: `${classPrefix$1i}-button-item-wrapper`
|
|
7924
7924
|
}, React__default.createElement("a", {
|
|
7925
|
-
className: classNames("adm-plain-anchor", `${classPrefix$
|
|
7926
|
-
[`${classPrefix$
|
|
7927
|
-
[`${classPrefix$
|
|
7928
|
-
[`${classPrefix$
|
|
7925
|
+
className: classNames("adm-plain-anchor", `${classPrefix$1i}-button-item`, {
|
|
7926
|
+
[`${classPrefix$1i}-button-item-danger`]: action.danger,
|
|
7927
|
+
[`${classPrefix$1i}-button-item-disabled`]: action.disabled,
|
|
7928
|
+
[`${classPrefix$1i}-button-item-bold`]: action.bold
|
|
7929
7929
|
}),
|
|
7930
7930
|
onClick: () => {
|
|
7931
7931
|
var _a, _b, _c;
|
|
@@ -7936,21 +7936,21 @@ const ActionSheet = (p) => {
|
|
|
7936
7936
|
}
|
|
7937
7937
|
}
|
|
7938
7938
|
}, React__default.createElement("div", {
|
|
7939
|
-
className: `${classPrefix$
|
|
7939
|
+
className: `${classPrefix$1i}-button-item-name`
|
|
7940
7940
|
}, action.text), action.description && React__default.createElement("div", {
|
|
7941
|
-
className: `${classPrefix$
|
|
7941
|
+
className: `${classPrefix$1i}-button-item-description`
|
|
7942
7942
|
}, action.description))))), props.cancelText && React__default.createElement("div", {
|
|
7943
|
-
className: `${classPrefix$
|
|
7943
|
+
className: `${classPrefix$1i}-cancel`
|
|
7944
7944
|
}, React__default.createElement("div", {
|
|
7945
|
-
className: `${classPrefix$
|
|
7945
|
+
className: `${classPrefix$1i}-button-item-wrapper`
|
|
7946
7946
|
}, React__default.createElement("a", {
|
|
7947
|
-
className: classNames("adm-plain-anchor", `${classPrefix$
|
|
7947
|
+
className: classNames("adm-plain-anchor", `${classPrefix$1i}-button-item`),
|
|
7948
7948
|
onClick: () => {
|
|
7949
7949
|
var _a;
|
|
7950
7950
|
(_a = props.onClose) === null || _a === void 0 ? void 0 : _a.call(props);
|
|
7951
7951
|
}
|
|
7952
7952
|
}, React__default.createElement("div", {
|
|
7953
|
-
className: `${classPrefix$
|
|
7953
|
+
className: `${classPrefix$1i}-button-item-name`
|
|
7954
7954
|
}, props.cancelText)))), props.safeArea && React__default.createElement(SafeArea, {
|
|
7955
7955
|
position: "bottom"
|
|
7956
7956
|
}))));
|
|
@@ -7962,15 +7962,153 @@ const index$j = attachPropertiesToComponent(ActionSheet, {
|
|
|
7962
7962
|
show: showActionSheet
|
|
7963
7963
|
});
|
|
7964
7964
|
const autoCenter = "";
|
|
7965
|
-
const classPrefix$
|
|
7965
|
+
const classPrefix$1h = "adm-auto-center";
|
|
7966
7966
|
const AutoCenter = (props) => {
|
|
7967
7967
|
return withNativeProps(props, React__default.createElement("div", {
|
|
7968
|
-
className: classPrefix$
|
|
7968
|
+
className: classPrefix$1h
|
|
7969
7969
|
}, React__default.createElement("div", {
|
|
7970
|
-
className: `${classPrefix$
|
|
7970
|
+
className: `${classPrefix$1h}-content`
|
|
7971
7971
|
}, props.children)));
|
|
7972
7972
|
};
|
|
7973
7973
|
const avatar = "";
|
|
7974
|
+
const image = "";
|
|
7975
|
+
var stagedComponents = {};
|
|
7976
|
+
var __importDefault = commonjsGlobal && commonjsGlobal.__importDefault || function(mod) {
|
|
7977
|
+
return mod && mod.__esModule ? mod : { "default": mod };
|
|
7978
|
+
};
|
|
7979
|
+
Object.defineProperty(stagedComponents, "__esModule", { value: true });
|
|
7980
|
+
var staged_1 = stagedComponents.staged = void 0;
|
|
7981
|
+
const react_1 = __importDefault(React__default);
|
|
7982
|
+
function processNext(next) {
|
|
7983
|
+
if (typeof next === "function") {
|
|
7984
|
+
return react_1.default.createElement(Stage, { stage: next });
|
|
7985
|
+
} else {
|
|
7986
|
+
return next;
|
|
7987
|
+
}
|
|
7988
|
+
}
|
|
7989
|
+
function Stage(props) {
|
|
7990
|
+
const next = props.stage();
|
|
7991
|
+
return processNext(next);
|
|
7992
|
+
}
|
|
7993
|
+
function staged(stage) {
|
|
7994
|
+
return function Staged(props, ref) {
|
|
7995
|
+
const next = stage(props, ref);
|
|
7996
|
+
return processNext(next);
|
|
7997
|
+
};
|
|
7998
|
+
}
|
|
7999
|
+
staged_1 = stagedComponents.staged = staged;
|
|
8000
|
+
function toCSSLength(val) {
|
|
8001
|
+
return typeof val === "number" ? `${val}px` : val;
|
|
8002
|
+
}
|
|
8003
|
+
const LazyDetector = (props) => {
|
|
8004
|
+
const ref = useRef(null);
|
|
8005
|
+
const [inViewport] = useInViewport(ref);
|
|
8006
|
+
useEffect(() => {
|
|
8007
|
+
if (inViewport) {
|
|
8008
|
+
props.onActive();
|
|
8009
|
+
}
|
|
8010
|
+
}, [inViewport]);
|
|
8011
|
+
return React__default.createElement("div", {
|
|
8012
|
+
ref
|
|
8013
|
+
});
|
|
8014
|
+
};
|
|
8015
|
+
const useIsomorphicUpdateLayoutEffect = createUpdateEffect(useIsomorphicLayoutEffect$1);
|
|
8016
|
+
const ImageIcon = () => React__default.createElement("svg", {
|
|
8017
|
+
viewBox: "0 0 48 48",
|
|
8018
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
8019
|
+
}, React__default.createElement("path", {
|
|
8020
|
+
d: "M41.396 6.234c1.923 0 3.487 1.574 3.487 3.505v29.14c0 1.937-1.568 3.51-3.491 3.51H6.604c-1.923 0-3.487-1.573-3.487-3.51V9.745c0-1.936 1.564-3.51 3.487-3.51Zm0 2.847H6.604c-.355 0-.654.3-.654.658V34.9l5.989-8.707a2.373 2.373 0 0 1 1.801-1.005 2.405 2.405 0 0 1 1.933.752l4.182 4.525 7.58-11.005a2.374 2.374 0 0 1 1.96-1.01c.79 0 1.532.38 1.966 1.01L42.05 34.89V9.74a.664.664 0 0 0-.654-.658Zm-28.305 2.763a3.119 3.119 0 0 1 3.117 3.117 3.119 3.119 0 0 1-3.117 3.117 3.122 3.122 0 0 1-3.117-3.117 3.119 3.119 0 0 1 3.117-3.117Z",
|
|
8021
|
+
fill: "#DBDBDB",
|
|
8022
|
+
fillRule: "nonzero"
|
|
8023
|
+
}));
|
|
8024
|
+
const BrokenImageIcon = () => React__default.createElement("svg", {
|
|
8025
|
+
viewBox: "0 0 48 48",
|
|
8026
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
8027
|
+
}, React__default.createElement("path", {
|
|
8028
|
+
d: "M19.233 6.233 17.42 9.08l-10.817.001a.665.665 0 0 0-.647.562l-.007.096V34.9l5.989-8.707a2.373 2.373 0 0 1 1.801-1.005 2.415 2.415 0 0 1 1.807.625l.126.127 4.182 4.525 2.267-3.292 5.461 7.841-4.065 7.375H6.604c-1.86 0-3.382-1.47-3.482-3.317l-.005-.192V9.744c0-1.872 1.461-3.405 3.296-3.505l.19-.005h12.63Zm22.163 0c1.86 0 3.382 1.472 3.482 3.314l.005.192v29.14a3.507 3.507 0 0 1-3.3 3.505l-.191.006H27.789l3.63-6.587.06-.119a1.87 1.87 0 0 0-.163-1.853l-6.928-9.949 3.047-4.422a2.374 2.374 0 0 1 1.96-1.01 2.4 2.4 0 0 1 1.86.87l.106.14L42.05 34.89V9.74a.664.664 0 0 0-.654-.658H21.855l1.812-2.848h17.73Zm-28.305 5.611c.794 0 1.52.298 2.07.788l-.843 1.325-.067.114a1.87 1.87 0 0 0 .11 1.959l.848 1.217c-.556.515-1.3.83-2.118.83a3.122 3.122 0 0 1-3.117-3.116 3.119 3.119 0 0 1 3.117-3.117Z",
|
|
8029
|
+
fill: "#DBDBDB",
|
|
8030
|
+
fillRule: "nonzero"
|
|
8031
|
+
}));
|
|
8032
|
+
const classPrefix$1g = `adm-image`;
|
|
8033
|
+
const defaultProps$10 = {
|
|
8034
|
+
fit: "fill",
|
|
8035
|
+
placeholder: React__default.createElement("div", {
|
|
8036
|
+
className: `${classPrefix$1g}-tip`
|
|
8037
|
+
}, React__default.createElement(ImageIcon, null)),
|
|
8038
|
+
fallback: React__default.createElement("div", {
|
|
8039
|
+
className: `${classPrefix$1g}-tip`
|
|
8040
|
+
}, React__default.createElement(BrokenImageIcon, null)),
|
|
8041
|
+
lazy: false,
|
|
8042
|
+
draggable: false
|
|
8043
|
+
};
|
|
8044
|
+
const Image$1 = staged_1((p) => {
|
|
8045
|
+
const props = mergeProps(defaultProps$10, p);
|
|
8046
|
+
const [loaded, setLoaded] = useState(false);
|
|
8047
|
+
const [failed, setFailed] = useState(false);
|
|
8048
|
+
const ref = useRef(null);
|
|
8049
|
+
let src = props.src;
|
|
8050
|
+
let srcSet = props.srcSet;
|
|
8051
|
+
const [initialized, setInitialized] = useState(!props.lazy);
|
|
8052
|
+
src = initialized ? props.src : void 0;
|
|
8053
|
+
srcSet = initialized ? props.srcSet : void 0;
|
|
8054
|
+
useIsomorphicUpdateLayoutEffect(() => {
|
|
8055
|
+
setLoaded(false);
|
|
8056
|
+
setFailed(false);
|
|
8057
|
+
}, [src]);
|
|
8058
|
+
function renderInner() {
|
|
8059
|
+
if (failed) {
|
|
8060
|
+
return React__default.createElement(React__default.Fragment, null, props.fallback);
|
|
8061
|
+
}
|
|
8062
|
+
const img = React__default.createElement("img", {
|
|
8063
|
+
className: `${classPrefix$1g}-img`,
|
|
8064
|
+
src,
|
|
8065
|
+
alt: props.alt,
|
|
8066
|
+
onClick: props.onClick,
|
|
8067
|
+
onLoad: (e) => {
|
|
8068
|
+
var _a;
|
|
8069
|
+
setLoaded(true);
|
|
8070
|
+
(_a = props.onLoad) === null || _a === void 0 ? void 0 : _a.call(props, e);
|
|
8071
|
+
},
|
|
8072
|
+
onError: (e) => {
|
|
8073
|
+
var _a;
|
|
8074
|
+
setFailed(true);
|
|
8075
|
+
(_a = props.onError) === null || _a === void 0 ? void 0 : _a.call(props, e);
|
|
8076
|
+
},
|
|
8077
|
+
style: {
|
|
8078
|
+
objectFit: props.fit,
|
|
8079
|
+
display: loaded ? "block" : "none"
|
|
8080
|
+
},
|
|
8081
|
+
crossOrigin: props.crossOrigin,
|
|
8082
|
+
decoding: props.decoding,
|
|
8083
|
+
loading: props.loading,
|
|
8084
|
+
referrerPolicy: props.referrerPolicy,
|
|
8085
|
+
sizes: props.sizes,
|
|
8086
|
+
srcSet,
|
|
8087
|
+
useMap: props.useMap,
|
|
8088
|
+
draggable: props.draggable
|
|
8089
|
+
});
|
|
8090
|
+
return React__default.createElement(React__default.Fragment, null, !loaded && props.placeholder, img);
|
|
8091
|
+
}
|
|
8092
|
+
const style = {};
|
|
8093
|
+
if (props.width) {
|
|
8094
|
+
style["--width"] = toCSSLength(props.width);
|
|
8095
|
+
style["width"] = toCSSLength(props.width);
|
|
8096
|
+
}
|
|
8097
|
+
if (props.height) {
|
|
8098
|
+
style["--height"] = toCSSLength(props.height);
|
|
8099
|
+
style["height"] = toCSSLength(props.height);
|
|
8100
|
+
}
|
|
8101
|
+
return withNativeProps(props, React__default.createElement("div", {
|
|
8102
|
+
ref,
|
|
8103
|
+
className: classPrefix$1g,
|
|
8104
|
+
style,
|
|
8105
|
+
onClick: props.onContainerClick
|
|
8106
|
+
}, props.lazy && !initialized && React__default.createElement(LazyDetector, {
|
|
8107
|
+
onActive: () => {
|
|
8108
|
+
setInitialized(true);
|
|
8109
|
+
}
|
|
8110
|
+
}), renderInner()));
|
|
8111
|
+
});
|
|
7974
8112
|
const Fallback = memo(() => React__default.createElement("svg", {
|
|
7975
8113
|
className: "adm-avatar-fallback",
|
|
7976
8114
|
width: "88px",
|
|
@@ -8295,6 +8433,9 @@ function convertValueToRange(selectionMode, value) {
|
|
|
8295
8433
|
}
|
|
8296
8434
|
return [value, value];
|
|
8297
8435
|
}
|
|
8436
|
+
function convertPageToDayjs(page) {
|
|
8437
|
+
return dayjs().year(page.year).month(page.month - 1).date(1);
|
|
8438
|
+
}
|
|
8298
8439
|
dayjs.extend(isoWeek);
|
|
8299
8440
|
const classPrefix$1b = "adm-calendar";
|
|
8300
8441
|
const defaultProps$Y = {
|
|
@@ -8347,35 +8488,51 @@ const Calendar = forwardRef((p, ref) => {
|
|
|
8347
8488
|
} else {
|
|
8348
8489
|
page = pageOrPageGenerator;
|
|
8349
8490
|
}
|
|
8350
|
-
setCurrent(
|
|
8491
|
+
setCurrent(convertPageToDayjs(page));
|
|
8351
8492
|
},
|
|
8352
8493
|
jumpToToday: () => {
|
|
8353
8494
|
setCurrent(dayjs().date(1));
|
|
8354
8495
|
}
|
|
8355
8496
|
}));
|
|
8497
|
+
const handlePageChange = (action, num, type4) => {
|
|
8498
|
+
const nxtCurrent = current[action](num, type4);
|
|
8499
|
+
if (action === "subtract" && props.minPage) {
|
|
8500
|
+
const minPage = convertPageToDayjs(props.minPage);
|
|
8501
|
+
if (nxtCurrent.isBefore(minPage, type4)) {
|
|
8502
|
+
return;
|
|
8503
|
+
}
|
|
8504
|
+
}
|
|
8505
|
+
if (action === "add" && props.maxPage) {
|
|
8506
|
+
const maxPage = convertPageToDayjs(props.maxPage);
|
|
8507
|
+
if (nxtCurrent.isAfter(maxPage, type4)) {
|
|
8508
|
+
return;
|
|
8509
|
+
}
|
|
8510
|
+
}
|
|
8511
|
+
setCurrent(current[action](num, type4));
|
|
8512
|
+
};
|
|
8356
8513
|
const header = React__default.createElement("div", {
|
|
8357
8514
|
className: `${classPrefix$1b}-header`
|
|
8358
8515
|
}, React__default.createElement("a", {
|
|
8359
8516
|
className: `${classPrefix$1b}-arrow-button ${classPrefix$1b}-arrow-button-year`,
|
|
8360
8517
|
onClick: () => {
|
|
8361
|
-
|
|
8518
|
+
handlePageChange("subtract", 1, "year");
|
|
8362
8519
|
}
|
|
8363
8520
|
}, props.prevYearButton), React__default.createElement("a", {
|
|
8364
8521
|
className: `${classPrefix$1b}-arrow-button ${classPrefix$1b}-arrow-button-month`,
|
|
8365
8522
|
onClick: () => {
|
|
8366
|
-
|
|
8523
|
+
handlePageChange("subtract", 1, "month");
|
|
8367
8524
|
}
|
|
8368
8525
|
}, props.prevMonthButton), React__default.createElement("div", {
|
|
8369
8526
|
className: `${classPrefix$1b}-title`
|
|
8370
8527
|
}, locale.Calendar.renderYearAndMonth(current.year(), current.month() + 1)), React__default.createElement("a", {
|
|
8371
8528
|
className: classNames(`${classPrefix$1b}-arrow-button`, `${classPrefix$1b}-arrow-button-right`, `${classPrefix$1b}-arrow-button-right-month`),
|
|
8372
8529
|
onClick: () => {
|
|
8373
|
-
|
|
8530
|
+
handlePageChange("add", 1, "month");
|
|
8374
8531
|
}
|
|
8375
8532
|
}, props.nextMonthButton), React__default.createElement("a", {
|
|
8376
8533
|
className: classNames(`${classPrefix$1b}-arrow-button`, `${classPrefix$1b}-arrow-button-right`, `${classPrefix$1b}-arrow-button-right-year`),
|
|
8377
8534
|
onClick: () => {
|
|
8378
|
-
|
|
8535
|
+
handlePageChange("add", 1, "year");
|
|
8379
8536
|
}
|
|
8380
8537
|
}, props.nextYearButton));
|
|
8381
8538
|
const maxDay = useMemo(() => props.max && dayjs(props.max), [props.max]);
|
|
@@ -8520,7 +8677,6 @@ function bound(position, min2, max2) {
|
|
|
8520
8677
|
}
|
|
8521
8678
|
return ret;
|
|
8522
8679
|
}
|
|
8523
|
-
const useIsomorphicUpdateLayoutEffect = createUpdateEffect(useIsomorphicLayoutEffect$1);
|
|
8524
8680
|
const useTabListScroll = (targetRef, activeIndex) => {
|
|
8525
8681
|
const [{
|
|
8526
8682
|
scrollLeft
|
|
@@ -10786,7 +10942,7 @@ function devError(component, message) {
|
|
|
10786
10942
|
function measureCSSLength(raw) {
|
|
10787
10943
|
if (raw === null || raw === void 0 || raw === "") {
|
|
10788
10944
|
{
|
|
10789
|
-
devError("Global", "
|
|
10945
|
+
devError("Global", "Something went wrong when calculating CSS length. Please report an issue at https://github.com/ant-design/ant-design-mobile/issues/new/choose");
|
|
10790
10946
|
}
|
|
10791
10947
|
return 0;
|
|
10792
10948
|
}
|
|
@@ -10827,12 +10983,13 @@ const Wheel = memo((props) => {
|
|
|
10827
10983
|
}));
|
|
10828
10984
|
const draggingRef = useRef(false);
|
|
10829
10985
|
const rootRef = useRef(null);
|
|
10986
|
+
const itemHeightMeasureRef = useRef(null);
|
|
10830
10987
|
const itemHeight = useRef(34);
|
|
10831
10988
|
useIsomorphicLayoutEffect$1(() => {
|
|
10832
|
-
const
|
|
10833
|
-
if (!
|
|
10989
|
+
const itemHeightMeasure = itemHeightMeasureRef.current;
|
|
10990
|
+
if (!itemHeightMeasure)
|
|
10834
10991
|
return;
|
|
10835
|
-
itemHeight.current = measureCSSLength(window.getComputedStyle(
|
|
10992
|
+
itemHeight.current = measureCSSLength(window.getComputedStyle(itemHeightMeasure).getPropertyValue("height"));
|
|
10836
10993
|
});
|
|
10837
10994
|
useIsomorphicLayoutEffect$1(() => {
|
|
10838
10995
|
if (draggingRef.current)
|
|
@@ -10948,7 +11105,10 @@ const Wheel = memo((props) => {
|
|
|
10948
11105
|
}
|
|
10949
11106
|
return React__default.createElement("div", {
|
|
10950
11107
|
className: `${classPrefix$17}-column`
|
|
10951
|
-
}, React__default.createElement(
|
|
11108
|
+
}, React__default.createElement("div", {
|
|
11109
|
+
className: `${classPrefix$17}-item-height-measure`,
|
|
11110
|
+
ref: itemHeightMeasureRef
|
|
11111
|
+
}), React__default.createElement(animated.div, {
|
|
10952
11112
|
ref: rootRef,
|
|
10953
11113
|
style: {
|
|
10954
11114
|
translateY: y
|
|
@@ -13125,151 +13285,14 @@ const DialogActionButton = (props) => {
|
|
|
13125
13285
|
disabled: action.disabled
|
|
13126
13286
|
}, action.text));
|
|
13127
13287
|
};
|
|
13128
|
-
const image = "";
|
|
13129
|
-
var stagedComponents = {};
|
|
13130
|
-
var __importDefault = commonjsGlobal && commonjsGlobal.__importDefault || function(mod) {
|
|
13131
|
-
return mod && mod.__esModule ? mod : { "default": mod };
|
|
13132
|
-
};
|
|
13133
|
-
Object.defineProperty(stagedComponents, "__esModule", { value: true });
|
|
13134
|
-
var staged_1 = stagedComponents.staged = void 0;
|
|
13135
|
-
const react_1 = __importDefault(React__default);
|
|
13136
|
-
function processNext(next) {
|
|
13137
|
-
if (typeof next === "function") {
|
|
13138
|
-
return react_1.default.createElement(Stage, { stage: next });
|
|
13139
|
-
} else {
|
|
13140
|
-
return next;
|
|
13141
|
-
}
|
|
13142
|
-
}
|
|
13143
|
-
function Stage(props) {
|
|
13144
|
-
const next = props.stage();
|
|
13145
|
-
return processNext(next);
|
|
13146
|
-
}
|
|
13147
|
-
function staged(stage) {
|
|
13148
|
-
return function Staged(props, ref) {
|
|
13149
|
-
const next = stage(props, ref);
|
|
13150
|
-
return processNext(next);
|
|
13151
|
-
};
|
|
13152
|
-
}
|
|
13153
|
-
staged_1 = stagedComponents.staged = staged;
|
|
13154
|
-
function toCSSLength(val) {
|
|
13155
|
-
return typeof val === "number" ? `${val}px` : val;
|
|
13156
|
-
}
|
|
13157
|
-
const LazyDetector = (props) => {
|
|
13158
|
-
const ref = useRef(null);
|
|
13159
|
-
const [inViewport] = useInViewport(ref);
|
|
13160
|
-
useEffect(() => {
|
|
13161
|
-
if (inViewport) {
|
|
13162
|
-
props.onActive();
|
|
13163
|
-
}
|
|
13164
|
-
}, [inViewport]);
|
|
13165
|
-
return React__default.createElement("div", {
|
|
13166
|
-
ref
|
|
13167
|
-
});
|
|
13168
|
-
};
|
|
13169
|
-
const ImageIcon = () => React__default.createElement("svg", {
|
|
13170
|
-
viewBox: "0 0 48 48",
|
|
13171
|
-
xmlns: "http://www.w3.org/2000/svg"
|
|
13172
|
-
}, React__default.createElement("path", {
|
|
13173
|
-
d: "M41.396 6.234c1.923 0 3.487 1.574 3.487 3.505v29.14c0 1.937-1.568 3.51-3.491 3.51H6.604c-1.923 0-3.487-1.573-3.487-3.51V9.745c0-1.936 1.564-3.51 3.487-3.51Zm0 2.847H6.604c-.355 0-.654.3-.654.658V34.9l5.989-8.707a2.373 2.373 0 0 1 1.801-1.005 2.405 2.405 0 0 1 1.933.752l4.182 4.525 7.58-11.005a2.374 2.374 0 0 1 1.96-1.01c.79 0 1.532.38 1.966 1.01L42.05 34.89V9.74a.664.664 0 0 0-.654-.658Zm-28.305 2.763a3.119 3.119 0 0 1 3.117 3.117 3.119 3.119 0 0 1-3.117 3.117 3.122 3.122 0 0 1-3.117-3.117 3.119 3.119 0 0 1 3.117-3.117Z",
|
|
13174
|
-
fill: "#DBDBDB",
|
|
13175
|
-
fillRule: "nonzero"
|
|
13176
|
-
}));
|
|
13177
|
-
const BrokenImageIcon = () => React__default.createElement("svg", {
|
|
13178
|
-
viewBox: "0 0 48 48",
|
|
13179
|
-
xmlns: "http://www.w3.org/2000/svg"
|
|
13180
|
-
}, React__default.createElement("path", {
|
|
13181
|
-
d: "M19.233 6.233 17.42 9.08l-10.817.001a.665.665 0 0 0-.647.562l-.007.096V34.9l5.989-8.707a2.373 2.373 0 0 1 1.801-1.005 2.415 2.415 0 0 1 1.807.625l.126.127 4.182 4.525 2.267-3.292 5.461 7.841-4.065 7.375H6.604c-1.86 0-3.382-1.47-3.482-3.317l-.005-.192V9.744c0-1.872 1.461-3.405 3.296-3.505l.19-.005h12.63Zm22.163 0c1.86 0 3.382 1.472 3.482 3.314l.005.192v29.14a3.507 3.507 0 0 1-3.3 3.505l-.191.006H27.789l3.63-6.587.06-.119a1.87 1.87 0 0 0-.163-1.853l-6.928-9.949 3.047-4.422a2.374 2.374 0 0 1 1.96-1.01 2.4 2.4 0 0 1 1.86.87l.106.14L42.05 34.89V9.74a.664.664 0 0 0-.654-.658H21.855l1.812-2.848h17.73Zm-28.305 5.611c.794 0 1.52.298 2.07.788l-.843 1.325-.067.114a1.87 1.87 0 0 0 .11 1.959l.848 1.217c-.556.515-1.3.83-2.118.83a3.122 3.122 0 0 1-3.117-3.116 3.119 3.119 0 0 1 3.117-3.117Z",
|
|
13182
|
-
fill: "#DBDBDB",
|
|
13183
|
-
fillRule: "nonzero"
|
|
13184
|
-
}));
|
|
13185
|
-
const classPrefix$V = `adm-image`;
|
|
13186
13288
|
const defaultProps$K = {
|
|
13187
|
-
fit: "fill",
|
|
13188
|
-
placeholder: React__default.createElement("div", {
|
|
13189
|
-
className: `${classPrefix$V}-tip`
|
|
13190
|
-
}, React__default.createElement(ImageIcon, null)),
|
|
13191
|
-
fallback: React__default.createElement("div", {
|
|
13192
|
-
className: `${classPrefix$V}-tip`
|
|
13193
|
-
}, React__default.createElement(BrokenImageIcon, null)),
|
|
13194
|
-
lazy: false,
|
|
13195
|
-
draggable: false
|
|
13196
|
-
};
|
|
13197
|
-
const Image$1 = staged_1((p) => {
|
|
13198
|
-
const props = mergeProps(defaultProps$K, p);
|
|
13199
|
-
const [loaded, setLoaded] = useState(false);
|
|
13200
|
-
const [failed, setFailed] = useState(false);
|
|
13201
|
-
const ref = useRef(null);
|
|
13202
|
-
let src = props.src;
|
|
13203
|
-
let srcSet = props.srcSet;
|
|
13204
|
-
const [initialized, setInitialized] = useState(!props.lazy);
|
|
13205
|
-
src = initialized ? props.src : void 0;
|
|
13206
|
-
srcSet = initialized ? props.srcSet : void 0;
|
|
13207
|
-
useIsomorphicUpdateLayoutEffect(() => {
|
|
13208
|
-
setLoaded(false);
|
|
13209
|
-
setFailed(false);
|
|
13210
|
-
}, [src]);
|
|
13211
|
-
function renderInner() {
|
|
13212
|
-
if (failed) {
|
|
13213
|
-
return React__default.createElement(React__default.Fragment, null, props.fallback);
|
|
13214
|
-
}
|
|
13215
|
-
const img = React__default.createElement("img", {
|
|
13216
|
-
className: `${classPrefix$V}-img`,
|
|
13217
|
-
src,
|
|
13218
|
-
alt: props.alt,
|
|
13219
|
-
onClick: props.onClick,
|
|
13220
|
-
onLoad: (e) => {
|
|
13221
|
-
var _a;
|
|
13222
|
-
setLoaded(true);
|
|
13223
|
-
(_a = props.onLoad) === null || _a === void 0 ? void 0 : _a.call(props, e);
|
|
13224
|
-
},
|
|
13225
|
-
onError: (e) => {
|
|
13226
|
-
var _a;
|
|
13227
|
-
setFailed(true);
|
|
13228
|
-
(_a = props.onError) === null || _a === void 0 ? void 0 : _a.call(props, e);
|
|
13229
|
-
},
|
|
13230
|
-
style: {
|
|
13231
|
-
objectFit: props.fit,
|
|
13232
|
-
display: loaded ? "block" : "none"
|
|
13233
|
-
},
|
|
13234
|
-
crossOrigin: props.crossOrigin,
|
|
13235
|
-
decoding: props.decoding,
|
|
13236
|
-
loading: props.loading,
|
|
13237
|
-
referrerPolicy: props.referrerPolicy,
|
|
13238
|
-
sizes: props.sizes,
|
|
13239
|
-
srcSet,
|
|
13240
|
-
useMap: props.useMap,
|
|
13241
|
-
draggable: props.draggable
|
|
13242
|
-
});
|
|
13243
|
-
return React__default.createElement(React__default.Fragment, null, !loaded && props.placeholder, img);
|
|
13244
|
-
}
|
|
13245
|
-
const style = {};
|
|
13246
|
-
if (props.width) {
|
|
13247
|
-
style["--width"] = toCSSLength(props.width);
|
|
13248
|
-
style["width"] = toCSSLength(props.width);
|
|
13249
|
-
}
|
|
13250
|
-
if (props.height) {
|
|
13251
|
-
style["--height"] = toCSSLength(props.height);
|
|
13252
|
-
style["height"] = toCSSLength(props.height);
|
|
13253
|
-
}
|
|
13254
|
-
return withNativeProps(props, React__default.createElement("div", {
|
|
13255
|
-
ref,
|
|
13256
|
-
className: classPrefix$V,
|
|
13257
|
-
style,
|
|
13258
|
-
onClick: props.onContainerClick
|
|
13259
|
-
}, props.lazy && !initialized && React__default.createElement(LazyDetector, {
|
|
13260
|
-
onActive: () => {
|
|
13261
|
-
setInitialized(true);
|
|
13262
|
-
}
|
|
13263
|
-
}), renderInner()));
|
|
13264
|
-
});
|
|
13265
|
-
const defaultProps$J = {
|
|
13266
13289
|
actions: [],
|
|
13267
13290
|
closeOnAction: false,
|
|
13268
13291
|
closeOnMaskClick: false,
|
|
13269
13292
|
getContainer: null
|
|
13270
13293
|
};
|
|
13271
13294
|
const Dialog = (p) => {
|
|
13272
|
-
const props = mergeProps(defaultProps$
|
|
13295
|
+
const props = mergeProps(defaultProps$K, p);
|
|
13273
13296
|
const element = React__default.createElement(React__default.Fragment, null, !!props.image && React__default.createElement("div", {
|
|
13274
13297
|
className: cls$1("image-container")
|
|
13275
13298
|
}, React__default.createElement(Image$1, {
|
|
@@ -13360,7 +13383,7 @@ function alert$1(p) {
|
|
|
13360
13383
|
}));
|
|
13361
13384
|
});
|
|
13362
13385
|
}
|
|
13363
|
-
const defaultProps$
|
|
13386
|
+
const defaultProps$J = {
|
|
13364
13387
|
confirmText: "\u786E\u8BA4",
|
|
13365
13388
|
cancelText: "\u53D6\u6D88"
|
|
13366
13389
|
};
|
|
@@ -13368,7 +13391,7 @@ function confirm$1(p) {
|
|
|
13368
13391
|
const {
|
|
13369
13392
|
locale
|
|
13370
13393
|
} = getDefaultConfig();
|
|
13371
|
-
const props = mergeProps(defaultProps$
|
|
13394
|
+
const props = mergeProps(defaultProps$J, {
|
|
13372
13395
|
confirmText: locale.common.confirm,
|
|
13373
13396
|
cancelText: locale.common.cancel
|
|
13374
13397
|
}, p);
|
|
@@ -13413,37 +13436,37 @@ const index$d = attachPropertiesToComponent(Dialog, {
|
|
|
13413
13436
|
clear: clear$2
|
|
13414
13437
|
});
|
|
13415
13438
|
const divider = "";
|
|
13416
|
-
const classPrefix$
|
|
13417
|
-
const defaultProps$
|
|
13439
|
+
const classPrefix$V = `adm-divider`;
|
|
13440
|
+
const defaultProps$I = {
|
|
13418
13441
|
contentPosition: "center",
|
|
13419
13442
|
direction: "horizontal"
|
|
13420
13443
|
};
|
|
13421
13444
|
const Divider = (p) => {
|
|
13422
|
-
const props = mergeProps(defaultProps$
|
|
13445
|
+
const props = mergeProps(defaultProps$I, p);
|
|
13423
13446
|
return withNativeProps(props, React__default.createElement("div", {
|
|
13424
|
-
className: classNames(classPrefix$
|
|
13447
|
+
className: classNames(classPrefix$V, `${classPrefix$V}-${props.direction}`, `${classPrefix$V}-${props.contentPosition}`)
|
|
13425
13448
|
}, props.children && React__default.createElement("div", {
|
|
13426
|
-
className: `${classPrefix$
|
|
13449
|
+
className: `${classPrefix$V}-content`
|
|
13427
13450
|
}, props.children)));
|
|
13428
13451
|
};
|
|
13429
13452
|
const dropdown = "";
|
|
13430
|
-
const classPrefix$
|
|
13453
|
+
const classPrefix$U = `adm-dropdown-item`;
|
|
13431
13454
|
const Item = (props) => {
|
|
13432
13455
|
var _a;
|
|
13433
|
-
const cls2 = classNames(classPrefix$
|
|
13434
|
-
[`${classPrefix$
|
|
13435
|
-
[`${classPrefix$
|
|
13456
|
+
const cls2 = classNames(classPrefix$U, {
|
|
13457
|
+
[`${classPrefix$U}-active`]: props.active,
|
|
13458
|
+
[`${classPrefix$U}-highlight`]: (_a = props.highlight) !== null && _a !== void 0 ? _a : props.active
|
|
13436
13459
|
});
|
|
13437
13460
|
return withNativeProps(props, React__default.createElement("div", {
|
|
13438
13461
|
className: cls2,
|
|
13439
13462
|
onClick: props.onClick
|
|
13440
13463
|
}, React__default.createElement("div", {
|
|
13441
|
-
className: `${classPrefix$
|
|
13464
|
+
className: `${classPrefix$U}-title`
|
|
13442
13465
|
}, React__default.createElement("span", {
|
|
13443
|
-
className: `${classPrefix$
|
|
13466
|
+
className: `${classPrefix$U}-title-text`
|
|
13444
13467
|
}, props.title), React__default.createElement("span", {
|
|
13445
|
-
className: classNames(`${classPrefix$
|
|
13446
|
-
[`${classPrefix$
|
|
13468
|
+
className: classNames(`${classPrefix$U}-title-arrow`, {
|
|
13469
|
+
[`${classPrefix$U}-title-arrow-active`]: props.active
|
|
13447
13470
|
})
|
|
13448
13471
|
}, props.arrow === void 0 ? React__default.createElement(DownFill, null) : props.arrow))));
|
|
13449
13472
|
};
|
|
@@ -13452,22 +13475,22 @@ const ItemChildrenWrap = (props) => {
|
|
|
13452
13475
|
active = false
|
|
13453
13476
|
} = props;
|
|
13454
13477
|
const shouldRender = useShouldRender(active, props.forceRender, props.destroyOnClose);
|
|
13455
|
-
const cls2 = classNames(`${classPrefix$
|
|
13456
|
-
[`${classPrefix$
|
|
13478
|
+
const cls2 = classNames(`${classPrefix$U}-content`, {
|
|
13479
|
+
[`${classPrefix$U}-content-hidden`]: !active
|
|
13457
13480
|
});
|
|
13458
13481
|
return shouldRender ? React__default.createElement("div", {
|
|
13459
13482
|
className: cls2,
|
|
13460
13483
|
onClick: props.onClick
|
|
13461
13484
|
}, props.children) : null;
|
|
13462
13485
|
};
|
|
13463
|
-
const classPrefix$
|
|
13464
|
-
const defaultProps$
|
|
13486
|
+
const classPrefix$T = `adm-dropdown`;
|
|
13487
|
+
const defaultProps$H = {
|
|
13465
13488
|
defaultActiveKey: null,
|
|
13466
13489
|
closeOnMaskClick: true,
|
|
13467
13490
|
closeOnClickAway: false
|
|
13468
13491
|
};
|
|
13469
13492
|
const Dropdown = forwardRef((p, ref) => {
|
|
13470
|
-
const props = mergeProps(defaultProps$
|
|
13493
|
+
const props = mergeProps(defaultProps$H, p);
|
|
13471
13494
|
const [value, setValue2] = usePropsValue({
|
|
13472
13495
|
value: props.activeKey,
|
|
13473
13496
|
defaultValue: props.defaultActiveKey,
|
|
@@ -13523,19 +13546,19 @@ const Dropdown = forwardRef((p, ref) => {
|
|
|
13523
13546
|
}
|
|
13524
13547
|
}), [setValue2]);
|
|
13525
13548
|
return withNativeProps(props, React__default.createElement("div", {
|
|
13526
|
-
className: classNames(classPrefix$
|
|
13527
|
-
[`${classPrefix$
|
|
13549
|
+
className: classNames(classPrefix$T, {
|
|
13550
|
+
[`${classPrefix$T}-open`]: !!value
|
|
13528
13551
|
}),
|
|
13529
13552
|
ref: containerRef
|
|
13530
13553
|
}, React__default.createElement("div", {
|
|
13531
|
-
className: `${classPrefix$
|
|
13554
|
+
className: `${classPrefix$T}-nav`,
|
|
13532
13555
|
ref: navRef
|
|
13533
13556
|
}, navs), React__default.createElement(Popup, {
|
|
13534
13557
|
visible: !!value,
|
|
13535
13558
|
position: "top",
|
|
13536
|
-
className: `${classPrefix$
|
|
13537
|
-
maskClassName: `${classPrefix$
|
|
13538
|
-
bodyClassName: `${classPrefix$
|
|
13559
|
+
className: `${classPrefix$T}-popup`,
|
|
13560
|
+
maskClassName: `${classPrefix$T}-popup-mask`,
|
|
13561
|
+
bodyClassName: `${classPrefix$T}-popup-body`,
|
|
13539
13562
|
style: {
|
|
13540
13563
|
top
|
|
13541
13564
|
},
|
|
@@ -13559,8 +13582,128 @@ const index$c = attachPropertiesToComponent(Dropdown, {
|
|
|
13559
13582
|
Item
|
|
13560
13583
|
});
|
|
13561
13584
|
const ellipsis = "";
|
|
13562
|
-
|
|
13563
|
-
const
|
|
13585
|
+
var runes$1 = { exports: {} };
|
|
13586
|
+
const HIGH_SURROGATE_START = 55296;
|
|
13587
|
+
const HIGH_SURROGATE_END = 56319;
|
|
13588
|
+
const LOW_SURROGATE_START = 56320;
|
|
13589
|
+
const REGIONAL_INDICATOR_START = 127462;
|
|
13590
|
+
const REGIONAL_INDICATOR_END = 127487;
|
|
13591
|
+
const FITZPATRICK_MODIFIER_START = 127995;
|
|
13592
|
+
const FITZPATRICK_MODIFIER_END = 127999;
|
|
13593
|
+
const VARIATION_MODIFIER_START = 65024;
|
|
13594
|
+
const VARIATION_MODIFIER_END = 65039;
|
|
13595
|
+
const DIACRITICAL_MARKS_START = 8400;
|
|
13596
|
+
const DIACRITICAL_MARKS_END = 8447;
|
|
13597
|
+
const ZWJ = 8205;
|
|
13598
|
+
const GRAPHEMS = [
|
|
13599
|
+
776,
|
|
13600
|
+
2359,
|
|
13601
|
+
2359,
|
|
13602
|
+
2367,
|
|
13603
|
+
2367,
|
|
13604
|
+
2984,
|
|
13605
|
+
3007,
|
|
13606
|
+
3021,
|
|
13607
|
+
3633,
|
|
13608
|
+
3635,
|
|
13609
|
+
3648,
|
|
13610
|
+
3657,
|
|
13611
|
+
4352,
|
|
13612
|
+
4449,
|
|
13613
|
+
4520
|
|
13614
|
+
];
|
|
13615
|
+
function runes(string3) {
|
|
13616
|
+
if (typeof string3 !== "string") {
|
|
13617
|
+
throw new Error("string cannot be undefined or null");
|
|
13618
|
+
}
|
|
13619
|
+
const result2 = [];
|
|
13620
|
+
let i = 0;
|
|
13621
|
+
let increment = 0;
|
|
13622
|
+
while (i < string3.length) {
|
|
13623
|
+
increment += nextUnits(i + increment, string3);
|
|
13624
|
+
if (isGraphem(string3[i + increment])) {
|
|
13625
|
+
increment++;
|
|
13626
|
+
}
|
|
13627
|
+
if (isVariationSelector(string3[i + increment])) {
|
|
13628
|
+
increment++;
|
|
13629
|
+
}
|
|
13630
|
+
if (isDiacriticalMark(string3[i + increment])) {
|
|
13631
|
+
increment++;
|
|
13632
|
+
}
|
|
13633
|
+
if (isZeroWidthJoiner(string3[i + increment])) {
|
|
13634
|
+
increment++;
|
|
13635
|
+
continue;
|
|
13636
|
+
}
|
|
13637
|
+
result2.push(string3.substring(i, i + increment));
|
|
13638
|
+
i += increment;
|
|
13639
|
+
increment = 0;
|
|
13640
|
+
}
|
|
13641
|
+
return result2;
|
|
13642
|
+
}
|
|
13643
|
+
function nextUnits(i, string3) {
|
|
13644
|
+
const current = string3[i];
|
|
13645
|
+
if (!isFirstOfSurrogatePair(current) || i === string3.length - 1) {
|
|
13646
|
+
return 1;
|
|
13647
|
+
}
|
|
13648
|
+
const currentPair = current + string3[i + 1];
|
|
13649
|
+
let nextPair = string3.substring(i + 2, i + 5);
|
|
13650
|
+
if (isRegionalIndicator(currentPair) && isRegionalIndicator(nextPair)) {
|
|
13651
|
+
return 4;
|
|
13652
|
+
}
|
|
13653
|
+
if (isFitzpatrickModifier(nextPair)) {
|
|
13654
|
+
return 4;
|
|
13655
|
+
}
|
|
13656
|
+
return 2;
|
|
13657
|
+
}
|
|
13658
|
+
function isFirstOfSurrogatePair(string3) {
|
|
13659
|
+
return string3 && betweenInclusive(string3[0].charCodeAt(0), HIGH_SURROGATE_START, HIGH_SURROGATE_END);
|
|
13660
|
+
}
|
|
13661
|
+
function isRegionalIndicator(string3) {
|
|
13662
|
+
return betweenInclusive(codePointFromSurrogatePair(string3), REGIONAL_INDICATOR_START, REGIONAL_INDICATOR_END);
|
|
13663
|
+
}
|
|
13664
|
+
function isFitzpatrickModifier(string3) {
|
|
13665
|
+
return betweenInclusive(codePointFromSurrogatePair(string3), FITZPATRICK_MODIFIER_START, FITZPATRICK_MODIFIER_END);
|
|
13666
|
+
}
|
|
13667
|
+
function isVariationSelector(string3) {
|
|
13668
|
+
return typeof string3 === "string" && betweenInclusive(string3.charCodeAt(0), VARIATION_MODIFIER_START, VARIATION_MODIFIER_END);
|
|
13669
|
+
}
|
|
13670
|
+
function isDiacriticalMark(string3) {
|
|
13671
|
+
return typeof string3 === "string" && betweenInclusive(string3.charCodeAt(0), DIACRITICAL_MARKS_START, DIACRITICAL_MARKS_END);
|
|
13672
|
+
}
|
|
13673
|
+
function isGraphem(string3) {
|
|
13674
|
+
return typeof string3 === "string" && GRAPHEMS.indexOf(string3.charCodeAt(0)) !== -1;
|
|
13675
|
+
}
|
|
13676
|
+
function isZeroWidthJoiner(string3) {
|
|
13677
|
+
return typeof string3 === "string" && string3.charCodeAt(0) === ZWJ;
|
|
13678
|
+
}
|
|
13679
|
+
function codePointFromSurrogatePair(pair) {
|
|
13680
|
+
const highOffset = pair.charCodeAt(0) - HIGH_SURROGATE_START;
|
|
13681
|
+
const lowOffset = pair.charCodeAt(1) - LOW_SURROGATE_START;
|
|
13682
|
+
return (highOffset << 10) + lowOffset + 65536;
|
|
13683
|
+
}
|
|
13684
|
+
function betweenInclusive(value, lower, upper) {
|
|
13685
|
+
return value >= lower && value <= upper;
|
|
13686
|
+
}
|
|
13687
|
+
function substring(string3, start2, width) {
|
|
13688
|
+
const chars = runes(string3);
|
|
13689
|
+
if (start2 === void 0) {
|
|
13690
|
+
return string3;
|
|
13691
|
+
}
|
|
13692
|
+
if (start2 >= chars.length) {
|
|
13693
|
+
return "";
|
|
13694
|
+
}
|
|
13695
|
+
const rest = chars.length - start2;
|
|
13696
|
+
const stringWidth = width === void 0 ? rest : width;
|
|
13697
|
+
let endIndex = start2 + stringWidth;
|
|
13698
|
+
if (endIndex > start2 + rest) {
|
|
13699
|
+
endIndex = void 0;
|
|
13700
|
+
}
|
|
13701
|
+
return chars.slice(start2, endIndex).join("");
|
|
13702
|
+
}
|
|
13703
|
+
runes$1.exports = runes;
|
|
13704
|
+
runes$1.exports.substr = substring;
|
|
13705
|
+
const classPrefix$S = `adm-ellipsis`;
|
|
13706
|
+
const defaultProps$G = {
|
|
13564
13707
|
direction: "end",
|
|
13565
13708
|
rows: 1,
|
|
13566
13709
|
expandText: "",
|
|
@@ -13570,11 +13713,15 @@ const defaultProps$F = {
|
|
|
13570
13713
|
}
|
|
13571
13714
|
};
|
|
13572
13715
|
const Ellipsis = (p) => {
|
|
13573
|
-
const props = mergeProps(defaultProps$
|
|
13716
|
+
const props = mergeProps(defaultProps$G, p);
|
|
13574
13717
|
const rootRef = useRef(null);
|
|
13575
13718
|
const [ellipsised, setEllipsised] = useState({});
|
|
13576
13719
|
const [expanded, setExpanded] = useState(false);
|
|
13577
13720
|
const [exceeded, setExceeded] = useState(false);
|
|
13721
|
+
const chars = useMemo(() => runes$1.exports(props.content), [props.content]);
|
|
13722
|
+
function getSubString(start2, end) {
|
|
13723
|
+
return chars.slice(start2, end).join("");
|
|
13724
|
+
}
|
|
13578
13725
|
function calcEllipsised() {
|
|
13579
13726
|
const root2 = rootRef.current;
|
|
13580
13727
|
if (!root2)
|
|
@@ -13609,19 +13756,19 @@ const Ellipsis = (p) => {
|
|
|
13609
13756
|
if (right - left <= 1) {
|
|
13610
13757
|
if (props.direction === "end") {
|
|
13611
13758
|
return {
|
|
13612
|
-
leading:
|
|
13759
|
+
leading: getSubString(0, left) + "..."
|
|
13613
13760
|
};
|
|
13614
13761
|
} else {
|
|
13615
13762
|
return {
|
|
13616
|
-
tailing: "..." +
|
|
13763
|
+
tailing: "..." + getSubString(right, end)
|
|
13617
13764
|
};
|
|
13618
13765
|
}
|
|
13619
13766
|
}
|
|
13620
13767
|
const middle2 = Math.round((left + right) / 2);
|
|
13621
13768
|
if (props.direction === "end") {
|
|
13622
|
-
container.innerText =
|
|
13769
|
+
container.innerText = getSubString(0, middle2) + "..." + actionText;
|
|
13623
13770
|
} else {
|
|
13624
|
-
container.innerText = actionText + "..." +
|
|
13771
|
+
container.innerText = actionText + "..." + getSubString(middle2, end);
|
|
13625
13772
|
}
|
|
13626
13773
|
if (container.offsetHeight <= maxHeight) {
|
|
13627
13774
|
if (props.direction === "end") {
|
|
@@ -13639,13 +13786,13 @@ const Ellipsis = (p) => {
|
|
|
13639
13786
|
}, checkMiddle = function(leftPart, rightPart) {
|
|
13640
13787
|
if (leftPart[1] - leftPart[0] <= 1 && rightPart[1] - rightPart[0] <= 1) {
|
|
13641
13788
|
return {
|
|
13642
|
-
leading:
|
|
13643
|
-
tailing: "..." +
|
|
13789
|
+
leading: getSubString(0, leftPart[0]) + "...",
|
|
13790
|
+
tailing: "..." + getSubString(rightPart[1], end)
|
|
13644
13791
|
};
|
|
13645
13792
|
}
|
|
13646
13793
|
const leftPartMiddle = Math.floor((leftPart[0] + leftPart[1]) / 2);
|
|
13647
13794
|
const rightPartMiddle = Math.ceil((rightPart[0] + rightPart[1]) / 2);
|
|
13648
|
-
container.innerText =
|
|
13795
|
+
container.innerText = getSubString(0, leftPartMiddle) + "..." + actionText + "..." + getSubString(rightPartMiddle, end);
|
|
13649
13796
|
if (container.offsetHeight <= maxHeight) {
|
|
13650
13797
|
return checkMiddle([leftPartMiddle, leftPart[1]], [rightPart[0], rightPartMiddle]);
|
|
13651
13798
|
} else {
|
|
@@ -13687,7 +13834,7 @@ const Ellipsis = (p) => {
|
|
|
13687
13834
|
};
|
|
13688
13835
|
return withNativeProps(props, React__default.createElement("div", {
|
|
13689
13836
|
ref: rootRef,
|
|
13690
|
-
className: classPrefix$
|
|
13837
|
+
className: classPrefix$S,
|
|
13691
13838
|
onClick: (e) => {
|
|
13692
13839
|
if (e.target === e.currentTarget) {
|
|
13693
13840
|
props.onContentClick(e);
|
|
@@ -13724,7 +13871,7 @@ const EmptyIcon = (props) => {
|
|
|
13724
13871
|
fill: "#fafafa"
|
|
13725
13872
|
})))));
|
|
13726
13873
|
};
|
|
13727
|
-
const classPrefix$
|
|
13874
|
+
const classPrefix$R = `adm-empty`;
|
|
13728
13875
|
const Empty = (props) => {
|
|
13729
13876
|
function renderImageNode() {
|
|
13730
13877
|
const {
|
|
@@ -13732,13 +13879,13 @@ const Empty = (props) => {
|
|
|
13732
13879
|
} = props;
|
|
13733
13880
|
if (image2 === void 0) {
|
|
13734
13881
|
return React__default.createElement(EmptyIcon, {
|
|
13735
|
-
className: `${classPrefix$
|
|
13882
|
+
className: `${classPrefix$R}-image`,
|
|
13736
13883
|
style: props.imageStyle
|
|
13737
13884
|
});
|
|
13738
13885
|
}
|
|
13739
13886
|
if (typeof image2 === "string") {
|
|
13740
13887
|
return React__default.createElement("img", {
|
|
13741
|
-
className: `${classPrefix$
|
|
13888
|
+
className: `${classPrefix$R}-image`,
|
|
13742
13889
|
style: props.imageStyle,
|
|
13743
13890
|
src: image2,
|
|
13744
13891
|
alt: "empty"
|
|
@@ -13747,22 +13894,22 @@ const Empty = (props) => {
|
|
|
13747
13894
|
return image2;
|
|
13748
13895
|
}
|
|
13749
13896
|
return withNativeProps(props, React__default.createElement("div", {
|
|
13750
|
-
className: classPrefix$
|
|
13897
|
+
className: classPrefix$R
|
|
13751
13898
|
}, React__default.createElement("div", {
|
|
13752
|
-
className: `${classPrefix$
|
|
13899
|
+
className: `${classPrefix$R}-image-container`
|
|
13753
13900
|
}, renderImageNode()), props.description && React__default.createElement("div", {
|
|
13754
|
-
className: classNames(`${classPrefix$
|
|
13901
|
+
className: classNames(`${classPrefix$R}-description`)
|
|
13755
13902
|
}, props.description)));
|
|
13756
13903
|
};
|
|
13757
13904
|
const errorBlock = "";
|
|
13758
|
-
const classPrefix$
|
|
13759
|
-
const defaultProps$
|
|
13905
|
+
const classPrefix$Q = `adm-error-block`;
|
|
13906
|
+
const defaultProps$F = {
|
|
13760
13907
|
status: "default"
|
|
13761
13908
|
};
|
|
13762
13909
|
function createErrorBlock(imageRecord2) {
|
|
13763
13910
|
const ErrorBlock2 = (p) => {
|
|
13764
13911
|
var _a;
|
|
13765
|
-
const props = mergeProps(defaultProps$
|
|
13912
|
+
const props = mergeProps(defaultProps$F, p);
|
|
13766
13913
|
const {
|
|
13767
13914
|
locale
|
|
13768
13915
|
} = useConfig();
|
|
@@ -13775,19 +13922,19 @@ function createErrorBlock(imageRecord2) {
|
|
|
13775
13922
|
alt: "error block image"
|
|
13776
13923
|
}) : image2;
|
|
13777
13924
|
return withNativeProps(props, React__default.createElement("div", {
|
|
13778
|
-
className: classNames(classPrefix$
|
|
13779
|
-
[`${classPrefix$
|
|
13925
|
+
className: classNames(classPrefix$Q, {
|
|
13926
|
+
[`${classPrefix$Q}-full-page`]: props.fullPage
|
|
13780
13927
|
})
|
|
13781
13928
|
}, React__default.createElement("div", {
|
|
13782
|
-
className: `${classPrefix$
|
|
13929
|
+
className: `${classPrefix$Q}-image`
|
|
13783
13930
|
}, imageNode), React__default.createElement("div", {
|
|
13784
|
-
className: `${classPrefix$
|
|
13931
|
+
className: `${classPrefix$Q}-description`
|
|
13785
13932
|
}, title && React__default.createElement("div", {
|
|
13786
|
-
className: `${classPrefix$
|
|
13933
|
+
className: `${classPrefix$Q}-description-title`
|
|
13787
13934
|
}, title), des && React__default.createElement("div", {
|
|
13788
|
-
className: `${classPrefix$
|
|
13935
|
+
className: `${classPrefix$Q}-description-subtitle`
|
|
13789
13936
|
}, des)), props.children && React__default.createElement("div", {
|
|
13790
|
-
className: `${classPrefix$
|
|
13937
|
+
className: `${classPrefix$Q}-content`
|
|
13791
13938
|
}, props.children)));
|
|
13792
13939
|
};
|
|
13793
13940
|
return ErrorBlock2;
|
|
@@ -14294,12 +14441,12 @@ const imageRecord = {
|
|
|
14294
14441
|
};
|
|
14295
14442
|
const ErrorBlock = createErrorBlock(imageRecord);
|
|
14296
14443
|
const floatingBubble = "";
|
|
14297
|
-
const classPrefix$
|
|
14298
|
-
const defaultProps$
|
|
14444
|
+
const classPrefix$P = `adm-floating-bubble`;
|
|
14445
|
+
const defaultProps$E = {
|
|
14299
14446
|
axis: "y"
|
|
14300
14447
|
};
|
|
14301
14448
|
const FloatingBubble = (p) => {
|
|
14302
|
-
const props = mergeProps(defaultProps$
|
|
14449
|
+
const props = mergeProps(defaultProps$E, p);
|
|
14303
14450
|
const boundaryRef = useRef(null);
|
|
14304
14451
|
const buttonRef = useRef(null);
|
|
14305
14452
|
const [{
|
|
@@ -14358,11 +14505,11 @@ const FloatingBubble = (p) => {
|
|
|
14358
14505
|
from: () => [x.get(), y.get()]
|
|
14359
14506
|
});
|
|
14360
14507
|
return withNativeProps(props, React__default.createElement("div", {
|
|
14361
|
-
className: classPrefix$
|
|
14508
|
+
className: classPrefix$P
|
|
14362
14509
|
}, React__default.createElement("div", {
|
|
14363
|
-
className: `${classPrefix$
|
|
14510
|
+
className: `${classPrefix$P}-boundary-outer`
|
|
14364
14511
|
}, React__default.createElement("div", {
|
|
14365
|
-
className: `${classPrefix$
|
|
14512
|
+
className: `${classPrefix$P}-boundary`,
|
|
14366
14513
|
ref: boundaryRef
|
|
14367
14514
|
})), React__default.createElement(animated.div, Object.assign({}, bind(), {
|
|
14368
14515
|
style: {
|
|
@@ -14370,7 +14517,7 @@ const FloatingBubble = (p) => {
|
|
|
14370
14517
|
transform: to([x, y], (x2, y2) => `translate(${x2}px, ${y2}px)`)
|
|
14371
14518
|
},
|
|
14372
14519
|
onClick: props.onClick,
|
|
14373
|
-
className: `${classPrefix$
|
|
14520
|
+
className: `${classPrefix$P}-button`,
|
|
14374
14521
|
ref: buttonRef
|
|
14375
14522
|
}), props.children)));
|
|
14376
14523
|
};
|
|
@@ -14380,12 +14527,12 @@ function nearest(arr, target) {
|
|
|
14380
14527
|
return Math.abs(pre - target) < Math.abs(cur - target) ? pre : cur;
|
|
14381
14528
|
});
|
|
14382
14529
|
}
|
|
14383
|
-
const defaultProps$
|
|
14530
|
+
const defaultProps$D = {
|
|
14384
14531
|
handleDraggingOfContent: true
|
|
14385
14532
|
};
|
|
14386
14533
|
const FloatingPanel = forwardRef((p, ref) => {
|
|
14387
14534
|
var _a, _b;
|
|
14388
|
-
const props = mergeProps(defaultProps$
|
|
14535
|
+
const props = mergeProps(defaultProps$D, p);
|
|
14389
14536
|
const {
|
|
14390
14537
|
anchors
|
|
14391
14538
|
} = props;
|
|
@@ -18641,17 +18788,17 @@ const FormArray = (props) => {
|
|
|
18641
18788
|
return React__default.createElement(React__default.Fragment, null, children);
|
|
18642
18789
|
});
|
|
18643
18790
|
};
|
|
18644
|
-
const classPrefix$
|
|
18645
|
-
const defaultProps$
|
|
18791
|
+
const classPrefix$O = "adm-form";
|
|
18792
|
+
const defaultProps$C = defaultFormContext;
|
|
18646
18793
|
const Form2 = forwardRef((p, ref) => {
|
|
18647
|
-
const props = mergeProps(defaultProps$
|
|
18794
|
+
const props = mergeProps(defaultProps$C, p);
|
|
18648
18795
|
const {
|
|
18649
18796
|
className,
|
|
18650
18797
|
style,
|
|
18651
18798
|
hasFeedback,
|
|
18652
18799
|
children,
|
|
18653
18800
|
layout,
|
|
18654
|
-
footer,
|
|
18801
|
+
footer: footer2,
|
|
18655
18802
|
mode,
|
|
18656
18803
|
disabled,
|
|
18657
18804
|
requiredMarkStyle
|
|
@@ -18692,7 +18839,7 @@ const Form2 = forwardRef((p, ref) => {
|
|
|
18692
18839
|
});
|
|
18693
18840
|
collect();
|
|
18694
18841
|
return React__default.createElement(RefForm, Object.assign({
|
|
18695
|
-
className: classNames(classPrefix$
|
|
18842
|
+
className: classNames(classPrefix$O, className),
|
|
18696
18843
|
style,
|
|
18697
18844
|
ref
|
|
18698
18845
|
}, formProps, {
|
|
@@ -18705,9 +18852,9 @@ const Form2 = forwardRef((p, ref) => {
|
|
|
18705
18852
|
requiredMarkStyle,
|
|
18706
18853
|
disabled
|
|
18707
18854
|
}
|
|
18708
|
-
}, lists),
|
|
18709
|
-
className: `${classPrefix$
|
|
18710
|
-
},
|
|
18855
|
+
}, lists), footer2 && React__default.createElement("div", {
|
|
18856
|
+
className: `${classPrefix$O}-footer`
|
|
18857
|
+
}, footer2));
|
|
18711
18858
|
});
|
|
18712
18859
|
var FieldContext = {};
|
|
18713
18860
|
var interopRequireWildcard = { exports: {} };
|
|
@@ -20086,15 +20233,15 @@ function convertPx(px) {
|
|
|
20086
20233
|
tester.style.setProperty("--size", px.toString());
|
|
20087
20234
|
return tester.getBoundingClientRect().height;
|
|
20088
20235
|
}
|
|
20089
|
-
const classPrefix$
|
|
20090
|
-
const defaultProps$
|
|
20236
|
+
const classPrefix$N = `adm-popover`;
|
|
20237
|
+
const defaultProps$B = {
|
|
20091
20238
|
placement: "top",
|
|
20092
20239
|
defaultVisible: false,
|
|
20093
20240
|
stopPropagation: ["click"],
|
|
20094
20241
|
getContainer: () => document.body
|
|
20095
20242
|
};
|
|
20096
20243
|
const Popover$1 = forwardRef((p, ref) => {
|
|
20097
|
-
const props = mergeProps(defaultProps$
|
|
20244
|
+
const props = mergeProps(defaultProps$B, p);
|
|
20098
20245
|
const {
|
|
20099
20246
|
mode = "light"
|
|
20100
20247
|
} = props;
|
|
@@ -20115,17 +20262,17 @@ const Popover$1 = forwardRef((p, ref) => {
|
|
|
20115
20262
|
const floatingRef = useRef(null);
|
|
20116
20263
|
const arrowRef = useRef(null);
|
|
20117
20264
|
const floating = withStopPropagation(props.stopPropagation, withNativeProps(props, React__default.createElement("div", {
|
|
20118
|
-
className: classNames(classPrefix$
|
|
20265
|
+
className: classNames(classPrefix$N, `${classPrefix$N}-${mode}`, !visible && `${classPrefix$N}-hidden`),
|
|
20119
20266
|
ref: floatingRef
|
|
20120
20267
|
}, React__default.createElement("div", {
|
|
20121
|
-
className: `${classPrefix$
|
|
20268
|
+
className: `${classPrefix$N}-arrow`,
|
|
20122
20269
|
ref: arrowRef
|
|
20123
20270
|
}, React__default.createElement(Arrow, {
|
|
20124
|
-
className: `${classPrefix$
|
|
20271
|
+
className: `${classPrefix$N}-arrow-icon`
|
|
20125
20272
|
})), React__default.createElement("div", {
|
|
20126
|
-
className: `${classPrefix$
|
|
20273
|
+
className: `${classPrefix$N}-inner`
|
|
20127
20274
|
}, React__default.createElement("div", {
|
|
20128
|
-
className: `${classPrefix$
|
|
20275
|
+
className: `${classPrefix$N}-inner-content`
|
|
20129
20276
|
}, props.content)))));
|
|
20130
20277
|
const [targetElement, setTargetElement] = useState(null);
|
|
20131
20278
|
function update2() {
|
|
@@ -20212,16 +20359,16 @@ const Popover$1 = forwardRef((p, ref) => {
|
|
|
20212
20359
|
if (!props.trigger)
|
|
20213
20360
|
return;
|
|
20214
20361
|
setVisible(false);
|
|
20215
|
-
}, () => {
|
|
20362
|
+
}, [() => {
|
|
20216
20363
|
var _a;
|
|
20217
20364
|
return (_a = targetRef.current) === null || _a === void 0 ? void 0 : _a.element;
|
|
20218
|
-
});
|
|
20365
|
+
}, floatingRef], ["click", "touchmove"]);
|
|
20219
20366
|
const shouldRender = useShouldRender(visible, false, props.destroyOnHide);
|
|
20220
20367
|
return React__default.createElement(React__default.Fragment, null, React__default.createElement(Wrapper, {
|
|
20221
20368
|
ref: targetRef
|
|
20222
20369
|
}, props.children), shouldRender && renderToContainer(props.getContainer, floating));
|
|
20223
20370
|
});
|
|
20224
|
-
const classPrefix$
|
|
20371
|
+
const classPrefix$M = `adm-popover-menu`;
|
|
20225
20372
|
const PopoverMenu = forwardRef((props, ref) => {
|
|
20226
20373
|
const innerRef = useRef(null);
|
|
20227
20374
|
useImperativeHandle(ref, () => innerRef.current, []);
|
|
@@ -20237,14 +20384,14 @@ const PopoverMenu = forwardRef((props, ref) => {
|
|
|
20237
20384
|
}, [props.onAction]);
|
|
20238
20385
|
const overlay = useMemo(() => {
|
|
20239
20386
|
return React__default.createElement("div", {
|
|
20240
|
-
className: `${classPrefix$
|
|
20387
|
+
className: `${classPrefix$M}-list`
|
|
20241
20388
|
}, React__default.createElement("div", {
|
|
20242
|
-
className: `${classPrefix$
|
|
20389
|
+
className: `${classPrefix$M}-list-inner`
|
|
20243
20390
|
}, props.actions.map((action, index2) => {
|
|
20244
20391
|
var _a;
|
|
20245
20392
|
return React__default.createElement("a", {
|
|
20246
20393
|
key: (_a = action.key) !== null && _a !== void 0 ? _a : index2,
|
|
20247
|
-
className: classNames(`${classPrefix$
|
|
20394
|
+
className: classNames(`${classPrefix$M}-item`, "adm-plain-anchor", action.disabled && `${classPrefix$M}-item-disabled`),
|
|
20248
20395
|
onClick: () => {
|
|
20249
20396
|
var _a2;
|
|
20250
20397
|
if (action.disabled)
|
|
@@ -20253,16 +20400,16 @@ const PopoverMenu = forwardRef((props, ref) => {
|
|
|
20253
20400
|
(_a2 = action.onClick) === null || _a2 === void 0 ? void 0 : _a2.call(action);
|
|
20254
20401
|
}
|
|
20255
20402
|
}, action.icon && React__default.createElement("div", {
|
|
20256
|
-
className: `${classPrefix$
|
|
20403
|
+
className: `${classPrefix$M}-item-icon`
|
|
20257
20404
|
}, action.icon), React__default.createElement("div", {
|
|
20258
|
-
className: `${classPrefix$
|
|
20405
|
+
className: `${classPrefix$M}-item-text`
|
|
20259
20406
|
}, action.text));
|
|
20260
20407
|
})));
|
|
20261
20408
|
}, [props.actions, onClick]);
|
|
20262
20409
|
return React__default.createElement(Popover$1, Object.assign({
|
|
20263
20410
|
ref: innerRef
|
|
20264
20411
|
}, props, {
|
|
20265
|
-
className: classNames(classPrefix$
|
|
20412
|
+
className: classNames(classPrefix$M, props.className),
|
|
20266
20413
|
content: overlay
|
|
20267
20414
|
}), props.children);
|
|
20268
20415
|
});
|
|
@@ -20278,7 +20425,7 @@ function undefinedFallback(...items) {
|
|
|
20278
20425
|
return items[i];
|
|
20279
20426
|
}
|
|
20280
20427
|
const NAME_SPLIT = "__SPLIT__";
|
|
20281
|
-
const classPrefix$
|
|
20428
|
+
const classPrefix$L = `adm-form-item`;
|
|
20282
20429
|
const MemoInput = React__default.memo(({
|
|
20283
20430
|
children
|
|
20284
20431
|
}) => children, (prev, next) => prev.value === next.value && prev.update === next.update);
|
|
@@ -20311,15 +20458,15 @@ const FormItemLayout = (props) => {
|
|
|
20311
20458
|
switch (requiredMarkStyle) {
|
|
20312
20459
|
case "asterisk":
|
|
20313
20460
|
return required4 && React__default.createElement("span", {
|
|
20314
|
-
className: `${classPrefix$
|
|
20461
|
+
className: `${classPrefix$L}-required-asterisk`
|
|
20315
20462
|
}, "*");
|
|
20316
20463
|
case "text-required":
|
|
20317
20464
|
return required4 && React__default.createElement("span", {
|
|
20318
|
-
className: `${classPrefix$
|
|
20465
|
+
className: `${classPrefix$L}-required-text`
|
|
20319
20466
|
}, "(", locale.Form.required, ")");
|
|
20320
20467
|
case "text-optional":
|
|
20321
20468
|
return !required4 && React__default.createElement("span", {
|
|
20322
|
-
className: `${classPrefix$
|
|
20469
|
+
className: `${classPrefix$L}-required-text`
|
|
20323
20470
|
}, "(", locale.Form.optional, ")");
|
|
20324
20471
|
case "none":
|
|
20325
20472
|
return null;
|
|
@@ -20328,24 +20475,24 @@ const FormItemLayout = (props) => {
|
|
|
20328
20475
|
}
|
|
20329
20476
|
})();
|
|
20330
20477
|
const labelElement = label ? React__default.createElement("label", {
|
|
20331
|
-
className: `${classPrefix$
|
|
20478
|
+
className: `${classPrefix$L}-label`,
|
|
20332
20479
|
htmlFor
|
|
20333
20480
|
}, label, requiredMark, help && React__default.createElement(Popover, {
|
|
20334
20481
|
content: help,
|
|
20335
20482
|
mode: "dark",
|
|
20336
20483
|
trigger: "click"
|
|
20337
20484
|
}, React__default.createElement("span", {
|
|
20338
|
-
className: `${classPrefix$
|
|
20485
|
+
className: `${classPrefix$L}-label-help`,
|
|
20339
20486
|
onClick: (e) => {
|
|
20340
20487
|
e.preventDefault();
|
|
20341
20488
|
}
|
|
20342
20489
|
}, React__default.createElement(QuestionCircleOutline, null)))) : null;
|
|
20343
20490
|
const description = props.description || hasFeedback ? React__default.createElement(React__default.Fragment, null, props.description, hasFeedback && React__default.createElement(React__default.Fragment, null, props.errors.map((error, index2) => React__default.createElement("div", {
|
|
20344
20491
|
key: `error-${index2}`,
|
|
20345
|
-
className: `${classPrefix$
|
|
20492
|
+
className: `${classPrefix$L}-feedback-error`
|
|
20346
20493
|
}, error)), props.warnings.map((warning3, index2) => React__default.createElement("div", {
|
|
20347
20494
|
key: `warning-${index2}`,
|
|
20348
|
-
className: `${classPrefix$
|
|
20495
|
+
className: `${classPrefix$L}-feedback-warning`
|
|
20349
20496
|
}, warning3)))) : null;
|
|
20350
20497
|
return withNativeProps(props, React__default.createElement(List$1.Item, {
|
|
20351
20498
|
style,
|
|
@@ -20353,18 +20500,18 @@ const FormItemLayout = (props) => {
|
|
|
20353
20500
|
prefix: layout === "horizontal" && labelElement,
|
|
20354
20501
|
extra,
|
|
20355
20502
|
description,
|
|
20356
|
-
className: classNames(classPrefix$
|
|
20357
|
-
[`${classPrefix$
|
|
20358
|
-
[`${classPrefix$
|
|
20503
|
+
className: classNames(classPrefix$L, className, `${classPrefix$L}-${layout}`, {
|
|
20504
|
+
[`${classPrefix$L}-hidden`]: hidden,
|
|
20505
|
+
[`${classPrefix$L}-has-error`]: props.errors.length
|
|
20359
20506
|
}),
|
|
20360
20507
|
disabled,
|
|
20361
20508
|
onClick: props.onClick,
|
|
20362
20509
|
clickable: props.clickable,
|
|
20363
20510
|
arrow: arrow2
|
|
20364
20511
|
}, React__default.createElement("div", {
|
|
20365
|
-
className: classNames(`${classPrefix$
|
|
20512
|
+
className: classNames(`${classPrefix$L}-child`, `${classPrefix$L}-child-position-${childElementPosition}`)
|
|
20366
20513
|
}, React__default.createElement("div", {
|
|
20367
|
-
className: classNames(`${classPrefix$
|
|
20514
|
+
className: classNames(`${classPrefix$L}-child-inner`)
|
|
20368
20515
|
}, children))));
|
|
20369
20516
|
};
|
|
20370
20517
|
const FormItem = (props) => {
|
|
@@ -20578,7 +20725,7 @@ const index$a = attachPropertiesToComponent(Form2, {
|
|
|
20578
20725
|
useWatch
|
|
20579
20726
|
});
|
|
20580
20727
|
const grid = "";
|
|
20581
|
-
const classPrefix$
|
|
20728
|
+
const classPrefix$K = `adm-grid`;
|
|
20582
20729
|
const Grid$1 = (props) => {
|
|
20583
20730
|
const style = {
|
|
20584
20731
|
"--columns": props.columns.toString()
|
|
@@ -20595,7 +20742,7 @@ const Grid$1 = (props) => {
|
|
|
20595
20742
|
}
|
|
20596
20743
|
}
|
|
20597
20744
|
return withNativeProps(props, React__default.createElement("div", {
|
|
20598
|
-
className: classPrefix$
|
|
20745
|
+
className: classPrefix$K,
|
|
20599
20746
|
style
|
|
20600
20747
|
}, props.children));
|
|
20601
20748
|
};
|
|
@@ -20607,7 +20754,7 @@ const GridItem = (p) => {
|
|
|
20607
20754
|
"--item-span": props.span
|
|
20608
20755
|
};
|
|
20609
20756
|
return withNativeProps(props, React__default.createElement("div", {
|
|
20610
|
-
className: `${classPrefix$
|
|
20757
|
+
className: `${classPrefix$K}-item`,
|
|
20611
20758
|
style: itemStyle,
|
|
20612
20759
|
onClick: props.onClick
|
|
20613
20760
|
}, props.children));
|
|
@@ -20641,7 +20788,7 @@ const apply = (m, [ox, oy]) => {
|
|
|
20641
20788
|
const multiply = (m1, m2) => {
|
|
20642
20789
|
return [m1[0] * m2[0] + m1[2] * m2[1], m1[1] * m2[0] + m1[3] * m2[1], m1[0] * m2[2] + m1[2] * m2[3], m1[1] * m2[2] + m1[3] * m2[3], m1[0] * m2[4] + m1[2] * m2[5] + m1[4], m1[1] * m2[4] + m1[3] * m2[5] + m1[5]];
|
|
20643
20790
|
};
|
|
20644
|
-
const classPrefix$
|
|
20791
|
+
const classPrefix$J = `adm-image-viewer`;
|
|
20645
20792
|
const Slide = (props) => {
|
|
20646
20793
|
const {
|
|
20647
20794
|
dragLockRef
|
|
@@ -20773,17 +20920,17 @@ const Slide = (props) => {
|
|
|
20773
20920
|
}
|
|
20774
20921
|
});
|
|
20775
20922
|
return React__default.createElement("div", {
|
|
20776
|
-
className: `${classPrefix$
|
|
20923
|
+
className: `${classPrefix$J}-slide`,
|
|
20777
20924
|
onPointerMove: (e) => {
|
|
20778
20925
|
if (getScaleX(matrix.get()) !== 1) {
|
|
20779
20926
|
e.stopPropagation();
|
|
20780
20927
|
}
|
|
20781
20928
|
}
|
|
20782
20929
|
}, React__default.createElement("div", {
|
|
20783
|
-
className: `${classPrefix$
|
|
20930
|
+
className: `${classPrefix$J}-control`,
|
|
20784
20931
|
ref: controlRef
|
|
20785
20932
|
}, React__default.createElement(animated.div, {
|
|
20786
|
-
className: `${classPrefix$
|
|
20933
|
+
className: `${classPrefix$J}-image-wrapper`,
|
|
20787
20934
|
style: {
|
|
20788
20935
|
matrix
|
|
20789
20936
|
}
|
|
@@ -20794,7 +20941,7 @@ const Slide = (props) => {
|
|
|
20794
20941
|
alt: props.image
|
|
20795
20942
|
}))));
|
|
20796
20943
|
};
|
|
20797
|
-
const classPrefix$
|
|
20944
|
+
const classPrefix$I = `adm-image-viewer`;
|
|
20798
20945
|
const Slides = forwardRef((props, ref) => {
|
|
20799
20946
|
const slideWidth = window.innerWidth + convertPx(16);
|
|
20800
20947
|
const [{
|
|
@@ -20851,42 +20998,42 @@ const Slides = forwardRef((props, ref) => {
|
|
|
20851
20998
|
}
|
|
20852
20999
|
});
|
|
20853
21000
|
return React__default.createElement("div", Object.assign({
|
|
20854
|
-
className: `${classPrefix$
|
|
21001
|
+
className: `${classPrefix$I}-slides`
|
|
20855
21002
|
}, bind()), React__default.createElement(animated.div, {
|
|
20856
|
-
className: `${classPrefix$
|
|
21003
|
+
className: `${classPrefix$I}-indicator`
|
|
20857
21004
|
}, x.to((v) => {
|
|
20858
21005
|
const index2 = bound(Math.round(v / slideWidth), 0, count - 1);
|
|
20859
21006
|
return `${index2 + 1} / ${count}`;
|
|
20860
21007
|
})), React__default.createElement(animated.div, {
|
|
20861
|
-
className: `${classPrefix$
|
|
21008
|
+
className: `${classPrefix$I}-slides-inner`,
|
|
20862
21009
|
style: {
|
|
20863
21010
|
x: x.to((x2) => -x2)
|
|
20864
21011
|
}
|
|
20865
|
-
}, props.images.map((image2) => React__default.createElement(Slide, {
|
|
20866
|
-
key:
|
|
21012
|
+
}, props.images.map((image2, index2) => React__default.createElement(Slide, {
|
|
21013
|
+
key: index2,
|
|
20867
21014
|
image: image2,
|
|
20868
21015
|
onTap: props.onTap,
|
|
20869
21016
|
maxZoom: props.maxZoom,
|
|
20870
21017
|
onZoomChange: (zoom) => {
|
|
20871
21018
|
if (zoom !== 1) {
|
|
20872
|
-
const
|
|
21019
|
+
const index3 = Math.round(x.get() / slideWidth);
|
|
20873
21020
|
api.start({
|
|
20874
|
-
x:
|
|
21021
|
+
x: index3 * slideWidth
|
|
20875
21022
|
});
|
|
20876
21023
|
}
|
|
20877
21024
|
},
|
|
20878
21025
|
dragLockRef
|
|
20879
21026
|
}))));
|
|
20880
21027
|
});
|
|
20881
|
-
const classPrefix$
|
|
20882
|
-
const defaultProps$
|
|
21028
|
+
const classPrefix$H = `adm-image-viewer`;
|
|
21029
|
+
const defaultProps$A = {
|
|
20883
21030
|
maxZoom: 3,
|
|
20884
21031
|
getContainer: null,
|
|
20885
21032
|
visible: false
|
|
20886
21033
|
};
|
|
20887
21034
|
const ImageViewer$1 = (p) => {
|
|
20888
21035
|
var _a;
|
|
20889
|
-
const props = mergeProps(defaultProps$
|
|
21036
|
+
const props = mergeProps(defaultProps$A, p);
|
|
20890
21037
|
const node = React__default.createElement(Mask, {
|
|
20891
21038
|
visible: props.visible,
|
|
20892
21039
|
disableBodyScroll: false,
|
|
@@ -20894,7 +21041,7 @@ const ImageViewer$1 = (p) => {
|
|
|
20894
21041
|
afterClose: props.afterClose,
|
|
20895
21042
|
destroyOnClose: true
|
|
20896
21043
|
}, React__default.createElement("div", {
|
|
20897
|
-
className: `${classPrefix$
|
|
21044
|
+
className: `${classPrefix$H}-content`
|
|
20898
21045
|
}, props.image && React__default.createElement(Slide, {
|
|
20899
21046
|
image: props.image,
|
|
20900
21047
|
onTap: () => {
|
|
@@ -20903,13 +21050,13 @@ const ImageViewer$1 = (p) => {
|
|
|
20903
21050
|
},
|
|
20904
21051
|
maxZoom: props.maxZoom
|
|
20905
21052
|
})), props.image && React__default.createElement("div", {
|
|
20906
|
-
className: `${classPrefix$
|
|
21053
|
+
className: `${classPrefix$H}-footer`
|
|
20907
21054
|
}, (_a = props.renderFooter) === null || _a === void 0 ? void 0 : _a.call(props, props.image), React__default.createElement(SafeArea, {
|
|
20908
21055
|
position: "bottom"
|
|
20909
21056
|
})));
|
|
20910
21057
|
return renderToContainer(props.getContainer, node);
|
|
20911
21058
|
};
|
|
20912
|
-
const multiDefaultProps = Object.assign(Object.assign({}, defaultProps$
|
|
21059
|
+
const multiDefaultProps = Object.assign(Object.assign({}, defaultProps$A), {
|
|
20913
21060
|
defaultIndex: 0
|
|
20914
21061
|
});
|
|
20915
21062
|
const MultiImageViewer = forwardRef((p, ref) => {
|
|
@@ -20936,7 +21083,7 @@ const MultiImageViewer = forwardRef((p, ref) => {
|
|
|
20936
21083
|
afterClose: props.afterClose,
|
|
20937
21084
|
destroyOnClose: true
|
|
20938
21085
|
}, React__default.createElement("div", {
|
|
20939
|
-
className: `${classPrefix$
|
|
21086
|
+
className: `${classPrefix$H}-content`
|
|
20940
21087
|
}, props.images && React__default.createElement(Slides, {
|
|
20941
21088
|
ref: slidesRef,
|
|
20942
21089
|
defaultIndex: index2,
|
|
@@ -20948,7 +21095,7 @@ const MultiImageViewer = forwardRef((p, ref) => {
|
|
|
20948
21095
|
},
|
|
20949
21096
|
maxZoom: props.maxZoom
|
|
20950
21097
|
})), props.images && React__default.createElement("div", {
|
|
20951
|
-
className: `${classPrefix$
|
|
21098
|
+
className: `${classPrefix$H}-footer`
|
|
20952
21099
|
}, (_a = props.renderFooter) === null || _a === void 0 ? void 0 : _a.call(props, props.images[index2], index2), React__default.createElement(SafeArea, {
|
|
20953
21100
|
position: "bottom"
|
|
20954
21101
|
})));
|
|
@@ -20993,7 +21140,7 @@ const ImageViewer = attachPropertiesToComponent(ImageViewer$1, {
|
|
|
20993
21140
|
show: showImageViewer,
|
|
20994
21141
|
clear: clearImageViewer
|
|
20995
21142
|
});
|
|
20996
|
-
const classPrefix$
|
|
21143
|
+
const classPrefix$G = `adm-image-uploader`;
|
|
20997
21144
|
const PreviewItem = (props) => {
|
|
20998
21145
|
const {
|
|
20999
21146
|
locale
|
|
@@ -21014,62 +21161,67 @@ const PreviewItem = (props) => {
|
|
|
21014
21161
|
}
|
|
21015
21162
|
return "";
|
|
21016
21163
|
}, [url2, file]);
|
|
21164
|
+
useLayoutEffect$1(() => {
|
|
21165
|
+
return () => {
|
|
21166
|
+
URL.revokeObjectURL(src);
|
|
21167
|
+
};
|
|
21168
|
+
}, [src]);
|
|
21017
21169
|
function renderLoading() {
|
|
21018
21170
|
return props.status === "pending" && React__default.createElement("div", {
|
|
21019
|
-
className: `${classPrefix$
|
|
21171
|
+
className: `${classPrefix$G}-cell-mask`
|
|
21020
21172
|
}, React__default.createElement("span", {
|
|
21021
|
-
className: `${classPrefix$
|
|
21173
|
+
className: `${classPrefix$G}-cell-loading`
|
|
21022
21174
|
}, React__default.createElement(SpinLoading, {
|
|
21023
21175
|
color: "white"
|
|
21024
21176
|
}), React__default.createElement("span", {
|
|
21025
|
-
className: `${classPrefix$
|
|
21177
|
+
className: `${classPrefix$G}-cell-mask-message`
|
|
21026
21178
|
}, locale.ImageUploader.uploading)));
|
|
21027
21179
|
}
|
|
21028
21180
|
function renderDelete() {
|
|
21029
21181
|
return deletable && React__default.createElement("span", {
|
|
21030
|
-
className: `${classPrefix$
|
|
21182
|
+
className: `${classPrefix$G}-cell-delete`,
|
|
21031
21183
|
onClick: onDelete
|
|
21032
21184
|
}, React__default.createElement(CloseOutline, {
|
|
21033
|
-
className: `${classPrefix$
|
|
21185
|
+
className: `${classPrefix$G}-cell-delete-icon`
|
|
21034
21186
|
}));
|
|
21035
21187
|
}
|
|
21036
21188
|
return React__default.createElement("div", {
|
|
21037
|
-
className: classNames(`${classPrefix$
|
|
21189
|
+
className: classNames(`${classPrefix$G}-cell`, props.status === "fail" && `${classPrefix$G}-cell-fail`)
|
|
21038
21190
|
}, React__default.createElement(Image$1, {
|
|
21039
|
-
className: `${classPrefix$
|
|
21191
|
+
className: `${classPrefix$G}-cell-image`,
|
|
21040
21192
|
src,
|
|
21041
21193
|
fit: imageFit,
|
|
21042
21194
|
onClick: props.onClick
|
|
21043
21195
|
}), renderLoading(), renderDelete());
|
|
21044
21196
|
};
|
|
21045
21197
|
const space = "";
|
|
21046
|
-
const classPrefix$
|
|
21047
|
-
const defaultProps$
|
|
21198
|
+
const classPrefix$F = `adm-space`;
|
|
21199
|
+
const defaultProps$z = {
|
|
21048
21200
|
direction: "horizontal"
|
|
21049
21201
|
};
|
|
21050
21202
|
const Space = (p) => {
|
|
21051
|
-
const props = mergeProps(defaultProps$
|
|
21203
|
+
const props = mergeProps(defaultProps$z, p);
|
|
21052
21204
|
const {
|
|
21053
21205
|
direction,
|
|
21054
21206
|
onClick
|
|
21055
21207
|
} = props;
|
|
21056
21208
|
return withNativeProps(props, React__default.createElement("div", {
|
|
21057
|
-
className: classNames(classPrefix$
|
|
21058
|
-
[`${classPrefix$
|
|
21059
|
-
[`${classPrefix$
|
|
21060
|
-
[`${classPrefix$
|
|
21061
|
-
[`${classPrefix$
|
|
21062
|
-
[`${classPrefix$
|
|
21209
|
+
className: classNames(classPrefix$F, {
|
|
21210
|
+
[`${classPrefix$F}-wrap`]: props.wrap,
|
|
21211
|
+
[`${classPrefix$F}-block`]: props.block,
|
|
21212
|
+
[`${classPrefix$F}-${direction}`]: true,
|
|
21213
|
+
[`${classPrefix$F}-align-${props.align}`]: !!props.align,
|
|
21214
|
+
[`${classPrefix$F}-justify-${props.justify}`]: !!props.justify
|
|
21063
21215
|
}),
|
|
21064
21216
|
onClick
|
|
21065
21217
|
}, React__default.Children.map(props.children, (child) => {
|
|
21066
21218
|
return child !== null && child !== void 0 && React__default.createElement("div", {
|
|
21067
|
-
className: `${classPrefix$
|
|
21219
|
+
className: `${classPrefix$F}-item`
|
|
21068
21220
|
}, child);
|
|
21069
21221
|
})));
|
|
21070
21222
|
};
|
|
21071
|
-
const classPrefix$
|
|
21072
|
-
const defaultProps$
|
|
21223
|
+
const classPrefix$E = `adm-image-uploader`;
|
|
21224
|
+
const defaultProps$y = {
|
|
21073
21225
|
disableUpload: false,
|
|
21074
21226
|
deletable: true,
|
|
21075
21227
|
showUpload: true,
|
|
@@ -21085,7 +21237,7 @@ const ImageUploader = (p) => {
|
|
|
21085
21237
|
const {
|
|
21086
21238
|
locale
|
|
21087
21239
|
} = useConfig();
|
|
21088
|
-
const props = mergeProps(defaultProps$
|
|
21240
|
+
const props = mergeProps(defaultProps$y, p);
|
|
21089
21241
|
const [value, setValue2] = usePropsValue(props);
|
|
21090
21242
|
const [tasks, setTasks] = useState([]);
|
|
21091
21243
|
useIsomorphicLayoutEffect$1(() => {
|
|
@@ -21095,10 +21247,18 @@ const ImageUploader = (p) => {
|
|
|
21095
21247
|
return !value.some((fileItem) => fileItem.url === task.url);
|
|
21096
21248
|
}));
|
|
21097
21249
|
}, [value]);
|
|
21250
|
+
useIsomorphicLayoutEffect$1(() => {
|
|
21251
|
+
var _a;
|
|
21252
|
+
(_a = props.onUploadQueueChange) === null || _a === void 0 ? void 0 : _a.call(props, tasks.map((item) => ({
|
|
21253
|
+
id: item.id,
|
|
21254
|
+
status: item.status
|
|
21255
|
+
})));
|
|
21256
|
+
}, [tasks]);
|
|
21098
21257
|
const idCountRef = useRef(0);
|
|
21099
21258
|
const {
|
|
21100
21259
|
maxCount,
|
|
21101
|
-
onPreview
|
|
21260
|
+
onPreview,
|
|
21261
|
+
renderItem
|
|
21102
21262
|
} = props;
|
|
21103
21263
|
function processFile(file, fileList) {
|
|
21104
21264
|
return __awaiter$1(this, void 0, void 0, function* () {
|
|
@@ -21152,6 +21312,7 @@ const ImageUploader = (p) => {
|
|
|
21152
21312
|
return prev.map((task) => {
|
|
21153
21313
|
if (task.id === currentTask.id) {
|
|
21154
21314
|
return Object.assign(Object.assign({}, task), {
|
|
21315
|
+
status: "success",
|
|
21155
21316
|
url: result2.url
|
|
21156
21317
|
});
|
|
21157
21318
|
}
|
|
@@ -21193,34 +21354,38 @@ const ImageUploader = (p) => {
|
|
|
21193
21354
|
(_a = imageViewerHandlerRef.current) === null || _a === void 0 ? void 0 : _a.close();
|
|
21194
21355
|
});
|
|
21195
21356
|
const showUpload = props.showUpload && (maxCount === 0 || value.length + tasks.length < maxCount);
|
|
21357
|
+
const renderImages = () => {
|
|
21358
|
+
return value.map((fileItem, index2) => {
|
|
21359
|
+
var _a, _b;
|
|
21360
|
+
const originNode = React__default.createElement(PreviewItem, {
|
|
21361
|
+
key: (_a = fileItem.key) !== null && _a !== void 0 ? _a : index2,
|
|
21362
|
+
url: (_b = fileItem.thumbnailUrl) !== null && _b !== void 0 ? _b : fileItem.url,
|
|
21363
|
+
deletable: props.deletable,
|
|
21364
|
+
imageFit: props.imageFit,
|
|
21365
|
+
onClick: () => {
|
|
21366
|
+
if (props.preview) {
|
|
21367
|
+
previewImage(index2);
|
|
21368
|
+
}
|
|
21369
|
+
onPreview && onPreview(index2, fileItem);
|
|
21370
|
+
},
|
|
21371
|
+
onDelete: () => __awaiter$1(void 0, void 0, void 0, function* () {
|
|
21372
|
+
var _c;
|
|
21373
|
+
const canDelete = yield (_c = props.onDelete) === null || _c === void 0 ? void 0 : _c.call(props, fileItem);
|
|
21374
|
+
if (canDelete === false)
|
|
21375
|
+
return;
|
|
21376
|
+
setValue2(value.filter((x, i) => i !== index2));
|
|
21377
|
+
})
|
|
21378
|
+
});
|
|
21379
|
+
return renderItem ? renderItem(originNode, fileItem, value) : originNode;
|
|
21380
|
+
});
|
|
21381
|
+
};
|
|
21196
21382
|
return withNativeProps(props, React__default.createElement("div", {
|
|
21197
|
-
className: classPrefix$
|
|
21383
|
+
className: classPrefix$E
|
|
21198
21384
|
}, React__default.createElement(Space, {
|
|
21199
|
-
className: `${classPrefix$
|
|
21385
|
+
className: `${classPrefix$E}-space`,
|
|
21200
21386
|
wrap: true,
|
|
21201
21387
|
block: true
|
|
21202
|
-
},
|
|
21203
|
-
var _a, _b;
|
|
21204
|
-
return React__default.createElement(PreviewItem, {
|
|
21205
|
-
key: (_a = fileItem.key) !== null && _a !== void 0 ? _a : index2,
|
|
21206
|
-
url: (_b = fileItem.thumbnailUrl) !== null && _b !== void 0 ? _b : fileItem.url,
|
|
21207
|
-
deletable: props.deletable,
|
|
21208
|
-
imageFit: props.imageFit,
|
|
21209
|
-
onClick: () => {
|
|
21210
|
-
if (props.preview) {
|
|
21211
|
-
previewImage(index2);
|
|
21212
|
-
}
|
|
21213
|
-
onPreview && onPreview(index2, fileItem);
|
|
21214
|
-
},
|
|
21215
|
-
onDelete: () => __awaiter$1(void 0, void 0, void 0, function* () {
|
|
21216
|
-
var _c;
|
|
21217
|
-
const canDelete = yield (_c = props.onDelete) === null || _c === void 0 ? void 0 : _c.call(props, fileItem);
|
|
21218
|
-
if (canDelete === false)
|
|
21219
|
-
return;
|
|
21220
|
-
setValue2(value.filter((x, i) => i !== index2));
|
|
21221
|
-
})
|
|
21222
|
-
});
|
|
21223
|
-
}), tasks.map((task) => {
|
|
21388
|
+
}, renderImages(), tasks.map((task) => {
|
|
21224
21389
|
if (!props.showFailed && task.status === "fail") {
|
|
21225
21390
|
return null;
|
|
21226
21391
|
}
|
|
@@ -21235,19 +21400,19 @@ const ImageUploader = (p) => {
|
|
|
21235
21400
|
}
|
|
21236
21401
|
});
|
|
21237
21402
|
}), showUpload && React__default.createElement("div", {
|
|
21238
|
-
className: `${classPrefix$
|
|
21403
|
+
className: `${classPrefix$E}-upload-button-wrap`
|
|
21239
21404
|
}, props.children ? props.children : React__default.createElement("span", {
|
|
21240
|
-
className: `${classPrefix$
|
|
21405
|
+
className: `${classPrefix$E}-cell ${classPrefix$E}-upload-button`,
|
|
21241
21406
|
role: "button",
|
|
21242
21407
|
"aria-label": locale.ImageUploader.upload
|
|
21243
21408
|
}, React__default.createElement("span", {
|
|
21244
|
-
className: `${classPrefix$
|
|
21409
|
+
className: `${classPrefix$E}-upload-button-icon`
|
|
21245
21410
|
}, React__default.createElement(AddOutline, null))), !props.disableUpload && React__default.createElement("input", {
|
|
21246
21411
|
capture: props.capture,
|
|
21247
21412
|
accept: props.accept,
|
|
21248
21413
|
multiple: props.multiple,
|
|
21249
21414
|
type: "file",
|
|
21250
|
-
className: `${classPrefix$
|
|
21415
|
+
className: `${classPrefix$E}-input`,
|
|
21251
21416
|
onChange,
|
|
21252
21417
|
"aria-hidden": true
|
|
21253
21418
|
})))));
|
|
@@ -21255,12 +21420,12 @@ const ImageUploader = (p) => {
|
|
|
21255
21420
|
const imageUploader = "";
|
|
21256
21421
|
const indexBar = "";
|
|
21257
21422
|
const Panel = () => null;
|
|
21258
|
-
const classPrefix$
|
|
21423
|
+
const classPrefix$D = `adm-index-bar`;
|
|
21259
21424
|
const Sidebar = (props) => {
|
|
21260
21425
|
const [interacting, setInteracting] = useState(false);
|
|
21261
21426
|
return React__default.createElement("div", {
|
|
21262
|
-
className: classNames(`${classPrefix$
|
|
21263
|
-
[`${classPrefix$
|
|
21427
|
+
className: classNames(`${classPrefix$D}-sidebar`, {
|
|
21428
|
+
[`${classPrefix$D}-sidebar-interacting`]: interacting
|
|
21264
21429
|
}),
|
|
21265
21430
|
onMouseDown: () => {
|
|
21266
21431
|
setInteracting(true);
|
|
@@ -21295,7 +21460,7 @@ const Sidebar = (props) => {
|
|
|
21295
21460
|
}) => {
|
|
21296
21461
|
const active = index2 === props.activeIndex;
|
|
21297
21462
|
return React__default.createElement("div", {
|
|
21298
|
-
className: `${classPrefix$
|
|
21463
|
+
className: `${classPrefix$D}-sidebar-row`,
|
|
21299
21464
|
onMouseDown: () => {
|
|
21300
21465
|
props.onActive(index2);
|
|
21301
21466
|
},
|
|
@@ -21310,21 +21475,21 @@ const Sidebar = (props) => {
|
|
|
21310
21475
|
"data-index": index2,
|
|
21311
21476
|
key: index2
|
|
21312
21477
|
}, interacting && active && React__default.createElement("div", {
|
|
21313
|
-
className: `${classPrefix$
|
|
21478
|
+
className: `${classPrefix$D}-sidebar-bubble`
|
|
21314
21479
|
}, brief), React__default.createElement("div", {
|
|
21315
|
-
className: classNames(`${classPrefix$
|
|
21316
|
-
[`${classPrefix$
|
|
21480
|
+
className: classNames(`${classPrefix$D}-sidebar-item`, {
|
|
21481
|
+
[`${classPrefix$D}-sidebar-item-active`]: active
|
|
21317
21482
|
}),
|
|
21318
21483
|
"data-index": index2
|
|
21319
21484
|
}, React__default.createElement("div", null, brief)));
|
|
21320
21485
|
}));
|
|
21321
21486
|
};
|
|
21322
|
-
const classPrefix$
|
|
21323
|
-
const defaultProps$
|
|
21487
|
+
const classPrefix$C = `adm-index-bar`;
|
|
21488
|
+
const defaultProps$x = {
|
|
21324
21489
|
sticky: true
|
|
21325
21490
|
};
|
|
21326
21491
|
const IndexBar = forwardRef((p, ref) => {
|
|
21327
|
-
const props = mergeProps(defaultProps$
|
|
21492
|
+
const props = mergeProps(defaultProps$x, p);
|
|
21328
21493
|
const titleHeight = convertPx(35);
|
|
21329
21494
|
const bodyRef = useRef(null);
|
|
21330
21495
|
const indexItems = [];
|
|
@@ -21344,9 +21509,9 @@ const IndexBar = forwardRef((p, ref) => {
|
|
|
21344
21509
|
panels.push(withNativeProps(child.props, React__default.createElement("div", {
|
|
21345
21510
|
key: child.props.index,
|
|
21346
21511
|
"data-index": child.props.index,
|
|
21347
|
-
className: `${classPrefix$
|
|
21512
|
+
className: `${classPrefix$C}-anchor`
|
|
21348
21513
|
}, React__default.createElement("div", {
|
|
21349
|
-
className: `${classPrefix$
|
|
21514
|
+
className: `${classPrefix$C}-anchor-title`
|
|
21350
21515
|
}, child.props.title || child.props.index), child.props.children)));
|
|
21351
21516
|
});
|
|
21352
21517
|
const [activeIndex, setActiveIndex] = useState(() => {
|
|
@@ -21383,7 +21548,7 @@ const IndexBar = forwardRef((p, ref) => {
|
|
|
21383
21548
|
if (!body)
|
|
21384
21549
|
return;
|
|
21385
21550
|
const scrollTop = body.scrollTop;
|
|
21386
|
-
const elements = body.getElementsByClassName(`${classPrefix$
|
|
21551
|
+
const elements = body.getElementsByClassName(`${classPrefix$C}-anchor`);
|
|
21387
21552
|
for (let i = 0; i < elements.length; i++) {
|
|
21388
21553
|
const panel = elements.item(i);
|
|
21389
21554
|
if (!panel)
|
|
@@ -21403,8 +21568,8 @@ const IndexBar = forwardRef((p, ref) => {
|
|
|
21403
21568
|
leading: true
|
|
21404
21569
|
});
|
|
21405
21570
|
return withNativeProps(props, React__default.createElement("div", {
|
|
21406
|
-
className: classNames(`${classPrefix$
|
|
21407
|
-
[`${classPrefix$
|
|
21571
|
+
className: classNames(`${classPrefix$C}`, {
|
|
21572
|
+
[`${classPrefix$C}-sticky`]: props.sticky
|
|
21408
21573
|
})
|
|
21409
21574
|
}, React__default.createElement(Sidebar, {
|
|
21410
21575
|
indexItems,
|
|
@@ -21413,7 +21578,7 @@ const IndexBar = forwardRef((p, ref) => {
|
|
|
21413
21578
|
scrollTo(index2);
|
|
21414
21579
|
}
|
|
21415
21580
|
}), React__default.createElement("div", {
|
|
21416
|
-
className: `${classPrefix$
|
|
21581
|
+
className: `${classPrefix$C}-body`,
|
|
21417
21582
|
ref: bodyRef,
|
|
21418
21583
|
onScroll: checkActiveIndex
|
|
21419
21584
|
}, panels)));
|
|
@@ -21425,8 +21590,8 @@ const infiniteScroll = "";
|
|
|
21425
21590
|
function isWindow(element) {
|
|
21426
21591
|
return element === window;
|
|
21427
21592
|
}
|
|
21428
|
-
const classPrefix$
|
|
21429
|
-
const defaultProps$
|
|
21593
|
+
const classPrefix$B = `adm-infinite-scroll`;
|
|
21594
|
+
const defaultProps$w = {
|
|
21430
21595
|
threshold: 250,
|
|
21431
21596
|
children: (hasMore, failed, retry) => React__default.createElement(InfiniteScrollContent, {
|
|
21432
21597
|
hasMore,
|
|
@@ -21435,7 +21600,7 @@ const defaultProps$v = {
|
|
|
21435
21600
|
})
|
|
21436
21601
|
};
|
|
21437
21602
|
const InfiniteScroll = (p) => {
|
|
21438
|
-
const props = mergeProps(defaultProps$
|
|
21603
|
+
const props = mergeProps(defaultProps$w, p);
|
|
21439
21604
|
const [failed, setFailed] = useState(false);
|
|
21440
21605
|
const doLoadMore = useLockFn((isRetry) => __awaiter$1(void 0, void 0, void 0, function* () {
|
|
21441
21606
|
try {
|
|
@@ -21504,7 +21669,7 @@ const InfiniteScroll = (p) => {
|
|
|
21504
21669
|
});
|
|
21505
21670
|
}
|
|
21506
21671
|
return withNativeProps(props, React__default.createElement("div", {
|
|
21507
|
-
className: classPrefix$
|
|
21672
|
+
className: classPrefix$B,
|
|
21508
21673
|
ref: elementRef
|
|
21509
21674
|
}, typeof props.children === "function" ? props.children(props.hasMore, failed, retry) : props.children));
|
|
21510
21675
|
};
|
|
@@ -21517,7 +21682,7 @@ const InfiniteScrollContent = (props) => {
|
|
|
21517
21682
|
}
|
|
21518
21683
|
if (props.failed) {
|
|
21519
21684
|
return React__default.createElement("span", null, React__default.createElement("span", {
|
|
21520
|
-
className: `${classPrefix$
|
|
21685
|
+
className: `${classPrefix$B}-failed-text`
|
|
21521
21686
|
}, locale.InfiniteScroll.failedToLoad), React__default.createElement("a", {
|
|
21522
21687
|
onClick: () => {
|
|
21523
21688
|
props.retry();
|
|
@@ -21527,13 +21692,13 @@ const InfiniteScrollContent = (props) => {
|
|
|
21527
21692
|
return React__default.createElement(React__default.Fragment, null, React__default.createElement("span", null, locale.common.loading), React__default.createElement(DotLoading, null));
|
|
21528
21693
|
};
|
|
21529
21694
|
const input = "";
|
|
21530
|
-
const classPrefix$
|
|
21531
|
-
const defaultProps$
|
|
21695
|
+
const classPrefix$A = `adm-input`;
|
|
21696
|
+
const defaultProps$v = {
|
|
21532
21697
|
defaultValue: "",
|
|
21533
21698
|
onlyShowClearWhenFocus: true
|
|
21534
21699
|
};
|
|
21535
21700
|
const Input = forwardRef((p, ref) => {
|
|
21536
|
-
const props = mergeProps(defaultProps$
|
|
21701
|
+
const props = mergeProps(defaultProps$v, p);
|
|
21537
21702
|
const [value, setValue2] = usePropsValue(props);
|
|
21538
21703
|
const [hasFocus, setHasFocus] = useState(false);
|
|
21539
21704
|
const compositionStartRef = useRef(false);
|
|
@@ -21593,10 +21758,10 @@ const Input = forwardRef((p, ref) => {
|
|
|
21593
21758
|
}
|
|
21594
21759
|
})();
|
|
21595
21760
|
return withNativeProps(props, React__default.createElement("div", {
|
|
21596
|
-
className: classNames(`${classPrefix$
|
|
21761
|
+
className: classNames(`${classPrefix$A}`, props.disabled && `${classPrefix$A}-disabled`)
|
|
21597
21762
|
}, React__default.createElement("input", {
|
|
21598
21763
|
ref: nativeInputRef,
|
|
21599
|
-
className: `${classPrefix$
|
|
21764
|
+
className: `${classPrefix$A}-element`,
|
|
21600
21765
|
value,
|
|
21601
21766
|
onChange: (e) => {
|
|
21602
21767
|
setValue2(e.target.value);
|
|
@@ -21647,7 +21812,7 @@ const Input = forwardRef((p, ref) => {
|
|
|
21647
21812
|
"aria-valuemin": props["aria-valuemin"],
|
|
21648
21813
|
"aria-label": props["aria-label"]
|
|
21649
21814
|
}), shouldShowClear && React__default.createElement("div", {
|
|
21650
|
-
className: `${classPrefix$
|
|
21815
|
+
className: `${classPrefix$A}-clear`,
|
|
21651
21816
|
onMouseDown: (e) => {
|
|
21652
21817
|
e.preventDefault();
|
|
21653
21818
|
},
|
|
@@ -21664,7 +21829,7 @@ const Input = forwardRef((p, ref) => {
|
|
|
21664
21829
|
}, React__default.createElement(CloseCircleFill, null))));
|
|
21665
21830
|
});
|
|
21666
21831
|
const jumboTabs = "";
|
|
21667
|
-
const classPrefix$
|
|
21832
|
+
const classPrefix$z = `adm-jumbo-tabs`;
|
|
21668
21833
|
const JumboTab = () => {
|
|
21669
21834
|
return null;
|
|
21670
21835
|
};
|
|
@@ -21705,19 +21870,19 @@ const JumboTabs = (props) => {
|
|
|
21705
21870
|
animate(true);
|
|
21706
21871
|
}, rootRef);
|
|
21707
21872
|
return withNativeProps(props, React__default.createElement("div", {
|
|
21708
|
-
className: classPrefix$
|
|
21873
|
+
className: classPrefix$z,
|
|
21709
21874
|
ref: rootRef
|
|
21710
21875
|
}, React__default.createElement("div", {
|
|
21711
|
-
className: `${classPrefix$
|
|
21876
|
+
className: `${classPrefix$z}-header`
|
|
21712
21877
|
}, React__default.createElement(ScrollMask, {
|
|
21713
21878
|
scrollTrackRef: tabListContainerRef
|
|
21714
21879
|
}), React__default.createElement(animated.div, {
|
|
21715
|
-
className: `${classPrefix$
|
|
21880
|
+
className: `${classPrefix$z}-tab-list`,
|
|
21716
21881
|
ref: tabListContainerRef,
|
|
21717
21882
|
scrollLeft
|
|
21718
21883
|
}, panes.map((pane) => withNativeProps(pane.props, React__default.createElement("div", {
|
|
21719
21884
|
key: pane.key,
|
|
21720
|
-
className: `${classPrefix$
|
|
21885
|
+
className: `${classPrefix$z}-tab-wrapper`
|
|
21721
21886
|
}, React__default.createElement("div", {
|
|
21722
21887
|
onClick: () => {
|
|
21723
21888
|
const {
|
|
@@ -21730,14 +21895,14 @@ const JumboTabs = (props) => {
|
|
|
21730
21895
|
}
|
|
21731
21896
|
setActiveKey(key.toString());
|
|
21732
21897
|
},
|
|
21733
|
-
className: classNames(`${classPrefix$
|
|
21734
|
-
[`${classPrefix$
|
|
21735
|
-
[`${classPrefix$
|
|
21898
|
+
className: classNames(`${classPrefix$z}-tab`, {
|
|
21899
|
+
[`${classPrefix$z}-tab-active`]: pane.key === activeKey,
|
|
21900
|
+
[`${classPrefix$z}-tab-disabled`]: pane.props.disabled
|
|
21736
21901
|
})
|
|
21737
21902
|
}, React__default.createElement("div", {
|
|
21738
|
-
className: `${classPrefix$
|
|
21903
|
+
className: `${classPrefix$z}-tab-title`
|
|
21739
21904
|
}, pane.props.title), React__default.createElement("div", {
|
|
21740
|
-
className: `${classPrefix$
|
|
21905
|
+
className: `${classPrefix$z}-tab-description`
|
|
21741
21906
|
}, pane.props.description))))))), panes.map((pane) => {
|
|
21742
21907
|
if (pane.props.children === void 0) {
|
|
21743
21908
|
return null;
|
|
@@ -21749,7 +21914,7 @@ const JumboTabs = (props) => {
|
|
|
21749
21914
|
forceRender: pane.props.forceRender,
|
|
21750
21915
|
destroyOnClose: pane.props.destroyOnClose
|
|
21751
21916
|
}, React__default.createElement("div", {
|
|
21752
|
-
className: `${classPrefix$
|
|
21917
|
+
className: `${classPrefix$z}-content`,
|
|
21753
21918
|
style: {
|
|
21754
21919
|
display: active ? "block" : "none"
|
|
21755
21920
|
}
|
|
@@ -21778,14 +21943,14 @@ const ModalActionButton = (props) => {
|
|
|
21778
21943
|
disabled: action.disabled
|
|
21779
21944
|
}, action.text));
|
|
21780
21945
|
};
|
|
21781
|
-
const defaultProps$
|
|
21946
|
+
const defaultProps$u = {
|
|
21782
21947
|
actions: [],
|
|
21783
21948
|
closeOnAction: false,
|
|
21784
21949
|
closeOnMaskClick: false,
|
|
21785
21950
|
getContainer: null
|
|
21786
21951
|
};
|
|
21787
21952
|
const Modal = (p) => {
|
|
21788
|
-
const props = mergeProps(defaultProps$
|
|
21953
|
+
const props = mergeProps(defaultProps$u, p);
|
|
21789
21954
|
const element = React__default.createElement(React__default.Fragment, null, !!props.image && React__default.createElement("div", {
|
|
21790
21955
|
className: cls("image-container")
|
|
21791
21956
|
}, React__default.createElement(Image$1, {
|
|
@@ -21872,7 +22037,7 @@ function alert(p) {
|
|
|
21872
22037
|
}));
|
|
21873
22038
|
});
|
|
21874
22039
|
}
|
|
21875
|
-
const defaultProps$
|
|
22040
|
+
const defaultProps$t = {
|
|
21876
22041
|
confirmText: "\u786E\u8BA4",
|
|
21877
22042
|
cancelText: "\u53D6\u6D88"
|
|
21878
22043
|
};
|
|
@@ -21880,7 +22045,7 @@ function confirm(p) {
|
|
|
21880
22045
|
const {
|
|
21881
22046
|
locale
|
|
21882
22047
|
} = getDefaultConfig();
|
|
21883
|
-
const props = mergeProps(defaultProps$
|
|
22048
|
+
const props = mergeProps(defaultProps$t, {
|
|
21884
22049
|
confirmText: locale.common.confirm,
|
|
21885
22050
|
cancelText: locale.common.cancel
|
|
21886
22051
|
}, p);
|
|
@@ -21925,45 +22090,45 @@ const index$7 = attachPropertiesToComponent(Modal, {
|
|
|
21925
22090
|
clear: clear$1
|
|
21926
22091
|
});
|
|
21927
22092
|
const navBar = "";
|
|
21928
|
-
const classPrefix$
|
|
21929
|
-
const defaultProps$
|
|
22093
|
+
const classPrefix$y = `adm-nav-bar`;
|
|
22094
|
+
const defaultProps$s = {
|
|
21930
22095
|
back: "",
|
|
21931
22096
|
backArrow: true
|
|
21932
22097
|
};
|
|
21933
22098
|
const NavBar = (p) => {
|
|
21934
|
-
const props = mergeProps(defaultProps$
|
|
22099
|
+
const props = mergeProps(defaultProps$s, p);
|
|
21935
22100
|
const {
|
|
21936
22101
|
back,
|
|
21937
22102
|
backArrow
|
|
21938
22103
|
} = props;
|
|
21939
22104
|
return withNativeProps(props, React__default.createElement("div", {
|
|
21940
|
-
className: classNames(classPrefix$
|
|
22105
|
+
className: classNames(classPrefix$y)
|
|
21941
22106
|
}, React__default.createElement("div", {
|
|
21942
|
-
className: `${classPrefix$
|
|
22107
|
+
className: `${classPrefix$y}-left`,
|
|
21943
22108
|
role: "button"
|
|
21944
22109
|
}, back !== null && React__default.createElement("div", {
|
|
21945
|
-
className: `${classPrefix$
|
|
22110
|
+
className: `${classPrefix$y}-back`,
|
|
21946
22111
|
onClick: props.onBack
|
|
21947
22112
|
}, backArrow && React__default.createElement("span", {
|
|
21948
|
-
className: `${classPrefix$
|
|
22113
|
+
className: `${classPrefix$y}-back-arrow`
|
|
21949
22114
|
}, backArrow === true ? React__default.createElement(LeftOutline, null) : backArrow), React__default.createElement("span", {
|
|
21950
22115
|
"aria-hidden": "true"
|
|
21951
22116
|
}, back)), props.left), React__default.createElement("div", {
|
|
21952
|
-
className: `${classPrefix$
|
|
22117
|
+
className: `${classPrefix$y}-title`
|
|
21953
22118
|
}, props.children), React__default.createElement("div", {
|
|
21954
|
-
className: `${classPrefix$
|
|
22119
|
+
className: `${classPrefix$y}-right`
|
|
21955
22120
|
}, props.right)));
|
|
21956
22121
|
};
|
|
21957
22122
|
const noticeBar = "";
|
|
21958
|
-
const classPrefix$
|
|
21959
|
-
const defaultProps$
|
|
22123
|
+
const classPrefix$x = `adm-notice-bar`;
|
|
22124
|
+
const defaultProps$r = {
|
|
21960
22125
|
color: "default",
|
|
21961
22126
|
delay: 2e3,
|
|
21962
22127
|
speed: 50,
|
|
21963
22128
|
icon: React__default.createElement(SoundOutline, null)
|
|
21964
22129
|
};
|
|
21965
22130
|
const NoticeBar = memo((p) => {
|
|
21966
|
-
const props = mergeProps(defaultProps$
|
|
22131
|
+
const props = mergeProps(defaultProps$r, p);
|
|
21967
22132
|
const containerRef = useRef(null);
|
|
21968
22133
|
const textRef = useRef(null);
|
|
21969
22134
|
const [visible, setVisible] = useState(true);
|
|
@@ -22014,30 +22179,30 @@ const NoticeBar = memo((p) => {
|
|
|
22014
22179
|
if (!visible)
|
|
22015
22180
|
return null;
|
|
22016
22181
|
return withNativeProps(props, React__default.createElement("div", {
|
|
22017
|
-
className: classNames(classPrefix$
|
|
22182
|
+
className: classNames(classPrefix$x, `${classPrefix$x}-${props.color}`)
|
|
22018
22183
|
}, props.icon && React__default.createElement("span", {
|
|
22019
|
-
className: `${classPrefix$
|
|
22184
|
+
className: `${classPrefix$x}-left`
|
|
22020
22185
|
}, props.icon), React__default.createElement("span", {
|
|
22021
22186
|
ref: containerRef,
|
|
22022
|
-
className: `${classPrefix$
|
|
22187
|
+
className: `${classPrefix$x}-content`
|
|
22023
22188
|
}, React__default.createElement("span", {
|
|
22024
22189
|
onTransitionEnd: () => {
|
|
22025
22190
|
animatingRef.current = false;
|
|
22026
22191
|
start2();
|
|
22027
22192
|
},
|
|
22028
22193
|
ref: textRef,
|
|
22029
|
-
className: `${classPrefix$
|
|
22194
|
+
className: `${classPrefix$x}-content-inner`
|
|
22030
22195
|
}, props.content)), (props.closeable || props.extra) && React__default.createElement("span", {
|
|
22031
|
-
className: `${classPrefix$
|
|
22196
|
+
className: `${classPrefix$x}-right`
|
|
22032
22197
|
}, props.extra, props.closeable && React__default.createElement("div", {
|
|
22033
|
-
className: `${classPrefix$
|
|
22198
|
+
className: `${classPrefix$x}-close`,
|
|
22034
22199
|
onClick: () => {
|
|
22035
22200
|
var _a;
|
|
22036
22201
|
setVisible(false);
|
|
22037
22202
|
(_a = props.onClose) === null || _a === void 0 ? void 0 : _a.call(props);
|
|
22038
22203
|
}
|
|
22039
22204
|
}, React__default.createElement(CloseOutline, {
|
|
22040
|
-
className: `${classPrefix$
|
|
22205
|
+
className: `${classPrefix$x}-close-icon`
|
|
22041
22206
|
})))));
|
|
22042
22207
|
});
|
|
22043
22208
|
const numberKeyboard = "";
|
|
@@ -22049,8 +22214,8 @@ function shuffle(array4) {
|
|
|
22049
22214
|
}
|
|
22050
22215
|
return result2;
|
|
22051
22216
|
}
|
|
22052
|
-
const classPrefix$
|
|
22053
|
-
const defaultProps$
|
|
22217
|
+
const classPrefix$w = "adm-number-keyboard";
|
|
22218
|
+
const defaultProps$q = {
|
|
22054
22219
|
defaultVisible: false,
|
|
22055
22220
|
randomOrder: false,
|
|
22056
22221
|
showCloseButton: true,
|
|
@@ -22061,7 +22226,7 @@ const defaultProps$p = {
|
|
|
22061
22226
|
forceRender: false
|
|
22062
22227
|
};
|
|
22063
22228
|
const NumberKeyboard = (p) => {
|
|
22064
|
-
const props = mergeProps(defaultProps$
|
|
22229
|
+
const props = mergeProps(defaultProps$q, p);
|
|
22065
22230
|
const {
|
|
22066
22231
|
visible,
|
|
22067
22232
|
title,
|
|
@@ -22128,13 +22293,13 @@ const NumberKeyboard = (p) => {
|
|
|
22128
22293
|
if (!showCloseButton && !title)
|
|
22129
22294
|
return null;
|
|
22130
22295
|
return React__default.createElement("div", {
|
|
22131
|
-
className: classNames(`${classPrefix$
|
|
22132
|
-
[`${classPrefix$
|
|
22296
|
+
className: classNames(`${classPrefix$w}-header`, {
|
|
22297
|
+
[`${classPrefix$w}-header-with-title`]: !!title
|
|
22133
22298
|
})
|
|
22134
22299
|
}, title && React__default.createElement("div", {
|
|
22135
|
-
className: `${classPrefix$
|
|
22300
|
+
className: `${classPrefix$w}-title`
|
|
22136
22301
|
}, title), showCloseButton && React__default.createElement("span", {
|
|
22137
|
-
className: `${classPrefix$
|
|
22302
|
+
className: `${classPrefix$w}-header-close-button`,
|
|
22138
22303
|
onClick: () => {
|
|
22139
22304
|
var _a;
|
|
22140
22305
|
(_a = props.onClose) === null || _a === void 0 ? void 0 : _a.call(props);
|
|
@@ -22145,10 +22310,10 @@ const NumberKeyboard = (p) => {
|
|
|
22145
22310
|
};
|
|
22146
22311
|
const renderKey = (key, index2) => {
|
|
22147
22312
|
const isNumberKey = /^\d$/.test(key);
|
|
22148
|
-
const className = classNames(`${classPrefix$
|
|
22149
|
-
[`${classPrefix$
|
|
22150
|
-
[`${classPrefix$
|
|
22151
|
-
[`${classPrefix$
|
|
22313
|
+
const className = classNames(`${classPrefix$w}-key`, {
|
|
22314
|
+
[`${classPrefix$w}-key-number`]: isNumberKey,
|
|
22315
|
+
[`${classPrefix$w}-key-sign`]: !isNumberKey && key,
|
|
22316
|
+
[`${classPrefix$w}-key-mid`]: index2 === 9 && !!confirmText && keys2.length < 12
|
|
22152
22317
|
});
|
|
22153
22318
|
const ariaProps = key ? {
|
|
22154
22319
|
role: "button",
|
|
@@ -22176,26 +22341,26 @@ const NumberKeyboard = (p) => {
|
|
|
22176
22341
|
mask: false,
|
|
22177
22342
|
afterClose: props.afterClose,
|
|
22178
22343
|
afterShow: props.afterShow,
|
|
22179
|
-
className: `${classPrefix$
|
|
22344
|
+
className: `${classPrefix$w}-popup`,
|
|
22180
22345
|
stopPropagation: props.stopPropagation,
|
|
22181
22346
|
destroyOnClose: props.destroyOnClose,
|
|
22182
22347
|
forceRender: props.forceRender
|
|
22183
22348
|
}, withNativeProps(props, React__default.createElement("div", {
|
|
22184
22349
|
ref: keyboardRef,
|
|
22185
|
-
className: classPrefix$
|
|
22350
|
+
className: classPrefix$w,
|
|
22186
22351
|
onMouseDown: (e) => {
|
|
22187
22352
|
e.preventDefault();
|
|
22188
22353
|
}
|
|
22189
22354
|
}, renderHeader(), React__default.createElement("div", {
|
|
22190
|
-
className: `${classPrefix$
|
|
22355
|
+
className: `${classPrefix$w}-wrapper`
|
|
22191
22356
|
}, React__default.createElement("div", {
|
|
22192
|
-
className: classNames(`${classPrefix$
|
|
22193
|
-
[`${classPrefix$
|
|
22357
|
+
className: classNames(`${classPrefix$w}-main`, {
|
|
22358
|
+
[`${classPrefix$w}-main-confirmed-style`]: !!confirmText
|
|
22194
22359
|
})
|
|
22195
22360
|
}, keys2.map(renderKey)), !!confirmText && React__default.createElement("div", {
|
|
22196
|
-
className: `${classPrefix$
|
|
22361
|
+
className: `${classPrefix$w}-confirm`
|
|
22197
22362
|
}, React__default.createElement("div", {
|
|
22198
|
-
className: `${classPrefix$
|
|
22363
|
+
className: `${classPrefix$w}-key ${classPrefix$w}-key-extra ${classPrefix$w}-key-bs`,
|
|
22199
22364
|
onTouchStart: () => {
|
|
22200
22365
|
onBackspacePressStart();
|
|
22201
22366
|
},
|
|
@@ -22206,39 +22371,39 @@ const NumberKeyboard = (p) => {
|
|
|
22206
22371
|
title: "BACKSPACE",
|
|
22207
22372
|
role: "button"
|
|
22208
22373
|
}, React__default.createElement(TextDeletionOutline, null)), React__default.createElement("div", {
|
|
22209
|
-
className: `${classPrefix$
|
|
22374
|
+
className: `${classPrefix$w}-key ${classPrefix$w}-key-extra ${classPrefix$w}-key-ok`,
|
|
22210
22375
|
onTouchEnd: (e) => onKeyPress(e, "OK"),
|
|
22211
22376
|
role: "button"
|
|
22212
22377
|
}, confirmText))), props.safeArea && React__default.createElement("div", {
|
|
22213
|
-
className: `${classPrefix$
|
|
22378
|
+
className: `${classPrefix$w}-footer`
|
|
22214
22379
|
}, React__default.createElement(SafeArea, {
|
|
22215
22380
|
position: "bottom"
|
|
22216
22381
|
})))));
|
|
22217
22382
|
};
|
|
22218
22383
|
const pageIndicator = "";
|
|
22219
|
-
const classPrefix$
|
|
22220
|
-
const defaultProps$
|
|
22384
|
+
const classPrefix$v = `adm-page-indicator`;
|
|
22385
|
+
const defaultProps$p = {
|
|
22221
22386
|
color: "primary",
|
|
22222
22387
|
direction: "horizontal"
|
|
22223
22388
|
};
|
|
22224
22389
|
const PageIndicator = memo((p) => {
|
|
22225
|
-
const props = mergeProps(defaultProps$
|
|
22390
|
+
const props = mergeProps(defaultProps$p, p);
|
|
22226
22391
|
const dots = [];
|
|
22227
22392
|
for (let i = 0; i < props.total; i++) {
|
|
22228
22393
|
dots.push(React__default.createElement("div", {
|
|
22229
22394
|
key: i,
|
|
22230
|
-
className: classNames(`${classPrefix$
|
|
22231
|
-
[`${classPrefix$
|
|
22395
|
+
className: classNames(`${classPrefix$v}-dot`, {
|
|
22396
|
+
[`${classPrefix$v}-dot-active`]: props.current === i
|
|
22232
22397
|
})
|
|
22233
22398
|
}));
|
|
22234
22399
|
}
|
|
22235
22400
|
return withNativeProps(props, React__default.createElement("div", {
|
|
22236
|
-
className: classNames(classPrefix$
|
|
22401
|
+
className: classNames(classPrefix$v, `${classPrefix$v}-${props.direction}`, `${classPrefix$v}-color-${props.color}`)
|
|
22237
22402
|
}, dots));
|
|
22238
22403
|
});
|
|
22239
22404
|
const passcodeInput = "";
|
|
22240
|
-
const classPrefix$
|
|
22241
|
-
const defaultProps$
|
|
22405
|
+
const classPrefix$u = "adm-passcode-input";
|
|
22406
|
+
const defaultProps$o = {
|
|
22242
22407
|
defaultValue: "",
|
|
22243
22408
|
length: 6,
|
|
22244
22409
|
plain: false,
|
|
@@ -22247,8 +22412,8 @@ const defaultProps$n = {
|
|
|
22247
22412
|
caret: true
|
|
22248
22413
|
};
|
|
22249
22414
|
const PasscodeInput = forwardRef((p, ref) => {
|
|
22250
|
-
const props = mergeProps(defaultProps$
|
|
22251
|
-
const cellLength = props.length > 0 && props.length < Infinity ? Math.floor(props.length) : defaultProps$
|
|
22415
|
+
const props = mergeProps(defaultProps$o, p);
|
|
22416
|
+
const cellLength = props.length > 0 && props.length < Infinity ? Math.floor(props.length) : defaultProps$o.length;
|
|
22252
22417
|
const {
|
|
22253
22418
|
locale
|
|
22254
22419
|
} = useConfig();
|
|
@@ -22308,20 +22473,20 @@ const PasscodeInput = forwardRef((p, ref) => {
|
|
|
22308
22473
|
const focusedIndex = bound(chars.length, 0, cellLength - 1);
|
|
22309
22474
|
for (let i = 0; i < cellLength; i++) {
|
|
22310
22475
|
cells.push(React__default.createElement("div", {
|
|
22311
|
-
className: classNames(`${classPrefix$
|
|
22312
|
-
[`${classPrefix$
|
|
22313
|
-
[`${classPrefix$
|
|
22314
|
-
[`${classPrefix$
|
|
22476
|
+
className: classNames(`${classPrefix$u}-cell`, {
|
|
22477
|
+
[`${classPrefix$u}-cell-caret`]: props.caret && caretIndex === i && focused,
|
|
22478
|
+
[`${classPrefix$u}-cell-focused`]: focusedIndex === i && focused,
|
|
22479
|
+
[`${classPrefix$u}-cell-dot`]: !props.plain && chars[i]
|
|
22315
22480
|
}),
|
|
22316
22481
|
key: i
|
|
22317
22482
|
}, chars[i] && props.plain ? chars[i] : ""));
|
|
22318
22483
|
}
|
|
22319
22484
|
return cells;
|
|
22320
22485
|
};
|
|
22321
|
-
const cls2 = classNames(classPrefix$
|
|
22322
|
-
[`${classPrefix$
|
|
22323
|
-
[`${classPrefix$
|
|
22324
|
-
[`${classPrefix$
|
|
22486
|
+
const cls2 = classNames(classPrefix$u, {
|
|
22487
|
+
[`${classPrefix$u}-focused`]: focused,
|
|
22488
|
+
[`${classPrefix$u}-error`]: props.error,
|
|
22489
|
+
[`${classPrefix$u}-seperated`]: props.seperated
|
|
22325
22490
|
});
|
|
22326
22491
|
return React__default.createElement(React__default.Fragment, null, withNativeProps(props, React__default.createElement("div", {
|
|
22327
22492
|
ref: rootRef,
|
|
@@ -22332,10 +22497,10 @@ const PasscodeInput = forwardRef((p, ref) => {
|
|
|
22332
22497
|
role: "button",
|
|
22333
22498
|
"aria-label": locale.PasscodeInput.name
|
|
22334
22499
|
}, React__default.createElement("div", {
|
|
22335
|
-
className: `${classPrefix$
|
|
22500
|
+
className: `${classPrefix$u}-cell-container`
|
|
22336
22501
|
}, renderCells()), React__default.createElement("input", {
|
|
22337
22502
|
ref: nativeInputRef,
|
|
22338
|
-
className: `${classPrefix$
|
|
22503
|
+
className: `${classPrefix$u}-native-input`,
|
|
22339
22504
|
value,
|
|
22340
22505
|
type: "text",
|
|
22341
22506
|
pattern: "[0-9]*",
|
|
@@ -22361,14 +22526,14 @@ const PasscodeInput = forwardRef((p, ref) => {
|
|
|
22361
22526
|
}));
|
|
22362
22527
|
});
|
|
22363
22528
|
const progressBar = "";
|
|
22364
|
-
const classPrefix$
|
|
22365
|
-
const defaultProps$
|
|
22529
|
+
const classPrefix$t = `adm-progress-bar`;
|
|
22530
|
+
const defaultProps$n = {
|
|
22366
22531
|
percent: 0,
|
|
22367
22532
|
rounded: true,
|
|
22368
22533
|
text: false
|
|
22369
22534
|
};
|
|
22370
22535
|
const ProgressBar = (p) => {
|
|
22371
|
-
const props = mergeProps(defaultProps$
|
|
22536
|
+
const props = mergeProps(defaultProps$n, p);
|
|
22372
22537
|
const fillStyle = {
|
|
22373
22538
|
width: `${props.percent}%`
|
|
22374
22539
|
};
|
|
@@ -22382,18 +22547,18 @@ const ProgressBar = (p) => {
|
|
|
22382
22547
|
return props.text;
|
|
22383
22548
|
}();
|
|
22384
22549
|
return withNativeProps(props, React__default.createElement("div", {
|
|
22385
|
-
className: classNames(classPrefix$
|
|
22550
|
+
className: classNames(classPrefix$t, props.rounded && `${classPrefix$t}-rounded`)
|
|
22386
22551
|
}, React__default.createElement("div", {
|
|
22387
|
-
className: `${classPrefix$
|
|
22552
|
+
className: `${classPrefix$t}-trail`
|
|
22388
22553
|
}, React__default.createElement("div", {
|
|
22389
|
-
className: `${classPrefix$
|
|
22554
|
+
className: `${classPrefix$t}-fill`,
|
|
22390
22555
|
style: fillStyle
|
|
22391
22556
|
})), isNodeWithContent(textElement) && React__default.createElement("div", {
|
|
22392
|
-
className: `${classPrefix$
|
|
22557
|
+
className: `${classPrefix$t}-text`
|
|
22393
22558
|
}, textElement)));
|
|
22394
22559
|
};
|
|
22395
22560
|
const progressCircle = "";
|
|
22396
|
-
const classPrefix$
|
|
22561
|
+
const classPrefix$s = `adm-progress-circle`;
|
|
22397
22562
|
const ProgressCircle = (p) => {
|
|
22398
22563
|
const props = mergeProps({
|
|
22399
22564
|
percent: 0
|
|
@@ -22402,26 +22567,26 @@ const ProgressCircle = (p) => {
|
|
|
22402
22567
|
"--percent": props.percent.toString()
|
|
22403
22568
|
};
|
|
22404
22569
|
return withNativeProps(props, React__default.createElement("div", {
|
|
22405
|
-
className: `${classPrefix$
|
|
22570
|
+
className: `${classPrefix$s}`,
|
|
22406
22571
|
style
|
|
22407
22572
|
}, React__default.createElement("div", {
|
|
22408
|
-
className: `${classPrefix$
|
|
22573
|
+
className: `${classPrefix$s}-content`
|
|
22409
22574
|
}, React__default.createElement("svg", {
|
|
22410
|
-
className: `${classPrefix$
|
|
22575
|
+
className: `${classPrefix$s}-svg`
|
|
22411
22576
|
}, React__default.createElement("circle", {
|
|
22412
|
-
className: `${classPrefix$
|
|
22577
|
+
className: `${classPrefix$s}-track`,
|
|
22413
22578
|
fill: "transparent"
|
|
22414
22579
|
}), React__default.createElement("circle", {
|
|
22415
|
-
className: `${classPrefix$
|
|
22580
|
+
className: `${classPrefix$s}-fill`,
|
|
22416
22581
|
fill: "transparent"
|
|
22417
22582
|
})), React__default.createElement("div", {
|
|
22418
|
-
className: `${classPrefix$
|
|
22583
|
+
className: `${classPrefix$s}-info`
|
|
22419
22584
|
}, props.children))));
|
|
22420
22585
|
};
|
|
22421
22586
|
const pullToRefresh = "";
|
|
22422
22587
|
const sleep = (time) => new Promise((resolve) => setTimeout(resolve, time));
|
|
22423
|
-
const classPrefix$
|
|
22424
|
-
const defaultProps$
|
|
22588
|
+
const classPrefix$r = `adm-pull-to-refresh`;
|
|
22589
|
+
const defaultProps$m = {
|
|
22425
22590
|
pullingText: "\u4E0B\u62C9\u5237\u65B0",
|
|
22426
22591
|
canReleaseText: "\u91CA\u653E\u7ACB\u5373\u5237\u65B0",
|
|
22427
22592
|
refreshingText: "\u52A0\u8F7D\u4E2D...",
|
|
@@ -22436,7 +22601,7 @@ const PullToRefresh = (p) => {
|
|
|
22436
22601
|
const {
|
|
22437
22602
|
locale
|
|
22438
22603
|
} = useConfig();
|
|
22439
|
-
const props = mergeProps(defaultProps$
|
|
22604
|
+
const props = mergeProps(defaultProps$m, {
|
|
22440
22605
|
refreshingText: `${locale.common.loading}...`,
|
|
22441
22606
|
pullingText: locale.PullToRefresh.pulling,
|
|
22442
22607
|
canReleaseText: locale.PullToRefresh.canRelease,
|
|
@@ -22573,27 +22738,27 @@ const PullToRefresh = (p) => {
|
|
|
22573
22738
|
};
|
|
22574
22739
|
return React__default.createElement(animated.div, {
|
|
22575
22740
|
ref: elementRef,
|
|
22576
|
-
className: classPrefix$
|
|
22741
|
+
className: classPrefix$r
|
|
22577
22742
|
}, React__default.createElement(animated.div, {
|
|
22578
22743
|
style: springStyles,
|
|
22579
|
-
className: `${classPrefix$
|
|
22744
|
+
className: `${classPrefix$r}-head`
|
|
22580
22745
|
}, React__default.createElement("div", {
|
|
22581
|
-
className: `${classPrefix$
|
|
22746
|
+
className: `${classPrefix$r}-head-content`,
|
|
22582
22747
|
style: {
|
|
22583
22748
|
height: headHeight
|
|
22584
22749
|
}
|
|
22585
22750
|
}, renderStatusText())), React__default.createElement("div", {
|
|
22586
|
-
className: `${classPrefix$
|
|
22751
|
+
className: `${classPrefix$r}-content`
|
|
22587
22752
|
}, props.children));
|
|
22588
22753
|
};
|
|
22589
22754
|
const radio = "";
|
|
22590
22755
|
const RadioGroupContext = createContext(null);
|
|
22591
|
-
const defaultProps$
|
|
22756
|
+
const defaultProps$l = {
|
|
22592
22757
|
disabled: false,
|
|
22593
22758
|
defaultValue: null
|
|
22594
22759
|
};
|
|
22595
22760
|
const Group = (p) => {
|
|
22596
|
-
const props = mergeProps(defaultProps$
|
|
22761
|
+
const props = mergeProps(defaultProps$l, p);
|
|
22597
22762
|
const [value, setValue2] = usePropsValue({
|
|
22598
22763
|
value: props.value,
|
|
22599
22764
|
defaultValue: props.defaultValue,
|
|
@@ -22616,12 +22781,12 @@ const Group = (p) => {
|
|
|
22616
22781
|
}
|
|
22617
22782
|
}, props.children);
|
|
22618
22783
|
};
|
|
22619
|
-
const classPrefix$
|
|
22620
|
-
const defaultProps$
|
|
22784
|
+
const classPrefix$q = `adm-radio`;
|
|
22785
|
+
const defaultProps$k = {
|
|
22621
22786
|
defaultChecked: false
|
|
22622
22787
|
};
|
|
22623
22788
|
const Radio = (p) => {
|
|
22624
|
-
const props = mergeProps(defaultProps$
|
|
22789
|
+
const props = mergeProps(defaultProps$k, p);
|
|
22625
22790
|
const groupContext = useContext(RadioGroupContext);
|
|
22626
22791
|
let [checked, setChecked] = usePropsValue({
|
|
22627
22792
|
value: props.checked,
|
|
@@ -22656,18 +22821,18 @@ const Radio = (p) => {
|
|
|
22656
22821
|
const renderIcon = () => {
|
|
22657
22822
|
if (props.icon) {
|
|
22658
22823
|
return React__default.createElement("div", {
|
|
22659
|
-
className: `${classPrefix$
|
|
22824
|
+
className: `${classPrefix$q}-custom-icon`
|
|
22660
22825
|
}, props.icon(checked));
|
|
22661
22826
|
}
|
|
22662
22827
|
return React__default.createElement("div", {
|
|
22663
|
-
className: `${classPrefix$
|
|
22828
|
+
className: `${classPrefix$q}-icon`
|
|
22664
22829
|
}, checked && React__default.createElement(CheckIcon, null));
|
|
22665
22830
|
};
|
|
22666
22831
|
return withNativeProps(props, React__default.createElement("label", {
|
|
22667
|
-
className: classNames(classPrefix$
|
|
22668
|
-
[`${classPrefix$
|
|
22669
|
-
[`${classPrefix$
|
|
22670
|
-
[`${classPrefix$
|
|
22832
|
+
className: classNames(classPrefix$q, {
|
|
22833
|
+
[`${classPrefix$q}-checked`]: checked,
|
|
22834
|
+
[`${classPrefix$q}-disabled`]: disabled,
|
|
22835
|
+
[`${classPrefix$q}-block`]: props.block
|
|
22671
22836
|
})
|
|
22672
22837
|
}, React__default.createElement(NativeInput, {
|
|
22673
22838
|
type: "radio",
|
|
@@ -22676,7 +22841,7 @@ const Radio = (p) => {
|
|
|
22676
22841
|
disabled,
|
|
22677
22842
|
id: props.id
|
|
22678
22843
|
}), renderIcon(), props.children && React__default.createElement("div", {
|
|
22679
|
-
className: `${classPrefix$
|
|
22844
|
+
className: `${classPrefix$q}-content`
|
|
22680
22845
|
}, props.children)));
|
|
22681
22846
|
};
|
|
22682
22847
|
const index$6 = attachPropertiesToComponent(Radio, {
|
|
@@ -22697,8 +22862,8 @@ const Star = () => {
|
|
|
22697
22862
|
fillRule: "evenodd"
|
|
22698
22863
|
}));
|
|
22699
22864
|
};
|
|
22700
|
-
const classPrefix$
|
|
22701
|
-
const defaultProps$
|
|
22865
|
+
const classPrefix$p = `adm-rate`;
|
|
22866
|
+
const defaultProps$j = {
|
|
22702
22867
|
count: 5,
|
|
22703
22868
|
allowHalf: false,
|
|
22704
22869
|
character: React__default.createElement(Star, null),
|
|
@@ -22707,16 +22872,16 @@ const defaultProps$i = {
|
|
|
22707
22872
|
allowClear: true
|
|
22708
22873
|
};
|
|
22709
22874
|
const Rate = (p) => {
|
|
22710
|
-
const props = mergeProps(defaultProps$
|
|
22875
|
+
const props = mergeProps(defaultProps$j, p);
|
|
22711
22876
|
const [value, setValue2] = usePropsValue(props);
|
|
22712
22877
|
const containerRef = useRef(null);
|
|
22713
22878
|
const starList = Array(props.count).fill(null);
|
|
22714
22879
|
function renderStar(v, half) {
|
|
22715
22880
|
return React__default.createElement("div", {
|
|
22716
|
-
className: classNames(`${classPrefix$
|
|
22717
|
-
[`${classPrefix$
|
|
22718
|
-
[`${classPrefix$
|
|
22719
|
-
[`${classPrefix$
|
|
22881
|
+
className: classNames(`${classPrefix$p}-star`, {
|
|
22882
|
+
[`${classPrefix$p}-star-active`]: value >= v,
|
|
22883
|
+
[`${classPrefix$p}-star-half`]: half,
|
|
22884
|
+
[`${classPrefix$p}-star-readonly`]: props.readOnly
|
|
22720
22885
|
}),
|
|
22721
22886
|
role: "radio",
|
|
22722
22887
|
"aria-checked": value >= v,
|
|
@@ -22752,17 +22917,19 @@ const Rate = (p) => {
|
|
|
22752
22917
|
filterTaps: true
|
|
22753
22918
|
});
|
|
22754
22919
|
return withNativeProps(props, React__default.createElement("div", Object.assign({
|
|
22755
|
-
className: classPrefix$
|
|
22920
|
+
className: classNames(classPrefix$p, {
|
|
22921
|
+
[`${classPrefix$p}-half`]: props.allowHalf
|
|
22922
|
+
}),
|
|
22756
22923
|
role: "radiogroup",
|
|
22757
22924
|
"aria-readonly": props.readOnly,
|
|
22758
22925
|
ref: containerRef
|
|
22759
22926
|
}, bind()), starList.map((_, i) => React__default.createElement("div", {
|
|
22760
22927
|
key: i,
|
|
22761
|
-
className: classNames(`${classPrefix$
|
|
22928
|
+
className: classNames(`${classPrefix$p}-box`)
|
|
22762
22929
|
}, props.allowHalf && renderStar(i + 0.5, true), renderStar(i + 1, false)))));
|
|
22763
22930
|
};
|
|
22764
22931
|
const result = "";
|
|
22765
|
-
const classPrefix$
|
|
22932
|
+
const classPrefix$o = `adm-result`;
|
|
22766
22933
|
const iconRecord$1 = {
|
|
22767
22934
|
success: CheckCircleFill,
|
|
22768
22935
|
error: CloseCircleFill,
|
|
@@ -22770,11 +22937,11 @@ const iconRecord$1 = {
|
|
|
22770
22937
|
waiting: ClockCircleFill,
|
|
22771
22938
|
warning: ExclamationCircleFill
|
|
22772
22939
|
};
|
|
22773
|
-
const defaultProps$
|
|
22940
|
+
const defaultProps$i = {
|
|
22774
22941
|
status: "info"
|
|
22775
22942
|
};
|
|
22776
22943
|
const Result = (p) => {
|
|
22777
|
-
const props = mergeProps(defaultProps$
|
|
22944
|
+
const props = mergeProps(defaultProps$i, p);
|
|
22778
22945
|
const {
|
|
22779
22946
|
status,
|
|
22780
22947
|
title,
|
|
@@ -22785,17 +22952,17 @@ const Result = (p) => {
|
|
|
22785
22952
|
return null;
|
|
22786
22953
|
const resultIcon = icon || React__default.createElement(iconRecord$1[status]);
|
|
22787
22954
|
return withNativeProps(props, React__default.createElement("div", {
|
|
22788
|
-
className: classNames(classPrefix$
|
|
22955
|
+
className: classNames(classPrefix$o, `${classPrefix$o}-${status}`)
|
|
22789
22956
|
}, React__default.createElement("div", {
|
|
22790
|
-
className: `${classPrefix$
|
|
22957
|
+
className: `${classPrefix$o}-icon`
|
|
22791
22958
|
}, resultIcon), React__default.createElement("div", {
|
|
22792
|
-
className: `${classPrefix$
|
|
22959
|
+
className: `${classPrefix$o}-title`
|
|
22793
22960
|
}, title), description ? React__default.createElement("div", {
|
|
22794
|
-
className: `${classPrefix$
|
|
22961
|
+
className: `${classPrefix$o}-description`
|
|
22795
22962
|
}, description) : null));
|
|
22796
22963
|
};
|
|
22797
22964
|
const resultPage = "";
|
|
22798
|
-
const classPrefix$
|
|
22965
|
+
const classPrefix$n = `adm-result-page`;
|
|
22799
22966
|
const iconRecord = {
|
|
22800
22967
|
success: CheckCircleFill,
|
|
22801
22968
|
error: CloseCircleFill,
|
|
@@ -22803,12 +22970,12 @@ const iconRecord = {
|
|
|
22803
22970
|
waiting: ClockCircleFill,
|
|
22804
22971
|
warning: ExclamationCircleFill
|
|
22805
22972
|
};
|
|
22806
|
-
const defaultProps$
|
|
22973
|
+
const defaultProps$h = {
|
|
22807
22974
|
status: "info",
|
|
22808
22975
|
details: []
|
|
22809
22976
|
};
|
|
22810
22977
|
const ResultPage = (p) => {
|
|
22811
|
-
const props = mergeProps(defaultProps$
|
|
22978
|
+
const props = mergeProps(defaultProps$h, p);
|
|
22812
22979
|
const {
|
|
22813
22980
|
status,
|
|
22814
22981
|
title,
|
|
@@ -22825,64 +22992,64 @@ const ResultPage = (p) => {
|
|
|
22825
22992
|
const showSecondaryButton = isNodeWithContent(secondaryButtonText);
|
|
22826
22993
|
const showPrimaryButton = isNodeWithContent(primaryButtonText);
|
|
22827
22994
|
return withNativeProps(props, React__default.createElement("div", {
|
|
22828
|
-
className: classPrefix$
|
|
22995
|
+
className: classPrefix$n
|
|
22829
22996
|
}, React__default.createElement("div", {
|
|
22830
|
-
className: `${classPrefix$
|
|
22997
|
+
className: `${classPrefix$n}-header`
|
|
22831
22998
|
}, React__default.createElement("div", {
|
|
22832
|
-
className: `${classPrefix$
|
|
22999
|
+
className: `${classPrefix$n}-icon`
|
|
22833
23000
|
}, resultIcon), React__default.createElement("div", {
|
|
22834
|
-
className: `${classPrefix$
|
|
23001
|
+
className: `${classPrefix$n}-title`
|
|
22835
23002
|
}, title), isNodeWithContent(description) ? React__default.createElement("div", {
|
|
22836
|
-
className: `${classPrefix$
|
|
23003
|
+
className: `${classPrefix$n}-description`
|
|
22837
23004
|
}, description) : null, details.length ? React__default.createElement("div", {
|
|
22838
|
-
className: `${classPrefix$
|
|
23005
|
+
className: `${classPrefix$n}-details`
|
|
22839
23006
|
}, (collapse2 ? details.slice(0, 3) : details).map((detail, index2) => {
|
|
22840
23007
|
return React__default.createElement("div", {
|
|
22841
|
-
className: classNames(`${classPrefix$
|
|
23008
|
+
className: classNames(`${classPrefix$n}-detail`, detail.bold && `${classPrefix$n}-detail-bold`),
|
|
22842
23009
|
key: index2
|
|
22843
23010
|
}, React__default.createElement("span", null, detail.label), React__default.createElement("span", null, detail.value));
|
|
22844
23011
|
}), details.length > 3 && React__default.createElement("div", {
|
|
22845
23012
|
onClick: () => setCollapse((prev) => !prev)
|
|
22846
23013
|
}, React__default.createElement("div", {
|
|
22847
|
-
className: classNames(`${classPrefix$
|
|
23014
|
+
className: classNames(`${classPrefix$n}-collapse`, !collapse2 && `${classPrefix$n}-collapse-active`)
|
|
22848
23015
|
}))) : null, React__default.createElement("div", {
|
|
22849
|
-
className: `${classPrefix$
|
|
23016
|
+
className: `${classPrefix$n}-bgWrapper`
|
|
22850
23017
|
}, React__default.createElement("div", {
|
|
22851
|
-
className: `${classPrefix$
|
|
23018
|
+
className: `${classPrefix$n}-bg`
|
|
22852
23019
|
}))), React__default.createElement("div", {
|
|
22853
|
-
className: `${classPrefix$
|
|
23020
|
+
className: `${classPrefix$n}-content`
|
|
22854
23021
|
}, props.children), React__default.createElement("div", {
|
|
22855
|
-
className: `${classPrefix$
|
|
23022
|
+
className: `${classPrefix$n}-footer`
|
|
22856
23023
|
}, showSecondaryButton && React__default.createElement(Button, {
|
|
22857
23024
|
block: true,
|
|
22858
23025
|
color: "default",
|
|
22859
23026
|
fill: "solid",
|
|
22860
23027
|
size: "large",
|
|
22861
23028
|
onClick: onSecondaryButtonClick,
|
|
22862
|
-
className: `${classPrefix$
|
|
23029
|
+
className: `${classPrefix$n}-footer-btn`
|
|
22863
23030
|
}, secondaryButtonText), showPrimaryButton && showSecondaryButton && React__default.createElement("div", {
|
|
22864
|
-
className: `${classPrefix$
|
|
23031
|
+
className: `${classPrefix$n}-footer-space`
|
|
22865
23032
|
}), showPrimaryButton && React__default.createElement(Button, {
|
|
22866
23033
|
block: true,
|
|
22867
23034
|
color: "primary",
|
|
22868
23035
|
fill: "solid",
|
|
22869
23036
|
size: "large",
|
|
22870
23037
|
onClick: onPrimaryButtonClick,
|
|
22871
|
-
className: `${classPrefix$
|
|
23038
|
+
className: `${classPrefix$n}-footer-btn`
|
|
22872
23039
|
}, primaryButtonText))));
|
|
22873
23040
|
};
|
|
22874
|
-
const classPrefix$
|
|
23041
|
+
const classPrefix$m = `adm-result-page-card`;
|
|
22875
23042
|
const ResultPageCard = (props) => {
|
|
22876
23043
|
return withNativeProps(props, React__default.createElement("div", {
|
|
22877
|
-
className: classNames(`${classPrefix$
|
|
23044
|
+
className: classNames(`${classPrefix$m}`)
|
|
22878
23045
|
}, props.children));
|
|
22879
23046
|
};
|
|
22880
23047
|
const index$5 = attachPropertiesToComponent(ResultPage, {
|
|
22881
23048
|
Card: ResultPageCard
|
|
22882
23049
|
});
|
|
22883
23050
|
const searchBar = "";
|
|
22884
|
-
const classPrefix$
|
|
22885
|
-
const defaultProps$
|
|
23051
|
+
const classPrefix$l = `adm-search-bar`;
|
|
23052
|
+
const defaultProps$g = {
|
|
22886
23053
|
clearable: true,
|
|
22887
23054
|
onlyShowClearWhenFocus: false,
|
|
22888
23055
|
showCancelButton: false,
|
|
@@ -22894,7 +23061,7 @@ const SearchBar = forwardRef((p, ref) => {
|
|
|
22894
23061
|
const {
|
|
22895
23062
|
locale
|
|
22896
23063
|
} = useConfig();
|
|
22897
|
-
const props = mergeProps(defaultProps$
|
|
23064
|
+
const props = mergeProps(defaultProps$g, {
|
|
22898
23065
|
cancelText: locale.common.cancel
|
|
22899
23066
|
}, p);
|
|
22900
23067
|
const [value, setValue2] = usePropsValue(props);
|
|
@@ -22927,10 +23094,10 @@ const SearchBar = forwardRef((p, ref) => {
|
|
|
22927
23094
|
isShowCancel = props.showCancelButton && hasFocus;
|
|
22928
23095
|
}
|
|
22929
23096
|
return isShowCancel && React__default.createElement("div", {
|
|
22930
|
-
className: `${classPrefix$
|
|
23097
|
+
className: `${classPrefix$l}-suffix`
|
|
22931
23098
|
}, React__default.createElement(Button, {
|
|
22932
23099
|
fill: "none",
|
|
22933
|
-
className: `${classPrefix$
|
|
23100
|
+
className: `${classPrefix$l}-cancel-button`,
|
|
22934
23101
|
onClick: () => {
|
|
22935
23102
|
var _a, _b, _c;
|
|
22936
23103
|
if (props.clearOnCancel) {
|
|
@@ -22945,17 +23112,17 @@ const SearchBar = forwardRef((p, ref) => {
|
|
|
22945
23112
|
}, props.cancelText));
|
|
22946
23113
|
};
|
|
22947
23114
|
return withNativeProps(props, React__default.createElement("div", {
|
|
22948
|
-
className: classNames(classPrefix$
|
|
22949
|
-
[`${classPrefix$
|
|
23115
|
+
className: classNames(classPrefix$l, {
|
|
23116
|
+
[`${classPrefix$l}-active`]: hasFocus
|
|
22950
23117
|
})
|
|
22951
23118
|
}, React__default.createElement("div", {
|
|
22952
|
-
className: `${classPrefix$
|
|
23119
|
+
className: `${classPrefix$l}-input-box`
|
|
22953
23120
|
}, props.icon && React__default.createElement("div", {
|
|
22954
|
-
className: `${classPrefix$
|
|
23121
|
+
className: `${classPrefix$l}-input-box-icon`
|
|
22955
23122
|
}, props.icon), React__default.createElement(Input, {
|
|
22956
23123
|
ref: inputRef,
|
|
22957
|
-
className: classNames(`${classPrefix$
|
|
22958
|
-
[`${classPrefix$
|
|
23124
|
+
className: classNames(`${classPrefix$l}-input`, {
|
|
23125
|
+
[`${classPrefix$l}-input-without-icon`]: !props.icon
|
|
22959
23126
|
}),
|
|
22960
23127
|
value,
|
|
22961
23128
|
onChange: setValue2,
|
|
@@ -23021,14 +23188,14 @@ const CheckMark = memo(() => {
|
|
|
23021
23188
|
points: "34.2767388 22 24.797043 31.4796958 21 27.6826527"
|
|
23022
23189
|
})))))));
|
|
23023
23190
|
});
|
|
23024
|
-
const classPrefix$
|
|
23025
|
-
const defaultProps$
|
|
23191
|
+
const classPrefix$k = `adm-selector`;
|
|
23192
|
+
const defaultProps$f = {
|
|
23026
23193
|
multiple: false,
|
|
23027
23194
|
defaultValue: [],
|
|
23028
23195
|
showCheckMark: true
|
|
23029
23196
|
};
|
|
23030
23197
|
const Selector = (p) => {
|
|
23031
|
-
const props = mergeProps(defaultProps$
|
|
23198
|
+
const props = mergeProps(defaultProps$f, p);
|
|
23032
23199
|
const [value, setValue2] = usePropsValue({
|
|
23033
23200
|
value: props.value,
|
|
23034
23201
|
defaultValue: props.defaultValue,
|
|
@@ -23045,10 +23212,10 @@ const Selector = (p) => {
|
|
|
23045
23212
|
const items = props.options.map((option) => {
|
|
23046
23213
|
const active = (value || []).includes(option.value);
|
|
23047
23214
|
const disabled = option.disabled || props.disabled;
|
|
23048
|
-
const itemCls = classNames(`${classPrefix$
|
|
23049
|
-
[`${classPrefix$
|
|
23050
|
-
[`${classPrefix$
|
|
23051
|
-
[`${classPrefix$
|
|
23215
|
+
const itemCls = classNames(`${classPrefix$k}-item`, {
|
|
23216
|
+
[`${classPrefix$k}-item-active`]: active && !props.multiple,
|
|
23217
|
+
[`${classPrefix$k}-item-multiple-active`]: active && props.multiple,
|
|
23218
|
+
[`${classPrefix$k}-item-disabled`]: disabled
|
|
23052
23219
|
});
|
|
23053
23220
|
return React__default.createElement("div", {
|
|
23054
23221
|
key: option.value,
|
|
@@ -23066,13 +23233,13 @@ const Selector = (p) => {
|
|
|
23066
23233
|
}
|
|
23067
23234
|
}
|
|
23068
23235
|
}, option.label, option.description && React__default.createElement("div", {
|
|
23069
|
-
className: `${classPrefix$
|
|
23236
|
+
className: `${classPrefix$k}-item-description`
|
|
23070
23237
|
}, option.description), active && props.showCheckMark && React__default.createElement("div", {
|
|
23071
|
-
className: `${classPrefix$
|
|
23238
|
+
className: `${classPrefix$k}-check-mark-wrapper`
|
|
23072
23239
|
}, React__default.createElement(CheckMark, null)));
|
|
23073
23240
|
});
|
|
23074
23241
|
return withNativeProps(props, React__default.createElement("div", {
|
|
23075
|
-
className: classPrefix$
|
|
23242
|
+
className: classPrefix$k
|
|
23076
23243
|
}, !props.columns && React__default.createElement(Space, {
|
|
23077
23244
|
wrap: true
|
|
23078
23245
|
}, items), props.columns && React__default.createElement(Grid, {
|
|
@@ -23092,7 +23259,7 @@ const Corner = memo((props) => withNativeProps(props, React__default.createEleme
|
|
|
23092
23259
|
fill: "var(--adm-color-background)",
|
|
23093
23260
|
transform: "translate(15.000000, 15.000000) scale(-1, -1) translate(-15.000000, -15.000000) "
|
|
23094
23261
|
})))));
|
|
23095
|
-
const classPrefix$
|
|
23262
|
+
const classPrefix$j = `adm-side-bar`;
|
|
23096
23263
|
const SideBarItem = () => {
|
|
23097
23264
|
return null;
|
|
23098
23265
|
};
|
|
@@ -23124,9 +23291,9 @@ const SideBar = (props) => {
|
|
|
23124
23291
|
const lastItem = items[items.length - 1];
|
|
23125
23292
|
const isLastItemActive = lastItem && lastItem.key === activeKey;
|
|
23126
23293
|
return withNativeProps(props, React__default.createElement("div", {
|
|
23127
|
-
className: classPrefix$
|
|
23294
|
+
className: classPrefix$j
|
|
23128
23295
|
}, React__default.createElement("div", {
|
|
23129
|
-
className: `${classPrefix$
|
|
23296
|
+
className: `${classPrefix$j}-items`
|
|
23130
23297
|
}, items.map((item, index2) => {
|
|
23131
23298
|
const active = item.key === activeKey;
|
|
23132
23299
|
const isActiveNextSibling = items[index2 - 1] && items[index2 - 1].key === activeKey;
|
|
@@ -23141,33 +23308,33 @@ const SideBar = (props) => {
|
|
|
23141
23308
|
return;
|
|
23142
23309
|
setActiveKey(key.toString());
|
|
23143
23310
|
},
|
|
23144
|
-
className: classNames(`${classPrefix$
|
|
23145
|
-
[`${classPrefix$
|
|
23146
|
-
[`${classPrefix$
|
|
23311
|
+
className: classNames(`${classPrefix$j}-item`, {
|
|
23312
|
+
[`${classPrefix$j}-item-active`]: active,
|
|
23313
|
+
[`${classPrefix$j}-item-disabled`]: item.props.disabled
|
|
23147
23314
|
})
|
|
23148
23315
|
}, React__default.createElement(React__default.Fragment, null, isActiveNextSibling && React__default.createElement(Corner, {
|
|
23149
|
-
className: `${classPrefix$
|
|
23316
|
+
className: `${classPrefix$j}-item-corner ${classPrefix$j}-item-corner-top`
|
|
23150
23317
|
}), isActivePreviousSibling && React__default.createElement(Corner, {
|
|
23151
|
-
className: `${classPrefix$
|
|
23318
|
+
className: `${classPrefix$j}-item-corner ${classPrefix$j}-item-corner-bottom`
|
|
23152
23319
|
})), React__default.createElement(Badge, {
|
|
23153
23320
|
content: item.props.badge,
|
|
23154
|
-
className: `${classPrefix$
|
|
23321
|
+
className: `${classPrefix$j}-badge`
|
|
23155
23322
|
}, React__default.createElement("div", {
|
|
23156
|
-
className: `${classPrefix$
|
|
23323
|
+
className: `${classPrefix$j}-item-title`
|
|
23157
23324
|
}, active && React__default.createElement("div", {
|
|
23158
|
-
className: `${classPrefix$
|
|
23325
|
+
className: `${classPrefix$j}-item-highlight`
|
|
23159
23326
|
}), item.props.title))));
|
|
23160
23327
|
})), React__default.createElement("div", {
|
|
23161
|
-
className: classNames(`${classPrefix$
|
|
23328
|
+
className: classNames(`${classPrefix$j}-extra-space`, isLastItemActive && `${classPrefix$j}-item-active-next-sibling`)
|
|
23162
23329
|
}, isLastItemActive && React__default.createElement(Corner, {
|
|
23163
|
-
className: `${classPrefix$
|
|
23330
|
+
className: `${classPrefix$j}-item-corner ${classPrefix$j}-item-corner-top`
|
|
23164
23331
|
}))));
|
|
23165
23332
|
};
|
|
23166
23333
|
const index$4 = attachPropertiesToComponent(SideBar, {
|
|
23167
23334
|
Item: SideBarItem
|
|
23168
23335
|
});
|
|
23169
23336
|
const slider = "";
|
|
23170
|
-
const classPrefix$
|
|
23337
|
+
const classPrefix$i = `adm-slider`;
|
|
23171
23338
|
const Ticks = ({
|
|
23172
23339
|
points,
|
|
23173
23340
|
max: max2,
|
|
@@ -23183,8 +23350,8 @@ const Ticks = ({
|
|
|
23183
23350
|
left: offset2
|
|
23184
23351
|
};
|
|
23185
23352
|
const pointClassName = classNames({
|
|
23186
|
-
[`${classPrefix$
|
|
23187
|
-
[`${classPrefix$
|
|
23353
|
+
[`${classPrefix$i}-tick`]: true,
|
|
23354
|
+
[`${classPrefix$i}-tick-active`]: isActived
|
|
23188
23355
|
});
|
|
23189
23356
|
return React__default.createElement("span", {
|
|
23190
23357
|
className: pointClassName,
|
|
@@ -23193,10 +23360,10 @@ const Ticks = ({
|
|
|
23193
23360
|
});
|
|
23194
23361
|
});
|
|
23195
23362
|
return React__default.createElement("div", {
|
|
23196
|
-
className: `${classPrefix$
|
|
23363
|
+
className: `${classPrefix$i}-ticks`
|
|
23197
23364
|
}, elements);
|
|
23198
23365
|
};
|
|
23199
|
-
const classPrefix$
|
|
23366
|
+
const classPrefix$h = `adm-slider-mark`;
|
|
23200
23367
|
const Marks = ({
|
|
23201
23368
|
marks,
|
|
23202
23369
|
upperBound,
|
|
@@ -23213,8 +23380,8 @@ const Marks = ({
|
|
|
23213
23380
|
}
|
|
23214
23381
|
const isActive = point <= upperBound && point >= lowerBound;
|
|
23215
23382
|
const markClassName = classNames({
|
|
23216
|
-
[`${classPrefix$
|
|
23217
|
-
[`${classPrefix$
|
|
23383
|
+
[`${classPrefix$h}-text`]: true,
|
|
23384
|
+
[`${classPrefix$h}-text-active`]: isActive
|
|
23218
23385
|
});
|
|
23219
23386
|
const style = {
|
|
23220
23387
|
left: `${(point - min2) / range3 * 100}%`
|
|
@@ -23226,7 +23393,7 @@ const Marks = ({
|
|
|
23226
23393
|
}, markPoint);
|
|
23227
23394
|
});
|
|
23228
23395
|
return React__default.createElement("div", {
|
|
23229
|
-
className: classPrefix$
|
|
23396
|
+
className: classPrefix$h
|
|
23230
23397
|
}, elements);
|
|
23231
23398
|
};
|
|
23232
23399
|
const ThumbIcon = (props) => {
|
|
@@ -23254,15 +23421,16 @@ const ThumbIcon = (props) => {
|
|
|
23254
23421
|
rx: 2
|
|
23255
23422
|
}))));
|
|
23256
23423
|
};
|
|
23257
|
-
const classPrefix$
|
|
23424
|
+
const classPrefix$g = `adm-slider`;
|
|
23258
23425
|
const Thumb = (props) => {
|
|
23259
23426
|
const {
|
|
23260
23427
|
value,
|
|
23261
23428
|
min: min2,
|
|
23262
23429
|
max: max2,
|
|
23263
23430
|
disabled,
|
|
23264
|
-
|
|
23265
|
-
|
|
23431
|
+
icon,
|
|
23432
|
+
residentPopover,
|
|
23433
|
+
onDrag
|
|
23266
23434
|
} = props;
|
|
23267
23435
|
const prevValue = useRef(value);
|
|
23268
23436
|
const {
|
|
@@ -23297,12 +23465,12 @@ const Thumb = (props) => {
|
|
|
23297
23465
|
});
|
|
23298
23466
|
const renderPopoverContent = typeof props.popover === "function" ? props.popover : props.popover ? (value2) => value2.toString() : null;
|
|
23299
23467
|
const thumbElement = React__default.createElement("div", {
|
|
23300
|
-
className: `${classPrefix$
|
|
23468
|
+
className: `${classPrefix$g}-thumb`
|
|
23301
23469
|
}, icon ? icon : React__default.createElement(ThumbIcon, {
|
|
23302
|
-
className: `${classPrefix$
|
|
23470
|
+
className: `${classPrefix$g}-thumb-icon`
|
|
23303
23471
|
}));
|
|
23304
23472
|
return React__default.createElement("div", Object.assign({
|
|
23305
|
-
className: `${classPrefix$
|
|
23473
|
+
className: `${classPrefix$g}-thumb-container`,
|
|
23306
23474
|
style: currentPosition()
|
|
23307
23475
|
}, bind(), {
|
|
23308
23476
|
role: "slider",
|
|
@@ -23314,24 +23482,25 @@ const Thumb = (props) => {
|
|
|
23314
23482
|
}), renderPopoverContent ? React__default.createElement(Popover$1, {
|
|
23315
23483
|
content: renderPopoverContent(value),
|
|
23316
23484
|
placement: "top",
|
|
23317
|
-
visible: dragging,
|
|
23485
|
+
visible: residentPopover || dragging,
|
|
23318
23486
|
getContainer: null,
|
|
23319
23487
|
mode: "dark"
|
|
23320
23488
|
}, thumbElement) : thumbElement);
|
|
23321
23489
|
};
|
|
23322
|
-
const classPrefix$
|
|
23323
|
-
const defaultProps$
|
|
23490
|
+
const classPrefix$f = `adm-slider`;
|
|
23491
|
+
const defaultProps$e = {
|
|
23324
23492
|
min: 0,
|
|
23325
23493
|
max: 100,
|
|
23326
23494
|
step: 1,
|
|
23327
23495
|
ticks: false,
|
|
23328
23496
|
range: false,
|
|
23329
23497
|
disabled: false,
|
|
23330
|
-
popover: false
|
|
23498
|
+
popover: false,
|
|
23499
|
+
residentPopover: false
|
|
23331
23500
|
};
|
|
23332
23501
|
const Slider = (p) => {
|
|
23333
23502
|
var _a;
|
|
23334
|
-
const props = mergeProps(defaultProps$
|
|
23503
|
+
const props = mergeProps(defaultProps$e, p);
|
|
23335
23504
|
const {
|
|
23336
23505
|
min: min2,
|
|
23337
23506
|
max: max2,
|
|
@@ -23354,8 +23523,13 @@ const Slider = (p) => {
|
|
|
23354
23523
|
var _a2;
|
|
23355
23524
|
(_a2 = props.onAfterChange) === null || _a2 === void 0 ? void 0 : _a2.call(props, reverseValue(value));
|
|
23356
23525
|
}
|
|
23526
|
+
let propsValue = props.value;
|
|
23527
|
+
if (props.range && typeof props.value === "number") {
|
|
23528
|
+
devWarning("Slider", "When `range` prop is enabled, the `value` prop should be an array, like: [0, 0]");
|
|
23529
|
+
propsValue = [0, props.value];
|
|
23530
|
+
}
|
|
23357
23531
|
const [rawValue, setRawValue] = usePropsValue({
|
|
23358
|
-
value:
|
|
23532
|
+
value: propsValue,
|
|
23359
23533
|
defaultValue: (_a = props.defaultValue) !== null && _a !== void 0 ? _a : props.range ? [min2, min2] : min2,
|
|
23360
23534
|
onChange: props.onChange
|
|
23361
23535
|
});
|
|
@@ -23430,6 +23604,7 @@ const Slider = (p) => {
|
|
|
23430
23604
|
trackRef,
|
|
23431
23605
|
icon,
|
|
23432
23606
|
popover: props.popover,
|
|
23607
|
+
residentPopover: props.residentPopover,
|
|
23433
23608
|
onDrag: (position, first, last) => {
|
|
23434
23609
|
if (first) {
|
|
23435
23610
|
dragLockRef.current += 1;
|
|
@@ -23453,18 +23628,18 @@ const Slider = (p) => {
|
|
|
23453
23628
|
});
|
|
23454
23629
|
};
|
|
23455
23630
|
return withNativeProps(props, React__default.createElement("div", {
|
|
23456
|
-
className: classNames(classPrefix$
|
|
23457
|
-
[`${classPrefix$
|
|
23631
|
+
className: classNames(classPrefix$f, {
|
|
23632
|
+
[`${classPrefix$f}-disabled`]: disabled
|
|
23458
23633
|
})
|
|
23459
23634
|
}, React__default.createElement("div", {
|
|
23460
|
-
className: `${classPrefix$
|
|
23635
|
+
className: `${classPrefix$f}-track-container`,
|
|
23461
23636
|
onClick: onTrackClick
|
|
23462
23637
|
}, React__default.createElement("div", {
|
|
23463
|
-
className: `${classPrefix$
|
|
23638
|
+
className: `${classPrefix$f}-track`,
|
|
23464
23639
|
onClick: onTrackClick,
|
|
23465
23640
|
ref: trackRef
|
|
23466
23641
|
}, React__default.createElement("div", {
|
|
23467
|
-
className: `${classPrefix$
|
|
23642
|
+
className: `${classPrefix$f}-fill`,
|
|
23468
23643
|
style: {
|
|
23469
23644
|
width: fillSize,
|
|
23470
23645
|
left: fillStart
|
|
@@ -23992,15 +24167,15 @@ P.valueOf = function() {
|
|
|
23992
24167
|
return stringify(x, x.e <= Big2.NE || x.e >= Big2.PE, true);
|
|
23993
24168
|
};
|
|
23994
24169
|
var Big = _Big_();
|
|
23995
|
-
const classPrefix$
|
|
23996
|
-
const defaultProps$
|
|
24170
|
+
const classPrefix$e = `adm-stepper`;
|
|
24171
|
+
const defaultProps$d = {
|
|
23997
24172
|
defaultValue: 0,
|
|
23998
24173
|
step: 1,
|
|
23999
24174
|
disabled: false,
|
|
24000
24175
|
allowEmpty: false
|
|
24001
24176
|
};
|
|
24002
24177
|
const Stepper = (p) => {
|
|
24003
|
-
const props = mergeProps(defaultProps$
|
|
24178
|
+
const props = mergeProps(defaultProps$d, p);
|
|
24004
24179
|
const {
|
|
24005
24180
|
disabled,
|
|
24006
24181
|
step,
|
|
@@ -24073,11 +24248,11 @@ const Stepper = (p) => {
|
|
|
24073
24248
|
return false;
|
|
24074
24249
|
};
|
|
24075
24250
|
return withNativeProps(props, React__default.createElement("div", {
|
|
24076
|
-
className: classNames(classPrefix$
|
|
24077
|
-
[`${classPrefix$
|
|
24251
|
+
className: classNames(classPrefix$e, {
|
|
24252
|
+
[`${classPrefix$e}-active`]: hasFocus
|
|
24078
24253
|
})
|
|
24079
24254
|
}, React__default.createElement(Button, {
|
|
24080
|
-
className: `${classPrefix$
|
|
24255
|
+
className: `${classPrefix$e}-minus`,
|
|
24081
24256
|
onClick: handleMinus,
|
|
24082
24257
|
disabled: minusDisabled(),
|
|
24083
24258
|
fill: "none",
|
|
@@ -24085,9 +24260,9 @@ const Stepper = (p) => {
|
|
|
24085
24260
|
color: "primary",
|
|
24086
24261
|
"aria-label": locale.Stepper.decrease
|
|
24087
24262
|
}, React__default.createElement(MinusOutline, null)), React__default.createElement("div", {
|
|
24088
|
-
className: `${classPrefix$
|
|
24263
|
+
className: `${classPrefix$e}-middle`
|
|
24089
24264
|
}, React__default.createElement(Input, {
|
|
24090
|
-
className: `${classPrefix$
|
|
24265
|
+
className: `${classPrefix$e}-input`,
|
|
24091
24266
|
onFocus: (e) => {
|
|
24092
24267
|
var _a;
|
|
24093
24268
|
setHasFocus(true);
|
|
@@ -24107,9 +24282,10 @@ const Stepper = (p) => {
|
|
|
24107
24282
|
role: "spinbutton",
|
|
24108
24283
|
"aria-valuenow": Number(inputValue),
|
|
24109
24284
|
"aria-valuemax": max2,
|
|
24110
|
-
"aria-valuemin": min2
|
|
24285
|
+
"aria-valuemin": min2,
|
|
24286
|
+
inputMode: "decimal"
|
|
24111
24287
|
})), React__default.createElement(Button, {
|
|
24112
|
-
className: `${classPrefix$
|
|
24288
|
+
className: `${classPrefix$e}-plus`,
|
|
24113
24289
|
onClick: handlePlus,
|
|
24114
24290
|
disabled: plusDisabled(),
|
|
24115
24291
|
fill: "none",
|
|
@@ -24133,7 +24309,7 @@ function convertTextToValue(text) {
|
|
|
24133
24309
|
return parseFloat(text);
|
|
24134
24310
|
}
|
|
24135
24311
|
const steps = "";
|
|
24136
|
-
const classPrefix$
|
|
24312
|
+
const classPrefix$d = `adm-step`;
|
|
24137
24313
|
const Step = (props) => {
|
|
24138
24314
|
const {
|
|
24139
24315
|
title,
|
|
@@ -24142,35 +24318,35 @@ const Step = (props) => {
|
|
|
24142
24318
|
status = "wait"
|
|
24143
24319
|
} = props;
|
|
24144
24320
|
return withNativeProps(props, React__default.createElement("div", {
|
|
24145
|
-
className: classNames(`${classPrefix$
|
|
24321
|
+
className: classNames(`${classPrefix$d}`, `${classPrefix$d}-status-${status}`)
|
|
24146
24322
|
}, React__default.createElement("div", {
|
|
24147
|
-
className: `${classPrefix$
|
|
24323
|
+
className: `${classPrefix$d}-indicator`
|
|
24148
24324
|
}, React__default.createElement("div", {
|
|
24149
|
-
className: `${classPrefix$
|
|
24325
|
+
className: `${classPrefix$d}-icon-container`
|
|
24150
24326
|
}, icon)), React__default.createElement("div", {
|
|
24151
|
-
className: `${classPrefix$
|
|
24327
|
+
className: `${classPrefix$d}-content`
|
|
24152
24328
|
}, React__default.createElement("div", {
|
|
24153
|
-
className: `${classPrefix$
|
|
24329
|
+
className: `${classPrefix$d}-title`
|
|
24154
24330
|
}, title), !!description && React__default.createElement("div", {
|
|
24155
|
-
className: `${classPrefix$
|
|
24331
|
+
className: `${classPrefix$d}-description`
|
|
24156
24332
|
}, description))));
|
|
24157
24333
|
};
|
|
24158
|
-
const classPrefix$
|
|
24334
|
+
const classPrefix$c = `adm-steps`;
|
|
24159
24335
|
const stepClassPrefix = `adm-step`;
|
|
24160
24336
|
const defaultIcon = React__default.createElement("span", {
|
|
24161
24337
|
className: `${stepClassPrefix}-icon-dot`
|
|
24162
24338
|
});
|
|
24163
|
-
const defaultProps$
|
|
24339
|
+
const defaultProps$c = {
|
|
24164
24340
|
current: 0,
|
|
24165
24341
|
direction: "horizontal"
|
|
24166
24342
|
};
|
|
24167
24343
|
const Steps = (p) => {
|
|
24168
|
-
const props = mergeProps(defaultProps$
|
|
24344
|
+
const props = mergeProps(defaultProps$c, p);
|
|
24169
24345
|
const {
|
|
24170
24346
|
direction,
|
|
24171
24347
|
current
|
|
24172
24348
|
} = props;
|
|
24173
|
-
const classString = classNames(classPrefix$
|
|
24349
|
+
const classString = classNames(classPrefix$c, `${classPrefix$c}-${direction}`);
|
|
24174
24350
|
return withNativeProps(props, React__default.createElement("div", {
|
|
24175
24351
|
className: classString
|
|
24176
24352
|
}, React__default.Children.map(props.children, (child, index2) => {
|
|
@@ -24196,8 +24372,8 @@ const index$3 = attachPropertiesToComponent(Steps, {
|
|
|
24196
24372
|
Step
|
|
24197
24373
|
});
|
|
24198
24374
|
const swipeAction = "";
|
|
24199
|
-
const classPrefix$
|
|
24200
|
-
const defaultProps$
|
|
24375
|
+
const classPrefix$b = `adm-swipe-action`;
|
|
24376
|
+
const defaultProps$b = {
|
|
24201
24377
|
rightActions: [],
|
|
24202
24378
|
leftActions: [],
|
|
24203
24379
|
closeOnTouchOutside: true,
|
|
@@ -24205,7 +24381,7 @@ const defaultProps$a = {
|
|
|
24205
24381
|
stopPropagation: []
|
|
24206
24382
|
};
|
|
24207
24383
|
const SwipeAction = forwardRef((p, ref) => {
|
|
24208
|
-
const props = mergeProps(defaultProps$
|
|
24384
|
+
const props = mergeProps(defaultProps$b, p);
|
|
24209
24385
|
const rootRef = useRef(null);
|
|
24210
24386
|
const leftRef = useRef(null);
|
|
24211
24387
|
const rightRef = useRef(null);
|
|
@@ -24336,7 +24512,7 @@ const SwipeAction = forwardRef((p, ref) => {
|
|
|
24336
24512
|
const color = (_a = action.color) !== null && _a !== void 0 ? _a : "light";
|
|
24337
24513
|
return React__default.createElement(Button, {
|
|
24338
24514
|
key: action.key,
|
|
24339
|
-
className: `${classPrefix$
|
|
24515
|
+
className: `${classPrefix$b}-action-button`,
|
|
24340
24516
|
style: {
|
|
24341
24517
|
"--background-color": (_b = colorRecord$1[color]) !== null && _b !== void 0 ? _b : color
|
|
24342
24518
|
},
|
|
@@ -24351,7 +24527,7 @@ const SwipeAction = forwardRef((p, ref) => {
|
|
|
24351
24527
|
}, action.text);
|
|
24352
24528
|
}
|
|
24353
24529
|
return withNativeProps(props, React__default.createElement("div", Object.assign({
|
|
24354
|
-
className: classPrefix$
|
|
24530
|
+
className: classPrefix$b
|
|
24355
24531
|
}, bind(), {
|
|
24356
24532
|
ref: rootRef,
|
|
24357
24533
|
onClickCapture: (e) => {
|
|
@@ -24361,15 +24537,15 @@ const SwipeAction = forwardRef((p, ref) => {
|
|
|
24361
24537
|
}
|
|
24362
24538
|
}
|
|
24363
24539
|
}), React__default.createElement(animated.div, {
|
|
24364
|
-
className: `${classPrefix$
|
|
24540
|
+
className: `${classPrefix$b}-track`,
|
|
24365
24541
|
style: {
|
|
24366
24542
|
x
|
|
24367
24543
|
}
|
|
24368
24544
|
}, withStopPropagation(props.stopPropagation, React__default.createElement("div", {
|
|
24369
|
-
className: `${classPrefix$
|
|
24545
|
+
className: `${classPrefix$b}-actions ${classPrefix$b}-actions-left`,
|
|
24370
24546
|
ref: leftRef
|
|
24371
24547
|
}, props.leftActions.map(renderAction))), React__default.createElement("div", {
|
|
24372
|
-
className: `${classPrefix$
|
|
24548
|
+
className: `${classPrefix$b}-content`,
|
|
24373
24549
|
onClickCapture: (e) => {
|
|
24374
24550
|
if (x.goal !== 0) {
|
|
24375
24551
|
e.preventDefault();
|
|
@@ -24382,7 +24558,7 @@ const SwipeAction = forwardRef((p, ref) => {
|
|
|
24382
24558
|
pointerEvents: x.to((v) => v !== 0 && x.goal !== 0 ? "none" : "auto")
|
|
24383
24559
|
}
|
|
24384
24560
|
}, props.children)), withStopPropagation(props.stopPropagation, React__default.createElement("div", {
|
|
24385
|
-
className: `${classPrefix$
|
|
24561
|
+
className: `${classPrefix$b}-actions ${classPrefix$b}-actions-right`,
|
|
24386
24562
|
ref: rightRef
|
|
24387
24563
|
}, props.rightActions.map(renderAction))))));
|
|
24388
24564
|
});
|
|
@@ -24409,8 +24585,8 @@ function useRefState(initialState) {
|
|
|
24409
24585
|
}, [state]);
|
|
24410
24586
|
return [state, setState, ref];
|
|
24411
24587
|
}
|
|
24412
|
-
const classPrefix$
|
|
24413
|
-
const defaultProps$
|
|
24588
|
+
const classPrefix$a = `adm-swiper`;
|
|
24589
|
+
const defaultProps$a = {
|
|
24414
24590
|
defaultIndex: 0,
|
|
24415
24591
|
allowTouchMove: true,
|
|
24416
24592
|
autoplay: false,
|
|
@@ -24422,8 +24598,10 @@ const defaultProps$9 = {
|
|
|
24422
24598
|
stuckAtBoundary: true,
|
|
24423
24599
|
rubberband: true
|
|
24424
24600
|
};
|
|
24601
|
+
let currentUid;
|
|
24425
24602
|
const Swiper = forwardRef(staged_1((p, ref) => {
|
|
24426
|
-
const props = mergeProps(defaultProps$
|
|
24603
|
+
const props = mergeProps(defaultProps$a, p);
|
|
24604
|
+
const [uid] = useState({});
|
|
24427
24605
|
const isVertical = props.direction === "vertical";
|
|
24428
24606
|
const slideRatio = props.slideSize / 100;
|
|
24429
24607
|
const offsetRatio = props.trackOffset / 100;
|
|
@@ -24513,6 +24691,12 @@ const Swiper = forwardRef(staged_1((p, ref) => {
|
|
|
24513
24691
|
dragCancelRef.current = state.cancel;
|
|
24514
24692
|
if (!state.intentional)
|
|
24515
24693
|
return;
|
|
24694
|
+
if (state.first && !currentUid) {
|
|
24695
|
+
currentUid = uid;
|
|
24696
|
+
}
|
|
24697
|
+
if (currentUid !== uid)
|
|
24698
|
+
return;
|
|
24699
|
+
currentUid = state.last ? void 0 : uid;
|
|
24516
24700
|
const slidePixels = getSlidePixels();
|
|
24517
24701
|
if (!slidePixels)
|
|
24518
24702
|
return;
|
|
@@ -24606,10 +24790,10 @@ const Swiper = forwardRef(staged_1((p, ref) => {
|
|
|
24606
24790
|
function renderTrackInner() {
|
|
24607
24791
|
if (loop2) {
|
|
24608
24792
|
return React__default.createElement("div", {
|
|
24609
|
-
className: `${classPrefix$
|
|
24793
|
+
className: `${classPrefix$a}-track-inner`
|
|
24610
24794
|
}, React__default.Children.map(validChildren, (child, index2) => {
|
|
24611
24795
|
return React__default.createElement(animated.div, {
|
|
24612
|
-
className: `${classPrefix$
|
|
24796
|
+
className: `${classPrefix$a}-slide`,
|
|
24613
24797
|
style: {
|
|
24614
24798
|
[isVertical ? "y" : "x"]: position.to((position2) => {
|
|
24615
24799
|
let finalPosition = -position2 + index2 * 100;
|
|
@@ -24624,13 +24808,13 @@ const Swiper = forwardRef(staged_1((p, ref) => {
|
|
|
24624
24808
|
}));
|
|
24625
24809
|
} else {
|
|
24626
24810
|
return React__default.createElement(animated.div, {
|
|
24627
|
-
className: `${classPrefix$
|
|
24811
|
+
className: `${classPrefix$a}-track-inner`,
|
|
24628
24812
|
style: {
|
|
24629
24813
|
[isVertical ? "y" : "x"]: position.to((position2) => `${-position2}%`)
|
|
24630
24814
|
}
|
|
24631
24815
|
}, React__default.Children.map(validChildren, (child) => {
|
|
24632
24816
|
return React__default.createElement("div", {
|
|
24633
|
-
className: `${classPrefix$
|
|
24817
|
+
className: `${classPrefix$a}-slide`
|
|
24634
24818
|
}, child);
|
|
24635
24819
|
}));
|
|
24636
24820
|
}
|
|
@@ -24640,12 +24824,12 @@ const Swiper = forwardRef(staged_1((p, ref) => {
|
|
|
24640
24824
|
"--track-offset": `${props.trackOffset}%`
|
|
24641
24825
|
};
|
|
24642
24826
|
return withNativeProps(props, React__default.createElement("div", {
|
|
24643
|
-
className: classNames(classPrefix$
|
|
24827
|
+
className: classNames(classPrefix$a, `${classPrefix$a}-${props.direction}`),
|
|
24644
24828
|
style
|
|
24645
24829
|
}, React__default.createElement("div", Object.assign({
|
|
24646
24830
|
ref: trackRef,
|
|
24647
|
-
className: classNames(`${classPrefix$
|
|
24648
|
-
[`${classPrefix$
|
|
24831
|
+
className: classNames(`${classPrefix$a}-track`, {
|
|
24832
|
+
[`${classPrefix$a}-track-allow-touch-move`]: props.allowTouchMove
|
|
24649
24833
|
}),
|
|
24650
24834
|
onClickCapture: (e) => {
|
|
24651
24835
|
if (draggingRef.current) {
|
|
@@ -24654,7 +24838,7 @@ const Swiper = forwardRef(staged_1((p, ref) => {
|
|
|
24654
24838
|
forceCancelDrag();
|
|
24655
24839
|
}
|
|
24656
24840
|
}, props.allowTouchMove ? bind() : {}), renderTrackInner()), props.indicator === void 0 ? React__default.createElement("div", {
|
|
24657
|
-
className: `${classPrefix$
|
|
24841
|
+
className: `${classPrefix$a}-indicator`
|
|
24658
24842
|
}, React__default.createElement(PageIndicator, Object.assign({}, props.indicatorProps, {
|
|
24659
24843
|
total: count,
|
|
24660
24844
|
current,
|
|
@@ -24691,12 +24875,12 @@ const SpinIcon = memo((props) => {
|
|
|
24691
24875
|
d: "M17.9996753,31.5 C10.5556724,31.5 4.5,25.4443275 4.5,18.0003247 C4.5,10.5563219 10.5556724,4.5 17.9996753,4.5 C18.5355492,4.5 18.9702974,4.93474816 18.9702974,5.47062208 C18.9702974,6.006496 18.5355492,6.44124416 17.9996753,6.44124416 C11.6261524,6.44124416 6.44124416,11.6267709 6.44124416,18.0002938 C6.44124416,24.3738167 11.6261524,29.5587249 17.9996753,29.5587249 C24.3731982,29.5587249 29.5587249,24.3738167 29.5587249,18.0002938 C29.5587249,14.7964616 28.2778291,11.8169616 25.9523687,9.61220279 C25.5637302,9.24317094 25.5473089,8.62893223 25.9157222,8.23967523 C26.2841356,7.84976878 26.8989928,7.83461537 27.2882498,8.20302872 C30.0042351,10.7787368 31.5,14.2580826 31.5,18.0002938 C31.5,25.4443275 25.4436781,31.5 17.9996753,31.5 Z"
|
|
24692
24876
|
})))))));
|
|
24693
24877
|
});
|
|
24694
|
-
const classPrefix$
|
|
24695
|
-
const defaultProps$
|
|
24878
|
+
const classPrefix$9 = `adm-switch`;
|
|
24879
|
+
const defaultProps$9 = {
|
|
24696
24880
|
defaultChecked: false
|
|
24697
24881
|
};
|
|
24698
24882
|
const Switch = (p) => {
|
|
24699
|
-
const props = mergeProps(defaultProps$
|
|
24883
|
+
const props = mergeProps(defaultProps$9, p);
|
|
24700
24884
|
const disabled = props.disabled || props.loading || false;
|
|
24701
24885
|
const [changing, setChanging] = useState(false);
|
|
24702
24886
|
const {
|
|
@@ -24738,35 +24922,35 @@ const Switch = (p) => {
|
|
|
24738
24922
|
}
|
|
24739
24923
|
return withNativeProps(props, React__default.createElement("div", {
|
|
24740
24924
|
onClick,
|
|
24741
|
-
className: classNames(classPrefix$
|
|
24742
|
-
[`${classPrefix$
|
|
24743
|
-
[`${classPrefix$
|
|
24925
|
+
className: classNames(classPrefix$9, {
|
|
24926
|
+
[`${classPrefix$9}-checked`]: checked,
|
|
24927
|
+
[`${classPrefix$9}-disabled`]: disabled || changing
|
|
24744
24928
|
}),
|
|
24745
24929
|
role: "switch",
|
|
24746
24930
|
"aria-label": locale.Switch.name,
|
|
24747
24931
|
"aria-checked": checked,
|
|
24748
24932
|
"aria-disabled": disabled
|
|
24749
24933
|
}, React__default.createElement("div", {
|
|
24750
|
-
className: `${classPrefix$
|
|
24934
|
+
className: `${classPrefix$9}-checkbox`
|
|
24751
24935
|
}, React__default.createElement("div", {
|
|
24752
|
-
className: `${classPrefix$
|
|
24936
|
+
className: `${classPrefix$9}-handle`
|
|
24753
24937
|
}, (props.loading || changing) && React__default.createElement(SpinIcon, {
|
|
24754
|
-
className: `${classPrefix$
|
|
24938
|
+
className: `${classPrefix$9}-spin-icon`
|
|
24755
24939
|
})), React__default.createElement("div", {
|
|
24756
|
-
className: `${classPrefix$
|
|
24940
|
+
className: `${classPrefix$9}-inner`
|
|
24757
24941
|
}, checked ? props.checkedText : props.uncheckedText))));
|
|
24758
24942
|
};
|
|
24759
24943
|
const tabBar = "";
|
|
24760
24944
|
const TabBarItem = () => {
|
|
24761
24945
|
return null;
|
|
24762
24946
|
};
|
|
24763
|
-
const classPrefix$
|
|
24764
|
-
const defaultProps$
|
|
24947
|
+
const classPrefix$8 = `adm-tab-bar`;
|
|
24948
|
+
const defaultProps$8 = {
|
|
24765
24949
|
safeArea: false
|
|
24766
24950
|
};
|
|
24767
24951
|
const TabBar = (p) => {
|
|
24768
24952
|
var _a;
|
|
24769
|
-
const props = mergeProps(defaultProps$
|
|
24953
|
+
const props = mergeProps(defaultProps$8, p);
|
|
24770
24954
|
let firstActiveKey = null;
|
|
24771
24955
|
const items = [];
|
|
24772
24956
|
traverseReactNode(props.children, (child, index2) => {
|
|
@@ -24791,27 +24975,27 @@ const TabBar = (p) => {
|
|
|
24791
24975
|
}
|
|
24792
24976
|
});
|
|
24793
24977
|
return withNativeProps(props, React__default.createElement("div", {
|
|
24794
|
-
className: classPrefix$
|
|
24978
|
+
className: classPrefix$8
|
|
24795
24979
|
}, React__default.createElement("div", {
|
|
24796
|
-
className: `${classPrefix$
|
|
24980
|
+
className: `${classPrefix$8}-wrap`
|
|
24797
24981
|
}, items.map((item) => {
|
|
24798
24982
|
const active = item.key === activeKey;
|
|
24799
24983
|
function renderContent() {
|
|
24800
24984
|
const iconElement = item.props.icon && React__default.createElement("div", {
|
|
24801
|
-
className: `${classPrefix$
|
|
24985
|
+
className: `${classPrefix$8}-item-icon`
|
|
24802
24986
|
}, typeof item.props.icon === "function" ? item.props.icon(active) : item.props.icon);
|
|
24803
24987
|
const titleElement = item.props.title && React__default.createElement("div", {
|
|
24804
|
-
className: classNames(`${classPrefix$
|
|
24988
|
+
className: classNames(`${classPrefix$8}-item-title`, Boolean(iconElement) && `${classPrefix$8}-item-title-with-icon`)
|
|
24805
24989
|
}, typeof item.props.title === "function" ? item.props.title(active) : item.props.title);
|
|
24806
24990
|
if (iconElement) {
|
|
24807
24991
|
return React__default.createElement(React__default.Fragment, null, React__default.createElement(Badge, {
|
|
24808
24992
|
content: item.props.badge,
|
|
24809
|
-
className: `${classPrefix$
|
|
24993
|
+
className: `${classPrefix$8}-icon-badge`
|
|
24810
24994
|
}, iconElement), titleElement);
|
|
24811
24995
|
} else if (titleElement) {
|
|
24812
24996
|
return React__default.createElement(Badge, {
|
|
24813
24997
|
content: item.props.badge,
|
|
24814
|
-
className: `${classPrefix$
|
|
24998
|
+
className: `${classPrefix$8}-title-badge`
|
|
24815
24999
|
}, titleElement);
|
|
24816
25000
|
}
|
|
24817
25001
|
return null;
|
|
@@ -24826,8 +25010,8 @@ const TabBar = (p) => {
|
|
|
24826
25010
|
return;
|
|
24827
25011
|
setActiveKey(key.toString());
|
|
24828
25012
|
},
|
|
24829
|
-
className: classNames(`${classPrefix$
|
|
24830
|
-
[`${classPrefix$
|
|
25013
|
+
className: classNames(`${classPrefix$8}-item`, {
|
|
25014
|
+
[`${classPrefix$8}-item-active`]: active
|
|
24831
25015
|
})
|
|
24832
25016
|
}, renderContent()));
|
|
24833
25017
|
})), props.safeArea && React__default.createElement(SafeArea, {
|
|
@@ -24838,7 +25022,7 @@ const index$1 = attachPropertiesToComponent(TabBar, {
|
|
|
24838
25022
|
Item: TabBarItem
|
|
24839
25023
|
});
|
|
24840
25024
|
const tag = "";
|
|
24841
|
-
const classPrefix$
|
|
25025
|
+
const classPrefix$7 = `adm-tag`;
|
|
24842
25026
|
const colorRecord = {
|
|
24843
25027
|
default: "#666666",
|
|
24844
25028
|
primary: "var(--adm-color-primary, #1677ff)",
|
|
@@ -24846,14 +25030,14 @@ const colorRecord = {
|
|
|
24846
25030
|
warning: "var(--adm-color-warning, #ff8f1f)",
|
|
24847
25031
|
danger: "var(--adm-color-danger, #ff3141)"
|
|
24848
25032
|
};
|
|
24849
|
-
const defaultProps$
|
|
25033
|
+
const defaultProps$7 = {
|
|
24850
25034
|
color: "default",
|
|
24851
25035
|
fill: "solid",
|
|
24852
25036
|
round: false
|
|
24853
25037
|
};
|
|
24854
25038
|
const Tag = (p) => {
|
|
24855
25039
|
var _a;
|
|
24856
|
-
const props = mergeProps(defaultProps$
|
|
25040
|
+
const props = mergeProps(defaultProps$7, p);
|
|
24857
25041
|
const color = (_a = colorRecord[props.color]) !== null && _a !== void 0 ? _a : props.color;
|
|
24858
25042
|
const style = {
|
|
24859
25043
|
"--border-color": color,
|
|
@@ -24863,21 +25047,21 @@ const Tag = (p) => {
|
|
|
24863
25047
|
return withNativeProps(props, React__default.createElement("span", {
|
|
24864
25048
|
style,
|
|
24865
25049
|
onClick: props.onClick,
|
|
24866
|
-
className: classNames(classPrefix$
|
|
24867
|
-
[`${classPrefix$
|
|
25050
|
+
className: classNames(classPrefix$7, {
|
|
25051
|
+
[`${classPrefix$7}-round`]: props.round
|
|
24868
25052
|
})
|
|
24869
25053
|
}, props.children));
|
|
24870
25054
|
};
|
|
24871
25055
|
const textArea = "";
|
|
24872
|
-
const classPrefix$
|
|
24873
|
-
const defaultProps$
|
|
25056
|
+
const classPrefix$6 = "adm-text-area";
|
|
25057
|
+
const defaultProps$6 = {
|
|
24874
25058
|
rows: 2,
|
|
24875
25059
|
showCount: false,
|
|
24876
25060
|
autoSize: false,
|
|
24877
25061
|
defaultValue: ""
|
|
24878
25062
|
};
|
|
24879
25063
|
const TextArea = forwardRef((p, ref) => {
|
|
24880
|
-
const props = mergeProps(defaultProps$
|
|
25064
|
+
const props = mergeProps(defaultProps$6, p);
|
|
24881
25065
|
const {
|
|
24882
25066
|
autoSize,
|
|
24883
25067
|
showCount,
|
|
@@ -24933,14 +25117,14 @@ const TextArea = forwardRef((p, ref) => {
|
|
|
24933
25117
|
count = showCount(valueLength, maxLength);
|
|
24934
25118
|
} else if (showCount) {
|
|
24935
25119
|
count = React__default.createElement("div", {
|
|
24936
|
-
className: `${classPrefix$
|
|
25120
|
+
className: `${classPrefix$6}-count`
|
|
24937
25121
|
}, maxLength === void 0 ? valueLength : valueLength + "/" + maxLength);
|
|
24938
25122
|
}
|
|
24939
25123
|
return withNativeProps(props, React__default.createElement("div", {
|
|
24940
|
-
className: classPrefix$
|
|
25124
|
+
className: classPrefix$6
|
|
24941
25125
|
}, React__default.createElement("textarea", {
|
|
24942
25126
|
ref: nativeTextAreaRef,
|
|
24943
|
-
className: `${classPrefix$
|
|
25127
|
+
className: `${classPrefix$6}-element`,
|
|
24944
25128
|
rows: props.rows,
|
|
24945
25129
|
value,
|
|
24946
25130
|
placeholder: props.placeholder,
|
|
@@ -24976,15 +25160,15 @@ const TextArea = forwardRef((p, ref) => {
|
|
|
24976
25160
|
onClick: props.onClick
|
|
24977
25161
|
}), count));
|
|
24978
25162
|
});
|
|
24979
|
-
TextArea.defaultProps = defaultProps$
|
|
25163
|
+
TextArea.defaultProps = defaultProps$6;
|
|
24980
25164
|
const toast = "";
|
|
24981
|
-
const classPrefix$
|
|
24982
|
-
const defaultProps$
|
|
25165
|
+
const classPrefix$5 = `adm-toast`;
|
|
25166
|
+
const defaultProps$5 = {
|
|
24983
25167
|
maskClickable: true,
|
|
24984
25168
|
stopPropagation: ["click"]
|
|
24985
25169
|
};
|
|
24986
25170
|
const InternalToast = (p) => {
|
|
24987
|
-
const props = mergeProps(defaultProps$
|
|
25171
|
+
const props = mergeProps(defaultProps$5, p);
|
|
24988
25172
|
const {
|
|
24989
25173
|
maskClickable,
|
|
24990
25174
|
content,
|
|
@@ -24997,16 +25181,16 @@ const InternalToast = (p) => {
|
|
|
24997
25181
|
switch (icon) {
|
|
24998
25182
|
case "success":
|
|
24999
25183
|
return React__default.createElement(CheckOutline, {
|
|
25000
|
-
className: `${classPrefix$
|
|
25184
|
+
className: `${classPrefix$5}-icon-success`
|
|
25001
25185
|
});
|
|
25002
25186
|
case "fail":
|
|
25003
25187
|
return React__default.createElement(CloseOutline, {
|
|
25004
|
-
className: `${classPrefix$
|
|
25188
|
+
className: `${classPrefix$5}-icon-fail`
|
|
25005
25189
|
});
|
|
25006
25190
|
case "loading":
|
|
25007
25191
|
return React__default.createElement(SpinLoading, {
|
|
25008
25192
|
color: "white",
|
|
25009
|
-
className: `${classPrefix$
|
|
25193
|
+
className: `${classPrefix$5}-loading`
|
|
25010
25194
|
});
|
|
25011
25195
|
default:
|
|
25012
25196
|
return icon;
|
|
@@ -25032,29 +25216,29 @@ const InternalToast = (p) => {
|
|
|
25032
25216
|
style: Object.assign({
|
|
25033
25217
|
pointerEvents: maskClickable ? "none" : "auto"
|
|
25034
25218
|
}, props.maskStyle),
|
|
25035
|
-
className: classNames(`${classPrefix$
|
|
25219
|
+
className: classNames(`${classPrefix$5}-mask`, props.maskClassName),
|
|
25036
25220
|
stopPropagation: props.stopPropagation
|
|
25037
25221
|
}, React__default.createElement("div", {
|
|
25038
|
-
className: classNames(`${classPrefix$
|
|
25222
|
+
className: classNames(`${classPrefix$5}-wrap`)
|
|
25039
25223
|
}, React__default.createElement("div", {
|
|
25040
25224
|
style: {
|
|
25041
25225
|
top
|
|
25042
25226
|
},
|
|
25043
|
-
className: classNames(`${classPrefix$
|
|
25227
|
+
className: classNames(`${classPrefix$5}-main`, icon ? `${classPrefix$5}-main-icon` : `${classPrefix$5}-main-text`)
|
|
25044
25228
|
}, iconElement && React__default.createElement("div", {
|
|
25045
|
-
className: `${classPrefix$
|
|
25229
|
+
className: `${classPrefix$5}-icon`
|
|
25046
25230
|
}, iconElement), React__default.createElement(AutoCenter, null, content))));
|
|
25047
25231
|
};
|
|
25048
25232
|
let currentHandler = null;
|
|
25049
25233
|
let currentTimeout = null;
|
|
25050
|
-
const defaultProps$
|
|
25234
|
+
const defaultProps$4 = {
|
|
25051
25235
|
duration: 2e3,
|
|
25052
25236
|
position: "center",
|
|
25053
25237
|
maskClickable: true
|
|
25054
25238
|
};
|
|
25055
25239
|
const ToastInner = (props) => React__default.createElement(InternalToast, Object.assign({}, props));
|
|
25056
25240
|
function show(p) {
|
|
25057
|
-
const props = mergeProps(defaultProps$
|
|
25241
|
+
const props = mergeProps(defaultProps$4, typeof p === "string" ? {
|
|
25058
25242
|
content: p
|
|
25059
25243
|
} : p);
|
|
25060
25244
|
const element = React__default.createElement(ToastInner, Object.assign({}, props, {
|
|
@@ -25083,13 +25267,13 @@ function clear() {
|
|
|
25083
25267
|
}
|
|
25084
25268
|
function config(val) {
|
|
25085
25269
|
if (val.duration !== void 0) {
|
|
25086
|
-
defaultProps$
|
|
25270
|
+
defaultProps$4.duration = val.duration;
|
|
25087
25271
|
}
|
|
25088
25272
|
if (val.position !== void 0) {
|
|
25089
|
-
defaultProps$
|
|
25273
|
+
defaultProps$4.position = val.position;
|
|
25090
25274
|
}
|
|
25091
25275
|
if (val.maskClickable !== void 0) {
|
|
25092
|
-
defaultProps$
|
|
25276
|
+
defaultProps$4.maskClickable = val.maskClickable;
|
|
25093
25277
|
}
|
|
25094
25278
|
}
|
|
25095
25279
|
const Toast = {
|
|
@@ -25112,14 +25296,14 @@ function getTreeDeep(treeData, childrenName = "children") {
|
|
|
25112
25296
|
};
|
|
25113
25297
|
return walker(treeData);
|
|
25114
25298
|
}
|
|
25115
|
-
const classPrefix$
|
|
25116
|
-
const defaultProps$
|
|
25299
|
+
const classPrefix$4 = `adm-tree-select`;
|
|
25300
|
+
const defaultProps$3 = {
|
|
25117
25301
|
options: [],
|
|
25118
25302
|
fieldNames: {},
|
|
25119
25303
|
defaultValue: []
|
|
25120
25304
|
};
|
|
25121
25305
|
const TreeSelect = (p) => {
|
|
25122
|
-
const props = mergeProps(defaultProps$
|
|
25306
|
+
const props = mergeProps(defaultProps$3, p);
|
|
25123
25307
|
const labelName = props.fieldNames.label || "label";
|
|
25124
25308
|
const valueName = props.fieldNames.value || "value";
|
|
25125
25309
|
const childrenName = props.fieldNames.children || "children";
|
|
@@ -25163,8 +25347,8 @@ const TreeSelect = (p) => {
|
|
|
25163
25347
|
const isActive = item[valueName] === value[index2];
|
|
25164
25348
|
return React__default.createElement("div", {
|
|
25165
25349
|
key: item[valueName],
|
|
25166
|
-
className: classNames(`${classPrefix$
|
|
25167
|
-
[`${classPrefix$
|
|
25350
|
+
className: classNames(`${classPrefix$4}-item`, {
|
|
25351
|
+
[`${classPrefix$4}-item-active`]: isActive
|
|
25168
25352
|
}),
|
|
25169
25353
|
onClick: () => {
|
|
25170
25354
|
if (!isActive) {
|
|
@@ -25187,7 +25371,7 @@ const TreeSelect = (p) => {
|
|
|
25187
25371
|
}
|
|
25188
25372
|
const column = React__default.createElement("div", {
|
|
25189
25373
|
key: i,
|
|
25190
|
-
className: classNames(`${classPrefix$
|
|
25374
|
+
className: classNames(`${classPrefix$4}-column`),
|
|
25191
25375
|
style: {
|
|
25192
25376
|
width
|
|
25193
25377
|
}
|
|
@@ -25197,10 +25381,10 @@ const TreeSelect = (p) => {
|
|
|
25197
25381
|
return columns;
|
|
25198
25382
|
};
|
|
25199
25383
|
return withNativeProps(props, React__default.createElement("div", {
|
|
25200
|
-
className: classPrefix$
|
|
25384
|
+
className: classPrefix$4
|
|
25201
25385
|
}, renderColumns()));
|
|
25202
25386
|
};
|
|
25203
|
-
const classPrefix$
|
|
25387
|
+
const classPrefix$3 = `adm-tree-select-multiple`;
|
|
25204
25388
|
const Multiple = (p) => {
|
|
25205
25389
|
const props = mergeProps({
|
|
25206
25390
|
options: [],
|
|
@@ -25340,7 +25524,7 @@ const Multiple = (p) => {
|
|
|
25340
25524
|
onChange(allSelectedLeafKeys.concat(currentLeafKeys));
|
|
25341
25525
|
}
|
|
25342
25526
|
},
|
|
25343
|
-
className: `${classPrefix$
|
|
25527
|
+
className: `${classPrefix$3}-item`
|
|
25344
25528
|
}, text);
|
|
25345
25529
|
};
|
|
25346
25530
|
const renderSelectAllLeafItem = (columnOptions, index2) => {
|
|
@@ -25360,9 +25544,9 @@ const Multiple = (p) => {
|
|
|
25360
25544
|
onChange(allSelectedLeafKeys.concat(currentLeafKeys));
|
|
25361
25545
|
}
|
|
25362
25546
|
},
|
|
25363
|
-
className: classNames(`${classPrefix$
|
|
25547
|
+
className: classNames(`${classPrefix$3}-item`, `${classPrefix$3}-item-leaf`)
|
|
25364
25548
|
}, React__default.createElement(Checkbox, {
|
|
25365
|
-
className: `${classPrefix$
|
|
25549
|
+
className: `${classPrefix$3}-item-checkbox`,
|
|
25366
25550
|
checked: allSelected,
|
|
25367
25551
|
indeterminate: halfSelected
|
|
25368
25552
|
}), text);
|
|
@@ -25376,11 +25560,11 @@ const Multiple = (p) => {
|
|
|
25376
25560
|
onItemSelect(option);
|
|
25377
25561
|
}
|
|
25378
25562
|
},
|
|
25379
|
-
className: classNames(`${classPrefix$
|
|
25380
|
-
[`${classPrefix$
|
|
25563
|
+
className: classNames(`${classPrefix$3}-item`, {
|
|
25564
|
+
[`${classPrefix$3}-item-expand`]: isExpand
|
|
25381
25565
|
})
|
|
25382
25566
|
}, option[labelName], !!dotMap.get(option[valueName]) && React__default.createElement("div", {
|
|
25383
|
-
className: `${classPrefix$
|
|
25567
|
+
className: `${classPrefix$3}-dot`
|
|
25384
25568
|
}));
|
|
25385
25569
|
};
|
|
25386
25570
|
const renderLeafItem = (option) => {
|
|
@@ -25394,9 +25578,9 @@ const Multiple = (p) => {
|
|
|
25394
25578
|
onChange([...allSelectedLeafKeys, option[valueName]]);
|
|
25395
25579
|
}
|
|
25396
25580
|
},
|
|
25397
|
-
className: classNames(`${classPrefix$
|
|
25581
|
+
className: classNames(`${classPrefix$3}-item`, `${classPrefix$3}-item-leaf`)
|
|
25398
25582
|
}, React__default.createElement(Checkbox, {
|
|
25399
|
-
className: `${classPrefix$
|
|
25583
|
+
className: `${classPrefix$3}-item-checkbox`,
|
|
25400
25584
|
checked: isSelected
|
|
25401
25585
|
}), option[labelName]);
|
|
25402
25586
|
};
|
|
@@ -25427,7 +25611,7 @@ const Multiple = (p) => {
|
|
|
25427
25611
|
}
|
|
25428
25612
|
const column = React__default.createElement("div", {
|
|
25429
25613
|
key: i,
|
|
25430
|
-
className: classNames(`${classPrefix$
|
|
25614
|
+
className: classNames(`${classPrefix$3}-column`),
|
|
25431
25615
|
style: {
|
|
25432
25616
|
width
|
|
25433
25617
|
}
|
|
@@ -25437,19 +25621,19 @@ const Multiple = (p) => {
|
|
|
25437
25621
|
return columns;
|
|
25438
25622
|
};
|
|
25439
25623
|
return withNativeProps(props, React__default.createElement("div", {
|
|
25440
|
-
className: classPrefix$
|
|
25624
|
+
className: classPrefix$3
|
|
25441
25625
|
}, renderColumns()));
|
|
25442
25626
|
};
|
|
25443
25627
|
const index = attachPropertiesToComponent(TreeSelect, {
|
|
25444
25628
|
Multiple
|
|
25445
25629
|
});
|
|
25446
25630
|
const virtualInput = "";
|
|
25447
|
-
const classPrefix$
|
|
25448
|
-
const defaultProps$
|
|
25631
|
+
const classPrefix$2 = "adm-virtual-input";
|
|
25632
|
+
const defaultProps$2 = {
|
|
25449
25633
|
defaultValue: ""
|
|
25450
25634
|
};
|
|
25451
25635
|
const VirtualInput = forwardRef((p, ref) => {
|
|
25452
|
-
const props = mergeProps(defaultProps$
|
|
25636
|
+
const props = mergeProps(defaultProps$2, p);
|
|
25453
25637
|
const [value, setValue2] = usePropsValue(props);
|
|
25454
25638
|
const rootRef = useRef(null);
|
|
25455
25639
|
const contentRef = useRef(null);
|
|
@@ -25516,22 +25700,22 @@ const VirtualInput = forwardRef((p, ref) => {
|
|
|
25516
25700
|
});
|
|
25517
25701
|
return withNativeProps(props, React__default.createElement("div", {
|
|
25518
25702
|
ref: rootRef,
|
|
25519
|
-
className: classNames(classPrefix$
|
|
25520
|
-
[`${classPrefix$
|
|
25703
|
+
className: classNames(classPrefix$2, {
|
|
25704
|
+
[`${classPrefix$2}-disabled`]: props.disabled
|
|
25521
25705
|
}),
|
|
25522
25706
|
tabIndex: props.disabled ? void 0 : 0,
|
|
25523
25707
|
onFocus,
|
|
25524
25708
|
onBlur,
|
|
25525
25709
|
onClick: props.onClick
|
|
25526
25710
|
}, React__default.createElement("div", {
|
|
25527
|
-
className: `${classPrefix$
|
|
25711
|
+
className: `${classPrefix$2}-content`,
|
|
25528
25712
|
ref: contentRef
|
|
25529
25713
|
}, value, React__default.createElement("div", {
|
|
25530
|
-
className: `${classPrefix$
|
|
25714
|
+
className: `${classPrefix$2}-caret-container`
|
|
25531
25715
|
}, hasFocus && React__default.createElement("div", {
|
|
25532
|
-
className: `${classPrefix$
|
|
25716
|
+
className: `${classPrefix$2}-caret`
|
|
25533
25717
|
}))), props.clearable && !!value && hasFocus && React__default.createElement("div", {
|
|
25534
|
-
className: `${classPrefix$
|
|
25718
|
+
className: `${classPrefix$2}-clear`,
|
|
25535
25719
|
onClick: (e) => {
|
|
25536
25720
|
var _a;
|
|
25537
25721
|
e.stopPropagation();
|
|
@@ -25539,16 +25723,16 @@ const VirtualInput = forwardRef((p, ref) => {
|
|
|
25539
25723
|
(_a = props.onClear) === null || _a === void 0 ? void 0 : _a.call(props);
|
|
25540
25724
|
}
|
|
25541
25725
|
}, React__default.createElement(CloseCircleFill, null)), !value && React__default.createElement("div", {
|
|
25542
|
-
className: `${classPrefix$
|
|
25726
|
+
className: `${classPrefix$2}-placeholder`
|
|
25543
25727
|
}, props.placeholder), keyboardElement));
|
|
25544
25728
|
});
|
|
25545
25729
|
const waterMark = "";
|
|
25546
|
-
const classPrefix = `adm-water-mark`;
|
|
25547
|
-
const defaultProps = {
|
|
25730
|
+
const classPrefix$1 = `adm-water-mark`;
|
|
25731
|
+
const defaultProps$1 = {
|
|
25548
25732
|
fullPage: true
|
|
25549
25733
|
};
|
|
25550
25734
|
const WaterMark = (p) => {
|
|
25551
|
-
const props = mergeProps(defaultProps, p);
|
|
25735
|
+
const props = mergeProps(defaultProps$1, p);
|
|
25552
25736
|
const {
|
|
25553
25737
|
zIndex = 2e3,
|
|
25554
25738
|
gapX = 24,
|
|
@@ -25607,8 +25791,8 @@ const WaterMark = (p) => {
|
|
|
25607
25791
|
}
|
|
25608
25792
|
}, [gapX, gapY, rotate, fontStyle, fontWeight, width, height, fontFamily, fontColor, image2, content, fontSize]);
|
|
25609
25793
|
return withNativeProps(props, React__default.createElement("div", {
|
|
25610
|
-
className: classNames(classPrefix, {
|
|
25611
|
-
[`${classPrefix}-full-page`]: props.fullPage
|
|
25794
|
+
className: classNames(classPrefix$1, {
|
|
25795
|
+
[`${classPrefix$1}-full-page`]: props.fullPage
|
|
25612
25796
|
}),
|
|
25613
25797
|
style: {
|
|
25614
25798
|
zIndex,
|
|
@@ -25617,6 +25801,65 @@ const WaterMark = (p) => {
|
|
|
25617
25801
|
}
|
|
25618
25802
|
}));
|
|
25619
25803
|
};
|
|
25804
|
+
const footer = "";
|
|
25805
|
+
const classPrefix = `adm-footer`;
|
|
25806
|
+
const defaultProps = {
|
|
25807
|
+
label: "",
|
|
25808
|
+
links: [],
|
|
25809
|
+
content: "",
|
|
25810
|
+
chips: []
|
|
25811
|
+
};
|
|
25812
|
+
const Footer = (p) => {
|
|
25813
|
+
const props = mergeProps(defaultProps, p);
|
|
25814
|
+
const {
|
|
25815
|
+
label,
|
|
25816
|
+
links,
|
|
25817
|
+
content,
|
|
25818
|
+
chips,
|
|
25819
|
+
onChipClick,
|
|
25820
|
+
onLinkClick
|
|
25821
|
+
} = props;
|
|
25822
|
+
const clickChipItem = (item, index2) => {
|
|
25823
|
+
if ((chips === null || chips === void 0 ? void 0 : chips.length) && item.type === "link") {
|
|
25824
|
+
onChipClick === null || onChipClick === void 0 ? void 0 : onChipClick(item, index2);
|
|
25825
|
+
}
|
|
25826
|
+
};
|
|
25827
|
+
const clickLinkItem = (item, index2, e) => {
|
|
25828
|
+
if (onLinkClick) {
|
|
25829
|
+
e.preventDefault();
|
|
25830
|
+
onLinkClick(item, index2);
|
|
25831
|
+
}
|
|
25832
|
+
};
|
|
25833
|
+
return withNativeProps(props, React__default.createElement("div", {
|
|
25834
|
+
className: classNames(classPrefix)
|
|
25835
|
+
}, label && React__default.createElement("div", {
|
|
25836
|
+
className: `${classPrefix}-label`
|
|
25837
|
+
}, React__default.createElement(Divider, null, label)), links && links.length > 0 && React__default.createElement("div", {
|
|
25838
|
+
className: `${classPrefix}-links`
|
|
25839
|
+
}, links.map((link, index2) => {
|
|
25840
|
+
return React__default.createElement(React__default.Fragment, {
|
|
25841
|
+
key: index2
|
|
25842
|
+
}, React__default.createElement("a", {
|
|
25843
|
+
href: link.href,
|
|
25844
|
+
rel: "noopener noreferrer",
|
|
25845
|
+
onClick: (event) => clickLinkItem(link, index2, event)
|
|
25846
|
+
}, link.text), index2 !== links.length - 1 && React__default.createElement(Divider, {
|
|
25847
|
+
direction: "vertical"
|
|
25848
|
+
}));
|
|
25849
|
+
})), content && React__default.createElement("div", {
|
|
25850
|
+
className: `${classPrefix}-content`
|
|
25851
|
+
}, content), chips && chips.length > 0 && React__default.createElement("div", {
|
|
25852
|
+
className: `${classPrefix}-chips`
|
|
25853
|
+
}, chips.map((chip, index2) => {
|
|
25854
|
+
return React__default.createElement("div", {
|
|
25855
|
+
key: index2,
|
|
25856
|
+
onClick: () => clickChipItem(chip, index2),
|
|
25857
|
+
className: classNames(`${classPrefix}-chip`, {
|
|
25858
|
+
[`${classPrefix}-chip-link`]: chip.type === "link"
|
|
25859
|
+
})
|
|
25860
|
+
}, chip.text);
|
|
25861
|
+
}))));
|
|
25862
|
+
};
|
|
25620
25863
|
export {
|
|
25621
25864
|
index$j as ActionSheet,
|
|
25622
25865
|
AutoCenter,
|
|
@@ -25646,6 +25889,7 @@ export {
|
|
|
25646
25889
|
ErrorBlock,
|
|
25647
25890
|
FloatingBubble,
|
|
25648
25891
|
FloatingPanel,
|
|
25892
|
+
Footer,
|
|
25649
25893
|
index$a as Form,
|
|
25650
25894
|
Grid,
|
|
25651
25895
|
Image$1 as Image,
|