antd-mobile 5.11.1 → 5.12.1
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/cjs/components/calendar/calendar.d.ts +4 -0
- package/2x/cjs/components/calendar/calendar.js +13 -9
- package/2x/cjs/components/capsule-tabs/capsule-tabs.css +1 -0
- package/2x/cjs/components/cascade-picker/cascade-picker.d.ts +6 -3
- package/2x/cjs/components/cascade-picker/cascade-picker.js +8 -4
- package/2x/cjs/components/cascade-picker/index.d.ts +4 -2
- package/2x/cjs/components/date-picker/date-picker.d.ts +18 -4
- package/2x/cjs/components/date-picker/date-picker.js +5 -6
- package/2x/cjs/components/date-picker/index.d.ts +15 -2
- package/2x/cjs/components/dialog/dialog.js +2 -2
- package/2x/cjs/components/form/form-item.d.ts +2 -1
- package/2x/cjs/components/form/form-item.js +21 -4
- package/2x/cjs/components/form/utils.d.ts +1 -0
- package/2x/cjs/components/form/utils.js +20 -0
- package/2x/cjs/components/image-uploader/image-uploader.js +10 -4
- package/2x/cjs/components/input/input.d.ts +2 -2
- package/2x/cjs/components/input/input.js +1 -0
- package/2x/cjs/components/jumbo-tabs/jumbo-tabs.css +1 -0
- package/2x/cjs/components/list/list-item.js +7 -5
- package/2x/cjs/components/list/list.css +1 -0
- package/2x/cjs/components/mask/mask.js +1 -1
- package/2x/cjs/components/modal/modal.js +2 -2
- package/2x/cjs/components/picker/index.d.ts +44 -3
- package/2x/cjs/components/picker/picker.d.ts +32 -2
- package/2x/cjs/components/picker/picker.js +43 -16
- package/2x/cjs/components/popup/popup.js +1 -1
- package/2x/cjs/components/swipe-action/swipe-action.js +1 -1
- package/2x/cjs/components/tabs/tabs.css +1 -0
- package/2x/cjs/components/text-area/text-area.d.ts +2 -2
- package/2x/cjs/components/text-area/text-area.js +4 -1
- package/2x/cjs/components/toast/methods.js +3 -7
- package/2x/cjs/components/virtual-input/virtual-input.js +2 -1
- package/2x/cjs/locales/base.d.ts +1 -0
- package/2x/cjs/locales/base.js +2 -1
- package/2x/cjs/locales/en-US.d.ts +1 -0
- package/2x/cjs/locales/es-ES.d.ts +1 -0
- package/2x/cjs/locales/fa-IR.d.ts +1 -0
- package/2x/cjs/locales/ko-KR.d.ts +1 -0
- package/2x/cjs/locales/zh-CN.d.ts +1 -0
- package/2x/cjs/locales/zh-CN.js +2 -1
- package/2x/cjs/locales/zh-HK.d.ts +1 -0
- package/2x/cjs/locales/zh-TW.d.ts +1 -0
- package/2x/cjs/utils/is-node-with-content.d.ts +4 -0
- package/2x/cjs/utils/is-node-with-content.js +10 -0
- package/2x/cjs/utils/render-to-body.js +3 -6
- package/2x/cjs/utils/render.d.ts +9 -0
- package/2x/cjs/utils/render.js +92 -0
- package/2x/cjs/utils/use-drag-and-pinch.d.ts +1 -1
- package/2x/cjs/utils/use-props-value.d.ts +1 -1
- package/2x/es/components/calendar/calendar.d.ts +4 -0
- package/2x/es/components/calendar/calendar.js +13 -9
- package/2x/es/components/capsule-tabs/capsule-tabs.css +1 -0
- package/2x/es/components/cascade-picker/cascade-picker.d.ts +6 -3
- package/2x/es/components/cascade-picker/cascade-picker.js +4 -3
- package/2x/es/components/cascade-picker/index.d.ts +4 -2
- package/2x/es/components/date-picker/date-picker.d.ts +18 -4
- package/2x/es/components/date-picker/date-picker.js +6 -5
- package/2x/es/components/date-picker/index.d.ts +15 -2
- package/2x/es/components/dialog/dialog.js +2 -2
- package/2x/es/components/form/form-item.d.ts +2 -1
- package/2x/es/components/form/form-item.js +23 -4
- package/2x/es/components/form/utils.d.ts +1 -0
- package/2x/es/components/form/utils.js +17 -0
- package/2x/es/components/image-uploader/image-uploader.js +9 -4
- package/2x/es/components/input/input.d.ts +2 -2
- package/2x/es/components/input/input.js +1 -0
- package/2x/es/components/jumbo-tabs/jumbo-tabs.css +1 -0
- package/2x/es/components/list/list-item.js +6 -5
- package/2x/es/components/list/list.css +1 -0
- package/2x/es/components/mask/mask.js +1 -1
- package/2x/es/components/modal/modal.js +2 -2
- package/2x/es/components/picker/index.d.ts +44 -3
- package/2x/es/components/picker/picker.d.ts +32 -2
- package/2x/es/components/picker/picker.js +42 -17
- package/2x/es/components/popup/popup.js +1 -1
- package/2x/es/components/swipe-action/swipe-action.js +1 -1
- package/2x/es/components/tabs/tabs.css +1 -0
- package/2x/es/components/text-area/text-area.d.ts +2 -2
- package/2x/es/components/text-area/text-area.js +4 -2
- package/2x/es/components/toast/methods.js +3 -3
- package/2x/es/components/virtual-input/virtual-input.js +2 -1
- package/2x/es/locales/base.d.ts +1 -0
- package/2x/es/locales/base.js +2 -1
- package/2x/es/locales/en-US.d.ts +1 -0
- package/2x/es/locales/es-ES.d.ts +1 -0
- package/2x/es/locales/fa-IR.d.ts +1 -0
- package/2x/es/locales/ko-KR.d.ts +1 -0
- package/2x/es/locales/zh-CN.d.ts +1 -0
- package/2x/es/locales/zh-CN.js +2 -1
- package/2x/es/locales/zh-HK.d.ts +1 -0
- package/2x/es/locales/zh-TW.d.ts +1 -0
- package/2x/es/utils/is-node-with-content.d.ts +4 -0
- package/2x/es/utils/is-node-with-content.js +3 -0
- package/2x/es/utils/render-to-body.js +3 -3
- package/2x/es/utils/render.d.ts +9 -0
- package/2x/es/utils/render.js +77 -0
- package/2x/es/utils/use-drag-and-pinch.d.ts +1 -1
- package/2x/es/utils/use-props-value.d.ts +1 -1
- package/2x/package.json +8 -8
- package/bundle/antd-mobile.cjs.js +5072 -4312
- package/bundle/antd-mobile.es.js +5073 -4313
- package/bundle/style.css +4 -0
- package/cjs/components/calendar/calendar.d.ts +4 -0
- package/cjs/components/calendar/calendar.js +13 -9
- package/cjs/components/capsule-tabs/capsule-tabs.css +1 -0
- package/cjs/components/cascade-picker/cascade-picker.d.ts +6 -3
- package/cjs/components/cascade-picker/cascade-picker.js +8 -4
- package/cjs/components/cascade-picker/index.d.ts +4 -2
- package/cjs/components/date-picker/date-picker.d.ts +18 -4
- package/cjs/components/date-picker/date-picker.js +5 -6
- package/cjs/components/date-picker/index.d.ts +15 -2
- package/cjs/components/dialog/dialog.js +2 -2
- package/cjs/components/form/form-item.d.ts +2 -1
- package/cjs/components/form/form-item.js +21 -4
- package/cjs/components/form/utils.d.ts +1 -0
- package/cjs/components/form/utils.js +20 -0
- package/cjs/components/image-uploader/image-uploader.js +10 -4
- package/cjs/components/input/input.d.ts +2 -2
- package/cjs/components/input/input.js +1 -0
- package/cjs/components/jumbo-tabs/jumbo-tabs.css +1 -0
- package/cjs/components/list/list-item.js +7 -5
- package/cjs/components/list/list.css +1 -0
- package/cjs/components/mask/mask.js +1 -1
- package/cjs/components/modal/modal.js +2 -2
- package/cjs/components/picker/index.d.ts +44 -3
- package/cjs/components/picker/picker.d.ts +32 -2
- package/cjs/components/picker/picker.js +43 -16
- package/cjs/components/popup/popup.js +1 -1
- package/cjs/components/swipe-action/swipe-action.js +1 -1
- package/cjs/components/tabs/tabs.css +1 -0
- package/cjs/components/text-area/text-area.d.ts +2 -2
- package/cjs/components/text-area/text-area.js +4 -1
- package/cjs/components/toast/methods.js +3 -7
- package/cjs/components/virtual-input/virtual-input.js +2 -1
- package/cjs/locales/base.d.ts +1 -0
- package/cjs/locales/base.js +2 -1
- package/cjs/locales/en-US.d.ts +1 -0
- package/cjs/locales/es-ES.d.ts +1 -0
- package/cjs/locales/fa-IR.d.ts +1 -0
- package/cjs/locales/ko-KR.d.ts +1 -0
- package/cjs/locales/zh-CN.d.ts +1 -0
- package/cjs/locales/zh-CN.js +2 -1
- package/cjs/locales/zh-HK.d.ts +1 -0
- package/cjs/locales/zh-TW.d.ts +1 -0
- package/cjs/utils/is-node-with-content.d.ts +4 -0
- package/cjs/utils/is-node-with-content.js +10 -0
- package/cjs/utils/render-to-body.js +3 -6
- package/cjs/utils/render.d.ts +9 -0
- package/cjs/utils/render.js +92 -0
- package/cjs/utils/use-drag-and-pinch.d.ts +1 -1
- package/cjs/utils/use-props-value.d.ts +1 -1
- package/es/components/calendar/calendar.d.ts +4 -0
- package/es/components/calendar/calendar.js +13 -9
- package/es/components/capsule-tabs/capsule-tabs.css +1 -0
- package/es/components/cascade-picker/cascade-picker.d.ts +6 -3
- package/es/components/cascade-picker/cascade-picker.js +4 -3
- package/es/components/cascade-picker/index.d.ts +4 -2
- package/es/components/date-picker/date-picker.d.ts +18 -4
- package/es/components/date-picker/date-picker.js +6 -5
- package/es/components/date-picker/index.d.ts +15 -2
- package/es/components/dialog/dialog.js +2 -2
- package/es/components/form/form-item.d.ts +2 -1
- package/es/components/form/form-item.js +23 -4
- package/es/components/form/utils.d.ts +1 -0
- package/es/components/form/utils.js +17 -0
- package/es/components/image-uploader/image-uploader.js +9 -4
- package/es/components/input/input.d.ts +2 -2
- package/es/components/input/input.js +1 -0
- package/es/components/jumbo-tabs/jumbo-tabs.css +1 -0
- package/es/components/list/list-item.js +6 -5
- package/es/components/list/list.css +1 -0
- package/es/components/mask/mask.js +1 -1
- package/es/components/modal/modal.js +2 -2
- package/es/components/picker/index.d.ts +44 -3
- package/es/components/picker/picker.d.ts +32 -2
- package/es/components/picker/picker.js +42 -17
- package/es/components/popup/popup.js +1 -1
- package/es/components/swipe-action/swipe-action.js +1 -1
- package/es/components/tabs/tabs.css +1 -0
- package/es/components/text-area/text-area.d.ts +2 -2
- package/es/components/text-area/text-area.js +4 -2
- package/es/components/toast/methods.js +3 -3
- package/es/components/virtual-input/virtual-input.js +2 -1
- package/es/locales/base.d.ts +1 -0
- package/es/locales/base.js +2 -1
- package/es/locales/en-US.d.ts +1 -0
- package/es/locales/es-ES.d.ts +1 -0
- package/es/locales/fa-IR.d.ts +1 -0
- package/es/locales/ko-KR.d.ts +1 -0
- package/es/locales/zh-CN.d.ts +1 -0
- package/es/locales/zh-CN.js +2 -1
- package/es/locales/zh-HK.d.ts +1 -0
- package/es/locales/zh-TW.d.ts +1 -0
- package/es/utils/is-node-with-content.d.ts +4 -0
- package/es/utils/is-node-with-content.js +3 -0
- package/es/utils/render-to-body.js +3 -3
- package/es/utils/render.d.ts +9 -0
- package/es/utils/render.js +77 -0
- package/es/utils/use-drag-and-pinch.d.ts +1 -1
- package/es/utils/use-props-value.d.ts +1 -1
- package/package.json +8 -8
- package/umd/antd-mobile.js +1 -1
|
@@ -185,7 +185,7 @@ export const SwipeAction = forwardRef((p, ref) => {
|
|
|
185
185
|
}
|
|
186
186
|
}, React.createElement(animated.div, {
|
|
187
187
|
style: {
|
|
188
|
-
pointerEvents: x.to(v => v !== 0 && x.goal !== 0 ? 'none' : '
|
|
188
|
+
pointerEvents: x.to(v => v !== 0 && x.goal !== 0 ? 'none' : 'auto')
|
|
189
189
|
}
|
|
190
190
|
}, props.children)), withStopPropagation(props.stopPropagation, React.createElement("div", {
|
|
191
191
|
className: 'adm-swipe-action-actions adm-swipe-action-actions-right',
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import type { ReactNode } from 'react';
|
|
3
3
|
import { NativeProps } from '../../utils/native-props';
|
|
4
|
-
export declare type TextAreaProps = Pick<React.DetailedHTMLProps<React.TextareaHTMLAttributes<HTMLTextAreaElement>, HTMLTextAreaElement>, 'autoComplete' | 'autoFocus' | 'disabled' | 'readOnly' | 'onFocus' | 'onBlur' | 'onCompositionStart' | 'onCompositionEnd' | 'onClick'> & {
|
|
4
|
+
export declare type TextAreaProps = Pick<React.DetailedHTMLProps<React.TextareaHTMLAttributes<HTMLTextAreaElement>, HTMLTextAreaElement>, 'autoComplete' | 'autoFocus' | 'disabled' | 'readOnly' | 'name' | 'onFocus' | 'onBlur' | 'onCompositionStart' | 'onCompositionEnd' | 'onClick'> & {
|
|
5
5
|
onChange?: (val: string) => void;
|
|
6
6
|
value?: string;
|
|
7
7
|
defaultValue?: string;
|
|
@@ -20,7 +20,7 @@ export declare type TextAreaRef = {
|
|
|
20
20
|
focus: () => void;
|
|
21
21
|
blur: () => void;
|
|
22
22
|
};
|
|
23
|
-
export declare const TextArea: React.ForwardRefExoticComponent<Pick<React.DetailedHTMLProps<React.TextareaHTMLAttributes<HTMLTextAreaElement>, HTMLTextAreaElement>, "onClick" | "disabled" | "onCompositionEnd" | "onCompositionStart" | "onFocus" | "onBlur" | "autoComplete" | "autoFocus" | "readOnly"> & {
|
|
23
|
+
export declare const TextArea: React.ForwardRefExoticComponent<Pick<React.DetailedHTMLProps<React.TextareaHTMLAttributes<HTMLTextAreaElement>, HTMLTextAreaElement>, "onClick" | "disabled" | "name" | "onCompositionEnd" | "onCompositionStart" | "onFocus" | "onBlur" | "autoComplete" | "autoFocus" | "readOnly"> & {
|
|
24
24
|
onChange?: ((val: string) => void) | undefined;
|
|
25
25
|
value?: string | undefined;
|
|
26
26
|
defaultValue?: string | undefined;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import React, { forwardRef,
|
|
1
|
+
import React, { forwardRef, useImperativeHandle, useRef } from 'react';
|
|
2
|
+
import { useIsomorphicLayoutEffect } from 'ahooks';
|
|
2
3
|
import { withNativeProps } from '../../utils/native-props';
|
|
3
4
|
import { usePropsValue } from '../../utils/use-props-value';
|
|
4
5
|
import { mergeProps } from '../../utils/with-default-props';
|
|
@@ -41,7 +42,7 @@ export const TextArea = forwardRef((p, ref) => {
|
|
|
41
42
|
(_a = nativeTextAreaRef.current) === null || _a === void 0 ? void 0 : _a.blur();
|
|
42
43
|
}
|
|
43
44
|
}));
|
|
44
|
-
|
|
45
|
+
useIsomorphicLayoutEffect(() => {
|
|
45
46
|
if (!autoSize) return;
|
|
46
47
|
const textArea = nativeTextAreaRef.current;
|
|
47
48
|
if (!textArea) return;
|
|
@@ -114,6 +115,7 @@ export const TextArea = forwardRef((p, ref) => {
|
|
|
114
115
|
autoFocus: props.autoFocus,
|
|
115
116
|
disabled: props.disabled,
|
|
116
117
|
readOnly: props.readOnly,
|
|
118
|
+
name: props.name,
|
|
117
119
|
onFocus: props.onFocus,
|
|
118
120
|
onBlur: props.onBlur,
|
|
119
121
|
onClick: props.onClick
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import React, { createRef, forwardRef, useEffect, useImperativeHandle, useState } from 'react';
|
|
2
2
|
import { resolveContainer } from '../../utils/get-container';
|
|
3
|
-
import ReactDOM from 'react-dom';
|
|
4
3
|
import { InternalToast } from './toast';
|
|
5
4
|
import { mergeProps } from '../../utils/with-default-props';
|
|
5
|
+
import { render, unmount as reactUnmount } from '../../utils/render';
|
|
6
6
|
const containers = [];
|
|
7
7
|
|
|
8
8
|
function unmount(container) {
|
|
9
|
-
const unmountResult =
|
|
9
|
+
const unmountResult = reactUnmount(container);
|
|
10
10
|
|
|
11
11
|
if (unmountResult && container.parentNode) {
|
|
12
12
|
container.parentNode.removeChild(container);
|
|
@@ -64,7 +64,7 @@ export function show(p) {
|
|
|
64
64
|
}));
|
|
65
65
|
});
|
|
66
66
|
const ref = createRef();
|
|
67
|
-
|
|
67
|
+
render(React.createElement(TempToast, {
|
|
68
68
|
ref: ref
|
|
69
69
|
}), container);
|
|
70
70
|
return {
|
|
@@ -84,7 +84,8 @@ export const VirtualInput = forwardRef((p, ref) => {
|
|
|
84
84
|
|
|
85
85
|
(_a = rootRef.current) === null || _a === void 0 ? void 0 : _a.blur();
|
|
86
86
|
(_c = (_b = keyboard.props).onClose) === null || _c === void 0 ? void 0 : _c.call(_b);
|
|
87
|
-
}
|
|
87
|
+
},
|
|
88
|
+
getContainer: null
|
|
88
89
|
});
|
|
89
90
|
return withNativeProps(props, React.createElement("div", {
|
|
90
91
|
ref: rootRef,
|
package/es/locales/base.d.ts
CHANGED
package/es/locales/base.js
CHANGED
package/es/locales/en-US.d.ts
CHANGED
package/es/locales/es-ES.d.ts
CHANGED
package/es/locales/fa-IR.d.ts
CHANGED
package/es/locales/ko-KR.d.ts
CHANGED
package/es/locales/zh-CN.d.ts
CHANGED
package/es/locales/zh-CN.js
CHANGED
package/es/locales/zh-HK.d.ts
CHANGED
package/es/locales/zh-TW.d.ts
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { render, unmount as reactUnmount } from './render';
|
|
2
2
|
export function renderToBody(element) {
|
|
3
3
|
const container = document.createElement('div');
|
|
4
4
|
document.body.appendChild(container);
|
|
5
5
|
|
|
6
6
|
function unmount() {
|
|
7
|
-
const unmountResult =
|
|
7
|
+
const unmountResult = reactUnmount(container);
|
|
8
8
|
|
|
9
9
|
if (unmountResult && container.parentNode) {
|
|
10
10
|
container.parentNode.removeChild(container);
|
|
11
11
|
}
|
|
12
12
|
}
|
|
13
13
|
|
|
14
|
-
|
|
14
|
+
render(element, container);
|
|
15
15
|
return unmount;
|
|
16
16
|
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { ReactElement } from 'react';
|
|
2
|
+
import type { Root } from 'react-dom/client';
|
|
3
|
+
declare const MARK = "__antd_mobile_root__";
|
|
4
|
+
declare type ContainerType = (Element | DocumentFragment) & {
|
|
5
|
+
[MARK]?: Root;
|
|
6
|
+
};
|
|
7
|
+
export declare function render(node: ReactElement, container: ContainerType): void;
|
|
8
|
+
export declare function unmount(container: ContainerType): boolean | Promise<void>;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
import { __awaiter } from "tslib";
|
|
2
|
+
import * as ReactDOM from 'react-dom'; // Let compiler not to search module usage
|
|
3
|
+
|
|
4
|
+
const fullClone = Object.assign({}, ReactDOM);
|
|
5
|
+
const {
|
|
6
|
+
version,
|
|
7
|
+
render: reactRender,
|
|
8
|
+
unmountComponentAtNode
|
|
9
|
+
} = fullClone;
|
|
10
|
+
let createRoot;
|
|
11
|
+
|
|
12
|
+
try {
|
|
13
|
+
const mainVersion = Number((version || '').split('.')[0]);
|
|
14
|
+
|
|
15
|
+
if (mainVersion >= 18 && fullClone.createRoot) {
|
|
16
|
+
// eslint-disable-next-line @typescript-eslint/no-var-requires
|
|
17
|
+
createRoot = fullClone.createRoot;
|
|
18
|
+
}
|
|
19
|
+
} catch (e) {// Do nothing;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
function toggleWarning(skip) {
|
|
23
|
+
const {
|
|
24
|
+
__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED
|
|
25
|
+
} = fullClone;
|
|
26
|
+
|
|
27
|
+
if (__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED && typeof __SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED === 'object') {
|
|
28
|
+
__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.usingClientEntryPoint = skip;
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
const MARK = '__antd_mobile_root__';
|
|
33
|
+
|
|
34
|
+
function legacyRender(node, container) {
|
|
35
|
+
reactRender(node, container);
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
function concurrentRender(node, container) {
|
|
39
|
+
toggleWarning(true);
|
|
40
|
+
const root = container[MARK] || createRoot(container);
|
|
41
|
+
toggleWarning(false);
|
|
42
|
+
root.render(node);
|
|
43
|
+
container[MARK] = root;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
export function render(node, container) {
|
|
47
|
+
if (createRoot) {
|
|
48
|
+
concurrentRender(node, container);
|
|
49
|
+
return;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
legacyRender(node, container);
|
|
53
|
+
} // ========================== Unmount =========================
|
|
54
|
+
|
|
55
|
+
function legacyUnmount(container) {
|
|
56
|
+
return unmountComponentAtNode(container);
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
function concurrentUnmount(container) {
|
|
60
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
61
|
+
// Delay to unmount to avoid React 18 sync warning
|
|
62
|
+
return Promise.resolve().then(() => {
|
|
63
|
+
var _a;
|
|
64
|
+
|
|
65
|
+
(_a = container[MARK]) === null || _a === void 0 ? void 0 : _a.unmount();
|
|
66
|
+
delete container[MARK];
|
|
67
|
+
});
|
|
68
|
+
});
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
export function unmount(container) {
|
|
72
|
+
if (createRoot) {
|
|
73
|
+
return concurrentUnmount(container);
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
return legacyUnmount(container);
|
|
77
|
+
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const useDragAndPinch: <Config extends import("@use-gesture/react").UserGestureConfig = import("@use-gesture/react").UserGestureConfig>(_handlers: Partial<import("@use-gesture/react").NativeHandlers<import("@use-gesture/react").EventTypes> & import("@use-gesture/react").UserHandlers<import("@use-gesture/react").EventTypes>>, _config?:
|
|
1
|
+
export declare const useDragAndPinch: <Config extends import("@use-gesture/react").UserGestureConfig = import("@use-gesture/react").UserGestureConfig>(_handlers: Partial<import("@use-gesture/react").NativeHandlers<import("@use-gesture/react").EventTypes> & import("@use-gesture/react").UserHandlers<import("@use-gesture/react").EventTypes>>, _config?: Config | undefined) => Config["target"] extends object ? void : (...args: any[]) => import("@use-gesture/react").ReactDOMAttributes;
|
|
@@ -4,5 +4,5 @@ declare type Options<T> = {
|
|
|
4
4
|
defaultValue: T;
|
|
5
5
|
onChange?: (v: T) => void;
|
|
6
6
|
};
|
|
7
|
-
export declare function usePropsValue<T>(options: Options<T>): readonly [T, (
|
|
7
|
+
export declare function usePropsValue<T>(options: Options<T>): readonly [T, (v: SetStateAction<T>) => void];
|
|
8
8
|
export {};
|
package/package.json
CHANGED
|
@@ -1,28 +1,28 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "antd-mobile",
|
|
3
|
-
"version": "5.
|
|
3
|
+
"version": "5.12.1",
|
|
4
4
|
"dependencies": {
|
|
5
|
-
"@floating-ui/dom": "^0.4.
|
|
6
|
-
"@react-spring/web": "^9.4.
|
|
5
|
+
"@floating-ui/dom": "^0.4.5",
|
|
6
|
+
"@react-spring/web": "^9.4.5",
|
|
7
7
|
"@types/big.js": "^6.1.3",
|
|
8
8
|
"@types/react-is": "^17.0.3",
|
|
9
9
|
"@types/react-virtualized": "^9.21.21",
|
|
10
10
|
"@types/resize-observer-browser": "^0.1.7",
|
|
11
|
-
"@use-gesture/react": "^10.2.
|
|
12
|
-
"ahooks": "^3.
|
|
11
|
+
"@use-gesture/react": "^10.2.12",
|
|
12
|
+
"ahooks": "^3.3.10",
|
|
13
13
|
"antd-mobile-icons": "^0.2.2",
|
|
14
14
|
"antd-mobile-v5-count": "^1.0.1",
|
|
15
15
|
"big.js": "^6.1.1",
|
|
16
16
|
"classnames": "^2.3.1",
|
|
17
|
-
"dayjs": "^1.11.
|
|
17
|
+
"dayjs": "^1.11.2",
|
|
18
18
|
"lodash": "^4.17.21",
|
|
19
|
-
"rc-field-form": "^1.26.
|
|
19
|
+
"rc-field-form": "^1.26.4",
|
|
20
20
|
"react-is": "^17.0.2",
|
|
21
21
|
"staged-components": "^1.1.2",
|
|
22
22
|
"tslib": "^2.3.1"
|
|
23
23
|
},
|
|
24
24
|
"peerDependencies": {
|
|
25
|
-
"react": "^16.8.0 || ^17.0.0"
|
|
25
|
+
"react": "^16.8.0 || ^17.0.0 || ^18.0.0"
|
|
26
26
|
},
|
|
27
27
|
"main": "./cjs/index.js",
|
|
28
28
|
"module": "./es/index.js",
|