antd-mobile 5.28.1 → 5.28.2
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 +147 -125
- package/2x/bundle/antd-mobile.cjs.js +10 -9
- package/2x/bundle/antd-mobile.es.development.js +147 -125
- package/2x/bundle/antd-mobile.es.js +7276 -7250
- package/2x/bundle/antd-mobile.umd.development.js +147 -125
- package/2x/bundle/antd-mobile.umd.js +10 -9
- package/2x/bundle/css-vars-patch.css +1 -0
- package/2x/bundle/style.css +9 -1
- package/2x/cjs/components/popover/popover.css +1 -1
- package/2x/cjs/components/popover/popover.patch.css +1 -0
- package/2x/cjs/components/pull-to-refresh/pull-to-refresh.js +15 -16
- package/2x/cjs/components/stepper/index.d.ts +1 -1
- package/2x/cjs/components/stepper/stepper.d.ts +4 -2
- package/2x/cjs/components/stepper/stepper.js +21 -3
- package/2x/cjs/components/text-area/text-area.css +8 -0
- package/2x/cjs/components/text-area/text-area.js +12 -2
- package/2x/cjs/global/css-vars-patch.css +1 -0
- package/2x/cjs/index.d.ts +1 -1
- package/2x/cjs/locales/ko-KR.js +31 -2
- package/2x/cjs/utils/reduce-and-restore-motion.js +7 -6
- package/2x/cjs/utils/render-imperatively.js +9 -3
- package/2x/es/components/popover/popover.css +1 -1
- package/2x/es/components/popover/popover.patch.css +1 -0
- package/2x/es/components/pull-to-refresh/pull-to-refresh.js +15 -16
- package/2x/es/components/stepper/index.d.ts +1 -1
- package/2x/es/components/stepper/stepper.d.ts +4 -2
- package/2x/es/components/stepper/stepper.js +19 -3
- package/2x/es/components/text-area/text-area.css +8 -0
- package/2x/es/components/text-area/text-area.js +12 -2
- package/2x/es/global/css-vars-patch.css +1 -0
- package/2x/es/index.d.ts +1 -1
- package/2x/es/locales/ko-KR.js +31 -2
- package/2x/es/utils/reduce-and-restore-motion.js +7 -6
- package/2x/es/utils/render-imperatively.js +9 -3
- package/2x/package.json +2 -2
- package/bundle/antd-mobile.cjs.development.js +147 -125
- package/bundle/antd-mobile.cjs.js +10 -9
- package/bundle/antd-mobile.compatible.umd.js +1 -1
- package/bundle/antd-mobile.es.development.js +147 -125
- package/bundle/antd-mobile.es.js +7276 -7250
- package/bundle/antd-mobile.umd.development.js +147 -125
- package/bundle/antd-mobile.umd.js +10 -9
- package/bundle/css-vars-patch.css +1 -0
- package/bundle/style.css +1 -1
- package/cjs/components/popover/popover.css +1 -1
- package/cjs/components/popover/popover.patch.css +1 -0
- package/cjs/components/pull-to-refresh/pull-to-refresh.js +15 -16
- package/cjs/components/stepper/index.d.ts +1 -1
- package/cjs/components/stepper/stepper.d.ts +4 -2
- package/cjs/components/stepper/stepper.js +21 -3
- package/cjs/components/text-area/text-area.css +7 -0
- package/cjs/components/text-area/text-area.js +12 -2
- package/cjs/global/css-vars-patch.css +1 -0
- package/cjs/index.d.ts +1 -1
- package/cjs/locales/ko-KR.js +31 -2
- package/cjs/utils/reduce-and-restore-motion.js +7 -6
- package/cjs/utils/render-imperatively.js +9 -3
- package/es/components/popover/popover.css +1 -1
- package/es/components/popover/popover.patch.css +1 -0
- package/es/components/pull-to-refresh/pull-to-refresh.js +15 -16
- package/es/components/stepper/index.d.ts +1 -1
- package/es/components/stepper/stepper.d.ts +4 -2
- package/es/components/stepper/stepper.js +19 -3
- package/es/components/text-area/text-area.css +7 -0
- package/es/components/text-area/text-area.js +12 -2
- package/es/global/css-vars-patch.css +1 -0
- package/es/index.d.ts +1 -1
- package/es/locales/ko-KR.js +31 -2
- package/es/utils/reduce-and-restore-motion.js +7 -6
- package/es/utils/render-imperatively.js +9 -3
- package/package.json +2 -2
- package/umd/antd-mobile.js +1 -1
- package/umd/antd-mobile.js.LICENSE.txt +5 -4
|
@@ -3138,7 +3138,13 @@ const useLayoutEffectWithTarget = useEffectWithTarget;
|
|
|
3138
3138
|
const useIsomorphicLayoutEffectWithTarget = isBrowser$3 ? useLayoutEffectWithTarget : useEffectWithTarget$2;
|
|
3139
3139
|
const useIsomorphicLayoutEffectWithTarget$1 = useIsomorphicLayoutEffectWithTarget;
|
|
3140
3140
|
function useSize(target) {
|
|
3141
|
-
const [state, setState] = useRafState()
|
|
3141
|
+
const [state, setState] = useRafState(() => {
|
|
3142
|
+
const el = getTargetElement(target);
|
|
3143
|
+
return el ? {
|
|
3144
|
+
width: el.clientWidth,
|
|
3145
|
+
height: el.clientHeight
|
|
3146
|
+
} : void 0;
|
|
3147
|
+
});
|
|
3142
3148
|
useIsomorphicLayoutEffectWithTarget$1(() => {
|
|
3143
3149
|
const el = getTargetElement(target);
|
|
3144
3150
|
if (!el) {
|
|
@@ -7527,10 +7533,14 @@ function renderImperatively(element) {
|
|
|
7527
7533
|
ref: wrapperRef
|
|
7528
7534
|
}));
|
|
7529
7535
|
return {
|
|
7530
|
-
close: () => {
|
|
7536
|
+
close: () => __awaiter(this, void 0, void 0, function* () {
|
|
7531
7537
|
var _a;
|
|
7532
|
-
(
|
|
7533
|
-
|
|
7538
|
+
if (!wrapperRef.current) {
|
|
7539
|
+
unmount2();
|
|
7540
|
+
} else {
|
|
7541
|
+
(_a = wrapperRef.current) === null || _a === void 0 ? void 0 : _a.close();
|
|
7542
|
+
}
|
|
7543
|
+
}),
|
|
7534
7544
|
replace: (element2) => {
|
|
7535
7545
|
var _a;
|
|
7536
7546
|
(_a = wrapperRef.current) === null || _a === void 0 ? void 0 : _a.replace(element2);
|
|
@@ -8457,9 +8467,10 @@ const ScrollMask$1 = (props) => {
|
|
|
8457
8467
|
}));
|
|
8458
8468
|
};
|
|
8459
8469
|
const ScrollMask = ScrollMask$1;
|
|
8460
|
-
var
|
|
8470
|
+
var _reactIs_18_2_0_reactIs = { exports: {} };
|
|
8461
8471
|
var reactIs_development$1 = {};
|
|
8462
|
-
/**
|
|
8472
|
+
/**
|
|
8473
|
+
* @license React
|
|
8463
8474
|
* react-is.development.js
|
|
8464
8475
|
*
|
|
8465
8476
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
@@ -8469,56 +8480,38 @@ var reactIs_development$1 = {};
|
|
|
8469
8480
|
*/
|
|
8470
8481
|
{
|
|
8471
8482
|
(function() {
|
|
8472
|
-
var REACT_ELEMENT_TYPE =
|
|
8473
|
-
var REACT_PORTAL_TYPE =
|
|
8474
|
-
var REACT_FRAGMENT_TYPE =
|
|
8475
|
-
var REACT_STRICT_MODE_TYPE =
|
|
8476
|
-
var REACT_PROFILER_TYPE =
|
|
8477
|
-
var REACT_PROVIDER_TYPE =
|
|
8478
|
-
var REACT_CONTEXT_TYPE =
|
|
8479
|
-
var
|
|
8480
|
-
var
|
|
8481
|
-
var
|
|
8482
|
-
var
|
|
8483
|
-
var
|
|
8484
|
-
var
|
|
8485
|
-
var
|
|
8486
|
-
var REACT_FUNDAMENTAL_TYPE = 60117;
|
|
8487
|
-
var REACT_DEBUG_TRACING_MODE_TYPE = 60129;
|
|
8488
|
-
var REACT_LEGACY_HIDDEN_TYPE = 60131;
|
|
8489
|
-
if (typeof Symbol === "function" && Symbol.for) {
|
|
8490
|
-
var symbolFor = Symbol.for;
|
|
8491
|
-
REACT_ELEMENT_TYPE = symbolFor("react.element");
|
|
8492
|
-
REACT_PORTAL_TYPE = symbolFor("react.portal");
|
|
8493
|
-
REACT_FRAGMENT_TYPE = symbolFor("react.fragment");
|
|
8494
|
-
REACT_STRICT_MODE_TYPE = symbolFor("react.strict_mode");
|
|
8495
|
-
REACT_PROFILER_TYPE = symbolFor("react.profiler");
|
|
8496
|
-
REACT_PROVIDER_TYPE = symbolFor("react.provider");
|
|
8497
|
-
REACT_CONTEXT_TYPE = symbolFor("react.context");
|
|
8498
|
-
REACT_FORWARD_REF_TYPE = symbolFor("react.forward_ref");
|
|
8499
|
-
REACT_SUSPENSE_TYPE = symbolFor("react.suspense");
|
|
8500
|
-
REACT_SUSPENSE_LIST_TYPE = symbolFor("react.suspense_list");
|
|
8501
|
-
REACT_MEMO_TYPE = symbolFor("react.memo");
|
|
8502
|
-
REACT_LAZY_TYPE = symbolFor("react.lazy");
|
|
8503
|
-
REACT_BLOCK_TYPE = symbolFor("react.block");
|
|
8504
|
-
REACT_SERVER_BLOCK_TYPE = symbolFor("react.server.block");
|
|
8505
|
-
REACT_FUNDAMENTAL_TYPE = symbolFor("react.fundamental");
|
|
8506
|
-
symbolFor("react.scope");
|
|
8507
|
-
symbolFor("react.opaque.id");
|
|
8508
|
-
REACT_DEBUG_TRACING_MODE_TYPE = symbolFor("react.debug_trace_mode");
|
|
8509
|
-
symbolFor("react.offscreen");
|
|
8510
|
-
REACT_LEGACY_HIDDEN_TYPE = symbolFor("react.legacy_hidden");
|
|
8511
|
-
}
|
|
8483
|
+
var REACT_ELEMENT_TYPE = Symbol.for("react.element");
|
|
8484
|
+
var REACT_PORTAL_TYPE = Symbol.for("react.portal");
|
|
8485
|
+
var REACT_FRAGMENT_TYPE = Symbol.for("react.fragment");
|
|
8486
|
+
var REACT_STRICT_MODE_TYPE = Symbol.for("react.strict_mode");
|
|
8487
|
+
var REACT_PROFILER_TYPE = Symbol.for("react.profiler");
|
|
8488
|
+
var REACT_PROVIDER_TYPE = Symbol.for("react.provider");
|
|
8489
|
+
var REACT_CONTEXT_TYPE = Symbol.for("react.context");
|
|
8490
|
+
var REACT_SERVER_CONTEXT_TYPE = Symbol.for("react.server_context");
|
|
8491
|
+
var REACT_FORWARD_REF_TYPE = Symbol.for("react.forward_ref");
|
|
8492
|
+
var REACT_SUSPENSE_TYPE = Symbol.for("react.suspense");
|
|
8493
|
+
var REACT_SUSPENSE_LIST_TYPE = Symbol.for("react.suspense_list");
|
|
8494
|
+
var REACT_MEMO_TYPE = Symbol.for("react.memo");
|
|
8495
|
+
var REACT_LAZY_TYPE = Symbol.for("react.lazy");
|
|
8496
|
+
var REACT_OFFSCREEN_TYPE = Symbol.for("react.offscreen");
|
|
8512
8497
|
var enableScopeAPI = false;
|
|
8498
|
+
var enableCacheElement = false;
|
|
8499
|
+
var enableTransitionTracing = false;
|
|
8500
|
+
var enableLegacyHidden = false;
|
|
8501
|
+
var enableDebugTracing = false;
|
|
8502
|
+
var REACT_MODULE_REFERENCE;
|
|
8503
|
+
{
|
|
8504
|
+
REACT_MODULE_REFERENCE = Symbol.for("react.module.reference");
|
|
8505
|
+
}
|
|
8513
8506
|
function isValidElementType(type4) {
|
|
8514
8507
|
if (typeof type4 === "string" || typeof type4 === "function") {
|
|
8515
8508
|
return true;
|
|
8516
8509
|
}
|
|
8517
|
-
if (type4 === REACT_FRAGMENT_TYPE || type4 === REACT_PROFILER_TYPE ||
|
|
8510
|
+
if (type4 === REACT_FRAGMENT_TYPE || type4 === REACT_PROFILER_TYPE || enableDebugTracing || type4 === REACT_STRICT_MODE_TYPE || type4 === REACT_SUSPENSE_TYPE || type4 === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type4 === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing) {
|
|
8518
8511
|
return true;
|
|
8519
8512
|
}
|
|
8520
8513
|
if (typeof type4 === "object" && type4 !== null) {
|
|
8521
|
-
if (type4.$$typeof === REACT_LAZY_TYPE || type4.$$typeof === REACT_MEMO_TYPE || type4.$$typeof === REACT_PROVIDER_TYPE || type4.$$typeof === REACT_CONTEXT_TYPE || type4.$$typeof === REACT_FORWARD_REF_TYPE || type4.$$typeof ===
|
|
8514
|
+
if (type4.$$typeof === REACT_LAZY_TYPE || type4.$$typeof === REACT_MEMO_TYPE || type4.$$typeof === REACT_PROVIDER_TYPE || type4.$$typeof === REACT_CONTEXT_TYPE || type4.$$typeof === REACT_FORWARD_REF_TYPE || type4.$$typeof === REACT_MODULE_REFERENCE || type4.getModuleId !== void 0) {
|
|
8522
8515
|
return true;
|
|
8523
8516
|
}
|
|
8524
8517
|
}
|
|
@@ -8540,6 +8533,7 @@ var reactIs_development$1 = {};
|
|
|
8540
8533
|
default:
|
|
8541
8534
|
var $$typeofType = type4 && type4.$$typeof;
|
|
8542
8535
|
switch ($$typeofType) {
|
|
8536
|
+
case REACT_SERVER_CONTEXT_TYPE:
|
|
8543
8537
|
case REACT_CONTEXT_TYPE:
|
|
8544
8538
|
case REACT_FORWARD_REF_TYPE:
|
|
8545
8539
|
case REACT_LAZY_TYPE:
|
|
@@ -8567,6 +8561,7 @@ var reactIs_development$1 = {};
|
|
|
8567
8561
|
var Profiler = REACT_PROFILER_TYPE;
|
|
8568
8562
|
var StrictMode = REACT_STRICT_MODE_TYPE;
|
|
8569
8563
|
var Suspense = REACT_SUSPENSE_TYPE;
|
|
8564
|
+
var SuspenseList = REACT_SUSPENSE_LIST_TYPE;
|
|
8570
8565
|
var hasWarnedAboutDeprecatedIsAsyncMode = false;
|
|
8571
8566
|
var hasWarnedAboutDeprecatedIsConcurrentMode = false;
|
|
8572
8567
|
function isAsyncMode(object4) {
|
|
@@ -8620,6 +8615,9 @@ var reactIs_development$1 = {};
|
|
|
8620
8615
|
function isSuspense(object4) {
|
|
8621
8616
|
return typeOf(object4) === REACT_SUSPENSE_TYPE;
|
|
8622
8617
|
}
|
|
8618
|
+
function isSuspenseList(object4) {
|
|
8619
|
+
return typeOf(object4) === REACT_SUSPENSE_LIST_TYPE;
|
|
8620
|
+
}
|
|
8623
8621
|
reactIs_development$1.ContextConsumer = ContextConsumer;
|
|
8624
8622
|
reactIs_development$1.ContextProvider = ContextProvider;
|
|
8625
8623
|
reactIs_development$1.Element = Element2;
|
|
@@ -8631,6 +8629,7 @@ var reactIs_development$1 = {};
|
|
|
8631
8629
|
reactIs_development$1.Profiler = Profiler;
|
|
8632
8630
|
reactIs_development$1.StrictMode = StrictMode;
|
|
8633
8631
|
reactIs_development$1.Suspense = Suspense;
|
|
8632
|
+
reactIs_development$1.SuspenseList = SuspenseList;
|
|
8634
8633
|
reactIs_development$1.isAsyncMode = isAsyncMode;
|
|
8635
8634
|
reactIs_development$1.isConcurrentMode = isConcurrentMode;
|
|
8636
8635
|
reactIs_development$1.isContextConsumer = isContextConsumer;
|
|
@@ -8644,6 +8643,7 @@ var reactIs_development$1 = {};
|
|
|
8644
8643
|
reactIs_development$1.isProfiler = isProfiler;
|
|
8645
8644
|
reactIs_development$1.isStrictMode = isStrictMode;
|
|
8646
8645
|
reactIs_development$1.isSuspense = isSuspense;
|
|
8646
|
+
reactIs_development$1.isSuspenseList = isSuspenseList;
|
|
8647
8647
|
reactIs_development$1.isValidElementType = isValidElementType;
|
|
8648
8648
|
reactIs_development$1.typeOf = typeOf;
|
|
8649
8649
|
})();
|
|
@@ -8652,12 +8652,12 @@ var reactIs_development$1 = {};
|
|
|
8652
8652
|
{
|
|
8653
8653
|
module2.exports = reactIs_development$1;
|
|
8654
8654
|
}
|
|
8655
|
-
})(
|
|
8655
|
+
})(_reactIs_18_2_0_reactIs);
|
|
8656
8656
|
function traverseReactNode(children, fn) {
|
|
8657
8657
|
let i = 0;
|
|
8658
8658
|
function handle(target) {
|
|
8659
8659
|
React__default.default.Children.forEach(target, (child) => {
|
|
8660
|
-
if (!
|
|
8660
|
+
if (!_reactIs_18_2_0_reactIs.exports.isFragment(child)) {
|
|
8661
8661
|
fn(child, i);
|
|
8662
8662
|
i += 1;
|
|
8663
8663
|
} else {
|
|
@@ -10911,7 +10911,7 @@ var useSyncExternalStoreShim_development = {};
|
|
|
10911
10911
|
var useState2 = React2.useState, useEffect = React2.useEffect, useLayoutEffect2 = React2.useLayoutEffect, useDebugValue = React2.useDebugValue;
|
|
10912
10912
|
var didWarnOld18Alpha = false;
|
|
10913
10913
|
var didWarnUncachedGetSnapshot = false;
|
|
10914
|
-
function useSyncExternalStore(
|
|
10914
|
+
function useSyncExternalStore(subscribe2, getSnapshot, getServerSnapshot) {
|
|
10915
10915
|
{
|
|
10916
10916
|
if (!didWarnOld18Alpha) {
|
|
10917
10917
|
if (React2.startTransition !== void 0) {
|
|
@@ -10944,7 +10944,7 @@ var useSyncExternalStoreShim_development = {};
|
|
|
10944
10944
|
inst
|
|
10945
10945
|
});
|
|
10946
10946
|
}
|
|
10947
|
-
}, [
|
|
10947
|
+
}, [subscribe2, value, getSnapshot]);
|
|
10948
10948
|
useEffect(function() {
|
|
10949
10949
|
if (checkIfSnapshotChanged(inst)) {
|
|
10950
10950
|
forceUpdate({
|
|
@@ -10958,8 +10958,8 @@ var useSyncExternalStoreShim_development = {};
|
|
|
10958
10958
|
});
|
|
10959
10959
|
}
|
|
10960
10960
|
};
|
|
10961
|
-
return
|
|
10962
|
-
}, [
|
|
10961
|
+
return subscribe2(handleStoreChange);
|
|
10962
|
+
}, [subscribe2]);
|
|
10963
10963
|
useDebugValue(value);
|
|
10964
10964
|
return value;
|
|
10965
10965
|
}
|
|
@@ -10973,7 +10973,7 @@ var useSyncExternalStoreShim_development = {};
|
|
|
10973
10973
|
return true;
|
|
10974
10974
|
}
|
|
10975
10975
|
}
|
|
10976
|
-
function useSyncExternalStore$1(
|
|
10976
|
+
function useSyncExternalStore$1(subscribe2, getSnapshot, getServerSnapshot) {
|
|
10977
10977
|
return getSnapshot();
|
|
10978
10978
|
}
|
|
10979
10979
|
var canUseDOM = !!(typeof window !== "undefined" && typeof window.document !== "undefined" && typeof window.document.createElement !== "undefined");
|
|
@@ -11015,13 +11015,14 @@ function restoreMotion() {
|
|
|
11015
11015
|
function isMotionReduced() {
|
|
11016
11016
|
return reduced;
|
|
11017
11017
|
}
|
|
11018
|
+
function subscribe(onStoreChange) {
|
|
11019
|
+
subscribers.add(onStoreChange);
|
|
11020
|
+
return () => {
|
|
11021
|
+
subscribers.delete(onStoreChange);
|
|
11022
|
+
};
|
|
11023
|
+
}
|
|
11018
11024
|
function useMotionReduced() {
|
|
11019
|
-
return shim.exports.useSyncExternalStore(
|
|
11020
|
-
subscribers.add(onStoreChange);
|
|
11021
|
-
return () => {
|
|
11022
|
-
subscribers.delete(onStoreChange);
|
|
11023
|
-
};
|
|
11024
|
-
}, isMotionReduced);
|
|
11025
|
+
return shim.exports.useSyncExternalStore(subscribe, isMotionReduced);
|
|
11025
11026
|
}
|
|
11026
11027
|
const classPrefix$16 = "adm-spin-loading";
|
|
11027
11028
|
const colorRecord$2 = {
|
|
@@ -18789,9 +18790,9 @@ function isSimpleFunctionComponent(type4) {
|
|
|
18789
18790
|
return typeof type4 === "function" && !shouldConstruct(type4) && type4.defaultProps === void 0;
|
|
18790
18791
|
}
|
|
18791
18792
|
function isSafeSetRefComponent(component) {
|
|
18792
|
-
if (
|
|
18793
|
+
if (_reactIs_18_2_0_reactIs.exports.isFragment(component))
|
|
18793
18794
|
return false;
|
|
18794
|
-
if (
|
|
18795
|
+
if (_reactIs_18_2_0_reactIs.exports.isMemo(component))
|
|
18795
18796
|
return isSafeSetRefComponent(component.type);
|
|
18796
18797
|
return !isSimpleFunctionComponent(component.type);
|
|
18797
18798
|
}
|
|
@@ -19075,7 +19076,8 @@ const arrow = (options) => ({
|
|
|
19075
19076
|
y,
|
|
19076
19077
|
placement,
|
|
19077
19078
|
rects,
|
|
19078
|
-
platform: platform2
|
|
19079
|
+
platform: platform2,
|
|
19080
|
+
elements
|
|
19079
19081
|
} = state;
|
|
19080
19082
|
if (element == null) {
|
|
19081
19083
|
{
|
|
@@ -19091,14 +19093,16 @@ const arrow = (options) => ({
|
|
|
19091
19093
|
const axis = getMainAxisFromPlacement(placement);
|
|
19092
19094
|
const length = getLengthFromAxis(axis);
|
|
19093
19095
|
const arrowDimensions = await platform2.getDimensions(element);
|
|
19094
|
-
const
|
|
19095
|
-
const
|
|
19096
|
+
const isYAxis = axis === "y";
|
|
19097
|
+
const minProp = isYAxis ? "top" : "left";
|
|
19098
|
+
const maxProp = isYAxis ? "bottom" : "right";
|
|
19099
|
+
const clientProp = isYAxis ? "clientHeight" : "clientWidth";
|
|
19096
19100
|
const endDiff = rects.reference[length] + rects.reference[axis] - coords[axis] - rects.floating[length];
|
|
19097
19101
|
const startDiff = coords[axis] - rects.reference[axis];
|
|
19098
19102
|
const arrowOffsetParent = await (platform2.getOffsetParent == null ? void 0 : platform2.getOffsetParent(element));
|
|
19099
|
-
let clientSize = arrowOffsetParent ?
|
|
19100
|
-
if (clientSize
|
|
19101
|
-
clientSize = rects.floating[length];
|
|
19103
|
+
let clientSize = arrowOffsetParent ? arrowOffsetParent[clientProp] : 0;
|
|
19104
|
+
if (!clientSize || !await (platform2.isElement == null ? void 0 : platform2.isElement(arrowOffsetParent))) {
|
|
19105
|
+
clientSize = elements.floating[clientProp] || rects.floating[length];
|
|
19102
19106
|
}
|
|
19103
19107
|
const centerToReference = endDiff / 2 - startDiff / 2;
|
|
19104
19108
|
const min2 = paddingObject[minProp];
|
|
@@ -19538,25 +19542,8 @@ function getWindow(node) {
|
|
|
19538
19542
|
function getComputedStyle$1(element) {
|
|
19539
19543
|
return getWindow(element).getComputedStyle(element);
|
|
19540
19544
|
}
|
|
19541
|
-
|
|
19542
|
-
|
|
19543
|
-
const round = Math.round;
|
|
19544
|
-
function getCssDimensions(element) {
|
|
19545
|
-
const css = getComputedStyle$1(element);
|
|
19546
|
-
let width = parseFloat(css.width);
|
|
19547
|
-
let height = parseFloat(css.height);
|
|
19548
|
-
const offsetWidth = element.offsetWidth;
|
|
19549
|
-
const offsetHeight = element.offsetHeight;
|
|
19550
|
-
const shouldFallback = round(width) !== offsetWidth || round(height) !== offsetHeight;
|
|
19551
|
-
if (shouldFallback) {
|
|
19552
|
-
width = offsetWidth;
|
|
19553
|
-
height = offsetHeight;
|
|
19554
|
-
}
|
|
19555
|
-
return {
|
|
19556
|
-
width,
|
|
19557
|
-
height,
|
|
19558
|
-
fallback: shouldFallback
|
|
19559
|
-
};
|
|
19545
|
+
function isNode(value) {
|
|
19546
|
+
return value instanceof getWindow(value).Node;
|
|
19560
19547
|
}
|
|
19561
19548
|
function getNodeName(node) {
|
|
19562
19549
|
return isNode(node) ? (node.nodeName || "").toLowerCase() : "";
|
|
@@ -19579,9 +19566,6 @@ function isHTMLElement(value) {
|
|
|
19579
19566
|
function isElement(value) {
|
|
19580
19567
|
return value instanceof getWindow(value).Element;
|
|
19581
19568
|
}
|
|
19582
|
-
function isNode(value) {
|
|
19583
|
-
return value instanceof getWindow(value).Node;
|
|
19584
|
-
}
|
|
19585
19569
|
function isShadowRoot(node) {
|
|
19586
19570
|
if (typeof ShadowRoot === "undefined") {
|
|
19587
19571
|
return false;
|
|
@@ -19616,6 +19600,27 @@ function isClientRectVisualViewportBased() {
|
|
|
19616
19600
|
function isLastTraversableNode(node) {
|
|
19617
19601
|
return ["html", "body", "#document"].includes(getNodeName(node));
|
|
19618
19602
|
}
|
|
19603
|
+
const min = Math.min;
|
|
19604
|
+
const max = Math.max;
|
|
19605
|
+
const round = Math.round;
|
|
19606
|
+
function getCssDimensions(element) {
|
|
19607
|
+
const css = getComputedStyle$1(element);
|
|
19608
|
+
let width = parseFloat(css.width);
|
|
19609
|
+
let height = parseFloat(css.height);
|
|
19610
|
+
const hasOffset = isHTMLElement(element);
|
|
19611
|
+
const offsetWidth = hasOffset ? element.offsetWidth : width;
|
|
19612
|
+
const offsetHeight = hasOffset ? element.offsetHeight : height;
|
|
19613
|
+
const shouldFallback = round(width) !== offsetWidth || round(height) !== offsetHeight;
|
|
19614
|
+
if (shouldFallback) {
|
|
19615
|
+
width = offsetWidth;
|
|
19616
|
+
height = offsetHeight;
|
|
19617
|
+
}
|
|
19618
|
+
return {
|
|
19619
|
+
width,
|
|
19620
|
+
height,
|
|
19621
|
+
fallback: shouldFallback
|
|
19622
|
+
};
|
|
19623
|
+
}
|
|
19619
19624
|
function unwrapElement(element) {
|
|
19620
19625
|
return !isElement(element) ? element.contextElement : element;
|
|
19621
19626
|
}
|
|
@@ -19692,16 +19697,12 @@ function getBoundingClientRect(element, includeScale, isFixedStrategy, offsetPar
|
|
|
19692
19697
|
currentIFrame = getWindow(currentIFrame).frameElement;
|
|
19693
19698
|
}
|
|
19694
19699
|
}
|
|
19695
|
-
return {
|
|
19700
|
+
return rectToClientRect({
|
|
19696
19701
|
width,
|
|
19697
19702
|
height,
|
|
19698
|
-
top: y,
|
|
19699
|
-
right: x + width,
|
|
19700
|
-
bottom: y + height,
|
|
19701
|
-
left: x,
|
|
19702
19703
|
x,
|
|
19703
19704
|
y
|
|
19704
|
-
};
|
|
19705
|
+
});
|
|
19705
19706
|
}
|
|
19706
19707
|
function getDocumentElement(node) {
|
|
19707
19708
|
return ((isNode(node) ? node.ownerDocument : node.document) || window.document).documentElement;
|
|
@@ -19929,10 +19930,7 @@ function getClippingRect(_ref) {
|
|
|
19929
19930
|
};
|
|
19930
19931
|
}
|
|
19931
19932
|
function getDimensions(element) {
|
|
19932
|
-
|
|
19933
|
-
return getCssDimensions(element);
|
|
19934
|
-
}
|
|
19935
|
-
return element.getBoundingClientRect();
|
|
19933
|
+
return getCssDimensions(element);
|
|
19936
19934
|
}
|
|
19937
19935
|
function getTrueOffsetParent(element, polyfill) {
|
|
19938
19936
|
if (!isHTMLElement(element) || getComputedStyle$1(element).position === "fixed") {
|
|
@@ -19956,6 +19954,9 @@ function getContainingBlock(element) {
|
|
|
19956
19954
|
}
|
|
19957
19955
|
function getOffsetParent(element, polyfill) {
|
|
19958
19956
|
const window2 = getWindow(element);
|
|
19957
|
+
if (!isHTMLElement(element)) {
|
|
19958
|
+
return window2;
|
|
19959
|
+
}
|
|
19959
19960
|
let offsetParent = getTrueOffsetParent(element, polyfill);
|
|
19960
19961
|
while (offsetParent && isTableElement(offsetParent) && getComputedStyle$1(offsetParent).position === "static") {
|
|
19961
19962
|
offsetParent = getTrueOffsetParent(offsetParent, polyfill);
|
|
@@ -20044,12 +20045,8 @@ function autoUpdate(reference, floating, update2, options) {
|
|
|
20044
20045
|
});
|
|
20045
20046
|
let observer = null;
|
|
20046
20047
|
if (elementResize) {
|
|
20047
|
-
let initialUpdate = true;
|
|
20048
20048
|
observer = new ResizeObserver(() => {
|
|
20049
|
-
|
|
20050
|
-
update2();
|
|
20051
|
-
}
|
|
20052
|
-
initialUpdate = false;
|
|
20049
|
+
update2();
|
|
20053
20050
|
});
|
|
20054
20051
|
isElement(reference) && !animationFrame && observer.observe(reference);
|
|
20055
20052
|
if (!isElement(reference) && reference.contextElement && !animationFrame) {
|
|
@@ -22614,6 +22611,19 @@ const PullToRefresh$1 = (p) => {
|
|
|
22614
22611
|
(_a2 = elementRef.current) === null || _a2 === void 0 ? void 0 : _a2.addEventListener("touchmove", () => {
|
|
22615
22612
|
});
|
|
22616
22613
|
}, []);
|
|
22614
|
+
const reset = () => {
|
|
22615
|
+
return new Promise((resolve) => {
|
|
22616
|
+
api.start({
|
|
22617
|
+
to: {
|
|
22618
|
+
height: 0
|
|
22619
|
+
},
|
|
22620
|
+
onResolve() {
|
|
22621
|
+
setStatus("pulling");
|
|
22622
|
+
resolve();
|
|
22623
|
+
}
|
|
22624
|
+
});
|
|
22625
|
+
});
|
|
22626
|
+
};
|
|
22617
22627
|
function doRefresh() {
|
|
22618
22628
|
return __awaiter(this, void 0, void 0, function* () {
|
|
22619
22629
|
api.start({
|
|
@@ -22624,27 +22634,13 @@ const PullToRefresh$1 = (p) => {
|
|
|
22624
22634
|
yield props.onRefresh();
|
|
22625
22635
|
setStatus("complete");
|
|
22626
22636
|
} catch (e) {
|
|
22627
|
-
|
|
22628
|
-
to: (next) => __awaiter(this, void 0, void 0, function* () {
|
|
22629
|
-
yield next({
|
|
22630
|
-
height: 0
|
|
22631
|
-
});
|
|
22632
|
-
setStatus("pulling");
|
|
22633
|
-
})
|
|
22634
|
-
});
|
|
22637
|
+
reset();
|
|
22635
22638
|
throw e;
|
|
22636
22639
|
}
|
|
22637
22640
|
if (props.completeDelay > 0) {
|
|
22638
22641
|
yield sleep(props.completeDelay);
|
|
22639
22642
|
}
|
|
22640
|
-
|
|
22641
|
-
to: (next) => __awaiter(this, void 0, void 0, function* () {
|
|
22642
|
-
yield next({
|
|
22643
|
-
height: 0
|
|
22644
|
-
});
|
|
22645
|
-
setStatus("pulling");
|
|
22646
|
-
})
|
|
22647
|
-
});
|
|
22643
|
+
reset();
|
|
22648
22644
|
});
|
|
22649
22645
|
}
|
|
22650
22646
|
useDrag((state) => {
|
|
@@ -24198,7 +24194,7 @@ const defaultProps$d = {
|
|
|
24198
24194
|
disabled: false,
|
|
24199
24195
|
allowEmpty: false
|
|
24200
24196
|
};
|
|
24201
|
-
function
|
|
24197
|
+
function InnerStepper(p, ref) {
|
|
24202
24198
|
const props = mergeProps(defaultProps$d, p);
|
|
24203
24199
|
const {
|
|
24204
24200
|
defaultValue = 0,
|
|
@@ -24217,6 +24213,20 @@ function Stepper(p) {
|
|
|
24217
24213
|
const {
|
|
24218
24214
|
locale
|
|
24219
24215
|
} = useConfig();
|
|
24216
|
+
React$4.useImperativeHandle(ref, () => ({
|
|
24217
|
+
focus: () => {
|
|
24218
|
+
var _a;
|
|
24219
|
+
(_a = inputRef.current) === null || _a === void 0 ? void 0 : _a.focus();
|
|
24220
|
+
},
|
|
24221
|
+
blur: () => {
|
|
24222
|
+
var _a;
|
|
24223
|
+
(_a = inputRef.current) === null || _a === void 0 ? void 0 : _a.blur();
|
|
24224
|
+
},
|
|
24225
|
+
get nativeElement() {
|
|
24226
|
+
var _a, _b;
|
|
24227
|
+
return (_b = (_a = inputRef.current) === null || _a === void 0 ? void 0 : _a.nativeElement) !== null && _b !== void 0 ? _b : null;
|
|
24228
|
+
}
|
|
24229
|
+
}));
|
|
24220
24230
|
const fixedValue = (value2) => {
|
|
24221
24231
|
const fixedValue2 = digits !== void 0 ? toFixed(value2.toString(), ".", digits) : value2;
|
|
24222
24232
|
return fixedValue2.toString();
|
|
@@ -24381,6 +24391,8 @@ function Stepper(p) {
|
|
|
24381
24391
|
"aria-label": locale.Stepper.increase
|
|
24382
24392
|
}, React__default.default.createElement(AddOutline, null))));
|
|
24383
24393
|
}
|
|
24394
|
+
const Stepper$1 = React$4.forwardRef(InnerStepper);
|
|
24395
|
+
const Stepper = Stepper$1;
|
|
24384
24396
|
const steps = "";
|
|
24385
24397
|
const classPrefix$d = `adm-step`;
|
|
24386
24398
|
const Step = (props) => {
|
|
@@ -25189,6 +25201,7 @@ const TextArea$1 = React$4.forwardRef((p, ref) => {
|
|
|
25189
25201
|
}
|
|
25190
25202
|
const nativeTextAreaRef = React$4.useRef(null);
|
|
25191
25203
|
const heightRef = React$4.useRef("auto");
|
|
25204
|
+
const hiddenTextAreaRef = React$4.useRef(null);
|
|
25192
25205
|
React$4.useImperativeHandle(ref, () => ({
|
|
25193
25206
|
clear: () => {
|
|
25194
25207
|
setValue2("");
|
|
@@ -25209,10 +25222,13 @@ const TextArea$1 = React$4.forwardRef((p, ref) => {
|
|
|
25209
25222
|
if (!autoSize)
|
|
25210
25223
|
return;
|
|
25211
25224
|
const textArea2 = nativeTextAreaRef.current;
|
|
25225
|
+
const hiddenTextArea = hiddenTextAreaRef.current;
|
|
25212
25226
|
if (!textArea2)
|
|
25213
25227
|
return;
|
|
25214
25228
|
textArea2.style.height = heightRef.current;
|
|
25215
|
-
|
|
25229
|
+
if (!hiddenTextArea)
|
|
25230
|
+
return;
|
|
25231
|
+
let height = hiddenTextArea.scrollHeight;
|
|
25216
25232
|
if (typeof autoSize === "object") {
|
|
25217
25233
|
const computedStyle = window.getComputedStyle(textArea2);
|
|
25218
25234
|
const lineHeight = parseFloat(computedStyle.lineHeight);
|
|
@@ -25274,7 +25290,13 @@ const TextArea$1 = React$4.forwardRef((p, ref) => {
|
|
|
25274
25290
|
onFocus: props.onFocus,
|
|
25275
25291
|
onBlur: props.onBlur,
|
|
25276
25292
|
onClick: props.onClick
|
|
25277
|
-
}), count
|
|
25293
|
+
}), count, autoSize && React__default.default.createElement("textarea", {
|
|
25294
|
+
ref: hiddenTextAreaRef,
|
|
25295
|
+
className: `${classPrefix$6}-element ${classPrefix$6}-element-hidden`,
|
|
25296
|
+
value,
|
|
25297
|
+
"aria-hidden": true,
|
|
25298
|
+
readOnly: true
|
|
25299
|
+
})));
|
|
25278
25300
|
});
|
|
25279
25301
|
TextArea$1.defaultProps = defaultProps$6;
|
|
25280
25302
|
const TextArea = TextArea$1;
|