@rc-component/util 1.10.0 → 1.11.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/es/Dom/focus.js +37 -8
- package/es/index.d.ts +25 -4
- package/es/index.js +24 -5
- package/lib/Dom/focus.js +36 -7
- package/lib/index.d.ts +25 -4
- package/lib/index.js +208 -3
- package/package.json +1 -1
package/es/Dom/focus.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { useEffect } from 'react';
|
|
1
|
+
import { useEffect, useRef, useState } from 'react';
|
|
2
2
|
import isVisible from "./isVisible";
|
|
3
3
|
import useId from "../hooks/useId";
|
|
4
4
|
function focusable(node, includePositive = false) {
|
|
@@ -173,6 +173,30 @@ export function lockFocus(element, id) {
|
|
|
173
173
|
};
|
|
174
174
|
}
|
|
175
175
|
|
|
176
|
+
/**
|
|
177
|
+
* Retry an effect until it reports ready.
|
|
178
|
+
* When `ready` is `false`, it will schedule one more effect cycle and call `func` again
|
|
179
|
+
* with the next `retryTimes`.
|
|
180
|
+
*/
|
|
181
|
+
|
|
182
|
+
function useRetryEffect(func, deps) {
|
|
183
|
+
/* eslint-disable react-hooks/exhaustive-deps */
|
|
184
|
+
const retryTimesRef = useRef(0);
|
|
185
|
+
const [retryMark, setRetryMark] = useState(0);
|
|
186
|
+
useEffect(() => {
|
|
187
|
+
retryTimesRef.current = 0;
|
|
188
|
+
}, deps);
|
|
189
|
+
useEffect(() => {
|
|
190
|
+
const [clearFn, ready] = func(retryTimesRef.current);
|
|
191
|
+
if (!ready) {
|
|
192
|
+
retryTimesRef.current += 1;
|
|
193
|
+
setRetryMark(count => count + 1);
|
|
194
|
+
}
|
|
195
|
+
return clearFn;
|
|
196
|
+
}, [...deps, retryMark]);
|
|
197
|
+
/* eslint-enable react-hooks/exhaustive-deps */
|
|
198
|
+
}
|
|
199
|
+
|
|
176
200
|
/**
|
|
177
201
|
* Lock focus within an element.
|
|
178
202
|
* When locked, focus will be restricted to focusable elements within the specified element.
|
|
@@ -181,14 +205,19 @@ export function lockFocus(element, id) {
|
|
|
181
205
|
*/
|
|
182
206
|
export function useLockFocus(lock, getElement) {
|
|
183
207
|
const id = useId();
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
208
|
+
const getElementRef = useRef(getElement);
|
|
209
|
+
getElementRef.current = getElement;
|
|
210
|
+
const lockEffect = retryTimes => {
|
|
211
|
+
if (!lock) {
|
|
212
|
+
return [undefined, true];
|
|
213
|
+
}
|
|
214
|
+
const element = getElementRef.current();
|
|
215
|
+
if (element) {
|
|
216
|
+
return [lockFocus(element, id), true];
|
|
190
217
|
}
|
|
191
|
-
|
|
218
|
+
return [undefined, retryTimes >= 1];
|
|
219
|
+
};
|
|
220
|
+
useRetryEffect(lockEffect, [id, lock]);
|
|
192
221
|
const ignoreElement = ele => {
|
|
193
222
|
if (ele) {
|
|
194
223
|
// Set the ignored element using stable ID
|
package/es/index.d.ts
CHANGED
|
@@ -1,10 +1,31 @@
|
|
|
1
1
|
export { default as useEvent } from './hooks/useEvent';
|
|
2
2
|
export { default as useMergedState } from './hooks/useMergedState';
|
|
3
3
|
export { default as useControlledState } from './hooks/useControlledState';
|
|
4
|
-
export {
|
|
5
|
-
export { default as
|
|
6
|
-
export { default as
|
|
7
|
-
export { default as
|
|
4
|
+
export { default as useId, getId } from './hooks/useId';
|
|
5
|
+
export { default as useLayoutEffect, useLayoutUpdateEffect, } from './hooks/useLayoutEffect';
|
|
6
|
+
export { default as useMemo } from './hooks/useMemo';
|
|
7
|
+
export { default as useState } from './hooks/useState';
|
|
8
|
+
export { default as useSyncState } from './hooks/useSyncState';
|
|
9
|
+
export { composeRef, fillRef, getNodeRef, supportNodeRef, supportRef, useComposeRef, } from './ref';
|
|
10
|
+
export { default as canUseDom } from './Dom/canUseDom';
|
|
11
|
+
export { default as contains } from './Dom/contains';
|
|
12
|
+
export { injectCSS, removeCSS, updateCSS } from './Dom/dynamicCSS';
|
|
13
|
+
export { getDOM, isDOM } from './Dom/findDOMNode';
|
|
14
|
+
export { getFocusNodeList, lockFocus, triggerFocus, useLockFocus, } from './Dom/focus';
|
|
15
|
+
export type { InputFocusOptions } from './Dom/focus';
|
|
16
|
+
export { default as isVisible } from './Dom/isVisible';
|
|
17
|
+
export { getShadowRoot } from './Dom/shadow';
|
|
18
|
+
export { default as KeyCode } from './KeyCode';
|
|
19
|
+
export { default as getScrollBarSize, getTargetScrollBarSize, } from './getScrollBarSize';
|
|
20
|
+
export { default as isEqual } from './isEqual';
|
|
21
|
+
export { default as isMobile } from './isMobile';
|
|
8
22
|
export { default as omit } from './omit';
|
|
23
|
+
export { default as pickAttrs } from './pickAttrs';
|
|
24
|
+
export { default as proxyObject } from './proxyObject';
|
|
25
|
+
export { default as raf } from './raf';
|
|
9
26
|
export { default as toArray } from './Children/toArray';
|
|
10
27
|
export { default as mergeProps } from './mergeProps';
|
|
28
|
+
export { default as get } from './utils/get';
|
|
29
|
+
export { default as set, merge, mergeWith } from './utils/set';
|
|
30
|
+
export { default as warning, noteOnce } from './warning';
|
|
31
|
+
export type { GetContainer } from './PortalWrapper';
|
package/es/index.js
CHANGED
|
@@ -1,10 +1,29 @@
|
|
|
1
1
|
export { default as useEvent } from "./hooks/useEvent";
|
|
2
2
|
export { default as useMergedState } from "./hooks/useMergedState";
|
|
3
3
|
export { default as useControlledState } from "./hooks/useControlledState";
|
|
4
|
-
export {
|
|
5
|
-
export { default as
|
|
6
|
-
export { default as
|
|
7
|
-
export { default as
|
|
4
|
+
export { default as useId, getId } from "./hooks/useId";
|
|
5
|
+
export { default as useLayoutEffect, useLayoutUpdateEffect } from "./hooks/useLayoutEffect";
|
|
6
|
+
export { default as useMemo } from "./hooks/useMemo";
|
|
7
|
+
export { default as useState } from "./hooks/useState";
|
|
8
|
+
export { default as useSyncState } from "./hooks/useSyncState";
|
|
9
|
+
export { composeRef, fillRef, getNodeRef, supportNodeRef, supportRef, useComposeRef } from "./ref";
|
|
10
|
+
export { default as canUseDom } from "./Dom/canUseDom";
|
|
11
|
+
export { default as contains } from "./Dom/contains";
|
|
12
|
+
export { injectCSS, removeCSS, updateCSS } from "./Dom/dynamicCSS";
|
|
13
|
+
export { getDOM, isDOM } from "./Dom/findDOMNode";
|
|
14
|
+
export { getFocusNodeList, lockFocus, triggerFocus, useLockFocus } from "./Dom/focus";
|
|
15
|
+
export { default as isVisible } from "./Dom/isVisible";
|
|
16
|
+
export { getShadowRoot } from "./Dom/shadow";
|
|
17
|
+
export { default as KeyCode } from "./KeyCode";
|
|
18
|
+
export { default as getScrollBarSize, getTargetScrollBarSize } from "./getScrollBarSize";
|
|
19
|
+
export { default as isEqual } from "./isEqual";
|
|
20
|
+
export { default as isMobile } from "./isMobile";
|
|
8
21
|
export { default as omit } from "./omit";
|
|
22
|
+
export { default as pickAttrs } from "./pickAttrs";
|
|
23
|
+
export { default as proxyObject } from "./proxyObject";
|
|
24
|
+
export { default as raf } from "./raf";
|
|
9
25
|
export { default as toArray } from "./Children/toArray";
|
|
10
|
-
export { default as mergeProps } from "./mergeProps";
|
|
26
|
+
export { default as mergeProps } from "./mergeProps";
|
|
27
|
+
export { default as get } from "./utils/get";
|
|
28
|
+
export { default as set, merge, mergeWith } from "./utils/set";
|
|
29
|
+
export { default as warning, noteOnce } from "./warning";
|
package/lib/Dom/focus.js
CHANGED
|
@@ -183,6 +183,30 @@ function lockFocus(element, id) {
|
|
|
183
183
|
};
|
|
184
184
|
}
|
|
185
185
|
|
|
186
|
+
/**
|
|
187
|
+
* Retry an effect until it reports ready.
|
|
188
|
+
* When `ready` is `false`, it will schedule one more effect cycle and call `func` again
|
|
189
|
+
* with the next `retryTimes`.
|
|
190
|
+
*/
|
|
191
|
+
|
|
192
|
+
function useRetryEffect(func, deps) {
|
|
193
|
+
/* eslint-disable react-hooks/exhaustive-deps */
|
|
194
|
+
const retryTimesRef = (0, _react.useRef)(0);
|
|
195
|
+
const [retryMark, setRetryMark] = (0, _react.useState)(0);
|
|
196
|
+
(0, _react.useEffect)(() => {
|
|
197
|
+
retryTimesRef.current = 0;
|
|
198
|
+
}, deps);
|
|
199
|
+
(0, _react.useEffect)(() => {
|
|
200
|
+
const [clearFn, ready] = func(retryTimesRef.current);
|
|
201
|
+
if (!ready) {
|
|
202
|
+
retryTimesRef.current += 1;
|
|
203
|
+
setRetryMark(count => count + 1);
|
|
204
|
+
}
|
|
205
|
+
return clearFn;
|
|
206
|
+
}, [...deps, retryMark]);
|
|
207
|
+
/* eslint-enable react-hooks/exhaustive-deps */
|
|
208
|
+
}
|
|
209
|
+
|
|
186
210
|
/**
|
|
187
211
|
* Lock focus within an element.
|
|
188
212
|
* When locked, focus will be restricted to focusable elements within the specified element.
|
|
@@ -191,14 +215,19 @@ function lockFocus(element, id) {
|
|
|
191
215
|
*/
|
|
192
216
|
function useLockFocus(lock, getElement) {
|
|
193
217
|
const id = (0, _useId.default)();
|
|
194
|
-
(0, _react.
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
218
|
+
const getElementRef = (0, _react.useRef)(getElement);
|
|
219
|
+
getElementRef.current = getElement;
|
|
220
|
+
const lockEffect = retryTimes => {
|
|
221
|
+
if (!lock) {
|
|
222
|
+
return [undefined, true];
|
|
223
|
+
}
|
|
224
|
+
const element = getElementRef.current();
|
|
225
|
+
if (element) {
|
|
226
|
+
return [lockFocus(element, id), true];
|
|
200
227
|
}
|
|
201
|
-
|
|
228
|
+
return [undefined, retryTimes >= 1];
|
|
229
|
+
};
|
|
230
|
+
useRetryEffect(lockEffect, [id, lock]);
|
|
202
231
|
const ignoreElement = ele => {
|
|
203
232
|
if (ele) {
|
|
204
233
|
// Set the ignored element using stable ID
|
package/lib/index.d.ts
CHANGED
|
@@ -1,10 +1,31 @@
|
|
|
1
1
|
export { default as useEvent } from './hooks/useEvent';
|
|
2
2
|
export { default as useMergedState } from './hooks/useMergedState';
|
|
3
3
|
export { default as useControlledState } from './hooks/useControlledState';
|
|
4
|
-
export {
|
|
5
|
-
export { default as
|
|
6
|
-
export { default as
|
|
7
|
-
export { default as
|
|
4
|
+
export { default as useId, getId } from './hooks/useId';
|
|
5
|
+
export { default as useLayoutEffect, useLayoutUpdateEffect, } from './hooks/useLayoutEffect';
|
|
6
|
+
export { default as useMemo } from './hooks/useMemo';
|
|
7
|
+
export { default as useState } from './hooks/useState';
|
|
8
|
+
export { default as useSyncState } from './hooks/useSyncState';
|
|
9
|
+
export { composeRef, fillRef, getNodeRef, supportNodeRef, supportRef, useComposeRef, } from './ref';
|
|
10
|
+
export { default as canUseDom } from './Dom/canUseDom';
|
|
11
|
+
export { default as contains } from './Dom/contains';
|
|
12
|
+
export { injectCSS, removeCSS, updateCSS } from './Dom/dynamicCSS';
|
|
13
|
+
export { getDOM, isDOM } from './Dom/findDOMNode';
|
|
14
|
+
export { getFocusNodeList, lockFocus, triggerFocus, useLockFocus, } from './Dom/focus';
|
|
15
|
+
export type { InputFocusOptions } from './Dom/focus';
|
|
16
|
+
export { default as isVisible } from './Dom/isVisible';
|
|
17
|
+
export { getShadowRoot } from './Dom/shadow';
|
|
18
|
+
export { default as KeyCode } from './KeyCode';
|
|
19
|
+
export { default as getScrollBarSize, getTargetScrollBarSize, } from './getScrollBarSize';
|
|
20
|
+
export { default as isEqual } from './isEqual';
|
|
21
|
+
export { default as isMobile } from './isMobile';
|
|
8
22
|
export { default as omit } from './omit';
|
|
23
|
+
export { default as pickAttrs } from './pickAttrs';
|
|
24
|
+
export { default as proxyObject } from './proxyObject';
|
|
25
|
+
export { default as raf } from './raf';
|
|
9
26
|
export { default as toArray } from './Children/toArray';
|
|
10
27
|
export { default as mergeProps } from './mergeProps';
|
|
28
|
+
export { default as get } from './utils/get';
|
|
29
|
+
export { default as set, merge, mergeWith } from './utils/set';
|
|
30
|
+
export { default as warning, noteOnce } from './warning';
|
|
31
|
+
export type { GetContainer } from './PortalWrapper';
|
package/lib/index.js
CHANGED
|
@@ -3,12 +3,120 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
+
Object.defineProperty(exports, "KeyCode", {
|
|
7
|
+
enumerable: true,
|
|
8
|
+
get: function () {
|
|
9
|
+
return _KeyCode.default;
|
|
10
|
+
}
|
|
11
|
+
});
|
|
12
|
+
Object.defineProperty(exports, "canUseDom", {
|
|
13
|
+
enumerable: true,
|
|
14
|
+
get: function () {
|
|
15
|
+
return _canUseDom.default;
|
|
16
|
+
}
|
|
17
|
+
});
|
|
18
|
+
Object.defineProperty(exports, "composeRef", {
|
|
19
|
+
enumerable: true,
|
|
20
|
+
get: function () {
|
|
21
|
+
return _ref.composeRef;
|
|
22
|
+
}
|
|
23
|
+
});
|
|
24
|
+
Object.defineProperty(exports, "contains", {
|
|
25
|
+
enumerable: true,
|
|
26
|
+
get: function () {
|
|
27
|
+
return _contains.default;
|
|
28
|
+
}
|
|
29
|
+
});
|
|
30
|
+
Object.defineProperty(exports, "fillRef", {
|
|
31
|
+
enumerable: true,
|
|
32
|
+
get: function () {
|
|
33
|
+
return _ref.fillRef;
|
|
34
|
+
}
|
|
35
|
+
});
|
|
6
36
|
Object.defineProperty(exports, "get", {
|
|
7
37
|
enumerable: true,
|
|
8
38
|
get: function () {
|
|
9
39
|
return _get.default;
|
|
10
40
|
}
|
|
11
41
|
});
|
|
42
|
+
Object.defineProperty(exports, "getDOM", {
|
|
43
|
+
enumerable: true,
|
|
44
|
+
get: function () {
|
|
45
|
+
return _findDOMNode.getDOM;
|
|
46
|
+
}
|
|
47
|
+
});
|
|
48
|
+
Object.defineProperty(exports, "getFocusNodeList", {
|
|
49
|
+
enumerable: true,
|
|
50
|
+
get: function () {
|
|
51
|
+
return _focus.getFocusNodeList;
|
|
52
|
+
}
|
|
53
|
+
});
|
|
54
|
+
Object.defineProperty(exports, "getId", {
|
|
55
|
+
enumerable: true,
|
|
56
|
+
get: function () {
|
|
57
|
+
return _useId.getId;
|
|
58
|
+
}
|
|
59
|
+
});
|
|
60
|
+
Object.defineProperty(exports, "getNodeRef", {
|
|
61
|
+
enumerable: true,
|
|
62
|
+
get: function () {
|
|
63
|
+
return _ref.getNodeRef;
|
|
64
|
+
}
|
|
65
|
+
});
|
|
66
|
+
Object.defineProperty(exports, "getScrollBarSize", {
|
|
67
|
+
enumerable: true,
|
|
68
|
+
get: function () {
|
|
69
|
+
return _getScrollBarSize.default;
|
|
70
|
+
}
|
|
71
|
+
});
|
|
72
|
+
Object.defineProperty(exports, "getShadowRoot", {
|
|
73
|
+
enumerable: true,
|
|
74
|
+
get: function () {
|
|
75
|
+
return _shadow.getShadowRoot;
|
|
76
|
+
}
|
|
77
|
+
});
|
|
78
|
+
Object.defineProperty(exports, "getTargetScrollBarSize", {
|
|
79
|
+
enumerable: true,
|
|
80
|
+
get: function () {
|
|
81
|
+
return _getScrollBarSize.getTargetScrollBarSize;
|
|
82
|
+
}
|
|
83
|
+
});
|
|
84
|
+
Object.defineProperty(exports, "injectCSS", {
|
|
85
|
+
enumerable: true,
|
|
86
|
+
get: function () {
|
|
87
|
+
return _dynamicCSS.injectCSS;
|
|
88
|
+
}
|
|
89
|
+
});
|
|
90
|
+
Object.defineProperty(exports, "isDOM", {
|
|
91
|
+
enumerable: true,
|
|
92
|
+
get: function () {
|
|
93
|
+
return _findDOMNode.isDOM;
|
|
94
|
+
}
|
|
95
|
+
});
|
|
96
|
+
Object.defineProperty(exports, "isEqual", {
|
|
97
|
+
enumerable: true,
|
|
98
|
+
get: function () {
|
|
99
|
+
return _isEqual.default;
|
|
100
|
+
}
|
|
101
|
+
});
|
|
102
|
+
Object.defineProperty(exports, "isMobile", {
|
|
103
|
+
enumerable: true,
|
|
104
|
+
get: function () {
|
|
105
|
+
return _isMobile.default;
|
|
106
|
+
}
|
|
107
|
+
});
|
|
108
|
+
Object.defineProperty(exports, "isVisible", {
|
|
109
|
+
enumerable: true,
|
|
110
|
+
get: function () {
|
|
111
|
+
return _isVisible.default;
|
|
112
|
+
}
|
|
113
|
+
});
|
|
114
|
+
Object.defineProperty(exports, "lockFocus", {
|
|
115
|
+
enumerable: true,
|
|
116
|
+
get: function () {
|
|
117
|
+
return _focus.lockFocus;
|
|
118
|
+
}
|
|
119
|
+
});
|
|
12
120
|
Object.defineProperty(exports, "merge", {
|
|
13
121
|
enumerable: true,
|
|
14
122
|
get: function () {
|
|
@@ -39,6 +147,30 @@ Object.defineProperty(exports, "omit", {
|
|
|
39
147
|
return _omit.default;
|
|
40
148
|
}
|
|
41
149
|
});
|
|
150
|
+
Object.defineProperty(exports, "pickAttrs", {
|
|
151
|
+
enumerable: true,
|
|
152
|
+
get: function () {
|
|
153
|
+
return _pickAttrs.default;
|
|
154
|
+
}
|
|
155
|
+
});
|
|
156
|
+
Object.defineProperty(exports, "proxyObject", {
|
|
157
|
+
enumerable: true,
|
|
158
|
+
get: function () {
|
|
159
|
+
return _proxyObject.default;
|
|
160
|
+
}
|
|
161
|
+
});
|
|
162
|
+
Object.defineProperty(exports, "raf", {
|
|
163
|
+
enumerable: true,
|
|
164
|
+
get: function () {
|
|
165
|
+
return _raf.default;
|
|
166
|
+
}
|
|
167
|
+
});
|
|
168
|
+
Object.defineProperty(exports, "removeCSS", {
|
|
169
|
+
enumerable: true,
|
|
170
|
+
get: function () {
|
|
171
|
+
return _dynamicCSS.removeCSS;
|
|
172
|
+
}
|
|
173
|
+
});
|
|
42
174
|
Object.defineProperty(exports, "set", {
|
|
43
175
|
enumerable: true,
|
|
44
176
|
get: function () {
|
|
@@ -63,6 +195,18 @@ Object.defineProperty(exports, "toArray", {
|
|
|
63
195
|
return _toArray.default;
|
|
64
196
|
}
|
|
65
197
|
});
|
|
198
|
+
Object.defineProperty(exports, "triggerFocus", {
|
|
199
|
+
enumerable: true,
|
|
200
|
+
get: function () {
|
|
201
|
+
return _focus.triggerFocus;
|
|
202
|
+
}
|
|
203
|
+
});
|
|
204
|
+
Object.defineProperty(exports, "updateCSS", {
|
|
205
|
+
enumerable: true,
|
|
206
|
+
get: function () {
|
|
207
|
+
return _dynamicCSS.updateCSS;
|
|
208
|
+
}
|
|
209
|
+
});
|
|
66
210
|
Object.defineProperty(exports, "useComposeRef", {
|
|
67
211
|
enumerable: true,
|
|
68
212
|
get: function () {
|
|
@@ -81,12 +225,54 @@ Object.defineProperty(exports, "useEvent", {
|
|
|
81
225
|
return _useEvent.default;
|
|
82
226
|
}
|
|
83
227
|
});
|
|
228
|
+
Object.defineProperty(exports, "useId", {
|
|
229
|
+
enumerable: true,
|
|
230
|
+
get: function () {
|
|
231
|
+
return _useId.default;
|
|
232
|
+
}
|
|
233
|
+
});
|
|
234
|
+
Object.defineProperty(exports, "useLayoutEffect", {
|
|
235
|
+
enumerable: true,
|
|
236
|
+
get: function () {
|
|
237
|
+
return _useLayoutEffect.default;
|
|
238
|
+
}
|
|
239
|
+
});
|
|
240
|
+
Object.defineProperty(exports, "useLayoutUpdateEffect", {
|
|
241
|
+
enumerable: true,
|
|
242
|
+
get: function () {
|
|
243
|
+
return _useLayoutEffect.useLayoutUpdateEffect;
|
|
244
|
+
}
|
|
245
|
+
});
|
|
246
|
+
Object.defineProperty(exports, "useLockFocus", {
|
|
247
|
+
enumerable: true,
|
|
248
|
+
get: function () {
|
|
249
|
+
return _focus.useLockFocus;
|
|
250
|
+
}
|
|
251
|
+
});
|
|
252
|
+
Object.defineProperty(exports, "useMemo", {
|
|
253
|
+
enumerable: true,
|
|
254
|
+
get: function () {
|
|
255
|
+
return _useMemo.default;
|
|
256
|
+
}
|
|
257
|
+
});
|
|
84
258
|
Object.defineProperty(exports, "useMergedState", {
|
|
85
259
|
enumerable: true,
|
|
86
260
|
get: function () {
|
|
87
261
|
return _useMergedState.default;
|
|
88
262
|
}
|
|
89
263
|
});
|
|
264
|
+
Object.defineProperty(exports, "useState", {
|
|
265
|
+
enumerable: true,
|
|
266
|
+
get: function () {
|
|
267
|
+
return _useState.default;
|
|
268
|
+
}
|
|
269
|
+
});
|
|
270
|
+
Object.defineProperty(exports, "useSyncState", {
|
|
271
|
+
enumerable: true,
|
|
272
|
+
get: function () {
|
|
273
|
+
return _useSyncState.default;
|
|
274
|
+
}
|
|
275
|
+
});
|
|
90
276
|
Object.defineProperty(exports, "warning", {
|
|
91
277
|
enumerable: true,
|
|
92
278
|
get: function () {
|
|
@@ -96,13 +282,32 @@ Object.defineProperty(exports, "warning", {
|
|
|
96
282
|
var _useEvent = _interopRequireDefault(require("./hooks/useEvent"));
|
|
97
283
|
var _useMergedState = _interopRequireDefault(require("./hooks/useMergedState"));
|
|
98
284
|
var _useControlledState = _interopRequireDefault(require("./hooks/useControlledState"));
|
|
285
|
+
var _useId = _interopRequireWildcard(require("./hooks/useId"));
|
|
286
|
+
var _useLayoutEffect = _interopRequireWildcard(require("./hooks/useLayoutEffect"));
|
|
287
|
+
var _useMemo = _interopRequireDefault(require("./hooks/useMemo"));
|
|
288
|
+
var _useState = _interopRequireDefault(require("./hooks/useState"));
|
|
289
|
+
var _useSyncState = _interopRequireDefault(require("./hooks/useSyncState"));
|
|
99
290
|
var _ref = require("./ref");
|
|
100
|
-
var
|
|
101
|
-
var
|
|
102
|
-
var
|
|
291
|
+
var _canUseDom = _interopRequireDefault(require("./Dom/canUseDom"));
|
|
292
|
+
var _contains = _interopRequireDefault(require("./Dom/contains"));
|
|
293
|
+
var _dynamicCSS = require("./Dom/dynamicCSS");
|
|
294
|
+
var _findDOMNode = require("./Dom/findDOMNode");
|
|
295
|
+
var _focus = require("./Dom/focus");
|
|
296
|
+
var _isVisible = _interopRequireDefault(require("./Dom/isVisible"));
|
|
297
|
+
var _shadow = require("./Dom/shadow");
|
|
298
|
+
var _KeyCode = _interopRequireDefault(require("./KeyCode"));
|
|
299
|
+
var _getScrollBarSize = _interopRequireWildcard(require("./getScrollBarSize"));
|
|
300
|
+
var _isEqual = _interopRequireDefault(require("./isEqual"));
|
|
301
|
+
var _isMobile = _interopRequireDefault(require("./isMobile"));
|
|
103
302
|
var _omit = _interopRequireDefault(require("./omit"));
|
|
303
|
+
var _pickAttrs = _interopRequireDefault(require("./pickAttrs"));
|
|
304
|
+
var _proxyObject = _interopRequireDefault(require("./proxyObject"));
|
|
305
|
+
var _raf = _interopRequireDefault(require("./raf"));
|
|
104
306
|
var _toArray = _interopRequireDefault(require("./Children/toArray"));
|
|
105
307
|
var _mergeProps = _interopRequireDefault(require("./mergeProps"));
|
|
308
|
+
var _get = _interopRequireDefault(require("./utils/get"));
|
|
309
|
+
var _set = _interopRequireWildcard(require("./utils/set"));
|
|
310
|
+
var _warning = _interopRequireWildcard(require("./warning"));
|
|
106
311
|
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
|
|
107
312
|
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
108
313
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|