PageSourceSearch

https://kyn-care.com/@fs/home/runner/workspace/node_modules/.vite/deps/chunk-WERSD76P.js?v=9ce4103e

js kyn-care.com collected 2026-10-08 11:36:00 UTC 928,147 bytes, 21,628 lines download raw bytes

1import {
2  require_react
3} from "/@fs/home/runner/workspace/node_modules/.vite/deps/chunk-3TFVT2CW.js?v=9ce4103e";
4import {
5  __commonJS
6} from "/@fs/home/runner/workspace/node_modules/.vite/deps/chunk-4MBMRILA.js?v=9ce4103e";
7
vendor: 16,946 bytes, lines 8-457
8// node_modules/scheduler/cjs/scheduler.development.js
9var require_scheduler_development = __commonJS({
10  "node_modules/scheduler/cjs/scheduler.development.js"(exports) {
11    "use strict";
12    if (true) {
13      (function() {
14        "use strict";
15        if (typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ !== "undefined" && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart === "function") {
16          __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(new Error());
17        }
18        var enableSchedulerDebugging = false;
19        var enableProfiling = false;
20        var frameYieldMs = 5;
21        function push(heap, node) {
22          var index = heap.length;
23          heap.push(node);
24          siftUp(heap, node, index);
25        }
26        function peek(heap) {
27          return heap.length === 0 ? null : heap[0];
28        }
29        function pop(heap) {
30          if (heap.length === 0) {
31            return null;
32          }
33          var first = heap[0];
34          var last = heap.pop();
35          if (last !== first) {
36            heap[0] = last;
37            siftDown(heap, last, 0);
38          }
39          return first;
40        }
41        function siftUp(heap, node, i) {
42          var index = i;
43          while (index > 0) {
44            var parentIndex = index - 1 >>> 1;
45            var parent = heap[parentIndex];
46            if (compare(parent, node) > 0) {
47              heap[parentIndex] = node;
48              heap[index] = parent;
49              index = parentIndex;
50            } else {
51              return;
52            }
53          }
54        }
55        function siftDown(heap, node, i) {
56          var index = i;
57          var length = heap.length;
58          var halfLength = length >>> 1;
59          while (index < halfLength) {
60            var leftIndex = (index + 1) * 2 - 1;
61            var left = heap[leftIndex];
62            var rightIndex = leftIndex + 1;
63            var right = heap[rightIndex];
64            if (compare(left, node) < 0) {
65              if (rightIndex < length && compare(right, left) < 0) {
66                heap[index] = right;
67                heap[rightIndex] = node;
68                index = rightIndex;
69              } else {
70                heap[index] = left;
71                heap[leftIndex] = node;
72                index = leftIndex;
73              }
74            } else if (rightIndex < length && compare(right, node) < 0) {
75              heap[index] = right;
76              heap[rightIndex] = node;
77              index = rightIndex;
78            } else {
79              return;
80            }
81          }
82        }
83        function compare(a, b) {
84          var diff = a.sortIndex - b.sortIndex;
85          return diff !== 0 ? diff : a.id - b.id;
86        }
87        var ImmediatePriority = 1;
88        var UserBlockingPriority = 2;
89        var NormalPriority = 3;
90        var LowPriority = 4;
91        var IdlePriority = 5;
92        function markTaskErrored(task, ms) {
93        }
94        var hasPerformanceNow = typeof performance === "object" && typeof performance.now === "function";
95        if (hasPerformanceNow) {
96          var localPerformance = performance;
97          exports.unstable_now = function() {
98            return localPerformance.now();
99          };
100        } else {
101          var localDate = Date;
102          var initialTime = localDate.now();
103          exports.unstable_now = function() {
104            return localDate.now() - initialTime;
105          };
106        }
107        var maxSigned31BitInt = 1073741823;
108        var IMMEDIATE_PRIORITY_TIMEOUT = -1;
109        var USER_BLOCKING_PRIORITY_TIMEOUT = 250;
110        var NORMAL_PRIORITY_TIMEOUT = 5e3;
111        var LOW_PRIORITY_TIMEOUT = 1e4;
112        var IDLE_PRIORITY_TIMEOUT = maxSigned31BitInt;
113        var taskQueue = [];
114        var timerQueue = [];
115        var taskIdCounter = 1;
116        var currentTask = null;
117        var currentPriorityLevel = NormalPriority;
118        var isPerformingWork = false;
119        var isHostCallbackScheduled = false;
120        var isHostTimeoutScheduled = false;
121        var localSetTimeout = typeof setTimeout === "function" ? setTimeout : null;
122        var localClearTimeout = typeof clearTimeout === "function" ? clearTimeout : null;
123        var localSetImmediate = typeof setImmediate !== "undefined" ? setImmediate : null;
124        var isInputPending = typeof navigator !== "undefined" && navigator.scheduling !== void 0 && navigator.scheduling.isInputPending !== void 0 ? navigator.scheduling.isInputPending.bind(navigator.scheduling) : null;
125        function advanceTimers(currentTime) {
126          var timer = peek(timerQueue);
127          while (timer !== null) {
128            if (timer.callback === null) {
129              pop(timerQueue);
130            } else if (timer.startTime <= currentTime) {
131              pop(timerQueue);
132              timer.sortIndex = timer.expirationTime;
133              push(taskQueue, timer);
134            } else {
135              return;
136            }
137            timer = peek(timerQueue);
138          }
139        }
140        function handleTimeout(currentTime) {
141          isHostTimeoutScheduled = false;
142          advanceTimers(currentTime);
143          if (!isHostCallbackScheduled) {
144            if (peek(taskQueue) !== null) {
145              isHostCallbackScheduled = true;
146              requestHostCallback(flushWork);
147            } else {
148              var firstTimer = peek(timerQueue);
149              if (firstTimer !== null) {
150                requestHostTimeout(handleTimeout, firstTimer.startTime - currentTime);
151              }
152            }
153          }
154        }
155        function flushWork(hasTimeRemaining, initialTime2) {
156          isHostCallbackScheduled = false;
157          if (isHostTimeoutScheduled) {
158            isHostTimeoutScheduled = false;
159            cancelHostTimeout();
160          }
161          isPerformingWork = true;
162          var previousPriorityLevel = currentPriorityLevel;
163          try {
164            if (enableProfiling) {
165              try {
166                return workLoop(hasTimeRemaining, initialTime2);
167              } catch (error) {
168                if (currentTask !== null) {
169                  var currentTime = exports.unstable_now();
170                  markTaskErrored(currentTask, currentTime);
171                  currentTask.isQueued = false;
172                }
173                throw error;
174              }
175            } else {
176              return workLoop(hasTimeRemaining, initialTime2);
177            }
178          } finally {
179            currentTask = null;
180            currentPriorityLevel = previousPriorityLevel;
181            isPerformingWork = false;
182          }
183        }
184        function workLoop(hasTimeRemaining, initialTime2) {
185          var currentTime = initialTime2;
186          advanceTimers(currentTime);
187          currentTask = peek(taskQueue);
188          while (currentTask !== null && !enableSchedulerDebugging) {
189            if (currentTask.expirationTime > currentTime && (!hasTimeRemaining || shouldYieldToHost())) {
190              break;
191            }
192            var callback = currentTask.callback;
193            if (typeof callback === "function") {
194              currentTask.callback = null;
195              currentPriorityLevel = currentTask.priorityLevel;
196              var didUserCallbackTimeout = currentTask.expirationTime <= currentTime;
197              var continuationCallback = callback(didUserCallbackTimeout);
198              currentTime = exports.unstable_now();
199              if (typeof continuationCallback === "function") {
200                currentTask.callback = continuationCallback;
201              } else {
202                if (currentTask === peek(taskQueue)) {
203                  pop(taskQueue);
204                }
205              }
206              advanceTimers(currentTime);
207            } else {
208              pop(taskQueue);
209            }
210            currentTask = peek(taskQueue);
211          }
212          if (currentTask !== null) {
213            return true;
214          } else {
215            var firstTimer = peek(timerQueue);
216            if (firstTimer !== null) {
217              requestHostTimeout(handleTimeout, firstTimer.startTime - currentTime);
218            }
219            return false;
220          }
221        }
222        function unstable_runWithPriority(priorityLevel, eventHandler) {
223          switch (priorityLevel) {
224            case ImmediatePriority:
225            case UserBlockingPriority:
226            case NormalPriority:
227            case LowPriority:
228            case IdlePriority:
229              break;
230            default:
231              priorityLevel = NormalPriority;
232          }
233          var previousPriorityLevel = currentPriorityLevel;
234          currentPriorityLevel = priorityLevel;
235          try {
236            return eventHandler();
237          } finally {
238            currentPriorityLevel = previousPriorityLevel;
239          }
240        }
241        function unstable_next(eventHandler) {
242          var priorityLevel;
243          switch (currentPriorityLevel) {
244            case ImmediatePriority:
245            case UserBlockingPriority:
246            case NormalPriority:
247              priorityLevel = NormalPriority;
248              break;
249            default:
250              priorityLevel = currentPriorityLevel;
251              break;
252          }
253          var previousPriorityLevel = currentPriorityLevel;
254          currentPriorityLevel = priorityLevel;
255          try {
256            return eventHandler();
257          } finally {
258            currentPriorityLevel = previousPriorityLevel;
259          }
260        }
261        function unstable_wrapCallback(callback) {
262          var parentPriorityLevel = currentPriorityLevel;
263          return function() {
264            var previousPriorityLevel = currentPriorityLevel;
265            currentPriorityLevel = parentPriorityLevel;
266            try {
267              return callback.apply(this, arguments);
268            } finally {
269              currentPriorityLevel = previousPriorityLevel;
270            }
271          };
272        }
273        function unstable_scheduleCallback(priorityLevel, callback, options) {
274          var currentTime = exports.unstable_now();
275          var startTime2;
276          if (typeof options === "object" && options !== null) {
277            var delay = options.delay;
278            if (typeof delay === "number" && delay > 0) {
279              startTime2 = currentTime + delay;
280            } else {
281              startTime2 = currentTime;
282            }
283          } else {
284            startTime2 = currentTime;
285          }
286          var timeout;
287          switch (priorityLevel) {
288            case ImmediatePriority:
289              timeout = IMMEDIATE_PRIORITY_TIMEOUT;
290              break;
291            case UserBlockingPriority:
292              timeout = USER_BLOCKING_PRIORITY_TIMEOUT;
293              break;
294            case IdlePriority:
295              timeout = IDLE_PRIORITY_TIMEOUT;
296              break;
297            case LowPriority:
298              timeout = LOW_PRIORITY_TIMEOUT;
299              break;
300            case NormalPriority:
301            default:
302              timeout = NORMAL_PRIORITY_TIMEOUT;
303              break;
304          }
305          var expirationTime = startTime2 + timeout;
306          var newTask = {
307            id: taskIdCounter++,
308            callback,
309            priorityLevel,
310            startTime: startTime2,
311            expirationTime,
312            sortIndex: -1
313          };
314          if (startTime2 > currentTime) {
315            newTask.sortIndex = startTime2;
316            push(timerQueue, newTask);
317            if (peek(taskQueue) === null && newTask === peek(timerQueue)) {
318              if (isHostTimeoutScheduled) {
319                cancelHostTimeout();
320              } else {
321                isHostTimeoutScheduled = true;
322              }
323              requestHostTimeout(handleTimeout, startTime2 - currentTime);
324            }
325          } else {
326            newTask.sortIndex = expirationTime;
327            push(taskQueue, newTask);
328            if (!isHostCallbackScheduled && !isPerformingWork) {
329              isHostCallbackScheduled = true;
330              requestHostCallback(flushWork);
331            }
332          }
333          return newTask;
334        }
335        function unstable_pauseExecution() {
336        }
337        function unstable_continueExecution() {
338          if (!isHostCallbackScheduled && !isPerformingWork) {
339            isHostCallbackScheduled = true;
340            requestHostCallback(flushWork);
341          }
342        }
343        function unstable_getFirstCallbackNode() {
344          return peek(taskQueue);
345        }
346        function unstable_cancelCallback(task) {
347          task.callback = null;
348        }
349        function unstable_getCurrentPriorityLevel() {
350          return currentPriorityLevel;
351        }
352        var isMessageLoopRunning = false;
353        var scheduledHostCallback = null;
354        var taskTimeoutID = -1;
355        var frameInterval = frameYieldMs;
356        var startTime = -1;
357        function shouldYieldToHost() {
358          var timeElapsed = exports.unstable_now() - startTime;
359          if (timeElapsed < frameInterval) {
360            return false;
361          }
362          return true;
363        }
364        function requestPaint() {
365        }
366        function forceFrameRate(fps) {
367          if (fps < 0 || fps > 125) {
368            console["error"]("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported");
369            return;
370          }
371          if (fps > 0) {
372            frameInterval = Math.floor(1e3 / fps);
373          } else {
374            frameInterval = frameYieldMs;
375          }
376        }
377        var performWorkUntilDeadline = function() {
378          if (scheduledHostCallback !== null) {
379            var currentTime = exports.unstable_now();
380            startTime = currentTime;
381            var hasTimeRemaining = true;
382            var hasMoreWork = true;
383            try {
384              hasMoreWork = scheduledHostCallback(hasTimeRemaining, currentTime);
385            } finally {
386              if (hasMoreWork) {
387                schedulePerformWorkUntilDeadline();
388              } else {
389                isMessageLoopRunning = false;
390                scheduledHostCallback = null;
391              }
392            }
393          } else {
394            isMessageLoopRunning = false;
395          }
396        };
397        var schedulePerformWorkUntilDeadline;
398        if (typeof localSetImmediate === "function") {
399          schedulePerformWorkUntilDeadline = function() {
400            localSetImmediate(performWorkUntilDeadline);
401          };
402        } else if (typeof MessageChannel !== "undefined") {
403          var channel = new MessageChannel();
404          var port = channel.port2;
405          channel.port1.onmessage = performWorkUntilDeadline;
406          schedulePerformWorkUntilDeadline = function() {
407            port.postMessage(null);
408          };
409        } else {
410          schedulePerformWorkUntilDeadline = function() {
411            localSetTimeout(performWorkUntilDeadline, 0);
412          };
413        }
414        function requestHostCallback(callback) {
415          scheduledHostCallback = callback;
416          if (!isMessageLoopRunning) {
417            isMessageLoopRunning = true;
418            schedulePerformWorkUntilDeadline();
419          }
420        }
421        function requestHostTimeout(callback, ms) {
422          taskTimeoutID = localSetTimeout(function() {
423            callback(exports.unstable_now());
424          }, ms);
425        }
426        function cancelHostTimeout() {
427          localClearTimeout(taskTimeoutID);
428          taskTimeoutID = -1;
429        }
430        var unstable_requestPaint = requestPaint;
431        var unstable_Profiling = null;
432        exports.unstable_IdlePriority = IdlePriority;
433        exports.unstable_ImmediatePriority = ImmediatePriority;
434        exports.unstable_LowPriority = LowPriority;
435        exports.unstable_NormalPriority = NormalPriority;
436        exports.unstable_Profiling = unstable_Profiling;
437        exports.unstable_UserBlockingPriority = UserBlockingPriority;
438        exports.unstable_cancelCallback = unstable_cancelCallback;
439        exports.unstable_continueExecution = unstable_continueExecution;
440        exports.unstable_forceFrameRate = forceFrameRate;
441        exports.unstable_getCurrentPriorityLevel = unstable_getCurrentPriorityLevel;
442        exports.unstable_getFirstCallbackNode = unstable_getFirstCallbackNode;
443        exports.unstable_next = unstable_next;
444        exports.unstable_pauseExecution = unstable_pauseExecution;
445        exports.unstable_requestPaint = unstable_requestPaint;
446        exports.unstable_runWithPriority = unstable_runWithPriority;
447        exports.unstable_scheduleCallback = unstable_scheduleCallback;
448        exports.unstable_shouldYield = shouldYieldToHost;
449        exports.unstable_wrapCallback = unstable_wrapCallback;
450        if (typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ !== "undefined" && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop === "function") {
451          __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(new Error());
452        }
453      })();
454    }
455  }
456});
457
vendor: 275 bytes, lines 458-469
458// node_modules/scheduler/index.js
459var require_scheduler = __commonJS({
460  "node_modules/scheduler/index.js"(exports, module) {
461    "use strict";
462    if (false) {
463      module.exports = null;
464    } else {
465      module.exports = require_scheduler_development();
466    }
467  }
468});
469
vendor: 909,274 bytes, lines 470-21575
470// node_modules/react-dom/cjs/react-dom.development.js
471var require_react_dom_development = __commonJS({
472  "node_modules/react-dom/cjs/react-dom.development.js"(exports) {
473    "use strict";
474    if (true) {
475      (function() {
476        "use strict";
477        if (typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ !== "undefined" && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart === "function") {
478          __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(new Error());
479        }
480        var React = require_react();
481        var Scheduler = require_scheduler();
482        var ReactSharedInternals = React.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
483        var suppressWarning = false;
484        function setSuppressWarning(newSuppressWarning) {
485          {
486            suppressWarning = newSuppressWarning;
487          }
488        }
489        function warn(format) {
490          {
491            if (!suppressWarning) {
492              for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
493                args[_key - 1] = arguments[_key];
494              }
495              printWarning("warn", format, args);
496            }
497          }
498        }
499        function error(format) {
500          {
501            if (!suppressWarning) {
502              for (var _len2 = arguments.length, args = new Array(_len2 > 1 ? _len2 - 1 : 0), _key2 = 1; _key2 < _len2; _key2++) {
503                args[_key2 - 1] = arguments[_key2];
504              }
505              printWarning("error", format, args);
506            }
507          }
508        }
509        function printWarning(level, format, args) {
510          {
511            var ReactDebugCurrentFrame2 = ReactSharedInternals.ReactDebugCurrentFrame;
512            var stack = ReactDebugCurrentFrame2.getStackAddendum();
513            if (stack !== "") {
514              format += "%s";
515              args = args.concat([stack]);
516            }
517            var argsWithFormat = args.map(function(item) {
518              return String(item);
519            });
520            argsWithFormat.unshift("Warning: " + format);
521            Function.prototype.apply.call(console[level], console, argsWithFormat);
522          }
523        }
524        var FunctionComponent = 0;
525        var ClassComponent = 1;
526        var IndeterminateComponent = 2;
527        var HostRoot = 3;
528        var HostPortal = 4;
529        var HostComponent = 5;
530        var HostText = 6;
531        var Fragment = 7;
532        var Mode = 8;
533        var ContextConsumer = 9;
534        var ContextProvider = 10;
535        var ForwardRef = 11;
536        var Profiler = 12;
537        var SuspenseComponent = 13;
538        var MemoComponent = 14;
539        var SimpleMemoComponent = 15;
540        var LazyComponent = 16;
541        var IncompleteClassComponent = 17;
542        var DehydratedFragment = 18;
543        var SuspenseListComponent = 19;
544        var ScopeComponent = 21;
545        var OffscreenComponent = 22;
546        var LegacyHiddenComponent = 23;
547        var CacheComponent = 24;
548        var TracingMarkerComponent = 25;
549        var enableClientRenderFallbackOnTextMismatch = true;
550        var enableNewReconciler = false;
551        var enableLazyContextPropagation = false;
552        var enableLegacyHidden = false;
553        var enableSuspenseAvoidThisFallback = false;
554        var disableCommentsAsDOMContainers = true;
555        var enableCustomElementPropertySupport = false;
556        var warnAboutStringRefs = true;
557        var enableSchedulingProfiler = true;
558        var enableProfilerTimer = true;
559        var enableProfilerCommitHooks = true;
560        var allNativeEvents = /* @__PURE__ */ new Set();
561        var registrationNameDependencies = {};
562        var possibleRegistrationNames = {};
563        function registerTwoPhaseEvent(registrationName, dependencies) {
564          registerDirectEvent(registrationName, dependencies);
565          registerDirectEvent(registrationName + "Capture", dependencies);
566        }
567        function registerDirectEvent(registrationName, dependencies) {
568          {
569            if (registrationNameDependencies[registrationName]) {
570              error("EventRegistry: More than one plugin attempted to publish the same registration name, `%s`.", registrationName);
571            }
572          }
573          registrationNameDependencies[registrationName] = dependencies;
574          {
575            var lowerCasedName = registrationName.toLowerCase();
576            possibleRegistrationNames[lowerCasedName] = registrationName;
577            if (registrationName === "onDoubleClick") {
578              possibleRegistrationNames.ondblclick = registrationName;
579            }
580          }
581          for (var i = 0; i < dependencies.length; i++) {
582            allNativeEvents.add(dependencies[i]);
583          }
584        }
585        var canUseDOM = !!(typeof window !== "undefined" && typeof window.document !== "undefined" && typeof window.document.createElement !== "undefined");
586        var hasOwnProperty = Object.prototype.hasOwnProperty;
587        function typeName(value) {
588          {
589            var hasToStringTag = typeof Symbol === "function" && Symbol.toStringTag;
590            var type = hasToStringTag && value[Symbol.toStringTag] || value.constructor.name || "Object";
591            return type;
592          }
593        }
594        function willCoercionThrow(value) {
595          {
596            try {
597              testStringCoercion(value);
598              return false;
599            } catch (e) {
600              return true;
601            }
602          }
603        }
604        function testStringCoercion(value) {
605          return "" + value;
606        }
607        function checkAttributeStringCoercion(value, attributeName) {
608          {
609            if (willCoercionThrow(value)) {
610              error("The provided `%s` attribute is an unsupported type %s. This value must be coerced to a string before before using it here.", attributeName, typeName(value));
611              return testStringCoercion(value);
612            }
613          }
614        }
615        function checkKeyStringCoercion(value) {
616          {
617            if (willCoercionThrow(value)) {
618              error("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", typeName(value));
619              return testStringCoercion(value);
620            }
621          }
622        }
623        function checkPropStringCoercion(value, propName) {
624          {
625            if (willCoercionThrow(value)) {
626              error("The provided `%s` prop is an unsupported type %s. This value must be coerced to a string before before using it here.", propName, typeName(value));
627              return testStringCoercion(value);
628            }
629          }
630        }
631        function checkCSSPropertyStringCoercion(value, propName) {
632          {
633            if (willCoercionThrow(value)) {
634              error("The provided `%s` CSS property is an unsupported type %s. This value must be coerced to a string before before using it here.", propName, typeName(value));
635              return testStringCoercion(value);
636            }
637          }
638        }
639        function checkHtmlStringCoercion(value) {
640          {
641            if (willCoercionThrow(value)) {
642              error("The provided HTML markup uses a value of unsupported type %s. This value must be coerced to a string before before using it here.", typeName(value));
643              return testStringCoercion(value);
644            }
645          }
646        }
647        function checkFormFieldValueStringCoercion(value) {
648          {
649            if (willCoercionThrow(value)) {
650              error("Form field values (value, checked, defaultValue, or defaultChecked props) must be strings, not %s. This value must be coerced to a string before before using it here.", typeName(value));
651              return testStringCoercion(value);
652            }
653          }
654        }
655        var RESERVED = 0;
656        var STRING = 1;
657        var BOOLEANISH_STRING = 2;
658        var BOOLEAN = 3;
659        var OVERLOADED_BOOLEAN = 4;
660        var NUMERIC = 5;
661        var POSITIVE_NUMERIC = 6;
662        var ATTRIBUTE_NAME_START_CHAR = ":A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD";
663        var ATTRIBUTE_NAME_CHAR = ATTRIBUTE_NAME_START_CHAR + "\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040";
664        var VALID_ATTRIBUTE_NAME_REGEX = new RegExp("^[" + ATTRIBUTE_NAME_START_CHAR + "][" + ATTRIBUTE_NAME_CHAR + "]*$");
665        var illegalAttributeNameCache = {};
666        var validatedAttributeNameCache = {};
667        function isAttributeNameSafe(attributeName) {
668          if (hasOwnProperty.call(validatedAttributeNameCache, attributeName)) {
669            return true;
670          }
671          if (hasOwnProperty.call(illegalAttributeNameCache, attributeName)) {
672            return false;
673          }
674          if (VALID_ATTRIBUTE_NAME_REGEX.test(attributeName)) {
675            validatedAttributeNameCache[attributeName] = true;
676            return true;
677          }
678          illegalAttributeNameCache[attributeName] = true;
679          {
680            error("Invalid attribute name: `%s`", attributeName);
681          }
682          return false;
683        }
684        function shouldIgnoreAttribute(name, propertyInfo, isCustomComponentTag) {
685          if (propertyInfo !== null) {
686            return propertyInfo.type === RESERVED;
687          }
688          if (isCustomComponentTag) {
689            return false;
690          }
691          if (name.length > 2 && (name[0] === "o" || name[0] === "O") && (name[1] === "n" || name[1] === "N")) {
692            return true;
693          }
694          return false;
695        }
696        function shouldRemoveAttributeWithWarning(name, value, propertyInfo, isCustomComponentTag) {
697          if (propertyInfo !== null && propertyInfo.type === RESERVED) {
698            return false;
699          }
700          switch (typeof value) {
701            case "function":
702            case "symbol":
703              return true;
704            case "boolean": {
705              if (isCustomComponentTag) {
706                return false;
707              }
708              if (propertyInfo !== null) {
709                return !propertyInfo.acceptsBooleans;
710              } else {
711                var prefix2 = name.toLowerCase().slice(0, 5);
712                return prefix2 !== "data-" && prefix2 !== "aria-";
713              }
714            }
715            default:
716              return false;
717          }
718        }
719        function shouldRemoveAttribute(name, value, propertyInfo, isCustomComponentTag) {
720          if (value === null || typeof value === "undefined") {
721            return true;
722          }
723          if (shouldRemoveAttributeWithWarning(name, value, propertyInfo, isCustomComponentTag)) {
724            return true;
725          }
726          if (isCustomComponentTag) {
727            return false;
728          }
729          if (propertyInfo !== null) {
730            switch (propertyInfo.type) {
731              case BOOLEAN:
732                return !value;
733              case OVERLOADED_BOOLEAN:
734                return value === false;
735              case NUMERIC:
736                return isNaN(value);
737              case POSITIVE_NUMERIC:
738                return isNaN(value) || value < 1;
739            }
740          }
741          return false;
742        }
743        function getPropertyInfo(name) {
744          return properties.hasOwnProperty(name) ? properties[name] : null;
745        }
746        function PropertyInfoRecord(name, type, mustUseProperty, attributeName, attributeNamespace, sanitizeURL2, removeEmptyString) {
747          this.acceptsBooleans = type === BOOLEANISH_STRING || type === BOOLEAN || type === OVERLOADED_BOOLEAN;
748          this.attributeName = attributeName;
749          this.attributeNamespace = attributeNamespace;
750          this.mustUseProperty = mustUseProperty;
751          this.propertyName = name;
752          this.type = type;
753          this.sanitizeURL = sanitizeURL2;
754          this.removeEmptyString = removeEmptyString;
755        }
756        var properties = {};
757        var reservedProps = [
758          "children",
759          "dangerouslySetInnerHTML",
760          // TODO: This prevents the assignment of defaultValue to regular
761          // elements (not just inputs). Now that ReactDOMInput assigns to the
762          // defaultValue property -- do we need this?
763          "defaultValue",
764          "defaultChecked",
765          "innerHTML",
766          "suppressContentEditableWarning",
767          "suppressHydrationWarning",
768          "style"
769        ];
770        reservedProps.forEach(function(name) {
771          properties[name] = new PropertyInfoRecord(
772            name,
773            RESERVED,
774            false,
775            // mustUseProperty
776            name,
777            // attributeName
778            null,
779            // attributeNamespace
780            false,
781            // sanitizeURL
782            false
783          );
784        });
785        [["acceptCharset", "accept-charset"], ["className", "class"], ["htmlFor", "for"], ["httpEquiv", "http-equiv"]].forEach(function(_ref) {
786          var name = _ref[0], attributeName = _ref[1];
787          properties[name] = new PropertyInfoRecord(
788            name,
789            STRING,
790            false,
791            // mustUseProperty
792            attributeName,
793            // attributeName
794            null,
795            // attributeNamespace
796            false,
797            // sanitizeURL
798            false
799          );
800        });
801        ["contentEditable", "draggable", "spellCheck", "value"].forEach(function(name) {
802          properties[name] = new PropertyInfoRecord(
803            name,
804            BOOLEANISH_STRING,
805            false,
806            // mustUseProperty
807            name.toLowerCase(),
808            // attributeName
809            null,
810            // attributeNamespace
811            false,
812            // sanitizeURL
813            false
814          );
815        });
816        ["autoReverse", "externalResourcesRequired", "focusable", "preserveAlpha"].forEach(function(name) {
817          properties[name] = new PropertyInfoRecord(
818            name,
819            BOOLEANISH_STRING,
820            false,
821            // mustUseProperty
822            name,
823            // attributeName
824            null,
825            // attributeNamespace
826            false,
827            // sanitizeURL
828            false
829          );
830        });
831        [
832          "allowFullScreen",
833          "async",
834          // Note: there is a special case that prevents it from being written to the DOM
835          // on the client side because the browsers are inconsistent. Instead we call focus().
836          "autoFocus",
837          "autoPlay",
838          "controls",
839          "default",
840          "defer",
841          "disabled",
842          "disablePictureInPicture",
843          "disableRemotePlayback",
844          "formNoValidate",
845          "hidden",
846          "loop",
847          "noModule",
848          "noValidate",
849          "open",
850          "playsInline",
851          "readOnly",
852          "required",
853          "reversed",
854          "scoped",
855          "seamless",
856          // Microdata
857          "itemScope"
858        ].forEach(function(name) {
859          properties[name] = new PropertyInfoRecord(
860            name,
861            BOOLEAN,
862            false,
863            // mustUseProperty
864            name.toLowerCase(),
865            // attributeName
866            null,
867            // attributeNamespace
868            false,
869            // sanitizeURL
870            false
871          );
872        });
873        [
874          "checked",
875          // Note: `option.selected` is not updated if `select.multiple` is
876          // disabled with `removeAttribute`. We have special logic for handling this.
877          "multiple",
878          "muted",
879          "selected"
880          // NOTE: if you add a camelCased prop to this list,
881          // you'll need to set attributeName to name.toLowerCase()
882          // instead in the assignment below.
883        ].forEach(function(name) {
884          properties[name] = new PropertyInfoRecord(
885            name,
886            BOOLEAN,
887            true,
888            // mustUseProperty
889            name,
890            // attributeName
891            null,
892            // attributeNamespace
893            false,
894            // sanitizeURL
895            false
896          );
897        });
898        [
899          "capture",
900          "download"
901          // NOTE: if you add a camelCased prop to this list,
902          // you'll need to set attributeName to name.toLowerCase()
903          // instead in the assignment below.
904        ].forEach(function(name) {
905          properties[name] = new PropertyInfoRecord(
906            name,
907            OVERLOADED_BOOLEAN,
908            false,
909            // mustUseProperty
910            name,
911            // attributeName
912            null,
913            // attributeNamespace
914            false,
915            // sanitizeURL
916            false
917          );
918        });
919        [
920          "cols",
921          "rows",
922          "size",
923          "span"
924          // NOTE: if you add a camelCased prop to this list,
925          // you'll need to set attributeName to name.toLowerCase()
926          // instead in the assignment below.
927        ].forEach(function(name) {
928          properties[name] = new PropertyInfoRecord(
929            name,
930            POSITIVE_NUMERIC,
931            false,
932            // mustUseProperty
933            name,
934            // attributeName
935            null,
936            // attributeNamespace
937            false,
938            // sanitizeURL
939            false
940          );
941        });
942        ["rowSpan", "start"].forEach(function(name) {
943          properties[name] = new PropertyInfoRecord(
944            name,
945            NUMERIC,
946            false,
947            // mustUseProperty
948            name.toLowerCase(),
949            // attributeName
950            null,
951            // attributeNamespace
952            false,
953            // sanitizeURL
954            false
955          );
956        });
957        var CAMELIZE = /[\-\:]([a-z])/g;
958        var capitalize = function(token) {
959          return token[1].toUpperCase();
960        };
961        [
962          "accent-height",
963          "alignment-baseline",
964          "arabic-form",
965          "baseline-shift",
966          "cap-height",
967          "clip-path",
968          "clip-rule",
969          "color-interpolation",
970          "color-interpolation-filters",
971          "color-profile",
972          "color-rendering",
973          "dominant-baseline",
974          "enable-background",
975          "fill-opacity",
976          "fill-rule",
977          "flood-color",
978          "flood-opacity",
979          "font-family",
980          "font-size",
981          "font-size-adjust",
982          "font-stretch",
983          "font-style",
984          "font-variant",
985          "font-weight",
986          "glyph-name",
987          "glyph-orientation-horizontal",
988          "glyph-orientation-vertical",
989          "horiz-adv-x",
990          "horiz-origin-x",
991          "image-rendering",
992          "letter-spacing",
993          "lighting-color",
994          "marker-end",
995          "marker-mid",
996          "marker-start",
997          "overline-position",
998          "overline-thickness",
999          "paint-order",
1000          "panose-1",
1001          "pointer-events",
1002          "rendering-intent",
1003          "shape-rendering",
1004          "stop-color",
1005          "stop-opacity",
1006          "strikethrough-position",
1007          "strikethrough-thickness",
1008          "stroke-dasharray",
1009          "stroke-dashoffset",
1010          "stroke-linecap",
1011          "stroke-linejoin",
1012          "stroke-miterlimit",
1013          "stroke-opacity",
1014          "stroke-width",
1015          "text-anchor",
1016          "text-decoration",
1017          "text-rendering",
1018          "underline-position",
1019          "underline-thickness",
1020          "unicode-bidi",
1021          "unicode-range",
1022          "units-per-em",
1023          "v-alphabetic",
1024          "v-hanging",
1025          "v-ideographic",
1026          "v-mathematical",
1027          "vector-effect",
1028          "vert-adv-y",
1029          "vert-origin-x",
1030          "vert-origin-y",
1031          "word-spacing",
1032          "writing-mode",
1033          "xmlns:xlink",
1034          "x-height"
1035          // NOTE: if you add a camelCased prop to this list,
1036          // you'll need to set attributeName to name.toLowerCase()
1037          // instead in the assignment below.
1038        ].forEach(function(attributeName) {
1039          var name = attributeName.replace(CAMELIZE, capitalize);
1040          properties[name] = new PropertyInfoRecord(
1041            name,
1042            STRING,
1043            false,
1044            // mustUseProperty
1045            attributeName,
1046            null,
1047            // attributeNamespace
1048            false,
1049            // sanitizeURL
1050            false
1051          );
1052        });
1053        [
1054          "xlink:actuate",
1055          "xlink:arcrole",
1056          "xlink:role",
1057          "xlink:show",
1058          "xlink:title",
1059          "xlink:type"
1060          // NOTE: if you add a camelCased prop to this list,
1061          // you'll need to set attributeName to name.toLowerCase()
1062          // instead in the assignment below.
1063        ].forEach(function(attributeName) {
1064          var name = attributeName.replace(CAMELIZE, capitalize);
1065          properties[name] = new PropertyInfoRecord(
1066            name,
1067            STRING,
1068            false,
1069            // mustUseProperty
1070            attributeName,
1071            "http://www.w3.org/1999/xlink",
1072            false,
1073            // sanitizeURL
1074            false
1075          );
1076        });
1077        [
1078          "xml:base",
1079          "xml:lang",
1080          "xml:space"
1081          // NOTE: if you add a camelCased prop to this list,
1082          // you'll need to set attributeName to name.toLowerCase()
1083          // instead in the assignment below.
1084        ].forEach(function(attributeName) {
1085          var name = attributeName.replace(CAMELIZE, capitalize);
1086          properties[name] = new PropertyInfoRecord(
1087            name,
1088            STRING,
1089            false,
1090            // mustUseProperty
1091            attributeName,
1092            "http://www.w3.org/XML/1998/namespace",
1093            false,
1094            // sanitizeURL
1095            false
1096          );
1097        });
1098        ["tabIndex", "crossOrigin"].forEach(function(attributeName) {
1099          properties[attributeName] = new PropertyInfoRecord(
1100            attributeName,
1101            STRING,
1102            false,
1103            // mustUseProperty
1104            attributeName.toLowerCase(),
1105            // attributeName
1106            null,
1107            // attributeNamespace
1108            false,
1109            // sanitizeURL
1110            false
1111          );
1112        });
1113        var xlinkHref = "xlinkHref";
1114        properties[xlinkHref] = new PropertyInfoRecord(
1115          "xlinkHref",
1116          STRING,
1117          false,
1118          // mustUseProperty
1119          "xlink:href",
1120          "http://www.w3.org/1999/xlink",
1121          true,
1122          // sanitizeURL
1123          false
1124        );
1125        ["src", "href", "action", "formAction"].forEach(function(attributeName) {
1126          properties[attributeName] = new PropertyInfoRecord(
1127            attributeName,
1128            STRING,
1129            false,
1130            // mustUseProperty
1131            attributeName.toLowerCase(),
1132            // attributeName
1133            null,
1134            // attributeNamespace
1135            true,
1136            // sanitizeURL
1137            true
1138          );
1139        });
1140        var isJavaScriptProtocol = /^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*\:/i;
1141        var didWarn = false;
1142        function sanitizeURL(url) {
1143          {
1144            if (!didWarn && isJavaScriptProtocol.test(url)) {
1145              didWarn = true;
1146              error("A future version of React will block javascript: URLs as a security precaution. Use event handlers instead if you can. If you need to generate unsafe HTML try using dangerouslySetInnerHTML instead. React was passed %s.", JSON.stringify(url));
1147            }
1148          }
1149        }
1150        function getValueForProperty(node, name, expected, propertyInfo) {
1151          {
1152            if (propertyInfo.mustUseProperty) {
1153              var propertyName = propertyInfo.propertyName;
1154              return node[propertyName];
1155            } else {
1156              {
1157                checkAttributeStringCoercion(expected, name);
1158              }
1159              if (propertyInfo.sanitizeURL) {
1160                sanitizeURL("" + expected);
1161              }
1162              var attributeName = propertyInfo.attributeName;
1163              var stringValue = null;
1164              if (propertyInfo.type === OVERLOADED_BOOLEAN) {
1165                if (node.hasAttribute(attributeName)) {
1166                  var value = node.getAttribute(attributeName);
1167                  if (value === "") {
1168                    return true;
1169                  }
1170                  if (shouldRemoveAttribute(name, expected, propertyInfo, false)) {
1171                    return value;
1172                  }
1173                  if (value === "" + expected) {
1174                    return expected;
1175                  }
1176                  return value;
1177                }
1178              } else if (node.hasAttribute(attributeName)) {
1179                if (shouldRemoveAttribute(name, expected, propertyInfo, false)) {
1180                  return node.getAttribute(attributeName);
1181                }
1182                if (propertyInfo.type === BOOLEAN) {
1183                  return expected;
1184                }
1185                stringValue = node.getAttribute(attributeName);
1186              }
1187              if (shouldRemoveAttribute(name, expected, propertyInfo, false)) {
1188                return stringValue === null ? expected : stringValue;
1189              } else if (stringValue === "" + expected) {
1190                return expected;
1191              } else {
1192                return stringValue;
1193              }
1194            }
1195          }
1196        }
1197        function getValueForAttribute(node, name, expected, isCustomComponentTag) {
1198          {
1199            if (!isAttributeNameSafe(name)) {
1200              return;
1201            }
1202            if (!node.hasAttribute(name)) {
1203              return expected === void 0 ? void 0 : null;
1204            }
1205            var value = node.getAttribute(name);
1206            {
1207              checkAttributeStringCoercion(expected, name);
1208            }
1209            if (value === "" + expected) {
1210              return expected;
1211            }
1212            return value;
1213          }
1214        }
1215        function setValueForProperty(node, name, value, isCustomComponentTag) {
1216          var propertyInfo = getPropertyInfo(name);
1217          if (shouldIgnoreAttribute(name, propertyInfo, isCustomComponentTag)) {
1218            return;
1219          }
1220          if (shouldRemoveAttribute(name, value, propertyInfo, isCustomComponentTag)) {
1221            value = null;
1222          }
1223          if (isCustomComponentTag || propertyInfo === null) {
1224            if (isAttributeNameSafe(name)) {
1225              var _attributeName = name;
1226              if (value === null) {
1227                node.removeAttribute(_attributeName);
1228              } else {
1229                {
1230                  checkAttributeStringCoercion(value, name);
1231                }
1232                node.setAttribute(_attributeName, "" + value);
1233              }
1234            }
1235            return;
1236          }
1237          var mustUseProperty = propertyInfo.mustUseProperty;
1238          if (mustUseProperty) {
1239            var propertyName = propertyInfo.propertyName;
1240            if (value === null) {
1241              var type = propertyInfo.type;
1242              node[propertyName] = type === BOOLEAN ? false : "";
1243            } else {
1244              node[propertyName] = value;
1245            }
1246            return;
1247          }
1248          var attributeName = propertyInfo.attributeName, attributeNamespace = propertyInfo.attributeNamespace;
1249          if (value === null) {
1250            node.removeAttribute(attributeName);
1251          } else {
1252            var _type = propertyInfo.type;
1253            var attributeValue;
1254            if (_type === BOOLEAN || _type === OVERLOADED_BOOLEAN && value === true) {
1255              attributeValue = "";
1256            } else {
1257              {
1258                {
1259                  checkAttributeStringCoercion(value, attributeName);
1260                }
1261                attributeValue = "" + value;
1262              }
1263              if (propertyInfo.sanitizeURL) {
1264                sanitizeURL(attributeValue.toString());
1265              }
1266            }
1267            if (attributeNamespace) {
1268              node.setAttributeNS(attributeNamespace, attributeName, attributeValue);
1269            } else {
1270              node.setAttribute(attributeName, attributeValue);
1271            }
1272          }
1273        }
1274        var REACT_ELEMENT_TYPE = Symbol.for("react.element");
1275        var REACT_PORTAL_TYPE = Symbol.for("react.portal");
1276        var REACT_FRAGMENT_TYPE = Symbol.for("react.fragment");
1277        var REACT_STRICT_MODE_TYPE = Symbol.for("react.strict_mode");
1278        var REACT_PROFILER_TYPE = Symbol.for("react.profiler");
1279        var REACT_PROVIDER_TYPE = Symbol.for("react.provider");
1280        var REACT_CONTEXT_TYPE = Symbol.for("react.context");
1281        var REACT_FORWARD_REF_TYPE = Symbol.for("react.forward_ref");
1282        var REACT_SUSPENSE_TYPE = Symbol.for("react.suspense");
1283        var REACT_SUSPENSE_LIST_TYPE = Symbol.for("react.suspense_list");
1284        var REACT_MEMO_TYPE = Symbol.for("react.memo");
1285        var REACT_LAZY_TYPE = Symbol.for("react.lazy");
1286        var REACT_SCOPE_TYPE = Symbol.for("react.scope");
1287        var REACT_DEBUG_TRACING_MODE_TYPE = Symbol.for("react.debug_trace_mode");
1288        var REACT_OFFSCREEN_TYPE = Symbol.for("react.offscreen");
1289        var REACT_LEGACY_HIDDEN_TYPE = Symbol.for("react.legacy_hidden");
1290        var REACT_CACHE_TYPE = Symbol.for("react.cache");
1291        var REACT_TRACING_MARKER_TYPE = Symbol.for("react.tracing_marker");
1292        var MAYBE_ITERATOR_SYMBOL = Symbol.iterator;
1293        var FAUX_ITERATOR_SYMBOL = "@@iterator";
1294        function getIteratorFn(maybeIterable) {
1295          if (maybeIterable === null || typeof maybeIterable !== "object") {
1296            return null;
1297          }
1298          var maybeIterator = MAYBE_ITERATOR_SYMBOL && maybeIterable[MAYBE_ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL];
1299          if (typeof maybeIterator === "function") {
1300            return maybeIterator;
1301          }
1302          return null;
1303        }
1304        var assign = Object.assign;
1305        var disabledDepth = 0;
1306        var prevLog;
1307        var prevInfo;
1308        var prevWarn;
1309        var prevError;
1310        var prevGroup;
1311        var prevGroupCollapsed;
1312        var prevGroupEnd;
1313        function disabledLog() {
1314        }
1315        disabledLog.__reactDisabledLog = true;
1316        function disableLogs() {
1317          {
1318            if (disabledDepth === 0) {
1319              prevLog = console.log;
1320              prevInfo = console.info;
1321              prevWarn = console.warn;
1322              prevError = console.error;
1323              prevGroup = console.group;
1324              prevGroupCollapsed = console.groupCollapsed;
1325              prevGroupEnd = console.groupEnd;
1326              var props = {
1327                configurable: true,
1328                enumerable: true,
1329                value: disabledLog,
1330                writable: true
1331              };
1332              Object.defineProperties(console, {
1333                info: props,
1334                log: props,
1335                warn: props,
1336                error: props,
1337                group: props,
1338                groupCollapsed: props,
1339                groupEnd: props
1340              });
1341            }
1342            disabledDepth++;
1343          }
1344        }
1345        function reenableLogs() {
1346          {
1347            disabledDepth--;
1348            if (disabledDepth === 0) {
1349              var props = {
1350                configurable: true,
1351                enumerable: true,
1352                writable: true
1353              };
1354              Object.defineProperties(console, {
1355                log: assign({}, props, {
1356                  value: prevLog
1357                }),
1358                info: assign({}, props, {
1359                  value: prevInfo
1360                }),
1361                warn: assign({}, props, {
1362                  value: prevWarn
1363                }),
1364                error: assign({}, props, {
1365                  value: prevError
1366                }),
1367                group: assign({}, props, {
1368                  value: prevGroup
1369                }),
1370                groupCollapsed: assign({}, props, {
1371                  value: prevGroupCollapsed
1372                }),
1373                groupEnd: assign({}, props, {
1374                  value: prevGroupEnd
1375                })
1376              });
1377            }
1378            if (disabledDepth < 0) {
1379              error("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
1380            }
1381          }
1382        }
1383        var ReactCurrentDispatcher = ReactSharedInternals.ReactCurrentDispatcher;
1384        var prefix;
1385        function describeBuiltInComponentFrame(name, source, ownerFn) {
1386          {
1387            if (prefix === void 0) {
1388              try {
1389                throw Error();
1390              } catch (x) {
1391                var match = x.stack.trim().match(/\n( *(at )?)/);
1392                prefix = match && match[1] || "";
1393              }
1394            }
1395            return "\n" + prefix + name;
1396          }
1397        }
1398        var reentry = false;
1399        var componentFrameCache;
1400        {
1401          var PossiblyWeakMap = typeof WeakMap === "function" ? WeakMap : Map;
1402          componentFrameCache = new PossiblyWeakMap();
1403        }
1404        function describeNativeComponentFrame(fn, construct) {
1405          if (!fn || reentry) {
1406            return "";
1407          }
1408          {
1409            var frame = componentFrameCache.get(fn);
1410            if (frame !== void 0) {
1411              return frame;
1412            }
1413          }
1414          var control;
1415          reentry = true;
1416          var previousPrepareStackTrace = Error.prepareStackTrace;
1417          Error.prepareStackTrace = void 0;
1418          var previousDispatcher;
1419          {
1420            previousDispatcher = ReactCurrentDispatcher.current;
1421            ReactCurrentDispatcher.current = null;
1422            disableLogs();
1423          }
1424          try {
1425            if (construct) {
1426              var Fake = function() {
1427                throw Error();
1428              };
1429              Object.defineProperty(Fake.prototype, "props", {
1430                set: function() {
1431                  throw Error();
1432                }
1433              });
1434              if (typeof Reflect === "object" && Reflect.construct) {
1435                try {
1436                  Reflect.construct(Fake, []);
1437                } catch (x) {
1438                  control = x;
1439                }
1440                Reflect.construct(fn, [], Fake);
1441              } else {
1442                try {
1443                  Fake.call();
1444                } catch (x) {
1445                  control = x;
1446                }
1447                fn.call(Fake.prototype);
1448              }
1449            } else {
1450              try {
1451                throw Error();
1452              } catch (x) {
1453                control = x;
1454              }
1455              fn();
1456            }
1457          } catch (sample) {
1458            if (sample && control && typeof sample.stack === "string") {
1459              var sampleLines = sample.stack.split("\n");
1460              var controlLines = control.stack.split("\n");
1461              var s = sampleLines.length - 1;
1462              var c = controlLines.length - 1;
1463              while (s >= 1 && c >= 0 && sampleLines[s] !== controlLines[c]) {
1464                c--;
1465              }
1466              for (; s >= 1 && c >= 0; s--, c--) {
1467                if (sampleLines[s] !== controlLines[c]) {
1468                  if (s !== 1 || c !== 1) {
1469                    do {
1470                      s--;
1471                      c--;
1472                      if (c < 0 || sampleLines[s] !== controlLines[c]) {
1473                        var _frame = "\n" + sampleLines[s].replace(" at new ", " at ");
1474                        if (fn.displayName && _frame.includes("<anonymous>")) {
1475                          _frame = _frame.replace("<anonymous>", fn.displayName);
1476                        }
1477                        {
1478                          if (typeof fn === "function") {
1479                            componentFrameCache.set(fn, _frame);
1480                          }
1481                        }
1482                        return _frame;
1483                      }
1484                    } while (s >= 1 && c >= 0);
1485                  }
1486                  break;
1487                }
1488              }
1489            }
1490          } finally {
1491            reentry = false;
1492            {
1493              ReactCurrentDispatcher.current = previousDispatcher;
1494              reenableLogs();
1495            }
1496            Error.prepareStackTrace = previousPrepareStackTrace;
1497          }
1498          var name = fn ? fn.displayName || fn.name : "";
1499          var syntheticFrame = name ? describeBuiltInComponentFrame(name) : "";
1500          {
1501            if (typeof fn === "function") {
1502              componentFrameCache.set(fn, syntheticFrame);
1503            }
1504          }
1505          return syntheticFrame;
1506        }
1507        function describeClassComponentFrame(ctor, source, ownerFn) {
1508          {
1509            return describeNativeComponentFrame(ctor, true);
1510          }
1511        }
1512        function describeFunctionComponentFrame(fn, source, ownerFn) {
1513          {
1514            return describeNativeComponentFrame(fn, false);
1515          }
1516        }
1517        function shouldConstruct(Component) {
1518          var prototype = Component.prototype;
1519          return !!(prototype && prototype.isReactComponent);
1520        }
1521        function describeUnknownElementTypeFrameInDEV(type, source, ownerFn) {
1522          if (type == null) {
1523            return "";
1524          }
1525          if (typeof type === "function") {
1526            {
1527              return describeNativeComponentFrame(type, shouldConstruct(type));
1528            }
1529          }
1530          if (typeof type === "string") {
1531            return describeBuiltInComponentFrame(type);
1532          }
1533          switch (type) {
1534            case REACT_SUSPENSE_TYPE:
1535              return describeBuiltInComponentFrame("Suspense");
1536            case REACT_SUSPENSE_LIST_TYPE:
1537              return describeBuiltInComponentFrame("SuspenseList");
1538          }
1539          if (typeof type === "object") {
1540            switch (type.$$typeof) {
1541              case REACT_FORWARD_REF_TYPE:
1542                return describeFunctionComponentFrame(type.render);
1543              case REACT_MEMO_TYPE:
1544                return describeUnknownElementTypeFrameInDEV(type.type, source, ownerFn);
1545              case REACT_LAZY_TYPE: {
1546                var lazyComponent = type;
1547                var payload = lazyComponent._payload;
1548                var init = lazyComponent._init;
1549                try {
1550                  return describeUnknownElementTypeFrameInDEV(init(payload), source, ownerFn);
1551                } catch (x) {
1552                }
1553              }
1554            }
1555          }
1556          return "";
1557        }
1558        function describeFiber(fiber) {
1559          var owner = fiber._debugOwner ? fiber._debugOwner.type : null;
1560          var source = fiber._debugSource;
1561          switch (fiber.tag) {
1562            case HostComponent:
1563              return describeBuiltInComponentFrame(fiber.type);
1564            case LazyComponent:
1565              return describeBuiltInComponentFrame("Lazy");
1566            case SuspenseComponent:
1567              return describeBuiltInComponentFrame("Suspense");
1568            case SuspenseListComponent:
1569              return describeBuiltInComponentFrame("SuspenseList");
1570            case FunctionComponent:
1571            case IndeterminateComponent:
1572            case SimpleMemoComponent:
1573              return describeFunctionComponentFrame(fiber.type);
1574            case ForwardRef:
1575              return describeFunctionComponentFrame(fiber.type.render);
1576            case ClassComponent:
1577              return describeClassComponentFrame(fiber.type);
1578            default:
1579              return "";
1580          }
1581        }
1582        function getStackByFiberInDevAndProd(workInProgress2) {
1583          try {
1584            var info = "";
1585            var node = workInProgress2;
1586            do {
1587              info += describeFiber(node);
1588              node = node.return;
1589            } while (node);
1590            return info;
1591          } catch (x) {
1592            return "\nError generating stack: " + x.message + "\n" + x.stack;
1593          }
1594        }
1595        function getWrappedName(outerType, innerType, wrapperName) {
1596          var displayName = outerType.displayName;
1597          if (displayName) {
1598            return displayName;
1599          }
1600          var functionName = innerType.displayName || innerType.name || "";
1601          return functionName !== "" ? wrapperName + "(" + functionName + ")" : wrapperName;
1602        }
1603        function getContextName(type) {
1604          return type.displayName || "Context";
1605        }
1606        function getComponentNameFromType(type) {
1607          if (type == null) {
1608            return null;
1609          }
1610          {
1611            if (typeof type.tag === "number") {
1612              error("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue.");
1613            }
1614          }
1615          if (typeof type === "function") {
1616            return type.displayName || type.name || null;
1617          }
1618          if (typeof type === "string") {
1619            return type;
1620          }
1621          switch (type) {
1622            case REACT_FRAGMENT_TYPE:
1623              return "Fragment";
1624            case REACT_PORTAL_TYPE:
1625              return "Portal";
1626            case REACT_PROFILER_TYPE:
1627              return "Profiler";
1628            case REACT_STRICT_MODE_TYPE:
1629              return "StrictMode";
1630            case REACT_SUSPENSE_TYPE:
1631              return "Suspense";
1632            case REACT_SUSPENSE_LIST_TYPE:
1633              return "SuspenseList";
1634          }
1635          if (typeof type === "object") {
1636            switch (type.$$typeof) {
1637              case REACT_CONTEXT_TYPE:
1638                var context = type;
1639                return getContextName(context) + ".Consumer";
1640              case REACT_PROVIDER_TYPE:
1641                var provider = type;
1642                return getContextName(provider._context) + ".Provider";
1643              case REACT_FORWARD_REF_TYPE:
1644                return getWrappedName(type, type.render, "ForwardRef");
1645              case REACT_MEMO_TYPE:
1646                var outerName = type.displayName || null;
1647                if (outerName !== null) {
1648                  return outerName;
1649                }
1650                return getComponentNameFromType(type.type) || "Memo";
1651              case REACT_LAZY_TYPE: {
1652                var lazyComponent = type;
1653                var payload = lazyComponent._payload;
1654                var init = lazyComponent._init;
1655                try {
1656                  return getComponentNameFromType(init(payload));
1657                } catch (x) {
1658                  return null;
1659                }
1660              }
1661            }
1662          }
1663          return null;
1664        }
1665        function getWrappedName$1(outerType, innerType, wrapperName) {
1666          var functionName = innerType.displayName || innerType.name || "";
1667          return outerType.displayName || (functionName !== "" ? wrapperName + "(" + functionName + ")" : wrapperName);
1668        }
1669        function getContextName$1(type) {
1670          return type.displayName || "Context";
1671        }
1672        function getComponentNameFromFiber(fiber) {
1673          var tag = fiber.tag, type = fiber.type;
1674          switch (tag) {
1675            case CacheComponent:
1676              return "Cache";
1677            case ContextConsumer:
1678              var context = type;
1679              return getContextName$1(context) + ".Consumer";
1680            case ContextProvider:
1681              var provider = type;
1682              return getContextName$1(provider._context) + ".Provider";
1683            case DehydratedFragment:
1684              return "DehydratedFragment";
1685            case ForwardRef:
1686              return getWrappedName$1(type, type.render, "ForwardRef");
1687            case Fragment:
1688              return "Fragment";
1689            case HostComponent:
1690              return type;
1691            case HostPortal:
1692              return "Portal";
1693            case HostRoot:
1694              return "Root";
1695            case HostText:
1696              return "Text";
1697            case LazyComponent:
1698              return getComponentNameFromType(type);
1699            case Mode:
1700              if (type === REACT_STRICT_MODE_TYPE) {
1701                return "StrictMode";
1702              }
1703              return "Mode";
1704            case OffscreenComponent:
1705              return "Offscreen";
1706            case Profiler:
1707              return "Profiler";
1708            case ScopeComponent:
1709              return "Scope";
1710            case SuspenseComponent:
1711              return "Suspense";
1712            case SuspenseListComponent:
1713              return "SuspenseList";
1714            case TracingMarkerComponent:
1715              return "TracingMarker";
1716            case ClassComponent:
1717            case FunctionComponent:
1718            case IncompleteClassComponent:
1719            case IndeterminateComponent:
1720            case MemoComponent:
1721            case SimpleMemoComponent:
1722              if (typeof type === "function") {
1723                return type.displayName || type.name || null;
1724              }
1725              if (typeof type === "string") {
1726                return type;
1727              }
1728              break;
1729          }
1730          return null;
1731        }
1732        var ReactDebugCurrentFrame = ReactSharedInternals.ReactDebugCurrentFrame;
1733        var current = null;
1734        var isRendering = false;
1735        function getCurrentFiberOwnerNameInDevOrNull() {
1736          {
1737            if (current === null) {
1738              return null;
1739            }
1740            var owner = current._debugOwner;
1741            if (owner !== null && typeof owner !== "undefined") {
1742              return getComponentNameFromFiber(owner);
1743            }
1744          }
1745          return null;
1746        }
1747        function getCurrentFiberStackInDev() {
1748          {
1749            if (current === null) {
1750              return "";
1751            }
1752            return getStackByFiberInDevAndProd(current);
1753          }
1754        }
1755        function resetCurrentFiber() {
1756          {
1757            ReactDebugCurrentFrame.getCurrentStack = null;
1758            current = null;
1759            isRendering = false;
1760          }
1761        }
1762        function setCurrentFiber(fiber) {
1763          {
1764            ReactDebugCurrentFrame.getCurrentStack = fiber === null ? null : getCurrentFiberStackInDev;
1765            current = fiber;
1766            isRendering = false;
1767          }
1768        }
1769        function getCurrentFiber() {
1770          {
1771            return current;
1772          }
1773        }
1774        function setIsRendering(rendering) {
1775          {
1776            isRendering = rendering;
1777          }
1778        }
1779        function toString(value) {
1780          return "" + value;
1781        }
1782        function getToStringValue(value) {
1783          switch (typeof value) {
1784            case "boolean":
1785            case "number":
1786            case "string":
1787            case "undefined":
1788              return value;
1789            case "object":
1790              {
1791                checkFormFieldValueStringCoercion(value);
1792              }
1793              return value;
1794            default:
1795              return "";
1796          }
1797        }
1798        var hasReadOnlyValue = {
1799          button: true,
1800          checkbox: true,
1801          image: true,
1802          hidden: true,
1803          radio: true,
1804          reset: true,
1805          submit: true
1806        };
1807        function checkControlledValueProps(tagName, props) {
1808          {
1809            if (!(hasReadOnlyValue[props.type] || props.onChange || props.onInput || props.readOnly || props.disabled || props.value == null)) {
1810              error("You provided a `value` prop to a form field without an `onChange` handler. This will render a read-only field. If the field should be mutable use `defaultValue`. Otherwise, set either `onChange` or `readOnly`.");
1811            }
1812            if (!(props.onChange || props.readOnly || props.disabled || props.checked == null)) {
1813              error("You provided a `checked` prop to a form field without an `onChange` handler. This will render a read-only field. If the field should be mutable use `defaultChecked`. Otherwise, set either `onChange` or `readOnly`.");
1814            }
1815          }
1816        }
1817        function isCheckable(elem) {
1818          var type = elem.type;
1819          var nodeName = elem.nodeName;
1820          return nodeName && nodeName.toLowerCase() === "input" && (type === "checkbox" || type === "radio");
1821        }
1822        function getTracker(node) {
1823          return node._valueTracker;
1824        }
1825        function detachTracker(node) {
1826          node._valueTracker = null;
1827        }
1828        function getValueFromNode(node) {
1829          var value = "";
1830          if (!node) {
1831            return value;
1832          }
1833          if (isCheckable(node)) {
1834            value = node.checked ? "true" : "false";
1835          } else {
1836            value = node.value;
1837          }
1838          return value;
1839        }
1840        function trackValueOnNode(node) {
1841          var valueField = isCheckable(node) ? "checked" : "value";
1842          var descriptor = Object.getOwnPropertyDescriptor(node.constructor.prototype, valueField);
1843          {
1844            checkFormFieldValueStringCoercion(node[valueField]);
1845          }
1846          var currentValue = "" + node[valueField];
1847          if (node.hasOwnProperty(valueField) || typeof descriptor === "undefined" || typeof descriptor.get !== "function" || typeof descriptor.set !== "function") {
1848            return;
1849          }
1850          var get2 = descriptor.get, set2 = descriptor.set;
1851          Object.defineProperty(node, valueField, {
1852            configurable: true,
1853            get: function() {
1854              return get2.call(this);
1855            },
1856            set: function(value) {
1857              {
1858                checkFormFieldValueStringCoercion(value);
1859              }
1860              currentValue = "" + value;
1861              set2.call(this, value);
1862            }
1863          });
1864          Object.defineProperty(node, valueField, {
1865            enumerable: descriptor.enumerable
1866          });
1867          var tracker = {
1868            getValue: function() {
1869              return currentValue;
1870            },
1871            setValue: function(value) {
1872              {
1873                checkFormFieldValueStringCoercion(value);
1874              }
1875              currentValue = "" + value;
1876            },
1877            stopTracking: function() {
1878              detachTracker(node);
1879              delete node[valueField];
1880            }
1881          };
1882          return tracker;
1883        }
1884        function track(node) {
1885          if (getTracker(node)) {
1886            return;
1887          }
1888          node._valueTracker = trackValueOnNode(node);
1889        }
1890        function updateValueIfChanged(node) {
1891          if (!node) {
1892            return false;
1893          }
1894          var tracker = getTracker(node);
1895          if (!tracker) {
1896            return true;
1897          }
1898          var lastValue = tracker.getValue();
1899          var nextValue = getValueFromNode(node);
1900          if (nextValue !== lastValue) {
1901            tracker.setValue(nextValue);
1902            return true;
1903          }
1904          return false;
1905        }
1906        function getActiveElement(doc) {
1907          doc = doc || (typeof document !== "undefined" ? document : void 0);
1908          if (typeof doc === "undefined") {
1909            return null;
1910          }
1911          try {
1912            return doc.activeElement || doc.body;
1913          } catch (e) {
1914            return doc.body;
1915          }
1916        }
1917        var didWarnValueDefaultValue = false;
1918        var didWarnCheckedDefaultChecked = false;
1919        var didWarnControlledToUncontrolled = false;
1920        var didWarnUncontrolledToControlled = false;
1921        function isControlled(props) {
1922          var usesChecked = props.type === "checkbox" || props.type === "radio";
1923          return usesChecked ? props.checked != null : props.value != null;
1924        }
1925        function getHostProps(element, props) {
1926          var node = element;
1927          var checked = props.checked;
1928          var hostProps = assign({}, props, {
1929            defaultChecked: void 0,
1930            defaultValue: void 0,
1931            value: void 0,
1932            checked: checked != null ? checked : node._wrapperState.initialChecked
1933          });
1934          return hostProps;
1935        }
1936        function initWrapperState(element, props) {
1937          {
1938            checkControlledValueProps("input", props);
1939            if (props.checked !== void 0 && props.defaultChecked !== void 0 && !didWarnCheckedDefaultChecked) {
1940              error("%s contains an input of type %s with both checked and defaultChecked props. Input elements must be either controlled or uncontrolled (specify either the checked prop, or the defaultChecked prop, but not both). Decide between using a controlled or uncontrolled input element and remove one of these props. More info: https://reactjs.org/link/controlled-components", getCurrentFiberOwnerNameInDevOrNull() || "A component", props.type);
1941              didWarnCheckedDefaultChecked = true;
1942            }
1943            if (props.value !== void 0 && props.defaultValue !== void 0 && !didWarnValueDefaultValue) {
1944              error("%s contains an input of type %s with both value and defaultValue props. Input elements must be either controlled or uncontrolled (specify either the value prop, or the defaultValue prop, but not both). Decide between using a controlled or uncontrolled input element and remove one of these props. More info: https://reactjs.org/link/controlled-components", getCurrentFiberOwnerNameInDevOrNull() || "A component", props.type);
1945              didWarnValueDefaultValue = true;
1946            }
1947          }
1948          var node = element;
1949          var defaultValue = props.defaultValue == null ? "" : props.defaultValue;
1950          node._wrapperState = {
1951            initialChecked: props.checked != null ? props.checked : props.defaultChecked,
1952            initialValue: getToStringValue(props.value != null ? props.value : defaultValue),
1953            controlled: isControlled(props)
1954          };
1955        }
1956        function updateChecked(element, props) {
1957          var node = element;
1958          var checked = props.checked;
1959          if (checked != null) {
1960            setValueForProperty(node, "checked", checked, false);
1961          }
1962        }
1963        function updateWrapper(element, props) {
1964          var node = element;
1965          {
1966            var controlled = isControlled(props);
1967            if (!node._wrapperState.controlled && controlled && !didWarnUncontrolledToControlled) {
1968              error("A component is changing an uncontrolled input to be controlled. This is likely caused by the value changing from undefined to a defined value, which should not happen. Decide between using a controlled or uncontrolled input element for the lifetime of the component. More info: https://reactjs.org/link/controlled-components");
1969              didWarnUncontrolledToControlled = true;
1970            }
1971            if (node._wrapperState.controlled && !controlled && !didWarnControlledToUncontrolled) {
1972              error("A component is changing a controlled input to be uncontrolled. This is likely caused by the value changing from a defined to undefined, which should not happen. Decide between using a controlled or uncontrolled input element for the lifetime of the component. More info: https://reactjs.org/link/controlled-components");
1973              didWarnControlledToUncontrolled = true;
1974            }
1975          }
1976          updateChecked(element, props);
1977          var value = getToStringValue(props.value);
1978          var type = props.type;
1979          if (value != null) {
1980            if (type === "number") {
1981              if (value === 0 && node.value === "" || // We explicitly want to coerce to number here if possible.
1982              // eslint-disable-next-line
1983              node.value != value) {
1984                node.value = toString(value);
1985              }
1986            } else if (node.value !== toString(value)) {
1987              node.value = toString(value);
1988            }
1989          } else if (type === "submit" || type === "reset") {
1990            node.removeAttribute("value");
1991            return;
1992          }
1993          {
1994            if (props.hasOwnProperty("value")) {
1995              setDefaultValue(node, props.type, value);
1996            } else if (props.hasOwnProperty("defaultValue")) {
1997              setDefaultValue(node, props.type, getToStringValue(props.defaultValue));
1998            }
1999          }
2000          {
2001            if (props.checked == null && props.defaultChecked != null) {
2002              node.defaultChecked = !!props.defaultChecked;
2003            }
2004          }
2005        }
2006        function postMountWrapper(element, props, isHydrating2) {
2007          var node = element;
2008          if (props.hasOwnProperty("value") || props.hasOwnProperty("defaultValue")) {
2009            var type = props.type;
2010            var isButton = type === "submit" || type === "reset";
2011            if (isButton && (props.value === void 0 || props.value === null)) {
2012              return;
2013            }
2014            var initialValue = toString(node._wrapperState.initialValue);
2015            if (!isHydrating2) {
2016              {
2017                if (initialValue !== node.value) {
2018                  node.value = initialValue;
2019                }
2020              }
2021            }
2022            {
2023              node.defaultValue = initialValue;
2024            }
2025          }
2026          var name = node.name;
2027          if (name !== "") {
2028            node.name = "";
2029          }
2030          {
2031            node.defaultChecked = !node.defaultChecked;
2032            node.defaultChecked = !!node._wrapperState.initialChecked;
2033          }
2034          if (name !== "") {
2035            node.name = name;
2036          }
2037        }
2038        function restoreControlledState(element, props) {
2039          var node = element;
2040          updateWrapper(node, props);
2041          updateNamedCousins(node, props);
2042        }
2043        function updateNamedCousins(rootNode, props) {
2044          var name = props.name;
2045          if (props.type === "radio" && name != null) {
2046            var queryRoot = rootNode;
2047            while (queryRoot.parentNode) {
2048              queryRoot = queryRoot.parentNode;
2049            }
2050            {
2051              checkAttributeStringCoercion(name, "name");
2052            }
2053            var group = queryRoot.querySelectorAll("input[name=" + JSON.stringify("" + name) + '][type="radio"]');
2054            for (var i = 0; i < group.length; i++) {
2055              var otherNode = group[i];
2056              if (otherNode === rootNode || otherNode.form !== rootNode.form) {
2057                continue;
2058              }
2059              var otherProps = getFiberCurrentPropsFromNode(otherNode);
2060              if (!otherProps) {
2061                throw new Error("ReactDOMInput: Mixing React and non-React radio inputs with the same `name` is not supported.");
2062              }
2063              updateValueIfChanged(otherNode);
2064              updateWrapper(otherNode, otherProps);
2065            }
2066          }
2067        }
2068        function setDefaultValue(node, type, value) {
2069          if (
2070            // Focused number inputs synchronize on blur. See ChangeEventPlugin.js
2071            type !== "number" || getActiveElement(node.ownerDocument) !== node
2072          ) {
2073            if (value == null) {
2074              node.defaultValue = toString(node._wrapperState.initialValue);
2075            } else if (node.defaultValue !== toString(value)) {
2076              node.defaultValue = toString(value);
2077            }
2078          }
2079        }
2080        var didWarnSelectedSetOnOption = false;
2081        var didWarnInvalidChild = false;
2082        var didWarnInvalidInnerHTML = false;
2083        function validateProps(element, props) {
2084          {
2085            if (props.value == null) {
2086              if (typeof props.children === "object" && props.children !== null) {
2087                React.Children.forEach(props.children, function(child) {
2088                  if (child == null) {
2089                    return;
2090                  }
2091                  if (typeof child === "string" || typeof child === "number") {
2092                    return;
2093                  }
2094                  if (!didWarnInvalidChild) {
2095                    didWarnInvalidChild = true;
2096                    error("Cannot infer the option value of complex children. Pass a `value` prop or use a plain string as children to <option>.");
2097                  }
2098                });
2099              } else if (props.dangerouslySetInnerHTML != null) {
2100                if (!didWarnInvalidInnerHTML) {
2101                  didWarnInvalidInnerHTML = true;
2102                  error("Pass a `value` prop if you set dangerouslyInnerHTML so React knows which value should be selected.");
2103                }
2104              }
2105            }
2106            if (props.selected != null && !didWarnSelectedSetOnOption) {
2107              error("Use the `defaultValue` or `value` props on <select> instead of setting `selected` on <option>.");
2108              didWarnSelectedSetOnOption = true;
2109            }
2110          }
2111        }
2112        function postMountWrapper$1(element, props) {
2113          if (props.value != null) {
2114            element.setAttribute("value", toString(getToStringValue(props.value)));
2115          }
2116        }
2117        var isArrayImpl = Array.isArray;
2118        function isArray(a) {
2119          return isArrayImpl(a);
2120        }
2121        var didWarnValueDefaultValue$1;
2122        {
2123          didWarnValueDefaultValue$1 = false;
2124        }
2125        function getDeclarationErrorAddendum() {
2126          var ownerName = getCurrentFiberOwnerNameInDevOrNull();
2127          if (ownerName) {
2128            return "\n\nCheck the render method of `" + ownerName + "`.";
2129          }
2130          return "";
2131        }
2132        var valuePropNames = ["value", "defaultValue"];
2133        function checkSelectPropTypes(props) {
2134          {
2135            checkControlledValueProps("select", props);
2136            for (var i = 0; i < valuePropNames.length; i++) {
2137              var propName = valuePropNames[i];
2138              if (props[propName] == null) {
2139                continue;
2140              }
2141              var propNameIsArray = isArray(props[propName]);
2142              if (props.multiple && !propNameIsArray) {
2143                error("The `%s` prop supplied to <select> must be an array if `multiple` is true.%s", propName, getDeclarationErrorAddendum());
2144              } else if (!props.multiple && propNameIsArray) {
2145                error("The `%s` prop supplied to <select> must be a scalar value if `multiple` is false.%s", propName, getDeclarationErrorAddendum());
2146              }
2147            }
2148          }
2149        }
2150        function updateOptions(node, multiple, propValue, setDefaultSelected) {
2151          var options2 = node.options;
2152          if (multiple) {
2153            var selectedValues = propValue;
2154            var selectedValue = {};
2155            for (var i = 0; i < selectedValues.length; i++) {
2156              selectedValue["$" + selectedValues[i]] = true;
2157            }
2158            for (var _i = 0; _i < options2.length; _i++) {
2159              var selected = selectedValue.hasOwnProperty("$" + options2[_i].value);
2160              if (options2[_i].selected !== selected) {
2161                options2[_i].selected = selected;
2162              }
2163              if (selected && setDefaultSelected) {
2164                options2[_i].defaultSelected = true;
2165              }
2166            }
2167          } else {
2168            var _selectedValue = toString(getToStringValue(propValue));
2169            var defaultSelected = null;
2170            for (var _i2 = 0; _i2 < options2.length; _i2++) {
2171              if (options2[_i2].value === _selectedValue) {
2172                options2[_i2].selected = true;
2173                if (setDefaultSelected) {
2174                  options2[_i2].defaultSelected = true;
2175                }
2176                return;
2177              }
2178              if (defaultSelected === null && !options2[_i2].disabled) {
2179                defaultSelected = options2[_i2];
2180              }
2181            }
2182            if (defaultSelected !== null) {
2183              defaultSelected.selected = true;
2184            }
2185          }
2186        }
2187        function getHostProps$1(element, props) {
2188          return assign({}, props, {
2189            value: void 0
2190          });
2191        }
2192        function initWrapperState$1(element, props) {
2193          var node = element;
2194          {
2195            checkSelectPropTypes(props);
2196          }
2197          node._wrapperState = {
2198            wasMultiple: !!props.multiple
2199          };
2200          {
2201            if (props.value !== void 0 && props.defaultValue !== void 0 && !didWarnValueDefaultValue$1) {
2202              error("Select elements must be either controlled or uncontrolled (specify either the value prop, or the defaultValue prop, but not both). Decide between using a controlled or uncontrolled select element and remove one of these props. More info: https://reactjs.org/link/controlled-components");
2203              didWarnValueDefaultValue$1 = true;
2204            }
2205          }
2206        }
2207        function postMountWrapper$2(element, props) {
2208          var node = element;
2209          node.multiple = !!props.multiple;
2210          var value = props.value;
2211          if (value != null) {
2212            updateOptions(node, !!props.multiple, value, false);
2213          } else if (props.defaultValue != null) {
2214            updateOptions(node, !!props.multiple, props.defaultValue, true);
2215          }
2216        }
2217        function postUpdateWrapper(element, props) {
2218          var node = element;
2219          var wasMultiple = node._wrapperState.wasMultiple;
2220          node._wrapperState.wasMultiple = !!props.multiple;
2221          var value = props.value;
2222          if (value != null) {
2223            updateOptions(node, !!props.multiple, value, false);
2224          } else if (wasMultiple !== !!props.multiple) {
2225            if (props.defaultValue != null) {
2226              updateOptions(node, !!props.multiple, props.defaultValue, true);
2227            } else {
2228              updateOptions(node, !!props.multiple, props.multiple ? [] : "", false);
2229            }
2230          }
2231        }
2232        function restoreControlledState$1(element, props) {
2233          var node = element;
2234          var value = props.value;
2235          if (value != null) {
2236            updateOptions(node, !!props.multiple, value, false);
2237          }
2238        }
2239        var didWarnValDefaultVal = false;
2240        function getHostProps$2(element, props) {
2241          var node = element;
2242          if (props.dangerouslySetInnerHTML != null) {
2243            throw new Error("`dangerouslySetInnerHTML` does not make sense on <textarea>.");
2244          }
2245          var hostProps = assign({}, props, {
2246            value: void 0,
2247            defaultValue: void 0,
2248            children: toString(node._wrapperState.initialValue)
2249          });
2250          return hostProps;
2251        }
2252        function initWrapperState$2(element, props) {
2253          var node = element;
2254          {
2255            checkControlledValueProps("textarea", props);
2256            if (props.value !== void 0 && props.defaultValue !== void 0 && !didWarnValDefaultVal) {
2257              error("%s contains a textarea with both value and defaultValue props. Textarea elements must be either controlled or uncontrolled (specify either the value prop, or the defaultValue prop, but not both). Decide between using a controlled or uncontrolled textarea and remove one of these props. More info: https://reactjs.org/link/controlled-components", getCurrentFiberOwnerNameInDevOrNull() || "A component");
2258              didWarnValDefaultVal = true;
2259            }
2260          }
2261          var initialValue = props.value;
2262          if (initialValue == null) {
2263            var children = props.children, defaultValue = props.defaultValue;
2264            if (children != null) {
2265              {
2266                error("Use the `defaultValue` or `value` props instead of setting children on <textarea>.");
2267              }
2268              {
2269                if (defaultValue != null) {
2270                  throw new Error("If you supply `defaultValue` on a <textarea>, do not pass children.");
2271                }
2272                if (isArray(children)) {
2273                  if (children.length > 1) {
2274                    throw new Error("<textarea> can only have at most one child.");
2275                  }
2276                  children = children[0];
2277                }
2278                defaultValue = children;
2279              }
2280            }
2281            if (defaultValue == null) {
2282              defaultValue = "";
2283            }
2284            initialValue = defaultValue;
2285          }
2286          node._wrapperState = {
2287            initialValue: getToStringValue(initialValue)
2288          };
2289        }
2290        function updateWrapper$1(element, props) {
2291          var node = element;
2292          var value = getToStringValue(props.value);
2293          var defaultValue = getToStringValue(props.defaultValue);
2294          if (value != null) {
2295            var newValue = toString(value);
2296            if (newValue !== node.value) {
2297              node.value = newValue;
2298            }
2299            if (props.defaultValue == null && node.defaultValue !== newValue) {
2300              node.defaultValue = newValue;
2301            }
2302          }
2303          if (defaultValue != null) {
2304            node.defaultValue = toString(defaultValue);
2305          }
2306        }
2307        function postMountWrapper$3(element, props) {
2308          var node = element;
2309          var textContent = node.textContent;
2310          if (textContent === node._wrapperState.initialValue) {
2311            if (textContent !== "" && textContent !== null) {
2312              node.value = textContent;
2313            }
2314          }
2315        }
2316        function restoreControlledState$2(element, props) {
2317          updateWrapper$1(element, props);
2318        }
2319        var HTML_NAMESPACE = "http://www.w3.org/1999/xhtml";
2320        var MATH_NAMESPACE = "http://www.w3.org/1998/Math/MathML";
2321        var SVG_NAMESPACE = "http://www.w3.org/2000/svg";
2322        function getIntrinsicNamespace(type) {
2323          switch (type) {
2324            case "svg":
2325              return SVG_NAMESPACE;
2326            case "math":
2327              return MATH_NAMESPACE;
2328            default:
2329              return HTML_NAMESPACE;
2330          }
2331        }
2332        function getChildNamespace(parentNamespace, type) {
2333          if (parentNamespace == null || parentNamespace === HTML_NAMESPACE) {
2334            return getIntrinsicNamespace(type);
2335          }
2336          if (parentNamespace === SVG_NAMESPACE && type === "foreignObject") {
2337            return HTML_NAMESPACE;
2338          }
2339          return parentNamespace;
2340        }
2341        var createMicrosoftUnsafeLocalFunction = function(func) {
2342          if (typeof MSApp !== "undefined" && MSApp.execUnsafeLocalFunction) {
2343            return function(arg0, arg1, arg2, arg3) {
2344              MSApp.execUnsafeLocalFunction(function() {
2345                return func(arg0, arg1, arg2, arg3);
2346              });
2347            };
2348          } else {
2349            return func;
2350          }
2351        };
2352        var reusableSVGContainer;
2353        var setInnerHTML = createMicrosoftUnsafeLocalFunction(function(node, html) {
2354          if (node.namespaceURI === SVG_NAMESPACE) {
2355            if (!("innerHTML" in node)) {
2356              reusableSVGContainer = reusableSVGContainer || document.createElement("div");
2357              reusableSVGContainer.innerHTML = "<svg>" + html.valueOf().toString() + "</svg>";
2358              var svgNode = reusableSVGContainer.firstChild;
2359              while (node.firstChild) {
2360                node.removeChild(node.firstChild);
2361              }
2362              while (svgNode.firstChild) {
2363                node.appendChild(svgNode.firstChild);
2364              }
2365              return;
2366            }
2367          }
2368          node.innerHTML = html;
2369        });
2370        var ELEMENT_NODE = 1;
2371        var TEXT_NODE = 3;
2372        var COMMENT_NODE = 8;
2373        var DOCUMENT_NODE = 9;
2374        var DOCUMENT_FRAGMENT_NODE = 11;
2375        var setTextContent = function(node, text) {
2376          if (text) {
2377            var firstChild = node.firstChild;
2378            if (firstChild && firstChild === node.lastChild && firstChild.nodeType === TEXT_NODE) {
2379              firstChild.nodeValue = text;
2380              return;
2381            }
2382          }
2383          node.textContent = text;
2384        };
2385        var shorthandToLonghand = {
2386          animation: ["animationDelay", "animationDirection", "animationDuration", "animationFillMode", "animationIterationCount", "animationName", "animationPlayState", "animationTimingFunction"],
2387          background: ["backgroundAttachment", "backgroundClip", "backgroundColor", "backgroundImage", "backgroundOrigin", "backgroundPositionX", "backgroundPositionY", "backgroundRepeat", "backgroundSize"],
2388          backgroundPosition: ["backgroundPositionX", "backgroundPositionY"],
2389          border: ["borderBottomColor", "borderBottomStyle", "borderBottomWidth", "borderImageOutset", "borderImageRepeat", "borderImageSlice", "borderImageSource", "borderImageWidth", "borderLeftColor", "borderLeftStyle", "borderLeftWidth", "borderRightColor", "borderRightStyle", "borderRightWidth", "borderTopColor", "borderTopStyle", "borderTopWidth"],
2390          borderBlockEnd: ["borderBlockEndColor", "borderBlockEndStyle", "borderBlockEndWidth"],
2391          borderBlockStart: ["borderBlockStartColor", "borderBlockStartStyle", "borderBlockStartWidth"],
2392          borderBottom: ["borderBottomColor", "borderBottomStyle", "borderBottomWidth"],
2393          borderColor: ["borderBottomColor", "borderLeftColor", "borderRightColor", "borderTopColor"],
2394          borderImage: ["borderImageOutset", "borderImageRepeat", "borderImageSlice", "borderImageSource", "borderImageWidth"],
2395          borderInlineEnd: ["borderInlineEndColor", "borderInlineEndStyle", "borderInlineEndWidth"],
2396          borderInlineStart: ["borderInlineStartColor", "borderInlineStartStyle", "borderInlineStartWidth"],
2397          borderLeft: ["borderLeftColor", "borderLeftStyle", "borderLeftWidth"],
2398          borderRadius: ["borderBottomLeftRadius", "borderBottomRightRadius", "borderTopLeftRadius", "borderTopRightRadius"],
2399          borderRight: ["borderRightColor", "borderRightStyle", "borderRightWidth"],
2400          borderStyle: ["borderBottomStyle", "borderLeftStyle", "borderRightStyle", "borderTopStyle"],
2401          borderTop: ["borderTopColor", "borderTopStyle", "borderTopWidth"],
2402          borderWidth: ["borderBottomWidth", "borderLeftWidth", "borderRightWidth", "borderTopWidth"],
2403          columnRule: ["columnRuleColor", "columnRuleStyle", "columnRuleWidth"],
2404          columns: ["columnCount", "columnWidth"],
2405          flex: ["flexBasis", "flexGrow", "flexShrink"],
2406          flexFlow: ["flexDirection", "flexWrap"],
2407          font: ["fontFamily", "fontFeatureSettings", "fontKerning", "fontLanguageOverride", "fontSize", "fontSizeAdjust", "fontStretch", "fontStyle", "fontVariant", "fontVariantAlternates", "fontVariantCaps", "fontVariantEastAsian", "fontVariantLigatures", "fontVariantNumeric", "fontVariantPosition", "fontWeight", "lineHeight"],
2408          fontVariant: ["fontVariantAlternates", "fontVariantCaps", "fontVariantEastAsian", "fontVariantLigatures", "fontVariantNumeric", "fontVariantPosition"],
2409          gap: ["columnGap", "rowGap"],
2410          grid: ["gridAutoColumns", "gridAutoFlow", "gridAutoRows", "gridTemplateAreas", "gridTemplateColumns", "gridTemplateRows"],
2411          gridArea: ["gridColumnEnd", "gridColumnStart", "gridRowEnd", "gridRowStart"],
2412          gridColumn: ["gridColumnEnd", "gridColumnStart"],
2413          gridColumnGap: ["columnGap"],
2414          gridGap: ["columnGap", "rowGap"],
2415          gridRow: ["gridRowEnd", "gridRowStart"],
2416          gridRowGap: ["rowGap"],
2417          gridTemplate: ["gridTemplateAreas", "gridTemplateColumns", "gridTemplateRows"],
2418          listStyle: ["listStyleImage", "listStylePosition", "listStyleType"],
2419          margin: ["marginBottom", "marginLeft", "marginRight", "marginTop"],
2420          marker: ["markerEnd", "markerMid", "markerStart"],
2421          mask: ["maskClip", "maskComposite", "maskImage", "maskMode", "maskOrigin", "maskPositionX", "maskPositionY", "maskRepeat", "maskSize"],
2422          maskPosition: ["maskPositionX", "maskPositionY"],
2423          outline: ["outlineColor", "outlineStyle", "outlineWidth"],
2424          overflow: ["overflowX", "overflowY"],
2425          padding: ["paddingBottom", "paddingLeft", "paddingRight", "paddingTop"],
2426          placeContent: ["alignContent", "justifyContent"],
2427          placeItems: ["alignItems", "justifyItems"],
2428          placeSelf: ["alignSelf", "justifySelf"],
2429          textDecoration: ["textDecorationColor", "textDecorationLine", "textDecorationStyle"],
2430          textEmphasis: ["textEmphasisColor", "textEmphasisStyle"],
2431          transition: ["transitionDelay", "transitionDuration", "transitionProperty", "transitionTimingFunction"],
2432          wordWrap: ["overflowWrap"]
2433        };
2434        var isUnitlessNumber = {
2435          animationIterationCount: true,
2436          aspectRatio: true,
2437          borderImageOutset: true,
2438          borderImageSlice: true,
2439          borderImageWidth: true,
2440          boxFlex: true,
2441          boxFlexGroup: true,
2442          boxOrdinalGroup: true,
2443          columnCount: true,
2444          columns: true,
2445          flex: true,
2446          flexGrow: true,
2447          flexPositive: true,
2448          flexShrink: true,
2449          flexNegative: true,
2450          flexOrder: true,
2451          gridArea: true,
2452          gridRow: true,
2453          gridRowEnd: true,
2454          gridRowSpan: true,
2455          gridRowStart: true,
2456          gridColumn: true,
2457          gridColumnEnd: true,
2458          gridColumnSpan: true,
2459          gridColumnStart: true,
2460          fontWeight: true,
2461          lineClamp: true,
2462          lineHeight: true,
2463          opacity: true,
2464          order: true,
2465          orphans: true,
2466          tabSize: true,
2467          widows: true,
2468          zIndex: true,
2469          zoom: true,
2470          // SVG-related properties
2471          fillOpacity: true,
2472          floodOpacity: true,
2473          stopOpacity: true,
2474          strokeDasharray: true,
2475          strokeDashoffset: true,
2476          strokeMiterlimit: true,
2477          strokeOpacity: true,
2478          strokeWidth: true
2479        };
2480        function prefixKey(prefix2, key) {
2481          return prefix2 + key.charAt(0).toUpperCase() + key.substring(1);
2482        }
2483        var prefixes = ["Webkit", "ms", "Moz", "O"];
2484        Object.keys(isUnitlessNumber).forEach(function(prop) {
2485          prefixes.forEach(function(prefix2) {
2486            isUnitlessNumber[prefixKey(prefix2, prop)] = isUnitlessNumber[prop];
2487          });
2488        });
2489        function dangerousStyleValue(name, value, isCustomProperty) {
2490          var isEmpty = value == null || typeof value === "boolean" || value === "";
2491          if (isEmpty) {
2492            return "";
2493          }
2494          if (!isCustomProperty && typeof value === "number" && value !== 0 && !(isUnitlessNumber.hasOwnProperty(name) && isUnitlessNumber[name])) {
2495            return value + "px";
2496          }
2497          {
2498            checkCSSPropertyStringCoercion(value, name);
2499          }
2500          return ("" + value).trim();
2501        }
2502        var uppercasePattern = /([A-Z])/g;
2503        var msPattern = /^ms-/;
2504        function hyphenateStyleName(name) {
2505          return name.replace(uppercasePattern, "-$1").toLowerCase().replace(msPattern, "-ms-");
2506        }
2507        var warnValidStyle = function() {
2508        };
2509        {
2510          var badVendoredStyleNamePattern = /^(?:webkit|moz|o)[A-Z]/;
2511          var msPattern$1 = /^-ms-/;
2512          var hyphenPattern = /-(.)/g;
2513          var badStyleValueWithSemicolonPattern = /;\s*$/;
2514          var warnedStyleNames = {};
2515          var warnedStyleValues = {};
2516          var warnedForNaNValue = false;
2517          var warnedForInfinityValue = false;
2518          var camelize = function(string) {
2519            return string.replace(hyphenPattern, function(_, character) {
2520              return character.toUpperCase();
2521            });
2522          };
2523          var warnHyphenatedStyleName = function(name) {
2524            if (warnedStyleNames.hasOwnProperty(name) && warnedStyleNames[name]) {
2525              return;
2526            }
2527            warnedStyleNames[name] = true;
2528            error(
2529              "Unsupported style property %s. Did you mean %s?",
2530              name,
2531              // As Andi Smith suggests
2532              // (http://www.andismith.com/blog/2012/02/modernizr-prefixed/), an `-ms` prefix
2533              // is converted to lowercase `ms`.
2534              camelize(name.replace(msPattern$1, "ms-"))
2535            );
2536          };
2537          var warnBadVendoredStyleName = function(name) {
2538            if (warnedStyleNames.hasOwnProperty(name) && warnedStyleNames[name]) {
2539              return;
2540            }
2541            warnedStyleNames[name] = true;
2542            error("Unsupported vendor-prefixed style property %s. Did you mean %s?", name, name.charAt(0).toUpperCase() + name.slice(1));
2543          };
2544          var warnStyleValueWithSemicolon = function(name, value) {
2545            if (warnedStyleValues.hasOwnProperty(value) && warnedStyleValues[value]) {
2546              return;
2547            }
2548            warnedStyleValues[value] = true;
2549            error(`Style property values shouldn't contain a semicolon. Try "%s: %s" instead.`, name, value.replace(badStyleValueWithSemicolonPattern, ""));
2550          };
2551          var warnStyleValueIsNaN = function(name, value) {
2552            if (warnedForNaNValue) {
2553              return;
2554            }
2555            warnedForNaNValue = true;
2556            error("`NaN` is an invalid value for the `%s` css style property.", name);
2557          };
2558          var warnStyleValueIsInfinity = function(name, value) {
2559            if (warnedForInfinityValue) {
2560              return;
2561            }
2562            warnedForInfinityValue = true;
2563            error("`Infinity` is an invalid value for the `%s` css style property.", name);
2564          };
2565          warnValidStyle = function(name, value) {
2566            if (name.indexOf("-") > -1) {
2567              warnHyphenatedStyleName(name);
2568            } else if (badVendoredStyleNamePattern.test(name)) {
2569              warnBadVendoredStyleName(name);
2570            } else if (badStyleValueWithSemicolonPattern.test(value)) {
2571              warnStyleValueWithSemicolon(name, value);
2572            }
2573            if (typeof value === "number") {
2574              if (isNaN(value)) {
2575                warnStyleValueIsNaN(name, value);
2576              } else if (!isFinite(value)) {
2577                warnStyleValueIsInfinity(name, value);
2578              }
2579            }
2580          };
2581        }
2582        var warnValidStyle$1 = warnValidStyle;
2583        function createDangerousStringForStyles(styles) {
2584          {
2585            var serialized = "";
2586            var delimiter = "";
2587            for (var styleName in styles) {
2588              if (!styles.hasOwnProperty(styleName)) {
2589                continue;
2590              }
2591              var styleValue = styles[styleName];
2592              if (styleValue != null) {
2593                var isCustomProperty = styleName.indexOf("--") === 0;
2594                serialized += delimiter + (isCustomProperty ? styleName : hyphenateStyleName(styleName)) + ":";
2595                serialized += dangerousStyleValue(styleName, styleValue, isCustomProperty);
2596                delimiter = ";";
2597              }
2598            }
2599            return serialized || null;
2600          }
2601        }
2602        function setValueForStyles(node, styles) {
2603          var style2 = node.style;
2604          for (var styleName in styles) {
2605            if (!styles.hasOwnProperty(styleName)) {
2606              continue;
2607            }
2608            var isCustomProperty = styleName.indexOf("--") === 0;
2609            {
2610              if (!isCustomProperty) {
2611                warnValidStyle$1(styleName, styles[styleName]);
2612              }
2613            }
2614            var styleValue = dangerousStyleValue(styleName, styles[styleName], isCustomProperty);
2615            if (styleName === "float") {
2616              styleName = "cssFloat";
2617            }
2618            if (isCustomProperty) {
2619              style2.setProperty(styleName, styleValue);
2620            } else {
2621              style2[styleName] = styleValue;
2622            }
2623          }
2624        }
2625        function isValueEmpty(value) {
2626          return value == null || typeof value === "boolean" || value === "";
2627        }
2628        function expandShorthandMap(styles) {
2629          var expanded = {};
2630          for (var key in styles) {
2631            var longhands = shorthandToLonghand[key] || [key];
2632            for (var i = 0; i < longhands.length; i++) {
2633              expanded[longhands[i]] = key;
2634            }
2635          }
2636          return expanded;
2637        }
2638        function validateShorthandPropertyCollisionInDev(styleUpdates, nextStyles) {
2639          {
2640            if (!nextStyles) {
2641              return;
2642            }
2643            var expandedUpdates = expandShorthandMap(styleUpdates);
2644            var expandedStyles = expandShorthandMap(nextStyles);
2645            var warnedAbout = {};
2646            for (var key in expandedUpdates) {
2647              var originalKey = expandedUpdates[key];
2648              var correctOriginalKey = expandedStyles[key];
2649              if (correctOriginalKey && originalKey !== correctOriginalKey) {
2650                var warningKey = originalKey + "," + correctOriginalKey;
2651                if (warnedAbout[warningKey]) {
2652                  continue;
2653                }
2654                warnedAbout[warningKey] = true;
2655                error("%s a style property during rerender (%s) when a conflicting property is set (%s) can lead to styling bugs. To avoid this, don't mix shorthand and non-shorthand properties for the same value; instead, replace the shorthand with separate values.", isValueEmpty(styleUpdates[originalKey]) ? "Removing" : "Updating", originalKey, correctOriginalKey);
2656              }
2657            }
2658          }
2659        }
2660        var omittedCloseTags = {
2661          area: true,
2662          base: true,
2663          br: true,
2664          col: true,
2665          embed: true,
2666          hr: true,
2667          img: true,
2668          input: true,
2669          keygen: true,
2670          link: true,
2671          meta: true,
2672          param: true,
2673          source: true,
2674          track: true,
2675          wbr: true
2676          // NOTE: menuitem's close tag should be omitted, but that causes problems.
2677        };
2678        var voidElementTags = assign({
2679          menuitem: true
2680        }, omittedCloseTags);
2681        var HTML = "__html";
2682        function assertValidProps(tag, props) {
2683          if (!props) {
2684            return;
2685          }
2686          if (voidElementTags[tag]) {
2687            if (props.children != null || props.dangerouslySetInnerHTML != null) {
2688              throw new Error(tag + " is a void element tag and must neither have `children` nor use `dangerouslySetInnerHTML`.");
2689            }
2690          }
2691          if (props.dangerouslySetInnerHTML != null) {
2692            if (props.children != null) {
2693              throw new Error("Can only set one of `children` or `props.dangerouslySetInnerHTML`.");
2694            }
2695            if (typeof props.dangerouslySetInnerHTML !== "object" || !(HTML in props.dangerouslySetInnerHTML)) {
2696              throw new Error("`props.dangerouslySetInnerHTML` must be in the form `{__html: ...}`. Please visit https://reactjs.org/link/dangerously-set-inner-html for more information.");
2697            }
2698          }
2699          {
2700            if (!props.suppressContentEditableWarning && props.contentEditable && props.children != null) {
2701              error("A component is `contentEditable` and contains `children` managed by React. It is now your responsibility to guarantee that none of those nodes are unexpectedly modified or duplicated. This is probably not intentional.");
2702            }
2703          }
2704          if (props.style != null && typeof props.style !== "object") {
2705            throw new Error("The `style` prop expects a mapping from style properties to values, not a string. For example, style={{marginRight: spacing + 'em'}} when using JSX.");
2706          }
2707        }
2708        function isCustomComponent(tagName, props) {
2709          if (tagName.indexOf("-") === -1) {
2710            return typeof props.is === "string";
2711          }
2712          switch (tagName) {
2713            case "annotation-xml":
2714            case "color-profile":
2715            case "font-face":
2716            case "font-face-src":
2717            case "font-face-uri":
2718            case "font-face-format":
2719            case "font-face-name":
2720            case "missing-glyph":
2721              return false;
2722            default:
2723              return true;
2724          }
2725        }
2726        var possibleStandardNames = {
2727          // HTML
2728          accept: "accept",
2729          acceptcharset: "acceptCharset",
2730          "accept-charset": "acceptCharset",
2731          accesskey: "accessKey",
2732          action: "action",
2733          allowfullscreen: "allowFullScreen",
2734          alt: "alt",
2735          as: "as",
2736          async: "async",
2737          autocapitalize: "autoCapitalize",
2738          autocomplete: "autoComplete",
2739          autocorrect: "autoCorrect",
2740          autofocus: "autoFocus",
2741          autoplay: "autoPlay",
2742          autosave: "autoSave",
2743          capture: "capture",
2744          cellpadding: "cellPadding",
2745          cellspacing: "cellSpacing",
2746          challenge: "challenge",
2747          charset: "charSet",
2748          checked: "checked",
2749          children: "children",
2750          cite: "cite",
2751          class: "className",
2752          classid: "classID",
2753          classname: "className",
2754          cols: "cols",
2755          colspan: "colSpan",
2756          content: "content",
2757          contenteditable: "contentEditable",
2758          contextmenu: "contextMenu",
2759          controls: "controls",
2760          controlslist: "controlsList",
2761          coords: "coords",
2762          crossorigin: "crossOrigin",
2763          dangerouslysetinnerhtml: "dangerouslySetInnerHTML",
2764          data: "data",
2765          datetime: "dateTime",
2766          default: "default",
2767          defaultchecked: "defaultChecked",
2768          defaultvalue: "defaultValue",
2769          defer: "defer",
2770          dir: "dir",
2771          disabled: "disabled",
2772          disablepictureinpicture: "disablePictureInPicture",
2773          disableremoteplayback: "disableRemotePlayback",
2774          download: "download",
2775          draggable: "draggable",
2776          enctype: "encType",
2777          enterkeyhint: "enterKeyHint",
2778          for: "htmlFor",
2779          form: "form",
2780          formmethod: "formMethod",
2781          formaction: "formAction",
2782          formenctype: "formEncType",
2783          formnovalidate: "formNoValidate",
2784          formtarget: "formTarget",
2785          frameborder: "frameBorder",
2786          headers: "headers",
2787          height: "height",
2788          hidden: "hidden",
2789          high: "high",
2790          href: "href",
2791          hreflang: "hrefLang",
2792          htmlfor: "htmlFor",
2793          httpequiv: "httpEquiv",
2794          "http-equiv": "httpEquiv",
2795          icon: "icon",
2796          id: "id",
2797          imagesizes: "imageSizes",
2798          imagesrcset: "imageSrcSet",
2799          innerhtml: "innerHTML",
2800          inputmode: "inputMode",
2801          integrity: "integrity",
2802          is: "is",
2803          itemid: "itemID",
2804          itemprop: "itemProp",
2805          itemref: "itemRef",
2806          itemscope: "itemScope",
2807          itemtype: "itemType",
2808          keyparams: "keyParams",
2809          keytype: "keyType",
2810          kind: "kind",
2811          label: "label",
2812          lang: "lang",
2813          list: "list",
2814          loop: "loop",
2815          low: "low",
2816          manifest: "manifest",
2817          marginwidth: "marginWidth",
2818          marginheight: "marginHeight",
2819          max: "max",
2820          maxlength: "maxLength",
2821          media: "media",
2822          mediagroup: "mediaGroup",
2823          method: "method",
2824          min: "min",
2825          minlength: "minLength",
2826          multiple: "multiple",
2827          muted: "muted",
2828          name: "name",
2829          nomodule: "noModule",
2830          nonce: "nonce",
2831          novalidate: "noValidate",
2832          open: "open",
2833          optimum: "optimum",
2834          pattern: "pattern",
2835          placeholder: "placeholder",
2836          playsinline: "playsInline",
2837          poster: "poster",
2838          preload: "preload",
2839          profile: "profile",
2840          radiogroup: "radioGroup",
2841          readonly: "readOnly",
2842          referrerpolicy: "referrerPolicy",
2843          rel: "rel",
2844          required: "required",
2845          reversed: "reversed",
2846          role: "role",
2847          rows: "rows",
2848          rowspan: "rowSpan",
2849          sandbox: "sandbox",
2850          scope: "scope",
2851          scoped: "scoped",
2852          scrolling: "scrolling",
2853          seamless: "seamless",
2854          selected: "selected",
2855          shape: "shape",
2856          size: "size",
2857          sizes: "sizes",
2858          span: "span",
2859          spellcheck: "spellCheck",
2860          src: "src",
2861          srcdoc: "srcDoc",
2862          srclang: "srcLang",
2863          srcset: "srcSet",
2864          start: "start",
2865          step: "step",
2866          style: "style",
2867          summary: "summary",
2868          tabindex: "tabIndex",
2869          target: "target",
2870          title: "title",
2871          type: "type",
2872          usemap: "useMap",
2873          value: "value",
2874          width: "width",
2875          wmode: "wmode",
2876          wrap: "wrap",
2877          // SVG
2878          about: "about",
2879          accentheight: "accentHeight",
2880          "accent-height": "accentHeight",
2881          accumulate: "accumulate",
2882          additive: "additive",
2883          alignmentbaseline: "alignmentBaseline",
2884          "alignment-baseline": "alignmentBaseline",
2885          allowreorder: "allowReorder",
2886          alphabetic: "alphabetic",
2887          amplitude: "amplitude",
2888          arabicform: "arabicForm",
2889          "arabic-form": "arabicForm",
2890          ascent: "ascent",
2891          attributename: "attributeName",
2892          attributetype: "attributeType",
2893          autoreverse: "autoReverse",
2894          azimuth: "azimuth",
2895          basefrequency: "baseFrequency",
2896          baselineshift: "baselineShift",
2897          "baseline-shift": "baselineShift",
2898          baseprofile: "baseProfile",
2899          bbox: "bbox",
2900          begin: "begin",
2901          bias: "bias",
2902          by: "by",
2903          calcmode: "calcMode",
2904          capheight: "capHeight",
2905          "cap-height": "capHeight",
2906          clip: "clip",
2907          clippath: "clipPath",
2908          "clip-path": "clipPath",
2909          clippathunits: "clipPathUnits",
2910          cliprule: "clipRule",
2911          "clip-rule": "clipRule",
2912          color: "color",
2913          colorinterpolation: "colorInterpolation",
2914          "color-interpolation": "colorInterpolation",
2915          colorinterpolationfilters: "colorInterpolationFilters",
2916          "color-interpolation-filters": "colorInterpolationFilters",
2917          colorprofile: "colorProfile",
2918          "color-profile": "colorProfile",
2919          colorrendering: "colorRendering",
2920          "color-rendering": "colorRendering",
2921          contentscripttype: "contentScriptType",
2922          contentstyletype: "contentStyleType",
2923          cursor: "cursor",
2924          cx: "cx",
2925          cy: "cy",
2926          d: "d",
2927          datatype: "datatype",
2928          decelerate: "decelerate",
2929          descent: "descent",
2930          diffuseconstant: "diffuseConstant",
2931          direction: "direction",
2932          display: "display",
2933          divisor: "divisor",
2934          dominantbaseline: "dominantBaseline",
2935          "dominant-baseline": "dominantBaseline",
2936          dur: "dur",
2937          dx: "dx",
2938          dy: "dy",
2939          edgemode: "edgeMode",
2940          elevation: "elevation",
2941          enablebackground: "enableBackground",
2942          "enable-background": "enableBackground",
2943          end: "end",
2944          exponent: "exponent",
2945          externalresourcesrequired: "externalResourcesRequired",
2946          fill: "fill",
2947          fillopacity: "fillOpacity",
2948          "fill-opacity": "fillOpacity",
2949          fillrule: "fillRule",
2950          "fill-rule": "fillRule",
2951          filter: "filter",
2952          filterres: "filterRes",
2953          filterunits: "filterUnits",
2954          floodopacity: "floodOpacity",
2955          "flood-opacity": "floodOpacity",
2956          floodcolor: "floodColor",
2957          "flood-color": "floodColor",
2958          focusable: "focusable",
2959          fontfamily: "fontFamily",
2960          "font-family": "fontFamily",
2961          fontsize: "fontSize",
2962          "font-size": "fontSize",
2963          fontsizeadjust: "fontSizeAdjust",
2964          "font-size-adjust": "fontSizeAdjust",
2965          fontstretch: "fontStretch",
2966          "font-stretch": "fontStretch",
2967          fontstyle: "fontStyle",
2968          "font-style": "fontStyle",
2969          fontvariant: "fontVariant",
2970          "font-variant": "fontVariant",
2971          fontweight: "fontWeight",
2972          "font-weight": "fontWeight",
2973          format: "format",
2974          from: "from",
2975          fx: "fx",
2976          fy: "fy",
2977          g1: "g1",
2978          g2: "g2",
2979          glyphname: "glyphName",
2980          "glyph-name": "glyphName",
2981          glyphorientationhorizontal: "glyphOrientationHorizontal",
2982          "glyph-orientation-horizontal": "glyphOrientationHorizontal",
2983          glyphorientationvertical: "glyphOrientationVertical",
2984          "glyph-orientation-vertical": "glyphOrientationVertical",
2985          glyphref: "glyphRef",
2986          gradienttransform: "gradientTransform",
2987          gradientunits: "gradientUnits",
2988          hanging: "hanging",
2989          horizadvx: "horizAdvX",
2990          "horiz-adv-x": "horizAdvX",
2991          horizoriginx: "horizOriginX",
2992          "horiz-origin-x": "horizOriginX",
2993          ideographic: "ideographic",
2994          imagerendering: "imageRendering",
2995          "image-rendering": "imageRendering",
2996          in2: "in2",
2997          in: "in",
2998          inlist: "inlist",
2999          intercept: "intercept",
3000          k1: "k1",
3001          k2: "k2",
3002          k3: "k3",
3003          k4: "k4",
3004          k: "k",
3005          kernelmatrix: "kernelMatrix",
3006          kernelunitlength: "kernelUnitLength",
3007          kerning: "kerning",
3008          keypoints: "keyPoints",
3009          keysplines: "keySplines",
3010          keytimes: "keyTimes",
3011          lengthadjust: "lengthAdjust",
3012          letterspacing: "letterSpacing",
3013          "letter-spacing": "letterSpacing",
3014          lightingcolor: "lightingColor",
3015          "lighting-color": "lightingColor",
3016          limitingconeangle: "limitingConeAngle",
3017          local: "local",
3018          markerend: "markerEnd",
3019          "marker-end": "markerEnd",
3020          markerheight: "markerHeight",
3021          markermid: "markerMid",
3022          "marker-mid": "markerMid",
3023          markerstart: "markerStart",
3024          "marker-start": "markerStart",
3025          markerunits: "markerUnits",
3026          markerwidth: "markerWidth",
3027          mask: "mask",
3028          maskcontentunits: "maskContentUnits",
3029          maskunits: "maskUnits",
3030          mathematical: "mathematical",
3031          mode: "mode",
3032          numoctaves: "numOctaves",
3033          offset: "offset",
3034          opacity: "opacity",
3035          operator: "operator",
3036          order: "order",
3037          orient: "orient",
3038          orientation: "orientation",
3039          origin: "origin",
3040          overflow: "overflow",
3041          overlineposition: "overlinePosition",
3042          "overline-position": "overlinePosition",
3043          overlinethickness: "overlineThickness",
3044          "overline-thickness": "overlineThickness",
3045          paintorder: "paintOrder",
3046          "paint-order": "paintOrder",
3047          panose1: "panose1",
3048          "panose-1": "panose1",
3049          pathlength: "pathLength",
3050          patterncontentunits: "patternContentUnits",
3051          patterntransform: "patternTransform",
3052          patternunits: "patternUnits",
3053          pointerevents: "pointerEvents",
3054          "pointer-events": "pointerEvents",
3055          points: "points",
3056          pointsatx: "pointsAtX",
3057          pointsaty: "pointsAtY",
3058          pointsatz: "pointsAtZ",
3059          prefix: "prefix",
3060          preservealpha: "preserveAlpha",
3061          preserveaspectratio: "preserveAspectRatio",
3062          primitiveunits: "primitiveUnits",
3063          property: "property",
3064          r: "r",
3065          radius: "radius",
3066          refx: "refX",
3067          refy: "refY",
3068          renderingintent: "renderingIntent",
3069          "rendering-intent": "renderingIntent",
3070          repeatcount: "repeatCount",
3071          repeatdur: "repeatDur",
3072          requiredextensions: "requiredExtensions",
3073          requiredfeatures: "requiredFeatures",
3074          resource: "resource",
3075          restart: "restart",
3076          result: "result",
3077          results: "results",
3078          rotate: "rotate",
3079          rx: "rx",
3080          ry: "ry",
3081          scale: "scale",
3082          security: "security",
3083          seed: "seed",
3084          shaperendering: "shapeRendering",
3085          "shape-rendering": "shapeRendering",
3086          slope: "slope",
3087          spacing: "spacing",
3088          specularconstant: "specularConstant",
3089          specularexponent: "specularExponent",
3090          speed: "speed",
3091          spreadmethod: "spreadMethod",
3092          startoffset: "startOffset",
3093          stddeviation: "stdDeviation",
3094          stemh: "stemh",
3095          stemv: "stemv",
3096          stitchtiles: "stitchTiles",
3097          stopcolor: "stopColor",
3098          "stop-color": "stopColor",
3099          stopopacity: "stopOpacity",
3100          "stop-opacity": "stopOpacity",
3101          strikethroughposition: "strikethroughPosition",
3102          "strikethrough-position": "strikethroughPosition",
3103          strikethroughthickness: "strikethroughThickness",
3104          "strikethrough-thickness": "strikethroughThickness",
3105          string: "string",
3106          stroke: "stroke",
3107          strokedasharray: "strokeDasharray",
3108          "stroke-dasharray": "strokeDasharray",
3109          strokedashoffset: "strokeDashoffset",
3110          "stroke-dashoffset": "strokeDashoffset",
3111          strokelinecap: "strokeLinecap",
3112          "stroke-linecap": "strokeLinecap",
3113          strokelinejoin: "strokeLinejoin",
3114          "stroke-linejoin": "strokeLinejoin",
3115          strokemiterlimit: "strokeMiterlimit",
3116          "stroke-miterlimit": "strokeMiterlimit",
3117          strokewidth: "strokeWidth",
3118          "stroke-width": "strokeWidth",
3119          strokeopacity: "strokeOpacity",
3120          "stroke-opacity": "strokeOpacity",
3121          suppresscontenteditablewarning: "suppressContentEditableWarning",
3122          suppresshydrationwarning: "suppressHydrationWarning",
3123          surfacescale: "surfaceScale",
3124          systemlanguage: "systemLanguage",
3125          tablevalues: "tableValues",
3126          targetx: "targetX",
3127          targety: "targetY",
3128          textanchor: "textAnchor",
3129          "text-anchor": "textAnchor",
3130          textdecoration: "textDecoration",
3131          "text-decoration": "textDecoration",
3132          textlength: "textLength",
3133          textrendering: "textRendering",
3134          "text-rendering": "textRendering",
3135          to: "to",
3136          transform: "transform",
3137          typeof: "typeof",
3138          u1: "u1",
3139          u2: "u2",
3140          underlineposition: "underlinePosition",
3141          "underline-position": "underlinePosition",
3142          underlinethickness: "underlineThickness",
3143          "underline-thickness": "underlineThickness",
3144          unicode: "unicode",
3145          unicodebidi: "unicodeBidi",
3146          "unicode-bidi": "unicodeBidi",
3147          unicoderange: "unicodeRange",
3148          "unicode-range": "unicodeRange",
3149          unitsperem: "unitsPerEm",
3150          "units-per-em": "unitsPerEm",
3151          unselectable: "unselectable",
3152          valphabetic: "vAlphabetic",
3153          "v-alphabetic": "vAlphabetic",
3154          values: "values",
3155          vectoreffect: "vectorEffect",
3156          "vector-effect": "vectorEffect",
3157          version: "version",
3158          vertadvy: "vertAdvY",
3159          "vert-adv-y": "vertAdvY",
3160          vertoriginx: "vertOriginX",
3161          "vert-origin-x": "vertOriginX",
3162          vertoriginy: "vertOriginY",
3163          "vert-origin-y": "vertOriginY",
3164          vhanging: "vHanging",
3165          "v-hanging": "vHanging",
3166          videographic: "vIdeographic",
3167          "v-ideographic": "vIdeographic",
3168          viewbox: "viewBox",
3169          viewtarget: "viewTarget",
3170          visibility: "visibility",
3171          vmathematical: "vMathematical",
3172          "v-mathematical": "vMathematical",
3173          vocab: "vocab",
3174          widths: "widths",
3175          wordspacing: "wordSpacing",
3176          "word-spacing": "wordSpacing",
3177          writingmode: "writingMode",
3178          "writing-mode": "writingMode",
3179          x1: "x1",
3180          x2: "x2",
3181          x: "x",
3182          xchannelselector: "xChannelSelector",
3183          xheight: "xHeight",
3184          "x-height": "xHeight",
3185          xlinkactuate: "xlinkActuate",
3186          "xlink:actuate": "xlinkActuate",
3187          xlinkarcrole: "xlinkArcrole",
3188          "xlink:arcrole": "xlinkArcrole",
3189          xlinkhref: "xlinkHref",
3190          "xlink:href": "xlinkHref",
3191          xlinkrole: "xlinkRole",
3192          "xlink:role": "xlinkRole",
3193          xlinkshow: "xlinkShow",
3194          "xlink:show": "xlinkShow",
3195          xlinktitle: "xlinkTitle",
3196          "xlink:title": "xlinkTitle",
3197          xlinktype: "xlinkType",
3198          "xlink:type": "xlinkType",
3199          xmlbase: "xmlBase",
3200          "xml:base": "xmlBase",
3201          xmllang: "xmlLang",
3202          "xml:lang": "xmlLang",
3203          xmlns: "xmlns",
3204          "xml:space": "xmlSpace",
3205          xmlnsxlink: "xmlnsXlink",
3206          "xmlns:xlink": "xmlnsXlink",
3207          xmlspace: "xmlSpace",
3208          y1: "y1",
3209          y2: "y2",
3210          y: "y",
3211          ychannelselector: "yChannelSelector",
3212          z: "z",
3213          zoomandpan: "zoomAndPan"
3214        };
3215        var ariaProperties = {
3216          "aria-current": 0,
3217          // state
3218          "aria-description": 0,
3219          "aria-details": 0,
3220          "aria-disabled": 0,
3221          // state
3222          "aria-hidden": 0,
3223          // state
3224          "aria-invalid": 0,
3225          // state
3226          "aria-keyshortcuts": 0,
3227          "aria-label": 0,
3228          "aria-roledescription": 0,
3229          // Widget Attributes
3230          "aria-autocomplete": 0,
3231          "aria-checked": 0,
3232          "aria-expanded": 0,
3233          "aria-haspopup": 0,
3234          "aria-level": 0,
3235          "aria-modal": 0,
3236          "aria-multiline": 0,
3237          "aria-multiselectable": 0,
3238          "aria-orientation": 0,
3239          "aria-placeholder": 0,
3240          "aria-pressed": 0,
3241          "aria-readonly": 0,
3242          "aria-required": 0,
3243          "aria-selected": 0,
3244          "aria-sort": 0,
3245          "aria-valuemax": 0,
3246          "aria-valuemin": 0,
3247          "aria-valuenow": 0,
3248          "aria-valuetext": 0,
3249          // Live Region Attributes
3250          "aria-atomic": 0,
3251          "aria-busy": 0,
3252          "aria-live": 0,
3253          "aria-relevant": 0,
3254          // Drag-and-Drop Attributes
3255          "aria-dropeffect": 0,
3256          "aria-grabbed": 0,
3257          // Relationship Attributes
3258          "aria-activedescendant": 0,
3259          "aria-colcount": 0,
3260          "aria-colindex": 0,
3261          "aria-colspan": 0,
3262          "aria-controls": 0,
3263          "aria-describedby": 0,
3264          "aria-errormessage": 0,
3265          "aria-flowto": 0,
3266          "aria-labelledby": 0,
3267          "aria-owns": 0,
3268          "aria-posinset": 0,
3269          "aria-rowcount": 0,
3270          "aria-rowindex": 0,
3271          "aria-rowspan": 0,
3272          "aria-setsize": 0
3273        };
3274        var warnedProperties = {};
3275        var rARIA = new RegExp("^(aria)-[" + ATTRIBUTE_NAME_CHAR + "]*$");
3276        var rARIACamel = new RegExp("^(aria)[A-Z][" + ATTRIBUTE_NAME_CHAR + "]*$");
3277        function validateProperty(tagName, name) {
3278          {
3279            if (hasOwnProperty.call(warnedProperties, name) && warnedProperties[name]) {
3280              return true;
3281            }
3282            if (rARIACamel.test(name)) {
3283              var ariaName = "aria-" + name.slice(4).toLowerCase();
3284              var correctName = ariaProperties.hasOwnProperty(ariaName) ? ariaName : null;
3285              if (correctName == null) {
3286                error("Invalid ARIA attribute `%s`. ARIA attributes follow the pattern aria-* and must be lowercase.", name);
3287                warnedProperties[name] = true;
3288                return true;
3289              }
3290              if (name !== correctName) {
3291                error("Invalid ARIA attribute `%s`. Did you mean `%s`?", name, correctName);
3292                warnedProperties[name] = true;
3293                return true;
3294              }
3295            }
3296            if (rARIA.test(name)) {
3297              var lowerCasedName = name.toLowerCase();
3298              var standardName = ariaProperties.hasOwnProperty(lowerCasedName) ? lowerCasedName : null;
3299              if (standardName == null) {
3300                warnedProperties[name] = true;
3301                return false;
3302              }
3303              if (name !== standardName) {
3304                error("Unknown ARIA attribute `%s`. Did you mean `%s`?", name, standardName);
3305                warnedProperties[name] = true;
3306                return true;
3307              }
3308            }
3309          }
3310          return true;
3311        }
3312        function warnInvalidARIAProps(type, props) {
3313          {
3314            var invalidProps = [];
3315            for (var key in props) {
3316              var isValid = validateProperty(type, key);
3317              if (!isValid) {
3318                invalidProps.push(key);
3319              }
3320            }
3321            var unknownPropString = invalidProps.map(function(prop) {
3322              return "`" + prop + "`";
3323            }).join(", ");
3324            if (invalidProps.length === 1) {
3325              error("Invalid aria prop %s on <%s> tag. For details, see https://reactjs.org/link/invalid-aria-props", unknownPropString, type);
3326            } else if (invalidProps.length > 1) {
3327              error("Invalid aria props %s on <%s> tag. For details, see https://reactjs.org/link/invalid-aria-props", unknownPropString, type);
3328            }
3329          }
3330        }
3331        function validateProperties(type, props) {
3332          if (isCustomComponent(type, props)) {
3333            return;
3334          }
3335          warnInvalidARIAProps(type, props);
3336        }
3337        var didWarnValueNull = false;
3338        function validateProperties$1(type, props) {
3339          {
3340            if (type !== "input" && type !== "textarea" && type !== "select") {
3341              return;
3342            }
3343            if (props != null && props.value === null && !didWarnValueNull) {
3344              didWarnValueNull = true;
3345              if (type === "select" && props.multiple) {
3346                error("`value` prop on `%s` should not be null. Consider using an empty array when `multiple` is set to `true` to clear the component or `undefined` for uncontrolled components.", type);
3347              } else {
3348                error("`value` prop on `%s` should not be null. Consider using an empty string to clear the component or `undefined` for uncontrolled components.", type);
3349              }
3350            }
3351          }
3352        }
3353        var validateProperty$1 = function() {
3354        };
3355        {
3356          var warnedProperties$1 = {};
3357          var EVENT_NAME_REGEX = /^on./;
3358          var INVALID_EVENT_NAME_REGEX = /^on[^A-Z]/;
3359          var rARIA$1 = new RegExp("^(aria)-[" + ATTRIBUTE_NAME_CHAR + "]*$");
3360          var rARIACamel$1 = new RegExp("^(aria)[A-Z][" + ATTRIBUTE_NAME_CHAR + "]*$");
3361          validateProperty$1 = function(tagName, name, value, eventRegistry) {
3362            if (hasOwnProperty.call(warnedProperties$1, name) && warnedProperties$1[name]) {
3363              return true;
3364            }
3365            var lowerCasedName = name.toLowerCase();
3366            if (lowerCasedName === "onfocusin" || lowerCasedName === "onfocusout") {
3367              error("React uses onFocus and onBlur instead of onFocusIn and onFocusOut. All React events are normalized to bubble, so onFocusIn and onFocusOut are not needed/supported by React.");
3368              warnedProperties$1[name] = true;
3369              return true;
3370            }
3371            if (eventRegistry != null) {
3372              var registrationNameDependencies2 = eventRegistry.registrationNameDependencies, possibleRegistrationNames2 = eventRegistry.possibleRegistrationNames;
3373              if (registrationNameDependencies2.hasOwnProperty(name)) {
3374                return true;
3375              }
3376              var registrationName = possibleRegistrationNames2.hasOwnProperty(lowerCasedName) ? possibleRegistrationNames2[lowerCasedName] : null;
3377              if (registrationName != null) {
3378                error("Invalid event handler property `%s`. Did you mean `%s`?", name, registrationName);
3379                warnedProperties$1[name] = true;
3380                return true;
3381              }
3382              if (EVENT_NAME_REGEX.test(name)) {
3383                error("Unknown event handler property `%s`. It will be ignored.", name);
3384                warnedProperties$1[name] = true;
3385                return true;
3386              }
3387            } else if (EVENT_NAME_REGEX.test(name)) {
3388              if (INVALID_EVENT_NAME_REGEX.test(name)) {
3389                error("Invalid event handler property `%s`. React events use the camelCase naming convention, for example `onClick`.", name);
3390              }
3391              warnedProperties$1[name] = true;
3392              return true;
3393            }
3394            if (rARIA$1.test(name) || rARIACamel$1.test(name)) {
3395              return true;
3396            }
3397            if (lowerCasedName === "innerhtml") {
3398              error("Directly setting property `innerHTML` is not permitted. For more information, lookup documentation on `dangerouslySetInnerHTML`.");
3399              warnedProperties$1[name] = true;
3400              return true;
3401            }
3402            if (lowerCasedName === "aria") {
3403              error("The `aria` attribute is reserved for future use in React. Pass individual `aria-` attributes instead.");
3404              warnedProperties$1[name] = true;
3405              return true;
3406            }
3407            if (lowerCasedName === "is" && value !== null && value !== void 0 && typeof value !== "string") {
3408              error("Received a `%s` for a string attribute `is`. If this is expected, cast the value to a string.", typeof value);
3409              warnedProperties$1[name] = true;
3410              return true;
3411            }
3412            if (typeof value === "number" && isNaN(value)) {
3413              error("Received NaN for the `%s` attribute. If this is expected, cast the value to a string.", name);
3414              warnedProperties$1[name] = true;
3415              return true;
3416            }
3417            var propertyInfo = getPropertyInfo(name);
3418            var isReserved = propertyInfo !== null && propertyInfo.type === RESERVED;
3419            if (possibleStandardNames.hasOwnProperty(lowerCasedName)) {
3420              var standardName = possibleStandardNames[lowerCasedName];
3421              if (standardName !== name) {
3422                error("Invalid DOM property `%s`. Did you mean `%s`?", name, standardName);
3423                warnedProperties$1[name] = true;
3424                return true;
3425              }
3426            } else if (!isReserved && name !== lowerCasedName) {
3427              error("React does not recognize the `%s` prop on a DOM element. If you intentionally want it to appear in the DOM as a custom attribute, spell it as lowercase `%s` instead. If you accidentally passed it from a parent component, remove it from the DOM element.", name, lowerCasedName);
3428              warnedProperties$1[name] = true;
3429              return true;
3430            }
3431            if (typeof value === "boolean" && shouldRemoveAttributeWithWarning(name, value, propertyInfo, false)) {
3432              if (value) {
3433                error('Received `%s` for a non-boolean attribute `%s`.\n\nIf you want to write it to the DOM, pass a string instead: %s="%s" or %s={value.toString()}.', value, name, name, value, name);
3434              } else {
3435                error('Received `%s` for a non-boolean attribute `%s`.\n\nIf you want to write it to the DOM, pass a string instead: %s="%s" or %s={value.toString()}.\n\nIf you used to conditionally omit it with %s={condition && value}, pass %s={condition ? value : undefined} instead.', value, name, name, value, name, name, name);
3436              }
3437              warnedProperties$1[name] = true;
3438              return true;
3439            }
3440            if (isReserved) {
3441              return true;
3442            }
3443            if (shouldRemoveAttributeWithWarning(name, value, propertyInfo, false)) {
3444              warnedProperties$1[name] = true;
3445              return false;
3446            }
3447            if ((value === "false" || value === "true") && propertyInfo !== null && propertyInfo.type === BOOLEAN) {
3448              error("Received the string `%s` for the boolean attribute `%s`. %s Did you mean %s={%s}?", value, name, value === "false" ? "The browser will interpret it as a truthy value." : 'Although this works, it will not work as expected if you pass the string "false".', name, value);
3449              warnedProperties$1[name] = true;
3450              return true;
3451            }
3452            return true;
3453          };
3454        }
3455        var warnUnknownProperties = function(type, props, eventRegistry) {
3456          {
3457            var unknownProps = [];
3458            for (var key in props) {
3459              var isValid = validateProperty$1(type, key, props[key], eventRegistry);
3460              if (!isValid) {
3461                unknownProps.push(key);
3462              }
3463            }
3464            var unknownPropString = unknownProps.map(function(prop) {
3465              return "`" + prop + "`";
3466            }).join(", ");
3467            if (unknownProps.length === 1) {
3468              error("Invalid value for prop %s on <%s> tag. Either remove it from the element, or pass a string or number value to keep it in the DOM. For details, see https://reactjs.org/link/attribute-behavior ", unknownPropString, type);
3469            } else if (unknownProps.length > 1) {
3470              error("Invalid values for props %s on <%s> tag. Either remove them from the element, or pass a string or number value to keep them in the DOM. For details, see https://reactjs.org/link/attribute-behavior ", unknownPropString, type);
3471            }
3472          }
3473        };
3474        function validateProperties$2(type, props, eventRegistry) {
3475          if (isCustomComponent(type, props)) {
3476            return;
3477          }
3478          warnUnknownProperties(type, props, eventRegistry);
3479        }
3480        var IS_EVENT_HANDLE_NON_MANAGED_NODE = 1;
3481        var IS_NON_DELEGATED = 1 << 1;
3482        var IS_CAPTURE_PHASE = 1 << 2;
3483        var SHOULD_NOT_PROCESS_POLYFILL_EVENT_PLUGINS = IS_EVENT_HANDLE_NON_MANAGED_NODE | IS_NON_DELEGATED | IS_CAPTURE_PHASE;
3484        var currentReplayingEvent = null;
3485        function setReplayingEvent(event) {
3486          {
3487            if (currentReplayingEvent !== null) {
3488              error("Expected currently replaying event to be null. This error is likely caused by a bug in React. Please file an issue.");
3489            }
3490          }
3491          currentReplayingEvent = event;
3492        }
3493        function resetReplayingEvent() {
3494          {
3495            if (currentReplayingEvent === null) {
3496              error("Expected currently replaying event to not be null. This error is likely caused by a bug in React. Please file an issue.");
3497            }
3498          }
3499          currentReplayingEvent = null;
3500        }
3501        function isReplayingEvent(event) {
3502          return event === currentReplayingEvent;
3503        }
3504        function getEventTarget(nativeEvent) {
3505          var target = nativeEvent.target || nativeEvent.srcElement || window;
3506          if (target.correspondingUseElement) {
3507            target = target.correspondingUseElement;
3508          }
3509          return target.nodeType === TEXT_NODE ? target.parentNode : target;
3510        }
3511        var restoreImpl = null;
3512        var restoreTarget = null;
3513        var restoreQueue = null;
3514        function restoreStateOfTarget(target) {
3515          var internalInstance = getInstanceFromNode(target);
3516          if (!internalInstance) {
3517            return;
3518          }
3519          if (typeof restoreImpl !== "function") {
3520            throw new Error("setRestoreImplementation() needs to be called to handle a target for controlled events. This error is likely caused by a bug in React. Please file an issue.");
3521          }
3522          var stateNode = internalInstance.stateNode;
3523          if (stateNode) {
3524            var _props = getFiberCurrentPropsFromNode(stateNode);
3525            restoreImpl(internalInstance.stateNode, internalInstance.type, _props);
3526          }
3527        }
3528        function setRestoreImplementation(impl) {
3529          restoreImpl = impl;
3530        }
3531        function enqueueStateRestore(target) {
3532          if (restoreTarget) {
3533            if (restoreQueue) {
3534              restoreQueue.push(target);
3535            } else {
3536              restoreQueue = [target];
3537            }
3538          } else {
3539            restoreTarget = target;
3540          }
3541        }
3542        function needsStateRestore() {
3543          return restoreTarget !== null || restoreQueue !== null;
3544        }
3545        function restoreStateIfNeeded() {
3546          if (!restoreTarget) {
3547            return;
3548          }
3549          var target = restoreTarget;
3550          var queuedTargets = restoreQueue;
3551          restoreTarget = null;
3552          restoreQueue = null;
3553          restoreStateOfTarget(target);
3554          if (queuedTargets) {
3555            for (var i = 0; i < queuedTargets.length; i++) {
3556              restoreStateOfTarget(queuedTargets[i]);
3557            }
3558          }
3559        }
3560        var batchedUpdatesImpl = function(fn, bookkeeping) {
3561          return fn(bookkeeping);
3562        };
3563        var flushSyncImpl = function() {
3564        };
3565        var isInsideEventHandler = false;
3566        function finishEventHandler() {
3567          var controlledComponentsHavePendingUpdates = needsStateRestore();
3568          if (controlledComponentsHavePendingUpdates) {
3569            flushSyncImpl();
3570            restoreStateIfNeeded();
3571          }
3572        }
3573        function batchedUpdates(fn, a, b) {
3574          if (isInsideEventHandler) {
3575            return fn(a, b);
3576          }
3577          isInsideEventHandler = true;
3578          try {
3579            return batchedUpdatesImpl(fn, a, b);
3580          } finally {
3581            isInsideEventHandler = false;
3582            finishEventHandler();
3583          }
3584        }
3585        function setBatchingImplementation(_batchedUpdatesImpl, _discreteUpdatesImpl, _flushSyncImpl) {
3586          batchedUpdatesImpl = _batchedUpdatesImpl;
3587          flushSyncImpl = _flushSyncImpl;
3588        }
3589        function isInteractive(tag) {
3590          return tag === "button" || tag === "input" || tag === "select" || tag === "textarea";
3591        }
3592        function shouldPreventMouseEvent(name, type, props) {
3593          switch (name) {
3594            case "onClick":
3595            case "onClickCapture":
3596            case "onDoubleClick":
3597            case "onDoubleClickCapture":
3598            case "onMouseDown":
3599            case "onMouseDownCapture":
3600            case "onMouseMove":
3601            case "onMouseMoveCapture":
3602            case "onMouseUp":
3603            case "onMouseUpCapture":
3604            case "onMouseEnter":
3605              return !!(props.disabled && isInteractive(type));
3606            default:
3607              return false;
3608          }
3609        }
3610        function getListener(inst, registrationName) {
3611          var stateNode = inst.stateNode;
3612          if (stateNode === null) {
3613            return null;
3614          }
3615          var props = getFiberCurrentPropsFromNode(stateNode);
3616          if (props === null) {
3617            return null;
3618          }
3619          var listener = props[registrationName];
3620          if (shouldPreventMouseEvent(registrationName, inst.type, props)) {
3621            return null;
3622          }
3623          if (listener && typeof listener !== "function") {
3624            throw new Error("Expected `" + registrationName + "` listener to be a function, instead got a value of `" + typeof listener + "` type.");
3625          }
3626          return listener;
3627        }
3628        var passiveBrowserEventsSupported = false;
3629        if (canUseDOM) {
3630          try {
3631            var options = {};
3632            Object.defineProperty(options, "passive", {
3633              get: function() {
3634                passiveBrowserEventsSupported = true;
3635              }
3636            });
3637            window.addEventListener("test", options, options);
3638            window.removeEventListener("test", options, options);
3639          } catch (e) {
3640            passiveBrowserEventsSupported = false;
3641          }
3642        }
3643        function invokeGuardedCallbackProd(name, func, context, a, b, c, d, e, f) {
3644          var funcArgs = Array.prototype.slice.call(arguments, 3);
3645          try {
3646            func.apply(context, funcArgs);
3647          } catch (error2) {
3648            this.onError(error2);
3649          }
3650        }
3651        var invokeGuardedCallbackImpl = invokeGuardedCallbackProd;
3652        {
3653          if (typeof window !== "undefined" && typeof window.dispatchEvent === "function" && typeof document !== "undefined" && typeof document.createEvent === "function") {
3654            var fakeNode = document.createElement("react");
3655            invokeGuardedCallbackImpl = function invokeGuardedCallbackDev(name, func, context, a, b, c, d, e, f) {
3656              if (typeof document === "undefined" || document === null) {
3657                throw new Error("The `document` global was defined when React was initialized, but is not defined anymore. This can happen in a test environment if a component schedules an update from an asynchronous callback, but the test has already finished running. To solve this, you can either unmount the component at the end of your test (and ensure that any asynchronous operations get canceled in `componentWillUnmount`), or you can change the test itself to be asynchronous.");
3658              }
3659              var evt = document.createEvent("Event");
3660              var didCall = false;
3661              var didError = true;
3662              var windowEvent = window.event;
3663              var windowEventDescriptor = Object.getOwnPropertyDescriptor(window, "event");
3664              function restoreAfterDispatch() {
3665                fakeNode.removeEventListener(evtType, callCallback2, false);
3666                if (typeof window.event !== "undefined" && window.hasOwnProperty("event")) {
3667                  window.event = windowEvent;
3668                }
3669              }
3670              var funcArgs = Array.prototype.slice.call(arguments, 3);
3671              function callCallback2() {
3672                didCall = true;
3673                restoreAfterDispatch();
3674                func.apply(context, funcArgs);
3675                didError = false;
3676              }
3677              var error2;
3678              var didSetError = false;
3679              var isCrossOriginError = false;
3680              function handleWindowError(event) {
3681                error2 = event.error;
3682                didSetError = true;
3683                if (error2 === null && event.colno === 0 && event.lineno === 0) {
3684                  isCrossOriginError = true;
3685                }
3686                if (event.defaultPrevented) {
3687                  if (error2 != null && typeof error2 === "object") {
3688                    try {
3689                      error2._suppressLogging = true;
3690                    } catch (inner) {
3691                    }
3692                  }
3693                }
3694              }
3695              var evtType = "react-" + (name ? name : "invokeguardedcallback");
3696              window.addEventListener("error", handleWindowError);
3697              fakeNode.addEventListener(evtType, callCallback2, false);
3698              evt.initEvent(evtType, false, false);
3699              fakeNode.dispatchEvent(evt);
3700              if (windowEventDescriptor) {
3701                Object.defineProperty(window, "event", windowEventDescriptor);
3702              }
3703              if (didCall && didError) {
3704                if (!didSetError) {
3705                  error2 = new Error(`An error was thrown inside one of your components, but React doesn't know what it was. This is likely due to browser flakiness. React does its best to preserve the "Pause on exceptions" behavior of the DevTools, which requires some DEV-mode only tricks. It's possible that these don't work in your browser. Try triggering the error in production mode, or switching to a modern browser. If you suspect that this is actually an issue with React, please file an issue.`);
3706                } else if (isCrossOriginError) {
3707                  error2 = new Error("A cross-origin error was thrown. React doesn't have access to the actual error object in development. See https://reactjs.org/link/crossorigin-error for more information.");
3708                }
3709                this.onError(error2);
3710              }
3711              window.removeEventListener("error", handleWindowError);
3712              if (!didCall) {
3713                restoreAfterDispatch();
3714                return invokeGuardedCallbackProd.apply(this, arguments);
3715              }
3716            };
3717          }
3718        }
3719        var invokeGuardedCallbackImpl$1 = invokeGuardedCallbackImpl;
3720        var hasError = false;
3721        var caughtError = null;
3722        var hasRethrowError = false;
3723        var rethrowError = null;
3724        var reporter = {
3725          onError: function(error2) {
3726            hasError = true;
3727            caughtError = error2;
3728          }
3729        };
3730        function invokeGuardedCallback(name, func, context, a, b, c, d, e, f) {
3731          hasError = false;
3732          caughtError = null;
3733          invokeGuardedCallbackImpl$1.apply(reporter, arguments);
3734        }
3735        function invokeGuardedCallbackAndCatchFirstError(name, func, context, a, b, c, d, e, f) {
3736          invokeGuardedCallback.apply(this, arguments);
3737          if (hasError) {
3738            var error2 = clearCaughtError();
3739            if (!hasRethrowError) {
3740              hasRethrowError = true;
3741              rethrowError = error2;
3742            }
3743          }
3744        }
3745        function rethrowCaughtError() {
3746          if (hasRethrowError) {
3747            var error2 = rethrowError;
3748            hasRethrowError = false;
3749            rethrowError = null;
3750            throw error2;
3751          }
3752        }
3753        function hasCaughtError() {
3754          return hasError;
3755        }
3756        function clearCaughtError() {
3757          if (hasError) {
3758            var error2 = caughtError;
3759            hasError = false;
3760            caughtError = null;
3761            return error2;
3762          } else {
3763            throw new Error("clearCaughtError was called but no error was captured. This error is likely caused by a bug in React. Please file an issue.");
3764          }
3765        }
3766        function get(key) {
3767          return key._reactInternals;
3768        }
3769        function has(key) {
3770          return key._reactInternals !== void 0;
3771        }
3772        function set(key, value) {
3773          key._reactInternals = value;
3774        }
3775        var NoFlags = (
3776          /*                      */
3777          0
3778        );
3779        var PerformedWork = (
3780          /*                */
3781          1
3782        );
3783        var Placement = (
3784          /*                    */
3785          2
3786        );
3787        var Update = (
3788          /*                       */
3789          4
3790        );
3791        var ChildDeletion = (
3792          /*                */
3793          16
3794        );
3795        var ContentReset = (
3796          /*                 */
3797          32
3798        );
3799        var Callback = (
3800          /*                     */
3801          64
3802        );
3803        var DidCapture = (
3804          /*                   */
3805          128
3806        );
3807        var ForceClientRender = (
3808          /*            */
3809          256
3810        );
3811        var Ref = (
3812          /*                          */
3813          512
3814        );
3815        var Snapshot = (
3816          /*                     */
3817          1024
3818        );
3819        var Passive = (
3820          /*                      */
3821          2048
3822        );
3823        var Hydrating = (
3824          /*                    */
3825          4096
3826        );
3827        var Visibility = (
3828          /*                   */
3829          8192
3830        );
3831        var StoreConsistency = (
3832          /*             */
3833          16384
3834        );
3835        var LifecycleEffectMask = Passive | Update | Callback | Ref | Snapshot | StoreConsistency;
3836        var HostEffectMask = (
3837          /*               */
3838          32767
3839        );
3840        var Incomplete = (
3841          /*                   */
3842          32768
3843        );
3844        var ShouldCapture = (
3845          /*                */
3846          65536
3847        );
3848        var ForceUpdateForLegacySuspense = (
3849          /* */
3850          131072
3851        );
3852        var Forked = (
3853          /*                       */
3854          1048576
3855        );
3856        var RefStatic = (
3857          /*                    */
3858          2097152
3859        );
3860        var LayoutStatic = (
3861          /*                 */
3862          4194304
3863        );
3864        var PassiveStatic = (
3865          /*                */
3866          8388608
3867        );
3868        var MountLayoutDev = (
3869          /*               */
3870          16777216
3871        );
3872        var MountPassiveDev = (
3873          /*              */
3874          33554432
3875        );
3876        var BeforeMutationMask = (
3877          // TODO: Remove Update flag from before mutation phase by re-landing Visibility
3878          // flag logic (see #20043)
3879          Update | Snapshot | 0
3880        );
3881        var MutationMask = Placement | Update | ChildDeletion | ContentReset | Ref | Hydrating | Visibility;
3882        var LayoutMask = Update | Callback | Ref | Visibility;
3883        var PassiveMask = Passive | ChildDeletion;
3884        var StaticMask = LayoutStatic | PassiveStatic | RefStatic;
3885        var ReactCurrentOwner = ReactSharedInternals.ReactCurrentOwner;
3886        function getNearestMountedFiber(fiber) {
3887          var node = fiber;
3888          var nearestMounted = fiber;
3889          if (!fiber.alternate) {
3890            var nextNode = node;
3891            do {
3892              node = nextNode;
3893              if ((node.flags & (Placement | Hydrating)) !== NoFlags) {
3894                nearestMounted = node.return;
3895              }
3896              nextNode = node.return;
3897            } while (nextNode);
3898          } else {
3899            while (node.return) {
3900              node = node.return;
3901            }
3902          }
3903          if (node.tag === HostRoot) {
3904            return nearestMounted;
3905          }
3906          return null;
3907        }
3908        function getSuspenseInstanceFromFiber(fiber) {
3909          if (fiber.tag === SuspenseComponent) {
3910            var suspenseState = fiber.memoizedState;
3911            if (suspenseState === null) {
3912              var current2 = fiber.alternate;
3913              if (current2 !== null) {
3914                suspenseState = current2.memoizedState;
3915              }
3916            }
3917            if (suspenseState !== null) {
3918              return suspenseState.dehydrated;
3919            }
3920          }
3921          return null;
3922        }
3923        function getContainerFromFiber(fiber) {
3924          return fiber.tag === HostRoot ? fiber.stateNode.containerInfo : null;
3925        }
3926        function isFiberMounted(fiber) {
3927          return getNearestMountedFiber(fiber) === fiber;
3928        }
3929        function isMounted(component) {
3930          {
3931            var owner = ReactCurrentOwner.current;
3932            if (owner !== null && owner.tag === ClassComponent) {
3933              var ownerFiber = owner;
3934              var instance = ownerFiber.stateNode;
3935              if (!instance._warnedAboutRefsInRender) {
3936                error("%s is accessing isMounted inside its render() function. render() should be a pure function of props and state. It should never access something that requires stale data from the previous render, such as refs. Move this logic to componentDidMount and componentDidUpdate instead.", getComponentNameFromFiber(ownerFiber) || "A component");
3937              }
3938              instance._warnedAboutRefsInRender = true;
3939            }
3940          }
3941          var fiber = get(component);
3942          if (!fiber) {
3943            return false;
3944          }
3945          return getNearestMountedFiber(fiber) === fiber;
3946        }
3947        function assertIsMounted(fiber) {
3948          if (getNearestMountedFiber(fiber) !== fiber) {
3949            throw new Error("Unable to find node on an unmounted component.");
3950          }
3951        }
3952        function findCurrentFiberUsingSlowPath(fiber) {
3953          var alternate = fiber.alternate;
3954          if (!alternate) {
3955            var nearestMounted = getNearestMountedFiber(fiber);
3956            if (nearestMounted === null) {
3957              throw new Error("Unable to find node on an unmounted component.");
3958            }
3959            if (nearestMounted !== fiber) {
3960              return null;
3961            }
3962            return fiber;
3963          }
3964          var a = fiber;
3965          var b = alternate;
3966          while (true) {
3967            var parentA = a.return;
3968            if (parentA === null) {
3969              break;
3970            }
3971            var parentB = parentA.alternate;
3972            if (parentB === null) {
3973              var nextParent = parentA.return;
3974              if (nextParent !== null) {
3975                a = b = nextParent;
3976                continue;
3977              }
3978              break;
3979            }
3980            if (parentA.child === parentB.child) {
3981              var child = parentA.child;
3982              while (child) {
3983                if (child === a) {
3984                  assertIsMounted(parentA);
3985                  return fiber;
3986                }
3987                if (child === b) {
3988                  assertIsMounted(parentA);
3989                  return alternate;
3990                }
3991                child = child.sibling;
3992              }
3993              throw new Error("Unable to find node on an unmounted component.");
3994            }
3995            if (a.return !== b.return) {
3996              a = parentA;
3997              b = parentB;
3998            } else {
3999              var didFindChild = false;
4000              var _child = parentA.child;
4001              while (_child) {
4002                if (_child === a) {
4003                  didFindChild = true;
4004                  a = parentA;
4005                  b = parentB;
4006                  break;
4007                }
4008                if (_child === b) {
4009                  didFindChild = true;
4010                  b = parentA;
4011                  a = parentB;
4012                  break;
4013                }
4014                _child = _child.sibling;
4015              }
4016              if (!didFindChild) {
4017                _child = parentB.child;
4018                while (_child) {
4019                  if (_child === a) {
4020                    didFindChild = true;
4021                    a = parentB;
4022                    b = parentA;
4023                    break;
4024                  }
4025                  if (_child === b) {
4026                    didFindChild = true;
4027                    b = parentB;
4028                    a = parentA;
4029                    break;
4030                  }
4031                  _child = _child.sibling;
4032                }
4033                if (!didFindChild) {
4034                  throw new Error("Child was not found in either parent set. This indicates a bug in React related to the return pointer. Please file an issue.");
4035                }
4036              }
4037            }
4038            if (a.alternate !== b) {
4039              throw new Error("Return fibers should always be each others' alternates. This error is likely caused by a bug in React. Please file an issue.");
4040            }
4041          }
4042          if (a.tag !== HostRoot) {
4043            throw new Error("Unable to find node on an unmounted component.");
4044          }
4045          if (a.stateNode.current === a) {
4046            return fiber;
4047          }
4048          return alternate;
4049        }
4050        function findCurrentHostFiber(parent) {
4051          var currentParent = findCurrentFiberUsingSlowPath(parent);
4052          return currentParent !== null ? findCurrentHostFiberImpl(currentParent) : null;
4053        }
4054        function findCurrentHostFiberImpl(node) {
4055          if (node.tag === HostComponent || node.tag === HostText) {
4056            return node;
4057          }
4058          var child = node.child;
4059          while (child !== null) {
4060            var match = findCurrentHostFiberImpl(child);
4061            if (match !== null) {
4062              return match;
4063            }
4064            child = child.sibling;
4065          }
4066          return null;
4067        }
4068        function findCurrentHostFiberWithNoPortals(parent) {
4069          var currentParent = findCurrentFiberUsingSlowPath(parent);
4070          return currentParent !== null ? findCurrentHostFiberWithNoPortalsImpl(currentParent) : null;
4071        }
4072        function findCurrentHostFiberWithNoPortalsImpl(node) {
4073          if (node.tag === HostComponent || node.tag === HostText) {
4074            return node;
4075          }
4076          var child = node.child;
4077          while (child !== null) {
4078            if (child.tag !== HostPortal) {
4079              var match = findCurrentHostFiberWithNoPortalsImpl(child);
4080              if (match !== null) {
4081                return match;
4082              }
4083            }
4084            child = child.sibling;
4085          }
4086          return null;
4087        }
4088        var scheduleCallback = Scheduler.unstable_scheduleCallback;
4089        var cancelCallback = Scheduler.unstable_cancelCallback;
4090        var shouldYield = Scheduler.unstable_shouldYield;
4091        var requestPaint = Scheduler.unstable_requestPaint;
4092        var now = Scheduler.unstable_now;
4093        var getCurrentPriorityLevel = Scheduler.unstable_getCurrentPriorityLevel;
4094        var ImmediatePriority = Scheduler.unstable_ImmediatePriority;
4095        var UserBlockingPriority = Scheduler.unstable_UserBlockingPriority;
4096        var NormalPriority = Scheduler.unstable_NormalPriority;
4097        var LowPriority = Scheduler.unstable_LowPriority;
4098        var IdlePriority = Scheduler.unstable_IdlePriority;
4099        var unstable_yieldValue = Scheduler.unstable_yieldValue;
4100        var unstable_setDisableYieldValue = Scheduler.unstable_setDisableYieldValue;
4101        var rendererID = null;
4102        var injectedHook = null;
4103        var injectedProfilingHooks = null;
4104        var hasLoggedError = false;
4105        var isDevToolsPresent = typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ !== "undefined";
4106        function injectInternals(internals) {
4107          if (typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ === "undefined") {
4108            return false;
4109          }
4110          var hook = __REACT_DEVTOOLS_GLOBAL_HOOK__;
4111          if (hook.isDisabled) {
4112            return true;
4113          }
4114          if (!hook.supportsFiber) {
4115            {
4116              error("The installed version of React DevTools is too old and will not work with the current version of React. Please update React DevTools. https://reactjs.org/link/react-devtools");
4117            }
4118            return true;
4119          }
4120          try {
4121            if (enableSchedulingProfiler) {
4122              internals = assign({}, internals, {
4123                getLaneLabelMap,
4124                injectProfilingHooks
4125              });
4126            }
4127            rendererID = hook.inject(internals);
4128            injectedHook = hook;
4129          } catch (err) {
4130            {
4131              error("React instrumentation encountered an error: %s.", err);
4132            }
4133          }
4134          if (hook.checkDCE) {
4135            return true;
4136          } else {
4137            return false;
4138          }
4139        }
4140        function onScheduleRoot(root2, children) {
4141          {
4142            if (injectedHook && typeof injectedHook.onScheduleFiberRoot === "function") {
4143              try {
4144                injectedHook.onScheduleFiberRoot(rendererID, root2, children);
4145              } catch (err) {
4146                if (!hasLoggedError) {
4147                  hasLoggedError = true;
4148                  error("React instrumentation encountered an error: %s", err);
4149                }
4150              }
4151            }
4152          }
4153        }
4154        function onCommitRoot(root2, eventPriority) {
4155          if (injectedHook && typeof injectedHook.onCommitFiberRoot === "function") {
4156            try {
4157              var didError = (root2.current.flags & DidCapture) === DidCapture;
4158              if (enableProfilerTimer) {
4159                var schedulerPriority;
4160                switch (eventPriority) {
4161                  case DiscreteEventPriority:
4162                    schedulerPriority = ImmediatePriority;
4163                    break;
4164                  case ContinuousEventPriority:
4165                    schedulerPriority = UserBlockingPriority;
4166                    break;
4167                  case DefaultEventPriority:
4168                    schedulerPriority = NormalPriority;
4169                    break;
4170                  case IdleEventPriority:
4171                    schedulerPriority = IdlePriority;
4172                    break;
4173                  default:
4174                    schedulerPriority = NormalPriority;
4175                    break;
4176                }
4177                injectedHook.onCommitFiberRoot(rendererID, root2, schedulerPriority, didError);
4178              } else {
4179                injectedHook.onCommitFiberRoot(rendererID, root2, void 0, didError);
4180              }
4181            } catch (err) {
4182              {
4183                if (!hasLoggedError) {
4184                  hasLoggedError = true;
4185                  error("React instrumentation encountered an error: %s", err);
4186                }
4187              }
4188            }
4189          }
4190        }
4191        function onPostCommitRoot(root2) {
4192          if (injectedHook && typeof injectedHook.onPostCommitFiberRoot === "function") {
4193            try {
4194              injectedHook.onPostCommitFiberRoot(rendererID, root2);
4195            } catch (err) {
4196              {
4197                if (!hasLoggedError) {
4198                  hasLoggedError = true;
4199                  error("React instrumentation encountered an error: %s", err);
4200                }
4201              }
4202            }
4203          }
4204        }
4205        function onCommitUnmount(fiber) {
4206          if (injectedHook && typeof injectedHook.onCommitFiberUnmount === "function") {
4207            try {
4208              injectedHook.onCommitFiberUnmount(rendererID, fiber);
4209            } catch (err) {
4210              {
4211                if (!hasLoggedError) {
4212                  hasLoggedError = true;
4213                  error("React instrumentation encountered an error: %s", err);
4214                }
4215              }
4216            }
4217          }
4218        }
4219        function setIsStrictModeForDevtools(newIsStrictMode) {
4220          {
4221            if (typeof unstable_yieldValue === "function") {
4222              unstable_setDisableYieldValue(newIsStrictMode);
4223              setSuppressWarning(newIsStrictMode);
4224            }
4225            if (injectedHook && typeof injectedHook.setStrictMode === "function") {
4226              try {
4227                injectedHook.setStrictMode(rendererID, newIsStrictMode);
4228              } catch (err) {
4229                {
4230                  if (!hasLoggedError) {
4231                    hasLoggedError = true;
4232                    error("React instrumentation encountered an error: %s", err);
4233                  }
4234                }
4235              }
4236            }
4237          }
4238        }
4239        function injectProfilingHooks(profilingHooks) {
4240          injectedProfilingHooks = profilingHooks;
4241        }
4242        function getLaneLabelMap() {
4243          {
4244            var map = /* @__PURE__ */ new Map();
4245            var lane = 1;
4246            for (var index2 = 0; index2 < TotalLanes; index2++) {
4247              var label = getLabelForLane(lane);
4248              map.set(lane, label);
4249              lane *= 2;
4250            }
4251            return map;
4252          }
4253        }
4254        function markCommitStarted(lanes) {
4255          {
4256            if (injectedProfilingHooks !== null && typeof injectedProfilingHooks.markCommitStarted === "function") {
4257              injectedProfilingHooks.markCommitStarted(lanes);
4258            }
4259          }
4260        }
4261        function markCommitStopped() {
4262          {
4263            if (injectedProfilingHooks !== null && typeof injectedProfilingHooks.markCommitStopped === "function") {
4264              injectedProfilingHooks.markCommitStopped();
4265            }
4266          }
4267        }
4268        function markComponentRenderStarted(fiber) {
4269          {
4270            if (injectedProfilingHooks !== null && typeof injectedProfilingHooks.markComponentRenderStarted === "function") {
4271              injectedProfilingHooks.markComponentRenderStarted(fiber);
4272            }
4273          }
4274        }
4275        function markComponentRenderStopped() {
4276          {
4277            if (injectedProfilingHooks !== null && typeof injectedProfilingHooks.markComponentRenderStopped === "function") {
4278              injectedProfilingHooks.markComponentRenderStopped();
4279            }
4280          }
4281        }
4282        function markComponentPassiveEffectMountStarted(fiber) {
4283          {
4284            if (injectedProfilingHooks !== null && typeof injectedProfilingHooks.markComponentPassiveEffectMountStarted === "function") {
4285              injectedProfilingHooks.markComponentPassiveEffectMountStarted(fiber);
4286            }
4287          }
4288        }
4289        function markComponentPassiveEffectMountStopped() {
4290          {
4291            if (injectedProfilingHooks !== null && typeof injectedProfilingHooks.markComponentPassiveEffectMountStopped === "function") {
4292              injectedProfilingHooks.markComponentPassiveEffectMountStopped();
4293            }
4294          }
4295        }
4296        function markComponentPassiveEffectUnmountStarted(fiber) {
4297          {
4298            if (injectedProfilingHooks !== null && typeof injectedProfilingHooks.markComponentPassiveEffectUnmountStarted === "function") {
4299              injectedProfilingHooks.markComponentPassiveEffectUnmountStarted(fiber);
4300            }
4301          }
4302        }
4303        function markComponentPassiveEffectUnmountStopped() {
4304          {
4305            if (injectedProfilingHooks !== null && typeof injectedProfilingHooks.markComponentPassiveEffectUnmountStopped === "function") {
4306              injectedProfilingHooks.markComponentPassiveEffectUnmountStopped();
4307            }
4308          }
4309        }
4310        function markComponentLayoutEffectMountStarted(fiber) {
4311          {
4312            if (injectedProfilingHooks !== null && typeof injectedProfilingHooks.markComponentLayoutEffectMountStarted === "function") {
4313              injectedProfilingHooks.markComponentLayoutEffectMountStarted(fiber);
4314            }
4315          }
4316        }
4317        function markComponentLayoutEffectMountStopped() {
4318          {
4319            if (injectedProfilingHooks !== null && typeof injectedProfilingHooks.markComponentLayoutEffectMountStopped === "function") {
4320              injectedProfilingHooks.markComponentLayoutEffectMountStopped();
4321            }
4322          }
4323        }
4324        function markComponentLayoutEffectUnmountStarted(fiber) {
4325          {
4326            if (injectedProfilingHooks !== null && typeof injectedProfilingHooks.markComponentLayoutEffectUnmountStarted === "function") {
4327              injectedProfilingHooks.markComponentLayoutEffectUnmountStarted(fiber);
4328            }
4329          }
4330        }
4331        function markComponentLayoutEffectUnmountStopped() {
4332          {
4333            if (injectedProfilingHooks !== null && typeof injectedProfilingHooks.markComponentLayoutEffectUnmountStopped === "function") {
4334              injectedProfilingHooks.markComponentLayoutEffectUnmountStopped();
4335            }
4336          }
4337        }
4338        function markComponentErrored(fiber, thrownValue, lanes) {
4339          {
4340            if (injectedProfilingHooks !== null && typeof injectedProfilingHooks.markComponentErrored === "function") {
4341              injectedProfilingHooks.markComponentErrored(fiber, thrownValue, lanes);
4342            }
4343          }
4344        }
4345        function markComponentSuspended(fiber, wakeable, lanes) {
4346          {
4347            if (injectedProfilingHooks !== null && typeof injectedProfilingHooks.markComponentSuspended === "function") {
4348              injectedProfilingHooks.markComponentSuspended(fiber, wakeable, lanes);
4349            }
4350          }
4351        }
4352        function markLayoutEffectsStarted(lanes) {
4353          {
4354            if (injectedProfilingHooks !== null && typeof injectedProfilingHooks.markLayoutEffectsStarted === "function") {
4355              injectedProfilingHooks.markLayoutEffectsStarted(lanes);
4356            }
4357          }
4358        }
4359        function markLayoutEffectsStopped() {
4360          {
4361            if (injectedProfilingHooks !== null && typeof injectedProfilingHooks.markLayoutEffectsStopped === "function") {
4362              injectedProfilingHooks.markLayoutEffectsStopped();
4363            }
4364          }
4365        }
4366        function markPassiveEffectsStarted(lanes) {
4367          {
4368            if (injectedProfilingHooks !== null && typeof injectedProfilingHooks.markPassiveEffectsStarted === "function") {
4369              injectedProfilingHooks.markPassiveEffectsStarted(lanes);
4370            }
4371          }
4372        }
4373        function markPassiveEffectsStopped() {
4374          {
4375            if (injectedProfilingHooks !== null && typeof injectedProfilingHooks.markPassiveEffectsStopped === "function") {
4376              injectedProfilingHooks.markPassiveEffectsStopped();
4377            }
4378          }
4379        }
4380        function markRenderStarted(lanes) {
4381          {
4382            if (injectedProfilingHooks !== null && typeof injectedProfilingHooks.markRenderStarted === "function") {
4383              injectedProfilingHooks.markRenderStarted(lanes);
4384            }
4385          }
4386        }
4387        function markRenderYielded() {
4388          {
4389            if (injectedProfilingHooks !== null && typeof injectedProfilingHooks.markRenderYielded === "function") {
4390              injectedProfilingHooks.markRenderYielded();
4391            }
4392          }
4393        }
4394        function markRenderStopped() {
4395          {
4396            if (injectedProfilingHooks !== null && typeof injectedProfilingHooks.markRenderStopped === "function") {
4397              injectedProfilingHooks.markRenderStopped();
4398            }
4399          }
4400        }
4401        function markRenderScheduled(lane) {
4402          {
4403            if (injectedProfilingHooks !== null && typeof injectedProfilingHooks.markRenderScheduled === "function") {
4404              injectedProfilingHooks.markRenderScheduled(lane);
4405            }
4406          }
4407        }
4408        function markForceUpdateScheduled(fiber, lane) {
4409          {
4410            if (injectedProfilingHooks !== null && typeof injectedProfilingHooks.markForceUpdateScheduled === "function") {
4411              injectedProfilingHooks.markForceUpdateScheduled(fiber, lane);
4412            }
4413          }
4414        }
4415        function markStateUpdateScheduled(fiber, lane) {
4416          {
4417            if (injectedProfilingHooks !== null && typeof injectedProfilingHooks.markStateUpdateScheduled === "function") {
4418              injectedProfilingHooks.markStateUpdateScheduled(fiber, lane);
4419            }
4420          }
4421        }
4422        var NoMode = (
4423          /*                         */
4424          0
4425        );
4426        var ConcurrentMode = (
4427          /*                 */
4428          1
4429        );
4430        var ProfileMode = (
4431          /*                    */
4432          2
4433        );
4434        var StrictLegacyMode = (
4435          /*               */
4436          8
4437        );
4438        var StrictEffectsMode = (
4439          /*              */
4440          16
4441        );
4442        var clz32 = Math.clz32 ? Math.clz32 : clz32Fallback;
4443        var log = Math.log;
4444        var LN2 = Math.LN2;
4445        function clz32Fallback(x) {
4446          var asUint = x >>> 0;
4447          if (asUint === 0) {
4448            return 32;
4449          }
4450          return 31 - (log(asUint) / LN2 | 0) | 0;
4451        }
4452        var TotalLanes = 31;
4453        var NoLanes = (
4454          /*                        */
4455          0
4456        );
4457        var NoLane = (
4458          /*                          */
4459          0
4460        );
4461        var SyncLane = (
4462          /*                        */
4463          1
4464        );
4465        var InputContinuousHydrationLane = (
4466          /*    */
4467          2
4468        );
4469        var InputContinuousLane = (
4470          /*             */
4471          4
4472        );
4473        var DefaultHydrationLane = (
4474          /*            */
4475          8
4476        );
4477        var DefaultLane = (
4478          /*                     */
4479          16
4480        );
4481        var TransitionHydrationLane = (
4482          /*                */
4483          32
4484        );
4485        var TransitionLanes = (
4486          /*                       */
4487          4194240
4488        );
4489        var TransitionLane1 = (
4490          /*                        */
4491          64
4492        );
4493        var TransitionLane2 = (
4494          /*                        */
4495          128
4496        );
4497        var TransitionLane3 = (
4498          /*                        */
4499          256
4500        );
4501        var TransitionLane4 = (
4502          /*                        */
4503          512
4504        );
4505        var TransitionLane5 = (
4506          /*                        */
4507          1024
4508        );
4509        var TransitionLane6 = (
4510          /*                        */
4511          2048
4512        );
4513        var TransitionLane7 = (
4514          /*                        */
4515          4096
4516        );
4517        var TransitionLane8 = (
4518          /*                        */
4519          8192
4520        );
4521        var TransitionLane9 = (
4522          /*                        */
4523          16384
4524        );
4525        var TransitionLane10 = (
4526          /*                       */
4527          32768
4528        );
4529        var TransitionLane11 = (
4530          /*                       */
4531          65536
4532        );
4533        var TransitionLane12 = (
4534          /*                       */
4535          131072
4536        );
4537        var TransitionLane13 = (
4538          /*                       */
4539          262144
4540        );
4541        var TransitionLane14 = (
4542          /*                       */
4543          524288
4544        );
4545        var TransitionLane15 = (
4546          /*                       */
4547          1048576
4548        );
4549        var TransitionLane16 = (
4550          /*                       */
4551          2097152
4552        );
4553        var RetryLanes = (
4554          /*                            */
4555          130023424
4556        );
4557        var RetryLane1 = (
4558          /*                             */
4559          4194304
4560        );
4561        var RetryLane2 = (
4562          /*                             */
4563          8388608
4564        );
4565        var RetryLane3 = (
4566          /*                             */
4567          16777216
4568        );
4569        var RetryLane4 = (
4570          /*                             */
4571          33554432
4572        );
4573        var RetryLane5 = (
4574          /*                             */
4575          67108864
4576        );
4577        var SomeRetryLane = RetryLane1;
4578        var SelectiveHydrationLane = (
4579          /*          */
4580          134217728
4581        );
4582        var NonIdleLanes = (
4583          /*                          */
4584          268435455
4585        );
4586        var IdleHydrationLane = (
4587          /*               */
4588          268435456
4589        );
4590        var IdleLane = (
4591          /*                        */
4592          536870912
4593        );
4594        var OffscreenLane = (
4595          /*                   */
4596          1073741824
4597        );
4598        function getLabelForLane(lane) {
4599          {
4600            if (lane & SyncLane) {
4601              return "Sync";
4602            }
4603            if (lane & InputContinuousHydrationLane) {
4604              return "InputContinuousHydration";
4605            }
4606            if (lane & InputContinuousLane) {
4607              return "InputContinuous";
4608            }
4609            if (lane & DefaultHydrationLane) {
4610              return "DefaultHydration";
4611            }
4612            if (lane & DefaultLane) {
4613              return "Default";
4614            }
4615            if (lane & TransitionHydrationLane) {
4616              return "TransitionHydration";
4617            }
4618            if (lane & TransitionLanes) {
4619              return "Transition";
4620            }
4621            if (lane & RetryLanes) {
4622              return "Retry";
4623            }
4624            if (lane & SelectiveHydrationLane) {
4625              return "SelectiveHydration";
4626            }
4627            if (lane & IdleHydrationLane) {
4628              return "IdleHydration";
4629            }
4630            if (lane & IdleLane) {
4631              return "Idle";
4632            }
4633            if (lane & OffscreenLane) {
4634              return "Offscreen";
4635            }
4636          }
4637        }
4638        var NoTimestamp = -1;
4639        var nextTransitionLane = TransitionLane1;
4640        var nextRetryLane = RetryLane1;
4641        function getHighestPriorityLanes(lanes) {
4642          switch (getHighestPriorityLane(lanes)) {
4643            case SyncLane:
4644              return SyncLane;
4645            case InputContinuousHydrationLane:
4646              return InputContinuousHydrationLane;
4647            case InputContinuousLane:
4648              return InputContinuousLane;
4649            case DefaultHydrationLane:
4650              return DefaultHydrationLane;
4651            case DefaultLane:
4652              return DefaultLane;
4653            case TransitionHydrationLane:
4654              return TransitionHydrationLane;
4655            case TransitionLane1:
4656            case TransitionLane2:
4657            case TransitionLane3:
4658            case TransitionLane4:
4659            case TransitionLane5:
4660            case TransitionLane6:
4661            case TransitionLane7:
4662            case TransitionLane8:
4663            case TransitionLane9:
4664            case TransitionLane10:
4665            case TransitionLane11:
4666            case TransitionLane12:
4667            case TransitionLane13:
4668            case TransitionLane14:
4669            case TransitionLane15:
4670            case TransitionLane16:
4671              return lanes & TransitionLanes;
4672            case RetryLane1:
4673            case RetryLane2:
4674            case RetryLane3:
4675            case RetryLane4:
4676            case RetryLane5:
4677              return lanes & RetryLanes;
4678            case SelectiveHydrationLane:
4679              return SelectiveHydrationLane;
4680            case IdleHydrationLane:
4681              return IdleHydrationLane;
4682            case IdleLane:
4683              return IdleLane;
4684            case OffscreenLane:
4685              return OffscreenLane;
4686            default:
4687              {
4688                error("Should have found matching lanes. This is a bug in React.");
4689              }
4690              return lanes;
4691          }
4692        }
4693        function getNextLanes(root2, wipLanes) {
4694          var pendingLanes = root2.pendingLanes;
4695          if (pendingLanes === NoLanes) {
4696            return NoLanes;
4697          }
4698          var nextLanes = NoLanes;
4699          var suspendedLanes = root2.suspendedLanes;
4700          var pingedLanes = root2.pingedLanes;
4701          var nonIdlePendingLanes = pendingLanes & NonIdleLanes;
4702          if (nonIdlePendingLanes !== NoLanes) {
4703            var nonIdleUnblockedLanes = nonIdlePendingLanes & ~suspendedLanes;
4704            if (nonIdleUnblockedLanes !== NoLanes) {
4705              nextLanes = getHighestPriorityLanes(nonIdleUnblockedLanes);
4706            } else {
4707              var nonIdlePingedLanes = nonIdlePendingLanes & pingedLanes;
4708              if (nonIdlePingedLanes !== NoLanes) {
4709                nextLanes = getHighestPriorityLanes(nonIdlePingedLanes);
4710              }
4711            }
4712          } else {
4713            var unblockedLanes = pendingLanes & ~suspendedLanes;
4714            if (unblockedLanes !== NoLanes) {
4715              nextLanes = getHighestPriorityLanes(unblockedLanes);
4716            } else {
4717              if (pingedLanes !== NoLanes) {
4718                nextLanes = getHighestPriorityLanes(pingedLanes);
4719              }
4720            }
4721          }
4722          if (nextLanes === NoLanes) {
4723            return NoLanes;
4724          }
4725          if (wipLanes !== NoLanes && wipLanes !== nextLanes && // If we already suspended with a delay, then interrupting is fine. Don't
4726          // bother waiting until the root is complete.
4727          (wipLanes & suspendedLanes) === NoLanes) {
4728            var nextLane = getHighestPriorityLane(nextLanes);
4729            var wipLane = getHighestPriorityLane(wipLanes);
4730            if (
4731              // Tests whether the next lane is equal or lower priority than the wip
4732              // one. This works because the bits decrease in priority as you go left.
4733              nextLane >= wipLane || // Default priority updates should not interrupt transition updates. The
4734              // only difference between default updates and transition updates is that
4735              // default updates do not support refresh transitions.
4736              nextLane === DefaultLane && (wipLane & TransitionLanes) !== NoLanes
4737            ) {
4738              return wipLanes;
4739            }
4740          }
4741          if ((nextLanes & InputContinuousLane) !== NoLanes) {
4742            nextLanes |= pendingLanes & DefaultLane;
4743          }
4744          var entangledLanes = root2.entangledLanes;
4745          if (entangledLanes !== NoLanes) {
4746            var entanglements = root2.entanglements;
4747            var lanes = nextLanes & entangledLanes;
4748            while (lanes > 0) {
4749              var index2 = pickArbitraryLaneIndex(lanes);
4750              var lane = 1 << index2;
4751              nextLanes |= entanglements[index2];
4752              lanes &= ~lane;
4753            }
4754          }
4755          return nextLanes;
4756        }
4757        function getMostRecentEventTime(root2, lanes) {
4758          var eventTimes = root2.eventTimes;
4759          var mostRecentEventTime = NoTimestamp;
4760          while (lanes > 0) {
4761            var index2 = pickArbitraryLaneIndex(lanes);
4762            var lane = 1 << index2;
4763            var eventTime = eventTimes[index2];
4764            if (eventTime > mostRecentEventTime) {
4765              mostRecentEventTime = eventTime;
4766            }
4767            lanes &= ~lane;
4768          }
4769          return mostRecentEventTime;
4770        }
4771        function computeExpirationTime(lane, currentTime) {
4772          switch (lane) {
4773            case SyncLane:
4774            case InputContinuousHydrationLane:
4775            case InputContinuousLane:
4776              return currentTime + 250;
4777            case DefaultHydrationLane:
4778            case DefaultLane:
4779            case TransitionHydrationLane:
4780            case TransitionLane1:
4781            case TransitionLane2:
4782            case TransitionLane3:
4783            case TransitionLane4:
4784            case TransitionLane5:
4785            case TransitionLane6:
4786            case TransitionLane7:
4787            case TransitionLane8:
4788            case TransitionLane9:
4789            case TransitionLane10:
4790            case TransitionLane11:
4791            case TransitionLane12:
4792            case TransitionLane13:
4793            case TransitionLane14:
4794            case TransitionLane15:
4795            case TransitionLane16:
4796              return currentTime + 5e3;
4797            case RetryLane1:
4798            case RetryLane2:
4799            case RetryLane3:
4800            case RetryLane4:
4801            case RetryLane5:
4802              return NoTimestamp;
4803            case SelectiveHydrationLane:
4804            case IdleHydrationLane:
4805            case IdleLane:
4806            case OffscreenLane:
4807              return NoTimestamp;
4808            default:
4809              {
4810                error("Should have found matching lanes. This is a bug in React.");
4811              }
4812              return NoTimestamp;
4813          }
4814        }
4815        function markStarvedLanesAsExpired(root2, currentTime) {
4816          var pendingLanes = root2.pendingLanes;
4817          var suspendedLanes = root2.suspendedLanes;
4818          var pingedLanes = root2.pingedLanes;
4819          var expirationTimes = root2.expirationTimes;
4820          var lanes = pendingLanes;
4821          while (lanes > 0) {
4822            var index2 = pickArbitraryLaneIndex(lanes);
4823            var lane = 1 << index2;
4824            var expirationTime = expirationTimes[index2];
4825            if (expirationTime === NoTimestamp) {
4826              if ((lane & suspendedLanes) === NoLanes || (lane & pingedLanes) !== NoLanes) {
4827                expirationTimes[index2] = computeExpirationTime(lane, currentTime);
4828              }
4829            } else if (expirationTime <= currentTime) {
4830              root2.expiredLanes |= lane;
4831            }
4832            lanes &= ~lane;
4833          }
4834        }
4835        function getHighestPriorityPendingLanes(root2) {
4836          return getHighestPriorityLanes(root2.pendingLanes);
4837        }
4838        function getLanesToRetrySynchronouslyOnError(root2) {
4839          var everythingButOffscreen = root2.pendingLanes & ~OffscreenLane;
4840          if (everythingButOffscreen !== NoLanes) {
4841            return everythingButOffscreen;
4842          }
4843          if (everythingButOffscreen & OffscreenLane) {
4844            return OffscreenLane;
4845          }
4846          return NoLanes;
4847        }
4848        function includesSyncLane(lanes) {
4849          return (lanes & SyncLane) !== NoLanes;
4850        }
4851        function includesNonIdleWork(lanes) {
4852          return (lanes & NonIdleLanes) !== NoLanes;
4853        }
4854        function includesOnlyRetries(lanes) {
4855          return (lanes & RetryLanes) === lanes;
4856        }
4857        function includesOnlyNonUrgentLanes(lanes) {
4858          var UrgentLanes = SyncLane | InputContinuousLane | DefaultLane;
4859          return (lanes & UrgentLanes) === NoLanes;
4860        }
4861        function includesOnlyTransitions(lanes) {
4862          return (lanes & TransitionLanes) === lanes;
4863        }
4864        function includesBlockingLane(root2, lanes) {
4865          var SyncDefaultLanes = InputContinuousHydrationLane | InputContinuousLane | DefaultHydrationLane | DefaultLane;
4866          return (lanes & SyncDefaultLanes) !== NoLanes;
4867        }
4868        function includesExpiredLane(root2, lanes) {
4869          return (lanes & root2.expiredLanes) !== NoLanes;
4870        }
4871        function isTransitionLane(lane) {
4872          return (lane & TransitionLanes) !== NoLanes;
4873        }
4874        function claimNextTransitionLane() {
4875          var lane = nextTransitionLane;
4876          nextTransitionLane <<= 1;
4877          if ((nextTransitionLane & TransitionLanes) === NoLanes) {
4878            nextTransitionLane = TransitionLane1;
4879          }
4880          return lane;
4881        }
4882        function claimNextRetryLane() {
4883          var lane = nextRetryLane;
4884          nextRetryLane <<= 1;
4885          if ((nextRetryLane & RetryLanes) === NoLanes) {
4886            nextRetryLane = RetryLane1;
4887          }
4888          return lane;
4889        }
4890        function getHighestPriorityLane(lanes) {
4891          return lanes & -lanes;
4892        }
4893        function pickArbitraryLane(lanes) {
4894          return getHighestPriorityLane(lanes);
4895        }
4896        function pickArbitraryLaneIndex(lanes) {
4897          return 31 - clz32(lanes);
4898        }
4899        function laneToIndex(lane) {
4900          return pickArbitraryLaneIndex(lane);
4901        }
4902        function includesSomeLane(a, b) {
4903          return (a & b) !== NoLanes;
4904        }
4905        function isSubsetOfLanes(set2, subset) {
4906          return (set2 & subset) === subset;
4907        }
4908        function mergeLanes(a, b) {
4909          return a | b;
4910        }
4911        function removeLanes(set2, subset) {
4912          return set2 & ~subset;
4913        }
4914        function intersectLanes(a, b) {
4915          return a & b;
4916        }
4917        function laneToLanes(lane) {
4918          return lane;
4919        }
4920        function higherPriorityLane(a, b) {
4921          return a !== NoLane && a < b ? a : b;
4922        }
4923        function createLaneMap(initial) {
4924          var laneMap = [];
4925          for (var i = 0; i < TotalLanes; i++) {
4926            laneMap.push(initial);
4927          }
4928          return laneMap;
4929        }
4930        function markRootUpdated(root2, updateLane, eventTime) {
4931          root2.pendingLanes |= updateLane;
4932          if (updateLane !== IdleLane) {
4933            root2.suspendedLanes = NoLanes;
4934            root2.pingedLanes = NoLanes;
4935          }
4936          var eventTimes = root2.eventTimes;
4937          var index2 = laneToIndex(updateLane);
4938          eventTimes[index2] = eventTime;
4939        }
4940        function markRootSuspended(root2, suspendedLanes) {
4941          root2.suspendedLanes |= suspendedLanes;
4942          root2.pingedLanes &= ~suspendedLanes;
4943          var expirationTimes = root2.expirationTimes;
4944          var lanes = suspendedLanes;
4945          while (lanes > 0) {
4946            var index2 = pickArbitraryLaneIndex(lanes);
4947            var lane = 1 << index2;
4948            expirationTimes[index2] = NoTimestamp;
4949            lanes &= ~lane;
4950          }
4951        }
4952        function markRootPinged(root2, pingedLanes, eventTime) {
4953          root2.pingedLanes |= root2.suspendedLanes & pingedLanes;
4954        }
4955        function markRootFinished(root2, remainingLanes) {
4956          var noLongerPendingLanes = root2.pendingLanes & ~remainingLanes;
4957          root2.pendingLanes = remainingLanes;
4958          root2.suspendedLanes = NoLanes;
4959          root2.pingedLanes = NoLanes;
4960          root2.expiredLanes &= remainingLanes;
4961          root2.mutableReadLanes &= remainingLanes;
4962          root2.entangledLanes &= remainingLanes;
4963          var entanglements = root2.entanglements;
4964          var eventTimes = root2.eventTimes;
4965          var expirationTimes = root2.expirationTimes;
4966          var lanes = noLongerPendingLanes;
4967          while (lanes > 0) {
4968            var index2 = pickArbitraryLaneIndex(lanes);
4969            var lane = 1 << index2;
4970            entanglements[index2] = NoLanes;
4971            eventTimes[index2] = NoTimestamp;
4972            expirationTimes[index2] = NoTimestamp;
4973            lanes &= ~lane;
4974          }
4975        }
4976        function markRootEntangled(root2, entangledLanes) {
4977          var rootEntangledLanes = root2.entangledLanes |= entangledLanes;
4978          var entanglements = root2.entanglements;
4979          var lanes = rootEntangledLanes;
4980          while (lanes) {
4981            var index2 = pickArbitraryLaneIndex(lanes);
4982            var lane = 1 << index2;
4983            if (
4984              // Is this one of the newly entangled lanes?
4985              lane & entangledLanes | // Is this lane transitively entangled with the newly entangled lanes?
4986              entanglements[index2] & entangledLanes
4987            ) {
4988              entanglements[index2] |= entangledLanes;
4989            }
4990            lanes &= ~lane;
4991          }
4992        }
4993        function getBumpedLaneForHydration(root2, renderLanes2) {
4994          var renderLane = getHighestPriorityLane(renderLanes2);
4995          var lane;
4996          switch (renderLane) {
4997            case InputContinuousLane:
4998              lane = InputContinuousHydrationLane;
4999              break;
5000            case DefaultLane:
5001              lane = DefaultHydrationLane;
5002              break;
5003            case TransitionLane1:
5004            case TransitionLane2:
5005            case TransitionLane3:
5006            case TransitionLane4:
5007            case TransitionLane5:
5008            case TransitionLane6:
5009            case TransitionLane7:
5010            case TransitionLane8:
5011            case TransitionLane9:
5012            case TransitionLane10:
5013            case TransitionLane11:
5014            case TransitionLane12:
5015            case TransitionLane13:
5016            case TransitionLane14:
5017            case TransitionLane15:
5018            case TransitionLane16:
5019            case RetryLane1:
5020            case RetryLane2:
5021            case RetryLane3:
5022            case RetryLane4:
5023            case RetryLane5:
5024              lane = TransitionHydrationLane;
5025              break;
5026            case IdleLane:
5027              lane = IdleHydrationLane;
5028              break;
5029            default:
5030              lane = NoLane;
5031              break;
5032          }
5033          if ((lane & (root2.suspendedLanes | renderLanes2)) !== NoLane) {
5034            return NoLane;
5035          }
5036          return lane;
5037        }
5038        function addFiberToLanesMap(root2, fiber, lanes) {
5039          if (!isDevToolsPresent) {
5040            return;
5041          }
5042          var pendingUpdatersLaneMap = root2.pendingUpdatersLaneMap;
5043          while (lanes > 0) {
5044            var index2 = laneToIndex(lanes);
5045            var lane = 1 << index2;
5046            var updaters = pendingUpdatersLaneMap[index2];
5047            updaters.add(fiber);
5048            lanes &= ~lane;
5049          }
5050        }
5051        function movePendingFibersToMemoized(root2, lanes) {
5052          if (!isDevToolsPresent) {
5053            return;
5054          }
5055          var pendingUpdatersLaneMap = root2.pendingUpdatersLaneMap;
5056          var memoizedUpdaters = root2.memoizedUpdaters;
5057          while (lanes > 0) {
5058            var index2 = laneToIndex(lanes);
5059            var lane = 1 << index2;
5060            var updaters = pendingUpdatersLaneMap[index2];
5061            if (updaters.size > 0) {
5062              updaters.forEach(function(fiber) {
5063                var alternate = fiber.alternate;
5064                if (alternate === null || !memoizedUpdaters.has(alternate)) {
5065                  memoizedUpdaters.add(fiber);
5066                }
5067              });
5068              updaters.clear();
5069            }
5070            lanes &= ~lane;
5071          }
5072        }
5073        function getTransitionsForLanes(root2, lanes) {
5074          {
5075            return null;
5076          }
5077        }
5078        var DiscreteEventPriority = SyncLane;
5079        var ContinuousEventPriority = InputContinuousLane;
5080        var DefaultEventPriority = DefaultLane;
5081        var IdleEventPriority = IdleLane;
5082        var currentUpdatePriority = NoLane;
5083        function getCurrentUpdatePriority() {
5084          return currentUpdatePriority;
5085        }
5086        function setCurrentUpdatePriority(newPriority) {
5087          currentUpdatePriority = newPriority;
5088        }
5089        function runWithPriority(priority, fn) {
5090          var previousPriority = currentUpdatePriority;
5091          try {
5092            currentUpdatePriority = priority;
5093            return fn();
5094          } finally {
5095            currentUpdatePriority = previousPriority;
5096          }
5097        }
5098        function higherEventPriority(a, b) {
5099          return a !== 0 && a < b ? a : b;
5100        }
5101        function lowerEventPriority(a, b) {
5102          return a === 0 || a > b ? a : b;
5103        }
5104        function isHigherEventPriority(a, b) {
5105          return a !== 0 && a < b;
5106        }
5107        function lanesToEventPriority(lanes) {
5108          var lane = getHighestPriorityLane(lanes);
5109          if (!isHigherEventPriority(DiscreteEventPriority, lane)) {
5110            return DiscreteEventPriority;
5111          }
5112          if (!isHigherEventPriority(ContinuousEventPriority, lane)) {
5113            return ContinuousEventPriority;
5114          }
5115          if (includesNonIdleWork(lane)) {
5116            return DefaultEventPriority;
5117          }
5118          return IdleEventPriority;
5119        }
5120        function isRootDehydrated(root2) {
5121          var currentState = root2.current.memoizedState;
5122          return currentState.isDehydrated;
5123        }
5124        var _attemptSynchronousHydration;
5125        function setAttemptSynchronousHydration(fn) {
5126          _attemptSynchronousHydration = fn;
5127        }
5128        function attemptSynchronousHydration(fiber) {
5129          _attemptSynchronousHydration(fiber);
5130        }
5131        var attemptContinuousHydration;
5132        function setAttemptContinuousHydration(fn) {
5133          attemptContinuousHydration = fn;
5134        }
5135        var attemptHydrationAtCurrentPriority;
5136        function setAttemptHydrationAtCurrentPriority(fn) {
5137          attemptHydrationAtCurrentPriority = fn;
5138        }
5139        var getCurrentUpdatePriority$1;
5140        function setGetCurrentUpdatePriority(fn) {
5141          getCurrentUpdatePriority$1 = fn;
5142        }
5143        var attemptHydrationAtPriority;
5144        function setAttemptHydrationAtPriority(fn) {
5145          attemptHydrationAtPriority = fn;
5146        }
5147        var hasScheduledReplayAttempt = false;
5148        var queuedDiscreteEvents = [];
5149        var queuedFocus = null;
5150        var queuedDrag = null;
5151        var queuedMouse = null;
5152        var queuedPointers = /* @__PURE__ */ new Map();
5153        var queuedPointerCaptures = /* @__PURE__ */ new Map();
5154        var queuedExplicitHydrationTargets = [];
5155        var discreteReplayableEvents = [
5156          "mousedown",
5157          "mouseup",
5158          "touchcancel",
5159          "touchend",
5160          "touchstart",
5161          "auxclick",
5162          "dblclick",
5163          "pointercancel",
5164          "pointerdown",
5165          "pointerup",
5166          "dragend",
5167          "dragstart",
5168          "drop",
5169          "compositionend",
5170          "compositionstart",
5171          "keydown",
5172          "keypress",
5173          "keyup",
5174          "input",
5175          "textInput",
5176          // Intentionally camelCase
5177          "copy",
5178          "cut",
5179          "paste",
5180          "click",
5181          "change",
5182          "contextmenu",
5183          "reset",
5184          "submit"
5185        ];
5186        function isDiscreteEventThatRequiresHydration(eventType) {
5187          return discreteReplayableEvents.indexOf(eventType) > -1;
5188        }
5189        function createQueuedReplayableEvent(blockedOn, domEventName, eventSystemFlags, targetContainer, nativeEvent) {
5190          return {
5191            blockedOn,
5192            domEventName,
5193            eventSystemFlags,
5194            nativeEvent,
5195            targetContainers: [targetContainer]
5196          };
5197        }
5198        function clearIfContinuousEvent(domEventName, nativeEvent) {
5199          switch (domEventName) {
5200            case "focusin":
5201            case "focusout":
5202              queuedFocus = null;
5203              break;
5204            case "dragenter":
5205            case "dragleave":
5206              queuedDrag = null;
5207              break;
5208            case "mouseover":
5209            case "mouseout":
5210              queuedMouse = null;
5211              break;
5212            case "pointerover":
5213            case "pointerout": {
5214              var pointerId = nativeEvent.pointerId;
5215              queuedPointers.delete(pointerId);
5216              break;
5217            }
5218            case "gotpointercapture":
5219            case "lostpointercapture": {
5220              var _pointerId = nativeEvent.pointerId;
5221              queuedPointerCaptures.delete(_pointerId);
5222              break;
5223            }
5224          }
5225        }
5226        function accumulateOrCreateContinuousQueuedReplayableEvent(existingQueuedEvent, blockedOn, domEventName, eventSystemFlags, targetContainer, nativeEvent) {
5227          if (existingQueuedEvent === null || existingQueuedEvent.nativeEvent !== nativeEvent) {
5228            var queuedEvent = createQueuedReplayableEvent(blockedOn, domEventName, eventSystemFlags, targetContainer, nativeEvent);
5229            if (blockedOn !== null) {
5230              var _fiber2 = getInstanceFromNode(blockedOn);
5231              if (_fiber2 !== null) {
5232                attemptContinuousHydration(_fiber2);
5233              }
5234            }
5235            return queuedEvent;
5236          }
5237          existingQueuedEvent.eventSystemFlags |= eventSystemFlags;
5238          var targetContainers = existingQueuedEvent.targetContainers;
5239          if (targetContainer !== null && targetContainers.indexOf(targetContainer) === -1) {
5240            targetContainers.push(targetContainer);
5241          }
5242          return existingQueuedEvent;
5243        }
5244        function queueIfContinuousEvent(blockedOn, domEventName, eventSystemFlags, targetContainer, nativeEvent) {
5245          switch (domEventName) {
5246            case "focusin": {
5247              var focusEvent = nativeEvent;
5248              queuedFocus = accumulateOrCreateContinuousQueuedReplayableEvent(queuedFocus, blockedOn, domEventName, eventSystemFlags, targetContainer, focusEvent);
5249              return true;
5250            }
5251            case "dragenter": {
5252              var dragEvent = nativeEvent;
5253              queuedDrag = accumulateOrCreateContinuousQueuedReplayableEvent(queuedDrag, blockedOn, domEventName, eventSystemFlags, targetContainer, dragEvent);
5254              return true;
5255            }
5256            case "mouseover": {
5257              var mouseEvent = nativeEvent;
5258              queuedMouse = accumulateOrCreateContinuousQueuedReplayableEvent(queuedMouse, blockedOn, domEventName, eventSystemFlags, targetContainer, mouseEvent);
5259              return true;
5260            }
5261            case "pointerover": {
5262              var pointerEvent = nativeEvent;
5263              var pointerId = pointerEvent.pointerId;
5264              queuedPointers.set(pointerId, accumulateOrCreateContinuousQueuedReplayableEvent(queuedPointers.get(pointerId) || null, blockedOn, domEventName, eventSystemFlags, targetContainer, pointerEvent));
5265              return true;
5266            }
5267            case "gotpointercapture": {
5268              var _pointerEvent = nativeEvent;
5269              var _pointerId2 = _pointerEvent.pointerId;
5270              queuedPointerCaptures.set(_pointerId2, accumulateOrCreateContinuousQueuedReplayableEvent(queuedPointerCaptures.get(_pointerId2) || null, blockedOn, domEventName, eventSystemFlags, targetContainer, _pointerEvent));
5271              return true;
5272            }
5273          }
5274          return false;
5275        }
5276        function attemptExplicitHydrationTarget(queuedTarget) {
5277          var targetInst = getClosestInstanceFromNode(queuedTarget.target);
5278          if (targetInst !== null) {
5279            var nearestMounted = getNearestMountedFiber(targetInst);
5280            if (nearestMounted !== null) {
5281              var tag = nearestMounted.tag;
5282              if (tag === SuspenseComponent) {
5283                var instance = getSuspenseInstanceFromFiber(nearestMounted);
5284                if (instance !== null) {
5285                  queuedTarget.blockedOn = instance;
5286                  attemptHydrationAtPriority(queuedTarget.priority, function() {
5287                    attemptHydrationAtCurrentPriority(nearestMounted);
5288                  });
5289                  return;
5290                }
5291              } else if (tag === HostRoot) {
5292                var root2 = nearestMounted.stateNode;
5293                if (isRootDehydrated(root2)) {
5294                  queuedTarget.blockedOn = getContainerFromFiber(nearestMounted);
5295                  return;
5296                }
5297              }
5298            }
5299          }
5300          queuedTarget.blockedOn = null;
5301        }
5302        function queueExplicitHydrationTarget(target) {
5303          var updatePriority = getCurrentUpdatePriority$1();
5304          var queuedTarget = {
5305            blockedOn: null,
5306            target,
5307            priority: updatePriority
5308          };
5309          var i = 0;
5310          for (; i < queuedExplicitHydrationTargets.length; i++) {
5311            if (!isHigherEventPriority(updatePriority, queuedExplicitHydrationTargets[i].priority)) {
5312              break;
5313            }
5314          }
5315          queuedExplicitHydrationTargets.splice(i, 0, queuedTarget);
5316          if (i === 0) {
5317            attemptExplicitHydrationTarget(queuedTarget);
5318          }
5319        }
5320        function attemptReplayContinuousQueuedEvent(queuedEvent) {
5321          if (queuedEvent.blockedOn !== null) {
5322            return false;
5323          }
5324          var targetContainers = queuedEvent.targetContainers;
5325          while (targetContainers.length > 0) {
5326            var targetContainer = targetContainers[0];
5327            var nextBlockedOn = findInstanceBlockingEvent(queuedEvent.domEventName, queuedEvent.eventSystemFlags, targetContainer, queuedEvent.nativeEvent);
5328            if (nextBlockedOn === null) {
5329              {
5330                var nativeEvent = queuedEvent.nativeEvent;
5331                var nativeEventClone = new nativeEvent.constructor(nativeEvent.type, nativeEvent);
5332                setReplayingEvent(nativeEventClone);
5333                nativeEvent.target.dispatchEvent(nativeEventClone);
5334                resetReplayingEvent();
5335              }
5336            } else {
5337              var _fiber3 = getInstanceFromNode(nextBlockedOn);
5338              if (_fiber3 !== null) {
5339                attemptContinuousHydration(_fiber3);
5340              }
5341              queuedEvent.blockedOn = nextBlockedOn;
5342              return false;
5343            }
5344            targetContainers.shift();
5345          }
5346          return true;
5347        }
5348        function attemptReplayContinuousQueuedEventInMap(queuedEvent, key, map) {
5349          if (attemptReplayContinuousQueuedEvent(queuedEvent)) {
5350            map.delete(key);
5351          }
5352        }
5353        function replayUnblockedEvents() {
5354          hasScheduledReplayAttempt = false;
5355          if (queuedFocus !== null && attemptReplayContinuousQueuedEvent(queuedFocus)) {
5356            queuedFocus = null;
5357          }
5358          if (queuedDrag !== null && attemptReplayContinuousQueuedEvent(queuedDrag)) {
5359            queuedDrag = null;
5360          }
5361          if (queuedMouse !== null && attemptReplayContinuousQueuedEvent(queuedMouse)) {
5362            queuedMouse = null;
5363          }
5364          queuedPointers.forEach(attemptReplayContinuousQueuedEventInMap);
5365          queuedPointerCaptures.forEach(attemptReplayContinuousQueuedEventInMap);
5366        }
5367        function scheduleCallbackIfUnblocked(queuedEvent, unblocked) {
5368          if (queuedEvent.blockedOn === unblocked) {
5369            queuedEvent.blockedOn = null;
5370            if (!hasScheduledReplayAttempt) {
5371              hasScheduledReplayAttempt = true;
5372              Scheduler.unstable_scheduleCallback(Scheduler.unstable_NormalPriority, replayUnblockedEvents);
5373            }
5374          }
5375        }
5376        function retryIfBlockedOn(unblocked) {
5377          if (queuedDiscreteEvents.length > 0) {
5378            scheduleCallbackIfUnblocked(queuedDiscreteEvents[0], unblocked);
5379            for (var i = 1; i < queuedDiscreteEvents.length; i++) {
5380              var queuedEvent = queuedDiscreteEvents[i];
5381              if (queuedEvent.blockedOn === unblocked) {
5382                queuedEvent.blockedOn = null;
5383              }
5384            }
5385          }
5386          if (queuedFocus !== null) {
5387            scheduleCallbackIfUnblocked(queuedFocus, unblocked);
5388          }
5389          if (queuedDrag !== null) {
5390            scheduleCallbackIfUnblocked(queuedDrag, unblocked);
5391          }
5392          if (queuedMouse !== null) {
5393            scheduleCallbackIfUnblocked(queuedMouse, unblocked);
5394          }
5395          var unblock = function(queuedEvent2) {
5396            return scheduleCallbackIfUnblocked(queuedEvent2, unblocked);
5397          };
5398          queuedPointers.forEach(unblock);
5399          queuedPointerCaptures.forEach(unblock);
5400          for (var _i = 0; _i < queuedExplicitHydrationTargets.length; _i++) {
5401            var queuedTarget = queuedExplicitHydrationTargets[_i];
5402            if (queuedTarget.blockedOn === unblocked) {
5403              queuedTarget.blockedOn = null;
5404            }
5405          }
5406          while (queuedExplicitHydrationTargets.length > 0) {
5407            var nextExplicitTarget = queuedExplicitHydrationTargets[0];
5408            if (nextExplicitTarget.blockedOn !== null) {
5409              break;
5410            } else {
5411              attemptExplicitHydrationTarget(nextExplicitTarget);
5412              if (nextExplicitTarget.blockedOn === null) {
5413                queuedExplicitHydrationTargets.shift();
5414              }
5415            }
5416          }
5417        }
5418        var ReactCurrentBatchConfig = ReactSharedInternals.ReactCurrentBatchConfig;
5419        var _enabled = true;
5420        function setEnabled(enabled) {
5421          _enabled = !!enabled;
5422        }
5423        function isEnabled() {
5424          return _enabled;
5425        }
5426        function createEventListenerWrapperWithPriority(targetContainer, domEventName, eventSystemFlags) {
5427          var eventPriority = getEventPriority(domEventName);
5428          var listenerWrapper;
5429          switch (eventPriority) {
5430            case DiscreteEventPriority:
5431              listenerWrapper = dispatchDiscreteEvent;
5432              break;
5433            case ContinuousEventPriority:
5434              listenerWrapper = dispatchContinuousEvent;
5435              break;
5436            case DefaultEventPriority:
5437            default:
5438              listenerWrapper = dispatchEvent;
5439              break;
5440          }
5441          return listenerWrapper.bind(null, domEventName, eventSystemFlags, targetContainer);
5442        }
5443        function dispatchDiscreteEvent(domEventName, eventSystemFlags, container, nativeEvent) {
5444          var previousPriority = getCurrentUpdatePriority();
5445          var prevTransition = ReactCurrentBatchConfig.transition;
5446          ReactCurrentBatchConfig.transition = null;
5447          try {
5448            setCurrentUpdatePriority(DiscreteEventPriority);
5449            dispatchEvent(domEventName, eventSystemFlags, container, nativeEvent);
5450          } finally {
5451            setCurrentUpdatePriority(previousPriority);
5452            ReactCurrentBatchConfig.transition = prevTransition;
5453          }
5454        }
5455        function dispatchContinuousEvent(domEventName, eventSystemFlags, container, nativeEvent) {
5456          var previousPriority = getCurrentUpdatePriority();
5457          var prevTransition = ReactCurrentBatchConfig.transition;
5458          ReactCurrentBatchConfig.transition = null;
5459          try {
5460            setCurrentUpdatePriority(ContinuousEventPriority);
5461            dispatchEvent(domEventName, eventSystemFlags, container, nativeEvent);
5462          } finally {
5463            setCurrentUpdatePriority(previousPriority);
5464            ReactCurrentBatchConfig.transition = prevTransition;
5465          }
5466        }
5467        function dispatchEvent(domEventName, eventSystemFlags, targetContainer, nativeEvent) {
5468          if (!_enabled) {
5469            return;
5470          }
5471          {
5472            dispatchEventWithEnableCapturePhaseSelectiveHydrationWithoutDiscreteEventReplay(domEventName, eventSystemFlags, targetContainer, nativeEvent);
5473          }
5474        }
5475        function dispatchEventWithEnableCapturePhaseSelectiveHydrationWithoutDiscreteEventReplay(domEventName, eventSystemFlags, targetContainer, nativeEvent) {
5476          var blockedOn = findInstanceBlockingEvent(domEventName, eventSystemFlags, targetContainer, nativeEvent);
5477          if (blockedOn === null) {
5478            dispatchEventForPluginEventSystem(domEventName, eventSystemFlags, nativeEvent, return_targetInst, targetContainer);
5479            clearIfContinuousEvent(domEventName, nativeEvent);
5480            return;
5481          }
5482          if (queueIfContinuousEvent(blockedOn, domEventName, eventSystemFlags, targetContainer, nativeEvent)) {
5483            nativeEvent.stopPropagation();
5484            return;
5485          }
5486          clearIfContinuousEvent(domEventName, nativeEvent);
5487          if (eventSystemFlags & IS_CAPTURE_PHASE && isDiscreteEventThatRequiresHydration(domEventName)) {
5488            while (blockedOn !== null) {
5489              var fiber = getInstanceFromNode(blockedOn);
5490              if (fiber !== null) {
5491                attemptSynchronousHydration(fiber);
5492              }
5493              var nextBlockedOn = findInstanceBlockingEvent(domEventName, eventSystemFlags, targetContainer, nativeEvent);
5494              if (nextBlockedOn === null) {
5495                dispatchEventForPluginEventSystem(domEventName, eventSystemFlags, nativeEvent, return_targetInst, targetContainer);
5496              }
5497              if (nextBlockedOn === blockedOn) {
5498                break;
5499              }
5500              blockedOn = nextBlockedOn;
5501            }
5502            if (blockedOn !== null) {
5503              nativeEvent.stopPropagation();
5504            }
5505            return;
5506          }
5507          dispatchEventForPluginEventSystem(domEventName, eventSystemFlags, nativeEvent, null, targetContainer);
5508        }
5509        var return_targetInst = null;
5510        function findInstanceBlockingEvent(domEventName, eventSystemFlags, targetContainer, nativeEvent) {
5511          return_targetInst = null;
5512          var nativeEventTarget = getEventTarget(nativeEvent);
5513          var targetInst = getClosestInstanceFromNode(nativeEventTarget);
5514          if (targetInst !== null) {
5515            var nearestMounted = getNearestMountedFiber(targetInst);
5516            if (nearestMounted === null) {
5517              targetInst = null;
5518            } else {
5519              var tag = nearestMounted.tag;
5520              if (tag === SuspenseComponent) {
5521                var instance = getSuspenseInstanceFromFiber(nearestMounted);
5522                if (instance !== null) {
5523                  return instance;
5524                }
5525                targetInst = null;
5526              } else if (tag === HostRoot) {
5527                var root2 = nearestMounted.stateNode;
5528                if (isRootDehydrated(root2)) {
5529                  return getContainerFromFiber(nearestMounted);
5530                }
5531                targetInst = null;
5532              } else if (nearestMounted !== targetInst) {
5533                targetInst = null;
5534              }
5535            }
5536          }
5537          return_targetInst = targetInst;
5538          return null;
5539        }
5540        function getEventPriority(domEventName) {
5541          switch (domEventName) {
5542            case "cancel":
5543            case "click":
5544            case "close":
5545            case "contextmenu":
5546            case "copy":
5547            case "cut":
5548            case "auxclick":
5549            case "dblclick":
5550            case "dragend":
5551            case "dragstart":
5552            case "drop":
5553            case "focusin":
5554            case "focusout":
5555            case "input":
5556            case "invalid":
5557            case "keydown":
5558            case "keypress":
5559            case "keyup":
5560            case "mousedown":
5561            case "mouseup":
5562            case "paste":
5563            case "pause":
5564            case "play":
5565            case "pointercancel":
5566            case "pointerdown":
5567            case "pointerup":
5568            case "ratechange":
5569            case "reset":
5570            case "resize":
5571            case "seeked":
5572            case "submit":
5573            case "touchcancel":
5574            case "touchend":
5575            case "touchstart":
5576            case "volumechange":
5577            case "change":
5578            case "selectionchange":
5579            case "textInput":
5580            case "compositionstart":
5581            case "compositionend":
5582            case "compositionupdate":
5583            case "beforeblur":
5584            case "afterblur":
5585            case "beforeinput":
5586            case "blur":
5587            case "fullscreenchange":
5588            case "focus":
5589            case "hashchange":
5590            case "popstate":
5591            case "select":
5592            case "selectstart":
5593              return DiscreteEventPriority;
5594            case "drag":
5595            case "dragenter":
5596            case "dragexit":
5597            case "dragleave":
5598            case "dragover":
5599            case "mousemove":
5600            case "mouseout":
5601            case "mouseover":
5602            case "pointermove":
5603            case "pointerout":
5604            case "pointerover":
5605            case "scroll":
5606            case "toggle":
5607            case "touchmove":
5608            case "wheel":
5609            case "mouseenter":
5610            case "mouseleave":
5611            case "pointerenter":
5612            case "pointerleave":
5613              return ContinuousEventPriority;
5614            case "message": {
5615              var schedulerPriority = getCurrentPriorityLevel();
5616              switch (schedulerPriority) {
5617                case ImmediatePriority:
5618                  return DiscreteEventPriority;
5619                case UserBlockingPriority:
5620                  return ContinuousEventPriority;
5621                case NormalPriority:
5622                case LowPriority:
5623                  return DefaultEventPriority;
5624                case IdlePriority:
5625                  return IdleEventPriority;
5626                default:
5627                  return DefaultEventPriority;
5628              }
5629            }
5630            default:
5631              return DefaultEventPriority;
5632          }
5633        }
5634        function addEventBubbleListener(target, eventType, listener) {
5635          target.addEventListener(eventType, listener, false);
5636          return listener;
5637        }
5638        function addEventCaptureListener(target, eventType, listener) {
5639          target.addEventListener(eventType, listener, true);
5640          return listener;
5641        }
5642        function addEventCaptureListenerWithPassiveFlag(target, eventType, listener, passive) {
5643          target.addEventListener(eventType, listener, {
5644            capture: true,
5645            passive
5646          });
5647          return listener;
5648        }
5649        function addEventBubbleListenerWithPassiveFlag(target, eventType, listener, passive) {
5650          target.addEventListener(eventType, listener, {
5651            passive
5652          });
5653          return listener;
5654        }
5655        var root = null;
5656        var startText = null;
5657        var fallbackText = null;
5658        function initialize(nativeEventTarget) {
5659          root = nativeEventTarget;
5660          startText = getText();
5661          return true;
5662        }
5663        function reset() {
5664          root = null;
5665          startText = null;
5666          fallbackText = null;
5667        }
5668        function getData() {
5669          if (fallbackText) {
5670            return fallbackText;
5671          }
5672          var start;
5673          var startValue = startText;
5674          var startLength = startValue.length;
5675          var end;
5676          var endValue = getText();
5677          var endLength = endValue.length;
5678          for (start = 0; start < startLength; start++) {
5679            if (startValue[start] !== endValue[start]) {
5680              break;
5681            }
5682          }
5683          var minEnd = startLength - start;
5684          for (end = 1; end <= minEnd; end++) {
5685            if (startValue[startLength - end] !== endValue[endLength - end]) {
5686              break;
5687            }
5688          }
5689          var sliceTail = end > 1 ? 1 - end : void 0;
5690          fallbackText = endValue.slice(start, sliceTail);
5691          return fallbackText;
5692        }
5693        function getText() {
5694          if ("value" in root) {
5695            return root.value;
5696          }
5697          return root.textContent;
5698        }
5699        function getEventCharCode(nativeEvent) {
5700          var charCode;
5701          var keyCode = nativeEvent.keyCode;
5702          if ("charCode" in nativeEvent) {
5703            charCode = nativeEvent.charCode;
5704            if (charCode === 0 && keyCode === 13) {
5705              charCode = 13;
5706            }
5707          } else {
5708            charCode = keyCode;
5709          }
5710          if (charCode === 10) {
5711            charCode = 13;
5712          }
5713          if (charCode >= 32 || charCode === 13) {
5714            return charCode;
5715          }
5716          return 0;
5717        }
5718        function functionThatReturnsTrue() {
5719          return true;
5720        }
5721        function functionThatReturnsFalse() {
5722          return false;
5723        }
5724        function createSyntheticEvent(Interface) {
5725          function SyntheticBaseEvent(reactName, reactEventType, targetInst, nativeEvent, nativeEventTarget) {
5726            this._reactName = reactName;
5727            this._targetInst = targetInst;
5728            this.type = reactEventType;
5729            this.nativeEvent = nativeEvent;
5730            this.target = nativeEventTarget;
5731            this.currentTarget = null;
5732            for (var _propName in Interface) {
5733              if (!Interface.hasOwnProperty(_propName)) {
5734                continue;
5735              }
5736              var normalize = Interface[_propName];
5737              if (normalize) {
5738                this[_propName] = normalize(nativeEvent);
5739              } else {
5740                this[_propName] = nativeEvent[_propName];
5741              }
5742            }
5743            var defaultPrevented = nativeEvent.defaultPrevented != null ? nativeEvent.defaultPrevented : nativeEvent.returnValue === false;
5744            if (defaultPrevented) {
5745              this.isDefaultPrevented = functionThatReturnsTrue;
5746            } else {
5747              this.isDefaultPrevented = functionThatReturnsFalse;
5748            }
5749            this.isPropagationStopped = functionThatReturnsFalse;
5750            return this;
5751          }
5752          assign(SyntheticBaseEvent.prototype, {
5753            preventDefault: function() {
5754              this.defaultPrevented = true;
5755              var event = this.nativeEvent;
5756              if (!event) {
5757                return;
5758              }
5759              if (event.preventDefault) {
5760                event.preventDefault();
5761              } else if (typeof event.returnValue !== "unknown") {
5762                event.returnValue = false;
5763              }
5764              this.isDefaultPrevented = functionThatReturnsTrue;
5765            },
5766            stopPropagation: function() {
5767              var event = this.nativeEvent;
5768              if (!event) {
5769                return;
5770              }
5771              if (event.stopPropagation) {
5772                event.stopPropagation();
5773              } else if (typeof event.cancelBubble !== "unknown") {
5774                event.cancelBubble = true;
5775              }
5776              this.isPropagationStopped = functionThatReturnsTrue;
5777            },
5778            /**
5779             * We release all dispatched `SyntheticEvent`s after each event loop, adding
5780             * them back into the pool. This allows a way to hold onto a reference that
5781             * won't be added back into the pool.
5782             */
5783            persist: function() {
5784            },
5785            /**
5786             * Checks if this event should be released back into the pool.
5787             *
5788             * @return {boolean} True if this should not be released, false otherwise.
5789             */
5790            isPersistent: functionThatReturnsTrue
5791          });
5792          return SyntheticBaseEvent;
5793        }
5794        var EventInterface = {
5795          eventPhase: 0,
5796          bubbles: 0,
5797          cancelable: 0,
5798          timeStamp: function(event) {
5799            return event.timeStamp || Date.now();
5800          },
5801          defaultPrevented: 0,
5802          isTrusted: 0
5803        };
5804        var SyntheticEvent = createSyntheticEvent(EventInterface);
5805        var UIEventInterface = assign({}, EventInterface, {
5806          view: 0,
5807          detail: 0
5808        });
5809        var SyntheticUIEvent = createSyntheticEvent(UIEventInterface);
5810        var lastMovementX;
5811        var lastMovementY;
5812        var lastMouseEvent;
5813        function updateMouseMovementPolyfillState(event) {
5814          if (event !== lastMouseEvent) {
5815            if (lastMouseEvent && event.type === "mousemove") {
5816              lastMovementX = event.screenX - lastMouseEvent.screenX;
5817              lastMovementY = event.screenY - lastMouseEvent.screenY;
5818            } else {
5819              lastMovementX = 0;
5820              lastMovementY = 0;
5821            }
5822            lastMouseEvent = event;
5823          }
5824        }
5825        var MouseEventInterface = assign({}, UIEventInterface, {
5826          screenX: 0,
5827          screenY: 0,
5828          clientX: 0,
5829          clientY: 0,
5830          pageX: 0,
5831          pageY: 0,
5832          ctrlKey: 0,
5833          shiftKey: 0,
5834          altKey: 0,
5835          metaKey: 0,
5836          getModifierState: getEventModifierState,
5837          button: 0,
5838          buttons: 0,
5839          relatedTarget: function(event) {
5840            if (event.relatedTarget === void 0) return event.fromElement === event.srcElement ? event.toElement : event.fromElement;
5841            return event.relatedTarget;
5842          },
5843          movementX: function(event) {
5844            if ("movementX" in event) {
5845              return event.movementX;
5846            }
5847            updateMouseMovementPolyfillState(event);
5848            return lastMovementX;
5849          },
5850          movementY: function(event) {
5851            if ("movementY" in event) {
5852              return event.movementY;
5853            }
5854            return lastMovementY;
5855          }
5856        });
5857        var SyntheticMouseEvent = createSyntheticEvent(MouseEventInterface);
5858        var DragEventInterface = assign({}, MouseEventInterface, {
5859          dataTransfer: 0
5860        });
5861        var SyntheticDragEvent = createSyntheticEvent(DragEventInterface);
5862        var FocusEventInterface = assign({}, UIEventInterface, {
5863          relatedTarget: 0
5864        });
5865        var SyntheticFocusEvent = createSyntheticEvent(FocusEventInterface);
5866        var AnimationEventInterface = assign({}, EventInterface, {
5867          animationName: 0,
5868          elapsedTime: 0,
5869          pseudoElement: 0
5870        });
5871        var SyntheticAnimationEvent = createSyntheticEvent(AnimationEventInterface);
5872        var ClipboardEventInterface = assign({}, EventInterface, {
5873          clipboardData: function(event) {
5874            return "clipboardData" in event ? event.clipboardData : window.clipboardData;
5875          }
5876        });
5877        var SyntheticClipboardEvent = createSyntheticEvent(ClipboardEventInterface);
5878        var CompositionEventInterface = assign({}, EventInterface, {
5879          data: 0
5880        });
5881        var SyntheticCompositionEvent = createSyntheticEvent(CompositionEventInterface);
5882        var SyntheticInputEvent = SyntheticCompositionEvent;
5883        var normalizeKey = {
5884          Esc: "Escape",
5885          Spacebar: " ",
5886          Left: "ArrowLeft",
5887          Up: "ArrowUp",
5888          Right: "ArrowRight",
5889          Down: "ArrowDown",
5890          Del: "Delete",
5891          Win: "OS",
5892          Menu: "ContextMenu",
5893          Apps: "ContextMenu",
5894          Scroll: "ScrollLock",
5895          MozPrintableKey: "Unidentified"
5896        };
5897        var translateToKey = {
5898          "8": "Backspace",
5899          "9": "Tab",
5900          "12": "Clear",
5901          "13": "Enter",
5902          "16": "Shift",
5903          "17": "Control",
5904          "18": "Alt",
5905          "19": "Pause",
5906          "20": "CapsLock",
5907          "27": "Escape",
5908          "32": " ",
5909          "33": "PageUp",
5910          "34": "PageDown",
5911          "35": "End",
5912          "36": "Home",
5913          "37": "ArrowLeft",
5914          "38": "ArrowUp",
5915          "39": "ArrowRight",
5916          "40": "ArrowDown",
5917          "45": "Insert",
5918          "46": "Delete",
5919          "112": "F1",
5920          "113": "F2",
5921          "114": "F3",
5922          "115": "F4",
5923          "116": "F5",
5924          "117": "F6",
5925          "118": "F7",
5926          "119": "F8",
5927          "120": "F9",
5928          "121": "F10",
5929          "122": "F11",
5930          "123": "F12",
5931          "144": "NumLock",
5932          "145": "ScrollLock",
5933          "224": "Meta"
5934        };
5935        function getEventKey(nativeEvent) {
5936          if (nativeEvent.key) {
5937            var key = normalizeKey[nativeEvent.key] || nativeEvent.key;
5938            if (key !== "Unidentified") {
5939              return key;
5940            }
5941          }
5942          if (nativeEvent.type === "keypress") {
5943            var charCode = getEventCharCode(nativeEvent);
5944            return charCode === 13 ? "Enter" : String.fromCharCode(charCode);
5945          }
5946          if (nativeEvent.type === "keydown" || nativeEvent.type === "keyup") {
5947            return translateToKey[nativeEvent.keyCode] || "Unidentified";
5948          }
5949          return "";
5950        }
5951        var modifierKeyToProp = {
5952          Alt: "altKey",
5953          Control: "ctrlKey",
5954          Meta: "metaKey",
5955          Shift: "shiftKey"
5956        };
5957        function modifierStateGetter(keyArg) {
5958          var syntheticEvent = this;
5959          var nativeEvent = syntheticEvent.nativeEvent;
5960          if (nativeEvent.getModifierState) {
5961            return nativeEvent.getModifierState(keyArg);
5962          }
5963          var keyProp = modifierKeyToProp[keyArg];
5964          return keyProp ? !!nativeEvent[keyProp] : false;
5965        }
5966        function getEventModifierState(nativeEvent) {
5967          return modifierStateGetter;
5968        }
5969        var KeyboardEventInterface = assign({}, UIEventInterface, {
5970          key: getEventKey,
5971          code: 0,
5972          location: 0,
5973          ctrlKey: 0,
5974          shiftKey: 0,
5975          altKey: 0,
5976          metaKey: 0,
5977          repeat: 0,
5978          locale: 0,
5979          getModifierState: getEventModifierState,
5980          // Legacy Interface
5981          charCode: function(event) {
5982            if (event.type === "keypress") {
5983              return getEventCharCode(event);
5984            }
5985            return 0;
5986          },
5987          keyCode: function(event) {
5988            if (event.type === "keydown" || event.type === "keyup") {
5989              return event.keyCode;
5990            }
5991            return 0;
5992          },
5993          which: function(event) {
5994            if (event.type === "keypress") {
5995              return getEventCharCode(event);
5996            }
5997            if (event.type === "keydown" || event.type === "keyup") {
5998              return event.keyCode;
5999            }
6000            return 0;
6001          }
6002        });
6003        var SyntheticKeyboardEvent = createSyntheticEvent(KeyboardEventInterface);
6004        var PointerEventInterface = assign({}, MouseEventInterface, {
6005          pointerId: 0,
6006          width: 0,
6007          height: 0,
6008          pressure: 0,
6009          tangentialPressure: 0,
6010          tiltX: 0,
6011          tiltY: 0,
6012          twist: 0,
6013          pointerType: 0,
6014          isPrimary: 0
6015        });
6016        var SyntheticPointerEvent = createSyntheticEvent(PointerEventInterface);
6017        var TouchEventInterface = assign({}, UIEventInterface, {
6018          touches: 0,
6019          targetTouches: 0,
6020          changedTouches: 0,
6021          altKey: 0,
6022          metaKey: 0,
6023          ctrlKey: 0,
6024          shiftKey: 0,
6025          getModifierState: getEventModifierState
6026        });
6027        var SyntheticTouchEvent = createSyntheticEvent(TouchEventInterface);
6028        var TransitionEventInterface = assign({}, EventInterface, {
6029          propertyName: 0,
6030          elapsedTime: 0,
6031          pseudoElement: 0
6032        });
6033        var SyntheticTransitionEvent = createSyntheticEvent(TransitionEventInterface);
6034        var WheelEventInterface = assign({}, MouseEventInterface, {
6035          deltaX: function(event) {
6036            return "deltaX" in event ? event.deltaX : (
6037              // Fallback to `wheelDeltaX` for Webkit and normalize (right is positive).
6038              "wheelDeltaX" in event ? -event.wheelDeltaX : 0
6039            );
6040          },
6041          deltaY: function(event) {
6042            return "deltaY" in event ? event.deltaY : (
6043              // Fallback to `wheelDeltaY` for Webkit and normalize (down is positive).
6044              "wheelDeltaY" in event ? -event.wheelDeltaY : (
6045                // Fallback to `wheelDelta` for IE<9 and normalize (down is positive).
6046                "wheelDelta" in event ? -event.wheelDelta : 0
6047              )
6048            );
6049          },
6050          deltaZ: 0,
6051          // Browsers without "deltaMode" is reporting in raw wheel delta where one
6052          // notch on the scroll is always +/- 120, roughly equivalent to pixels.
6053          // A good approximation of DOM_DELTA_LINE (1) is 5% of viewport size or
6054          // ~40 pixels, for DOM_DELTA_SCREEN (2) it is 87.5% of viewport size.
6055          deltaMode: 0
6056        });
6057        var SyntheticWheelEvent = createSyntheticEvent(WheelEventInterface);
6058        var END_KEYCODES = [9, 13, 27, 32];
6059        var START_KEYCODE = 229;
6060        var canUseCompositionEvent = canUseDOM && "CompositionEvent" in window;
6061        var documentMode = null;
6062        if (canUseDOM && "documentMode" in document) {
6063          documentMode = document.documentMode;
6064        }
6065        var canUseTextInputEvent = canUseDOM && "TextEvent" in window && !documentMode;
6066        var useFallbackCompositionData = canUseDOM && (!canUseCompositionEvent || documentMode && documentMode > 8 && documentMode <= 11);
6067        var SPACEBAR_CODE = 32;
6068        var SPACEBAR_CHAR = String.fromCharCode(SPACEBAR_CODE);
6069        function registerEvents() {
6070          registerTwoPhaseEvent("onBeforeInput", ["compositionend", "keypress", "textInput", "paste"]);
6071          registerTwoPhaseEvent("onCompositionEnd", ["compositionend", "focusout", "keydown", "keypress", "keyup", "mousedown"]);
6072          registerTwoPhaseEvent("onCompositionStart", ["compositionstart", "focusout", "keydown", "keypress", "keyup", "mousedown"]);
6073          registerTwoPhaseEvent("onCompositionUpdate", ["compositionupdate", "focusout", "keydown", "keypress", "keyup", "mousedown"]);
6074        }
6075        var hasSpaceKeypress = false;
6076        function isKeypressCommand(nativeEvent) {
6077          return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) && // ctrlKey && altKey is equivalent to AltGr, and is not a command.
6078          !(nativeEvent.ctrlKey && nativeEvent.altKey);
6079        }
6080        function getCompositionEventType(domEventName) {
6081          switch (domEventName) {
6082            case "compositionstart":
6083              return "onCompositionStart";
6084            case "compositionend":
6085              return "onCompositionEnd";
6086            case "compositionupdate":
6087              return "onCompositionUpdate";
6088          }
6089        }
6090        function isFallbackCompositionStart(domEventName, nativeEvent) {
6091          return domEventName === "keydown" && nativeEvent.keyCode === START_KEYCODE;
6092        }
6093        function isFallbackCompositionEnd(domEventName, nativeEvent) {
6094          switch (domEventName) {
6095            case "keyup":
6096              return END_KEYCODES.indexOf(nativeEvent.keyCode) !== -1;
6097            case "keydown":
6098              return nativeEvent.keyCode !== START_KEYCODE;
6099            case "keypress":
6100            case "mousedown":
6101            case "focusout":
6102              return true;
6103            default:
6104              return false;
6105          }
6106        }
6107        function getDataFromCustomEvent(nativeEvent) {
6108          var detail = nativeEvent.detail;
6109          if (typeof detail === "object" && "data" in detail) {
6110            return detail.data;
6111          }
6112          return null;
6113        }
6114        function isUsingKoreanIME(nativeEvent) {
6115          return nativeEvent.locale === "ko";
6116        }
6117        var isComposing = false;
6118        function extractCompositionEvent(dispatchQueue, domEventName, targetInst, nativeEvent, nativeEventTarget) {
6119          var eventType;
6120          var fallbackData;
6121          if (canUseCompositionEvent) {
6122            eventType = getCompositionEventType(domEventName);
6123          } else if (!isComposing) {
6124            if (isFallbackCompositionStart(domEventName, nativeEvent)) {
6125              eventType = "onCompositionStart";
6126            }
6127          } else if (isFallbackCompositionEnd(domEventName, nativeEvent)) {
6128            eventType = "onCompositionEnd";
6129          }
6130          if (!eventType) {
6131            return null;
6132          }
6133          if (useFallbackCompositionData && !isUsingKoreanIME(nativeEvent)) {
6134            if (!isComposing && eventType === "onCompositionStart") {
6135              isComposing = initialize(nativeEventTarget);
6136            } else if (eventType === "onCompositionEnd") {
6137              if (isComposing) {
6138                fallbackData = getData();
6139              }
6140            }
6141          }
6142          var listeners = accumulateTwoPhaseListeners(targetInst, eventType);
6143          if (listeners.length > 0) {
6144            var event = new SyntheticCompositionEvent(eventType, domEventName, null, nativeEvent, nativeEventTarget);
6145            dispatchQueue.push({
6146              event,
6147              listeners
6148            });
6149            if (fallbackData) {
6150              event.data = fallbackData;
6151            } else {
6152              var customData = getDataFromCustomEvent(nativeEvent);
6153              if (customData !== null) {
6154                event.data = customData;
6155              }
6156            }
6157          }
6158        }
6159        function getNativeBeforeInputChars(domEventName, nativeEvent) {
6160          switch (domEventName) {
6161            case "compositionend":
6162              return getDataFromCustomEvent(nativeEvent);
6163            case "keypress":
6164              var which = nativeEvent.which;
6165              if (which !== SPACEBAR_CODE) {
6166                return null;
6167              }
6168              hasSpaceKeypress = true;
6169              return SPACEBAR_CHAR;
6170            case "textInput":
6171              var chars = nativeEvent.data;
6172              if (chars === SPACEBAR_CHAR && hasSpaceKeypress) {
6173                return null;
6174              }
6175              return chars;
6176            default:
6177              return null;
6178          }
6179        }
6180        function getFallbackBeforeInputChars(domEventName, nativeEvent) {
6181          if (isComposing) {
6182            if (domEventName === "compositionend" || !canUseCompositionEvent && isFallbackCompositionEnd(domEventName, nativeEvent)) {
6183              var chars = getData();
6184              reset();
6185              isComposing = false;
6186              return chars;
6187            }
6188            return null;
6189          }
6190          switch (domEventName) {
6191            case "paste":
6192              return null;
6193            case "keypress":
6194              if (!isKeypressCommand(nativeEvent)) {
6195                if (nativeEvent.char && nativeEvent.char.length > 1) {
6196                  return nativeEvent.char;
6197                } else if (nativeEvent.which) {
6198                  return String.fromCharCode(nativeEvent.which);
6199                }
6200              }
6201              return null;
6202            case "compositionend":
6203              return useFallbackCompositionData && !isUsingKoreanIME(nativeEvent) ? null : nativeEvent.data;
6204            default:
6205              return null;
6206          }
6207        }
6208        function extractBeforeInputEvent(dispatchQueue, domEventName, targetInst, nativeEvent, nativeEventTarget) {
6209          var chars;
6210          if (canUseTextInputEvent) {
6211            chars = getNativeBeforeInputChars(domEventName, nativeEvent);
6212          } else {
6213            chars = getFallbackBeforeInputChars(domEventName, nativeEvent);
6214          }
6215          if (!chars) {
6216            return null;
6217          }
6218          var listeners = accumulateTwoPhaseListeners(targetInst, "onBeforeInput");
6219          if (listeners.length > 0) {
6220            var event = new SyntheticInputEvent("onBeforeInput", "beforeinput", null, nativeEvent, nativeEventTarget);
6221            dispatchQueue.push({
6222              event,
6223              listeners
6224            });
6225            event.data = chars;
6226          }
6227        }
6228        function extractEvents(dispatchQueue, domEventName, targetInst, nativeEvent, nativeEventTarget, eventSystemFlags, targetContainer) {
6229          extractCompositionEvent(dispatchQueue, domEventName, targetInst, nativeEvent, nativeEventTarget);
6230          extractBeforeInputEvent(dispatchQueue, domEventName, targetInst, nativeEvent, nativeEventTarget);
6231        }
6232        var supportedInputTypes = {
6233          color: true,
6234          date: true,
6235          datetime: true,
6236          "datetime-local": true,
6237          email: true,
6238          month: true,
6239          number: true,
6240          password: true,
6241          range: true,
6242          search: true,
6243          tel: true,
6244          text: true,
6245          time: true,
6246          url: true,
6247          week: true
6248        };
6249        function isTextInputElement(elem) {
6250          var nodeName = elem && elem.nodeName && elem.nodeName.toLowerCase();
6251          if (nodeName === "input") {
6252            return !!supportedInputTypes[elem.type];
6253          }
6254          if (nodeName === "textarea") {
6255            return true;
6256          }
6257          return false;
6258        }
6259        function isEventSupported(eventNameSuffix) {
6260          if (!canUseDOM) {
6261            return false;
6262          }
6263          var eventName = "on" + eventNameSuffix;
6264          var isSupported = eventName in document;
6265          if (!isSupported) {
6266            var element = document.createElement("div");
6267            element.setAttribute(eventName, "return;");
6268            isSupported = typeof element[eventName] === "function";
6269          }
6270          return isSupported;
6271        }
6272        function registerEvents$1() {
6273          registerTwoPhaseEvent("onChange", ["change", "click", "focusin", "focusout", "input", "keydown", "keyup", "selectionchange"]);
6274        }
6275        function createAndAccumulateChangeEvent(dispatchQueue, inst, nativeEvent, target) {
6276          enqueueStateRestore(target);
6277          var listeners = accumulateTwoPhaseListeners(inst, "onChange");
6278          if (listeners.length > 0) {
6279            var event = new SyntheticEvent("onChange", "change", null, nativeEvent, target);
6280            dispatchQueue.push({
6281              event,
6282              listeners
6283            });
6284          }
6285        }
6286        var activeElement = null;
6287        var activeElementInst = null;
6288        function shouldUseChangeEvent(elem) {
6289          var nodeName = elem.nodeName && elem.nodeName.toLowerCase();
6290          return nodeName === "select" || nodeName === "input" && elem.type === "file";
6291        }
6292        function manualDispatchChangeEvent(nativeEvent) {
6293          var dispatchQueue = [];
6294          createAndAccumulateChangeEvent(dispatchQueue, activeElementInst, nativeEvent, getEventTarget(nativeEvent));
6295          batchedUpdates(runEventInBatch, dispatchQueue);
6296        }
6297        function runEventInBatch(dispatchQueue) {
6298          processDispatchQueue(dispatchQueue, 0);
6299        }
6300        function getInstIfValueChanged(targetInst) {
6301          var targetNode = getNodeFromInstance(targetInst);
6302          if (updateValueIfChanged(targetNode)) {
6303            return targetInst;
6304          }
6305        }
6306        function getTargetInstForChangeEvent(domEventName, targetInst) {
6307          if (domEventName === "change") {
6308            return targetInst;
6309          }
6310        }
6311        var isInputEventSupported = false;
6312        if (canUseDOM) {
6313          isInputEventSupported = isEventSupported("input") && (!document.documentMode || document.documentMode > 9);
6314        }
6315        function startWatchingForValueChange(target, targetInst) {
6316          activeElement = target;
6317          activeElementInst = targetInst;
6318          activeElement.attachEvent("onpropertychange", handlePropertyChange);
6319        }
6320        function stopWatchingForValueChange() {
6321          if (!activeElement) {
6322            return;
6323          }
6324          activeElement.detachEvent("onpropertychange", handlePropertyChange);
6325          activeElement = null;
6326          activeElementInst = null;
6327        }
6328        function handlePropertyChange(nativeEvent) {
6329          if (nativeEvent.propertyName !== "value") {
6330            return;
6331          }
6332          if (getInstIfValueChanged(activeElementInst)) {
6333            manualDispatchChangeEvent(nativeEvent);
6334          }
6335        }
6336        function handleEventsForInputEventPolyfill(domEventName, target, targetInst) {
6337          if (domEventName === "focusin") {
6338            stopWatchingForValueChange();
6339            startWatchingForValueChange(target, targetInst);
6340          } else if (domEventName === "focusout") {
6341            stopWatchingForValueChange();
6342          }
6343        }
6344        function getTargetInstForInputEventPolyfill(domEventName, targetInst) {
6345          if (domEventName === "selectionchange" || domEventName === "keyup" || domEventName === "keydown") {
6346            return getInstIfValueChanged(activeElementInst);
6347          }
6348        }
6349        function shouldUseClickEvent(elem) {
6350          var nodeName = elem.nodeName;
6351          return nodeName && nodeName.toLowerCase() === "input" && (elem.type === "checkbox" || elem.type === "radio");
6352        }
6353        function getTargetInstForClickEvent(domEventName, targetInst) {
6354          if (domEventName === "click") {
6355            return getInstIfValueChanged(targetInst);
6356          }
6357        }
6358        function getTargetInstForInputOrChangeEvent(domEventName, targetInst) {
6359          if (domEventName === "input" || domEventName === "change") {
6360            return getInstIfValueChanged(targetInst);
6361          }
6362        }
6363        function handleControlledInputBlur(node) {
6364          var state = node._wrapperState;
6365          if (!state || !state.controlled || node.type !== "number") {
6366            return;
6367          }
6368          {
6369            setDefaultValue(node, "number", node.value);
6370          }
6371        }
6372        function extractEvents$1(dispatchQueue, domEventName, targetInst, nativeEvent, nativeEventTarget, eventSystemFlags, targetContainer) {
6373          var targetNode = targetInst ? getNodeFromInstance(targetInst) : window;
6374          var getTargetInstFunc, handleEventFunc;
6375          if (shouldUseChangeEvent(targetNode)) {
6376            getTargetInstFunc = getTargetInstForChangeEvent;
6377          } else if (isTextInputElement(targetNode)) {
6378            if (isInputEventSupported) {
6379              getTargetInstFunc = getTargetInstForInputOrChangeEvent;
6380            } else {
6381              getTargetInstFunc = getTargetInstForInputEventPolyfill;
6382              handleEventFunc = handleEventsForInputEventPolyfill;
6383            }
6384          } else if (shouldUseClickEvent(targetNode)) {
6385            getTargetInstFunc = getTargetInstForClickEvent;
6386          }
6387          if (getTargetInstFunc) {
6388            var inst = getTargetInstFunc(domEventName, targetInst);
6389            if (inst) {
6390              createAndAccumulateChangeEvent(dispatchQueue, inst, nativeEvent, nativeEventTarget);
6391              return;
6392            }
6393          }
6394          if (handleEventFunc) {
6395            handleEventFunc(domEventName, targetNode, targetInst);
6396          }
6397          if (domEventName === "focusout") {
6398            handleControlledInputBlur(targetNode);
6399          }
6400        }
6401        function registerEvents$2() {
6402          registerDirectEvent("onMouseEnter", ["mouseout", "mouseover"]);
6403          registerDirectEvent("onMouseLeave", ["mouseout", "mouseover"]);
6404          registerDirectEvent("onPointerEnter", ["pointerout", "pointerover"]);
6405          registerDirectEvent("onPointerLeave", ["pointerout", "pointerover"]);
6406        }
6407        function extractEvents$2(dispatchQueue, domEventName, targetInst, nativeEvent, nativeEventTarget, eventSystemFlags, targetContainer) {
6408          var isOverEvent = domEventName === "mouseover" || domEventName === "pointerover";
6409          var isOutEvent = domEventName === "mouseout" || domEventName === "pointerout";
6410          if (isOverEvent && !isReplayingEvent(nativeEvent)) {
6411            var related = nativeEvent.relatedTarget || nativeEvent.fromElement;
6412            if (related) {
6413              if (getClosestInstanceFromNode(related) || isContainerMarkedAsRoot(related)) {
6414                return;
6415              }
6416            }
6417          }
6418          if (!isOutEvent && !isOverEvent) {
6419            return;
6420          }
6421          var win;
6422          if (nativeEventTarget.window === nativeEventTarget) {
6423            win = nativeEventTarget;
6424          } else {
6425            var doc = nativeEventTarget.ownerDocument;
6426            if (doc) {
6427              win = doc.defaultView || doc.parentWindow;
6428            } else {
6429              win = window;
6430            }
6431          }
6432          var from;
6433          var to;
6434          if (isOutEvent) {
6435            var _related = nativeEvent.relatedTarget || nativeEvent.toElement;
6436            from = targetInst;
6437            to = _related ? getClosestInstanceFromNode(_related) : null;
6438            if (to !== null) {
6439              var nearestMounted = getNearestMountedFiber(to);
6440              if (to !== nearestMounted || to.tag !== HostComponent && to.tag !== HostText) {
6441                to = null;
6442              }
6443            }
6444          } else {
6445            from = null;
6446            to = targetInst;
6447          }
6448          if (from === to) {
6449            return;
6450          }
6451          var SyntheticEventCtor = SyntheticMouseEvent;
6452          var leaveEventType = "onMouseLeave";
6453          var enterEventType = "onMouseEnter";
6454          var eventTypePrefix = "mouse";
6455          if (domEventName === "pointerout" || domEventName === "pointerover") {
6456            SyntheticEventCtor = SyntheticPointerEvent;
6457            leaveEventType = "onPointerLeave";
6458            enterEventType = "onPointerEnter";
6459            eventTypePrefix = "pointer";
6460          }
6461          var fromNode = from == null ? win : getNodeFromInstance(from);
6462          var toNode = to == null ? win : getNodeFromInstance(to);
6463          var leave = new SyntheticEventCtor(leaveEventType, eventTypePrefix + "leave", from, nativeEvent, nativeEventTarget);
6464          leave.target = fromNode;
6465          leave.relatedTarget = toNode;
6466          var enter = null;
6467          var nativeTargetInst = getClosestInstanceFromNode(nativeEventTarget);
6468          if (nativeTargetInst === targetInst) {
6469            var enterEvent = new SyntheticEventCtor(enterEventType, eventTypePrefix + "enter", to, nativeEvent, nativeEventTarget);
6470            enterEvent.target = toNode;
6471            enterEvent.relatedTarget = fromNode;
6472            enter = enterEvent;
6473          }
6474          accumulateEnterLeaveTwoPhaseListeners(dispatchQueue, leave, enter, from, to);
6475        }
6476        function is(x, y) {
6477          return x === y && (x !== 0 || 1 / x === 1 / y) || x !== x && y !== y;
6478        }
6479        var objectIs = typeof Object.is === "function" ? Object.is : is;
6480        function shallowEqual(objA, objB) {
6481          if (objectIs(objA, objB)) {
6482            return true;
6483          }
6484          if (typeof objA !== "object" || objA === null || typeof objB !== "object" || objB === null) {
6485            return false;
6486          }
6487          var keysA = Object.keys(objA);
6488          var keysB = Object.keys(objB);
6489          if (keysA.length !== keysB.length) {
6490            return false;
6491          }
6492          for (var i = 0; i < keysA.length; i++) {
6493            var currentKey = keysA[i];
6494            if (!hasOwnProperty.call(objB, currentKey) || !objectIs(objA[currentKey], objB[currentKey])) {
6495              return false;
6496            }
6497          }
6498          return true;
6499        }
6500        function getLeafNode(node) {
6501          while (node && node.firstChild) {
6502            node = node.firstChild;
6503          }
6504          return node;
6505        }
6506        function getSiblingNode(node) {
6507          while (node) {
6508            if (node.nextSibling) {
6509              return node.nextSibling;
6510            }
6511            node = node.parentNode;
6512          }
6513        }
6514        function getNodeForCharacterOffset(root2, offset) {
6515          var node = getLeafNode(root2);
6516          var nodeStart = 0;
6517          var nodeEnd = 0;
6518          while (node) {
6519            if (node.nodeType === TEXT_NODE) {
6520              nodeEnd = nodeStart + node.textContent.length;
6521              if (nodeStart <= offset && nodeEnd >= offset) {
6522                return {
6523                  node,
6524                  offset: offset - nodeStart
6525                };
6526              }
6527              nodeStart = nodeEnd;
6528            }
6529            node = getLeafNode(getSiblingNode(node));
6530          }
6531        }
6532        function getOffsets(outerNode) {
6533          var ownerDocument = outerNode.ownerDocument;
6534          var win = ownerDocument && ownerDocument.defaultView || window;
6535          var selection = win.getSelection && win.getSelection();
6536          if (!selection || selection.rangeCount === 0) {
6537            return null;
6538          }
6539          var anchorNode = selection.anchorNode, anchorOffset = selection.anchorOffset, focusNode = selection.focusNode, focusOffset = selection.focusOffset;
6540          try {
6541            anchorNode.nodeType;
6542            focusNode.nodeType;
6543          } catch (e) {
6544            return null;
6545          }
6546          return getModernOffsetsFromPoints(outerNode, anchorNode, anchorOffset, focusNode, focusOffset);
6547        }
6548        function getModernOffsetsFromPoints(outerNode, anchorNode, anchorOffset, focusNode, focusOffset) {
6549          var length = 0;
6550          var start = -1;
6551          var end = -1;
6552          var indexWithinAnchor = 0;
6553          var indexWithinFocus = 0;
6554          var node = outerNode;
6555          var parentNode = null;
6556          outer: while (true) {
6557            var next = null;
6558            while (true) {
6559              if (node === anchorNode && (anchorOffset === 0 || node.nodeType === TEXT_NODE)) {
6560                start = length + anchorOffset;
6561              }
6562              if (node === focusNode && (focusOffset === 0 || node.nodeType === TEXT_NODE)) {
6563                end = length + focusOffset;
6564              }
6565              if (node.nodeType === TEXT_NODE) {
6566                length += node.nodeValue.length;
6567              }
6568              if ((next = node.firstChild) === null) {
6569                break;
6570              }
6571              parentNode = node;
6572              node = next;
6573            }
6574            while (true) {
6575              if (node === outerNode) {
6576                break outer;
6577              }
6578              if (parentNode === anchorNode && ++indexWithinAnchor === anchorOffset) {
6579                start = length;
6580              }
6581              if (parentNode === focusNode && ++indexWithinFocus === focusOffset) {
6582                end = length;
6583              }
6584              if ((next = node.nextSibling) !== null) {
6585                break;
6586              }
6587              node = parentNode;
6588              parentNode = node.parentNode;
6589            }
6590            node = next;
6591          }
6592          if (start === -1 || end === -1) {
6593            return null;
6594          }
6595          return {
6596            start,
6597            end
6598          };
6599        }
6600        function setOffsets(node, offsets) {
6601          var doc = node.ownerDocument || document;
6602          var win = doc && doc.defaultView || window;
6603          if (!win.getSelection) {
6604            return;
6605          }
6606          var selection = win.getSelection();
6607          var length = node.textContent.length;
6608          var start = Math.min(offsets.start, length);
6609          var end = offsets.end === void 0 ? start : Math.min(offsets.end, length);
6610          if (!selection.extend && start > end) {
6611            var temp = end;
6612            end = start;
6613            start = temp;
6614          }
6615          var startMarker = getNodeForCharacterOffset(node, start);
6616          var endMarker = getNodeForCharacterOffset(node, end);
6617          if (startMarker && endMarker) {
6618            if (selection.rangeCount === 1 && selection.anchorNode === startMarker.node && selection.anchorOffset === startMarker.offset && selection.focusNode === endMarker.node && selection.focusOffset === endMarker.offset) {
6619              return;
6620            }
6621            var range = doc.createRange();
6622            range.setStart(startMarker.node, startMarker.offset);
6623            selection.removeAllRanges();
6624            if (start > end) {
6625              selection.addRange(range);
6626              selection.extend(endMarker.node, endMarker.offset);
6627            } else {
6628              range.setEnd(endMarker.node, endMarker.offset);
6629              selection.addRange(range);
6630            }
6631          }
6632        }
6633        function isTextNode(node) {
6634          return node && node.nodeType === TEXT_NODE;
6635        }
6636        function containsNode(outerNode, innerNode) {
6637          if (!outerNode || !innerNode) {
6638            return false;
6639          } else if (outerNode === innerNode) {
6640            return true;
6641          } else if (isTextNode(outerNode)) {
6642            return false;
6643          } else if (isTextNode(innerNode)) {
6644            return containsNode(outerNode, innerNode.parentNode);
6645          } else if ("contains" in outerNode) {
6646            return outerNode.contains(innerNode);
6647          } else if (outerNode.compareDocumentPosition) {
6648            return !!(outerNode.compareDocumentPosition(innerNode) & 16);
6649          } else {
6650            return false;
6651          }
6652        }
6653        function isInDocument(node) {
6654          return node && node.ownerDocument && containsNode(node.ownerDocument.documentElement, node);
6655        }
6656        function isSameOriginFrame(iframe) {
6657          try {
6658            return typeof iframe.contentWindow.location.href === "string";
6659          } catch (err) {
6660            return false;
6661          }
6662        }
6663        function getActiveElementDeep() {
6664          var win = window;
6665          var element = getActiveElement();
6666          while (element instanceof win.HTMLIFrameElement) {
6667            if (isSameOriginFrame(element)) {
6668              win = element.contentWindow;
6669            } else {
6670              return element;
6671            }
6672            element = getActiveElement(win.document);
6673          }
6674          return element;
6675        }
6676        function hasSelectionCapabilities(elem) {
6677          var nodeName = elem && elem.nodeName && elem.nodeName.toLowerCase();
6678          return nodeName && (nodeName === "input" && (elem.type === "text" || elem.type === "search" || elem.type === "tel" || elem.type === "url" || elem.type === "password") || nodeName === "textarea" || elem.contentEditable === "true");
6679        }
6680        function getSelectionInformation() {
6681          var focusedElem = getActiveElementDeep();
6682          return {
6683            focusedElem,
6684            selectionRange: hasSelectionCapabilities(focusedElem) ? getSelection(focusedElem) : null
6685          };
6686        }
6687        function restoreSelection(priorSelectionInformation) {
6688          var curFocusedElem = getActiveElementDeep();
6689          var priorFocusedElem = priorSelectionInformation.focusedElem;
6690          var priorSelectionRange = priorSelectionInformation.selectionRange;
6691          if (curFocusedElem !== priorFocusedElem && isInDocument(priorFocusedElem)) {
6692            if (priorSelectionRange !== null && hasSelectionCapabilities(priorFocusedElem)) {
6693              setSelection(priorFocusedElem, priorSelectionRange);
6694            }
6695            var ancestors = [];
6696            var ancestor = priorFocusedElem;
6697            while (ancestor = ancestor.parentNode) {
6698              if (ancestor.nodeType === ELEMENT_NODE) {
6699                ancestors.push({
6700                  element: ancestor,
6701                  left: ancestor.scrollLeft,
6702                  top: ancestor.scrollTop
6703                });
6704              }
6705            }
6706            if (typeof priorFocusedElem.focus === "function") {
6707              priorFocusedElem.focus();
6708            }
6709            for (var i = 0; i < ancestors.length; i++) {
6710              var info = ancestors[i];
6711              info.element.scrollLeft = info.left;
6712              info.element.scrollTop = info.top;
6713            }
6714          }
6715        }
6716        function getSelection(input) {
6717          var selection;
6718          if ("selectionStart" in input) {
6719            selection = {
6720              start: input.selectionStart,
6721              end: input.selectionEnd
6722            };
6723          } else {
6724            selection = getOffsets(input);
6725          }
6726          return selection || {
6727            start: 0,
6728            end: 0
6729          };
6730        }
6731        function setSelection(input, offsets) {
6732          var start = offsets.start;
6733          var end = offsets.end;
6734          if (end === void 0) {
6735            end = start;
6736          }
6737          if ("selectionStart" in input) {
6738            input.selectionStart = start;
6739            input.selectionEnd = Math.min(end, input.value.length);
6740          } else {
6741            setOffsets(input, offsets);
6742          }
6743        }
6744        var skipSelectionChangeEvent = canUseDOM && "documentMode" in document && document.documentMode <= 11;
6745        function registerEvents$3() {
6746          registerTwoPhaseEvent("onSelect", ["focusout", "contextmenu", "dragend", "focusin", "keydown", "keyup", "mousedown", "mouseup", "selectionchange"]);
6747        }
6748        var activeElement$1 = null;
6749        var activeElementInst$1 = null;
6750        var lastSelection = null;
6751        var mouseDown = false;
6752        function getSelection$1(node) {
6753          if ("selectionStart" in node && hasSelectionCapabilities(node)) {
6754            return {
6755              start: node.selectionStart,
6756              end: node.selectionEnd
6757            };
6758          } else {
6759            var win = node.ownerDocument && node.ownerDocument.defaultView || window;
6760            var selection = win.getSelection();
6761            return {
6762              anchorNode: selection.anchorNode,
6763              anchorOffset: selection.anchorOffset,
6764              focusNode: selection.focusNode,
6765              focusOffset: selection.focusOffset
6766            };
6767          }
6768        }
6769        function getEventTargetDocument(eventTarget) {
6770          return eventTarget.window === eventTarget ? eventTarget.document : eventTarget.nodeType === DOCUMENT_NODE ? eventTarget : eventTarget.ownerDocument;
6771        }
6772        function constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget) {
6773          var doc = getEventTargetDocument(nativeEventTarget);
6774          if (mouseDown || activeElement$1 == null || activeElement$1 !== getActiveElement(doc)) {
6775            return;
6776          }
6777          var currentSelection = getSelection$1(activeElement$1);
6778          if (!lastSelection || !shallowEqual(lastSelection, currentSelection)) {
6779            lastSelection = currentSelection;
6780            var listeners = accumulateTwoPhaseListeners(activeElementInst$1, "onSelect");
6781            if (listeners.length > 0) {
6782              var event = new SyntheticEvent("onSelect", "select", null, nativeEvent, nativeEventTarget);
6783              dispatchQueue.push({
6784                event,
6785                listeners
6786              });
6787              event.target = activeElement$1;
6788            }
6789          }
6790        }
6791        function extractEvents$3(dispatchQueue, domEventName, targetInst, nativeEvent, nativeEventTarget, eventSystemFlags, targetContainer) {
6792          var targetNode = targetInst ? getNodeFromInstance(targetInst) : window;
6793          switch (domEventName) {
6794            case "focusin":
6795              if (isTextInputElement(targetNode) || targetNode.contentEditable === "true") {
6796                activeElement$1 = targetNode;
6797                activeElementInst$1 = targetInst;
6798                lastSelection = null;
6799              }
6800              break;
6801            case "focusout":
6802              activeElement$1 = null;
6803              activeElementInst$1 = null;
6804              lastSelection = null;
6805              break;
6806            case "mousedown":
6807              mouseDown = true;
6808              break;
6809            case "contextmenu":
6810            case "mouseup":
6811            case "dragend":
6812              mouseDown = false;
6813              constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget);
6814              break;
6815            case "selectionchange":
6816              if (skipSelectionChangeEvent) {
6817                break;
6818              }
6819            case "keydown":
6820            case "keyup":
6821              constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget);
6822          }
6823        }
6824        function makePrefixMap(styleProp, eventName) {
6825          var prefixes2 = {};
6826          prefixes2[styleProp.toLowerCase()] = eventName.toLowerCase();
6827          prefixes2["Webkit" + styleProp] = "webkit" + eventName;
6828          prefixes2["Moz" + styleProp] = "moz" + eventName;
6829          return prefixes2;
6830        }
6831        var vendorPrefixes = {
6832          animationend: makePrefixMap("Animation", "AnimationEnd"),
6833          animationiteration: makePrefixMap("Animation", "AnimationIteration"),
6834          animationstart: makePrefixMap("Animation", "AnimationStart"),
6835          transitionend: makePrefixMap("Transition", "TransitionEnd")
6836        };
6837        var prefixedEventNames = {};
6838        var style = {};
6839        if (canUseDOM) {
6840          style = document.createElement("div").style;
6841          if (!("AnimationEvent" in window)) {
6842            delete vendorPrefixes.animationend.animation;
6843            delete vendorPrefixes.animationiteration.animation;
6844            delete vendorPrefixes.animationstart.animation;
6845          }
6846          if (!("TransitionEvent" in window)) {
6847            delete vendorPrefixes.transitionend.transition;
6848          }
6849        }
6850        function getVendorPrefixedEventName(eventName) {
6851          if (prefixedEventNames[eventName]) {
6852            return prefixedEventNames[eventName];
6853          } else if (!vendorPrefixes[eventName]) {
6854            return eventName;
6855          }
6856          var prefixMap = vendorPrefixes[eventName];
6857          for (var styleProp in prefixMap) {
6858            if (prefixMap.hasOwnProperty(styleProp) && styleProp in style) {
6859              return prefixedEventNames[eventName] = prefixMap[styleProp];
6860            }
6861          }
6862          return eventName;
6863        }
6864        var ANIMATION_END = getVendorPrefixedEventName("animationend");
6865        var ANIMATION_ITERATION = getVendorPrefixedEventName("animationiteration");
6866        var ANIMATION_START = getVendorPrefixedEventName("animationstart");
6867        var TRANSITION_END = getVendorPrefixedEventName("transitionend");
6868        var topLevelEventsToReactNames = /* @__PURE__ */ new Map();
6869        var simpleEventPluginEvents = ["abort", "auxClick", "cancel", "canPlay", "canPlayThrough", "click", "close", "contextMenu", "copy", "cut", "drag", "dragEnd", "dragEnter", "dragExit", "dragLeave", "dragOver", "dragStart", "drop", "durationChange", "emptied", "encrypted", "ended", "error", "gotPointerCapture", "input", "invalid", "keyDown", "keyPress", "keyUp", "load", "loadedData", "loadedMetadata", "loadStart", "lostPointerCapture", "mouseDown", "mouseMove", "mouseOut", "mouseOver", "mouseUp", "paste", "pause", "play", "playing", "pointerCancel", "pointerDown", "pointerMove", "pointerOut", "pointerOver", "pointerUp", "progress", "rateChange", "reset", "resize", "seeked", "seeking", "stalled", "submit", "suspend", "timeUpdate", "touchCancel", "touchEnd", "touchStart", "volumeChange", "scroll", "toggle", "touchMove", "waiting", "wheel"];
6870        function registerSimpleEvent(domEventName, reactName) {
6871          topLevelEventsToReactNames.set(domEventName, reactName);
6872          registerTwoPhaseEvent(reactName, [domEventName]);
6873        }
6874        function registerSimpleEvents() {
6875          for (var i = 0; i < simpleEventPluginEvents.length; i++) {
6876            var eventName = simpleEventPluginEvents[i];
6877            var domEventName = eventName.toLowerCase();
6878            var capitalizedEvent = eventName[0].toUpperCase() + eventName.slice(1);
6879            registerSimpleEvent(domEventName, "on" + capitalizedEvent);
6880          }
6881          registerSimpleEvent(ANIMATION_END, "onAnimationEnd");
6882          registerSimpleEvent(ANIMATION_ITERATION, "onAnimationIteration");
6883          registerSimpleEvent(ANIMATION_START, "onAnimationStart");
6884          registerSimpleEvent("dblclick", "onDoubleClick");
6885          registerSimpleEvent("focusin", "onFocus");
6886          registerSimpleEvent("focusout", "onBlur");
6887          registerSimpleEvent(TRANSITION_END, "onTransitionEnd");
6888        }
6889        function extractEvents$4(dispatchQueue, domEventName, targetInst, nativeEvent, nativeEventTarget, eventSystemFlags, targetContainer) {
6890          var reactName = topLevelEventsToReactNames.get(domEventName);
6891          if (reactName === void 0) {
6892            return;
6893          }
6894          var SyntheticEventCtor = SyntheticEvent;
6895          var reactEventType = domEventName;
6896          switch (domEventName) {
6897            case "keypress":
6898              if (getEventCharCode(nativeEvent) === 0) {
6899                return;
6900              }
6901            case "keydown":
6902            case "keyup":
6903              SyntheticEventCtor = SyntheticKeyboardEvent;
6904              break;
6905            case "focusin":
6906              reactEventType = "focus";
6907              SyntheticEventCtor = SyntheticFocusEvent;
6908              break;
6909            case "focusout":
6910              reactEventType = "blur";
6911              SyntheticEventCtor = SyntheticFocusEvent;
6912              break;
6913            case "beforeblur":
6914            case "afterblur":
6915              SyntheticEventCtor = SyntheticFocusEvent;
6916              break;
6917            case "click":
6918              if (nativeEvent.button === 2) {
6919                return;
6920              }
6921            case "auxclick":
6922            case "dblclick":
6923            case "mousedown":
6924            case "mousemove":
6925            case "mouseup":
6926            case "mouseout":
6927            case "mouseover":
6928            case "contextmenu":
6929              SyntheticEventCtor = SyntheticMouseEvent;
6930              break;
6931            case "drag":
6932            case "dragend":
6933            case "dragenter":
6934            case "dragexit":
6935            case "dragleave":
6936            case "dragover":
6937            case "dragstart":
6938            case "drop":
6939              SyntheticEventCtor = SyntheticDragEvent;
6940              break;
6941            case "touchcancel":
6942            case "touchend":
6943            case "touchmove":
6944            case "touchstart":
6945              SyntheticEventCtor = SyntheticTouchEvent;
6946              break;
6947            case ANIMATION_END:
6948            case ANIMATION_ITERATION:
6949            case ANIMATION_START:
6950              SyntheticEventCtor = SyntheticAnimationEvent;
6951              break;
6952            case TRANSITION_END:
6953              SyntheticEventCtor = SyntheticTransitionEvent;
6954              break;
6955            case "scroll":
6956              SyntheticEventCtor = SyntheticUIEvent;
6957              break;
6958            case "wheel":
6959              SyntheticEventCtor = SyntheticWheelEvent;
6960              break;
6961            case "copy":
6962            case "cut":
6963            case "paste":
6964              SyntheticEventCtor = SyntheticClipboardEvent;
6965              break;
6966            case "gotpointercapture":
6967            case "lostpointercapture":
6968            case "pointercancel":
6969            case "pointerdown":
6970            case "pointermove":
6971            case "pointerout":
6972            case "pointerover":
6973            case "pointerup":
6974              SyntheticEventCtor = SyntheticPointerEvent;
6975              break;
6976          }
6977          var inCapturePhase = (eventSystemFlags & IS_CAPTURE_PHASE) !== 0;
6978          {
6979            var accumulateTargetOnly = !inCapturePhase && // TODO: ideally, we'd eventually add all events from
6980            // nonDelegatedEvents list in DOMPluginEventSystem.
6981            // Then we can remove this special list.
6982            // This is a breaking change that can wait until React 18.
6983            domEventName === "scroll";
6984            var _listeners = accumulateSinglePhaseListeners(targetInst, reactName, nativeEvent.type, inCapturePhase, accumulateTargetOnly);
6985            if (_listeners.length > 0) {
6986              var _event = new SyntheticEventCtor(reactName, reactEventType, null, nativeEvent, nativeEventTarget);
6987              dispatchQueue.push({
6988                event: _event,
6989                listeners: _listeners
6990              });
6991            }
6992          }
6993        }
6994        registerSimpleEvents();
6995        registerEvents$2();
6996        registerEvents$1();
6997        registerEvents$3();
6998        registerEvents();
6999        function extractEvents$5(dispatchQueue, domEventName, targetInst, nativeEvent, nativeEventTarget, eventSystemFlags, targetContainer) {
7000          extractEvents$4(dispatchQueue, domEventName, targetInst, nativeEvent, nativeEventTarget, eventSystemFlags);
7001          var shouldProcessPolyfillPlugins = (eventSystemFlags & SHOULD_NOT_PROCESS_POLYFILL_EVENT_PLUGINS) === 0;
7002          if (shouldProcessPolyfillPlugins) {
7003            extractEvents$2(dispatchQueue, domEventName, targetInst, nativeEvent, nativeEventTarget);
7004            extractEvents$1(dispatchQueue, domEventName, targetInst, nativeEvent, nativeEventTarget);
7005            extractEvents$3(dispatchQueue, domEventName, targetInst, nativeEvent, nativeEventTarget);
7006            extractEvents(dispatchQueue, domEventName, targetInst, nativeEvent, nativeEventTarget);
7007          }
7008        }
7009        var mediaEventTypes = ["abort", "canplay", "canplaythrough", "durationchange", "emptied", "encrypted", "ended", "error", "loadeddata", "loadedmetadata", "loadstart", "pause", "play", "playing", "progress", "ratechange", "resize", "seeked", "seeking", "stalled", "suspend", "timeupdate", "volumechange", "waiting"];
7010        var nonDelegatedEvents = new Set(["cancel", "close", "invalid", "load", "scroll", "toggle"].concat(mediaEventTypes));
7011        function executeDispatch(event, listener, currentTarget) {
7012          var type = event.type || "unknown-event";
7013          event.currentTarget = currentTarget;
7014          invokeGuardedCallbackAndCatchFirstError(type, listener, void 0, event);
7015          event.currentTarget = null;
7016        }
7017        function processDispatchQueueItemsInOrder(event, dispatchListeners, inCapturePhase) {
7018          var previousInstance;
7019          if (inCapturePhase) {
7020            for (var i = dispatchListeners.length - 1; i >= 0; i--) {
7021              var _dispatchListeners$i = dispatchListeners[i], instance = _dispatchListeners$i.instance, currentTarget = _dispatchListeners$i.currentTarget, listener = _dispatchListeners$i.listener;
7022              if (instance !== previousInstance && event.isPropagationStopped()) {
7023                return;
7024              }
7025              executeDispatch(event, listener, currentTarget);
7026              previousInstance = instance;
7027            }
7028          } else {
7029            for (var _i = 0; _i < dispatchListeners.length; _i++) {
7030              var _dispatchListeners$_i = dispatchListeners[_i], _instance = _dispatchListeners$_i.instance, _currentTarget = _dispatchListeners$_i.currentTarget, _listener = _dispatchListeners$_i.listener;
7031              if (_instance !== previousInstance && event.isPropagationStopped()) {
7032                return;
7033              }
7034              executeDispatch(event, _listener, _currentTarget);
7035              previousInstance = _instance;
7036            }
7037          }
7038        }
7039        function processDispatchQueue(dispatchQueue, eventSystemFlags) {
7040          var inCapturePhase = (eventSystemFlags & IS_CAPTURE_PHASE) !== 0;
7041          for (var i = 0; i < dispatchQueue.length; i++) {
7042            var _dispatchQueue$i = dispatchQueue[i], event = _dispatchQueue$i.event, listeners = _dispatchQueue$i.listeners;
7043            processDispatchQueueItemsInOrder(event, listeners, inCapturePhase);
7044          }
7045          rethrowCaughtError();
7046        }
7047        function dispatchEventsForPlugins(domEventName, eventSystemFlags, nativeEvent, targetInst, targetContainer) {
7048          var nativeEventTarget = getEventTarget(nativeEvent);
7049          var dispatchQueue = [];
7050          extractEvents$5(dispatchQueue, domEventName, targetInst, nativeEvent, nativeEventTarget, eventSystemFlags);
7051          processDispatchQueue(dispatchQueue, eventSystemFlags);
7052        }
7053        function listenToNonDelegatedEvent(domEventName, targetElement) {
7054          {
7055            if (!nonDelegatedEvents.has(domEventName)) {
7056              error('Did not expect a listenToNonDelegatedEvent() call for "%s". This is a bug in React. Please file an issue.', domEventName);
7057            }
7058          }
7059          var isCapturePhaseListener = false;
7060          var listenerSet = getEventListenerSet(targetElement);
7061          var listenerSetKey = getListenerSetKey(domEventName, isCapturePhaseListener);
7062          if (!listenerSet.has(listenerSetKey)) {
7063            addTrappedEventListener(targetElement, domEventName, IS_NON_DELEGATED, isCapturePhaseListener);
7064            listenerSet.add(listenerSetKey);
7065          }
7066        }
7067        function listenToNativeEvent(domEventName, isCapturePhaseListener, target) {
7068          {
7069            if (nonDelegatedEvents.has(domEventName) && !isCapturePhaseListener) {
7070              error('Did not expect a listenToNativeEvent() call for "%s" in the bubble phase. This is a bug in React. Please file an issue.', domEventName);
7071            }
7072          }
7073          var eventSystemFlags = 0;
7074          if (isCapturePhaseListener) {
7075            eventSystemFlags |= IS_CAPTURE_PHASE;
7076          }
7077          addTrappedEventListener(target, domEventName, eventSystemFlags, isCapturePhaseListener);
7078        }
7079        var listeningMarker = "_reactListening" + Math.random().toString(36).slice(2);
7080        function listenToAllSupportedEvents(rootContainerElement) {
7081          if (!rootContainerElement[listeningMarker]) {
7082            rootContainerElement[listeningMarker] = true;
7083            allNativeEvents.forEach(function(domEventName) {
7084              if (domEventName !== "selectionchange") {
7085                if (!nonDelegatedEvents.has(domEventName)) {
7086                  listenToNativeEvent(domEventName, false, rootContainerElement);
7087                }
7088                listenToNativeEvent(domEventName, true, rootContainerElement);
7089              }
7090            });
7091            var ownerDocument = rootContainerElement.nodeType === DOCUMENT_NODE ? rootContainerElement : rootContainerElement.ownerDocument;
7092            if (ownerDocument !== null) {
7093              if (!ownerDocument[listeningMarker]) {
7094                ownerDocument[listeningMarker] = true;
7095                listenToNativeEvent("selectionchange", false, ownerDocument);
7096              }
7097            }
7098          }
7099        }
7100        function addTrappedEventListener(targetContainer, domEventName, eventSystemFlags, isCapturePhaseListener, isDeferredListenerForLegacyFBSupport) {
7101          var listener = createEventListenerWrapperWithPriority(targetContainer, domEventName, eventSystemFlags);
7102          var isPassiveListener = void 0;
7103          if (passiveBrowserEventsSupported) {
7104            if (domEventName === "touchstart" || domEventName === "touchmove" || domEventName === "wheel") {
7105              isPassiveListener = true;
7106            }
7107          }
7108          targetContainer = targetContainer;
7109          var unsubscribeListener;
7110          if (isCapturePhaseListener) {
7111            if (isPassiveListener !== void 0) {
7112              unsubscribeListener = addEventCaptureListenerWithPassiveFlag(targetContainer, domEventName, listener, isPassiveListener);
7113            } else {
7114              unsubscribeListener = addEventCaptureListener(targetContainer, domEventName, listener);
7115            }
7116          } else {
7117            if (isPassiveListener !== void 0) {
7118              unsubscribeListener = addEventBubbleListenerWithPassiveFlag(targetContainer, domEventName, listener, isPassiveListener);
7119            } else {
7120              unsubscribeListener = addEventBubbleListener(targetContainer, domEventName, listener);
7121            }
7122          }
7123        }
7124        function isMatchingRootContainer(grandContainer, targetContainer) {
7125          return grandContainer === targetContainer || grandContainer.nodeType === COMMENT_NODE && grandContainer.parentNode === targetContainer;
7126        }
7127        function dispatchEventForPluginEventSystem(domEventName, eventSystemFlags, nativeEvent, targetInst, targetContainer) {
7128          var ancestorInst = targetInst;
7129          if ((eventSystemFlags & IS_EVENT_HANDLE_NON_MANAGED_NODE) === 0 && (eventSystemFlags & IS_NON_DELEGATED) === 0) {
7130            var targetContainerNode = targetContainer;
7131            if (targetInst !== null) {
7132              var node = targetInst;
7133              mainLoop: while (true) {
7134                if (node === null) {
7135                  return;
7136                }
7137                var nodeTag = node.tag;
7138                if (nodeTag === HostRoot || nodeTag === HostPortal) {
7139                  var container = node.stateNode.containerInfo;
7140                  if (isMatchingRootContainer(container, targetContainerNode)) {
7141                    break;
7142                  }
7143                  if (nodeTag === HostPortal) {
7144                    var grandNode = node.return;
7145                    while (grandNode !== null) {
7146                      var grandTag = grandNode.tag;
7147                      if (grandTag === HostRoot || grandTag === HostPortal) {
7148                        var grandContainer = grandNode.stateNode.containerInfo;
7149                        if (isMatchingRootContainer(grandContainer, targetContainerNode)) {
7150                          return;
7151                        }
7152                      }
7153                      grandNode = grandNode.return;
7154                    }
7155                  }
7156                  while (container !== null) {
7157                    var parentNode = getClosestInstanceFromNode(container);
7158                    if (parentNode === null) {
7159                      return;
7160                    }
7161                    var parentTag = parentNode.tag;
7162                    if (parentTag === HostComponent || parentTag === HostText) {
7163                      node = ancestorInst = parentNode;
7164                      continue mainLoop;
7165                    }
7166                    container = container.parentNode;
7167                  }
7168                }
7169                node = node.return;
7170              }
7171            }
7172          }
7173          batchedUpdates(function() {
7174            return dispatchEventsForPlugins(domEventName, eventSystemFlags, nativeEvent, ancestorInst);
7175          });
7176        }
7177        function createDispatchListener(instance, listener, currentTarget) {
7178          return {
7179            instance,
7180            listener,
7181            currentTarget
7182          };
7183        }
7184        function accumulateSinglePhaseListeners(targetFiber, reactName, nativeEventType, inCapturePhase, accumulateTargetOnly, nativeEvent) {
7185          var captureName = reactName !== null ? reactName + "Capture" : null;
7186          var reactEventName = inCapturePhase ? captureName : reactName;
7187          var listeners = [];
7188          var instance = targetFiber;
7189          var lastHostComponent = null;
7190          while (instance !== null) {
7191            var _instance2 = instance, stateNode = _instance2.stateNode, tag = _instance2.tag;
7192            if (tag === HostComponent && stateNode !== null) {
7193              lastHostComponent = stateNode;
7194              if (reactEventName !== null) {
7195                var listener = getListener(instance, reactEventName);
7196                if (listener != null) {
7197                  listeners.push(createDispatchListener(instance, listener, lastHostComponent));
7198                }
7199              }
7200            }
7201            if (accumulateTargetOnly) {
7202              break;
7203            }
7204            instance = instance.return;
7205          }
7206          return listeners;
7207        }
7208        function accumulateTwoPhaseListeners(targetFiber, reactName) {
7209          var captureName = reactName + "Capture";
7210          var listeners = [];
7211          var instance = targetFiber;
7212          while (instance !== null) {
7213            var _instance3 = instance, stateNode = _instance3.stateNode, tag = _instance3.tag;
7214            if (tag === HostComponent && stateNode !== null) {
7215              var currentTarget = stateNode;
7216              var captureListener = getListener(instance, captureName);
7217              if (captureListener != null) {
7218                listeners.unshift(createDispatchListener(instance, captureListener, currentTarget));
7219              }
7220              var bubbleListener = getListener(instance, reactName);
7221              if (bubbleListener != null) {
7222                listeners.push(createDispatchListener(instance, bubbleListener, currentTarget));
7223              }
7224            }
7225            instance = instance.return;
7226          }
7227          return listeners;
7228        }
7229        function getParent(inst) {
7230          if (inst === null) {
7231            return null;
7232          }
7233          do {
7234            inst = inst.return;
7235          } while (inst && inst.tag !== HostComponent);
7236          if (inst) {
7237            return inst;
7238          }
7239          return null;
7240        }
7241        function getLowestCommonAncestor(instA, instB) {
7242          var nodeA = instA;
7243          var nodeB = instB;
7244          var depthA = 0;
7245          for (var tempA = nodeA; tempA; tempA = getParent(tempA)) {
7246            depthA++;
7247          }
7248          var depthB = 0;
7249          for (var tempB = nodeB; tempB; tempB = getParent(tempB)) {
7250            depthB++;
7251          }
7252          while (depthA - depthB > 0) {
7253            nodeA = getParent(nodeA);
7254            depthA--;
7255          }
7256          while (depthB - depthA > 0) {
7257            nodeB = getParent(nodeB);
7258            depthB--;
7259          }
7260          var depth = depthA;
7261          while (depth--) {
7262            if (nodeA === nodeB || nodeB !== null && nodeA === nodeB.alternate) {
7263              return nodeA;
7264            }
7265            nodeA = getParent(nodeA);
7266            nodeB = getParent(nodeB);
7267          }
7268          return null;
7269        }
7270        function accumulateEnterLeaveListenersForEvent(dispatchQueue, event, target, common, inCapturePhase) {
7271          var registrationName = event._reactName;
7272          var listeners = [];
7273          var instance = target;
7274          while (instance !== null) {
7275            if (instance === common) {
7276              break;
7277            }
7278            var _instance4 = instance, alternate = _instance4.alternate, stateNode = _instance4.stateNode, tag = _instance4.tag;
7279            if (alternate !== null && alternate === common) {
7280              break;
7281            }
7282            if (tag === HostComponent && stateNode !== null) {
7283              var currentTarget = stateNode;
7284              if (inCapturePhase) {
7285                var captureListener = getListener(instance, registrationName);
7286                if (captureListener != null) {
7287                  listeners.unshift(createDispatchListener(instance, captureListener, currentTarget));
7288                }
7289              } else if (!inCapturePhase) {
7290                var bubbleListener = getListener(instance, registrationName);
7291                if (bubbleListener != null) {
7292                  listeners.push(createDispatchListener(instance, bubbleListener, currentTarget));
7293                }
7294              }
7295            }
7296            instance = instance.return;
7297          }
7298          if (listeners.length !== 0) {
7299            dispatchQueue.push({
7300              event,
7301              listeners
7302            });
7303          }
7304        }
7305        function accumulateEnterLeaveTwoPhaseListeners(dispatchQueue, leaveEvent, enterEvent, from, to) {
7306          var common = from && to ? getLowestCommonAncestor(from, to) : null;
7307          if (from !== null) {
7308            accumulateEnterLeaveListenersForEvent(dispatchQueue, leaveEvent, from, common, false);
7309          }
7310          if (to !== null && enterEvent !== null) {
7311            accumulateEnterLeaveListenersForEvent(dispatchQueue, enterEvent, to, common, true);
7312          }
7313        }
7314        function getListenerSetKey(domEventName, capture) {
7315          return domEventName + "__" + (capture ? "capture" : "bubble");
7316        }
7317        var didWarnInvalidHydration = false;
7318        var DANGEROUSLY_SET_INNER_HTML = "dangerouslySetInnerHTML";
7319        var SUPPRESS_CONTENT_EDITABLE_WARNING = "suppressContentEditableWarning";
7320        var SUPPRESS_HYDRATION_WARNING = "suppressHydrationWarning";
7321        var AUTOFOCUS = "autoFocus";
7322        var CHILDREN = "children";
7323        var STYLE = "style";
7324        var HTML$1 = "__html";
7325        var warnedUnknownTags;
7326        var validatePropertiesInDevelopment;
7327        var warnForPropDifference;
7328        var warnForExtraAttributes;
7329        var warnForInvalidEventListener;
7330        var canDiffStyleForHydrationWarning;
7331        var normalizeHTML;
7332        {
7333          warnedUnknownTags = {
7334            // There are working polyfills for <dialog>. Let people use it.
7335            dialog: true,
7336            // Electron ships a custom <webview> tag to display external web content in
7337            // an isolated frame and process.
7338            // This tag is not present in non Electron environments such as JSDom which
7339            // is often used for testing purposes.
7340            // @see https://electronjs.org/docs/api/webview-tag
7341            webview: true
7342          };
7343          validatePropertiesInDevelopment = function(type, props) {
7344            validateProperties(type, props);
7345            validateProperties$1(type, props);
7346            validateProperties$2(type, props, {
7347              registrationNameDependencies,
7348              possibleRegistrationNames
7349            });
7350          };
7351          canDiffStyleForHydrationWarning = canUseDOM && !document.documentMode;
7352          warnForPropDifference = function(propName, serverValue, clientValue) {
7353            if (didWarnInvalidHydration) {
7354              return;
7355            }
7356            var normalizedClientValue = normalizeMarkupForTextOrAttribute(clientValue);
7357            var normalizedServerValue = normalizeMarkupForTextOrAttribute(serverValue);
7358            if (normalizedServerValue === normalizedClientValue) {
7359              return;
7360            }
7361            didWarnInvalidHydration = true;
7362            error("Prop `%s` did not match. Server: %s Client: %s", propName, JSON.stringify(normalizedServerValue), JSON.stringify(normalizedClientValue));
7363          };
7364          warnForExtraAttributes = function(attributeNames) {
7365            if (didWarnInvalidHydration) {
7366              return;
7367            }
7368            didWarnInvalidHydration = true;
7369            var names = [];
7370            attributeNames.forEach(function(name) {
7371              names.push(name);
7372            });
7373            error("Extra attributes from the server: %s", names);
7374          };
7375          warnForInvalidEventListener = function(registrationName, listener) {
7376            if (listener === false) {
7377              error("Expected `%s` listener to be a function, instead got `false`.\n\nIf you used to conditionally omit it with %s={condition && value}, pass %s={condition ? value : undefined} instead.", registrationName, registrationName, registrationName);
7378            } else {
7379              error("Expected `%s` listener to be a function, instead got a value of `%s` type.", registrationName, typeof listener);
7380            }
7381          };
7382          normalizeHTML = function(parent, html) {
7383            var testElement = parent.namespaceURI === HTML_NAMESPACE ? parent.ownerDocument.createElement(parent.tagName) : parent.ownerDocument.createElementNS(parent.namespaceURI, parent.tagName);
7384            testElement.innerHTML = html;
7385            return testElement.innerHTML;
7386          };
7387        }
7388        var NORMALIZE_NEWLINES_REGEX = /\r\n?/g;
7389        var NORMALIZE_NULL_AND_REPLACEMENT_REGEX = /\u0000|\uFFFD/g;
7390        function normalizeMarkupForTextOrAttribute(markup) {
7391          {
7392            checkHtmlStringCoercion(markup);
7393          }
7394          var markupString = typeof markup === "string" ? markup : "" + markup;
7395          return markupString.replace(NORMALIZE_NEWLINES_REGEX, "\n").replace(NORMALIZE_NULL_AND_REPLACEMENT_REGEX, "");
7396        }
7397        function checkForUnmatchedText(serverText, clientText, isConcurrentMode, shouldWarnDev) {
7398          var normalizedClientText = normalizeMarkupForTextOrAttribute(clientText);
7399          var normalizedServerText = normalizeMarkupForTextOrAttribute(serverText);
7400          if (normalizedServerText === normalizedClientText) {
7401            return;
7402          }
7403          if (shouldWarnDev) {
7404            {
7405              if (!didWarnInvalidHydration) {
7406                didWarnInvalidHydration = true;
7407                error('Text content did not match. Server: "%s" Client: "%s"', normalizedServerText, normalizedClientText);
7408              }
7409            }
7410          }
7411          if (isConcurrentMode && enableClientRenderFallbackOnTextMismatch) {
7412            throw new Error("Text content does not match server-rendered HTML.");
7413          }
7414        }
7415        function getOwnerDocumentFromRootContainer(rootContainerElement) {
7416          return rootContainerElement.nodeType === DOCUMENT_NODE ? rootContainerElement : rootContainerElement.ownerDocument;
7417        }
7418        function noop() {
7419        }
7420        function trapClickOnNonInteractiveElement(node) {
7421          node.onclick = noop;
7422        }
7423        function setInitialDOMProperties(tag, domElement, rootContainerElement, nextProps, isCustomComponentTag) {
7424          for (var propKey in nextProps) {
7425            if (!nextProps.hasOwnProperty(propKey)) {
7426              continue;
7427            }
7428            var nextProp = nextProps[propKey];
7429            if (propKey === STYLE) {
7430              {
7431                if (nextProp) {
7432                  Object.freeze(nextProp);
7433                }
7434              }
7435              setValueForStyles(domElement, nextProp);
7436            } else if (propKey === DANGEROUSLY_SET_INNER_HTML) {
7437              var nextHtml = nextProp ? nextProp[HTML$1] : void 0;
7438              if (nextHtml != null) {
7439                setInnerHTML(domElement, nextHtml);
7440              }
7441            } else if (propKey === CHILDREN) {
7442              if (typeof nextProp === "string") {
7443                var canSetTextContent = tag !== "textarea" || nextProp !== "";
7444                if (canSetTextContent) {
7445                  setTextContent(domElement, nextProp);
7446                }
7447              } else if (typeof nextProp === "number") {
7448                setTextContent(domElement, "" + nextProp);
7449              }
7450            } else if (propKey === SUPPRESS_CONTENT_EDITABLE_WARNING || propKey === SUPPRESS_HYDRATION_WARNING) ;
7451            else if (propKey === AUTOFOCUS) ;
7452            else if (registrationNameDependencies.hasOwnProperty(propKey)) {
7453              if (nextProp != null) {
7454                if (typeof nextProp !== "function") {
7455                  warnForInvalidEventListener(propKey, nextProp);
7456                }
7457                if (propKey === "onScroll") {
7458                  listenToNonDelegatedEvent("scroll", domElement);
7459                }
7460              }
7461            } else if (nextProp != null) {
7462              setValueForProperty(domElement, propKey, nextProp, isCustomComponentTag);
7463            }
7464          }
7465        }
7466        function updateDOMProperties(domElement, updatePayload, wasCustomComponentTag, isCustomComponentTag) {
7467          for (var i = 0; i < updatePayload.length; i += 2) {
7468            var propKey = updatePayload[i];
7469            var propValue = updatePayload[i + 1];
7470            if (propKey === STYLE) {
7471              setValueForStyles(domElement, propValue);
7472            } else if (propKey === DANGEROUSLY_SET_INNER_HTML) {
7473              setInnerHTML(domElement, propValue);
7474            } else if (propKey === CHILDREN) {
7475              setTextContent(domElement, propValue);
7476            } else {
7477              setValueForProperty(domElement, propKey, propValue, isCustomComponentTag);
7478            }
7479          }
7480        }
7481        function createElement(type, props, rootContainerElement, parentNamespace) {
7482          var isCustomComponentTag;
7483          var ownerDocument = getOwnerDocumentFromRootContainer(rootContainerElement);
7484          var domElement;
7485          var namespaceURI = parentNamespace;
7486          if (namespaceURI === HTML_NAMESPACE) {
7487            namespaceURI = getIntrinsicNamespace(type);
7488          }
7489          if (namespaceURI === HTML_NAMESPACE) {
7490            {
7491              isCustomComponentTag = isCustomComponent(type, props);
7492              if (!isCustomComponentTag && type !== type.toLowerCase()) {
7493                error("<%s /> is using incorrect casing. Use PascalCase for React components, or lowercase for HTML elements.", type);
7494              }
7495            }
7496            if (type === "script") {
7497              var div = ownerDocument.createElement("div");
7498              div.innerHTML = "<script><\/script>";
7499              var firstChild = div.firstChild;
7500              domElement = div.removeChild(firstChild);
7501            } else if (typeof props.is === "string") {
7502              domElement = ownerDocument.createElement(type, {
7503                is: props.is
7504              });
7505            } else {
7506              domElement = ownerDocument.createElement(type);
7507              if (type === "select") {
7508                var node = domElement;
7509                if (props.multiple) {
7510                  node.multiple = true;
7511                } else if (props.size) {
7512                  node.size = props.size;
7513                }
7514              }
7515            }
7516          } else {
7517            domElement = ownerDocument.createElementNS(namespaceURI, type);
7518          }
7519          {
7520            if (namespaceURI === HTML_NAMESPACE) {
7521              if (!isCustomComponentTag && Object.prototype.toString.call(domElement) === "[object HTMLUnknownElement]" && !hasOwnProperty.call(warnedUnknownTags, type)) {
7522                warnedUnknownTags[type] = true;
7523                error("The tag <%s> is unrecognized in this browser. If you meant to render a React component, start its name with an uppercase letter.", type);
7524              }
7525            }
7526          }
7527          return domElement;
7528        }
7529        function createTextNode(text, rootContainerElement) {
7530          return getOwnerDocumentFromRootContainer(rootContainerElement).createTextNode(text);
7531        }
7532        function setInitialProperties(domElement, tag, rawProps, rootContainerElement) {
7533          var isCustomComponentTag = isCustomComponent(tag, rawProps);
7534          {
7535            validatePropertiesInDevelopment(tag, rawProps);
7536          }
7537          var props;
7538          switch (tag) {
7539            case "dialog":
7540              listenToNonDelegatedEvent("cancel", domElement);
7541              listenToNonDelegatedEvent("close", domElement);
7542              props = rawProps;
7543              break;
7544            case "iframe":
7545            case "object":
7546            case "embed":
7547              listenToNonDelegatedEvent("load", domElement);
7548              props = rawProps;
7549              break;
7550            case "video":
7551            case "audio":
7552              for (var i = 0; i < mediaEventTypes.length; i++) {
7553                listenToNonDelegatedEvent(mediaEventTypes[i], domElement);
7554              }
7555              props = rawProps;
7556              break;
7557            case "source":
7558              listenToNonDelegatedEvent("error", domElement);
7559              props = rawProps;
7560              break;
7561            case "img":
7562            case "image":
7563            case "link":
7564              listenToNonDelegatedEvent("error", domElement);
7565              listenToNonDelegatedEvent("load", domElement);
7566              props = rawProps;
7567              break;
7568            case "details":
7569              listenToNonDelegatedEvent("toggle", domElement);
7570              props = rawProps;
7571              break;
7572            case "input":
7573              initWrapperState(domElement, rawProps);
7574              props = getHostProps(domElement, rawProps);
7575              listenToNonDelegatedEvent("invalid", domElement);
7576              break;
7577            case "option":
7578              validateProps(domElement, rawProps);
7579              props = rawProps;
7580              break;
7581            case "select":
7582              initWrapperState$1(domElement, rawProps);
7583              props = getHostProps$1(domElement, rawProps);
7584              listenToNonDelegatedEvent("invalid", domElement);
7585              break;
7586            case "textarea":
7587              initWrapperState$2(domElement, rawProps);
7588              props = getHostProps$2(domElement, rawProps);
7589              listenToNonDelegatedEvent("invalid", domElement);
7590              break;
7591            default:
7592              props = rawProps;
7593          }
7594          assertValidProps(tag, props);
7595          setInitialDOMProperties(tag, domElement, rootContainerElement, props, isCustomComponentTag);
7596          switch (tag) {
7597            case "input":
7598              track(domElement);
7599              postMountWrapper(domElement, rawProps, false);
7600              break;
7601            case "textarea":
7602              track(domElement);
7603              postMountWrapper$3(domElement);
7604              break;
7605            case "option":
7606              postMountWrapper$1(domElement, rawProps);
7607              break;
7608            case "select":
7609              postMountWrapper$2(domElement, rawProps);
7610              break;
7611            default:
7612              if (typeof props.onClick === "function") {
7613                trapClickOnNonInteractiveElement(domElement);
7614              }
7615              break;
7616          }
7617        }
7618        function diffProperties(domElement, tag, lastRawProps, nextRawProps, rootContainerElement) {
7619          {
7620            validatePropertiesInDevelopment(tag, nextRawProps);
7621          }
7622          var updatePayload = null;
7623          var lastProps;
7624          var nextProps;
7625          switch (tag) {
7626            case "input":
7627              lastProps = getHostProps(domElement, lastRawProps);
7628              nextProps = getHostProps(domElement, nextRawProps);
7629              updatePayload = [];
7630              break;
7631            case "select":
7632              lastProps = getHostProps$1(domElement, lastRawProps);
7633              nextProps = getHostProps$1(domElement, nextRawProps);
7634              updatePayload = [];
7635              break;
7636            case "textarea":
7637              lastProps = getHostProps$2(domElement, lastRawProps);
7638              nextProps = getHostProps$2(domElement, nextRawProps);
7639              updatePayload = [];
7640              break;
7641            default:
7642              lastProps = lastRawProps;
7643              nextProps = nextRawProps;
7644              if (typeof lastProps.onClick !== "function" && typeof nextProps.onClick === "function") {
7645                trapClickOnNonInteractiveElement(domElement);
7646              }
7647              break;
7648          }
7649          assertValidProps(tag, nextProps);
7650          var propKey;
7651          var styleName;
7652          var styleUpdates = null;
7653          for (propKey in lastProps) {
7654            if (nextProps.hasOwnProperty(propKey) || !lastProps.hasOwnProperty(propKey) || lastProps[propKey] == null) {
7655              continue;
7656            }
7657            if (propKey === STYLE) {
7658              var lastStyle = lastProps[propKey];
7659              for (styleName in lastStyle) {
7660                if (lastStyle.hasOwnProperty(styleName)) {
7661                  if (!styleUpdates) {
7662                    styleUpdates = {};
7663                  }
7664                  styleUpdates[styleName] = "";
7665                }
7666              }
7667            } else if (propKey === DANGEROUSLY_SET_INNER_HTML || propKey === CHILDREN) ;
7668            else if (propKey === SUPPRESS_CONTENT_EDITABLE_WARNING || propKey === SUPPRESS_HYDRATION_WARNING) ;
7669            else if (propKey === AUTOFOCUS) ;
7670            else if (registrationNameDependencies.hasOwnProperty(propKey)) {
7671              if (!updatePayload) {
7672                updatePayload = [];
7673              }
7674            } else {
7675              (updatePayload = updatePayload || []).push(propKey, null);
7676            }
7677          }
7678          for (propKey in nextProps) {
7679            var nextProp = nextProps[propKey];
7680            var lastProp = lastProps != null ? lastProps[propKey] : void 0;
7681            if (!nextProps.hasOwnProperty(propKey) || nextProp === lastProp || nextProp == null && lastProp == null) {
7682              continue;
7683            }
7684            if (propKey === STYLE) {
7685              {
7686                if (nextProp) {
7687                  Object.freeze(nextProp);
7688                }
7689              }
7690              if (lastProp) {
7691                for (styleName in lastProp) {
7692                  if (lastProp.hasOwnProperty(styleName) && (!nextProp || !nextProp.hasOwnProperty(styleName))) {
7693                    if (!styleUpdates) {
7694                      styleUpdates = {};
7695                    }
7696                    styleUpdates[styleName] = "";
7697                  }
7698                }
7699                for (styleName in nextProp) {
7700                  if (nextProp.hasOwnProperty(styleName) && lastProp[styleName] !== nextProp[styleName]) {
7701                    if (!styleUpdates) {
7702                      styleUpdates = {};
7703                    }
7704                    styleUpdates[styleName] = nextProp[styleName];
7705                  }
7706                }
7707              } else {
7708                if (!styleUpdates) {
7709                  if (!updatePayload) {
7710                    updatePayload = [];
7711                  }
7712                  updatePayload.push(propKey, styleUpdates);
7713                }
7714                styleUpdates = nextProp;
7715              }
7716            } else if (propKey === DANGEROUSLY_SET_INNER_HTML) {
7717              var nextHtml = nextProp ? nextProp[HTML$1] : void 0;
7718              var lastHtml = lastProp ? lastProp[HTML$1] : void 0;
7719              if (nextHtml != null) {
7720                if (lastHtml !== nextHtml) {
7721                  (updatePayload = updatePayload || []).push(propKey, nextHtml);
7722                }
7723              }
7724            } else if (propKey === CHILDREN) {
7725              if (typeof nextProp === "string" || typeof nextProp === "number") {
7726                (updatePayload = updatePayload || []).push(propKey, "" + nextProp);
7727              }
7728            } else if (propKey === SUPPRESS_CONTENT_EDITABLE_WARNING || propKey === SUPPRESS_HYDRATION_WARNING) ;
7729            else if (registrationNameDependencies.hasOwnProperty(propKey)) {
7730              if (nextProp != null) {
7731                if (typeof nextProp !== "function") {
7732                  warnForInvalidEventListener(propKey, nextProp);
7733                }
7734                if (propKey === "onScroll") {
7735                  listenToNonDelegatedEvent("scroll", domElement);
7736                }
7737              }
7738              if (!updatePayload && lastProp !== nextProp) {
7739                updatePayload = [];
7740              }
7741            } else {
7742              (updatePayload = updatePayload || []).push(propKey, nextProp);
7743            }
7744          }
7745          if (styleUpdates) {
7746            {
7747              validateShorthandPropertyCollisionInDev(styleUpdates, nextProps[STYLE]);
7748            }
7749            (updatePayload = updatePayload || []).push(STYLE, styleUpdates);
7750          }
7751          return updatePayload;
7752        }
7753        function updateProperties(domElement, updatePayload, tag, lastRawProps, nextRawProps) {
7754          if (tag === "input" && nextRawProps.type === "radio" && nextRawProps.name != null) {
7755            updateChecked(domElement, nextRawProps);
7756          }
7757          var wasCustomComponentTag = isCustomComponent(tag, lastRawProps);
7758          var isCustomComponentTag = isCustomComponent(tag, nextRawProps);
7759          updateDOMProperties(domElement, updatePayload, wasCustomComponentTag, isCustomComponentTag);
7760          switch (tag) {
7761            case "input":
7762              updateWrapper(domElement, nextRawProps);
7763              break;
7764            case "textarea":
7765              updateWrapper$1(domElement, nextRawProps);
7766              break;
7767            case "select":
7768              postUpdateWrapper(domElement, nextRawProps);
7769              break;
7770          }
7771        }
7772        function getPossibleStandardName(propName) {
7773          {
7774            var lowerCasedName = propName.toLowerCase();
7775            if (!possibleStandardNames.hasOwnProperty(lowerCasedName)) {
7776              return null;
7777            }
7778            return possibleStandardNames[lowerCasedName] || null;
7779          }
7780        }
7781        function diffHydratedProperties(domElement, tag, rawProps, parentNamespace, rootContainerElement, isConcurrentMode, shouldWarnDev) {
7782          var isCustomComponentTag;
7783          var extraAttributeNames;
7784          {
7785            isCustomComponentTag = isCustomComponent(tag, rawProps);
7786            validatePropertiesInDevelopment(tag, rawProps);
7787          }
7788          switch (tag) {
7789            case "dialog":
7790              listenToNonDelegatedEvent("cancel", domElement);
7791              listenToNonDelegatedEvent("close", domElement);
7792              break;
7793            case "iframe":
7794            case "object":
7795            case "embed":
7796              listenToNonDelegatedEvent("load", domElement);
7797              break;
7798            case "video":
7799            case "audio":
7800              for (var i = 0; i < mediaEventTypes.length; i++) {
7801                listenToNonDelegatedEvent(mediaEventTypes[i], domElement);
7802              }
7803              break;
7804            case "source":
7805              listenToNonDelegatedEvent("error", domElement);
7806              break;
7807            case "img":
7808            case "image":
7809            case "link":
7810              listenToNonDelegatedEvent("error", domElement);
7811              listenToNonDelegatedEvent("load", domElement);
7812              break;
7813            case "details":
7814              listenToNonDelegatedEvent("toggle", domElement);
7815              break;
7816            case "input":
7817              initWrapperState(domElement, rawProps);
7818              listenToNonDelegatedEvent("invalid", domElement);
7819              break;
7820            case "option":
7821              validateProps(domElement, rawProps);
7822              break;
7823            case "select":
7824              initWrapperState$1(domElement, rawProps);
7825              listenToNonDelegatedEvent("invalid", domElement);
7826              break;
7827            case "textarea":
7828              initWrapperState$2(domElement, rawProps);
7829              listenToNonDelegatedEvent("invalid", domElement);
7830              break;
7831          }
7832          assertValidProps(tag, rawProps);
7833          {
7834            extraAttributeNames = /* @__PURE__ */ new Set();
7835            var attributes = domElement.attributes;
7836            for (var _i = 0; _i < attributes.length; _i++) {
7837              var name = attributes[_i].name.toLowerCase();
7838              switch (name) {
7839                case "value":
7840                  break;
7841                case "checked":
7842                  break;
7843                case "selected":
7844                  break;
7845                default:
7846                  extraAttributeNames.add(attributes[_i].name);
7847              }
7848            }
7849          }
7850          var updatePayload = null;
7851          for (var propKey in rawProps) {
7852            if (!rawProps.hasOwnProperty(propKey)) {
7853              continue;
7854            }
7855            var nextProp = rawProps[propKey];
7856            if (propKey === CHILDREN) {
7857              if (typeof nextProp === "string") {
7858                if (domElement.textContent !== nextProp) {
7859                  if (rawProps[SUPPRESS_HYDRATION_WARNING] !== true) {
7860                    checkForUnmatchedText(domElement.textContent, nextProp, isConcurrentMode, shouldWarnDev);
7861                  }
7862                  updatePayload = [CHILDREN, nextProp];
7863                }
7864              } else if (typeof nextProp === "number") {
7865                if (domElement.textContent !== "" + nextProp) {
7866                  if (rawProps[SUPPRESS_HYDRATION_WARNING] !== true) {
7867                    checkForUnmatchedText(domElement.textContent, nextProp, isConcurrentMode, shouldWarnDev);
7868                  }
7869                  updatePayload = [CHILDREN, "" + nextProp];
7870                }
7871              }
7872            } else if (registrationNameDependencies.hasOwnProperty(propKey)) {
7873              if (nextProp != null) {
7874                if (typeof nextProp !== "function") {
7875                  warnForInvalidEventListener(propKey, nextProp);
7876                }
7877                if (propKey === "onScroll") {
7878                  listenToNonDelegatedEvent("scroll", domElement);
7879                }
7880              }
7881            } else if (shouldWarnDev && true && // Convince Flow we've calculated it (it's DEV-only in this method.)
7882            typeof isCustomComponentTag === "boolean") {
7883              var serverValue = void 0;
7884              var propertyInfo = isCustomComponentTag && enableCustomElementPropertySupport ? null : getPropertyInfo(propKey);
7885              if (rawProps[SUPPRESS_HYDRATION_WARNING] === true) ;
7886              else if (propKey === SUPPRESS_CONTENT_EDITABLE_WARNING || propKey === SUPPRESS_HYDRATION_WARNING || // Controlled attributes are not validated
7887              // TODO: Only ignore them on controlled tags.
7888              propKey === "value" || propKey === "checked" || propKey === "selected") ;
7889              else if (propKey === DANGEROUSLY_SET_INNER_HTML) {
7890                var serverHTML = domElement.innerHTML;
7891                var nextHtml = nextProp ? nextProp[HTML$1] : void 0;
7892                if (nextHtml != null) {
7893                  var expectedHTML = normalizeHTML(domElement, nextHtml);
7894                  if (expectedHTML !== serverHTML) {
7895                    warnForPropDifference(propKey, serverHTML, expectedHTML);
7896                  }
7897                }
7898              } else if (propKey === STYLE) {
7899                extraAttributeNames.delete(propKey);
7900                if (canDiffStyleForHydrationWarning) {
7901                  var expectedStyle = createDangerousStringForStyles(nextProp);
7902                  serverValue = domElement.getAttribute("style");
7903                  if (expectedStyle !== serverValue) {
7904                    warnForPropDifference(propKey, serverValue, expectedStyle);
7905                  }
7906                }
7907              } else if (isCustomComponentTag && !enableCustomElementPropertySupport) {
7908                extraAttributeNames.delete(propKey.toLowerCase());
7909                serverValue = getValueForAttribute(domElement, propKey, nextProp);
7910                if (nextProp !== serverValue) {
7911                  warnForPropDifference(propKey, serverValue, nextProp);
7912                }
7913              } else if (!shouldIgnoreAttribute(propKey, propertyInfo, isCustomComponentTag) && !shouldRemoveAttribute(propKey, nextProp, propertyInfo, isCustomComponentTag)) {
7914                var isMismatchDueToBadCasing = false;
7915                if (propertyInfo !== null) {
7916                  extraAttributeNames.delete(propertyInfo.attributeName);
7917                  serverValue = getValueForProperty(domElement, propKey, nextProp, propertyInfo);
7918                } else {
7919                  var ownNamespace = parentNamespace;
7920                  if (ownNamespace === HTML_NAMESPACE) {
7921                    ownNamespace = getIntrinsicNamespace(tag);
7922                  }
7923                  if (ownNamespace === HTML_NAMESPACE) {
7924                    extraAttributeNames.delete(propKey.toLowerCase());
7925                  } else {
7926                    var standardName = getPossibleStandardName(propKey);
7927                    if (standardName !== null && standardName !== propKey) {
7928                      isMismatchDueToBadCasing = true;
7929                      extraAttributeNames.delete(standardName);
7930                    }
7931                    extraAttributeNames.delete(propKey);
7932                  }
7933                  serverValue = getValueForAttribute(domElement, propKey, nextProp);
7934                }
7935                var dontWarnCustomElement = enableCustomElementPropertySupport;
7936                if (!dontWarnCustomElement && nextProp !== serverValue && !isMismatchDueToBadCasing) {
7937                  warnForPropDifference(propKey, serverValue, nextProp);
7938                }
7939              }
7940            }
7941          }
7942          {
7943            if (shouldWarnDev) {
7944              if (
7945                // $FlowFixMe - Should be inferred as not undefined.
7946                extraAttributeNames.size > 0 && rawProps[SUPPRESS_HYDRATION_WARNING] !== true
7947              ) {
7948                warnForExtraAttributes(extraAttributeNames);
7949              }
7950            }
7951          }
7952          switch (tag) {
7953            case "input":
7954              track(domElement);
7955              postMountWrapper(domElement, rawProps, true);
7956              break;
7957            case "textarea":
7958              track(domElement);
7959              postMountWrapper$3(domElement);
7960              break;
7961            case "select":
7962            case "option":
7963              break;
7964            default:
7965              if (typeof rawProps.onClick === "function") {
7966                trapClickOnNonInteractiveElement(domElement);
7967              }
7968              break;
7969          }
7970          return updatePayload;
7971        }
7972        function diffHydratedText(textNode, text, isConcurrentMode) {
7973          var isDifferent = textNode.nodeValue !== text;
7974          return isDifferent;
7975        }
7976        function warnForDeletedHydratableElement(parentNode, child) {
7977          {
7978            if (didWarnInvalidHydration) {
7979              return;
7980            }
7981            didWarnInvalidHydration = true;
7982            error("Did not expect server HTML to contain a <%s> in <%s>.", child.nodeName.toLowerCase(), parentNode.nodeName.toLowerCase());
7983          }
7984        }
7985        function warnForDeletedHydratableText(parentNode, child) {
7986          {
7987            if (didWarnInvalidHydration) {
7988              return;
7989            }
7990            didWarnInvalidHydration = true;
7991            error('Did not expect server HTML to contain the text node "%s" in <%s>.', child.nodeValue, parentNode.nodeName.toLowerCase());
7992          }
7993        }
7994        function warnForInsertedHydratedElement(parentNode, tag, props) {
7995          {
7996            if (didWarnInvalidHydration) {
7997              return;
7998            }
7999            didWarnInvalidHydration = true;
8000            error("Expected server HTML to contain a matching <%s> in <%s>.", tag, parentNode.nodeName.toLowerCase());
8001          }
8002        }
8003        function warnForInsertedHydratedText(parentNode, text) {
8004          {
8005            if (text === "") {
8006              return;
8007            }
8008            if (didWarnInvalidHydration) {
8009              return;
8010            }
8011            didWarnInvalidHydration = true;
8012            error('Expected server HTML to contain a matching text node for "%s" in <%s>.', text, parentNode.nodeName.toLowerCase());
8013          }
8014        }
8015        function restoreControlledState$3(domElement, tag, props) {
8016          switch (tag) {
8017            case "input":
8018              restoreControlledState(domElement, props);
8019              return;
8020            case "textarea":
8021              restoreControlledState$2(domElement, props);
8022              return;
8023            case "select":
8024              restoreControlledState$1(domElement, props);
8025              return;
8026          }
8027        }
8028        var validateDOMNesting = function() {
8029        };
8030        var updatedAncestorInfo = function() {
8031        };
8032        {
8033          var specialTags = ["address", "applet", "area", "article", "aside", "base", "basefont", "bgsound", "blockquote", "body", "br", "button", "caption", "center", "col", "colgroup", "dd", "details", "dir", "div", "dl", "dt", "embed", "fieldset", "figcaption", "figure", "footer", "form", "frame", "frameset", "h1", "h2", "h3", "h4", "h5", "h6", "head", "header", "hgroup", "hr", "html", "iframe", "img", "input", "isindex", "li", "link", "listing", "main", "marquee", "menu", "menuitem", "meta", "nav", "noembed", "noframes", "noscript", "object", "ol", "p", "param", "plaintext", "pre", "script", "section", "select", "source", "style", "summary", "table", "tbody", "td", "template", "textarea", "tfoot", "th", "thead", "title", "tr", "track", "ul", "wbr", "xmp"];
8034          var inScopeTags = [
8035            "applet",
8036            "caption",
8037            "html",
8038            "table",
8039            "td",
8040            "th",
8041            "marquee",
8042            "object",
8043            "template",
8044            // https://html.spec.whatwg.org/multipage/syntax.html#html-integration-point
8045            // TODO: Distinguish by namespace here -- for <title>, including it here
8046            // errs on the side of fewer warnings
8047            "foreignObject",
8048            "desc",
8049            "title"
8050          ];
8051          var buttonScopeTags = inScopeTags.concat(["button"]);
8052          var impliedEndTags = ["dd", "dt", "li", "option", "optgroup", "p", "rp", "rt"];
8053          var emptyAncestorInfo = {
8054            current: null,
8055            formTag: null,
8056            aTagInScope: null,
8057            buttonTagInScope: null,
8058            nobrTagInScope: null,
8059            pTagInButtonScope: null,
8060            listItemTagAutoclosing: null,
8061            dlItemTagAutoclosing: null
8062          };
8063          updatedAncestorInfo = function(oldInfo, tag) {
8064            var ancestorInfo = assign({}, oldInfo || emptyAncestorInfo);
8065            var info = {
8066              tag
8067            };
8068            if (inScopeTags.indexOf(tag) !== -1) {
8069              ancestorInfo.aTagInScope = null;
8070              ancestorInfo.buttonTagInScope = null;
8071              ancestorInfo.nobrTagInScope = null;
8072            }
8073            if (buttonScopeTags.indexOf(tag) !== -1) {
8074              ancestorInfo.pTagInButtonScope = null;
8075            }
8076            if (specialTags.indexOf(tag) !== -1 && tag !== "address" && tag !== "div" && tag !== "p") {
8077              ancestorInfo.listItemTagAutoclosing = null;
8078              ancestorInfo.dlItemTagAutoclosing = null;
8079            }
8080            ancestorInfo.current = info;
8081            if (tag === "form") {
8082              ancestorInfo.formTag = info;
8083            }
8084            if (tag === "a") {
8085              ancestorInfo.aTagInScope = info;
8086            }
8087            if (tag === "button") {
8088              ancestorInfo.buttonTagInScope = info;
8089            }
8090            if (tag === "nobr") {
8091              ancestorInfo.nobrTagInScope = info;
8092            }
8093            if (tag === "p") {
8094              ancestorInfo.pTagInButtonScope = info;
8095            }
8096            if (tag === "li") {
8097              ancestorInfo.listItemTagAutoclosing = info;
8098            }
8099            if (tag === "dd" || tag === "dt") {
8100              ancestorInfo.dlItemTagAutoclosing = info;
8101            }
8102            return ancestorInfo;
8103          };
8104          var isTagValidWithParent = function(tag, parentTag) {
8105            switch (parentTag) {
8106              case "select":
8107                return tag === "option" || tag === "optgroup" || tag === "#text";
8108              case "optgroup":
8109                return tag === "option" || tag === "#text";
8110              case "option":
8111                return tag === "#text";
8112              case "tr":
8113                return tag === "th" || tag === "td" || tag === "style" || tag === "script" || tag === "template";
8114              case "tbody":
8115              case "thead":
8116              case "tfoot":
8117                return tag === "tr" || tag === "style" || tag === "script" || tag === "template";
8118              case "colgroup":
8119                return tag === "col" || tag === "template";
8120              case "table":
8121                return tag === "caption" || tag === "colgroup" || tag === "tbody" || tag === "tfoot" || tag === "thead" || tag === "style" || tag === "script" || tag === "template";
8122              case "head":
8123                return tag === "base" || tag === "basefont" || tag === "bgsound" || tag === "link" || tag === "meta" || tag === "title" || tag === "noscript" || tag === "noframes" || tag === "style" || tag === "script" || tag === "template";
8124              case "html":
8125                return tag === "head" || tag === "body" || tag === "frameset";
8126              case "frameset":
8127                return tag === "frame";
8128              case "#document":
8129                return tag === "html";
8130            }
8131            switch (tag) {
8132              case "h1":
8133              case "h2":
8134              case "h3":
8135              case "h4":
8136              case "h5":
8137              case "h6":
8138                return parentTag !== "h1" && parentTag !== "h2" && parentTag !== "h3" && parentTag !== "h4" && parentTag !== "h5" && parentTag !== "h6";
8139              case "rp":
8140              case "rt":
8141                return impliedEndTags.indexOf(parentTag) === -1;
8142              case "body":
8143              case "caption":
8144              case "col":
8145              case "colgroup":
8146              case "frameset":
8147              case "frame":
8148              case "head":
8149              case "html":
8150              case "tbody":
8151              case "td":
8152              case "tfoot":
8153              case "th":
8154              case "thead":
8155              case "tr":
8156                return parentTag == null;
8157            }
8158            return true;
8159          };
8160          var findInvalidAncestorForTag = function(tag, ancestorInfo) {
8161            switch (tag) {
8162              case "address":
8163              case "article":
8164              case "aside":
8165              case "blockquote":
8166              case "center":
8167              case "details":
8168              case "dialog":
8169              case "dir":
8170              case "div":
8171              case "dl":
8172              case "fieldset":
8173              case "figcaption":
8174              case "figure":
8175              case "footer":
8176              case "header":
8177              case "hgroup":
8178              case "main":
8179              case "menu":
8180              case "nav":
8181              case "ol":
8182              case "p":
8183              case "section":
8184              case "summary":
8185              case "ul":
8186              case "pre":
8187              case "listing":
8188              case "table":
8189              case "hr":
8190              case "xmp":
8191              case "h1":
8192              case "h2":
8193              case "h3":
8194              case "h4":
8195              case "h5":
8196              case "h6":
8197                return ancestorInfo.pTagInButtonScope;
8198              case "form":
8199                return ancestorInfo.formTag || ancestorInfo.pTagInButtonScope;
8200              case "li":
8201                return ancestorInfo.listItemTagAutoclosing;
8202              case "dd":
8203              case "dt":
8204                return ancestorInfo.dlItemTagAutoclosing;
8205              case "button":
8206                return ancestorInfo.buttonTagInScope;
8207              case "a":
8208                return ancestorInfo.aTagInScope;
8209              case "nobr":
8210                return ancestorInfo.nobrTagInScope;
8211            }
8212            return null;
8213          };
8214          var didWarn$1 = {};
8215          validateDOMNesting = function(childTag, childText, ancestorInfo) {
8216            ancestorInfo = ancestorInfo || emptyAncestorInfo;
8217            var parentInfo = ancestorInfo.current;
8218            var parentTag = parentInfo && parentInfo.tag;
8219            if (childText != null) {
8220              if (childTag != null) {
8221                error("validateDOMNesting: when childText is passed, childTag should be null");
8222              }
8223              childTag = "#text";
8224            }
8225            var invalidParent = isTagValidWithParent(childTag, parentTag) ? null : parentInfo;
8226            var invalidAncestor = invalidParent ? null : findInvalidAncestorForTag(childTag, ancestorInfo);
8227            var invalidParentOrAncestor = invalidParent || invalidAncestor;
8228            if (!invalidParentOrAncestor) {
8229              return;
8230            }
8231            var ancestorTag = invalidParentOrAncestor.tag;
8232            var warnKey = !!invalidParent + "|" + childTag + "|" + ancestorTag;
8233            if (didWarn$1[warnKey]) {
8234              return;
8235            }
8236            didWarn$1[warnKey] = true;
8237            var tagDisplayName = childTag;
8238            var whitespaceInfo = "";
8239            if (childTag === "#text") {
8240              if (/\S/.test(childText)) {
8241                tagDisplayName = "Text nodes";
8242              } else {
8243                tagDisplayName = "Whitespace text nodes";
8244                whitespaceInfo = " Make sure you don't have any extra whitespace between tags on each line of your source code.";
8245              }
8246            } else {
8247              tagDisplayName = "<" + childTag + ">";
8248            }
8249            if (invalidParent) {
8250              var info = "";
8251              if (ancestorTag === "table" && childTag === "tr") {
8252                info += " Add a <tbody>, <thead> or <tfoot> to your code to match the DOM tree generated by the browser.";
8253              }
8254              error("validateDOMNesting(...): %s cannot appear as a child of <%s>.%s%s", tagDisplayName, ancestorTag, whitespaceInfo, info);
8255            } else {
8256              error("validateDOMNesting(...): %s cannot appear as a descendant of <%s>.", tagDisplayName, ancestorTag);
8257            }
8258          };
8259        }
8260        var SUPPRESS_HYDRATION_WARNING$1 = "suppressHydrationWarning";
8261        var SUSPENSE_START_DATA = "$";
8262        var SUSPENSE_END_DATA = "/$";
8263        var SUSPENSE_PENDING_START_DATA = "$?";
8264        var SUSPENSE_FALLBACK_START_DATA = "$!";
8265        var STYLE$1 = "style";
8266        var eventsEnabled = null;
8267        var selectionInformation = null;
8268        function getRootHostContext(rootContainerInstance) {
8269          var type;
8270          var namespace;
8271          var nodeType = rootContainerInstance.nodeType;
8272          switch (nodeType) {
8273            case DOCUMENT_NODE:
8274            case DOCUMENT_FRAGMENT_NODE: {
8275              type = nodeType === DOCUMENT_NODE ? "#document" : "#fragment";
8276              var root2 = rootContainerInstance.documentElement;
8277              namespace = root2 ? root2.namespaceURI : getChildNamespace(null, "");
8278              break;
8279            }
8280            default: {
8281              var container = nodeType === COMMENT_NODE ? rootContainerInstance.parentNode : rootContainerInstance;
8282              var ownNamespace = container.namespaceURI || null;
8283              type = container.tagName;
8284              namespace = getChildNamespace(ownNamespace, type);
8285              break;
8286            }
8287          }
8288          {
8289            var validatedTag = type.toLowerCase();
8290            var ancestorInfo = updatedAncestorInfo(null, validatedTag);
8291            return {
8292              namespace,
8293              ancestorInfo
8294            };
8295          }
8296        }
8297        function getChildHostContext(parentHostContext, type, rootContainerInstance) {
8298          {
8299            var parentHostContextDev = parentHostContext;
8300            var namespace = getChildNamespace(parentHostContextDev.namespace, type);
8301            var ancestorInfo = updatedAncestorInfo(parentHostContextDev.ancestorInfo, type);
8302            return {
8303              namespace,
8304              ancestorInfo
8305            };
8306          }
8307        }
8308        function getPublicInstance(instance) {
8309          return instance;
8310        }
8311        function prepareForCommit(containerInfo) {
8312          eventsEnabled = isEnabled();
8313          selectionInformation = getSelectionInformation();
8314          var activeInstance = null;
8315          setEnabled(false);
8316          return activeInstance;
8317        }
8318        function resetAfterCommit(containerInfo) {
8319          restoreSelection(selectionInformation);
8320          setEnabled(eventsEnabled);
8321          eventsEnabled = null;
8322          selectionInformation = null;
8323        }
8324        function createInstance(type, props, rootContainerInstance, hostContext, internalInstanceHandle) {
8325          var parentNamespace;
8326          {
8327            var hostContextDev = hostContext;
8328            validateDOMNesting(type, null, hostContextDev.ancestorInfo);
8329            if (typeof props.children === "string" || typeof props.children === "number") {
8330              var string = "" + props.children;
8331              var ownAncestorInfo = updatedAncestorInfo(hostContextDev.ancestorInfo, type);
8332              validateDOMNesting(null, string, ownAncestorInfo);
8333            }
8334            parentNamespace = hostContextDev.namespace;
8335          }
8336          var domElement = createElement(type, props, rootContainerInstance, parentNamespace);
8337          precacheFiberNode(internalInstanceHandle, domElement);
8338          updateFiberProps(domElement, props);
8339          return domElement;
8340        }
8341        function appendInitialChild(parentInstance, child) {
8342          parentInstance.appendChild(child);
8343        }
8344        function finalizeInitialChildren(domElement, type, props, rootContainerInstance, hostContext) {
8345          setInitialProperties(domElement, type, props, rootContainerInstance);
8346          switch (type) {
8347            case "button":
8348            case "input":
8349            case "select":
8350            case "textarea":
8351              return !!props.autoFocus;
8352            case "img":
8353              return true;
8354            default:
8355              return false;
8356          }
8357        }
8358        function prepareUpdate(domElement, type, oldProps, newProps, rootContainerInstance, hostContext) {
8359          {
8360            var hostContextDev = hostContext;
8361            if (typeof newProps.children !== typeof oldProps.children && (typeof newProps.children === "string" || typeof newProps.children === "number")) {
8362              var string = "" + newProps.children;
8363              var ownAncestorInfo = updatedAncestorInfo(hostContextDev.ancestorInfo, type);
8364              validateDOMNesting(null, string, ownAncestorInfo);
8365            }
8366          }
8367          return diffProperties(domElement, type, oldProps, newProps);
8368        }
8369        function shouldSetTextContent(type, props) {
8370          return type === "textarea" || type === "noscript" || typeof props.children === "string" || typeof props.children === "number" || typeof props.dangerouslySetInnerHTML === "object" && props.dangerouslySetInnerHTML !== null && props.dangerouslySetInnerHTML.__html != null;
8371        }
8372        function createTextInstance(text, rootContainerInstance, hostContext, internalInstanceHandle) {
8373          {
8374            var hostContextDev = hostContext;
8375            validateDOMNesting(null, text, hostContextDev.ancestorInfo);
8376          }
8377          var textNode = createTextNode(text, rootContainerInstance);
8378          precacheFiberNode(internalInstanceHandle, textNode);
8379          return textNode;
8380        }
8381        function getCurrentEventPriority() {
8382          var currentEvent = window.event;
8383          if (currentEvent === void 0) {
8384            return DefaultEventPriority;
8385          }
8386          return getEventPriority(currentEvent.type);
8387        }
8388        var scheduleTimeout = typeof setTimeout === "function" ? setTimeout : void 0;
8389        var cancelTimeout = typeof clearTimeout === "function" ? clearTimeout : void 0;
8390        var noTimeout = -1;
8391        var localPromise = typeof Promise === "function" ? Promise : void 0;
8392        var scheduleMicrotask = typeof queueMicrotask === "function" ? queueMicrotask : typeof localPromise !== "undefined" ? function(callback) {
8393          return localPromise.resolve(null).then(callback).catch(handleErrorInNextTick);
8394        } : scheduleTimeout;
8395        function handleErrorInNextTick(error2) {
8396          setTimeout(function() {
8397            throw error2;
8398          });
8399        }
8400        function commitMount(domElement, type, newProps, internalInstanceHandle) {
8401          switch (type) {
8402            case "button":
8403            case "input":
8404            case "select":
8405            case "textarea":
8406              if (newProps.autoFocus) {
8407                domElement.focus();
8408              }
8409              return;
8410            case "img": {
8411              if (newProps.src) {
8412                domElement.src = newProps.src;
8413              }
8414              return;
8415            }
8416          }
8417        }
8418        function commitUpdate(domElement, updatePayload, type, oldProps, newProps, internalInstanceHandle) {
8419          updateProperties(domElement, updatePayload, type, oldProps, newProps);
8420          updateFiberProps(domElement, newProps);
8421        }
8422        function resetTextContent(domElement) {
8423          setTextContent(domElement, "");
8424        }
8425        function commitTextUpdate(textInstance, oldText, newText) {
8426          textInstance.nodeValue = newText;
8427        }
8428        function appendChild(parentInstance, child) {
8429          parentInstance.appendChild(child);
8430        }
8431        function appendChildToContainer(container, child) {
8432          var parentNode;
8433          if (container.nodeType === COMMENT_NODE) {
8434            parentNode = container.parentNode;
8435            parentNode.insertBefore(child, container);
8436          } else {
8437            parentNode = container;
8438            parentNode.appendChild(child);
8439          }
8440          var reactRootContainer = container._reactRootContainer;
8441          if ((reactRootContainer === null || reactRootContainer === void 0) && parentNode.onclick === null) {
8442            trapClickOnNonInteractiveElement(parentNode);
8443          }
8444        }
8445        function insertBefore(parentInstance, child, beforeChild) {
8446          parentInstance.insertBefore(child, beforeChild);
8447        }
8448        function insertInContainerBefore(container, child, beforeChild) {
8449          if (container.nodeType === COMMENT_NODE) {
8450            container.parentNode.insertBefore(child, beforeChild);
8451          } else {
8452            container.insertBefore(child, beforeChild);
8453          }
8454        }
8455        function removeChild(parentInstance, child) {
8456          parentInstance.removeChild(child);
8457        }
8458        function removeChildFromContainer(container, child) {
8459          if (container.nodeType === COMMENT_NODE) {
8460            container.parentNode.removeChild(child);
8461          } else {
8462            container.removeChild(child);
8463          }
8464        }
8465        function clearSuspenseBoundary(parentInstance, suspenseInstance) {
8466          var node = suspenseInstance;
8467          var depth = 0;
8468          do {
8469            var nextNode = node.nextSibling;
8470            parentInstance.removeChild(node);
8471            if (nextNode && nextNode.nodeType === COMMENT_NODE) {
8472              var data = nextNode.data;
8473              if (data === SUSPENSE_END_DATA) {
8474                if (depth === 0) {
8475                  parentInstance.removeChild(nextNode);
8476                  retryIfBlockedOn(suspenseInstance);
8477                  return;
8478                } else {
8479                  depth--;
8480                }
8481              } else if (data === SUSPENSE_START_DATA || data === SUSPENSE_PENDING_START_DATA || data === SUSPENSE_FALLBACK_START_DATA) {
8482                depth++;
8483              }
8484            }
8485            node = nextNode;
8486          } while (node);
8487          retryIfBlockedOn(suspenseInstance);
8488        }
8489        function clearSuspenseBoundaryFromContainer(container, suspenseInstance) {
8490          if (container.nodeType === COMMENT_NODE) {
8491            clearSuspenseBoundary(container.parentNode, suspenseInstance);
8492          } else if (container.nodeType === ELEMENT_NODE) {
8493            clearSuspenseBoundary(container, suspenseInstance);
8494          }
8495          retryIfBlockedOn(container);
8496        }
8497        function hideInstance(instance) {
8498          instance = instance;
8499          var style2 = instance.style;
8500          if (typeof style2.setProperty === "function") {
8501            style2.setProperty("display", "none", "important");
8502          } else {
8503            style2.display = "none";
8504          }
8505        }
8506        function hideTextInstance(textInstance) {
8507          textInstance.nodeValue = "";
8508        }
8509        function unhideInstance(instance, props) {
8510          instance = instance;
8511          var styleProp = props[STYLE$1];
8512          var display = styleProp !== void 0 && styleProp !== null && styleProp.hasOwnProperty("display") ? styleProp.display : null;
8513          instance.style.display = dangerousStyleValue("display", display);
8514        }
8515        function unhideTextInstance(textInstance, text) {
8516          textInstance.nodeValue = text;
8517        }
8518        function clearContainer(container) {
8519          if (container.nodeType === ELEMENT_NODE) {
8520            container.textContent = "";
8521          } else if (container.nodeType === DOCUMENT_NODE) {
8522            if (container.documentElement) {
8523              container.removeChild(container.documentElement);
8524            }
8525          }
8526        }
8527        function canHydrateInstance(instance, type, props) {
8528          if (instance.nodeType !== ELEMENT_NODE || type.toLowerCase() !== instance.nodeName.toLowerCase()) {
8529            return null;
8530          }
8531          return instance;
8532        }
8533        function canHydrateTextInstance(instance, text) {
8534          if (text === "" || instance.nodeType !== TEXT_NODE) {
8535            return null;
8536          }
8537          return instance;
8538        }
8539        function canHydrateSuspenseInstance(instance) {
8540          if (instance.nodeType !== COMMENT_NODE) {
8541            return null;
8542          }
8543          return instance;
8544        }
8545        function isSuspenseInstancePending(instance) {
8546          return instance.data === SUSPENSE_PENDING_START_DATA;
8547        }
8548        function isSuspenseInstanceFallback(instance) {
8549          return instance.data === SUSPENSE_FALLBACK_START_DATA;
8550        }
8551        function getSuspenseInstanceFallbackErrorDetails(instance) {
8552          var dataset = instance.nextSibling && instance.nextSibling.dataset;
8553          var digest, message, stack;
8554          if (dataset) {
8555            digest = dataset.dgst;
8556            {
8557              message = dataset.msg;
8558              stack = dataset.stck;
8559            }
8560          }
8561          {
8562            return {
8563              message,
8564              digest,
8565              stack
8566            };
8567          }
8568        }
8569        function registerSuspenseInstanceRetry(instance, callback) {
8570          instance._reactRetry = callback;
8571        }
8572        function getNextHydratable(node) {
8573          for (; node != null; node = node.nextSibling) {
8574            var nodeType = node.nodeType;
8575            if (nodeType === ELEMENT_NODE || nodeType === TEXT_NODE) {
8576              break;
8577            }
8578            if (nodeType === COMMENT_NODE) {
8579              var nodeData = node.data;
8580              if (nodeData === SUSPENSE_START_DATA || nodeData === SUSPENSE_FALLBACK_START_DATA || nodeData === SUSPENSE_PENDING_START_DATA) {
8581                break;
8582              }
8583              if (nodeData === SUSPENSE_END_DATA) {
8584                return null;
8585              }
8586            }
8587          }
8588          return node;
8589        }
8590        function getNextHydratableSibling(instance) {
8591          return getNextHydratable(instance.nextSibling);
8592        }
8593        function getFirstHydratableChild(parentInstance) {
8594          return getNextHydratable(parentInstance.firstChild);
8595        }
8596        function getFirstHydratableChildWithinContainer(parentContainer) {
8597          return getNextHydratable(parentContainer.firstChild);
8598        }
8599        function getFirstHydratableChildWithinSuspenseInstance(parentInstance) {
8600          return getNextHydratable(parentInstance.nextSibling);
8601        }
8602        function hydrateInstance(instance, type, props, rootContainerInstance, hostContext, internalInstanceHandle, shouldWarnDev) {
8603          precacheFiberNode(internalInstanceHandle, instance);
8604          updateFiberProps(instance, props);
8605          var parentNamespace;
8606          {
8607            var hostContextDev = hostContext;
8608            parentNamespace = hostContextDev.namespace;
8609          }
8610          var isConcurrentMode = (internalInstanceHandle.mode & ConcurrentMode) !== NoMode;
8611          return diffHydratedProperties(instance, type, props, parentNamespace, rootContainerInstance, isConcurrentMode, shouldWarnDev);
8612        }
8613        function hydrateTextInstance(textInstance, text, internalInstanceHandle, shouldWarnDev) {
8614          precacheFiberNode(internalInstanceHandle, textInstance);
8615          var isConcurrentMode = (internalInstanceHandle.mode & ConcurrentMode) !== NoMode;
8616          return diffHydratedText(textInstance, text);
8617        }
8618        function hydrateSuspenseInstance(suspenseInstance, internalInstanceHandle) {
8619          precacheFiberNode(internalInstanceHandle, suspenseInstance);
8620        }
8621        function getNextHydratableInstanceAfterSuspenseInstance(suspenseInstance) {
8622          var node = suspenseInstance.nextSibling;
8623          var depth = 0;
8624          while (node) {
8625            if (node.nodeType === COMMENT_NODE) {
8626              var data = node.data;
8627              if (data === SUSPENSE_END_DATA) {
8628                if (depth === 0) {
8629                  return getNextHydratableSibling(node);
8630                } else {
8631                  depth--;
8632                }
8633              } else if (data === SUSPENSE_START_DATA || data === SUSPENSE_FALLBACK_START_DATA || data === SUSPENSE_PENDING_START_DATA) {
8634                depth++;
8635              }
8636            }
8637            node = node.nextSibling;
8638          }
8639          return null;
8640        }
8641        function getParentSuspenseInstance(targetInstance) {
8642          var node = targetInstance.previousSibling;
8643          var depth = 0;
8644          while (node) {
8645            if (node.nodeType === COMMENT_NODE) {
8646              var data = node.data;
8647              if (data === SUSPENSE_START_DATA || data === SUSPENSE_FALLBACK_START_DATA || data === SUSPENSE_PENDING_START_DATA) {
8648                if (depth === 0) {
8649                  return node;
8650                } else {
8651                  depth--;
8652                }
8653              } else if (data === SUSPENSE_END_DATA) {
8654                depth++;
8655              }
8656            }
8657            node = node.previousSibling;
8658          }
8659          return null;
8660        }
8661        function commitHydratedContainer(container) {
8662          retryIfBlockedOn(container);
8663        }
8664        function commitHydratedSuspenseInstance(suspenseInstance) {
8665          retryIfBlockedOn(suspenseInstance);
8666        }
8667        function shouldDeleteUnhydratedTailInstances(parentType) {
8668          return parentType !== "head" && parentType !== "body";
8669        }
8670        function didNotMatchHydratedContainerTextInstance(parentContainer, textInstance, text, isConcurrentMode) {
8671          var shouldWarnDev = true;
8672          checkForUnmatchedText(textInstance.nodeValue, text, isConcurrentMode, shouldWarnDev);
8673        }
8674        function didNotMatchHydratedTextInstance(parentType, parentProps, parentInstance, textInstance, text, isConcurrentMode) {
8675          if (parentProps[SUPPRESS_HYDRATION_WARNING$1] !== true) {
8676            var shouldWarnDev = true;
8677            checkForUnmatchedText(textInstance.nodeValue, text, isConcurrentMode, shouldWarnDev);
8678          }
8679        }
8680        function didNotHydrateInstanceWithinContainer(parentContainer, instance) {
8681          {
8682            if (instance.nodeType === ELEMENT_NODE) {
8683              warnForDeletedHydratableElement(parentContainer, instance);
8684            } else if (instance.nodeType === COMMENT_NODE) ;
8685            else {
8686              warnForDeletedHydratableText(parentContainer, instance);
8687            }
8688          }
8689        }
8690        function didNotHydrateInstanceWithinSuspenseInstance(parentInstance, instance) {
8691          {
8692            var parentNode = parentInstance.parentNode;
8693            if (parentNode !== null) {
8694              if (instance.nodeType === ELEMENT_NODE) {
8695                warnForDeletedHydratableElement(parentNode, instance);
8696              } else if (instance.nodeType === COMMENT_NODE) ;
8697              else {
8698                warnForDeletedHydratableText(parentNode, instance);
8699              }
8700            }
8701          }
8702        }
8703        function didNotHydrateInstance(parentType, parentProps, parentInstance, instance, isConcurrentMode) {
8704          {
8705            if (isConcurrentMode || parentProps[SUPPRESS_HYDRATION_WARNING$1] !== true) {
8706              if (instance.nodeType === ELEMENT_NODE) {
8707                warnForDeletedHydratableElement(parentInstance, instance);
8708              } else if (instance.nodeType === COMMENT_NODE) ;
8709              else {
8710                warnForDeletedHydratableText(parentInstance, instance);
8711              }
8712            }
8713          }
8714        }
8715        function didNotFindHydratableInstanceWithinContainer(parentContainer, type, props) {
8716          {
8717            warnForInsertedHydratedElement(parentContainer, type);
8718          }
8719        }
8720        function didNotFindHydratableTextInstanceWithinContainer(parentContainer, text) {
8721          {
8722            warnForInsertedHydratedText(parentContainer, text);
8723          }
8724        }
8725        function didNotFindHydratableInstanceWithinSuspenseInstance(parentInstance, type, props) {
8726          {
8727            var parentNode = parentInstance.parentNode;
8728            if (parentNode !== null) warnForInsertedHydratedElement(parentNode, type);
8729          }
8730        }
8731        function didNotFindHydratableTextInstanceWithinSuspenseInstance(parentInstance, text) {
8732          {
8733            var parentNode = parentInstance.parentNode;
8734            if (parentNode !== null) warnForInsertedHydratedText(parentNode, text);
8735          }
8736        }
8737        function didNotFindHydratableInstance(parentType, parentProps, parentInstance, type, props, isConcurrentMode) {
8738          {
8739            if (isConcurrentMode || parentProps[SUPPRESS_HYDRATION_WARNING$1] !== true) {
8740              warnForInsertedHydratedElement(parentInstance, type);
8741            }
8742          }
8743        }
8744        function didNotFindHydratableTextInstance(parentType, parentProps, parentInstance, text, isConcurrentMode) {
8745          {
8746            if (isConcurrentMode || parentProps[SUPPRESS_HYDRATION_WARNING$1] !== true) {
8747              warnForInsertedHydratedText(parentInstance, text);
8748            }
8749          }
8750        }
8751        function errorHydratingContainer(parentContainer) {
8752          {
8753            error("An error occurred during hydration. The server HTML was replaced with client content in <%s>.", parentContainer.nodeName.toLowerCase());
8754          }
8755        }
8756        function preparePortalMount(portalInstance) {
8757          listenToAllSupportedEvents(portalInstance);
8758        }
8759        var randomKey = Math.random().toString(36).slice(2);
8760        var internalInstanceKey = "__reactFiber$" + randomKey;
8761        var internalPropsKey = "__reactProps$" + randomKey;
8762        var internalContainerInstanceKey = "__reactContainer$" + randomKey;
8763        var internalEventHandlersKey = "__reactEvents$" + randomKey;
8764        var internalEventHandlerListenersKey = "__reactListeners$" + randomKey;
8765        var internalEventHandlesSetKey = "__reactHandles$" + randomKey;
8766        function detachDeletedInstance(node) {
8767          delete node[internalInstanceKey];
8768          delete node[internalPropsKey];
8769          delete node[internalEventHandlersKey];
8770          delete node[internalEventHandlerListenersKey];
8771          delete node[internalEventHandlesSetKey];
8772        }
8773        function precacheFiberNode(hostInst, node) {
8774          node[internalInstanceKey] = hostInst;
8775        }
8776        function markContainerAsRoot(hostRoot, node) {
8777          node[internalContainerInstanceKey] = hostRoot;
8778        }
8779        function unmarkContainerAsRoot(node) {
8780          node[internalContainerInstanceKey] = null;
8781        }
8782        function isContainerMarkedAsRoot(node) {
8783          return !!node[internalContainerInstanceKey];
8784        }
8785        function getClosestInstanceFromNode(targetNode) {
8786          var targetInst = targetNode[internalInstanceKey];
8787          if (targetInst) {
8788            return targetInst;
8789          }
8790          var parentNode = targetNode.parentNode;
8791          while (parentNode) {
8792            targetInst = parentNode[internalContainerInstanceKey] || parentNode[internalInstanceKey];
8793            if (targetInst) {
8794              var alternate = targetInst.alternate;
8795              if (targetInst.child !== null || alternate !== null && alternate.child !== null) {
8796                var suspenseInstance = getParentSuspenseInstance(targetNode);
8797                while (suspenseInstance !== null) {
8798                  var targetSuspenseInst = suspenseInstance[internalInstanceKey];
8799                  if (targetSuspenseInst) {
8800                    return targetSuspenseInst;
8801                  }
8802                  suspenseInstance = getParentSuspenseInstance(suspenseInstance);
8803                }
8804              }
8805              return targetInst;
8806            }
8807            targetNode = parentNode;
8808            parentNode = targetNode.parentNode;
8809          }
8810          return null;
8811        }
8812        function getInstanceFromNode(node) {
8813          var inst = node[internalInstanceKey] || node[internalContainerInstanceKey];
8814          if (inst) {
8815            if (inst.tag === HostComponent || inst.tag === HostText || inst.tag === SuspenseComponent || inst.tag === HostRoot) {
8816              return inst;
8817            } else {
8818              return null;
8819            }
8820          }
8821          return null;
8822        }
8823        function getNodeFromInstance(inst) {
8824          if (inst.tag === HostComponent || inst.tag === HostText) {
8825            return inst.stateNode;
8826          }
8827          throw new Error("getNodeFromInstance: Invalid argument.");
8828        }
8829        function getFiberCurrentPropsFromNode(node) {
8830          return node[internalPropsKey] || null;
8831        }
8832        function updateFiberProps(node, props) {
8833          node[internalPropsKey] = props;
8834        }
8835        function getEventListenerSet(node) {
8836          var elementListenerSet = node[internalEventHandlersKey];
8837          if (elementListenerSet === void 0) {
8838            elementListenerSet = node[internalEventHandlersKey] = /* @__PURE__ */ new Set();
8839          }
8840          return elementListenerSet;
8841        }
8842        var loggedTypeFailures = {};
8843        var ReactDebugCurrentFrame$1 = ReactSharedInternals.ReactDebugCurrentFrame;
8844        function setCurrentlyValidatingElement(element) {
8845          {
8846            if (element) {
8847              var owner = element._owner;
8848              var stack = describeUnknownElementTypeFrameInDEV(element.type, element._source, owner ? owner.type : null);
8849              ReactDebugCurrentFrame$1.setExtraStackFrame(stack);
8850            } else {
8851              ReactDebugCurrentFrame$1.setExtraStackFrame(null);
8852            }
8853          }
8854        }
8855        function checkPropTypes(typeSpecs, values, location, componentName, element) {
8856          {
8857            var has2 = Function.call.bind(hasOwnProperty);
8858            for (var typeSpecName in typeSpecs) {
8859              if (has2(typeSpecs, typeSpecName)) {
8860                var error$1 = void 0;
8861                try {
8862                  if (typeof typeSpecs[typeSpecName] !== "function") {
8863                    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`.");
8864                    err.name = "Invariant Violation";
8865                    throw err;
8866                  }
8867                  error$1 = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
8868                } catch (ex) {
8869                  error$1 = ex;
8870                }
8871                if (error$1 && !(error$1 instanceof Error)) {
8872                  setCurrentlyValidatingElement(element);
8873                  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);
8874                  setCurrentlyValidatingElement(null);
8875                }
8876                if (error$1 instanceof Error && !(error$1.message in loggedTypeFailures)) {
8877                  loggedTypeFailures[error$1.message] = true;
8878                  setCurrentlyValidatingElement(element);
8879                  error("Failed %s type: %s", location, error$1.message);
8880                  setCurrentlyValidatingElement(null);
8881                }
8882              }
8883            }
8884          }
8885        }
8886        var valueStack = [];
8887        var fiberStack;
8888        {
8889          fiberStack = [];
8890        }
8891        var index = -1;
8892        function createCursor(defaultValue) {
8893          return {
8894            current: defaultValue
8895          };
8896        }
8897        function pop(cursor, fiber) {
8898          if (index < 0) {
8899            {
8900              error("Unexpected pop.");
8901            }
8902            return;
8903          }
8904          {
8905            if (fiber !== fiberStack[index]) {
8906              error("Unexpected Fiber popped.");
8907            }
8908          }
8909          cursor.current = valueStack[index];
8910          valueStack[index] = null;
8911          {
8912            fiberStack[index] = null;
8913          }
8914          index--;
8915        }
8916        function push(cursor, value, fiber) {
8917          index++;
8918          valueStack[index] = cursor.current;
8919          {
8920            fiberStack[index] = fiber;
8921          }
8922          cursor.current = value;
8923        }
8924        var warnedAboutMissingGetChildContext;
8925        {
8926          warnedAboutMissingGetChildContext = {};
8927        }
8928        var emptyContextObject = {};
8929        {
8930          Object.freeze(emptyContextObject);
8931        }
8932        var contextStackCursor = createCursor(emptyContextObject);
8933        var didPerformWorkStackCursor = createCursor(false);
8934        var previousContext = emptyContextObject;
8935        function getUnmaskedContext(workInProgress2, Component, didPushOwnContextIfProvider) {
8936          {
8937            if (didPushOwnContextIfProvider && isContextProvider(Component)) {
8938              return previousContext;
8939            }
8940            return contextStackCursor.current;
8941          }
8942        }
8943        function cacheContext(workInProgress2, unmaskedContext, maskedContext) {
8944          {
8945            var instance = workInProgress2.stateNode;
8946            instance.__reactInternalMemoizedUnmaskedChildContext = unmaskedContext;
8947            instance.__reactInternalMemoizedMaskedChildContext = maskedContext;
8948          }
8949        }
8950        function getMaskedContext(workInProgress2, unmaskedContext) {
8951          {
8952            var type = workInProgress2.type;
8953            var contextTypes = type.contextTypes;
8954            if (!contextTypes) {
8955              return emptyContextObject;
8956            }
8957            var instance = workInProgress2.stateNode;
8958            if (instance && instance.__reactInternalMemoizedUnmaskedChildContext === unmaskedContext) {
8959              return instance.__reactInternalMemoizedMaskedChildContext;
8960            }
8961            var context = {};
8962            for (var key in contextTypes) {
8963              context[key] = unmaskedContext[key];
8964            }
8965            {
8966              var name = getComponentNameFromFiber(workInProgress2) || "Unknown";
8967              checkPropTypes(contextTypes, context, "context", name);
8968            }
8969            if (instance) {
8970              cacheContext(workInProgress2, unmaskedContext, context);
8971            }
8972            return context;
8973          }
8974        }
8975        function hasContextChanged() {
8976          {
8977            return didPerformWorkStackCursor.current;
8978          }
8979        }
8980        function isContextProvider(type) {
8981          {
8982            var childContextTypes = type.childContextTypes;
8983            return childContextTypes !== null && childContextTypes !== void 0;
8984          }
8985        }
8986        function popContext(fiber) {
8987          {
8988            pop(didPerformWorkStackCursor, fiber);
8989            pop(contextStackCursor, fiber);
8990          }
8991        }
8992        function popTopLevelContextObject(fiber) {
8993          {
8994            pop(didPerformWorkStackCursor, fiber);
8995            pop(contextStackCursor, fiber);
8996          }
8997        }
8998        function pushTopLevelContextObject(fiber, context, didChange) {
8999          {
9000            if (contextStackCursor.current !== emptyContextObject) {
9001              throw new Error("Unexpected context found on stack. This error is likely caused by a bug in React. Please file an issue.");
9002            }
9003            push(contextStackCursor, context, fiber);
9004            push(didPerformWorkStackCursor, didChange, fiber);
9005          }
9006        }
9007        function processChildContext(fiber, type, parentContext) {
9008          {
9009            var instance = fiber.stateNode;
9010            var childContextTypes = type.childContextTypes;
9011            if (typeof instance.getChildContext !== "function") {
9012              {
9013                var componentName = getComponentNameFromFiber(fiber) || "Unknown";
9014                if (!warnedAboutMissingGetChildContext[componentName]) {
9015                  warnedAboutMissingGetChildContext[componentName] = true;
9016                  error("%s.childContextTypes is specified but there is no getChildContext() method on the instance. You can either define getChildContext() on %s or remove childContextTypes from it.", componentName, componentName);
9017                }
9018              }
9019              return parentContext;
9020            }
9021            var childContext = instance.getChildContext();
9022            for (var contextKey in childContext) {
9023              if (!(contextKey in childContextTypes)) {
9024                throw new Error((getComponentNameFromFiber(fiber) || "Unknown") + '.getChildContext(): key "' + contextKey + '" is not defined in childContextTypes.');
9025              }
9026            }
9027            {
9028              var name = getComponentNameFromFiber(fiber) || "Unknown";
9029              checkPropTypes(childContextTypes, childContext, "child context", name);
9030            }
9031            return assign({}, parentContext, childContext);
9032          }
9033        }
9034        function pushContextProvider(workInProgress2) {
9035          {
9036            var instance = workInProgress2.stateNode;
9037            var memoizedMergedChildContext = instance && instance.__reactInternalMemoizedMergedChildContext || emptyContextObject;
9038            previousContext = contextStackCursor.current;
9039            push(contextStackCursor, memoizedMergedChildContext, workInProgress2);
9040            push(didPerformWorkStackCursor, didPerformWorkStackCursor.current, workInProgress2);
9041            return true;
9042          }
9043        }
9044        function invalidateContextProvider(workInProgress2, type, didChange) {
9045          {
9046            var instance = workInProgress2.stateNode;
9047            if (!instance) {
9048              throw new Error("Expected to have an instance by this point. This error is likely caused by a bug in React. Please file an issue.");
9049            }
9050            if (didChange) {
9051              var mergedContext = processChildContext(workInProgress2, type, previousContext);
9052              instance.__reactInternalMemoizedMergedChildContext = mergedContext;
9053              pop(didPerformWorkStackCursor, workInProgress2);
9054              pop(contextStackCursor, workInProgress2);
9055              push(contextStackCursor, mergedContext, workInProgress2);
9056              push(didPerformWorkStackCursor, didChange, workInProgress2);
9057            } else {
9058              pop(didPerformWorkStackCursor, workInProgress2);
9059              push(didPerformWorkStackCursor, didChange, workInProgress2);
9060            }
9061          }
9062        }
9063        function findCurrentUnmaskedContext(fiber) {
9064          {
9065            if (!isFiberMounted(fiber) || fiber.tag !== ClassComponent) {
9066              throw new Error("Expected subtree parent to be a mounted class component. This error is likely caused by a bug in React. Please file an issue.");
9067            }
9068            var node = fiber;
9069            do {
9070              switch (node.tag) {
9071                case HostRoot:
9072                  return node.stateNode.context;
9073                case ClassComponent: {
9074                  var Component = node.type;
9075                  if (isContextProvider(Component)) {
9076                    return node.stateNode.__reactInternalMemoizedMergedChildContext;
9077                  }
9078                  break;
9079                }
9080              }
9081              node = node.return;
9082            } while (node !== null);
9083            throw new Error("Found unexpected detached subtree parent. This error is likely caused by a bug in React. Please file an issue.");
9084          }
9085        }
9086        var LegacyRoot = 0;
9087        var ConcurrentRoot = 1;
9088        var syncQueue = null;
9089        var includesLegacySyncCallbacks = false;
9090        var isFlushingSyncQueue = false;
9091        function scheduleSyncCallback(callback) {
9092          if (syncQueue === null) {
9093            syncQueue = [callback];
9094          } else {
9095            syncQueue.push(callback);
9096          }
9097        }
9098        function scheduleLegacySyncCallback(callback) {
9099          includesLegacySyncCallbacks = true;
9100          scheduleSyncCallback(callback);
9101        }
9102        function flushSyncCallbacksOnlyInLegacyMode() {
9103          if (includesLegacySyncCallbacks) {
9104            flushSyncCallbacks();
9105          }
9106        }
9107        function flushSyncCallbacks() {
9108          if (!isFlushingSyncQueue && syncQueue !== null) {
9109            isFlushingSyncQueue = true;
9110            var i = 0;
9111            var previousUpdatePriority = getCurrentUpdatePriority();
9112            try {
9113              var isSync = true;
9114              var queue = syncQueue;
9115              setCurrentUpdatePriority(DiscreteEventPriority);
9116              for (; i < queue.length; i++) {
9117                var callback = queue[i];
9118                do {
9119                  callback = callback(isSync);
9120                } while (callback !== null);
9121              }
9122              syncQueue = null;
9123              includesLegacySyncCallbacks = false;
9124            } catch (error2) {
9125              if (syncQueue !== null) {
9126                syncQueue = syncQueue.slice(i + 1);
9127              }
9128              scheduleCallback(ImmediatePriority, flushSyncCallbacks);
9129              throw error2;
9130            } finally {
9131              setCurrentUpdatePriority(previousUpdatePriority);
9132              isFlushingSyncQueue = false;
9133            }
9134          }
9135          return null;
9136        }
9137        var forkStack = [];
9138        var forkStackIndex = 0;
9139        var treeForkProvider = null;
9140        var treeForkCount = 0;
9141        var idStack = [];
9142        var idStackIndex = 0;
9143        var treeContextProvider = null;
9144        var treeContextId = 1;
9145        var treeContextOverflow = "";
9146        function isForkedChild(workInProgress2) {
9147          warnIfNotHydrating();
9148          return (workInProgress2.flags & Forked) !== NoFlags;
9149        }
9150        function getForksAtLevel(workInProgress2) {
9151          warnIfNotHydrating();
9152          return treeForkCount;
9153        }
9154        function getTreeId() {
9155          var overflow = treeContextOverflow;
9156          var idWithLeadingBit = treeContextId;
9157          var id = idWithLeadingBit & ~getLeadingBit(idWithLeadingBit);
9158          return id.toString(32) + overflow;
9159        }
9160        function pushTreeFork(workInProgress2, totalChildren) {
9161          warnIfNotHydrating();
9162          forkStack[forkStackIndex++] = treeForkCount;
9163          forkStack[forkStackIndex++] = treeForkProvider;
9164          treeForkProvider = workInProgress2;
9165          treeForkCount = totalChildren;
9166        }
9167        function pushTreeId(workInProgress2, totalChildren, index2) {
9168          warnIfNotHydrating();
9169          idStack[idStackIndex++] = treeContextId;
9170          idStack[idStackIndex++] = treeContextOverflow;
9171          idStack[idStackIndex++] = treeContextProvider;
9172          treeContextProvider = workInProgress2;
9173          var baseIdWithLeadingBit = treeContextId;
9174          var baseOverflow = treeContextOverflow;
9175          var baseLength = getBitLength(baseIdWithLeadingBit) - 1;
9176          var baseId = baseIdWithLeadingBit & ~(1 << baseLength);
9177          var slot = index2 + 1;
9178          var length = getBitLength(totalChildren) + baseLength;
9179          if (length > 30) {
9180            var numberOfOverflowBits = baseLength - baseLength % 5;
9181            var newOverflowBits = (1 << numberOfOverflowBits) - 1;
9182            var newOverflow = (baseId & newOverflowBits).toString(32);
9183            var restOfBaseId = baseId >> numberOfOverflowBits;
9184            var restOfBaseLength = baseLength - numberOfOverflowBits;
9185            var restOfLength = getBitLength(totalChildren) + restOfBaseLength;
9186            var restOfNewBits = slot << restOfBaseLength;
9187            var id = restOfNewBits | restOfBaseId;
9188            var overflow = newOverflow + baseOverflow;
9189            treeContextId = 1 << restOfLength | id;
9190            treeContextOverflow = overflow;
9191          } else {
9192            var newBits = slot << baseLength;
9193            var _id = newBits | baseId;
9194            var _overflow = baseOverflow;
9195            treeContextId = 1 << length | _id;
9196            treeContextOverflow = _overflow;
9197          }
9198        }
9199        function pushMaterializedTreeId(workInProgress2) {
9200          warnIfNotHydrating();
9201          var returnFiber = workInProgress2.return;
9202          if (returnFiber !== null) {
9203            var numberOfForks = 1;
9204            var slotIndex = 0;
9205            pushTreeFork(workInProgress2, numberOfForks);
9206            pushTreeId(workInProgress2, numberOfForks, slotIndex);
9207          }
9208        }
9209        function getBitLength(number) {
9210          return 32 - clz32(number);
9211        }
9212        function getLeadingBit(id) {
9213          return 1 << getBitLength(id) - 1;
9214        }
9215        function popTreeContext(workInProgress2) {
9216          while (workInProgress2 === treeForkProvider) {
9217            treeForkProvider = forkStack[--forkStackIndex];
9218            forkStack[forkStackIndex] = null;
9219            treeForkCount = forkStack[--forkStackIndex];
9220            forkStack[forkStackIndex] = null;
9221          }
9222          while (workInProgress2 === treeContextProvider) {
9223            treeContextProvider = idStack[--idStackIndex];
9224            idStack[idStackIndex] = null;
9225            treeContextOverflow = idStack[--idStackIndex];
9226            idStack[idStackIndex] = null;
9227            treeContextId = idStack[--idStackIndex];
9228            idStack[idStackIndex] = null;
9229          }
9230        }
9231        function getSuspendedTreeContext() {
9232          warnIfNotHydrating();
9233          if (treeContextProvider !== null) {
9234            return {
9235              id: treeContextId,
9236              overflow: treeContextOverflow
9237            };
9238          } else {
9239            return null;
9240          }
9241        }
9242        function restoreSuspendedTreeContext(workInProgress2, suspendedContext) {
9243          warnIfNotHydrating();
9244          idStack[idStackIndex++] = treeContextId;
9245          idStack[idStackIndex++] = treeContextOverflow;
9246          idStack[idStackIndex++] = treeContextProvider;
9247          treeContextId = suspendedContext.id;
9248          treeContextOverflow = suspendedContext.overflow;
9249          treeContextProvider = workInProgress2;
9250        }
9251        function warnIfNotHydrating() {
9252          {
9253            if (!getIsHydrating()) {
9254              error("Expected to be hydrating. This is a bug in React. Please file an issue.");
9255            }
9256          }
9257        }
9258        var hydrationParentFiber = null;
9259        var nextHydratableInstance = null;
9260        var isHydrating = false;
9261        var didSuspendOrErrorDEV = false;
9262        var hydrationErrors = null;
9263        function warnIfHydrating() {
9264          {
9265            if (isHydrating) {
9266              error("We should not be hydrating here. This is a bug in React. Please file a bug.");
9267            }
9268          }
9269        }
9270        function markDidThrowWhileHydratingDEV() {
9271          {
9272            didSuspendOrErrorDEV = true;
9273          }
9274        }
9275        function didSuspendOrErrorWhileHydratingDEV() {
9276          {
9277            return didSuspendOrErrorDEV;
9278          }
9279        }
9280        function enterHydrationState(fiber) {
9281          var parentInstance = fiber.stateNode.containerInfo;
9282          nextHydratableInstance = getFirstHydratableChildWithinContainer(parentInstance);
9283          hydrationParentFiber = fiber;
9284          isHydrating = true;
9285          hydrationErrors = null;
9286          didSuspendOrErrorDEV = false;
9287          return true;
9288        }
9289        function reenterHydrationStateFromDehydratedSuspenseInstance(fiber, suspenseInstance, treeContext) {
9290          nextHydratableInstance = getFirstHydratableChildWithinSuspenseInstance(suspenseInstance);
9291          hydrationParentFiber = fiber;
9292          isHydrating = true;
9293          hydrationErrors = null;
9294          didSuspendOrErrorDEV = false;
9295          if (treeContext !== null) {
9296            restoreSuspendedTreeContext(fiber, treeContext);
9297          }
9298          return true;
9299        }
9300        function warnUnhydratedInstance(returnFiber, instance) {
9301          {
9302            switch (returnFiber.tag) {
9303              case HostRoot: {
9304                didNotHydrateInstanceWithinContainer(returnFiber.stateNode.containerInfo, instance);
9305                break;
9306              }
9307              case HostComponent: {
9308                var isConcurrentMode = (returnFiber.mode & ConcurrentMode) !== NoMode;
9309                didNotHydrateInstance(
9310                  returnFiber.type,
9311                  returnFiber.memoizedProps,
9312                  returnFiber.stateNode,
9313                  instance,
9314                  // TODO: Delete this argument when we remove the legacy root API.
9315                  isConcurrentMode
9316                );
9317                break;
9318              }
9319              case SuspenseComponent: {
9320                var suspenseState = returnFiber.memoizedState;
9321                if (suspenseState.dehydrated !== null) didNotHydrateInstanceWithinSuspenseInstance(suspenseState.dehydrated, instance);
9322                break;
9323              }
9324            }
9325          }
9326        }
9327        function deleteHydratableInstance(returnFiber, instance) {
9328          warnUnhydratedInstance(returnFiber, instance);
9329          var childToDelete = createFiberFromHostInstanceForDeletion();
9330          childToDelete.stateNode = instance;
9331          childToDelete.return = returnFiber;
9332          var deletions = returnFiber.deletions;
9333          if (deletions === null) {
9334            returnFiber.deletions = [childToDelete];
9335            returnFiber.flags |= ChildDeletion;
9336          } else {
9337            deletions.push(childToDelete);
9338          }
9339        }
9340        function warnNonhydratedInstance(returnFiber, fiber) {
9341          {
9342            if (didSuspendOrErrorDEV) {
9343              return;
9344            }
9345            switch (returnFiber.tag) {
9346              case HostRoot: {
9347                var parentContainer = returnFiber.stateNode.containerInfo;
9348                switch (fiber.tag) {
9349                  case HostComponent:
9350                    var type = fiber.type;
9351                    var props = fiber.pendingProps;
9352                    didNotFindHydratableInstanceWithinContainer(parentContainer, type);
9353                    break;
9354                  case HostText:
9355                    var text = fiber.pendingProps;
9356                    didNotFindHydratableTextInstanceWithinContainer(parentContainer, text);
9357                    break;
9358                }
9359                break;
9360              }
9361              case HostComponent: {
9362                var parentType = returnFiber.type;
9363                var parentProps = returnFiber.memoizedProps;
9364                var parentInstance = returnFiber.stateNode;
9365                switch (fiber.tag) {
9366                  case HostComponent: {
9367                    var _type = fiber.type;
9368                    var _props = fiber.pendingProps;
9369                    var isConcurrentMode = (returnFiber.mode & ConcurrentMode) !== NoMode;
9370                    didNotFindHydratableInstance(
9371                      parentType,
9372                      parentProps,
9373                      parentInstance,
9374                      _type,
9375                      _props,
9376                      // TODO: Delete this argument when we remove the legacy root API.
9377                      isConcurrentMode
9378                    );
9379                    break;
9380                  }
9381                  case HostText: {
9382                    var _text = fiber.pendingProps;
9383                    var _isConcurrentMode = (returnFiber.mode & ConcurrentMode) !== NoMode;
9384                    didNotFindHydratableTextInstance(
9385                      parentType,
9386                      parentProps,
9387                      parentInstance,
9388                      _text,
9389                      // TODO: Delete this argument when we remove the legacy root API.
9390                      _isConcurrentMode
9391                    );
9392                    break;
9393                  }
9394                }
9395                break;
9396              }
9397              case SuspenseComponent: {
9398                var suspenseState = returnFiber.memoizedState;
9399                var _parentInstance = suspenseState.dehydrated;
9400                if (_parentInstance !== null) switch (fiber.tag) {
9401                  case HostComponent:
9402                    var _type2 = fiber.type;
9403                    var _props2 = fiber.pendingProps;
9404                    didNotFindHydratableInstanceWithinSuspenseInstance(_parentInstance, _type2);
9405                    break;
9406                  case HostText:
9407                    var _text2 = fiber.pendingProps;
9408                    didNotFindHydratableTextInstanceWithinSuspenseInstance(_parentInstance, _text2);
9409                    break;
9410                }
9411                break;
9412              }
9413              default:
9414                return;
9415            }
9416          }
9417        }
9418        function insertNonHydratedInstance(returnFiber, fiber) {
9419          fiber.flags = fiber.flags & ~Hydrating | Placement;
9420          warnNonhydratedInstance(returnFiber, fiber);
9421        }
9422        function tryHydrate(fiber, nextInstance) {
9423          switch (fiber.tag) {
9424            case HostComponent: {
9425              var type = fiber.type;
9426              var props = fiber.pendingProps;
9427              var instance = canHydrateInstance(nextInstance, type);
9428              if (instance !== null) {
9429                fiber.stateNode = instance;
9430                hydrationParentFiber = fiber;
9431                nextHydratableInstance = getFirstHydratableChild(instance);
9432                return true;
9433              }
9434              return false;
9435            }
9436            case HostText: {
9437              var text = fiber.pendingProps;
9438              var textInstance = canHydrateTextInstance(nextInstance, text);
9439              if (textInstance !== null) {
9440                fiber.stateNode = textInstance;
9441                hydrationParentFiber = fiber;
9442                nextHydratableInstance = null;
9443                return true;
9444              }
9445              return false;
9446            }
9447            case SuspenseComponent: {
9448              var suspenseInstance = canHydrateSuspenseInstance(nextInstance);
9449              if (suspenseInstance !== null) {
9450                var suspenseState = {
9451                  dehydrated: suspenseInstance,
9452                  treeContext: getSuspendedTreeContext(),
9453                  retryLane: OffscreenLane
9454                };
9455                fiber.memoizedState = suspenseState;
9456                var dehydratedFragment = createFiberFromDehydratedFragment(suspenseInstance);
9457                dehydratedFragment.return = fiber;
9458                fiber.child = dehydratedFragment;
9459                hydrationParentFiber = fiber;
9460                nextHydratableInstance = null;
9461                return true;
9462              }
9463              return false;
9464            }
9465            default:
9466              return false;
9467          }
9468        }
9469        function shouldClientRenderOnMismatch(fiber) {
9470          return (fiber.mode & ConcurrentMode) !== NoMode && (fiber.flags & DidCapture) === NoFlags;
9471        }
9472        function throwOnHydrationMismatch(fiber) {
9473          throw new Error("Hydration failed because the initial UI does not match what was rendered on the server.");
9474        }
9475        function tryToClaimNextHydratableInstance(fiber) {
9476          if (!isHydrating) {
9477            return;
9478          }
9479          var nextInstance = nextHydratableInstance;
9480          if (!nextInstance) {
9481            if (shouldClientRenderOnMismatch(fiber)) {
9482              warnNonhydratedInstance(hydrationParentFiber, fiber);
9483              throwOnHydrationMismatch();
9484            }
9485            insertNonHydratedInstance(hydrationParentFiber, fiber);
9486            isHydrating = false;
9487            hydrationParentFiber = fiber;
9488            return;
9489          }
9490          var firstAttemptedInstance = nextInstance;
9491          if (!tryHydrate(fiber, nextInstance)) {
9492            if (shouldClientRenderOnMismatch(fiber)) {
9493              warnNonhydratedInstance(hydrationParentFiber, fiber);
9494              throwOnHydrationMismatch();
9495            }
9496            nextInstance = getNextHydratableSibling(firstAttemptedInstance);
9497            var prevHydrationParentFiber = hydrationParentFiber;
9498            if (!nextInstance || !tryHydrate(fiber, nextInstance)) {
9499              insertNonHydratedInstance(hydrationParentFiber, fiber);
9500              isHydrating = false;
9501              hydrationParentFiber = fiber;
9502              return;
9503            }
9504            deleteHydratableInstance(prevHydrationParentFiber, firstAttemptedInstance);
9505          }
9506        }
9507        function prepareToHydrateHostInstance(fiber, rootContainerInstance, hostContext) {
9508          var instance = fiber.stateNode;
9509          var shouldWarnIfMismatchDev = !didSuspendOrErrorDEV;
9510          var updatePayload = hydrateInstance(instance, fiber.type, fiber.memoizedProps, rootContainerInstance, hostContext, fiber, shouldWarnIfMismatchDev);
9511          fiber.updateQueue = updatePayload;
9512          if (updatePayload !== null) {
9513            return true;
9514          }
9515          return false;
9516        }
9517        function prepareToHydrateHostTextInstance(fiber) {
9518          var textInstance = fiber.stateNode;
9519          var textContent = fiber.memoizedProps;
9520          var shouldUpdate = hydrateTextInstance(textInstance, textContent, fiber);
9521          if (shouldUpdate) {
9522            var returnFiber = hydrationParentFiber;
9523            if (returnFiber !== null) {
9524              switch (returnFiber.tag) {
9525                case HostRoot: {
9526                  var parentContainer = returnFiber.stateNode.containerInfo;
9527                  var isConcurrentMode = (returnFiber.mode & ConcurrentMode) !== NoMode;
9528                  didNotMatchHydratedContainerTextInstance(
9529                    parentContainer,
9530                    textInstance,
9531                    textContent,
9532                    // TODO: Delete this argument when we remove the legacy root API.
9533                    isConcurrentMode
9534                  );
9535                  break;
9536                }
9537                case HostComponent: {
9538                  var parentType = returnFiber.type;
9539                  var parentProps = returnFiber.memoizedProps;
9540                  var parentInstance = returnFiber.stateNode;
9541                  var _isConcurrentMode2 = (returnFiber.mode & ConcurrentMode) !== NoMode;
9542                  didNotMatchHydratedTextInstance(
9543                    parentType,
9544                    parentProps,
9545                    parentInstance,
9546                    textInstance,
9547                    textContent,
9548                    // TODO: Delete this argument when we remove the legacy root API.
9549                    _isConcurrentMode2
9550                  );
9551                  break;
9552                }
9553              }
9554            }
9555          }
9556          return shouldUpdate;
9557        }
9558        function prepareToHydrateHostSuspenseInstance(fiber) {
9559          var suspenseState = fiber.memoizedState;
9560          var suspenseInstance = suspenseState !== null ? suspenseState.dehydrated : null;
9561          if (!suspenseInstance) {
9562            throw new Error("Expected to have a hydrated suspense instance. This error is likely caused by a bug in React. Please file an issue.");
9563          }
9564          hydrateSuspenseInstance(suspenseInstance, fiber);
9565        }
9566        function skipPastDehydratedSuspenseInstance(fiber) {
9567          var suspenseState = fiber.memoizedState;
9568          var suspenseInstance = suspenseState !== null ? suspenseState.dehydrated : null;
9569          if (!suspenseInstance) {
9570            throw new Error("Expected to have a hydrated suspense instance. This error is likely caused by a bug in React. Please file an issue.");
9571          }
9572          return getNextHydratableInstanceAfterSuspenseInstance(suspenseInstance);
9573        }
9574        function popToNextHostParent(fiber) {
9575          var parent = fiber.return;
9576          while (parent !== null && parent.tag !== HostComponent && parent.tag !== HostRoot && parent.tag !== SuspenseComponent) {
9577            parent = parent.return;
9578          }
9579          hydrationParentFiber = parent;
9580        }
9581        function popHydrationState(fiber) {
9582          if (fiber !== hydrationParentFiber) {
9583            return false;
9584          }
9585          if (!isHydrating) {
9586            popToNextHostParent(fiber);
9587            isHydrating = true;
9588            return false;
9589          }
9590          if (fiber.tag !== HostRoot && (fiber.tag !== HostComponent || shouldDeleteUnhydratedTailInstances(fiber.type) && !shouldSetTextContent(fiber.type, fiber.memoizedProps))) {
9591            var nextInstance = nextHydratableInstance;
9592            if (nextInstance) {
9593              if (shouldClientRenderOnMismatch(fiber)) {
9594                warnIfUnhydratedTailNodes(fiber);
9595                throwOnHydrationMismatch();
9596              } else {
9597                while (nextInstance) {
9598                  deleteHydratableInstance(fiber, nextInstance);
9599                  nextInstance = getNextHydratableSibling(nextInstance);
9600                }
9601              }
9602            }
9603          }
9604          popToNextHostParent(fiber);
9605          if (fiber.tag === SuspenseComponent) {
9606            nextHydratableInstance = skipPastDehydratedSuspenseInstance(fiber);
9607          } else {
9608            nextHydratableInstance = hydrationParentFiber ? getNextHydratableSibling(fiber.stateNode) : null;
9609          }
9610          return true;
9611        }
9612        function hasUnhydratedTailNodes() {
9613          return isHydrating && nextHydratableInstance !== null;
9614        }
9615        function warnIfUnhydratedTailNodes(fiber) {
9616          var nextInstance = nextHydratableInstance;
9617          while (nextInstance) {
9618            warnUnhydratedInstance(fiber, nextInstance);
9619            nextInstance = getNextHydratableSibling(nextInstance);
9620          }
9621        }
9622        function resetHydrationState() {
9623          hydrationParentFiber = null;
9624          nextHydratableInstance = null;
9625          isHydrating = false;
9626          didSuspendOrErrorDEV = false;
9627        }
9628        function upgradeHydrationErrorsToRecoverable() {
9629          if (hydrationErrors !== null) {
9630            queueRecoverableErrors(hydrationErrors);
9631            hydrationErrors = null;
9632          }
9633        }
9634        function getIsHydrating() {
9635          return isHydrating;
9636        }
9637        function queueHydrationError(error2) {
9638          if (hydrationErrors === null) {
9639            hydrationErrors = [error2];
9640          } else {
9641            hydrationErrors.push(error2);
9642          }
9643        }
9644        var ReactCurrentBatchConfig$1 = ReactSharedInternals.ReactCurrentBatchConfig;
9645        var NoTransition = null;
9646        function requestCurrentTransition() {
9647          return ReactCurrentBatchConfig$1.transition;
9648        }
9649        var ReactStrictModeWarnings = {
9650          recordUnsafeLifecycleWarnings: function(fiber, instance) {
9651          },
9652          flushPendingUnsafeLifecycleWarnings: function() {
9653          },
9654          recordLegacyContextWarning: function(fiber, instance) {
9655          },
9656          flushLegacyContextWarning: function() {
9657          },
9658          discardPendingWarnings: function() {
9659          }
9660        };
9661        {
9662          var findStrictRoot = function(fiber) {
9663            var maybeStrictRoot = null;
9664            var node = fiber;
9665            while (node !== null) {
9666              if (node.mode & StrictLegacyMode) {
9667                maybeStrictRoot = node;
9668              }
9669              node = node.return;
9670            }
9671            return maybeStrictRoot;
9672          };
9673          var setToSortedString = function(set2) {
9674            var array = [];
9675            set2.forEach(function(value) {
9676              array.push(value);
9677            });
9678            return array.sort().join(", ");
9679          };
9680          var pendingComponentWillMountWarnings = [];
9681          var pendingUNSAFE_ComponentWillMountWarnings = [];
9682          var pendingComponentWillReceivePropsWarnings = [];
9683          var pendingUNSAFE_ComponentWillReceivePropsWarnings = [];
9684          var pendingComponentWillUpdateWarnings = [];
9685          var pendingUNSAFE_ComponentWillUpdateWarnings = [];
9686          var didWarnAboutUnsafeLifecycles = /* @__PURE__ */ new Set();
9687          ReactStrictModeWarnings.recordUnsafeLifecycleWarnings = function(fiber, instance) {
9688            if (didWarnAboutUnsafeLifecycles.has(fiber.type)) {
9689              return;
9690            }
9691            if (typeof instance.componentWillMount === "function" && // Don't warn about react-lifecycles-compat polyfilled components.
9692            instance.componentWillMount.__suppressDeprecationWarning !== true) {
9693              pendingComponentWillMountWarnings.push(fiber);
9694            }
9695            if (fiber.mode & StrictLegacyMode && typeof instance.UNSAFE_componentWillMount === "function") {
9696              pendingUNSAFE_ComponentWillMountWarnings.push(fiber);
9697            }
9698            if (typeof instance.componentWillReceiveProps === "function" && instance.componentWillReceiveProps.__suppressDeprecationWarning !== true) {
9699              pendingComponentWillReceivePropsWarnings.push(fiber);
9700            }
9701            if (fiber.mode & StrictLegacyMode && typeof instance.UNSAFE_componentWillReceiveProps === "function") {
9702              pendingUNSAFE_ComponentWillReceivePropsWarnings.push(fiber);
9703            }
9704            if (typeof instance.componentWillUpdate === "function" && instance.componentWillUpdate.__suppressDeprecationWarning !== true) {
9705              pendingComponentWillUpdateWarnings.push(fiber);
9706            }
9707            if (fiber.mode & StrictLegacyMode && typeof instance.UNSAFE_componentWillUpdate === "function") {
9708              pendingUNSAFE_ComponentWillUpdateWarnings.push(fiber);
9709            }
9710          };
9711          ReactStrictModeWarnings.flushPendingUnsafeLifecycleWarnings = function() {
9712            var componentWillMountUniqueNames = /* @__PURE__ */ new Set();
9713            if (pendingComponentWillMountWarnings.length > 0) {
9714              pendingComponentWillMountWarnings.forEach(function(fiber) {
9715                componentWillMountUniqueNames.add(getComponentNameFromFiber(fiber) || "Component");
9716                didWarnAboutUnsafeLifecycles.add(fiber.type);
9717              });
9718              pendingComponentWillMountWarnings = [];
9719            }
9720            var UNSAFE_componentWillMountUniqueNames = /* @__PURE__ */ new Set();
9721            if (pendingUNSAFE_ComponentWillMountWarnings.length > 0) {
9722              pendingUNSAFE_ComponentWillMountWarnings.forEach(function(fiber) {
9723                UNSAFE_componentWillMountUniqueNames.add(getComponentNameFromFiber(fiber) || "Component");
9724                didWarnAboutUnsafeLifecycles.add(fiber.type);
9725              });
9726              pendingUNSAFE_ComponentWillMountWarnings = [];
9727            }
9728            var componentWillReceivePropsUniqueNames = /* @__PURE__ */ new Set();
9729            if (pendingComponentWillReceivePropsWarnings.length > 0) {
9730              pendingComponentWillReceivePropsWarnings.forEach(function(fiber) {
9731                componentWillReceivePropsUniqueNames.add(getComponentNameFromFiber(fiber) || "Component");
9732                didWarnAboutUnsafeLifecycles.add(fiber.type);
9733              });
9734              pendingComponentWillReceivePropsWarnings = [];
9735            }
9736            var UNSAFE_componentWillReceivePropsUniqueNames = /* @__PURE__ */ new Set();
9737            if (pendingUNSAFE_ComponentWillReceivePropsWarnings.length > 0) {
9738              pendingUNSAFE_ComponentWillReceivePropsWarnings.forEach(function(fiber) {
9739                UNSAFE_componentWillReceivePropsUniqueNames.add(getComponentNameFromFiber(fiber) || "Component");
9740                didWarnAboutUnsafeLifecycles.add(fiber.type);
9741              });
9742              pendingUNSAFE_ComponentWillReceivePropsWarnings = [];
9743            }
9744            var componentWillUpdateUniqueNames = /* @__PURE__ */ new Set();
9745            if (pendingComponentWillUpdateWarnings.length > 0) {
9746              pendingComponentWillUpdateWarnings.forEach(function(fiber) {
9747                componentWillUpdateUniqueNames.add(getComponentNameFromFiber(fiber) || "Component");
9748                didWarnAboutUnsafeLifecycles.add(fiber.type);
9749              });
9750              pendingComponentWillUpdateWarnings = [];
9751            }
9752            var UNSAFE_componentWillUpdateUniqueNames = /* @__PURE__ */ new Set();
9753            if (pendingUNSAFE_ComponentWillUpdateWarnings.length > 0) {
9754              pendingUNSAFE_ComponentWillUpdateWarnings.forEach(function(fiber) {
9755                UNSAFE_componentWillUpdateUniqueNames.add(getComponentNameFromFiber(fiber) || "Component");
9756                didWarnAboutUnsafeLifecycles.add(fiber.type);
9757              });
9758              pendingUNSAFE_ComponentWillUpdateWarnings = [];
9759            }
9760            if (UNSAFE_componentWillMountUniqueNames.size > 0) {
9761              var sortedNames = setToSortedString(UNSAFE_componentWillMountUniqueNames);
9762              error("Using UNSAFE_componentWillMount in strict mode is not recommended and may indicate bugs in your code. See https://reactjs.org/link/unsafe-component-lifecycles for details.\n\n* Move code with side effects to componentDidMount, and set initial state in the constructor.\n\nPlease update the following components: %s", sortedNames);
9763            }
9764            if (UNSAFE_componentWillReceivePropsUniqueNames.size > 0) {
9765              var _sortedNames = setToSortedString(UNSAFE_componentWillReceivePropsUniqueNames);
9766              error("Using UNSAFE_componentWillReceiveProps in strict mode is not recommended and may indicate bugs in your code. See https://reactjs.org/link/unsafe-component-lifecycles for details.\n\n* Move data fetching code or side effects to componentDidUpdate.\n* If you're updating state whenever props change, refactor your code to use memoization techniques or move it to static getDerivedStateFromProps. Learn more at: https://reactjs.org/link/derived-state\n\nPlease update the following components: %s", _sortedNames);
9767            }
9768            if (UNSAFE_componentWillUpdateUniqueNames.size > 0) {
9769              var _sortedNames2 = setToSortedString(UNSAFE_componentWillUpdateUniqueNames);
9770              error("Using UNSAFE_componentWillUpdate in strict mode is not recommended and may indicate bugs in your code. See https://reactjs.org/link/unsafe-component-lifecycles for details.\n\n* Move data fetching code or side effects to componentDidUpdate.\n\nPlease update the following components: %s", _sortedNames2);
9771            }
9772            if (componentWillMountUniqueNames.size > 0) {
9773              var _sortedNames3 = setToSortedString(componentWillMountUniqueNames);
9774              warn("componentWillMount has been renamed, and is not recommended for use. See https://reactjs.org/link/unsafe-component-lifecycles for details.\n\n* Move code with side effects to componentDidMount, and set initial state in the constructor.\n* Rename componentWillMount to UNSAFE_componentWillMount to suppress this warning in non-strict mode. In React 18.x, only the UNSAFE_ name will work. To rename all deprecated lifecycles to their new names, you can run `npx react-codemod rename-unsafe-lifecycles` in your project source folder.\n\nPlease update the following components: %s", _sortedNames3);
9775            }
9776            if (componentWillReceivePropsUniqueNames.size > 0) {
9777              var _sortedNames4 = setToSortedString(componentWillReceivePropsUniqueNames);
9778              warn("componentWillReceiveProps has been renamed, and is not recommended for use. See https://reactjs.org/link/unsafe-component-lifecycles for details.\n\n* Move data fetching code or side effects to componentDidUpdate.\n* If you're updating state whenever props change, refactor your code to use memoization techniques or move it to static getDerivedStateFromProps. Learn more at: https://reactjs.org/link/derived-state\n* Rename componentWillReceiveProps to UNSAFE_componentWillReceiveProps to suppress this warning in non-strict mode. In React 18.x, only the UNSAFE_ name will work. To rename all deprecated lifecycles to their new names, you can run `npx react-codemod rename-unsafe-lifecycles` in your project source folder.\n\nPlease update the following components: %s", _sortedNames4);
9779            }
9780            if (componentWillUpdateUniqueNames.size > 0) {
9781              var _sortedNames5 = setToSortedString(componentWillUpdateUniqueNames);
9782              warn("componentWillUpdate has been renamed, and is not recommended for use. See https://reactjs.org/link/unsafe-component-lifecycles for details.\n\n* Move data fetching code or side effects to componentDidUpdate.\n* Rename componentWillUpdate to UNSAFE_componentWillUpdate to suppress this warning in non-strict mode. In React 18.x, only the UNSAFE_ name will work. To rename all deprecated lifecycles to their new names, you can run `npx react-codemod rename-unsafe-lifecycles` in your project source folder.\n\nPlease update the following components: %s", _sortedNames5);
9783            }
9784          };
9785          var pendingLegacyContextWarning = /* @__PURE__ */ new Map();
9786          var didWarnAboutLegacyContext = /* @__PURE__ */ new Set();
9787          ReactStrictModeWarnings.recordLegacyContextWarning = function(fiber, instance) {
9788            var strictRoot = findStrictRoot(fiber);
9789            if (strictRoot === null) {
9790              error("Expected to find a StrictMode component in a strict mode tree. This error is likely caused by a bug in React. Please file an issue.");
9791              return;
9792            }
9793            if (didWarnAboutLegacyContext.has(fiber.type)) {
9794              return;
9795            }
9796            var warningsForRoot = pendingLegacyContextWarning.get(strictRoot);
9797            if (fiber.type.contextTypes != null || fiber.type.childContextTypes != null || instance !== null && typeof instance.getChildContext === "function") {
9798              if (warningsForRoot === void 0) {
9799                warningsForRoot = [];
9800                pendingLegacyContextWarning.set(strictRoot, warningsForRoot);
9801              }
9802              warningsForRoot.push(fiber);
9803            }
9804          };
9805          ReactStrictModeWarnings.flushLegacyContextWarning = function() {
9806            pendingLegacyContextWarning.forEach(function(fiberArray, strictRoot) {
9807              if (fiberArray.length === 0) {
9808                return;
9809              }
9810              var firstFiber = fiberArray[0];
9811              var uniqueNames = /* @__PURE__ */ new Set();
9812              fiberArray.forEach(function(fiber) {
9813                uniqueNames.add(getComponentNameFromFiber(fiber) || "Component");
9814                didWarnAboutLegacyContext.add(fiber.type);
9815              });
9816              var sortedNames = setToSortedString(uniqueNames);
9817              try {
9818                setCurrentFiber(firstFiber);
9819                error("Legacy context API has been detected within a strict-mode tree.\n\nThe old API will be supported in all 16.x releases, but applications using it should migrate to the new version.\n\nPlease update the following components: %s\n\nLearn more about this warning here: https://reactjs.org/link/legacy-context", sortedNames);
9820              } finally {
9821                resetCurrentFiber();
9822              }
9823            });
9824          };
9825          ReactStrictModeWarnings.discardPendingWarnings = function() {
9826            pendingComponentWillMountWarnings = [];
9827            pendingUNSAFE_ComponentWillMountWarnings = [];
9828            pendingComponentWillReceivePropsWarnings = [];
9829            pendingUNSAFE_ComponentWillReceivePropsWarnings = [];
9830            pendingComponentWillUpdateWarnings = [];
9831            pendingUNSAFE_ComponentWillUpdateWarnings = [];
9832            pendingLegacyContextWarning = /* @__PURE__ */ new Map();
9833          };
9834        }
9835        var didWarnAboutMaps;
9836        var didWarnAboutGenerators;
9837        var didWarnAboutStringRefs;
9838        var ownerHasKeyUseWarning;
9839        var ownerHasFunctionTypeWarning;
9840        var warnForMissingKey = function(child, returnFiber) {
9841        };
9842        {
9843          didWarnAboutMaps = false;
9844          didWarnAboutGenerators = false;
9845          didWarnAboutStringRefs = {};
9846          ownerHasKeyUseWarning = {};
9847          ownerHasFunctionTypeWarning = {};
9848          warnForMissingKey = function(child, returnFiber) {
9849            if (child === null || typeof child !== "object") {
9850              return;
9851            }
9852            if (!child._store || child._store.validated || child.key != null) {
9853              return;
9854            }
9855            if (typeof child._store !== "object") {
9856              throw new Error("React Component in warnForMissingKey should have a _store. This error is likely caused by a bug in React. Please file an issue.");
9857            }
9858            child._store.validated = true;
9859            var componentName = getComponentNameFromFiber(returnFiber) || "Component";
9860            if (ownerHasKeyUseWarning[componentName]) {
9861              return;
9862            }
9863            ownerHasKeyUseWarning[componentName] = true;
9864            error('Each child in a list should have a unique "key" prop. See https://reactjs.org/link/warning-keys for more information.');
9865          };
9866        }
9867        function isReactClass(type) {
9868          return type.prototype && type.prototype.isReactComponent;
9869        }
9870        function coerceRef(returnFiber, current2, element) {
9871          var mixedRef = element.ref;
9872          if (mixedRef !== null && typeof mixedRef !== "function" && typeof mixedRef !== "object") {
9873            {
9874              if ((returnFiber.mode & StrictLegacyMode || warnAboutStringRefs) && // We warn in ReactElement.js if owner and self are equal for string refs
9875              // because these cannot be automatically converted to an arrow function
9876              // using a codemod. Therefore, we don't have to warn about string refs again.
9877              !(element._owner && element._self && element._owner.stateNode !== element._self) && // Will already throw with "Function components cannot have string refs"
9878              !(element._owner && element._owner.tag !== ClassComponent) && // Will already warn with "Function components cannot be given refs"
9879              !(typeof element.type === "function" && !isReactClass(element.type)) && // Will already throw with "Element ref was specified as a string (someStringRef) but no owner was set"
9880              element._owner) {
9881                var componentName = getComponentNameFromFiber(returnFiber) || "Component";
9882                if (!didWarnAboutStringRefs[componentName]) {
9883                  {
9884                    error('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. We recommend using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref', componentName, mixedRef);
9885                  }
9886                  didWarnAboutStringRefs[componentName] = true;
9887                }
9888              }
9889            }
9890            if (element._owner) {
9891              var owner = element._owner;
9892              var inst;
9893              if (owner) {
9894                var ownerFiber = owner;
9895                if (ownerFiber.tag !== ClassComponent) {
9896                  throw new Error("Function components cannot have string refs. We recommend using useRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref");
9897                }
9898                inst = ownerFiber.stateNode;
9899              }
9900              if (!inst) {
9901                throw new Error("Missing owner for string ref " + mixedRef + ". This error is likely caused by a bug in React. Please file an issue.");
9902              }
9903              var resolvedInst = inst;
9904              {
9905                checkPropStringCoercion(mixedRef, "ref");
9906              }
9907              var stringRef = "" + mixedRef;
9908              if (current2 !== null && current2.ref !== null && typeof current2.ref === "function" && current2.ref._stringRef === stringRef) {
9909                return current2.ref;
9910              }
9911              var ref = function(value) {
9912                var refs = resolvedInst.refs;
9913                if (value === null) {
9914                  delete refs[stringRef];
9915                } else {
9916                  refs[stringRef] = value;
9917                }
9918              };
9919              ref._stringRef = stringRef;
9920              return ref;
9921            } else {
9922              if (typeof mixedRef !== "string") {
9923                throw new Error("Expected ref to be a function, a string, an object returned by React.createRef(), or null.");
9924              }
9925              if (!element._owner) {
9926                throw new Error("Element ref was specified as a string (" + mixedRef + ") but no owner was set. This could happen for one of the following reasons:\n1. You may be adding a ref to a function component\n2. You may be adding a ref to a component that was not created inside a component's render method\n3. You have multiple copies of React loaded\nSee https://reactjs.org/link/refs-must-have-owner for more information.");
9927              }
9928            }
9929          }
9930          return mixedRef;
9931        }
9932        function throwOnInvalidObjectType(returnFiber, newChild) {
9933          var childString = Object.prototype.toString.call(newChild);
9934          throw new Error("Objects are not valid as a React child (found: " + (childString === "[object Object]" ? "object with keys {" + Object.keys(newChild).join(", ") + "}" : childString) + "). If you meant to render a collection of children, use an array instead.");
9935        }
9936        function warnOnFunctionType(returnFiber) {
9937          {
9938            var componentName = getComponentNameFromFiber(returnFiber) || "Component";
9939            if (ownerHasFunctionTypeWarning[componentName]) {
9940              return;
9941            }
9942            ownerHasFunctionTypeWarning[componentName] = true;
9943            error("Functions are not valid as a React child. This may happen if you return a Component instead of <Component /> from render. Or maybe you meant to call this function rather than return it.");
9944          }
9945        }
9946        function resolveLazy(lazyType) {
9947          var payload = lazyType._payload;
9948          var init = lazyType._init;
9949          return init(payload);
9950        }
9951        function ChildReconciler(shouldTrackSideEffects) {
9952          function deleteChild(returnFiber, childToDelete) {
9953            if (!shouldTrackSideEffects) {
9954              return;
9955            }
9956            var deletions = returnFiber.deletions;
9957            if (deletions === null) {
9958              returnFiber.deletions = [childToDelete];
9959              returnFiber.flags |= ChildDeletion;
9960            } else {
9961              deletions.push(childToDelete);
9962            }
9963          }
9964          function deleteRemainingChildren(returnFiber, currentFirstChild) {
9965            if (!shouldTrackSideEffects) {
9966              return null;
9967            }
9968            var childToDelete = currentFirstChild;
9969            while (childToDelete !== null) {
9970              deleteChild(returnFiber, childToDelete);
9971              childToDelete = childToDelete.sibling;
9972            }
9973            return null;
9974          }
9975          function mapRemainingChildren(returnFiber, currentFirstChild) {
9976            var existingChildren = /* @__PURE__ */ new Map();
9977            var existingChild = currentFirstChild;
9978            while (existingChild !== null) {
9979              if (existingChild.key !== null) {
9980                existingChildren.set(existingChild.key, existingChild);
9981              } else {
9982                existingChildren.set(existingChild.index, existingChild);
9983              }
9984              existingChild = existingChild.sibling;
9985            }
9986            return existingChildren;
9987          }
9988          function useFiber(fiber, pendingProps) {
9989            var clone = createWorkInProgress(fiber, pendingProps);
9990            clone.index = 0;
9991            clone.sibling = null;
9992            return clone;
9993          }
9994          function placeChild(newFiber, lastPlacedIndex, newIndex) {
9995            newFiber.index = newIndex;
9996            if (!shouldTrackSideEffects) {
9997              newFiber.flags |= Forked;
9998              return lastPlacedIndex;
9999            }
10000            var current2 = newFiber.alternate;
10001            if (current2 !== null) {
10002              var oldIndex = current2.index;
10003              if (oldIndex < lastPlacedIndex) {
10004                newFiber.flags |= Placement;
10005                return lastPlacedIndex;
10006              } else {
10007                return oldIndex;
10008              }
10009            } else {
10010              newFiber.flags |= Placement;
10011              return lastPlacedIndex;
10012            }
10013          }
10014          function placeSingleChild(newFiber) {
10015            if (shouldTrackSideEffects && newFiber.alternate === null) {
10016              newFiber.flags |= Placement;
10017            }
10018            return newFiber;
10019          }
10020          function updateTextNode(returnFiber, current2, textContent, lanes) {
10021            if (current2 === null || current2.tag !== HostText) {
10022              var created = createFiberFromText(textContent, returnFiber.mode, lanes);
10023              created.return = returnFiber;
10024              return created;
10025            } else {
10026              var existing = useFiber(current2, textContent);
10027              existing.return = returnFiber;
10028              return existing;
10029            }
10030          }
10031          function updateElement(returnFiber, current2, element, lanes) {
10032            var elementType = element.type;
10033            if (elementType === REACT_FRAGMENT_TYPE) {
10034              return updateFragment2(returnFiber, current2, element.props.children, lanes, element.key);
10035            }
10036            if (current2 !== null) {
10037              if (current2.elementType === elementType || // Keep this check inline so it only runs on the false path:
10038              isCompatibleFamilyForHotReloading(current2, element) || // Lazy types should reconcile their resolved type.
10039              // We need to do this after the Hot Reloading check above,
10040              // because hot reloading has different semantics than prod because
10041              // it doesn't resuspend. So we can't let the call below suspend.
10042              typeof elementType === "object" && elementType !== null && elementType.$$typeof === REACT_LAZY_TYPE && resolveLazy(elementType) === current2.type) {
10043                var existing = useFiber(current2, element.props);
10044                existing.ref = coerceRef(returnFiber, current2, element);
10045                existing.return = returnFiber;
10046                {
10047                  existing._debugSource = element._source;
10048                  existing._debugOwner = element._owner;
10049                }
10050                return existing;
10051              }
10052            }
10053            var created = createFiberFromElement(element, returnFiber.mode, lanes);
10054            created.ref = coerceRef(returnFiber, current2, element);
10055            created.return = returnFiber;
10056            return created;
10057          }
10058          function updatePortal(returnFiber, current2, portal, lanes) {
10059            if (current2 === null || current2.tag !== HostPortal || current2.stateNode.containerInfo !== portal.containerInfo || current2.stateNode.implementation !== portal.implementation) {
10060              var created = createFiberFromPortal(portal, returnFiber.mode, lanes);
10061              created.return = returnFiber;
10062              return created;
10063            } else {
10064              var existing = useFiber(current2, portal.children || []);
10065              existing.return = returnFiber;
10066              return existing;
10067            }
10068          }
10069          function updateFragment2(returnFiber, current2, fragment, lanes, key) {
10070            if (current2 === null || current2.tag !== Fragment) {
10071              var created = createFiberFromFragment(fragment, returnFiber.mode, lanes, key);
10072              created.return = returnFiber;
10073              return created;
10074            } else {
10075              var existing = useFiber(current2, fragment);
10076              existing.return = returnFiber;
10077              return existing;
10078            }
10079          }
10080          function createChild(returnFiber, newChild, lanes) {
10081            if (typeof newChild === "string" && newChild !== "" || typeof newChild === "number") {
10082              var created = createFiberFromText("" + newChild, returnFiber.mode, lanes);
10083              created.return = returnFiber;
10084              return created;
10085            }
10086            if (typeof newChild === "object" && newChild !== null) {
10087              switch (newChild.$$typeof) {
10088                case REACT_ELEMENT_TYPE: {
10089                  var _created = createFiberFromElement(newChild, returnFiber.mode, lanes);
10090                  _created.ref = coerceRef(returnFiber, null, newChild);
10091                  _created.return = returnFiber;
10092                  return _created;
10093                }
10094                case REACT_PORTAL_TYPE: {
10095                  var _created2 = createFiberFromPortal(newChild, returnFiber.mode, lanes);
10096                  _created2.return = returnFiber;
10097                  return _created2;
10098                }
10099                case REACT_LAZY_TYPE: {
10100                  var payload = newChild._payload;
10101                  var init = newChild._init;
10102                  return createChild(returnFiber, init(payload), lanes);
10103                }
10104              }
10105              if (isArray(newChild) || getIteratorFn(newChild)) {
10106                var _created3 = createFiberFromFragment(newChild, returnFiber.mode, lanes, null);
10107                _created3.return = returnFiber;
10108                return _created3;
10109              }
10110              throwOnInvalidObjectType(returnFiber, newChild);
10111            }
10112            {
10113              if (typeof newChild === "function") {
10114                warnOnFunctionType(returnFiber);
10115              }
10116            }
10117            return null;
10118          }
10119          function updateSlot(returnFiber, oldFiber, newChild, lanes) {
10120            var key = oldFiber !== null ? oldFiber.key : null;
10121            if (typeof newChild === "string" && newChild !== "" || typeof newChild === "number") {
10122              if (key !== null) {
10123                return null;
10124              }
10125              return updateTextNode(returnFiber, oldFiber, "" + newChild, lanes);
10126            }
10127            if (typeof newChild === "object" && newChild !== null) {
10128              switch (newChild.$$typeof) {
10129                case REACT_ELEMENT_TYPE: {
10130                  if (newChild.key === key) {
10131                    return updateElement(returnFiber, oldFiber, newChild, lanes);
10132                  } else {
10133                    return null;
10134                  }
10135                }
10136                case REACT_PORTAL_TYPE: {
10137                  if (newChild.key === key) {
10138                    return updatePortal(returnFiber, oldFiber, newChild, lanes);
10139                  } else {
10140                    return null;
10141                  }
10142                }
10143                case REACT_LAZY_TYPE: {
10144                  var payload = newChild._payload;
10145                  var init = newChild._init;
10146                  return updateSlot(returnFiber, oldFiber, init(payload), lanes);
10147                }
10148              }
10149              if (isArray(newChild) || getIteratorFn(newChild)) {
10150                if (key !== null) {
10151                  return null;
10152                }
10153                return updateFragment2(returnFiber, oldFiber, newChild, lanes, null);
10154              }
10155              throwOnInvalidObjectType(returnFiber, newChild);
10156            }
10157            {
10158              if (typeof newChild === "function") {
10159                warnOnFunctionType(returnFiber);
10160              }
10161            }
10162            return null;
10163          }
10164          function updateFromMap(existingChildren, returnFiber, newIdx, newChild, lanes) {
10165            if (typeof newChild === "string" && newChild !== "" || typeof newChild === "number") {
10166              var matchedFiber = existingChildren.get(newIdx) || null;
10167              return updateTextNode(returnFiber, matchedFiber, "" + newChild, lanes);
10168            }
10169            if (typeof newChild === "object" && newChild !== null) {
10170              switch (newChild.$$typeof) {
10171                case REACT_ELEMENT_TYPE: {
10172                  var _matchedFiber = existingChildren.get(newChild.key === null ? newIdx : newChild.key) || null;
10173                  return updateElement(returnFiber, _matchedFiber, newChild, lanes);
10174                }
10175                case REACT_PORTAL_TYPE: {
10176                  var _matchedFiber2 = existingChildren.get(newChild.key === null ? newIdx : newChild.key) || null;
10177                  return updatePortal(returnFiber, _matchedFiber2, newChild, lanes);
10178                }
10179                case REACT_LAZY_TYPE:
10180                  var payload = newChild._payload;
10181                  var init = newChild._init;
10182                  return updateFromMap(existingChildren, returnFiber, newIdx, init(payload), lanes);
10183              }
10184              if (isArray(newChild) || getIteratorFn(newChild)) {
10185                var _matchedFiber3 = existingChildren.get(newIdx) || null;
10186                return updateFragment2(returnFiber, _matchedFiber3, newChild, lanes, null);
10187              }
10188              throwOnInvalidObjectType(returnFiber, newChild);
10189            }
10190            {
10191              if (typeof newChild === "function") {
10192                warnOnFunctionType(returnFiber);
10193              }
10194            }
10195            return null;
10196          }
10197          function warnOnInvalidKey(child, knownKeys, returnFiber) {
10198            {
10199              if (typeof child !== "object" || child === null) {
10200                return knownKeys;
10201              }
10202              switch (child.$$typeof) {
10203                case REACT_ELEMENT_TYPE:
10204                case REACT_PORTAL_TYPE:
10205                  warnForMissingKey(child, returnFiber);
10206                  var key = child.key;
10207                  if (typeof key !== "string") {
10208                    break;
10209                  }
10210                  if (knownKeys === null) {
10211                    knownKeys = /* @__PURE__ */ new Set();
10212                    knownKeys.add(key);
10213                    break;
10214                  }
10215                  if (!knownKeys.has(key)) {
10216                    knownKeys.add(key);
10217                    break;
10218                  }
10219                  error("Encountered two children with the same key, `%s`. Keys should be unique so that components maintain their identity across updates. Non-unique keys may cause children to be duplicated and/or omitted — the behavior is unsupported and could change in a future version.", key);
10220                  break;
10221                case REACT_LAZY_TYPE:
10222                  var payload = child._payload;
10223                  var init = child._init;
10224                  warnOnInvalidKey(init(payload), knownKeys, returnFiber);
10225                  break;
10226              }
10227            }
10228            return knownKeys;
10229          }
10230          function reconcileChildrenArray(returnFiber, currentFirstChild, newChildren, lanes) {
10231            {
10232              var knownKeys = null;
10233              for (var i = 0; i < newChildren.length; i++) {
10234                var child = newChildren[i];
10235                knownKeys = warnOnInvalidKey(child, knownKeys, returnFiber);
10236              }
10237            }
10238            var resultingFirstChild = null;
10239            var previousNewFiber = null;
10240            var oldFiber = currentFirstChild;
10241            var lastPlacedIndex = 0;
10242            var newIdx = 0;
10243            var nextOldFiber = null;
10244            for (; oldFiber !== null && newIdx < newChildren.length; newIdx++) {
10245              if (oldFiber.index > newIdx) {
10246                nextOldFiber = oldFiber;
10247                oldFiber = null;
10248              } else {
10249                nextOldFiber = oldFiber.sibling;
10250              }
10251              var newFiber = updateSlot(returnFiber, oldFiber, newChildren[newIdx], lanes);
10252              if (newFiber === null) {
10253                if (oldFiber === null) {
10254                  oldFiber = nextOldFiber;
10255                }
10256                break;
10257              }
10258              if (shouldTrackSideEffects) {
10259                if (oldFiber && newFiber.alternate === null) {
10260                  deleteChild(returnFiber, oldFiber);
10261                }
10262              }
10263              lastPlacedIndex = placeChild(newFiber, lastPlacedIndex, newIdx);
10264              if (previousNewFiber === null) {
10265                resultingFirstChild = newFiber;
10266              } else {
10267                previousNewFiber.sibling = newFiber;
10268              }
10269              previousNewFiber = newFiber;
10270              oldFiber = nextOldFiber;
10271            }
10272            if (newIdx === newChildren.length) {
10273              deleteRemainingChildren(returnFiber, oldFiber);
10274              if (getIsHydrating()) {
10275                var numberOfForks = newIdx;
10276                pushTreeFork(returnFiber, numberOfForks);
10277              }
10278              return resultingFirstChild;
10279            }
10280            if (oldFiber === null) {
10281              for (; newIdx < newChildren.length; newIdx++) {
10282                var _newFiber = createChild(returnFiber, newChildren[newIdx], lanes);
10283                if (_newFiber === null) {
10284                  continue;
10285                }
10286                lastPlacedIndex = placeChild(_newFiber, lastPlacedIndex, newIdx);
10287                if (previousNewFiber === null) {
10288                  resultingFirstChild = _newFiber;
10289                } else {
10290                  previousNewFiber.sibling = _newFiber;
10291                }
10292                previousNewFiber = _newFiber;
10293              }
10294              if (getIsHydrating()) {
10295                var _numberOfForks = newIdx;
10296                pushTreeFork(returnFiber, _numberOfForks);
10297              }
10298              return resultingFirstChild;
10299            }
10300            var existingChildren = mapRemainingChildren(returnFiber, oldFiber);
10301            for (; newIdx < newChildren.length; newIdx++) {
10302              var _newFiber2 = updateFromMap(existingChildren, returnFiber, newIdx, newChildren[newIdx], lanes);
10303              if (_newFiber2 !== null) {
10304                if (shouldTrackSideEffects) {
10305                  if (_newFiber2.alternate !== null) {
10306                    existingChildren.delete(_newFiber2.key === null ? newIdx : _newFiber2.key);
10307                  }
10308                }
10309                lastPlacedIndex = placeChild(_newFiber2, lastPlacedIndex, newIdx);
10310                if (previousNewFiber === null) {
10311                  resultingFirstChild = _newFiber2;
10312                } else {
10313                  previousNewFiber.sibling = _newFiber2;
10314                }
10315                previousNewFiber = _newFiber2;
10316              }
10317            }
10318            if (shouldTrackSideEffects) {
10319              existingChildren.forEach(function(child2) {
10320                return deleteChild(returnFiber, child2);
10321              });
10322            }
10323            if (getIsHydrating()) {
10324              var _numberOfForks2 = newIdx;
10325              pushTreeFork(returnFiber, _numberOfForks2);
10326            }
10327            return resultingFirstChild;
10328          }
10329          function reconcileChildrenIterator(returnFiber, currentFirstChild, newChildrenIterable, lanes) {
10330            var iteratorFn = getIteratorFn(newChildrenIterable);
10331            if (typeof iteratorFn !== "function") {
10332              throw new Error("An object is not an iterable. This error is likely caused by a bug in React. Please file an issue.");
10333            }
10334            {
10335              if (typeof Symbol === "function" && // $FlowFixMe Flow doesn't know about toStringTag
10336              newChildrenIterable[Symbol.toStringTag] === "Generator") {
10337                if (!didWarnAboutGenerators) {
10338                  error("Using Generators as children is unsupported and will likely yield unexpected results because enumerating a generator mutates it. You may convert it to an array with `Array.from()` or the `[...spread]` operator before rendering. Keep in mind you might need to polyfill these features for older browsers.");
10339                }
10340                didWarnAboutGenerators = true;
10341              }
10342              if (newChildrenIterable.entries === iteratorFn) {
10343                if (!didWarnAboutMaps) {
10344                  error("Using Maps as children is not supported. Use an array of keyed ReactElements instead.");
10345                }
10346                didWarnAboutMaps = true;
10347              }
10348              var _newChildren = iteratorFn.call(newChildrenIterable);
10349              if (_newChildren) {
10350                var knownKeys = null;
10351                var _step = _newChildren.next();
10352                for (; !_step.done; _step = _newChildren.next()) {
10353                  var child = _step.value;
10354                  knownKeys = warnOnInvalidKey(child, knownKeys, returnFiber);
10355                }
10356              }
10357            }
10358            var newChildren = iteratorFn.call(newChildrenIterable);
10359            if (newChildren == null) {
10360              throw new Error("An iterable object provided no iterator.");
10361            }
10362            var resultingFirstChild = null;
10363            var previousNewFiber = null;
10364            var oldFiber = currentFirstChild;
10365            var lastPlacedIndex = 0;
10366            var newIdx = 0;
10367            var nextOldFiber = null;
10368            var step = newChildren.next();
10369            for (; oldFiber !== null && !step.done; newIdx++, step = newChildren.next()) {
10370              if (oldFiber.index > newIdx) {
10371                nextOldFiber = oldFiber;
10372                oldFiber = null;
10373              } else {
10374                nextOldFiber = oldFiber.sibling;
10375              }
10376              var newFiber = updateSlot(returnFiber, oldFiber, step.value, lanes);
10377              if (newFiber === null) {
10378                if (oldFiber === null) {
10379                  oldFiber = nextOldFiber;
10380                }
10381                break;
10382              }
10383              if (shouldTrackSideEffects) {
10384                if (oldFiber && newFiber.alternate === null) {
10385                  deleteChild(returnFiber, oldFiber);
10386                }
10387              }
10388              lastPlacedIndex = placeChild(newFiber, lastPlacedIndex, newIdx);
10389              if (previousNewFiber === null) {
10390                resultingFirstChild = newFiber;
10391              } else {
10392                previousNewFiber.sibling = newFiber;
10393              }
10394              previousNewFiber = newFiber;
10395              oldFiber = nextOldFiber;
10396            }
10397            if (step.done) {
10398              deleteRemainingChildren(returnFiber, oldFiber);
10399              if (getIsHydrating()) {
10400                var numberOfForks = newIdx;
10401                pushTreeFork(returnFiber, numberOfForks);
10402              }
10403              return resultingFirstChild;
10404            }
10405            if (oldFiber === null) {
10406              for (; !step.done; newIdx++, step = newChildren.next()) {
10407                var _newFiber3 = createChild(returnFiber, step.value, lanes);
10408                if (_newFiber3 === null) {
10409                  continue;
10410                }
10411                lastPlacedIndex = placeChild(_newFiber3, lastPlacedIndex, newIdx);
10412                if (previousNewFiber === null) {
10413                  resultingFirstChild = _newFiber3;
10414                } else {
10415                  previousNewFiber.sibling = _newFiber3;
10416                }
10417                previousNewFiber = _newFiber3;
10418              }
10419              if (getIsHydrating()) {
10420                var _numberOfForks3 = newIdx;
10421                pushTreeFork(returnFiber, _numberOfForks3);
10422              }
10423              return resultingFirstChild;
10424            }
10425            var existingChildren = mapRemainingChildren(returnFiber, oldFiber);
10426            for (; !step.done; newIdx++, step = newChildren.next()) {
10427              var _newFiber4 = updateFromMap(existingChildren, returnFiber, newIdx, step.value, lanes);
10428              if (_newFiber4 !== null) {
10429                if (shouldTrackSideEffects) {
10430                  if (_newFiber4.alternate !== null) {
10431                    existingChildren.delete(_newFiber4.key === null ? newIdx : _newFiber4.key);
10432                  }
10433                }
10434                lastPlacedIndex = placeChild(_newFiber4, lastPlacedIndex, newIdx);
10435                if (previousNewFiber === null) {
10436                  resultingFirstChild = _newFiber4;
10437                } else {
10438                  previousNewFiber.sibling = _newFiber4;
10439                }
10440                previousNewFiber = _newFiber4;
10441              }
10442            }
10443            if (shouldTrackSideEffects) {
10444              existingChildren.forEach(function(child2) {
10445                return deleteChild(returnFiber, child2);
10446              });
10447            }
10448            if (getIsHydrating()) {
10449              var _numberOfForks4 = newIdx;
10450              pushTreeFork(returnFiber, _numberOfForks4);
10451            }
10452            return resultingFirstChild;
10453          }
10454          function reconcileSingleTextNode(returnFiber, currentFirstChild, textContent, lanes) {
10455            if (currentFirstChild !== null && currentFirstChild.tag === HostText) {
10456              deleteRemainingChildren(returnFiber, currentFirstChild.sibling);
10457              var existing = useFiber(currentFirstChild, textContent);
10458              existing.return = returnFiber;
10459              return existing;
10460            }
10461            deleteRemainingChildren(returnFiber, currentFirstChild);
10462            var created = createFiberFromText(textContent, returnFiber.mode, lanes);
10463            created.return = returnFiber;
10464            return created;
10465          }
10466          function reconcileSingleElement(returnFiber, currentFirstChild, element, lanes) {
10467            var key = element.key;
10468            var child = currentFirstChild;
10469            while (child !== null) {
10470              if (child.key === key) {
10471                var elementType = element.type;
10472                if (elementType === REACT_FRAGMENT_TYPE) {
10473                  if (child.tag === Fragment) {
10474                    deleteRemainingChildren(returnFiber, child.sibling);
10475                    var existing = useFiber(child, element.props.children);
10476                    existing.return = returnFiber;
10477                    {
10478                      existing._debugSource = element._source;
10479                      existing._debugOwner = element._owner;
10480                    }
10481                    return existing;
10482                  }
10483                } else {
10484                  if (child.elementType === elementType || // Keep this check inline so it only runs on the false path:
10485                  isCompatibleFamilyForHotReloading(child, element) || // Lazy types should reconcile their resolved type.
10486                  // We need to do this after the Hot Reloading check above,
10487                  // because hot reloading has different semantics than prod because
10488                  // it doesn't resuspend. So we can't let the call below suspend.
10489                  typeof elementType === "object" && elementType !== null && elementType.$$typeof === REACT_LAZY_TYPE && resolveLazy(elementType) === child.type) {
10490                    deleteRemainingChildren(returnFiber, child.sibling);
10491                    var _existing = useFiber(child, element.props);
10492                    _existing.ref = coerceRef(returnFiber, child, element);
10493                    _existing.return = returnFiber;
10494                    {
10495                      _existing._debugSource = element._source;
10496                      _existing._debugOwner = element._owner;
10497                    }
10498                    return _existing;
10499                  }
10500                }
10501                deleteRemainingChildren(returnFiber, child);
10502                break;
10503              } else {
10504                deleteChild(returnFiber, child);
10505              }
10506              child = child.sibling;
10507            }
10508            if (element.type === REACT_FRAGMENT_TYPE) {
10509              var created = createFiberFromFragment(element.props.children, returnFiber.mode, lanes, element.key);
10510              created.return = returnFiber;
10511              return created;
10512            } else {
10513              var _created4 = createFiberFromElement(element, returnFiber.mode, lanes);
10514              _created4.ref = coerceRef(returnFiber, currentFirstChild, element);
10515              _created4.return = returnFiber;
10516              return _created4;
10517            }
10518          }
10519          function reconcileSinglePortal(returnFiber, currentFirstChild, portal, lanes) {
10520            var key = portal.key;
10521            var child = currentFirstChild;
10522            while (child !== null) {
10523              if (child.key === key) {
10524                if (child.tag === HostPortal && child.stateNode.containerInfo === portal.containerInfo && child.stateNode.implementation === portal.implementation) {
10525                  deleteRemainingChildren(returnFiber, child.sibling);
10526                  var existing = useFiber(child, portal.children || []);
10527                  existing.return = returnFiber;
10528                  return existing;
10529                } else {
10530                  deleteRemainingChildren(returnFiber, child);
10531                  break;
10532                }
10533              } else {
10534                deleteChild(returnFiber, child);
10535              }
10536              child = child.sibling;
10537            }
10538            var created = createFiberFromPortal(portal, returnFiber.mode, lanes);
10539            created.return = returnFiber;
10540            return created;
10541          }
10542          function reconcileChildFibers2(returnFiber, currentFirstChild, newChild, lanes) {
10543            var isUnkeyedTopLevelFragment = typeof newChild === "object" && newChild !== null && newChild.type === REACT_FRAGMENT_TYPE && newChild.key === null;
10544            if (isUnkeyedTopLevelFragment) {
10545              newChild = newChild.props.children;
10546            }
10547            if (typeof newChild === "object" && newChild !== null) {
10548              switch (newChild.$$typeof) {
10549                case REACT_ELEMENT_TYPE:
10550                  return placeSingleChild(reconcileSingleElement(returnFiber, currentFirstChild, newChild, lanes));
10551                case REACT_PORTAL_TYPE:
10552                  return placeSingleChild(reconcileSinglePortal(returnFiber, currentFirstChild, newChild, lanes));
10553                case REACT_LAZY_TYPE:
10554                  var payload = newChild._payload;
10555                  var init = newChild._init;
10556                  return reconcileChildFibers2(returnFiber, currentFirstChild, init(payload), lanes);
10557              }
10558              if (isArray(newChild)) {
10559                return reconcileChildrenArray(returnFiber, currentFirstChild, newChild, lanes);
10560              }
10561              if (getIteratorFn(newChild)) {
10562                return reconcileChildrenIterator(returnFiber, currentFirstChild, newChild, lanes);
10563              }
10564              throwOnInvalidObjectType(returnFiber, newChild);
10565            }
10566            if (typeof newChild === "string" && newChild !== "" || typeof newChild === "number") {
10567              return placeSingleChild(reconcileSingleTextNode(returnFiber, currentFirstChild, "" + newChild, lanes));
10568            }
10569            {
10570              if (typeof newChild === "function") {
10571                warnOnFunctionType(returnFiber);
10572              }
10573            }
10574            return deleteRemainingChildren(returnFiber, currentFirstChild);
10575          }
10576          return reconcileChildFibers2;
10577        }
10578        var reconcileChildFibers = ChildReconciler(true);
10579        var mountChildFibers = ChildReconciler(false);
10580        function cloneChildFibers(current2, workInProgress2) {
10581          if (current2 !== null && workInProgress2.child !== current2.child) {
10582            throw new Error("Resuming work not yet implemented.");
10583          }
10584          if (workInProgress2.child === null) {
10585            return;
10586          }
10587          var currentChild = workInProgress2.child;
10588          var newChild = createWorkInProgress(currentChild, currentChild.pendingProps);
10589          workInProgress2.child = newChild;
10590          newChild.return = workInProgress2;
10591          while (currentChild.sibling !== null) {
10592            currentChild = currentChild.sibling;
10593            newChild = newChild.sibling = createWorkInProgress(currentChild, currentChild.pendingProps);
10594            newChild.return = workInProgress2;
10595          }
10596          newChild.sibling = null;
10597        }
10598        function resetChildFibers(workInProgress2, lanes) {
10599          var child = workInProgress2.child;
10600          while (child !== null) {
10601            resetWorkInProgress(child, lanes);
10602            child = child.sibling;
10603          }
10604        }
10605        var valueCursor = createCursor(null);
10606        var rendererSigil;
10607        {
10608          rendererSigil = {};
10609        }
10610        var currentlyRenderingFiber = null;
10611        var lastContextDependency = null;
10612        var lastFullyObservedContext = null;
10613        var isDisallowedContextReadInDEV = false;
10614        function resetContextDependencies() {
10615          currentlyRenderingFiber = null;
10616          lastContextDependency = null;
10617          lastFullyObservedContext = null;
10618          {
10619            isDisallowedContextReadInDEV = false;
10620          }
10621        }
10622        function enterDisallowedContextReadInDEV() {
10623          {
10624            isDisallowedContextReadInDEV = true;
10625          }
10626        }
10627        function exitDisallowedContextReadInDEV() {
10628          {
10629            isDisallowedContextReadInDEV = false;
10630          }
10631        }
10632        function pushProvider(providerFiber, context, nextValue) {
10633          {
10634            push(valueCursor, context._currentValue, providerFiber);
10635            context._currentValue = nextValue;
10636            {
10637              if (context._currentRenderer !== void 0 && context._currentRenderer !== null && context._currentRenderer !== rendererSigil) {
10638                error("Detected multiple renderers concurrently rendering the same context provider. This is currently unsupported.");
10639              }
10640              context._currentRenderer = rendererSigil;
10641            }
10642          }
10643        }
10644        function popProvider(context, providerFiber) {
10645          var currentValue = valueCursor.current;
10646          pop(valueCursor, providerFiber);
10647          {
10648            {
10649              context._currentValue = currentValue;
10650            }
10651          }
10652        }
10653        function scheduleContextWorkOnParentPath(parent, renderLanes2, propagationRoot) {
10654          var node = parent;
10655          while (node !== null) {
10656            var alternate = node.alternate;
10657            if (!isSubsetOfLanes(node.childLanes, renderLanes2)) {
10658              node.childLanes = mergeLanes(node.childLanes, renderLanes2);
10659              if (alternate !== null) {
10660                alternate.childLanes = mergeLanes(alternate.childLanes, renderLanes2);
10661              }
10662            } else if (alternate !== null && !isSubsetOfLanes(alternate.childLanes, renderLanes2)) {
10663              alternate.childLanes = mergeLanes(alternate.childLanes, renderLanes2);
10664            }
10665            if (node === propagationRoot) {
10666              break;
10667            }
10668            node = node.return;
10669          }
10670          {
10671            if (node !== propagationRoot) {
10672              error("Expected to find the propagation root when scheduling context work. This error is likely caused by a bug in React. Please file an issue.");
10673            }
10674          }
10675        }
10676        function propagateContextChange(workInProgress2, context, renderLanes2) {
10677          {
10678            propagateContextChange_eager(workInProgress2, context, renderLanes2);
10679          }
10680        }
10681        function propagateContextChange_eager(workInProgress2, context, renderLanes2) {
10682          var fiber = workInProgress2.child;
10683          if (fiber !== null) {
10684            fiber.return = workInProgress2;
10685          }
10686          while (fiber !== null) {
10687            var nextFiber = void 0;
10688            var list = fiber.dependencies;
10689            if (list !== null) {
10690              nextFiber = fiber.child;
10691              var dependency = list.firstContext;
10692              while (dependency !== null) {
10693                if (dependency.context === context) {
10694                  if (fiber.tag === ClassComponent) {
10695                    var lane = pickArbitraryLane(renderLanes2);
10696                    var update = createUpdate(NoTimestamp, lane);
10697                    update.tag = ForceUpdate;
10698                    var updateQueue = fiber.updateQueue;
10699                    if (updateQueue === null) ;
10700                    else {
10701                      var sharedQueue = updateQueue.shared;
10702                      var pending = sharedQueue.pending;
10703                      if (pending === null) {
10704                        update.next = update;
10705                      } else {
10706                        update.next = pending.next;
10707                        pending.next = update;
10708                      }
10709                      sharedQueue.pending = update;
10710                    }
10711                  }
10712                  fiber.lanes = mergeLanes(fiber.lanes, renderLanes2);
10713                  var alternate = fiber.alternate;
10714                  if (alternate !== null) {
10715                    alternate.lanes = mergeLanes(alternate.lanes, renderLanes2);
10716                  }
10717                  scheduleContextWorkOnParentPath(fiber.return, renderLanes2, workInProgress2);
10718                  list.lanes = mergeLanes(list.lanes, renderLanes2);
10719                  break;
10720                }
10721                dependency = dependency.next;
10722              }
10723            } else if (fiber.tag === ContextProvider) {
10724              nextFiber = fiber.type === workInProgress2.type ? null : fiber.child;
10725            } else if (fiber.tag === DehydratedFragment) {
10726              var parentSuspense = fiber.return;
10727              if (parentSuspense === null) {
10728                throw new Error("We just came from a parent so we must have had a parent. This is a bug in React.");
10729              }
10730              parentSuspense.lanes = mergeLanes(parentSuspense.lanes, renderLanes2);
10731              var _alternate = parentSuspense.alternate;
10732              if (_alternate !== null) {
10733                _alternate.lanes = mergeLanes(_alternate.lanes, renderLanes2);
10734              }
10735              scheduleContextWorkOnParentPath(parentSuspense, renderLanes2, workInProgress2);
10736              nextFiber = fiber.sibling;
10737            } else {
10738              nextFiber = fiber.child;
10739            }
10740            if (nextFiber !== null) {
10741              nextFiber.return = fiber;
10742            } else {
10743              nextFiber = fiber;
10744              while (nextFiber !== null) {
10745                if (nextFiber === workInProgress2) {
10746                  nextFiber = null;
10747                  break;
10748                }
10749                var sibling = nextFiber.sibling;
10750                if (sibling !== null) {
10751                  sibling.return = nextFiber.return;
10752                  nextFiber = sibling;
10753                  break;
10754                }
10755                nextFiber = nextFiber.return;
10756              }
10757            }
10758            fiber = nextFiber;
10759          }
10760        }
10761        function prepareToReadContext(workInProgress2, renderLanes2) {
10762          currentlyRenderingFiber = workInProgress2;
10763          lastContextDependency = null;
10764          lastFullyObservedContext = null;
10765          var dependencies = workInProgress2.dependencies;
10766          if (dependencies !== null) {
10767            {
10768              var firstContext = dependencies.firstContext;
10769              if (firstContext !== null) {
10770                if (includesSomeLane(dependencies.lanes, renderLanes2)) {
10771                  markWorkInProgressReceivedUpdate();
10772                }
10773                dependencies.firstContext = null;
10774              }
10775            }
10776          }
10777        }
10778        function readContext(context) {
10779          {
10780            if (isDisallowedContextReadInDEV) {
10781              error("Context can only be read while React is rendering. In classes, you can read it in the render method or getDerivedStateFromProps. In function components, you can read it directly in the function body, but not inside Hooks like useReducer() or useMemo().");
10782            }
10783          }
10784          var value = context._currentValue;
10785          if (lastFullyObservedContext === context) ;
10786          else {
10787            var contextItem = {
10788              context,
10789              memoizedValue: value,
10790              next: null
10791            };
10792            if (lastContextDependency === null) {
10793              if (currentlyRenderingFiber === null) {
10794                throw new Error("Context can only be read while React is rendering. In classes, you can read it in the render method or getDerivedStateFromProps. In function components, you can read it directly in the function body, but not inside Hooks like useReducer() or useMemo().");
10795              }
10796              lastContextDependency = contextItem;
10797              currentlyRenderingFiber.dependencies = {
10798                lanes: NoLanes,
10799                firstContext: contextItem
10800              };
10801            } else {
10802              lastContextDependency = lastContextDependency.next = contextItem;
10803            }
10804          }
10805          return value;
10806        }
10807        var concurrentQueues = null;
10808        function pushConcurrentUpdateQueue(queue) {
10809          if (concurrentQueues === null) {
10810            concurrentQueues = [queue];
10811          } else {
10812            concurrentQueues.push(queue);
10813          }
10814        }
10815        function finishQueueingConcurrentUpdates() {
10816          if (concurrentQueues !== null) {
10817            for (var i = 0; i < concurrentQueues.length; i++) {
10818              var queue = concurrentQueues[i];
10819              var lastInterleavedUpdate = queue.interleaved;
10820              if (lastInterleavedUpdate !== null) {
10821                queue.interleaved = null;
10822                var firstInterleavedUpdate = lastInterleavedUpdate.next;
10823                var lastPendingUpdate = queue.pending;
10824                if (lastPendingUpdate !== null) {
10825                  var firstPendingUpdate = lastPendingUpdate.next;
10826                  lastPendingUpdate.next = firstInterleavedUpdate;
10827                  lastInterleavedUpdate.next = firstPendingUpdate;
10828                }
10829                queue.pending = lastInterleavedUpdate;
10830              }
10831            }
10832            concurrentQueues = null;
10833          }
10834        }
10835        function enqueueConcurrentHookUpdate(fiber, queue, update, lane) {
10836          var interleaved = queue.interleaved;
10837          if (interleaved === null) {
10838            update.next = update;
10839            pushConcurrentUpdateQueue(queue);
10840          } else {
10841            update.next = interleaved.next;
10842            interleaved.next = update;
10843          }
10844          queue.interleaved = update;
10845          return markUpdateLaneFromFiberToRoot(fiber, lane);
10846        }
10847        function enqueueConcurrentHookUpdateAndEagerlyBailout(fiber, queue, update, lane) {
10848          var interleaved = queue.interleaved;
10849          if (interleaved === null) {
10850            update.next = update;
10851            pushConcurrentUpdateQueue(queue);
10852          } else {
10853            update.next = interleaved.next;
10854            interleaved.next = update;
10855          }
10856          queue.interleaved = update;
10857        }
10858        function enqueueConcurrentClassUpdate(fiber, queue, update, lane) {
10859          var interleaved = queue.interleaved;
10860          if (interleaved === null) {
10861            update.next = update;
10862            pushConcurrentUpdateQueue(queue);
10863          } else {
10864            update.next = interleaved.next;
10865            interleaved.next = update;
10866          }
10867          queue.interleaved = update;
10868          return markUpdateLaneFromFiberToRoot(fiber, lane);
10869        }
10870        function enqueueConcurrentRenderForLane(fiber, lane) {
10871          return markUpdateLaneFromFiberToRoot(fiber, lane);
10872        }
10873        var unsafe_markUpdateLaneFromFiberToRoot = markUpdateLaneFromFiberToRoot;
10874        function markUpdateLaneFromFiberToRoot(sourceFiber, lane) {
10875          sourceFiber.lanes = mergeLanes(sourceFiber.lanes, lane);
10876          var alternate = sourceFiber.alternate;
10877          if (alternate !== null) {
10878            alternate.lanes = mergeLanes(alternate.lanes, lane);
10879          }
10880          {
10881            if (alternate === null && (sourceFiber.flags & (Placement | Hydrating)) !== NoFlags) {
10882              warnAboutUpdateOnNotYetMountedFiberInDEV(sourceFiber);
10883            }
10884          }
10885          var node = sourceFiber;
10886          var parent = sourceFiber.return;
10887          while (parent !== null) {
10888            parent.childLanes = mergeLanes(parent.childLanes, lane);
10889            alternate = parent.alternate;
10890            if (alternate !== null) {
10891              alternate.childLanes = mergeLanes(alternate.childLanes, lane);
10892            } else {
10893              {
10894                if ((parent.flags & (Placement | Hydrating)) !== NoFlags) {
10895                  warnAboutUpdateOnNotYetMountedFiberInDEV(sourceFiber);
10896                }
10897              }
10898            }
10899            node = parent;
10900            parent = parent.return;
10901          }
10902          if (node.tag === HostRoot) {
10903            var root2 = node.stateNode;
10904            return root2;
10905          } else {
10906            return null;
10907          }
10908        }
10909        var UpdateState = 0;
10910        var ReplaceState = 1;
10911        var ForceUpdate = 2;
10912        var CaptureUpdate = 3;
10913        var hasForceUpdate = false;
10914        var didWarnUpdateInsideUpdate;
10915        var currentlyProcessingQueue;
10916        {
10917          didWarnUpdateInsideUpdate = false;
10918          currentlyProcessingQueue = null;
10919        }
10920        function initializeUpdateQueue(fiber) {
10921          var queue = {
10922            baseState: fiber.memoizedState,
10923            firstBaseUpdate: null,
10924            lastBaseUpdate: null,
10925            shared: {
10926              pending: null,
10927              interleaved: null,
10928              lanes: NoLanes
10929            },
10930            effects: null
10931          };
10932          fiber.updateQueue = queue;
10933        }
10934        function cloneUpdateQueue(current2, workInProgress2) {
10935          var queue = workInProgress2.updateQueue;
10936          var currentQueue = current2.updateQueue;
10937          if (queue === currentQueue) {
10938            var clone = {
10939              baseState: currentQueue.baseState,
10940              firstBaseUpdate: currentQueue.firstBaseUpdate,
10941              lastBaseUpdate: currentQueue.lastBaseUpdate,
10942              shared: currentQueue.shared,
10943              effects: currentQueue.effects
10944            };
10945            workInProgress2.updateQueue = clone;
10946          }
10947        }
10948        function createUpdate(eventTime, lane) {
10949          var update = {
10950            eventTime,
10951            lane,
10952            tag: UpdateState,
10953            payload: null,
10954            callback: null,
10955            next: null
10956          };
10957          return update;
10958        }
10959        function enqueueUpdate(fiber, update, lane) {
10960          var updateQueue = fiber.updateQueue;
10961          if (updateQueue === null) {
10962            return null;
10963          }
10964          var sharedQueue = updateQueue.shared;
10965          {
10966            if (currentlyProcessingQueue === sharedQueue && !didWarnUpdateInsideUpdate) {
10967              error("An update (setState, replaceState, or forceUpdate) was scheduled from inside an update function. Update functions should be pure, with zero side-effects. Consider using componentDidUpdate or a callback.");
10968              didWarnUpdateInsideUpdate = true;
10969            }
10970          }
10971          if (isUnsafeClassRenderPhaseUpdate()) {
10972            var pending = sharedQueue.pending;
10973            if (pending === null) {
10974              update.next = update;
10975            } else {
10976              update.next = pending.next;
10977              pending.next = update;
10978            }
10979            sharedQueue.pending = update;
10980            return unsafe_markUpdateLaneFromFiberToRoot(fiber, lane);
10981          } else {
10982            return enqueueConcurrentClassUpdate(fiber, sharedQueue, update, lane);
10983          }
10984        }
10985        function entangleTransitions(root2, fiber, lane) {
10986          var updateQueue = fiber.updateQueue;
10987          if (updateQueue === null) {
10988            return;
10989          }
10990          var sharedQueue = updateQueue.shared;
10991          if (isTransitionLane(lane)) {
10992            var queueLanes = sharedQueue.lanes;
10993            queueLanes = intersectLanes(queueLanes, root2.pendingLanes);
10994            var newQueueLanes = mergeLanes(queueLanes, lane);
10995            sharedQueue.lanes = newQueueLanes;
10996            markRootEntangled(root2, newQueueLanes);
10997          }
10998        }
10999        function enqueueCapturedUpdate(workInProgress2, capturedUpdate) {
11000          var queue = workInProgress2.updateQueue;
11001          var current2 = workInProgress2.alternate;
11002          if (current2 !== null) {
11003            var currentQueue = current2.updateQueue;
11004            if (queue === currentQueue) {
11005              var newFirst = null;
11006              var newLast = null;
11007              var firstBaseUpdate = queue.firstBaseUpdate;
11008              if (firstBaseUpdate !== null) {
11009                var update = firstBaseUpdate;
11010                do {
11011                  var clone = {
11012                    eventTime: update.eventTime,
11013                    lane: update.lane,
11014                    tag: update.tag,
11015                    payload: update.payload,
11016                    callback: update.callback,
11017                    next: null
11018                  };
11019                  if (newLast === null) {
11020                    newFirst = newLast = clone;
11021                  } else {
11022                    newLast.next = clone;
11023                    newLast = clone;
11024                  }
11025                  update = update.next;
11026                } while (update !== null);
11027                if (newLast === null) {
11028                  newFirst = newLast = capturedUpdate;
11029                } else {
11030                  newLast.next = capturedUpdate;
11031                  newLast = capturedUpdate;
11032                }
11033              } else {
11034                newFirst = newLast = capturedUpdate;
11035              }
11036              queue = {
11037                baseState: currentQueue.baseState,
11038                firstBaseUpdate: newFirst,
11039                lastBaseUpdate: newLast,
11040                shared: currentQueue.shared,
11041                effects: currentQueue.effects
11042              };
11043              workInProgress2.updateQueue = queue;
11044              return;
11045            }
11046          }
11047          var lastBaseUpdate = queue.lastBaseUpdate;
11048          if (lastBaseUpdate === null) {
11049            queue.firstBaseUpdate = capturedUpdate;
11050          } else {
11051            lastBaseUpdate.next = capturedUpdate;
11052          }
11053          queue.lastBaseUpdate = capturedUpdate;
11054        }
11055        function getStateFromUpdate(workInProgress2, queue, update, prevState, nextProps, instance) {
11056          switch (update.tag) {
11057            case ReplaceState: {
11058              var payload = update.payload;
11059              if (typeof payload === "function") {
11060                {
11061                  enterDisallowedContextReadInDEV();
11062                }
11063                var nextState = payload.call(instance, prevState, nextProps);
11064                {
11065                  if (workInProgress2.mode & StrictLegacyMode) {
11066                    setIsStrictModeForDevtools(true);
11067                    try {
11068                      payload.call(instance, prevState, nextProps);
11069                    } finally {
11070                      setIsStrictModeForDevtools(false);
11071                    }
11072                  }
11073                  exitDisallowedContextReadInDEV();
11074                }
11075                return nextState;
11076              }
11077              return payload;
11078            }
11079            case CaptureUpdate: {
11080              workInProgress2.flags = workInProgress2.flags & ~ShouldCapture | DidCapture;
11081            }
11082            case UpdateState: {
11083              var _payload = update.payload;
11084              var partialState;
11085              if (typeof _payload === "function") {
11086                {
11087                  enterDisallowedContextReadInDEV();
11088                }
11089                partialState = _payload.call(instance, prevState, nextProps);
11090                {
11091                  if (workInProgress2.mode & StrictLegacyMode) {
11092                    setIsStrictModeForDevtools(true);
11093                    try {
11094                      _payload.call(instance, prevState, nextProps);
11095                    } finally {
11096                      setIsStrictModeForDevtools(false);
11097                    }
11098                  }
11099                  exitDisallowedContextReadInDEV();
11100                }
11101              } else {
11102                partialState = _payload;
11103              }
11104              if (partialState === null || partialState === void 0) {
11105                return prevState;
11106              }
11107              return assign({}, prevState, partialState);
11108            }
11109            case ForceUpdate: {
11110              hasForceUpdate = true;
11111              return prevState;
11112            }
11113          }
11114          return prevState;
11115        }
11116        function processUpdateQueue(workInProgress2, props, instance, renderLanes2) {
11117          var queue = workInProgress2.updateQueue;
11118          hasForceUpdate = false;
11119          {
11120            currentlyProcessingQueue = queue.shared;
11121          }
11122          var firstBaseUpdate = queue.firstBaseUpdate;
11123          var lastBaseUpdate = queue.lastBaseUpdate;
11124          var pendingQueue = queue.shared.pending;
11125          if (pendingQueue !== null) {
11126            queue.shared.pending = null;
11127            var lastPendingUpdate = pendingQueue;
11128            var firstPendingUpdate = lastPendingUpdate.next;
11129            lastPendingUpdate.next = null;
11130            if (lastBaseUpdate === null) {
11131              firstBaseUpdate = firstPendingUpdate;
11132            } else {
11133              lastBaseUpdate.next = firstPendingUpdate;
11134            }
11135            lastBaseUpdate = lastPendingUpdate;
11136            var current2 = workInProgress2.alternate;
11137            if (current2 !== null) {
11138              var currentQueue = current2.updateQueue;
11139              var currentLastBaseUpdate = currentQueue.lastBaseUpdate;
11140              if (currentLastBaseUpdate !== lastBaseUpdate) {
11141                if (currentLastBaseUpdate === null) {
11142                  currentQueue.firstBaseUpdate = firstPendingUpdate;
11143                } else {
11144                  currentLastBaseUpdate.next = firstPendingUpdate;
11145                }
11146                currentQueue.lastBaseUpdate = lastPendingUpdate;
11147              }
11148            }
11149          }
11150          if (firstBaseUpdate !== null) {
11151            var newState = queue.baseState;
11152            var newLanes = NoLanes;
11153            var newBaseState = null;
11154            var newFirstBaseUpdate = null;
11155            var newLastBaseUpdate = null;
11156            var update = firstBaseUpdate;
11157            do {
11158              var updateLane = update.lane;
11159              var updateEventTime = update.eventTime;
11160              if (!isSubsetOfLanes(renderLanes2, updateLane)) {
11161                var clone = {
11162                  eventTime: updateEventTime,
11163                  lane: updateLane,
11164                  tag: update.tag,
11165                  payload: update.payload,
11166                  callback: update.callback,
11167                  next: null
11168                };
11169                if (newLastBaseUpdate === null) {
11170                  newFirstBaseUpdate = newLastBaseUpdate = clone;
11171                  newBaseState = newState;
11172                } else {
11173                  newLastBaseUpdate = newLastBaseUpdate.next = clone;
11174                }
11175                newLanes = mergeLanes(newLanes, updateLane);
11176              } else {
11177                if (newLastBaseUpdate !== null) {
11178                  var _clone = {
11179                    eventTime: updateEventTime,
11180                    // This update is going to be committed so we never want uncommit
11181                    // it. Using NoLane works because 0 is a subset of all bitmasks, so
11182                    // this will never be skipped by the check above.
11183                    lane: NoLane,
11184                    tag: update.tag,
11185                    payload: update.payload,
11186                    callback: update.callback,
11187                    next: null
11188                  };
11189                  newLastBaseUpdate = newLastBaseUpdate.next = _clone;
11190                }
11191                newState = getStateFromUpdate(workInProgress2, queue, update, newState, props, instance);
11192                var callback = update.callback;
11193                if (callback !== null && // If the update was already committed, we should not queue its
11194                // callback again.
11195                update.lane !== NoLane) {
11196                  workInProgress2.flags |= Callback;
11197                  var effects = queue.effects;
11198                  if (effects === null) {
11199                    queue.effects = [update];
11200                  } else {
11201                    effects.push(update);
11202                  }
11203                }
11204              }
11205              update = update.next;
11206              if (update === null) {
11207                pendingQueue = queue.shared.pending;
11208                if (pendingQueue === null) {
11209                  break;
11210                } else {
11211                  var _lastPendingUpdate = pendingQueue;
11212                  var _firstPendingUpdate = _lastPendingUpdate.next;
11213                  _lastPendingUpdate.next = null;
11214                  update = _firstPendingUpdate;
11215                  queue.lastBaseUpdate = _lastPendingUpdate;
11216                  queue.shared.pending = null;
11217                }
11218              }
11219            } while (true);
11220            if (newLastBaseUpdate === null) {
11221              newBaseState = newState;
11222            }
11223            queue.baseState = newBaseState;
11224            queue.firstBaseUpdate = newFirstBaseUpdate;
11225            queue.lastBaseUpdate = newLastBaseUpdate;
11226            var lastInterleaved = queue.shared.interleaved;
11227            if (lastInterleaved !== null) {
11228              var interleaved = lastInterleaved;
11229              do {
11230                newLanes = mergeLanes(newLanes, interleaved.lane);
11231                interleaved = interleaved.next;
11232              } while (interleaved !== lastInterleaved);
11233            } else if (firstBaseUpdate === null) {
11234              queue.shared.lanes = NoLanes;
11235            }
11236            markSkippedUpdateLanes(newLanes);
11237            workInProgress2.lanes = newLanes;
11238            workInProgress2.memoizedState = newState;
11239          }
11240          {
11241            currentlyProcessingQueue = null;
11242          }
11243        }
11244        function callCallback(callback, context) {
11245          if (typeof callback !== "function") {
11246            throw new Error("Invalid argument passed as callback. Expected a function. Instead " + ("received: " + callback));
11247          }
11248          callback.call(context);
11249        }
11250        function resetHasForceUpdateBeforeProcessing() {
11251          hasForceUpdate = false;
11252        }
11253        function checkHasForceUpdateAfterProcessing() {
11254          return hasForceUpdate;
11255        }
11256        function commitUpdateQueue(finishedWork, finishedQueue, instance) {
11257          var effects = finishedQueue.effects;
11258          finishedQueue.effects = null;
11259          if (effects !== null) {
11260            for (var i = 0; i < effects.length; i++) {
11261              var effect = effects[i];
11262              var callback = effect.callback;
11263              if (callback !== null) {
11264                effect.callback = null;
11265                callCallback(callback, instance);
11266              }
11267            }
11268          }
11269        }
11270        var NO_CONTEXT = {};
11271        var contextStackCursor$1 = createCursor(NO_CONTEXT);
11272        var contextFiberStackCursor = createCursor(NO_CONTEXT);
11273        var rootInstanceStackCursor = createCursor(NO_CONTEXT);
11274        function requiredContext(c) {
11275          if (c === NO_CONTEXT) {
11276            throw new Error("Expected host context to exist. This error is likely caused by a bug in React. Please file an issue.");
11277          }
11278          return c;
11279        }
11280        function getRootHostContainer() {
11281          var rootInstance = requiredContext(rootInstanceStackCursor.current);
11282          return rootInstance;
11283        }
11284        function pushHostContainer(fiber, nextRootInstance) {
11285          push(rootInstanceStackCursor, nextRootInstance, fiber);
11286          push(contextFiberStackCursor, fiber, fiber);
11287          push(contextStackCursor$1, NO_CONTEXT, fiber);
11288          var nextRootContext = getRootHostContext(nextRootInstance);
11289          pop(contextStackCursor$1, fiber);
11290          push(contextStackCursor$1, nextRootContext, fiber);
11291        }
11292        function popHostContainer(fiber) {
11293          pop(contextStackCursor$1, fiber);
11294          pop(contextFiberStackCursor, fiber);
11295          pop(rootInstanceStackCursor, fiber);
11296        }
11297        function getHostContext() {
11298          var context = requiredContext(contextStackCursor$1.current);
11299          return context;
11300        }
11301        function pushHostContext(fiber) {
11302          var rootInstance = requiredContext(rootInstanceStackCursor.current);
11303          var context = requiredContext(contextStackCursor$1.current);
11304          var nextContext = getChildHostContext(context, fiber.type);
11305          if (context === nextContext) {
11306            return;
11307          }
11308          push(contextFiberStackCursor, fiber, fiber);
11309          push(contextStackCursor$1, nextContext, fiber);
11310        }
11311        function popHostContext(fiber) {
11312          if (contextFiberStackCursor.current !== fiber) {
11313            return;
11314          }
11315          pop(contextStackCursor$1, fiber);
11316          pop(contextFiberStackCursor, fiber);
11317        }
11318        var DefaultSuspenseContext = 0;
11319        var SubtreeSuspenseContextMask = 1;
11320        var InvisibleParentSuspenseContext = 1;
11321        var ForceSuspenseFallback = 2;
11322        var suspenseStackCursor = createCursor(DefaultSuspenseContext);
11323        function hasSuspenseContext(parentContext, flag) {
11324          return (parentContext & flag) !== 0;
11325        }
11326        function setDefaultShallowSuspenseContext(parentContext) {
11327          return parentContext & SubtreeSuspenseContextMask;
11328        }
11329        function setShallowSuspenseContext(parentContext, shallowContext) {
11330          return parentContext & SubtreeSuspenseContextMask | shallowContext;
11331        }
11332        function addSubtreeSuspenseContext(parentContext, subtreeContext) {
11333          return parentContext | subtreeContext;
11334        }
11335        function pushSuspenseContext(fiber, newContext) {
11336          push(suspenseStackCursor, newContext, fiber);
11337        }
11338        function popSuspenseContext(fiber) {
11339          pop(suspenseStackCursor, fiber);
11340        }
11341        function shouldCaptureSuspense(workInProgress2, hasInvisibleParent) {
11342          var nextState = workInProgress2.memoizedState;
11343          if (nextState !== null) {
11344            if (nextState.dehydrated !== null) {
11345              return true;
11346            }
11347            return false;
11348          }
11349          var props = workInProgress2.memoizedProps;
11350          {
11351            return true;
11352          }
11353        }
11354        function findFirstSuspended(row) {
11355          var node = row;
11356          while (node !== null) {
11357            if (node.tag === SuspenseComponent) {
11358              var state = node.memoizedState;
11359              if (state !== null) {
11360                var dehydrated = state.dehydrated;
11361                if (dehydrated === null || isSuspenseInstancePending(dehydrated) || isSuspenseInstanceFallback(dehydrated)) {
11362                  return node;
11363                }
11364              }
11365            } else if (node.tag === SuspenseListComponent && // revealOrder undefined can't be trusted because it don't
11366            // keep track of whether it suspended or not.
11367            node.memoizedProps.revealOrder !== void 0) {
11368              var didSuspend = (node.flags & DidCapture) !== NoFlags;
11369              if (didSuspend) {
11370                return node;
11371              }
11372            } else if (node.child !== null) {
11373              node.child.return = node;
11374              node = node.child;
11375              continue;
11376            }
11377            if (node === row) {
11378              return null;
11379            }
11380            while (node.sibling === null) {
11381              if (node.return === null || node.return === row) {
11382                return null;
11383              }
11384              node = node.return;
11385            }
11386            node.sibling.return = node.return;
11387            node = node.sibling;
11388          }
11389          return null;
11390        }
11391        var NoFlags$1 = (
11392          /*   */
11393          0
11394        );
11395        var HasEffect = (
11396          /* */
11397          1
11398        );
11399        var Insertion = (
11400          /*  */
11401          2
11402        );
11403        var Layout = (
11404          /*    */
11405          4
11406        );
11407        var Passive$1 = (
11408          /*   */
11409          8
11410        );
11411        var workInProgressSources = [];
11412        function resetWorkInProgressVersions() {
11413          for (var i = 0; i < workInProgressSources.length; i++) {
11414            var mutableSource = workInProgressSources[i];
11415            {
11416              mutableSource._workInProgressVersionPrimary = null;
11417            }
11418          }
11419          workInProgressSources.length = 0;
11420        }
11421        function registerMutableSourceForHydration(root2, mutableSource) {
11422          var getVersion = mutableSource._getVersion;
11423          var version = getVersion(mutableSource._source);
11424          if (root2.mutableSourceEagerHydrationData == null) {
11425            root2.mutableSourceEagerHydrationData = [mutableSource, version];
11426          } else {
11427            root2.mutableSourceEagerHydrationData.push(mutableSource, version);
11428          }
11429        }
11430        var ReactCurrentDispatcher$1 = ReactSharedInternals.ReactCurrentDispatcher, ReactCurrentBatchConfig$2 = ReactSharedInternals.ReactCurrentBatchConfig;
11431        var didWarnAboutMismatchedHooksForComponent;
11432        var didWarnUncachedGetSnapshot;
11433        {
11434          didWarnAboutMismatchedHooksForComponent = /* @__PURE__ */ new Set();
11435        }
11436        var renderLanes = NoLanes;
11437        var currentlyRenderingFiber$1 = null;
11438        var currentHook = null;
11439        var workInProgressHook = null;
11440        var didScheduleRenderPhaseUpdate = false;
11441        var didScheduleRenderPhaseUpdateDuringThisPass = false;
11442        var localIdCounter = 0;
11443        var globalClientIdCounter = 0;
11444        var RE_RENDER_LIMIT = 25;
11445        var currentHookNameInDev = null;
11446        var hookTypesDev = null;
11447        var hookTypesUpdateIndexDev = -1;
11448        var ignorePreviousDependencies = false;
11449        function mountHookTypesDev() {
11450          {
11451            var hookName = currentHookNameInDev;
11452            if (hookTypesDev === null) {
11453              hookTypesDev = [hookName];
11454            } else {
11455              hookTypesDev.push(hookName);
11456            }
11457          }
11458        }
11459        function updateHookTypesDev() {
11460          {
11461            var hookName = currentHookNameInDev;
11462            if (hookTypesDev !== null) {
11463              hookTypesUpdateIndexDev++;
11464              if (hookTypesDev[hookTypesUpdateIndexDev] !== hookName) {
11465                warnOnHookMismatchInDev(hookName);
11466              }
11467            }
11468          }
11469        }
11470        function checkDepsAreArrayDev(deps) {
11471          {
11472            if (deps !== void 0 && deps !== null && !isArray(deps)) {
11473              error("%s received a final argument that is not an array (instead, received `%s`). When specified, the final argument must be an array.", currentHookNameInDev, typeof deps);
11474            }
11475          }
11476        }
11477        function warnOnHookMismatchInDev(currentHookName) {
11478          {
11479            var componentName = getComponentNameFromFiber(currentlyRenderingFiber$1);
11480            if (!didWarnAboutMismatchedHooksForComponent.has(componentName)) {
11481              didWarnAboutMismatchedHooksForComponent.add(componentName);
11482              if (hookTypesDev !== null) {
11483                var table = "";
11484                var secondColumnStart = 30;
11485                for (var i = 0; i <= hookTypesUpdateIndexDev; i++) {
11486                  var oldHookName = hookTypesDev[i];
11487                  var newHookName = i === hookTypesUpdateIndexDev ? currentHookName : oldHookName;
11488                  var row = i + 1 + ". " + oldHookName;
11489                  while (row.length < secondColumnStart) {
11490                    row += " ";
11491                  }
11492                  row += newHookName + "\n";
11493                  table += row;
11494                }
11495                error("React has detected a change in the order of Hooks called by %s. This will lead to bugs and errors if not fixed. For more information, read the Rules of Hooks: https://reactjs.org/link/rules-of-hooks\n\n   Previous render            Next render\n   ------------------------------------------------------\n%s   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n", componentName, table);
11496              }
11497            }
11498          }
11499        }
11500        function throwInvalidHookError() {
11501          throw new 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:\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://reactjs.org/link/invalid-hook-call for tips about how to debug and fix this problem.");
11502        }
11503        function areHookInputsEqual(nextDeps, prevDeps) {
11504          {
11505            if (ignorePreviousDependencies) {
11506              return false;
11507            }
11508          }
11509          if (prevDeps === null) {
11510            {
11511              error("%s received a final argument during this render, but not during the previous render. Even though the final argument is optional, its type cannot change between renders.", currentHookNameInDev);
11512            }
11513            return false;
11514          }
11515          {
11516            if (nextDeps.length !== prevDeps.length) {
11517              error("The final argument passed to %s changed size between renders. The order and size of this array must remain constant.\n\nPrevious: %s\nIncoming: %s", currentHookNameInDev, "[" + prevDeps.join(", ") + "]", "[" + nextDeps.join(", ") + "]");
11518            }
11519          }
11520          for (var i = 0; i < prevDeps.length && i < nextDeps.length; i++) {
11521            if (objectIs(nextDeps[i], prevDeps[i])) {
11522              continue;
11523            }
11524            return false;
11525          }
11526          return true;
11527        }
11528        function renderWithHooks(current2, workInProgress2, Component, props, secondArg, nextRenderLanes) {
11529          renderLanes = nextRenderLanes;
11530          currentlyRenderingFiber$1 = workInProgress2;
11531          {
11532            hookTypesDev = current2 !== null ? current2._debugHookTypes : null;
11533            hookTypesUpdateIndexDev = -1;
11534            ignorePreviousDependencies = current2 !== null && current2.type !== workInProgress2.type;
11535          }
11536          workInProgress2.memoizedState = null;
11537          workInProgress2.updateQueue = null;
11538          workInProgress2.lanes = NoLanes;
11539          {
11540            if (current2 !== null && current2.memoizedState !== null) {
11541              ReactCurrentDispatcher$1.current = HooksDispatcherOnUpdateInDEV;
11542            } else if (hookTypesDev !== null) {
11543              ReactCurrentDispatcher$1.current = HooksDispatcherOnMountWithHookTypesInDEV;
11544            } else {
11545              ReactCurrentDispatcher$1.current = HooksDispatcherOnMountInDEV;
11546            }
11547          }
11548          var children = Component(props, secondArg);
11549          if (didScheduleRenderPhaseUpdateDuringThisPass) {
11550            var numberOfReRenders = 0;
11551            do {
11552              didScheduleRenderPhaseUpdateDuringThisPass = false;
11553              localIdCounter = 0;
11554              if (numberOfReRenders >= RE_RENDER_LIMIT) {
11555                throw new Error("Too many re-renders. React limits the number of renders to prevent an infinite loop.");
11556              }
11557              numberOfReRenders += 1;
11558              {
11559                ignorePreviousDependencies = false;
11560              }
11561              currentHook = null;
11562              workInProgressHook = null;
11563              workInProgress2.updateQueue = null;
11564              {
11565                hookTypesUpdateIndexDev = -1;
11566              }
11567              ReactCurrentDispatcher$1.current = HooksDispatcherOnRerenderInDEV;
11568              children = Component(props, secondArg);
11569            } while (didScheduleRenderPhaseUpdateDuringThisPass);
11570          }
11571          ReactCurrentDispatcher$1.current = ContextOnlyDispatcher;
11572          {
11573            workInProgress2._debugHookTypes = hookTypesDev;
11574          }
11575          var didRenderTooFewHooks = currentHook !== null && currentHook.next !== null;
11576          renderLanes = NoLanes;
11577          currentlyRenderingFiber$1 = null;
11578          currentHook = null;
11579          workInProgressHook = null;
11580          {
11581            currentHookNameInDev = null;
11582            hookTypesDev = null;
11583            hookTypesUpdateIndexDev = -1;
11584            if (current2 !== null && (current2.flags & StaticMask) !== (workInProgress2.flags & StaticMask) && // Disable this warning in legacy mode, because legacy Suspense is weird
11585            // and creates false positives. To make this work in legacy mode, we'd
11586            // need to mark fibers that commit in an incomplete state, somehow. For
11587            // now I'll disable the warning that most of the bugs that would trigger
11588            // it are either exclusive to concurrent mode or exist in both.
11589            (current2.mode & ConcurrentMode) !== NoMode) {
11590              error("Internal React error: Expected static flag was missing. Please notify the React team.");
11591            }
11592          }
11593          didScheduleRenderPhaseUpdate = false;
11594          if (didRenderTooFewHooks) {
11595            throw new Error("Rendered fewer hooks than expected. This may be caused by an accidental early return statement.");
11596          }
11597          return children;
11598        }
11599        function checkDidRenderIdHook() {
11600          var didRenderIdHook = localIdCounter !== 0;
11601          localIdCounter = 0;
11602          return didRenderIdHook;
11603        }
11604        function bailoutHooks(current2, workInProgress2, lanes) {
11605          workInProgress2.updateQueue = current2.updateQueue;
11606          if ((workInProgress2.mode & StrictEffectsMode) !== NoMode) {
11607            workInProgress2.flags &= ~(MountPassiveDev | MountLayoutDev | Passive | Update);
11608          } else {
11609            workInProgress2.flags &= ~(Passive | Update);
11610          }
11611          current2.lanes = removeLanes(current2.lanes, lanes);
11612        }
11613        function resetHooksAfterThrow() {
11614          ReactCurrentDispatcher$1.current = ContextOnlyDispatcher;
11615          if (didScheduleRenderPhaseUpdate) {
11616            var hook = currentlyRenderingFiber$1.memoizedState;
11617            while (hook !== null) {
11618              var queue = hook.queue;
11619              if (queue !== null) {
11620                queue.pending = null;
11621              }
11622              hook = hook.next;
11623            }
11624            didScheduleRenderPhaseUpdate = false;
11625          }
11626          renderLanes = NoLanes;
11627          currentlyRenderingFiber$1 = null;
11628          currentHook = null;
11629          workInProgressHook = null;
11630          {
11631            hookTypesDev = null;
11632            hookTypesUpdateIndexDev = -1;
11633            currentHookNameInDev = null;
11634            isUpdatingOpaqueValueInRenderPhase = false;
11635          }
11636          didScheduleRenderPhaseUpdateDuringThisPass = false;
11637          localIdCounter = 0;
11638        }
11639        function mountWorkInProgressHook() {
11640          var hook = {
11641            memoizedState: null,
11642            baseState: null,
11643            baseQueue: null,
11644            queue: null,
11645            next: null
11646          };
11647          if (workInProgressHook === null) {
11648            currentlyRenderingFiber$1.memoizedState = workInProgressHook = hook;
11649          } else {
11650            workInProgressHook = workInProgressHook.next = hook;
11651          }
11652          return workInProgressHook;
11653        }
11654        function updateWorkInProgressHook() {
11655          var nextCurrentHook;
11656          if (currentHook === null) {
11657            var current2 = currentlyRenderingFiber$1.alternate;
11658            if (current2 !== null) {
11659              nextCurrentHook = current2.memoizedState;
11660            } else {
11661              nextCurrentHook = null;
11662            }
11663          } else {
11664            nextCurrentHook = currentHook.next;
11665          }
11666          var nextWorkInProgressHook;
11667          if (workInProgressHook === null) {
11668            nextWorkInProgressHook = currentlyRenderingFiber$1.memoizedState;
11669          } else {
11670            nextWorkInProgressHook = workInProgressHook.next;
11671          }
11672          if (nextWorkInProgressHook !== null) {
11673            workInProgressHook = nextWorkInProgressHook;
11674            nextWorkInProgressHook = workInProgressHook.next;
11675            currentHook = nextCurrentHook;
11676          } else {
11677            if (nextCurrentHook === null) {
11678              throw new Error("Rendered more hooks than during the previous render.");
11679            }
11680            currentHook = nextCurrentHook;
11681            var newHook = {
11682              memoizedState: currentHook.memoizedState,
11683              baseState: currentHook.baseState,
11684              baseQueue: currentHook.baseQueue,
11685              queue: currentHook.queue,
11686              next: null
11687            };
11688            if (workInProgressHook === null) {
11689              currentlyRenderingFiber$1.memoizedState = workInProgressHook = newHook;
11690            } else {
11691              workInProgressHook = workInProgressHook.next = newHook;
11692            }
11693          }
11694          return workInProgressHook;
11695        }
11696        function createFunctionComponentUpdateQueue() {
11697          return {
11698            lastEffect: null,
11699            stores: null
11700          };
11701        }
11702        function basicStateReducer(state, action) {
11703          return typeof action === "function" ? action(state) : action;
11704        }
11705        function mountReducer(reducer, initialArg, init) {
11706          var hook = mountWorkInProgressHook();
11707          var initialState;
11708          if (init !== void 0) {
11709            initialState = init(initialArg);
11710          } else {
11711            initialState = initialArg;
11712          }
11713          hook.memoizedState = hook.baseState = initialState;
11714          var queue = {
11715            pending: null,
11716            interleaved: null,
11717            lanes: NoLanes,
11718            dispatch: null,
11719            lastRenderedReducer: reducer,
11720            lastRenderedState: initialState
11721          };
11722          hook.queue = queue;
11723          var dispatch = queue.dispatch = dispatchReducerAction.bind(null, currentlyRenderingFiber$1, queue);
11724          return [hook.memoizedState, dispatch];
11725        }
11726        function updateReducer(reducer, initialArg, init) {
11727          var hook = updateWorkInProgressHook();
11728          var queue = hook.queue;
11729          if (queue === null) {
11730            throw new Error("Should have a queue. This is likely a bug in React. Please file an issue.");
11731          }
11732          queue.lastRenderedReducer = reducer;
11733          var current2 = currentHook;
11734          var baseQueue = current2.baseQueue;
11735          var pendingQueue = queue.pending;
11736          if (pendingQueue !== null) {
11737            if (baseQueue !== null) {
11738              var baseFirst = baseQueue.next;
11739              var pendingFirst = pendingQueue.next;
11740              baseQueue.next = pendingFirst;
11741              pendingQueue.next = baseFirst;
11742            }
11743            {
11744              if (current2.baseQueue !== baseQueue) {
11745                error("Internal error: Expected work-in-progress queue to be a clone. This is a bug in React.");
11746              }
11747            }
11748            current2.baseQueue = baseQueue = pendingQueue;
11749            queue.pending = null;
11750          }
11751          if (baseQueue !== null) {
11752            var first = baseQueue.next;
11753            var newState = current2.baseState;
11754            var newBaseState = null;
11755            var newBaseQueueFirst = null;
11756            var newBaseQueueLast = null;
11757            var update = first;
11758            do {
11759              var updateLane = update.lane;
11760              if (!isSubsetOfLanes(renderLanes, updateLane)) {
11761                var clone = {
11762                  lane: updateLane,
11763                  action: update.action,
11764                  hasEagerState: update.hasEagerState,
11765                  eagerState: update.eagerState,
11766                  next: null
11767                };
11768                if (newBaseQueueLast === null) {
11769                  newBaseQueueFirst = newBaseQueueLast = clone;
11770                  newBaseState = newState;
11771                } else {
11772                  newBaseQueueLast = newBaseQueueLast.next = clone;
11773                }
11774                currentlyRenderingFiber$1.lanes = mergeLanes(currentlyRenderingFiber$1.lanes, updateLane);
11775                markSkippedUpdateLanes(updateLane);
11776              } else {
11777                if (newBaseQueueLast !== null) {
11778                  var _clone = {
11779                    // This update is going to be committed so we never want uncommit
11780                    // it. Using NoLane works because 0 is a subset of all bitmasks, so
11781                    // this will never be skipped by the check above.
11782                    lane: NoLane,
11783                    action: update.action,
11784                    hasEagerState: update.hasEagerState,
11785                    eagerState: update.eagerState,
11786                    next: null
11787                  };
11788                  newBaseQueueLast = newBaseQueueLast.next = _clone;
11789                }
11790                if (update.hasEagerState) {
11791                  newState = update.eagerState;
11792                } else {
11793                  var action = update.action;
11794                  newState = reducer(newState, action);
11795                }
11796              }
11797              update = update.next;
11798            } while (update !== null && update !== first);
11799            if (newBaseQueueLast === null) {
11800              newBaseState = newState;
11801            } else {
11802              newBaseQueueLast.next = newBaseQueueFirst;
11803            }
11804            if (!objectIs(newState, hook.memoizedState)) {
11805              markWorkInProgressReceivedUpdate();
11806            }
11807            hook.memoizedState = newState;
11808            hook.baseState = newBaseState;
11809            hook.baseQueue = newBaseQueueLast;
11810            queue.lastRenderedState = newState;
11811          }
11812          var lastInterleaved = queue.interleaved;
11813          if (lastInterleaved !== null) {
11814            var interleaved = lastInterleaved;
11815            do {
11816              var interleavedLane = interleaved.lane;
11817              currentlyRenderingFiber$1.lanes = mergeLanes(currentlyRenderingFiber$1.lanes, interleavedLane);
11818              markSkippedUpdateLanes(interleavedLane);
11819              interleaved = interleaved.next;
11820            } while (interleaved !== lastInterleaved);
11821          } else if (baseQueue === null) {
11822            queue.lanes = NoLanes;
11823          }
11824          var dispatch = queue.dispatch;
11825          return [hook.memoizedState, dispatch];
11826        }
11827        function rerenderReducer(reducer, initialArg, init) {
11828          var hook = updateWorkInProgressHook();
11829          var queue = hook.queue;
11830          if (queue === null) {
11831            throw new Error("Should have a queue. This is likely a bug in React. Please file an issue.");
11832          }
11833          queue.lastRenderedReducer = reducer;
11834          var dispatch = queue.dispatch;
11835          var lastRenderPhaseUpdate = queue.pending;
11836          var newState = hook.memoizedState;
11837          if (lastRenderPhaseUpdate !== null) {
11838            queue.pending = null;
11839            var firstRenderPhaseUpdate = lastRenderPhaseUpdate.next;
11840            var update = firstRenderPhaseUpdate;
11841            do {
11842              var action = update.action;
11843              newState = reducer(newState, action);
11844              update = update.next;
11845            } while (update !== firstRenderPhaseUpdate);
11846            if (!objectIs(newState, hook.memoizedState)) {
11847              markWorkInProgressReceivedUpdate();
11848            }
11849            hook.memoizedState = newState;
11850            if (hook.baseQueue === null) {
11851              hook.baseState = newState;
11852            }
11853            queue.lastRenderedState = newState;
11854          }
11855          return [newState, dispatch];
11856        }
11857        function mountMutableSource(source, getSnapshot, subscribe) {
11858          {
11859            return void 0;
11860          }
11861        }
11862        function updateMutableSource(source, getSnapshot, subscribe) {
11863          {
11864            return void 0;
11865          }
11866        }
11867        function mountSyncExternalStore(subscribe, getSnapshot, getServerSnapshot) {
11868          var fiber = currentlyRenderingFiber$1;
11869          var hook = mountWorkInProgressHook();
11870          var nextSnapshot;
11871          var isHydrating2 = getIsHydrating();
11872          if (isHydrating2) {
11873            if (getServerSnapshot === void 0) {
11874              throw new Error("Missing getServerSnapshot, which is required for server-rendered content. Will revert to client rendering.");
11875            }
11876            nextSnapshot = getServerSnapshot();
11877            {
11878              if (!didWarnUncachedGetSnapshot) {
11879                if (nextSnapshot !== getServerSnapshot()) {
11880                  error("The result of getServerSnapshot should be cached to avoid an infinite loop");
11881                  didWarnUncachedGetSnapshot = true;
11882                }
11883              }
11884            }
11885          } else {
11886            nextSnapshot = getSnapshot();
11887            {
11888              if (!didWarnUncachedGetSnapshot) {
11889                var cachedSnapshot = getSnapshot();
11890                if (!objectIs(nextSnapshot, cachedSnapshot)) {
11891                  error("The result of getSnapshot should be cached to avoid an infinite loop");
11892                  didWarnUncachedGetSnapshot = true;
11893                }
11894              }
11895            }
11896            var root2 = getWorkInProgressRoot();
11897            if (root2 === null) {
11898              throw new Error("Expected a work-in-progress root. This is a bug in React. Please file an issue.");
11899            }
11900            if (!includesBlockingLane(root2, renderLanes)) {
11901              pushStoreConsistencyCheck(fiber, getSnapshot, nextSnapshot);
11902            }
11903          }
11904          hook.memoizedState = nextSnapshot;
11905          var inst = {
11906            value: nextSnapshot,
11907            getSnapshot
11908          };
11909          hook.queue = inst;
11910          mountEffect(subscribeToStore.bind(null, fiber, inst, subscribe), [subscribe]);
11911          fiber.flags |= Passive;
11912          pushEffect(HasEffect | Passive$1, updateStoreInstance.bind(null, fiber, inst, nextSnapshot, getSnapshot), void 0, null);
11913          return nextSnapshot;
11914        }
11915        function updateSyncExternalStore(subscribe, getSnapshot, getServerSnapshot) {
11916          var fiber = currentlyRenderingFiber$1;
11917          var hook = updateWorkInProgressHook();
11918          var nextSnapshot = getSnapshot();
11919          {
11920            if (!didWarnUncachedGetSnapshot) {
11921              var cachedSnapshot = getSnapshot();
11922              if (!objectIs(nextSnapshot, cachedSnapshot)) {
11923                error("The result of getSnapshot should be cached to avoid an infinite loop");
11924                didWarnUncachedGetSnapshot = true;
11925              }
11926            }
11927          }
11928          var prevSnapshot = hook.memoizedState;
11929          var snapshotChanged = !objectIs(prevSnapshot, nextSnapshot);
11930          if (snapshotChanged) {
11931            hook.memoizedState = nextSnapshot;
11932            markWorkInProgressReceivedUpdate();
11933          }
11934          var inst = hook.queue;
11935          updateEffect(subscribeToStore.bind(null, fiber, inst, subscribe), [subscribe]);
11936          if (inst.getSnapshot !== getSnapshot || snapshotChanged || // Check if the susbcribe function changed. We can save some memory by
11937          // checking whether we scheduled a subscription effect above.
11938          workInProgressHook !== null && workInProgressHook.memoizedState.tag & HasEffect) {
11939            fiber.flags |= Passive;
11940            pushEffect(HasEffect | Passive$1, updateStoreInstance.bind(null, fiber, inst, nextSnapshot, getSnapshot), void 0, null);
11941            var root2 = getWorkInProgressRoot();
11942            if (root2 === null) {
11943              throw new Error("Expected a work-in-progress root. This is a bug in React. Please file an issue.");
11944            }
11945            if (!includesBlockingLane(root2, renderLanes)) {
11946              pushStoreConsistencyCheck(fiber, getSnapshot, nextSnapshot);
11947            }
11948          }
11949          return nextSnapshot;
11950        }
11951        function pushStoreConsistencyCheck(fiber, getSnapshot, renderedSnapshot) {
11952          fiber.flags |= StoreConsistency;
11953          var check = {
11954            getSnapshot,
11955            value: renderedSnapshot
11956          };
11957          var componentUpdateQueue = currentlyRenderingFiber$1.updateQueue;
11958          if (componentUpdateQueue === null) {
11959            componentUpdateQueue = createFunctionComponentUpdateQueue();
11960            currentlyRenderingFiber$1.updateQueue = componentUpdateQueue;
11961            componentUpdateQueue.stores = [check];
11962          } else {
11963            var stores = componentUpdateQueue.stores;
11964            if (stores === null) {
11965              componentUpdateQueue.stores = [check];
11966            } else {
11967              stores.push(check);
11968            }
11969          }
11970        }
11971        function updateStoreInstance(fiber, inst, nextSnapshot, getSnapshot) {
11972          inst.value = nextSnapshot;
11973          inst.getSnapshot = getSnapshot;
11974          if (checkIfSnapshotChanged(inst)) {
11975            forceStoreRerender(fiber);
11976          }
11977        }
11978        function subscribeToStore(fiber, inst, subscribe) {
11979          var handleStoreChange = function() {
11980            if (checkIfSnapshotChanged(inst)) {
11981              forceStoreRerender(fiber);
11982            }
11983          };
11984          return subscribe(handleStoreChange);
11985        }
11986        function checkIfSnapshotChanged(inst) {
11987          var latestGetSnapshot = inst.getSnapshot;
11988          var prevValue = inst.value;
11989          try {
11990            var nextValue = latestGetSnapshot();
11991            return !objectIs(prevValue, nextValue);
11992          } catch (error2) {
11993            return true;
11994          }
11995        }
11996        function forceStoreRerender(fiber) {
11997          var root2 = enqueueConcurrentRenderForLane(fiber, SyncLane);
11998          if (root2 !== null) {
11999            scheduleUpdateOnFiber(root2, fiber, SyncLane, NoTimestamp);
12000          }
12001        }
12002        function mountState(initialState) {
12003          var hook = mountWorkInProgressHook();
12004          if (typeof initialState === "function") {
12005            initialState = initialState();
12006          }
12007          hook.memoizedState = hook.baseState = initialState;
12008          var queue = {
12009            pending: null,
12010            interleaved: null,
12011            lanes: NoLanes,
12012            dispatch: null,
12013            lastRenderedReducer: basicStateReducer,
12014            lastRenderedState: initialState
12015          };
12016          hook.queue = queue;
12017          var dispatch = queue.dispatch = dispatchSetState.bind(null, currentlyRenderingFiber$1, queue);
12018          return [hook.memoizedState, dispatch];
12019        }
12020        function updateState(initialState) {
12021          return updateReducer(basicStateReducer);
12022        }
12023        function rerenderState(initialState) {
12024          return rerenderReducer(basicStateReducer);
12025        }
12026        function pushEffect(tag, create, destroy, deps) {
12027          var effect = {
12028            tag,
12029            create,
12030            destroy,
12031            deps,
12032            // Circular
12033            next: null
12034          };
12035          var componentUpdateQueue = currentlyRenderingFiber$1.updateQueue;
12036          if (componentUpdateQueue === null) {
12037            componentUpdateQueue = createFunctionComponentUpdateQueue();
12038            currentlyRenderingFiber$1.updateQueue = componentUpdateQueue;
12039            componentUpdateQueue.lastEffect = effect.next = effect;
12040          } else {
12041            var lastEffect = componentUpdateQueue.lastEffect;
12042            if (lastEffect === null) {
12043              componentUpdateQueue.lastEffect = effect.next = effect;
12044            } else {
12045              var firstEffect = lastEffect.next;
12046              lastEffect.next = effect;
12047              effect.next = firstEffect;
12048              componentUpdateQueue.lastEffect = effect;
12049            }
12050          }
12051          return effect;
12052        }
12053        function mountRef(initialValue) {
12054          var hook = mountWorkInProgressHook();
12055          {
12056            var _ref2 = {
12057              current: initialValue
12058            };
12059            hook.memoizedState = _ref2;
12060            return _ref2;
12061          }
12062        }
12063        function updateRef(initialValue) {
12064          var hook = updateWorkInProgressHook();
12065          return hook.memoizedState;
12066        }
12067        function mountEffectImpl(fiberFlags, hookFlags, create, deps) {
12068          var hook = mountWorkInProgressHook();
12069          var nextDeps = deps === void 0 ? null : deps;
12070          currentlyRenderingFiber$1.flags |= fiberFlags;
12071          hook.memoizedState = pushEffect(HasEffect | hookFlags, create, void 0, nextDeps);
12072        }
12073        function updateEffectImpl(fiberFlags, hookFlags, create, deps) {
12074          var hook = updateWorkInProgressHook();
12075          var nextDeps = deps === void 0 ? null : deps;
12076          var destroy = void 0;
12077          if (currentHook !== null) {
12078            var prevEffect = currentHook.memoizedState;
12079            destroy = prevEffect.destroy;
12080            if (nextDeps !== null) {
12081              var prevDeps = prevEffect.deps;
12082              if (areHookInputsEqual(nextDeps, prevDeps)) {
12083                hook.memoizedState = pushEffect(hookFlags, create, destroy, nextDeps);
12084                return;
12085              }
12086            }
12087          }
12088          currentlyRenderingFiber$1.flags |= fiberFlags;
12089          hook.memoizedState = pushEffect(HasEffect | hookFlags, create, destroy, nextDeps);
12090        }
12091        function mountEffect(create, deps) {
12092          if ((currentlyRenderingFiber$1.mode & StrictEffectsMode) !== NoMode) {
12093            return mountEffectImpl(MountPassiveDev | Passive | PassiveStatic, Passive$1, create, deps);
12094          } else {
12095            return mountEffectImpl(Passive | PassiveStatic, Passive$1, create, deps);
12096          }
12097        }
12098        function updateEffect(create, deps) {
12099          return updateEffectImpl(Passive, Passive$1, create, deps);
12100        }
12101        function mountInsertionEffect(create, deps) {
12102          return mountEffectImpl(Update, Insertion, create, deps);
12103        }
12104        function updateInsertionEffect(create, deps) {
12105          return updateEffectImpl(Update, Insertion, create, deps);
12106        }
12107        function mountLayoutEffect(create, deps) {
12108          var fiberFlags = Update;
12109          {
12110            fiberFlags |= LayoutStatic;
12111          }
12112          if ((currentlyRenderingFiber$1.mode & StrictEffectsMode) !== NoMode) {
12113            fiberFlags |= MountLayoutDev;
12114          }
12115          return mountEffectImpl(fiberFlags, Layout, create, deps);
12116        }
12117        function updateLayoutEffect(create, deps) {
12118          return updateEffectImpl(Update, Layout, create, deps);
12119        }
12120        function imperativeHandleEffect(create, ref) {
12121          if (typeof ref === "function") {
12122            var refCallback = ref;
12123            var _inst = create();
12124            refCallback(_inst);
12125            return function() {
12126              refCallback(null);
12127            };
12128          } else if (ref !== null && ref !== void 0) {
12129            var refObject = ref;
12130            {
12131              if (!refObject.hasOwnProperty("current")) {
12132                error("Expected useImperativeHandle() first argument to either be a ref callback or React.createRef() object. Instead received: %s.", "an object with keys {" + Object.keys(refObject).join(", ") + "}");
12133              }
12134            }
12135            var _inst2 = create();
12136            refObject.current = _inst2;
12137            return function() {
12138              refObject.current = null;
12139            };
12140          }
12141        }
12142        function mountImperativeHandle(ref, create, deps) {
12143          {
12144            if (typeof create !== "function") {
12145              error("Expected useImperativeHandle() second argument to be a function that creates a handle. Instead received: %s.", create !== null ? typeof create : "null");
12146            }
12147          }
12148          var effectDeps = deps !== null && deps !== void 0 ? deps.concat([ref]) : null;
12149          var fiberFlags = Update;
12150          {
12151            fiberFlags |= LayoutStatic;
12152          }
12153          if ((currentlyRenderingFiber$1.mode & StrictEffectsMode) !== NoMode) {
12154            fiberFlags |= MountLayoutDev;
12155          }
12156          return mountEffectImpl(fiberFlags, Layout, imperativeHandleEffect.bind(null, create, ref), effectDeps);
12157        }
12158        function updateImperativeHandle(ref, create, deps) {
12159          {
12160            if (typeof create !== "function") {
12161              error("Expected useImperativeHandle() second argument to be a function that creates a handle. Instead received: %s.", create !== null ? typeof create : "null");
12162            }
12163          }
12164          var effectDeps = deps !== null && deps !== void 0 ? deps.concat([ref]) : null;
12165          return updateEffectImpl(Update, Layout, imperativeHandleEffect.bind(null, create, ref), effectDeps);
12166        }
12167        function mountDebugValue(value, formatterFn) {
12168        }
12169        var updateDebugValue = mountDebugValue;
12170        function mountCallback(callback, deps) {
12171          var hook = mountWorkInProgressHook();
12172          var nextDeps = deps === void 0 ? null : deps;
12173          hook.memoizedState = [callback, nextDeps];
12174          return callback;
12175        }
12176        function updateCallback(callback, deps) {
12177          var hook = updateWorkInProgressHook();
12178          var nextDeps = deps === void 0 ? null : deps;
12179          var prevState = hook.memoizedState;
12180          if (prevState !== null) {
12181            if (nextDeps !== null) {
12182              var prevDeps = prevState[1];
12183              if (areHookInputsEqual(nextDeps, prevDeps)) {
12184                return prevState[0];
12185              }
12186            }
12187          }
12188          hook.memoizedState = [callback, nextDeps];
12189          return callback;
12190        }
12191        function mountMemo(nextCreate, deps) {
12192          var hook = mountWorkInProgressHook();
12193          var nextDeps = deps === void 0 ? null : deps;
12194          var nextValue = nextCreate();
12195          hook.memoizedState = [nextValue, nextDeps];
12196          return nextValue;
12197        }
12198        function updateMemo(nextCreate, deps) {
12199          var hook = updateWorkInProgressHook();
12200          var nextDeps = deps === void 0 ? null : deps;
12201          var prevState = hook.memoizedState;
12202          if (prevState !== null) {
12203            if (nextDeps !== null) {
12204              var prevDeps = prevState[1];
12205              if (areHookInputsEqual(nextDeps, prevDeps)) {
12206                return prevState[0];
12207              }
12208            }
12209          }
12210          var nextValue = nextCreate();
12211          hook.memoizedState = [nextValue, nextDeps];
12212          return nextValue;
12213        }
12214        function mountDeferredValue(value) {
12215          var hook = mountWorkInProgressHook();
12216          hook.memoizedState = value;
12217          return value;
12218        }
12219        function updateDeferredValue(value) {
12220          var hook = updateWorkInProgressHook();
12221          var resolvedCurrentHook = currentHook;
12222          var prevValue = resolvedCurrentHook.memoizedState;
12223          return updateDeferredValueImpl(hook, prevValue, value);
12224        }
12225        function rerenderDeferredValue(value) {
12226          var hook = updateWorkInProgressHook();
12227          if (currentHook === null) {
12228            hook.memoizedState = value;
12229            return value;
12230          } else {
12231            var prevValue = currentHook.memoizedState;
12232            return updateDeferredValueImpl(hook, prevValue, value);
12233          }
12234        }
12235        function updateDeferredValueImpl(hook, prevValue, value) {
12236          var shouldDeferValue = !includesOnlyNonUrgentLanes(renderLanes);
12237          if (shouldDeferValue) {
12238            if (!objectIs(value, prevValue)) {
12239              var deferredLane = claimNextTransitionLane();
12240              currentlyRenderingFiber$1.lanes = mergeLanes(currentlyRenderingFiber$1.lanes, deferredLane);
12241              markSkippedUpdateLanes(deferredLane);
12242              hook.baseState = true;
12243            }
12244            return prevValue;
12245          } else {
12246            if (hook.baseState) {
12247              hook.baseState = false;
12248              markWorkInProgressReceivedUpdate();
12249            }
12250            hook.memoizedState = value;
12251            return value;
12252          }
12253        }
12254        function startTransition(setPending, callback, options2) {
12255          var previousPriority = getCurrentUpdatePriority();
12256          setCurrentUpdatePriority(higherEventPriority(previousPriority, ContinuousEventPriority));
12257          setPending(true);
12258          var prevTransition = ReactCurrentBatchConfig$2.transition;
12259          ReactCurrentBatchConfig$2.transition = {};
12260          var currentTransition = ReactCurrentBatchConfig$2.transition;
12261          {
12262            ReactCurrentBatchConfig$2.transition._updatedFibers = /* @__PURE__ */ new Set();
12263          }
12264          try {
12265            setPending(false);
12266            callback();
12267          } finally {
12268            setCurrentUpdatePriority(previousPriority);
12269            ReactCurrentBatchConfig$2.transition = prevTransition;
12270            {
12271              if (prevTransition === null && currentTransition._updatedFibers) {
12272                var updatedFibersCount = currentTransition._updatedFibers.size;
12273                if (updatedFibersCount > 10) {
12274                  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.");
12275                }
12276                currentTransition._updatedFibers.clear();
12277              }
12278            }
12279          }
12280        }
12281        function mountTransition() {
12282          var _mountState = mountState(false), isPending = _mountState[0], setPending = _mountState[1];
12283          var start = startTransition.bind(null, setPending);
12284          var hook = mountWorkInProgressHook();
12285          hook.memoizedState = start;
12286          return [isPending, start];
12287        }
12288        function updateTransition() {
12289          var _updateState = updateState(), isPending = _updateState[0];
12290          var hook = updateWorkInProgressHook();
12291          var start = hook.memoizedState;
12292          return [isPending, start];
12293        }
12294        function rerenderTransition() {
12295          var _rerenderState = rerenderState(), isPending = _rerenderState[0];
12296          var hook = updateWorkInProgressHook();
12297          var start = hook.memoizedState;
12298          return [isPending, start];
12299        }
12300        var isUpdatingOpaqueValueInRenderPhase = false;
12301        function getIsUpdatingOpaqueValueInRenderPhaseInDEV() {
12302          {
12303            return isUpdatingOpaqueValueInRenderPhase;
12304          }
12305        }
12306        function mountId() {
12307          var hook = mountWorkInProgressHook();
12308          var root2 = getWorkInProgressRoot();
12309          var identifierPrefix = root2.identifierPrefix;
12310          var id;
12311          if (getIsHydrating()) {
12312            var treeId = getTreeId();
12313            id = ":" + identifierPrefix + "R" + treeId;
12314            var localId = localIdCounter++;
12315            if (localId > 0) {
12316              id += "H" + localId.toString(32);
12317            }
12318            id += ":";
12319          } else {
12320            var globalClientId = globalClientIdCounter++;
12321            id = ":" + identifierPrefix + "r" + globalClientId.toString(32) + ":";
12322          }
12323          hook.memoizedState = id;
12324          return id;
12325        }
12326        function updateId() {
12327          var hook = updateWorkInProgressHook();
12328          var id = hook.memoizedState;
12329          return id;
12330        }
12331        function dispatchReducerAction(fiber, queue, action) {
12332          {
12333            if (typeof arguments[3] === "function") {
12334              error("State updates from the useState() and useReducer() Hooks don't support the second callback argument. To execute a side effect after rendering, declare it in the component body with useEffect().");
12335            }
12336          }
12337          var lane = requestUpdateLane(fiber);
12338          var update = {
12339            lane,
12340            action,
12341            hasEagerState: false,
12342            eagerState: null,
12343            next: null
12344          };
12345          if (isRenderPhaseUpdate(fiber)) {
12346            enqueueRenderPhaseUpdate(queue, update);
12347          } else {
12348            var root2 = enqueueConcurrentHookUpdate(fiber, queue, update, lane);
12349            if (root2 !== null) {
12350              var eventTime = requestEventTime();
12351              scheduleUpdateOnFiber(root2, fiber, lane, eventTime);
12352              entangleTransitionUpdate(root2, queue, lane);
12353            }
12354          }
12355          markUpdateInDevTools(fiber, lane);
12356        }
12357        function dispatchSetState(fiber, queue, action) {
12358          {
12359            if (typeof arguments[3] === "function") {
12360              error("State updates from the useState() and useReducer() Hooks don't support the second callback argument. To execute a side effect after rendering, declare it in the component body with useEffect().");
12361            }
12362          }
12363          var lane = requestUpdateLane(fiber);
12364          var update = {
12365            lane,
12366            action,
12367            hasEagerState: false,
12368            eagerState: null,
12369            next: null
12370          };
12371          if (isRenderPhaseUpdate(fiber)) {
12372            enqueueRenderPhaseUpdate(queue, update);
12373          } else {
12374            var alternate = fiber.alternate;
12375            if (fiber.lanes === NoLanes && (alternate === null || alternate.lanes === NoLanes)) {
12376              var lastRenderedReducer = queue.lastRenderedReducer;
12377              if (lastRenderedReducer !== null) {
12378                var prevDispatcher;
12379                {
12380                  prevDispatcher = ReactCurrentDispatcher$1.current;
12381                  ReactCurrentDispatcher$1.current = InvalidNestedHooksDispatcherOnUpdateInDEV;
12382                }
12383                try {
12384                  var currentState = queue.lastRenderedState;
12385                  var eagerState = lastRenderedReducer(currentState, action);
12386                  update.hasEagerState = true;
12387                  update.eagerState = eagerState;
12388                  if (objectIs(eagerState, currentState)) {
12389                    enqueueConcurrentHookUpdateAndEagerlyBailout(fiber, queue, update, lane);
12390                    return;
12391                  }
12392                } catch (error2) {
12393                } finally {
12394                  {
12395                    ReactCurrentDispatcher$1.current = prevDispatcher;
12396                  }
12397                }
12398              }
12399            }
12400            var root2 = enqueueConcurrentHookUpdate(fiber, queue, update, lane);
12401            if (root2 !== null) {
12402              var eventTime = requestEventTime();
12403              scheduleUpdateOnFiber(root2, fiber, lane, eventTime);
12404              entangleTransitionUpdate(root2, queue, lane);
12405            }
12406          }
12407          markUpdateInDevTools(fiber, lane);
12408        }
12409        function isRenderPhaseUpdate(fiber) {
12410          var alternate = fiber.alternate;
12411          return fiber === currentlyRenderingFiber$1 || alternate !== null && alternate === currentlyRenderingFiber$1;
12412        }
12413        function enqueueRenderPhaseUpdate(queue, update) {
12414          didScheduleRenderPhaseUpdateDuringThisPass = didScheduleRenderPhaseUpdate = true;
12415          var pending = queue.pending;
12416          if (pending === null) {
12417            update.next = update;
12418          } else {
12419            update.next = pending.next;
12420            pending.next = update;
12421          }
12422          queue.pending = update;
12423        }
12424        function entangleTransitionUpdate(root2, queue, lane) {
12425          if (isTransitionLane(lane)) {
12426            var queueLanes = queue.lanes;
12427            queueLanes = intersectLanes(queueLanes, root2.pendingLanes);
12428            var newQueueLanes = mergeLanes(queueLanes, lane);
12429            queue.lanes = newQueueLanes;
12430            markRootEntangled(root2, newQueueLanes);
12431          }
12432        }
12433        function markUpdateInDevTools(fiber, lane, action) {
12434          {
12435            markStateUpdateScheduled(fiber, lane);
12436          }
12437        }
12438        var ContextOnlyDispatcher = {
12439          readContext,
12440          useCallback: throwInvalidHookError,
12441          useContext: throwInvalidHookError,
12442          useEffect: throwInvalidHookError,
12443          useImperativeHandle: throwInvalidHookError,
12444          useInsertionEffect: throwInvalidHookError,
12445          useLayoutEffect: throwInvalidHookError,
12446          useMemo: throwInvalidHookError,
12447          useReducer: throwInvalidHookError,
12448          useRef: throwInvalidHookError,
12449          useState: throwInvalidHookError,
12450          useDebugValue: throwInvalidHookError,
12451          useDeferredValue: throwInvalidHookError,
12452          useTransition: throwInvalidHookError,
12453          useMutableSource: throwInvalidHookError,
12454          useSyncExternalStore: throwInvalidHookError,
12455          useId: throwInvalidHookError,
12456          unstable_isNewReconciler: enableNewReconciler
12457        };
12458        var HooksDispatcherOnMountInDEV = null;
12459        var HooksDispatcherOnMountWithHookTypesInDEV = null;
12460        var HooksDispatcherOnUpdateInDEV = null;
12461        var HooksDispatcherOnRerenderInDEV = null;
12462        var InvalidNestedHooksDispatcherOnMountInDEV = null;
12463        var InvalidNestedHooksDispatcherOnUpdateInDEV = null;
12464        var InvalidNestedHooksDispatcherOnRerenderInDEV = null;
12465        {
12466          var warnInvalidContextAccess = function() {
12467            error("Context can only be read while React is rendering. In classes, you can read it in the render method or getDerivedStateFromProps. In function components, you can read it directly in the function body, but not inside Hooks like useReducer() or useMemo().");
12468          };
12469          var warnInvalidHookAccess = function() {
12470            error("Do not call Hooks inside useEffect(...), useMemo(...), or other built-in Hooks. You can only call Hooks at the top level of your React function. For more information, see https://reactjs.org/link/rules-of-hooks");
12471          };
12472          HooksDispatcherOnMountInDEV = {
12473            readContext: function(context) {
12474              return readContext(context);
12475            },
12476            useCallback: function(callback, deps) {
12477              currentHookNameInDev = "useCallback";
12478              mountHookTypesDev();
12479              checkDepsAreArrayDev(deps);
12480              return mountCallback(callback, deps);
12481            },
12482            useContext: function(context) {
12483              currentHookNameInDev = "useContext";
12484              mountHookTypesDev();
12485              return readContext(context);
12486            },
12487            useEffect: function(create, deps) {
12488              currentHookNameInDev = "useEffect";
12489              mountHookTypesDev();
12490              checkDepsAreArrayDev(deps);
12491              return mountEffect(create, deps);
12492            },
12493            useImperativeHandle: function(ref, create, deps) {
12494              currentHookNameInDev = "useImperativeHandle";
12495              mountHookTypesDev();
12496              checkDepsAreArrayDev(deps);
12497              return mountImperativeHandle(ref, create, deps);
12498            },
12499            useInsertionEffect: function(create, deps) {
12500              currentHookNameInDev = "useInsertionEffect";
12501              mountHookTypesDev();
12502              checkDepsAreArrayDev(deps);
12503              return mountInsertionEffect(create, deps);
12504            },
12505            useLayoutEffect: function(create, deps) {
12506              currentHookNameInDev = "useLayoutEffect";
12507              mountHookTypesDev();
12508              checkDepsAreArrayDev(deps);
12509              return mountLayoutEffect(create, deps);
12510            },
12511            useMemo: function(create, deps) {
12512              currentHookNameInDev = "useMemo";
12513              mountHookTypesDev();
12514              checkDepsAreArrayDev(deps);
12515              var prevDispatcher = ReactCurrentDispatcher$1.current;
12516              ReactCurrentDispatcher$1.current = InvalidNestedHooksDispatcherOnMountInDEV;
12517              try {
12518                return mountMemo(create, deps);
12519              } finally {
12520                ReactCurrentDispatcher$1.current = prevDispatcher;
12521              }
12522            },
12523            useReducer: function(reducer, initialArg, init) {
12524              currentHookNameInDev = "useReducer";
12525              mountHookTypesDev();
12526              var prevDispatcher = ReactCurrentDispatcher$1.current;
12527              ReactCurrentDispatcher$1.current = InvalidNestedHooksDispatcherOnMountInDEV;
12528              try {
12529                return mountReducer(reducer, initialArg, init);
12530              } finally {
12531                ReactCurrentDispatcher$1.current = prevDispatcher;
12532              }
12533            },
12534            useRef: function(initialValue) {
12535              currentHookNameInDev = "useRef";
12536              mountHookTypesDev();
12537              return mountRef(initialValue);
12538            },
12539            useState: function(initialState) {
12540              currentHookNameInDev = "useState";
12541              mountHookTypesDev();
12542              var prevDispatcher = ReactCurrentDispatcher$1.current;
12543              ReactCurrentDispatcher$1.current = InvalidNestedHooksDispatcherOnMountInDEV;
12544              try {
12545                return mountState(initialState);
12546              } finally {
12547                ReactCurrentDispatcher$1.current = prevDispatcher;
12548              }
12549            },
12550            useDebugValue: function(value, formatterFn) {
12551              currentHookNameInDev = "useDebugValue";
12552              mountHookTypesDev();
12553              return mountDebugValue();
12554            },
12555            useDeferredValue: function(value) {
12556              currentHookNameInDev = "useDeferredValue";
12557              mountHookTypesDev();
12558              return mountDeferredValue(value);
12559            },
12560            useTransition: function() {
12561              currentHookNameInDev = "useTransition";
12562              mountHookTypesDev();
12563              return mountTransition();
12564            },
12565            useMutableSource: function(source, getSnapshot, subscribe) {
12566              currentHookNameInDev = "useMutableSource";
12567              mountHookTypesDev();
12568              return mountMutableSource();
12569            },
12570            useSyncExternalStore: function(subscribe, getSnapshot, getServerSnapshot) {
12571              currentHookNameInDev = "useSyncExternalStore";
12572              mountHookTypesDev();
12573              return mountSyncExternalStore(subscribe, getSnapshot, getServerSnapshot);
12574            },
12575            useId: function() {
12576              currentHookNameInDev = "useId";
12577              mountHookTypesDev();
12578              return mountId();
12579            },
12580            unstable_isNewReconciler: enableNewReconciler
12581          };
12582          HooksDispatcherOnMountWithHookTypesInDEV = {
12583            readContext: function(context) {
12584              return readContext(context);
12585            },
12586            useCallback: function(callback, deps) {
12587              currentHookNameInDev = "useCallback";
12588              updateHookTypesDev();
12589              return mountCallback(callback, deps);
12590            },
12591            useContext: function(context) {
12592              currentHookNameInDev = "useContext";
12593              updateHookTypesDev();
12594              return readContext(context);
12595            },
12596            useEffect: function(create, deps) {
12597              currentHookNameInDev = "useEffect";
12598              updateHookTypesDev();
12599              return mountEffect(create, deps);
12600            },
12601            useImperativeHandle: function(ref, create, deps) {
12602              currentHookNameInDev = "useImperativeHandle";
12603              updateHookTypesDev();
12604              return mountImperativeHandle(ref, create, deps);
12605            },
12606            useInsertionEffect: function(create, deps) {
12607              currentHookNameInDev = "useInsertionEffect";
12608              updateHookTypesDev();
12609              return mountInsertionEffect(create, deps);
12610            },
12611            useLayoutEffect: function(create, deps) {
12612              currentHookNameInDev = "useLayoutEffect";
12613              updateHookTypesDev();
12614              return mountLayoutEffect(create, deps);
12615            },
12616            useMemo: function(create, deps) {
12617              currentHookNameInDev = "useMemo";
12618              updateHookTypesDev();
12619              var prevDispatcher = ReactCurrentDispatcher$1.current;
12620              ReactCurrentDispatcher$1.current = InvalidNestedHooksDispatcherOnMountInDEV;
12621              try {
12622                return mountMemo(create, deps);
12623              } finally {
12624                ReactCurrentDispatcher$1.current = prevDispatcher;
12625              }
12626            },
12627            useReducer: function(reducer, initialArg, init) {
12628              currentHookNameInDev = "useReducer";
12629              updateHookTypesDev();
12630              var prevDispatcher = ReactCurrentDispatcher$1.current;
12631              ReactCurrentDispatcher$1.current = InvalidNestedHooksDispatcherOnMountInDEV;
12632              try {
12633                return mountReducer(reducer, initialArg, init);
12634              } finally {
12635                ReactCurrentDispatcher$1.current = prevDispatcher;
12636              }
12637            },
12638            useRef: function(initialValue) {
12639              currentHookNameInDev = "useRef";
12640              updateHookTypesDev();
12641              return mountRef(initialValue);
12642            },
12643            useState: function(initialState) {
12644              currentHookNameInDev = "useState";
12645              updateHookTypesDev();
12646              var prevDispatcher = ReactCurrentDispatcher$1.current;
12647              ReactCurrentDispatcher$1.current = InvalidNestedHooksDispatcherOnMountInDEV;
12648              try {
12649                return mountState(initialState);
12650              } finally {
12651                ReactCurrentDispatcher$1.current = prevDispatcher;
12652              }
12653            },
12654            useDebugValue: function(value, formatterFn) {
12655              currentHookNameInDev = "useDebugValue";
12656              updateHookTypesDev();
12657              return mountDebugValue();
12658            },
12659            useDeferredValue: function(value) {
12660              currentHookNameInDev = "useDeferredValue";
12661              updateHookTypesDev();
12662              return mountDeferredValue(value);
12663            },
12664            useTransition: function() {
12665              currentHookNameInDev = "useTransition";
12666              updateHookTypesDev();
12667              return mountTransition();
12668            },
12669            useMutableSource: function(source, getSnapshot, subscribe) {
12670              currentHookNameInDev = "useMutableSource";
12671              updateHookTypesDev();
12672              return mountMutableSource();
12673            },
12674            useSyncExternalStore: function(subscribe, getSnapshot, getServerSnapshot) {
12675              currentHookNameInDev = "useSyncExternalStore";
12676              updateHookTypesDev();
12677              return mountSyncExternalStore(subscribe, getSnapshot, getServerSnapshot);
12678            },
12679            useId: function() {
12680              currentHookNameInDev = "useId";
12681              updateHookTypesDev();
12682              return mountId();
12683            },
12684            unstable_isNewReconciler: enableNewReconciler
12685          };
12686          HooksDispatcherOnUpdateInDEV = {
12687            readContext: function(context) {
12688              return readContext(context);
12689            },
12690            useCallback: function(callback, deps) {
12691              currentHookNameInDev = "useCallback";
12692              updateHookTypesDev();
12693              return updateCallback(callback, deps);
12694            },
12695            useContext: function(context) {
12696              currentHookNameInDev = "useContext";
12697              updateHookTypesDev();
12698              return readContext(context);
12699            },
12700            useEffect: function(create, deps) {
12701              currentHookNameInDev = "useEffect";
12702              updateHookTypesDev();
12703              return updateEffect(create, deps);
12704            },
12705            useImperativeHandle: function(ref, create, deps) {
12706              currentHookNameInDev = "useImperativeHandle";
12707              updateHookTypesDev();
12708              return updateImperativeHandle(ref, create, deps);
12709            },
12710            useInsertionEffect: function(create, deps) {
12711              currentHookNameInDev = "useInsertionEffect";
12712              updateHookTypesDev();
12713              return updateInsertionEffect(create, deps);
12714            },
12715            useLayoutEffect: function(create, deps) {
12716              currentHookNameInDev = "useLayoutEffect";
12717              updateHookTypesDev();
12718              return updateLayoutEffect(create, deps);
12719            },
12720            useMemo: function(create, deps) {
12721              currentHookNameInDev = "useMemo";
12722              updateHookTypesDev();
12723              var prevDispatcher = ReactCurrentDispatcher$1.current;
12724              ReactCurrentDispatcher$1.current = InvalidNestedHooksDispatcherOnUpdateInDEV;
12725              try {
12726                return updateMemo(create, deps);
12727              } finally {
12728                ReactCurrentDispatcher$1.current = prevDispatcher;
12729              }
12730            },
12731            useReducer: function(reducer, initialArg, init) {
12732              currentHookNameInDev = "useReducer";
12733              updateHookTypesDev();
12734              var prevDispatcher = ReactCurrentDispatcher$1.current;
12735              ReactCurrentDispatcher$1.current = InvalidNestedHooksDispatcherOnUpdateInDEV;
12736              try {
12737                return updateReducer(reducer, initialArg, init);
12738              } finally {
12739                ReactCurrentDispatcher$1.current = prevDispatcher;
12740              }
12741            },
12742            useRef: function(initialValue) {
12743              currentHookNameInDev = "useRef";
12744              updateHookTypesDev();
12745              return updateRef();
12746            },
12747            useState: function(initialState) {
12748              currentHookNameInDev = "useState";
12749              updateHookTypesDev();
12750              var prevDispatcher = ReactCurrentDispatcher$1.current;
12751              ReactCurrentDispatcher$1.current = InvalidNestedHooksDispatcherOnUpdateInDEV;
12752              try {
12753                return updateState(initialState);
12754              } finally {
12755                ReactCurrentDispatcher$1.current = prevDispatcher;
12756              }
12757            },
12758            useDebugValue: function(value, formatterFn) {
12759              currentHookNameInDev = "useDebugValue";
12760              updateHookTypesDev();
12761              return updateDebugValue();
12762            },
12763            useDeferredValue: function(value) {
12764              currentHookNameInDev = "useDeferredValue";
12765              updateHookTypesDev();
12766              return updateDeferredValue(value);
12767            },
12768            useTransition: function() {
12769              currentHookNameInDev = "useTransition";
12770              updateHookTypesDev();
12771              return updateTransition();
12772            },
12773            useMutableSource: function(source, getSnapshot, subscribe) {
12774              currentHookNameInDev = "useMutableSource";
12775              updateHookTypesDev();
12776              return updateMutableSource();
12777            },
12778            useSyncExternalStore: function(subscribe, getSnapshot, getServerSnapshot) {
12779              currentHookNameInDev = "useSyncExternalStore";
12780              updateHookTypesDev();
12781              return updateSyncExternalStore(subscribe, getSnapshot);
12782            },
12783            useId: function() {
12784              currentHookNameInDev = "useId";
12785              updateHookTypesDev();
12786              return updateId();
12787            },
12788            unstable_isNewReconciler: enableNewReconciler
12789          };
12790          HooksDispatcherOnRerenderInDEV = {
12791            readContext: function(context) {
12792              return readContext(context);
12793            },
12794            useCallback: function(callback, deps) {
12795              currentHookNameInDev = "useCallback";
12796              updateHookTypesDev();
12797              return updateCallback(callback, deps);
12798            },
12799            useContext: function(context) {
12800              currentHookNameInDev = "useContext";
12801              updateHookTypesDev();
12802              return readContext(context);
12803            },
12804            useEffect: function(create, deps) {
12805              currentHookNameInDev = "useEffect";
12806              updateHookTypesDev();
12807              return updateEffect(create, deps);
12808            },
12809            useImperativeHandle: function(ref, create, deps) {
12810              currentHookNameInDev = "useImperativeHandle";
12811              updateHookTypesDev();
12812              return updateImperativeHandle(ref, create, deps);
12813            },
12814            useInsertionEffect: function(create, deps) {
12815              currentHookNameInDev = "useInsertionEffect";
12816              updateHookTypesDev();
12817              return updateInsertionEffect(create, deps);
12818            },
12819            useLayoutEffect: function(create, deps) {
12820              currentHookNameInDev = "useLayoutEffect";
12821              updateHookTypesDev();
12822              return updateLayoutEffect(create, deps);
12823            },
12824            useMemo: function(create, deps) {
12825              currentHookNameInDev = "useMemo";
12826              updateHookTypesDev();
12827              var prevDispatcher = ReactCurrentDispatcher$1.current;
12828              ReactCurrentDispatcher$1.current = InvalidNestedHooksDispatcherOnRerenderInDEV;
12829              try {
12830                return updateMemo(create, deps);
12831              } finally {
12832                ReactCurrentDispatcher$1.current = prevDispatcher;
12833              }
12834            },
12835            useReducer: function(reducer, initialArg, init) {
12836              currentHookNameInDev = "useReducer";
12837              updateHookTypesDev();
12838              var prevDispatcher = ReactCurrentDispatcher$1.current;
12839              ReactCurrentDispatcher$1.current = InvalidNestedHooksDispatcherOnRerenderInDEV;
12840              try {
12841                return rerenderReducer(reducer, initialArg, init);
12842              } finally {
12843                ReactCurrentDispatcher$1.current = prevDispatcher;
12844              }
12845            },
12846            useRef: function(initialValue) {
12847              currentHookNameInDev = "useRef";
12848              updateHookTypesDev();
12849              return updateRef();
12850            },
12851            useState: function(initialState) {
12852              currentHookNameInDev = "useState";
12853              updateHookTypesDev();
12854              var prevDispatcher = ReactCurrentDispatcher$1.current;
12855              ReactCurrentDispatcher$1.current = InvalidNestedHooksDispatcherOnRerenderInDEV;
12856              try {
12857                return rerenderState(initialState);
12858              } finally {
12859                ReactCurrentDispatcher$1.current = prevDispatcher;
12860              }
12861            },
12862            useDebugValue: function(value, formatterFn) {
12863              currentHookNameInDev = "useDebugValue";
12864              updateHookTypesDev();
12865              return updateDebugValue();
12866            },
12867            useDeferredValue: function(value) {
12868              currentHookNameInDev = "useDeferredValue";
12869              updateHookTypesDev();
12870              return rerenderDeferredValue(value);
12871            },
12872            useTransition: function() {
12873              currentHookNameInDev = "useTransition";
12874              updateHookTypesDev();
12875              return rerenderTransition();
12876            },
12877            useMutableSource: function(source, getSnapshot, subscribe) {
12878              currentHookNameInDev = "useMutableSource";
12879              updateHookTypesDev();
12880              return updateMutableSource();
12881            },
12882            useSyncExternalStore: function(subscribe, getSnapshot, getServerSnapshot) {
12883              currentHookNameInDev = "useSyncExternalStore";
12884              updateHookTypesDev();
12885              return updateSyncExternalStore(subscribe, getSnapshot);
12886            },
12887            useId: function() {
12888              currentHookNameInDev = "useId";
12889              updateHookTypesDev();
12890              return updateId();
12891            },
12892            unstable_isNewReconciler: enableNewReconciler
12893          };
12894          InvalidNestedHooksDispatcherOnMountInDEV = {
12895            readContext: function(context) {
12896              warnInvalidContextAccess();
12897              return readContext(context);
12898            },
12899            useCallback: function(callback, deps) {
12900              currentHookNameInDev = "useCallback";
12901              warnInvalidHookAccess();
12902              mountHookTypesDev();
12903              return mountCallback(callback, deps);
12904            },
12905            useContext: function(context) {
12906              currentHookNameInDev = "useContext";
12907              warnInvalidHookAccess();
12908              mountHookTypesDev();
12909              return readContext(context);
12910            },
12911            useEffect: function(create, deps) {
12912              currentHookNameInDev = "useEffect";
12913              warnInvalidHookAccess();
12914              mountHookTypesDev();
12915              return mountEffect(create, deps);
12916            },
12917            useImperativeHandle: function(ref, create, deps) {
12918              currentHookNameInDev = "useImperativeHandle";
12919              warnInvalidHookAccess();
12920              mountHookTypesDev();
12921              return mountImperativeHandle(ref, create, deps);
12922            },
12923            useInsertionEffect: function(create, deps) {
12924              currentHookNameInDev = "useInsertionEffect";
12925              warnInvalidHookAccess();
12926              mountHookTypesDev();
12927              return mountInsertionEffect(create, deps);
12928            },
12929            useLayoutEffect: function(create, deps) {
12930              currentHookNameInDev = "useLayoutEffect";
12931              warnInvalidHookAccess();
12932              mountHookTypesDev();
12933              return mountLayoutEffect(create, deps);
12934            },
12935            useMemo: function(create, deps) {
12936              currentHookNameInDev = "useMemo";
12937              warnInvalidHookAccess();
12938              mountHookTypesDev();
12939              var prevDispatcher = ReactCurrentDispatcher$1.current;
12940              ReactCurrentDispatcher$1.current = InvalidNestedHooksDispatcherOnMountInDEV;
12941              try {
12942                return mountMemo(create, deps);
12943              } finally {
12944                ReactCurrentDispatcher$1.current = prevDispatcher;
12945              }
12946            },
12947            useReducer: function(reducer, initialArg, init) {
12948              currentHookNameInDev = "useReducer";
12949              warnInvalidHookAccess();
12950              mountHookTypesDev();
12951              var prevDispatcher = ReactCurrentDispatcher$1.current;
12952              ReactCurrentDispatcher$1.current = InvalidNestedHooksDispatcherOnMountInDEV;
12953              try {
12954                return mountReducer(reducer, initialArg, init);
12955              } finally {
12956                ReactCurrentDispatcher$1.current = prevDispatcher;
12957              }
12958            },
12959            useRef: function(initialValue) {
12960              currentHookNameInDev = "useRef";
12961              warnInvalidHookAccess();
12962              mountHookTypesDev();
12963              return mountRef(initialValue);
12964            },
12965            useState: function(initialState) {
12966              currentHookNameInDev = "useState";
12967              warnInvalidHookAccess();
12968              mountHookTypesDev();
12969              var prevDispatcher = ReactCurrentDispatcher$1.current;
12970              ReactCurrentDispatcher$1.current = InvalidNestedHooksDispatcherOnMountInDEV;
12971              try {
12972                return mountState(initialState);
12973              } finally {
12974                ReactCurrentDispatcher$1.current = prevDispatcher;
12975              }
12976            },
12977            useDebugValue: function(value, formatterFn) {
12978              currentHookNameInDev = "useDebugValue";
12979              warnInvalidHookAccess();
12980              mountHookTypesDev();
12981              return mountDebugValue();
12982            },
12983            useDeferredValue: function(value) {
12984              currentHookNameInDev = "useDeferredValue";
12985              warnInvalidHookAccess();
12986              mountHookTypesDev();
12987              return mountDeferredValue(value);
12988            },
12989            useTransition: function() {
12990              currentHookNameInDev = "useTransition";
12991              warnInvalidHookAccess();
12992              mountHookTypesDev();
12993              return mountTransition();
12994            },
12995            useMutableSource: function(source, getSnapshot, subscribe) {
12996              currentHookNameInDev = "useMutableSource";
12997              warnInvalidHookAccess();
12998              mountHookTypesDev();
12999              return mountMutableSource();
13000            },
13001            useSyncExternalStore: function(subscribe, getSnapshot, getServerSnapshot) {
13002              currentHookNameInDev = "useSyncExternalStore";
13003              warnInvalidHookAccess();
13004              mountHookTypesDev();
13005              return mountSyncExternalStore(subscribe, getSnapshot, getServerSnapshot);
13006            },
13007            useId: function() {
13008              currentHookNameInDev = "useId";
13009              warnInvalidHookAccess();
13010              mountHookTypesDev();
13011              return mountId();
13012            },
13013            unstable_isNewReconciler: enableNewReconciler
13014          };
13015          InvalidNestedHooksDispatcherOnUpdateInDEV = {
13016            readContext: function(context) {
13017              warnInvalidContextAccess();
13018              return readContext(context);
13019            },
13020            useCallback: function(callback, deps) {
13021              currentHookNameInDev = "useCallback";
13022              warnInvalidHookAccess();
13023              updateHookTypesDev();
13024              return updateCallback(callback, deps);
13025            },
13026            useContext: function(context) {
13027              currentHookNameInDev = "useContext";
13028              warnInvalidHookAccess();
13029              updateHookTypesDev();
13030              return readContext(context);
13031            },
13032            useEffect: function(create, deps) {
13033              currentHookNameInDev = "useEffect";
13034              warnInvalidHookAccess();
13035              updateHookTypesDev();
13036              return updateEffect(create, deps);
13037            },
13038            useImperativeHandle: function(ref, create, deps) {
13039              currentHookNameInDev = "useImperativeHandle";
13040              warnInvalidHookAccess();
13041              updateHookTypesDev();
13042              return updateImperativeHandle(ref, create, deps);
13043            },
13044            useInsertionEffect: function(create, deps) {
13045              currentHookNameInDev = "useInsertionEffect";
13046              warnInvalidHookAccess();
13047              updateHookTypesDev();
13048              return updateInsertionEffect(create, deps);
13049            },
13050            useLayoutEffect: function(create, deps) {
13051              currentHookNameInDev = "useLayoutEffect";
13052              warnInvalidHookAccess();
13053              updateHookTypesDev();
13054              return updateLayoutEffect(create, deps);
13055            },
13056            useMemo: function(create, deps) {
13057              currentHookNameInDev = "useMemo";
13058              warnInvalidHookAccess();
13059              updateHookTypesDev();
13060              var prevDispatcher = ReactCurrentDispatcher$1.current;
13061              ReactCurrentDispatcher$1.current = InvalidNestedHooksDispatcherOnUpdateInDEV;
13062              try {
13063                return updateMemo(create, deps);
13064              } finally {
13065                ReactCurrentDispatcher$1.current = prevDispatcher;
13066              }
13067            },
13068            useReducer: function(reducer, initialArg, init) {
13069              currentHookNameInDev = "useReducer";
13070              warnInvalidHookAccess();
13071              updateHookTypesDev();
13072              var prevDispatcher = ReactCurrentDispatcher$1.current;
13073              ReactCurrentDispatcher$1.current = InvalidNestedHooksDispatcherOnUpdateInDEV;
13074              try {
13075                return updateReducer(reducer, initialArg, init);
13076              } finally {
13077                ReactCurrentDispatcher$1.current = prevDispatcher;
13078              }
13079            },
13080            useRef: function(initialValue) {
13081              currentHookNameInDev = "useRef";
13082              warnInvalidHookAccess();
13083              updateHookTypesDev();
13084              return updateRef();
13085            },
13086            useState: function(initialState) {
13087              currentHookNameInDev = "useState";
13088              warnInvalidHookAccess();
13089              updateHookTypesDev();
13090              var prevDispatcher = ReactCurrentDispatcher$1.current;
13091              ReactCurrentDispatcher$1.current = InvalidNestedHooksDispatcherOnUpdateInDEV;
13092              try {
13093                return updateState(initialState);
13094              } finally {
13095                ReactCurrentDispatcher$1.current = prevDispatcher;
13096              }
13097            },
13098            useDebugValue: function(value, formatterFn) {
13099              currentHookNameInDev = "useDebugValue";
13100              warnInvalidHookAccess();
13101              updateHookTypesDev();
13102              return updateDebugValue();
13103            },
13104            useDeferredValue: function(value) {
13105              currentHookNameInDev = "useDeferredValue";
13106              warnInvalidHookAccess();
13107              updateHookTypesDev();
13108              return updateDeferredValue(value);
13109            },
13110            useTransition: function() {
13111              currentHookNameInDev = "useTransition";
13112              warnInvalidHookAccess();
13113              updateHookTypesDev();
13114              return updateTransition();
13115            },
13116            useMutableSource: function(source, getSnapshot, subscribe) {
13117              currentHookNameInDev = "useMutableSource";
13118              warnInvalidHookAccess();
13119              updateHookTypesDev();
13120              return updateMutableSource();
13121            },
13122            useSyncExternalStore: function(subscribe, getSnapshot, getServerSnapshot) {
13123              currentHookNameInDev = "useSyncExternalStore";
13124              warnInvalidHookAccess();
13125              updateHookTypesDev();
13126              return updateSyncExternalStore(subscribe, getSnapshot);
13127            },
13128            useId: function() {
13129              currentHookNameInDev = "useId";
13130              warnInvalidHookAccess();
13131              updateHookTypesDev();
13132              return updateId();
13133            },
13134            unstable_isNewReconciler: enableNewReconciler
13135          };
13136          InvalidNestedHooksDispatcherOnRerenderInDEV = {
13137            readContext: function(context) {
13138              warnInvalidContextAccess();
13139              return readContext(context);
13140            },
13141            useCallback: function(callback, deps) {
13142              currentHookNameInDev = "useCallback";
13143              warnInvalidHookAccess();
13144              updateHookTypesDev();
13145              return updateCallback(callback, deps);
13146            },
13147            useContext: function(context) {
13148              currentHookNameInDev = "useContext";
13149              warnInvalidHookAccess();
13150              updateHookTypesDev();
13151              return readContext(context);
13152            },
13153            useEffect: function(create, deps) {
13154              currentHookNameInDev = "useEffect";
13155              warnInvalidHookAccess();
13156              updateHookTypesDev();
13157              return updateEffect(create, deps);
13158            },
13159            useImperativeHandle: function(ref, create, deps) {
13160              currentHookNameInDev = "useImperativeHandle";
13161              warnInvalidHookAccess();
13162              updateHookTypesDev();
13163              return updateImperativeHandle(ref, create, deps);
13164            },
13165            useInsertionEffect: function(create, deps) {
13166              currentHookNameInDev = "useInsertionEffect";
13167              warnInvalidHookAccess();
13168              updateHookTypesDev();
13169              return updateInsertionEffect(create, deps);
13170            },
13171            useLayoutEffect: function(create, deps) {
13172              currentHookNameInDev = "useLayoutEffect";
13173              warnInvalidHookAccess();
13174              updateHookTypesDev();
13175              return updateLayoutEffect(create, deps);
13176            },
13177            useMemo: function(create, deps) {
13178              currentHookNameInDev = "useMemo";
13179              warnInvalidHookAccess();
13180              updateHookTypesDev();
13181              var prevDispatcher = ReactCurrentDispatcher$1.current;
13182              ReactCurrentDispatcher$1.current = InvalidNestedHooksDispatcherOnUpdateInDEV;
13183              try {
13184                return updateMemo(create, deps);
13185              } finally {
13186                ReactCurrentDispatcher$1.current = prevDispatcher;
13187              }
13188            },
13189            useReducer: function(reducer, initialArg, init) {
13190              currentHookNameInDev = "useReducer";
13191              warnInvalidHookAccess();
13192              updateHookTypesDev();
13193              var prevDispatcher = ReactCurrentDispatcher$1.current;
13194              ReactCurrentDispatcher$1.current = InvalidNestedHooksDispatcherOnUpdateInDEV;
13195              try {
13196                return rerenderReducer(reducer, initialArg, init);
13197              } finally {
13198                ReactCurrentDispatcher$1.current = prevDispatcher;
13199              }
13200            },
13201            useRef: function(initialValue) {
13202              currentHookNameInDev = "useRef";
13203              warnInvalidHookAccess();
13204              updateHookTypesDev();
13205              return updateRef();
13206            },
13207            useState: function(initialState) {
13208              currentHookNameInDev = "useState";
13209              warnInvalidHookAccess();
13210              updateHookTypesDev();
13211              var prevDispatcher = ReactCurrentDispatcher$1.current;
13212              ReactCurrentDispatcher$1.current = InvalidNestedHooksDispatcherOnUpdateInDEV;
13213              try {
13214                return rerenderState(initialState);
13215              } finally {
13216                ReactCurrentDispatcher$1.current = prevDispatcher;
13217              }
13218            },
13219            useDebugValue: function(value, formatterFn) {
13220              currentHookNameInDev = "useDebugValue";
13221              warnInvalidHookAccess();
13222              updateHookTypesDev();
13223              return updateDebugValue();
13224            },
13225            useDeferredValue: function(value) {
13226              currentHookNameInDev = "useDeferredValue";
13227              warnInvalidHookAccess();
13228              updateHookTypesDev();
13229              return rerenderDeferredValue(value);
13230            },
13231            useTransition: function() {
13232              currentHookNameInDev = "useTransition";
13233              warnInvalidHookAccess();
13234              updateHookTypesDev();
13235              return rerenderTransition();
13236            },
13237            useMutableSource: function(source, getSnapshot, subscribe) {
13238              currentHookNameInDev = "useMutableSource";
13239              warnInvalidHookAccess();
13240              updateHookTypesDev();
13241              return updateMutableSource();
13242            },
13243            useSyncExternalStore: function(subscribe, getSnapshot, getServerSnapshot) {
13244              currentHookNameInDev = "useSyncExternalStore";
13245              warnInvalidHookAccess();
13246              updateHookTypesDev();
13247              return updateSyncExternalStore(subscribe, getSnapshot);
13248            },
13249            useId: function() {
13250              currentHookNameInDev = "useId";
13251              warnInvalidHookAccess();
13252              updateHookTypesDev();
13253              return updateId();
13254            },
13255            unstable_isNewReconciler: enableNewReconciler
13256          };
13257        }
13258        var now$1 = Scheduler.unstable_now;
13259        var commitTime = 0;
13260        var layoutEffectStartTime = -1;
13261        var profilerStartTime = -1;
13262        var passiveEffectStartTime = -1;
13263        var currentUpdateIsNested = false;
13264        var nestedUpdateScheduled = false;
13265        function isCurrentUpdateNested() {
13266          return currentUpdateIsNested;
13267        }
13268        function markNestedUpdateScheduled() {
13269          {
13270            nestedUpdateScheduled = true;
13271          }
13272        }
13273        function resetNestedUpdateFlag() {
13274          {
13275            currentUpdateIsNested = false;
13276            nestedUpdateScheduled = false;
13277          }
13278        }
13279        function syncNestedUpdateFlag() {
13280          {
13281            currentUpdateIsNested = nestedUpdateScheduled;
13282            nestedUpdateScheduled = false;
13283          }
13284        }
13285        function getCommitTime() {
13286          return commitTime;
13287        }
13288        function recordCommitTime() {
13289          commitTime = now$1();
13290        }
13291        function startProfilerTimer(fiber) {
13292          profilerStartTime = now$1();
13293          if (fiber.actualStartTime < 0) {
13294            fiber.actualStartTime = now$1();
13295          }
13296        }
13297        function stopProfilerTimerIfRunning(fiber) {
13298          profilerStartTime = -1;
13299        }
13300        function stopProfilerTimerIfRunningAndRecordDelta(fiber, overrideBaseTime) {
13301          if (profilerStartTime >= 0) {
13302            var elapsedTime = now$1() - profilerStartTime;
13303            fiber.actualDuration += elapsedTime;
13304            if (overrideBaseTime) {
13305              fiber.selfBaseDuration = elapsedTime;
13306            }
13307            profilerStartTime = -1;
13308          }
13309        }
13310        function recordLayoutEffectDuration(fiber) {
13311          if (layoutEffectStartTime >= 0) {
13312            var elapsedTime = now$1() - layoutEffectStartTime;
13313            layoutEffectStartTime = -1;
13314            var parentFiber = fiber.return;
13315            while (parentFiber !== null) {
13316              switch (parentFiber.tag) {
13317                case HostRoot:
13318                  var root2 = parentFiber.stateNode;
13319                  root2.effectDuration += elapsedTime;
13320                  return;
13321                case Profiler:
13322                  var parentStateNode = parentFiber.stateNode;
13323                  parentStateNode.effectDuration += elapsedTime;
13324                  return;
13325              }
13326              parentFiber = parentFiber.return;
13327            }
13328          }
13329        }
13330        function recordPassiveEffectDuration(fiber) {
13331          if (passiveEffectStartTime >= 0) {
13332            var elapsedTime = now$1() - passiveEffectStartTime;
13333            passiveEffectStartTime = -1;
13334            var parentFiber = fiber.return;
13335            while (parentFiber !== null) {
13336              switch (parentFiber.tag) {
13337                case HostRoot:
13338                  var root2 = parentFiber.stateNode;
13339                  if (root2 !== null) {
13340                    root2.passiveEffectDuration += elapsedTime;
13341                  }
13342                  return;
13343                case Profiler:
13344                  var parentStateNode = parentFiber.stateNode;
13345                  if (parentStateNode !== null) {
13346                    parentStateNode.passiveEffectDuration += elapsedTime;
13347                  }
13348                  return;
13349              }
13350              parentFiber = parentFiber.return;
13351            }
13352          }
13353        }
13354        function startLayoutEffectTimer() {
13355          layoutEffectStartTime = now$1();
13356        }
13357        function startPassiveEffectTimer() {
13358          passiveEffectStartTime = now$1();
13359        }
13360        function transferActualDuration(fiber) {
13361          var child = fiber.child;
13362          while (child) {
13363            fiber.actualDuration += child.actualDuration;
13364            child = child.sibling;
13365          }
13366        }
13367        function resolveDefaultProps(Component, baseProps) {
13368          if (Component && Component.defaultProps) {
13369            var props = assign({}, baseProps);
13370            var defaultProps = Component.defaultProps;
13371            for (var propName in defaultProps) {
13372              if (props[propName] === void 0) {
13373                props[propName] = defaultProps[propName];
13374              }
13375            }
13376            return props;
13377          }
13378          return baseProps;
13379        }
13380        var fakeInternalInstance = {};
13381        var didWarnAboutStateAssignmentForComponent;
13382        var didWarnAboutUninitializedState;
13383        var didWarnAboutGetSnapshotBeforeUpdateWithoutDidUpdate;
13384        var didWarnAboutLegacyLifecyclesAndDerivedState;
13385        var didWarnAboutUndefinedDerivedState;
13386        var warnOnUndefinedDerivedState;
13387        var warnOnInvalidCallback;
13388        var didWarnAboutDirectlyAssigningPropsToState;
13389        var didWarnAboutContextTypeAndContextTypes;
13390        var didWarnAboutInvalidateContextType;
13391        var didWarnAboutLegacyContext$1;
13392        {
13393          didWarnAboutStateAssignmentForComponent = /* @__PURE__ */ new Set();
13394          didWarnAboutUninitializedState = /* @__PURE__ */ new Set();
13395          didWarnAboutGetSnapshotBeforeUpdateWithoutDidUpdate = /* @__PURE__ */ new Set();
13396          didWarnAboutLegacyLifecyclesAndDerivedState = /* @__PURE__ */ new Set();
13397          didWarnAboutDirectlyAssigningPropsToState = /* @__PURE__ */ new Set();
13398          didWarnAboutUndefinedDerivedState = /* @__PURE__ */ new Set();
13399          didWarnAboutContextTypeAndContextTypes = /* @__PURE__ */ new Set();
13400          didWarnAboutInvalidateContextType = /* @__PURE__ */ new Set();
13401          didWarnAboutLegacyContext$1 = /* @__PURE__ */ new Set();
13402          var didWarnOnInvalidCallback = /* @__PURE__ */ new Set();
13403          warnOnInvalidCallback = function(callback, callerName) {
13404            if (callback === null || typeof callback === "function") {
13405              return;
13406            }
13407            var key = callerName + "_" + callback;
13408            if (!didWarnOnInvalidCallback.has(key)) {
13409              didWarnOnInvalidCallback.add(key);
13410              error("%s(...): Expected the last optional `callback` argument to be a function. Instead received: %s.", callerName, callback);
13411            }
13412          };
13413          warnOnUndefinedDerivedState = function(type, partialState) {
13414            if (partialState === void 0) {
13415              var componentName = getComponentNameFromType(type) || "Component";
13416              if (!didWarnAboutUndefinedDerivedState.has(componentName)) {
13417                didWarnAboutUndefinedDerivedState.add(componentName);
13418                error("%s.getDerivedStateFromProps(): A valid state object (or null) must be returned. You have returned undefined.", componentName);
13419              }
13420            }
13421          };
13422          Object.defineProperty(fakeInternalInstance, "_processChildContext", {
13423            enumerable: false,
13424            value: function() {
13425              throw new Error("_processChildContext is not available in React 16+. This likely means you have multiple copies of React and are attempting to nest a React 15 tree inside a React 16 tree using unstable_renderSubtreeIntoContainer, which isn't supported. Try to make sure you have only one copy of React (and ideally, switch to ReactDOM.createPortal).");
13426            }
13427          });
13428          Object.freeze(fakeInternalInstance);
13429        }
13430        function applyDerivedStateFromProps(workInProgress2, ctor, getDerivedStateFromProps, nextProps) {
13431          var prevState = workInProgress2.memoizedState;
13432          var partialState = getDerivedStateFromProps(nextProps, prevState);
13433          {
13434            if (workInProgress2.mode & StrictLegacyMode) {
13435              setIsStrictModeForDevtools(true);
13436              try {
13437                partialState = getDerivedStateFromProps(nextProps, prevState);
13438              } finally {
13439                setIsStrictModeForDevtools(false);
13440              }
13441            }
13442            warnOnUndefinedDerivedState(ctor, partialState);
13443          }
13444          var memoizedState = partialState === null || partialState === void 0 ? prevState : assign({}, prevState, partialState);
13445          workInProgress2.memoizedState = memoizedState;
13446          if (workInProgress2.lanes === NoLanes) {
13447            var updateQueue = workInProgress2.updateQueue;
13448            updateQueue.baseState = memoizedState;
13449          }
13450        }
13451        var classComponentUpdater = {
13452          isMounted,
13453          enqueueSetState: function(inst, payload, callback) {
13454            var fiber = get(inst);
13455            var eventTime = requestEventTime();
13456            var lane = requestUpdateLane(fiber);
13457            var update = createUpdate(eventTime, lane);
13458            update.payload = payload;
13459            if (callback !== void 0 && callback !== null) {
13460              {
13461                warnOnInvalidCallback(callback, "setState");
13462              }
13463              update.callback = callback;
13464            }
13465            var root2 = enqueueUpdate(fiber, update, lane);
13466            if (root2 !== null) {
13467              scheduleUpdateOnFiber(root2, fiber, lane, eventTime);
13468              entangleTransitions(root2, fiber, lane);
13469            }
13470            {
13471              markStateUpdateScheduled(fiber, lane);
13472            }
13473          },
13474          enqueueReplaceState: function(inst, payload, callback) {
13475            var fiber = get(inst);
13476            var eventTime = requestEventTime();
13477            var lane = requestUpdateLane(fiber);
13478            var update = createUpdate(eventTime, lane);
13479            update.tag = ReplaceState;
13480            update.payload = payload;
13481            if (callback !== void 0 && callback !== null) {
13482              {
13483                warnOnInvalidCallback(callback, "replaceState");
13484              }
13485              update.callback = callback;
13486            }
13487            var root2 = enqueueUpdate(fiber, update, lane);
13488            if (root2 !== null) {
13489              scheduleUpdateOnFiber(root2, fiber, lane, eventTime);
13490              entangleTransitions(root2, fiber, lane);
13491            }
13492            {
13493              markStateUpdateScheduled(fiber, lane);
13494            }
13495          },
13496          enqueueForceUpdate: function(inst, callback) {
13497            var fiber = get(inst);
13498            var eventTime = requestEventTime();
13499            var lane = requestUpdateLane(fiber);
13500            var update = createUpdate(eventTime, lane);
13501            update.tag = ForceUpdate;
13502            if (callback !== void 0 && callback !== null) {
13503              {
13504                warnOnInvalidCallback(callback, "forceUpdate");
13505              }
13506              update.callback = callback;
13507            }
13508            var root2 = enqueueUpdate(fiber, update, lane);
13509            if (root2 !== null) {
13510              scheduleUpdateOnFiber(root2, fiber, lane, eventTime);
13511              entangleTransitions(root2, fiber, lane);
13512            }
13513            {
13514              markForceUpdateScheduled(fiber, lane);
13515            }
13516          }
13517        };
13518        function checkShouldComponentUpdate(workInProgress2, ctor, oldProps, newProps, oldState, newState, nextContext) {
13519          var instance = workInProgress2.stateNode;
13520          if (typeof instance.shouldComponentUpdate === "function") {
13521            var shouldUpdate = instance.shouldComponentUpdate(newProps, newState, nextContext);
13522            {
13523              if (workInProgress2.mode & StrictLegacyMode) {
13524                setIsStrictModeForDevtools(true);
13525                try {
13526                  shouldUpdate = instance.shouldComponentUpdate(newProps, newState, nextContext);
13527                } finally {
13528                  setIsStrictModeForDevtools(false);
13529                }
13530              }
13531              if (shouldUpdate === void 0) {
13532                error("%s.shouldComponentUpdate(): Returned undefined instead of a boolean value. Make sure to return true or false.", getComponentNameFromType(ctor) || "Component");
13533              }
13534            }
13535            return shouldUpdate;
13536          }
13537          if (ctor.prototype && ctor.prototype.isPureReactComponent) {
13538            return !shallowEqual(oldProps, newProps) || !shallowEqual(oldState, newState);
13539          }
13540          return true;
13541        }
13542        function checkClassInstance(workInProgress2, ctor, newProps) {
13543          var instance = workInProgress2.stateNode;
13544          {
13545            var name = getComponentNameFromType(ctor) || "Component";
13546            var renderPresent = instance.render;
13547            if (!renderPresent) {
13548              if (ctor.prototype && typeof ctor.prototype.render === "function") {
13549                error("%s(...): No `render` method found on the returned component instance: did you accidentally return an object from the constructor?", name);
13550              } else {
13551                error("%s(...): No `render` method found on the returned component instance: you may have forgotten to define `render`.", name);
13552              }
13553            }
13554            if (instance.getInitialState && !instance.getInitialState.isReactClassApproved && !instance.state) {
13555              error("getInitialState was defined on %s, a plain JavaScript class. This is only supported for classes created using React.createClass. Did you mean to define a state property instead?", name);
13556            }
13557            if (instance.getDefaultProps && !instance.getDefaultProps.isReactClassApproved) {
13558              error("getDefaultProps was defined on %s, a plain JavaScript class. This is only supported for classes created using React.createClass. Use a static property to define defaultProps instead.", name);
13559            }
13560            if (instance.propTypes) {
13561              error("propTypes was defined as an instance property on %s. Use a static property to define propTypes instead.", name);
13562            }
13563            if (instance.contextType) {
13564              error("contextType was defined as an instance property on %s. Use a static property to define contextType instead.", name);
13565            }
13566            {
13567              if (ctor.childContextTypes && !didWarnAboutLegacyContext$1.has(ctor) && // Strict Mode has its own warning for legacy context, so we can skip
13568              // this one.
13569              (workInProgress2.mode & StrictLegacyMode) === NoMode) {
13570                didWarnAboutLegacyContext$1.add(ctor);
13571                error("%s uses the legacy childContextTypes API which is no longer supported and will be removed in the next major release. Use React.createContext() instead\n\n.Learn more about this warning here: https://reactjs.org/link/legacy-context", name);
13572              }
13573              if (ctor.contextTypes && !didWarnAboutLegacyContext$1.has(ctor) && // Strict Mode has its own warning for legacy context, so we can skip
13574              // this one.
13575              (workInProgress2.mode & StrictLegacyMode) === NoMode) {
13576                didWarnAboutLegacyContext$1.add(ctor);
13577                error("%s uses the legacy contextTypes API which is no longer supported and will be removed in the next major release. Use React.createContext() with static contextType instead.\n\nLearn more about this warning here: https://reactjs.org/link/legacy-context", name);
13578              }
13579              if (instance.contextTypes) {
13580                error("contextTypes was defined as an instance property on %s. Use a static property to define contextTypes instead.", name);
13581              }
13582              if (ctor.contextType && ctor.contextTypes && !didWarnAboutContextTypeAndContextTypes.has(ctor)) {
13583                didWarnAboutContextTypeAndContextTypes.add(ctor);
13584                error("%s declares both contextTypes and contextType static properties. The legacy contextTypes property will be ignored.", name);
13585              }
13586            }
13587            if (typeof instance.componentShouldUpdate === "function") {
13588              error("%s has a method called componentShouldUpdate(). Did you mean shouldComponentUpdate()? The name is phrased as a question because the function is expected to return a value.", name);
13589            }
13590            if (ctor.prototype && ctor.prototype.isPureReactComponent && typeof instance.shouldComponentUpdate !== "undefined") {
13591              error("%s has a method called shouldComponentUpdate(). shouldComponentUpdate should not be used when extending React.PureComponent. Please extend React.Component if shouldComponentUpdate is used.", getComponentNameFromType(ctor) || "A pure component");
13592            }
13593            if (typeof instance.componentDidUnmount === "function") {
13594              error("%s has a method called componentDidUnmount(). But there is no such lifecycle method. Did you mean componentWillUnmount()?", name);
13595            }
13596            if (typeof instance.componentDidReceiveProps === "function") {
13597              error("%s has a method called componentDidReceiveProps(). But there is no such lifecycle method. If you meant to update the state in response to changing props, use componentWillReceiveProps(). If you meant to fetch data or run side-effects or mutations after React has updated the UI, use componentDidUpdate().", name);
13598            }
13599            if (typeof instance.componentWillRecieveProps === "function") {
13600              error("%s has a method called componentWillRecieveProps(). Did you mean componentWillReceiveProps()?", name);
13601            }
13602            if (typeof instance.UNSAFE_componentWillRecieveProps === "function") {
13603              error("%s has a method called UNSAFE_componentWillRecieveProps(). Did you mean UNSAFE_componentWillReceiveProps()?", name);
13604            }
13605            var hasMutatedProps = instance.props !== newProps;
13606            if (instance.props !== void 0 && hasMutatedProps) {
13607              error("%s(...): When calling super() in `%s`, make sure to pass up the same props that your component's constructor was passed.", name, name);
13608            }
13609            if (instance.defaultProps) {
13610              error("Setting defaultProps as an instance property on %s is not supported and will be ignored. Instead, define defaultProps as a static property on %s.", name, name);
13611            }
13612            if (typeof instance.getSnapshotBeforeUpdate === "function" && typeof instance.componentDidUpdate !== "function" && !didWarnAboutGetSnapshotBeforeUpdateWithoutDidUpdate.has(ctor)) {
13613              didWarnAboutGetSnapshotBeforeUpdateWithoutDidUpdate.add(ctor);
13614              error("%s: getSnapshotBeforeUpdate() should be used with componentDidUpdate(). This component defines getSnapshotBeforeUpdate() only.", getComponentNameFromType(ctor));
13615            }
13616            if (typeof instance.getDerivedStateFromProps === "function") {
13617              error("%s: getDerivedStateFromProps() is defined as an instance method and will be ignored. Instead, declare it as a static method.", name);
13618            }
13619            if (typeof instance.getDerivedStateFromError === "function") {
13620              error("%s: getDerivedStateFromError() is defined as an instance method and will be ignored. Instead, declare it as a static method.", name);
13621            }
13622            if (typeof ctor.getSnapshotBeforeUpdate === "function") {
13623              error("%s: getSnapshotBeforeUpdate() is defined as a static method and will be ignored. Instead, declare it as an instance method.", name);
13624            }
13625            var _state = instance.state;
13626            if (_state && (typeof _state !== "object" || isArray(_state))) {
13627              error("%s.state: must be set to an object or null", name);
13628            }
13629            if (typeof instance.getChildContext === "function" && typeof ctor.childContextTypes !== "object") {
13630              error("%s.getChildContext(): childContextTypes must be defined in order to use getChildContext().", name);
13631            }
13632          }
13633        }
13634        function adoptClassInstance(workInProgress2, instance) {
13635          instance.updater = classComponentUpdater;
13636          workInProgress2.stateNode = instance;
13637          set(instance, workInProgress2);
13638          {
13639            instance._reactInternalInstance = fakeInternalInstance;
13640          }
13641        }
13642        function constructClassInstance(workInProgress2, ctor, props) {
13643          var isLegacyContextConsumer = false;
13644          var unmaskedContext = emptyContextObject;
13645          var context = emptyContextObject;
13646          var contextType = ctor.contextType;
13647          {
13648            if ("contextType" in ctor) {
13649              var isValid = (
13650                // Allow null for conditional declaration
13651                contextType === null || contextType !== void 0 && contextType.$$typeof === REACT_CONTEXT_TYPE && contextType._context === void 0
13652              );
13653              if (!isValid && !didWarnAboutInvalidateContextType.has(ctor)) {
13654                didWarnAboutInvalidateContextType.add(ctor);
13655                var addendum = "";
13656                if (contextType === void 0) {
13657                  addendum = " However, it is set to undefined. This can be caused by a typo or by mixing up named and default imports. This can also happen due to a circular dependency, so try moving the createContext() call to a separate file.";
13658                } else if (typeof contextType !== "object") {
13659                  addendum = " However, it is set to a " + typeof contextType + ".";
13660                } else if (contextType.$$typeof === REACT_PROVIDER_TYPE) {
13661                  addendum = " Did you accidentally pass the Context.Provider instead?";
13662                } else if (contextType._context !== void 0) {
13663                  addendum = " Did you accidentally pass the Context.Consumer instead?";
13664                } else {
13665                  addendum = " However, it is set to an object with keys {" + Object.keys(contextType).join(", ") + "}.";
13666                }
13667                error("%s defines an invalid contextType. contextType should point to the Context object returned by React.createContext().%s", getComponentNameFromType(ctor) || "Component", addendum);
13668              }
13669            }
13670          }
13671          if (typeof contextType === "object" && contextType !== null) {
13672            context = readContext(contextType);
13673          } else {
13674            unmaskedContext = getUnmaskedContext(workInProgress2, ctor, true);
13675            var contextTypes = ctor.contextTypes;
13676            isLegacyContextConsumer = contextTypes !== null && contextTypes !== void 0;
13677            context = isLegacyContextConsumer ? getMaskedContext(workInProgress2, unmaskedContext) : emptyContextObject;
13678          }
13679          var instance = new ctor(props, context);
13680          {
13681            if (workInProgress2.mode & StrictLegacyMode) {
13682              setIsStrictModeForDevtools(true);
13683              try {
13684                instance = new ctor(props, context);
13685              } finally {
13686                setIsStrictModeForDevtools(false);
13687              }
13688            }
13689          }
13690          var state = workInProgress2.memoizedState = instance.state !== null && instance.state !== void 0 ? instance.state : null;
13691          adoptClassInstance(workInProgress2, instance);
13692          {
13693            if (typeof ctor.getDerivedStateFromProps === "function" && state === null) {
13694              var componentName = getComponentNameFromType(ctor) || "Component";
13695              if (!didWarnAboutUninitializedState.has(componentName)) {
13696                didWarnAboutUninitializedState.add(componentName);
13697                error("`%s` uses `getDerivedStateFromProps` but its initial state is %s. This is not recommended. Instead, define the initial state by assigning an object to `this.state` in the constructor of `%s`. This ensures that `getDerivedStateFromProps` arguments have a consistent shape.", componentName, instance.state === null ? "null" : "undefined", componentName);
13698              }
13699            }
13700            if (typeof ctor.getDerivedStateFromProps === "function" || typeof instance.getSnapshotBeforeUpdate === "function") {
13701              var foundWillMountName = null;
13702              var foundWillReceivePropsName = null;
13703              var foundWillUpdateName = null;
13704              if (typeof instance.componentWillMount === "function" && instance.componentWillMount.__suppressDeprecationWarning !== true) {
13705                foundWillMountName = "componentWillMount";
13706              } else if (typeof instance.UNSAFE_componentWillMount === "function") {
13707                foundWillMountName = "UNSAFE_componentWillMount";
13708              }
13709              if (typeof instance.componentWillReceiveProps === "function" && instance.componentWillReceiveProps.__suppressDeprecationWarning !== true) {
13710                foundWillReceivePropsName = "componentWillReceiveProps";
13711              } else if (typeof instance.UNSAFE_componentWillReceiveProps === "function") {
13712                foundWillReceivePropsName = "UNSAFE_componentWillReceiveProps";
13713              }
13714              if (typeof instance.componentWillUpdate === "function" && instance.componentWillUpdate.__suppressDeprecationWarning !== true) {
13715                foundWillUpdateName = "componentWillUpdate";
13716              } else if (typeof instance.UNSAFE_componentWillUpdate === "function") {
13717                foundWillUpdateName = "UNSAFE_componentWillUpdate";
13718              }
13719              if (foundWillMountName !== null || foundWillReceivePropsName !== null || foundWillUpdateName !== null) {
13720                var _componentName = getComponentNameFromType(ctor) || "Component";
13721                var newApiName = typeof ctor.getDerivedStateFromProps === "function" ? "getDerivedStateFromProps()" : "getSnapshotBeforeUpdate()";
13722                if (!didWarnAboutLegacyLifecyclesAndDerivedState.has(_componentName)) {
13723                  didWarnAboutLegacyLifecyclesAndDerivedState.add(_componentName);
13724                  error("Unsafe legacy lifecycles will not be called for components using new component APIs.\n\n%s uses %s but also contains the following legacy lifecycles:%s%s%s\n\nThe above lifecycles should be removed. Learn more about this warning here:\nhttps://reactjs.org/link/unsafe-component-lifecycles", _componentName, newApiName, foundWillMountName !== null ? "\n  " + foundWillMountName : "", foundWillReceivePropsName !== null ? "\n  " + foundWillReceivePropsName : "", foundWillUpdateName !== null ? "\n  " + foundWillUpdateName : "");
13725                }
13726              }
13727            }
13728          }
13729          if (isLegacyContextConsumer) {
13730            cacheContext(workInProgress2, unmaskedContext, context);
13731          }
13732          return instance;
13733        }
13734        function callComponentWillMount(workInProgress2, instance) {
13735          var oldState = instance.state;
13736          if (typeof instance.componentWillMount === "function") {
13737            instance.componentWillMount();
13738          }
13739          if (typeof instance.UNSAFE_componentWillMount === "function") {
13740            instance.UNSAFE_componentWillMount();
13741          }
13742          if (oldState !== instance.state) {
13743            {
13744              error("%s.componentWillMount(): Assigning directly to this.state is deprecated (except inside a component's constructor). Use setState instead.", getComponentNameFromFiber(workInProgress2) || "Component");
13745            }
13746            classComponentUpdater.enqueueReplaceState(instance, instance.state, null);
13747          }
13748        }
13749        function callComponentWillReceiveProps(workInProgress2, instance, newProps, nextContext) {
13750          var oldState = instance.state;
13751          if (typeof instance.componentWillReceiveProps === "function") {
13752            instance.componentWillReceiveProps(newProps, nextContext);
13753          }
13754          if (typeof instance.UNSAFE_componentWillReceiveProps === "function") {
13755            instance.UNSAFE_componentWillReceiveProps(newProps, nextContext);
13756          }
13757          if (instance.state !== oldState) {
13758            {
13759              var componentName = getComponentNameFromFiber(workInProgress2) || "Component";
13760              if (!didWarnAboutStateAssignmentForComponent.has(componentName)) {
13761                didWarnAboutStateAssignmentForComponent.add(componentName);
13762                error("%s.componentWillReceiveProps(): Assigning directly to this.state is deprecated (except inside a component's constructor). Use setState instead.", componentName);
13763              }
13764            }
13765            classComponentUpdater.enqueueReplaceState(instance, instance.state, null);
13766          }
13767        }
13768        function mountClassInstance(workInProgress2, ctor, newProps, renderLanes2) {
13769          {
13770            checkClassInstance(workInProgress2, ctor, newProps);
13771          }
13772          var instance = workInProgress2.stateNode;
13773          instance.props = newProps;
13774          instance.state = workInProgress2.memoizedState;
13775          instance.refs = {};
13776          initializeUpdateQueue(workInProgress2);
13777          var contextType = ctor.contextType;
13778          if (typeof contextType === "object" && contextType !== null) {
13779            instance.context = readContext(contextType);
13780          } else {
13781            var unmaskedContext = getUnmaskedContext(workInProgress2, ctor, true);
13782            instance.context = getMaskedContext(workInProgress2, unmaskedContext);
13783          }
13784          {
13785            if (instance.state === newProps) {
13786              var componentName = getComponentNameFromType(ctor) || "Component";
13787              if (!didWarnAboutDirectlyAssigningPropsToState.has(componentName)) {
13788                didWarnAboutDirectlyAssigningPropsToState.add(componentName);
13789                error("%s: It is not recommended to assign props directly to state because updates to props won't be reflected in state. In most cases, it is better to use props directly.", componentName);
13790              }
13791            }
13792            if (workInProgress2.mode & StrictLegacyMode) {
13793              ReactStrictModeWarnings.recordLegacyContextWarning(workInProgress2, instance);
13794            }
13795            {
13796              ReactStrictModeWarnings.recordUnsafeLifecycleWarnings(workInProgress2, instance);
13797            }
13798          }
13799          instance.state = workInProgress2.memoizedState;
13800          var getDerivedStateFromProps = ctor.getDerivedStateFromProps;
13801          if (typeof getDerivedStateFromProps === "function") {
13802            applyDerivedStateFromProps(workInProgress2, ctor, getDerivedStateFromProps, newProps);
13803            instance.state = workInProgress2.memoizedState;
13804          }
13805          if (typeof ctor.getDerivedStateFromProps !== "function" && typeof instance.getSnapshotBeforeUpdate !== "function" && (typeof instance.UNSAFE_componentWillMount === "function" || typeof instance.componentWillMount === "function")) {
13806            callComponentWillMount(workInProgress2, instance);
13807            processUpdateQueue(workInProgress2, newProps, instance, renderLanes2);
13808            instance.state = workInProgress2.memoizedState;
13809          }
13810          if (typeof instance.componentDidMount === "function") {
13811            var fiberFlags = Update;
13812            {
13813              fiberFlags |= LayoutStatic;
13814            }
13815            if ((workInProgress2.mode & StrictEffectsMode) !== NoMode) {
13816              fiberFlags |= MountLayoutDev;
13817            }
13818            workInProgress2.flags |= fiberFlags;
13819          }
13820        }
13821        function resumeMountClassInstance(workInProgress2, ctor, newProps, renderLanes2) {
13822          var instance = workInProgress2.stateNode;
13823          var oldProps = workInProgress2.memoizedProps;
13824          instance.props = oldProps;
13825          var oldContext = instance.context;
13826          var contextType = ctor.contextType;
13827          var nextContext = emptyContextObject;
13828          if (typeof contextType === "object" && contextType !== null) {
13829            nextContext = readContext(contextType);
13830          } else {
13831            var nextLegacyUnmaskedContext = getUnmaskedContext(workInProgress2, ctor, true);
13832            nextContext = getMaskedContext(workInProgress2, nextLegacyUnmaskedContext);
13833          }
13834          var getDerivedStateFromProps = ctor.getDerivedStateFromProps;
13835          var hasNewLifecycles = typeof getDerivedStateFromProps === "function" || typeof instance.getSnapshotBeforeUpdate === "function";
13836          if (!hasNewLifecycles && (typeof instance.UNSAFE_componentWillReceiveProps === "function" || typeof instance.componentWillReceiveProps === "function")) {
13837            if (oldProps !== newProps || oldContext !== nextContext) {
13838              callComponentWillReceiveProps(workInProgress2, instance, newProps, nextContext);
13839            }
13840          }
13841          resetHasForceUpdateBeforeProcessing();
13842          var oldState = workInProgress2.memoizedState;
13843          var newState = instance.state = oldState;
13844          processUpdateQueue(workInProgress2, newProps, instance, renderLanes2);
13845          newState = workInProgress2.memoizedState;
13846          if (oldProps === newProps && oldState === newState && !hasContextChanged() && !checkHasForceUpdateAfterProcessing()) {
13847            if (typeof instance.componentDidMount === "function") {
13848              var fiberFlags = Update;
13849              {
13850                fiberFlags |= LayoutStatic;
13851              }
13852              if ((workInProgress2.mode & StrictEffectsMode) !== NoMode) {
13853                fiberFlags |= MountLayoutDev;
13854              }
13855              workInProgress2.flags |= fiberFlags;
13856            }
13857            return false;
13858          }
13859          if (typeof getDerivedStateFromProps === "function") {
13860            applyDerivedStateFromProps(workInProgress2, ctor, getDerivedStateFromProps, newProps);
13861            newState = workInProgress2.memoizedState;
13862          }
13863          var shouldUpdate = checkHasForceUpdateAfterProcessing() || checkShouldComponentUpdate(workInProgress2, ctor, oldProps, newProps, oldState, newState, nextContext);
13864          if (shouldUpdate) {
13865            if (!hasNewLifecycles && (typeof instance.UNSAFE_componentWillMount === "function" || typeof instance.componentWillMount === "function")) {
13866              if (typeof instance.componentWillMount === "function") {
13867                instance.componentWillMount();
13868              }
13869              if (typeof instance.UNSAFE_componentWillMount === "function") {
13870                instance.UNSAFE_componentWillMount();
13871              }
13872            }
13873            if (typeof instance.componentDidMount === "function") {
13874              var _fiberFlags = Update;
13875              {
13876                _fiberFlags |= LayoutStatic;
13877              }
13878              if ((workInProgress2.mode & StrictEffectsMode) !== NoMode) {
13879                _fiberFlags |= MountLayoutDev;
13880              }
13881              workInProgress2.flags |= _fiberFlags;
13882            }
13883          } else {
13884            if (typeof instance.componentDidMount === "function") {
13885              var _fiberFlags2 = Update;
13886              {
13887                _fiberFlags2 |= LayoutStatic;
13888              }
13889              if ((workInProgress2.mode & StrictEffectsMode) !== NoMode) {
13890                _fiberFlags2 |= MountLayoutDev;
13891              }
13892              workInProgress2.flags |= _fiberFlags2;
13893            }
13894            workInProgress2.memoizedProps = newProps;
13895            workInProgress2.memoizedState = newState;
13896          }
13897          instance.props = newProps;
13898          instance.state = newState;
13899          instance.context = nextContext;
13900          return shouldUpdate;
13901        }
13902        function updateClassInstance(current2, workInProgress2, ctor, newProps, renderLanes2) {
13903          var instance = workInProgress2.stateNode;
13904          cloneUpdateQueue(current2, workInProgress2);
13905          var unresolvedOldProps = workInProgress2.memoizedProps;
13906          var oldProps = workInProgress2.type === workInProgress2.elementType ? unresolvedOldProps : resolveDefaultProps(workInProgress2.type, unresolvedOldProps);
13907          instance.props = oldProps;
13908          var unresolvedNewProps = workInProgress2.pendingProps;
13909          var oldContext = instance.context;
13910          var contextType = ctor.contextType;
13911          var nextContext = emptyContextObject;
13912          if (typeof contextType === "object" && contextType !== null) {
13913            nextContext = readContext(contextType);
13914          } else {
13915            var nextUnmaskedContext = getUnmaskedContext(workInProgress2, ctor, true);
13916            nextContext = getMaskedContext(workInProgress2, nextUnmaskedContext);
13917          }
13918          var getDerivedStateFromProps = ctor.getDerivedStateFromProps;
13919          var hasNewLifecycles = typeof getDerivedStateFromProps === "function" || typeof instance.getSnapshotBeforeUpdate === "function";
13920          if (!hasNewLifecycles && (typeof instance.UNSAFE_componentWillReceiveProps === "function" || typeof instance.componentWillReceiveProps === "function")) {
13921            if (unresolvedOldProps !== unresolvedNewProps || oldContext !== nextContext) {
13922              callComponentWillReceiveProps(workInProgress2, instance, newProps, nextContext);
13923            }
13924          }
13925          resetHasForceUpdateBeforeProcessing();
13926          var oldState = workInProgress2.memoizedState;
13927          var newState = instance.state = oldState;
13928          processUpdateQueue(workInProgress2, newProps, instance, renderLanes2);
13929          newState = workInProgress2.memoizedState;
13930          if (unresolvedOldProps === unresolvedNewProps && oldState === newState && !hasContextChanged() && !checkHasForceUpdateAfterProcessing() && !enableLazyContextPropagation) {
13931            if (typeof instance.componentDidUpdate === "function") {
13932              if (unresolvedOldProps !== current2.memoizedProps || oldState !== current2.memoizedState) {
13933                workInProgress2.flags |= Update;
13934              }
13935            }
13936            if (typeof instance.getSnapshotBeforeUpdate === "function") {
13937              if (unresolvedOldProps !== current2.memoizedProps || oldState !== current2.memoizedState) {
13938                workInProgress2.flags |= Snapshot;
13939              }
13940            }
13941            return false;
13942          }
13943          if (typeof getDerivedStateFromProps === "function") {
13944            applyDerivedStateFromProps(workInProgress2, ctor, getDerivedStateFromProps, newProps);
13945            newState = workInProgress2.memoizedState;
13946          }
13947          var shouldUpdate = checkHasForceUpdateAfterProcessing() || checkShouldComponentUpdate(workInProgress2, ctor, oldProps, newProps, oldState, newState, nextContext) || // TODO: In some cases, we'll end up checking if context has changed twice,
13948          // both before and after `shouldComponentUpdate` has been called. Not ideal,
13949          // but I'm loath to refactor this function. This only happens for memoized
13950          // components so it's not that common.
13951          enableLazyContextPropagation;
13952          if (shouldUpdate) {
13953            if (!hasNewLifecycles && (typeof instance.UNSAFE_componentWillUpdate === "function" || typeof instance.componentWillUpdate === "function")) {
13954              if (typeof instance.componentWillUpdate === "function") {
13955                instance.componentWillUpdate(newProps, newState, nextContext);
13956              }
13957              if (typeof instance.UNSAFE_componentWillUpdate === "function") {
13958                instance.UNSAFE_componentWillUpdate(newProps, newState, nextContext);
13959              }
13960            }
13961            if (typeof instance.componentDidUpdate === "function") {
13962              workInProgress2.flags |= Update;
13963            }
13964            if (typeof instance.getSnapshotBeforeUpdate === "function") {
13965              workInProgress2.flags |= Snapshot;
13966            }
13967          } else {
13968            if (typeof instance.componentDidUpdate === "function") {
13969              if (unresolvedOldProps !== current2.memoizedProps || oldState !== current2.memoizedState) {
13970                workInProgress2.flags |= Update;
13971              }
13972            }
13973            if (typeof instance.getSnapshotBeforeUpdate === "function") {
13974              if (unresolvedOldProps !== current2.memoizedProps || oldState !== current2.memoizedState) {
13975                workInProgress2.flags |= Snapshot;
13976              }
13977            }
13978            workInProgress2.memoizedProps = newProps;
13979            workInProgress2.memoizedState = newState;
13980          }
13981          instance.props = newProps;
13982          instance.state = newState;
13983          instance.context = nextContext;
13984          return shouldUpdate;
13985        }
13986        function createCapturedValueAtFiber(value, source) {
13987          return {
13988            value,
13989            source,
13990            stack: getStackByFiberInDevAndProd(source),
13991            digest: null
13992          };
13993        }
13994        function createCapturedValue(value, digest, stack) {
13995          return {
13996            value,
13997            source: null,
13998            stack: stack != null ? stack : null,
13999            digest: digest != null ? digest : null
14000          };
14001        }
14002        function showErrorDialog(boundary, errorInfo) {
14003          return true;
14004        }
14005        function logCapturedError(boundary, errorInfo) {
14006          try {
14007            var logError = showErrorDialog(boundary, errorInfo);
14008            if (logError === false) {
14009              return;
14010            }
14011            var error2 = errorInfo.value;
14012            if (true) {
14013              var source = errorInfo.source;
14014              var stack = errorInfo.stack;
14015              var componentStack = stack !== null ? stack : "";
14016              if (error2 != null && error2._suppressLogging) {
14017                if (boundary.tag === ClassComponent) {
14018                  return;
14019                }
14020                console["error"](error2);
14021              }
14022              var componentName = source ? getComponentNameFromFiber(source) : null;
14023              var componentNameMessage = componentName ? "The above error occurred in the <" + componentName + "> component:" : "The above error occurred in one of your React components:";
14024              var errorBoundaryMessage;
14025              if (boundary.tag === HostRoot) {
14026                errorBoundaryMessage = "Consider adding an error boundary to your tree to customize error handling behavior.\nVisit https://reactjs.org/link/error-boundaries to learn more about error boundaries.";
14027              } else {
14028                var errorBoundaryName = getComponentNameFromFiber(boundary) || "Anonymous";
14029                errorBoundaryMessage = "React will try to recreate this component tree from scratch " + ("using the error boundary you provided, " + errorBoundaryName + ".");
14030              }
14031              var combinedMessage = componentNameMessage + "\n" + componentStack + "\n\n" + ("" + errorBoundaryMessage);
14032              console["error"](combinedMessage);
14033            } else {
14034              console["error"](error2);
14035            }
14036          } catch (e) {
14037            setTimeout(function() {
14038              throw e;
14039            });
14040          }
14041        }
14042        var PossiblyWeakMap$1 = typeof WeakMap === "function" ? WeakMap : Map;
14043        function createRootErrorUpdate(fiber, errorInfo, lane) {
14044          var update = createUpdate(NoTimestamp, lane);
14045          update.tag = CaptureUpdate;
14046          update.payload = {
14047            element: null
14048          };
14049          var error2 = errorInfo.value;
14050          update.callback = function() {
14051            onUncaughtError(error2);
14052            logCapturedError(fiber, errorInfo);
14053          };
14054          return update;
14055        }
14056        function createClassErrorUpdate(fiber, errorInfo, lane) {
14057          var update = createUpdate(NoTimestamp, lane);
14058          update.tag = CaptureUpdate;
14059          var getDerivedStateFromError = fiber.type.getDerivedStateFromError;
14060          if (typeof getDerivedStateFromError === "function") {
14061            var error$1 = errorInfo.value;
14062            update.payload = function() {
14063              return getDerivedStateFromError(error$1);
14064            };
14065            update.callback = function() {
14066              {
14067                markFailedErrorBoundaryForHotReloading(fiber);
14068              }
14069              logCapturedError(fiber, errorInfo);
14070            };
14071          }
14072          var inst = fiber.stateNode;
14073          if (inst !== null && typeof inst.componentDidCatch === "function") {
14074            update.callback = function callback() {
14075              {
14076                markFailedErrorBoundaryForHotReloading(fiber);
14077              }
14078              logCapturedError(fiber, errorInfo);
14079              if (typeof getDerivedStateFromError !== "function") {
14080                markLegacyErrorBoundaryAsFailed(this);
14081              }
14082              var error$12 = errorInfo.value;
14083              var stack = errorInfo.stack;
14084              this.componentDidCatch(error$12, {
14085                componentStack: stack !== null ? stack : ""
14086              });
14087              {
14088                if (typeof getDerivedStateFromError !== "function") {
14089                  if (!includesSomeLane(fiber.lanes, SyncLane)) {
14090                    error("%s: Error boundaries should implement getDerivedStateFromError(). In that method, return a state update to display an error message or fallback UI.", getComponentNameFromFiber(fiber) || "Unknown");
14091                  }
14092                }
14093              }
14094            };
14095          }
14096          return update;
14097        }
14098        function attachPingListener(root2, wakeable, lanes) {
14099          var pingCache = root2.pingCache;
14100          var threadIDs;
14101          if (pingCache === null) {
14102            pingCache = root2.pingCache = new PossiblyWeakMap$1();
14103            threadIDs = /* @__PURE__ */ new Set();
14104            pingCache.set(wakeable, threadIDs);
14105          } else {
14106            threadIDs = pingCache.get(wakeable);
14107            if (threadIDs === void 0) {
14108              threadIDs = /* @__PURE__ */ new Set();
14109              pingCache.set(wakeable, threadIDs);
14110            }
14111          }
14112          if (!threadIDs.has(lanes)) {
14113            threadIDs.add(lanes);
14114            var ping = pingSuspendedRoot.bind(null, root2, wakeable, lanes);
14115            {
14116              if (isDevToolsPresent) {
14117                restorePendingUpdaters(root2, lanes);
14118              }
14119            }
14120            wakeable.then(ping, ping);
14121          }
14122        }
14123        function attachRetryListener(suspenseBoundary, root2, wakeable, lanes) {
14124          var wakeables = suspenseBoundary.updateQueue;
14125          if (wakeables === null) {
14126            var updateQueue = /* @__PURE__ */ new Set();
14127            updateQueue.add(wakeable);
14128            suspenseBoundary.updateQueue = updateQueue;
14129          } else {
14130            wakeables.add(wakeable);
14131          }
14132        }
14133        function resetSuspendedComponent(sourceFiber, rootRenderLanes) {
14134          var tag = sourceFiber.tag;
14135          if ((sourceFiber.mode & ConcurrentMode) === NoMode && (tag === FunctionComponent || tag === ForwardRef || tag === SimpleMemoComponent)) {
14136            var currentSource = sourceFiber.alternate;
14137            if (currentSource) {
14138              sourceFiber.updateQueue = currentSource.updateQueue;
14139              sourceFiber.memoizedState = currentSource.memoizedState;
14140              sourceFiber.lanes = currentSource.lanes;
14141            } else {
14142              sourceFiber.updateQueue = null;
14143              sourceFiber.memoizedState = null;
14144            }
14145          }
14146        }
14147        function getNearestSuspenseBoundaryToCapture(returnFiber) {
14148          var node = returnFiber;
14149          do {
14150            if (node.tag === SuspenseComponent && shouldCaptureSuspense(node)) {
14151              return node;
14152            }
14153            node = node.return;
14154          } while (node !== null);
14155          return null;
14156        }
14157        function markSuspenseBoundaryShouldCapture(suspenseBoundary, returnFiber, sourceFiber, root2, rootRenderLanes) {
14158          if ((suspenseBoundary.mode & ConcurrentMode) === NoMode) {
14159            if (suspenseBoundary === returnFiber) {
14160              suspenseBoundary.flags |= ShouldCapture;
14161            } else {
14162              suspenseBoundary.flags |= DidCapture;
14163              sourceFiber.flags |= ForceUpdateForLegacySuspense;
14164              sourceFiber.flags &= ~(LifecycleEffectMask | Incomplete);
14165              if (sourceFiber.tag === ClassComponent) {
14166                var currentSourceFiber = sourceFiber.alternate;
14167                if (currentSourceFiber === null) {
14168                  sourceFiber.tag = IncompleteClassComponent;
14169                } else {
14170                  var update = createUpdate(NoTimestamp, SyncLane);
14171                  update.tag = ForceUpdate;
14172                  enqueueUpdate(sourceFiber, update, SyncLane);
14173                }
14174              }
14175              sourceFiber.lanes = mergeLanes(sourceFiber.lanes, SyncLane);
14176            }
14177            return suspenseBoundary;
14178          }
14179          suspenseBoundary.flags |= ShouldCapture;
14180          suspenseBoundary.lanes = rootRenderLanes;
14181          return suspenseBoundary;
14182        }
14183        function throwException(root2, returnFiber, sourceFiber, value, rootRenderLanes) {
14184          sourceFiber.flags |= Incomplete;
14185          {
14186            if (isDevToolsPresent) {
14187              restorePendingUpdaters(root2, rootRenderLanes);
14188            }
14189          }
14190          if (value !== null && typeof value === "object" && typeof value.then === "function") {
14191            var wakeable = value;
14192            resetSuspendedComponent(sourceFiber);
14193            {
14194              if (getIsHydrating() && sourceFiber.mode & ConcurrentMode) {
14195                markDidThrowWhileHydratingDEV();
14196              }
14197            }
14198            var suspenseBoundary = getNearestSuspenseBoundaryToCapture(returnFiber);
14199            if (suspenseBoundary !== null) {
14200              suspenseBoundary.flags &= ~ForceClientRender;
14201              markSuspenseBoundaryShouldCapture(suspenseBoundary, returnFiber, sourceFiber, root2, rootRenderLanes);
14202              if (suspenseBoundary.mode & ConcurrentMode) {
14203                attachPingListener(root2, wakeable, rootRenderLanes);
14204              }
14205              attachRetryListener(suspenseBoundary, root2, wakeable);
14206              return;
14207            } else {
14208              if (!includesSyncLane(rootRenderLanes)) {
14209                attachPingListener(root2, wakeable, rootRenderLanes);
14210                renderDidSuspendDelayIfPossible();
14211                return;
14212              }
14213              var uncaughtSuspenseError = new Error("A component suspended while responding to synchronous input. This will cause the UI to be replaced with a loading indicator. To fix, updates that suspend should be wrapped with startTransition.");
14214              value = uncaughtSuspenseError;
14215            }
14216          } else {
14217            if (getIsHydrating() && sourceFiber.mode & ConcurrentMode) {
14218              markDidThrowWhileHydratingDEV();
14219              var _suspenseBoundary = getNearestSuspenseBoundaryToCapture(returnFiber);
14220              if (_suspenseBoundary !== null) {
14221                if ((_suspenseBoundary.flags & ShouldCapture) === NoFlags) {
14222                  _suspenseBoundary.flags |= ForceClientRender;
14223                }
14224                markSuspenseBoundaryShouldCapture(_suspenseBoundary, returnFiber, sourceFiber, root2, rootRenderLanes);
14225                queueHydrationError(createCapturedValueAtFiber(value, sourceFiber));
14226                return;
14227              }
14228            }
14229          }
14230          value = createCapturedValueAtFiber(value, sourceFiber);
14231          renderDidError(value);
14232          var workInProgress2 = returnFiber;
14233          do {
14234            switch (workInProgress2.tag) {
14235              case HostRoot: {
14236                var _errorInfo = value;
14237                workInProgress2.flags |= ShouldCapture;
14238                var lane = pickArbitraryLane(rootRenderLanes);
14239                workInProgress2.lanes = mergeLanes(workInProgress2.lanes, lane);
14240                var update = createRootErrorUpdate(workInProgress2, _errorInfo, lane);
14241                enqueueCapturedUpdate(workInProgress2, update);
14242                return;
14243              }
14244              case ClassComponent:
14245                var errorInfo = value;
14246                var ctor = workInProgress2.type;
14247                var instance = workInProgress2.stateNode;
14248                if ((workInProgress2.flags & DidCapture) === NoFlags && (typeof ctor.getDerivedStateFromError === "function" || instance !== null && typeof instance.componentDidCatch === "function" && !isAlreadyFailedLegacyErrorBoundary(instance))) {
14249                  workInProgress2.flags |= ShouldCapture;
14250                  var _lane = pickArbitraryLane(rootRenderLanes);
14251                  workInProgress2.lanes = mergeLanes(workInProgress2.lanes, _lane);
14252                  var _update = createClassErrorUpdate(workInProgress2, errorInfo, _lane);
14253                  enqueueCapturedUpdate(workInProgress2, _update);
14254                  return;
14255                }
14256                break;
14257            }
14258            workInProgress2 = workInProgress2.return;
14259          } while (workInProgress2 !== null);
14260        }
14261        function getSuspendedCache() {
14262          {
14263            return null;
14264          }
14265        }
14266        var ReactCurrentOwner$1 = ReactSharedInternals.ReactCurrentOwner;
14267        var didReceiveUpdate = false;
14268        var didWarnAboutBadClass;
14269        var didWarnAboutModulePatternComponent;
14270        var didWarnAboutContextTypeOnFunctionComponent;
14271        var didWarnAboutGetDerivedStateOnFunctionComponent;
14272        var didWarnAboutFunctionRefs;
14273        var didWarnAboutReassigningProps;
14274        var didWarnAboutRevealOrder;
14275        var didWarnAboutTailOptions;
14276        var didWarnAboutDefaultPropsOnFunctionComponent;
14277        {
14278          didWarnAboutBadClass = {};
14279          didWarnAboutModulePatternComponent = {};
14280          didWarnAboutContextTypeOnFunctionComponent = {};
14281          didWarnAboutGetDerivedStateOnFunctionComponent = {};
14282          didWarnAboutFunctionRefs = {};
14283          didWarnAboutReassigningProps = false;
14284          didWarnAboutRevealOrder = {};
14285          didWarnAboutTailOptions = {};
14286          didWarnAboutDefaultPropsOnFunctionComponent = {};
14287        }
14288        function reconcileChildren(current2, workInProgress2, nextChildren, renderLanes2) {
14289          if (current2 === null) {
14290            workInProgress2.child = mountChildFibers(workInProgress2, null, nextChildren, renderLanes2);
14291          } else {
14292            workInProgress2.child = reconcileChildFibers(workInProgress2, current2.child, nextChildren, renderLanes2);
14293          }
14294        }
14295        function forceUnmountCurrentAndReconcile(current2, workInProgress2, nextChildren, renderLanes2) {
14296          workInProgress2.child = reconcileChildFibers(workInProgress2, current2.child, null, renderLanes2);
14297          workInProgress2.child = reconcileChildFibers(workInProgress2, null, nextChildren, renderLanes2);
14298        }
14299        function updateForwardRef(current2, workInProgress2, Component, nextProps, renderLanes2) {
14300          {
14301            if (workInProgress2.type !== workInProgress2.elementType) {
14302              var innerPropTypes = Component.propTypes;
14303              if (innerPropTypes) {
14304                checkPropTypes(
14305                  innerPropTypes,
14306                  nextProps,
14307                  // Resolved props
14308                  "prop",
14309                  getComponentNameFromType(Component)
14310                );
14311              }
14312            }
14313          }
14314          var render2 = Component.render;
14315          var ref = workInProgress2.ref;
14316          var nextChildren;
14317          var hasId;
14318          prepareToReadContext(workInProgress2, renderLanes2);
14319          {
14320            markComponentRenderStarted(workInProgress2);
14321          }
14322          {
14323            ReactCurrentOwner$1.current = workInProgress2;
14324            setIsRendering(true);
14325            nextChildren = renderWithHooks(current2, workInProgress2, render2, nextProps, ref, renderLanes2);
14326            hasId = checkDidRenderIdHook();
14327            if (workInProgress2.mode & StrictLegacyMode) {
14328              setIsStrictModeForDevtools(true);
14329              try {
14330                nextChildren = renderWithHooks(current2, workInProgress2, render2, nextProps, ref, renderLanes2);
14331                hasId = checkDidRenderIdHook();
14332              } finally {
14333                setIsStrictModeForDevtools(false);
14334              }
14335            }
14336            setIsRendering(false);
14337          }
14338          {
14339            markComponentRenderStopped();
14340          }
14341          if (current2 !== null && !didReceiveUpdate) {
14342            bailoutHooks(current2, workInProgress2, renderLanes2);
14343            return bailoutOnAlreadyFinishedWork(current2, workInProgress2, renderLanes2);
14344          }
14345          if (getIsHydrating() && hasId) {
14346            pushMaterializedTreeId(workInProgress2);
14347          }
14348          workInProgress2.flags |= PerformedWork;
14349          reconcileChildren(current2, workInProgress2, nextChildren, renderLanes2);
14350          return workInProgress2.child;
14351        }
14352        function updateMemoComponent(current2, workInProgress2, Component, nextProps, renderLanes2) {
14353          if (current2 === null) {
14354            var type = Component.type;
14355            if (isSimpleFunctionComponent(type) && Component.compare === null && // SimpleMemoComponent codepath doesn't resolve outer props either.
14356            Component.defaultProps === void 0) {
14357              var resolvedType = type;
14358              {
14359                resolvedType = resolveFunctionForHotReloading(type);
14360              }
14361              workInProgress2.tag = SimpleMemoComponent;
14362              workInProgress2.type = resolvedType;
14363              {
14364                validateFunctionComponentInDev(workInProgress2, type);
14365              }
14366              return updateSimpleMemoComponent(current2, workInProgress2, resolvedType, nextProps, renderLanes2);
14367            }
14368            {
14369              var innerPropTypes = type.propTypes;
14370              if (innerPropTypes) {
14371                checkPropTypes(
14372                  innerPropTypes,
14373                  nextProps,
14374                  // Resolved props
14375                  "prop",
14376                  getComponentNameFromType(type)
14377                );
14378              }
14379              if (Component.defaultProps !== void 0) {
14380                var componentName = getComponentNameFromType(type) || "Unknown";
14381                if (!didWarnAboutDefaultPropsOnFunctionComponent[componentName]) {
14382                  error("%s: Support for defaultProps will be removed from memo components in a future major release. Use JavaScript default parameters instead.", componentName);
14383                  didWarnAboutDefaultPropsOnFunctionComponent[componentName] = true;
14384                }
14385              }
14386            }
14387            var child = createFiberFromTypeAndProps(Component.type, null, nextProps, workInProgress2, workInProgress2.mode, renderLanes2);
14388            child.ref = workInProgress2.ref;
14389            child.return = workInProgress2;
14390            workInProgress2.child = child;
14391            return child;
14392          }
14393          {
14394            var _type = Component.type;
14395            var _innerPropTypes = _type.propTypes;
14396            if (_innerPropTypes) {
14397              checkPropTypes(
14398                _innerPropTypes,
14399                nextProps,
14400                // Resolved props
14401                "prop",
14402                getComponentNameFromType(_type)
14403              );
14404            }
14405          }
14406          var currentChild = current2.child;
14407          var hasScheduledUpdateOrContext = checkScheduledUpdateOrContext(current2, renderLanes2);
14408          if (!hasScheduledUpdateOrContext) {
14409            var prevProps = currentChild.memoizedProps;
14410            var compare = Component.compare;
14411            compare = compare !== null ? compare : shallowEqual;
14412            if (compare(prevProps, nextProps) && current2.ref === workInProgress2.ref) {
14413              return bailoutOnAlreadyFinishedWork(current2, workInProgress2, renderLanes2);
14414            }
14415          }
14416          workInProgress2.flags |= PerformedWork;
14417          var newChild = createWorkInProgress(currentChild, nextProps);
14418          newChild.ref = workInProgress2.ref;
14419          newChild.return = workInProgress2;
14420          workInProgress2.child = newChild;
14421          return newChild;
14422        }
14423        function updateSimpleMemoComponent(current2, workInProgress2, Component, nextProps, renderLanes2) {
14424          {
14425            if (workInProgress2.type !== workInProgress2.elementType) {
14426              var outerMemoType = workInProgress2.elementType;
14427              if (outerMemoType.$$typeof === REACT_LAZY_TYPE) {
14428                var lazyComponent = outerMemoType;
14429                var payload = lazyComponent._payload;
14430                var init = lazyComponent._init;
14431                try {
14432                  outerMemoType = init(payload);
14433                } catch (x) {
14434                  outerMemoType = null;
14435                }
14436                var outerPropTypes = outerMemoType && outerMemoType.propTypes;
14437                if (outerPropTypes) {
14438                  checkPropTypes(
14439                    outerPropTypes,
14440                    nextProps,
14441                    // Resolved (SimpleMemoComponent has no defaultProps)
14442                    "prop",
14443                    getComponentNameFromType(outerMemoType)
14444                  );
14445                }
14446              }
14447            }
14448          }
14449          if (current2 !== null) {
14450            var prevProps = current2.memoizedProps;
14451            if (shallowEqual(prevProps, nextProps) && current2.ref === workInProgress2.ref && // Prevent bailout if the implementation changed due to hot reload.
14452            workInProgress2.type === current2.type) {
14453              didReceiveUpdate = false;
14454              workInProgress2.pendingProps = nextProps = prevProps;
14455              if (!checkScheduledUpdateOrContext(current2, renderLanes2)) {
14456                workInProgress2.lanes = current2.lanes;
14457                return bailoutOnAlreadyFinishedWork(current2, workInProgress2, renderLanes2);
14458              } else if ((current2.flags & ForceUpdateForLegacySuspense) !== NoFlags) {
14459                didReceiveUpdate = true;
14460              }
14461            }
14462          }
14463          return updateFunctionComponent(current2, workInProgress2, Component, nextProps, renderLanes2);
14464        }
14465        function updateOffscreenComponent(current2, workInProgress2, renderLanes2) {
14466          var nextProps = workInProgress2.pendingProps;
14467          var nextChildren = nextProps.children;
14468          var prevState = current2 !== null ? current2.memoizedState : null;
14469          if (nextProps.mode === "hidden" || enableLegacyHidden) {
14470            if ((workInProgress2.mode & ConcurrentMode) === NoMode) {
14471              var nextState = {
14472                baseLanes: NoLanes,
14473                cachePool: null,
14474                transitions: null
14475              };
14476              workInProgress2.memoizedState = nextState;
14477              pushRenderLanes(workInProgress2, renderLanes2);
14478            } else if (!includesSomeLane(renderLanes2, OffscreenLane)) {
14479              var spawnedCachePool = null;
14480              var nextBaseLanes;
14481              if (prevState !== null) {
14482                var prevBaseLanes = prevState.baseLanes;
14483                nextBaseLanes = mergeLanes(prevBaseLanes, renderLanes2);
14484              } else {
14485                nextBaseLanes = renderLanes2;
14486              }
14487              workInProgress2.lanes = workInProgress2.childLanes = laneToLanes(OffscreenLane);
14488              var _nextState = {
14489                baseLanes: nextBaseLanes,
14490                cachePool: spawnedCachePool,
14491                transitions: null
14492              };
14493              workInProgress2.memoizedState = _nextState;
14494              workInProgress2.updateQueue = null;
14495              pushRenderLanes(workInProgress2, nextBaseLanes);
14496              return null;
14497            } else {
14498              var _nextState2 = {
14499                baseLanes: NoLanes,
14500                cachePool: null,
14501                transitions: null
14502              };
14503              workInProgress2.memoizedState = _nextState2;
14504              var subtreeRenderLanes2 = prevState !== null ? prevState.baseLanes : renderLanes2;
14505              pushRenderLanes(workInProgress2, subtreeRenderLanes2);
14506            }
14507          } else {
14508            var _subtreeRenderLanes;
14509            if (prevState !== null) {
14510              _subtreeRenderLanes = mergeLanes(prevState.baseLanes, renderLanes2);
14511              workInProgress2.memoizedState = null;
14512            } else {
14513              _subtreeRenderLanes = renderLanes2;
14514            }
14515            pushRenderLanes(workInProgress2, _subtreeRenderLanes);
14516          }
14517          reconcileChildren(current2, workInProgress2, nextChildren, renderLanes2);
14518          return workInProgress2.child;
14519        }
14520        function updateFragment(current2, workInProgress2, renderLanes2) {
14521          var nextChildren = workInProgress2.pendingProps;
14522          reconcileChildren(current2, workInProgress2, nextChildren, renderLanes2);
14523          return workInProgress2.child;
14524        }
14525        function updateMode(current2, workInProgress2, renderLanes2) {
14526          var nextChildren = workInProgress2.pendingProps.children;
14527          reconcileChildren(current2, workInProgress2, nextChildren, renderLanes2);
14528          return workInProgress2.child;
14529        }
14530        function updateProfiler(current2, workInProgress2, renderLanes2) {
14531          {
14532            workInProgress2.flags |= Update;
14533            {
14534              var stateNode = workInProgress2.stateNode;
14535              stateNode.effectDuration = 0;
14536              stateNode.passiveEffectDuration = 0;
14537            }
14538          }
14539          var nextProps = workInProgress2.pendingProps;
14540          var nextChildren = nextProps.children;
14541          reconcileChildren(current2, workInProgress2, nextChildren, renderLanes2);
14542          return workInProgress2.child;
14543        }
14544        function markRef(current2, workInProgress2) {
14545          var ref = workInProgress2.ref;
14546          if (current2 === null && ref !== null || current2 !== null && current2.ref !== ref) {
14547            workInProgress2.flags |= Ref;
14548            {
14549              workInProgress2.flags |= RefStatic;
14550            }
14551          }
14552        }
14553        function updateFunctionComponent(current2, workInProgress2, Component, nextProps, renderLanes2) {
14554          {
14555            if (workInProgress2.type !== workInProgress2.elementType) {
14556              var innerPropTypes = Component.propTypes;
14557              if (innerPropTypes) {
14558                checkPropTypes(
14559                  innerPropTypes,
14560                  nextProps,
14561                  // Resolved props
14562                  "prop",
14563                  getComponentNameFromType(Component)
14564                );
14565              }
14566            }
14567          }
14568          var context;
14569          {
14570            var unmaskedContext = getUnmaskedContext(workInProgress2, Component, true);
14571            context = getMaskedContext(workInProgress2, unmaskedContext);
14572          }
14573          var nextChildren;
14574          var hasId;
14575          prepareToReadContext(workInProgress2, renderLanes2);
14576          {
14577            markComponentRenderStarted(workInProgress2);
14578          }
14579          {
14580            ReactCurrentOwner$1.current = workInProgress2;
14581            setIsRendering(true);
14582            nextChildren = renderWithHooks(current2, workInProgress2, Component, nextProps, context, renderLanes2);
14583            hasId = checkDidRenderIdHook();
14584            if (workInProgress2.mode & StrictLegacyMode) {
14585              setIsStrictModeForDevtools(true);
14586              try {
14587                nextChildren = renderWithHooks(current2, workInProgress2, Component, nextProps, context, renderLanes2);
14588                hasId = checkDidRenderIdHook();
14589              } finally {
14590                setIsStrictModeForDevtools(false);
14591              }
14592            }
14593            setIsRendering(false);
14594          }
14595          {
14596            markComponentRenderStopped();
14597          }
14598          if (current2 !== null && !didReceiveUpdate) {
14599            bailoutHooks(current2, workInProgress2, renderLanes2);
14600            return bailoutOnAlreadyFinishedWork(current2, workInProgress2, renderLanes2);
14601          }
14602          if (getIsHydrating() && hasId) {
14603            pushMaterializedTreeId(workInProgress2);
14604          }
14605          workInProgress2.flags |= PerformedWork;
14606          reconcileChildren(current2, workInProgress2, nextChildren, renderLanes2);
14607          return workInProgress2.child;
14608        }
14609        function updateClassComponent(current2, workInProgress2, Component, nextProps, renderLanes2) {
14610          {
14611            switch (shouldError(workInProgress2)) {
14612              case false: {
14613                var _instance = workInProgress2.stateNode;
14614                var ctor = workInProgress2.type;
14615                var tempInstance = new ctor(workInProgress2.memoizedProps, _instance.context);
14616                var state = tempInstance.state;
14617                _instance.updater.enqueueSetState(_instance, state, null);
14618                break;
14619              }
14620              case true: {
14621                workInProgress2.flags |= DidCapture;
14622                workInProgress2.flags |= ShouldCapture;
14623                var error$1 = new Error("Simulated error coming from DevTools");
14624                var lane = pickArbitraryLane(renderLanes2);
14625                workInProgress2.lanes = mergeLanes(workInProgress2.lanes, lane);
14626                var update = createClassErrorUpdate(workInProgress2, createCapturedValueAtFiber(error$1, workInProgress2), lane);
14627                enqueueCapturedUpdate(workInProgress2, update);
14628                break;
14629              }
14630            }
14631            if (workInProgress2.type !== workInProgress2.elementType) {
14632              var innerPropTypes = Component.propTypes;
14633              if (innerPropTypes) {
14634                checkPropTypes(
14635                  innerPropTypes,
14636                  nextProps,
14637                  // Resolved props
14638                  "prop",
14639                  getComponentNameFromType(Component)
14640                );
14641              }
14642            }
14643          }
14644          var hasContext;
14645          if (isContextProvider(Component)) {
14646            hasContext = true;
14647            pushContextProvider(workInProgress2);
14648          } else {
14649            hasContext = false;
14650          }
14651          prepareToReadContext(workInProgress2, renderLanes2);
14652          var instance = workInProgress2.stateNode;
14653          var shouldUpdate;
14654          if (instance === null) {
14655            resetSuspendedCurrentOnMountInLegacyMode(current2, workInProgress2);
14656            constructClassInstance(workInProgress2, Component, nextProps);
14657            mountClassInstance(workInProgress2, Component, nextProps, renderLanes2);
14658            shouldUpdate = true;
14659          } else if (current2 === null) {
14660            shouldUpdate = resumeMountClassInstance(workInProgress2, Component, nextProps, renderLanes2);
14661          } else {
14662            shouldUpdate = updateClassInstance(current2, workInProgress2, Component, nextProps, renderLanes2);
14663          }
14664          var nextUnitOfWork = finishClassComponent(current2, workInProgress2, Component, shouldUpdate, hasContext, renderLanes2);
14665          {
14666            var inst = workInProgress2.stateNode;
14667            if (shouldUpdate && inst.props !== nextProps) {
14668              if (!didWarnAboutReassigningProps) {
14669                error("It looks like %s is reassigning its own `this.props` while rendering. This is not supported and can lead to confusing bugs.", getComponentNameFromFiber(workInProgress2) || "a component");
14670              }
14671              didWarnAboutReassigningProps = true;
14672            }
14673          }
14674          return nextUnitOfWork;
14675        }
14676        function finishClassComponent(current2, workInProgress2, Component, shouldUpdate, hasContext, renderLanes2) {
14677          markRef(current2, workInProgress2);
14678          var didCaptureError = (workInProgress2.flags & DidCapture) !== NoFlags;
14679          if (!shouldUpdate && !didCaptureError) {
14680            if (hasContext) {
14681              invalidateContextProvider(workInProgress2, Component, false);
14682            }
14683            return bailoutOnAlreadyFinishedWork(current2, workInProgress2, renderLanes2);
14684          }
14685          var instance = workInProgress2.stateNode;
14686          ReactCurrentOwner$1.current = workInProgress2;
14687          var nextChildren;
14688          if (didCaptureError && typeof Component.getDerivedStateFromError !== "function") {
14689            nextChildren = null;
14690            {
14691              stopProfilerTimerIfRunning();
14692            }
14693          } else {
14694            {
14695              markComponentRenderStarted(workInProgress2);
14696            }
14697            {
14698              setIsRendering(true);
14699              nextChildren = instance.render();
14700              if (workInProgress2.mode & StrictLegacyMode) {
14701                setIsStrictModeForDevtools(true);
14702                try {
14703                  instance.render();
14704                } finally {
14705                  setIsStrictModeForDevtools(false);
14706                }
14707              }
14708              setIsRendering(false);
14709            }
14710            {
14711              markComponentRenderStopped();
14712            }
14713          }
14714          workInProgress2.flags |= PerformedWork;
14715          if (current2 !== null && didCaptureError) {
14716            forceUnmountCurrentAndReconcile(current2, workInProgress2, nextChildren, renderLanes2);
14717          } else {
14718            reconcileChildren(current2, workInProgress2, nextChildren, renderLanes2);
14719          }
14720          workInProgress2.memoizedState = instance.state;
14721          if (hasContext) {
14722            invalidateContextProvider(workInProgress2, Component, true);
14723          }
14724          return workInProgress2.child;
14725        }
14726        function pushHostRootContext(workInProgress2) {
14727          var root2 = workInProgress2.stateNode;
14728          if (root2.pendingContext) {
14729            pushTopLevelContextObject(workInProgress2, root2.pendingContext, root2.pendingContext !== root2.context);
14730          } else if (root2.context) {
14731            pushTopLevelContextObject(workInProgress2, root2.context, false);
14732          }
14733          pushHostContainer(workInProgress2, root2.containerInfo);
14734        }
14735        function updateHostRoot(current2, workInProgress2, renderLanes2) {
14736          pushHostRootContext(workInProgress2);
14737          if (current2 === null) {
14738            throw new Error("Should have a current fiber. This is a bug in React.");
14739          }
14740          var nextProps = workInProgress2.pendingProps;
14741          var prevState = workInProgress2.memoizedState;
14742          var prevChildren = prevState.element;
14743          cloneUpdateQueue(current2, workInProgress2);
14744          processUpdateQueue(workInProgress2, nextProps, null, renderLanes2);
14745          var nextState = workInProgress2.memoizedState;
14746          var root2 = workInProgress2.stateNode;
14747          var nextChildren = nextState.element;
14748          if (prevState.isDehydrated) {
14749            var overrideState = {
14750              element: nextChildren,
14751              isDehydrated: false,
14752              cache: nextState.cache,
14753              pendingSuspenseBoundaries: nextState.pendingSuspenseBoundaries,
14754              transitions: nextState.transitions
14755            };
14756            var updateQueue = workInProgress2.updateQueue;
14757            updateQueue.baseState = overrideState;
14758            workInProgress2.memoizedState = overrideState;
14759            if (workInProgress2.flags & ForceClientRender) {
14760              var recoverableError = createCapturedValueAtFiber(new Error("There was an error while hydrating. Because the error happened outside of a Suspense boundary, the entire root will switch to client rendering."), workInProgress2);
14761              return mountHostRootWithoutHydrating(current2, workInProgress2, nextChildren, renderLanes2, recoverableError);
14762            } else if (nextChildren !== prevChildren) {
14763              var _recoverableError = createCapturedValueAtFiber(new Error("This root received an early update, before anything was able hydrate. Switched the entire root to client rendering."), workInProgress2);
14764              return mountHostRootWithoutHydrating(current2, workInProgress2, nextChildren, renderLanes2, _recoverableError);
14765            } else {
14766              enterHydrationState(workInProgress2);
14767              var child = mountChildFibers(workInProgress2, null, nextChildren, renderLanes2);
14768              workInProgress2.child = child;
14769              var node = child;
14770              while (node) {
14771                node.flags = node.flags & ~Placement | Hydrating;
14772                node = node.sibling;
14773              }
14774            }
14775          } else {
14776            resetHydrationState();
14777            if (nextChildren === prevChildren) {
14778              return bailoutOnAlreadyFinishedWork(current2, workInProgress2, renderLanes2);
14779            }
14780            reconcileChildren(current2, workInProgress2, nextChildren, renderLanes2);
14781          }
14782          return workInProgress2.child;
14783        }
14784        function mountHostRootWithoutHydrating(current2, workInProgress2, nextChildren, renderLanes2, recoverableError) {
14785          resetHydrationState();
14786          queueHydrationError(recoverableError);
14787          workInProgress2.flags |= ForceClientRender;
14788          reconcileChildren(current2, workInProgress2, nextChildren, renderLanes2);
14789          return workInProgress2.child;
14790        }
14791        function updateHostComponent(current2, workInProgress2, renderLanes2) {
14792          pushHostContext(workInProgress2);
14793          if (current2 === null) {
14794            tryToClaimNextHydratableInstance(workInProgress2);
14795          }
14796          var type = workInProgress2.type;
14797          var nextProps = workInProgress2.pendingProps;
14798          var prevProps = current2 !== null ? current2.memoizedProps : null;
14799          var nextChildren = nextProps.children;
14800          var isDirectTextChild = shouldSetTextContent(type, nextProps);
14801          if (isDirectTextChild) {
14802            nextChildren = null;
14803          } else if (prevProps !== null && shouldSetTextContent(type, prevProps)) {
14804            workInProgress2.flags |= ContentReset;
14805          }
14806          markRef(current2, workInProgress2);
14807          reconcileChildren(current2, workInProgress2, nextChildren, renderLanes2);
14808          return workInProgress2.child;
14809        }
14810        function updateHostText(current2, workInProgress2) {
14811          if (current2 === null) {
14812            tryToClaimNextHydratableInstance(workInProgress2);
14813          }
14814          return null;
14815        }
14816        function mountLazyComponent(_current, workInProgress2, elementType, renderLanes2) {
14817          resetSuspendedCurrentOnMountInLegacyMode(_current, workInProgress2);
14818          var props = workInProgress2.pendingProps;
14819          var lazyComponent = elementType;
14820          var payload = lazyComponent._payload;
14821          var init = lazyComponent._init;
14822          var Component = init(payload);
14823          workInProgress2.type = Component;
14824          var resolvedTag = workInProgress2.tag = resolveLazyComponentTag(Component);
14825          var resolvedProps = resolveDefaultProps(Component, props);
14826          var child;
14827          switch (resolvedTag) {
14828            case FunctionComponent: {
14829              {
14830                validateFunctionComponentInDev(workInProgress2, Component);
14831                workInProgress2.type = Component = resolveFunctionForHotReloading(Component);
14832              }
14833              child = updateFunctionComponent(null, workInProgress2, Component, resolvedProps, renderLanes2);
14834              return child;
14835            }
14836            case ClassComponent: {
14837              {
14838                workInProgress2.type = Component = resolveClassForHotReloading(Component);
14839              }
14840              child = updateClassComponent(null, workInProgress2, Component, resolvedProps, renderLanes2);
14841              return child;
14842            }
14843            case ForwardRef: {
14844              {
14845                workInProgress2.type = Component = resolveForwardRefForHotReloading(Component);
14846              }
14847              child = updateForwardRef(null, workInProgress2, Component, resolvedProps, renderLanes2);
14848              return child;
14849            }
14850            case MemoComponent: {
14851              {
14852                if (workInProgress2.type !== workInProgress2.elementType) {
14853                  var outerPropTypes = Component.propTypes;
14854                  if (outerPropTypes) {
14855                    checkPropTypes(
14856                      outerPropTypes,
14857                      resolvedProps,
14858                      // Resolved for outer only
14859                      "prop",
14860                      getComponentNameFromType(Component)
14861                    );
14862                  }
14863                }
14864              }
14865              child = updateMemoComponent(
14866                null,
14867                workInProgress2,
14868                Component,
14869                resolveDefaultProps(Component.type, resolvedProps),
14870                // The inner type can have defaults too
14871                renderLanes2
14872              );
14873              return child;
14874            }
14875          }
14876          var hint = "";
14877          {
14878            if (Component !== null && typeof Component === "object" && Component.$$typeof === REACT_LAZY_TYPE) {
14879              hint = " Did you wrap a component in React.lazy() more than once?";
14880            }
14881          }
14882          throw new Error("Element type is invalid. Received a promise that resolves to: " + Component + ". " + ("Lazy element type must resolve to a class or function." + hint));
14883        }
14884        function mountIncompleteClassComponent(_current, workInProgress2, Component, nextProps, renderLanes2) {
14885          resetSuspendedCurrentOnMountInLegacyMode(_current, workInProgress2);
14886          workInProgress2.tag = ClassComponent;
14887          var hasContext;
14888          if (isContextProvider(Component)) {
14889            hasContext = true;
14890            pushContextProvider(workInProgress2);
14891          } else {
14892            hasContext = false;
14893          }
14894          prepareToReadContext(workInProgress2, renderLanes2);
14895          constructClassInstance(workInProgress2, Component, nextProps);
14896          mountClassInstance(workInProgress2, Component, nextProps, renderLanes2);
14897          return finishClassComponent(null, workInProgress2, Component, true, hasContext, renderLanes2);
14898        }
14899        function mountIndeterminateComponent(_current, workInProgress2, Component, renderLanes2) {
14900          resetSuspendedCurrentOnMountInLegacyMode(_current, workInProgress2);
14901          var props = workInProgress2.pendingProps;
14902          var context;
14903          {
14904            var unmaskedContext = getUnmaskedContext(workInProgress2, Component, false);
14905            context = getMaskedContext(workInProgress2, unmaskedContext);
14906          }
14907          prepareToReadContext(workInProgress2, renderLanes2);
14908          var value;
14909          var hasId;
14910          {
14911            markComponentRenderStarted(workInProgress2);
14912          }
14913          {
14914            if (Component.prototype && typeof Component.prototype.render === "function") {
14915              var componentName = getComponentNameFromType(Component) || "Unknown";
14916              if (!didWarnAboutBadClass[componentName]) {
14917                error("The <%s /> component appears to have a render method, but doesn't extend React.Component. This is likely to cause errors. Change %s to extend React.Component instead.", componentName, componentName);
14918                didWarnAboutBadClass[componentName] = true;
14919              }
14920            }
14921            if (workInProgress2.mode & StrictLegacyMode) {
14922              ReactStrictModeWarnings.recordLegacyContextWarning(workInProgress2, null);
14923            }
14924            setIsRendering(true);
14925            ReactCurrentOwner$1.current = workInProgress2;
14926            value = renderWithHooks(null, workInProgress2, Component, props, context, renderLanes2);
14927            hasId = checkDidRenderIdHook();
14928            setIsRendering(false);
14929          }
14930          {
14931            markComponentRenderStopped();
14932          }
14933          workInProgress2.flags |= PerformedWork;
14934          {
14935            if (typeof value === "object" && value !== null && typeof value.render === "function" && value.$$typeof === void 0) {
14936              var _componentName = getComponentNameFromType(Component) || "Unknown";
14937              if (!didWarnAboutModulePatternComponent[_componentName]) {
14938                error("The <%s /> component appears to be a function component that returns a class instance. Change %s to a class that extends React.Component instead. If you can't use a class try assigning the prototype on the function as a workaround. `%s.prototype = React.Component.prototype`. Don't use an arrow function since it cannot be called with `new` by React.", _componentName, _componentName, _componentName);
14939                didWarnAboutModulePatternComponent[_componentName] = true;
14940              }
14941            }
14942          }
14943          if (
14944            // Run these checks in production only if the flag is off.
14945            // Eventually we'll delete this branch altogether.
14946            typeof value === "object" && value !== null && typeof value.render === "function" && value.$$typeof === void 0
14947          ) {
14948            {
14949              var _componentName2 = getComponentNameFromType(Component) || "Unknown";
14950              if (!didWarnAboutModulePatternComponent[_componentName2]) {
14951                error("The <%s /> component appears to be a function component that returns a class instance. Change %s to a class that extends React.Component instead. If you can't use a class try assigning the prototype on the function as a workaround. `%s.prototype = React.Component.prototype`. Don't use an arrow function since it cannot be called with `new` by React.", _componentName2, _componentName2, _componentName2);
14952                didWarnAboutModulePatternComponent[_componentName2] = true;
14953              }
14954            }
14955            workInProgress2.tag = ClassComponent;
14956            workInProgress2.memoizedState = null;
14957            workInProgress2.updateQueue = null;
14958            var hasContext = false;
14959            if (isContextProvider(Component)) {
14960              hasContext = true;
14961              pushContextProvider(workInProgress2);
14962            } else {
14963              hasContext = false;
14964            }
14965            workInProgress2.memoizedState = value.state !== null && value.state !== void 0 ? value.state : null;
14966            initializeUpdateQueue(workInProgress2);
14967            adoptClassInstance(workInProgress2, value);
14968            mountClassInstance(workInProgress2, Component, props, renderLanes2);
14969            return finishClassComponent(null, workInProgress2, Component, true, hasContext, renderLanes2);
14970          } else {
14971            workInProgress2.tag = FunctionComponent;
14972            {
14973              if (workInProgress2.mode & StrictLegacyMode) {
14974                setIsStrictModeForDevtools(true);
14975                try {
14976                  value = renderWithHooks(null, workInProgress2, Component, props, context, renderLanes2);
14977                  hasId = checkDidRenderIdHook();
14978                } finally {
14979                  setIsStrictModeForDevtools(false);
14980                }
14981              }
14982            }
14983            if (getIsHydrating() && hasId) {
14984              pushMaterializedTreeId(workInProgress2);
14985            }
14986            reconcileChildren(null, workInProgress2, value, renderLanes2);
14987            {
14988              validateFunctionComponentInDev(workInProgress2, Component);
14989            }
14990            return workInProgress2.child;
14991          }
14992        }
14993        function validateFunctionComponentInDev(workInProgress2, Component) {
14994          {
14995            if (Component) {
14996              if (Component.childContextTypes) {
14997                error("%s(...): childContextTypes cannot be defined on a function component.", Component.displayName || Component.name || "Component");
14998              }
14999            }
15000            if (workInProgress2.ref !== null) {
15001              var info = "";
15002              var ownerName = getCurrentFiberOwnerNameInDevOrNull();
15003              if (ownerName) {
15004                info += "\n\nCheck the render method of `" + ownerName + "`.";
15005              }
15006              var warningKey = ownerName || "";
15007              var debugSource = workInProgress2._debugSource;
15008              if (debugSource) {
15009                warningKey = debugSource.fileName + ":" + debugSource.lineNumber;
15010              }
15011              if (!didWarnAboutFunctionRefs[warningKey]) {
15012                didWarnAboutFunctionRefs[warningKey] = true;
15013                error("Function components cannot be given refs. Attempts to access this ref will fail. Did you mean to use React.forwardRef()?%s", info);
15014              }
15015            }
15016            if (Component.defaultProps !== void 0) {
15017              var componentName = getComponentNameFromType(Component) || "Unknown";
15018              if (!didWarnAboutDefaultPropsOnFunctionComponent[componentName]) {
15019                error("%s: Support for defaultProps will be removed from function components in a future major release. Use JavaScript default parameters instead.", componentName);
15020                didWarnAboutDefaultPropsOnFunctionComponent[componentName] = true;
15021              }
15022            }
15023            if (typeof Component.getDerivedStateFromProps === "function") {
15024              var _componentName3 = getComponentNameFromType(Component) || "Unknown";
15025              if (!didWarnAboutGetDerivedStateOnFunctionComponent[_componentName3]) {
15026                error("%s: Function components do not support getDerivedStateFromProps.", _componentName3);
15027                didWarnAboutGetDerivedStateOnFunctionComponent[_componentName3] = true;
15028              }
15029            }
15030            if (typeof Component.contextType === "object" && Component.contextType !== null) {
15031              var _componentName4 = getComponentNameFromType(Component) || "Unknown";
15032              if (!didWarnAboutContextTypeOnFunctionComponent[_componentName4]) {
15033                error("%s: Function components do not support contextType.", _componentName4);
15034                didWarnAboutContextTypeOnFunctionComponent[_componentName4] = true;
15035              }
15036            }
15037          }
15038        }
15039        var SUSPENDED_MARKER = {
15040          dehydrated: null,
15041          treeContext: null,
15042          retryLane: NoLane
15043        };
15044        function mountSuspenseOffscreenState(renderLanes2) {
15045          return {
15046            baseLanes: renderLanes2,
15047            cachePool: getSuspendedCache(),
15048            transitions: null
15049          };
15050        }
15051        function updateSuspenseOffscreenState(prevOffscreenState, renderLanes2) {
15052          var cachePool = null;
15053          return {
15054            baseLanes: mergeLanes(prevOffscreenState.baseLanes, renderLanes2),
15055            cachePool,
15056            transitions: prevOffscreenState.transitions
15057          };
15058        }
15059        function shouldRemainOnFallback(suspenseContext, current2, workInProgress2, renderLanes2) {
15060          if (current2 !== null) {
15061            var suspenseState = current2.memoizedState;
15062            if (suspenseState === null) {
15063              return false;
15064            }
15065          }
15066          return hasSuspenseContext(suspenseContext, ForceSuspenseFallback);
15067        }
15068        function getRemainingWorkInPrimaryTree(current2, renderLanes2) {
15069          return removeLanes(current2.childLanes, renderLanes2);
15070        }
15071        function updateSuspenseComponent(current2, workInProgress2, renderLanes2) {
15072          var nextProps = workInProgress2.pendingProps;
15073          {
15074            if (shouldSuspend(workInProgress2)) {
15075              workInProgress2.flags |= DidCapture;
15076            }
15077          }
15078          var suspenseContext = suspenseStackCursor.current;
15079          var showFallback = false;
15080          var didSuspend = (workInProgress2.flags & DidCapture) !== NoFlags;
15081          if (didSuspend || shouldRemainOnFallback(suspenseContext, current2)) {
15082            showFallback = true;
15083            workInProgress2.flags &= ~DidCapture;
15084          } else {
15085            if (current2 === null || current2.memoizedState !== null) {
15086              {
15087                suspenseContext = addSubtreeSuspenseContext(suspenseContext, InvisibleParentSuspenseContext);
15088              }
15089            }
15090          }
15091          suspenseContext = setDefaultShallowSuspenseContext(suspenseContext);
15092          pushSuspenseContext(workInProgress2, suspenseContext);
15093          if (current2 === null) {
15094            tryToClaimNextHydratableInstance(workInProgress2);
15095            var suspenseState = workInProgress2.memoizedState;
15096            if (suspenseState !== null) {
15097              var dehydrated = suspenseState.dehydrated;
15098              if (dehydrated !== null) {
15099                return mountDehydratedSuspenseComponent(workInProgress2, dehydrated);
15100              }
15101            }
15102            var nextPrimaryChildren = nextProps.children;
15103            var nextFallbackChildren = nextProps.fallback;
15104            if (showFallback) {
15105              var fallbackFragment = mountSuspenseFallbackChildren(workInProgress2, nextPrimaryChildren, nextFallbackChildren, renderLanes2);
15106              var primaryChildFragment = workInProgress2.child;
15107              primaryChildFragment.memoizedState = mountSuspenseOffscreenState(renderLanes2);
15108              workInProgress2.memoizedState = SUSPENDED_MARKER;
15109              return fallbackFragment;
15110            } else {
15111              return mountSuspensePrimaryChildren(workInProgress2, nextPrimaryChildren);
15112            }
15113          } else {
15114            var prevState = current2.memoizedState;
15115            if (prevState !== null) {
15116              var _dehydrated = prevState.dehydrated;
15117              if (_dehydrated !== null) {
15118                return updateDehydratedSuspenseComponent(current2, workInProgress2, didSuspend, nextProps, _dehydrated, prevState, renderLanes2);
15119              }
15120            }
15121            if (showFallback) {
15122              var _nextFallbackChildren = nextProps.fallback;
15123              var _nextPrimaryChildren = nextProps.children;
15124              var fallbackChildFragment = updateSuspenseFallbackChildren(current2, workInProgress2, _nextPrimaryChildren, _nextFallbackChildren, renderLanes2);
15125              var _primaryChildFragment2 = workInProgress2.child;
15126              var prevOffscreenState = current2.child.memoizedState;
15127              _primaryChildFragment2.memoizedState = prevOffscreenState === null ? mountSuspenseOffscreenState(renderLanes2) : updateSuspenseOffscreenState(prevOffscreenState, renderLanes2);
15128              _primaryChildFragment2.childLanes = getRemainingWorkInPrimaryTree(current2, renderLanes2);
15129              workInProgress2.memoizedState = SUSPENDED_MARKER;
15130              return fallbackChildFragment;
15131            } else {
15132              var _nextPrimaryChildren2 = nextProps.children;
15133              var _primaryChildFragment3 = updateSuspensePrimaryChildren(current2, workInProgress2, _nextPrimaryChildren2, renderLanes2);
15134              workInProgress2.memoizedState = null;
15135              return _primaryChildFragment3;
15136            }
15137          }
15138        }
15139        function mountSuspensePrimaryChildren(workInProgress2, primaryChildren, renderLanes2) {
15140          var mode = workInProgress2.mode;
15141          var primaryChildProps = {
15142            mode: "visible",
15143            children: primaryChildren
15144          };
15145          var primaryChildFragment = mountWorkInProgressOffscreenFiber(primaryChildProps, mode);
15146          primaryChildFragment.return = workInProgress2;
15147          workInProgress2.child = primaryChildFragment;
15148          return primaryChildFragment;
15149        }
15150        function mountSuspenseFallbackChildren(workInProgress2, primaryChildren, fallbackChildren, renderLanes2) {
15151          var mode = workInProgress2.mode;
15152          var progressedPrimaryFragment = workInProgress2.child;
15153          var primaryChildProps = {
15154            mode: "hidden",
15155            children: primaryChildren
15156          };
15157          var primaryChildFragment;
15158          var fallbackChildFragment;
15159          if ((mode & ConcurrentMode) === NoMode && progressedPrimaryFragment !== null) {
15160            primaryChildFragment = progressedPrimaryFragment;
15161            primaryChildFragment.childLanes = NoLanes;
15162            primaryChildFragment.pendingProps = primaryChildProps;
15163            if (workInProgress2.mode & ProfileMode) {
15164              primaryChildFragment.actualDuration = 0;
15165              primaryChildFragment.actualStartTime = -1;
15166              primaryChildFragment.selfBaseDuration = 0;
15167              primaryChildFragment.treeBaseDuration = 0;
15168            }
15169            fallbackChildFragment = createFiberFromFragment(fallbackChildren, mode, renderLanes2, null);
15170          } else {
15171            primaryChildFragment = mountWorkInProgressOffscreenFiber(primaryChildProps, mode);
15172            fallbackChildFragment = createFiberFromFragment(fallbackChildren, mode, renderLanes2, null);
15173          }
15174          primaryChildFragment.return = workInProgress2;
15175          fallbackChildFragment.return = workInProgress2;
15176          primaryChildFragment.sibling = fallbackChildFragment;
15177          workInProgress2.child = primaryChildFragment;
15178          return fallbackChildFragment;
15179        }
15180        function mountWorkInProgressOffscreenFiber(offscreenProps, mode, renderLanes2) {
15181          return createFiberFromOffscreen(offscreenProps, mode, NoLanes, null);
15182        }
15183        function updateWorkInProgressOffscreenFiber(current2, offscreenProps) {
15184          return createWorkInProgress(current2, offscreenProps);
15185        }
15186        function updateSuspensePrimaryChildren(current2, workInProgress2, primaryChildren, renderLanes2) {
15187          var currentPrimaryChildFragment = current2.child;
15188          var currentFallbackChildFragment = currentPrimaryChildFragment.sibling;
15189          var primaryChildFragment = updateWorkInProgressOffscreenFiber(currentPrimaryChildFragment, {
15190            mode: "visible",
15191            children: primaryChildren
15192          });
15193          if ((workInProgress2.mode & ConcurrentMode) === NoMode) {
15194            primaryChildFragment.lanes = renderLanes2;
15195          }
15196          primaryChildFragment.return = workInProgress2;
15197          primaryChildFragment.sibling = null;
15198          if (currentFallbackChildFragment !== null) {
15199            var deletions = workInProgress2.deletions;
15200            if (deletions === null) {
15201              workInProgress2.deletions = [currentFallbackChildFragment];
15202              workInProgress2.flags |= ChildDeletion;
15203            } else {
15204              deletions.push(currentFallbackChildFragment);
15205            }
15206          }
15207          workInProgress2.child = primaryChildFragment;
15208          return primaryChildFragment;
15209        }
15210        function updateSuspenseFallbackChildren(current2, workInProgress2, primaryChildren, fallbackChildren, renderLanes2) {
15211          var mode = workInProgress2.mode;
15212          var currentPrimaryChildFragment = current2.child;
15213          var currentFallbackChildFragment = currentPrimaryChildFragment.sibling;
15214          var primaryChildProps = {
15215            mode: "hidden",
15216            children: primaryChildren
15217          };
15218          var primaryChildFragment;
15219          if (
15220            // In legacy mode, we commit the primary tree as if it successfully
15221            // completed, even though it's in an inconsistent state.
15222            (mode & ConcurrentMode) === NoMode && // Make sure we're on the second pass, i.e. the primary child fragment was
15223            // already cloned. In legacy mode, the only case where this isn't true is
15224            // when DevTools forces us to display a fallback; we skip the first render
15225            // pass entirely and go straight to rendering the fallback. (In Concurrent
15226            // Mode, SuspenseList can also trigger this scenario, but this is a legacy-
15227            // only codepath.)
15228            workInProgress2.child !== currentPrimaryChildFragment
15229          ) {
15230            var progressedPrimaryFragment = workInProgress2.child;
15231            primaryChildFragment = progressedPrimaryFragment;
15232            primaryChildFragment.childLanes = NoLanes;
15233            primaryChildFragment.pendingProps = primaryChildProps;
15234            if (workInProgress2.mode & ProfileMode) {
15235              primaryChildFragment.actualDuration = 0;
15236              primaryChildFragment.actualStartTime = -1;
15237              primaryChildFragment.selfBaseDuration = currentPrimaryChildFragment.selfBaseDuration;
15238              primaryChildFragment.treeBaseDuration = currentPrimaryChildFragment.treeBaseDuration;
15239            }
15240            workInProgress2.deletions = null;
15241          } else {
15242            primaryChildFragment = updateWorkInProgressOffscreenFiber(currentPrimaryChildFragment, primaryChildProps);
15243            primaryChildFragment.subtreeFlags = currentPrimaryChildFragment.subtreeFlags & StaticMask;
15244          }
15245          var fallbackChildFragment;
15246          if (currentFallbackChildFragment !== null) {
15247            fallbackChildFragment = createWorkInProgress(currentFallbackChildFragment, fallbackChildren);
15248          } else {
15249            fallbackChildFragment = createFiberFromFragment(fallbackChildren, mode, renderLanes2, null);
15250            fallbackChildFragment.flags |= Placement;
15251          }
15252          fallbackChildFragment.return = workInProgress2;
15253          primaryChildFragment.return = workInProgress2;
15254          primaryChildFragment.sibling = fallbackChildFragment;
15255          workInProgress2.child = primaryChildFragment;
15256          return fallbackChildFragment;
15257        }
15258        function retrySuspenseComponentWithoutHydrating(current2, workInProgress2, renderLanes2, recoverableError) {
15259          if (recoverableError !== null) {
15260            queueHydrationError(recoverableError);
15261          }
15262          reconcileChildFibers(workInProgress2, current2.child, null, renderLanes2);
15263          var nextProps = workInProgress2.pendingProps;
15264          var primaryChildren = nextProps.children;
15265          var primaryChildFragment = mountSuspensePrimaryChildren(workInProgress2, primaryChildren);
15266          primaryChildFragment.flags |= Placement;
15267          workInProgress2.memoizedState = null;
15268          return primaryChildFragment;
15269        }
15270        function mountSuspenseFallbackAfterRetryWithoutHydrating(current2, workInProgress2, primaryChildren, fallbackChildren, renderLanes2) {
15271          var fiberMode = workInProgress2.mode;
15272          var primaryChildProps = {
15273            mode: "visible",
15274            children: primaryChildren
15275          };
15276          var primaryChildFragment = mountWorkInProgressOffscreenFiber(primaryChildProps, fiberMode);
15277          var fallbackChildFragment = createFiberFromFragment(fallbackChildren, fiberMode, renderLanes2, null);
15278          fallbackChildFragment.flags |= Placement;
15279          primaryChildFragment.return = workInProgress2;
15280          fallbackChildFragment.return = workInProgress2;
15281          primaryChildFragment.sibling = fallbackChildFragment;
15282          workInProgress2.child = primaryChildFragment;
15283          if ((workInProgress2.mode & ConcurrentMode) !== NoMode) {
15284            reconcileChildFibers(workInProgress2, current2.child, null, renderLanes2);
15285          }
15286          return fallbackChildFragment;
15287        }
15288        function mountDehydratedSuspenseComponent(workInProgress2, suspenseInstance, renderLanes2) {
15289          if ((workInProgress2.mode & ConcurrentMode) === NoMode) {
15290            {
15291              error("Cannot hydrate Suspense in legacy mode. Switch from ReactDOM.hydrate(element, container) to ReactDOMClient.hydrateRoot(container, <App />).render(element) or remove the Suspense components from the server rendered components.");
15292            }
15293            workInProgress2.lanes = laneToLanes(SyncLane);
15294          } else if (isSuspenseInstanceFallback(suspenseInstance)) {
15295            workInProgress2.lanes = laneToLanes(DefaultHydrationLane);
15296          } else {
15297            workInProgress2.lanes = laneToLanes(OffscreenLane);
15298          }
15299          return null;
15300        }
15301        function updateDehydratedSuspenseComponent(current2, workInProgress2, didSuspend, nextProps, suspenseInstance, suspenseState, renderLanes2) {
15302          if (!didSuspend) {
15303            warnIfHydrating();
15304            if ((workInProgress2.mode & ConcurrentMode) === NoMode) {
15305              return retrySuspenseComponentWithoutHydrating(
15306                current2,
15307                workInProgress2,
15308                renderLanes2,
15309                // TODO: When we delete legacy mode, we should make this error argument
15310                // required — every concurrent mode path that causes hydration to
15311                // de-opt to client rendering should have an error message.
15312                null
15313              );
15314            }
15315            if (isSuspenseInstanceFallback(suspenseInstance)) {
15316              var digest, message, stack;
15317              {
15318                var _getSuspenseInstanceF = getSuspenseInstanceFallbackErrorDetails(suspenseInstance);
15319                digest = _getSuspenseInstanceF.digest;
15320                message = _getSuspenseInstanceF.message;
15321                stack = _getSuspenseInstanceF.stack;
15322              }
15323              var error2;
15324              if (message) {
15325                error2 = new Error(message);
15326              } else {
15327                error2 = new Error("The server could not finish this Suspense boundary, likely due to an error during server rendering. Switched to client rendering.");
15328              }
15329              var capturedValue = createCapturedValue(error2, digest, stack);
15330              return retrySuspenseComponentWithoutHydrating(current2, workInProgress2, renderLanes2, capturedValue);
15331            }
15332            var hasContextChanged2 = includesSomeLane(renderLanes2, current2.childLanes);
15333            if (didReceiveUpdate || hasContextChanged2) {
15334              var root2 = getWorkInProgressRoot();
15335              if (root2 !== null) {
15336                var attemptHydrationAtLane = getBumpedLaneForHydration(root2, renderLanes2);
15337                if (attemptHydrationAtLane !== NoLane && attemptHydrationAtLane !== suspenseState.retryLane) {
15338                  suspenseState.retryLane = attemptHydrationAtLane;
15339                  var eventTime = NoTimestamp;
15340                  enqueueConcurrentRenderForLane(current2, attemptHydrationAtLane);
15341                  scheduleUpdateOnFiber(root2, current2, attemptHydrationAtLane, eventTime);
15342                }
15343              }
15344              renderDidSuspendDelayIfPossible();
15345              var _capturedValue = createCapturedValue(new Error("This Suspense boundary received an update before it finished hydrating. This caused the boundary to switch to client rendering. The usual way to fix this is to wrap the original update in startTransition."));
15346              return retrySuspenseComponentWithoutHydrating(current2, workInProgress2, renderLanes2, _capturedValue);
15347            } else if (isSuspenseInstancePending(suspenseInstance)) {
15348              workInProgress2.flags |= DidCapture;
15349              workInProgress2.child = current2.child;
15350              var retry = retryDehydratedSuspenseBoundary.bind(null, current2);
15351              registerSuspenseInstanceRetry(suspenseInstance, retry);
15352              return null;
15353            } else {
15354              reenterHydrationStateFromDehydratedSuspenseInstance(workInProgress2, suspenseInstance, suspenseState.treeContext);
15355              var primaryChildren = nextProps.children;
15356              var primaryChildFragment = mountSuspensePrimaryChildren(workInProgress2, primaryChildren);
15357              primaryChildFragment.flags |= Hydrating;
15358              return primaryChildFragment;
15359            }
15360          } else {
15361            if (workInProgress2.flags & ForceClientRender) {
15362              workInProgress2.flags &= ~ForceClientRender;
15363              var _capturedValue2 = createCapturedValue(new Error("There was an error while hydrating this Suspense boundary. Switched to client rendering."));
15364              return retrySuspenseComponentWithoutHydrating(current2, workInProgress2, renderLanes2, _capturedValue2);
15365            } else if (workInProgress2.memoizedState !== null) {
15366              workInProgress2.child = current2.child;
15367              workInProgress2.flags |= DidCapture;
15368              return null;
15369            } else {
15370              var nextPrimaryChildren = nextProps.children;
15371              var nextFallbackChildren = nextProps.fallback;
15372              var fallbackChildFragment = mountSuspenseFallbackAfterRetryWithoutHydrating(current2, workInProgress2, nextPrimaryChildren, nextFallbackChildren, renderLanes2);
15373              var _primaryChildFragment4 = workInProgress2.child;
15374              _primaryChildFragment4.memoizedState = mountSuspenseOffscreenState(renderLanes2);
15375              workInProgress2.memoizedState = SUSPENDED_MARKER;
15376              return fallbackChildFragment;
15377            }
15378          }
15379        }
15380        function scheduleSuspenseWorkOnFiber(fiber, renderLanes2, propagationRoot) {
15381          fiber.lanes = mergeLanes(fiber.lanes, renderLanes2);
15382          var alternate = fiber.alternate;
15383          if (alternate !== null) {
15384            alternate.lanes = mergeLanes(alternate.lanes, renderLanes2);
15385          }
15386          scheduleContextWorkOnParentPath(fiber.return, renderLanes2, propagationRoot);
15387        }
15388        function propagateSuspenseContextChange(workInProgress2, firstChild, renderLanes2) {
15389          var node = firstChild;
15390          while (node !== null) {
15391            if (node.tag === SuspenseComponent) {
15392              var state = node.memoizedState;
15393              if (state !== null) {
15394                scheduleSuspenseWorkOnFiber(node, renderLanes2, workInProgress2);
15395              }
15396            } else if (node.tag === SuspenseListComponent) {
15397              scheduleSuspenseWorkOnFiber(node, renderLanes2, workInProgress2);
15398            } else if (node.child !== null) {
15399              node.child.return = node;
15400              node = node.child;
15401              continue;
15402            }
15403            if (node === workInProgress2) {
15404              return;
15405            }
15406            while (node.sibling === null) {
15407              if (node.return === null || node.return === workInProgress2) {
15408                return;
15409              }
15410              node = node.return;
15411            }
15412            node.sibling.return = node.return;
15413            node = node.sibling;
15414          }
15415        }
15416        function findLastContentRow(firstChild) {
15417          var row = firstChild;
15418          var lastContentRow = null;
15419          while (row !== null) {
15420            var currentRow = row.alternate;
15421            if (currentRow !== null && findFirstSuspended(currentRow) === null) {
15422              lastContentRow = row;
15423            }
15424            row = row.sibling;
15425          }
15426          return lastContentRow;
15427        }
15428        function validateRevealOrder(revealOrder) {
15429          {
15430            if (revealOrder !== void 0 && revealOrder !== "forwards" && revealOrder !== "backwards" && revealOrder !== "together" && !didWarnAboutRevealOrder[revealOrder]) {
15431              didWarnAboutRevealOrder[revealOrder] = true;
15432              if (typeof revealOrder === "string") {
15433                switch (revealOrder.toLowerCase()) {
15434                  case "together":
15435                  case "forwards":
15436                  case "backwards": {
15437                    error('"%s" is not a valid value for revealOrder on <SuspenseList />. Use lowercase "%s" instead.', revealOrder, revealOrder.toLowerCase());
15438                    break;
15439                  }
15440                  case "forward":
15441                  case "backward": {
15442                    error('"%s" is not a valid value for revealOrder on <SuspenseList />. React uses the -s suffix in the spelling. Use "%ss" instead.', revealOrder, revealOrder.toLowerCase());
15443                    break;
15444                  }
15445                  default:
15446                    error('"%s" is not a supported revealOrder on <SuspenseList />. Did you mean "together", "forwards" or "backwards"?', revealOrder);
15447                    break;
15448                }
15449              } else {
15450                error('%s is not a supported value for revealOrder on <SuspenseList />. Did you mean "together", "forwards" or "backwards"?', revealOrder);
15451              }
15452            }
15453          }
15454        }
15455        function validateTailOptions(tailMode, revealOrder) {
15456          {
15457            if (tailMode !== void 0 && !didWarnAboutTailOptions[tailMode]) {
15458              if (tailMode !== "collapsed" && tailMode !== "hidden") {
15459                didWarnAboutTailOptions[tailMode] = true;
15460                error('"%s" is not a supported value for tail on <SuspenseList />. Did you mean "collapsed" or "hidden"?', tailMode);
15461              } else if (revealOrder !== "forwards" && revealOrder !== "backwards") {
15462                didWarnAboutTailOptions[tailMode] = true;
15463                error('<SuspenseList tail="%s" /> is only valid if revealOrder is "forwards" or "backwards". Did you mean to specify revealOrder="forwards"?', tailMode);
15464              }
15465            }
15466          }
15467        }
15468        function validateSuspenseListNestedChild(childSlot, index2) {
15469          {
15470            var isAnArray = isArray(childSlot);
15471            var isIterable = !isAnArray && typeof getIteratorFn(childSlot) === "function";
15472            if (isAnArray || isIterable) {
15473              var type = isAnArray ? "array" : "iterable";
15474              error("A nested %s was passed to row #%s in <SuspenseList />. Wrap it in an additional SuspenseList to configure its revealOrder: <SuspenseList revealOrder=...> ... <SuspenseList revealOrder=...>{%s}</SuspenseList> ... </SuspenseList>", type, index2, type);
15475              return false;
15476            }
15477          }
15478          return true;
15479        }
15480        function validateSuspenseListChildren(children, revealOrder) {
15481          {
15482            if ((revealOrder === "forwards" || revealOrder === "backwards") && children !== void 0 && children !== null && children !== false) {
15483              if (isArray(children)) {
15484                for (var i = 0; i < children.length; i++) {
15485                  if (!validateSuspenseListNestedChild(children[i], i)) {
15486                    return;
15487                  }
15488                }
15489              } else {
15490                var iteratorFn = getIteratorFn(children);
15491                if (typeof iteratorFn === "function") {
15492                  var childrenIterator = iteratorFn.call(children);
15493                  if (childrenIterator) {
15494                    var step = childrenIterator.next();
15495                    var _i = 0;
15496                    for (; !step.done; step = childrenIterator.next()) {
15497                      if (!validateSuspenseListNestedChild(step.value, _i)) {
15498                        return;
15499                      }
15500                      _i++;
15501                    }
15502                  }
15503                } else {
15504                  error('A single row was passed to a <SuspenseList revealOrder="%s" />. This is not useful since it needs multiple rows. Did you mean to pass multiple children or an array?', revealOrder);
15505                }
15506              }
15507            }
15508          }
15509        }
15510        function initSuspenseListRenderState(workInProgress2, isBackwards, tail, lastContentRow, tailMode) {
15511          var renderState = workInProgress2.memoizedState;
15512          if (renderState === null) {
15513            workInProgress2.memoizedState = {
15514              isBackwards,
15515              rendering: null,
15516              renderingStartTime: 0,
15517              last: lastContentRow,
15518              tail,
15519              tailMode
15520            };
15521          } else {
15522            renderState.isBackwards = isBackwards;
15523            renderState.rendering = null;
15524            renderState.renderingStartTime = 0;
15525            renderState.last = lastContentRow;
15526            renderState.tail = tail;
15527            renderState.tailMode = tailMode;
15528          }
15529        }
15530        function updateSuspenseListComponent(current2, workInProgress2, renderLanes2) {
15531          var nextProps = workInProgress2.pendingProps;
15532          var revealOrder = nextProps.revealOrder;
15533          var tailMode = nextProps.tail;
15534          var newChildren = nextProps.children;
15535          validateRevealOrder(revealOrder);
15536          validateTailOptions(tailMode, revealOrder);
15537          validateSuspenseListChildren(newChildren, revealOrder);
15538          reconcileChildren(current2, workInProgress2, newChildren, renderLanes2);
15539          var suspenseContext = suspenseStackCursor.current;
15540          var shouldForceFallback = hasSuspenseContext(suspenseContext, ForceSuspenseFallback);
15541          if (shouldForceFallback) {
15542            suspenseContext = setShallowSuspenseContext(suspenseContext, ForceSuspenseFallback);
15543            workInProgress2.flags |= DidCapture;
15544          } else {
15545            var didSuspendBefore = current2 !== null && (current2.flags & DidCapture) !== NoFlags;
15546            if (didSuspendBefore) {
15547              propagateSuspenseContextChange(workInProgress2, workInProgress2.child, renderLanes2);
15548            }
15549            suspenseContext = setDefaultShallowSuspenseContext(suspenseContext);
15550          }
15551          pushSuspenseContext(workInProgress2, suspenseContext);
15552          if ((workInProgress2.mode & ConcurrentMode) === NoMode) {
15553            workInProgress2.memoizedState = null;
15554          } else {
15555            switch (revealOrder) {
15556              case "forwards": {
15557                var lastContentRow = findLastContentRow(workInProgress2.child);
15558                var tail;
15559                if (lastContentRow === null) {
15560                  tail = workInProgress2.child;
15561                  workInProgress2.child = null;
15562                } else {
15563                  tail = lastContentRow.sibling;
15564                  lastContentRow.sibling = null;
15565                }
15566                initSuspenseListRenderState(
15567                  workInProgress2,
15568                  false,
15569                  // isBackwards
15570                  tail,
15571                  lastContentRow,
15572                  tailMode
15573                );
15574                break;
15575              }
15576              case "backwards": {
15577                var _tail = null;
15578                var row = workInProgress2.child;
15579                workInProgress2.child = null;
15580                while (row !== null) {
15581                  var currentRow = row.alternate;
15582                  if (currentRow !== null && findFirstSuspended(currentRow) === null) {
15583                    workInProgress2.child = row;
15584                    break;
15585                  }
15586                  var nextRow = row.sibling;
15587                  row.sibling = _tail;
15588                  _tail = row;
15589                  row = nextRow;
15590                }
15591                initSuspenseListRenderState(
15592                  workInProgress2,
15593                  true,
15594                  // isBackwards
15595                  _tail,
15596                  null,
15597                  // last
15598                  tailMode
15599                );
15600                break;
15601              }
15602              case "together": {
15603                initSuspenseListRenderState(
15604                  workInProgress2,
15605                  false,
15606                  // isBackwards
15607                  null,
15608                  // tail
15609                  null,
15610                  // last
15611                  void 0
15612                );
15613                break;
15614              }
15615              default: {
15616                workInProgress2.memoizedState = null;
15617              }
15618            }
15619          }
15620          return workInProgress2.child;
15621        }
15622        function updatePortalComponent(current2, workInProgress2, renderLanes2) {
15623          pushHostContainer(workInProgress2, workInProgress2.stateNode.containerInfo);
15624          var nextChildren = workInProgress2.pendingProps;
15625          if (current2 === null) {
15626            workInProgress2.child = reconcileChildFibers(workInProgress2, null, nextChildren, renderLanes2);
15627          } else {
15628            reconcileChildren(current2, workInProgress2, nextChildren, renderLanes2);
15629          }
15630          return workInProgress2.child;
15631        }
15632        var hasWarnedAboutUsingNoValuePropOnContextProvider = false;
15633        function updateContextProvider(current2, workInProgress2, renderLanes2) {
15634          var providerType = workInProgress2.type;
15635          var context = providerType._context;
15636          var newProps = workInProgress2.pendingProps;
15637          var oldProps = workInProgress2.memoizedProps;
15638          var newValue = newProps.value;
15639          {
15640            if (!("value" in newProps)) {
15641              if (!hasWarnedAboutUsingNoValuePropOnContextProvider) {
15642                hasWarnedAboutUsingNoValuePropOnContextProvider = true;
15643                error("The `value` prop is required for the `<Context.Provider>`. Did you misspell it or forget to pass it?");
15644              }
15645            }
15646            var providerPropTypes = workInProgress2.type.propTypes;
15647            if (providerPropTypes) {
15648              checkPropTypes(providerPropTypes, newProps, "prop", "Context.Provider");
15649            }
15650          }
15651          pushProvider(workInProgress2, context, newValue);
15652          {
15653            if (oldProps !== null) {
15654              var oldValue = oldProps.value;
15655              if (objectIs(oldValue, newValue)) {
15656                if (oldProps.children === newProps.children && !hasContextChanged()) {
15657                  return bailoutOnAlreadyFinishedWork(current2, workInProgress2, renderLanes2);
15658                }
15659              } else {
15660                propagateContextChange(workInProgress2, context, renderLanes2);
15661              }
15662            }
15663          }
15664          var newChildren = newProps.children;
15665          reconcileChildren(current2, workInProgress2, newChildren, renderLanes2);
15666          return workInProgress2.child;
15667        }
15668        var hasWarnedAboutUsingContextAsConsumer = false;
15669        function updateContextConsumer(current2, workInProgress2, renderLanes2) {
15670          var context = workInProgress2.type;
15671          {
15672            if (context._context === void 0) {
15673              if (context !== context.Consumer) {
15674                if (!hasWarnedAboutUsingContextAsConsumer) {
15675                  hasWarnedAboutUsingContextAsConsumer = true;
15676                  error("Rendering <Context> directly is not supported and will be removed in a future major release. Did you mean to render <Context.Consumer> instead?");
15677                }
15678              }
15679            } else {
15680              context = context._context;
15681            }
15682          }
15683          var newProps = workInProgress2.pendingProps;
15684          var render2 = newProps.children;
15685          {
15686            if (typeof render2 !== "function") {
15687              error("A context consumer was rendered with multiple children, or a child that isn't a function. A context consumer expects a single child that is a function. If you did pass a function, make sure there is no trailing or leading whitespace around it.");
15688            }
15689          }
15690          prepareToReadContext(workInProgress2, renderLanes2);
15691          var newValue = readContext(context);
15692          {
15693            markComponentRenderStarted(workInProgress2);
15694          }
15695          var newChildren;
15696          {
15697            ReactCurrentOwner$1.current = workInProgress2;
15698            setIsRendering(true);
15699            newChildren = render2(newValue);
15700            setIsRendering(false);
15701          }
15702          {
15703            markComponentRenderStopped();
15704          }
15705          workInProgress2.flags |= PerformedWork;
15706          reconcileChildren(current2, workInProgress2, newChildren, renderLanes2);
15707          return workInProgress2.child;
15708        }
15709        function markWorkInProgressReceivedUpdate() {
15710          didReceiveUpdate = true;
15711        }
15712        function resetSuspendedCurrentOnMountInLegacyMode(current2, workInProgress2) {
15713          if ((workInProgress2.mode & ConcurrentMode) === NoMode) {
15714            if (current2 !== null) {
15715              current2.alternate = null;
15716              workInProgress2.alternate = null;
15717              workInProgress2.flags |= Placement;
15718            }
15719          }
15720        }
15721        function bailoutOnAlreadyFinishedWork(current2, workInProgress2, renderLanes2) {
15722          if (current2 !== null) {
15723            workInProgress2.dependencies = current2.dependencies;
15724          }
15725          {
15726            stopProfilerTimerIfRunning();
15727          }
15728          markSkippedUpdateLanes(workInProgress2.lanes);
15729          if (!includesSomeLane(renderLanes2, workInProgress2.childLanes)) {
15730            {
15731              return null;
15732            }
15733          }
15734          cloneChildFibers(current2, workInProgress2);
15735          return workInProgress2.child;
15736        }
15737        function remountFiber(current2, oldWorkInProgress, newWorkInProgress) {
15738          {
15739            var returnFiber = oldWorkInProgress.return;
15740            if (returnFiber === null) {
15741              throw new Error("Cannot swap the root fiber.");
15742            }
15743            current2.alternate = null;
15744            oldWorkInProgress.alternate = null;
15745            newWorkInProgress.index = oldWorkInProgress.index;
15746            newWorkInProgress.sibling = oldWorkInProgress.sibling;
15747            newWorkInProgress.return = oldWorkInProgress.return;
15748            newWorkInProgress.ref = oldWorkInProgress.ref;
15749            if (oldWorkInProgress === returnFiber.child) {
15750              returnFiber.child = newWorkInProgress;
15751            } else {
15752              var prevSibling = returnFiber.child;
15753              if (prevSibling === null) {
15754                throw new Error("Expected parent to have a child.");
15755              }
15756              while (prevSibling.sibling !== oldWorkInProgress) {
15757                prevSibling = prevSibling.sibling;
15758                if (prevSibling === null) {
15759                  throw new Error("Expected to find the previous sibling.");
15760                }
15761              }
15762              prevSibling.sibling = newWorkInProgress;
15763            }
15764            var deletions = returnFiber.deletions;
15765            if (deletions === null) {
15766              returnFiber.deletions = [current2];
15767              returnFiber.flags |= ChildDeletion;
15768            } else {
15769              deletions.push(current2);
15770            }
15771            newWorkInProgress.flags |= Placement;
15772            return newWorkInProgress;
15773          }
15774        }
15775        function checkScheduledUpdateOrContext(current2, renderLanes2) {
15776          var updateLanes = current2.lanes;
15777          if (includesSomeLane(updateLanes, renderLanes2)) {
15778            return true;
15779          }
15780          return false;
15781        }
15782        function attemptEarlyBailoutIfNoScheduledUpdate(current2, workInProgress2, renderLanes2) {
15783          switch (workInProgress2.tag) {
15784            case HostRoot:
15785              pushHostRootContext(workInProgress2);
15786              var root2 = workInProgress2.stateNode;
15787              resetHydrationState();
15788              break;
15789            case HostComponent:
15790              pushHostContext(workInProgress2);
15791              break;
15792            case ClassComponent: {
15793              var Component = workInProgress2.type;
15794              if (isContextProvider(Component)) {
15795                pushContextProvider(workInProgress2);
15796              }
15797              break;
15798            }
15799            case HostPortal:
15800              pushHostContainer(workInProgress2, workInProgress2.stateNode.containerInfo);
15801              break;
15802            case ContextProvider: {
15803              var newValue = workInProgress2.memoizedProps.value;
15804              var context = workInProgress2.type._context;
15805              pushProvider(workInProgress2, context, newValue);
15806              break;
15807            }
15808            case Profiler:
15809              {
15810                var hasChildWork = includesSomeLane(renderLanes2, workInProgress2.childLanes);
15811                if (hasChildWork) {
15812                  workInProgress2.flags |= Update;
15813                }
15814                {
15815                  var stateNode = workInProgress2.stateNode;
15816                  stateNode.effectDuration = 0;
15817                  stateNode.passiveEffectDuration = 0;
15818                }
15819              }
15820              break;
15821            case SuspenseComponent: {
15822              var state = workInProgress2.memoizedState;
15823              if (state !== null) {
15824                if (state.dehydrated !== null) {
15825                  pushSuspenseContext(workInProgress2, setDefaultShallowSuspenseContext(suspenseStackCursor.current));
15826                  workInProgress2.flags |= DidCapture;
15827                  return null;
15828                }
15829                var primaryChildFragment = workInProgress2.child;
15830                var primaryChildLanes = primaryChildFragment.childLanes;
15831                if (includesSomeLane(renderLanes2, primaryChildLanes)) {
15832                  return updateSuspenseComponent(current2, workInProgress2, renderLanes2);
15833                } else {
15834                  pushSuspenseContext(workInProgress2, setDefaultShallowSuspenseContext(suspenseStackCursor.current));
15835                  var child = bailoutOnAlreadyFinishedWork(current2, workInProgress2, renderLanes2);
15836                  if (child !== null) {
15837                    return child.sibling;
15838                  } else {
15839                    return null;
15840                  }
15841                }
15842              } else {
15843                pushSuspenseContext(workInProgress2, setDefaultShallowSuspenseContext(suspenseStackCursor.current));
15844              }
15845              break;
15846            }
15847            case SuspenseListComponent: {
15848              var didSuspendBefore = (current2.flags & DidCapture) !== NoFlags;
15849              var _hasChildWork = includesSomeLane(renderLanes2, workInProgress2.childLanes);
15850              if (didSuspendBefore) {
15851                if (_hasChildWork) {
15852                  return updateSuspenseListComponent(current2, workInProgress2, renderLanes2);
15853                }
15854                workInProgress2.flags |= DidCapture;
15855              }
15856              var renderState = workInProgress2.memoizedState;
15857              if (renderState !== null) {
15858                renderState.rendering = null;
15859                renderState.tail = null;
15860                renderState.lastEffect = null;
15861              }
15862              pushSuspenseContext(workInProgress2, suspenseStackCursor.current);
15863              if (_hasChildWork) {
15864                break;
15865              } else {
15866                return null;
15867              }
15868            }
15869            case OffscreenComponent:
15870            case LegacyHiddenComponent: {
15871              workInProgress2.lanes = NoLanes;
15872              return updateOffscreenComponent(current2, workInProgress2, renderLanes2);
15873            }
15874          }
15875          return bailoutOnAlreadyFinishedWork(current2, workInProgress2, renderLanes2);
15876        }
15877        function beginWork(current2, workInProgress2, renderLanes2) {
15878          {
15879            if (workInProgress2._debugNeedsRemount && current2 !== null) {
15880              return remountFiber(current2, workInProgress2, createFiberFromTypeAndProps(workInProgress2.type, workInProgress2.key, workInProgress2.pendingProps, workInProgress2._debugOwner || null, workInProgress2.mode, workInProgress2.lanes));
15881            }
15882          }
15883          if (current2 !== null) {
15884            var oldProps = current2.memoizedProps;
15885            var newProps = workInProgress2.pendingProps;
15886            if (oldProps !== newProps || hasContextChanged() || // Force a re-render if the implementation changed due to hot reload:
15887            workInProgress2.type !== current2.type) {
15888              didReceiveUpdate = true;
15889            } else {
15890              var hasScheduledUpdateOrContext = checkScheduledUpdateOrContext(current2, renderLanes2);
15891              if (!hasScheduledUpdateOrContext && // If this is the second pass of an error or suspense boundary, there
15892              // may not be work scheduled on `current`, so we check for this flag.
15893              (workInProgress2.flags & DidCapture) === NoFlags) {
15894                didReceiveUpdate = false;
15895                return attemptEarlyBailoutIfNoScheduledUpdate(current2, workInProgress2, renderLanes2);
15896              }
15897              if ((current2.flags & ForceUpdateForLegacySuspense) !== NoFlags) {
15898                didReceiveUpdate = true;
15899              } else {
15900                didReceiveUpdate = false;
15901              }
15902            }
15903          } else {
15904            didReceiveUpdate = false;
15905            if (getIsHydrating() && isForkedChild(workInProgress2)) {
15906              var slotIndex = workInProgress2.index;
15907              var numberOfForks = getForksAtLevel();
15908              pushTreeId(workInProgress2, numberOfForks, slotIndex);
15909            }
15910          }
15911          workInProgress2.lanes = NoLanes;
15912          switch (workInProgress2.tag) {
15913            case IndeterminateComponent: {
15914              return mountIndeterminateComponent(current2, workInProgress2, workInProgress2.type, renderLanes2);
15915            }
15916            case LazyComponent: {
15917              var elementType = workInProgress2.elementType;
15918              return mountLazyComponent(current2, workInProgress2, elementType, renderLanes2);
15919            }
15920            case FunctionComponent: {
15921              var Component = workInProgress2.type;
15922              var unresolvedProps = workInProgress2.pendingProps;
15923              var resolvedProps = workInProgress2.elementType === Component ? unresolvedProps : resolveDefaultProps(Component, unresolvedProps);
15924              return updateFunctionComponent(current2, workInProgress2, Component, resolvedProps, renderLanes2);
15925            }
15926            case ClassComponent: {
15927              var _Component = workInProgress2.type;
15928              var _unresolvedProps = workInProgress2.pendingProps;
15929              var _resolvedProps = workInProgress2.elementType === _Component ? _unresolvedProps : resolveDefaultProps(_Component, _unresolvedProps);
15930              return updateClassComponent(current2, workInProgress2, _Component, _resolvedProps, renderLanes2);
15931            }
15932            case HostRoot:
15933              return updateHostRoot(current2, workInProgress2, renderLanes2);
15934            case HostComponent:
15935              return updateHostComponent(current2, workInProgress2, renderLanes2);
15936            case HostText:
15937              return updateHostText(current2, workInProgress2);
15938            case SuspenseComponent:
15939              return updateSuspenseComponent(current2, workInProgress2, renderLanes2);
15940            case HostPortal:
15941              return updatePortalComponent(current2, workInProgress2, renderLanes2);
15942            case ForwardRef: {
15943              var type = workInProgress2.type;
15944              var _unresolvedProps2 = workInProgress2.pendingProps;
15945              var _resolvedProps2 = workInProgress2.elementType === type ? _unresolvedProps2 : resolveDefaultProps(type, _unresolvedProps2);
15946              return updateForwardRef(current2, workInProgress2, type, _resolvedProps2, renderLanes2);
15947            }
15948            case Fragment:
15949              return updateFragment(current2, workInProgress2, renderLanes2);
15950            case Mode:
15951              return updateMode(current2, workInProgress2, renderLanes2);
15952            case Profiler:
15953              return updateProfiler(current2, workInProgress2, renderLanes2);
15954            case ContextProvider:
15955              return updateContextProvider(current2, workInProgress2, renderLanes2);
15956            case ContextConsumer:
15957              return updateContextConsumer(current2, workInProgress2, renderLanes2);
15958            case MemoComponent: {
15959              var _type2 = workInProgress2.type;
15960              var _unresolvedProps3 = workInProgress2.pendingProps;
15961              var _resolvedProps3 = resolveDefaultProps(_type2, _unresolvedProps3);
15962              {
15963                if (workInProgress2.type !== workInProgress2.elementType) {
15964                  var outerPropTypes = _type2.propTypes;
15965                  if (outerPropTypes) {
15966                    checkPropTypes(
15967                      outerPropTypes,
15968                      _resolvedProps3,
15969                      // Resolved for outer only
15970                      "prop",
15971                      getComponentNameFromType(_type2)
15972                    );
15973                  }
15974                }
15975              }
15976              _resolvedProps3 = resolveDefaultProps(_type2.type, _resolvedProps3);
15977              return updateMemoComponent(current2, workInProgress2, _type2, _resolvedProps3, renderLanes2);
15978            }
15979            case SimpleMemoComponent: {
15980              return updateSimpleMemoComponent(current2, workInProgress2, workInProgress2.type, workInProgress2.pendingProps, renderLanes2);
15981            }
15982            case IncompleteClassComponent: {
15983              var _Component2 = workInProgress2.type;
15984              var _unresolvedProps4 = workInProgress2.pendingProps;
15985              var _resolvedProps4 = workInProgress2.elementType === _Component2 ? _unresolvedProps4 : resolveDefaultProps(_Component2, _unresolvedProps4);
15986              return mountIncompleteClassComponent(current2, workInProgress2, _Component2, _resolvedProps4, renderLanes2);
15987            }
15988            case SuspenseListComponent: {
15989              return updateSuspenseListComponent(current2, workInProgress2, renderLanes2);
15990            }
15991            case ScopeComponent: {
15992              break;
15993            }
15994            case OffscreenComponent: {
15995              return updateOffscreenComponent(current2, workInProgress2, renderLanes2);
15996            }
15997          }
15998          throw new Error("Unknown unit of work tag (" + workInProgress2.tag + "). This error is likely caused by a bug in React. Please file an issue.");
15999        }
16000        function markUpdate(workInProgress2) {
16001          workInProgress2.flags |= Update;
16002        }
16003        function markRef$1(workInProgress2) {
16004          workInProgress2.flags |= Ref;
16005          {
16006            workInProgress2.flags |= RefStatic;
16007          }
16008        }
16009        var appendAllChildren;
16010        var updateHostContainer;
16011        var updateHostComponent$1;
16012        var updateHostText$1;
16013        {
16014          appendAllChildren = function(parent, workInProgress2, needsVisibilityToggle, isHidden) {
16015            var node = workInProgress2.child;
16016            while (node !== null) {
16017              if (node.tag === HostComponent || node.tag === HostText) {
16018                appendInitialChild(parent, node.stateNode);
16019              } else if (node.tag === HostPortal) ;
16020              else if (node.child !== null) {
16021                node.child.return = node;
16022                node = node.child;
16023                continue;
16024              }
16025              if (node === workInProgress2) {
16026                return;
16027              }
16028              while (node.sibling === null) {
16029                if (node.return === null || node.return === workInProgress2) {
16030                  return;
16031                }
16032                node = node.return;
16033              }
16034              node.sibling.return = node.return;
16035              node = node.sibling;
16036            }
16037          };
16038          updateHostContainer = function(current2, workInProgress2) {
16039          };
16040          updateHostComponent$1 = function(current2, workInProgress2, type, newProps, rootContainerInstance) {
16041            var oldProps = current2.memoizedProps;
16042            if (oldProps === newProps) {
16043              return;
16044            }
16045            var instance = workInProgress2.stateNode;
16046            var currentHostContext = getHostContext();
16047            var updatePayload = prepareUpdate(instance, type, oldProps, newProps, rootContainerInstance, currentHostContext);
16048            workInProgress2.updateQueue = updatePayload;
16049            if (updatePayload) {
16050              markUpdate(workInProgress2);
16051            }
16052          };
16053          updateHostText$1 = function(current2, workInProgress2, oldText, newText) {
16054            if (oldText !== newText) {
16055              markUpdate(workInProgress2);
16056            }
16057          };
16058        }
16059        function cutOffTailIfNeeded(renderState, hasRenderedATailFallback) {
16060          if (getIsHydrating()) {
16061            return;
16062          }
16063          switch (renderState.tailMode) {
16064            case "hidden": {
16065              var tailNode = renderState.tail;
16066              var lastTailNode = null;
16067              while (tailNode !== null) {
16068                if (tailNode.alternate !== null) {
16069                  lastTailNode = tailNode;
16070                }
16071                tailNode = tailNode.sibling;
16072              }
16073              if (lastTailNode === null) {
16074                renderState.tail = null;
16075              } else {
16076                lastTailNode.sibling = null;
16077              }
16078              break;
16079            }
16080            case "collapsed": {
16081              var _tailNode = renderState.tail;
16082              var _lastTailNode = null;
16083              while (_tailNode !== null) {
16084                if (_tailNode.alternate !== null) {
16085                  _lastTailNode = _tailNode;
16086                }
16087                _tailNode = _tailNode.sibling;
16088              }
16089              if (_lastTailNode === null) {
16090                if (!hasRenderedATailFallback && renderState.tail !== null) {
16091                  renderState.tail.sibling = null;
16092                } else {
16093                  renderState.tail = null;
16094                }
16095              } else {
16096                _lastTailNode.sibling = null;
16097              }
16098              break;
16099            }
16100          }
16101        }
16102        function bubbleProperties(completedWork) {
16103          var didBailout = completedWork.alternate !== null && completedWork.alternate.child === completedWork.child;
16104          var newChildLanes = NoLanes;
16105          var subtreeFlags = NoFlags;
16106          if (!didBailout) {
16107            if ((completedWork.mode & ProfileMode) !== NoMode) {
16108              var actualDuration = completedWork.actualDuration;
16109              var treeBaseDuration = completedWork.selfBaseDuration;
16110              var child = completedWork.child;
16111              while (child !== null) {
16112                newChildLanes = mergeLanes(newChildLanes, mergeLanes(child.lanes, child.childLanes));
16113                subtreeFlags |= child.subtreeFlags;
16114                subtreeFlags |= child.flags;
16115                actualDuration += child.actualDuration;
16116                treeBaseDuration += child.treeBaseDuration;
16117                child = child.sibling;
16118              }
16119              completedWork.actualDuration = actualDuration;
16120              completedWork.treeBaseDuration = treeBaseDuration;
16121            } else {
16122              var _child = completedWork.child;
16123              while (_child !== null) {
16124                newChildLanes = mergeLanes(newChildLanes, mergeLanes(_child.lanes, _child.childLanes));
16125                subtreeFlags |= _child.subtreeFlags;
16126                subtreeFlags |= _child.flags;
16127                _child.return = completedWork;
16128                _child = _child.sibling;
16129              }
16130            }
16131            completedWork.subtreeFlags |= subtreeFlags;
16132          } else {
16133            if ((completedWork.mode & ProfileMode) !== NoMode) {
16134              var _treeBaseDuration = completedWork.selfBaseDuration;
16135              var _child2 = completedWork.child;
16136              while (_child2 !== null) {
16137                newChildLanes = mergeLanes(newChildLanes, mergeLanes(_child2.lanes, _child2.childLanes));
16138                subtreeFlags |= _child2.subtreeFlags & StaticMask;
16139                subtreeFlags |= _child2.flags & StaticMask;
16140                _treeBaseDuration += _child2.treeBaseDuration;
16141                _child2 = _child2.sibling;
16142              }
16143              completedWork.treeBaseDuration = _treeBaseDuration;
16144            } else {
16145              var _child3 = completedWork.child;
16146              while (_child3 !== null) {
16147                newChildLanes = mergeLanes(newChildLanes, mergeLanes(_child3.lanes, _child3.childLanes));
16148                subtreeFlags |= _child3.subtreeFlags & StaticMask;
16149                subtreeFlags |= _child3.flags & StaticMask;
16150                _child3.return = completedWork;
16151                _child3 = _child3.sibling;
16152              }
16153            }
16154            completedWork.subtreeFlags |= subtreeFlags;
16155          }
16156          completedWork.childLanes = newChildLanes;
16157          return didBailout;
16158        }
16159        function completeDehydratedSuspenseBoundary(current2, workInProgress2, nextState) {
16160          if (hasUnhydratedTailNodes() && (workInProgress2.mode & ConcurrentMode) !== NoMode && (workInProgress2.flags & DidCapture) === NoFlags) {
16161            warnIfUnhydratedTailNodes(workInProgress2);
16162            resetHydrationState();
16163            workInProgress2.flags |= ForceClientRender | Incomplete | ShouldCapture;
16164            return false;
16165          }
16166          var wasHydrated = popHydrationState(workInProgress2);
16167          if (nextState !== null && nextState.dehydrated !== null) {
16168            if (current2 === null) {
16169              if (!wasHydrated) {
16170                throw new Error("A dehydrated suspense component was completed without a hydrated node. This is probably a bug in React.");
16171              }
16172              prepareToHydrateHostSuspenseInstance(workInProgress2);
16173              bubbleProperties(workInProgress2);
16174              {
16175                if ((workInProgress2.mode & ProfileMode) !== NoMode) {
16176                  var isTimedOutSuspense = nextState !== null;
16177                  if (isTimedOutSuspense) {
16178                    var primaryChildFragment = workInProgress2.child;
16179                    if (primaryChildFragment !== null) {
16180                      workInProgress2.treeBaseDuration -= primaryChildFragment.treeBaseDuration;
16181                    }
16182                  }
16183                }
16184              }
16185              return false;
16186            } else {
16187              resetHydrationState();
16188              if ((workInProgress2.flags & DidCapture) === NoFlags) {
16189                workInProgress2.memoizedState = null;
16190              }
16191              workInProgress2.flags |= Update;
16192              bubbleProperties(workInProgress2);
16193              {
16194                if ((workInProgress2.mode & ProfileMode) !== NoMode) {
16195                  var _isTimedOutSuspense = nextState !== null;
16196                  if (_isTimedOutSuspense) {
16197                    var _primaryChildFragment = workInProgress2.child;
16198                    if (_primaryChildFragment !== null) {
16199                      workInProgress2.treeBaseDuration -= _primaryChildFragment.treeBaseDuration;
16200                    }
16201                  }
16202                }
16203              }
16204              return false;
16205            }
16206          } else {
16207            upgradeHydrationErrorsToRecoverable();
16208            return true;
16209          }
16210        }
16211        function completeWork(current2, workInProgress2, renderLanes2) {
16212          var newProps = workInProgress2.pendingProps;
16213          popTreeContext(workInProgress2);
16214          switch (workInProgress2.tag) {
16215            case IndeterminateComponent:
16216            case LazyComponent:
16217            case SimpleMemoComponent:
16218            case FunctionComponent:
16219            case ForwardRef:
16220            case Fragment:
16221            case Mode:
16222            case Profiler:
16223            case ContextConsumer:
16224            case MemoComponent:
16225              bubbleProperties(workInProgress2);
16226              return null;
16227            case ClassComponent: {
16228              var Component = workInProgress2.type;
16229              if (isContextProvider(Component)) {
16230                popContext(workInProgress2);
16231              }
16232              bubbleProperties(workInProgress2);
16233              return null;
16234            }
16235            case HostRoot: {
16236              var fiberRoot = workInProgress2.stateNode;
16237              popHostContainer(workInProgress2);
16238              popTopLevelContextObject(workInProgress2);
16239              resetWorkInProgressVersions();
16240              if (fiberRoot.pendingContext) {
16241                fiberRoot.context = fiberRoot.pendingContext;
16242                fiberRoot.pendingContext = null;
16243              }
16244              if (current2 === null || current2.child === null) {
16245                var wasHydrated = popHydrationState(workInProgress2);
16246                if (wasHydrated) {
16247                  markUpdate(workInProgress2);
16248                } else {
16249                  if (current2 !== null) {
16250                    var prevState = current2.memoizedState;
16251                    if (
16252                      // Check if this is a client root
16253                      !prevState.isDehydrated || // Check if we reverted to client rendering (e.g. due to an error)
16254                      (workInProgress2.flags & ForceClientRender) !== NoFlags
16255                    ) {
16256                      workInProgress2.flags |= Snapshot;
16257                      upgradeHydrationErrorsToRecoverable();
16258                    }
16259                  }
16260                }
16261              }
16262              updateHostContainer(current2, workInProgress2);
16263              bubbleProperties(workInProgress2);
16264              return null;
16265            }
16266            case HostComponent: {
16267              popHostContext(workInProgress2);
16268              var rootContainerInstance = getRootHostContainer();
16269              var type = workInProgress2.type;
16270              if (current2 !== null && workInProgress2.stateNode != null) {
16271                updateHostComponent$1(current2, workInProgress2, type, newProps, rootContainerInstance);
16272                if (current2.ref !== workInProgress2.ref) {
16273                  markRef$1(workInProgress2);
16274                }
16275              } else {
16276                if (!newProps) {
16277                  if (workInProgress2.stateNode === null) {
16278                    throw new Error("We must have new props for new mounts. This error is likely caused by a bug in React. Please file an issue.");
16279                  }
16280                  bubbleProperties(workInProgress2);
16281                  return null;
16282                }
16283                var currentHostContext = getHostContext();
16284                var _wasHydrated = popHydrationState(workInProgress2);
16285                if (_wasHydrated) {
16286                  if (prepareToHydrateHostInstance(workInProgress2, rootContainerInstance, currentHostContext)) {
16287                    markUpdate(workInProgress2);
16288                  }
16289                } else {
16290                  var instance = createInstance(type, newProps, rootContainerInstance, currentHostContext, workInProgress2);
16291                  appendAllChildren(instance, workInProgress2, false, false);
16292                  workInProgress2.stateNode = instance;
16293                  if (finalizeInitialChildren(instance, type, newProps, rootContainerInstance)) {
16294                    markUpdate(workInProgress2);
16295                  }
16296                }
16297                if (workInProgress2.ref !== null) {
16298                  markRef$1(workInProgress2);
16299                }
16300              }
16301              bubbleProperties(workInProgress2);
16302              return null;
16303            }
16304            case HostText: {
16305              var newText = newProps;
16306              if (current2 && workInProgress2.stateNode != null) {
16307                var oldText = current2.memoizedProps;
16308                updateHostText$1(current2, workInProgress2, oldText, newText);
16309              } else {
16310                if (typeof newText !== "string") {
16311                  if (workInProgress2.stateNode === null) {
16312                    throw new Error("We must have new props for new mounts. This error is likely caused by a bug in React. Please file an issue.");
16313                  }
16314                }
16315                var _rootContainerInstance = getRootHostContainer();
16316                var _currentHostContext = getHostContext();
16317                var _wasHydrated2 = popHydrationState(workInProgress2);
16318                if (_wasHydrated2) {
16319                  if (prepareToHydrateHostTextInstance(workInProgress2)) {
16320                    markUpdate(workInProgress2);
16321                  }
16322                } else {
16323                  workInProgress2.stateNode = createTextInstance(newText, _rootContainerInstance, _currentHostContext, workInProgress2);
16324                }
16325              }
16326              bubbleProperties(workInProgress2);
16327              return null;
16328            }
16329            case SuspenseComponent: {
16330              popSuspenseContext(workInProgress2);
16331              var nextState = workInProgress2.memoizedState;
16332              if (current2 === null || current2.memoizedState !== null && current2.memoizedState.dehydrated !== null) {
16333                var fallthroughToNormalSuspensePath = completeDehydratedSuspenseBoundary(current2, workInProgress2, nextState);
16334                if (!fallthroughToNormalSuspensePath) {
16335                  if (workInProgress2.flags & ShouldCapture) {
16336                    return workInProgress2;
16337                  } else {
16338                    return null;
16339                  }
16340                }
16341              }
16342              if ((workInProgress2.flags & DidCapture) !== NoFlags) {
16343                workInProgress2.lanes = renderLanes2;
16344                if ((workInProgress2.mode & ProfileMode) !== NoMode) {
16345                  transferActualDuration(workInProgress2);
16346                }
16347                return workInProgress2;
16348              }
16349              var nextDidTimeout = nextState !== null;
16350              var prevDidTimeout = current2 !== null && current2.memoizedState !== null;
16351              if (nextDidTimeout !== prevDidTimeout) {
16352                if (nextDidTimeout) {
16353                  var _offscreenFiber2 = workInProgress2.child;
16354                  _offscreenFiber2.flags |= Visibility;
16355                  if ((workInProgress2.mode & ConcurrentMode) !== NoMode) {
16356                    var hasInvisibleChildContext = current2 === null && (workInProgress2.memoizedProps.unstable_avoidThisFallback !== true || !enableSuspenseAvoidThisFallback);
16357                    if (hasInvisibleChildContext || hasSuspenseContext(suspenseStackCursor.current, InvisibleParentSuspenseContext)) {
16358                      renderDidSuspend();
16359                    } else {
16360                      renderDidSuspendDelayIfPossible();
16361                    }
16362                  }
16363                }
16364              }
16365              var wakeables = workInProgress2.updateQueue;
16366              if (wakeables !== null) {
16367                workInProgress2.flags |= Update;
16368              }
16369              bubbleProperties(workInProgress2);
16370              {
16371                if ((workInProgress2.mode & ProfileMode) !== NoMode) {
16372                  if (nextDidTimeout) {
16373                    var primaryChildFragment = workInProgress2.child;
16374                    if (primaryChildFragment !== null) {
16375                      workInProgress2.treeBaseDuration -= primaryChildFragment.treeBaseDuration;
16376                    }
16377                  }
16378                }
16379              }
16380              return null;
16381            }
16382            case HostPortal:
16383              popHostContainer(workInProgress2);
16384              updateHostContainer(current2, workInProgress2);
16385              if (current2 === null) {
16386                preparePortalMount(workInProgress2.stateNode.containerInfo);
16387              }
16388              bubbleProperties(workInProgress2);
16389              return null;
16390            case ContextProvider:
16391              var context = workInProgress2.type._context;
16392              popProvider(context, workInProgress2);
16393              bubbleProperties(workInProgress2);
16394              return null;
16395            case IncompleteClassComponent: {
16396              var _Component = workInProgress2.type;
16397              if (isContextProvider(_Component)) {
16398                popContext(workInProgress2);
16399              }
16400              bubbleProperties(workInProgress2);
16401              return null;
16402            }
16403            case SuspenseListComponent: {
16404              popSuspenseContext(workInProgress2);
16405              var renderState = workInProgress2.memoizedState;
16406              if (renderState === null) {
16407                bubbleProperties(workInProgress2);
16408                return null;
16409              }
16410              var didSuspendAlready = (workInProgress2.flags & DidCapture) !== NoFlags;
16411              var renderedTail = renderState.rendering;
16412              if (renderedTail === null) {
16413                if (!didSuspendAlready) {
16414                  var cannotBeSuspended = renderHasNotSuspendedYet() && (current2 === null || (current2.flags & DidCapture) === NoFlags);
16415                  if (!cannotBeSuspended) {
16416                    var row = workInProgress2.child;
16417                    while (row !== null) {
16418                      var suspended = findFirstSuspended(row);
16419                      if (suspended !== null) {
16420                        didSuspendAlready = true;
16421                        workInProgress2.flags |= DidCapture;
16422                        cutOffTailIfNeeded(renderState, false);
16423                        var newThenables = suspended.updateQueue;
16424                        if (newThenables !== null) {
16425                          workInProgress2.updateQueue = newThenables;
16426                          workInProgress2.flags |= Update;
16427                        }
16428                        workInProgress2.subtreeFlags = NoFlags;
16429                        resetChildFibers(workInProgress2, renderLanes2);
16430                        pushSuspenseContext(workInProgress2, setShallowSuspenseContext(suspenseStackCursor.current, ForceSuspenseFallback));
16431                        return workInProgress2.child;
16432                      }
16433                      row = row.sibling;
16434                    }
16435                  }
16436                  if (renderState.tail !== null && now() > getRenderTargetTime()) {
16437                    workInProgress2.flags |= DidCapture;
16438                    didSuspendAlready = true;
16439                    cutOffTailIfNeeded(renderState, false);
16440                    workInProgress2.lanes = SomeRetryLane;
16441                  }
16442                } else {
16443                  cutOffTailIfNeeded(renderState, false);
16444                }
16445              } else {
16446                if (!didSuspendAlready) {
16447                  var _suspended = findFirstSuspended(renderedTail);
16448                  if (_suspended !== null) {
16449                    workInProgress2.flags |= DidCapture;
16450                    didSuspendAlready = true;
16451                    var _newThenables = _suspended.updateQueue;
16452                    if (_newThenables !== null) {
16453                      workInProgress2.updateQueue = _newThenables;
16454                      workInProgress2.flags |= Update;
16455                    }
16456                    cutOffTailIfNeeded(renderState, true);
16457                    if (renderState.tail === null && renderState.tailMode === "hidden" && !renderedTail.alternate && !getIsHydrating()) {
16458                      bubbleProperties(workInProgress2);
16459                      return null;
16460                    }
16461                  } else if (
16462                    // The time it took to render last row is greater than the remaining
16463                    // time we have to render. So rendering one more row would likely
16464                    // exceed it.
16465                    now() * 2 - renderState.renderingStartTime > getRenderTargetTime() && renderLanes2 !== OffscreenLane
16466                  ) {
16467                    workInProgress2.flags |= DidCapture;
16468                    didSuspendAlready = true;
16469                    cutOffTailIfNeeded(renderState, false);
16470                    workInProgress2.lanes = SomeRetryLane;
16471                  }
16472                }
16473                if (renderState.isBackwards) {
16474                  renderedTail.sibling = workInProgress2.child;
16475                  workInProgress2.child = renderedTail;
16476                } else {
16477                  var previousSibling = renderState.last;
16478                  if (previousSibling !== null) {
16479                    previousSibling.sibling = renderedTail;
16480                  } else {
16481                    workInProgress2.child = renderedTail;
16482                  }
16483                  renderState.last = renderedTail;
16484                }
16485              }
16486              if (renderState.tail !== null) {
16487                var next = renderState.tail;
16488                renderState.rendering = next;
16489                renderState.tail = next.sibling;
16490                renderState.renderingStartTime = now();
16491                next.sibling = null;
16492                var suspenseContext = suspenseStackCursor.current;
16493                if (didSuspendAlready) {
16494                  suspenseContext = setShallowSuspenseContext(suspenseContext, ForceSuspenseFallback);
16495                } else {
16496                  suspenseContext = setDefaultShallowSuspenseContext(suspenseContext);
16497                }
16498                pushSuspenseContext(workInProgress2, suspenseContext);
16499                return next;
16500              }
16501              bubbleProperties(workInProgress2);
16502              return null;
16503            }
16504            case ScopeComponent: {
16505              break;
16506            }
16507            case OffscreenComponent:
16508            case LegacyHiddenComponent: {
16509              popRenderLanes(workInProgress2);
16510              var _nextState = workInProgress2.memoizedState;
16511              var nextIsHidden = _nextState !== null;
16512              if (current2 !== null) {
16513                var _prevState = current2.memoizedState;
16514                var prevIsHidden = _prevState !== null;
16515                if (prevIsHidden !== nextIsHidden && // LegacyHidden doesn't do any hiding — it only pre-renders.
16516                !enableLegacyHidden) {
16517                  workInProgress2.flags |= Visibility;
16518                }
16519              }
16520              if (!nextIsHidden || (workInProgress2.mode & ConcurrentMode) === NoMode) {
16521                bubbleProperties(workInProgress2);
16522              } else {
16523                if (includesSomeLane(subtreeRenderLanes, OffscreenLane)) {
16524                  bubbleProperties(workInProgress2);
16525                  {
16526                    if (workInProgress2.subtreeFlags & (Placement | Update)) {
16527                      workInProgress2.flags |= Visibility;
16528                    }
16529                  }
16530                }
16531              }
16532              return null;
16533            }
16534            case CacheComponent: {
16535              return null;
16536            }
16537            case TracingMarkerComponent: {
16538              return null;
16539            }
16540          }
16541          throw new Error("Unknown unit of work tag (" + workInProgress2.tag + "). This error is likely caused by a bug in React. Please file an issue.");
16542        }
16543        function unwindWork(current2, workInProgress2, renderLanes2) {
16544          popTreeContext(workInProgress2);
16545          switch (workInProgress2.tag) {
16546            case ClassComponent: {
16547              var Component = workInProgress2.type;
16548              if (isContextProvider(Component)) {
16549                popContext(workInProgress2);
16550              }
16551              var flags = workInProgress2.flags;
16552              if (flags & ShouldCapture) {
16553                workInProgress2.flags = flags & ~ShouldCapture | DidCapture;
16554                if ((workInProgress2.mode & ProfileMode) !== NoMode) {
16555                  transferActualDuration(workInProgress2);
16556                }
16557                return workInProgress2;
16558              }
16559              return null;
16560            }
16561            case HostRoot: {
16562              var root2 = workInProgress2.stateNode;
16563              popHostContainer(workInProgress2);
16564              popTopLevelContextObject(workInProgress2);
16565              resetWorkInProgressVersions();
16566              var _flags = workInProgress2.flags;
16567              if ((_flags & ShouldCapture) !== NoFlags && (_flags & DidCapture) === NoFlags) {
16568                workInProgress2.flags = _flags & ~ShouldCapture | DidCapture;
16569                return workInProgress2;
16570              }
16571              return null;
16572            }
16573            case HostComponent: {
16574              popHostContext(workInProgress2);
16575              return null;
16576            }
16577            case SuspenseComponent: {
16578              popSuspenseContext(workInProgress2);
16579              var suspenseState = workInProgress2.memoizedState;
16580              if (suspenseState !== null && suspenseState.dehydrated !== null) {
16581                if (workInProgress2.alternate === null) {
16582                  throw new Error("Threw in newly mounted dehydrated component. This is likely a bug in React. Please file an issue.");
16583                }
16584                resetHydrationState();
16585              }
16586              var _flags2 = workInProgress2.flags;
16587              if (_flags2 & ShouldCapture) {
16588                workInProgress2.flags = _flags2 & ~ShouldCapture | DidCapture;
16589                if ((workInProgress2.mode & ProfileMode) !== NoMode) {
16590                  transferActualDuration(workInProgress2);
16591                }
16592                return workInProgress2;
16593              }
16594              return null;
16595            }
16596            case SuspenseListComponent: {
16597              popSuspenseContext(workInProgress2);
16598              return null;
16599            }
16600            case HostPortal:
16601              popHostContainer(workInProgress2);
16602              return null;
16603            case ContextProvider:
16604              var context = workInProgress2.type._context;
16605              popProvider(context, workInProgress2);
16606              return null;
16607            case OffscreenComponent:
16608            case LegacyHiddenComponent:
16609              popRenderLanes(workInProgress2);
16610              return null;
16611            case CacheComponent:
16612              return null;
16613            default:
16614              return null;
16615          }
16616        }
16617        function unwindInterruptedWork(current2, interruptedWork, renderLanes2) {
16618          popTreeContext(interruptedWork);
16619          switch (interruptedWork.tag) {
16620            case ClassComponent: {
16621              var childContextTypes = interruptedWork.type.childContextTypes;
16622              if (childContextTypes !== null && childContextTypes !== void 0) {
16623                popContext(interruptedWork);
16624              }
16625              break;
16626            }
16627            case HostRoot: {
16628              var root2 = interruptedWork.stateNode;
16629              popHostContainer(interruptedWork);
16630              popTopLevelContextObject(interruptedWork);
16631              resetWorkInProgressVersions();
16632              break;
16633            }
16634            case HostComponent: {
16635              popHostContext(interruptedWork);
16636              break;
16637            }
16638            case HostPortal:
16639              popHostContainer(interruptedWork);
16640              break;
16641            case SuspenseComponent:
16642              popSuspenseContext(interruptedWork);
16643              break;
16644            case SuspenseListComponent:
16645              popSuspenseContext(interruptedWork);
16646              break;
16647            case ContextProvider:
16648              var context = interruptedWork.type._context;
16649              popProvider(context, interruptedWork);
16650              break;
16651            case OffscreenComponent:
16652            case LegacyHiddenComponent:
16653              popRenderLanes(interruptedWork);
16654              break;
16655          }
16656        }
16657        var didWarnAboutUndefinedSnapshotBeforeUpdate = null;
16658        {
16659          didWarnAboutUndefinedSnapshotBeforeUpdate = /* @__PURE__ */ new Set();
16660        }
16661        var offscreenSubtreeIsHidden = false;
16662        var offscreenSubtreeWasHidden = false;
16663        var PossiblyWeakSet = typeof WeakSet === "function" ? WeakSet : Set;
16664        var nextEffect = null;
16665        var inProgressLanes = null;
16666        var inProgressRoot = null;
16667        function reportUncaughtErrorInDEV(error2) {
16668          {
16669            invokeGuardedCallback(null, function() {
16670              throw error2;
16671            });
16672            clearCaughtError();
16673          }
16674        }
16675        var callComponentWillUnmountWithTimer = function(current2, instance) {
16676          instance.props = current2.memoizedProps;
16677          instance.state = current2.memoizedState;
16678          if (current2.mode & ProfileMode) {
16679            try {
16680              startLayoutEffectTimer();
16681              instance.componentWillUnmount();
16682            } finally {
16683              recordLayoutEffectDuration(current2);
16684            }
16685          } else {
16686            instance.componentWillUnmount();
16687          }
16688        };
16689        function safelyCallCommitHookLayoutEffectListMount(current2, nearestMountedAncestor) {
16690          try {
16691            commitHookEffectListMount(Layout, current2);
16692          } catch (error2) {
16693            captureCommitPhaseError(current2, nearestMountedAncestor, error2);
16694          }
16695        }
16696        function safelyCallComponentWillUnmount(current2, nearestMountedAncestor, instance) {
16697          try {
16698            callComponentWillUnmountWithTimer(current2, instance);
16699          } catch (error2) {
16700            captureCommitPhaseError(current2, nearestMountedAncestor, error2);
16701          }
16702        }
16703        function safelyCallComponentDidMount(current2, nearestMountedAncestor, instance) {
16704          try {
16705            instance.componentDidMount();
16706          } catch (error2) {
16707            captureCommitPhaseError(current2, nearestMountedAncestor, error2);
16708          }
16709        }
16710        function safelyAttachRef(current2, nearestMountedAncestor) {
16711          try {
16712            commitAttachRef(current2);
16713          } catch (error2) {
16714            captureCommitPhaseError(current2, nearestMountedAncestor, error2);
16715          }
16716        }
16717        function safelyDetachRef(current2, nearestMountedAncestor) {
16718          var ref = current2.ref;
16719          if (ref !== null) {
16720            if (typeof ref === "function") {
16721              var retVal;
16722              try {
16723                if (enableProfilerTimer && enableProfilerCommitHooks && current2.mode & ProfileMode) {
16724                  try {
16725                    startLayoutEffectTimer();
16726                    retVal = ref(null);
16727                  } finally {
16728                    recordLayoutEffectDuration(current2);
16729                  }
16730                } else {
16731                  retVal = ref(null);
16732                }
16733              } catch (error2) {
16734                captureCommitPhaseError(current2, nearestMountedAncestor, error2);
16735              }
16736              {
16737                if (typeof retVal === "function") {
16738                  error("Unexpected return value from a callback ref in %s. A callback ref should not return a function.", getComponentNameFromFiber(current2));
16739                }
16740              }
16741            } else {
16742              ref.current = null;
16743            }
16744          }
16745        }
16746        function safelyCallDestroy(current2, nearestMountedAncestor, destroy) {
16747          try {
16748            destroy();
16749          } catch (error2) {
16750            captureCommitPhaseError(current2, nearestMountedAncestor, error2);
16751          }
16752        }
16753        var focusedInstanceHandle = null;
16754        var shouldFireAfterActiveInstanceBlur = false;
16755        function commitBeforeMutationEffects(root2, firstChild) {
16756          focusedInstanceHandle = prepareForCommit(root2.containerInfo);
16757          nextEffect = firstChild;
16758          commitBeforeMutationEffects_begin();
16759          var shouldFire = shouldFireAfterActiveInstanceBlur;
16760          shouldFireAfterActiveInstanceBlur = false;
16761          focusedInstanceHandle = null;
16762          return shouldFire;
16763        }
16764        function commitBeforeMutationEffects_begin() {
16765          while (nextEffect !== null) {
16766            var fiber = nextEffect;
16767            var child = fiber.child;
16768            if ((fiber.subtreeFlags & BeforeMutationMask) !== NoFlags && child !== null) {
16769              child.return = fiber;
16770              nextEffect = child;
16771            } else {
16772              commitBeforeMutationEffects_complete();
16773            }
16774          }
16775        }
16776        function commitBeforeMutationEffects_complete() {
16777          while (nextEffect !== null) {
16778            var fiber = nextEffect;
16779            setCurrentFiber(fiber);
16780            try {
16781              commitBeforeMutationEffectsOnFiber(fiber);
16782            } catch (error2) {
16783              captureCommitPhaseError(fiber, fiber.return, error2);
16784            }
16785            resetCurrentFiber();
16786            var sibling = fiber.sibling;
16787            if (sibling !== null) {
16788              sibling.return = fiber.return;
16789              nextEffect = sibling;
16790              return;
16791            }
16792            nextEffect = fiber.return;
16793          }
16794        }
16795        function commitBeforeMutationEffectsOnFiber(finishedWork) {
16796          var current2 = finishedWork.alternate;
16797          var flags = finishedWork.flags;
16798          if ((flags & Snapshot) !== NoFlags) {
16799            setCurrentFiber(finishedWork);
16800            switch (finishedWork.tag) {
16801              case FunctionComponent:
16802              case ForwardRef:
16803              case SimpleMemoComponent: {
16804                break;
16805              }
16806              case ClassComponent: {
16807                if (current2 !== null) {
16808                  var prevProps = current2.memoizedProps;
16809                  var prevState = current2.memoizedState;
16810                  var instance = finishedWork.stateNode;
16811                  {
16812                    if (finishedWork.type === finishedWork.elementType && !didWarnAboutReassigningProps) {
16813                      if (instance.props !== finishedWork.memoizedProps) {
16814                        error("Expected %s props to match memoized props before getSnapshotBeforeUpdate. This might either be because of a bug in React, or because a component reassigns its own `this.props`. Please file an issue.", getComponentNameFromFiber(finishedWork) || "instance");
16815                      }
16816                      if (instance.state !== finishedWork.memoizedState) {
16817                        error("Expected %s state to match memoized state before getSnapshotBeforeUpdate. This might either be because of a bug in React, or because a component reassigns its own `this.state`. Please file an issue.", getComponentNameFromFiber(finishedWork) || "instance");
16818                      }
16819                    }
16820                  }
16821                  var snapshot = instance.getSnapshotBeforeUpdate(finishedWork.elementType === finishedWork.type ? prevProps : resolveDefaultProps(finishedWork.type, prevProps), prevState);
16822                  {
16823                    var didWarnSet = didWarnAboutUndefinedSnapshotBeforeUpdate;
16824                    if (snapshot === void 0 && !didWarnSet.has(finishedWork.type)) {
16825                      didWarnSet.add(finishedWork.type);
16826                      error("%s.getSnapshotBeforeUpdate(): A snapshot value (or null) must be returned. You have returned undefined.", getComponentNameFromFiber(finishedWork));
16827                    }
16828                  }
16829                  instance.__reactInternalSnapshotBeforeUpdate = snapshot;
16830                }
16831                break;
16832              }
16833              case HostRoot: {
16834                {
16835                  var root2 = finishedWork.stateNode;
16836                  clearContainer(root2.containerInfo);
16837                }
16838                break;
16839              }
16840              case HostComponent:
16841              case HostText:
16842              case HostPortal:
16843              case IncompleteClassComponent:
16844                break;
16845              default: {
16846                throw new Error("This unit of work tag should not have side-effects. This error is likely caused by a bug in React. Please file an issue.");
16847              }
16848            }
16849            resetCurrentFiber();
16850          }
16851        }
16852        function commitHookEffectListUnmount(flags, finishedWork, nearestMountedAncestor) {
16853          var updateQueue = finishedWork.updateQueue;
16854          var lastEffect = updateQueue !== null ? updateQueue.lastEffect : null;
16855          if (lastEffect !== null) {
16856            var firstEffect = lastEffect.next;
16857            var effect = firstEffect;
16858            do {
16859              if ((effect.tag & flags) === flags) {
16860                var destroy = effect.destroy;
16861                effect.destroy = void 0;
16862                if (destroy !== void 0) {
16863                  {
16864                    if ((flags & Passive$1) !== NoFlags$1) {
16865                      markComponentPassiveEffectUnmountStarted(finishedWork);
16866                    } else if ((flags & Layout) !== NoFlags$1) {
16867                      markComponentLayoutEffectUnmountStarted(finishedWork);
16868                    }
16869                  }
16870                  {
16871                    if ((flags & Insertion) !== NoFlags$1) {
16872                      setIsRunningInsertionEffect(true);
16873                    }
16874                  }
16875                  safelyCallDestroy(finishedWork, nearestMountedAncestor, destroy);
16876                  {
16877                    if ((flags & Insertion) !== NoFlags$1) {
16878                      setIsRunningInsertionEffect(false);
16879                    }
16880                  }
16881                  {
16882                    if ((flags & Passive$1) !== NoFlags$1) {
16883                      markComponentPassiveEffectUnmountStopped();
16884                    } else if ((flags & Layout) !== NoFlags$1) {
16885                      markComponentLayoutEffectUnmountStopped();
16886                    }
16887                  }
16888                }
16889              }
16890              effect = effect.next;
16891            } while (effect !== firstEffect);
16892          }
16893        }
16894        function commitHookEffectListMount(flags, finishedWork) {
16895          var updateQueue = finishedWork.updateQueue;
16896          var lastEffect = updateQueue !== null ? updateQueue.lastEffect : null;
16897          if (lastEffect !== null) {
16898            var firstEffect = lastEffect.next;
16899            var effect = firstEffect;
16900            do {
16901              if ((effect.tag & flags) === flags) {
16902                {
16903                  if ((flags & Passive$1) !== NoFlags$1) {
16904                    markComponentPassiveEffectMountStarted(finishedWork);
16905                  } else if ((flags & Layout) !== NoFlags$1) {
16906                    markComponentLayoutEffectMountStarted(finishedWork);
16907                  }
16908                }
16909                var create = effect.create;
16910                {
16911                  if ((flags & Insertion) !== NoFlags$1) {
16912                    setIsRunningInsertionEffect(true);
16913                  }
16914                }
16915                effect.destroy = create();
16916                {
16917                  if ((flags & Insertion) !== NoFlags$1) {
16918                    setIsRunningInsertionEffect(false);
16919                  }
16920                }
16921                {
16922                  if ((flags & Passive$1) !== NoFlags$1) {
16923                    markComponentPassiveEffectMountStopped();
16924                  } else if ((flags & Layout) !== NoFlags$1) {
16925                    markComponentLayoutEffectMountStopped();
16926                  }
16927                }
16928                {
16929                  var destroy = effect.destroy;
16930                  if (destroy !== void 0 && typeof destroy !== "function") {
16931                    var hookName = void 0;
16932                    if ((effect.tag & Layout) !== NoFlags) {
16933                      hookName = "useLayoutEffect";
16934                    } else if ((effect.tag & Insertion) !== NoFlags) {
16935                      hookName = "useInsertionEffect";
16936                    } else {
16937                      hookName = "useEffect";
16938                    }
16939                    var addendum = void 0;
16940                    if (destroy === null) {
16941                      addendum = " You returned null. If your effect does not require clean up, return undefined (or nothing).";
16942                    } else if (typeof destroy.then === "function") {
16943                      addendum = "\n\nIt looks like you wrote " + hookName + "(async () => ...) or returned a Promise. Instead, write the async function inside your effect and call it immediately:\n\n" + hookName + "(() => {\n  async function fetchData() {\n    // You can await here\n    const response = await MyAPI.getData(someId);\n    // ...\n  }\n  fetchData();\n}, [someId]); // Or [] if effect doesn't need props or state\n\nLearn more about data fetching with Hooks: https://reactjs.org/link/hooks-data-fetching";
16944                    } else {
16945                      addendum = " You returned: " + destroy;
16946                    }
16947                    error("%s must not return anything besides a function, which is used for clean-up.%s", hookName, addendum);
16948                  }
16949                }
16950              }
16951              effect = effect.next;
16952            } while (effect !== firstEffect);
16953          }
16954        }
16955        function commitPassiveEffectDurations(finishedRoot, finishedWork) {
16956          {
16957            if ((finishedWork.flags & Update) !== NoFlags) {
16958              switch (finishedWork.tag) {
16959                case Profiler: {
16960                  var passiveEffectDuration = finishedWork.stateNode.passiveEffectDuration;
16961                  var _finishedWork$memoize = finishedWork.memoizedProps, id = _finishedWork$memoize.id, onPostCommit = _finishedWork$memoize.onPostCommit;
16962                  var commitTime2 = getCommitTime();
16963                  var phase = finishedWork.alternate === null ? "mount" : "update";
16964                  {
16965                    if (isCurrentUpdateNested()) {
16966                      phase = "nested-update";
16967                    }
16968                  }
16969                  if (typeof onPostCommit === "function") {
16970                    onPostCommit(id, phase, passiveEffectDuration, commitTime2);
16971                  }
16972                  var parentFiber = finishedWork.return;
16973                  outer: while (parentFiber !== null) {
16974                    switch (parentFiber.tag) {
16975                      case HostRoot:
16976                        var root2 = parentFiber.stateNode;
16977                        root2.passiveEffectDuration += passiveEffectDuration;
16978                        break outer;
16979                      case Profiler:
16980                        var parentStateNode = parentFiber.stateNode;
16981                        parentStateNode.passiveEffectDuration += passiveEffectDuration;
16982                        break outer;
16983                    }
16984                    parentFiber = parentFiber.return;
16985                  }
16986                  break;
16987                }
16988              }
16989            }
16990          }
16991        }
16992        function commitLayoutEffectOnFiber(finishedRoot, current2, finishedWork, committedLanes) {
16993          if ((finishedWork.flags & LayoutMask) !== NoFlags) {
16994            switch (finishedWork.tag) {
16995              case FunctionComponent:
16996              case ForwardRef:
16997              case SimpleMemoComponent: {
16998                if (!offscreenSubtreeWasHidden) {
16999                  if (finishedWork.mode & ProfileMode) {
17000                    try {
17001                      startLayoutEffectTimer();
17002                      commitHookEffectListMount(Layout | HasEffect, finishedWork);
17003                    } finally {
17004                      recordLayoutEffectDuration(finishedWork);
17005                    }
17006                  } else {
17007                    commitHookEffectListMount(Layout | HasEffect, finishedWork);
17008                  }
17009                }
17010                break;
17011              }
17012              case ClassComponent: {
17013                var instance = finishedWork.stateNode;
17014                if (finishedWork.flags & Update) {
17015                  if (!offscreenSubtreeWasHidden) {
17016                    if (current2 === null) {
17017                      {
17018                        if (finishedWork.type === finishedWork.elementType && !didWarnAboutReassigningProps) {
17019                          if (instance.props !== finishedWork.memoizedProps) {
17020                            error("Expected %s props to match memoized props before componentDidMount. This might either be because of a bug in React, or because a component reassigns its own `this.props`. Please file an issue.", getComponentNameFromFiber(finishedWork) || "instance");
17021                          }
17022                          if (instance.state !== finishedWork.memoizedState) {
17023                            error("Expected %s state to match memoized state before componentDidMount. This might either be because of a bug in React, or because a component reassigns its own `this.state`. Please file an issue.", getComponentNameFromFiber(finishedWork) || "instance");
17024                          }
17025                        }
17026                      }
17027                      if (finishedWork.mode & ProfileMode) {
17028                        try {
17029                          startLayoutEffectTimer();
17030                          instance.componentDidMount();
17031                        } finally {
17032                          recordLayoutEffectDuration(finishedWork);
17033                        }
17034                      } else {
17035                        instance.componentDidMount();
17036                      }
17037                    } else {
17038                      var prevProps = finishedWork.elementType === finishedWork.type ? current2.memoizedProps : resolveDefaultProps(finishedWork.type, current2.memoizedProps);
17039                      var prevState = current2.memoizedState;
17040                      {
17041                        if (finishedWork.type === finishedWork.elementType && !didWarnAboutReassigningProps) {
17042                          if (instance.props !== finishedWork.memoizedProps) {
17043                            error("Expected %s props to match memoized props before componentDidUpdate. This might either be because of a bug in React, or because a component reassigns its own `this.props`. Please file an issue.", getComponentNameFromFiber(finishedWork) || "instance");
17044                          }
17045                          if (instance.state !== finishedWork.memoizedState) {
17046                            error("Expected %s state to match memoized state before componentDidUpdate. This might either be because of a bug in React, or because a component reassigns its own `this.state`. Please file an issue.", getComponentNameFromFiber(finishedWork) || "instance");
17047                          }
17048                        }
17049                      }
17050                      if (finishedWork.mode & ProfileMode) {
17051                        try {
17052                          startLayoutEffectTimer();
17053                          instance.componentDidUpdate(prevProps, prevState, instance.__reactInternalSnapshotBeforeUpdate);
17054                        } finally {
17055                          recordLayoutEffectDuration(finishedWork);
17056                        }
17057                      } else {
17058                        instance.componentDidUpdate(prevProps, prevState, instance.__reactInternalSnapshotBeforeUpdate);
17059                      }
17060                    }
17061                  }
17062                }
17063                var updateQueue = finishedWork.updateQueue;
17064                if (updateQueue !== null) {
17065                  {
17066                    if (finishedWork.type === finishedWork.elementType && !didWarnAboutReassigningProps) {
17067                      if (instance.props !== finishedWork.memoizedProps) {
17068                        error("Expected %s props to match memoized props before processing the update queue. This might either be because of a bug in React, or because a component reassigns its own `this.props`. Please file an issue.", getComponentNameFromFiber(finishedWork) || "instance");
17069                      }
17070                      if (instance.state !== finishedWork.memoizedState) {
17071                        error("Expected %s state to match memoized state before processing the update queue. This might either be because of a bug in React, or because a component reassigns its own `this.state`. Please file an issue.", getComponentNameFromFiber(finishedWork) || "instance");
17072                      }
17073                    }
17074                  }
17075                  commitUpdateQueue(finishedWork, updateQueue, instance);
17076                }
17077                break;
17078              }
17079              case HostRoot: {
17080                var _updateQueue = finishedWork.updateQueue;
17081                if (_updateQueue !== null) {
17082                  var _instance = null;
17083                  if (finishedWork.child !== null) {
17084                    switch (finishedWork.child.tag) {
17085                      case HostComponent:
17086                        _instance = getPublicInstance(finishedWork.child.stateNode);
17087                        break;
17088                      case ClassComponent:
17089                        _instance = finishedWork.child.stateNode;
17090                        break;
17091                    }
17092                  }
17093                  commitUpdateQueue(finishedWork, _updateQueue, _instance);
17094                }
17095                break;
17096              }
17097              case HostComponent: {
17098                var _instance2 = finishedWork.stateNode;
17099                if (current2 === null && finishedWork.flags & Update) {
17100                  var type = finishedWork.type;
17101                  var props = finishedWork.memoizedProps;
17102                  commitMount(_instance2, type, props);
17103                }
17104                break;
17105              }
17106              case HostText: {
17107                break;
17108              }
17109              case HostPortal: {
17110                break;
17111              }
17112              case Profiler: {
17113                {
17114                  var _finishedWork$memoize2 = finishedWork.memoizedProps, onCommit = _finishedWork$memoize2.onCommit, onRender = _finishedWork$memoize2.onRender;
17115                  var effectDuration = finishedWork.stateNode.effectDuration;
17116                  var commitTime2 = getCommitTime();
17117                  var phase = current2 === null ? "mount" : "update";
17118                  {
17119                    if (isCurrentUpdateNested()) {
17120                      phase = "nested-update";
17121                    }
17122                  }
17123                  if (typeof onRender === "function") {
17124                    onRender(finishedWork.memoizedProps.id, phase, finishedWork.actualDuration, finishedWork.treeBaseDuration, finishedWork.actualStartTime, commitTime2);
17125                  }
17126                  {
17127                    if (typeof onCommit === "function") {
17128                      onCommit(finishedWork.memoizedProps.id, phase, effectDuration, commitTime2);
17129                    }
17130                    enqueuePendingPassiveProfilerEffect(finishedWork);
17131                    var parentFiber = finishedWork.return;
17132                    outer: while (parentFiber !== null) {
17133                      switch (parentFiber.tag) {
17134                        case HostRoot:
17135                          var root2 = parentFiber.stateNode;
17136                          root2.effectDuration += effectDuration;
17137                          break outer;
17138                        case Profiler:
17139                          var parentStateNode = parentFiber.stateNode;
17140                          parentStateNode.effectDuration += effectDuration;
17141                          break outer;
17142                      }
17143                      parentFiber = parentFiber.return;
17144                    }
17145                  }
17146                }
17147                break;
17148              }
17149              case SuspenseComponent: {
17150                commitSuspenseHydrationCallbacks(finishedRoot, finishedWork);
17151                break;
17152              }
17153              case SuspenseListComponent:
17154              case IncompleteClassComponent:
17155              case ScopeComponent:
17156              case OffscreenComponent:
17157              case LegacyHiddenComponent:
17158              case TracingMarkerComponent: {
17159                break;
17160              }
17161              default:
17162                throw new Error("This unit of work tag should not have side-effects. This error is likely caused by a bug in React. Please file an issue.");
17163            }
17164          }
17165          if (!offscreenSubtreeWasHidden) {
17166            {
17167              if (finishedWork.flags & Ref) {
17168                commitAttachRef(finishedWork);
17169              }
17170            }
17171          }
17172        }
17173        function reappearLayoutEffectsOnFiber(node) {
17174          switch (node.tag) {
17175            case FunctionComponent:
17176            case ForwardRef:
17177            case SimpleMemoComponent: {
17178              if (node.mode & ProfileMode) {
17179                try {
17180                  startLayoutEffectTimer();
17181                  safelyCallCommitHookLayoutEffectListMount(node, node.return);
17182                } finally {
17183                  recordLayoutEffectDuration(node);
17184                }
17185              } else {
17186                safelyCallCommitHookLayoutEffectListMount(node, node.return);
17187              }
17188              break;
17189            }
17190            case ClassComponent: {
17191              var instance = node.stateNode;
17192              if (typeof instance.componentDidMount === "function") {
17193                safelyCallComponentDidMount(node, node.return, instance);
17194              }
17195              safelyAttachRef(node, node.return);
17196              break;
17197            }
17198            case HostComponent: {
17199              safelyAttachRef(node, node.return);
17200              break;
17201            }
17202          }
17203        }
17204        function hideOrUnhideAllChildren(finishedWork, isHidden) {
17205          var hostSubtreeRoot = null;
17206          {
17207            var node = finishedWork;
17208            while (true) {
17209              if (node.tag === HostComponent) {
17210                if (hostSubtreeRoot === null) {
17211                  hostSubtreeRoot = node;
17212                  try {
17213                    var instance = node.stateNode;
17214                    if (isHidden) {
17215                      hideInstance(instance);
17216                    } else {
17217                      unhideInstance(node.stateNode, node.memoizedProps);
17218                    }
17219                  } catch (error2) {
17220                    captureCommitPhaseError(finishedWork, finishedWork.return, error2);
17221                  }
17222                }
17223              } else if (node.tag === HostText) {
17224                if (hostSubtreeRoot === null) {
17225                  try {
17226                    var _instance3 = node.stateNode;
17227                    if (isHidden) {
17228                      hideTextInstance(_instance3);
17229                    } else {
17230                      unhideTextInstance(_instance3, node.memoizedProps);
17231                    }
17232                  } catch (error2) {
17233                    captureCommitPhaseError(finishedWork, finishedWork.return, error2);
17234                  }
17235                }
17236              } else if ((node.tag === OffscreenComponent || node.tag === LegacyHiddenComponent) && node.memoizedState !== null && node !== finishedWork) ;
17237              else if (node.child !== null) {
17238                node.child.return = node;
17239                node = node.child;
17240                continue;
17241              }
17242              if (node === finishedWork) {
17243                return;
17244              }
17245              while (node.sibling === null) {
17246                if (node.return === null || node.return === finishedWork) {
17247                  return;
17248                }
17249                if (hostSubtreeRoot === node) {
17250                  hostSubtreeRoot = null;
17251                }
17252                node = node.return;
17253              }
17254              if (hostSubtreeRoot === node) {
17255                hostSubtreeRoot = null;
17256              }
17257              node.sibling.return = node.return;
17258              node = node.sibling;
17259            }
17260          }
17261        }
17262        function commitAttachRef(finishedWork) {
17263          var ref = finishedWork.ref;
17264          if (ref !== null) {
17265            var instance = finishedWork.stateNode;
17266            var instanceToUse;
17267            switch (finishedWork.tag) {
17268              case HostComponent:
17269                instanceToUse = getPublicInstance(instance);
17270                break;
17271              default:
17272                instanceToUse = instance;
17273            }
17274            if (typeof ref === "function") {
17275              var retVal;
17276              if (finishedWork.mode & ProfileMode) {
17277                try {
17278                  startLayoutEffectTimer();
17279                  retVal = ref(instanceToUse);
17280                } finally {
17281                  recordLayoutEffectDuration(finishedWork);
17282                }
17283              } else {
17284                retVal = ref(instanceToUse);
17285              }
17286              {
17287                if (typeof retVal === "function") {
17288                  error("Unexpected return value from a callback ref in %s. A callback ref should not return a function.", getComponentNameFromFiber(finishedWork));
17289                }
17290              }
17291            } else {
17292              {
17293                if (!ref.hasOwnProperty("current")) {
17294                  error("Unexpected ref object provided for %s. Use either a ref-setter function or React.createRef().", getComponentNameFromFiber(finishedWork));
17295                }
17296              }
17297              ref.current = instanceToUse;
17298            }
17299          }
17300        }
17301        function detachFiberMutation(fiber) {
17302          var alternate = fiber.alternate;
17303          if (alternate !== null) {
17304            alternate.return = null;
17305          }
17306          fiber.return = null;
17307        }
17308        function detachFiberAfterEffects(fiber) {
17309          var alternate = fiber.alternate;
17310          if (alternate !== null) {
17311            fiber.alternate = null;
17312            detachFiberAfterEffects(alternate);
17313          }
17314          {
17315            fiber.child = null;
17316            fiber.deletions = null;
17317            fiber.sibling = null;
17318            if (fiber.tag === HostComponent) {
17319              var hostInstance = fiber.stateNode;
17320              if (hostInstance !== null) {
17321                detachDeletedInstance(hostInstance);
17322              }
17323            }
17324            fiber.stateNode = null;
17325            {
17326              fiber._debugOwner = null;
17327            }
17328            {
17329              fiber.return = null;
17330              fiber.dependencies = null;
17331              fiber.memoizedProps = null;
17332              fiber.memoizedState = null;
17333              fiber.pendingProps = null;
17334              fiber.stateNode = null;
17335              fiber.updateQueue = null;
17336            }
17337          }
17338        }
17339        function getHostParentFiber(fiber) {
17340          var parent = fiber.return;
17341          while (parent !== null) {
17342            if (isHostParent(parent)) {
17343              return parent;
17344            }
17345            parent = parent.return;
17346          }
17347          throw new Error("Expected to find a host parent. This error is likely caused by a bug in React. Please file an issue.");
17348        }
17349        function isHostParent(fiber) {
17350          return fiber.tag === HostComponent || fiber.tag === HostRoot || fiber.tag === HostPortal;
17351        }
17352        function getHostSibling(fiber) {
17353          var node = fiber;
17354          siblings: while (true) {
17355            while (node.sibling === null) {
17356              if (node.return === null || isHostParent(node.return)) {
17357                return null;
17358              }
17359              node = node.return;
17360            }
17361            node.sibling.return = node.return;
17362            node = node.sibling;
17363            while (node.tag !== HostComponent && node.tag !== HostText && node.tag !== DehydratedFragment) {
17364              if (node.flags & Placement) {
17365                continue siblings;
17366              }
17367              if (node.child === null || node.tag === HostPortal) {
17368                continue siblings;
17369              } else {
17370                node.child.return = node;
17371                node = node.child;
17372              }
17373            }
17374            if (!(node.flags & Placement)) {
17375              return node.stateNode;
17376            }
17377          }
17378        }
17379        function commitPlacement(finishedWork) {
17380          var parentFiber = getHostParentFiber(finishedWork);
17381          switch (parentFiber.tag) {
17382            case HostComponent: {
17383              var parent = parentFiber.stateNode;
17384              if (parentFiber.flags & ContentReset) {
17385                resetTextContent(parent);
17386                parentFiber.flags &= ~ContentReset;
17387              }
17388              var before = getHostSibling(finishedWork);
17389              insertOrAppendPlacementNode(finishedWork, before, parent);
17390              break;
17391            }
17392            case HostRoot:
17393            case HostPortal: {
17394              var _parent = parentFiber.stateNode.containerInfo;
17395              var _before = getHostSibling(finishedWork);
17396              insertOrAppendPlacementNodeIntoContainer(finishedWork, _before, _parent);
17397              break;
17398            }
17399            default:
17400              throw new Error("Invalid host parent fiber. This error is likely caused by a bug in React. Please file an issue.");
17401          }
17402        }
17403        function insertOrAppendPlacementNodeIntoContainer(node, before, parent) {
17404          var tag = node.tag;
17405          var isHost = tag === HostComponent || tag === HostText;
17406          if (isHost) {
17407            var stateNode = node.stateNode;
17408            if (before) {
17409              insertInContainerBefore(parent, stateNode, before);
17410            } else {
17411              appendChildToContainer(parent, stateNode);
17412            }
17413          } else if (tag === HostPortal) ;
17414          else {
17415            var child = node.child;
17416            if (child !== null) {
17417              insertOrAppendPlacementNodeIntoContainer(child, before, parent);
17418              var sibling = child.sibling;
17419              while (sibling !== null) {
17420                insertOrAppendPlacementNodeIntoContainer(sibling, before, parent);
17421                sibling = sibling.sibling;
17422              }
17423            }
17424          }
17425        }
17426        function insertOrAppendPlacementNode(node, before, parent) {
17427          var tag = node.tag;
17428          var isHost = tag === HostComponent || tag === HostText;
17429          if (isHost) {
17430            var stateNode = node.stateNode;
17431            if (before) {
17432              insertBefore(parent, stateNode, before);
17433            } else {
17434              appendChild(parent, stateNode);
17435            }
17436          } else if (tag === HostPortal) ;
17437          else {
17438            var child = node.child;
17439            if (child !== null) {
17440              insertOrAppendPlacementNode(child, before, parent);
17441              var sibling = child.sibling;
17442              while (sibling !== null) {
17443                insertOrAppendPlacementNode(sibling, before, parent);
17444                sibling = sibling.sibling;
17445              }
17446            }
17447          }
17448        }
17449        var hostParent = null;
17450        var hostParentIsContainer = false;
17451        function commitDeletionEffects(root2, returnFiber, deletedFiber) {
17452          {
17453            var parent = returnFiber;
17454            findParent: while (parent !== null) {
17455              switch (parent.tag) {
17456                case HostComponent: {
17457                  hostParent = parent.stateNode;
17458                  hostParentIsContainer = false;
17459                  break findParent;
17460                }
17461                case HostRoot: {
17462                  hostParent = parent.stateNode.containerInfo;
17463                  hostParentIsContainer = true;
17464                  break findParent;
17465                }
17466                case HostPortal: {
17467                  hostParent = parent.stateNode.containerInfo;
17468                  hostParentIsContainer = true;
17469                  break findParent;
17470                }
17471              }
17472              parent = parent.return;
17473            }
17474            if (hostParent === null) {
17475              throw new Error("Expected to find a host parent. This error is likely caused by a bug in React. Please file an issue.");
17476            }
17477            commitDeletionEffectsOnFiber(root2, returnFiber, deletedFiber);
17478            hostParent = null;
17479            hostParentIsContainer = false;
17480          }
17481          detachFiberMutation(deletedFiber);
17482        }
17483        function recursivelyTraverseDeletionEffects(finishedRoot, nearestMountedAncestor, parent) {
17484          var child = parent.child;
17485          while (child !== null) {
17486            commitDeletionEffectsOnFiber(finishedRoot, nearestMountedAncestor, child);
17487            child = child.sibling;
17488          }
17489        }
17490        function commitDeletionEffectsOnFiber(finishedRoot, nearestMountedAncestor, deletedFiber) {
17491          onCommitUnmount(deletedFiber);
17492          switch (deletedFiber.tag) {
17493            case HostComponent: {
17494              if (!offscreenSubtreeWasHidden) {
17495                safelyDetachRef(deletedFiber, nearestMountedAncestor);
17496              }
17497            }
17498            case HostText: {
17499              {
17500                var prevHostParent = hostParent;
17501                var prevHostParentIsContainer = hostParentIsContainer;
17502                hostParent = null;
17503                recursivelyTraverseDeletionEffects(finishedRoot, nearestMountedAncestor, deletedFiber);
17504                hostParent = prevHostParent;
17505                hostParentIsContainer = prevHostParentIsContainer;
17506                if (hostParent !== null) {
17507                  if (hostParentIsContainer) {
17508                    removeChildFromContainer(hostParent, deletedFiber.stateNode);
17509                  } else {
17510                    removeChild(hostParent, deletedFiber.stateNode);
17511                  }
17512                }
17513              }
17514              return;
17515            }
17516            case DehydratedFragment: {
17517              {
17518                if (hostParent !== null) {
17519                  if (hostParentIsContainer) {
17520                    clearSuspenseBoundaryFromContainer(hostParent, deletedFiber.stateNode);
17521                  } else {
17522                    clearSuspenseBoundary(hostParent, deletedFiber.stateNode);
17523                  }
17524                }
17525              }
17526              return;
17527            }
17528            case HostPortal: {
17529              {
17530                var _prevHostParent = hostParent;
17531                var _prevHostParentIsContainer = hostParentIsContainer;
17532                hostParent = deletedFiber.stateNode.containerInfo;
17533                hostParentIsContainer = true;
17534                recursivelyTraverseDeletionEffects(finishedRoot, nearestMountedAncestor, deletedFiber);
17535                hostParent = _prevHostParent;
17536                hostParentIsContainer = _prevHostParentIsContainer;
17537              }
17538              return;
17539            }
17540            case FunctionComponent:
17541            case ForwardRef:
17542            case MemoComponent:
17543            case SimpleMemoComponent: {
17544              if (!offscreenSubtreeWasHidden) {
17545                var updateQueue = deletedFiber.updateQueue;
17546                if (updateQueue !== null) {
17547                  var lastEffect = updateQueue.lastEffect;
17548                  if (lastEffect !== null) {
17549                    var firstEffect = lastEffect.next;
17550                    var effect = firstEffect;
17551                    do {
17552                      var _effect = effect, destroy = _effect.destroy, tag = _effect.tag;
17553                      if (destroy !== void 0) {
17554                        if ((tag & Insertion) !== NoFlags$1) {
17555                          safelyCallDestroy(deletedFiber, nearestMountedAncestor, destroy);
17556                        } else if ((tag & Layout) !== NoFlags$1) {
17557                          {
17558                            markComponentLayoutEffectUnmountStarted(deletedFiber);
17559                          }
17560                          if (deletedFiber.mode & ProfileMode) {
17561                            startLayoutEffectTimer();
17562                            safelyCallDestroy(deletedFiber, nearestMountedAncestor, destroy);
17563                            recordLayoutEffectDuration(deletedFiber);
17564                          } else {
17565                            safelyCallDestroy(deletedFiber, nearestMountedAncestor, destroy);
17566                          }
17567                          {
17568                            markComponentLayoutEffectUnmountStopped();
17569                          }
17570                        }
17571                      }
17572                      effect = effect.next;
17573                    } while (effect !== firstEffect);
17574                  }
17575                }
17576              }
17577              recursivelyTraverseDeletionEffects(finishedRoot, nearestMountedAncestor, deletedFiber);
17578              return;
17579            }
17580            case ClassComponent: {
17581              if (!offscreenSubtreeWasHidden) {
17582                safelyDetachRef(deletedFiber, nearestMountedAncestor);
17583                var instance = deletedFiber.stateNode;
17584                if (typeof instance.componentWillUnmount === "function") {
17585                  safelyCallComponentWillUnmount(deletedFiber, nearestMountedAncestor, instance);
17586                }
17587              }
17588              recursivelyTraverseDeletionEffects(finishedRoot, nearestMountedAncestor, deletedFiber);
17589              return;
17590            }
17591            case ScopeComponent: {
17592              recursivelyTraverseDeletionEffects(finishedRoot, nearestMountedAncestor, deletedFiber);
17593              return;
17594            }
17595            case OffscreenComponent: {
17596              if (
17597                // TODO: Remove this dead flag
17598                deletedFiber.mode & ConcurrentMode
17599              ) {
17600                var prevOffscreenSubtreeWasHidden = offscreenSubtreeWasHidden;
17601                offscreenSubtreeWasHidden = prevOffscreenSubtreeWasHidden || deletedFiber.memoizedState !== null;
17602                recursivelyTraverseDeletionEffects(finishedRoot, nearestMountedAncestor, deletedFiber);
17603                offscreenSubtreeWasHidden = prevOffscreenSubtreeWasHidden;
17604              } else {
17605                recursivelyTraverseDeletionEffects(finishedRoot, nearestMountedAncestor, deletedFiber);
17606              }
17607              break;
17608            }
17609            default: {
17610              recursivelyTraverseDeletionEffects(finishedRoot, nearestMountedAncestor, deletedFiber);
17611              return;
17612            }
17613          }
17614        }
17615        function commitSuspenseCallback(finishedWork) {
17616          var newState = finishedWork.memoizedState;
17617        }
17618        function commitSuspenseHydrationCallbacks(finishedRoot, finishedWork) {
17619          var newState = finishedWork.memoizedState;
17620          if (newState === null) {
17621            var current2 = finishedWork.alternate;
17622            if (current2 !== null) {
17623              var prevState = current2.memoizedState;
17624              if (prevState !== null) {
17625                var suspenseInstance = prevState.dehydrated;
17626                if (suspenseInstance !== null) {
17627                  commitHydratedSuspenseInstance(suspenseInstance);
17628                }
17629              }
17630            }
17631          }
17632        }
17633        function attachSuspenseRetryListeners(finishedWork) {
17634          var wakeables = finishedWork.updateQueue;
17635          if (wakeables !== null) {
17636            finishedWork.updateQueue = null;
17637            var retryCache = finishedWork.stateNode;
17638            if (retryCache === null) {
17639              retryCache = finishedWork.stateNode = new PossiblyWeakSet();
17640            }
17641            wakeables.forEach(function(wakeable) {
17642              var retry = resolveRetryWakeable.bind(null, finishedWork, wakeable);
17643              if (!retryCache.has(wakeable)) {
17644                retryCache.add(wakeable);
17645                {
17646                  if (isDevToolsPresent) {
17647                    if (inProgressLanes !== null && inProgressRoot !== null) {
17648                      restorePendingUpdaters(inProgressRoot, inProgressLanes);
17649                    } else {
17650                      throw Error("Expected finished root and lanes to be set. This is a bug in React.");
17651                    }
17652                  }
17653                }
17654                wakeable.then(retry, retry);
17655              }
17656            });
17657          }
17658        }
17659        function commitMutationEffects(root2, finishedWork, committedLanes) {
17660          inProgressLanes = committedLanes;
17661          inProgressRoot = root2;
17662          setCurrentFiber(finishedWork);
17663          commitMutationEffectsOnFiber(finishedWork, root2);
17664          setCurrentFiber(finishedWork);
17665          inProgressLanes = null;
17666          inProgressRoot = null;
17667        }
17668        function recursivelyTraverseMutationEffects(root2, parentFiber, lanes) {
17669          var deletions = parentFiber.deletions;
17670          if (deletions !== null) {
17671            for (var i = 0; i < deletions.length; i++) {
17672              var childToDelete = deletions[i];
17673              try {
17674                commitDeletionEffects(root2, parentFiber, childToDelete);
17675              } catch (error2) {
17676                captureCommitPhaseError(childToDelete, parentFiber, error2);
17677              }
17678            }
17679          }
17680          var prevDebugFiber = getCurrentFiber();
17681          if (parentFiber.subtreeFlags & MutationMask) {
17682            var child = parentFiber.child;
17683            while (child !== null) {
17684              setCurrentFiber(child);
17685              commitMutationEffectsOnFiber(child, root2);
17686              child = child.sibling;
17687            }
17688          }
17689          setCurrentFiber(prevDebugFiber);
17690        }
17691        function commitMutationEffectsOnFiber(finishedWork, root2, lanes) {
17692          var current2 = finishedWork.alternate;
17693          var flags = finishedWork.flags;
17694          switch (finishedWork.tag) {
17695            case FunctionComponent:
17696            case ForwardRef:
17697            case MemoComponent:
17698            case SimpleMemoComponent: {
17699              recursivelyTraverseMutationEffects(root2, finishedWork);
17700              commitReconciliationEffects(finishedWork);
17701              if (flags & Update) {
17702                try {
17703                  commitHookEffectListUnmount(Insertion | HasEffect, finishedWork, finishedWork.return);
17704                  commitHookEffectListMount(Insertion | HasEffect, finishedWork);
17705                } catch (error2) {
17706                  captureCommitPhaseError(finishedWork, finishedWork.return, error2);
17707                }
17708                if (finishedWork.mode & ProfileMode) {
17709                  try {
17710                    startLayoutEffectTimer();
17711                    commitHookEffectListUnmount(Layout | HasEffect, finishedWork, finishedWork.return);
17712                  } catch (error2) {
17713                    captureCommitPhaseError(finishedWork, finishedWork.return, error2);
17714                  }
17715                  recordLayoutEffectDuration(finishedWork);
17716                } else {
17717                  try {
17718                    commitHookEffectListUnmount(Layout | HasEffect, finishedWork, finishedWork.return);
17719                  } catch (error2) {
17720                    captureCommitPhaseError(finishedWork, finishedWork.return, error2);
17721                  }
17722                }
17723              }
17724              return;
17725            }
17726            case ClassComponent: {
17727              recursivelyTraverseMutationEffects(root2, finishedWork);
17728              commitReconciliationEffects(finishedWork);
17729              if (flags & Ref) {
17730                if (current2 !== null) {
17731                  safelyDetachRef(current2, current2.return);
17732                }
17733              }
17734              return;
17735            }
17736            case HostComponent: {
17737              recursivelyTraverseMutationEffects(root2, finishedWork);
17738              commitReconciliationEffects(finishedWork);
17739              if (flags & Ref) {
17740                if (current2 !== null) {
17741                  safelyDetachRef(current2, current2.return);
17742                }
17743              }
17744              {
17745                if (finishedWork.flags & ContentReset) {
17746                  var instance = finishedWork.stateNode;
17747                  try {
17748                    resetTextContent(instance);
17749                  } catch (error2) {
17750                    captureCommitPhaseError(finishedWork, finishedWork.return, error2);
17751                  }
17752                }
17753                if (flags & Update) {
17754                  var _instance4 = finishedWork.stateNode;
17755                  if (_instance4 != null) {
17756                    var newProps = finishedWork.memoizedProps;
17757                    var oldProps = current2 !== null ? current2.memoizedProps : newProps;
17758                    var type = finishedWork.type;
17759                    var updatePayload = finishedWork.updateQueue;
17760                    finishedWork.updateQueue = null;
17761                    if (updatePayload !== null) {
17762                      try {
17763                        commitUpdate(_instance4, updatePayload, type, oldProps, newProps, finishedWork);
17764                      } catch (error2) {
17765                        captureCommitPhaseError(finishedWork, finishedWork.return, error2);
17766                      }
17767                    }
17768                  }
17769                }
17770              }
17771              return;
17772            }
17773            case HostText: {
17774              recursivelyTraverseMutationEffects(root2, finishedWork);
17775              commitReconciliationEffects(finishedWork);
17776              if (flags & Update) {
17777                {
17778                  if (finishedWork.stateNode === null) {
17779                    throw new Error("This should have a text node initialized. This error is likely caused by a bug in React. Please file an issue.");
17780                  }
17781                  var textInstance = finishedWork.stateNode;
17782                  var newText = finishedWork.memoizedProps;
17783                  var oldText = current2 !== null ? current2.memoizedProps : newText;
17784                  try {
17785                    commitTextUpdate(textInstance, oldText, newText);
17786                  } catch (error2) {
17787                    captureCommitPhaseError(finishedWork, finishedWork.return, error2);
17788                  }
17789                }
17790              }
17791              return;
17792            }
17793            case HostRoot: {
17794              recursivelyTraverseMutationEffects(root2, finishedWork);
17795              commitReconciliationEffects(finishedWork);
17796              if (flags & Update) {
17797                {
17798                  if (current2 !== null) {
17799                    var prevRootState = current2.memoizedState;
17800                    if (prevRootState.isDehydrated) {
17801                      try {
17802                        commitHydratedContainer(root2.containerInfo);
17803                      } catch (error2) {
17804                        captureCommitPhaseError(finishedWork, finishedWork.return, error2);
17805                      }
17806                    }
17807                  }
17808                }
17809              }
17810              return;
17811            }
17812            case HostPortal: {
17813              recursivelyTraverseMutationEffects(root2, finishedWork);
17814              commitReconciliationEffects(finishedWork);
17815              return;
17816            }
17817            case SuspenseComponent: {
17818              recursivelyTraverseMutationEffects(root2, finishedWork);
17819              commitReconciliationEffects(finishedWork);
17820              var offscreenFiber = finishedWork.child;
17821              if (offscreenFiber.flags & Visibility) {
17822                var offscreenInstance = offscreenFiber.stateNode;
17823                var newState = offscreenFiber.memoizedState;
17824                var isHidden = newState !== null;
17825                offscreenInstance.isHidden = isHidden;
17826                if (isHidden) {
17827                  var wasHidden = offscreenFiber.alternate !== null && offscreenFiber.alternate.memoizedState !== null;
17828                  if (!wasHidden) {
17829                    markCommitTimeOfFallback();
17830                  }
17831                }
17832              }
17833              if (flags & Update) {
17834                try {
17835                  commitSuspenseCallback(finishedWork);
17836                } catch (error2) {
17837                  captureCommitPhaseError(finishedWork, finishedWork.return, error2);
17838                }
17839                attachSuspenseRetryListeners(finishedWork);
17840              }
17841              return;
17842            }
17843            case OffscreenComponent: {
17844              var _wasHidden = current2 !== null && current2.memoizedState !== null;
17845              if (
17846                // TODO: Remove this dead flag
17847                finishedWork.mode & ConcurrentMode
17848              ) {
17849                var prevOffscreenSubtreeWasHidden = offscreenSubtreeWasHidden;
17850                offscreenSubtreeWasHidden = prevOffscreenSubtreeWasHidden || _wasHidden;
17851                recursivelyTraverseMutationEffects(root2, finishedWork);
17852                offscreenSubtreeWasHidden = prevOffscreenSubtreeWasHidden;
17853              } else {
17854                recursivelyTraverseMutationEffects(root2, finishedWork);
17855              }
17856              commitReconciliationEffects(finishedWork);
17857              if (flags & Visibility) {
17858                var _offscreenInstance = finishedWork.stateNode;
17859                var _newState = finishedWork.memoizedState;
17860                var _isHidden = _newState !== null;
17861                var offscreenBoundary = finishedWork;
17862                _offscreenInstance.isHidden = _isHidden;
17863                {
17864                  if (_isHidden) {
17865                    if (!_wasHidden) {
17866                      if ((offscreenBoundary.mode & ConcurrentMode) !== NoMode) {
17867                        nextEffect = offscreenBoundary;
17868                        var offscreenChild = offscreenBoundary.child;
17869                        while (offscreenChild !== null) {
17870                          nextEffect = offscreenChild;
17871                          disappearLayoutEffects_begin(offscreenChild);
17872                          offscreenChild = offscreenChild.sibling;
17873                        }
17874                      }
17875                    }
17876                  }
17877                }
17878                {
17879                  hideOrUnhideAllChildren(offscreenBoundary, _isHidden);
17880                }
17881              }
17882              return;
17883            }
17884            case SuspenseListComponent: {
17885              recursivelyTraverseMutationEffects(root2, finishedWork);
17886              commitReconciliationEffects(finishedWork);
17887              if (flags & Update) {
17888                attachSuspenseRetryListeners(finishedWork);
17889              }
17890              return;
17891            }
17892            case ScopeComponent: {
17893              return;
17894            }
17895            default: {
17896              recursivelyTraverseMutationEffects(root2, finishedWork);
17897              commitReconciliationEffects(finishedWork);
17898              return;
17899            }
17900          }
17901        }
17902        function commitReconciliationEffects(finishedWork) {
17903          var flags = finishedWork.flags;
17904          if (flags & Placement) {
17905            try {
17906              commitPlacement(finishedWork);
17907            } catch (error2) {
17908              captureCommitPhaseError(finishedWork, finishedWork.return, error2);
17909            }
17910            finishedWork.flags &= ~Placement;
17911          }
17912          if (flags & Hydrating) {
17913            finishedWork.flags &= ~Hydrating;
17914          }
17915        }
17916        function commitLayoutEffects(finishedWork, root2, committedLanes) {
17917          inProgressLanes = committedLanes;
17918          inProgressRoot = root2;
17919          nextEffect = finishedWork;
17920          commitLayoutEffects_begin(finishedWork, root2, committedLanes);
17921          inProgressLanes = null;
17922          inProgressRoot = null;
17923        }
17924        function commitLayoutEffects_begin(subtreeRoot, root2, committedLanes) {
17925          var isModernRoot = (subtreeRoot.mode & ConcurrentMode) !== NoMode;
17926          while (nextEffect !== null) {
17927            var fiber = nextEffect;
17928            var firstChild = fiber.child;
17929            if (fiber.tag === OffscreenComponent && isModernRoot) {
17930              var isHidden = fiber.memoizedState !== null;
17931              var newOffscreenSubtreeIsHidden = isHidden || offscreenSubtreeIsHidden;
17932              if (newOffscreenSubtreeIsHidden) {
17933                commitLayoutMountEffects_complete(subtreeRoot, root2, committedLanes);
17934                continue;
17935              } else {
17936                var current2 = fiber.alternate;
17937                var wasHidden = current2 !== null && current2.memoizedState !== null;
17938                var newOffscreenSubtreeWasHidden = wasHidden || offscreenSubtreeWasHidden;
17939                var prevOffscreenSubtreeIsHidden = offscreenSubtreeIsHidden;
17940                var prevOffscreenSubtreeWasHidden = offscreenSubtreeWasHidden;
17941                offscreenSubtreeIsHidden = newOffscreenSubtreeIsHidden;
17942                offscreenSubtreeWasHidden = newOffscreenSubtreeWasHidden;
17943                if (offscreenSubtreeWasHidden && !prevOffscreenSubtreeWasHidden) {
17944                  nextEffect = fiber;
17945                  reappearLayoutEffects_begin(fiber);
17946                }
17947                var child = firstChild;
17948                while (child !== null) {
17949                  nextEffect = child;
17950                  commitLayoutEffects_begin(
17951                    child,
17952                    // New root; bubble back up to here and stop.
17953                    root2,
17954                    committedLanes
17955                  );
17956                  child = child.sibling;
17957                }
17958                nextEffect = fiber;
17959                offscreenSubtreeIsHidden = prevOffscreenSubtreeIsHidden;
17960                offscreenSubtreeWasHidden = prevOffscreenSubtreeWasHidden;
17961                commitLayoutMountEffects_complete(subtreeRoot, root2, committedLanes);
17962                continue;
17963              }
17964            }
17965            if ((fiber.subtreeFlags & LayoutMask) !== NoFlags && firstChild !== null) {
17966              firstChild.return = fiber;
17967              nextEffect = firstChild;
17968            } else {
17969              commitLayoutMountEffects_complete(subtreeRoot, root2, committedLanes);
17970            }
17971          }
17972        }
17973        function commitLayoutMountEffects_complete(subtreeRoot, root2, committedLanes) {
17974          while (nextEffect !== null) {
17975            var fiber = nextEffect;
17976            if ((fiber.flags & LayoutMask) !== NoFlags) {
17977              var current2 = fiber.alternate;
17978              setCurrentFiber(fiber);
17979              try {
17980                commitLayoutEffectOnFiber(root2, current2, fiber, committedLanes);
17981              } catch (error2) {
17982                captureCommitPhaseError(fiber, fiber.return, error2);
17983              }
17984              resetCurrentFiber();
17985            }
17986            if (fiber === subtreeRoot) {
17987              nextEffect = null;
17988              return;
17989            }
17990            var sibling = fiber.sibling;
17991            if (sibling !== null) {
17992              sibling.return = fiber.return;
17993              nextEffect = sibling;
17994              return;
17995            }
17996            nextEffect = fiber.return;
17997          }
17998        }
17999        function disappearLayoutEffects_begin(subtreeRoot) {
18000          while (nextEffect !== null) {
18001            var fiber = nextEffect;
18002            var firstChild = fiber.child;
18003            switch (fiber.tag) {
18004              case FunctionComponent:
18005              case ForwardRef:
18006              case MemoComponent:
18007              case SimpleMemoComponent: {
18008                if (fiber.mode & ProfileMode) {
18009                  try {
18010                    startLayoutEffectTimer();
18011                    commitHookEffectListUnmount(Layout, fiber, fiber.return);
18012                  } finally {
18013                    recordLayoutEffectDuration(fiber);
18014                  }
18015                } else {
18016                  commitHookEffectListUnmount(Layout, fiber, fiber.return);
18017                }
18018                break;
18019              }
18020              case ClassComponent: {
18021                safelyDetachRef(fiber, fiber.return);
18022                var instance = fiber.stateNode;
18023                if (typeof instance.componentWillUnmount === "function") {
18024                  safelyCallComponentWillUnmount(fiber, fiber.return, instance);
18025                }
18026                break;
18027              }
18028              case HostComponent: {
18029                safelyDetachRef(fiber, fiber.return);
18030                break;
18031              }
18032              case OffscreenComponent: {
18033                var isHidden = fiber.memoizedState !== null;
18034                if (isHidden) {
18035                  disappearLayoutEffects_complete(subtreeRoot);
18036                  continue;
18037                }
18038                break;
18039              }
18040            }
18041            if (firstChild !== null) {
18042              firstChild.return = fiber;
18043              nextEffect = firstChild;
18044            } else {
18045              disappearLayoutEffects_complete(subtreeRoot);
18046            }
18047          }
18048        }
18049        function disappearLayoutEffects_complete(subtreeRoot) {
18050          while (nextEffect !== null) {
18051            var fiber = nextEffect;
18052            if (fiber === subtreeRoot) {
18053              nextEffect = null;
18054              return;
18055            }
18056            var sibling = fiber.sibling;
18057            if (sibling !== null) {
18058              sibling.return = fiber.return;
18059              nextEffect = sibling;
18060              return;
18061            }
18062            nextEffect = fiber.return;
18063          }
18064        }
18065        function reappearLayoutEffects_begin(subtreeRoot) {
18066          while (nextEffect !== null) {
18067            var fiber = nextEffect;
18068            var firstChild = fiber.child;
18069            if (fiber.tag === OffscreenComponent) {
18070              var isHidden = fiber.memoizedState !== null;
18071              if (isHidden) {
18072                reappearLayoutEffects_complete(subtreeRoot);
18073                continue;
18074              }
18075            }
18076            if (firstChild !== null) {
18077              firstChild.return = fiber;
18078              nextEffect = firstChild;
18079            } else {
18080              reappearLayoutEffects_complete(subtreeRoot);
18081            }
18082          }
18083        }
18084        function reappearLayoutEffects_complete(subtreeRoot) {
18085          while (nextEffect !== null) {
18086            var fiber = nextEffect;
18087            setCurrentFiber(fiber);
18088            try {
18089              reappearLayoutEffectsOnFiber(fiber);
18090            } catch (error2) {
18091              captureCommitPhaseError(fiber, fiber.return, error2);
18092            }
18093            resetCurrentFiber();
18094            if (fiber === subtreeRoot) {
18095              nextEffect = null;
18096              return;
18097            }
18098            var sibling = fiber.sibling;
18099            if (sibling !== null) {
18100              sibling.return = fiber.return;
18101              nextEffect = sibling;
18102              return;
18103            }
18104            nextEffect = fiber.return;
18105          }
18106        }
18107        function commitPassiveMountEffects(root2, finishedWork, committedLanes, committedTransitions) {
18108          nextEffect = finishedWork;
18109          commitPassiveMountEffects_begin(finishedWork, root2, committedLanes, committedTransitions);
18110        }
18111        function commitPassiveMountEffects_begin(subtreeRoot, root2, committedLanes, committedTransitions) {
18112          while (nextEffect !== null) {
18113            var fiber = nextEffect;
18114            var firstChild = fiber.child;
18115            if ((fiber.subtreeFlags & PassiveMask) !== NoFlags && firstChild !== null) {
18116              firstChild.return = fiber;
18117              nextEffect = firstChild;
18118            } else {
18119              commitPassiveMountEffects_complete(subtreeRoot, root2, committedLanes, committedTransitions);
18120            }
18121          }
18122        }
18123        function commitPassiveMountEffects_complete(subtreeRoot, root2, committedLanes, committedTransitions) {
18124          while (nextEffect !== null) {
18125            var fiber = nextEffect;
18126            if ((fiber.flags & Passive) !== NoFlags) {
18127              setCurrentFiber(fiber);
18128              try {
18129                commitPassiveMountOnFiber(root2, fiber, committedLanes, committedTransitions);
18130              } catch (error2) {
18131                captureCommitPhaseError(fiber, fiber.return, error2);
18132              }
18133              resetCurrentFiber();
18134            }
18135            if (fiber === subtreeRoot) {
18136              nextEffect = null;
18137              return;
18138            }
18139            var sibling = fiber.sibling;
18140            if (sibling !== null) {
18141              sibling.return = fiber.return;
18142              nextEffect = sibling;
18143              return;
18144            }
18145            nextEffect = fiber.return;
18146          }
18147        }
18148        function commitPassiveMountOnFiber(finishedRoot, finishedWork, committedLanes, committedTransitions) {
18149          switch (finishedWork.tag) {
18150            case FunctionComponent:
18151            case ForwardRef:
18152            case SimpleMemoComponent: {
18153              if (finishedWork.mode & ProfileMode) {
18154                startPassiveEffectTimer();
18155                try {
18156                  commitHookEffectListMount(Passive$1 | HasEffect, finishedWork);
18157                } finally {
18158                  recordPassiveEffectDuration(finishedWork);
18159                }
18160              } else {
18161                commitHookEffectListMount(Passive$1 | HasEffect, finishedWork);
18162              }
18163              break;
18164            }
18165          }
18166        }
18167        function commitPassiveUnmountEffects(firstChild) {
18168          nextEffect = firstChild;
18169          commitPassiveUnmountEffects_begin();
18170        }
18171        function commitPassiveUnmountEffects_begin() {
18172          while (nextEffect !== null) {
18173            var fiber = nextEffect;
18174            var child = fiber.child;
18175            if ((nextEffect.flags & ChildDeletion) !== NoFlags) {
18176              var deletions = fiber.deletions;
18177              if (deletions !== null) {
18178                for (var i = 0; i < deletions.length; i++) {
18179                  var fiberToDelete = deletions[i];
18180                  nextEffect = fiberToDelete;
18181                  commitPassiveUnmountEffectsInsideOfDeletedTree_begin(fiberToDelete, fiber);
18182                }
18183                {
18184                  var previousFiber = fiber.alternate;
18185                  if (previousFiber !== null) {
18186                    var detachedChild = previousFiber.child;
18187                    if (detachedChild !== null) {
18188                      previousFiber.child = null;
18189                      do {
18190                        var detachedSibling = detachedChild.sibling;
18191                        detachedChild.sibling = null;
18192                        detachedChild = detachedSibling;
18193                      } while (detachedChild !== null);
18194                    }
18195                  }
18196                }
18197                nextEffect = fiber;
18198              }
18199            }
18200            if ((fiber.subtreeFlags & PassiveMask) !== NoFlags && child !== null) {
18201              child.return = fiber;
18202              nextEffect = child;
18203            } else {
18204              commitPassiveUnmountEffects_complete();
18205            }
18206          }
18207        }
18208        function commitPassiveUnmountEffects_complete() {
18209          while (nextEffect !== null) {
18210            var fiber = nextEffect;
18211            if ((fiber.flags & Passive) !== NoFlags) {
18212              setCurrentFiber(fiber);
18213              commitPassiveUnmountOnFiber(fiber);
18214              resetCurrentFiber();
18215            }
18216            var sibling = fiber.sibling;
18217            if (sibling !== null) {
18218              sibling.return = fiber.return;
18219              nextEffect = sibling;
18220              return;
18221            }
18222            nextEffect = fiber.return;
18223          }
18224        }
18225        function commitPassiveUnmountOnFiber(finishedWork) {
18226          switch (finishedWork.tag) {
18227            case FunctionComponent:
18228            case ForwardRef:
18229            case SimpleMemoComponent: {
18230              if (finishedWork.mode & ProfileMode) {
18231                startPassiveEffectTimer();
18232                commitHookEffectListUnmount(Passive$1 | HasEffect, finishedWork, finishedWork.return);
18233                recordPassiveEffectDuration(finishedWork);
18234              } else {
18235                commitHookEffectListUnmount(Passive$1 | HasEffect, finishedWork, finishedWork.return);
18236              }
18237              break;
18238            }
18239          }
18240        }
18241        function commitPassiveUnmountEffectsInsideOfDeletedTree_begin(deletedSubtreeRoot, nearestMountedAncestor) {
18242          while (nextEffect !== null) {
18243            var fiber = nextEffect;
18244            setCurrentFiber(fiber);
18245            commitPassiveUnmountInsideDeletedTreeOnFiber(fiber, nearestMountedAncestor);
18246            resetCurrentFiber();
18247            var child = fiber.child;
18248            if (child !== null) {
18249              child.return = fiber;
18250              nextEffect = child;
18251            } else {
18252              commitPassiveUnmountEffectsInsideOfDeletedTree_complete(deletedSubtreeRoot);
18253            }
18254          }
18255        }
18256        function commitPassiveUnmountEffectsInsideOfDeletedTree_complete(deletedSubtreeRoot) {
18257          while (nextEffect !== null) {
18258            var fiber = nextEffect;
18259            var sibling = fiber.sibling;
18260            var returnFiber = fiber.return;
18261            {
18262              detachFiberAfterEffects(fiber);
18263              if (fiber === deletedSubtreeRoot) {
18264                nextEffect = null;
18265                return;
18266              }
18267            }
18268            if (sibling !== null) {
18269              sibling.return = returnFiber;
18270              nextEffect = sibling;
18271              return;
18272            }
18273            nextEffect = returnFiber;
18274          }
18275        }
18276        function commitPassiveUnmountInsideDeletedTreeOnFiber(current2, nearestMountedAncestor) {
18277          switch (current2.tag) {
18278            case FunctionComponent:
18279            case ForwardRef:
18280            case SimpleMemoComponent: {
18281              if (current2.mode & ProfileMode) {
18282                startPassiveEffectTimer();
18283                commitHookEffectListUnmount(Passive$1, current2, nearestMountedAncestor);
18284                recordPassiveEffectDuration(current2);
18285              } else {
18286                commitHookEffectListUnmount(Passive$1, current2, nearestMountedAncestor);
18287              }
18288              break;
18289            }
18290          }
18291        }
18292        function invokeLayoutEffectMountInDEV(fiber) {
18293          {
18294            switch (fiber.tag) {
18295              case FunctionComponent:
18296              case ForwardRef:
18297              case SimpleMemoComponent: {
18298                try {
18299                  commitHookEffectListMount(Layout | HasEffect, fiber);
18300                } catch (error2) {
18301                  captureCommitPhaseError(fiber, fiber.return, error2);
18302                }
18303                break;
18304              }
18305              case ClassComponent: {
18306                var instance = fiber.stateNode;
18307                try {
18308                  instance.componentDidMount();
18309                } catch (error2) {
18310                  captureCommitPhaseError(fiber, fiber.return, error2);
18311                }
18312                break;
18313              }
18314            }
18315          }
18316        }
18317        function invokePassiveEffectMountInDEV(fiber) {
18318          {
18319            switch (fiber.tag) {
18320              case FunctionComponent:
18321              case ForwardRef:
18322              case SimpleMemoComponent: {
18323                try {
18324                  commitHookEffectListMount(Passive$1 | HasEffect, fiber);
18325                } catch (error2) {
18326                  captureCommitPhaseError(fiber, fiber.return, error2);
18327                }
18328                break;
18329              }
18330            }
18331          }
18332        }
18333        function invokeLayoutEffectUnmountInDEV(fiber) {
18334          {
18335            switch (fiber.tag) {
18336              case FunctionComponent:
18337              case ForwardRef:
18338              case SimpleMemoComponent: {
18339                try {
18340                  commitHookEffectListUnmount(Layout | HasEffect, fiber, fiber.return);
18341                } catch (error2) {
18342                  captureCommitPhaseError(fiber, fiber.return, error2);
18343                }
18344                break;
18345              }
18346              case ClassComponent: {
18347                var instance = fiber.stateNode;
18348                if (typeof instance.componentWillUnmount === "function") {
18349                  safelyCallComponentWillUnmount(fiber, fiber.return, instance);
18350                }
18351                break;
18352              }
18353            }
18354          }
18355        }
18356        function invokePassiveEffectUnmountInDEV(fiber) {
18357          {
18358            switch (fiber.tag) {
18359              case FunctionComponent:
18360              case ForwardRef:
18361              case SimpleMemoComponent: {
18362                try {
18363                  commitHookEffectListUnmount(Passive$1 | HasEffect, fiber, fiber.return);
18364                } catch (error2) {
18365                  captureCommitPhaseError(fiber, fiber.return, error2);
18366                }
18367              }
18368            }
18369          }
18370        }
18371        var COMPONENT_TYPE = 0;
18372        var HAS_PSEUDO_CLASS_TYPE = 1;
18373        var ROLE_TYPE = 2;
18374        var TEST_NAME_TYPE = 3;
18375        var TEXT_TYPE = 4;
18376        if (typeof Symbol === "function" && Symbol.for) {
18377          var symbolFor = Symbol.for;
18378          COMPONENT_TYPE = symbolFor("selector.component");
18379          HAS_PSEUDO_CLASS_TYPE = symbolFor("selector.has_pseudo_class");
18380          ROLE_TYPE = symbolFor("selector.role");
18381          TEST_NAME_TYPE = symbolFor("selector.test_id");
18382          TEXT_TYPE = symbolFor("selector.text");
18383        }
18384        var commitHooks = [];
18385        function onCommitRoot$1() {
18386          {
18387            commitHooks.forEach(function(commitHook) {
18388              return commitHook();
18389            });
18390          }
18391        }
18392        var ReactCurrentActQueue = ReactSharedInternals.ReactCurrentActQueue;
18393        function isLegacyActEnvironment(fiber) {
18394          {
18395            var isReactActEnvironmentGlobal = (
18396              // $FlowExpectedError – Flow doesn't know about IS_REACT_ACT_ENVIRONMENT global
18397              typeof IS_REACT_ACT_ENVIRONMENT !== "undefined" ? IS_REACT_ACT_ENVIRONMENT : void 0
18398            );
18399            var jestIsDefined = typeof jest !== "undefined";
18400            return jestIsDefined && isReactActEnvironmentGlobal !== false;
18401          }
18402        }
18403        function isConcurrentActEnvironment() {
18404          {
18405            var isReactActEnvironmentGlobal = (
18406              // $FlowExpectedError – Flow doesn't know about IS_REACT_ACT_ENVIRONMENT global
18407              typeof IS_REACT_ACT_ENVIRONMENT !== "undefined" ? IS_REACT_ACT_ENVIRONMENT : void 0
18408            );
18409            if (!isReactActEnvironmentGlobal && ReactCurrentActQueue.current !== null) {
18410              error("The current testing environment is not configured to support act(...)");
18411            }
18412            return isReactActEnvironmentGlobal;
18413          }
18414        }
18415        var ceil = Math.ceil;
18416        var ReactCurrentDispatcher$2 = ReactSharedInternals.ReactCurrentDispatcher, ReactCurrentOwner$2 = ReactSharedInternals.ReactCurrentOwner, ReactCurrentBatchConfig$3 = ReactSharedInternals.ReactCurrentBatchConfig, ReactCurrentActQueue$1 = ReactSharedInternals.ReactCurrentActQueue;
18417        var NoContext = (
18418          /*             */
18419          0
18420        );
18421        var BatchedContext = (
18422          /*               */
18423          1
18424        );
18425        var RenderContext = (
18426          /*                */
18427          2
18428        );
18429        var CommitContext = (
18430          /*                */
18431          4
18432        );
18433        var RootInProgress = 0;
18434        var RootFatalErrored = 1;
18435        var RootErrored = 2;
18436        var RootSuspended = 3;
18437        var RootSuspendedWithDelay = 4;
18438        var RootCompleted = 5;
18439        var RootDidNotComplete = 6;
18440        var executionContext = NoContext;
18441        var workInProgressRoot = null;
18442        var workInProgress = null;
18443        var workInProgressRootRenderLanes = NoLanes;
18444        var subtreeRenderLanes = NoLanes;
18445        var subtreeRenderLanesCursor = createCursor(NoLanes);
18446        var workInProgressRootExitStatus = RootInProgress;
18447        var workInProgressRootFatalError = null;
18448        var workInProgressRootIncludedLanes = NoLanes;
18449        var workInProgressRootSkippedLanes = NoLanes;
18450        var workInProgressRootInterleavedUpdatedLanes = NoLanes;
18451        var workInProgressRootPingedLanes = NoLanes;
18452        var workInProgressRootConcurrentErrors = null;
18453        var workInProgressRootRecoverableErrors = null;
18454        var globalMostRecentFallbackTime = 0;
18455        var FALLBACK_THROTTLE_MS = 500;
18456        var workInProgressRootRenderTargetTime = Infinity;
18457        var RENDER_TIMEOUT_MS = 500;
18458        var workInProgressTransitions = null;
18459        function resetRenderTimer() {
18460          workInProgressRootRenderTargetTime = now() + RENDER_TIMEOUT_MS;
18461        }
18462        function getRenderTargetTime() {
18463          return workInProgressRootRenderTargetTime;
18464        }
18465        var hasUncaughtError = false;
18466        var firstUncaughtError = null;
18467        var legacyErrorBoundariesThatAlreadyFailed = null;
18468        var rootDoesHavePassiveEffects = false;
18469        var rootWithPendingPassiveEffects = null;
18470        var pendingPassiveEffectsLanes = NoLanes;
18471        var pendingPassiveProfilerEffects = [];
18472        var pendingPassiveTransitions = null;
18473        var NESTED_UPDATE_LIMIT = 50;
18474        var nestedUpdateCount = 0;
18475        var rootWithNestedUpdates = null;
18476        var isFlushingPassiveEffects = false;
18477        var didScheduleUpdateDuringPassiveEffects = false;
18478        var NESTED_PASSIVE_UPDATE_LIMIT = 50;
18479        var nestedPassiveUpdateCount = 0;
18480        var rootWithPassiveNestedUpdates = null;
18481        var currentEventTime = NoTimestamp;
18482        var currentEventTransitionLane = NoLanes;
18483        var isRunningInsertionEffect = false;
18484        function getWorkInProgressRoot() {
18485          return workInProgressRoot;
18486        }
18487        function requestEventTime() {
18488          if ((executionContext & (RenderContext | CommitContext)) !== NoContext) {
18489            return now();
18490          }
18491          if (currentEventTime !== NoTimestamp) {
18492            return currentEventTime;
18493          }
18494          currentEventTime = now();
18495          return currentEventTime;
18496        }
18497        function requestUpdateLane(fiber) {
18498          var mode = fiber.mode;
18499          if ((mode & ConcurrentMode) === NoMode) {
18500            return SyncLane;
18501          } else if ((executionContext & RenderContext) !== NoContext && workInProgressRootRenderLanes !== NoLanes) {
18502            return pickArbitraryLane(workInProgressRootRenderLanes);
18503          }
18504          var isTransition = requestCurrentTransition() !== NoTransition;
18505          if (isTransition) {
18506            if (ReactCurrentBatchConfig$3.transition !== null) {
18507              var transition = ReactCurrentBatchConfig$3.transition;
18508              if (!transition._updatedFibers) {
18509                transition._updatedFibers = /* @__PURE__ */ new Set();
18510              }
18511              transition._updatedFibers.add(fiber);
18512            }
18513            if (currentEventTransitionLane === NoLane) {
18514              currentEventTransitionLane = claimNextTransitionLane();
18515            }
18516            return currentEventTransitionLane;
18517          }
18518          var updateLane = getCurrentUpdatePriority();
18519          if (updateLane !== NoLane) {
18520            return updateLane;
18521          }
18522          var eventLane = getCurrentEventPriority();
18523          return eventLane;
18524        }
18525        function requestRetryLane(fiber) {
18526          var mode = fiber.mode;
18527          if ((mode & ConcurrentMode) === NoMode) {
18528            return SyncLane;
18529          }
18530          return claimNextRetryLane();
18531        }
18532        function scheduleUpdateOnFiber(root2, fiber, lane, eventTime) {
18533          checkForNestedUpdates();
18534          {
18535            if (isRunningInsertionEffect) {
18536              error("useInsertionEffect must not schedule updates.");
18537            }
18538          }
18539          {
18540            if (isFlushingPassiveEffects) {
18541              didScheduleUpdateDuringPassiveEffects = true;
18542            }
18543          }
18544          markRootUpdated(root2, lane, eventTime);
18545          if ((executionContext & RenderContext) !== NoLanes && root2 === workInProgressRoot) {
18546            warnAboutRenderPhaseUpdatesInDEV(fiber);
18547          } else {
18548            {
18549              if (isDevToolsPresent) {
18550                addFiberToLanesMap(root2, fiber, lane);
18551              }
18552            }
18553            warnIfUpdatesNotWrappedWithActDEV(fiber);
18554            if (root2 === workInProgressRoot) {
18555              if ((executionContext & RenderContext) === NoContext) {
18556                workInProgressRootInterleavedUpdatedLanes = mergeLanes(workInProgressRootInterleavedUpdatedLanes, lane);
18557              }
18558              if (workInProgressRootExitStatus === RootSuspendedWithDelay) {
18559                markRootSuspended$1(root2, workInProgressRootRenderLanes);
18560              }
18561            }
18562            ensureRootIsScheduled(root2, eventTime);
18563            if (lane === SyncLane && executionContext === NoContext && (fiber.mode & ConcurrentMode) === NoMode && // Treat `act` as if it's inside `batchedUpdates`, even in legacy mode.
18564            !ReactCurrentActQueue$1.isBatchingLegacy) {
18565              resetRenderTimer();
18566              flushSyncCallbacksOnlyInLegacyMode();
18567            }
18568          }
18569        }
18570        function scheduleInitialHydrationOnRoot(root2, lane, eventTime) {
18571          var current2 = root2.current;
18572          current2.lanes = lane;
18573          markRootUpdated(root2, lane, eventTime);
18574          ensureRootIsScheduled(root2, eventTime);
18575        }
18576        function isUnsafeClassRenderPhaseUpdate(fiber) {
18577          return (
18578            // TODO: Remove outdated deferRenderPhaseUpdateToNextBatch experiment. We
18579            // decided not to enable it.
18580            (executionContext & RenderContext) !== NoContext
18581          );
18582        }
18583        function ensureRootIsScheduled(root2, currentTime) {
18584          var existingCallbackNode = root2.callbackNode;
18585          markStarvedLanesAsExpired(root2, currentTime);
18586          var nextLanes = getNextLanes(root2, root2 === workInProgressRoot ? workInProgressRootRenderLanes : NoLanes);
18587          if (nextLanes === NoLanes) {
18588            if (existingCallbackNode !== null) {
18589              cancelCallback$1(existingCallbackNode);
18590            }
18591            root2.callbackNode = null;
18592            root2.callbackPriority = NoLane;
18593            return;
18594          }
18595          var newCallbackPriority = getHighestPriorityLane(nextLanes);
18596          var existingCallbackPriority = root2.callbackPriority;
18597          if (existingCallbackPriority === newCallbackPriority && // Special case related to `act`. If the currently scheduled task is a
18598          // Scheduler task, rather than an `act` task, cancel it and re-scheduled
18599          // on the `act` queue.
18600          !(ReactCurrentActQueue$1.current !== null && existingCallbackNode !== fakeActCallbackNode)) {
18601            {
18602              if (existingCallbackNode == null && existingCallbackPriority !== SyncLane) {
18603                error("Expected scheduled callback to exist. This error is likely caused by a bug in React. Please file an issue.");
18604              }
18605            }
18606            return;
18607          }
18608          if (existingCallbackNode != null) {
18609            cancelCallback$1(existingCallbackNode);
18610          }
18611          var newCallbackNode;
18612          if (newCallbackPriority === SyncLane) {
18613            if (root2.tag === LegacyRoot) {
18614              if (ReactCurrentActQueue$1.isBatchingLegacy !== null) {
18615                ReactCurrentActQueue$1.didScheduleLegacyUpdate = true;
18616              }
18617              scheduleLegacySyncCallback(performSyncWorkOnRoot.bind(null, root2));
18618            } else {
18619              scheduleSyncCallback(performSyncWorkOnRoot.bind(null, root2));
18620            }
18621            {
18622              if (ReactCurrentActQueue$1.current !== null) {
18623                ReactCurrentActQueue$1.current.push(flushSyncCallbacks);
18624              } else {
18625                scheduleMicrotask(function() {
18626                  if ((executionContext & (RenderContext | CommitContext)) === NoContext) {
18627                    flushSyncCallbacks();
18628                  }
18629                });
18630              }
18631            }
18632            newCallbackNode = null;
18633          } else {
18634            var schedulerPriorityLevel;
18635            switch (lanesToEventPriority(nextLanes)) {
18636              case DiscreteEventPriority:
18637                schedulerPriorityLevel = ImmediatePriority;
18638                break;
18639              case ContinuousEventPriority:
18640                schedulerPriorityLevel = UserBlockingPriority;
18641                break;
18642              case DefaultEventPriority:
18643                schedulerPriorityLevel = NormalPriority;
18644                break;
18645              case IdleEventPriority:
18646                schedulerPriorityLevel = IdlePriority;
18647                break;
18648              default:
18649                schedulerPriorityLevel = NormalPriority;
18650                break;
18651            }
18652            newCallbackNode = scheduleCallback$1(schedulerPriorityLevel, performConcurrentWorkOnRoot.bind(null, root2));
18653          }
18654          root2.callbackPriority = newCallbackPriority;
18655          root2.callbackNode = newCallbackNode;
18656        }
18657        function performConcurrentWorkOnRoot(root2, didTimeout) {
18658          {
18659            resetNestedUpdateFlag();
18660          }
18661          currentEventTime = NoTimestamp;
18662          currentEventTransitionLane = NoLanes;
18663          if ((executionContext & (RenderContext | CommitContext)) !== NoContext) {
18664            throw new Error("Should not already be working.");
18665          }
18666          var originalCallbackNode = root2.callbackNode;
18667          var didFlushPassiveEffects = flushPassiveEffects();
18668          if (didFlushPassiveEffects) {
18669            if (root2.callbackNode !== originalCallbackNode) {
18670              return null;
18671            }
18672          }
18673          var lanes = getNextLanes(root2, root2 === workInProgressRoot ? workInProgressRootRenderLanes : NoLanes);
18674          if (lanes === NoLanes) {
18675            return null;
18676          }
18677          var shouldTimeSlice = !includesBlockingLane(root2, lanes) && !includesExpiredLane(root2, lanes) && !didTimeout;
18678          var exitStatus = shouldTimeSlice ? renderRootConcurrent(root2, lanes) : renderRootSync(root2, lanes);
18679          if (exitStatus !== RootInProgress) {
18680            if (exitStatus === RootErrored) {
18681              var errorRetryLanes = getLanesToRetrySynchronouslyOnError(root2);
18682              if (errorRetryLanes !== NoLanes) {
18683                lanes = errorRetryLanes;
18684                exitStatus = recoverFromConcurrentError(root2, errorRetryLanes);
18685              }
18686            }
18687            if (exitStatus === RootFatalErrored) {
18688              var fatalError = workInProgressRootFatalError;
18689              prepareFreshStack(root2, NoLanes);
18690              markRootSuspended$1(root2, lanes);
18691              ensureRootIsScheduled(root2, now());
18692              throw fatalError;
18693            }
18694            if (exitStatus === RootDidNotComplete) {
18695              markRootSuspended$1(root2, lanes);
18696            } else {
18697              var renderWasConcurrent = !includesBlockingLane(root2, lanes);
18698              var finishedWork = root2.current.alternate;
18699              if (renderWasConcurrent && !isRenderConsistentWithExternalStores(finishedWork)) {
18700                exitStatus = renderRootSync(root2, lanes);
18701                if (exitStatus === RootErrored) {
18702                  var _errorRetryLanes = getLanesToRetrySynchronouslyOnError(root2);
18703                  if (_errorRetryLanes !== NoLanes) {
18704                    lanes = _errorRetryLanes;
18705                    exitStatus = recoverFromConcurrentError(root2, _errorRetryLanes);
18706                  }
18707                }
18708                if (exitStatus === RootFatalErrored) {
18709                  var _fatalError = workInProgressRootFatalError;
18710                  prepareFreshStack(root2, NoLanes);
18711                  markRootSuspended$1(root2, lanes);
18712                  ensureRootIsScheduled(root2, now());
18713                  throw _fatalError;
18714                }
18715              }
18716              root2.finishedWork = finishedWork;
18717              root2.finishedLanes = lanes;
18718              finishConcurrentRender(root2, exitStatus, lanes);
18719            }
18720          }
18721          ensureRootIsScheduled(root2, now());
18722          if (root2.callbackNode === originalCallbackNode) {
18723            return performConcurrentWorkOnRoot.bind(null, root2);
18724          }
18725          return null;
18726        }
18727        function recoverFromConcurrentError(root2, errorRetryLanes) {
18728          var errorsFromFirstAttempt = workInProgressRootConcurrentErrors;
18729          if (isRootDehydrated(root2)) {
18730            var rootWorkInProgress = prepareFreshStack(root2, errorRetryLanes);
18731            rootWorkInProgress.flags |= ForceClientRender;
18732            {
18733              errorHydratingContainer(root2.containerInfo);
18734            }
18735          }
18736          var exitStatus = renderRootSync(root2, errorRetryLanes);
18737          if (exitStatus !== RootErrored) {
18738            var errorsFromSecondAttempt = workInProgressRootRecoverableErrors;
18739            workInProgressRootRecoverableErrors = errorsFromFirstAttempt;
18740            if (errorsFromSecondAttempt !== null) {
18741              queueRecoverableErrors(errorsFromSecondAttempt);
18742            }
18743          }
18744          return exitStatus;
18745        }
18746        function queueRecoverableErrors(errors) {
18747          if (workInProgressRootRecoverableErrors === null) {
18748            workInProgressRootRecoverableErrors = errors;
18749          } else {
18750            workInProgressRootRecoverableErrors.push.apply(workInProgressRootRecoverableErrors, errors);
18751          }
18752        }
18753        function finishConcurrentRender(root2, exitStatus, lanes) {
18754          switch (exitStatus) {
18755            case RootInProgress:
18756            case RootFatalErrored: {
18757              throw new Error("Root did not complete. This is a bug in React.");
18758            }
18759            case RootErrored: {
18760              commitRoot(root2, workInProgressRootRecoverableErrors, workInProgressTransitions);
18761              break;
18762            }
18763            case RootSuspended: {
18764              markRootSuspended$1(root2, lanes);
18765              if (includesOnlyRetries(lanes) && // do not delay if we're inside an act() scope
18766              !shouldForceFlushFallbacksInDEV()) {
18767                var msUntilTimeout = globalMostRecentFallbackTime + FALLBACK_THROTTLE_MS - now();
18768                if (msUntilTimeout > 10) {
18769                  var nextLanes = getNextLanes(root2, NoLanes);
18770                  if (nextLanes !== NoLanes) {
18771                    break;
18772                  }
18773                  var suspendedLanes = root2.suspendedLanes;
18774                  if (!isSubsetOfLanes(suspendedLanes, lanes)) {
18775                    var eventTime = requestEventTime();
18776                    markRootPinged(root2, suspendedLanes);
18777                    break;
18778                  }
18779                  root2.timeoutHandle = scheduleTimeout(commitRoot.bind(null, root2, workInProgressRootRecoverableErrors, workInProgressTransitions), msUntilTimeout);
18780                  break;
18781                }
18782              }
18783              commitRoot(root2, workInProgressRootRecoverableErrors, workInProgressTransitions);
18784              break;
18785            }
18786            case RootSuspendedWithDelay: {
18787              markRootSuspended$1(root2, lanes);
18788              if (includesOnlyTransitions(lanes)) {
18789                break;
18790              }
18791              if (!shouldForceFlushFallbacksInDEV()) {
18792                var mostRecentEventTime = getMostRecentEventTime(root2, lanes);
18793                var eventTimeMs = mostRecentEventTime;
18794                var timeElapsedMs = now() - eventTimeMs;
18795                var _msUntilTimeout = jnd(timeElapsedMs) - timeElapsedMs;
18796                if (_msUntilTimeout > 10) {
18797                  root2.timeoutHandle = scheduleTimeout(commitRoot.bind(null, root2, workInProgressRootRecoverableErrors, workInProgressTransitions), _msUntilTimeout);
18798                  break;
18799                }
18800              }
18801              commitRoot(root2, workInProgressRootRecoverableErrors, workInProgressTransitions);
18802              break;
18803            }
18804            case RootCompleted: {
18805              commitRoot(root2, workInProgressRootRecoverableErrors, workInProgressTransitions);
18806              break;
18807            }
18808            default: {
18809              throw new Error("Unknown root exit status.");
18810            }
18811          }
18812        }
18813        function isRenderConsistentWithExternalStores(finishedWork) {
18814          var node = finishedWork;
18815          while (true) {
18816            if (node.flags & StoreConsistency) {
18817              var updateQueue = node.updateQueue;
18818              if (updateQueue !== null) {
18819                var checks = updateQueue.stores;
18820                if (checks !== null) {
18821                  for (var i = 0; i < checks.length; i++) {
18822                    var check = checks[i];
18823                    var getSnapshot = check.getSnapshot;
18824                    var renderedValue = check.value;
18825                    try {
18826                      if (!objectIs(getSnapshot(), renderedValue)) {
18827                        return false;
18828                      }
18829                    } catch (error2) {
18830                      return false;
18831                    }
18832                  }
18833                }
18834              }
18835            }
18836            var child = node.child;
18837            if (node.subtreeFlags & StoreConsistency && child !== null) {
18838              child.return = node;
18839              node = child;
18840              continue;
18841            }
18842            if (node === finishedWork) {
18843              return true;
18844            }
18845            while (node.sibling === null) {
18846              if (node.return === null || node.return === finishedWork) {
18847                return true;
18848              }
18849              node = node.return;
18850            }
18851            node.sibling.return = node.return;
18852            node = node.sibling;
18853          }
18854          return true;
18855        }
18856        function markRootSuspended$1(root2, suspendedLanes) {
18857          suspendedLanes = removeLanes(suspendedLanes, workInProgressRootPingedLanes);
18858          suspendedLanes = removeLanes(suspendedLanes, workInProgressRootInterleavedUpdatedLanes);
18859          markRootSuspended(root2, suspendedLanes);
18860        }
18861        function performSyncWorkOnRoot(root2) {
18862          {
18863            syncNestedUpdateFlag();
18864          }
18865          if ((executionContext & (RenderContext | CommitContext)) !== NoContext) {
18866            throw new Error("Should not already be working.");
18867          }
18868          flushPassiveEffects();
18869          var lanes = getNextLanes(root2, NoLanes);
18870          if (!includesSomeLane(lanes, SyncLane)) {
18871            ensureRootIsScheduled(root2, now());
18872            return null;
18873          }
18874          var exitStatus = renderRootSync(root2, lanes);
18875          if (root2.tag !== LegacyRoot && exitStatus === RootErrored) {
18876            var errorRetryLanes = getLanesToRetrySynchronouslyOnError(root2);
18877            if (errorRetryLanes !== NoLanes) {
18878              lanes = errorRetryLanes;
18879              exitStatus = recoverFromConcurrentError(root2, errorRetryLanes);
18880            }
18881          }
18882          if (exitStatus === RootFatalErrored) {
18883            var fatalError = workInProgressRootFatalError;
18884            prepareFreshStack(root2, NoLanes);
18885            markRootSuspended$1(root2, lanes);
18886            ensureRootIsScheduled(root2, now());
18887            throw fatalError;
18888          }
18889          if (exitStatus === RootDidNotComplete) {
18890            throw new Error("Root did not complete. This is a bug in React.");
18891          }
18892          var finishedWork = root2.current.alternate;
18893          root2.finishedWork = finishedWork;
18894          root2.finishedLanes = lanes;
18895          commitRoot(root2, workInProgressRootRecoverableErrors, workInProgressTransitions);
18896          ensureRootIsScheduled(root2, now());
18897          return null;
18898        }
18899        function flushRoot(root2, lanes) {
18900          if (lanes !== NoLanes) {
18901            markRootEntangled(root2, mergeLanes(lanes, SyncLane));
18902            ensureRootIsScheduled(root2, now());
18903            if ((executionContext & (RenderContext | CommitContext)) === NoContext) {
18904              resetRenderTimer();
18905              flushSyncCallbacks();
18906            }
18907          }
18908        }
18909        function batchedUpdates$1(fn, a) {
18910          var prevExecutionContext = executionContext;
18911          executionContext |= BatchedContext;
18912          try {
18913            return fn(a);
18914          } finally {
18915            executionContext = prevExecutionContext;
18916            if (executionContext === NoContext && // Treat `act` as if it's inside `batchedUpdates`, even in legacy mode.
18917            !ReactCurrentActQueue$1.isBatchingLegacy) {
18918              resetRenderTimer();
18919              flushSyncCallbacksOnlyInLegacyMode();
18920            }
18921          }
18922        }
18923        function discreteUpdates(fn, a, b, c, d) {
18924          var previousPriority = getCurrentUpdatePriority();
18925          var prevTransition = ReactCurrentBatchConfig$3.transition;
18926          try {
18927            ReactCurrentBatchConfig$3.transition = null;
18928            setCurrentUpdatePriority(DiscreteEventPriority);
18929            return fn(a, b, c, d);
18930          } finally {
18931            setCurrentUpdatePriority(previousPriority);
18932            ReactCurrentBatchConfig$3.transition = prevTransition;
18933            if (executionContext === NoContext) {
18934              resetRenderTimer();
18935            }
18936          }
18937        }
18938        function flushSync(fn) {
18939          if (rootWithPendingPassiveEffects !== null && rootWithPendingPassiveEffects.tag === LegacyRoot && (executionContext & (RenderContext | CommitContext)) === NoContext) {
18940            flushPassiveEffects();
18941          }
18942          var prevExecutionContext = executionContext;
18943          executionContext |= BatchedContext;
18944          var prevTransition = ReactCurrentBatchConfig$3.transition;
18945          var previousPriority = getCurrentUpdatePriority();
18946          try {
18947            ReactCurrentBatchConfig$3.transition = null;
18948            setCurrentUpdatePriority(DiscreteEventPriority);
18949            if (fn) {
18950              return fn();
18951            } else {
18952              return void 0;
18953            }
18954          } finally {
18955            setCurrentUpdatePriority(previousPriority);
18956            ReactCurrentBatchConfig$3.transition = prevTransition;
18957            executionContext = prevExecutionContext;
18958            if ((executionContext & (RenderContext | CommitContext)) === NoContext) {
18959              flushSyncCallbacks();
18960            }
18961          }
18962        }
18963        function isAlreadyRendering() {
18964          return (executionContext & (RenderContext | CommitContext)) !== NoContext;
18965        }
18966        function pushRenderLanes(fiber, lanes) {
18967          push(subtreeRenderLanesCursor, subtreeRenderLanes, fiber);
18968          subtreeRenderLanes = mergeLanes(subtreeRenderLanes, lanes);
18969          workInProgressRootIncludedLanes = mergeLanes(workInProgressRootIncludedLanes, lanes);
18970        }
18971        function popRenderLanes(fiber) {
18972          subtreeRenderLanes = subtreeRenderLanesCursor.current;
18973          pop(subtreeRenderLanesCursor, fiber);
18974        }
18975        function prepareFreshStack(root2, lanes) {
18976          root2.finishedWork = null;
18977          root2.finishedLanes = NoLanes;
18978          var timeoutHandle = root2.timeoutHandle;
18979          if (timeoutHandle !== noTimeout) {
18980            root2.timeoutHandle = noTimeout;
18981            cancelTimeout(timeoutHandle);
18982          }
18983          if (workInProgress !== null) {
18984            var interruptedWork = workInProgress.return;
18985            while (interruptedWork !== null) {
18986              var current2 = interruptedWork.alternate;
18987              unwindInterruptedWork(current2, interruptedWork);
18988              interruptedWork = interruptedWork.return;
18989            }
18990          }
18991          workInProgressRoot = root2;
18992          var rootWorkInProgress = createWorkInProgress(root2.current, null);
18993          workInProgress = rootWorkInProgress;
18994          workInProgressRootRenderLanes = subtreeRenderLanes = workInProgressRootIncludedLanes = lanes;
18995          workInProgressRootExitStatus = RootInProgress;
18996          workInProgressRootFatalError = null;
18997          workInProgressRootSkippedLanes = NoLanes;
18998          workInProgressRootInterleavedUpdatedLanes = NoLanes;
18999          workInProgressRootPingedLanes = NoLanes;
19000          workInProgressRootConcurrentErrors = null;
19001          workInProgressRootRecoverableErrors = null;
19002          finishQueueingConcurrentUpdates();
19003          {
19004            ReactStrictModeWarnings.discardPendingWarnings();
19005          }
19006          return rootWorkInProgress;
19007        }
19008        function handleError(root2, thrownValue) {
19009          do {
19010            var erroredWork = workInProgress;
19011            try {
19012              resetContextDependencies();
19013              resetHooksAfterThrow();
19014              resetCurrentFiber();
19015              ReactCurrentOwner$2.current = null;
19016              if (erroredWork === null || erroredWork.return === null) {
19017                workInProgressRootExitStatus = RootFatalErrored;
19018                workInProgressRootFatalError = thrownValue;
19019                workInProgress = null;
19020                return;
19021              }
19022              if (enableProfilerTimer && erroredWork.mode & ProfileMode) {
19023                stopProfilerTimerIfRunningAndRecordDelta(erroredWork, true);
19024              }
19025              if (enableSchedulingProfiler) {
19026                markComponentRenderStopped();
19027                if (thrownValue !== null && typeof thrownValue === "object" && typeof thrownValue.then === "function") {
19028                  var wakeable = thrownValue;
19029                  markComponentSuspended(erroredWork, wakeable, workInProgressRootRenderLanes);
19030                } else {
19031                  markComponentErrored(erroredWork, thrownValue, workInProgressRootRenderLanes);
19032                }
19033              }
19034              throwException(root2, erroredWork.return, erroredWork, thrownValue, workInProgressRootRenderLanes);
19035              completeUnitOfWork(erroredWork);
19036            } catch (yetAnotherThrownValue) {
19037              thrownValue = yetAnotherThrownValue;
19038              if (workInProgress === erroredWork && erroredWork !== null) {
19039                erroredWork = erroredWork.return;
19040                workInProgress = erroredWork;
19041              } else {
19042                erroredWork = workInProgress;
19043              }
19044              continue;
19045            }
19046            return;
19047          } while (true);
19048        }
19049        function pushDispatcher() {
19050          var prevDispatcher = ReactCurrentDispatcher$2.current;
19051          ReactCurrentDispatcher$2.current = ContextOnlyDispatcher;
19052          if (prevDispatcher === null) {
19053            return ContextOnlyDispatcher;
19054          } else {
19055            return prevDispatcher;
19056          }
19057        }
19058        function popDispatcher(prevDispatcher) {
19059          ReactCurrentDispatcher$2.current = prevDispatcher;
19060        }
19061        function markCommitTimeOfFallback() {
19062          globalMostRecentFallbackTime = now();
19063        }
19064        function markSkippedUpdateLanes(lane) {
19065          workInProgressRootSkippedLanes = mergeLanes(lane, workInProgressRootSkippedLanes);
19066        }
19067        function renderDidSuspend() {
19068          if (workInProgressRootExitStatus === RootInProgress) {
19069            workInProgressRootExitStatus = RootSuspended;
19070          }
19071        }
19072        function renderDidSuspendDelayIfPossible() {
19073          if (workInProgressRootExitStatus === RootInProgress || workInProgressRootExitStatus === RootSuspended || workInProgressRootExitStatus === RootErrored) {
19074            workInProgressRootExitStatus = RootSuspendedWithDelay;
19075          }
19076          if (workInProgressRoot !== null && (includesNonIdleWork(workInProgressRootSkippedLanes) || includesNonIdleWork(workInProgressRootInterleavedUpdatedLanes))) {
19077            markRootSuspended$1(workInProgressRoot, workInProgressRootRenderLanes);
19078          }
19079        }
19080        function renderDidError(error2) {
19081          if (workInProgressRootExitStatus !== RootSuspendedWithDelay) {
19082            workInProgressRootExitStatus = RootErrored;
19083          }
19084          if (workInProgressRootConcurrentErrors === null) {
19085            workInProgressRootConcurrentErrors = [error2];
19086          } else {
19087            workInProgressRootConcurrentErrors.push(error2);
19088          }
19089        }
19090        function renderHasNotSuspendedYet() {
19091          return workInProgressRootExitStatus === RootInProgress;
19092        }
19093        function renderRootSync(root2, lanes) {
19094          var prevExecutionContext = executionContext;
19095          executionContext |= RenderContext;
19096          var prevDispatcher = pushDispatcher();
19097          if (workInProgressRoot !== root2 || workInProgressRootRenderLanes !== lanes) {
19098            {
19099              if (isDevToolsPresent) {
19100                var memoizedUpdaters = root2.memoizedUpdaters;
19101                if (memoizedUpdaters.size > 0) {
19102                  restorePendingUpdaters(root2, workInProgressRootRenderLanes);
19103                  memoizedUpdaters.clear();
19104                }
19105                movePendingFibersToMemoized(root2, lanes);
19106              }
19107            }
19108            workInProgressTransitions = getTransitionsForLanes();
19109            prepareFreshStack(root2, lanes);
19110          }
19111          {
19112            markRenderStarted(lanes);
19113          }
19114          do {
19115            try {
19116              workLoopSync();
19117              break;
19118            } catch (thrownValue) {
19119              handleError(root2, thrownValue);
19120            }
19121          } while (true);
19122          resetContextDependencies();
19123          executionContext = prevExecutionContext;
19124          popDispatcher(prevDispatcher);
19125          if (workInProgress !== null) {
19126            throw new Error("Cannot commit an incomplete root. This error is likely caused by a bug in React. Please file an issue.");
19127          }
19128          {
19129            markRenderStopped();
19130          }
19131          workInProgressRoot = null;
19132          workInProgressRootRenderLanes = NoLanes;
19133          return workInProgressRootExitStatus;
19134        }
19135        function workLoopSync() {
19136          while (workInProgress !== null) {
19137            performUnitOfWork(workInProgress);
19138          }
19139        }
19140        function renderRootConcurrent(root2, lanes) {
19141          var prevExecutionContext = executionContext;
19142          executionContext |= RenderContext;
19143          var prevDispatcher = pushDispatcher();
19144          if (workInProgressRoot !== root2 || workInProgressRootRenderLanes !== lanes) {
19145            {
19146              if (isDevToolsPresent) {
19147                var memoizedUpdaters = root2.memoizedUpdaters;
19148                if (memoizedUpdaters.size > 0) {
19149                  restorePendingUpdaters(root2, workInProgressRootRenderLanes);
19150                  memoizedUpdaters.clear();
19151                }
19152                movePendingFibersToMemoized(root2, lanes);
19153              }
19154            }
19155            workInProgressTransitions = getTransitionsForLanes();
19156            resetRenderTimer();
19157            prepareFreshStack(root2, lanes);
19158          }
19159          {
19160            markRenderStarted(lanes);
19161          }
19162          do {
19163            try {
19164              workLoopConcurrent();
19165              break;
19166            } catch (thrownValue) {
19167              handleError(root2, thrownValue);
19168            }
19169          } while (true);
19170          resetContextDependencies();
19171          popDispatcher(prevDispatcher);
19172          executionContext = prevExecutionContext;
19173          if (workInProgress !== null) {
19174            {
19175              markRenderYielded();
19176            }
19177            return RootInProgress;
19178          } else {
19179            {
19180              markRenderStopped();
19181            }
19182            workInProgressRoot = null;
19183            workInProgressRootRenderLanes = NoLanes;
19184            return workInProgressRootExitStatus;
19185          }
19186        }
19187        function workLoopConcurrent() {
19188          while (workInProgress !== null && !shouldYield()) {
19189            performUnitOfWork(workInProgress);
19190          }
19191        }
19192        function performUnitOfWork(unitOfWork) {
19193          var current2 = unitOfWork.alternate;
19194          setCurrentFiber(unitOfWork);
19195          var next;
19196          if ((unitOfWork.mode & ProfileMode) !== NoMode) {
19197            startProfilerTimer(unitOfWork);
19198            next = beginWork$1(current2, unitOfWork, subtreeRenderLanes);
19199            stopProfilerTimerIfRunningAndRecordDelta(unitOfWork, true);
19200          } else {
19201            next = beginWork$1(current2, unitOfWork, subtreeRenderLanes);
19202          }
19203          resetCurrentFiber();
19204          unitOfWork.memoizedProps = unitOfWork.pendingProps;
19205          if (next === null) {
19206            completeUnitOfWork(unitOfWork);
19207          } else {
19208            workInProgress = next;
19209          }
19210          ReactCurrentOwner$2.current = null;
19211        }
19212        function completeUnitOfWork(unitOfWork) {
19213          var completedWork = unitOfWork;
19214          do {
19215            var current2 = completedWork.alternate;
19216            var returnFiber = completedWork.return;
19217            if ((completedWork.flags & Incomplete) === NoFlags) {
19218              setCurrentFiber(completedWork);
19219              var next = void 0;
19220              if ((completedWork.mode & ProfileMode) === NoMode) {
19221                next = completeWork(current2, completedWork, subtreeRenderLanes);
19222              } else {
19223                startProfilerTimer(completedWork);
19224                next = completeWork(current2, completedWork, subtreeRenderLanes);
19225                stopProfilerTimerIfRunningAndRecordDelta(completedWork, false);
19226              }
19227              resetCurrentFiber();
19228              if (next !== null) {
19229                workInProgress = next;
19230                return;
19231              }
19232            } else {
19233              var _next = unwindWork(current2, completedWork);
19234              if (_next !== null) {
19235                _next.flags &= HostEffectMask;
19236                workInProgress = _next;
19237                return;
19238              }
19239              if ((completedWork.mode & ProfileMode) !== NoMode) {
19240                stopProfilerTimerIfRunningAndRecordDelta(completedWork, false);
19241                var actualDuration = completedWork.actualDuration;
19242                var child = completedWork.child;
19243                while (child !== null) {
19244                  actualDuration += child.actualDuration;
19245                  child = child.sibling;
19246                }
19247                completedWork.actualDuration = actualDuration;
19248              }
19249              if (returnFiber !== null) {
19250                returnFiber.flags |= Incomplete;
19251                returnFiber.subtreeFlags = NoFlags;
19252                returnFiber.deletions = null;
19253              } else {
19254                workInProgressRootExitStatus = RootDidNotComplete;
19255                workInProgress = null;
19256                return;
19257              }
19258            }
19259            var siblingFiber = completedWork.sibling;
19260            if (siblingFiber !== null) {
19261              workInProgress = siblingFiber;
19262              return;
19263            }
19264            completedWork = returnFiber;
19265            workInProgress = completedWork;
19266          } while (completedWork !== null);
19267          if (workInProgressRootExitStatus === RootInProgress) {
19268            workInProgressRootExitStatus = RootCompleted;
19269          }
19270        }
19271        function commitRoot(root2, recoverableErrors, transitions) {
19272          var previousUpdateLanePriority = getCurrentUpdatePriority();
19273          var prevTransition = ReactCurrentBatchConfig$3.transition;
19274          try {
19275            ReactCurrentBatchConfig$3.transition = null;
19276            setCurrentUpdatePriority(DiscreteEventPriority);
19277            commitRootImpl(root2, recoverableErrors, transitions, previousUpdateLanePriority);
19278          } finally {
19279            ReactCurrentBatchConfig$3.transition = prevTransition;
19280            setCurrentUpdatePriority(previousUpdateLanePriority);
19281          }
19282          return null;
19283        }
19284        function commitRootImpl(root2, recoverableErrors, transitions, renderPriorityLevel) {
19285          do {
19286            flushPassiveEffects();
19287          } while (rootWithPendingPassiveEffects !== null);
19288          flushRenderPhaseStrictModeWarningsInDEV();
19289          if ((executionContext & (RenderContext | CommitContext)) !== NoContext) {
19290            throw new Error("Should not already be working.");
19291          }
19292          var finishedWork = root2.finishedWork;
19293          var lanes = root2.finishedLanes;
19294          {
19295            markCommitStarted(lanes);
19296          }
19297          if (finishedWork === null) {
19298            {
19299              markCommitStopped();
19300            }
19301            return null;
19302          } else {
19303            {
19304              if (lanes === NoLanes) {
19305                error("root.finishedLanes should not be empty during a commit. This is a bug in React.");
19306              }
19307            }
19308          }
19309          root2.finishedWork = null;
19310          root2.finishedLanes = NoLanes;
19311          if (finishedWork === root2.current) {
19312            throw new Error("Cannot commit the same tree as before. This error is likely caused by a bug in React. Please file an issue.");
19313          }
19314          root2.callbackNode = null;
19315          root2.callbackPriority = NoLane;
19316          var remainingLanes = mergeLanes(finishedWork.lanes, finishedWork.childLanes);
19317          markRootFinished(root2, remainingLanes);
19318          if (root2 === workInProgressRoot) {
19319            workInProgressRoot = null;
19320            workInProgress = null;
19321            workInProgressRootRenderLanes = NoLanes;
19322          }
19323          if ((finishedWork.subtreeFlags & PassiveMask) !== NoFlags || (finishedWork.flags & PassiveMask) !== NoFlags) {
19324            if (!rootDoesHavePassiveEffects) {
19325              rootDoesHavePassiveEffects = true;
19326              pendingPassiveTransitions = transitions;
19327              scheduleCallback$1(NormalPriority, function() {
19328                flushPassiveEffects();
19329                return null;
19330              });
19331            }
19332          }
19333          var subtreeHasEffects = (finishedWork.subtreeFlags & (BeforeMutationMask | MutationMask | LayoutMask | PassiveMask)) !== NoFlags;
19334          var rootHasEffect = (finishedWork.flags & (BeforeMutationMask | MutationMask | LayoutMask | PassiveMask)) !== NoFlags;
19335          if (subtreeHasEffects || rootHasEffect) {
19336            var prevTransition = ReactCurrentBatchConfig$3.transition;
19337            ReactCurrentBatchConfig$3.transition = null;
19338            var previousPriority = getCurrentUpdatePriority();
19339            setCurrentUpdatePriority(DiscreteEventPriority);
19340            var prevExecutionContext = executionContext;
19341            executionContext |= CommitContext;
19342            ReactCurrentOwner$2.current = null;
19343            var shouldFireAfterActiveInstanceBlur2 = commitBeforeMutationEffects(root2, finishedWork);
19344            {
19345              recordCommitTime();
19346            }
19347            commitMutationEffects(root2, finishedWork, lanes);
19348            resetAfterCommit(root2.containerInfo);
19349            root2.current = finishedWork;
19350            {
19351              markLayoutEffectsStarted(lanes);
19352            }
19353            commitLayoutEffects(finishedWork, root2, lanes);
19354            {
19355              markLayoutEffectsStopped();
19356            }
19357            requestPaint();
19358            executionContext = prevExecutionContext;
19359            setCurrentUpdatePriority(previousPriority);
19360            ReactCurrentBatchConfig$3.transition = prevTransition;
19361          } else {
19362            root2.current = finishedWork;
19363            {
19364              recordCommitTime();
19365            }
19366          }
19367          var rootDidHavePassiveEffects = rootDoesHavePassiveEffects;
19368          if (rootDoesHavePassiveEffects) {
19369            rootDoesHavePassiveEffects = false;
19370            rootWithPendingPassiveEffects = root2;
19371            pendingPassiveEffectsLanes = lanes;
19372          } else {
19373            {
19374              nestedPassiveUpdateCount = 0;
19375              rootWithPassiveNestedUpdates = null;
19376            }
19377          }
19378          remainingLanes = root2.pendingLanes;
19379          if (remainingLanes === NoLanes) {
19380            legacyErrorBoundariesThatAlreadyFailed = null;
19381          }
19382          {
19383            if (!rootDidHavePassiveEffects) {
19384              commitDoubleInvokeEffectsInDEV(root2.current, false);
19385            }
19386          }
19387          onCommitRoot(finishedWork.stateNode, renderPriorityLevel);
19388          {
19389            if (isDevToolsPresent) {
19390              root2.memoizedUpdaters.clear();
19391            }
19392          }
19393          {
19394            onCommitRoot$1();
19395          }
19396          ensureRootIsScheduled(root2, now());
19397          if (recoverableErrors !== null) {
19398            var onRecoverableError = root2.onRecoverableError;
19399            for (var i = 0; i < recoverableErrors.length; i++) {
19400              var recoverableError = recoverableErrors[i];
19401              var componentStack = recoverableError.stack;
19402              var digest = recoverableError.digest;
19403              onRecoverableError(recoverableError.value, {
19404                componentStack,
19405                digest
19406              });
19407            }
19408          }
19409          if (hasUncaughtError) {
19410            hasUncaughtError = false;
19411            var error$1 = firstUncaughtError;
19412            firstUncaughtError = null;
19413            throw error$1;
19414          }
19415          if (includesSomeLane(pendingPassiveEffectsLanes, SyncLane) && root2.tag !== LegacyRoot) {
19416            flushPassiveEffects();
19417          }
19418          remainingLanes = root2.pendingLanes;
19419          if (includesSomeLane(remainingLanes, SyncLane)) {
19420            {
19421              markNestedUpdateScheduled();
19422            }
19423            if (root2 === rootWithNestedUpdates) {
19424              nestedUpdateCount++;
19425            } else {
19426              nestedUpdateCount = 0;
19427              rootWithNestedUpdates = root2;
19428            }
19429          } else {
19430            nestedUpdateCount = 0;
19431          }
19432          flushSyncCallbacks();
19433          {
19434            markCommitStopped();
19435          }
19436          return null;
19437        }
19438        function flushPassiveEffects() {
19439          if (rootWithPendingPassiveEffects !== null) {
19440            var renderPriority = lanesToEventPriority(pendingPassiveEffectsLanes);
19441            var priority = lowerEventPriority(DefaultEventPriority, renderPriority);
19442            var prevTransition = ReactCurrentBatchConfig$3.transition;
19443            var previousPriority = getCurrentUpdatePriority();
19444            try {
19445              ReactCurrentBatchConfig$3.transition = null;
19446              setCurrentUpdatePriority(priority);
19447              return flushPassiveEffectsImpl();
19448            } finally {
19449              setCurrentUpdatePriority(previousPriority);
19450              ReactCurrentBatchConfig$3.transition = prevTransition;
19451            }
19452          }
19453          return false;
19454        }
19455        function enqueuePendingPassiveProfilerEffect(fiber) {
19456          {
19457            pendingPassiveProfilerEffects.push(fiber);
19458            if (!rootDoesHavePassiveEffects) {
19459              rootDoesHavePassiveEffects = true;
19460              scheduleCallback$1(NormalPriority, function() {
19461                flushPassiveEffects();
19462                return null;
19463              });
19464            }
19465          }
19466        }
19467        function flushPassiveEffectsImpl() {
19468          if (rootWithPendingPassiveEffects === null) {
19469            return false;
19470          }
19471          var transitions = pendingPassiveTransitions;
19472          pendingPassiveTransitions = null;
19473          var root2 = rootWithPendingPassiveEffects;
19474          var lanes = pendingPassiveEffectsLanes;
19475          rootWithPendingPassiveEffects = null;
19476          pendingPassiveEffectsLanes = NoLanes;
19477          if ((executionContext & (RenderContext | CommitContext)) !== NoContext) {
19478            throw new Error("Cannot flush passive effects while already rendering.");
19479          }
19480          {
19481            isFlushingPassiveEffects = true;
19482            didScheduleUpdateDuringPassiveEffects = false;
19483          }
19484          {
19485            markPassiveEffectsStarted(lanes);
19486          }
19487          var prevExecutionContext = executionContext;
19488          executionContext |= CommitContext;
19489          commitPassiveUnmountEffects(root2.current);
19490          commitPassiveMountEffects(root2, root2.current, lanes, transitions);
19491          {
19492            var profilerEffects = pendingPassiveProfilerEffects;
19493            pendingPassiveProfilerEffects = [];
19494            for (var i = 0; i < profilerEffects.length; i++) {
19495              var _fiber = profilerEffects[i];
19496              commitPassiveEffectDurations(root2, _fiber);
19497            }
19498          }
19499          {
19500            markPassiveEffectsStopped();
19501          }
19502          {
19503            commitDoubleInvokeEffectsInDEV(root2.current, true);
19504          }
19505          executionContext = prevExecutionContext;
19506          flushSyncCallbacks();
19507          {
19508            if (didScheduleUpdateDuringPassiveEffects) {
19509              if (root2 === rootWithPassiveNestedUpdates) {
19510                nestedPassiveUpdateCount++;
19511              } else {
19512                nestedPassiveUpdateCount = 0;
19513                rootWithPassiveNestedUpdates = root2;
19514              }
19515            } else {
19516              nestedPassiveUpdateCount = 0;
19517            }
19518            isFlushingPassiveEffects = false;
19519            didScheduleUpdateDuringPassiveEffects = false;
19520          }
19521          onPostCommitRoot(root2);
19522          {
19523            var stateNode = root2.current.stateNode;
19524            stateNode.effectDuration = 0;
19525            stateNode.passiveEffectDuration = 0;
19526          }
19527          return true;
19528        }
19529        function isAlreadyFailedLegacyErrorBoundary(instance) {
19530          return legacyErrorBoundariesThatAlreadyFailed !== null && legacyErrorBoundariesThatAlreadyFailed.has(instance);
19531        }
19532        function markLegacyErrorBoundaryAsFailed(instance) {
19533          if (legacyErrorBoundariesThatAlreadyFailed === null) {
19534            legacyErrorBoundariesThatAlreadyFailed = /* @__PURE__ */ new Set([instance]);
19535          } else {
19536            legacyErrorBoundariesThatAlreadyFailed.add(instance);
19537          }
19538        }
19539        function prepareToThrowUncaughtError(error2) {
19540          if (!hasUncaughtError) {
19541            hasUncaughtError = true;
19542            firstUncaughtError = error2;
19543          }
19544        }
19545        var onUncaughtError = prepareToThrowUncaughtError;
19546        function captureCommitPhaseErrorOnRoot(rootFiber, sourceFiber, error2) {
19547          var errorInfo = createCapturedValueAtFiber(error2, sourceFiber);
19548          var update = createRootErrorUpdate(rootFiber, errorInfo, SyncLane);
19549          var root2 = enqueueUpdate(rootFiber, update, SyncLane);
19550          var eventTime = requestEventTime();
19551          if (root2 !== null) {
19552            markRootUpdated(root2, SyncLane, eventTime);
19553            ensureRootIsScheduled(root2, eventTime);
19554          }
19555        }
19556        function captureCommitPhaseError(sourceFiber, nearestMountedAncestor, error$1) {
19557          {
19558            reportUncaughtErrorInDEV(error$1);
19559            setIsRunningInsertionEffect(false);
19560          }
19561          if (sourceFiber.tag === HostRoot) {
19562            captureCommitPhaseErrorOnRoot(sourceFiber, sourceFiber, error$1);
19563            return;
19564          }
19565          var fiber = null;
19566          {
19567            fiber = nearestMountedAncestor;
19568          }
19569          while (fiber !== null) {
19570            if (fiber.tag === HostRoot) {
19571              captureCommitPhaseErrorOnRoot(fiber, sourceFiber, error$1);
19572              return;
19573            } else if (fiber.tag === ClassComponent) {
19574              var ctor = fiber.type;
19575              var instance = fiber.stateNode;
19576              if (typeof ctor.getDerivedStateFromError === "function" || typeof instance.componentDidCatch === "function" && !isAlreadyFailedLegacyErrorBoundary(instance)) {
19577                var errorInfo = createCapturedValueAtFiber(error$1, sourceFiber);
19578                var update = createClassErrorUpdate(fiber, errorInfo, SyncLane);
19579                var root2 = enqueueUpdate(fiber, update, SyncLane);
19580                var eventTime = requestEventTime();
19581                if (root2 !== null) {
19582                  markRootUpdated(root2, SyncLane, eventTime);
19583                  ensureRootIsScheduled(root2, eventTime);
19584                }
19585                return;
19586              }
19587            }
19588            fiber = fiber.return;
19589          }
19590          {
19591            error("Internal React error: Attempted to capture a commit phase error inside a detached tree. This indicates a bug in React. Likely causes include deleting the same fiber more than once, committing an already-finished tree, or an inconsistent return pointer.\n\nError message:\n\n%s", error$1);
19592          }
19593        }
19594        function pingSuspendedRoot(root2, wakeable, pingedLanes) {
19595          var pingCache = root2.pingCache;
19596          if (pingCache !== null) {
19597            pingCache.delete(wakeable);
19598          }
19599          var eventTime = requestEventTime();
19600          markRootPinged(root2, pingedLanes);
19601          warnIfSuspenseResolutionNotWrappedWithActDEV(root2);
19602          if (workInProgressRoot === root2 && isSubsetOfLanes(workInProgressRootRenderLanes, pingedLanes)) {
19603            if (workInProgressRootExitStatus === RootSuspendedWithDelay || workInProgressRootExitStatus === RootSuspended && includesOnlyRetries(workInProgressRootRenderLanes) && now() - globalMostRecentFallbackTime < FALLBACK_THROTTLE_MS) {
19604              prepareFreshStack(root2, NoLanes);
19605            } else {
19606              workInProgressRootPingedLanes = mergeLanes(workInProgressRootPingedLanes, pingedLanes);
19607            }
19608          }
19609          ensureRootIsScheduled(root2, eventTime);
19610        }
19611        function retryTimedOutBoundary(boundaryFiber, retryLane) {
19612          if (retryLane === NoLane) {
19613            retryLane = requestRetryLane(boundaryFiber);
19614          }
19615          var eventTime = requestEventTime();
19616          var root2 = enqueueConcurrentRenderForLane(boundaryFiber, retryLane);
19617          if (root2 !== null) {
19618            markRootUpdated(root2, retryLane, eventTime);
19619            ensureRootIsScheduled(root2, eventTime);
19620          }
19621        }
19622        function retryDehydratedSuspenseBoundary(boundaryFiber) {
19623          var suspenseState = boundaryFiber.memoizedState;
19624          var retryLane = NoLane;
19625          if (suspenseState !== null) {
19626            retryLane = suspenseState.retryLane;
19627          }
19628          retryTimedOutBoundary(boundaryFiber, retryLane);
19629        }
19630        function resolveRetryWakeable(boundaryFiber, wakeable) {
19631          var retryLane = NoLane;
19632          var retryCache;
19633          switch (boundaryFiber.tag) {
19634            case SuspenseComponent:
19635              retryCache = boundaryFiber.stateNode;
19636              var suspenseState = boundaryFiber.memoizedState;
19637              if (suspenseState !== null) {
19638                retryLane = suspenseState.retryLane;
19639              }
19640              break;
19641            case SuspenseListComponent:
19642              retryCache = boundaryFiber.stateNode;
19643              break;
19644            default:
19645              throw new Error("Pinged unknown suspense boundary type. This is probably a bug in React.");
19646          }
19647          if (retryCache !== null) {
19648            retryCache.delete(wakeable);
19649          }
19650          retryTimedOutBoundary(boundaryFiber, retryLane);
19651        }
19652        function jnd(timeElapsed) {
19653          return timeElapsed < 120 ? 120 : timeElapsed < 480 ? 480 : timeElapsed < 1080 ? 1080 : timeElapsed < 1920 ? 1920 : timeElapsed < 3e3 ? 3e3 : timeElapsed < 4320 ? 4320 : ceil(timeElapsed / 1960) * 1960;
19654        }
19655        function checkForNestedUpdates() {
19656          if (nestedUpdateCount > NESTED_UPDATE_LIMIT) {
19657            nestedUpdateCount = 0;
19658            rootWithNestedUpdates = null;
19659            throw new Error("Maximum update depth exceeded. This can happen when a component repeatedly calls setState inside componentWillUpdate or componentDidUpdate. React limits the number of nested updates to prevent infinite loops.");
19660          }
19661          {
19662            if (nestedPassiveUpdateCount > NESTED_PASSIVE_UPDATE_LIMIT) {
19663              nestedPassiveUpdateCount = 0;
19664              rootWithPassiveNestedUpdates = null;
19665              error("Maximum update depth exceeded. This can happen when a component calls setState inside useEffect, but useEffect either doesn't have a dependency array, or one of the dependencies changes on every render.");
19666            }
19667          }
19668        }
19669        function flushRenderPhaseStrictModeWarningsInDEV() {
19670          {
19671            ReactStrictModeWarnings.flushLegacyContextWarning();
19672            {
19673              ReactStrictModeWarnings.flushPendingUnsafeLifecycleWarnings();
19674            }
19675          }
19676        }
19677        function commitDoubleInvokeEffectsInDEV(fiber, hasPassiveEffects) {
19678          {
19679            setCurrentFiber(fiber);
19680            invokeEffectsInDev(fiber, MountLayoutDev, invokeLayoutEffectUnmountInDEV);
19681            if (hasPassiveEffects) {
19682              invokeEffectsInDev(fiber, MountPassiveDev, invokePassiveEffectUnmountInDEV);
19683            }
19684            invokeEffectsInDev(fiber, MountLayoutDev, invokeLayoutEffectMountInDEV);
19685            if (hasPassiveEffects) {
19686              invokeEffectsInDev(fiber, MountPassiveDev, invokePassiveEffectMountInDEV);
19687            }
19688            resetCurrentFiber();
19689          }
19690        }
19691        function invokeEffectsInDev(firstChild, fiberFlags, invokeEffectFn) {
19692          {
19693            var current2 = firstChild;
19694            var subtreeRoot = null;
19695            while (current2 !== null) {
19696              var primarySubtreeFlag = current2.subtreeFlags & fiberFlags;
19697              if (current2 !== subtreeRoot && current2.child !== null && primarySubtreeFlag !== NoFlags) {
19698                current2 = current2.child;
19699              } else {
19700                if ((current2.flags & fiberFlags) !== NoFlags) {
19701                  invokeEffectFn(current2);
19702                }
19703                if (current2.sibling !== null) {
19704                  current2 = current2.sibling;
19705                } else {
19706                  current2 = subtreeRoot = current2.return;
19707                }
19708              }
19709            }
19710          }
19711        }
19712        var didWarnStateUpdateForNotYetMountedComponent = null;
19713        function warnAboutUpdateOnNotYetMountedFiberInDEV(fiber) {
19714          {
19715            if ((executionContext & RenderContext) !== NoContext) {
19716              return;
19717            }
19718            if (!(fiber.mode & ConcurrentMode)) {
19719              return;
19720            }
19721            var tag = fiber.tag;
19722            if (tag !== IndeterminateComponent && tag !== HostRoot && tag !== ClassComponent && tag !== FunctionComponent && tag !== ForwardRef && tag !== MemoComponent && tag !== SimpleMemoComponent) {
19723              return;
19724            }
19725            var componentName = getComponentNameFromFiber(fiber) || "ReactComponent";
19726            if (didWarnStateUpdateForNotYetMountedComponent !== null) {
19727              if (didWarnStateUpdateForNotYetMountedComponent.has(componentName)) {
19728                return;
19729              }
19730              didWarnStateUpdateForNotYetMountedComponent.add(componentName);
19731            } else {
19732              didWarnStateUpdateForNotYetMountedComponent = /* @__PURE__ */ new Set([componentName]);
19733            }
19734            var previousFiber = current;
19735            try {
19736              setCurrentFiber(fiber);
19737              error("Can't perform a React state update on a component that hasn't mounted yet. This indicates that you have a side-effect in your render function that asynchronously later calls tries to update the component. Move this work to useEffect instead.");
19738            } finally {
19739              if (previousFiber) {
19740                setCurrentFiber(fiber);
19741              } else {
19742                resetCurrentFiber();
19743              }
19744            }
19745          }
19746        }
19747        var beginWork$1;
19748        {
19749          var dummyFiber = null;
19750          beginWork$1 = function(current2, unitOfWork, lanes) {
19751            var originalWorkInProgressCopy = assignFiberPropertiesInDEV(dummyFiber, unitOfWork);
19752            try {
19753              return beginWork(current2, unitOfWork, lanes);
19754            } catch (originalError) {
19755              if (didSuspendOrErrorWhileHydratingDEV() || originalError !== null && typeof originalError === "object" && typeof originalError.then === "function") {
19756                throw originalError;
19757              }
19758              resetContextDependencies();
19759              resetHooksAfterThrow();
19760              unwindInterruptedWork(current2, unitOfWork);
19761              assignFiberPropertiesInDEV(unitOfWork, originalWorkInProgressCopy);
19762              if (unitOfWork.mode & ProfileMode) {
19763                startProfilerTimer(unitOfWork);
19764              }
19765              invokeGuardedCallback(null, beginWork, null, current2, unitOfWork, lanes);
19766              if (hasCaughtError()) {
19767                var replayError = clearCaughtError();
19768                if (typeof replayError === "object" && replayError !== null && replayError._suppressLogging && typeof originalError === "object" && originalError !== null && !originalError._suppressLogging) {
19769                  originalError._suppressLogging = true;
19770                }
19771              }
19772              throw originalError;
19773            }
19774          };
19775        }
19776        var didWarnAboutUpdateInRender = false;
19777        var didWarnAboutUpdateInRenderForAnotherComponent;
19778        {
19779          didWarnAboutUpdateInRenderForAnotherComponent = /* @__PURE__ */ new Set();
19780        }
19781        function warnAboutRenderPhaseUpdatesInDEV(fiber) {
19782          {
19783            if (isRendering && !getIsUpdatingOpaqueValueInRenderPhaseInDEV()) {
19784              switch (fiber.tag) {
19785                case FunctionComponent:
19786                case ForwardRef:
19787                case SimpleMemoComponent: {
19788                  var renderingComponentName = workInProgress && getComponentNameFromFiber(workInProgress) || "Unknown";
19789                  var dedupeKey = renderingComponentName;
19790                  if (!didWarnAboutUpdateInRenderForAnotherComponent.has(dedupeKey)) {
19791                    didWarnAboutUpdateInRenderForAnotherComponent.add(dedupeKey);
19792                    var setStateComponentName = getComponentNameFromFiber(fiber) || "Unknown";
19793                    error("Cannot update a component (`%s`) while rendering a different component (`%s`). To locate the bad setState() call inside `%s`, follow the stack trace as described in https://reactjs.org/link/setstate-in-render", setStateComponentName, renderingComponentName, renderingComponentName);
19794                  }
19795                  break;
19796                }
19797                case ClassComponent: {
19798                  if (!didWarnAboutUpdateInRender) {
19799                    error("Cannot update during an existing state transition (such as within `render`). Render methods should be a pure function of props and state.");
19800                    didWarnAboutUpdateInRender = true;
19801                  }
19802                  break;
19803                }
19804              }
19805            }
19806          }
19807        }
19808        function restorePendingUpdaters(root2, lanes) {
19809          {
19810            if (isDevToolsPresent) {
19811              var memoizedUpdaters = root2.memoizedUpdaters;
19812              memoizedUpdaters.forEach(function(schedulingFiber) {
19813                addFiberToLanesMap(root2, schedulingFiber, lanes);
19814              });
19815            }
19816          }
19817        }
19818        var fakeActCallbackNode = {};
19819        function scheduleCallback$1(priorityLevel, callback) {
19820          {
19821            var actQueue = ReactCurrentActQueue$1.current;
19822            if (actQueue !== null) {
19823              actQueue.push(callback);
19824              return fakeActCallbackNode;
19825            } else {
19826              return scheduleCallback(priorityLevel, callback);
19827            }
19828          }
19829        }
19830        function cancelCallback$1(callbackNode) {
19831          if (callbackNode === fakeActCallbackNode) {
19832            return;
19833          }
19834          return cancelCallback(callbackNode);
19835        }
19836        function shouldForceFlushFallbacksInDEV() {
19837          return ReactCurrentActQueue$1.current !== null;
19838        }
19839        function warnIfUpdatesNotWrappedWithActDEV(fiber) {
19840          {
19841            if (fiber.mode & ConcurrentMode) {
19842              if (!isConcurrentActEnvironment()) {
19843                return;
19844              }
19845            } else {
19846              if (!isLegacyActEnvironment()) {
19847                return;
19848              }
19849              if (executionContext !== NoContext) {
19850                return;
19851              }
19852              if (fiber.tag !== FunctionComponent && fiber.tag !== ForwardRef && fiber.tag !== SimpleMemoComponent) {
19853                return;
19854              }
19855            }
19856            if (ReactCurrentActQueue$1.current === null) {
19857              var previousFiber = current;
19858              try {
19859                setCurrentFiber(fiber);
19860                error("An update to %s inside a test was not wrapped in act(...).\n\nWhen testing, code that causes React state updates should be wrapped into act(...):\n\nact(() => {\n  /* fire events that update state */\n});\n/* assert on the output */\n\nThis ensures that you're testing the behavior the user would see in the browser. Learn more at https://reactjs.org/link/wrap-tests-with-act", getComponentNameFromFiber(fiber));
19861              } finally {
19862                if (previousFiber) {
19863                  setCurrentFiber(fiber);
19864                } else {
19865                  resetCurrentFiber();
19866                }
19867              }
19868            }
19869          }
19870        }
19871        function warnIfSuspenseResolutionNotWrappedWithActDEV(root2) {
19872          {
19873            if (root2.tag !== LegacyRoot && isConcurrentActEnvironment() && ReactCurrentActQueue$1.current === null) {
19874              error("A suspended resource finished loading inside a test, but the event was not wrapped in act(...).\n\nWhen testing, code that resolves suspended data should be wrapped into act(...):\n\nact(() => {\n  /* finish loading suspended data */\n});\n/* assert on the output */\n\nThis ensures that you're testing the behavior the user would see in the browser. Learn more at https://reactjs.org/link/wrap-tests-with-act");
19875            }
19876          }
19877        }
19878        function setIsRunningInsertionEffect(isRunning) {
19879          {
19880            isRunningInsertionEffect = isRunning;
19881          }
19882        }
19883        var resolveFamily = null;
19884        var failedBoundaries = null;
19885        var setRefreshHandler = function(handler) {
19886          {
19887            resolveFamily = handler;
19888          }
19889        };
19890        function resolveFunctionForHotReloading(type) {
19891          {
19892            if (resolveFamily === null) {
19893              return type;
19894            }
19895            var family = resolveFamily(type);
19896            if (family === void 0) {
19897              return type;
19898            }
19899            return family.current;
19900          }
19901        }
19902        function resolveClassForHotReloading(type) {
19903          return resolveFunctionForHotReloading(type);
19904        }
19905        function resolveForwardRefForHotReloading(type) {
19906          {
19907            if (resolveFamily === null) {
19908              return type;
19909            }
19910            var family = resolveFamily(type);
19911            if (family === void 0) {
19912              if (type !== null && type !== void 0 && typeof type.render === "function") {
19913                var currentRender = resolveFunctionForHotReloading(type.render);
19914                if (type.render !== currentRender) {
19915                  var syntheticType = {
19916                    $$typeof: REACT_FORWARD_REF_TYPE,
19917                    render: currentRender
19918                  };
19919                  if (type.displayName !== void 0) {
19920                    syntheticType.displayName = type.displayName;
19921                  }
19922                  return syntheticType;
19923                }
19924              }
19925              return type;
19926            }
19927            return family.current;
19928          }
19929        }
19930        function isCompatibleFamilyForHotReloading(fiber, element) {
19931          {
19932            if (resolveFamily === null) {
19933              return false;
19934            }
19935            var prevType = fiber.elementType;
19936            var nextType = element.type;
19937            var needsCompareFamilies = false;
19938            var $$typeofNextType = typeof nextType === "object" && nextType !== null ? nextType.$$typeof : null;
19939            switch (fiber.tag) {
19940              case ClassComponent: {
19941                if (typeof nextType === "function") {
19942                  needsCompareFamilies = true;
19943                }
19944                break;
19945              }
19946              case FunctionComponent: {
19947                if (typeof nextType === "function") {
19948                  needsCompareFamilies = true;
19949                } else if ($$typeofNextType === REACT_LAZY_TYPE) {
19950                  needsCompareFamilies = true;
19951                }
19952                break;
19953              }
19954              case ForwardRef: {
19955                if ($$typeofNextType === REACT_FORWARD_REF_TYPE) {
19956                  needsCompareFamilies = true;
19957                } else if ($$typeofNextType === REACT_LAZY_TYPE) {
19958                  needsCompareFamilies = true;
19959                }
19960                break;
19961              }
19962              case MemoComponent:
19963              case SimpleMemoComponent: {
19964                if ($$typeofNextType === REACT_MEMO_TYPE) {
19965                  needsCompareFamilies = true;
19966                } else if ($$typeofNextType === REACT_LAZY_TYPE) {
19967                  needsCompareFamilies = true;
19968                }
19969                break;
19970              }
19971              default:
19972                return false;
19973            }
19974            if (needsCompareFamilies) {
19975              var prevFamily = resolveFamily(prevType);
19976              if (prevFamily !== void 0 && prevFamily === resolveFamily(nextType)) {
19977                return true;
19978              }
19979            }
19980            return false;
19981          }
19982        }
19983        function markFailedErrorBoundaryForHotReloading(fiber) {
19984          {
19985            if (resolveFamily === null) {
19986              return;
19987            }
19988            if (typeof WeakSet !== "function") {
19989              return;
19990            }
19991            if (failedBoundaries === null) {
19992              failedBoundaries = /* @__PURE__ */ new WeakSet();
19993            }
19994            failedBoundaries.add(fiber);
19995          }
19996        }
19997        var scheduleRefresh = function(root2, update) {
19998          {
19999            if (resolveFamily === null) {
20000              return;
20001            }
20002            var staleFamilies = update.staleFamilies, updatedFamilies = update.updatedFamilies;
20003            flushPassiveEffects();
20004            flushSync(function() {
20005              scheduleFibersWithFamiliesRecursively(root2.current, updatedFamilies, staleFamilies);
20006            });
20007          }
20008        };
20009        var scheduleRoot = function(root2, element) {
20010          {
20011            if (root2.context !== emptyContextObject) {
20012              return;
20013            }
20014            flushPassiveEffects();
20015            flushSync(function() {
20016              updateContainer(element, root2, null, null);
20017            });
20018          }
20019        };
20020        function scheduleFibersWithFamiliesRecursively(fiber, updatedFamilies, staleFamilies) {
20021          {
20022            var alternate = fiber.alternate, child = fiber.child, sibling = fiber.sibling, tag = fiber.tag, type = fiber.type;
20023            var candidateType = null;
20024            switch (tag) {
20025              case FunctionComponent:
20026              case SimpleMemoComponent:
20027              case ClassComponent:
20028                candidateType = type;
20029                break;
20030              case ForwardRef:
20031                candidateType = type.render;
20032                break;
20033            }
20034            if (resolveFamily === null) {
20035              throw new Error("Expected resolveFamily to be set during hot reload.");
20036            }
20037            var needsRender = false;
20038            var needsRemount = false;
20039            if (candidateType !== null) {
20040              var family = resolveFamily(candidateType);
20041              if (family !== void 0) {
20042                if (staleFamilies.has(family)) {
20043                  needsRemount = true;
20044                } else if (updatedFamilies.has(family)) {
20045                  if (tag === ClassComponent) {
20046                    needsRemount = true;
20047                  } else {
20048                    needsRender = true;
20049                  }
20050                }
20051              }
20052            }
20053            if (failedBoundaries !== null) {
20054              if (failedBoundaries.has(fiber) || alternate !== null && failedBoundaries.has(alternate)) {
20055                needsRemount = true;
20056              }
20057            }
20058            if (needsRemount) {
20059              fiber._debugNeedsRemount = true;
20060            }
20061            if (needsRemount || needsRender) {
20062              var _root = enqueueConcurrentRenderForLane(fiber, SyncLane);
20063              if (_root !== null) {
20064                scheduleUpdateOnFiber(_root, fiber, SyncLane, NoTimestamp);
20065              }
20066            }
20067            if (child !== null && !needsRemount) {
20068              scheduleFibersWithFamiliesRecursively(child, updatedFamilies, staleFamilies);
20069            }
20070            if (sibling !== null) {
20071              scheduleFibersWithFamiliesRecursively(sibling, updatedFamilies, staleFamilies);
20072            }
20073          }
20074        }
20075        var findHostInstancesForRefresh = function(root2, families) {
20076          {
20077            var hostInstances = /* @__PURE__ */ new Set();
20078            var types = new Set(families.map(function(family) {
20079              return family.current;
20080            }));
20081            findHostInstancesForMatchingFibersRecursively(root2.current, types, hostInstances);
20082            return hostInstances;
20083          }
20084        };
20085        function findHostInstancesForMatchingFibersRecursively(fiber, types, hostInstances) {
20086          {
20087            var child = fiber.child, sibling = fiber.sibling, tag = fiber.tag, type = fiber.type;
20088            var candidateType = null;
20089            switch (tag) {
20090              case FunctionComponent:
20091              case SimpleMemoComponent:
20092              case ClassComponent:
20093                candidateType = type;
20094                break;
20095              case ForwardRef:
20096                candidateType = type.render;
20097                break;
20098            }
20099            var didMatch = false;
20100            if (candidateType !== null) {
20101              if (types.has(candidateType)) {
20102                didMatch = true;
20103              }
20104            }
20105            if (didMatch) {
20106              findHostInstancesForFiberShallowly(fiber, hostInstances);
20107            } else {
20108              if (child !== null) {
20109                findHostInstancesForMatchingFibersRecursively(child, types, hostInstances);
20110              }
20111            }
20112            if (sibling !== null) {
20113              findHostInstancesForMatchingFibersRecursively(sibling, types, hostInstances);
20114            }
20115          }
20116        }
20117        function findHostInstancesForFiberShallowly(fiber, hostInstances) {
20118          {
20119            var foundHostInstances = findChildHostInstancesForFiberShallowly(fiber, hostInstances);
20120            if (foundHostInstances) {
20121              return;
20122            }
20123            var node = fiber;
20124            while (true) {
20125              switch (node.tag) {
20126                case HostComponent:
20127                  hostInstances.add(node.stateNode);
20128                  return;
20129                case HostPortal:
20130                  hostInstances.add(node.stateNode.containerInfo);
20131                  return;
20132                case HostRoot:
20133                  hostInstances.add(node.stateNode.containerInfo);
20134                  return;
20135              }
20136              if (node.return === null) {
20137                throw new Error("Expected to reach root first.");
20138              }
20139              node = node.return;
20140            }
20141          }
20142        }
20143        function findChildHostInstancesForFiberShallowly(fiber, hostInstances) {
20144          {
20145            var node = fiber;
20146            var foundHostInstances = false;
20147            while (true) {
20148              if (node.tag === HostComponent) {
20149                foundHostInstances = true;
20150                hostInstances.add(node.stateNode);
20151              } else if (node.child !== null) {
20152                node.child.return = node;
20153                node = node.child;
20154                continue;
20155              }
20156              if (node === fiber) {
20157                return foundHostInstances;
20158              }
20159              while (node.sibling === null) {
20160                if (node.return === null || node.return === fiber) {
20161                  return foundHostInstances;
20162                }
20163                node = node.return;
20164              }
20165              node.sibling.return = node.return;
20166              node = node.sibling;
20167            }
20168          }
20169          return false;
20170        }
20171        var hasBadMapPolyfill;
20172        {
20173          hasBadMapPolyfill = false;
20174          try {
20175            var nonExtensibleObject = Object.preventExtensions({});
20176            /* @__PURE__ */ new Map([[nonExtensibleObject, null]]);
20177            /* @__PURE__ */ new Set([nonExtensibleObject]);
20178          } catch (e) {
20179            hasBadMapPolyfill = true;
20180          }
20181        }
20182        function FiberNode(tag, pendingProps, key, mode) {
20183          this.tag = tag;
20184          this.key = key;
20185          this.elementType = null;
20186          this.type = null;
20187          this.stateNode = null;
20188          this.return = null;
20189          this.child = null;
20190          this.sibling = null;
20191          this.index = 0;
20192          this.ref = null;
20193          this.pendingProps = pendingProps;
20194          this.memoizedProps = null;
20195          this.updateQueue = null;
20196          this.memoizedState = null;
20197          this.dependencies = null;
20198          this.mode = mode;
20199          this.flags = NoFlags;
20200          this.subtreeFlags = NoFlags;
20201          this.deletions = null;
20202          this.lanes = NoLanes;
20203          this.childLanes = NoLanes;
20204          this.alternate = null;
20205          {
20206            this.actualDuration = Number.NaN;
20207            this.actualStartTime = Number.NaN;
20208            this.selfBaseDuration = Number.NaN;
20209            this.treeBaseDuration = Number.NaN;
20210            this.actualDuration = 0;
20211            this.actualStartTime = -1;
20212            this.selfBaseDuration = 0;
20213            this.treeBaseDuration = 0;
20214          }
20215          {
20216            this._debugSource = null;
20217            this._debugOwner = null;
20218            this._debugNeedsRemount = false;
20219            this._debugHookTypes = null;
20220            if (!hasBadMapPolyfill && typeof Object.preventExtensions === "function") {
20221              Object.preventExtensions(this);
20222            }
20223          }
20224        }
20225        var createFiber = function(tag, pendingProps, key, mode) {
20226          return new FiberNode(tag, pendingProps, key, mode);
20227        };
20228        function shouldConstruct$1(Component) {
20229          var prototype = Component.prototype;
20230          return !!(prototype && prototype.isReactComponent);
20231        }
20232        function isSimpleFunctionComponent(type) {
20233          return typeof type === "function" && !shouldConstruct$1(type) && type.defaultProps === void 0;
20234        }
20235        function resolveLazyComponentTag(Component) {
20236          if (typeof Component === "function") {
20237            return shouldConstruct$1(Component) ? ClassComponent : FunctionComponent;
20238          } else if (Component !== void 0 && Component !== null) {
20239            var $$typeof = Component.$$typeof;
20240            if ($$typeof === REACT_FORWARD_REF_TYPE) {
20241              return ForwardRef;
20242            }
20243            if ($$typeof === REACT_MEMO_TYPE) {
20244              return MemoComponent;
20245            }
20246          }
20247          return IndeterminateComponent;
20248        }
20249        function createWorkInProgress(current2, pendingProps) {
20250          var workInProgress2 = current2.alternate;
20251          if (workInProgress2 === null) {
20252            workInProgress2 = createFiber(current2.tag, pendingProps, current2.key, current2.mode);
20253            workInProgress2.elementType = current2.elementType;
20254            workInProgress2.type = current2.type;
20255            workInProgress2.stateNode = current2.stateNode;
20256            {
20257              workInProgress2._debugSource = current2._debugSource;
20258              workInProgress2._debugOwner = current2._debugOwner;
20259              workInProgress2._debugHookTypes = current2._debugHookTypes;
20260            }
20261            workInProgress2.alternate = current2;
20262            current2.alternate = workInProgress2;
20263          } else {
20264            workInProgress2.pendingProps = pendingProps;
20265            workInProgress2.type = current2.type;
20266            workInProgress2.flags = NoFlags;
20267            workInProgress2.subtreeFlags = NoFlags;
20268            workInProgress2.deletions = null;
20269            {
20270              workInProgress2.actualDuration = 0;
20271              workInProgress2.actualStartTime = -1;
20272            }
20273          }
20274          workInProgress2.flags = current2.flags & StaticMask;
20275          workInProgress2.childLanes = current2.childLanes;
20276          workInProgress2.lanes = current2.lanes;
20277          workInProgress2.child = current2.child;
20278          workInProgress2.memoizedProps = current2.memoizedProps;
20279          workInProgress2.memoizedState = current2.memoizedState;
20280          workInProgress2.updateQueue = current2.updateQueue;
20281          var currentDependencies = current2.dependencies;
20282          workInProgress2.dependencies = currentDependencies === null ? null : {
20283            lanes: currentDependencies.lanes,
20284            firstContext: currentDependencies.firstContext
20285          };
20286          workInProgress2.sibling = current2.sibling;
20287          workInProgress2.index = current2.index;
20288          workInProgress2.ref = current2.ref;
20289          {
20290            workInProgress2.selfBaseDuration = current2.selfBaseDuration;
20291            workInProgress2.treeBaseDuration = current2.treeBaseDuration;
20292          }
20293          {
20294            workInProgress2._debugNeedsRemount = current2._debugNeedsRemount;
20295            switch (workInProgress2.tag) {
20296              case IndeterminateComponent:
20297              case FunctionComponent:
20298              case SimpleMemoComponent:
20299                workInProgress2.type = resolveFunctionForHotReloading(current2.type);
20300                break;
20301              case ClassComponent:
20302                workInProgress2.type = resolveClassForHotReloading(current2.type);
20303                break;
20304              case ForwardRef:
20305                workInProgress2.type = resolveForwardRefForHotReloading(current2.type);
20306                break;
20307            }
20308          }
20309          return workInProgress2;
20310        }
20311        function resetWorkInProgress(workInProgress2, renderLanes2) {
20312          workInProgress2.flags &= StaticMask | Placement;
20313          var current2 = workInProgress2.alternate;
20314          if (current2 === null) {
20315            workInProgress2.childLanes = NoLanes;
20316            workInProgress2.lanes = renderLanes2;
20317            workInProgress2.child = null;
20318            workInProgress2.subtreeFlags = NoFlags;
20319            workInProgress2.memoizedProps = null;
20320            workInProgress2.memoizedState = null;
20321            workInProgress2.updateQueue = null;
20322            workInProgress2.dependencies = null;
20323            workInProgress2.stateNode = null;
20324            {
20325              workInProgress2.selfBaseDuration = 0;
20326              workInProgress2.treeBaseDuration = 0;
20327            }
20328          } else {
20329            workInProgress2.childLanes = current2.childLanes;
20330            workInProgress2.lanes = current2.lanes;
20331            workInProgress2.child = current2.child;
20332            workInProgress2.subtreeFlags = NoFlags;
20333            workInProgress2.deletions = null;
20334            workInProgress2.memoizedProps = current2.memoizedProps;
20335            workInProgress2.memoizedState = current2.memoizedState;
20336            workInProgress2.updateQueue = current2.updateQueue;
20337            workInProgress2.type = current2.type;
20338            var currentDependencies = current2.dependencies;
20339            workInProgress2.dependencies = currentDependencies === null ? null : {
20340              lanes: currentDependencies.lanes,
20341              firstContext: currentDependencies.firstContext
20342            };
20343            {
20344              workInProgress2.selfBaseDuration = current2.selfBaseDuration;
20345              workInProgress2.treeBaseDuration = current2.treeBaseDuration;
20346            }
20347          }
20348          return workInProgress2;
20349        }
20350        function createHostRootFiber(tag, isStrictMode, concurrentUpdatesByDefaultOverride) {
20351          var mode;
20352          if (tag === ConcurrentRoot) {
20353            mode = ConcurrentMode;
20354            if (isStrictMode === true) {
20355              mode |= StrictLegacyMode;
20356              {
20357                mode |= StrictEffectsMode;
20358              }
20359            }
20360          } else {
20361            mode = NoMode;
20362          }
20363          if (isDevToolsPresent) {
20364            mode |= ProfileMode;
20365          }
20366          return createFiber(HostRoot, null, null, mode);
20367        }
20368        function createFiberFromTypeAndProps(type, key, pendingProps, owner, mode, lanes) {
20369          var fiberTag = IndeterminateComponent;
20370          var resolvedType = type;
20371          if (typeof type === "function") {
20372            if (shouldConstruct$1(type)) {
20373              fiberTag = ClassComponent;
20374              {
20375                resolvedType = resolveClassForHotReloading(resolvedType);
20376              }
20377            } else {
20378              {
20379                resolvedType = resolveFunctionForHotReloading(resolvedType);
20380              }
20381            }
20382          } else if (typeof type === "string") {
20383            fiberTag = HostComponent;
20384          } else {
20385            getTag: switch (type) {
20386              case REACT_FRAGMENT_TYPE:
20387                return createFiberFromFragment(pendingProps.children, mode, lanes, key);
20388              case REACT_STRICT_MODE_TYPE:
20389                fiberTag = Mode;
20390                mode |= StrictLegacyMode;
20391                if ((mode & ConcurrentMode) !== NoMode) {
20392                  mode |= StrictEffectsMode;
20393                }
20394                break;
20395              case REACT_PROFILER_TYPE:
20396                return createFiberFromProfiler(pendingProps, mode, lanes, key);
20397              case REACT_SUSPENSE_TYPE:
20398                return createFiberFromSuspense(pendingProps, mode, lanes, key);
20399              case REACT_SUSPENSE_LIST_TYPE:
20400                return createFiberFromSuspenseList(pendingProps, mode, lanes, key);
20401              case REACT_OFFSCREEN_TYPE:
20402                return createFiberFromOffscreen(pendingProps, mode, lanes, key);
20403              case REACT_LEGACY_HIDDEN_TYPE:
20404              case REACT_SCOPE_TYPE:
20405              case REACT_CACHE_TYPE:
20406              case REACT_TRACING_MARKER_TYPE:
20407              case REACT_DEBUG_TRACING_MODE_TYPE:
20408              default: {
20409                if (typeof type === "object" && type !== null) {
20410                  switch (type.$$typeof) {
20411                    case REACT_PROVIDER_TYPE:
20412                      fiberTag = ContextProvider;
20413                      break getTag;
20414                    case REACT_CONTEXT_TYPE:
20415                      fiberTag = ContextConsumer;
20416                      break getTag;
20417                    case REACT_FORWARD_REF_TYPE:
20418                      fiberTag = ForwardRef;
20419                      {
20420                        resolvedType = resolveForwardRefForHotReloading(resolvedType);
20421                      }
20422                      break getTag;
20423                    case REACT_MEMO_TYPE:
20424                      fiberTag = MemoComponent;
20425                      break getTag;
20426                    case REACT_LAZY_TYPE:
20427                      fiberTag = LazyComponent;
20428                      resolvedType = null;
20429                      break getTag;
20430                  }
20431                }
20432                var info = "";
20433                {
20434                  if (type === void 0 || typeof type === "object" && type !== null && Object.keys(type).length === 0) {
20435                    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.";
20436                  }
20437                  var ownerName = owner ? getComponentNameFromFiber(owner) : null;
20438                  if (ownerName) {
20439                    info += "\n\nCheck the render method of `" + ownerName + "`.";
20440                  }
20441                }
20442                throw new Error("Element type is invalid: expected a string (for built-in components) or a class/function (for composite components) " + ("but got: " + (type == null ? type : typeof type) + "." + info));
20443              }
20444            }
20445          }
20446          var fiber = createFiber(fiberTag, pendingProps, key, mode);
20447          fiber.elementType = type;
20448          fiber.type = resolvedType;
20449          fiber.lanes = lanes;
20450          {
20451            fiber._debugOwner = owner;
20452          }
20453          return fiber;
20454        }
20455        function createFiberFromElement(element, mode, lanes) {
20456          var owner = null;
20457          {
20458            owner = element._owner;
20459          }
20460          var type = element.type;
20461          var key = element.key;
20462          var pendingProps = element.props;
20463          var fiber = createFiberFromTypeAndProps(type, key, pendingProps, owner, mode, lanes);
20464          {
20465            fiber._debugSource = element._source;
20466            fiber._debugOwner = element._owner;
20467          }
20468          return fiber;
20469        }
20470        function createFiberFromFragment(elements, mode, lanes, key) {
20471          var fiber = createFiber(Fragment, elements, key, mode);
20472          fiber.lanes = lanes;
20473          return fiber;
20474        }
20475        function createFiberFromProfiler(pendingProps, mode, lanes, key) {
20476          {
20477            if (typeof pendingProps.id !== "string") {
20478              error('Profiler must specify an "id" of type `string` as a prop. Received the type `%s` instead.', typeof pendingProps.id);
20479            }
20480          }
20481          var fiber = createFiber(Profiler, pendingProps, key, mode | ProfileMode);
20482          fiber.elementType = REACT_PROFILER_TYPE;
20483          fiber.lanes = lanes;
20484          {
20485            fiber.stateNode = {
20486              effectDuration: 0,
20487              passiveEffectDuration: 0
20488            };
20489          }
20490          return fiber;
20491        }
20492        function createFiberFromSuspense(pendingProps, mode, lanes, key) {
20493          var fiber = createFiber(SuspenseComponent, pendingProps, key, mode);
20494          fiber.elementType = REACT_SUSPENSE_TYPE;
20495          fiber.lanes = lanes;
20496          return fiber;
20497        }
20498        function createFiberFromSuspenseList(pendingProps, mode, lanes, key) {
20499          var fiber = createFiber(SuspenseListComponent, pendingProps, key, mode);
20500          fiber.elementType = REACT_SUSPENSE_LIST_TYPE;
20501          fiber.lanes = lanes;
20502          return fiber;
20503        }
20504        function createFiberFromOffscreen(pendingProps, mode, lanes, key) {
20505          var fiber = createFiber(OffscreenComponent, pendingProps, key, mode);
20506          fiber.elementType = REACT_OFFSCREEN_TYPE;
20507          fiber.lanes = lanes;
20508          var primaryChildInstance = {
20509            isHidden: false
20510          };
20511          fiber.stateNode = primaryChildInstance;
20512          return fiber;
20513        }
20514        function createFiberFromText(content, mode, lanes) {
20515          var fiber = createFiber(HostText, content, null, mode);
20516          fiber.lanes = lanes;
20517          return fiber;
20518        }
20519        function createFiberFromHostInstanceForDeletion() {
20520          var fiber = createFiber(HostComponent, null, null, NoMode);
20521          fiber.elementType = "DELETED";
20522          return fiber;
20523        }
20524        function createFiberFromDehydratedFragment(dehydratedNode) {
20525          var fiber = createFiber(DehydratedFragment, null, null, NoMode);
20526          fiber.stateNode = dehydratedNode;
20527          return fiber;
20528        }
20529        function createFiberFromPortal(portal, mode, lanes) {
20530          var pendingProps = portal.children !== null ? portal.children : [];
20531          var fiber = createFiber(HostPortal, pendingProps, portal.key, mode);
20532          fiber.lanes = lanes;
20533          fiber.stateNode = {
20534            containerInfo: portal.containerInfo,
20535            pendingChildren: null,
20536            // Used by persistent updates
20537            implementation: portal.implementation
20538          };
20539          return fiber;
20540        }
20541        function assignFiberPropertiesInDEV(target, source) {
20542          if (target === null) {
20543            target = createFiber(IndeterminateComponent, null, null, NoMode);
20544          }
20545          target.tag = source.tag;
20546          target.key = source.key;
20547          target.elementType = source.elementType;
20548          target.type = source.type;
20549          target.stateNode = source.stateNode;
20550          target.return = source.return;
20551          target.child = source.child;
20552          target.sibling = source.sibling;
20553          target.index = source.index;
20554          target.ref = source.ref;
20555          target.pendingProps = source.pendingProps;
20556          target.memoizedProps = source.memoizedProps;
20557          target.updateQueue = source.updateQueue;
20558          target.memoizedState = source.memoizedState;
20559          target.dependencies = source.dependencies;
20560          target.mode = source.mode;
20561          target.flags = source.flags;
20562          target.subtreeFlags = source.subtreeFlags;
20563          target.deletions = source.deletions;
20564          target.lanes = source.lanes;
20565          target.childLanes = source.childLanes;
20566          target.alternate = source.alternate;
20567          {
20568            target.actualDuration = source.actualDuration;
20569            target.actualStartTime = source.actualStartTime;
20570            target.selfBaseDuration = source.selfBaseDuration;
20571            target.treeBaseDuration = source.treeBaseDuration;
20572          }
20573          target._debugSource = source._debugSource;
20574          target._debugOwner = source._debugOwner;
20575          target._debugNeedsRemount = source._debugNeedsRemount;
20576          target._debugHookTypes = source._debugHookTypes;
20577          return target;
20578        }
20579        function FiberRootNode(containerInfo, tag, hydrate2, identifierPrefix, onRecoverableError) {
20580          this.tag = tag;
20581          this.containerInfo = containerInfo;
20582          this.pendingChildren = null;
20583          this.current = null;
20584          this.pingCache = null;
20585          this.finishedWork = null;
20586          this.timeoutHandle = noTimeout;
20587          this.context = null;
20588          this.pendingContext = null;
20589          this.callbackNode = null;
20590          this.callbackPriority = NoLane;
20591          this.eventTimes = createLaneMap(NoLanes);
20592          this.expirationTimes = createLaneMap(NoTimestamp);
20593          this.pendingLanes = NoLanes;
20594          this.suspendedLanes = NoLanes;
20595          this.pingedLanes = NoLanes;
20596          this.expiredLanes = NoLanes;
20597          this.mutableReadLanes = NoLanes;
20598          this.finishedLanes = NoLanes;
20599          this.entangledLanes = NoLanes;
20600          this.entanglements = createLaneMap(NoLanes);
20601          this.identifierPrefix = identifierPrefix;
20602          this.onRecoverableError = onRecoverableError;
20603          {
20604            this.mutableSourceEagerHydrationData = null;
20605          }
20606          {
20607            this.effectDuration = 0;
20608            this.passiveEffectDuration = 0;
20609          }
20610          {
20611            this.memoizedUpdaters = /* @__PURE__ */ new Set();
20612            var pendingUpdatersLaneMap = this.pendingUpdatersLaneMap = [];
20613            for (var _i = 0; _i < TotalLanes; _i++) {
20614              pendingUpdatersLaneMap.push(/* @__PURE__ */ new Set());
20615            }
20616          }
20617          {
20618            switch (tag) {
20619              case ConcurrentRoot:
20620                this._debugRootType = hydrate2 ? "hydrateRoot()" : "createRoot()";
20621                break;
20622              case LegacyRoot:
20623                this._debugRootType = hydrate2 ? "hydrate()" : "render()";
20624                break;
20625            }
20626          }
20627        }
20628        function createFiberRoot(containerInfo, tag, hydrate2, initialChildren, hydrationCallbacks, isStrictMode, concurrentUpdatesByDefaultOverride, identifierPrefix, onRecoverableError, transitionCallbacks) {
20629          var root2 = new FiberRootNode(containerInfo, tag, hydrate2, identifierPrefix, onRecoverableError);
20630          var uninitializedFiber = createHostRootFiber(tag, isStrictMode);
20631          root2.current = uninitializedFiber;
20632          uninitializedFiber.stateNode = root2;
20633          {
20634            var _initialState = {
20635              element: initialChildren,
20636              isDehydrated: hydrate2,
20637              cache: null,
20638              // not enabled yet
20639              transitions: null,
20640              pendingSuspenseBoundaries: null
20641            };
20642            uninitializedFiber.memoizedState = _initialState;
20643          }
20644          initializeUpdateQueue(uninitializedFiber);
20645          return root2;
20646        }
20647        var ReactVersion = "18.3.1";
20648        function createPortal(children, containerInfo, implementation) {
20649          var key = arguments.length > 3 && arguments[3] !== void 0 ? arguments[3] : null;
20650          {
20651            checkKeyStringCoercion(key);
20652          }
20653          return {
20654            // This tag allow us to uniquely identify this as a React Portal
20655            $$typeof: REACT_PORTAL_TYPE,
20656            key: key == null ? null : "" + key,
20657            children,
20658            containerInfo,
20659            implementation
20660          };
20661        }
20662        var didWarnAboutNestedUpdates;
20663        var didWarnAboutFindNodeInStrictMode;
20664        {
20665          didWarnAboutNestedUpdates = false;
20666          didWarnAboutFindNodeInStrictMode = {};
20667        }
20668        function getContextForSubtree(parentComponent) {
20669          if (!parentComponent) {
20670            return emptyContextObject;
20671          }
20672          var fiber = get(parentComponent);
20673          var parentContext = findCurrentUnmaskedContext(fiber);
20674          if (fiber.tag === ClassComponent) {
20675            var Component = fiber.type;
20676            if (isContextProvider(Component)) {
20677              return processChildContext(fiber, Component, parentContext);
20678            }
20679          }
20680          return parentContext;
20681        }
20682        function findHostInstanceWithWarning(component, methodName) {
20683          {
20684            var fiber = get(component);
20685            if (fiber === void 0) {
20686              if (typeof component.render === "function") {
20687                throw new Error("Unable to find node on an unmounted component.");
20688              } else {
20689                var keys = Object.keys(component).join(",");
20690                throw new Error("Argument appears to not be a ReactComponent. Keys: " + keys);
20691              }
20692            }
20693            var hostFiber = findCurrentHostFiber(fiber);
20694            if (hostFiber === null) {
20695              return null;
20696            }
20697            if (hostFiber.mode & StrictLegacyMode) {
20698              var componentName = getComponentNameFromFiber(fiber) || "Component";
20699              if (!didWarnAboutFindNodeInStrictMode[componentName]) {
20700                didWarnAboutFindNodeInStrictMode[componentName] = true;
20701                var previousFiber = current;
20702                try {
20703                  setCurrentFiber(hostFiber);
20704                  if (fiber.mode & StrictLegacyMode) {
20705                    error("%s is deprecated in StrictMode. %s was passed an instance of %s which is inside StrictMode. Instead, add a ref directly to the element you want to reference. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-find-node", methodName, methodName, componentName);
20706                  } else {
20707                    error("%s is deprecated in StrictMode. %s was passed an instance of %s which renders StrictMode children. Instead, add a ref directly to the element you want to reference. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-find-node", methodName, methodName, componentName);
20708                  }
20709                } finally {
20710                  if (previousFiber) {
20711                    setCurrentFiber(previousFiber);
20712                  } else {
20713                    resetCurrentFiber();
20714                  }
20715                }
20716              }
20717            }
20718            return hostFiber.stateNode;
20719          }
20720        }
20721        function createContainer(containerInfo, tag, hydrationCallbacks, isStrictMode, concurrentUpdatesByDefaultOverride, identifierPrefix, onRecoverableError, transitionCallbacks) {
20722          var hydrate2 = false;
20723          var initialChildren = null;
20724          return createFiberRoot(containerInfo, tag, hydrate2, initialChildren, hydrationCallbacks, isStrictMode, concurrentUpdatesByDefaultOverride, identifierPrefix, onRecoverableError);
20725        }
20726        function createHydrationContainer(initialChildren, callback, containerInfo, tag, hydrationCallbacks, isStrictMode, concurrentUpdatesByDefaultOverride, identifierPrefix, onRecoverableError, transitionCallbacks) {
20727          var hydrate2 = true;
20728          var root2 = createFiberRoot(containerInfo, tag, hydrate2, initialChildren, hydrationCallbacks, isStrictMode, concurrentUpdatesByDefaultOverride, identifierPrefix, onRecoverableError);
20729          root2.context = getContextForSubtree(null);
20730          var current2 = root2.current;
20731          var eventTime = requestEventTime();
20732          var lane = requestUpdateLane(current2);
20733          var update = createUpdate(eventTime, lane);
20734          update.callback = callback !== void 0 && callback !== null ? callback : null;
20735          enqueueUpdate(current2, update, lane);
20736          scheduleInitialHydrationOnRoot(root2, lane, eventTime);
20737          return root2;
20738        }
20739        function updateContainer(element, container, parentComponent, callback) {
20740          {
20741            onScheduleRoot(container, element);
20742          }
20743          var current$1 = container.current;
20744          var eventTime = requestEventTime();
20745          var lane = requestUpdateLane(current$1);
20746          {
20747            markRenderScheduled(lane);
20748          }
20749          var context = getContextForSubtree(parentComponent);
20750          if (container.context === null) {
20751            container.context = context;
20752          } else {
20753            container.pendingContext = context;
20754          }
20755          {
20756            if (isRendering && current !== null && !didWarnAboutNestedUpdates) {
20757              didWarnAboutNestedUpdates = true;
20758              error("Render methods should be a pure function of props and state; triggering nested component updates from render is not allowed. If necessary, trigger nested updates in componentDidUpdate.\n\nCheck the render method of %s.", getComponentNameFromFiber(current) || "Unknown");
20759            }
20760          }
20761          var update = createUpdate(eventTime, lane);
20762          update.payload = {
20763            element
20764          };
20765          callback = callback === void 0 ? null : callback;
20766          if (callback !== null) {
20767            {
20768              if (typeof callback !== "function") {
20769                error("render(...): Expected the last optional `callback` argument to be a function. Instead received: %s.", callback);
20770              }
20771            }
20772            update.callback = callback;
20773          }
20774          var root2 = enqueueUpdate(current$1, update, lane);
20775          if (root2 !== null) {
20776            scheduleUpdateOnFiber(root2, current$1, lane, eventTime);
20777            entangleTransitions(root2, current$1, lane);
20778          }
20779          return lane;
20780        }
20781        function getPublicRootInstance(container) {
20782          var containerFiber = container.current;
20783          if (!containerFiber.child) {
20784            return null;
20785          }
20786          switch (containerFiber.child.tag) {
20787            case HostComponent:
20788              return getPublicInstance(containerFiber.child.stateNode);
20789            default:
20790              return containerFiber.child.stateNode;
20791          }
20792        }
20793        function attemptSynchronousHydration$1(fiber) {
20794          switch (fiber.tag) {
20795            case HostRoot: {
20796              var root2 = fiber.stateNode;
20797              if (isRootDehydrated(root2)) {
20798                var lanes = getHighestPriorityPendingLanes(root2);
20799                flushRoot(root2, lanes);
20800              }
20801              break;
20802            }
20803            case SuspenseComponent: {
20804              flushSync(function() {
20805                var root3 = enqueueConcurrentRenderForLane(fiber, SyncLane);
20806                if (root3 !== null) {
20807                  var eventTime = requestEventTime();
20808                  scheduleUpdateOnFiber(root3, fiber, SyncLane, eventTime);
20809                }
20810              });
20811              var retryLane = SyncLane;
20812              markRetryLaneIfNotHydrated(fiber, retryLane);
20813              break;
20814            }
20815          }
20816        }
20817        function markRetryLaneImpl(fiber, retryLane) {
20818          var suspenseState = fiber.memoizedState;
20819          if (suspenseState !== null && suspenseState.dehydrated !== null) {
20820            suspenseState.retryLane = higherPriorityLane(suspenseState.retryLane, retryLane);
20821          }
20822        }
20823        function markRetryLaneIfNotHydrated(fiber, retryLane) {
20824          markRetryLaneImpl(fiber, retryLane);
20825          var alternate = fiber.alternate;
20826          if (alternate) {
20827            markRetryLaneImpl(alternate, retryLane);
20828          }
20829        }
20830        function attemptContinuousHydration$1(fiber) {
20831          if (fiber.tag !== SuspenseComponent) {
20832            return;
20833          }
20834          var lane = SelectiveHydrationLane;
20835          var root2 = enqueueConcurrentRenderForLane(fiber, lane);
20836          if (root2 !== null) {
20837            var eventTime = requestEventTime();
20838            scheduleUpdateOnFiber(root2, fiber, lane, eventTime);
20839          }
20840          markRetryLaneIfNotHydrated(fiber, lane);
20841        }
20842        function attemptHydrationAtCurrentPriority$1(fiber) {
20843          if (fiber.tag !== SuspenseComponent) {
20844            return;
20845          }
20846          var lane = requestUpdateLane(fiber);
20847          var root2 = enqueueConcurrentRenderForLane(fiber, lane);
20848          if (root2 !== null) {
20849            var eventTime = requestEventTime();
20850            scheduleUpdateOnFiber(root2, fiber, lane, eventTime);
20851          }
20852          markRetryLaneIfNotHydrated(fiber, lane);
20853        }
20854        function findHostInstanceWithNoPortals(fiber) {
20855          var hostFiber = findCurrentHostFiberWithNoPortals(fiber);
20856          if (hostFiber === null) {
20857            return null;
20858          }
20859          return hostFiber.stateNode;
20860        }
20861        var shouldErrorImpl = function(fiber) {
20862          return null;
20863        };
20864        function shouldError(fiber) {
20865          return shouldErrorImpl(fiber);
20866        }
20867        var shouldSuspendImpl = function(fiber) {
20868          return false;
20869        };
20870        function shouldSuspend(fiber) {
20871          return shouldSuspendImpl(fiber);
20872        }
20873        var overrideHookState = null;
20874        var overrideHookStateDeletePath = null;
20875        var overrideHookStateRenamePath = null;
20876        var overrideProps = null;
20877        var overridePropsDeletePath = null;
20878        var overridePropsRenamePath = null;
20879        var scheduleUpdate = null;
20880        var setErrorHandler = null;
20881        var setSuspenseHandler = null;
20882        {
20883          var copyWithDeleteImpl = function(obj, path, index2) {
20884            var key = path[index2];
20885            var updated = isArray(obj) ? obj.slice() : assign({}, obj);
20886            if (index2 + 1 === path.length) {
20887              if (isArray(updated)) {
20888                updated.splice(key, 1);
20889              } else {
20890                delete updated[key];
20891              }
20892              return updated;
20893            }
20894            updated[key] = copyWithDeleteImpl(obj[key], path, index2 + 1);
20895            return updated;
20896          };
20897          var copyWithDelete = function(obj, path) {
20898            return copyWithDeleteImpl(obj, path, 0);
20899          };
20900          var copyWithRenameImpl = function(obj, oldPath, newPath, index2) {
20901            var oldKey = oldPath[index2];
20902            var updated = isArray(obj) ? obj.slice() : assign({}, obj);
20903            if (index2 + 1 === oldPath.length) {
20904              var newKey = newPath[index2];
20905              updated[newKey] = updated[oldKey];
20906              if (isArray(updated)) {
20907                updated.splice(oldKey, 1);
20908              } else {
20909                delete updated[oldKey];
20910              }
20911            } else {
20912              updated[oldKey] = copyWithRenameImpl(
20913                // $FlowFixMe number or string is fine here
20914                obj[oldKey],
20915                oldPath,
20916                newPath,
20917                index2 + 1
20918              );
20919            }
20920            return updated;
20921          };
20922          var copyWithRename = function(obj, oldPath, newPath) {
20923            if (oldPath.length !== newPath.length) {
20924              warn("copyWithRename() expects paths of the same length");
20925              return;
20926            } else {
20927              for (var i = 0; i < newPath.length - 1; i++) {
20928                if (oldPath[i] !== newPath[i]) {
20929                  warn("copyWithRename() expects paths to be the same except for the deepest key");
20930                  return;
20931                }
20932              }
20933            }
20934            return copyWithRenameImpl(obj, oldPath, newPath, 0);
20935          };
20936          var copyWithSetImpl = function(obj, path, index2, value) {
20937            if (index2 >= path.length) {
20938              return value;
20939            }
20940            var key = path[index2];
20941            var updated = isArray(obj) ? obj.slice() : assign({}, obj);
20942            updated[key] = copyWithSetImpl(obj[key], path, index2 + 1, value);
20943            return updated;
20944          };
20945          var copyWithSet = function(obj, path, value) {
20946            return copyWithSetImpl(obj, path, 0, value);
20947          };
20948          var findHook = function(fiber, id) {
20949            var currentHook2 = fiber.memoizedState;
20950            while (currentHook2 !== null && id > 0) {
20951              currentHook2 = currentHook2.next;
20952              id--;
20953            }
20954            return currentHook2;
20955          };
20956          overrideHookState = function(fiber, id, path, value) {
20957            var hook = findHook(fiber, id);
20958            if (hook !== null) {
20959              var newState = copyWithSet(hook.memoizedState, path, value);
20960              hook.memoizedState = newState;
20961              hook.baseState = newState;
20962              fiber.memoizedProps = assign({}, fiber.memoizedProps);
20963              var root2 = enqueueConcurrentRenderForLane(fiber, SyncLane);
20964              if (root2 !== null) {
20965                scheduleUpdateOnFiber(root2, fiber, SyncLane, NoTimestamp);
20966              }
20967            }
20968          };
20969          overrideHookStateDeletePath = function(fiber, id, path) {
20970            var hook = findHook(fiber, id);
20971            if (hook !== null) {
20972              var newState = copyWithDelete(hook.memoizedState, path);
20973              hook.memoizedState = newState;
20974              hook.baseState = newState;
20975              fiber.memoizedProps = assign({}, fiber.memoizedProps);
20976              var root2 = enqueueConcurrentRenderForLane(fiber, SyncLane);
20977              if (root2 !== null) {
20978                scheduleUpdateOnFiber(root2, fiber, SyncLane, NoTimestamp);
20979              }
20980            }
20981          };
20982          overrideHookStateRenamePath = function(fiber, id, oldPath, newPath) {
20983            var hook = findHook(fiber, id);
20984            if (hook !== null) {
20985              var newState = copyWithRename(hook.memoizedState, oldPath, newPath);
20986              hook.memoizedState = newState;
20987              hook.baseState = newState;
20988              fiber.memoizedProps = assign({}, fiber.memoizedProps);
20989              var root2 = enqueueConcurrentRenderForLane(fiber, SyncLane);
20990              if (root2 !== null) {
20991                scheduleUpdateOnFiber(root2, fiber, SyncLane, NoTimestamp);
20992              }
20993            }
20994          };
20995          overrideProps = function(fiber, path, value) {
20996            fiber.pendingProps = copyWithSet(fiber.memoizedProps, path, value);
20997            if (fiber.alternate) {
20998              fiber.alternate.pendingProps = fiber.pendingProps;
20999            }
21000            var root2 = enqueueConcurrentRenderForLane(fiber, SyncLane);
21001            if (root2 !== null) {
21002              scheduleUpdateOnFiber(root2, fiber, SyncLane, NoTimestamp);
21003            }
21004          };
21005          overridePropsDeletePath = function(fiber, path) {
21006            fiber.pendingProps = copyWithDelete(fiber.memoizedProps, path);
21007            if (fiber.alternate) {
21008              fiber.alternate.pendingProps = fiber.pendingProps;
21009            }
21010            var root2 = enqueueConcurrentRenderForLane(fiber, SyncLane);
21011            if (root2 !== null) {
21012              scheduleUpdateOnFiber(root2, fiber, SyncLane, NoTimestamp);
21013            }
21014          };
21015          overridePropsRenamePath = function(fiber, oldPath, newPath) {
21016            fiber.pendingProps = copyWithRename(fiber.memoizedProps, oldPath, newPath);
21017            if (fiber.alternate) {
21018              fiber.alternate.pendingProps = fiber.pendingProps;
21019            }
21020            var root2 = enqueueConcurrentRenderForLane(fiber, SyncLane);
21021            if (root2 !== null) {
21022              scheduleUpdateOnFiber(root2, fiber, SyncLane, NoTimestamp);
21023            }
21024          };
21025          scheduleUpdate = function(fiber) {
21026            var root2 = enqueueConcurrentRenderForLane(fiber, SyncLane);
21027            if (root2 !== null) {
21028              scheduleUpdateOnFiber(root2, fiber, SyncLane, NoTimestamp);
21029            }
21030          };
21031          setErrorHandler = function(newShouldErrorImpl) {
21032            shouldErrorImpl = newShouldErrorImpl;
21033          };
21034          setSuspenseHandler = function(newShouldSuspendImpl) {
21035            shouldSuspendImpl = newShouldSuspendImpl;
21036          };
21037        }
21038        function findHostInstanceByFiber(fiber) {
21039          var hostFiber = findCurrentHostFiber(fiber);
21040          if (hostFiber === null) {
21041            return null;
21042          }
21043          return hostFiber.stateNode;
21044        }
21045        function emptyFindFiberByHostInstance(instance) {
21046          return null;
21047        }
21048        function getCurrentFiberForDevTools() {
21049          return current;
21050        }
21051        function injectIntoDevTools(devToolsConfig) {
21052          var findFiberByHostInstance = devToolsConfig.findFiberByHostInstance;
21053          var ReactCurrentDispatcher2 = ReactSharedInternals.ReactCurrentDispatcher;
21054          return injectInternals({
21055            bundleType: devToolsConfig.bundleType,
21056            version: devToolsConfig.version,
21057            rendererPackageName: devToolsConfig.rendererPackageName,
21058            rendererConfig: devToolsConfig.rendererConfig,
21059            overrideHookState,
21060            overrideHookStateDeletePath,
21061            overrideHookStateRenamePath,
21062            overrideProps,
21063            overridePropsDeletePath,
21064            overridePropsRenamePath,
21065            setErrorHandler,
21066            setSuspenseHandler,
21067            scheduleUpdate,
21068            currentDispatcherRef: ReactCurrentDispatcher2,
21069            findHostInstanceByFiber,
21070            findFiberByHostInstance: findFiberByHostInstance || emptyFindFiberByHostInstance,
21071            // React Refresh
21072            findHostInstancesForRefresh,
21073            scheduleRefresh,
21074            scheduleRoot,
21075            setRefreshHandler,
21076            // Enables DevTools to append owner stacks to error messages in DEV mode.
21077            getCurrentFiber: getCurrentFiberForDevTools,
21078            // Enables DevTools to detect reconciler version rather than renderer version
21079            // which may not match for third party renderers.
21080            reconcilerVersion: ReactVersion
21081          });
21082        }
21083        var defaultOnRecoverableError = typeof reportError === "function" ? (
21084          // In modern browsers, reportError will dispatch an error event,
21085          // emulating an uncaught JavaScript error.
21086          reportError
21087        ) : function(error2) {
21088          console["error"](error2);
21089        };
21090        function ReactDOMRoot(internalRoot) {
21091          this._internalRoot = internalRoot;
21092        }
21093        ReactDOMHydrationRoot.prototype.render = ReactDOMRoot.prototype.render = function(children) {
21094          var root2 = this._internalRoot;
21095          if (root2 === null) {
21096            throw new Error("Cannot update an unmounted root.");
21097          }
21098          {
21099            if (typeof arguments[1] === "function") {
21100              error("render(...): does not support the second callback argument. To execute a side effect after rendering, declare it in a component body with useEffect().");
21101            } else if (isValidContainer(arguments[1])) {
21102              error("You passed a container to the second argument of root.render(...). You don't need to pass it again since you already passed it to create the root.");
21103            } else if (typeof arguments[1] !== "undefined") {
21104              error("You passed a second argument to root.render(...) but it only accepts one argument.");
21105            }
21106            var container = root2.containerInfo;
21107            if (container.nodeType !== COMMENT_NODE) {
21108              var hostInstance = findHostInstanceWithNoPortals(root2.current);
21109              if (hostInstance) {
21110                if (hostInstance.parentNode !== container) {
21111                  error("render(...): It looks like the React-rendered content of the root container was removed without using React. This is not supported and will cause errors. Instead, call root.unmount() to empty a root's container.");
21112                }
21113              }
21114            }
21115          }
21116          updateContainer(children, root2, null, null);
21117        };
21118        ReactDOMHydrationRoot.prototype.unmount = ReactDOMRoot.prototype.unmount = function() {
21119          {
21120            if (typeof arguments[0] === "function") {
21121              error("unmount(...): does not support a callback argument. To execute a side effect after rendering, declare it in a component body with useEffect().");
21122            }
21123          }
21124          var root2 = this._internalRoot;
21125          if (root2 !== null) {
21126            this._internalRoot = null;
21127            var container = root2.containerInfo;
21128            {
21129              if (isAlreadyRendering()) {
21130                error("Attempted to synchronously unmount a root while React was already rendering. React cannot finish unmounting the root until the current render has completed, which may lead to a race condition.");
21131              }
21132            }
21133            flushSync(function() {
21134              updateContainer(null, root2, null, null);
21135            });
21136            unmarkContainerAsRoot(container);
21137          }
21138        };
21139        function createRoot(container, options2) {
21140          if (!isValidContainer(container)) {
21141            throw new Error("createRoot(...): Target container is not a DOM element.");
21142          }
21143          warnIfReactDOMContainerInDEV(container);
21144          var isStrictMode = false;
21145          var concurrentUpdatesByDefaultOverride = false;
21146          var identifierPrefix = "";
21147          var onRecoverableError = defaultOnRecoverableError;
21148          var transitionCallbacks = null;
21149          if (options2 !== null && options2 !== void 0) {
21150            {
21151              if (options2.hydrate) {
21152                warn("hydrate through createRoot is deprecated. Use ReactDOMClient.hydrateRoot(container, <App />) instead.");
21153              } else {
21154                if (typeof options2 === "object" && options2 !== null && options2.$$typeof === REACT_ELEMENT_TYPE) {
21155                  error("You passed a JSX element to createRoot. You probably meant to call root.render instead. Example usage:\n\n  let root = createRoot(domContainer);\n  root.render(<App />);");
21156                }
21157              }
21158            }
21159            if (options2.unstable_strictMode === true) {
21160              isStrictMode = true;
21161            }
21162            if (options2.identifierPrefix !== void 0) {
21163              identifierPrefix = options2.identifierPrefix;
21164            }
21165            if (options2.onRecoverableError !== void 0) {
21166              onRecoverableError = options2.onRecoverableError;
21167            }
21168            if (options2.transitionCallbacks !== void 0) {
21169              transitionCallbacks = options2.transitionCallbacks;
21170            }
21171          }
21172          var root2 = createContainer(container, ConcurrentRoot, null, isStrictMode, concurrentUpdatesByDefaultOverride, identifierPrefix, onRecoverableError);
21173          markContainerAsRoot(root2.current, container);
21174          var rootContainerElement = container.nodeType === COMMENT_NODE ? container.parentNode : container;
21175          listenToAllSupportedEvents(rootContainerElement);
21176          return new ReactDOMRoot(root2);
21177        }
21178        function ReactDOMHydrationRoot(internalRoot) {
21179          this._internalRoot = internalRoot;
21180        }
21181        function scheduleHydration(target) {
21182          if (target) {
21183            queueExplicitHydrationTarget(target);
21184          }
21185        }
21186        ReactDOMHydrationRoot.prototype.unstable_scheduleHydration = scheduleHydration;
21187        function hydrateRoot(container, initialChildren, options2) {
21188          if (!isValidContainer(container)) {
21189            throw new Error("hydrateRoot(...): Target container is not a DOM element.");
21190          }
21191          warnIfReactDOMContainerInDEV(container);
21192          {
21193            if (initialChildren === void 0) {
21194              error("Must provide initial children as second argument to hydrateRoot. Example usage: hydrateRoot(domContainer, <App />)");
21195            }
21196          }
21197          var hydrationCallbacks = options2 != null ? options2 : null;
21198          var mutableSources = options2 != null && options2.hydratedSources || null;
21199          var isStrictMode = false;
21200          var concurrentUpdatesByDefaultOverride = false;
21201          var identifierPrefix = "";
21202          var onRecoverableError = defaultOnRecoverableError;
21203          if (options2 !== null && options2 !== void 0) {
21204            if (options2.unstable_strictMode === true) {
21205              isStrictMode = true;
21206            }
21207            if (options2.identifierPrefix !== void 0) {
21208              identifierPrefix = options2.identifierPrefix;
21209            }
21210            if (options2.onRecoverableError !== void 0) {
21211              onRecoverableError = options2.onRecoverableError;
21212            }
21213          }
21214          var root2 = createHydrationContainer(initialChildren, null, container, ConcurrentRoot, hydrationCallbacks, isStrictMode, concurrentUpdatesByDefaultOverride, identifierPrefix, onRecoverableError);
21215          markContainerAsRoot(root2.current, container);
21216          listenToAllSupportedEvents(container);
21217          if (mutableSources) {
21218            for (var i = 0; i < mutableSources.length; i++) {
21219              var mutableSource = mutableSources[i];
21220              registerMutableSourceForHydration(root2, mutableSource);
21221            }
21222          }
21223          return new ReactDOMHydrationRoot(root2);
21224        }
21225        function isValidContainer(node) {
21226          return !!(node && (node.nodeType === ELEMENT_NODE || node.nodeType === DOCUMENT_NODE || node.nodeType === DOCUMENT_FRAGMENT_NODE || !disableCommentsAsDOMContainers));
21227        }
21228        function isValidContainerLegacy(node) {
21229          return !!(node && (node.nodeType === ELEMENT_NODE || node.nodeType === DOCUMENT_NODE || node.nodeType === DOCUMENT_FRAGMENT_NODE || node.nodeType === COMMENT_NODE && node.nodeValue === " react-mount-point-unstable "));
21230        }
21231        function warnIfReactDOMContainerInDEV(container) {
21232          {
21233            if (container.nodeType === ELEMENT_NODE && container.tagName && container.tagName.toUpperCase() === "BODY") {
21234              error("createRoot(): Creating roots directly with document.body is discouraged, since its children are often manipulated by third-party scripts and browser extensions. This may lead to subtle reconciliation issues. Try using a container element created for your app.");
21235            }
21236            if (isContainerMarkedAsRoot(container)) {
21237              if (container._reactRootContainer) {
21238                error("You are calling ReactDOMClient.createRoot() on a container that was previously passed to ReactDOM.render(). This is not supported.");
21239              } else {
21240                error("You are calling ReactDOMClient.createRoot() on a container that has already been passed to createRoot() before. Instead, call root.render() on the existing root instead if you want to update it.");
21241              }
21242            }
21243          }
21244        }
21245        var ReactCurrentOwner$3 = ReactSharedInternals.ReactCurrentOwner;
21246        var topLevelUpdateWarnings;
21247        {
21248          topLevelUpdateWarnings = function(container) {
21249            if (container._reactRootContainer && container.nodeType !== COMMENT_NODE) {
21250              var hostInstance = findHostInstanceWithNoPortals(container._reactRootContainer.current);
21251              if (hostInstance) {
21252                if (hostInstance.parentNode !== container) {
21253                  error("render(...): It looks like the React-rendered content of this container was removed without using React. This is not supported and will cause errors. Instead, call ReactDOM.unmountComponentAtNode to empty a container.");
21254                }
21255              }
21256            }
21257            var isRootRenderedBySomeReact = !!container._reactRootContainer;
21258            var rootEl = getReactRootElementInContainer(container);
21259            var hasNonRootReactChild = !!(rootEl && getInstanceFromNode(rootEl));
21260            if (hasNonRootReactChild && !isRootRenderedBySomeReact) {
21261              error("render(...): Replacing React-rendered children with a new root component. If you intended to update the children of this node, you should instead have the existing children update their state and render the new components instead of calling ReactDOM.render.");
21262            }
21263            if (container.nodeType === ELEMENT_NODE && container.tagName && container.tagName.toUpperCase() === "BODY") {
21264              error("render(): Rendering components directly into document.body is discouraged, since its children are often manipulated by third-party scripts and browser extensions. This may lead to subtle reconciliation issues. Try rendering into a container element created for your app.");
21265            }
21266          };
21267        }
21268        function getReactRootElementInContainer(container) {
21269          if (!container) {
21270            return null;
21271          }
21272          if (container.nodeType === DOCUMENT_NODE) {
21273            return container.documentElement;
21274          } else {
21275            return container.firstChild;
21276          }
21277        }
21278        function noopOnRecoverableError() {
21279        }
21280        function legacyCreateRootFromDOMContainer(container, initialChildren, parentComponent, callback, isHydrationContainer) {
21281          if (isHydrationContainer) {
21282            if (typeof callback === "function") {
21283              var originalCallback = callback;
21284              callback = function() {
21285                var instance = getPublicRootInstance(root2);
21286                originalCallback.call(instance);
21287              };
21288            }
21289            var root2 = createHydrationContainer(
21290              initialChildren,
21291              callback,
21292              container,
21293              LegacyRoot,
21294              null,
21295              // hydrationCallbacks
21296              false,
21297              // isStrictMode
21298              false,
21299              // concurrentUpdatesByDefaultOverride,
21300              "",
21301              // identifierPrefix
21302              noopOnRecoverableError
21303            );
21304            container._reactRootContainer = root2;
21305            markContainerAsRoot(root2.current, container);
21306            var rootContainerElement = container.nodeType === COMMENT_NODE ? container.parentNode : container;
21307            listenToAllSupportedEvents(rootContainerElement);
21308            flushSync();
21309            return root2;
21310          } else {
21311            var rootSibling;
21312            while (rootSibling = container.lastChild) {
21313              container.removeChild(rootSibling);
21314            }
21315            if (typeof callback === "function") {
21316              var _originalCallback = callback;
21317              callback = function() {
21318                var instance = getPublicRootInstance(_root);
21319                _originalCallback.call(instance);
21320              };
21321            }
21322            var _root = createContainer(
21323              container,
21324              LegacyRoot,
21325              null,
21326              // hydrationCallbacks
21327              false,
21328              // isStrictMode
21329              false,
21330              // concurrentUpdatesByDefaultOverride,
21331              "",
21332              // identifierPrefix
21333              noopOnRecoverableError
21334            );
21335            container._reactRootContainer = _root;
21336            markContainerAsRoot(_root.current, container);
21337            var _rootContainerElement = container.nodeType === COMMENT_NODE ? container.parentNode : container;
21338            listenToAllSupportedEvents(_rootContainerElement);
21339            flushSync(function() {
21340              updateContainer(initialChildren, _root, parentComponent, callback);
21341            });
21342            return _root;
21343          }
21344        }
21345        function warnOnInvalidCallback$1(callback, callerName) {
21346          {
21347            if (callback !== null && typeof callback !== "function") {
21348              error("%s(...): Expected the last optional `callback` argument to be a function. Instead received: %s.", callerName, callback);
21349            }
21350          }
21351        }
21352        function legacyRenderSubtreeIntoContainer(parentComponent, children, container, forceHydrate, callback) {
21353          {
21354            topLevelUpdateWarnings(container);
21355            warnOnInvalidCallback$1(callback === void 0 ? null : callback, "render");
21356          }
21357          var maybeRoot = container._reactRootContainer;
21358          var root2;
21359          if (!maybeRoot) {
21360            root2 = legacyCreateRootFromDOMContainer(container, children, parentComponent, callback, forceHydrate);
21361          } else {
21362            root2 = maybeRoot;
21363            if (typeof callback === "function") {
21364              var originalCallback = callback;
21365              callback = function() {
21366                var instance = getPublicRootInstance(root2);
21367                originalCallback.call(instance);
21368              };
21369            }
21370            updateContainer(children, root2, parentComponent, callback);
21371          }
21372          return getPublicRootInstance(root2);
21373        }
21374        var didWarnAboutFindDOMNode = false;
21375        function findDOMNode(componentOrElement) {
21376          {
21377            if (!didWarnAboutFindDOMNode) {
21378              didWarnAboutFindDOMNode = true;
21379              error("findDOMNode is deprecated and will be removed in the next major release. Instead, add a ref directly to the element you want to reference. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-find-node");
21380            }
21381            var owner = ReactCurrentOwner$3.current;
21382            if (owner !== null && owner.stateNode !== null) {
21383              var warnedAboutRefsInRender = owner.stateNode._warnedAboutRefsInRender;
21384              if (!warnedAboutRefsInRender) {
21385                error("%s is accessing findDOMNode inside its render(). render() should be a pure function of props and state. It should never access something that requires stale data from the previous render, such as refs. Move this logic to componentDidMount and componentDidUpdate instead.", getComponentNameFromType(owner.type) || "A component");
21386              }
21387              owner.stateNode._warnedAboutRefsInRender = true;
21388            }
21389          }
21390          if (componentOrElement == null) {
21391            return null;
21392          }
21393          if (componentOrElement.nodeType === ELEMENT_NODE) {
21394            return componentOrElement;
21395          }
21396          {
21397            return findHostInstanceWithWarning(componentOrElement, "findDOMNode");
21398          }
21399        }
21400        function hydrate(element, container, callback) {
21401          {
21402            error("ReactDOM.hydrate is no longer supported in React 18. Use hydrateRoot instead. Until you switch to the new API, your app will behave as if it's running React 17. Learn more: https://reactjs.org/link/switch-to-createroot");
21403          }
21404          if (!isValidContainerLegacy(container)) {
21405            throw new Error("Target container is not a DOM element.");
21406          }
21407          {
21408            var isModernRoot = isContainerMarkedAsRoot(container) && container._reactRootContainer === void 0;
21409            if (isModernRoot) {
21410              error("You are calling ReactDOM.hydrate() on a container that was previously passed to ReactDOMClient.createRoot(). This is not supported. Did you mean to call hydrateRoot(container, element)?");
21411            }
21412          }
21413          return legacyRenderSubtreeIntoContainer(null, element, container, true, callback);
21414        }
21415        function render(element, container, callback) {
21416          {
21417            error("ReactDOM.render is no longer supported in React 18. Use createRoot instead. Until you switch to the new API, your app will behave as if it's running React 17. Learn more: https://reactjs.org/link/switch-to-createroot");
21418          }
21419          if (!isValidContainerLegacy(container)) {
21420            throw new Error("Target container is not a DOM element.");
21421          }
21422          {
21423            var isModernRoot = isContainerMarkedAsRoot(container) && container._reactRootContainer === void 0;
21424            if (isModernRoot) {
21425              error("You are calling ReactDOM.render() on a container that was previously passed to ReactDOMClient.createRoot(). This is not supported. Did you mean to call root.render(element)?");
21426            }
21427          }
21428          return legacyRenderSubtreeIntoContainer(null, element, container, false, callback);
21429        }
21430        function unstable_renderSubtreeIntoContainer(parentComponent, element, containerNode, callback) {
21431          {
21432            error("ReactDOM.unstable_renderSubtreeIntoContainer() is no longer supported in React 18. Consider using a portal instead. Until you switch to the createRoot API, your app will behave as if it's running React 17. Learn more: https://reactjs.org/link/switch-to-createroot");
21433          }
21434          if (!isValidContainerLegacy(containerNode)) {
21435            throw new Error("Target container is not a DOM element.");
21436          }
21437          if (parentComponent == null || !has(parentComponent)) {
21438            throw new Error("parentComponent must be a valid React Component");
21439          }
21440          return legacyRenderSubtreeIntoContainer(parentComponent, element, containerNode, false, callback);
21441        }
21442        var didWarnAboutUnmountComponentAtNode = false;
21443        function unmountComponentAtNode(container) {
21444          {
21445            if (!didWarnAboutUnmountComponentAtNode) {
21446              didWarnAboutUnmountComponentAtNode = true;
21447              error("unmountComponentAtNode is deprecated and will be removed in the next major release. Switch to the createRoot API. Learn more: https://reactjs.org/link/switch-to-createroot");
21448            }
21449          }
21450          if (!isValidContainerLegacy(container)) {
21451            throw new Error("unmountComponentAtNode(...): Target container is not a DOM element.");
21452          }
21453          {
21454            var isModernRoot = isContainerMarkedAsRoot(container) && container._reactRootContainer === void 0;
21455            if (isModernRoot) {
21456              error("You are calling ReactDOM.unmountComponentAtNode() on a container that was previously passed to ReactDOMClient.createRoot(). This is not supported. Did you mean to call root.unmount()?");
21457            }
21458          }
21459          if (container._reactRootContainer) {
21460            {
21461              var rootEl = getReactRootElementInContainer(container);
21462              var renderedByDifferentReact = rootEl && !getInstanceFromNode(rootEl);
21463              if (renderedByDifferentReact) {
21464                error("unmountComponentAtNode(): The node you're attempting to unmount was rendered by another copy of React.");
21465              }
21466            }
21467            flushSync(function() {
21468              legacyRenderSubtreeIntoContainer(null, null, container, false, function() {
21469                container._reactRootContainer = null;
21470                unmarkContainerAsRoot(container);
21471              });
21472            });
21473            return true;
21474          } else {
21475            {
21476              var _rootEl = getReactRootElementInContainer(container);
21477              var hasNonRootReactChild = !!(_rootEl && getInstanceFromNode(_rootEl));
21478              var isContainerReactRoot = container.nodeType === ELEMENT_NODE && isValidContainerLegacy(container.parentNode) && !!container.parentNode._reactRootContainer;
21479              if (hasNonRootReactChild) {
21480                error("unmountComponentAtNode(): The node you're attempting to unmount was rendered by React and is not a top-level container. %s", isContainerReactRoot ? "You may have accidentally passed in a React root node instead of its container." : "Instead, have the parent component update its state and rerender in order to remove this component.");
21481              }
21482            }
21483            return false;
21484          }
21485        }
21486        setAttemptSynchronousHydration(attemptSynchronousHydration$1);
21487        setAttemptContinuousHydration(attemptContinuousHydration$1);
21488        setAttemptHydrationAtCurrentPriority(attemptHydrationAtCurrentPriority$1);
21489        setGetCurrentUpdatePriority(getCurrentUpdatePriority);
21490        setAttemptHydrationAtPriority(runWithPriority);
21491        {
21492          if (typeof Map !== "function" || // $FlowIssue Flow incorrectly thinks Map has no prototype
21493          Map.prototype == null || typeof Map.prototype.forEach !== "function" || typeof Set !== "function" || // $FlowIssue Flow incorrectly thinks Set has no prototype
21494          Set.prototype == null || typeof Set.prototype.clear !== "function" || typeof Set.prototype.forEach !== "function") {
21495            error("React depends on Map and Set built-in types. Make sure that you load a polyfill in older browsers. https://reactjs.org/link/react-polyfills");
21496          }
21497        }
21498        setRestoreImplementation(restoreControlledState$3);
21499        setBatchingImplementation(batchedUpdates$1, discreteUpdates, flushSync);
21500        function createPortal$1(children, container) {
21501          var key = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : null;
21502          if (!isValidContainer(container)) {
21503            throw new Error("Target container is not a DOM element.");
21504          }
21505          return createPortal(children, container, null, key);
21506        }
21507        function renderSubtreeIntoContainer(parentComponent, element, containerNode, callback) {
21508          return unstable_renderSubtreeIntoContainer(parentComponent, element, containerNode, callback);
21509        }
21510        var Internals = {
21511          usingClientEntryPoint: false,
21512          // Keep in sync with ReactTestUtils.js.
21513          // This is an array for better minification.
21514          Events: [getInstanceFromNode, getNodeFromInstance, getFiberCurrentPropsFromNode, enqueueStateRestore, restoreStateIfNeeded, batchedUpdates$1]
21515        };
21516        function createRoot$1(container, options2) {
21517          {
21518            if (!Internals.usingClientEntryPoint && true) {
21519              error('You are importing createRoot from "react-dom" which is not supported. You should instead import it from "react-dom/client".');
21520            }
21521          }
21522          return createRoot(container, options2);
21523        }
21524        function hydrateRoot$1(container, initialChildren, options2) {
21525          {
21526            if (!Internals.usingClientEntryPoint && true) {
21527              error('You are importing hydrateRoot from "react-dom" which is not supported. You should instead import it from "react-dom/client".');
21528            }
21529          }
21530          return hydrateRoot(container, initialChildren, options2);
21531        }
21532        function flushSync$1(fn) {
21533          {
21534            if (isAlreadyRendering()) {
21535              error("flushSync was called from inside a lifecycle method. React cannot flush when React is already rendering. Consider moving this call to a scheduler task or micro task.");
21536            }
21537          }
21538          return flushSync(fn);
21539        }
21540        var foundDevTools = injectIntoDevTools({
21541          findFiberByHostInstance: getClosestInstanceFromNode,
21542          bundleType: 1,
21543          version: ReactVersion,
21544          rendererPackageName: "react-dom"
21545        });
21546        {
21547          if (!foundDevTools && canUseDOM && window.top === window.self) {
21548            if (navigator.userAgent.indexOf("Chrome") > -1 && navigator.userAgent.indexOf("Edge") === -1 || navigator.userAgent.indexOf("Firefox") > -1) {
21549              var protocol = window.location.protocol;
21550              if (/^(https?|file):$/.test(protocol)) {
21551                console.info("%cDownload the React DevTools for a better development experience: https://reactjs.org/link/react-devtools" + (protocol === "file:" ? "\nYou might need to use a local HTTP server (instead of file://): https://reactjs.org/link/react-devtools-faq" : ""), "font-weight:bold");
21552              }
21553            }
21554          }
21555        }
21556        exports.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED = Internals;
21557        exports.createPortal = createPortal$1;
21558        exports.createRoot = createRoot$1;
21559        exports.findDOMNode = findDOMNode;
21560        exports.flushSync = flushSync$1;
21561        exports.hydrate = hydrate;
21562        exports.hydrateRoot = hydrateRoot$1;
21563        exports.render = render;
21564        exports.unmountComponentAtNode = unmountComponentAtNode;
21565        exports.unstable_batchedUpdates = batchedUpdates$1;
21566        exports.unstable_renderSubtreeIntoContainer = renderSubtreeIntoContainer;
21567        exports.version = ReactVersion;
21568        if (typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ !== "undefined" && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop === "function") {
21569          __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(new Error());
21570        }
21571      })();
21572    }
21573  }
21574});
21575
vendor: 1,424 bytes, lines 21576-21628
21576// node_modules/react-dom/index.js
21577var require_react_dom = __commonJS({
21578  "node_modules/react-dom/index.js"(exports, module) {
21579    if (false) {
21580      checkDCE();
21581      module.exports = null;
21582    } else {
21583      module.exports = require_react_dom_development();
21584    }
21585  }
21586});
21587
21588export {
21589  require_react_dom
21590};
21591/*! Bundled license information:
21592
21593scheduler/cjs/scheduler.development.js:
21594  (**
21595   * @license React
21596   * scheduler.development.js
21597   *
21598   * Copyright (c) Facebook, Inc. and its affiliates.
21599   *
21600   * This source code is licensed under the MIT license found in the
21601   * LICENSE file in the root directory of this source tree.
21602   *)
21603
21604react-dom/cjs/react-dom.development.js:
21605  (**
21606   * @license React
21607   * react-dom.development.js
21608   *
21609   * Copyright (c) Facebook, Inc. and its affiliates.
21610   *
21611   * This source code is licensed under the MIT license found in the
21612   * LICENSE file in the root directory of this source tree.
21613   *)
21614  (**
21615   * Checks if an event is supported in the current execution environment.
21616   *
21617   * NOTE: This will not work correctly for non-generic events such as `change`,
21618   * `reset`, `load`, `error`, and `select`.
21619   *
21620   * Borrows from Modernizr.
21621   *
21622   * @param {string} eventNameSuffix Event name, e.g. "click".
21623   * @return {boolean} True if the event is supported.
21624   * @internal
21625   * @license Modernizr 3.0.0pre (Custom Build) | MIT
21626   *)
21627*/
21628//# sourceMappingURL=chunk-WERSD76P.js.map

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.