@egov3/system-design 1.2.48 → 1.2.50
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/dist/cjs/components/Accordion/index.d.ts +3 -3
- package/dist/cjs/components/InputField/index.d.ts +1 -1
- package/dist/cjs/components/Modal/index.d.ts +2 -2
- package/dist/cjs/components/Typography/index.d.ts +1 -1
- package/dist/cjs/index.js +1707 -2688
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/components/Accordion/index.d.ts +3 -3
- package/dist/esm/components/InputField/index.d.ts +1 -1
- package/dist/esm/components/Modal/index.d.ts +2 -2
- package/dist/esm/components/Typography/index.d.ts +1 -1
- package/dist/esm/index.d.ts +2 -2
- package/dist/esm/index.js +1700 -2677
- package/dist/esm/index.js.map +1 -1
- package/package.json +6 -5
package/dist/esm/index.js
CHANGED
|
@@ -1,2780 +1,1799 @@
|
|
|
1
|
-
import typography from '~styles/typography.module.css';
|
|
2
|
-
|
|
3
1
|
var react = {exports: {}};
|
|
4
2
|
|
|
5
|
-
var
|
|
6
|
-
|
|
7
|
-
/**
|
|
8
|
-
* @license React
|
|
9
|
-
* react.production.min.js
|
|
10
|
-
*
|
|
11
|
-
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
12
|
-
*
|
|
13
|
-
* This source code is licensed under the MIT license found in the
|
|
14
|
-
* LICENSE file in the root directory of this source tree.
|
|
15
|
-
*/
|
|
16
|
-
var l=Symbol.for("react.element"),n=Symbol.for("react.portal"),p=Symbol.for("react.fragment"),q=Symbol.for("react.strict_mode"),r=Symbol.for("react.profiler"),t=Symbol.for("react.provider"),u=Symbol.for("react.context"),v=Symbol.for("react.forward_ref"),w=Symbol.for("react.suspense"),x=Symbol.for("react.memo"),y=Symbol.for("react.lazy"),z=Symbol.iterator;function A(a){if(null===a||"object"!==typeof a)return null;a=z&&a[z]||a["@@iterator"];return "function"===typeof a?a:null}
|
|
17
|
-
var B={isMounted:function(){return !1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},C=Object.assign,D={};function E(a,b,e){this.props=a;this.context=b;this.refs=D;this.updater=e||B;}E.prototype.isReactComponent={};
|
|
18
|
-
E.prototype.setState=function(a,b){if("object"!==typeof a&&"function"!==typeof a&&null!=a)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,a,b,"setState");};E.prototype.forceUpdate=function(a){this.updater.enqueueForceUpdate(this,a,"forceUpdate");};function F(){}F.prototype=E.prototype;function G(a,b,e){this.props=a;this.context=b;this.refs=D;this.updater=e||B;}var H=G.prototype=new F;
|
|
19
|
-
H.constructor=G;C(H,E.prototype);H.isPureReactComponent=!0;var I=Array.isArray,J=Object.prototype.hasOwnProperty,K={current:null},L={key:!0,ref:!0,__self:!0,__source:!0};
|
|
20
|
-
function M(a,b,e){var d,c={},k=null,h=null;if(null!=b)for(d in void 0!==b.ref&&(h=b.ref),void 0!==b.key&&(k=""+b.key),b)J.call(b,d)&&!L.hasOwnProperty(d)&&(c[d]=b[d]);var g=arguments.length-2;if(1===g)c.children=e;else if(1<g){for(var f=Array(g),m=0;m<g;m++)f[m]=arguments[m+2];c.children=f;}if(a&&a.defaultProps)for(d in g=a.defaultProps,g)void 0===c[d]&&(c[d]=g[d]);return {$$typeof:l,type:a,key:k,ref:h,props:c,_owner:K.current}}
|
|
21
|
-
function N(a,b){return {$$typeof:l,type:a.type,key:b,ref:a.ref,props:a.props,_owner:a._owner}}function O(a){return "object"===typeof a&&null!==a&&a.$$typeof===l}function escape(a){var b={"=":"=0",":":"=2"};return "$"+a.replace(/[=:]/g,function(a){return b[a]})}var P=/\/+/g;function Q(a,b){return "object"===typeof a&&null!==a&&null!=a.key?escape(""+a.key):b.toString(36)}
|
|
22
|
-
function R(a,b,e,d,c){var k=typeof a;if("undefined"===k||"boolean"===k)a=null;var h=!1;if(null===a)h=!0;else switch(k){case "string":case "number":h=!0;break;case "object":switch(a.$$typeof){case l:case n:h=!0;}}if(h)return h=a,c=c(h),a=""===d?"."+Q(h,0):d,I(c)?(e="",null!=a&&(e=a.replace(P,"$&/")+"/"),R(c,b,e,"",function(a){return a})):null!=c&&(O(c)&&(c=N(c,e+(!c.key||h&&h.key===c.key?"":(""+c.key).replace(P,"$&/")+"/")+a)),b.push(c)),1;h=0;d=""===d?".":d+":";if(I(a))for(var g=0;g<a.length;g++){k=
|
|
23
|
-
a[g];var f=d+Q(k,g);h+=R(k,b,e,f,c);}else if(f=A(a),"function"===typeof f)for(a=f.call(a),g=0;!(k=a.next()).done;)k=k.value,f=d+Q(k,g++),h+=R(k,b,e,f,c);else if("object"===k)throw b=String(a),Error("Objects are not valid as a React child (found: "+("[object Object]"===b?"object with keys {"+Object.keys(a).join(", ")+"}":b)+"). If you meant to render a collection of children, use an array instead.");return h}
|
|
24
|
-
function S(a,b,e){if(null==a)return a;var d=[],c=0;R(a,d,"","",function(a){return b.call(e,a,c++)});return d}function T(a){if(-1===a._status){var b=a._result;b=b();b.then(function(b){if(0===a._status||-1===a._status)a._status=1,a._result=b;},function(b){if(0===a._status||-1===a._status)a._status=2,a._result=b;});-1===a._status&&(a._status=0,a._result=b);}if(1===a._status)return a._result.default;throw a._result;}
|
|
25
|
-
var U={current:null},V={transition:null},W={ReactCurrentDispatcher:U,ReactCurrentBatchConfig:V,ReactCurrentOwner:K};function X(){throw Error("act(...) is not supported in production builds of React.");}
|
|
26
|
-
react_production_min.Children={map:S,forEach:function(a,b,e){S(a,function(){b.apply(this,arguments);},e);},count:function(a){var b=0;S(a,function(){b++;});return b},toArray:function(a){return S(a,function(a){return a})||[]},only:function(a){if(!O(a))throw Error("React.Children.only expected to receive a single React element child.");return a}};react_production_min.Component=E;react_production_min.Fragment=p;react_production_min.Profiler=r;react_production_min.PureComponent=G;react_production_min.StrictMode=q;react_production_min.Suspense=w;
|
|
27
|
-
react_production_min.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=W;react_production_min.act=X;
|
|
28
|
-
react_production_min.cloneElement=function(a,b,e){if(null===a||void 0===a)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+a+".");var d=C({},a.props),c=a.key,k=a.ref,h=a._owner;if(null!=b){void 0!==b.ref&&(k=b.ref,h=K.current);void 0!==b.key&&(c=""+b.key);if(a.type&&a.type.defaultProps)var g=a.type.defaultProps;for(f in b)J.call(b,f)&&!L.hasOwnProperty(f)&&(d[f]=void 0===b[f]&&void 0!==g?g[f]:b[f]);}var f=arguments.length-2;if(1===f)d.children=e;else if(1<f){g=Array(f);
|
|
29
|
-
for(var m=0;m<f;m++)g[m]=arguments[m+2];d.children=g;}return {$$typeof:l,type:a.type,key:c,ref:k,props:d,_owner:h}};react_production_min.createContext=function(a){a={$$typeof:u,_currentValue:a,_currentValue2:a,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null};a.Provider={$$typeof:t,_context:a};return a.Consumer=a};react_production_min.createElement=M;react_production_min.createFactory=function(a){var b=M.bind(null,a);b.type=a;return b};react_production_min.createRef=function(){return {current:null}};
|
|
30
|
-
react_production_min.forwardRef=function(a){return {$$typeof:v,render:a}};react_production_min.isValidElement=O;react_production_min.lazy=function(a){return {$$typeof:y,_payload:{_status:-1,_result:a},_init:T}};react_production_min.memo=function(a,b){return {$$typeof:x,type:a,compare:void 0===b?null:b}};react_production_min.startTransition=function(a){var b=V.transition;V.transition={};try{a();}finally{V.transition=b;}};react_production_min.unstable_act=X;react_production_min.useCallback=function(a,b){return U.current.useCallback(a,b)};react_production_min.useContext=function(a){return U.current.useContext(a)};
|
|
31
|
-
react_production_min.useDebugValue=function(){};react_production_min.useDeferredValue=function(a){return U.current.useDeferredValue(a)};react_production_min.useEffect=function(a,b){return U.current.useEffect(a,b)};react_production_min.useId=function(){return U.current.useId()};react_production_min.useImperativeHandle=function(a,b,e){return U.current.useImperativeHandle(a,b,e)};react_production_min.useInsertionEffect=function(a,b){return U.current.useInsertionEffect(a,b)};react_production_min.useLayoutEffect=function(a,b){return U.current.useLayoutEffect(a,b)};
|
|
32
|
-
react_production_min.useMemo=function(a,b){return U.current.useMemo(a,b)};react_production_min.useReducer=function(a,b,e){return U.current.useReducer(a,b,e)};react_production_min.useRef=function(a){return U.current.useRef(a)};react_production_min.useState=function(a){return U.current.useState(a)};react_production_min.useSyncExternalStore=function(a,b,e){return U.current.useSyncExternalStore(a,b,e)};react_production_min.useTransition=function(){return U.current.useTransition()};react_production_min.version="18.3.1";
|
|
33
|
-
|
|
34
|
-
var react_development = {exports: {}};
|
|
3
|
+
var react_production = {};
|
|
35
4
|
|
|
36
5
|
/**
|
|
37
6
|
* @license React
|
|
38
|
-
* react.
|
|
7
|
+
* react.production.js
|
|
39
8
|
*
|
|
40
|
-
* Copyright (c)
|
|
9
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
41
10
|
*
|
|
42
11
|
* This source code is licensed under the MIT license found in the
|
|
43
12
|
* LICENSE file in the root directory of this source tree.
|
|
44
13
|
*/
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
(
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(new Error());
|
|
58
|
-
}
|
|
59
|
-
var ReactVersion = '18.3.1';
|
|
60
|
-
|
|
61
|
-
// ATTENTION
|
|
62
|
-
// When adding new symbols to this file,
|
|
63
|
-
// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'
|
|
64
|
-
// The Symbol used to tag the ReactElement-like types.
|
|
65
|
-
var REACT_ELEMENT_TYPE = Symbol.for('react.element');
|
|
66
|
-
var REACT_PORTAL_TYPE = Symbol.for('react.portal');
|
|
67
|
-
var REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');
|
|
68
|
-
var REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');
|
|
69
|
-
var REACT_PROFILER_TYPE = Symbol.for('react.profiler');
|
|
70
|
-
var REACT_PROVIDER_TYPE = Symbol.for('react.provider');
|
|
71
|
-
var REACT_CONTEXT_TYPE = Symbol.for('react.context');
|
|
72
|
-
var REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');
|
|
73
|
-
var REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');
|
|
74
|
-
var REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');
|
|
75
|
-
var REACT_MEMO_TYPE = Symbol.for('react.memo');
|
|
76
|
-
var REACT_LAZY_TYPE = Symbol.for('react.lazy');
|
|
77
|
-
var REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');
|
|
78
|
-
var MAYBE_ITERATOR_SYMBOL = Symbol.iterator;
|
|
79
|
-
var FAUX_ITERATOR_SYMBOL = '@@iterator';
|
|
14
|
+
var REACT_ELEMENT_TYPE = Symbol.for("react.transitional.element"),
|
|
15
|
+
REACT_PORTAL_TYPE = Symbol.for("react.portal"),
|
|
16
|
+
REACT_FRAGMENT_TYPE = Symbol.for("react.fragment"),
|
|
17
|
+
REACT_STRICT_MODE_TYPE = Symbol.for("react.strict_mode"),
|
|
18
|
+
REACT_PROFILER_TYPE = Symbol.for("react.profiler"),
|
|
19
|
+
REACT_CONSUMER_TYPE = Symbol.for("react.consumer"),
|
|
20
|
+
REACT_CONTEXT_TYPE = Symbol.for("react.context"),
|
|
21
|
+
REACT_FORWARD_REF_TYPE = Symbol.for("react.forward_ref"),
|
|
22
|
+
REACT_SUSPENSE_TYPE = Symbol.for("react.suspense"),
|
|
23
|
+
REACT_MEMO_TYPE = Symbol.for("react.memo"),
|
|
24
|
+
REACT_LAZY_TYPE = Symbol.for("react.lazy"),
|
|
25
|
+
MAYBE_ITERATOR_SYMBOL = Symbol.iterator;
|
|
80
26
|
function getIteratorFn(maybeIterable) {
|
|
81
|
-
if (
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
if (typeof maybeIterator === 'function') {
|
|
88
|
-
return maybeIterator;
|
|
89
|
-
}
|
|
90
|
-
|
|
91
|
-
return null;
|
|
92
|
-
}
|
|
93
|
-
|
|
94
|
-
/**
|
|
95
|
-
* Keeps track of the current dispatcher.
|
|
96
|
-
*/
|
|
97
|
-
var ReactCurrentDispatcher = {
|
|
98
|
-
/**
|
|
99
|
-
* @internal
|
|
100
|
-
* @type {ReactComponent}
|
|
101
|
-
*/
|
|
102
|
-
current: null
|
|
103
|
-
};
|
|
104
|
-
|
|
105
|
-
/**
|
|
106
|
-
* Keeps track of the current batch's configuration such as how long an update
|
|
107
|
-
* should suspend for if it needs to.
|
|
108
|
-
*/
|
|
109
|
-
var ReactCurrentBatchConfig = {
|
|
110
|
-
transition: null
|
|
111
|
-
};
|
|
112
|
-
|
|
113
|
-
var ReactCurrentActQueue = {
|
|
114
|
-
current: null,
|
|
115
|
-
// Used to reproduce behavior of `batchedUpdates` in legacy mode.
|
|
116
|
-
isBatchingLegacy: false,
|
|
117
|
-
didScheduleLegacyUpdate: false
|
|
118
|
-
};
|
|
119
|
-
|
|
120
|
-
/**
|
|
121
|
-
* Keeps track of the current owner.
|
|
122
|
-
*
|
|
123
|
-
* The current owner is the component who should own any components that are
|
|
124
|
-
* currently being constructed.
|
|
125
|
-
*/
|
|
126
|
-
var ReactCurrentOwner = {
|
|
127
|
-
/**
|
|
128
|
-
* @internal
|
|
129
|
-
* @type {ReactComponent}
|
|
130
|
-
*/
|
|
131
|
-
current: null
|
|
132
|
-
};
|
|
133
|
-
|
|
134
|
-
var ReactDebugCurrentFrame = {};
|
|
135
|
-
var currentExtraStackFrame = null;
|
|
136
|
-
function setExtraStackFrame(stack) {
|
|
137
|
-
{
|
|
138
|
-
currentExtraStackFrame = stack;
|
|
139
|
-
}
|
|
140
|
-
}
|
|
141
|
-
|
|
142
|
-
{
|
|
143
|
-
ReactDebugCurrentFrame.setExtraStackFrame = function (stack) {
|
|
144
|
-
{
|
|
145
|
-
currentExtraStackFrame = stack;
|
|
146
|
-
}
|
|
147
|
-
}; // Stack implementation injected by the current renderer.
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
ReactDebugCurrentFrame.getCurrentStack = null;
|
|
151
|
-
|
|
152
|
-
ReactDebugCurrentFrame.getStackAddendum = function () {
|
|
153
|
-
var stack = ''; // Add an extra top frame while an element is being validated
|
|
154
|
-
|
|
155
|
-
if (currentExtraStackFrame) {
|
|
156
|
-
stack += currentExtraStackFrame;
|
|
157
|
-
} // Delegate to the injected renderer-specific implementation
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
var impl = ReactDebugCurrentFrame.getCurrentStack;
|
|
161
|
-
|
|
162
|
-
if (impl) {
|
|
163
|
-
stack += impl() || '';
|
|
164
|
-
}
|
|
165
|
-
|
|
166
|
-
return stack;
|
|
167
|
-
};
|
|
168
|
-
}
|
|
169
|
-
|
|
170
|
-
// -----------------------------------------------------------------------------
|
|
171
|
-
|
|
172
|
-
var enableScopeAPI = false; // Experimental Create Event Handle API.
|
|
173
|
-
var enableCacheElement = false;
|
|
174
|
-
var enableTransitionTracing = false; // No known bugs, but needs performance testing
|
|
175
|
-
|
|
176
|
-
var enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber
|
|
177
|
-
// stuff. Intended to enable React core members to more easily debug scheduling
|
|
178
|
-
// issues in DEV builds.
|
|
179
|
-
|
|
180
|
-
var enableDebugTracing = false; // Track which Fiber(s) schedule render work.
|
|
181
|
-
|
|
182
|
-
var ReactSharedInternals = {
|
|
183
|
-
ReactCurrentDispatcher: ReactCurrentDispatcher,
|
|
184
|
-
ReactCurrentBatchConfig: ReactCurrentBatchConfig,
|
|
185
|
-
ReactCurrentOwner: ReactCurrentOwner
|
|
186
|
-
};
|
|
187
|
-
|
|
188
|
-
{
|
|
189
|
-
ReactSharedInternals.ReactDebugCurrentFrame = ReactDebugCurrentFrame;
|
|
190
|
-
ReactSharedInternals.ReactCurrentActQueue = ReactCurrentActQueue;
|
|
191
|
-
}
|
|
192
|
-
|
|
193
|
-
// by calls to these methods by a Babel plugin.
|
|
194
|
-
//
|
|
195
|
-
// In PROD (or in packages without access to React internals),
|
|
196
|
-
// they are left as they are instead.
|
|
197
|
-
|
|
198
|
-
function warn(format) {
|
|
199
|
-
{
|
|
200
|
-
{
|
|
201
|
-
for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
|
|
202
|
-
args[_key - 1] = arguments[_key];
|
|
203
|
-
}
|
|
204
|
-
|
|
205
|
-
printWarning('warn', format, args);
|
|
206
|
-
}
|
|
207
|
-
}
|
|
208
|
-
}
|
|
209
|
-
function error(format) {
|
|
210
|
-
{
|
|
211
|
-
{
|
|
212
|
-
for (var _len2 = arguments.length, args = new Array(_len2 > 1 ? _len2 - 1 : 0), _key2 = 1; _key2 < _len2; _key2++) {
|
|
213
|
-
args[_key2 - 1] = arguments[_key2];
|
|
214
|
-
}
|
|
215
|
-
|
|
216
|
-
printWarning('error', format, args);
|
|
217
|
-
}
|
|
218
|
-
}
|
|
219
|
-
}
|
|
220
|
-
|
|
221
|
-
function printWarning(level, format, args) {
|
|
222
|
-
// When changing this logic, you might want to also
|
|
223
|
-
// update consoleWithStackDev.www.js as well.
|
|
224
|
-
{
|
|
225
|
-
var ReactDebugCurrentFrame = ReactSharedInternals.ReactDebugCurrentFrame;
|
|
226
|
-
var stack = ReactDebugCurrentFrame.getStackAddendum();
|
|
227
|
-
|
|
228
|
-
if (stack !== '') {
|
|
229
|
-
format += '%s';
|
|
230
|
-
args = args.concat([stack]);
|
|
231
|
-
} // eslint-disable-next-line react-internal/safe-string-coercion
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
var argsWithFormat = args.map(function (item) {
|
|
235
|
-
return String(item);
|
|
236
|
-
}); // Careful: RN currently depends on this prefix
|
|
237
|
-
|
|
238
|
-
argsWithFormat.unshift('Warning: ' + format); // We intentionally don't use spread (or .apply) directly because it
|
|
239
|
-
// breaks IE9: https://github.com/facebook/react/issues/13610
|
|
240
|
-
// eslint-disable-next-line react-internal/no-production-logging
|
|
241
|
-
|
|
242
|
-
Function.prototype.apply.call(console[level], console, argsWithFormat);
|
|
243
|
-
}
|
|
244
|
-
}
|
|
245
|
-
|
|
246
|
-
var didWarnStateUpdateForUnmountedComponent = {};
|
|
247
|
-
|
|
248
|
-
function warnNoop(publicInstance, callerName) {
|
|
249
|
-
{
|
|
250
|
-
var _constructor = publicInstance.constructor;
|
|
251
|
-
var componentName = _constructor && (_constructor.displayName || _constructor.name) || 'ReactClass';
|
|
252
|
-
var warningKey = componentName + "." + callerName;
|
|
253
|
-
|
|
254
|
-
if (didWarnStateUpdateForUnmountedComponent[warningKey]) {
|
|
255
|
-
return;
|
|
256
|
-
}
|
|
257
|
-
|
|
258
|
-
error("Can't call %s on a component that is not yet mounted. " + 'This is a no-op, but it might indicate a bug in your application. ' + 'Instead, assign to `this.state` directly or define a `state = {};` ' + 'class property with the desired state in the %s component.', callerName, componentName);
|
|
259
|
-
|
|
260
|
-
didWarnStateUpdateForUnmountedComponent[warningKey] = true;
|
|
261
|
-
}
|
|
27
|
+
if (null === maybeIterable || "object" !== typeof maybeIterable) return null;
|
|
28
|
+
maybeIterable =
|
|
29
|
+
(MAYBE_ITERATOR_SYMBOL && maybeIterable[MAYBE_ITERATOR_SYMBOL]) ||
|
|
30
|
+
maybeIterable["@@iterator"];
|
|
31
|
+
return "function" === typeof maybeIterable ? maybeIterable : null;
|
|
262
32
|
}
|
|
263
|
-
/**
|
|
264
|
-
* This is the abstract API for an update queue.
|
|
265
|
-
*/
|
|
266
|
-
|
|
267
|
-
|
|
268
33
|
var ReactNoopUpdateQueue = {
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
*/
|
|
276
|
-
isMounted: function (publicInstance) {
|
|
277
|
-
return false;
|
|
278
|
-
},
|
|
279
|
-
|
|
280
|
-
/**
|
|
281
|
-
* Forces an update. This should only be invoked when it is known with
|
|
282
|
-
* certainty that we are **not** in a DOM transaction.
|
|
283
|
-
*
|
|
284
|
-
* You may want to call this when you know that some deeper aspect of the
|
|
285
|
-
* component's state has changed but `setState` was not called.
|
|
286
|
-
*
|
|
287
|
-
* This will not invoke `shouldComponentUpdate`, but it will invoke
|
|
288
|
-
* `componentWillUpdate` and `componentDidUpdate`.
|
|
289
|
-
*
|
|
290
|
-
* @param {ReactClass} publicInstance The instance that should rerender.
|
|
291
|
-
* @param {?function} callback Called after component is updated.
|
|
292
|
-
* @param {?string} callerName name of the calling function in the public API.
|
|
293
|
-
* @internal
|
|
294
|
-
*/
|
|
295
|
-
enqueueForceUpdate: function (publicInstance, callback, callerName) {
|
|
296
|
-
warnNoop(publicInstance, 'forceUpdate');
|
|
297
|
-
},
|
|
298
|
-
|
|
299
|
-
/**
|
|
300
|
-
* Replaces all of the state. Always use this or `setState` to mutate state.
|
|
301
|
-
* You should treat `this.state` as immutable.
|
|
302
|
-
*
|
|
303
|
-
* There is no guarantee that `this.state` will be immediately updated, so
|
|
304
|
-
* accessing `this.state` after calling this method may return the old value.
|
|
305
|
-
*
|
|
306
|
-
* @param {ReactClass} publicInstance The instance that should rerender.
|
|
307
|
-
* @param {object} completeState Next state.
|
|
308
|
-
* @param {?function} callback Called after component is updated.
|
|
309
|
-
* @param {?string} callerName name of the calling function in the public API.
|
|
310
|
-
* @internal
|
|
311
|
-
*/
|
|
312
|
-
enqueueReplaceState: function (publicInstance, completeState, callback, callerName) {
|
|
313
|
-
warnNoop(publicInstance, 'replaceState');
|
|
34
|
+
isMounted: function () {
|
|
35
|
+
return !1;
|
|
36
|
+
},
|
|
37
|
+
enqueueForceUpdate: function () {},
|
|
38
|
+
enqueueReplaceState: function () {},
|
|
39
|
+
enqueueSetState: function () {}
|
|
314
40
|
},
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
* Sets a subset of the state. This only exists because _pendingState is
|
|
318
|
-
* internal. This provides a merging strategy that is not available to deep
|
|
319
|
-
* properties which is confusing. TODO: Expose pendingState or don't use it
|
|
320
|
-
* during the merge.
|
|
321
|
-
*
|
|
322
|
-
* @param {ReactClass} publicInstance The instance that should rerender.
|
|
323
|
-
* @param {object} partialState Next partial state to be merged with state.
|
|
324
|
-
* @param {?function} callback Called after component is updated.
|
|
325
|
-
* @param {?string} Name of the calling function in the public API.
|
|
326
|
-
* @internal
|
|
327
|
-
*/
|
|
328
|
-
enqueueSetState: function (publicInstance, partialState, callback, callerName) {
|
|
329
|
-
warnNoop(publicInstance, 'setState');
|
|
330
|
-
}
|
|
331
|
-
};
|
|
332
|
-
|
|
333
|
-
var assign = Object.assign;
|
|
334
|
-
|
|
335
|
-
var emptyObject = {};
|
|
336
|
-
|
|
337
|
-
{
|
|
338
|
-
Object.freeze(emptyObject);
|
|
339
|
-
}
|
|
340
|
-
/**
|
|
341
|
-
* Base class helpers for the updating state of a component.
|
|
342
|
-
*/
|
|
343
|
-
|
|
344
|
-
|
|
41
|
+
assign = Object.assign,
|
|
42
|
+
emptyObject = {};
|
|
345
43
|
function Component(props, context, updater) {
|
|
346
44
|
this.props = props;
|
|
347
|
-
this.context = context;
|
|
348
|
-
|
|
349
|
-
this.refs = emptyObject; // We initialize the default updater but the real one gets injected by the
|
|
350
|
-
// renderer.
|
|
351
|
-
|
|
45
|
+
this.context = context;
|
|
46
|
+
this.refs = emptyObject;
|
|
352
47
|
this.updater = updater || ReactNoopUpdateQueue;
|
|
353
48
|
}
|
|
354
|
-
|
|
355
49
|
Component.prototype.isReactComponent = {};
|
|
356
|
-
/**
|
|
357
|
-
* Sets a subset of the state. Always use this to mutate
|
|
358
|
-
* state. You should treat `this.state` as immutable.
|
|
359
|
-
*
|
|
360
|
-
* There is no guarantee that `this.state` will be immediately updated, so
|
|
361
|
-
* accessing `this.state` after calling this method may return the old value.
|
|
362
|
-
*
|
|
363
|
-
* There is no guarantee that calls to `setState` will run synchronously,
|
|
364
|
-
* as they may eventually be batched together. You can provide an optional
|
|
365
|
-
* callback that will be executed when the call to setState is actually
|
|
366
|
-
* completed.
|
|
367
|
-
*
|
|
368
|
-
* When a function is provided to setState, it will be called at some point in
|
|
369
|
-
* the future (not synchronously). It will be called with the up to date
|
|
370
|
-
* component arguments (state, props, context). These values can be different
|
|
371
|
-
* from this.* because your function may be called after receiveProps but before
|
|
372
|
-
* shouldComponentUpdate, and this new state, props, and context will not yet be
|
|
373
|
-
* assigned to this.
|
|
374
|
-
*
|
|
375
|
-
* @param {object|function} partialState Next partial state or function to
|
|
376
|
-
* produce next partial state to be merged with current state.
|
|
377
|
-
* @param {?function} callback Called after state is updated.
|
|
378
|
-
* @final
|
|
379
|
-
* @protected
|
|
380
|
-
*/
|
|
381
|
-
|
|
382
50
|
Component.prototype.setState = function (partialState, callback) {
|
|
383
|
-
if (
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
51
|
+
if (
|
|
52
|
+
"object" !== typeof partialState &&
|
|
53
|
+
"function" !== typeof partialState &&
|
|
54
|
+
null != partialState
|
|
55
|
+
)
|
|
56
|
+
throw Error(
|
|
57
|
+
"takes an object of state variables to update or a function which returns an object of state variables."
|
|
58
|
+
);
|
|
59
|
+
this.updater.enqueueSetState(this, partialState, callback, "setState");
|
|
388
60
|
};
|
|
389
|
-
/**
|
|
390
|
-
* Forces an update. This should only be invoked when it is known with
|
|
391
|
-
* certainty that we are **not** in a DOM transaction.
|
|
392
|
-
*
|
|
393
|
-
* You may want to call this when you know that some deeper aspect of the
|
|
394
|
-
* component's state has changed but `setState` was not called.
|
|
395
|
-
*
|
|
396
|
-
* This will not invoke `shouldComponentUpdate`, but it will invoke
|
|
397
|
-
* `componentWillUpdate` and `componentDidUpdate`.
|
|
398
|
-
*
|
|
399
|
-
* @param {?function} callback Called after update is complete.
|
|
400
|
-
* @final
|
|
401
|
-
* @protected
|
|
402
|
-
*/
|
|
403
|
-
|
|
404
|
-
|
|
405
61
|
Component.prototype.forceUpdate = function (callback) {
|
|
406
|
-
this.updater.enqueueForceUpdate(this, callback,
|
|
62
|
+
this.updater.enqueueForceUpdate(this, callback, "forceUpdate");
|
|
407
63
|
};
|
|
408
|
-
/**
|
|
409
|
-
* Deprecated APIs. These APIs used to exist on classic React classes but since
|
|
410
|
-
* we would like to deprecate them, we're not going to move them over to this
|
|
411
|
-
* modern base class. Instead, we define a getter that warns if it's accessed.
|
|
412
|
-
*/
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
{
|
|
416
|
-
var deprecatedAPIs = {
|
|
417
|
-
isMounted: ['isMounted', 'Instead, make sure to clean up subscriptions and pending requests in ' + 'componentWillUnmount to prevent memory leaks.'],
|
|
418
|
-
replaceState: ['replaceState', 'Refactor your code to use setState instead (see ' + 'https://github.com/facebook/react/issues/3236).']
|
|
419
|
-
};
|
|
420
|
-
|
|
421
|
-
var defineDeprecationWarning = function (methodName, info) {
|
|
422
|
-
Object.defineProperty(Component.prototype, methodName, {
|
|
423
|
-
get: function () {
|
|
424
|
-
warn('%s(...) is deprecated in plain JavaScript React classes. %s', info[0], info[1]);
|
|
425
|
-
|
|
426
|
-
return undefined;
|
|
427
|
-
}
|
|
428
|
-
});
|
|
429
|
-
};
|
|
430
|
-
|
|
431
|
-
for (var fnName in deprecatedAPIs) {
|
|
432
|
-
if (deprecatedAPIs.hasOwnProperty(fnName)) {
|
|
433
|
-
defineDeprecationWarning(fnName, deprecatedAPIs[fnName]);
|
|
434
|
-
}
|
|
435
|
-
}
|
|
436
|
-
}
|
|
437
|
-
|
|
438
64
|
function ComponentDummy() {}
|
|
439
|
-
|
|
440
65
|
ComponentDummy.prototype = Component.prototype;
|
|
441
|
-
/**
|
|
442
|
-
* Convenience component with default shallow equality check for sCU.
|
|
443
|
-
*/
|
|
444
|
-
|
|
445
66
|
function PureComponent(props, context, updater) {
|
|
446
67
|
this.props = props;
|
|
447
|
-
this.context = context;
|
|
448
|
-
|
|
68
|
+
this.context = context;
|
|
449
69
|
this.refs = emptyObject;
|
|
450
70
|
this.updater = updater || ReactNoopUpdateQueue;
|
|
451
71
|
}
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
pureComponentPrototype.constructor = PureComponent; // Avoid an extra prototype jump for these methods.
|
|
455
|
-
|
|
72
|
+
var pureComponentPrototype = (PureComponent.prototype = new ComponentDummy());
|
|
73
|
+
pureComponentPrototype.constructor = PureComponent;
|
|
456
74
|
assign(pureComponentPrototype, Component.prototype);
|
|
457
|
-
pureComponentPrototype.isPureReactComponent =
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
75
|
+
pureComponentPrototype.isPureReactComponent = !0;
|
|
76
|
+
var isArrayImpl = Array.isArray,
|
|
77
|
+
ReactSharedInternals = { H: null, A: null, T: null, S: null, V: null },
|
|
78
|
+
hasOwnProperty = Object.prototype.hasOwnProperty;
|
|
79
|
+
function ReactElement(type, key, self, source, owner, props) {
|
|
80
|
+
self = props.ref;
|
|
81
|
+
return {
|
|
82
|
+
$$typeof: REACT_ELEMENT_TYPE,
|
|
83
|
+
type: type,
|
|
84
|
+
key: key,
|
|
85
|
+
ref: void 0 !== self ? self : null,
|
|
86
|
+
props: props
|
|
463
87
|
};
|
|
464
|
-
|
|
465
|
-
{
|
|
466
|
-
Object.seal(refObject);
|
|
467
|
-
}
|
|
468
|
-
|
|
469
|
-
return refObject;
|
|
470
88
|
}
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
89
|
+
function cloneAndReplaceKey(oldElement, newKey) {
|
|
90
|
+
return ReactElement(
|
|
91
|
+
oldElement.type,
|
|
92
|
+
newKey,
|
|
93
|
+
void 0,
|
|
94
|
+
void 0,
|
|
95
|
+
void 0,
|
|
96
|
+
oldElement.props
|
|
97
|
+
);
|
|
476
98
|
}
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
* easier-to-debug exception with a clear errors message message explaining the
|
|
484
|
-
* problem. (Instead of a confusing exception thrown inside the implementation
|
|
485
|
-
* of the `value` object).
|
|
486
|
-
*/
|
|
487
|
-
// $FlowFixMe only called in DEV, so void return is not possible.
|
|
488
|
-
function typeName(value) {
|
|
489
|
-
{
|
|
490
|
-
// toStringTag is needed for namespaced types like Temporal.Instant
|
|
491
|
-
var hasToStringTag = typeof Symbol === 'function' && Symbol.toStringTag;
|
|
492
|
-
var type = hasToStringTag && value[Symbol.toStringTag] || value.constructor.name || 'Object';
|
|
493
|
-
return type;
|
|
494
|
-
}
|
|
495
|
-
} // $FlowFixMe only called in DEV, so void return is not possible.
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
function willCoercionThrow(value) {
|
|
499
|
-
{
|
|
500
|
-
try {
|
|
501
|
-
testStringCoercion(value);
|
|
502
|
-
return false;
|
|
503
|
-
} catch (e) {
|
|
504
|
-
return true;
|
|
505
|
-
}
|
|
506
|
-
}
|
|
99
|
+
function isValidElement(object) {
|
|
100
|
+
return (
|
|
101
|
+
"object" === typeof object &&
|
|
102
|
+
null !== object &&
|
|
103
|
+
object.$$typeof === REACT_ELEMENT_TYPE
|
|
104
|
+
);
|
|
507
105
|
}
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
// and Temporal objects like `Temporal.Instant`. But any object that has a
|
|
517
|
-
// `valueOf` or `[Symbol.toPrimitive]` method that throws will also cause this
|
|
518
|
-
// exception. (Library authors do this to prevent users from using built-in
|
|
519
|
-
// numeric operators like `+` or comparison operators like `>=` because custom
|
|
520
|
-
// methods are needed to perform accurate arithmetic or comparison.)
|
|
521
|
-
//
|
|
522
|
-
// To fix the problem, coerce this object or symbol value to a string before
|
|
523
|
-
// passing it to React. The most reliable way is usually `String(value)`.
|
|
524
|
-
//
|
|
525
|
-
// To find which value is throwing, check the browser or debugger console.
|
|
526
|
-
// Before this exception was thrown, there should be `console.error` output
|
|
527
|
-
// that shows the type (Symbol, Temporal.PlainDate, etc.) that caused the
|
|
528
|
-
// problem and how that type was used: key, atrribute, input value prop, etc.
|
|
529
|
-
// In most cases, this console output also shows the component and its
|
|
530
|
-
// ancestor components where the exception happened.
|
|
531
|
-
//
|
|
532
|
-
// eslint-disable-next-line react-internal/safe-string-coercion
|
|
533
|
-
return '' + value;
|
|
106
|
+
function escape(key) {
|
|
107
|
+
var escaperLookup = { "=": "=0", ":": "=2" };
|
|
108
|
+
return (
|
|
109
|
+
"$" +
|
|
110
|
+
key.replace(/[=:]/g, function (match) {
|
|
111
|
+
return escaperLookup[match];
|
|
112
|
+
})
|
|
113
|
+
);
|
|
534
114
|
}
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
115
|
+
var userProvidedKeyEscapeRegex = /\/+/g;
|
|
116
|
+
function getElementKey(element, index) {
|
|
117
|
+
return "object" === typeof element && null !== element && null != element.key
|
|
118
|
+
? escape("" + element.key)
|
|
119
|
+
: index.toString(36);
|
|
120
|
+
}
|
|
121
|
+
function noop$1() {}
|
|
122
|
+
function resolveThenable(thenable) {
|
|
123
|
+
switch (thenable.status) {
|
|
124
|
+
case "fulfilled":
|
|
125
|
+
return thenable.value;
|
|
126
|
+
case "rejected":
|
|
127
|
+
throw thenable.reason;
|
|
128
|
+
default:
|
|
129
|
+
switch (
|
|
130
|
+
("string" === typeof thenable.status
|
|
131
|
+
? thenable.then(noop$1, noop$1)
|
|
132
|
+
: ((thenable.status = "pending"),
|
|
133
|
+
thenable.then(
|
|
134
|
+
function (fulfilledValue) {
|
|
135
|
+
"pending" === thenable.status &&
|
|
136
|
+
((thenable.status = "fulfilled"),
|
|
137
|
+
(thenable.value = fulfilledValue));
|
|
138
|
+
},
|
|
139
|
+
function (error) {
|
|
140
|
+
"pending" === thenable.status &&
|
|
141
|
+
((thenable.status = "rejected"), (thenable.reason = error));
|
|
142
|
+
}
|
|
143
|
+
)),
|
|
144
|
+
thenable.status)
|
|
145
|
+
) {
|
|
146
|
+
case "fulfilled":
|
|
147
|
+
return thenable.value;
|
|
148
|
+
case "rejected":
|
|
149
|
+
throw thenable.reason;
|
|
150
|
+
}
|
|
542
151
|
}
|
|
152
|
+
throw thenable;
|
|
543
153
|
}
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
if (
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
if (typeof type === 'function') {
|
|
575
|
-
return type.displayName || type.name || null;
|
|
576
|
-
}
|
|
577
|
-
|
|
578
|
-
if (typeof type === 'string') {
|
|
579
|
-
return type;
|
|
580
|
-
}
|
|
581
|
-
|
|
582
|
-
switch (type) {
|
|
583
|
-
case REACT_FRAGMENT_TYPE:
|
|
584
|
-
return 'Fragment';
|
|
585
|
-
|
|
586
|
-
case REACT_PORTAL_TYPE:
|
|
587
|
-
return 'Portal';
|
|
588
|
-
|
|
589
|
-
case REACT_PROFILER_TYPE:
|
|
590
|
-
return 'Profiler';
|
|
591
|
-
|
|
592
|
-
case REACT_STRICT_MODE_TYPE:
|
|
593
|
-
return 'StrictMode';
|
|
594
|
-
|
|
595
|
-
case REACT_SUSPENSE_TYPE:
|
|
596
|
-
return 'Suspense';
|
|
597
|
-
|
|
598
|
-
case REACT_SUSPENSE_LIST_TYPE:
|
|
599
|
-
return 'SuspenseList';
|
|
600
|
-
|
|
601
|
-
}
|
|
602
|
-
|
|
603
|
-
if (typeof type === 'object') {
|
|
604
|
-
switch (type.$$typeof) {
|
|
605
|
-
case REACT_CONTEXT_TYPE:
|
|
606
|
-
var context = type;
|
|
607
|
-
return getContextName(context) + '.Consumer';
|
|
608
|
-
|
|
609
|
-
case REACT_PROVIDER_TYPE:
|
|
610
|
-
var provider = type;
|
|
611
|
-
return getContextName(provider._context) + '.Provider';
|
|
612
|
-
|
|
613
|
-
case REACT_FORWARD_REF_TYPE:
|
|
614
|
-
return getWrappedName(type, type.render, 'ForwardRef');
|
|
615
|
-
|
|
616
|
-
case REACT_MEMO_TYPE:
|
|
617
|
-
var outerName = type.displayName || null;
|
|
618
|
-
|
|
619
|
-
if (outerName !== null) {
|
|
620
|
-
return outerName;
|
|
621
|
-
}
|
|
622
|
-
|
|
623
|
-
return getComponentNameFromType(type.type) || 'Memo';
|
|
624
|
-
|
|
625
|
-
case REACT_LAZY_TYPE:
|
|
626
|
-
{
|
|
627
|
-
var lazyComponent = type;
|
|
628
|
-
var payload = lazyComponent._payload;
|
|
629
|
-
var init = lazyComponent._init;
|
|
630
|
-
|
|
631
|
-
try {
|
|
632
|
-
return getComponentNameFromType(init(payload));
|
|
633
|
-
} catch (x) {
|
|
634
|
-
return null;
|
|
635
|
-
}
|
|
154
|
+
function mapIntoArray(children, array, escapedPrefix, nameSoFar, callback) {
|
|
155
|
+
var type = typeof children;
|
|
156
|
+
if ("undefined" === type || "boolean" === type) children = null;
|
|
157
|
+
var invokeCallback = !1;
|
|
158
|
+
if (null === children) invokeCallback = !0;
|
|
159
|
+
else
|
|
160
|
+
switch (type) {
|
|
161
|
+
case "bigint":
|
|
162
|
+
case "string":
|
|
163
|
+
case "number":
|
|
164
|
+
invokeCallback = !0;
|
|
165
|
+
break;
|
|
166
|
+
case "object":
|
|
167
|
+
switch (children.$$typeof) {
|
|
168
|
+
case REACT_ELEMENT_TYPE:
|
|
169
|
+
case REACT_PORTAL_TYPE:
|
|
170
|
+
invokeCallback = !0;
|
|
171
|
+
break;
|
|
172
|
+
case REACT_LAZY_TYPE:
|
|
173
|
+
return (
|
|
174
|
+
(invokeCallback = children._init),
|
|
175
|
+
mapIntoArray(
|
|
176
|
+
invokeCallback(children._payload),
|
|
177
|
+
array,
|
|
178
|
+
escapedPrefix,
|
|
179
|
+
nameSoFar,
|
|
180
|
+
callback
|
|
181
|
+
)
|
|
182
|
+
);
|
|
636
183
|
}
|
|
637
|
-
|
|
638
|
-
// eslint-disable-next-line no-fallthrough
|
|
639
184
|
}
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
185
|
+
if (invokeCallback)
|
|
186
|
+
return (
|
|
187
|
+
(callback = callback(children)),
|
|
188
|
+
(invokeCallback =
|
|
189
|
+
"" === nameSoFar ? "." + getElementKey(children, 0) : nameSoFar),
|
|
190
|
+
isArrayImpl(callback)
|
|
191
|
+
? ((escapedPrefix = ""),
|
|
192
|
+
null != invokeCallback &&
|
|
193
|
+
(escapedPrefix =
|
|
194
|
+
invokeCallback.replace(userProvidedKeyEscapeRegex, "$&/") + "/"),
|
|
195
|
+
mapIntoArray(callback, array, escapedPrefix, "", function (c) {
|
|
196
|
+
return c;
|
|
197
|
+
}))
|
|
198
|
+
: null != callback &&
|
|
199
|
+
(isValidElement(callback) &&
|
|
200
|
+
(callback = cloneAndReplaceKey(
|
|
201
|
+
callback,
|
|
202
|
+
escapedPrefix +
|
|
203
|
+
(null == callback.key ||
|
|
204
|
+
(children && children.key === callback.key)
|
|
205
|
+
? ""
|
|
206
|
+
: ("" + callback.key).replace(
|
|
207
|
+
userProvidedKeyEscapeRegex,
|
|
208
|
+
"$&/"
|
|
209
|
+
) + "/") +
|
|
210
|
+
invokeCallback
|
|
211
|
+
)),
|
|
212
|
+
array.push(callback)),
|
|
213
|
+
1
|
|
214
|
+
);
|
|
215
|
+
invokeCallback = 0;
|
|
216
|
+
var nextNamePrefix = "" === nameSoFar ? "." : nameSoFar + ":";
|
|
217
|
+
if (isArrayImpl(children))
|
|
218
|
+
for (var i = 0; i < children.length; i++)
|
|
219
|
+
(nameSoFar = children[i]),
|
|
220
|
+
(type = nextNamePrefix + getElementKey(nameSoFar, i)),
|
|
221
|
+
(invokeCallback += mapIntoArray(
|
|
222
|
+
nameSoFar,
|
|
223
|
+
array,
|
|
224
|
+
escapedPrefix,
|
|
225
|
+
type,
|
|
226
|
+
callback
|
|
227
|
+
));
|
|
228
|
+
else if (((i = getIteratorFn(children)), "function" === typeof i))
|
|
229
|
+
for (
|
|
230
|
+
children = i.call(children), i = 0;
|
|
231
|
+
!(nameSoFar = children.next()).done;
|
|
232
|
+
|
|
233
|
+
)
|
|
234
|
+
(nameSoFar = nameSoFar.value),
|
|
235
|
+
(type = nextNamePrefix + getElementKey(nameSoFar, i++)),
|
|
236
|
+
(invokeCallback += mapIntoArray(
|
|
237
|
+
nameSoFar,
|
|
238
|
+
array,
|
|
239
|
+
escapedPrefix,
|
|
240
|
+
type,
|
|
241
|
+
callback
|
|
242
|
+
));
|
|
243
|
+
else if ("object" === type) {
|
|
244
|
+
if ("function" === typeof children.then)
|
|
245
|
+
return mapIntoArray(
|
|
246
|
+
resolveThenable(children),
|
|
247
|
+
array,
|
|
248
|
+
escapedPrefix,
|
|
249
|
+
nameSoFar,
|
|
250
|
+
callback
|
|
251
|
+
);
|
|
252
|
+
array = String(children);
|
|
253
|
+
throw Error(
|
|
254
|
+
"Objects are not valid as a React child (found: " +
|
|
255
|
+
("[object Object]" === array
|
|
256
|
+
? "object with keys {" + Object.keys(children).join(", ") + "}"
|
|
257
|
+
: array) +
|
|
258
|
+
"). If you meant to render a collection of children, use an array instead."
|
|
259
|
+
);
|
|
260
|
+
}
|
|
261
|
+
return invokeCallback;
|
|
643
262
|
}
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
};
|
|
653
|
-
var specialPropKeyWarningShown, specialPropRefWarningShown, didWarnAboutStringRefs;
|
|
654
|
-
|
|
655
|
-
{
|
|
656
|
-
didWarnAboutStringRefs = {};
|
|
263
|
+
function mapChildren(children, func, context) {
|
|
264
|
+
if (null == children) return children;
|
|
265
|
+
var result = [],
|
|
266
|
+
count = 0;
|
|
267
|
+
mapIntoArray(children, result, "", "", function (child) {
|
|
268
|
+
return func.call(context, child, count++);
|
|
269
|
+
});
|
|
270
|
+
return result;
|
|
657
271
|
}
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
272
|
+
function lazyInitializer(payload) {
|
|
273
|
+
if (-1 === payload._status) {
|
|
274
|
+
var ctor = payload._result;
|
|
275
|
+
ctor = ctor();
|
|
276
|
+
ctor.then(
|
|
277
|
+
function (moduleObject) {
|
|
278
|
+
if (0 === payload._status || -1 === payload._status)
|
|
279
|
+
(payload._status = 1), (payload._result = moduleObject);
|
|
280
|
+
},
|
|
281
|
+
function (error) {
|
|
282
|
+
if (0 === payload._status || -1 === payload._status)
|
|
283
|
+
(payload._status = 2), (payload._result = error);
|
|
666
284
|
}
|
|
667
|
-
|
|
285
|
+
);
|
|
286
|
+
-1 === payload._status && ((payload._status = 0), (payload._result = ctor));
|
|
287
|
+
}
|
|
288
|
+
if (1 === payload._status) return payload._result.default;
|
|
289
|
+
throw payload._result;
|
|
290
|
+
}
|
|
291
|
+
var reportGlobalError =
|
|
292
|
+
"function" === typeof reportError
|
|
293
|
+
? reportError
|
|
294
|
+
: function (error) {
|
|
295
|
+
if (
|
|
296
|
+
"object" === typeof window &&
|
|
297
|
+
"function" === typeof window.ErrorEvent
|
|
298
|
+
) {
|
|
299
|
+
var event = new window.ErrorEvent("error", {
|
|
300
|
+
bubbles: !0,
|
|
301
|
+
cancelable: !0,
|
|
302
|
+
message:
|
|
303
|
+
"object" === typeof error &&
|
|
304
|
+
null !== error &&
|
|
305
|
+
"string" === typeof error.message
|
|
306
|
+
? String(error.message)
|
|
307
|
+
: String(error),
|
|
308
|
+
error: error
|
|
309
|
+
});
|
|
310
|
+
if (!window.dispatchEvent(event)) return;
|
|
311
|
+
} else if (
|
|
312
|
+
"object" === typeof process &&
|
|
313
|
+
"function" === typeof process.emit
|
|
314
|
+
) {
|
|
315
|
+
process.emit("uncaughtException", error);
|
|
316
|
+
return;
|
|
317
|
+
}
|
|
318
|
+
console.error(error);
|
|
319
|
+
};
|
|
320
|
+
function noop() {}
|
|
321
|
+
react_production.Children = {
|
|
322
|
+
map: mapChildren,
|
|
323
|
+
forEach: function (children, forEachFunc, forEachContext) {
|
|
324
|
+
mapChildren(
|
|
325
|
+
children,
|
|
326
|
+
function () {
|
|
327
|
+
forEachFunc.apply(this, arguments);
|
|
328
|
+
},
|
|
329
|
+
forEachContext
|
|
330
|
+
);
|
|
331
|
+
},
|
|
332
|
+
count: function (children) {
|
|
333
|
+
var n = 0;
|
|
334
|
+
mapChildren(children, function () {
|
|
335
|
+
n++;
|
|
336
|
+
});
|
|
337
|
+
return n;
|
|
338
|
+
},
|
|
339
|
+
toArray: function (children) {
|
|
340
|
+
return (
|
|
341
|
+
mapChildren(children, function (child) {
|
|
342
|
+
return child;
|
|
343
|
+
}) || []
|
|
344
|
+
);
|
|
345
|
+
},
|
|
346
|
+
only: function (children) {
|
|
347
|
+
if (!isValidElement(children))
|
|
348
|
+
throw Error(
|
|
349
|
+
"React.Children.only expected to receive a single React element child."
|
|
350
|
+
);
|
|
351
|
+
return children;
|
|
668
352
|
}
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
|
|
680
|
-
|
|
681
|
-
|
|
353
|
+
};
|
|
354
|
+
react_production.Component = Component;
|
|
355
|
+
react_production.Fragment = REACT_FRAGMENT_TYPE;
|
|
356
|
+
react_production.Profiler = REACT_PROFILER_TYPE;
|
|
357
|
+
react_production.PureComponent = PureComponent;
|
|
358
|
+
react_production.StrictMode = REACT_STRICT_MODE_TYPE;
|
|
359
|
+
react_production.Suspense = REACT_SUSPENSE_TYPE;
|
|
360
|
+
react_production.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE =
|
|
361
|
+
ReactSharedInternals;
|
|
362
|
+
react_production.__COMPILER_RUNTIME = {
|
|
363
|
+
__proto__: null,
|
|
364
|
+
c: function (size) {
|
|
365
|
+
return ReactSharedInternals.H.useMemoCache(size);
|
|
682
366
|
}
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
function defineKeyPropWarningGetter(props, displayName) {
|
|
688
|
-
var warnAboutAccessingKey = function () {
|
|
689
|
-
{
|
|
690
|
-
if (!specialPropKeyWarningShown) {
|
|
691
|
-
specialPropKeyWarningShown = true;
|
|
692
|
-
|
|
693
|
-
error('%s: `key` is not a prop. Trying to access it will result ' + 'in `undefined` being returned. If you need to access the same ' + 'value within the child component, you should pass it as a different ' + 'prop. (https://reactjs.org/link/special-props)', displayName);
|
|
694
|
-
}
|
|
695
|
-
}
|
|
696
|
-
};
|
|
697
|
-
|
|
698
|
-
warnAboutAccessingKey.isReactWarning = true;
|
|
699
|
-
Object.defineProperty(props, 'key', {
|
|
700
|
-
get: warnAboutAccessingKey,
|
|
701
|
-
configurable: true
|
|
702
|
-
});
|
|
703
|
-
}
|
|
704
|
-
|
|
705
|
-
function defineRefPropWarningGetter(props, displayName) {
|
|
706
|
-
var warnAboutAccessingRef = function () {
|
|
707
|
-
{
|
|
708
|
-
if (!specialPropRefWarningShown) {
|
|
709
|
-
specialPropRefWarningShown = true;
|
|
710
|
-
|
|
711
|
-
error('%s: `ref` is not a prop. Trying to access it will result ' + 'in `undefined` being returned. If you need to access the same ' + 'value within the child component, you should pass it as a different ' + 'prop. (https://reactjs.org/link/special-props)', displayName);
|
|
712
|
-
}
|
|
713
|
-
}
|
|
714
|
-
};
|
|
715
|
-
|
|
716
|
-
warnAboutAccessingRef.isReactWarning = true;
|
|
717
|
-
Object.defineProperty(props, 'ref', {
|
|
718
|
-
get: warnAboutAccessingRef,
|
|
719
|
-
configurable: true
|
|
720
|
-
});
|
|
721
|
-
}
|
|
722
|
-
|
|
723
|
-
function warnIfStringRefCannotBeAutoConverted(config) {
|
|
724
|
-
{
|
|
725
|
-
if (typeof config.ref === 'string' && ReactCurrentOwner.current && config.__self && ReactCurrentOwner.current.stateNode !== config.__self) {
|
|
726
|
-
var componentName = getComponentNameFromType(ReactCurrentOwner.current.type);
|
|
727
|
-
|
|
728
|
-
if (!didWarnAboutStringRefs[componentName]) {
|
|
729
|
-
error('Component "%s" contains the string ref "%s". ' + 'Support for string refs will be removed in a future major release. ' + 'This case cannot be automatically converted to an arrow function. ' + 'We ask you to manually fix this case by using useRef() or createRef() instead. ' + 'Learn more about using refs safely here: ' + 'https://reactjs.org/link/strict-mode-string-ref', componentName, config.ref);
|
|
730
|
-
|
|
731
|
-
didWarnAboutStringRefs[componentName] = true;
|
|
732
|
-
}
|
|
733
|
-
}
|
|
734
|
-
}
|
|
735
|
-
}
|
|
736
|
-
/**
|
|
737
|
-
* Factory method to create a new React element. This no longer adheres to
|
|
738
|
-
* the class pattern, so do not use new to call it. Also, instanceof check
|
|
739
|
-
* will not work. Instead test $$typeof field against Symbol.for('react.element') to check
|
|
740
|
-
* if something is a React Element.
|
|
741
|
-
*
|
|
742
|
-
* @param {*} type
|
|
743
|
-
* @param {*} props
|
|
744
|
-
* @param {*} key
|
|
745
|
-
* @param {string|object} ref
|
|
746
|
-
* @param {*} owner
|
|
747
|
-
* @param {*} self A *temporary* helper to detect places where `this` is
|
|
748
|
-
* different from the `owner` when React.createElement is called, so that we
|
|
749
|
-
* can warn. We want to get rid of owner and replace string `ref`s with arrow
|
|
750
|
-
* functions, and as long as `this` and owner are the same, there will be no
|
|
751
|
-
* change in behavior.
|
|
752
|
-
* @param {*} source An annotation object (added by a transpiler or otherwise)
|
|
753
|
-
* indicating filename, line number, and/or other information.
|
|
754
|
-
* @internal
|
|
755
|
-
*/
|
|
756
|
-
|
|
757
|
-
|
|
758
|
-
var ReactElement = function (type, key, ref, self, source, owner, props) {
|
|
759
|
-
var element = {
|
|
760
|
-
// This tag allows us to uniquely identify this as a React Element
|
|
761
|
-
$$typeof: REACT_ELEMENT_TYPE,
|
|
762
|
-
// Built-in properties that belong on the element
|
|
763
|
-
type: type,
|
|
764
|
-
key: key,
|
|
765
|
-
ref: ref,
|
|
766
|
-
props: props,
|
|
767
|
-
// Record the component responsible for creating this element.
|
|
768
|
-
_owner: owner
|
|
367
|
+
};
|
|
368
|
+
react_production.cache = function (fn) {
|
|
369
|
+
return function () {
|
|
370
|
+
return fn.apply(null, arguments);
|
|
769
371
|
};
|
|
770
|
-
|
|
771
|
-
{
|
|
772
|
-
// The validation flag is currently mutative. We put it on
|
|
773
|
-
// an external backing store so that we can freeze the whole object.
|
|
774
|
-
// This can be replaced with a WeakMap once they are implemented in
|
|
775
|
-
// commonly used development environments.
|
|
776
|
-
element._store = {}; // To make comparing ReactElements easier for testing purposes, we make
|
|
777
|
-
// the validation flag non-enumerable (where possible, which should
|
|
778
|
-
// include every environment we run tests in), so the test framework
|
|
779
|
-
// ignores it.
|
|
780
|
-
|
|
781
|
-
Object.defineProperty(element._store, 'validated', {
|
|
782
|
-
configurable: false,
|
|
783
|
-
enumerable: false,
|
|
784
|
-
writable: true,
|
|
785
|
-
value: false
|
|
786
|
-
}); // self and source are DEV only properties.
|
|
787
|
-
|
|
788
|
-
Object.defineProperty(element, '_self', {
|
|
789
|
-
configurable: false,
|
|
790
|
-
enumerable: false,
|
|
791
|
-
writable: false,
|
|
792
|
-
value: self
|
|
793
|
-
}); // Two elements created in two different places should be considered
|
|
794
|
-
// equal for testing purposes and therefore we hide it from enumeration.
|
|
795
|
-
|
|
796
|
-
Object.defineProperty(element, '_source', {
|
|
797
|
-
configurable: false,
|
|
798
|
-
enumerable: false,
|
|
799
|
-
writable: false,
|
|
800
|
-
value: source
|
|
801
|
-
});
|
|
802
|
-
|
|
803
|
-
if (Object.freeze) {
|
|
804
|
-
Object.freeze(element.props);
|
|
805
|
-
Object.freeze(element);
|
|
806
|
-
}
|
|
807
|
-
}
|
|
808
|
-
|
|
809
|
-
return element;
|
|
810
372
|
};
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
|
|
818
|
-
|
|
819
|
-
|
|
820
|
-
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
|
|
824
|
-
|
|
825
|
-
|
|
826
|
-
|
|
827
|
-
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
|
|
831
|
-
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
if (hasValidKey(config)) {
|
|
835
|
-
{
|
|
836
|
-
checkKeyStringCoercion(config.key);
|
|
837
|
-
}
|
|
838
|
-
|
|
839
|
-
key = '' + config.key;
|
|
840
|
-
}
|
|
841
|
-
|
|
842
|
-
self = config.__self === undefined ? null : config.__self;
|
|
843
|
-
source = config.__source === undefined ? null : config.__source; // Remaining properties are added to a new props object
|
|
844
|
-
|
|
845
|
-
for (propName in config) {
|
|
846
|
-
if (hasOwnProperty.call(config, propName) && !RESERVED_PROPS.hasOwnProperty(propName)) {
|
|
847
|
-
props[propName] = config[propName];
|
|
848
|
-
}
|
|
849
|
-
}
|
|
850
|
-
} // Children can be more than one argument, and those are transferred onto
|
|
851
|
-
// the newly allocated props object.
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
var childrenLength = arguments.length - 2;
|
|
855
|
-
|
|
856
|
-
if (childrenLength === 1) {
|
|
857
|
-
props.children = children;
|
|
858
|
-
} else if (childrenLength > 1) {
|
|
859
|
-
var childArray = Array(childrenLength);
|
|
860
|
-
|
|
861
|
-
for (var i = 0; i < childrenLength; i++) {
|
|
373
|
+
react_production.cloneElement = function (element, config, children) {
|
|
374
|
+
if (null === element || void 0 === element)
|
|
375
|
+
throw Error(
|
|
376
|
+
"The argument must be a React element, but you passed " + element + "."
|
|
377
|
+
);
|
|
378
|
+
var props = assign({}, element.props),
|
|
379
|
+
key = element.key,
|
|
380
|
+
owner = void 0;
|
|
381
|
+
if (null != config)
|
|
382
|
+
for (propName in (void 0 !== config.ref && (owner = void 0),
|
|
383
|
+
void 0 !== config.key && (key = "" + config.key),
|
|
384
|
+
config))
|
|
385
|
+
!hasOwnProperty.call(config, propName) ||
|
|
386
|
+
"key" === propName ||
|
|
387
|
+
"__self" === propName ||
|
|
388
|
+
"__source" === propName ||
|
|
389
|
+
("ref" === propName && void 0 === config.ref) ||
|
|
390
|
+
(props[propName] = config[propName]);
|
|
391
|
+
var propName = arguments.length - 2;
|
|
392
|
+
if (1 === propName) props.children = children;
|
|
393
|
+
else if (1 < propName) {
|
|
394
|
+
for (var childArray = Array(propName), i = 0; i < propName; i++)
|
|
862
395
|
childArray[i] = arguments[i + 2];
|
|
863
|
-
}
|
|
864
|
-
|
|
865
|
-
{
|
|
866
|
-
if (Object.freeze) {
|
|
867
|
-
Object.freeze(childArray);
|
|
868
|
-
}
|
|
869
|
-
}
|
|
870
|
-
|
|
871
|
-
props.children = childArray;
|
|
872
|
-
} // Resolve default props
|
|
873
|
-
|
|
874
|
-
|
|
875
|
-
if (type && type.defaultProps) {
|
|
876
|
-
var defaultProps = type.defaultProps;
|
|
877
|
-
|
|
878
|
-
for (propName in defaultProps) {
|
|
879
|
-
if (props[propName] === undefined) {
|
|
880
|
-
props[propName] = defaultProps[propName];
|
|
881
|
-
}
|
|
882
|
-
}
|
|
883
|
-
}
|
|
884
|
-
|
|
885
|
-
{
|
|
886
|
-
if (key || ref) {
|
|
887
|
-
var displayName = typeof type === 'function' ? type.displayName || type.name || 'Unknown' : type;
|
|
888
|
-
|
|
889
|
-
if (key) {
|
|
890
|
-
defineKeyPropWarningGetter(props, displayName);
|
|
891
|
-
}
|
|
892
|
-
|
|
893
|
-
if (ref) {
|
|
894
|
-
defineRefPropWarningGetter(props, displayName);
|
|
895
|
-
}
|
|
896
|
-
}
|
|
897
|
-
}
|
|
898
|
-
|
|
899
|
-
return ReactElement(type, key, ref, self, source, ReactCurrentOwner.current, props);
|
|
900
|
-
}
|
|
901
|
-
function cloneAndReplaceKey(oldElement, newKey) {
|
|
902
|
-
var newElement = ReactElement(oldElement.type, newKey, oldElement.ref, oldElement._self, oldElement._source, oldElement._owner, oldElement.props);
|
|
903
|
-
return newElement;
|
|
904
|
-
}
|
|
905
|
-
/**
|
|
906
|
-
* Clone and return a new ReactElement using element as the starting point.
|
|
907
|
-
* See https://reactjs.org/docs/react-api.html#cloneelement
|
|
908
|
-
*/
|
|
909
|
-
|
|
910
|
-
function cloneElement(element, config, children) {
|
|
911
|
-
if (element === null || element === undefined) {
|
|
912
|
-
throw new Error("React.cloneElement(...): The argument must be a React element, but you passed " + element + ".");
|
|
913
|
-
}
|
|
914
|
-
|
|
915
|
-
var propName; // Original props are copied
|
|
916
|
-
|
|
917
|
-
var props = assign({}, element.props); // Reserved names are extracted
|
|
918
|
-
|
|
919
|
-
var key = element.key;
|
|
920
|
-
var ref = element.ref; // Self is preserved since the owner is preserved.
|
|
921
|
-
|
|
922
|
-
var self = element._self; // Source is preserved since cloneElement is unlikely to be targeted by a
|
|
923
|
-
// transpiler, and the original source is probably a better indicator of the
|
|
924
|
-
// true owner.
|
|
925
|
-
|
|
926
|
-
var source = element._source; // Owner will be preserved, unless ref is overridden
|
|
927
|
-
|
|
928
|
-
var owner = element._owner;
|
|
929
|
-
|
|
930
|
-
if (config != null) {
|
|
931
|
-
if (hasValidRef(config)) {
|
|
932
|
-
// Silently steal the ref from the parent.
|
|
933
|
-
ref = config.ref;
|
|
934
|
-
owner = ReactCurrentOwner.current;
|
|
935
|
-
}
|
|
936
|
-
|
|
937
|
-
if (hasValidKey(config)) {
|
|
938
|
-
{
|
|
939
|
-
checkKeyStringCoercion(config.key);
|
|
940
|
-
}
|
|
941
|
-
|
|
942
|
-
key = '' + config.key;
|
|
943
|
-
} // Remaining properties override existing props
|
|
944
|
-
|
|
945
|
-
|
|
946
|
-
var defaultProps;
|
|
947
|
-
|
|
948
|
-
if (element.type && element.type.defaultProps) {
|
|
949
|
-
defaultProps = element.type.defaultProps;
|
|
950
|
-
}
|
|
951
|
-
|
|
952
|
-
for (propName in config) {
|
|
953
|
-
if (hasOwnProperty.call(config, propName) && !RESERVED_PROPS.hasOwnProperty(propName)) {
|
|
954
|
-
if (config[propName] === undefined && defaultProps !== undefined) {
|
|
955
|
-
// Resolve default props
|
|
956
|
-
props[propName] = defaultProps[propName];
|
|
957
|
-
} else {
|
|
958
|
-
props[propName] = config[propName];
|
|
959
|
-
}
|
|
960
|
-
}
|
|
961
|
-
}
|
|
962
|
-
} // Children can be more than one argument, and those are transferred onto
|
|
963
|
-
// the newly allocated props object.
|
|
964
|
-
|
|
965
|
-
|
|
966
|
-
var childrenLength = arguments.length - 2;
|
|
967
|
-
|
|
968
|
-
if (childrenLength === 1) {
|
|
969
|
-
props.children = children;
|
|
970
|
-
} else if (childrenLength > 1) {
|
|
971
|
-
var childArray = Array(childrenLength);
|
|
972
|
-
|
|
973
|
-
for (var i = 0; i < childrenLength; i++) {
|
|
974
|
-
childArray[i] = arguments[i + 2];
|
|
975
|
-
}
|
|
976
|
-
|
|
977
396
|
props.children = childArray;
|
|
978
397
|
}
|
|
979
|
-
|
|
980
|
-
|
|
981
|
-
|
|
982
|
-
|
|
983
|
-
* Verifies the object is a ReactElement.
|
|
984
|
-
* See https://reactjs.org/docs/react-api.html#isvalidelement
|
|
985
|
-
* @param {?object} object
|
|
986
|
-
* @return {boolean} True if `object` is a ReactElement.
|
|
987
|
-
* @final
|
|
988
|
-
*/
|
|
989
|
-
|
|
990
|
-
function isValidElement(object) {
|
|
991
|
-
return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;
|
|
992
|
-
}
|
|
993
|
-
|
|
994
|
-
var SEPARATOR = '.';
|
|
995
|
-
var SUBSEPARATOR = ':';
|
|
996
|
-
/**
|
|
997
|
-
* Escape and wrap key so it is safe to use as a reactid
|
|
998
|
-
*
|
|
999
|
-
* @param {string} key to be escaped.
|
|
1000
|
-
* @return {string} the escaped key.
|
|
1001
|
-
*/
|
|
1002
|
-
|
|
1003
|
-
function escape(key) {
|
|
1004
|
-
var escapeRegex = /[=:]/g;
|
|
1005
|
-
var escaperLookup = {
|
|
1006
|
-
'=': '=0',
|
|
1007
|
-
':': '=2'
|
|
1008
|
-
};
|
|
1009
|
-
var escapedString = key.replace(escapeRegex, function (match) {
|
|
1010
|
-
return escaperLookup[match];
|
|
1011
|
-
});
|
|
1012
|
-
return '$' + escapedString;
|
|
1013
|
-
}
|
|
1014
|
-
/**
|
|
1015
|
-
* TODO: Test that a single child and an array with one item have the same key
|
|
1016
|
-
* pattern.
|
|
1017
|
-
*/
|
|
1018
|
-
|
|
1019
|
-
|
|
1020
|
-
var didWarnAboutMaps = false;
|
|
1021
|
-
var userProvidedKeyEscapeRegex = /\/+/g;
|
|
1022
|
-
|
|
1023
|
-
function escapeUserProvidedKey(text) {
|
|
1024
|
-
return text.replace(userProvidedKeyEscapeRegex, '$&/');
|
|
1025
|
-
}
|
|
1026
|
-
/**
|
|
1027
|
-
* Generate a key string that identifies a element within a set.
|
|
1028
|
-
*
|
|
1029
|
-
* @param {*} element A element that could contain a manual key.
|
|
1030
|
-
* @param {number} index Index that is used if a manual key is not provided.
|
|
1031
|
-
* @return {string}
|
|
1032
|
-
*/
|
|
1033
|
-
|
|
1034
|
-
|
|
1035
|
-
function getElementKey(element, index) {
|
|
1036
|
-
// Do some typechecking here since we call this blindly. We want to ensure
|
|
1037
|
-
// that we don't block potential future ES APIs.
|
|
1038
|
-
if (typeof element === 'object' && element !== null && element.key != null) {
|
|
1039
|
-
// Explicit key
|
|
1040
|
-
{
|
|
1041
|
-
checkKeyStringCoercion(element.key);
|
|
1042
|
-
}
|
|
1043
|
-
|
|
1044
|
-
return escape('' + element.key);
|
|
1045
|
-
} // Implicit key determined by the index in the set
|
|
1046
|
-
|
|
1047
|
-
|
|
1048
|
-
return index.toString(36);
|
|
1049
|
-
}
|
|
1050
|
-
|
|
1051
|
-
function mapIntoArray(children, array, escapedPrefix, nameSoFar, callback) {
|
|
1052
|
-
var type = typeof children;
|
|
1053
|
-
|
|
1054
|
-
if (type === 'undefined' || type === 'boolean') {
|
|
1055
|
-
// All of the above are perceived as null.
|
|
1056
|
-
children = null;
|
|
1057
|
-
}
|
|
1058
|
-
|
|
1059
|
-
var invokeCallback = false;
|
|
1060
|
-
|
|
1061
|
-
if (children === null) {
|
|
1062
|
-
invokeCallback = true;
|
|
1063
|
-
} else {
|
|
1064
|
-
switch (type) {
|
|
1065
|
-
case 'string':
|
|
1066
|
-
case 'number':
|
|
1067
|
-
invokeCallback = true;
|
|
1068
|
-
break;
|
|
1069
|
-
|
|
1070
|
-
case 'object':
|
|
1071
|
-
switch (children.$$typeof) {
|
|
1072
|
-
case REACT_ELEMENT_TYPE:
|
|
1073
|
-
case REACT_PORTAL_TYPE:
|
|
1074
|
-
invokeCallback = true;
|
|
1075
|
-
}
|
|
1076
|
-
|
|
1077
|
-
}
|
|
1078
|
-
}
|
|
1079
|
-
|
|
1080
|
-
if (invokeCallback) {
|
|
1081
|
-
var _child = children;
|
|
1082
|
-
var mappedChild = callback(_child); // If it's the only child, treat the name as if it was wrapped in an array
|
|
1083
|
-
// so that it's consistent if the number of children grows:
|
|
1084
|
-
|
|
1085
|
-
var childKey = nameSoFar === '' ? SEPARATOR + getElementKey(_child, 0) : nameSoFar;
|
|
1086
|
-
|
|
1087
|
-
if (isArray(mappedChild)) {
|
|
1088
|
-
var escapedChildKey = '';
|
|
1089
|
-
|
|
1090
|
-
if (childKey != null) {
|
|
1091
|
-
escapedChildKey = escapeUserProvidedKey(childKey) + '/';
|
|
1092
|
-
}
|
|
1093
|
-
|
|
1094
|
-
mapIntoArray(mappedChild, array, escapedChildKey, '', function (c) {
|
|
1095
|
-
return c;
|
|
1096
|
-
});
|
|
1097
|
-
} else if (mappedChild != null) {
|
|
1098
|
-
if (isValidElement(mappedChild)) {
|
|
1099
|
-
{
|
|
1100
|
-
// The `if` statement here prevents auto-disabling of the safe
|
|
1101
|
-
// coercion ESLint rule, so we must manually disable it below.
|
|
1102
|
-
// $FlowFixMe Flow incorrectly thinks React.Portal doesn't have a key
|
|
1103
|
-
if (mappedChild.key && (!_child || _child.key !== mappedChild.key)) {
|
|
1104
|
-
checkKeyStringCoercion(mappedChild.key);
|
|
1105
|
-
}
|
|
1106
|
-
}
|
|
1107
|
-
|
|
1108
|
-
mappedChild = cloneAndReplaceKey(mappedChild, // Keep both the (mapped) and old keys if they differ, just as
|
|
1109
|
-
// traverseAllChildren used to do for objects as children
|
|
1110
|
-
escapedPrefix + ( // $FlowFixMe Flow incorrectly thinks React.Portal doesn't have a key
|
|
1111
|
-
mappedChild.key && (!_child || _child.key !== mappedChild.key) ? // $FlowFixMe Flow incorrectly thinks existing element's key can be a number
|
|
1112
|
-
// eslint-disable-next-line react-internal/safe-string-coercion
|
|
1113
|
-
escapeUserProvidedKey('' + mappedChild.key) + '/' : '') + childKey);
|
|
1114
|
-
}
|
|
1115
|
-
|
|
1116
|
-
array.push(mappedChild);
|
|
1117
|
-
}
|
|
1118
|
-
|
|
1119
|
-
return 1;
|
|
1120
|
-
}
|
|
1121
|
-
|
|
1122
|
-
var child;
|
|
1123
|
-
var nextName;
|
|
1124
|
-
var subtreeCount = 0; // Count of children found in the current subtree.
|
|
1125
|
-
|
|
1126
|
-
var nextNamePrefix = nameSoFar === '' ? SEPARATOR : nameSoFar + SUBSEPARATOR;
|
|
1127
|
-
|
|
1128
|
-
if (isArray(children)) {
|
|
1129
|
-
for (var i = 0; i < children.length; i++) {
|
|
1130
|
-
child = children[i];
|
|
1131
|
-
nextName = nextNamePrefix + getElementKey(child, i);
|
|
1132
|
-
subtreeCount += mapIntoArray(child, array, escapedPrefix, nextName, callback);
|
|
1133
|
-
}
|
|
1134
|
-
} else {
|
|
1135
|
-
var iteratorFn = getIteratorFn(children);
|
|
1136
|
-
|
|
1137
|
-
if (typeof iteratorFn === 'function') {
|
|
1138
|
-
var iterableChildren = children;
|
|
1139
|
-
|
|
1140
|
-
{
|
|
1141
|
-
// Warn about using Maps as children
|
|
1142
|
-
if (iteratorFn === iterableChildren.entries) {
|
|
1143
|
-
if (!didWarnAboutMaps) {
|
|
1144
|
-
warn('Using Maps as children is not supported. ' + 'Use an array of keyed ReactElements instead.');
|
|
1145
|
-
}
|
|
1146
|
-
|
|
1147
|
-
didWarnAboutMaps = true;
|
|
1148
|
-
}
|
|
1149
|
-
}
|
|
1150
|
-
|
|
1151
|
-
var iterator = iteratorFn.call(iterableChildren);
|
|
1152
|
-
var step;
|
|
1153
|
-
var ii = 0;
|
|
1154
|
-
|
|
1155
|
-
while (!(step = iterator.next()).done) {
|
|
1156
|
-
child = step.value;
|
|
1157
|
-
nextName = nextNamePrefix + getElementKey(child, ii++);
|
|
1158
|
-
subtreeCount += mapIntoArray(child, array, escapedPrefix, nextName, callback);
|
|
1159
|
-
}
|
|
1160
|
-
} else if (type === 'object') {
|
|
1161
|
-
// eslint-disable-next-line react-internal/safe-string-coercion
|
|
1162
|
-
var childrenString = String(children);
|
|
1163
|
-
throw new Error("Objects are not valid as a React child (found: " + (childrenString === '[object Object]' ? 'object with keys {' + Object.keys(children).join(', ') + '}' : childrenString) + "). " + 'If you meant to render a collection of children, use an array ' + 'instead.');
|
|
1164
|
-
}
|
|
1165
|
-
}
|
|
1166
|
-
|
|
1167
|
-
return subtreeCount;
|
|
1168
|
-
}
|
|
1169
|
-
|
|
1170
|
-
/**
|
|
1171
|
-
* Maps children that are typically specified as `props.children`.
|
|
1172
|
-
*
|
|
1173
|
-
* See https://reactjs.org/docs/react-api.html#reactchildrenmap
|
|
1174
|
-
*
|
|
1175
|
-
* The provided mapFunction(child, index) will be called for each
|
|
1176
|
-
* leaf child.
|
|
1177
|
-
*
|
|
1178
|
-
* @param {?*} children Children tree container.
|
|
1179
|
-
* @param {function(*, int)} func The map function.
|
|
1180
|
-
* @param {*} context Context for mapFunction.
|
|
1181
|
-
* @return {object} Object containing the ordered map of results.
|
|
1182
|
-
*/
|
|
1183
|
-
function mapChildren(children, func, context) {
|
|
1184
|
-
if (children == null) {
|
|
1185
|
-
return children;
|
|
1186
|
-
}
|
|
1187
|
-
|
|
1188
|
-
var result = [];
|
|
1189
|
-
var count = 0;
|
|
1190
|
-
mapIntoArray(children, result, '', '', function (child) {
|
|
1191
|
-
return func.call(context, child, count++);
|
|
1192
|
-
});
|
|
1193
|
-
return result;
|
|
1194
|
-
}
|
|
1195
|
-
/**
|
|
1196
|
-
* Count the number of children that are typically specified as
|
|
1197
|
-
* `props.children`.
|
|
1198
|
-
*
|
|
1199
|
-
* See https://reactjs.org/docs/react-api.html#reactchildrencount
|
|
1200
|
-
*
|
|
1201
|
-
* @param {?*} children Children tree container.
|
|
1202
|
-
* @return {number} The number of children.
|
|
1203
|
-
*/
|
|
1204
|
-
|
|
1205
|
-
|
|
1206
|
-
function countChildren(children) {
|
|
1207
|
-
var n = 0;
|
|
1208
|
-
mapChildren(children, function () {
|
|
1209
|
-
n++; // Don't return anything
|
|
1210
|
-
});
|
|
1211
|
-
return n;
|
|
1212
|
-
}
|
|
1213
|
-
|
|
1214
|
-
/**
|
|
1215
|
-
* Iterates through children that are typically specified as `props.children`.
|
|
1216
|
-
*
|
|
1217
|
-
* See https://reactjs.org/docs/react-api.html#reactchildrenforeach
|
|
1218
|
-
*
|
|
1219
|
-
* The provided forEachFunc(child, index) will be called for each
|
|
1220
|
-
* leaf child.
|
|
1221
|
-
*
|
|
1222
|
-
* @param {?*} children Children tree container.
|
|
1223
|
-
* @param {function(*, int)} forEachFunc
|
|
1224
|
-
* @param {*} forEachContext Context for forEachContext.
|
|
1225
|
-
*/
|
|
1226
|
-
function forEachChildren(children, forEachFunc, forEachContext) {
|
|
1227
|
-
mapChildren(children, function () {
|
|
1228
|
-
forEachFunc.apply(this, arguments); // Don't return anything.
|
|
1229
|
-
}, forEachContext);
|
|
1230
|
-
}
|
|
1231
|
-
/**
|
|
1232
|
-
* Flatten a children object (typically specified as `props.children`) and
|
|
1233
|
-
* return an array with appropriately re-keyed children.
|
|
1234
|
-
*
|
|
1235
|
-
* See https://reactjs.org/docs/react-api.html#reactchildrentoarray
|
|
1236
|
-
*/
|
|
1237
|
-
|
|
1238
|
-
|
|
1239
|
-
function toArray(children) {
|
|
1240
|
-
return mapChildren(children, function (child) {
|
|
1241
|
-
return child;
|
|
1242
|
-
}) || [];
|
|
1243
|
-
}
|
|
1244
|
-
/**
|
|
1245
|
-
* Returns the first child in a collection of children and verifies that there
|
|
1246
|
-
* is only one child in the collection.
|
|
1247
|
-
*
|
|
1248
|
-
* See https://reactjs.org/docs/react-api.html#reactchildrenonly
|
|
1249
|
-
*
|
|
1250
|
-
* The current implementation of this function assumes that a single child gets
|
|
1251
|
-
* passed without a wrapper, but the purpose of this helper function is to
|
|
1252
|
-
* abstract away the particular structure of children.
|
|
1253
|
-
*
|
|
1254
|
-
* @param {?object} children Child collection structure.
|
|
1255
|
-
* @return {ReactElement} The first and only `ReactElement` contained in the
|
|
1256
|
-
* structure.
|
|
1257
|
-
*/
|
|
1258
|
-
|
|
1259
|
-
|
|
1260
|
-
function onlyChild(children) {
|
|
1261
|
-
if (!isValidElement(children)) {
|
|
1262
|
-
throw new Error('React.Children.only expected to receive a single React element child.');
|
|
1263
|
-
}
|
|
1264
|
-
|
|
1265
|
-
return children;
|
|
1266
|
-
}
|
|
1267
|
-
|
|
1268
|
-
function createContext(defaultValue) {
|
|
1269
|
-
// TODO: Second argument used to be an optional `calculateChangedBits`
|
|
1270
|
-
// function. Warn to reserve for future use?
|
|
1271
|
-
var context = {
|
|
398
|
+
return ReactElement(element.type, key, void 0, void 0, owner, props);
|
|
399
|
+
};
|
|
400
|
+
react_production.createContext = function (defaultValue) {
|
|
401
|
+
defaultValue = {
|
|
1272
402
|
$$typeof: REACT_CONTEXT_TYPE,
|
|
1273
|
-
// As a workaround to support multiple concurrent renderers, we categorize
|
|
1274
|
-
// some renderers as primary and others as secondary. We only expect
|
|
1275
|
-
// there to be two concurrent renderers at most: React Native (primary) and
|
|
1276
|
-
// Fabric (secondary); React DOM (primary) and React ART (secondary).
|
|
1277
|
-
// Secondary renderers store their context values on separate fields.
|
|
1278
403
|
_currentValue: defaultValue,
|
|
1279
404
|
_currentValue2: defaultValue,
|
|
1280
|
-
// Used to track how many concurrent renderers this context currently
|
|
1281
|
-
// supports within in a single renderer. Such as parallel server rendering.
|
|
1282
405
|
_threadCount: 0,
|
|
1283
|
-
// These are circular
|
|
1284
406
|
Provider: null,
|
|
1285
|
-
Consumer: null
|
|
1286
|
-
// Add these to use same hidden class in VM as ServerContext
|
|
1287
|
-
_defaultValue: null,
|
|
1288
|
-
_globalName: null
|
|
407
|
+
Consumer: null
|
|
1289
408
|
};
|
|
1290
|
-
|
|
1291
|
-
|
|
1292
|
-
|
|
409
|
+
defaultValue.Provider = defaultValue;
|
|
410
|
+
defaultValue.Consumer = {
|
|
411
|
+
$$typeof: REACT_CONSUMER_TYPE,
|
|
412
|
+
_context: defaultValue
|
|
1293
413
|
};
|
|
1294
|
-
|
|
1295
|
-
|
|
1296
|
-
|
|
1297
|
-
|
|
1298
|
-
|
|
1299
|
-
|
|
1300
|
-
|
|
1301
|
-
|
|
1302
|
-
|
|
1303
|
-
|
|
1304
|
-
|
|
1305
|
-
|
|
1306
|
-
|
|
1307
|
-
|
|
1308
|
-
|
|
1309
|
-
|
|
1310
|
-
|
|
1311
|
-
|
|
1312
|
-
|
|
1313
|
-
error('Rendering <Context.Consumer.Provider> is not supported and will be removed in ' + 'a future major release. Did you mean to render <Context.Provider> instead?');
|
|
1314
|
-
}
|
|
1315
|
-
|
|
1316
|
-
return context.Provider;
|
|
1317
|
-
},
|
|
1318
|
-
set: function (_Provider) {
|
|
1319
|
-
context.Provider = _Provider;
|
|
1320
|
-
}
|
|
1321
|
-
},
|
|
1322
|
-
_currentValue: {
|
|
1323
|
-
get: function () {
|
|
1324
|
-
return context._currentValue;
|
|
1325
|
-
},
|
|
1326
|
-
set: function (_currentValue) {
|
|
1327
|
-
context._currentValue = _currentValue;
|
|
1328
|
-
}
|
|
1329
|
-
},
|
|
1330
|
-
_currentValue2: {
|
|
1331
|
-
get: function () {
|
|
1332
|
-
return context._currentValue2;
|
|
1333
|
-
},
|
|
1334
|
-
set: function (_currentValue2) {
|
|
1335
|
-
context._currentValue2 = _currentValue2;
|
|
1336
|
-
}
|
|
1337
|
-
},
|
|
1338
|
-
_threadCount: {
|
|
1339
|
-
get: function () {
|
|
1340
|
-
return context._threadCount;
|
|
1341
|
-
},
|
|
1342
|
-
set: function (_threadCount) {
|
|
1343
|
-
context._threadCount = _threadCount;
|
|
1344
|
-
}
|
|
1345
|
-
},
|
|
1346
|
-
Consumer: {
|
|
1347
|
-
get: function () {
|
|
1348
|
-
if (!hasWarnedAboutUsingNestedContextConsumers) {
|
|
1349
|
-
hasWarnedAboutUsingNestedContextConsumers = true;
|
|
1350
|
-
|
|
1351
|
-
error('Rendering <Context.Consumer.Consumer> is not supported and will be removed in ' + 'a future major release. Did you mean to render <Context.Consumer> instead?');
|
|
1352
|
-
}
|
|
1353
|
-
|
|
1354
|
-
return context.Consumer;
|
|
1355
|
-
}
|
|
1356
|
-
},
|
|
1357
|
-
displayName: {
|
|
1358
|
-
get: function () {
|
|
1359
|
-
return context.displayName;
|
|
1360
|
-
},
|
|
1361
|
-
set: function (displayName) {
|
|
1362
|
-
if (!hasWarnedAboutDisplayNameOnConsumer) {
|
|
1363
|
-
warn('Setting `displayName` on Context.Consumer has no effect. ' + "You should set it directly on the context with Context.displayName = '%s'.", displayName);
|
|
1364
|
-
|
|
1365
|
-
hasWarnedAboutDisplayNameOnConsumer = true;
|
|
1366
|
-
}
|
|
1367
|
-
}
|
|
1368
|
-
}
|
|
1369
|
-
}); // $FlowFixMe: Flow complains about missing properties because it doesn't understand defineProperty
|
|
1370
|
-
|
|
1371
|
-
context.Consumer = Consumer;
|
|
1372
|
-
}
|
|
1373
|
-
|
|
1374
|
-
{
|
|
1375
|
-
context._currentRenderer = null;
|
|
1376
|
-
context._currentRenderer2 = null;
|
|
1377
|
-
}
|
|
1378
|
-
|
|
1379
|
-
return context;
|
|
1380
|
-
}
|
|
1381
|
-
|
|
1382
|
-
var Uninitialized = -1;
|
|
1383
|
-
var Pending = 0;
|
|
1384
|
-
var Resolved = 1;
|
|
1385
|
-
var Rejected = 2;
|
|
1386
|
-
|
|
1387
|
-
function lazyInitializer(payload) {
|
|
1388
|
-
if (payload._status === Uninitialized) {
|
|
1389
|
-
var ctor = payload._result;
|
|
1390
|
-
var thenable = ctor(); // Transition to the next state.
|
|
1391
|
-
// This might throw either because it's missing or throws. If so, we treat it
|
|
1392
|
-
// as still uninitialized and try again next time. Which is the same as what
|
|
1393
|
-
// happens if the ctor or any wrappers processing the ctor throws. This might
|
|
1394
|
-
// end up fixing it if the resolution was a concurrency bug.
|
|
1395
|
-
|
|
1396
|
-
thenable.then(function (moduleObject) {
|
|
1397
|
-
if (payload._status === Pending || payload._status === Uninitialized) {
|
|
1398
|
-
// Transition to the next state.
|
|
1399
|
-
var resolved = payload;
|
|
1400
|
-
resolved._status = Resolved;
|
|
1401
|
-
resolved._result = moduleObject;
|
|
1402
|
-
}
|
|
1403
|
-
}, function (error) {
|
|
1404
|
-
if (payload._status === Pending || payload._status === Uninitialized) {
|
|
1405
|
-
// Transition to the next state.
|
|
1406
|
-
var rejected = payload;
|
|
1407
|
-
rejected._status = Rejected;
|
|
1408
|
-
rejected._result = error;
|
|
1409
|
-
}
|
|
1410
|
-
});
|
|
1411
|
-
|
|
1412
|
-
if (payload._status === Uninitialized) {
|
|
1413
|
-
// In case, we're still uninitialized, then we're waiting for the thenable
|
|
1414
|
-
// to resolve. Set it as pending in the meantime.
|
|
1415
|
-
var pending = payload;
|
|
1416
|
-
pending._status = Pending;
|
|
1417
|
-
pending._result = thenable;
|
|
1418
|
-
}
|
|
1419
|
-
}
|
|
1420
|
-
|
|
1421
|
-
if (payload._status === Resolved) {
|
|
1422
|
-
var moduleObject = payload._result;
|
|
1423
|
-
|
|
1424
|
-
{
|
|
1425
|
-
if (moduleObject === undefined) {
|
|
1426
|
-
error('lazy: Expected the result of a dynamic imp' + 'ort() call. ' + 'Instead received: %s\n\nYour code should look like: \n ' + // Break up imports to avoid accidentally parsing them as dependencies.
|
|
1427
|
-
'const MyComponent = lazy(() => imp' + "ort('./MyComponent'))\n\n" + 'Did you accidentally put curly braces around the import?', moduleObject);
|
|
1428
|
-
}
|
|
1429
|
-
}
|
|
1430
|
-
|
|
1431
|
-
{
|
|
1432
|
-
if (!('default' in moduleObject)) {
|
|
1433
|
-
error('lazy: Expected the result of a dynamic imp' + 'ort() call. ' + 'Instead received: %s\n\nYour code should look like: \n ' + // Break up imports to avoid accidentally parsing them as dependencies.
|
|
1434
|
-
'const MyComponent = lazy(() => imp' + "ort('./MyComponent'))", moduleObject);
|
|
1435
|
-
}
|
|
1436
|
-
}
|
|
1437
|
-
|
|
1438
|
-
return moduleObject.default;
|
|
1439
|
-
} else {
|
|
1440
|
-
throw payload._result;
|
|
414
|
+
return defaultValue;
|
|
415
|
+
};
|
|
416
|
+
react_production.createElement = function (type, config, children) {
|
|
417
|
+
var propName,
|
|
418
|
+
props = {},
|
|
419
|
+
key = null;
|
|
420
|
+
if (null != config)
|
|
421
|
+
for (propName in (void 0 !== config.key && (key = "" + config.key), config))
|
|
422
|
+
hasOwnProperty.call(config, propName) &&
|
|
423
|
+
"key" !== propName &&
|
|
424
|
+
"__self" !== propName &&
|
|
425
|
+
"__source" !== propName &&
|
|
426
|
+
(props[propName] = config[propName]);
|
|
427
|
+
var childrenLength = arguments.length - 2;
|
|
428
|
+
if (1 === childrenLength) props.children = children;
|
|
429
|
+
else if (1 < childrenLength) {
|
|
430
|
+
for (var childArray = Array(childrenLength), i = 0; i < childrenLength; i++)
|
|
431
|
+
childArray[i] = arguments[i + 2];
|
|
432
|
+
props.children = childArray;
|
|
1441
433
|
}
|
|
1442
|
-
|
|
1443
|
-
|
|
1444
|
-
|
|
1445
|
-
|
|
1446
|
-
|
|
1447
|
-
|
|
1448
|
-
|
|
1449
|
-
};
|
|
1450
|
-
|
|
434
|
+
if (type && type.defaultProps)
|
|
435
|
+
for (propName in ((childrenLength = type.defaultProps), childrenLength))
|
|
436
|
+
void 0 === props[propName] &&
|
|
437
|
+
(props[propName] = childrenLength[propName]);
|
|
438
|
+
return ReactElement(type, key, void 0, void 0, null, props);
|
|
439
|
+
};
|
|
440
|
+
react_production.createRef = function () {
|
|
441
|
+
return { current: null };
|
|
442
|
+
};
|
|
443
|
+
react_production.forwardRef = function (render) {
|
|
444
|
+
return { $$typeof: REACT_FORWARD_REF_TYPE, render: render };
|
|
445
|
+
};
|
|
446
|
+
react_production.isValidElement = isValidElement;
|
|
447
|
+
react_production.lazy = function (ctor) {
|
|
448
|
+
return {
|
|
1451
449
|
$$typeof: REACT_LAZY_TYPE,
|
|
1452
|
-
_payload:
|
|
450
|
+
_payload: { _status: -1, _result: ctor },
|
|
1453
451
|
_init: lazyInitializer
|
|
1454
452
|
};
|
|
1455
|
-
|
|
1456
|
-
|
|
1457
|
-
|
|
1458
|
-
var defaultProps;
|
|
1459
|
-
var propTypes; // $FlowFixMe
|
|
1460
|
-
|
|
1461
|
-
Object.defineProperties(lazyType, {
|
|
1462
|
-
defaultProps: {
|
|
1463
|
-
configurable: true,
|
|
1464
|
-
get: function () {
|
|
1465
|
-
return defaultProps;
|
|
1466
|
-
},
|
|
1467
|
-
set: function (newDefaultProps) {
|
|
1468
|
-
error('React.lazy(...): It is not supported to assign `defaultProps` to ' + 'a lazy component import. Either specify them where the component ' + 'is defined, or create a wrapping component around it.');
|
|
1469
|
-
|
|
1470
|
-
defaultProps = newDefaultProps; // Match production behavior more closely:
|
|
1471
|
-
// $FlowFixMe
|
|
1472
|
-
|
|
1473
|
-
Object.defineProperty(lazyType, 'defaultProps', {
|
|
1474
|
-
enumerable: true
|
|
1475
|
-
});
|
|
1476
|
-
}
|
|
1477
|
-
},
|
|
1478
|
-
propTypes: {
|
|
1479
|
-
configurable: true,
|
|
1480
|
-
get: function () {
|
|
1481
|
-
return propTypes;
|
|
1482
|
-
},
|
|
1483
|
-
set: function (newPropTypes) {
|
|
1484
|
-
error('React.lazy(...): It is not supported to assign `propTypes` to ' + 'a lazy component import. Either specify them where the component ' + 'is defined, or create a wrapping component around it.');
|
|
1485
|
-
|
|
1486
|
-
propTypes = newPropTypes; // Match production behavior more closely:
|
|
1487
|
-
// $FlowFixMe
|
|
1488
|
-
|
|
1489
|
-
Object.defineProperty(lazyType, 'propTypes', {
|
|
1490
|
-
enumerable: true
|
|
1491
|
-
});
|
|
1492
|
-
}
|
|
1493
|
-
}
|
|
1494
|
-
});
|
|
1495
|
-
}
|
|
1496
|
-
|
|
1497
|
-
return lazyType;
|
|
1498
|
-
}
|
|
1499
|
-
|
|
1500
|
-
function forwardRef(render) {
|
|
1501
|
-
{
|
|
1502
|
-
if (render != null && render.$$typeof === REACT_MEMO_TYPE) {
|
|
1503
|
-
error('forwardRef requires a render function but received a `memo` ' + 'component. Instead of forwardRef(memo(...)), use ' + 'memo(forwardRef(...)).');
|
|
1504
|
-
} else if (typeof render !== 'function') {
|
|
1505
|
-
error('forwardRef requires a render function but was given %s.', render === null ? 'null' : typeof render);
|
|
1506
|
-
} else {
|
|
1507
|
-
if (render.length !== 0 && render.length !== 2) {
|
|
1508
|
-
error('forwardRef render functions accept exactly two parameters: props and ref. %s', render.length === 1 ? 'Did you forget to use the ref parameter?' : 'Any additional parameter will be undefined.');
|
|
1509
|
-
}
|
|
1510
|
-
}
|
|
1511
|
-
|
|
1512
|
-
if (render != null) {
|
|
1513
|
-
if (render.defaultProps != null || render.propTypes != null) {
|
|
1514
|
-
error('forwardRef render functions do not support propTypes or defaultProps. ' + 'Did you accidentally pass a React component?');
|
|
1515
|
-
}
|
|
1516
|
-
}
|
|
1517
|
-
}
|
|
1518
|
-
|
|
1519
|
-
var elementType = {
|
|
1520
|
-
$$typeof: REACT_FORWARD_REF_TYPE,
|
|
1521
|
-
render: render
|
|
1522
|
-
};
|
|
1523
|
-
|
|
1524
|
-
{
|
|
1525
|
-
var ownName;
|
|
1526
|
-
Object.defineProperty(elementType, 'displayName', {
|
|
1527
|
-
enumerable: false,
|
|
1528
|
-
configurable: true,
|
|
1529
|
-
get: function () {
|
|
1530
|
-
return ownName;
|
|
1531
|
-
},
|
|
1532
|
-
set: function (name) {
|
|
1533
|
-
ownName = name; // The inner component shouldn't inherit this display name in most cases,
|
|
1534
|
-
// because the component may be used elsewhere.
|
|
1535
|
-
// But it's nice for anonymous functions to inherit the name,
|
|
1536
|
-
// so that our component-stack generation logic will display their frames.
|
|
1537
|
-
// An anonymous function generally suggests a pattern like:
|
|
1538
|
-
// React.forwardRef((props, ref) => {...});
|
|
1539
|
-
// This kind of inner function is not used elsewhere so the side effect is okay.
|
|
1540
|
-
|
|
1541
|
-
if (!render.name && !render.displayName) {
|
|
1542
|
-
render.displayName = name;
|
|
1543
|
-
}
|
|
1544
|
-
}
|
|
1545
|
-
});
|
|
1546
|
-
}
|
|
1547
|
-
|
|
1548
|
-
return elementType;
|
|
1549
|
-
}
|
|
1550
|
-
|
|
1551
|
-
var REACT_MODULE_REFERENCE;
|
|
1552
|
-
|
|
1553
|
-
{
|
|
1554
|
-
REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');
|
|
1555
|
-
}
|
|
1556
|
-
|
|
1557
|
-
function isValidElementType(type) {
|
|
1558
|
-
if (typeof type === 'string' || typeof type === 'function') {
|
|
1559
|
-
return true;
|
|
1560
|
-
} // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).
|
|
1561
|
-
|
|
1562
|
-
|
|
1563
|
-
if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {
|
|
1564
|
-
return true;
|
|
1565
|
-
}
|
|
1566
|
-
|
|
1567
|
-
if (typeof type === 'object' && type !== null) {
|
|
1568
|
-
if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object
|
|
1569
|
-
// types supported by any Flight configuration anywhere since
|
|
1570
|
-
// we don't know which Flight build this will end up being used
|
|
1571
|
-
// with.
|
|
1572
|
-
type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {
|
|
1573
|
-
return true;
|
|
1574
|
-
}
|
|
1575
|
-
}
|
|
1576
|
-
|
|
1577
|
-
return false;
|
|
1578
|
-
}
|
|
1579
|
-
|
|
1580
|
-
function memo(type, compare) {
|
|
1581
|
-
{
|
|
1582
|
-
if (!isValidElementType(type)) {
|
|
1583
|
-
error('memo: The first argument must be a component. Instead ' + 'received: %s', type === null ? 'null' : typeof type);
|
|
1584
|
-
}
|
|
1585
|
-
}
|
|
1586
|
-
|
|
1587
|
-
var elementType = {
|
|
453
|
+
};
|
|
454
|
+
react_production.memo = function (type, compare) {
|
|
455
|
+
return {
|
|
1588
456
|
$$typeof: REACT_MEMO_TYPE,
|
|
1589
457
|
type: type,
|
|
1590
|
-
compare:
|
|
458
|
+
compare: void 0 === compare ? null : compare
|
|
1591
459
|
};
|
|
1592
|
-
|
|
1593
|
-
|
|
1594
|
-
|
|
1595
|
-
|
|
1596
|
-
|
|
1597
|
-
configurable: true,
|
|
1598
|
-
get: function () {
|
|
1599
|
-
return ownName;
|
|
1600
|
-
},
|
|
1601
|
-
set: function (name) {
|
|
1602
|
-
ownName = name; // The inner component shouldn't inherit this display name in most cases,
|
|
1603
|
-
// because the component may be used elsewhere.
|
|
1604
|
-
// But it's nice for anonymous functions to inherit the name,
|
|
1605
|
-
// so that our component-stack generation logic will display their frames.
|
|
1606
|
-
// An anonymous function generally suggests a pattern like:
|
|
1607
|
-
// React.memo((props) => {...});
|
|
1608
|
-
// This kind of inner function is not used elsewhere so the side effect is okay.
|
|
1609
|
-
|
|
1610
|
-
if (!type.name && !type.displayName) {
|
|
1611
|
-
type.displayName = name;
|
|
1612
|
-
}
|
|
1613
|
-
}
|
|
1614
|
-
});
|
|
1615
|
-
}
|
|
1616
|
-
|
|
1617
|
-
return elementType;
|
|
1618
|
-
}
|
|
1619
|
-
|
|
1620
|
-
function resolveDispatcher() {
|
|
1621
|
-
var dispatcher = ReactCurrentDispatcher.current;
|
|
1622
|
-
|
|
1623
|
-
{
|
|
1624
|
-
if (dispatcher === null) {
|
|
1625
|
-
error('Invalid hook call. Hooks can only be called inside of the body of a function component. This could happen for' + ' one of the following reasons:\n' + '1. You might have mismatching versions of React and the renderer (such as React DOM)\n' + '2. You might be breaking the Rules of Hooks\n' + '3. You might have more than one copy of React in the same app\n' + 'See https://reactjs.org/link/invalid-hook-call for tips about how to debug and fix this problem.');
|
|
1626
|
-
}
|
|
1627
|
-
} // Will result in a null access error if accessed outside render phase. We
|
|
1628
|
-
// intentionally don't throw our own error because this is in a hot path.
|
|
1629
|
-
// Also helps ensure this is inlined.
|
|
1630
|
-
|
|
1631
|
-
|
|
1632
|
-
return dispatcher;
|
|
1633
|
-
}
|
|
1634
|
-
function useContext(Context) {
|
|
1635
|
-
var dispatcher = resolveDispatcher();
|
|
1636
|
-
|
|
1637
|
-
{
|
|
1638
|
-
// TODO: add a more generic warning for invalid values.
|
|
1639
|
-
if (Context._context !== undefined) {
|
|
1640
|
-
var realContext = Context._context; // Don't deduplicate because this legitimately causes bugs
|
|
1641
|
-
// and nobody should be using this in existing code.
|
|
1642
|
-
|
|
1643
|
-
if (realContext.Consumer === Context) {
|
|
1644
|
-
error('Calling useContext(Context.Consumer) is not supported, may cause bugs, and will be ' + 'removed in a future major release. Did you mean to call useContext(Context) instead?');
|
|
1645
|
-
} else if (realContext.Provider === Context) {
|
|
1646
|
-
error('Calling useContext(Context.Provider) is not supported. ' + 'Did you mean to call useContext(Context) instead?');
|
|
1647
|
-
}
|
|
1648
|
-
}
|
|
1649
|
-
}
|
|
1650
|
-
|
|
1651
|
-
return dispatcher.useContext(Context);
|
|
1652
|
-
}
|
|
1653
|
-
function useState(initialState) {
|
|
1654
|
-
var dispatcher = resolveDispatcher();
|
|
1655
|
-
return dispatcher.useState(initialState);
|
|
1656
|
-
}
|
|
1657
|
-
function useReducer(reducer, initialArg, init) {
|
|
1658
|
-
var dispatcher = resolveDispatcher();
|
|
1659
|
-
return dispatcher.useReducer(reducer, initialArg, init);
|
|
1660
|
-
}
|
|
1661
|
-
function useRef(initialValue) {
|
|
1662
|
-
var dispatcher = resolveDispatcher();
|
|
1663
|
-
return dispatcher.useRef(initialValue);
|
|
1664
|
-
}
|
|
1665
|
-
function useEffect(create, deps) {
|
|
1666
|
-
var dispatcher = resolveDispatcher();
|
|
1667
|
-
return dispatcher.useEffect(create, deps);
|
|
1668
|
-
}
|
|
1669
|
-
function useInsertionEffect(create, deps) {
|
|
1670
|
-
var dispatcher = resolveDispatcher();
|
|
1671
|
-
return dispatcher.useInsertionEffect(create, deps);
|
|
1672
|
-
}
|
|
1673
|
-
function useLayoutEffect(create, deps) {
|
|
1674
|
-
var dispatcher = resolveDispatcher();
|
|
1675
|
-
return dispatcher.useLayoutEffect(create, deps);
|
|
1676
|
-
}
|
|
1677
|
-
function useCallback(callback, deps) {
|
|
1678
|
-
var dispatcher = resolveDispatcher();
|
|
1679
|
-
return dispatcher.useCallback(callback, deps);
|
|
1680
|
-
}
|
|
1681
|
-
function useMemo(create, deps) {
|
|
1682
|
-
var dispatcher = resolveDispatcher();
|
|
1683
|
-
return dispatcher.useMemo(create, deps);
|
|
1684
|
-
}
|
|
1685
|
-
function useImperativeHandle(ref, create, deps) {
|
|
1686
|
-
var dispatcher = resolveDispatcher();
|
|
1687
|
-
return dispatcher.useImperativeHandle(ref, create, deps);
|
|
1688
|
-
}
|
|
1689
|
-
function useDebugValue(value, formatterFn) {
|
|
1690
|
-
{
|
|
1691
|
-
var dispatcher = resolveDispatcher();
|
|
1692
|
-
return dispatcher.useDebugValue(value, formatterFn);
|
|
1693
|
-
}
|
|
1694
|
-
}
|
|
1695
|
-
function useTransition() {
|
|
1696
|
-
var dispatcher = resolveDispatcher();
|
|
1697
|
-
return dispatcher.useTransition();
|
|
1698
|
-
}
|
|
1699
|
-
function useDeferredValue(value) {
|
|
1700
|
-
var dispatcher = resolveDispatcher();
|
|
1701
|
-
return dispatcher.useDeferredValue(value);
|
|
1702
|
-
}
|
|
1703
|
-
function useId() {
|
|
1704
|
-
var dispatcher = resolveDispatcher();
|
|
1705
|
-
return dispatcher.useId();
|
|
1706
|
-
}
|
|
1707
|
-
function useSyncExternalStore(subscribe, getSnapshot, getServerSnapshot) {
|
|
1708
|
-
var dispatcher = resolveDispatcher();
|
|
1709
|
-
return dispatcher.useSyncExternalStore(subscribe, getSnapshot, getServerSnapshot);
|
|
1710
|
-
}
|
|
1711
|
-
|
|
1712
|
-
// Helpers to patch console.logs to avoid logging during side-effect free
|
|
1713
|
-
// replaying on render function. This currently only patches the object
|
|
1714
|
-
// lazily which won't cover if the log function was extracted eagerly.
|
|
1715
|
-
// We could also eagerly patch the method.
|
|
1716
|
-
var disabledDepth = 0;
|
|
1717
|
-
var prevLog;
|
|
1718
|
-
var prevInfo;
|
|
1719
|
-
var prevWarn;
|
|
1720
|
-
var prevError;
|
|
1721
|
-
var prevGroup;
|
|
1722
|
-
var prevGroupCollapsed;
|
|
1723
|
-
var prevGroupEnd;
|
|
1724
|
-
|
|
1725
|
-
function disabledLog() {}
|
|
1726
|
-
|
|
1727
|
-
disabledLog.__reactDisabledLog = true;
|
|
1728
|
-
function disableLogs() {
|
|
1729
|
-
{
|
|
1730
|
-
if (disabledDepth === 0) {
|
|
1731
|
-
/* eslint-disable react-internal/no-production-logging */
|
|
1732
|
-
prevLog = console.log;
|
|
1733
|
-
prevInfo = console.info;
|
|
1734
|
-
prevWarn = console.warn;
|
|
1735
|
-
prevError = console.error;
|
|
1736
|
-
prevGroup = console.group;
|
|
1737
|
-
prevGroupCollapsed = console.groupCollapsed;
|
|
1738
|
-
prevGroupEnd = console.groupEnd; // https://github.com/facebook/react/issues/19099
|
|
1739
|
-
|
|
1740
|
-
var props = {
|
|
1741
|
-
configurable: true,
|
|
1742
|
-
enumerable: true,
|
|
1743
|
-
value: disabledLog,
|
|
1744
|
-
writable: true
|
|
1745
|
-
}; // $FlowFixMe Flow thinks console is immutable.
|
|
1746
|
-
|
|
1747
|
-
Object.defineProperties(console, {
|
|
1748
|
-
info: props,
|
|
1749
|
-
log: props,
|
|
1750
|
-
warn: props,
|
|
1751
|
-
error: props,
|
|
1752
|
-
group: props,
|
|
1753
|
-
groupCollapsed: props,
|
|
1754
|
-
groupEnd: props
|
|
1755
|
-
});
|
|
1756
|
-
/* eslint-enable react-internal/no-production-logging */
|
|
1757
|
-
}
|
|
1758
|
-
|
|
1759
|
-
disabledDepth++;
|
|
1760
|
-
}
|
|
1761
|
-
}
|
|
1762
|
-
function reenableLogs() {
|
|
1763
|
-
{
|
|
1764
|
-
disabledDepth--;
|
|
1765
|
-
|
|
1766
|
-
if (disabledDepth === 0) {
|
|
1767
|
-
/* eslint-disable react-internal/no-production-logging */
|
|
1768
|
-
var props = {
|
|
1769
|
-
configurable: true,
|
|
1770
|
-
enumerable: true,
|
|
1771
|
-
writable: true
|
|
1772
|
-
}; // $FlowFixMe Flow thinks console is immutable.
|
|
1773
|
-
|
|
1774
|
-
Object.defineProperties(console, {
|
|
1775
|
-
log: assign({}, props, {
|
|
1776
|
-
value: prevLog
|
|
1777
|
-
}),
|
|
1778
|
-
info: assign({}, props, {
|
|
1779
|
-
value: prevInfo
|
|
1780
|
-
}),
|
|
1781
|
-
warn: assign({}, props, {
|
|
1782
|
-
value: prevWarn
|
|
1783
|
-
}),
|
|
1784
|
-
error: assign({}, props, {
|
|
1785
|
-
value: prevError
|
|
1786
|
-
}),
|
|
1787
|
-
group: assign({}, props, {
|
|
1788
|
-
value: prevGroup
|
|
1789
|
-
}),
|
|
1790
|
-
groupCollapsed: assign({}, props, {
|
|
1791
|
-
value: prevGroupCollapsed
|
|
1792
|
-
}),
|
|
1793
|
-
groupEnd: assign({}, props, {
|
|
1794
|
-
value: prevGroupEnd
|
|
1795
|
-
})
|
|
1796
|
-
});
|
|
1797
|
-
/* eslint-enable react-internal/no-production-logging */
|
|
1798
|
-
}
|
|
1799
|
-
|
|
1800
|
-
if (disabledDepth < 0) {
|
|
1801
|
-
error('disabledDepth fell below zero. ' + 'This is a bug in React. Please file an issue.');
|
|
1802
|
-
}
|
|
1803
|
-
}
|
|
1804
|
-
}
|
|
1805
|
-
|
|
1806
|
-
var ReactCurrentDispatcher$1 = ReactSharedInternals.ReactCurrentDispatcher;
|
|
1807
|
-
var prefix;
|
|
1808
|
-
function describeBuiltInComponentFrame(name, source, ownerFn) {
|
|
1809
|
-
{
|
|
1810
|
-
if (prefix === undefined) {
|
|
1811
|
-
// Extract the VM specific prefix used by each line.
|
|
1812
|
-
try {
|
|
1813
|
-
throw Error();
|
|
1814
|
-
} catch (x) {
|
|
1815
|
-
var match = x.stack.trim().match(/\n( *(at )?)/);
|
|
1816
|
-
prefix = match && match[1] || '';
|
|
1817
|
-
}
|
|
1818
|
-
} // We use the prefix to ensure our stacks line up with native stack frames.
|
|
1819
|
-
|
|
1820
|
-
|
|
1821
|
-
return '\n' + prefix + name;
|
|
1822
|
-
}
|
|
1823
|
-
}
|
|
1824
|
-
var reentry = false;
|
|
1825
|
-
var componentFrameCache;
|
|
1826
|
-
|
|
1827
|
-
{
|
|
1828
|
-
var PossiblyWeakMap = typeof WeakMap === 'function' ? WeakMap : Map;
|
|
1829
|
-
componentFrameCache = new PossiblyWeakMap();
|
|
1830
|
-
}
|
|
1831
|
-
|
|
1832
|
-
function describeNativeComponentFrame(fn, construct) {
|
|
1833
|
-
// If something asked for a stack inside a fake render, it should get ignored.
|
|
1834
|
-
if ( !fn || reentry) {
|
|
1835
|
-
return '';
|
|
1836
|
-
}
|
|
1837
|
-
|
|
1838
|
-
{
|
|
1839
|
-
var frame = componentFrameCache.get(fn);
|
|
1840
|
-
|
|
1841
|
-
if (frame !== undefined) {
|
|
1842
|
-
return frame;
|
|
1843
|
-
}
|
|
1844
|
-
}
|
|
1845
|
-
|
|
1846
|
-
var control;
|
|
1847
|
-
reentry = true;
|
|
1848
|
-
var previousPrepareStackTrace = Error.prepareStackTrace; // $FlowFixMe It does accept undefined.
|
|
1849
|
-
|
|
1850
|
-
Error.prepareStackTrace = undefined;
|
|
1851
|
-
var previousDispatcher;
|
|
1852
|
-
|
|
1853
|
-
{
|
|
1854
|
-
previousDispatcher = ReactCurrentDispatcher$1.current; // Set the dispatcher in DEV because this might be call in the render function
|
|
1855
|
-
// for warnings.
|
|
1856
|
-
|
|
1857
|
-
ReactCurrentDispatcher$1.current = null;
|
|
1858
|
-
disableLogs();
|
|
1859
|
-
}
|
|
1860
|
-
|
|
460
|
+
};
|
|
461
|
+
react_production.startTransition = function (scope) {
|
|
462
|
+
var prevTransition = ReactSharedInternals.T,
|
|
463
|
+
currentTransition = {};
|
|
464
|
+
ReactSharedInternals.T = currentTransition;
|
|
1861
465
|
try {
|
|
1862
|
-
|
|
1863
|
-
|
|
1864
|
-
|
|
1865
|
-
|
|
1866
|
-
|
|
1867
|
-
|
|
1868
|
-
|
|
1869
|
-
|
|
1870
|
-
|
|
1871
|
-
|
|
1872
|
-
// We use a throwing setter instead of frozen or non-writable props
|
|
1873
|
-
// because that won't throw in a non-strict mode function.
|
|
1874
|
-
throw Error();
|
|
1875
|
-
}
|
|
1876
|
-
});
|
|
1877
|
-
|
|
1878
|
-
if (typeof Reflect === 'object' && Reflect.construct) {
|
|
1879
|
-
// We construct a different control for this case to include any extra
|
|
1880
|
-
// frames added by the construct call.
|
|
1881
|
-
try {
|
|
1882
|
-
Reflect.construct(Fake, []);
|
|
1883
|
-
} catch (x) {
|
|
1884
|
-
control = x;
|
|
1885
|
-
}
|
|
1886
|
-
|
|
1887
|
-
Reflect.construct(fn, [], Fake);
|
|
1888
|
-
} else {
|
|
1889
|
-
try {
|
|
1890
|
-
Fake.call();
|
|
1891
|
-
} catch (x) {
|
|
1892
|
-
control = x;
|
|
1893
|
-
}
|
|
1894
|
-
|
|
1895
|
-
fn.call(Fake.prototype);
|
|
1896
|
-
}
|
|
1897
|
-
} else {
|
|
1898
|
-
try {
|
|
1899
|
-
throw Error();
|
|
1900
|
-
} catch (x) {
|
|
1901
|
-
control = x;
|
|
1902
|
-
}
|
|
1903
|
-
|
|
1904
|
-
fn();
|
|
1905
|
-
}
|
|
1906
|
-
} catch (sample) {
|
|
1907
|
-
// This is inlined manually because closure doesn't do it for us.
|
|
1908
|
-
if (sample && control && typeof sample.stack === 'string') {
|
|
1909
|
-
// This extracts the first frame from the sample that isn't also in the control.
|
|
1910
|
-
// Skipping one frame that we assume is the frame that calls the two.
|
|
1911
|
-
var sampleLines = sample.stack.split('\n');
|
|
1912
|
-
var controlLines = control.stack.split('\n');
|
|
1913
|
-
var s = sampleLines.length - 1;
|
|
1914
|
-
var c = controlLines.length - 1;
|
|
1915
|
-
|
|
1916
|
-
while (s >= 1 && c >= 0 && sampleLines[s] !== controlLines[c]) {
|
|
1917
|
-
// We expect at least one stack frame to be shared.
|
|
1918
|
-
// Typically this will be the root most one. However, stack frames may be
|
|
1919
|
-
// cut off due to maximum stack limits. In this case, one maybe cut off
|
|
1920
|
-
// earlier than the other. We assume that the sample is longer or the same
|
|
1921
|
-
// and there for cut off earlier. So we should find the root most frame in
|
|
1922
|
-
// the sample somewhere in the control.
|
|
1923
|
-
c--;
|
|
1924
|
-
}
|
|
1925
|
-
|
|
1926
|
-
for (; s >= 1 && c >= 0; s--, c--) {
|
|
1927
|
-
// Next we find the first one that isn't the same which should be the
|
|
1928
|
-
// frame that called our sample function and the control.
|
|
1929
|
-
if (sampleLines[s] !== controlLines[c]) {
|
|
1930
|
-
// In V8, the first line is describing the message but other VMs don't.
|
|
1931
|
-
// If we're about to return the first line, and the control is also on the same
|
|
1932
|
-
// line, that's a pretty good indicator that our sample threw at same line as
|
|
1933
|
-
// the control. I.e. before we entered the sample frame. So we ignore this result.
|
|
1934
|
-
// This can happen if you passed a class to function component, or non-function.
|
|
1935
|
-
if (s !== 1 || c !== 1) {
|
|
1936
|
-
do {
|
|
1937
|
-
s--;
|
|
1938
|
-
c--; // We may still have similar intermediate frames from the construct call.
|
|
1939
|
-
// The next one that isn't the same should be our match though.
|
|
1940
|
-
|
|
1941
|
-
if (c < 0 || sampleLines[s] !== controlLines[c]) {
|
|
1942
|
-
// V8 adds a "new" prefix for native classes. Let's remove it to make it prettier.
|
|
1943
|
-
var _frame = '\n' + sampleLines[s].replace(' at new ', ' at '); // If our component frame is labeled "<anonymous>"
|
|
1944
|
-
// but we have a user-provided "displayName"
|
|
1945
|
-
// splice it in to make the stack more readable.
|
|
1946
|
-
|
|
1947
|
-
|
|
1948
|
-
if (fn.displayName && _frame.includes('<anonymous>')) {
|
|
1949
|
-
_frame = _frame.replace('<anonymous>', fn.displayName);
|
|
1950
|
-
}
|
|
1951
|
-
|
|
1952
|
-
{
|
|
1953
|
-
if (typeof fn === 'function') {
|
|
1954
|
-
componentFrameCache.set(fn, _frame);
|
|
1955
|
-
}
|
|
1956
|
-
} // Return the line we found.
|
|
1957
|
-
|
|
1958
|
-
|
|
1959
|
-
return _frame;
|
|
1960
|
-
}
|
|
1961
|
-
} while (s >= 1 && c >= 0);
|
|
1962
|
-
}
|
|
1963
|
-
|
|
1964
|
-
break;
|
|
1965
|
-
}
|
|
1966
|
-
}
|
|
1967
|
-
}
|
|
466
|
+
var returnValue = scope(),
|
|
467
|
+
onStartTransitionFinish = ReactSharedInternals.S;
|
|
468
|
+
null !== onStartTransitionFinish &&
|
|
469
|
+
onStartTransitionFinish(currentTransition, returnValue);
|
|
470
|
+
"object" === typeof returnValue &&
|
|
471
|
+
null !== returnValue &&
|
|
472
|
+
"function" === typeof returnValue.then &&
|
|
473
|
+
returnValue.then(noop, reportGlobalError);
|
|
474
|
+
} catch (error) {
|
|
475
|
+
reportGlobalError(error);
|
|
1968
476
|
} finally {
|
|
1969
|
-
|
|
1970
|
-
|
|
1971
|
-
{
|
|
1972
|
-
ReactCurrentDispatcher$1.current = previousDispatcher;
|
|
1973
|
-
reenableLogs();
|
|
1974
|
-
}
|
|
1975
|
-
|
|
1976
|
-
Error.prepareStackTrace = previousPrepareStackTrace;
|
|
1977
|
-
} // Fallback to just using the name if we couldn't make it throw.
|
|
1978
|
-
|
|
1979
|
-
|
|
1980
|
-
var name = fn ? fn.displayName || fn.name : '';
|
|
1981
|
-
var syntheticFrame = name ? describeBuiltInComponentFrame(name) : '';
|
|
1982
|
-
|
|
1983
|
-
{
|
|
1984
|
-
if (typeof fn === 'function') {
|
|
1985
|
-
componentFrameCache.set(fn, syntheticFrame);
|
|
1986
|
-
}
|
|
1987
|
-
}
|
|
1988
|
-
|
|
1989
|
-
return syntheticFrame;
|
|
1990
|
-
}
|
|
1991
|
-
function describeFunctionComponentFrame(fn, source, ownerFn) {
|
|
1992
|
-
{
|
|
1993
|
-
return describeNativeComponentFrame(fn, false);
|
|
1994
|
-
}
|
|
1995
|
-
}
|
|
1996
|
-
|
|
1997
|
-
function shouldConstruct(Component) {
|
|
1998
|
-
var prototype = Component.prototype;
|
|
1999
|
-
return !!(prototype && prototype.isReactComponent);
|
|
2000
|
-
}
|
|
2001
|
-
|
|
2002
|
-
function describeUnknownElementTypeFrameInDEV(type, source, ownerFn) {
|
|
2003
|
-
|
|
2004
|
-
if (type == null) {
|
|
2005
|
-
return '';
|
|
2006
|
-
}
|
|
2007
|
-
|
|
2008
|
-
if (typeof type === 'function') {
|
|
2009
|
-
{
|
|
2010
|
-
return describeNativeComponentFrame(type, shouldConstruct(type));
|
|
2011
|
-
}
|
|
2012
|
-
}
|
|
2013
|
-
|
|
2014
|
-
if (typeof type === 'string') {
|
|
2015
|
-
return describeBuiltInComponentFrame(type);
|
|
2016
|
-
}
|
|
2017
|
-
|
|
2018
|
-
switch (type) {
|
|
2019
|
-
case REACT_SUSPENSE_TYPE:
|
|
2020
|
-
return describeBuiltInComponentFrame('Suspense');
|
|
2021
|
-
|
|
2022
|
-
case REACT_SUSPENSE_LIST_TYPE:
|
|
2023
|
-
return describeBuiltInComponentFrame('SuspenseList');
|
|
2024
|
-
}
|
|
2025
|
-
|
|
2026
|
-
if (typeof type === 'object') {
|
|
2027
|
-
switch (type.$$typeof) {
|
|
2028
|
-
case REACT_FORWARD_REF_TYPE:
|
|
2029
|
-
return describeFunctionComponentFrame(type.render);
|
|
2030
|
-
|
|
2031
|
-
case REACT_MEMO_TYPE:
|
|
2032
|
-
// Memo may contain any component type so we recursively resolve it.
|
|
2033
|
-
return describeUnknownElementTypeFrameInDEV(type.type, source, ownerFn);
|
|
2034
|
-
|
|
2035
|
-
case REACT_LAZY_TYPE:
|
|
2036
|
-
{
|
|
2037
|
-
var lazyComponent = type;
|
|
2038
|
-
var payload = lazyComponent._payload;
|
|
2039
|
-
var init = lazyComponent._init;
|
|
2040
|
-
|
|
2041
|
-
try {
|
|
2042
|
-
// Lazy may contain any component type so we recursively resolve it.
|
|
2043
|
-
return describeUnknownElementTypeFrameInDEV(init(payload), source, ownerFn);
|
|
2044
|
-
} catch (x) {}
|
|
2045
|
-
}
|
|
2046
|
-
}
|
|
2047
|
-
}
|
|
2048
|
-
|
|
2049
|
-
return '';
|
|
2050
|
-
}
|
|
2051
|
-
|
|
2052
|
-
var loggedTypeFailures = {};
|
|
2053
|
-
var ReactDebugCurrentFrame$1 = ReactSharedInternals.ReactDebugCurrentFrame;
|
|
2054
|
-
|
|
2055
|
-
function setCurrentlyValidatingElement(element) {
|
|
2056
|
-
{
|
|
2057
|
-
if (element) {
|
|
2058
|
-
var owner = element._owner;
|
|
2059
|
-
var stack = describeUnknownElementTypeFrameInDEV(element.type, element._source, owner ? owner.type : null);
|
|
2060
|
-
ReactDebugCurrentFrame$1.setExtraStackFrame(stack);
|
|
2061
|
-
} else {
|
|
2062
|
-
ReactDebugCurrentFrame$1.setExtraStackFrame(null);
|
|
2063
|
-
}
|
|
2064
|
-
}
|
|
2065
|
-
}
|
|
2066
|
-
|
|
2067
|
-
function checkPropTypes(typeSpecs, values, location, componentName, element) {
|
|
2068
|
-
{
|
|
2069
|
-
// $FlowFixMe This is okay but Flow doesn't know it.
|
|
2070
|
-
var has = Function.call.bind(hasOwnProperty);
|
|
2071
|
-
|
|
2072
|
-
for (var typeSpecName in typeSpecs) {
|
|
2073
|
-
if (has(typeSpecs, typeSpecName)) {
|
|
2074
|
-
var error$1 = void 0; // Prop type validation may throw. In case they do, we don't want to
|
|
2075
|
-
// fail the render phase where it didn't fail before. So we log it.
|
|
2076
|
-
// After these have been cleaned up, we'll let them throw.
|
|
2077
|
-
|
|
2078
|
-
try {
|
|
2079
|
-
// This is intentionally an invariant that gets caught. It's the same
|
|
2080
|
-
// behavior as without this statement except with a better message.
|
|
2081
|
-
if (typeof typeSpecs[typeSpecName] !== 'function') {
|
|
2082
|
-
// eslint-disable-next-line react-internal/prod-error-codes
|
|
2083
|
-
var err = Error((componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' + 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' + 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.');
|
|
2084
|
-
err.name = 'Invariant Violation';
|
|
2085
|
-
throw err;
|
|
2086
|
-
}
|
|
2087
|
-
|
|
2088
|
-
error$1 = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED');
|
|
2089
|
-
} catch (ex) {
|
|
2090
|
-
error$1 = ex;
|
|
2091
|
-
}
|
|
2092
|
-
|
|
2093
|
-
if (error$1 && !(error$1 instanceof Error)) {
|
|
2094
|
-
setCurrentlyValidatingElement(element);
|
|
2095
|
-
|
|
2096
|
-
error('%s: type specification of %s' + ' `%s` is invalid; the type checker ' + 'function must return `null` or an `Error` but returned a %s. ' + 'You may have forgotten to pass an argument to the type checker ' + 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' + 'shape all require an argument).', componentName || 'React class', location, typeSpecName, typeof error$1);
|
|
2097
|
-
|
|
2098
|
-
setCurrentlyValidatingElement(null);
|
|
2099
|
-
}
|
|
2100
|
-
|
|
2101
|
-
if (error$1 instanceof Error && !(error$1.message in loggedTypeFailures)) {
|
|
2102
|
-
// Only monitor this failure once because there tends to be a lot of the
|
|
2103
|
-
// same error.
|
|
2104
|
-
loggedTypeFailures[error$1.message] = true;
|
|
2105
|
-
setCurrentlyValidatingElement(element);
|
|
2106
|
-
|
|
2107
|
-
error('Failed %s type: %s', location, error$1.message);
|
|
2108
|
-
|
|
2109
|
-
setCurrentlyValidatingElement(null);
|
|
2110
|
-
}
|
|
2111
|
-
}
|
|
2112
|
-
}
|
|
2113
|
-
}
|
|
2114
|
-
}
|
|
2115
|
-
|
|
2116
|
-
function setCurrentlyValidatingElement$1(element) {
|
|
2117
|
-
{
|
|
2118
|
-
if (element) {
|
|
2119
|
-
var owner = element._owner;
|
|
2120
|
-
var stack = describeUnknownElementTypeFrameInDEV(element.type, element._source, owner ? owner.type : null);
|
|
2121
|
-
setExtraStackFrame(stack);
|
|
2122
|
-
} else {
|
|
2123
|
-
setExtraStackFrame(null);
|
|
2124
|
-
}
|
|
477
|
+
ReactSharedInternals.T = prevTransition;
|
|
2125
478
|
}
|
|
2126
|
-
}
|
|
2127
|
-
|
|
2128
|
-
|
|
2129
|
-
|
|
2130
|
-
{
|
|
2131
|
-
|
|
2132
|
-
}
|
|
2133
|
-
|
|
2134
|
-
|
|
2135
|
-
|
|
2136
|
-
|
|
2137
|
-
|
|
2138
|
-
|
|
2139
|
-
|
|
2140
|
-
|
|
2141
|
-
|
|
2142
|
-
|
|
2143
|
-
|
|
2144
|
-
|
|
2145
|
-
|
|
2146
|
-
function
|
|
2147
|
-
|
|
2148
|
-
|
|
2149
|
-
|
|
2150
|
-
|
|
2151
|
-
|
|
2152
|
-
|
|
2153
|
-
|
|
2154
|
-
|
|
2155
|
-
|
|
2156
|
-
|
|
2157
|
-
|
|
2158
|
-
|
|
2159
|
-
|
|
2160
|
-
|
|
2161
|
-
return
|
|
2162
|
-
}
|
|
2163
|
-
|
|
2164
|
-
|
|
2165
|
-
|
|
2166
|
-
|
|
2167
|
-
|
|
2168
|
-
|
|
2169
|
-
|
|
2170
|
-
|
|
2171
|
-
|
|
2172
|
-
function
|
|
2173
|
-
|
|
2174
|
-
|
|
2175
|
-
|
|
2176
|
-
|
|
2177
|
-
|
|
2178
|
-
|
|
2179
|
-
|
|
2180
|
-
|
|
2181
|
-
|
|
2182
|
-
|
|
2183
|
-
|
|
2184
|
-
|
|
2185
|
-
|
|
2186
|
-
|
|
2187
|
-
|
|
2188
|
-
|
|
2189
|
-
|
|
2190
|
-
|
|
2191
|
-
|
|
2192
|
-
|
|
2193
|
-
|
|
2194
|
-
|
|
2195
|
-
|
|
2196
|
-
|
|
2197
|
-
|
|
2198
|
-
function validateExplicitKey(element, parentType) {
|
|
2199
|
-
if (!element._store || element._store.validated || element.key != null) {
|
|
2200
|
-
return;
|
|
2201
|
-
}
|
|
2202
|
-
|
|
2203
|
-
element._store.validated = true;
|
|
2204
|
-
var currentComponentErrorInfo = getCurrentComponentErrorInfo(parentType);
|
|
2205
|
-
|
|
2206
|
-
if (ownerHasKeyUseWarning[currentComponentErrorInfo]) {
|
|
2207
|
-
return;
|
|
2208
|
-
}
|
|
2209
|
-
|
|
2210
|
-
ownerHasKeyUseWarning[currentComponentErrorInfo] = true; // Usually the current owner is the offender, but if it accepts children as a
|
|
2211
|
-
// property, it may be the creator of the child that's responsible for
|
|
2212
|
-
// assigning it a key.
|
|
2213
|
-
|
|
2214
|
-
var childOwner = '';
|
|
2215
|
-
|
|
2216
|
-
if (element && element._owner && element._owner !== ReactCurrentOwner.current) {
|
|
2217
|
-
// Give the component that originally created this child.
|
|
2218
|
-
childOwner = " It was passed a child from " + getComponentNameFromType(element._owner.type) + ".";
|
|
2219
|
-
}
|
|
2220
|
-
|
|
2221
|
-
{
|
|
2222
|
-
setCurrentlyValidatingElement$1(element);
|
|
2223
|
-
|
|
2224
|
-
error('Each child in a list should have a unique "key" prop.' + '%s%s See https://reactjs.org/link/warning-keys for more information.', currentComponentErrorInfo, childOwner);
|
|
2225
|
-
|
|
2226
|
-
setCurrentlyValidatingElement$1(null);
|
|
2227
|
-
}
|
|
2228
|
-
}
|
|
2229
|
-
/**
|
|
2230
|
-
* Ensure that every element either is passed in a static location, in an
|
|
2231
|
-
* array with an explicit keys property defined, or in an object literal
|
|
2232
|
-
* with valid key property.
|
|
2233
|
-
*
|
|
2234
|
-
* @internal
|
|
2235
|
-
* @param {ReactNode} node Statically passed child of any type.
|
|
2236
|
-
* @param {*} parentType node's parent's type.
|
|
2237
|
-
*/
|
|
2238
|
-
|
|
2239
|
-
|
|
2240
|
-
function validateChildKeys(node, parentType) {
|
|
2241
|
-
if (typeof node !== 'object') {
|
|
2242
|
-
return;
|
|
2243
|
-
}
|
|
2244
|
-
|
|
2245
|
-
if (isArray(node)) {
|
|
2246
|
-
for (var i = 0; i < node.length; i++) {
|
|
2247
|
-
var child = node[i];
|
|
2248
|
-
|
|
2249
|
-
if (isValidElement(child)) {
|
|
2250
|
-
validateExplicitKey(child, parentType);
|
|
2251
|
-
}
|
|
2252
|
-
}
|
|
2253
|
-
} else if (isValidElement(node)) {
|
|
2254
|
-
// This element was passed in a valid location.
|
|
2255
|
-
if (node._store) {
|
|
2256
|
-
node._store.validated = true;
|
|
2257
|
-
}
|
|
2258
|
-
} else if (node) {
|
|
2259
|
-
var iteratorFn = getIteratorFn(node);
|
|
2260
|
-
|
|
2261
|
-
if (typeof iteratorFn === 'function') {
|
|
2262
|
-
// Entry iterators used to provide implicit keys,
|
|
2263
|
-
// but now we print a separate warning for them later.
|
|
2264
|
-
if (iteratorFn !== node.entries) {
|
|
2265
|
-
var iterator = iteratorFn.call(node);
|
|
2266
|
-
var step;
|
|
2267
|
-
|
|
2268
|
-
while (!(step = iterator.next()).done) {
|
|
2269
|
-
if (isValidElement(step.value)) {
|
|
2270
|
-
validateExplicitKey(step.value, parentType);
|
|
2271
|
-
}
|
|
2272
|
-
}
|
|
2273
|
-
}
|
|
2274
|
-
}
|
|
2275
|
-
}
|
|
2276
|
-
}
|
|
2277
|
-
/**
|
|
2278
|
-
* Given an element, validate that its props follow the propTypes definition,
|
|
2279
|
-
* provided by the type.
|
|
2280
|
-
*
|
|
2281
|
-
* @param {ReactElement} element
|
|
2282
|
-
*/
|
|
2283
|
-
|
|
2284
|
-
|
|
2285
|
-
function validatePropTypes(element) {
|
|
2286
|
-
{
|
|
2287
|
-
var type = element.type;
|
|
2288
|
-
|
|
2289
|
-
if (type === null || type === undefined || typeof type === 'string') {
|
|
2290
|
-
return;
|
|
2291
|
-
}
|
|
2292
|
-
|
|
2293
|
-
var propTypes;
|
|
2294
|
-
|
|
2295
|
-
if (typeof type === 'function') {
|
|
2296
|
-
propTypes = type.propTypes;
|
|
2297
|
-
} else if (typeof type === 'object' && (type.$$typeof === REACT_FORWARD_REF_TYPE || // Note: Memo only checks outer props here.
|
|
2298
|
-
// Inner props are checked in the reconciler.
|
|
2299
|
-
type.$$typeof === REACT_MEMO_TYPE)) {
|
|
2300
|
-
propTypes = type.propTypes;
|
|
2301
|
-
} else {
|
|
2302
|
-
return;
|
|
2303
|
-
}
|
|
2304
|
-
|
|
2305
|
-
if (propTypes) {
|
|
2306
|
-
// Intentionally inside to avoid triggering lazy initializers:
|
|
2307
|
-
var name = getComponentNameFromType(type);
|
|
2308
|
-
checkPropTypes(propTypes, element.props, 'prop', name, element);
|
|
2309
|
-
} else if (type.PropTypes !== undefined && !propTypesMisspellWarningShown) {
|
|
2310
|
-
propTypesMisspellWarningShown = true; // Intentionally inside to avoid triggering lazy initializers:
|
|
2311
|
-
|
|
2312
|
-
var _name = getComponentNameFromType(type);
|
|
479
|
+
};
|
|
480
|
+
react_production.unstable_useCacheRefresh = function () {
|
|
481
|
+
return ReactSharedInternals.H.useCacheRefresh();
|
|
482
|
+
};
|
|
483
|
+
react_production.use = function (usable) {
|
|
484
|
+
return ReactSharedInternals.H.use(usable);
|
|
485
|
+
};
|
|
486
|
+
react_production.useActionState = function (action, initialState, permalink) {
|
|
487
|
+
return ReactSharedInternals.H.useActionState(action, initialState, permalink);
|
|
488
|
+
};
|
|
489
|
+
react_production.useCallback = function (callback, deps) {
|
|
490
|
+
return ReactSharedInternals.H.useCallback(callback, deps);
|
|
491
|
+
};
|
|
492
|
+
react_production.useContext = function (Context) {
|
|
493
|
+
return ReactSharedInternals.H.useContext(Context);
|
|
494
|
+
};
|
|
495
|
+
react_production.useDebugValue = function () {};
|
|
496
|
+
react_production.useDeferredValue = function (value, initialValue) {
|
|
497
|
+
return ReactSharedInternals.H.useDeferredValue(value, initialValue);
|
|
498
|
+
};
|
|
499
|
+
react_production.useEffect = function (create, createDeps, update) {
|
|
500
|
+
var dispatcher = ReactSharedInternals.H;
|
|
501
|
+
if ("function" === typeof update)
|
|
502
|
+
throw Error(
|
|
503
|
+
"useEffect CRUD overload is not enabled in this build of React."
|
|
504
|
+
);
|
|
505
|
+
return dispatcher.useEffect(create, createDeps);
|
|
506
|
+
};
|
|
507
|
+
react_production.useId = function () {
|
|
508
|
+
return ReactSharedInternals.H.useId();
|
|
509
|
+
};
|
|
510
|
+
react_production.useImperativeHandle = function (ref, create, deps) {
|
|
511
|
+
return ReactSharedInternals.H.useImperativeHandle(ref, create, deps);
|
|
512
|
+
};
|
|
513
|
+
react_production.useInsertionEffect = function (create, deps) {
|
|
514
|
+
return ReactSharedInternals.H.useInsertionEffect(create, deps);
|
|
515
|
+
};
|
|
516
|
+
react_production.useLayoutEffect = function (create, deps) {
|
|
517
|
+
return ReactSharedInternals.H.useLayoutEffect(create, deps);
|
|
518
|
+
};
|
|
519
|
+
react_production.useMemo = function (create, deps) {
|
|
520
|
+
return ReactSharedInternals.H.useMemo(create, deps);
|
|
521
|
+
};
|
|
522
|
+
react_production.useOptimistic = function (passthrough, reducer) {
|
|
523
|
+
return ReactSharedInternals.H.useOptimistic(passthrough, reducer);
|
|
524
|
+
};
|
|
525
|
+
react_production.useReducer = function (reducer, initialArg, init) {
|
|
526
|
+
return ReactSharedInternals.H.useReducer(reducer, initialArg, init);
|
|
527
|
+
};
|
|
528
|
+
react_production.useRef = function (initialValue) {
|
|
529
|
+
return ReactSharedInternals.H.useRef(initialValue);
|
|
530
|
+
};
|
|
531
|
+
react_production.useState = function (initialState) {
|
|
532
|
+
return ReactSharedInternals.H.useState(initialState);
|
|
533
|
+
};
|
|
534
|
+
react_production.useSyncExternalStore = function (
|
|
535
|
+
subscribe,
|
|
536
|
+
getSnapshot,
|
|
537
|
+
getServerSnapshot
|
|
538
|
+
) {
|
|
539
|
+
return ReactSharedInternals.H.useSyncExternalStore(
|
|
540
|
+
subscribe,
|
|
541
|
+
getSnapshot,
|
|
542
|
+
getServerSnapshot
|
|
543
|
+
);
|
|
544
|
+
};
|
|
545
|
+
react_production.useTransition = function () {
|
|
546
|
+
return ReactSharedInternals.H.useTransition();
|
|
547
|
+
};
|
|
548
|
+
react_production.version = "19.1.0";
|
|
2313
549
|
|
|
2314
|
-
|
|
2315
|
-
}
|
|
550
|
+
var react_development = {exports: {}};
|
|
2316
551
|
|
|
2317
|
-
if (typeof type.getDefaultProps === 'function' && !type.getDefaultProps.isReactClassApproved) {
|
|
2318
|
-
error('getDefaultProps is only used on classic React.createClass ' + 'definitions. Use a static property named `defaultProps` instead.');
|
|
2319
|
-
}
|
|
2320
|
-
}
|
|
2321
|
-
}
|
|
2322
552
|
/**
|
|
2323
|
-
*
|
|
2324
|
-
*
|
|
553
|
+
* @license React
|
|
554
|
+
* react.development.js
|
|
555
|
+
*
|
|
556
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
557
|
+
*
|
|
558
|
+
* This source code is licensed under the MIT license found in the
|
|
559
|
+
* LICENSE file in the root directory of this source tree.
|
|
2325
560
|
*/
|
|
2326
561
|
|
|
2327
|
-
|
|
2328
|
-
|
|
2329
|
-
{
|
|
2330
|
-
|
|
2331
|
-
|
|
2332
|
-
|
|
2333
|
-
|
|
2334
|
-
|
|
2335
|
-
|
|
2336
|
-
|
|
2337
|
-
|
|
2338
|
-
|
|
2339
|
-
|
|
2340
|
-
setCurrentlyValidatingElement$1(null);
|
|
2341
|
-
break;
|
|
2342
|
-
}
|
|
2343
|
-
}
|
|
2344
|
-
|
|
2345
|
-
if (fragment.ref !== null) {
|
|
2346
|
-
setCurrentlyValidatingElement$1(fragment);
|
|
2347
|
-
|
|
2348
|
-
error('Invalid attribute `ref` supplied to `React.Fragment`.');
|
|
2349
|
-
|
|
2350
|
-
setCurrentlyValidatingElement$1(null);
|
|
2351
|
-
}
|
|
2352
|
-
}
|
|
2353
|
-
}
|
|
2354
|
-
function createElementWithValidation(type, props, children) {
|
|
2355
|
-
var validType = isValidElementType(type); // We warn in this case but don't throw. We expect the element creation to
|
|
2356
|
-
// succeed and there will likely be errors in render.
|
|
2357
|
-
|
|
2358
|
-
if (!validType) {
|
|
2359
|
-
var info = '';
|
|
2360
|
-
|
|
2361
|
-
if (type === undefined || typeof type === 'object' && type !== null && Object.keys(type).length === 0) {
|
|
2362
|
-
info += ' You likely forgot to export your component from the file ' + "it's defined in, or you might have mixed up default and named imports.";
|
|
562
|
+
(function (module, exports) {
|
|
563
|
+
"production" !== process.env.NODE_ENV &&
|
|
564
|
+
(function () {
|
|
565
|
+
function defineDeprecationWarning(methodName, info) {
|
|
566
|
+
Object.defineProperty(Component.prototype, methodName, {
|
|
567
|
+
get: function () {
|
|
568
|
+
console.warn(
|
|
569
|
+
"%s(...) is deprecated in plain JavaScript React classes. %s",
|
|
570
|
+
info[0],
|
|
571
|
+
info[1]
|
|
572
|
+
);
|
|
573
|
+
}
|
|
574
|
+
});
|
|
2363
575
|
}
|
|
2364
|
-
|
|
2365
|
-
|
|
2366
|
-
|
|
2367
|
-
|
|
2368
|
-
|
|
2369
|
-
|
|
2370
|
-
|
|
576
|
+
function getIteratorFn(maybeIterable) {
|
|
577
|
+
if (null === maybeIterable || "object" !== typeof maybeIterable)
|
|
578
|
+
return null;
|
|
579
|
+
maybeIterable =
|
|
580
|
+
(MAYBE_ITERATOR_SYMBOL && maybeIterable[MAYBE_ITERATOR_SYMBOL]) ||
|
|
581
|
+
maybeIterable["@@iterator"];
|
|
582
|
+
return "function" === typeof maybeIterable ? maybeIterable : null;
|
|
583
|
+
}
|
|
584
|
+
function warnNoop(publicInstance, callerName) {
|
|
585
|
+
publicInstance =
|
|
586
|
+
((publicInstance = publicInstance.constructor) &&
|
|
587
|
+
(publicInstance.displayName || publicInstance.name)) ||
|
|
588
|
+
"ReactClass";
|
|
589
|
+
var warningKey = publicInstance + "." + callerName;
|
|
590
|
+
didWarnStateUpdateForUnmountedComponent[warningKey] ||
|
|
591
|
+
(console.error(
|
|
592
|
+
"Can't call %s on a component that is not yet mounted. This is a no-op, but it might indicate a bug in your application. Instead, assign to `this.state` directly or define a `state = {};` class property with the desired state in the %s component.",
|
|
593
|
+
callerName,
|
|
594
|
+
publicInstance
|
|
595
|
+
),
|
|
596
|
+
(didWarnStateUpdateForUnmountedComponent[warningKey] = !0));
|
|
597
|
+
}
|
|
598
|
+
function Component(props, context, updater) {
|
|
599
|
+
this.props = props;
|
|
600
|
+
this.context = context;
|
|
601
|
+
this.refs = emptyObject;
|
|
602
|
+
this.updater = updater || ReactNoopUpdateQueue;
|
|
603
|
+
}
|
|
604
|
+
function ComponentDummy() {}
|
|
605
|
+
function PureComponent(props, context, updater) {
|
|
606
|
+
this.props = props;
|
|
607
|
+
this.context = context;
|
|
608
|
+
this.refs = emptyObject;
|
|
609
|
+
this.updater = updater || ReactNoopUpdateQueue;
|
|
610
|
+
}
|
|
611
|
+
function testStringCoercion(value) {
|
|
612
|
+
return "" + value;
|
|
613
|
+
}
|
|
614
|
+
function checkKeyStringCoercion(value) {
|
|
615
|
+
try {
|
|
616
|
+
testStringCoercion(value);
|
|
617
|
+
var JSCompiler_inline_result = !1;
|
|
618
|
+
} catch (e) {
|
|
619
|
+
JSCompiler_inline_result = !0;
|
|
620
|
+
}
|
|
621
|
+
if (JSCompiler_inline_result) {
|
|
622
|
+
JSCompiler_inline_result = console;
|
|
623
|
+
var JSCompiler_temp_const = JSCompiler_inline_result.error;
|
|
624
|
+
var JSCompiler_inline_result$jscomp$0 =
|
|
625
|
+
("function" === typeof Symbol &&
|
|
626
|
+
Symbol.toStringTag &&
|
|
627
|
+
value[Symbol.toStringTag]) ||
|
|
628
|
+
value.constructor.name ||
|
|
629
|
+
"Object";
|
|
630
|
+
JSCompiler_temp_const.call(
|
|
631
|
+
JSCompiler_inline_result,
|
|
632
|
+
"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",
|
|
633
|
+
JSCompiler_inline_result$jscomp$0
|
|
634
|
+
);
|
|
635
|
+
return testStringCoercion(value);
|
|
636
|
+
}
|
|
2371
637
|
}
|
|
2372
|
-
|
|
2373
|
-
|
|
2374
|
-
|
|
2375
|
-
|
|
2376
|
-
|
|
2377
|
-
|
|
2378
|
-
|
|
2379
|
-
|
|
2380
|
-
|
|
2381
|
-
|
|
2382
|
-
|
|
2383
|
-
|
|
638
|
+
function getComponentNameFromType(type) {
|
|
639
|
+
if (null == type) return null;
|
|
640
|
+
if ("function" === typeof type)
|
|
641
|
+
return type.$$typeof === REACT_CLIENT_REFERENCE
|
|
642
|
+
? null
|
|
643
|
+
: type.displayName || type.name || null;
|
|
644
|
+
if ("string" === typeof type) return type;
|
|
645
|
+
switch (type) {
|
|
646
|
+
case REACT_FRAGMENT_TYPE:
|
|
647
|
+
return "Fragment";
|
|
648
|
+
case REACT_PROFILER_TYPE:
|
|
649
|
+
return "Profiler";
|
|
650
|
+
case REACT_STRICT_MODE_TYPE:
|
|
651
|
+
return "StrictMode";
|
|
652
|
+
case REACT_SUSPENSE_TYPE:
|
|
653
|
+
return "Suspense";
|
|
654
|
+
case REACT_SUSPENSE_LIST_TYPE:
|
|
655
|
+
return "SuspenseList";
|
|
656
|
+
case REACT_ACTIVITY_TYPE:
|
|
657
|
+
return "Activity";
|
|
658
|
+
}
|
|
659
|
+
if ("object" === typeof type)
|
|
660
|
+
switch (
|
|
661
|
+
("number" === typeof type.tag &&
|
|
662
|
+
console.error(
|
|
663
|
+
"Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."
|
|
664
|
+
),
|
|
665
|
+
type.$$typeof)
|
|
666
|
+
) {
|
|
667
|
+
case REACT_PORTAL_TYPE:
|
|
668
|
+
return "Portal";
|
|
669
|
+
case REACT_CONTEXT_TYPE:
|
|
670
|
+
return (type.displayName || "Context") + ".Provider";
|
|
671
|
+
case REACT_CONSUMER_TYPE:
|
|
672
|
+
return (type._context.displayName || "Context") + ".Consumer";
|
|
673
|
+
case REACT_FORWARD_REF_TYPE:
|
|
674
|
+
var innerType = type.render;
|
|
675
|
+
type = type.displayName;
|
|
676
|
+
type ||
|
|
677
|
+
((type = innerType.displayName || innerType.name || ""),
|
|
678
|
+
(type = "" !== type ? "ForwardRef(" + type + ")" : "ForwardRef"));
|
|
679
|
+
return type;
|
|
680
|
+
case REACT_MEMO_TYPE:
|
|
681
|
+
return (
|
|
682
|
+
(innerType = type.displayName || null),
|
|
683
|
+
null !== innerType
|
|
684
|
+
? innerType
|
|
685
|
+
: getComponentNameFromType(type.type) || "Memo"
|
|
686
|
+
);
|
|
687
|
+
case REACT_LAZY_TYPE:
|
|
688
|
+
innerType = type._payload;
|
|
689
|
+
type = type._init;
|
|
690
|
+
try {
|
|
691
|
+
return getComponentNameFromType(type(innerType));
|
|
692
|
+
} catch (x) {}
|
|
693
|
+
}
|
|
694
|
+
return null;
|
|
695
|
+
}
|
|
696
|
+
function getTaskName(type) {
|
|
697
|
+
if (type === REACT_FRAGMENT_TYPE) return "<>";
|
|
698
|
+
if (
|
|
699
|
+
"object" === typeof type &&
|
|
700
|
+
null !== type &&
|
|
701
|
+
type.$$typeof === REACT_LAZY_TYPE
|
|
702
|
+
)
|
|
703
|
+
return "<...>";
|
|
704
|
+
try {
|
|
705
|
+
var name = getComponentNameFromType(type);
|
|
706
|
+
return name ? "<" + name + ">" : "<...>";
|
|
707
|
+
} catch (x) {
|
|
708
|
+
return "<...>";
|
|
709
|
+
}
|
|
2384
710
|
}
|
|
2385
|
-
|
|
2386
|
-
|
|
2387
|
-
|
|
711
|
+
function getOwner() {
|
|
712
|
+
var dispatcher = ReactSharedInternals.A;
|
|
713
|
+
return null === dispatcher ? null : dispatcher.getOwner();
|
|
2388
714
|
}
|
|
2389
|
-
|
|
2390
|
-
|
|
2391
|
-
var element = createElement.apply(this, arguments); // The result can be nullish if a mock or a custom function is used.
|
|
2392
|
-
// TODO: Drop this when these are no longer allowed as the type argument.
|
|
2393
|
-
|
|
2394
|
-
if (element == null) {
|
|
2395
|
-
return element;
|
|
2396
|
-
} // Skip key warning if the type isn't valid since our key validation logic
|
|
2397
|
-
// doesn't expect a non-string/function type and can throw confusing errors.
|
|
2398
|
-
// We don't want exception behavior to differ between dev and prod.
|
|
2399
|
-
// (Rendering will throw with a helpful message and as soon as the type is
|
|
2400
|
-
// fixed, the key warnings will appear.)
|
|
2401
|
-
|
|
2402
|
-
|
|
2403
|
-
if (validType) {
|
|
2404
|
-
for (var i = 2; i < arguments.length; i++) {
|
|
2405
|
-
validateChildKeys(arguments[i], type);
|
|
715
|
+
function UnknownOwner() {
|
|
716
|
+
return Error("react-stack-top-frame");
|
|
2406
717
|
}
|
|
2407
|
-
|
|
2408
|
-
|
|
2409
|
-
|
|
2410
|
-
|
|
2411
|
-
} else {
|
|
2412
|
-
validatePropTypes(element);
|
|
2413
|
-
}
|
|
2414
|
-
|
|
2415
|
-
return element;
|
|
2416
|
-
}
|
|
2417
|
-
var didWarnAboutDeprecatedCreateFactory = false;
|
|
2418
|
-
function createFactoryWithValidation(type) {
|
|
2419
|
-
var validatedFactory = createElementWithValidation.bind(null, type);
|
|
2420
|
-
validatedFactory.type = type;
|
|
2421
|
-
|
|
2422
|
-
{
|
|
2423
|
-
if (!didWarnAboutDeprecatedCreateFactory) {
|
|
2424
|
-
didWarnAboutDeprecatedCreateFactory = true;
|
|
2425
|
-
|
|
2426
|
-
warn('React.createFactory() is deprecated and will be removed in ' + 'a future major release. Consider using JSX ' + 'or use React.createElement() directly instead.');
|
|
2427
|
-
} // Legacy hook: remove it
|
|
2428
|
-
|
|
2429
|
-
|
|
2430
|
-
Object.defineProperty(validatedFactory, 'type', {
|
|
2431
|
-
enumerable: false,
|
|
2432
|
-
get: function () {
|
|
2433
|
-
warn('Factory.type is deprecated. Access the class directly ' + 'before passing it to createFactory.');
|
|
2434
|
-
|
|
2435
|
-
Object.defineProperty(this, 'type', {
|
|
2436
|
-
value: type
|
|
2437
|
-
});
|
|
2438
|
-
return type;
|
|
718
|
+
function hasValidKey(config) {
|
|
719
|
+
if (hasOwnProperty.call(config, "key")) {
|
|
720
|
+
var getter = Object.getOwnPropertyDescriptor(config, "key").get;
|
|
721
|
+
if (getter && getter.isReactWarning) return !1;
|
|
2439
722
|
}
|
|
2440
|
-
|
|
2441
|
-
|
|
2442
|
-
|
|
2443
|
-
|
|
2444
|
-
|
|
2445
|
-
|
|
2446
|
-
|
|
2447
|
-
|
|
2448
|
-
|
|
2449
|
-
|
|
2450
|
-
}
|
|
2451
|
-
|
|
2452
|
-
validatePropTypes(newElement);
|
|
2453
|
-
return newElement;
|
|
2454
|
-
}
|
|
2455
|
-
|
|
2456
|
-
function startTransition(scope, options) {
|
|
2457
|
-
var prevTransition = ReactCurrentBatchConfig.transition;
|
|
2458
|
-
ReactCurrentBatchConfig.transition = {};
|
|
2459
|
-
var currentTransition = ReactCurrentBatchConfig.transition;
|
|
2460
|
-
|
|
2461
|
-
{
|
|
2462
|
-
ReactCurrentBatchConfig.transition._updatedFibers = new Set();
|
|
2463
|
-
}
|
|
2464
|
-
|
|
2465
|
-
try {
|
|
2466
|
-
scope();
|
|
2467
|
-
} finally {
|
|
2468
|
-
ReactCurrentBatchConfig.transition = prevTransition;
|
|
2469
|
-
|
|
2470
|
-
{
|
|
2471
|
-
if (prevTransition === null && currentTransition._updatedFibers) {
|
|
2472
|
-
var updatedFibersCount = currentTransition._updatedFibers.size;
|
|
2473
|
-
|
|
2474
|
-
if (updatedFibersCount > 10) {
|
|
2475
|
-
warn('Detected a large number of updates inside startTransition. ' + 'If this is due to a subscription please re-write it to use React provided hooks. ' + 'Otherwise concurrent mode guarantees are off the table.');
|
|
2476
|
-
}
|
|
2477
|
-
|
|
2478
|
-
currentTransition._updatedFibers.clear();
|
|
723
|
+
return void 0 !== config.key;
|
|
724
|
+
}
|
|
725
|
+
function defineKeyPropWarningGetter(props, displayName) {
|
|
726
|
+
function warnAboutAccessingKey() {
|
|
727
|
+
specialPropKeyWarningShown ||
|
|
728
|
+
((specialPropKeyWarningShown = !0),
|
|
729
|
+
console.error(
|
|
730
|
+
"%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)",
|
|
731
|
+
displayName
|
|
732
|
+
));
|
|
2479
733
|
}
|
|
734
|
+
warnAboutAccessingKey.isReactWarning = !0;
|
|
735
|
+
Object.defineProperty(props, "key", {
|
|
736
|
+
get: warnAboutAccessingKey,
|
|
737
|
+
configurable: !0
|
|
738
|
+
});
|
|
2480
739
|
}
|
|
2481
|
-
|
|
2482
|
-
|
|
2483
|
-
|
|
2484
|
-
|
|
2485
|
-
|
|
2486
|
-
|
|
2487
|
-
|
|
2488
|
-
|
|
2489
|
-
|
|
2490
|
-
|
|
2491
|
-
|
|
2492
|
-
|
|
2493
|
-
|
|
2494
|
-
|
|
2495
|
-
|
|
2496
|
-
|
|
2497
|
-
|
|
2498
|
-
|
|
2499
|
-
|
|
2500
|
-
|
|
2501
|
-
|
|
2502
|
-
|
|
2503
|
-
|
|
2504
|
-
|
|
2505
|
-
|
|
2506
|
-
|
|
740
|
+
function elementRefGetterWithDeprecationWarning() {
|
|
741
|
+
var componentName = getComponentNameFromType(this.type);
|
|
742
|
+
didWarnAboutElementRef[componentName] ||
|
|
743
|
+
((didWarnAboutElementRef[componentName] = !0),
|
|
744
|
+
console.error(
|
|
745
|
+
"Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release."
|
|
746
|
+
));
|
|
747
|
+
componentName = this.props.ref;
|
|
748
|
+
return void 0 !== componentName ? componentName : null;
|
|
749
|
+
}
|
|
750
|
+
function ReactElement(
|
|
751
|
+
type,
|
|
752
|
+
key,
|
|
753
|
+
self,
|
|
754
|
+
source,
|
|
755
|
+
owner,
|
|
756
|
+
props,
|
|
757
|
+
debugStack,
|
|
758
|
+
debugTask
|
|
759
|
+
) {
|
|
760
|
+
self = props.ref;
|
|
761
|
+
type = {
|
|
762
|
+
$$typeof: REACT_ELEMENT_TYPE,
|
|
763
|
+
type: type,
|
|
764
|
+
key: key,
|
|
765
|
+
props: props,
|
|
766
|
+
_owner: owner
|
|
767
|
+
};
|
|
768
|
+
null !== (void 0 !== self ? self : null)
|
|
769
|
+
? Object.defineProperty(type, "ref", {
|
|
770
|
+
enumerable: !1,
|
|
771
|
+
get: elementRefGetterWithDeprecationWarning
|
|
772
|
+
})
|
|
773
|
+
: Object.defineProperty(type, "ref", { enumerable: !1, value: null });
|
|
774
|
+
type._store = {};
|
|
775
|
+
Object.defineProperty(type._store, "validated", {
|
|
776
|
+
configurable: !1,
|
|
777
|
+
enumerable: !1,
|
|
778
|
+
writable: !0,
|
|
779
|
+
value: 0
|
|
780
|
+
});
|
|
781
|
+
Object.defineProperty(type, "_debugInfo", {
|
|
782
|
+
configurable: !1,
|
|
783
|
+
enumerable: !1,
|
|
784
|
+
writable: !0,
|
|
785
|
+
value: null
|
|
786
|
+
});
|
|
787
|
+
Object.defineProperty(type, "_debugStack", {
|
|
788
|
+
configurable: !1,
|
|
789
|
+
enumerable: !1,
|
|
790
|
+
writable: !0,
|
|
791
|
+
value: debugStack
|
|
792
|
+
});
|
|
793
|
+
Object.defineProperty(type, "_debugTask", {
|
|
794
|
+
configurable: !1,
|
|
795
|
+
enumerable: !1,
|
|
796
|
+
writable: !0,
|
|
797
|
+
value: debugTask
|
|
798
|
+
});
|
|
799
|
+
Object.freeze && (Object.freeze(type.props), Object.freeze(type));
|
|
800
|
+
return type;
|
|
801
|
+
}
|
|
802
|
+
function cloneAndReplaceKey(oldElement, newKey) {
|
|
803
|
+
newKey = ReactElement(
|
|
804
|
+
oldElement.type,
|
|
805
|
+
newKey,
|
|
806
|
+
void 0,
|
|
807
|
+
void 0,
|
|
808
|
+
oldElement._owner,
|
|
809
|
+
oldElement.props,
|
|
810
|
+
oldElement._debugStack,
|
|
811
|
+
oldElement._debugTask
|
|
812
|
+
);
|
|
813
|
+
oldElement._store &&
|
|
814
|
+
(newKey._store.validated = oldElement._store.validated);
|
|
815
|
+
return newKey;
|
|
816
|
+
}
|
|
817
|
+
function isValidElement(object) {
|
|
818
|
+
return (
|
|
819
|
+
"object" === typeof object &&
|
|
820
|
+
null !== object &&
|
|
821
|
+
object.$$typeof === REACT_ELEMENT_TYPE
|
|
822
|
+
);
|
|
823
|
+
}
|
|
824
|
+
function escape(key) {
|
|
825
|
+
var escaperLookup = { "=": "=0", ":": "=2" };
|
|
826
|
+
return (
|
|
827
|
+
"$" +
|
|
828
|
+
key.replace(/[=:]/g, function (match) {
|
|
829
|
+
return escaperLookup[match];
|
|
830
|
+
})
|
|
831
|
+
);
|
|
832
|
+
}
|
|
833
|
+
function getElementKey(element, index) {
|
|
834
|
+
return "object" === typeof element &&
|
|
835
|
+
null !== element &&
|
|
836
|
+
null != element.key
|
|
837
|
+
? (checkKeyStringCoercion(element.key), escape("" + element.key))
|
|
838
|
+
: index.toString(36);
|
|
839
|
+
}
|
|
840
|
+
function noop$1() {}
|
|
841
|
+
function resolveThenable(thenable) {
|
|
842
|
+
switch (thenable.status) {
|
|
843
|
+
case "fulfilled":
|
|
844
|
+
return thenable.value;
|
|
845
|
+
case "rejected":
|
|
846
|
+
throw thenable.reason;
|
|
847
|
+
default:
|
|
848
|
+
switch (
|
|
849
|
+
("string" === typeof thenable.status
|
|
850
|
+
? thenable.then(noop$1, noop$1)
|
|
851
|
+
: ((thenable.status = "pending"),
|
|
852
|
+
thenable.then(
|
|
853
|
+
function (fulfilledValue) {
|
|
854
|
+
"pending" === thenable.status &&
|
|
855
|
+
((thenable.status = "fulfilled"),
|
|
856
|
+
(thenable.value = fulfilledValue));
|
|
857
|
+
},
|
|
858
|
+
function (error) {
|
|
859
|
+
"pending" === thenable.status &&
|
|
860
|
+
((thenable.status = "rejected"),
|
|
861
|
+
(thenable.reason = error));
|
|
862
|
+
}
|
|
863
|
+
)),
|
|
864
|
+
thenable.status)
|
|
865
|
+
) {
|
|
866
|
+
case "fulfilled":
|
|
867
|
+
return thenable.value;
|
|
868
|
+
case "rejected":
|
|
869
|
+
throw thenable.reason;
|
|
870
|
+
}
|
|
871
|
+
}
|
|
872
|
+
throw thenable;
|
|
873
|
+
}
|
|
874
|
+
function mapIntoArray(children, array, escapedPrefix, nameSoFar, callback) {
|
|
875
|
+
var type = typeof children;
|
|
876
|
+
if ("undefined" === type || "boolean" === type) children = null;
|
|
877
|
+
var invokeCallback = !1;
|
|
878
|
+
if (null === children) invokeCallback = !0;
|
|
879
|
+
else
|
|
880
|
+
switch (type) {
|
|
881
|
+
case "bigint":
|
|
882
|
+
case "string":
|
|
883
|
+
case "number":
|
|
884
|
+
invokeCallback = !0;
|
|
885
|
+
break;
|
|
886
|
+
case "object":
|
|
887
|
+
switch (children.$$typeof) {
|
|
888
|
+
case REACT_ELEMENT_TYPE:
|
|
889
|
+
case REACT_PORTAL_TYPE:
|
|
890
|
+
invokeCallback = !0;
|
|
891
|
+
break;
|
|
892
|
+
case REACT_LAZY_TYPE:
|
|
893
|
+
return (
|
|
894
|
+
(invokeCallback = children._init),
|
|
895
|
+
mapIntoArray(
|
|
896
|
+
invokeCallback(children._payload),
|
|
897
|
+
array,
|
|
898
|
+
escapedPrefix,
|
|
899
|
+
nameSoFar,
|
|
900
|
+
callback
|
|
901
|
+
)
|
|
902
|
+
);
|
|
2507
903
|
}
|
|
904
|
+
}
|
|
905
|
+
if (invokeCallback) {
|
|
906
|
+
invokeCallback = children;
|
|
907
|
+
callback = callback(invokeCallback);
|
|
908
|
+
var childKey =
|
|
909
|
+
"" === nameSoFar ? "." + getElementKey(invokeCallback, 0) : nameSoFar;
|
|
910
|
+
isArrayImpl(callback)
|
|
911
|
+
? ((escapedPrefix = ""),
|
|
912
|
+
null != childKey &&
|
|
913
|
+
(escapedPrefix =
|
|
914
|
+
childKey.replace(userProvidedKeyEscapeRegex, "$&/") + "/"),
|
|
915
|
+
mapIntoArray(callback, array, escapedPrefix, "", function (c) {
|
|
916
|
+
return c;
|
|
917
|
+
}))
|
|
918
|
+
: null != callback &&
|
|
919
|
+
(isValidElement(callback) &&
|
|
920
|
+
(null != callback.key &&
|
|
921
|
+
((invokeCallback && invokeCallback.key === callback.key) ||
|
|
922
|
+
checkKeyStringCoercion(callback.key)),
|
|
923
|
+
(escapedPrefix = cloneAndReplaceKey(
|
|
924
|
+
callback,
|
|
925
|
+
escapedPrefix +
|
|
926
|
+
(null == callback.key ||
|
|
927
|
+
(invokeCallback && invokeCallback.key === callback.key)
|
|
928
|
+
? ""
|
|
929
|
+
: ("" + callback.key).replace(
|
|
930
|
+
userProvidedKeyEscapeRegex,
|
|
931
|
+
"$&/"
|
|
932
|
+
) + "/") +
|
|
933
|
+
childKey
|
|
934
|
+
)),
|
|
935
|
+
"" !== nameSoFar &&
|
|
936
|
+
null != invokeCallback &&
|
|
937
|
+
isValidElement(invokeCallback) &&
|
|
938
|
+
null == invokeCallback.key &&
|
|
939
|
+
invokeCallback._store &&
|
|
940
|
+
!invokeCallback._store.validated &&
|
|
941
|
+
(escapedPrefix._store.validated = 2),
|
|
942
|
+
(callback = escapedPrefix)),
|
|
943
|
+
array.push(callback));
|
|
944
|
+
return 1;
|
|
945
|
+
}
|
|
946
|
+
invokeCallback = 0;
|
|
947
|
+
childKey = "" === nameSoFar ? "." : nameSoFar + ":";
|
|
948
|
+
if (isArrayImpl(children))
|
|
949
|
+
for (var i = 0; i < children.length; i++)
|
|
950
|
+
(nameSoFar = children[i]),
|
|
951
|
+
(type = childKey + getElementKey(nameSoFar, i)),
|
|
952
|
+
(invokeCallback += mapIntoArray(
|
|
953
|
+
nameSoFar,
|
|
954
|
+
array,
|
|
955
|
+
escapedPrefix,
|
|
956
|
+
type,
|
|
957
|
+
callback
|
|
958
|
+
));
|
|
959
|
+
else if (((i = getIteratorFn(children)), "function" === typeof i))
|
|
960
|
+
for (
|
|
961
|
+
i === children.entries &&
|
|
962
|
+
(didWarnAboutMaps ||
|
|
963
|
+
console.warn(
|
|
964
|
+
"Using Maps as children is not supported. Use an array of keyed ReactElements instead."
|
|
965
|
+
),
|
|
966
|
+
(didWarnAboutMaps = !0)),
|
|
967
|
+
children = i.call(children),
|
|
968
|
+
i = 0;
|
|
969
|
+
!(nameSoFar = children.next()).done;
|
|
970
|
+
|
|
971
|
+
)
|
|
972
|
+
(nameSoFar = nameSoFar.value),
|
|
973
|
+
(type = childKey + getElementKey(nameSoFar, i++)),
|
|
974
|
+
(invokeCallback += mapIntoArray(
|
|
975
|
+
nameSoFar,
|
|
976
|
+
array,
|
|
977
|
+
escapedPrefix,
|
|
978
|
+
type,
|
|
979
|
+
callback
|
|
980
|
+
));
|
|
981
|
+
else if ("object" === type) {
|
|
982
|
+
if ("function" === typeof children.then)
|
|
983
|
+
return mapIntoArray(
|
|
984
|
+
resolveThenable(children),
|
|
985
|
+
array,
|
|
986
|
+
escapedPrefix,
|
|
987
|
+
nameSoFar,
|
|
988
|
+
callback
|
|
989
|
+
);
|
|
990
|
+
array = String(children);
|
|
991
|
+
throw Error(
|
|
992
|
+
"Objects are not valid as a React child (found: " +
|
|
993
|
+
("[object Object]" === array
|
|
994
|
+
? "object with keys {" + Object.keys(children).join(", ") + "}"
|
|
995
|
+
: array) +
|
|
996
|
+
"). If you meant to render a collection of children, use an array instead."
|
|
997
|
+
);
|
|
998
|
+
}
|
|
999
|
+
return invokeCallback;
|
|
1000
|
+
}
|
|
1001
|
+
function mapChildren(children, func, context) {
|
|
1002
|
+
if (null == children) return children;
|
|
1003
|
+
var result = [],
|
|
1004
|
+
count = 0;
|
|
1005
|
+
mapIntoArray(children, result, "", "", function (child) {
|
|
1006
|
+
return func.call(context, child, count++);
|
|
1007
|
+
});
|
|
1008
|
+
return result;
|
|
1009
|
+
}
|
|
1010
|
+
function lazyInitializer(payload) {
|
|
1011
|
+
if (-1 === payload._status) {
|
|
1012
|
+
var ctor = payload._result;
|
|
1013
|
+
ctor = ctor();
|
|
1014
|
+
ctor.then(
|
|
1015
|
+
function (moduleObject) {
|
|
1016
|
+
if (0 === payload._status || -1 === payload._status)
|
|
1017
|
+
(payload._status = 1), (payload._result = moduleObject);
|
|
1018
|
+
},
|
|
1019
|
+
function (error) {
|
|
1020
|
+
if (0 === payload._status || -1 === payload._status)
|
|
1021
|
+
(payload._status = 2), (payload._result = error);
|
|
2508
1022
|
}
|
|
1023
|
+
);
|
|
1024
|
+
-1 === payload._status &&
|
|
1025
|
+
((payload._status = 0), (payload._result = ctor));
|
|
1026
|
+
}
|
|
1027
|
+
if (1 === payload._status)
|
|
1028
|
+
return (
|
|
1029
|
+
(ctor = payload._result),
|
|
1030
|
+
void 0 === ctor &&
|
|
1031
|
+
console.error(
|
|
1032
|
+
"lazy: Expected the result of a dynamic import() call. Instead received: %s\n\nYour code should look like: \n const MyComponent = lazy(() => import('./MyComponent'))\n\nDid you accidentally put curly braces around the import?",
|
|
1033
|
+
ctor
|
|
1034
|
+
),
|
|
1035
|
+
"default" in ctor ||
|
|
1036
|
+
console.error(
|
|
1037
|
+
"lazy: Expected the result of a dynamic import() call. Instead received: %s\n\nYour code should look like: \n const MyComponent = lazy(() => import('./MyComponent'))",
|
|
1038
|
+
ctor
|
|
1039
|
+
),
|
|
1040
|
+
ctor.default
|
|
1041
|
+
);
|
|
1042
|
+
throw payload._result;
|
|
1043
|
+
}
|
|
1044
|
+
function resolveDispatcher() {
|
|
1045
|
+
var dispatcher = ReactSharedInternals.H;
|
|
1046
|
+
null === dispatcher &&
|
|
1047
|
+
console.error(
|
|
1048
|
+
"Invalid hook call. Hooks can only be called inside of the body of a function component. This could happen for one of the following reasons:\n1. You might have mismatching versions of React and the renderer (such as React DOM)\n2. You might be breaking the Rules of Hooks\n3. You might have more than one copy of React in the same app\nSee https://react.dev/link/invalid-hook-call for tips about how to debug and fix this problem."
|
|
1049
|
+
);
|
|
1050
|
+
return dispatcher;
|
|
1051
|
+
}
|
|
1052
|
+
function noop() {}
|
|
1053
|
+
function enqueueTask(task) {
|
|
1054
|
+
if (null === enqueueTaskImpl)
|
|
1055
|
+
try {
|
|
1056
|
+
var requireString = ("require" + Math.random()).slice(0, 7);
|
|
1057
|
+
enqueueTaskImpl = (module && module[requireString]).call(
|
|
1058
|
+
module,
|
|
1059
|
+
"timers"
|
|
1060
|
+
).setImmediate;
|
|
1061
|
+
} catch (_err) {
|
|
1062
|
+
enqueueTaskImpl = function (callback) {
|
|
1063
|
+
!1 === didWarnAboutMessageChannel &&
|
|
1064
|
+
((didWarnAboutMessageChannel = !0),
|
|
1065
|
+
"undefined" === typeof MessageChannel &&
|
|
1066
|
+
console.error(
|
|
1067
|
+
"This browser does not have a MessageChannel implementation, so enqueuing tasks via await act(async () => ...) will fail. Please file an issue at https://github.com/facebook/react/issues if you encounter this warning."
|
|
1068
|
+
));
|
|
1069
|
+
var channel = new MessageChannel();
|
|
1070
|
+
channel.port1.onmessage = callback;
|
|
1071
|
+
channel.port2.postMessage(void 0);
|
|
1072
|
+
};
|
|
2509
1073
|
}
|
|
2510
|
-
|
|
2511
|
-
|
|
2512
|
-
|
|
2513
|
-
|
|
2514
|
-
|
|
2515
|
-
|
|
2516
|
-
|
|
2517
|
-
|
|
2518
|
-
|
|
2519
|
-
|
|
2520
|
-
|
|
2521
|
-
|
|
2522
|
-
|
|
2523
|
-
|
|
2524
|
-
|
|
2525
|
-
|
|
2526
|
-
|
|
2527
|
-
|
|
2528
|
-
|
|
2529
|
-
|
|
2530
|
-
|
|
2531
|
-
|
|
2532
|
-
|
|
2533
|
-
|
|
2534
|
-
|
|
2535
|
-
|
|
2536
|
-
|
|
2537
|
-
|
|
2538
|
-
|
|
2539
|
-
|
|
2540
|
-
|
|
2541
|
-
|
|
2542
|
-
|
|
2543
|
-
|
|
2544
|
-
|
|
2545
|
-
|
|
2546
|
-
|
|
2547
|
-
|
|
2548
|
-
|
|
2549
|
-
|
|
2550
|
-
|
|
2551
|
-
|
|
2552
|
-
|
|
2553
|
-
|
|
2554
|
-
|
|
1074
|
+
return enqueueTaskImpl(task);
|
|
1075
|
+
}
|
|
1076
|
+
function aggregateErrors(errors) {
|
|
1077
|
+
return 1 < errors.length && "function" === typeof AggregateError
|
|
1078
|
+
? new AggregateError(errors)
|
|
1079
|
+
: errors[0];
|
|
1080
|
+
}
|
|
1081
|
+
function popActScope(prevActQueue, prevActScopeDepth) {
|
|
1082
|
+
prevActScopeDepth !== actScopeDepth - 1 &&
|
|
1083
|
+
console.error(
|
|
1084
|
+
"You seem to have overlapping act() calls, this is not supported. Be sure to await previous act() calls before making a new one. "
|
|
1085
|
+
);
|
|
1086
|
+
actScopeDepth = prevActScopeDepth;
|
|
1087
|
+
}
|
|
1088
|
+
function recursivelyFlushAsyncActWork(returnValue, resolve, reject) {
|
|
1089
|
+
var queue = ReactSharedInternals.actQueue;
|
|
1090
|
+
if (null !== queue)
|
|
1091
|
+
if (0 !== queue.length)
|
|
1092
|
+
try {
|
|
1093
|
+
flushActQueue(queue);
|
|
1094
|
+
enqueueTask(function () {
|
|
1095
|
+
return recursivelyFlushAsyncActWork(returnValue, resolve, reject);
|
|
1096
|
+
});
|
|
1097
|
+
return;
|
|
1098
|
+
} catch (error) {
|
|
1099
|
+
ReactSharedInternals.thrownErrors.push(error);
|
|
1100
|
+
}
|
|
1101
|
+
else ReactSharedInternals.actQueue = null;
|
|
1102
|
+
0 < ReactSharedInternals.thrownErrors.length
|
|
1103
|
+
? ((queue = aggregateErrors(ReactSharedInternals.thrownErrors)),
|
|
1104
|
+
(ReactSharedInternals.thrownErrors.length = 0),
|
|
1105
|
+
reject(queue))
|
|
1106
|
+
: resolve(returnValue);
|
|
1107
|
+
}
|
|
1108
|
+
function flushActQueue(queue) {
|
|
1109
|
+
if (!isFlushing) {
|
|
1110
|
+
isFlushing = !0;
|
|
1111
|
+
var i = 0;
|
|
1112
|
+
try {
|
|
1113
|
+
for (; i < queue.length; i++) {
|
|
1114
|
+
var callback = queue[i];
|
|
1115
|
+
do {
|
|
1116
|
+
ReactSharedInternals.didUsePromise = !1;
|
|
1117
|
+
var continuation = callback(!1);
|
|
1118
|
+
if (null !== continuation) {
|
|
1119
|
+
if (ReactSharedInternals.didUsePromise) {
|
|
1120
|
+
queue[i] = callback;
|
|
1121
|
+
queue.splice(0, i);
|
|
1122
|
+
return;
|
|
1123
|
+
}
|
|
1124
|
+
callback = continuation;
|
|
1125
|
+
} else break;
|
|
1126
|
+
} while (1);
|
|
1127
|
+
}
|
|
1128
|
+
queue.length = 0;
|
|
1129
|
+
} catch (error) {
|
|
1130
|
+
queue.splice(0, i + 1), ReactSharedInternals.thrownErrors.push(error);
|
|
1131
|
+
} finally {
|
|
1132
|
+
isFlushing = !1;
|
|
2555
1133
|
}
|
|
2556
1134
|
}
|
|
2557
|
-
} catch (error) {
|
|
2558
|
-
popActScope(prevActScopeDepth);
|
|
2559
|
-
throw error;
|
|
2560
|
-
} finally {
|
|
2561
|
-
ReactCurrentActQueue.isBatchingLegacy = prevIsBatchingLegacy;
|
|
2562
1135
|
}
|
|
2563
|
-
|
|
2564
|
-
|
|
2565
|
-
|
|
2566
|
-
|
|
2567
|
-
|
|
2568
|
-
|
|
2569
|
-
|
|
2570
|
-
|
|
2571
|
-
|
|
2572
|
-
|
|
2573
|
-
|
|
2574
|
-
|
|
2575
|
-
|
|
2576
|
-
|
|
2577
|
-
|
|
2578
|
-
|
|
2579
|
-
|
|
2580
|
-
|
|
2581
|
-
|
|
2582
|
-
|
|
2583
|
-
|
|
2584
|
-
|
|
2585
|
-
|
|
2586
|
-
|
|
2587
|
-
|
|
2588
|
-
|
|
2589
|
-
|
|
2590
|
-
|
|
2591
|
-
|
|
2592
|
-
|
|
2593
|
-
|
|
2594
|
-
if (!wasAwaited) {
|
|
2595
|
-
didWarnNoAwaitAct = true;
|
|
2596
|
-
|
|
2597
|
-
error('You called act(async () => ...) without await. ' + 'This could lead to unexpected testing behaviour, ' + 'interleaving multiple act calls and mixing their ' + 'scopes. ' + 'You should - await act(async () => ...);');
|
|
2598
|
-
}
|
|
2599
|
-
});
|
|
1136
|
+
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
|
|
1137
|
+
"function" ===
|
|
1138
|
+
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart &&
|
|
1139
|
+
__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());
|
|
1140
|
+
var REACT_ELEMENT_TYPE = Symbol.for("react.transitional.element"),
|
|
1141
|
+
REACT_PORTAL_TYPE = Symbol.for("react.portal"),
|
|
1142
|
+
REACT_FRAGMENT_TYPE = Symbol.for("react.fragment"),
|
|
1143
|
+
REACT_STRICT_MODE_TYPE = Symbol.for("react.strict_mode"),
|
|
1144
|
+
REACT_PROFILER_TYPE = Symbol.for("react.profiler");
|
|
1145
|
+
var REACT_CONSUMER_TYPE = Symbol.for("react.consumer"),
|
|
1146
|
+
REACT_CONTEXT_TYPE = Symbol.for("react.context"),
|
|
1147
|
+
REACT_FORWARD_REF_TYPE = Symbol.for("react.forward_ref"),
|
|
1148
|
+
REACT_SUSPENSE_TYPE = Symbol.for("react.suspense"),
|
|
1149
|
+
REACT_SUSPENSE_LIST_TYPE = Symbol.for("react.suspense_list"),
|
|
1150
|
+
REACT_MEMO_TYPE = Symbol.for("react.memo"),
|
|
1151
|
+
REACT_LAZY_TYPE = Symbol.for("react.lazy"),
|
|
1152
|
+
REACT_ACTIVITY_TYPE = Symbol.for("react.activity"),
|
|
1153
|
+
MAYBE_ITERATOR_SYMBOL = Symbol.iterator,
|
|
1154
|
+
didWarnStateUpdateForUnmountedComponent = {},
|
|
1155
|
+
ReactNoopUpdateQueue = {
|
|
1156
|
+
isMounted: function () {
|
|
1157
|
+
return !1;
|
|
1158
|
+
},
|
|
1159
|
+
enqueueForceUpdate: function (publicInstance) {
|
|
1160
|
+
warnNoop(publicInstance, "forceUpdate");
|
|
1161
|
+
},
|
|
1162
|
+
enqueueReplaceState: function (publicInstance) {
|
|
1163
|
+
warnNoop(publicInstance, "replaceState");
|
|
1164
|
+
},
|
|
1165
|
+
enqueueSetState: function (publicInstance) {
|
|
1166
|
+
warnNoop(publicInstance, "setState");
|
|
2600
1167
|
}
|
|
1168
|
+
},
|
|
1169
|
+
assign = Object.assign,
|
|
1170
|
+
emptyObject = {};
|
|
1171
|
+
Object.freeze(emptyObject);
|
|
1172
|
+
Component.prototype.isReactComponent = {};
|
|
1173
|
+
Component.prototype.setState = function (partialState, callback) {
|
|
1174
|
+
if (
|
|
1175
|
+
"object" !== typeof partialState &&
|
|
1176
|
+
"function" !== typeof partialState &&
|
|
1177
|
+
null != partialState
|
|
1178
|
+
)
|
|
1179
|
+
throw Error(
|
|
1180
|
+
"takes an object of state variables to update or a function which returns an object of state variables."
|
|
1181
|
+
);
|
|
1182
|
+
this.updater.enqueueSetState(this, partialState, callback, "setState");
|
|
1183
|
+
};
|
|
1184
|
+
Component.prototype.forceUpdate = function (callback) {
|
|
1185
|
+
this.updater.enqueueForceUpdate(this, callback, "forceUpdate");
|
|
1186
|
+
};
|
|
1187
|
+
var deprecatedAPIs = {
|
|
1188
|
+
isMounted: [
|
|
1189
|
+
"isMounted",
|
|
1190
|
+
"Instead, make sure to clean up subscriptions and pending requests in componentWillUnmount to prevent memory leaks."
|
|
1191
|
+
],
|
|
1192
|
+
replaceState: [
|
|
1193
|
+
"replaceState",
|
|
1194
|
+
"Refactor your code to use setState instead (see https://github.com/facebook/react/issues/3236)."
|
|
1195
|
+
]
|
|
1196
|
+
},
|
|
1197
|
+
fnName;
|
|
1198
|
+
for (fnName in deprecatedAPIs)
|
|
1199
|
+
deprecatedAPIs.hasOwnProperty(fnName) &&
|
|
1200
|
+
defineDeprecationWarning(fnName, deprecatedAPIs[fnName]);
|
|
1201
|
+
ComponentDummy.prototype = Component.prototype;
|
|
1202
|
+
deprecatedAPIs = PureComponent.prototype = new ComponentDummy();
|
|
1203
|
+
deprecatedAPIs.constructor = PureComponent;
|
|
1204
|
+
assign(deprecatedAPIs, Component.prototype);
|
|
1205
|
+
deprecatedAPIs.isPureReactComponent = !0;
|
|
1206
|
+
var isArrayImpl = Array.isArray,
|
|
1207
|
+
REACT_CLIENT_REFERENCE = Symbol.for("react.client.reference"),
|
|
1208
|
+
ReactSharedInternals = {
|
|
1209
|
+
H: null,
|
|
1210
|
+
A: null,
|
|
1211
|
+
T: null,
|
|
1212
|
+
S: null,
|
|
1213
|
+
V: null,
|
|
1214
|
+
actQueue: null,
|
|
1215
|
+
isBatchingLegacy: !1,
|
|
1216
|
+
didScheduleLegacyUpdate: !1,
|
|
1217
|
+
didUsePromise: !1,
|
|
1218
|
+
thrownErrors: [],
|
|
1219
|
+
getCurrentStack: null,
|
|
1220
|
+
recentlyCreatedOwnerStacks: 0
|
|
1221
|
+
},
|
|
1222
|
+
hasOwnProperty = Object.prototype.hasOwnProperty,
|
|
1223
|
+
createTask = console.createTask
|
|
1224
|
+
? console.createTask
|
|
1225
|
+
: function () {
|
|
1226
|
+
return null;
|
|
1227
|
+
};
|
|
1228
|
+
deprecatedAPIs = {
|
|
1229
|
+
"react-stack-bottom-frame": function (callStackForError) {
|
|
1230
|
+
return callStackForError();
|
|
2601
1231
|
}
|
|
2602
|
-
|
|
2603
|
-
|
|
2604
|
-
|
|
2605
|
-
|
|
2606
|
-
|
|
2607
|
-
|
|
2608
|
-
|
|
2609
|
-
|
|
2610
|
-
|
|
2611
|
-
|
|
2612
|
-
|
|
2613
|
-
|
|
2614
|
-
|
|
2615
|
-
|
|
2616
|
-
|
|
2617
|
-
|
|
2618
|
-
|
|
2619
|
-
|
|
2620
|
-
|
|
2621
|
-
|
|
2622
|
-
|
|
2623
|
-
|
|
2624
|
-
|
|
2625
|
-
|
|
2626
|
-
|
|
2627
|
-
|
|
2628
|
-
|
|
2629
|
-
|
|
2630
|
-
|
|
2631
|
-
|
|
1232
|
+
};
|
|
1233
|
+
var specialPropKeyWarningShown, didWarnAboutOldJSXRuntime;
|
|
1234
|
+
var didWarnAboutElementRef = {};
|
|
1235
|
+
var unknownOwnerDebugStack = deprecatedAPIs[
|
|
1236
|
+
"react-stack-bottom-frame"
|
|
1237
|
+
].bind(deprecatedAPIs, UnknownOwner)();
|
|
1238
|
+
var unknownOwnerDebugTask = createTask(getTaskName(UnknownOwner));
|
|
1239
|
+
var didWarnAboutMaps = !1,
|
|
1240
|
+
userProvidedKeyEscapeRegex = /\/+/g,
|
|
1241
|
+
reportGlobalError =
|
|
1242
|
+
"function" === typeof reportError
|
|
1243
|
+
? reportError
|
|
1244
|
+
: function (error) {
|
|
1245
|
+
if (
|
|
1246
|
+
"object" === typeof window &&
|
|
1247
|
+
"function" === typeof window.ErrorEvent
|
|
1248
|
+
) {
|
|
1249
|
+
var event = new window.ErrorEvent("error", {
|
|
1250
|
+
bubbles: !0,
|
|
1251
|
+
cancelable: !0,
|
|
1252
|
+
message:
|
|
1253
|
+
"object" === typeof error &&
|
|
1254
|
+
null !== error &&
|
|
1255
|
+
"string" === typeof error.message
|
|
1256
|
+
? String(error.message)
|
|
1257
|
+
: String(error),
|
|
1258
|
+
error: error
|
|
1259
|
+
});
|
|
1260
|
+
if (!window.dispatchEvent(event)) return;
|
|
1261
|
+
} else if (
|
|
1262
|
+
"object" === typeof process &&
|
|
1263
|
+
"function" === typeof process.emit
|
|
1264
|
+
) {
|
|
1265
|
+
process.emit("uncaughtException", error);
|
|
1266
|
+
return;
|
|
1267
|
+
}
|
|
1268
|
+
console.error(error);
|
|
1269
|
+
},
|
|
1270
|
+
didWarnAboutMessageChannel = !1,
|
|
1271
|
+
enqueueTaskImpl = null,
|
|
1272
|
+
actScopeDepth = 0,
|
|
1273
|
+
didWarnNoAwaitAct = !1,
|
|
1274
|
+
isFlushing = !1,
|
|
1275
|
+
queueSeveralMicrotasks =
|
|
1276
|
+
"function" === typeof queueMicrotask
|
|
1277
|
+
? function (callback) {
|
|
1278
|
+
queueMicrotask(function () {
|
|
1279
|
+
return queueMicrotask(callback);
|
|
1280
|
+
});
|
|
2632
1281
|
}
|
|
2633
|
-
|
|
2634
|
-
|
|
2635
|
-
|
|
2636
|
-
|
|
2637
|
-
|
|
2638
|
-
|
|
2639
|
-
|
|
1282
|
+
: enqueueTask;
|
|
1283
|
+
deprecatedAPIs = Object.freeze({
|
|
1284
|
+
__proto__: null,
|
|
1285
|
+
c: function (size) {
|
|
1286
|
+
return resolveDispatcher().useMemoCache(size);
|
|
1287
|
+
}
|
|
1288
|
+
});
|
|
1289
|
+
exports.Children = {
|
|
1290
|
+
map: mapChildren,
|
|
1291
|
+
forEach: function (children, forEachFunc, forEachContext) {
|
|
1292
|
+
mapChildren(
|
|
1293
|
+
children,
|
|
1294
|
+
function () {
|
|
1295
|
+
forEachFunc.apply(this, arguments);
|
|
1296
|
+
},
|
|
1297
|
+
forEachContext
|
|
1298
|
+
);
|
|
1299
|
+
},
|
|
1300
|
+
count: function (children) {
|
|
1301
|
+
var n = 0;
|
|
1302
|
+
mapChildren(children, function () {
|
|
1303
|
+
n++;
|
|
1304
|
+
});
|
|
1305
|
+
return n;
|
|
1306
|
+
},
|
|
1307
|
+
toArray: function (children) {
|
|
1308
|
+
return (
|
|
1309
|
+
mapChildren(children, function (child) {
|
|
1310
|
+
return child;
|
|
1311
|
+
}) || []
|
|
1312
|
+
);
|
|
1313
|
+
},
|
|
1314
|
+
only: function (children) {
|
|
1315
|
+
if (!isValidElement(children))
|
|
1316
|
+
throw Error(
|
|
1317
|
+
"React.Children.only expected to receive a single React element child."
|
|
1318
|
+
);
|
|
1319
|
+
return children;
|
|
1320
|
+
}
|
|
1321
|
+
};
|
|
1322
|
+
exports.Component = Component;
|
|
1323
|
+
exports.Fragment = REACT_FRAGMENT_TYPE;
|
|
1324
|
+
exports.Profiler = REACT_PROFILER_TYPE;
|
|
1325
|
+
exports.PureComponent = PureComponent;
|
|
1326
|
+
exports.StrictMode = REACT_STRICT_MODE_TYPE;
|
|
1327
|
+
exports.Suspense = REACT_SUSPENSE_TYPE;
|
|
1328
|
+
exports.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE =
|
|
1329
|
+
ReactSharedInternals;
|
|
1330
|
+
exports.__COMPILER_RUNTIME = deprecatedAPIs;
|
|
1331
|
+
exports.act = function (callback) {
|
|
1332
|
+
var prevActQueue = ReactSharedInternals.actQueue,
|
|
1333
|
+
prevActScopeDepth = actScopeDepth;
|
|
1334
|
+
actScopeDepth++;
|
|
1335
|
+
var queue = (ReactSharedInternals.actQueue =
|
|
1336
|
+
null !== prevActQueue ? prevActQueue : []),
|
|
1337
|
+
didAwaitActCall = !1;
|
|
1338
|
+
try {
|
|
1339
|
+
var result = callback();
|
|
1340
|
+
} catch (error) {
|
|
1341
|
+
ReactSharedInternals.thrownErrors.push(error);
|
|
1342
|
+
}
|
|
1343
|
+
if (0 < ReactSharedInternals.thrownErrors.length)
|
|
1344
|
+
throw (
|
|
1345
|
+
(popActScope(prevActQueue, prevActScopeDepth),
|
|
1346
|
+
(callback = aggregateErrors(ReactSharedInternals.thrownErrors)),
|
|
1347
|
+
(ReactSharedInternals.thrownErrors.length = 0),
|
|
1348
|
+
callback)
|
|
1349
|
+
);
|
|
1350
|
+
if (
|
|
1351
|
+
null !== result &&
|
|
1352
|
+
"object" === typeof result &&
|
|
1353
|
+
"function" === typeof result.then
|
|
1354
|
+
) {
|
|
1355
|
+
var thenable = result;
|
|
1356
|
+
queueSeveralMicrotasks(function () {
|
|
1357
|
+
didAwaitActCall ||
|
|
1358
|
+
didWarnNoAwaitAct ||
|
|
1359
|
+
((didWarnNoAwaitAct = !0),
|
|
1360
|
+
console.error(
|
|
1361
|
+
"You called act(async () => ...) without await. This could lead to unexpected testing behaviour, interleaving multiple act calls and mixing their scopes. You should - await act(async () => ...);"
|
|
1362
|
+
));
|
|
1363
|
+
});
|
|
1364
|
+
return {
|
|
2640
1365
|
then: function (resolve, reject) {
|
|
2641
|
-
|
|
1366
|
+
didAwaitActCall = !0;
|
|
1367
|
+
thenable.then(
|
|
1368
|
+
function (returnValue) {
|
|
1369
|
+
popActScope(prevActQueue, prevActScopeDepth);
|
|
1370
|
+
if (0 === prevActScopeDepth) {
|
|
1371
|
+
try {
|
|
1372
|
+
flushActQueue(queue),
|
|
1373
|
+
enqueueTask(function () {
|
|
1374
|
+
return recursivelyFlushAsyncActWork(
|
|
1375
|
+
returnValue,
|
|
1376
|
+
resolve,
|
|
1377
|
+
reject
|
|
1378
|
+
);
|
|
1379
|
+
});
|
|
1380
|
+
} catch (error$0) {
|
|
1381
|
+
ReactSharedInternals.thrownErrors.push(error$0);
|
|
1382
|
+
}
|
|
1383
|
+
if (0 < ReactSharedInternals.thrownErrors.length) {
|
|
1384
|
+
var _thrownError = aggregateErrors(
|
|
1385
|
+
ReactSharedInternals.thrownErrors
|
|
1386
|
+
);
|
|
1387
|
+
ReactSharedInternals.thrownErrors.length = 0;
|
|
1388
|
+
reject(_thrownError);
|
|
1389
|
+
}
|
|
1390
|
+
} else resolve(returnValue);
|
|
1391
|
+
},
|
|
1392
|
+
function (error) {
|
|
1393
|
+
popActScope(prevActQueue, prevActScopeDepth);
|
|
1394
|
+
0 < ReactSharedInternals.thrownErrors.length
|
|
1395
|
+
? ((error = aggregateErrors(
|
|
1396
|
+
ReactSharedInternals.thrownErrors
|
|
1397
|
+
)),
|
|
1398
|
+
(ReactSharedInternals.thrownErrors.length = 0),
|
|
1399
|
+
reject(error))
|
|
1400
|
+
: reject(error);
|
|
1401
|
+
}
|
|
1402
|
+
);
|
|
2642
1403
|
}
|
|
2643
1404
|
};
|
|
2644
|
-
return _thenable2;
|
|
2645
1405
|
}
|
|
2646
|
-
|
|
2647
|
-
|
|
2648
|
-
|
|
2649
|
-
|
|
2650
|
-
|
|
2651
|
-
|
|
2652
|
-
|
|
2653
|
-
|
|
2654
|
-
|
|
2655
|
-
|
|
2656
|
-
|
|
2657
|
-
|
|
2658
|
-
}
|
|
2659
|
-
|
|
2660
|
-
|
|
2661
|
-
|
|
2662
|
-
|
|
2663
|
-
|
|
2664
|
-
|
|
2665
|
-
|
|
2666
|
-
|
|
2667
|
-
|
|
2668
|
-
|
|
2669
|
-
|
|
2670
|
-
|
|
2671
|
-
|
|
2672
|
-
|
|
2673
|
-
|
|
2674
|
-
|
|
1406
|
+
var returnValue$jscomp$0 = result;
|
|
1407
|
+
popActScope(prevActQueue, prevActScopeDepth);
|
|
1408
|
+
0 === prevActScopeDepth &&
|
|
1409
|
+
(flushActQueue(queue),
|
|
1410
|
+
0 !== queue.length &&
|
|
1411
|
+
queueSeveralMicrotasks(function () {
|
|
1412
|
+
didAwaitActCall ||
|
|
1413
|
+
didWarnNoAwaitAct ||
|
|
1414
|
+
((didWarnNoAwaitAct = !0),
|
|
1415
|
+
console.error(
|
|
1416
|
+
"A component suspended inside an `act` scope, but the `act` call was not awaited. When testing React components that depend on asynchronous data, you must await the result:\n\nawait act(() => ...)"
|
|
1417
|
+
));
|
|
1418
|
+
}),
|
|
1419
|
+
(ReactSharedInternals.actQueue = null));
|
|
1420
|
+
if (0 < ReactSharedInternals.thrownErrors.length)
|
|
1421
|
+
throw (
|
|
1422
|
+
((callback = aggregateErrors(ReactSharedInternals.thrownErrors)),
|
|
1423
|
+
(ReactSharedInternals.thrownErrors.length = 0),
|
|
1424
|
+
callback)
|
|
1425
|
+
);
|
|
1426
|
+
return {
|
|
1427
|
+
then: function (resolve, reject) {
|
|
1428
|
+
didAwaitActCall = !0;
|
|
1429
|
+
0 === prevActScopeDepth
|
|
1430
|
+
? ((ReactSharedInternals.actQueue = queue),
|
|
1431
|
+
enqueueTask(function () {
|
|
1432
|
+
return recursivelyFlushAsyncActWork(
|
|
1433
|
+
returnValue$jscomp$0,
|
|
1434
|
+
resolve,
|
|
1435
|
+
reject
|
|
1436
|
+
);
|
|
1437
|
+
}))
|
|
1438
|
+
: resolve(returnValue$jscomp$0);
|
|
1439
|
+
}
|
|
1440
|
+
};
|
|
1441
|
+
};
|
|
1442
|
+
exports.cache = function (fn) {
|
|
1443
|
+
return function () {
|
|
1444
|
+
return fn.apply(null, arguments);
|
|
1445
|
+
};
|
|
1446
|
+
};
|
|
1447
|
+
exports.captureOwnerStack = function () {
|
|
1448
|
+
var getCurrentStack = ReactSharedInternals.getCurrentStack;
|
|
1449
|
+
return null === getCurrentStack ? null : getCurrentStack();
|
|
1450
|
+
};
|
|
1451
|
+
exports.cloneElement = function (element, config, children) {
|
|
1452
|
+
if (null === element || void 0 === element)
|
|
1453
|
+
throw Error(
|
|
1454
|
+
"The argument must be a React element, but you passed " +
|
|
1455
|
+
element +
|
|
1456
|
+
"."
|
|
1457
|
+
);
|
|
1458
|
+
var props = assign({}, element.props),
|
|
1459
|
+
key = element.key,
|
|
1460
|
+
owner = element._owner;
|
|
1461
|
+
if (null != config) {
|
|
1462
|
+
var JSCompiler_inline_result;
|
|
1463
|
+
a: {
|
|
1464
|
+
if (
|
|
1465
|
+
hasOwnProperty.call(config, "ref") &&
|
|
1466
|
+
(JSCompiler_inline_result = Object.getOwnPropertyDescriptor(
|
|
1467
|
+
config,
|
|
1468
|
+
"ref"
|
|
1469
|
+
).get) &&
|
|
1470
|
+
JSCompiler_inline_result.isReactWarning
|
|
1471
|
+
) {
|
|
1472
|
+
JSCompiler_inline_result = !1;
|
|
1473
|
+
break a;
|
|
2675
1474
|
}
|
|
2676
|
-
|
|
2677
|
-
|
|
2678
|
-
|
|
1475
|
+
JSCompiler_inline_result = void 0 !== config.ref;
|
|
1476
|
+
}
|
|
1477
|
+
JSCompiler_inline_result && (owner = getOwner());
|
|
1478
|
+
hasValidKey(config) &&
|
|
1479
|
+
(checkKeyStringCoercion(config.key), (key = "" + config.key));
|
|
1480
|
+
for (propName in config)
|
|
1481
|
+
!hasOwnProperty.call(config, propName) ||
|
|
1482
|
+
"key" === propName ||
|
|
1483
|
+
"__self" === propName ||
|
|
1484
|
+
"__source" === propName ||
|
|
1485
|
+
("ref" === propName && void 0 === config.ref) ||
|
|
1486
|
+
(props[propName] = config[propName]);
|
|
2679
1487
|
}
|
|
2680
|
-
|
|
2681
|
-
|
|
2682
|
-
|
|
2683
|
-
|
|
2684
|
-
|
|
2685
|
-
|
|
2686
|
-
|
|
2687
|
-
|
|
2688
|
-
|
|
2689
|
-
|
|
2690
|
-
|
|
2691
|
-
|
|
2692
|
-
|
|
2693
|
-
|
|
2694
|
-
|
|
2695
|
-
|
|
2696
|
-
|
|
2697
|
-
|
|
2698
|
-
|
|
2699
|
-
|
|
2700
|
-
|
|
2701
|
-
|
|
1488
|
+
var propName = arguments.length - 2;
|
|
1489
|
+
if (1 === propName) props.children = children;
|
|
1490
|
+
else if (1 < propName) {
|
|
1491
|
+
JSCompiler_inline_result = Array(propName);
|
|
1492
|
+
for (var i = 0; i < propName; i++)
|
|
1493
|
+
JSCompiler_inline_result[i] = arguments[i + 2];
|
|
1494
|
+
props.children = JSCompiler_inline_result;
|
|
1495
|
+
}
|
|
1496
|
+
props = ReactElement(
|
|
1497
|
+
element.type,
|
|
1498
|
+
key,
|
|
1499
|
+
void 0,
|
|
1500
|
+
void 0,
|
|
1501
|
+
owner,
|
|
1502
|
+
props,
|
|
1503
|
+
element._debugStack,
|
|
1504
|
+
element._debugTask
|
|
1505
|
+
);
|
|
1506
|
+
for (key = 2; key < arguments.length; key++)
|
|
1507
|
+
(owner = arguments[key]),
|
|
1508
|
+
isValidElement(owner) && owner._store && (owner._store.validated = 1);
|
|
1509
|
+
return props;
|
|
1510
|
+
};
|
|
1511
|
+
exports.createContext = function (defaultValue) {
|
|
1512
|
+
defaultValue = {
|
|
1513
|
+
$$typeof: REACT_CONTEXT_TYPE,
|
|
1514
|
+
_currentValue: defaultValue,
|
|
1515
|
+
_currentValue2: defaultValue,
|
|
1516
|
+
_threadCount: 0,
|
|
1517
|
+
Provider: null,
|
|
1518
|
+
Consumer: null
|
|
1519
|
+
};
|
|
1520
|
+
defaultValue.Provider = defaultValue;
|
|
1521
|
+
defaultValue.Consumer = {
|
|
1522
|
+
$$typeof: REACT_CONSUMER_TYPE,
|
|
1523
|
+
_context: defaultValue
|
|
1524
|
+
};
|
|
1525
|
+
defaultValue._currentRenderer = null;
|
|
1526
|
+
defaultValue._currentRenderer2 = null;
|
|
1527
|
+
return defaultValue;
|
|
1528
|
+
};
|
|
1529
|
+
exports.createElement = function (type, config, children) {
|
|
1530
|
+
for (var i = 2; i < arguments.length; i++) {
|
|
1531
|
+
var node = arguments[i];
|
|
1532
|
+
isValidElement(node) && node._store && (node._store.validated = 1);
|
|
1533
|
+
}
|
|
1534
|
+
i = {};
|
|
1535
|
+
node = null;
|
|
1536
|
+
if (null != config)
|
|
1537
|
+
for (propName in (didWarnAboutOldJSXRuntime ||
|
|
1538
|
+
!("__self" in config) ||
|
|
1539
|
+
"key" in config ||
|
|
1540
|
+
((didWarnAboutOldJSXRuntime = !0),
|
|
1541
|
+
console.warn(
|
|
1542
|
+
"Your app (or one of its dependencies) is using an outdated JSX transform. Update to the modern JSX transform for faster performance: https://react.dev/link/new-jsx-transform"
|
|
1543
|
+
)),
|
|
1544
|
+
hasValidKey(config) &&
|
|
1545
|
+
(checkKeyStringCoercion(config.key), (node = "" + config.key)),
|
|
1546
|
+
config))
|
|
1547
|
+
hasOwnProperty.call(config, propName) &&
|
|
1548
|
+
"key" !== propName &&
|
|
1549
|
+
"__self" !== propName &&
|
|
1550
|
+
"__source" !== propName &&
|
|
1551
|
+
(i[propName] = config[propName]);
|
|
1552
|
+
var childrenLength = arguments.length - 2;
|
|
1553
|
+
if (1 === childrenLength) i.children = children;
|
|
1554
|
+
else if (1 < childrenLength) {
|
|
1555
|
+
for (
|
|
1556
|
+
var childArray = Array(childrenLength), _i = 0;
|
|
1557
|
+
_i < childrenLength;
|
|
1558
|
+
_i++
|
|
1559
|
+
)
|
|
1560
|
+
childArray[_i] = arguments[_i + 2];
|
|
1561
|
+
Object.freeze && Object.freeze(childArray);
|
|
1562
|
+
i.children = childArray;
|
|
1563
|
+
}
|
|
1564
|
+
if (type && type.defaultProps)
|
|
1565
|
+
for (propName in ((childrenLength = type.defaultProps), childrenLength))
|
|
1566
|
+
void 0 === i[propName] && (i[propName] = childrenLength[propName]);
|
|
1567
|
+
node &&
|
|
1568
|
+
defineKeyPropWarningGetter(
|
|
1569
|
+
i,
|
|
1570
|
+
"function" === typeof type
|
|
1571
|
+
? type.displayName || type.name || "Unknown"
|
|
1572
|
+
: type
|
|
1573
|
+
);
|
|
1574
|
+
var propName = 1e4 > ReactSharedInternals.recentlyCreatedOwnerStacks++;
|
|
1575
|
+
return ReactElement(
|
|
1576
|
+
type,
|
|
1577
|
+
node,
|
|
1578
|
+
void 0,
|
|
1579
|
+
void 0,
|
|
1580
|
+
getOwner(),
|
|
1581
|
+
i,
|
|
1582
|
+
propName ? Error("react-stack-top-frame") : unknownOwnerDebugStack,
|
|
1583
|
+
propName ? createTask(getTaskName(type)) : unknownOwnerDebugTask
|
|
1584
|
+
);
|
|
1585
|
+
};
|
|
1586
|
+
exports.createRef = function () {
|
|
1587
|
+
var refObject = { current: null };
|
|
1588
|
+
Object.seal(refObject);
|
|
1589
|
+
return refObject;
|
|
1590
|
+
};
|
|
1591
|
+
exports.forwardRef = function (render) {
|
|
1592
|
+
null != render && render.$$typeof === REACT_MEMO_TYPE
|
|
1593
|
+
? console.error(
|
|
1594
|
+
"forwardRef requires a render function but received a `memo` component. Instead of forwardRef(memo(...)), use memo(forwardRef(...))."
|
|
1595
|
+
)
|
|
1596
|
+
: "function" !== typeof render
|
|
1597
|
+
? console.error(
|
|
1598
|
+
"forwardRef requires a render function but was given %s.",
|
|
1599
|
+
null === render ? "null" : typeof render
|
|
1600
|
+
)
|
|
1601
|
+
: 0 !== render.length &&
|
|
1602
|
+
2 !== render.length &&
|
|
1603
|
+
console.error(
|
|
1604
|
+
"forwardRef render functions accept exactly two parameters: props and ref. %s",
|
|
1605
|
+
1 === render.length
|
|
1606
|
+
? "Did you forget to use the ref parameter?"
|
|
1607
|
+
: "Any additional parameter will be undefined."
|
|
1608
|
+
);
|
|
1609
|
+
null != render &&
|
|
1610
|
+
null != render.defaultProps &&
|
|
1611
|
+
console.error(
|
|
1612
|
+
"forwardRef render functions do not support defaultProps. Did you accidentally pass a React component?"
|
|
1613
|
+
);
|
|
1614
|
+
var elementType = { $$typeof: REACT_FORWARD_REF_TYPE, render: render },
|
|
1615
|
+
ownName;
|
|
1616
|
+
Object.defineProperty(elementType, "displayName", {
|
|
1617
|
+
enumerable: !1,
|
|
1618
|
+
configurable: !0,
|
|
1619
|
+
get: function () {
|
|
1620
|
+
return ownName;
|
|
1621
|
+
},
|
|
1622
|
+
set: function (name) {
|
|
1623
|
+
ownName = name;
|
|
1624
|
+
render.name ||
|
|
1625
|
+
render.displayName ||
|
|
1626
|
+
(Object.defineProperty(render, "name", { value: name }),
|
|
1627
|
+
(render.displayName = name));
|
|
2702
1628
|
}
|
|
2703
|
-
|
|
2704
|
-
|
|
1629
|
+
});
|
|
1630
|
+
return elementType;
|
|
1631
|
+
};
|
|
1632
|
+
exports.isValidElement = isValidElement;
|
|
1633
|
+
exports.lazy = function (ctor) {
|
|
1634
|
+
return {
|
|
1635
|
+
$$typeof: REACT_LAZY_TYPE,
|
|
1636
|
+
_payload: { _status: -1, _result: ctor },
|
|
1637
|
+
_init: lazyInitializer
|
|
1638
|
+
};
|
|
1639
|
+
};
|
|
1640
|
+
exports.memo = function (type, compare) {
|
|
1641
|
+
null == type &&
|
|
1642
|
+
console.error(
|
|
1643
|
+
"memo: The first argument must be a component. Instead received: %s",
|
|
1644
|
+
null === type ? "null" : typeof type
|
|
1645
|
+
);
|
|
1646
|
+
compare = {
|
|
1647
|
+
$$typeof: REACT_MEMO_TYPE,
|
|
1648
|
+
type: type,
|
|
1649
|
+
compare: void 0 === compare ? null : compare
|
|
1650
|
+
};
|
|
1651
|
+
var ownName;
|
|
1652
|
+
Object.defineProperty(compare, "displayName", {
|
|
1653
|
+
enumerable: !1,
|
|
1654
|
+
configurable: !0,
|
|
1655
|
+
get: function () {
|
|
1656
|
+
return ownName;
|
|
1657
|
+
},
|
|
1658
|
+
set: function (name) {
|
|
1659
|
+
ownName = name;
|
|
1660
|
+
type.name ||
|
|
1661
|
+
type.displayName ||
|
|
1662
|
+
(Object.defineProperty(type, "name", { value: name }),
|
|
1663
|
+
(type.displayName = name));
|
|
1664
|
+
}
|
|
1665
|
+
});
|
|
1666
|
+
return compare;
|
|
1667
|
+
};
|
|
1668
|
+
exports.startTransition = function (scope) {
|
|
1669
|
+
var prevTransition = ReactSharedInternals.T,
|
|
1670
|
+
currentTransition = {};
|
|
1671
|
+
ReactSharedInternals.T = currentTransition;
|
|
1672
|
+
currentTransition._updatedFibers = new Set();
|
|
1673
|
+
try {
|
|
1674
|
+
var returnValue = scope(),
|
|
1675
|
+
onStartTransitionFinish = ReactSharedInternals.S;
|
|
1676
|
+
null !== onStartTransitionFinish &&
|
|
1677
|
+
onStartTransitionFinish(currentTransition, returnValue);
|
|
1678
|
+
"object" === typeof returnValue &&
|
|
1679
|
+
null !== returnValue &&
|
|
1680
|
+
"function" === typeof returnValue.then &&
|
|
1681
|
+
returnValue.then(noop, reportGlobalError);
|
|
2705
1682
|
} catch (error) {
|
|
2706
|
-
|
|
2707
|
-
queue = queue.slice(i + 1);
|
|
2708
|
-
throw error;
|
|
1683
|
+
reportGlobalError(error);
|
|
2709
1684
|
} finally {
|
|
2710
|
-
|
|
1685
|
+
null === prevTransition &&
|
|
1686
|
+
currentTransition._updatedFibers &&
|
|
1687
|
+
((scope = currentTransition._updatedFibers.size),
|
|
1688
|
+
currentTransition._updatedFibers.clear(),
|
|
1689
|
+
10 < scope &&
|
|
1690
|
+
console.warn(
|
|
1691
|
+
"Detected a large number of updates inside startTransition. If this is due to a subscription please re-write it to use React provided hooks. Otherwise concurrent mode guarantees are off the table."
|
|
1692
|
+
)),
|
|
1693
|
+
(ReactSharedInternals.T = prevTransition);
|
|
2711
1694
|
}
|
|
2712
|
-
}
|
|
2713
|
-
|
|
2714
|
-
|
|
2715
|
-
|
|
2716
|
-
|
|
2717
|
-
|
|
2718
|
-
|
|
2719
|
-
|
|
2720
|
-
|
|
2721
|
-
|
|
2722
|
-
|
|
2723
|
-
|
|
2724
|
-
|
|
2725
|
-
};
|
|
2726
|
-
|
|
2727
|
-
|
|
2728
|
-
|
|
2729
|
-
exports.
|
|
2730
|
-
|
|
2731
|
-
|
|
2732
|
-
|
|
2733
|
-
|
|
2734
|
-
|
|
2735
|
-
|
|
2736
|
-
|
|
2737
|
-
exports.
|
|
2738
|
-
|
|
2739
|
-
|
|
2740
|
-
exports.
|
|
2741
|
-
|
|
2742
|
-
|
|
2743
|
-
exports.
|
|
2744
|
-
|
|
2745
|
-
|
|
2746
|
-
|
|
2747
|
-
|
|
2748
|
-
|
|
2749
|
-
|
|
2750
|
-
|
|
2751
|
-
|
|
2752
|
-
|
|
2753
|
-
|
|
2754
|
-
|
|
2755
|
-
exports.
|
|
2756
|
-
|
|
2757
|
-
|
|
2758
|
-
exports.
|
|
2759
|
-
|
|
2760
|
-
|
|
2761
|
-
exports.
|
|
2762
|
-
|
|
2763
|
-
|
|
2764
|
-
|
|
2765
|
-
|
|
2766
|
-
|
|
2767
|
-
|
|
2768
|
-
) {
|
|
2769
|
-
|
|
2770
|
-
|
|
2771
|
-
|
|
1695
|
+
};
|
|
1696
|
+
exports.unstable_useCacheRefresh = function () {
|
|
1697
|
+
return resolveDispatcher().useCacheRefresh();
|
|
1698
|
+
};
|
|
1699
|
+
exports.use = function (usable) {
|
|
1700
|
+
return resolveDispatcher().use(usable);
|
|
1701
|
+
};
|
|
1702
|
+
exports.useActionState = function (action, initialState, permalink) {
|
|
1703
|
+
return resolveDispatcher().useActionState(
|
|
1704
|
+
action,
|
|
1705
|
+
initialState,
|
|
1706
|
+
permalink
|
|
1707
|
+
);
|
|
1708
|
+
};
|
|
1709
|
+
exports.useCallback = function (callback, deps) {
|
|
1710
|
+
return resolveDispatcher().useCallback(callback, deps);
|
|
1711
|
+
};
|
|
1712
|
+
exports.useContext = function (Context) {
|
|
1713
|
+
var dispatcher = resolveDispatcher();
|
|
1714
|
+
Context.$$typeof === REACT_CONSUMER_TYPE &&
|
|
1715
|
+
console.error(
|
|
1716
|
+
"Calling useContext(Context.Consumer) is not supported and will cause bugs. Did you mean to call useContext(Context) instead?"
|
|
1717
|
+
);
|
|
1718
|
+
return dispatcher.useContext(Context);
|
|
1719
|
+
};
|
|
1720
|
+
exports.useDebugValue = function (value, formatterFn) {
|
|
1721
|
+
return resolveDispatcher().useDebugValue(value, formatterFn);
|
|
1722
|
+
};
|
|
1723
|
+
exports.useDeferredValue = function (value, initialValue) {
|
|
1724
|
+
return resolveDispatcher().useDeferredValue(value, initialValue);
|
|
1725
|
+
};
|
|
1726
|
+
exports.useEffect = function (create, createDeps, update) {
|
|
1727
|
+
null == create &&
|
|
1728
|
+
console.warn(
|
|
1729
|
+
"React Hook useEffect requires an effect callback. Did you forget to pass a callback to the hook?"
|
|
1730
|
+
);
|
|
1731
|
+
var dispatcher = resolveDispatcher();
|
|
1732
|
+
if ("function" === typeof update)
|
|
1733
|
+
throw Error(
|
|
1734
|
+
"useEffect CRUD overload is not enabled in this build of React."
|
|
1735
|
+
);
|
|
1736
|
+
return dispatcher.useEffect(create, createDeps);
|
|
1737
|
+
};
|
|
1738
|
+
exports.useId = function () {
|
|
1739
|
+
return resolveDispatcher().useId();
|
|
1740
|
+
};
|
|
1741
|
+
exports.useImperativeHandle = function (ref, create, deps) {
|
|
1742
|
+
return resolveDispatcher().useImperativeHandle(ref, create, deps);
|
|
1743
|
+
};
|
|
1744
|
+
exports.useInsertionEffect = function (create, deps) {
|
|
1745
|
+
null == create &&
|
|
1746
|
+
console.warn(
|
|
1747
|
+
"React Hook useInsertionEffect requires an effect callback. Did you forget to pass a callback to the hook?"
|
|
1748
|
+
);
|
|
1749
|
+
return resolveDispatcher().useInsertionEffect(create, deps);
|
|
1750
|
+
};
|
|
1751
|
+
exports.useLayoutEffect = function (create, deps) {
|
|
1752
|
+
null == create &&
|
|
1753
|
+
console.warn(
|
|
1754
|
+
"React Hook useLayoutEffect requires an effect callback. Did you forget to pass a callback to the hook?"
|
|
1755
|
+
);
|
|
1756
|
+
return resolveDispatcher().useLayoutEffect(create, deps);
|
|
1757
|
+
};
|
|
1758
|
+
exports.useMemo = function (create, deps) {
|
|
1759
|
+
return resolveDispatcher().useMemo(create, deps);
|
|
1760
|
+
};
|
|
1761
|
+
exports.useOptimistic = function (passthrough, reducer) {
|
|
1762
|
+
return resolveDispatcher().useOptimistic(passthrough, reducer);
|
|
1763
|
+
};
|
|
1764
|
+
exports.useReducer = function (reducer, initialArg, init) {
|
|
1765
|
+
return resolveDispatcher().useReducer(reducer, initialArg, init);
|
|
1766
|
+
};
|
|
1767
|
+
exports.useRef = function (initialValue) {
|
|
1768
|
+
return resolveDispatcher().useRef(initialValue);
|
|
1769
|
+
};
|
|
1770
|
+
exports.useState = function (initialState) {
|
|
1771
|
+
return resolveDispatcher().useState(initialState);
|
|
1772
|
+
};
|
|
1773
|
+
exports.useSyncExternalStore = function (
|
|
1774
|
+
subscribe,
|
|
1775
|
+
getSnapshot,
|
|
1776
|
+
getServerSnapshot
|
|
1777
|
+
) {
|
|
1778
|
+
return resolveDispatcher().useSyncExternalStore(
|
|
1779
|
+
subscribe,
|
|
1780
|
+
getSnapshot,
|
|
1781
|
+
getServerSnapshot
|
|
1782
|
+
);
|
|
1783
|
+
};
|
|
1784
|
+
exports.useTransition = function () {
|
|
1785
|
+
return resolveDispatcher().useTransition();
|
|
1786
|
+
};
|
|
1787
|
+
exports.version = "19.1.0";
|
|
1788
|
+
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
|
|
1789
|
+
"function" ===
|
|
1790
|
+
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&
|
|
1791
|
+
__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error());
|
|
2772
1792
|
})();
|
|
2773
|
-
}
|
|
2774
1793
|
}(react_development, react_development.exports));
|
|
2775
1794
|
|
|
2776
1795
|
if (process.env.NODE_ENV === 'production') {
|
|
2777
|
-
react.exports =
|
|
1796
|
+
react.exports = react_production;
|
|
2778
1797
|
} else {
|
|
2779
1798
|
react.exports = react_development.exports;
|
|
2780
1799
|
}
|
|
@@ -2808,9 +1827,9 @@ function styleInject(css, ref) {
|
|
|
2808
1827
|
}
|
|
2809
1828
|
}
|
|
2810
1829
|
|
|
2811
|
-
var css_248z$
|
|
1830
|
+
var css_248z$7 = ".Accordion-module_accordionBtn__1unNG {\n border-radius: inherit;\n width: 100%;\n text-align: left;\n display: flex;\n justify-content: space-between;\n cursor: pointer;\n}\n\n.Accordion-module_accordionContent__Qnx7K {\n max-height: 1000px;\n overflow: hidden;\n transition: all 0.3s ease-in-out;\n}\n\n.Accordion-module_accordionContent--hidden__DrXay {\n max-height: 0;\n}\n";
|
|
2812
1831
|
var styles$6 = {"accordionBtn":"Accordion-module_accordionBtn__1unNG","accordionContent":"Accordion-module_accordionContent__Qnx7K","accordionContent--hidden":"Accordion-module_accordionContent--hidden__DrXay"};
|
|
2813
|
-
styleInject(css_248z$
|
|
1832
|
+
styleInject(css_248z$7);
|
|
2814
1833
|
|
|
2815
1834
|
var joinClasses = function () {
|
|
2816
1835
|
var args = [];
|
|
@@ -2834,8 +1853,12 @@ var Accordion = function (_a) {
|
|
|
2834
1853
|
React.createElement("div", { "data-testid": "Accordion_CONTENT", className: joinClasses(styles$6.accordionContent, !open && styles$6["accordionContent--hidden"]) }, children)));
|
|
2835
1854
|
};
|
|
2836
1855
|
|
|
2837
|
-
var css_248z$
|
|
1856
|
+
var css_248z$6 = "@import \"../../styles/colors.module.css\";\n\n.button-module_button__JyfZW {\n border: none;\n transition: background-color 0.2s ease;\n\n display: inline-flex;\n justify-content: center;\n align-items: center;\n cursor: pointer;\n}\n\n.button-module_btn-default__EDl7t {\n color: var(--default-white-color);\n background-color: var(--default-primary-accent);\n}\n\n.button-module_btn-default--disabled__H36E7 {\n color: var(--text-disabled-color);\n background-color: var(--button-disabled-default-color);\n}\n\n.button-module_btn-tinted__Do6iX {\n color: var(--text-accent);\n background-color: var(--button-tinted-default-color);\n}\n\n.button-module_btn-tinted--disabled__XRuq- {\n color: var(--text-disabled-accent-color);\n background-color: var(--button-tinted-default-color);\n}\n\n.button-module_btn-secondary__LtTTr {\n color: var(--text-primary);\n background-color: var(--surface-surface-3-color);\n}\n\n.button-module_btn-secondary--disabled__5YS63 {\n color: var(--text-secondary);\n background-color: var(--surface-surface-3-color);\n}\n\n.button-module_btn-default__EDl7t:hover {\n background-color: var(--button-primary-on-hover-color);\n}\n\n.button-module_btn-tinted__Do6iX:hover {\n background-color: var(--button-tinted-on-hover-color);\n}\n\n.button-module_btn-secondary__LtTTr:hover {\n background-color: var(--button-secondary-on-hover);\n}\n\n.button-module_btn--mini__a9EJm {\n gap: 4px;\n padding: 6px 12px;\n}\n.button-module_btn--small__xfhlR {\n gap: 8px;\n padding: 8px 16px;\n}\n.button-module_btn--medium__pFJSr {\n gap: 8px;\n padding: 8px 20px;\n}\n.button-module_btn--large__GvwY2 {\n gap: 8px;\n padding: 14px 24px;\n}\n\n.button-module_btn-square--mini__RWpOc {\n border-radius: 4px;\n}\n.button-module_btn-square--small__M-WgA {\n border-radius: 6px;\n}\n.button-module_btn-square--medium__aDBfE {\n border-radius: 10px;\n}\n.button-module_btn-square--large__dwebF {\n border-radius: 12px;\n}\n\n.button-module_btn-rounded--mini__bX5xJ {\n border-radius: 32px;\n}\n.button-module_btn-rounded--small__LI-QV {\n border-radius: 32px;\n}\n.button-module_btn-rounded--medium__TKy02 {\n border-radius: 32px;\n}\n.button-module_btn-rounded--large__joy-r {\n border-radius: 40px;\n}\n";
|
|
2838
1857
|
var styles$5 = {"button":"button-module_button__JyfZW","btn-default":"button-module_btn-default__EDl7t","btn-default--disabled":"button-module_btn-default--disabled__H36E7","btn-tinted":"button-module_btn-tinted__Do6iX","btn-tinted--disabled":"button-module_btn-tinted--disabled__XRuq-","btn-secondary":"button-module_btn-secondary__LtTTr","btn-secondary--disabled":"button-module_btn-secondary--disabled__5YS63","btn--mini":"button-module_btn--mini__a9EJm","btn--small":"button-module_btn--small__xfhlR","btn--medium":"button-module_btn--medium__pFJSr","btn--large":"button-module_btn--large__GvwY2","btn-square--mini":"button-module_btn-square--mini__RWpOc","btn-square--small":"button-module_btn-square--small__M-WgA","btn-square--medium":"button-module_btn-square--medium__aDBfE","btn-square--large":"button-module_btn-square--large__dwebF","btn-rounded--mini":"button-module_btn-rounded--mini__bX5xJ","btn-rounded--small":"button-module_btn-rounded--small__LI-QV","btn-rounded--medium":"button-module_btn-rounded--medium__TKy02","btn-rounded--large":"button-module_btn-rounded--large__joy-r"};
|
|
1858
|
+
styleInject(css_248z$6);
|
|
1859
|
+
|
|
1860
|
+
var css_248z$5 = "/* Headings/Heading 1 */\n.typography-module_heading1__ub7Od {\n font-family: Inter;\n font-size: 32px;\n font-style: normal;\n font-weight: 600;\n line-height: 36px; /* 112.5% */\n letter-spacing: -0.32px;\n}\n\n/* Headings/Heading 3 */\n.typography-module_heading3__QLNPD {\n font-family: Inter;\n font-size: 24px;\n font-style: normal;\n font-weight: 600;\n line-height: 28px; /* 116.667% */\n letter-spacing: -0.24px;\n}\n\n/* Subtitles/Subtitle 3 */\n.typography-module_subtitles3__QZScB {\n font-family: Inter;\n font-size: 16px;\n font-style: normal;\n font-weight: 600;\n line-height: 24px; /* 150% */\n}\n\n/* Body/Body 1, Medium */\n.typography-module_body1Medium__INZB0 {\n font-family: Inter;\n font-size: 16px;\n font-style: normal;\n font-weight: 500;\n line-height: 24px; /* 150% */\n}\n\n/* Body/Body 1, Regular */\n.typography-module_body1Regular__H3iQB {\n font-family: Inter;\n font-size: 16px;\n font-style: normal;\n font-weight: 400;\n line-height: 24px; /* 150% */\n}\n\n/* Body/Body 2, Medium */\n.typography-module_body2Medium__Caa0m {\n font-family: Inter;\n font-size: 14px;\n font-style: normal;\n font-weight: 500;\n line-height: 20px; /* 142.857% */\n}\n\n/* Body/Body 2, Regular */\n.typography-module_body2Regular__MEtzs {\n font-family: Inter;\n font-size: 14px;\n font-style: normal;\n font-weight: 400;\n line-height: 20px; /* 142.857% */\n}\n\n/* Body/Body 3, Regular */\n.typography-module_body3Regular__rp6ng {\n font-family: Inter;\n font-size: 14px;\n font-style: normal;\n font-weight: 400;\n line-height: 16px; /* 114.286% */\n}\n\n/* Caption/Caption 1, Medium */\n.typography-module_caption1Medium__xXMm- {\n font-family: Inter;\n font-size: 12px;\n font-style: normal;\n font-weight: 500;\n line-height: 16px; /* 133.333% */\n}\n\n/* Caption/Caption 1, Regular */\n.typography-module_caption1Regular__QVGyq {\n font-family: Inter;\n font-size: 12px;\n font-style: normal;\n font-weight: 400;\n line-height: 16px; /* 133.333% */\n}\n\n/* Caption/Caption 1, Semibold */\n.typography-module_caption1Semibold__Il1Aq {\n font-family: Inter;\n font-size: 12px;\n font-style: normal;\n font-weight: 600;\n line-height: 16px; /* 133.333% */\n}\n\n/* Caption/Caption 2, Medium */\n.typography-module_caption2Medium__0Vvmy {\n font-family: Inter;\n font-size: 10px;\n font-style: normal;\n font-weight: 500;\n line-height: 12px; /* 120% */\n}\n\n/* Caption/Caption 2, Regular */\n.typography-module_caption2Regular__GxtiS {\n font-family: Inter;\n font-size: 10px;\n font-style: normal;\n font-weight: 400;\n line-height: 12px; /* 120% */\n}\n";
|
|
1861
|
+
var typography = {"heading1":"typography-module_heading1__ub7Od","heading3":"typography-module_heading3__QLNPD","subtitles3":"typography-module_subtitles3__QZScB","body1Medium":"typography-module_body1Medium__INZB0","body1Regular":"typography-module_body1Regular__H3iQB","body2Medium":"typography-module_body2Medium__Caa0m","body2Regular":"typography-module_body2Regular__MEtzs","body3Regular":"typography-module_body3Regular__rp6ng","caption1Medium":"typography-module_caption1Medium__xXMm-","caption1Regular":"typography-module_caption1Regular__QVGyq","caption1Semibold":"typography-module_caption1Semibold__Il1Aq","caption2Medium":"typography-module_caption2Medium__0Vvmy","caption2Regular":"typography-module_caption2Regular__GxtiS"};
|
|
2839
1862
|
styleInject(css_248z$5);
|
|
2840
1863
|
|
|
2841
1864
|
var btnTypography = {
|