chunk-UWV35TSL.js 18 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489
  1. import {
  2. __commonJS
  3. } from "/build/_shared/chunk-PNG5AS42.js";
  4. // node_modules/react-refresh/cjs/react-refresh-runtime.development.js
  5. var require_react_refresh_runtime_development = __commonJS({
  6. "node_modules/react-refresh/cjs/react-refresh-runtime.development.js"(exports) {
  7. "use strict";
  8. if (true) {
  9. (function() {
  10. "use strict";
  11. var REACT_FORWARD_REF_TYPE = Symbol.for("react.forward_ref");
  12. var REACT_MEMO_TYPE = Symbol.for("react.memo");
  13. var PossiblyWeakMap = typeof WeakMap === "function" ? WeakMap : Map;
  14. var allFamiliesByID = /* @__PURE__ */ new Map();
  15. var allFamiliesByType = new PossiblyWeakMap();
  16. var allSignaturesByType = new PossiblyWeakMap();
  17. var updatedFamiliesByType = new PossiblyWeakMap();
  18. var pendingUpdates = [];
  19. var helpersByRendererID = /* @__PURE__ */ new Map();
  20. var helpersByRoot = /* @__PURE__ */ new Map();
  21. var mountedRoots = /* @__PURE__ */ new Set();
  22. var failedRoots = /* @__PURE__ */ new Set();
  23. var rootElements = (
  24. // $FlowIssue
  25. typeof WeakMap === "function" ? /* @__PURE__ */ new WeakMap() : null
  26. );
  27. var isPerformingRefresh = false;
  28. function computeFullKey(signature) {
  29. if (signature.fullKey !== null) {
  30. return signature.fullKey;
  31. }
  32. var fullKey = signature.ownKey;
  33. var hooks;
  34. try {
  35. hooks = signature.getCustomHooks();
  36. } catch (err) {
  37. signature.forceReset = true;
  38. signature.fullKey = fullKey;
  39. return fullKey;
  40. }
  41. for (var i = 0; i < hooks.length; i++) {
  42. var hook = hooks[i];
  43. if (typeof hook !== "function") {
  44. signature.forceReset = true;
  45. signature.fullKey = fullKey;
  46. return fullKey;
  47. }
  48. var nestedHookSignature = allSignaturesByType.get(hook);
  49. if (nestedHookSignature === void 0) {
  50. continue;
  51. }
  52. var nestedHookKey = computeFullKey(nestedHookSignature);
  53. if (nestedHookSignature.forceReset) {
  54. signature.forceReset = true;
  55. }
  56. fullKey += "\n---\n" + nestedHookKey;
  57. }
  58. signature.fullKey = fullKey;
  59. return fullKey;
  60. }
  61. function haveEqualSignatures(prevType, nextType) {
  62. var prevSignature = allSignaturesByType.get(prevType);
  63. var nextSignature = allSignaturesByType.get(nextType);
  64. if (prevSignature === void 0 && nextSignature === void 0) {
  65. return true;
  66. }
  67. if (prevSignature === void 0 || nextSignature === void 0) {
  68. return false;
  69. }
  70. if (computeFullKey(prevSignature) !== computeFullKey(nextSignature)) {
  71. return false;
  72. }
  73. if (nextSignature.forceReset) {
  74. return false;
  75. }
  76. return true;
  77. }
  78. function isReactClass(type) {
  79. return type.prototype && type.prototype.isReactComponent;
  80. }
  81. function canPreserveStateBetween(prevType, nextType) {
  82. if (isReactClass(prevType) || isReactClass(nextType)) {
  83. return false;
  84. }
  85. if (haveEqualSignatures(prevType, nextType)) {
  86. return true;
  87. }
  88. return false;
  89. }
  90. function resolveFamily(type) {
  91. return updatedFamiliesByType.get(type);
  92. }
  93. function cloneMap(map) {
  94. var clone = /* @__PURE__ */ new Map();
  95. map.forEach(function(value, key) {
  96. clone.set(key, value);
  97. });
  98. return clone;
  99. }
  100. function cloneSet(set) {
  101. var clone = /* @__PURE__ */ new Set();
  102. set.forEach(function(value) {
  103. clone.add(value);
  104. });
  105. return clone;
  106. }
  107. function getProperty(object, property) {
  108. try {
  109. return object[property];
  110. } catch (err) {
  111. return void 0;
  112. }
  113. }
  114. function performReactRefresh() {
  115. if (pendingUpdates.length === 0) {
  116. return null;
  117. }
  118. if (isPerformingRefresh) {
  119. return null;
  120. }
  121. isPerformingRefresh = true;
  122. try {
  123. var staleFamilies = /* @__PURE__ */ new Set();
  124. var updatedFamilies = /* @__PURE__ */ new Set();
  125. var updates = pendingUpdates;
  126. pendingUpdates = [];
  127. updates.forEach(function(_ref) {
  128. var family = _ref[0], nextType = _ref[1];
  129. var prevType = family.current;
  130. updatedFamiliesByType.set(prevType, family);
  131. updatedFamiliesByType.set(nextType, family);
  132. family.current = nextType;
  133. if (canPreserveStateBetween(prevType, nextType)) {
  134. updatedFamilies.add(family);
  135. } else {
  136. staleFamilies.add(family);
  137. }
  138. });
  139. var update = {
  140. updatedFamilies,
  141. // Families that will re-render preserving state
  142. staleFamilies
  143. // Families that will be remounted
  144. };
  145. helpersByRendererID.forEach(function(helpers) {
  146. helpers.setRefreshHandler(resolveFamily);
  147. });
  148. var didError = false;
  149. var firstError = null;
  150. var failedRootsSnapshot = cloneSet(failedRoots);
  151. var mountedRootsSnapshot = cloneSet(mountedRoots);
  152. var helpersByRootSnapshot = cloneMap(helpersByRoot);
  153. failedRootsSnapshot.forEach(function(root) {
  154. var helpers = helpersByRootSnapshot.get(root);
  155. if (helpers === void 0) {
  156. throw new Error("Could not find helpers for a root. This is a bug in React Refresh.");
  157. }
  158. if (!failedRoots.has(root)) {
  159. }
  160. if (rootElements === null) {
  161. return;
  162. }
  163. if (!rootElements.has(root)) {
  164. return;
  165. }
  166. var element = rootElements.get(root);
  167. try {
  168. helpers.scheduleRoot(root, element);
  169. } catch (err) {
  170. if (!didError) {
  171. didError = true;
  172. firstError = err;
  173. }
  174. }
  175. });
  176. mountedRootsSnapshot.forEach(function(root) {
  177. var helpers = helpersByRootSnapshot.get(root);
  178. if (helpers === void 0) {
  179. throw new Error("Could not find helpers for a root. This is a bug in React Refresh.");
  180. }
  181. if (!mountedRoots.has(root)) {
  182. }
  183. try {
  184. helpers.scheduleRefresh(root, update);
  185. } catch (err) {
  186. if (!didError) {
  187. didError = true;
  188. firstError = err;
  189. }
  190. }
  191. });
  192. if (didError) {
  193. throw firstError;
  194. }
  195. return update;
  196. } finally {
  197. isPerformingRefresh = false;
  198. }
  199. }
  200. function register(type, id) {
  201. {
  202. if (type === null) {
  203. return;
  204. }
  205. if (typeof type !== "function" && typeof type !== "object") {
  206. return;
  207. }
  208. if (allFamiliesByType.has(type)) {
  209. return;
  210. }
  211. var family = allFamiliesByID.get(id);
  212. if (family === void 0) {
  213. family = {
  214. current: type
  215. };
  216. allFamiliesByID.set(id, family);
  217. } else {
  218. pendingUpdates.push([family, type]);
  219. }
  220. allFamiliesByType.set(type, family);
  221. if (typeof type === "object" && type !== null) {
  222. switch (getProperty(type, "$$typeof")) {
  223. case REACT_FORWARD_REF_TYPE:
  224. register(type.render, id + "$render");
  225. break;
  226. case REACT_MEMO_TYPE:
  227. register(type.type, id + "$type");
  228. break;
  229. }
  230. }
  231. }
  232. }
  233. function setSignature(type, key) {
  234. var forceReset = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : false;
  235. var getCustomHooks = arguments.length > 3 ? arguments[3] : void 0;
  236. {
  237. if (!allSignaturesByType.has(type)) {
  238. allSignaturesByType.set(type, {
  239. forceReset,
  240. ownKey: key,
  241. fullKey: null,
  242. getCustomHooks: getCustomHooks || function() {
  243. return [];
  244. }
  245. });
  246. }
  247. if (typeof type === "object" && type !== null) {
  248. switch (getProperty(type, "$$typeof")) {
  249. case REACT_FORWARD_REF_TYPE:
  250. setSignature(type.render, key, forceReset, getCustomHooks);
  251. break;
  252. case REACT_MEMO_TYPE:
  253. setSignature(type.type, key, forceReset, getCustomHooks);
  254. break;
  255. }
  256. }
  257. }
  258. }
  259. function collectCustomHooksForSignature(type) {
  260. {
  261. var signature = allSignaturesByType.get(type);
  262. if (signature !== void 0) {
  263. computeFullKey(signature);
  264. }
  265. }
  266. }
  267. function getFamilyByID(id) {
  268. {
  269. return allFamiliesByID.get(id);
  270. }
  271. }
  272. function getFamilyByType(type) {
  273. {
  274. return allFamiliesByType.get(type);
  275. }
  276. }
  277. function findAffectedHostInstances(families) {
  278. {
  279. var affectedInstances = /* @__PURE__ */ new Set();
  280. mountedRoots.forEach(function(root) {
  281. var helpers = helpersByRoot.get(root);
  282. if (helpers === void 0) {
  283. throw new Error("Could not find helpers for a root. This is a bug in React Refresh.");
  284. }
  285. var instancesForRoot = helpers.findHostInstancesForRefresh(root, families);
  286. instancesForRoot.forEach(function(inst) {
  287. affectedInstances.add(inst);
  288. });
  289. });
  290. return affectedInstances;
  291. }
  292. }
  293. function injectIntoGlobalHook(globalObject) {
  294. {
  295. var hook = globalObject.__REACT_DEVTOOLS_GLOBAL_HOOK__;
  296. if (hook === void 0) {
  297. var nextID = 0;
  298. globalObject.__REACT_DEVTOOLS_GLOBAL_HOOK__ = hook = {
  299. renderers: /* @__PURE__ */ new Map(),
  300. supportsFiber: true,
  301. inject: function(injected) {
  302. return nextID++;
  303. },
  304. onScheduleFiberRoot: function(id, root, children) {
  305. },
  306. onCommitFiberRoot: function(id, root, maybePriorityLevel, didError) {
  307. },
  308. onCommitFiberUnmount: function() {
  309. }
  310. };
  311. }
  312. if (hook.isDisabled) {
  313. console["warn"]("Something has shimmed the React DevTools global hook (__REACT_DEVTOOLS_GLOBAL_HOOK__). Fast Refresh is not compatible with this shim and will be disabled.");
  314. return;
  315. }
  316. var oldInject = hook.inject;
  317. hook.inject = function(injected) {
  318. var id = oldInject.apply(this, arguments);
  319. if (typeof injected.scheduleRefresh === "function" && typeof injected.setRefreshHandler === "function") {
  320. helpersByRendererID.set(id, injected);
  321. }
  322. return id;
  323. };
  324. hook.renderers.forEach(function(injected, id) {
  325. if (typeof injected.scheduleRefresh === "function" && typeof injected.setRefreshHandler === "function") {
  326. helpersByRendererID.set(id, injected);
  327. }
  328. });
  329. var oldOnCommitFiberRoot = hook.onCommitFiberRoot;
  330. var oldOnScheduleFiberRoot = hook.onScheduleFiberRoot || function() {
  331. };
  332. hook.onScheduleFiberRoot = function(id, root, children) {
  333. if (!isPerformingRefresh) {
  334. failedRoots.delete(root);
  335. if (rootElements !== null) {
  336. rootElements.set(root, children);
  337. }
  338. }
  339. return oldOnScheduleFiberRoot.apply(this, arguments);
  340. };
  341. hook.onCommitFiberRoot = function(id, root, maybePriorityLevel, didError) {
  342. var helpers = helpersByRendererID.get(id);
  343. if (helpers !== void 0) {
  344. helpersByRoot.set(root, helpers);
  345. var current = root.current;
  346. var alternate = current.alternate;
  347. if (alternate !== null) {
  348. var wasMounted = alternate.memoizedState != null && alternate.memoizedState.element != null && mountedRoots.has(root);
  349. var isMounted = current.memoizedState != null && current.memoizedState.element != null;
  350. if (!wasMounted && isMounted) {
  351. mountedRoots.add(root);
  352. failedRoots.delete(root);
  353. } else if (wasMounted && isMounted)
  354. ;
  355. else if (wasMounted && !isMounted) {
  356. mountedRoots.delete(root);
  357. if (didError) {
  358. failedRoots.add(root);
  359. } else {
  360. helpersByRoot.delete(root);
  361. }
  362. } else if (!wasMounted && !isMounted) {
  363. if (didError) {
  364. failedRoots.add(root);
  365. }
  366. }
  367. } else {
  368. mountedRoots.add(root);
  369. }
  370. }
  371. return oldOnCommitFiberRoot.apply(this, arguments);
  372. };
  373. }
  374. }
  375. function hasUnrecoverableErrors() {
  376. return false;
  377. }
  378. function _getMountedRootCount() {
  379. {
  380. return mountedRoots.size;
  381. }
  382. }
  383. function createSignatureFunctionForTransform() {
  384. {
  385. var savedType;
  386. var hasCustomHooks;
  387. var didCollectHooks = false;
  388. return function(type, key, forceReset, getCustomHooks) {
  389. if (typeof key === "string") {
  390. if (!savedType) {
  391. savedType = type;
  392. hasCustomHooks = typeof getCustomHooks === "function";
  393. }
  394. if (type != null && (typeof type === "function" || typeof type === "object")) {
  395. setSignature(type, key, forceReset, getCustomHooks);
  396. }
  397. return type;
  398. } else {
  399. if (!didCollectHooks && hasCustomHooks) {
  400. didCollectHooks = true;
  401. collectCustomHooksForSignature(savedType);
  402. }
  403. }
  404. };
  405. }
  406. }
  407. function isLikelyComponentType(type) {
  408. {
  409. switch (typeof type) {
  410. case "function": {
  411. if (type.prototype != null) {
  412. if (type.prototype.isReactComponent) {
  413. return true;
  414. }
  415. var ownNames = Object.getOwnPropertyNames(type.prototype);
  416. if (ownNames.length > 1 || ownNames[0] !== "constructor") {
  417. return false;
  418. }
  419. if (type.prototype.__proto__ !== Object.prototype) {
  420. return false;
  421. }
  422. }
  423. var name = type.name || type.displayName;
  424. return typeof name === "string" && /^[A-Z]/.test(name);
  425. }
  426. case "object": {
  427. if (type != null) {
  428. switch (getProperty(type, "$$typeof")) {
  429. case REACT_FORWARD_REF_TYPE:
  430. case REACT_MEMO_TYPE:
  431. return true;
  432. default:
  433. return false;
  434. }
  435. }
  436. return false;
  437. }
  438. default: {
  439. return false;
  440. }
  441. }
  442. }
  443. }
  444. exports._getMountedRootCount = _getMountedRootCount;
  445. exports.collectCustomHooksForSignature = collectCustomHooksForSignature;
  446. exports.createSignatureFunctionForTransform = createSignatureFunctionForTransform;
  447. exports.findAffectedHostInstances = findAffectedHostInstances;
  448. exports.getFamilyByID = getFamilyByID;
  449. exports.getFamilyByType = getFamilyByType;
  450. exports.hasUnrecoverableErrors = hasUnrecoverableErrors;
  451. exports.injectIntoGlobalHook = injectIntoGlobalHook;
  452. exports.isLikelyComponentType = isLikelyComponentType;
  453. exports.performReactRefresh = performReactRefresh;
  454. exports.register = register;
  455. exports.setSignature = setSignature;
  456. })();
  457. }
  458. }
  459. });
  460. // node_modules/react-refresh/runtime.js
  461. var require_runtime = __commonJS({
  462. "node_modules/react-refresh/runtime.js"(exports, module) {
  463. if (false) {
  464. module.exports = null;
  465. } else {
  466. module.exports = require_react_refresh_runtime_development();
  467. }
  468. }
  469. });
  470. export {
  471. require_runtime
  472. };
  473. /*! Bundled license information:
  474. react-refresh/cjs/react-refresh-runtime.development.js:
  475. (**
  476. * @license React
  477. * react-refresh-runtime.development.js
  478. *
  479. * Copyright (c) Facebook, Inc. and its affiliates.
  480. *
  481. * This source code is licensed under the MIT license found in the
  482. * LICENSE file in the root directory of this source tree.
  483. *)
  484. */
  485. //# sourceMappingURL=/build/_shared/chunk-UWV35TSL.js.map