@nullix/zod-mongoose-studio 3.2.0 → 3.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (118) hide show
  1. package/.output/nitro.json +1 -1
  2. package/.output/public/_fonts/57NSSoFy1VLVs2gqly8Ls9awBnZMFyXGrefpmqvdqmc-zJfbBtpgM4cDmcXBsqZNW79_kFnlpPd62b48glgdydA.woff2 +0 -0
  3. package/.output/public/_fonts/8VR2wSMN-3U4NbWAVYXlkRV6hA0jFBXP-0RtL3X7fko-x2gYI4qfmkRdxyQQUPaBZdZdgl1TeVrquF_TxHeM4lM.woff2 +0 -0
  4. package/.output/public/_fonts/GsKUclqeNLJ96g5AU593ug6yanivOiwjW_7zESNPChw-jHA4tBeM1bjF7LATGUpfBuSTyomIFrWBTzjF7txVYfg.woff2 +0 -0
  5. package/.output/public/_fonts/Ld1FnTo3yTIwDyGfTQ5-Fws9AWsCbKfMvgxduXr7JcY-W25bL8NF1fjpLRSOgJb7RoZPHqGQNwMTM7S9tHVoxx8.woff2 +0 -0
  6. package/.output/public/_fonts/NdzqRASp2bovDUhQT1IRE_EMqKJ2KYQdTCfFcBvL8yw-KhwZiS86o3fErOe5GGMExHUemmI_dBfaEFxjISZrBd0.woff2 +0 -0
  7. package/.output/public/_fonts/iTkrULNFJJkTvihIg1Vqi5IODRH_9btXCioVF5l98I8-AndUyau2HR2felA_ra8V2mutQgschhasE5FD1dXGJX8.woff2 +0 -0
  8. package/.output/public/_nuxt/{qQyvCkbV.js → 5Tu2WUJz.js} +1 -1
  9. package/.output/public/_nuxt/B0N6xv5E.js +1 -0
  10. package/.output/public/_nuxt/{DjPT-NCE.js → B0cUlOSM.js} +1 -1
  11. package/.output/public/_nuxt/B9paGgN0.js +33 -0
  12. package/.output/public/_nuxt/{IxYCG8hB.js → BCIlnd0g.js} +1 -1
  13. package/.output/public/_nuxt/{ikxafTHA.js → BNDnV2op.js} +180 -184
  14. package/.output/public/_nuxt/{Ce-T_1aD.js → BO4hqv6q.js} +1 -1
  15. package/.output/public/_nuxt/{Bd32GOUy.js → BOsJJ_ZU.js} +1 -1
  16. package/.output/public/_nuxt/{BzhSDy30.js → C2BHp-MG.js} +1 -1
  17. package/.output/public/_nuxt/{Cs8GXJCB.js → CKULsFUz.js} +1 -1
  18. package/.output/public/_nuxt/CMH9iX_E.js +6 -0
  19. package/.output/public/_nuxt/{tzj4nvDE.js → CzbCpNnc.js} +2 -2
  20. package/.output/public/_nuxt/{CC3n3Aga.js → D87QMS6j.js} +1 -1
  21. package/.output/public/_nuxt/DA0pQuyP.js +27 -0
  22. package/.output/public/_nuxt/{B7P0wQ35.js → DcJ7oPvZ.js} +1 -1
  23. package/.output/public/_nuxt/{Ick_23I4.js → Dce9SnGa.js} +1 -1
  24. package/.output/public/_nuxt/{CAd-qHfI.js → DpKrXpkK.js} +1 -1
  25. package/.output/public/_nuxt/DsnIpnT9.js +1 -0
  26. package/.output/public/_nuxt/{CNZorjDf.js → I3Ucam2s.js} +1 -1
  27. package/.output/public/_nuxt/builds/latest.json +1 -1
  28. package/.output/public/_nuxt/builds/meta/51f1351c-0667-4235-9ddc-16582a51ce03.json +1 -0
  29. package/.output/public/_nuxt/{entry.J_CbC0oY.css → entry.B-vs1tRH.css} +1 -1
  30. package/.output/public/_nuxt/error-404.CTSXlFYa.css +1 -0
  31. package/.output/public/_nuxt/error-500.DqEfQnVZ.css +1 -0
  32. package/.output/public/_nuxt/{nDZOJ7rN.js → o-NCh2rp.js} +2 -2
  33. package/.output/public/_nuxt/{qwxNOyg7.js → sKEJiAHO.js} +1 -1
  34. package/.output/public/_nuxt/{81vqh61j.js → tqQNlhT9.js} +1 -1
  35. package/.output/public/_nuxt/ypRHVLFO.js +1 -0
  36. package/.output/server/chunks/_/error-500.mjs.map +1 -1
  37. package/.output/server/chunks/build/client.precomputed.mjs +1 -1
  38. package/.output/server/chunks/build/{error-404-BN-7rNE4.mjs → error-404-KRkA0DPI.mjs} +10 -4
  39. package/.output/server/chunks/build/error-404-KRkA0DPI.mjs.map +1 -0
  40. package/.output/server/chunks/build/error-404-styles.I0NYw-Bn.mjs +8 -0
  41. package/.output/server/chunks/build/error-404-styles.I0NYw-Bn.mjs.map +1 -0
  42. package/.output/server/chunks/build/{error-500-DhIQ-2yt.mjs → error-500-DIIFf55p.mjs} +10 -4
  43. package/.output/server/chunks/build/error-500-DIIFf55p.mjs.map +1 -0
  44. package/.output/server/chunks/build/error-500-styles.D1cs9hQy.mjs +8 -0
  45. package/.output/server/chunks/build/error-500-styles.D1cs9hQy.mjs.map +1 -0
  46. package/.output/server/chunks/build/index-CB1N4gax.mjs +557 -0
  47. package/.output/server/chunks/build/index-CB1N4gax.mjs.map +1 -0
  48. package/.output/server/chunks/build/server.mjs +326 -248
  49. package/.output/server/chunks/build/server.mjs.map +1 -1
  50. package/.output/server/chunks/build/styles.mjs +4 -4
  51. package/.output/server/chunks/nitro/nitro.mjs +2302 -835
  52. package/.output/server/chunks/nitro/nitro.mjs.map +1 -1
  53. package/.output/server/chunks/routes/api/editor-types.get.mjs +44 -0
  54. package/.output/server/chunks/routes/api/editor-types.get.mjs.map +1 -0
  55. package/.output/server/chunks/routes/api/parse.post.mjs +26 -1316
  56. package/.output/server/chunks/routes/api/parse.post.mjs.map +1 -1
  57. package/.output/server/chunks/routes/api/resolve.get.mjs +6 -0
  58. package/.output/server/chunks/routes/api/resolve.get.mjs.map +1 -1
  59. package/.output/server/chunks/routes/api/studio/run.post.mjs +35 -0
  60. package/.output/server/chunks/routes/api/studio/run.post.mjs.map +1 -0
  61. package/.output/server/chunks/routes/renderer.mjs +1 -1
  62. package/.output/server/chunks/routes/renderer.mjs.map +1 -1
  63. package/.output/server/index.mjs +7 -1
  64. package/.output/server/index.mjs.map +1 -1
  65. package/.output/server/node_modules/acorn/dist/acorn.mjs +6266 -0
  66. package/.output/server/node_modules/acorn/package.json +50 -0
  67. package/.output/server/node_modules/ip-address/dist/common.js +112 -4
  68. package/.output/server/node_modules/ip-address/dist/ipv4.js +322 -87
  69. package/.output/server/node_modules/ip-address/dist/ipv6.js +654 -199
  70. package/.output/server/node_modules/ip-address/dist/v4/constants.js +45 -2
  71. package/.output/server/node_modules/ip-address/dist/v6/constants.js +55 -3
  72. package/.output/server/node_modules/ip-address/dist/v6/helpers.js +12 -3
  73. package/.output/server/node_modules/ip-address/package.json +49 -37
  74. package/.output/server/node_modules/ufo/dist/index.mjs +2 -2
  75. package/.output/server/node_modules/ufo/package.json +9 -9
  76. package/.output/server/package.json +4 -3
  77. package/README.md +62 -19
  78. package/app/assets/css/main.css +1 -0
  79. package/app/assets/css/studio.css +131 -0
  80. package/app/components/StudioConversion.vue +41 -0
  81. package/app/components/StudioDataPanel.vue +21 -0
  82. package/app/components/StudioEditor.vue +78 -102
  83. package/app/components/StudioExpandButton.vue +11 -0
  84. package/app/components/StudioOutput.vue +7 -1
  85. package/app/components/StudioSourcePanel.vue +16 -0
  86. package/app/components/StudioValidation.vue +47 -0
  87. package/app/components/ZodMongooseStudio.vue +216 -198
  88. package/app/composables/useStudioRunner.ts +142 -0
  89. package/app/pages/index.vue +1 -1
  90. package/app/plugins/monaco.client.ts +2 -0
  91. package/bin/index.mjs +5 -0
  92. package/nuxt.config.ts +4 -3
  93. package/package.json +4 -2
  94. package/server/api/editor-types.get.ts +28 -0
  95. package/server/api/parse.post.ts +17 -175
  96. package/server/api/studio/run.post.ts +17 -0
  97. package/server/middleware/security.ts +29 -7
  98. package/server/utils/example-data.ts +80 -0
  99. package/server/utils/parse-request.ts +28 -0
  100. package/server/utils/runner-client.ts +40 -0
  101. package/server/utils/studio-execution.ts +176 -0
  102. package/.output/public/_nuxt/BD40YYqZ.js +0 -33
  103. package/.output/public/_nuxt/BlQmLjV4.js +0 -1
  104. package/.output/public/_nuxt/CJ4Cv9fY.js +0 -61
  105. package/.output/public/_nuxt/builds/meta/34871c14-b0f4-4898-9ff0-debaff743355.json +0 -1
  106. package/.output/public/_nuxt/error-404.64pZEiDn.css +0 -1
  107. package/.output/public/_nuxt/error-500.DHOpI0Ir.css +0 -1
  108. package/.output/public/_nuxt/rH_O4qXT.js +0 -1
  109. package/.output/server/chunks/build/error-404-BN-7rNE4.mjs.map +0 -1
  110. package/.output/server/chunks/build/error-404-styles.Byx46oLR.mjs +0 -8
  111. package/.output/server/chunks/build/error-404-styles.Byx46oLR.mjs.map +0 -1
  112. package/.output/server/chunks/build/error-500-DhIQ-2yt.mjs.map +0 -1
  113. package/.output/server/chunks/build/error-500-styles.BL3UT0Wa.mjs +0 -8
  114. package/.output/server/chunks/build/error-500-styles.BL3UT0Wa.mjs.map +0 -1
  115. package/.output/server/chunks/build/index-B4T6zHp0.mjs +0 -1904
  116. package/.output/server/chunks/build/index-B4T6zHp0.mjs.map +0 -1
  117. package/.output/server/node_modules/zod/index.js +0 -4
  118. /package/.output/public/_nuxt/{editor.CdBKkuhR.css → monaco.CdBKkuhR.css} +0 -0
@@ -1,4 +1,11 @@
1
- import process from 'node:process';globalThis._importMeta_=globalThis._importMeta_||{url:"file:///_entry.js",env:process.env};import http, { Server as Server$1 } from 'node:http';
1
+ import process from 'node:process';globalThis._importMeta_=globalThis._importMeta_||{url:"file:///_entry.js",env:process.env};import http, { request, Server as Server$1 } from 'node:http';
2
+ import vm from 'node:vm';
3
+ import { transformSync } from 'esbuild';
4
+ import util from 'node:util';
5
+ import { parse } from 'acorn';
6
+ import * as zod from 'zod/v4';
7
+ import { z } from 'zod/v4';
8
+ import mongoose from 'mongoose';
2
9
  import https, { Server } from 'node:https';
3
10
  import { EventEmitter } from 'node:events';
4
11
  import { Buffer as Buffer$1 } from 'node:buffer';
@@ -81,14 +88,12 @@ const HASH_RE = /#/g;
81
88
  const AMPERSAND_RE = /&/g;
82
89
  const SLASH_RE = /\//g;
83
90
  const EQUAL_RE = /=/g;
84
- const IM_RE = /\?/g;
85
91
  const PLUS_RE = /\+/g;
86
92
  const ENC_CARET_RE = /%5e/gi;
87
93
  const ENC_BACKTICK_RE = /%60/gi;
88
94
  const ENC_PIPE_RE = /%7c/gi;
89
95
  const ENC_SPACE_RE = /%20/gi;
90
96
  const ENC_SLASH_RE = /%2f/gi;
91
- const ENC_ENC_SLASH_RE = /%252f/gi;
92
97
  function encode(text) {
93
98
  return encodeURI("" + text).replace(ENC_PIPE_RE, "|");
94
99
  }
@@ -98,10 +103,7 @@ function encodeQueryValue(input) {
98
103
  function encodeQueryKey(text) {
99
104
  return encodeQueryValue(text).replace(EQUAL_RE, "%3D");
100
105
  }
101
- function encodePath(text) {
102
- return encode(text).replace(HASH_RE, "%23").replace(IM_RE, "%3F").replace(ENC_ENC_SLASH_RE, "%2F").replace(AMPERSAND_RE, "%26").replace(PLUS_RE, "%2B");
103
- }
104
- function decode$2(text = "") {
106
+ function decode(text = "") {
105
107
  try {
106
108
  return decodeURIComponent("" + text);
107
109
  } catch {
@@ -109,13 +111,13 @@ function decode$2(text = "") {
109
111
  }
110
112
  }
111
113
  function decodePath(text) {
112
- return decode$2(text.replace(ENC_SLASH_RE, "%252F"));
114
+ return decode(text.replace(ENC_SLASH_RE, "%252F"));
113
115
  }
114
116
  function decodeQueryKey(text) {
115
- return decode$2(text.replace(PLUS_RE, " "));
117
+ return decode(text.replace(PLUS_RE, " "));
116
118
  }
117
119
  function decodeQueryValue(text) {
118
- return decode$2(text.replace(PLUS_RE, " "));
120
+ return decode(text.replace(PLUS_RE, " "));
119
121
  }
120
122
 
121
123
  function parseQuery(parametersString = "") {
@@ -164,8 +166,6 @@ function stringifyQuery(query) {
164
166
  const PROTOCOL_STRICT_REGEX = /^[\s\w\0+.-]{2,}:([/\\]{1,2})/;
165
167
  const PROTOCOL_REGEX = /^[\s\w\0+.-]{2,}:([/\\]{2})?/;
166
168
  const PROTOCOL_RELATIVE_REGEX = /^([/\\]\s*){2,}[^/\\]/;
167
- const PROTOCOL_SCRIPT_RE = /^[\s\0]*(blob|data|javascript|vbscript):$/i;
168
- const TRAILING_SLASH_RE = /\/$|\/\?|\/#/;
169
169
  const JOIN_LEADING_SLASH_RE = /^\.?\//;
170
170
  function hasProtocol(inputString, opts = {}) {
171
171
  if (typeof opts === "boolean") {
@@ -176,52 +176,20 @@ function hasProtocol(inputString, opts = {}) {
176
176
  }
177
177
  return PROTOCOL_REGEX.test(inputString) || (opts.acceptRelative ? PROTOCOL_RELATIVE_REGEX.test(inputString) : false);
178
178
  }
179
- function isScriptProtocol(protocol) {
180
- return !!protocol && PROTOCOL_SCRIPT_RE.test(protocol);
181
- }
182
179
  function hasTrailingSlash(input = "", respectQueryAndFragment) {
183
- if (!respectQueryAndFragment) {
180
+ {
184
181
  return input.endsWith("/");
185
182
  }
186
- return TRAILING_SLASH_RE.test(input);
187
183
  }
188
184
  function withoutTrailingSlash(input = "", respectQueryAndFragment) {
189
- if (!respectQueryAndFragment) {
185
+ {
190
186
  return (hasTrailingSlash(input) ? input.slice(0, -1) : input) || "/";
191
187
  }
192
- if (!hasTrailingSlash(input, true)) {
193
- return input || "/";
194
- }
195
- let path = input;
196
- let fragment = "";
197
- const fragmentIndex = input.indexOf("#");
198
- if (fragmentIndex !== -1) {
199
- path = input.slice(0, fragmentIndex);
200
- fragment = input.slice(fragmentIndex);
201
- }
202
- const [s0, ...s] = path.split("?");
203
- const cleanPath = s0.endsWith("/") ? s0.slice(0, -1) : s0;
204
- return (cleanPath || "/") + (s.length > 0 ? `?${s.join("?")}` : "") + fragment;
205
188
  }
206
189
  function withTrailingSlash(input = "", respectQueryAndFragment) {
207
- if (!respectQueryAndFragment) {
190
+ {
208
191
  return input.endsWith("/") ? input : input + "/";
209
192
  }
210
- if (hasTrailingSlash(input, true)) {
211
- return input || "/";
212
- }
213
- let path = input;
214
- let fragment = "";
215
- const fragmentIndex = input.indexOf("#");
216
- if (fragmentIndex !== -1) {
217
- path = input.slice(0, fragmentIndex);
218
- fragment = input.slice(fragmentIndex);
219
- if (!path) {
220
- return fragment;
221
- }
222
- }
223
- const [s0, ...s] = path.split("?");
224
- return s0 + "/" + (s.length > 0 ? `?${s.join("?")}` : "") + fragment;
225
193
  }
226
194
  function hasLeadingSlash(input = "") {
227
195
  return input.startsWith("/");
@@ -254,8 +222,8 @@ function withoutBase(input, base) {
254
222
  if (nextChar && nextChar !== "/" && nextChar !== "?") {
255
223
  return input;
256
224
  }
257
- const trimmed = input.slice(_base.length);
258
- return trimmed[0] === "/" ? trimmed : "/" + trimmed;
225
+ const trimmed = input.slice(_base.length).replace(/^\/+/, "");
226
+ return "/" + trimmed;
259
227
  }
260
228
  function withQuery(input, query) {
261
229
  const parsed = parseURL(input);
@@ -383,217 +351,6 @@ function stringifyParsedURL(parsed) {
383
351
  return proto + auth + host + pathname + search + hash;
384
352
  }
385
353
 
386
- const NullObject$1 = /* @__PURE__ */ (() => {
387
- const C = function() {
388
- };
389
- C.prototype = /* @__PURE__ */ Object.create(null);
390
- return C;
391
- })();
392
- function parse$1(str, options) {
393
- if (typeof str !== "string") {
394
- throw new TypeError("argument str must be a string");
395
- }
396
- const obj = new NullObject$1();
397
- const opt = {};
398
- const dec = opt.decode || decode$1;
399
- let index = 0;
400
- while (index < str.length) {
401
- const eqIdx = str.indexOf("=", index);
402
- if (eqIdx === -1) {
403
- break;
404
- }
405
- let endIdx = str.indexOf(";", index);
406
- if (endIdx === -1) {
407
- endIdx = str.length;
408
- } else if (endIdx < eqIdx) {
409
- index = str.lastIndexOf(";", eqIdx - 1) + 1;
410
- continue;
411
- }
412
- const key = str.slice(index, eqIdx).trim();
413
- if (opt?.filter && !opt?.filter(key)) {
414
- index = endIdx + 1;
415
- continue;
416
- }
417
- if (void 0 === obj[key]) {
418
- let val = str.slice(eqIdx + 1, endIdx).trim();
419
- if (val.codePointAt(0) === 34) {
420
- val = val.slice(1, -1);
421
- }
422
- obj[key] = tryDecode$1(val, dec);
423
- }
424
- index = endIdx + 1;
425
- }
426
- return obj;
427
- }
428
- function decode$1(str) {
429
- return str.includes("%") ? decodeURIComponent(str) : str;
430
- }
431
- function tryDecode$1(str, decode2) {
432
- try {
433
- return decode2(str);
434
- } catch {
435
- return str;
436
- }
437
- }
438
-
439
- const fieldContentRegExp = /^[\u0009\u0020-\u007E\u0080-\u00FF]+$/;
440
- function serialize$2(name, value, options) {
441
- const opt = options || {};
442
- const enc = opt.encode || encodeURIComponent;
443
- if (typeof enc !== "function") {
444
- throw new TypeError("option encode is invalid");
445
- }
446
- if (!fieldContentRegExp.test(name)) {
447
- throw new TypeError("argument name is invalid");
448
- }
449
- const encodedValue = enc(value);
450
- if (encodedValue && !fieldContentRegExp.test(encodedValue)) {
451
- throw new TypeError("argument val is invalid");
452
- }
453
- let str = name + "=" + encodedValue;
454
- if (void 0 !== opt.maxAge && opt.maxAge !== null) {
455
- const maxAge = opt.maxAge - 0;
456
- if (Number.isNaN(maxAge) || !Number.isFinite(maxAge)) {
457
- throw new TypeError("option maxAge is invalid");
458
- }
459
- str += "; Max-Age=" + Math.floor(maxAge);
460
- }
461
- if (opt.domain) {
462
- if (!fieldContentRegExp.test(opt.domain)) {
463
- throw new TypeError("option domain is invalid");
464
- }
465
- str += "; Domain=" + opt.domain;
466
- }
467
- if (opt.path) {
468
- if (!fieldContentRegExp.test(opt.path)) {
469
- throw new TypeError("option path is invalid");
470
- }
471
- str += "; Path=" + opt.path;
472
- }
473
- if (opt.expires) {
474
- if (!isDate(opt.expires) || Number.isNaN(opt.expires.valueOf())) {
475
- throw new TypeError("option expires is invalid");
476
- }
477
- str += "; Expires=" + opt.expires.toUTCString();
478
- }
479
- if (opt.httpOnly) {
480
- str += "; HttpOnly";
481
- }
482
- if (opt.secure) {
483
- str += "; Secure";
484
- }
485
- if (opt.priority) {
486
- const priority = typeof opt.priority === "string" ? opt.priority.toLowerCase() : opt.priority;
487
- switch (priority) {
488
- case "low": {
489
- str += "; Priority=Low";
490
- break;
491
- }
492
- case "medium": {
493
- str += "; Priority=Medium";
494
- break;
495
- }
496
- case "high": {
497
- str += "; Priority=High";
498
- break;
499
- }
500
- default: {
501
- throw new TypeError("option priority is invalid");
502
- }
503
- }
504
- }
505
- if (opt.sameSite) {
506
- const sameSite = typeof opt.sameSite === "string" ? opt.sameSite.toLowerCase() : opt.sameSite;
507
- switch (sameSite) {
508
- case true: {
509
- str += "; SameSite=Strict";
510
- break;
511
- }
512
- case "lax": {
513
- str += "; SameSite=Lax";
514
- break;
515
- }
516
- case "strict": {
517
- str += "; SameSite=Strict";
518
- break;
519
- }
520
- case "none": {
521
- str += "; SameSite=None";
522
- break;
523
- }
524
- default: {
525
- throw new TypeError("option sameSite is invalid");
526
- }
527
- }
528
- }
529
- if (opt.partitioned) {
530
- str += "; Partitioned";
531
- }
532
- return str;
533
- }
534
- function isDate(val) {
535
- return Object.prototype.toString.call(val) === "[object Date]" || val instanceof Date;
536
- }
537
-
538
- function parseSetCookie(setCookieValue, options) {
539
- const parts = (setCookieValue || "").split(";").filter((str) => typeof str === "string" && !!str.trim());
540
- const nameValuePairStr = parts.shift() || "";
541
- const parsed = _parseNameValuePair(nameValuePairStr);
542
- const name = parsed.name;
543
- let value = parsed.value;
544
- try {
545
- value = options?.decode === false ? value : (options?.decode || decodeURIComponent)(value);
546
- } catch {
547
- }
548
- const cookie = {
549
- name,
550
- value
551
- };
552
- for (const part of parts) {
553
- const sides = part.split("=");
554
- const partKey = (sides.shift() || "").trimStart().toLowerCase();
555
- const partValue = sides.join("=");
556
- switch (partKey) {
557
- case "expires": {
558
- cookie.expires = new Date(partValue);
559
- break;
560
- }
561
- case "max-age": {
562
- cookie.maxAge = Number.parseInt(partValue, 10);
563
- break;
564
- }
565
- case "secure": {
566
- cookie.secure = true;
567
- break;
568
- }
569
- case "httponly": {
570
- cookie.httpOnly = true;
571
- break;
572
- }
573
- case "samesite": {
574
- cookie.sameSite = partValue;
575
- break;
576
- }
577
- default: {
578
- cookie[partKey] = partValue;
579
- }
580
- }
581
- }
582
- return cookie;
583
- }
584
- function _parseNameValuePair(nameValuePairStr) {
585
- let name = "";
586
- let value = "";
587
- const nameValueArr = nameValuePairStr.split("=");
588
- if (nameValueArr.length > 1) {
589
- name = nameValueArr.shift();
590
- value = nameValueArr.join("=");
591
- } else {
592
- value = nameValuePairStr;
593
- }
594
- return { name, value };
595
- }
596
-
597
354
  const NODE_TYPES = {
598
355
  NORMAL: 0,
599
356
  WILDCARD: 1,
@@ -885,7 +642,7 @@ const defuFn = createDefu((object, key, currentValue) => {
885
642
  }
886
643
  });
887
644
 
888
- function o(n){throw new Error(`${n} is not implemented yet!`)}let i$1 = class i extends EventEmitter{__unenv__={};readableEncoding=null;readableEnded=true;readableFlowing=false;readableHighWaterMark=0;readableLength=0;readableObjectMode=false;readableAborted=false;readableDidRead=false;closed=false;errored=null;readable=false;destroyed=false;static from(e,t){return new i(t)}constructor(e){super();}_read(e){}read(e){}setEncoding(e){return this}pause(){return this}resume(){return this}isPaused(){return true}unpipe(e){return this}unshift(e,t){}wrap(e){return this}push(e,t){return false}_destroy(e,t){this.removeAllListeners();}destroy(e){return this.destroyed=true,this._destroy(e),this}pipe(e,t){return {}}compose(e,t){throw new Error("Method not implemented.")}[Symbol.asyncDispose](){return this.destroy(),Promise.resolve()}async*[Symbol.asyncIterator](){throw o("Readable.asyncIterator")}iterator(e){throw o("Readable.iterator")}map(e,t){throw o("Readable.map")}filter(e,t){throw o("Readable.filter")}forEach(e,t){throw o("Readable.forEach")}reduce(e,t,r){throw o("Readable.reduce")}find(e,t){throw o("Readable.find")}findIndex(e,t){throw o("Readable.findIndex")}some(e,t){throw o("Readable.some")}toArray(e){throw o("Readable.toArray")}every(e,t){throw o("Readable.every")}flatMap(e,t){throw o("Readable.flatMap")}drop(e,t){throw o("Readable.drop")}take(e,t){throw o("Readable.take")}asIndexedPairs(e){throw o("Readable.asIndexedPairs")}};let l$1 = class l extends EventEmitter{__unenv__={};writable=true;writableEnded=false;writableFinished=false;writableHighWaterMark=0;writableLength=0;writableObjectMode=false;writableCorked=0;closed=false;errored=null;writableNeedDrain=false;writableAborted=false;destroyed=false;_data;_encoding="utf8";constructor(e){super();}pipe(e,t){return {}}_write(e,t,r){if(this.writableEnded){r&&r();return}if(this._data===void 0)this._data=e;else {const s=typeof this._data=="string"?Buffer$1.from(this._data,this._encoding||t||"utf8"):this._data,a=typeof e=="string"?Buffer$1.from(e,t||this._encoding||"utf8"):e;this._data=Buffer$1.concat([s,a]);}this._encoding=t,r&&r();}_writev(e,t){}_destroy(e,t){}_final(e){}write(e,t,r){const s=typeof t=="string"?this._encoding:"utf8",a=typeof t=="function"?t:typeof r=="function"?r:void 0;return this._write(e,s,a),true}setDefaultEncoding(e){return this}end(e,t,r){const s=typeof e=="function"?e:typeof t=="function"?t:typeof r=="function"?r:void 0;if(this.writableEnded)return s&&s(),this;const a=e===s?void 0:e;if(a){const u=t===s?void 0:t;this.write(a,u,s);}return this.writableEnded=true,this.writableFinished=true,this.emit("close"),this.emit("finish"),this}cork(){}uncork(){}destroy(e){return this.destroyed=true,delete this._data,this.removeAllListeners(),this}compose(e,t){throw new Error("Method not implemented.")}[Symbol.asyncDispose](){return Promise.resolve()}};const c$1=class c{allowHalfOpen=true;_destroy;constructor(e=new i$1,t=new l$1){Object.assign(this,e),Object.assign(this,t),this._destroy=m(e._destroy,t._destroy);}};function _(){return Object.assign(c$1.prototype,i$1.prototype),Object.assign(c$1.prototype,l$1.prototype),c$1}function m(...n){return function(...e){for(const t of n)t(...e);}}const g=_();class A extends g{__unenv__={};bufferSize=0;bytesRead=0;bytesWritten=0;connecting=false;destroyed=false;pending=false;localAddress="";localPort=0;remoteAddress="";remoteFamily="";remotePort=0;autoSelectFamilyAttemptedAddresses=[];readyState="readOnly";constructor(e){super();}write(e,t,r){return false}connect(e,t,r){return this}end(e,t,r){return this}setEncoding(e){return this}pause(){return this}resume(){return this}setTimeout(e,t){return this}setNoDelay(e){return this}setKeepAlive(e,t){return this}address(){return {}}unref(){return this}ref(){return this}destroySoon(){this.destroy();}resetAndDestroy(){const e=new Error("ERR_SOCKET_CLOSED");return e.code="ERR_SOCKET_CLOSED",this.destroy(e),this}}class y extends i$1{aborted=false;httpVersion="1.1";httpVersionMajor=1;httpVersionMinor=1;complete=true;connection;socket;headers={};trailers={};method="GET";url="/";statusCode=200;statusMessage="";closed=false;errored=null;readable=false;constructor(e){super(),this.socket=this.connection=e||new A;}get rawHeaders(){const e=this.headers,t=[];for(const r in e)if(Array.isArray(e[r]))for(const s of e[r])t.push(r,s);else t.push(r,e[r]);return t}get rawTrailers(){return []}setTimeout(e,t){return this}get headersDistinct(){return p(this.headers)}get trailersDistinct(){return p(this.trailers)}}function p(n){const e={};for(const[t,r]of Object.entries(n))t&&(e[t]=(Array.isArray(r)?r:[r]).filter(Boolean));return e}class w extends l$1{statusCode=200;statusMessage="";upgrading=false;chunkedEncoding=false;shouldKeepAlive=false;useChunkedEncodingByDefault=false;sendDate=false;finished=false;headersSent=false;strictContentLength=false;connection=null;socket=null;req;_headers={};constructor(e){super(),this.req=e;}assignSocket(e){e._httpMessage=this,this.socket=e,this.connection=e,this.emit("socket",e),this._flush();}_flush(){this.flushHeaders();}detachSocket(e){}writeContinue(e){}writeHead(e,t,r){e&&(this.statusCode=e),typeof t=="string"&&(this.statusMessage=t,t=void 0);const s=r||t;if(s&&!Array.isArray(s))for(const a in s)this.setHeader(a,s[a]);return this.headersSent=true,this}writeProcessing(){}setTimeout(e,t){return this}appendHeader(e,t){e=e.toLowerCase();const r=this._headers[e],s=[...Array.isArray(r)?r:[r],...Array.isArray(t)?t:[t]].filter(Boolean);return this._headers[e]=s.length>1?s:s[0],this}setHeader(e,t){return this._headers[e.toLowerCase()]=t,this}setHeaders(e){for(const[t,r]of Object.entries(e))this.setHeader(t,r);return this}getHeader(e){return this._headers[e.toLowerCase()]}getHeaders(){return this._headers}getHeaderNames(){return Object.keys(this._headers)}hasHeader(e){return e.toLowerCase()in this._headers}removeHeader(e){delete this._headers[e.toLowerCase()];}addTrailers(e){}flushHeaders(){}writeEarlyHints(e,t){typeof t=="function"&&t();}}const E=(()=>{const n=function(){};return n.prototype=Object.create(null),n})();function R(n={}){const e=new E,t=Array.isArray(n)||H(n)?n:Object.entries(n);for(const[r,s]of t)if(s){if(e[r]===void 0){e[r]=s;continue}e[r]=[...Array.isArray(e[r])?e[r]:[e[r]],...Array.isArray(s)?s:[s]];}return e}function H(n){return typeof n?.entries=="function"}function v(n={}){if(n instanceof Headers)return n;const e=new Headers;for(const[t,r]of Object.entries(n))if(r!==void 0){if(Array.isArray(r)){for(const s of r)e.append(t,String(s));continue}e.set(t,String(r));}return e}const S=new Set([101,204,205,304]);async function b(n,e){const t=new y,r=new w(t);t.url=e.url?.toString()||"/";let s;if(!t.url.startsWith("/")){const d=new URL(t.url);s=d.host,t.url=d.pathname+d.search+d.hash;}t.method=e.method||"GET",t.headers=R(e.headers||{}),t.headers.host||(t.headers.host=e.host||s||"localhost"),t.connection.encrypted=t.connection.encrypted||e.protocol==="https",t.body=e.body||null,t.__unenv__=e.context,await n(t,r);let a=r._data;(S.has(r.statusCode)||t.method.toUpperCase()==="HEAD")&&(a=null,delete r._headers["content-length"]);const u={status:r.statusCode,statusText:r.statusMessage,headers:r._headers,body:a};return t.destroy(),r.destroy(),u}async function C(n,e,t={}){try{const r=await b(n,{url:e,...t});return new Response(r.body,{status:r.status,statusText:r.statusText,headers:v(r.headers)})}catch(r){return new Response(r.toString(),{status:Number.parseInt(r.statusCode||r.code)||500,statusText:r.statusText})}}
645
+ function o(n){throw new Error(`${n} is not implemented yet!`)}let i$1 = class i extends EventEmitter{__unenv__={};readableEncoding=null;readableEnded=true;readableFlowing=false;readableHighWaterMark=0;readableLength=0;readableObjectMode=false;readableAborted=false;readableDidRead=false;closed=false;errored=null;readable=false;destroyed=false;static from(e,t){return new i(t)}constructor(e){super();}_read(e){}read(e){}setEncoding(e){return this}pause(){return this}resume(){return this}isPaused(){return true}unpipe(e){return this}unshift(e,t){}wrap(e){return this}push(e,t){return false}_destroy(e,t){this.removeAllListeners();}destroy(e){return this.destroyed=true,this._destroy(e),this}pipe(e,t){return {}}compose(e,t){throw new Error("Method not implemented.")}[Symbol.asyncDispose](){return this.destroy(),Promise.resolve()}async*[Symbol.asyncIterator](){throw o("Readable.asyncIterator")}iterator(e){throw o("Readable.iterator")}map(e,t){throw o("Readable.map")}filter(e,t){throw o("Readable.filter")}forEach(e,t){throw o("Readable.forEach")}reduce(e,t,r){throw o("Readable.reduce")}find(e,t){throw o("Readable.find")}findIndex(e,t){throw o("Readable.findIndex")}some(e,t){throw o("Readable.some")}toArray(e){throw o("Readable.toArray")}every(e,t){throw o("Readable.every")}flatMap(e,t){throw o("Readable.flatMap")}drop(e,t){throw o("Readable.drop")}take(e,t){throw o("Readable.take")}asIndexedPairs(e){throw o("Readable.asIndexedPairs")}};let l$1 = class l extends EventEmitter{__unenv__={};writable=true;writableEnded=false;writableFinished=false;writableHighWaterMark=0;writableLength=0;writableObjectMode=false;writableCorked=0;closed=false;errored=null;writableNeedDrain=false;writableAborted=false;destroyed=false;_data;_encoding="utf8";constructor(e){super();}pipe(e,t){return {}}_write(e,t,r){if(this.writableEnded){r&&r();return}if(this._data===void 0)this._data=e;else {const s=typeof this._data=="string"?Buffer$1.from(this._data,this._encoding||t||"utf8"):this._data,a=typeof e=="string"?Buffer$1.from(e,t||this._encoding||"utf8"):e;this._data=Buffer$1.concat([s,a]);}this._encoding=t,r&&r();}_writev(e,t){}_destroy(e,t){}_final(e){}write(e,t,r){const s=typeof t=="string"?this._encoding:"utf8",a=typeof t=="function"?t:typeof r=="function"?r:void 0;return this._write(e,s,a),true}setDefaultEncoding(e){return this}end(e,t,r){const s=typeof e=="function"?e:typeof t=="function"?t:typeof r=="function"?r:void 0;if(this.writableEnded)return s&&s(),this;const a=e===s?void 0:e;if(a){const u=t===s?void 0:t;this.write(a,u);}return this.writableEnded=true,this.writableFinished=true,this.emit("close"),this.emit("finish"),s&&s(),this}cork(){}uncork(){}destroy(e){return this.destroyed=true,delete this._data,this.removeAllListeners(),this}compose(e,t){throw new Error("Method not implemented.")}[Symbol.asyncDispose](){return Promise.resolve()}};const c=class{allowHalfOpen=true;_destroy;constructor(e=new i$1,t=new l$1){Object.assign(this,e),Object.assign(this,t),this._destroy=m(e._destroy,t._destroy);}};function _(){return Object.assign(c.prototype,i$1.prototype),Object.assign(c.prototype,l$1.prototype),c}function m(...n){return function(...e){for(const t of n)t(...e);}}const g=_();class A extends g{__unenv__={};bufferSize=0;bytesRead=0;bytesWritten=0;connecting=false;destroyed=false;pending=false;localAddress="";localPort=0;remoteAddress="";remoteFamily="";remotePort=0;autoSelectFamilyAttemptedAddresses=[];readyState="readOnly";constructor(e){super();}write(e,t,r){return false}connect(e,t,r){return this}end(e,t,r){return this}setEncoding(e){return this}pause(){return this}resume(){return this}setTimeout(e,t){return this}setNoDelay(e){return this}setKeepAlive(e,t){return this}address(){return {}}unref(){return this}ref(){return this}destroySoon(){this.destroy();}resetAndDestroy(){const e=new Error("ERR_SOCKET_CLOSED");return e.code="ERR_SOCKET_CLOSED",this.destroy(e),this}}class y extends i$1{aborted=false;httpVersion="1.1";httpVersionMajor=1;httpVersionMinor=1;complete=true;connection;socket;headers={};trailers={};method="GET";url="/";statusCode=200;statusMessage="";closed=false;errored=null;readable=false;constructor(e){super(),this.socket=this.connection=e||new A;}get rawHeaders(){const e=this.headers,t=[];for(const r in e)if(Array.isArray(e[r]))for(const s of e[r])t.push(r,s);else t.push(r,e[r]);return t}get rawTrailers(){return []}setTimeout(e,t){return this}get headersDistinct(){return p(this.headers)}get trailersDistinct(){return p(this.trailers)}}function p(n){const e={};for(const[t,r]of Object.entries(n))t&&(e[t]=(Array.isArray(r)?r:[r]).filter(Boolean));return e}class w extends l$1{statusCode=200;statusMessage="";upgrading=false;chunkedEncoding=false;shouldKeepAlive=false;useChunkedEncodingByDefault=false;sendDate=false;finished=false;headersSent=false;strictContentLength=false;connection=null;socket=null;req;_headers={};constructor(e){super(),this.req=e;}assignSocket(e){e._httpMessage=this,this.socket=e,this.connection=e,this.emit("socket",e),this._flush();}_flush(){this.flushHeaders();}detachSocket(e){}writeContinue(e){}writeHead(e,t,r){e&&(this.statusCode=e),typeof t=="string"&&(this.statusMessage=t,t=void 0);const s=r||t;if(s&&!Array.isArray(s))for(const a in s)this.setHeader(a,s[a]);return this.headersSent=true,this}writeProcessing(){}setTimeout(e,t){return this}appendHeader(e,t){e=e.toLowerCase();const r=this._headers[e],s=[...Array.isArray(r)?r:[r],...Array.isArray(t)?t:[t]].filter(Boolean);return this._headers[e]=s.length>1?s:s[0],this}setHeader(e,t){return this._headers[e.toLowerCase()]=t,this}setHeaders(e){for(const[t,r]of Object.entries(e))this.setHeader(t,r);return this}getHeader(e){return this._headers[e.toLowerCase()]}getHeaders(){return this._headers}getHeaderNames(){return Object.keys(this._headers)}hasHeader(e){return e.toLowerCase()in this._headers}removeHeader(e){delete this._headers[e.toLowerCase()];}addTrailers(e){}flushHeaders(){}writeEarlyHints(e,t){typeof t=="function"&&t();}}const E=(()=>{const n=function(){};return n.prototype=Object.create(null),n})();function R(n={}){const e=new E,t=Array.isArray(n)||H(n)?n:Object.entries(n);for(const[r,s]of t)if(s){if(e[r]===void 0){e[r]=s;continue}e[r]=[...Array.isArray(e[r])?e[r]:[e[r]],...Array.isArray(s)?s:[s]];}return e}function H(n){return typeof n?.entries=="function"}function v(n={}){if(n instanceof Headers)return n;const e=new Headers;for(const[t,r]of Object.entries(n))if(r!==void 0){if(Array.isArray(r)){for(const s of r)e.append(t,String(s));continue}e.set(t,String(r));}return e}const S=new Set([101,204,205,304]);async function b(n,e){const t=new y,r=new w(t);t.url=e.url?.toString()||"/";let s;if(!t.url.startsWith("/")){const d=new URL(t.url);s=d.host,t.url=d.pathname+d.search+d.hash;}t.method=e.method||"GET",t.headers=R(e.headers||{}),t.headers.host||(t.headers.host=e.host||s||"localhost"),t.connection.encrypted=t.connection.encrypted||e.protocol==="https",t.body=e.body||null,t.__unenv__=e.context,await n(t,r);let a=r._data;(S.has(r.statusCode)||t.method.toUpperCase()==="HEAD")&&(a=null,delete r._headers["content-length"]);const u={status:r.statusCode,statusText:r.statusMessage,headers:r._headers,body:a};return t.destroy(),r.destroy(),u}async function C(n,e,t={}){try{const r=await b(n,{url:e,...t});return new Response(r.body,{status:r.status,statusText:r.statusText,headers:v(r.headers)})}catch(r){return new Response(r.toString(),{status:Number.parseInt(r.statusCode||r.code)||500,statusText:r.statusText})}}
889
646
 
890
647
  function hasProp(obj, prop) {
891
648
  try {
@@ -1037,6 +794,7 @@ function getRequestHeader(event, name) {
1037
794
  const value = headers[name.toLowerCase()];
1038
795
  return value;
1039
796
  }
797
+ const getHeader = getRequestHeader;
1040
798
  function getRequestHost(event, opts = {}) {
1041
799
  if (opts.xForwardedHost) {
1042
800
  const _header = event.node.req.headers["x-forwarded-host"];
@@ -1078,7 +836,6 @@ function getRequestIP(event, opts = {}) {
1078
836
  }
1079
837
 
1080
838
  const RawBodySymbol = Symbol.for("h3RawBody");
1081
- const ParsedBodySymbol = Symbol.for("h3ParsedBody");
1082
839
  const PayloadMethods$1 = ["PATCH", "POST", "PUT", "DELETE"];
1083
840
  function readRawBody(event, encoding = "utf8") {
1084
841
  assertMethod(event, PayloadMethods$1);
@@ -1148,26 +905,6 @@ function readRawBody(event, encoding = "utf8") {
1148
905
  const result = encoding ? promise.then((buff) => buff.toString(encoding)) : promise;
1149
906
  return result;
1150
907
  }
1151
- async function readBody(event, options = {}) {
1152
- const request = event.node.req;
1153
- if (hasProp(request, ParsedBodySymbol)) {
1154
- return request[ParsedBodySymbol];
1155
- }
1156
- const contentType = request.headers["content-type"] || "";
1157
- const body = await readRawBody(event);
1158
- let parsed;
1159
- if (contentType === "application/json") {
1160
- parsed = _parseJSON(body, options.strict ?? true);
1161
- } else if (contentType.startsWith("application/x-www-form-urlencoded")) {
1162
- parsed = _parseURLEncodedBody(body);
1163
- } else if (contentType.startsWith("text/")) {
1164
- parsed = body;
1165
- } else {
1166
- parsed = _parseJSON(body, options.strict ?? false);
1167
- }
1168
- request[ParsedBodySymbol] = parsed;
1169
- return parsed;
1170
- }
1171
908
  function getRequestWebStream(event) {
1172
909
  if (!PayloadMethods$1.includes(event.method)) {
1173
910
  return;
@@ -1202,35 +939,6 @@ function getRequestWebStream(event) {
1202
939
  }
1203
940
  });
1204
941
  }
1205
- function _parseJSON(body = "", strict) {
1206
- if (!body) {
1207
- return void 0;
1208
- }
1209
- try {
1210
- return destr(body, { strict });
1211
- } catch {
1212
- throw createError$1({
1213
- statusCode: 400,
1214
- statusMessage: "Bad Request",
1215
- message: "Invalid JSON body"
1216
- });
1217
- }
1218
- }
1219
- function _parseURLEncodedBody(body) {
1220
- const form = new URLSearchParams(body);
1221
- const parsedForm = /* @__PURE__ */ Object.create(null);
1222
- for (const [key, value] of form.entries()) {
1223
- if (hasProp(parsedForm, key)) {
1224
- if (!Array.isArray(parsedForm[key])) {
1225
- parsedForm[key] = [parsedForm[key]];
1226
- }
1227
- parsedForm[key].push(value);
1228
- } else {
1229
- parsedForm[key] = value;
1230
- }
1231
- }
1232
- return parsedForm;
1233
- }
1234
942
 
1235
943
  function handleCacheHeaders(event, opts) {
1236
944
  const cacheControls = ["public", ...opts.cacheControls || []];
@@ -1285,47 +993,6 @@ function sanitizeStatusCode(statusCode, defaultStatusCode = 200) {
1285
993
  }
1286
994
  return statusCode;
1287
995
  }
1288
-
1289
- function getDistinctCookieKey(name, opts) {
1290
- return [name, opts.domain || "", opts.path || "/"].join(";");
1291
- }
1292
-
1293
- function parseCookies(event) {
1294
- return parse$1(event.node.req.headers.cookie || "");
1295
- }
1296
- function getCookie(event, name) {
1297
- return parseCookies(event)[name];
1298
- }
1299
- function setCookie(event, name, value, serializeOptions = {}) {
1300
- if (!serializeOptions.path) {
1301
- serializeOptions = { path: "/", ...serializeOptions };
1302
- }
1303
- const newCookie = serialize$2(name, value, serializeOptions);
1304
- const currentCookies = splitCookiesString(
1305
- event.node.res.getHeader("set-cookie")
1306
- );
1307
- if (currentCookies.length === 0) {
1308
- event.node.res.setHeader("set-cookie", newCookie);
1309
- return;
1310
- }
1311
- const newCookieKey = getDistinctCookieKey(name, serializeOptions);
1312
- event.node.res.removeHeader("set-cookie");
1313
- for (const cookie of currentCookies) {
1314
- const parsed = parseSetCookie(cookie);
1315
- const key = getDistinctCookieKey(parsed.name, parsed);
1316
- if (key === newCookieKey) {
1317
- continue;
1318
- }
1319
- event.node.res.appendHeader("set-cookie", cookie);
1320
- }
1321
- event.node.res.appendHeader("set-cookie", newCookie);
1322
- }
1323
- function deleteCookie(event, name, serializeOptions) {
1324
- setCookie(event, name, "", {
1325
- ...serializeOptions,
1326
- maxAge: 0
1327
- });
1328
- }
1329
996
  function splitCookiesString(cookiesString) {
1330
997
  if (Array.isArray(cookiesString)) {
1331
998
  return cookiesString.flatMap((c) => splitCookiesString(c));
@@ -1457,6 +1124,7 @@ const setHeaders = setResponseHeaders;
1457
1124
  function setResponseHeader(event, name, value) {
1458
1125
  event.node.res.setHeader(name, value);
1459
1126
  }
1127
+ const setHeader = setResponseHeader;
1460
1128
  function appendResponseHeader(event, name, value) {
1461
1129
  let current = event.node.res.getHeader(name);
1462
1130
  if (!current) {
@@ -2275,12 +1943,12 @@ function toNodeListener(app) {
2275
1943
  return toNodeHandle;
2276
1944
  }
2277
1945
 
2278
- function flatHooks(configHooks, hooks = {}, parentName) {
1946
+ function flatHooks$1(configHooks, hooks = {}, parentName) {
2279
1947
  for (const key in configHooks) {
2280
1948
  const subHook = configHooks[key];
2281
1949
  const name = parentName ? `${parentName}:${key}` : key;
2282
1950
  if (typeof subHook === "object" && subHook !== null) {
2283
- flatHooks(subHook, hooks, name);
1951
+ flatHooks$1(subHook, hooks, name);
2284
1952
  } else if (typeof subHook === "function") {
2285
1953
  hooks[name] = subHook;
2286
1954
  }
@@ -2289,27 +1957,27 @@ function flatHooks(configHooks, hooks = {}, parentName) {
2289
1957
  }
2290
1958
  const defaultTask = { run: (function_) => function_() };
2291
1959
  const _createTask = () => defaultTask;
2292
- const createTask = typeof console.createTask !== "undefined" ? console.createTask : _createTask;
2293
- function serialTaskCaller(hooks, args) {
1960
+ const createTask$1 = typeof console.createTask !== "undefined" ? console.createTask : _createTask;
1961
+ function serialTaskCaller$1(hooks, args) {
2294
1962
  const name = args.shift();
2295
- const task = createTask(name);
1963
+ const task = createTask$1(name);
2296
1964
  return hooks.reduce(
2297
1965
  (promise, hookFunction) => promise.then(() => task.run(() => hookFunction(...args))),
2298
1966
  Promise.resolve()
2299
1967
  );
2300
1968
  }
2301
- function parallelTaskCaller(hooks, args) {
1969
+ function parallelTaskCaller$1(hooks, args) {
2302
1970
  const name = args.shift();
2303
- const task = createTask(name);
1971
+ const task = createTask$1(name);
2304
1972
  return Promise.all(hooks.map((hook) => task.run(() => hook(...args))));
2305
1973
  }
2306
- function callEachWith(callbacks, arg0) {
1974
+ function callEachWith$1(callbacks, arg0) {
2307
1975
  for (const callback of [...callbacks]) {
2308
1976
  callback(arg0);
2309
1977
  }
2310
1978
  }
2311
1979
 
2312
- class Hookable {
1980
+ let Hookable$1 = class Hookable {
2313
1981
  constructor() {
2314
1982
  this._hooks = {};
2315
1983
  this._before = void 0;
@@ -2401,7 +2069,7 @@ class Hookable {
2401
2069
  }
2402
2070
  }
2403
2071
  addHooks(configHooks) {
2404
- const hooks = flatHooks(configHooks);
2072
+ const hooks = flatHooks$1(configHooks);
2405
2073
  const removeFns = Object.keys(hooks).map(
2406
2074
  (key) => this.hook(key, hooks[key])
2407
2075
  );
@@ -2412,7 +2080,7 @@ class Hookable {
2412
2080
  };
2413
2081
  }
2414
2082
  removeHooks(configHooks) {
2415
- const hooks = flatHooks(configHooks);
2083
+ const hooks = flatHooks$1(configHooks);
2416
2084
  for (const key in hooks) {
2417
2085
  this.removeHook(key, hooks[key]);
2418
2086
  }
@@ -2424,16 +2092,16 @@ class Hookable {
2424
2092
  }
2425
2093
  callHook(name, ...arguments_) {
2426
2094
  arguments_.unshift(name);
2427
- return this.callHookWith(serialTaskCaller, name, ...arguments_);
2095
+ return this.callHookWith(serialTaskCaller$1, name, ...arguments_);
2428
2096
  }
2429
2097
  callHookParallel(name, ...arguments_) {
2430
2098
  arguments_.unshift(name);
2431
- return this.callHookWith(parallelTaskCaller, name, ...arguments_);
2099
+ return this.callHookWith(parallelTaskCaller$1, name, ...arguments_);
2432
2100
  }
2433
2101
  callHookWith(caller, name, ...arguments_) {
2434
2102
  const event = this._before || this._after ? { name, args: arguments_, context: {} } : void 0;
2435
2103
  if (this._before) {
2436
- callEachWith(this._before, event);
2104
+ callEachWith$1(this._before, event);
2437
2105
  }
2438
2106
  const result = caller(
2439
2107
  name in this._hooks ? [...this._hooks[name]] : [],
@@ -2442,12 +2110,12 @@ class Hookable {
2442
2110
  if (result instanceof Promise) {
2443
2111
  return result.finally(() => {
2444
2112
  if (this._after && event) {
2445
- callEachWith(this._after, event);
2113
+ callEachWith$1(this._after, event);
2446
2114
  }
2447
2115
  });
2448
2116
  }
2449
2117
  if (this._after && event) {
2450
- callEachWith(this._after, event);
2118
+ callEachWith$1(this._after, event);
2451
2119
  }
2452
2120
  return result;
2453
2121
  }
@@ -2475,12 +2143,12 @@ class Hookable {
2475
2143
  }
2476
2144
  };
2477
2145
  }
2478
- }
2479
- function createHooks() {
2480
- return new Hookable();
2146
+ };
2147
+ function createHooks$1() {
2148
+ return new Hookable$1();
2481
2149
  }
2482
2150
 
2483
- const s$1=globalThis.Headers,i=globalThis.AbortController,l=globalThis.fetch||(()=>{throw new Error("[node-fetch-native] Failed to fetch: `globalThis.fetch` is not available!")});
2151
+ const s=globalThis.Headers,i=globalThis.AbortController,l=globalThis.fetch||(()=>{throw new Error("[node-fetch-native] Failed to fetch: `globalThis.fetch` is not available!")});
2484
2152
 
2485
2153
  class FetchError extends Error {
2486
2154
  constructor(message, opts) {
@@ -2611,7 +2279,7 @@ function mergeHeaders(input, defaults, Headers) {
2611
2279
  }
2612
2280
  return headers;
2613
2281
  }
2614
- async function callHooks(context, hooks) {
2282
+ async function callHooks$1(context, hooks) {
2615
2283
  if (hooks) {
2616
2284
  if (Array.isArray(hooks)) {
2617
2285
  for (const hook of hooks) {
@@ -2691,7 +2359,7 @@ function createFetch(globalOptions = {}) {
2691
2359
  context.options.method = context.options.method.toUpperCase();
2692
2360
  }
2693
2361
  if (context.options.onRequest) {
2694
- await callHooks(context, context.options.onRequest);
2362
+ await callHooks$1(context, context.options.onRequest);
2695
2363
  if (!(context.options.headers instanceof Headers)) {
2696
2364
  context.options.headers = new Headers(
2697
2365
  context.options.headers || {}
@@ -2759,7 +2427,7 @@ function createFetch(globalOptions = {}) {
2759
2427
  } catch (error) {
2760
2428
  context.error = error;
2761
2429
  if (context.options.onRequestError) {
2762
- await callHooks(
2430
+ await callHooks$1(
2763
2431
  context,
2764
2432
  context.options.onRequestError
2765
2433
  );
@@ -2793,14 +2461,14 @@ function createFetch(globalOptions = {}) {
2793
2461
  }
2794
2462
  }
2795
2463
  if (context.options.onResponse) {
2796
- await callHooks(
2464
+ await callHooks$1(
2797
2465
  context,
2798
2466
  context.options.onResponse
2799
2467
  );
2800
2468
  }
2801
2469
  if (!context.options.ignoreResponseError && context.response.status >= 400 && context.response.status < 600) {
2802
2470
  if (context.options.onResponseError) {
2803
- await callHooks(
2471
+ await callHooks$1(
2804
2472
  context,
2805
2473
  context.options.onResponseError
2806
2474
  );
@@ -2845,7 +2513,7 @@ function createNodeFetch() {
2845
2513
  };
2846
2514
  }
2847
2515
  const fetch$1 = globalThis.fetch ? (...args) => globalThis.fetch(...args) : createNodeFetch();
2848
- const Headers$1 = globalThis.Headers || s$1;
2516
+ const Headers$1 = globalThis.Headers || s;
2849
2517
  const AbortController = globalThis.AbortController || i;
2850
2518
  const ofetch = createFetch({ fetch: fetch$1, Headers: Headers$1, AbortController });
2851
2519
  const $fetch$1 = ofetch;
@@ -3634,22 +3302,164 @@ function useStorage(base = "") {
3634
3302
  return base ? prefixStorage(storage, base) : storage;
3635
3303
  }
3636
3304
 
3637
- function serialize$1(o){return typeof o=="string"?`'${o}'`:new c().serialize(o)}const c=/*@__PURE__*/function(){class o{#t=new Map;compare(t,r){const e=typeof t,n=typeof r;return e==="string"&&n==="string"?t.localeCompare(r):e==="number"&&n==="number"?t-r:String.prototype.localeCompare.call(this.serialize(t,true),this.serialize(r,true))}serialize(t,r){if(t===null)return "null";switch(typeof t){case "string":return r?t:`'${t}'`;case "bigint":return `${t}n`;case "object":return this.$object(t);case "function":return this.$function(t)}return String(t)}serializeObject(t){const r=Object.prototype.toString.call(t);if(r!=="[object Object]")return this.serializeBuiltInType(r.length<10?`unknown:${r}`:r.slice(8,-1),t);const e=t.constructor,n=e===Object||e===void 0?"":e.name;if(n!==""&&globalThis[n]===e)return this.serializeBuiltInType(n,t);if(typeof t.toJSON=="function"){const i=t.toJSON();return n+(i!==null&&typeof i=="object"?this.$object(i):`(${this.serialize(i)})`)}return this.serializeObjectEntries(n,Object.entries(t))}serializeBuiltInType(t,r){const e=this["$"+t];if(e)return e.call(this,r);if(typeof r?.entries=="function")return this.serializeObjectEntries(t,r.entries());throw new Error(`Cannot serialize ${t}`)}serializeObjectEntries(t,r){const e=Array.from(r).sort((i,a)=>this.compare(i[0],a[0]));let n=`${t}{`;for(let i=0;i<e.length;i++){const[a,l]=e[i];n+=`${this.serialize(a,true)}:${this.serialize(l)}`,i<e.length-1&&(n+=",");}return n+"}"}$object(t){let r=this.#t.get(t);return r===void 0&&(this.#t.set(t,`#${this.#t.size}`),r=this.serializeObject(t),this.#t.set(t,r)),r}$function(t){const r=Function.prototype.toString.call(t);return r.slice(-15)==="[native code] }"?`${t.name||""}()[native]`:`${t.name}(${t.length})${r.replace(/\s*\n\s*/g,"")}`}$Array(t){let r="[";for(let e=0;e<t.length;e++)r+=this.serialize(t[e]),e<t.length-1&&(r+=",");return r+"]"}$Date(t){try{return `Date(${t.toISOString()})`}catch{return "Date(null)"}}$ArrayBuffer(t){return `ArrayBuffer[${new Uint8Array(t).join(",")}]`}$Set(t){return `Set${this.$Array(Array.from(t).sort((r,e)=>this.compare(r,e)))}`}$Map(t){return this.serializeObjectEntries("Map",t.entries())}}for(const s of ["Error","RegExp","URL"])o.prototype["$"+s]=function(t){return `${s}(${t})`};for(const s of ["Int8Array","Uint8Array","Uint8ClampedArray","Int16Array","Uint16Array","Int32Array","Uint32Array","Float32Array","Float64Array"])o.prototype["$"+s]=function(t){return `${s}[${t.join(",")}]`};for(const s of ["BigInt64Array","BigUint64Array"])o.prototype["$"+s]=function(t){return `${s}[${t.join("n,")}${t.length>0?"n":""}]`};return o}();
3305
+ function serialize$1(input) {
3306
+ if (typeof input === "string") return `'${input}'`;
3307
+ return new Serializer().serialize(input);
3308
+ }
3309
+ const asciiOrder = " _-,;:!?.'\"()[]{}@*/\\&#%`^+<=>|~$0123456789abcdefghijklmnopqrstuvwxyz";
3310
+ const asciiWeights = /*@__PURE__*/ (function() {
3311
+ const weights = /* @__PURE__ */ new Uint8Array(128);
3312
+ for (let i = 0; i < 69; i++) weights[asciiOrder.charCodeAt(i)] = i + 1;
3313
+ for (let code = 65; code <= 90; code++) weights[code] = weights[code + 32];
3314
+ return weights;
3315
+ })();
3316
+ function compareStrings(a, b) {
3317
+ if (a === b) return 0;
3318
+ const length = Math.min(a.length, b.length);
3319
+ let tieBreaker = 0;
3320
+ for (let i = 0; i < length; i++) {
3321
+ const codeA = a.charCodeAt(i);
3322
+ const codeB = b.charCodeAt(i);
3323
+ if (codeA === codeB) continue;
3324
+ const weightA = codeA < 128 && asciiWeights[codeA] ? asciiWeights[codeA] : codeA + 128;
3325
+ const weightB = codeB < 128 && asciiWeights[codeB] ? asciiWeights[codeB] : codeB + 128;
3326
+ if (weightA !== weightB) return weightA < weightB ? -1 : 1;
3327
+ if (tieBreaker === 0) tieBreaker = codeA > codeB ? -1 : 1;
3328
+ }
3329
+ if (a.length !== b.length) return a.length < b.length ? -1 : 1;
3330
+ return tieBreaker;
3331
+ }
3332
+ const Serializer = /*@__PURE__*/ (function() {
3333
+ class Serializer {
3334
+ #context = /* @__PURE__ */ new Map();
3335
+ compare(a, b) {
3336
+ const typeA = typeof a;
3337
+ const typeB = typeof b;
3338
+ if (typeA === "string" && typeB === "string") return compareStrings(a, b);
3339
+ if (typeA === "number" && typeB === "number") return a - b;
3340
+ return compareStrings(this.serialize(a, true), this.serialize(b, true));
3341
+ }
3342
+ serialize(value, noQuotes) {
3343
+ if (value === null) return "null";
3344
+ switch (typeof value) {
3345
+ case "string": return noQuotes ? value : `'${value}'`;
3346
+ case "bigint": return `${value}n`;
3347
+ case "object": return this.$object(value);
3348
+ case "function": return this.$function(value);
3349
+ }
3350
+ return String(value);
3351
+ }
3352
+ serializeObject(object) {
3353
+ const objString = Object.prototype.toString.call(object);
3354
+ if (objString !== "[object Object]") return this.serializeBuiltInType(objString.length < 10 ? `unknown:${objString}` : objString.slice(8, -1), object);
3355
+ const constructor = object.constructor;
3356
+ const objName = constructor === Object || constructor === void 0 ? "" : constructor.name;
3357
+ if (objName !== "" && globalThis[objName] === constructor) return this.serializeBuiltInType(objName, object);
3358
+ if ("toJSON" in object && typeof object.toJSON === "function") {
3359
+ const json = object.toJSON();
3360
+ return objName + (json !== null && typeof json === "object" ? this.$object(json) : `(${this.serialize(json)})`);
3361
+ }
3362
+ const keys = Object.keys(object).sort(compareStrings);
3363
+ let content = `${objName}{`;
3364
+ for (let i = 0; i < keys.length; i++) {
3365
+ const key = keys[i];
3366
+ content += `${key}:${this.serialize(object[key])}`;
3367
+ if (i < keys.length - 1) content += ",";
3368
+ }
3369
+ return content + "}";
3370
+ }
3371
+ serializeBuiltInType(type, object) {
3372
+ const handler = this["$" + type];
3373
+ if (handler) return handler.call(this, object);
3374
+ if (typeof object.entries === "function") return this.serializeObjectEntries(type, object.entries());
3375
+ throw new Error(`Cannot serialize ${type}`);
3376
+ }
3377
+ serializeObjectEntries(type, entries) {
3378
+ const sortedEntries = Array.from(entries).sort((a, b) => this.compare(a[0], b[0]));
3379
+ let content = `${type}{`;
3380
+ for (let i = 0; i < sortedEntries.length; i++) {
3381
+ const [key, value] = sortedEntries[i];
3382
+ content += `${this.serialize(key, true)}:${this.serialize(value)}`;
3383
+ if (i < sortedEntries.length - 1) content += ",";
3384
+ }
3385
+ return content + "}";
3386
+ }
3387
+ $object(object) {
3388
+ let content = this.#context.get(object);
3389
+ if (content === void 0) {
3390
+ this.#context.set(object, `#${this.#context.size}`);
3391
+ content = this.serializeObject(object);
3392
+ this.#context.set(object, content);
3393
+ }
3394
+ return content;
3395
+ }
3396
+ $function(fn) {
3397
+ const fnStr = Function.prototype.toString.call(fn);
3398
+ if (fnStr.slice(-15) === "[native code] }") return `${fn.name || ""}()[native]`;
3399
+ return `${fn.name}(${fn.length})${fnStr.replace(/\s*\n\s*/g, "")}`;
3400
+ }
3401
+ $Array(arr) {
3402
+ let content = "[";
3403
+ for (let i = 0; i < arr.length; i++) {
3404
+ content += this.serialize(arr[i]);
3405
+ if (i < arr.length - 1) content += ",";
3406
+ }
3407
+ return content + "]";
3408
+ }
3409
+ $Date(date) {
3410
+ try {
3411
+ return `Date(${date.toISOString()})`;
3412
+ } catch {
3413
+ return `Date(null)`;
3414
+ }
3415
+ }
3416
+ $ArrayBuffer(arr) {
3417
+ return `ArrayBuffer[${new Uint8Array(arr).join(",")}]`;
3418
+ }
3419
+ $Set(set) {
3420
+ return `Set${this.$Array(Array.from(set).sort((a, b) => this.compare(a, b)))}`;
3421
+ }
3422
+ $Map(map) {
3423
+ return this.serializeObjectEntries("Map", map.entries());
3424
+ }
3425
+ }
3426
+ for (const type of [
3427
+ "Error",
3428
+ "RegExp",
3429
+ "URL"
3430
+ ]) Serializer.prototype["$" + type] = function(val) {
3431
+ return `${type}(${val})`;
3432
+ };
3433
+ for (const type of [
3434
+ "Int8Array",
3435
+ "Uint8Array",
3436
+ "Uint8ClampedArray",
3437
+ "Int16Array",
3438
+ "Uint16Array",
3439
+ "Int32Array",
3440
+ "Uint32Array",
3441
+ "Float32Array",
3442
+ "Float64Array"
3443
+ ]) Serializer.prototype["$" + type] = function(arr) {
3444
+ return `${type}[${arr.join(",")}]`;
3445
+ };
3446
+ for (const type of ["BigInt64Array", "BigUint64Array"]) Serializer.prototype["$" + type] = function(arr) {
3447
+ return `${type}[${arr.join("n,")}${arr.length > 0 ? "n" : ""}]`;
3448
+ };
3449
+ return Serializer;
3450
+ })();
3638
3451
 
3639
- function isEqual(object1, object2) {
3640
- if (object1 === object2) {
3641
- return true;
3642
- }
3643
- if (serialize$1(object1) === serialize$1(object2)) {
3644
- return true;
3645
- }
3646
- return false;
3452
+ const fastHash = /*@__PURE__*/ (() => globalThis.process?.getBuiltinModule?.("crypto")?.hash)();
3453
+ const algorithm = "sha256";
3454
+ const encoding = "base64url";
3455
+ function digest(data) {
3456
+ if (fastHash) return fastHash(algorithm, data, encoding);
3457
+ const h = createHash(algorithm).update(data);
3458
+ return globalThis.process?.versions?.webcontainer ? h.digest().toString(encoding) : h.digest(encoding);
3647
3459
  }
3648
3460
 
3649
- const e=globalThis.process?.getBuiltinModule?.("crypto")?.hash,r="sha256",s="base64url";function digest(t){if(e)return e(r,t,s);const o=createHash(r).update(t);return globalThis.process?.versions?.webcontainer?o.digest().toString(s):o.digest(s)}
3650
-
3651
3461
  function hash$1(input) {
3652
- return digest(serialize$1(input));
3462
+ return digest(serialize$1(input));
3653
3463
  }
3654
3464
 
3655
3465
  const Hasher = /* @__PURE__ */ (() => {
@@ -4652,7 +4462,7 @@ function _expandFromEnv(value) {
4652
4462
  const _inlineRuntimeConfig = {
4653
4463
  "app": {
4654
4464
  "baseURL": "/",
4655
- "buildId": "34871c14-b0f4-4898-9ff0-debaff743355",
4465
+ "buildId": "51f1351c-0667-4235-9ddc-16582a51ce03",
4656
4466
  "buildAssetsDir": "/_nuxt/",
4657
4467
  "cdnURL": ""
4658
4468
  },
@@ -4685,8 +4495,9 @@ const _inlineRuntimeConfig = {
4685
4495
  }
4686
4496
  },
4687
4497
  "public": {
4688
- "isDocsMode": true,
4689
- "isLocalMode": false
4498
+ "isDocsMode": false,
4499
+ "isLocalMode": false,
4500
+ "isExecutionEnabled": true
4690
4501
  },
4691
4502
  "icon": {
4692
4503
  "serverKnownCssClasses": []
@@ -5138,819 +4949,875 @@ const assets = {
5138
4949
  "/android-chrome-192x192.png": {
5139
4950
  "type": "image/png",
5140
4951
  "etag": "\"3ad0-QyBoLY89FSkQ3jQ6kYWo21t19MI\"",
5141
- "mtime": "2026-09-25T13:28:52.550Z",
4952
+ "mtime": "2026-09-29T10:07:41.529Z",
5142
4953
  "size": 15056,
5143
4954
  "path": "../public/android-chrome-192x192.png"
5144
4955
  },
5145
4956
  "/android-chrome-512x512.png": {
5146
4957
  "type": "image/png",
5147
4958
  "etag": "\"a607-Tx5rFH47AswgZVVr/4EZAFZgo/A\"",
5148
- "mtime": "2026-09-25T13:28:52.550Z",
4959
+ "mtime": "2026-09-29T10:07:41.529Z",
5149
4960
  "size": 42503,
5150
4961
  "path": "../public/android-chrome-512x512.png"
5151
4962
  },
5152
4963
  "/apple-touch-icon.png": {
5153
4964
  "type": "image/png",
5154
4965
  "etag": "\"34bd-3QQEmjyBlqNXOHQzdK75bZGa41E\"",
5155
- "mtime": "2026-09-25T13:28:52.550Z",
4966
+ "mtime": "2026-09-29T10:07:41.529Z",
5156
4967
  "size": 13501,
5157
4968
  "path": "../public/apple-touch-icon.png"
5158
4969
  },
5159
4970
  "/favicon-16x16.png": {
5160
4971
  "type": "image/png",
5161
4972
  "etag": "\"300-3ReZfkEBD+LQFkb0huYbCmUrRNo\"",
5162
- "mtime": "2026-09-25T13:28:52.550Z",
4973
+ "mtime": "2026-09-29T10:07:41.529Z",
5163
4974
  "size": 768,
5164
4975
  "path": "../public/favicon-16x16.png"
5165
4976
  },
5166
4977
  "/favicon-32x32.png": {
5167
4978
  "type": "image/png",
5168
4979
  "etag": "\"6b7-NntNGG1aOmdW9ivfGhxBdj9tfVw\"",
5169
- "mtime": "2026-09-25T13:28:52.550Z",
4980
+ "mtime": "2026-09-29T10:07:41.529Z",
5170
4981
  "size": 1719,
5171
4982
  "path": "../public/favicon-32x32.png"
5172
4983
  },
5173
4984
  "/favicon.ico": {
5174
4985
  "type": "image/vnd.microsoft.icon",
5175
4986
  "etag": "\"3c2e-es1fg4pe8uDI2uJ6zpC4eMeZwAo\"",
5176
- "mtime": "2026-09-25T13:28:52.550Z",
4987
+ "mtime": "2026-09-29T10:07:41.529Z",
5177
4988
  "size": 15406,
5178
4989
  "path": "../public/favicon.ico"
5179
4990
  },
5180
4991
  "/robots.txt": {
5181
4992
  "type": "text/plain; charset=utf-8",
5182
4993
  "etag": "\"18-j8OIsL9qGDmNZ+lHhp2tyH4XtaE\"",
5183
- "mtime": "2026-09-25T13:28:52.550Z",
4994
+ "mtime": "2026-09-29T10:07:41.529Z",
5184
4995
  "size": 24,
5185
4996
  "path": "../public/robots.txt"
5186
4997
  },
5187
4998
  "/site.webmanifest": {
5188
4999
  "type": "application/manifest+json",
5189
5000
  "etag": "\"107-vzG6+RvdL83iSkXj8qG+M3M8b2k\"",
5190
- "mtime": "2026-09-25T13:28:52.550Z",
5001
+ "mtime": "2026-09-29T10:07:41.530Z",
5191
5002
  "size": 263,
5192
5003
  "path": "../public/site.webmanifest"
5193
5004
  },
5194
5005
  "/zodmongoose-b.jpg": {
5195
5006
  "type": "image/jpeg",
5196
5007
  "etag": "\"bba9-C7tcEi/Rte2CpxJPn9o2oDEfZ5I\"",
5197
- "mtime": "2026-09-25T13:28:52.550Z",
5008
+ "mtime": "2026-09-29T10:07:41.529Z",
5198
5009
  "size": 48041,
5199
5010
  "path": "../public/zodmongoose-b.jpg"
5200
5011
  },
5201
- "/zodmongoose-b.png": {
5202
- "type": "image/png",
5203
- "etag": "\"8ca6-2NZ8CEl6Sh3yXhHwinshX6s5YJk\"",
5204
- "mtime": "2026-09-25T13:28:52.550Z",
5205
- "size": 36006,
5206
- "path": "../public/zodmongoose-b.png"
5207
- },
5208
5012
  "/zodmongoose-b.svg": {
5209
5013
  "type": "image/svg+xml",
5210
5014
  "etag": "\"8d1-fyAQMwygQVSe1aEhM1zq8g7uh0E\"",
5211
- "mtime": "2026-09-25T13:28:52.550Z",
5015
+ "mtime": "2026-09-29T10:07:41.530Z",
5212
5016
  "size": 2257,
5213
5017
  "path": "../public/zodmongoose-b.svg"
5214
5018
  },
5019
+ "/zodmongoose-b.png": {
5020
+ "type": "image/png",
5021
+ "etag": "\"8ca6-2NZ8CEl6Sh3yXhHwinshX6s5YJk\"",
5022
+ "mtime": "2026-09-29T10:07:41.530Z",
5023
+ "size": 36006,
5024
+ "path": "../public/zodmongoose-b.png"
5025
+ },
5215
5026
  "/zodmongoose.png": {
5216
5027
  "type": "image/png",
5217
5028
  "etag": "\"a5cd-fvxOutXODdTKApyIjJvfHKZ9/lk\"",
5218
- "mtime": "2026-09-25T13:28:52.550Z",
5029
+ "mtime": "2026-09-29T10:07:41.530Z",
5219
5030
  "size": 42445,
5220
5031
  "path": "../public/zodmongoose.png"
5221
5032
  },
5222
5033
  "/zodmongoose.svg": {
5223
5034
  "type": "image/svg+xml",
5224
5035
  "etag": "\"2223-/eFCEKOmfvQfyKwirwvmMm+9U+c\"",
5225
- "mtime": "2026-09-25T13:28:52.550Z",
5036
+ "mtime": "2026-09-29T10:07:41.530Z",
5226
5037
  "size": 8739,
5227
5038
  "path": "../public/zodmongoose.svg"
5228
5039
  },
5229
- "/_nuxt/81vqh61j.js": {
5230
- "type": "text/javascript; charset=utf-8",
5231
- "etag": "\"de5-JMadwMI9jE9iZsnXN/929Ucmak4\"",
5232
- "mtime": "2026-09-25T13:28:52.537Z",
5233
- "size": 3557,
5234
- "path": "../public/_nuxt/81vqh61j.js"
5040
+ "/zodmongoose.jpg": {
5041
+ "type": "image/jpeg",
5042
+ "etag": "\"1cb92-DVl82sENXcztkHA/oqGnF7i8mNw\"",
5043
+ "mtime": "2026-09-29T10:07:41.530Z",
5044
+ "size": 117650,
5045
+ "path": "../public/zodmongoose.jpg"
5235
5046
  },
5236
- "/_nuxt/9HpZscsL.js": {
5047
+ "/_fonts/57NSSoFy1VLVs2gqly8Ls9awBnZMFyXGrefpmqvdqmc-zJfbBtpgM4cDmcXBsqZNW79_kFnlpPd62b48glgdydA.woff2": {
5048
+ "type": "font/woff2",
5049
+ "etag": "\"4b5c-TAo9mx7r3xQs52+HbHcHJ52z8Qo\"",
5050
+ "mtime": "2026-09-29T10:07:41.486Z",
5051
+ "size": 19292,
5052
+ "path": "../public/_fonts/57NSSoFy1VLVs2gqly8Ls9awBnZMFyXGrefpmqvdqmc-zJfbBtpgM4cDmcXBsqZNW79_kFnlpPd62b48glgdydA.woff2"
5053
+ },
5054
+ "/_fonts/8VR2wSMN-3U4NbWAVYXlkRV6hA0jFBXP-0RtL3X7fko-x2gYI4qfmkRdxyQQUPaBZdZdgl1TeVrquF_TxHeM4lM.woff2": {
5055
+ "type": "font/woff2",
5056
+ "etag": "\"212c-FshXJibFzNhd2HEIMP8C3JR5PYg\"",
5057
+ "mtime": "2026-09-29T10:07:41.486Z",
5058
+ "size": 8492,
5059
+ "path": "../public/_fonts/8VR2wSMN-3U4NbWAVYXlkRV6hA0jFBXP-0RtL3X7fko-x2gYI4qfmkRdxyQQUPaBZdZdgl1TeVrquF_TxHeM4lM.woff2"
5060
+ },
5061
+ "/_fonts/GsKUclqeNLJ96g5AU593ug6yanivOiwjW_7zESNPChw-jHA4tBeM1bjF7LATGUpfBuSTyomIFrWBTzjF7txVYfg.woff2": {
5062
+ "type": "font/woff2",
5063
+ "etag": "\"680c-mJtsV33lkTAKSmfq5k3lKHSllcU\"",
5064
+ "mtime": "2026-09-29T10:07:41.486Z",
5065
+ "size": 26636,
5066
+ "path": "../public/_fonts/GsKUclqeNLJ96g5AU593ug6yanivOiwjW_7zESNPChw-jHA4tBeM1bjF7LATGUpfBuSTyomIFrWBTzjF7txVYfg.woff2"
5067
+ },
5068
+ "/_fonts/Ld1FnTo3yTIwDyGfTQ5-Fws9AWsCbKfMvgxduXr7JcY-W25bL8NF1fjpLRSOgJb7RoZPHqGQNwMTM7S9tHVoxx8.woff2": {
5069
+ "type": "font/woff2",
5070
+ "etag": "\"6ec4-8OoFFPZKF1grqmfGVjh5JDE6DOU\"",
5071
+ "mtime": "2026-09-29T10:07:41.486Z",
5072
+ "size": 28356,
5073
+ "path": "../public/_fonts/Ld1FnTo3yTIwDyGfTQ5-Fws9AWsCbKfMvgxduXr7JcY-W25bL8NF1fjpLRSOgJb7RoZPHqGQNwMTM7S9tHVoxx8.woff2"
5074
+ },
5075
+ "/_fonts/NdzqRASp2bovDUhQT1IRE_EMqKJ2KYQdTCfFcBvL8yw-KhwZiS86o3fErOe5GGMExHUemmI_dBfaEFxjISZrBd0.woff2": {
5076
+ "type": "font/woff2",
5077
+ "etag": "\"1d98-cDZfMibtk4T04FTTAmlfhWDpkN0\"",
5078
+ "mtime": "2026-09-29T10:07:41.486Z",
5079
+ "size": 7576,
5080
+ "path": "../public/_fonts/NdzqRASp2bovDUhQT1IRE_EMqKJ2KYQdTCfFcBvL8yw-KhwZiS86o3fErOe5GGMExHUemmI_dBfaEFxjISZrBd0.woff2"
5081
+ },
5082
+ "/_fonts/iTkrULNFJJkTvihIg1Vqi5IODRH_9btXCioVF5l98I8-AndUyau2HR2felA_ra8V2mutQgschhasE5FD1dXGJX8.woff2": {
5083
+ "type": "font/woff2",
5084
+ "etag": "\"47c4-5xyngHnzzhetUee74tMx9OTgqNQ\"",
5085
+ "mtime": "2026-09-29T10:07:41.486Z",
5086
+ "size": 18372,
5087
+ "path": "../public/_fonts/iTkrULNFJJkTvihIg1Vqi5IODRH_9btXCioVF5l98I8-AndUyau2HR2felA_ra8V2mutQgschhasE5FD1dXGJX8.woff2"
5088
+ },
5089
+ "/_nuxt/5Tu2WUJz.js": {
5237
5090
  "type": "text/javascript; charset=utf-8",
5238
- "etag": "\"eb0-1etrd79M3Jdeb7OGrU7ZnEhsLww\"",
5239
- "mtime": "2026-09-25T13:28:52.537Z",
5240
- "size": 3760,
5241
- "path": "../public/_nuxt/9HpZscsL.js"
5091
+ "etag": "\"d7b-uL97TpnTATYA2ApoynHv3sRmCaU\"",
5092
+ "mtime": "2026-09-29T10:07:41.515Z",
5093
+ "size": 3451,
5094
+ "path": "../public/_nuxt/5Tu2WUJz.js"
5242
5095
  },
5243
5096
  "/_nuxt/8SOpv6rk.js": {
5244
5097
  "type": "text/javascript; charset=utf-8",
5245
5098
  "etag": "\"1252-jhNpKqIAahWiFbQfUlPi0MNOHvA\"",
5246
- "mtime": "2026-09-25T13:28:52.537Z",
5099
+ "mtime": "2026-09-29T10:07:41.515Z",
5247
5100
  "size": 4690,
5248
5101
  "path": "../public/_nuxt/8SOpv6rk.js"
5249
5102
  },
5250
- "/zodmongoose.jpg": {
5251
- "type": "image/jpeg",
5252
- "etag": "\"1cb92-DVl82sENXcztkHA/oqGnF7i8mNw\"",
5253
- "mtime": "2026-09-25T13:28:52.550Z",
5254
- "size": 117650,
5255
- "path": "../public/zodmongoose.jpg"
5103
+ "/_nuxt/9HpZscsL.js": {
5104
+ "type": "text/javascript; charset=utf-8",
5105
+ "etag": "\"eb0-1etrd79M3Jdeb7OGrU7ZnEhsLww\"",
5106
+ "mtime": "2026-09-29T10:07:41.515Z",
5107
+ "size": 3760,
5108
+ "path": "../public/_nuxt/9HpZscsL.js"
5256
5109
  },
5257
- "/_nuxt/B7P0wQ35.js": {
5110
+ "/_nuxt/B0N6xv5E.js": {
5258
5111
  "type": "text/javascript; charset=utf-8",
5259
- "etag": "\"1337-q9hyFCZRCprOd+OzyKhw8x1NahM\"",
5260
- "mtime": "2026-09-25T13:28:52.537Z",
5261
- "size": 4919,
5262
- "path": "../public/_nuxt/B7P0wQ35.js"
5112
+ "etag": "\"4ca-IQWqJFkL9EMCJbZuXLH8c99qTLY\"",
5113
+ "mtime": "2026-09-29T10:07:41.516Z",
5114
+ "size": 1226,
5115
+ "path": "../public/_nuxt/B0N6xv5E.js"
5116
+ },
5117
+ "/_nuxt/B0cUlOSM.js": {
5118
+ "type": "text/javascript; charset=utf-8",
5119
+ "etag": "\"11c2-Ugxo1g8gpHJ3ypHTml6d1ehzhXE\"",
5120
+ "mtime": "2026-09-29T10:07:41.516Z",
5121
+ "size": 4546,
5122
+ "path": "../public/_nuxt/B0cUlOSM.js"
5263
5123
  },
5264
5124
  "/_nuxt/B8OfTtLu.js": {
5265
5125
  "type": "text/javascript; charset=utf-8",
5266
5126
  "etag": "\"a77-BXgbntlXNqUnAJ9kYer+IEdVpyw\"",
5267
- "mtime": "2026-09-25T13:28:52.537Z",
5127
+ "mtime": "2026-09-29T10:07:41.516Z",
5268
5128
  "size": 2679,
5269
5129
  "path": "../public/_nuxt/B8OfTtLu.js"
5270
5130
  },
5271
5131
  "/_nuxt/BBUBE1dy.js": {
5272
5132
  "type": "text/javascript; charset=utf-8",
5273
5133
  "etag": "\"1ed1-PSPAfQCHqDoY8hy5ZiY2soJ8wSg\"",
5274
- "mtime": "2026-09-25T13:28:52.537Z",
5134
+ "mtime": "2026-09-29T10:07:41.516Z",
5275
5135
  "size": 7889,
5276
5136
  "path": "../public/_nuxt/BBUBE1dy.js"
5277
5137
  },
5278
5138
  "/_nuxt/BBc9UKZt.js": {
5279
5139
  "type": "text/javascript; charset=utf-8",
5280
5140
  "etag": "\"69b-7FkyMvpdK8QgqiellgZa0BocbOw\"",
5281
- "mtime": "2026-09-25T13:28:52.537Z",
5141
+ "mtime": "2026-09-29T10:07:41.516Z",
5282
5142
  "size": 1691,
5283
5143
  "path": "../public/_nuxt/BBc9UKZt.js"
5284
5144
  },
5145
+ "/_nuxt/B9paGgN0.js": {
5146
+ "type": "text/javascript; charset=utf-8",
5147
+ "etag": "\"56eca-e9xiz0t6YGUSrKFkqLqIUFpbEEo\"",
5148
+ "mtime": "2026-09-29T10:07:41.516Z",
5149
+ "size": 356042,
5150
+ "path": "../public/_nuxt/B9paGgN0.js"
5151
+ },
5152
+ "/_nuxt/BCIlnd0g.js": {
5153
+ "type": "text/javascript; charset=utf-8",
5154
+ "etag": "\"da4-9e0fcNaKjL5BhIC8byfDE6+wS7Q\"",
5155
+ "mtime": "2026-09-29T10:07:41.516Z",
5156
+ "size": 3492,
5157
+ "path": "../public/_nuxt/BCIlnd0g.js"
5158
+ },
5285
5159
  "/_nuxt/BDtDVThU.js": {
5286
5160
  "type": "text/javascript; charset=utf-8",
5287
5161
  "etag": "\"8d8-tdOSVG0mR4S2JoHY+vUk3Ju14DM\"",
5288
- "mtime": "2026-09-25T13:28:52.537Z",
5162
+ "mtime": "2026-09-29T10:07:41.516Z",
5289
5163
  "size": 2264,
5290
5164
  "path": "../public/_nuxt/BDtDVThU.js"
5291
5165
  },
5292
- "/_nuxt/BD40YYqZ.js": {
5293
- "type": "text/javascript; charset=utf-8",
5294
- "etag": "\"56923-hedRQwgjudQIh9eHYRx0f8H57rM\"",
5295
- "mtime": "2026-09-25T13:28:52.537Z",
5296
- "size": 354595,
5297
- "path": "../public/_nuxt/BD40YYqZ.js"
5298
- },
5299
5166
  "/_nuxt/BEgZUVRK.js": {
5300
5167
  "type": "text/javascript; charset=utf-8",
5301
5168
  "etag": "\"1454-fqd1Il1nKLHt2iPsHLZ/Nx1xAt8\"",
5302
- "mtime": "2026-09-25T13:28:52.537Z",
5169
+ "mtime": "2026-09-29T10:07:41.516Z",
5303
5170
  "size": 5204,
5304
5171
  "path": "../public/_nuxt/BEgZUVRK.js"
5305
5172
  },
5306
5173
  "/_nuxt/BFxVWTOG.js": {
5307
5174
  "type": "text/javascript; charset=utf-8",
5308
5175
  "etag": "\"e42-Ti91WI2wfk479jJPLvNuO2MJ+jY\"",
5309
- "mtime": "2026-09-25T13:28:52.537Z",
5176
+ "mtime": "2026-09-29T10:07:41.516Z",
5310
5177
  "size": 3650,
5311
5178
  "path": "../public/_nuxt/BFxVWTOG.js"
5312
5179
  },
5313
5180
  "/_nuxt/BG73LgW2.js": {
5314
5181
  "type": "text/javascript; charset=utf-8",
5315
5182
  "etag": "\"6c3-JuIkJIg19gnyh5BltKBXx9CtvXI\"",
5316
- "mtime": "2026-09-25T13:28:52.537Z",
5183
+ "mtime": "2026-09-29T10:07:41.516Z",
5317
5184
  "size": 1731,
5318
5185
  "path": "../public/_nuxt/BG73LgW2.js"
5319
5186
  },
5187
+ "/_nuxt/BO4hqv6q.js": {
5188
+ "type": "text/javascript; charset=utf-8",
5189
+ "etag": "\"799-eI33w61PIIiT7XKUrpAPnb8BTYA\"",
5190
+ "mtime": "2026-09-29T10:07:41.516Z",
5191
+ "size": 1945,
5192
+ "path": "../public/_nuxt/BO4hqv6q.js"
5193
+ },
5194
+ "/_nuxt/BOsJJ_ZU.js": {
5195
+ "type": "text/javascript; charset=utf-8",
5196
+ "etag": "\"10f1-7SbN3Je7a2Fv0oqBnQswOt1oYJc\"",
5197
+ "mtime": "2026-09-29T10:07:41.516Z",
5198
+ "size": 4337,
5199
+ "path": "../public/_nuxt/BOsJJ_ZU.js"
5200
+ },
5320
5201
  "/_nuxt/BOtBlQCF.js": {
5321
5202
  "type": "text/javascript; charset=utf-8",
5322
5203
  "etag": "\"1010-rOMZ3v1/JH2RPnwfxLBlHoNhcjU\"",
5323
- "mtime": "2026-09-25T13:28:52.537Z",
5204
+ "mtime": "2026-09-29T10:07:41.516Z",
5324
5205
  "size": 4112,
5325
5206
  "path": "../public/_nuxt/BOtBlQCF.js"
5326
5207
  },
5327
5208
  "/_nuxt/BPhDTwHR.js": {
5328
5209
  "type": "text/javascript; charset=utf-8",
5329
5210
  "etag": "\"65d-nnBDUcRkn5FxqG4j7Ws9cb+Jbqg\"",
5330
- "mtime": "2026-09-25T13:28:52.537Z",
5211
+ "mtime": "2026-09-29T10:07:41.516Z",
5331
5212
  "size": 1629,
5332
5213
  "path": "../public/_nuxt/BPhDTwHR.js"
5333
5214
  },
5334
5215
  "/_nuxt/BTesnYfV.js": {
5335
5216
  "type": "text/javascript; charset=utf-8",
5336
5217
  "etag": "\"1c2a-TdSFrM2B/G8uIhtdAwwad7rkLKo\"",
5337
- "mtime": "2026-09-25T13:28:52.537Z",
5218
+ "mtime": "2026-09-29T10:07:41.516Z",
5338
5219
  "size": 7210,
5339
5220
  "path": "../public/_nuxt/BTesnYfV.js"
5340
5221
  },
5341
- "/_nuxt/Bd32GOUy.js": {
5342
- "type": "text/javascript; charset=utf-8",
5343
- "etag": "\"10f1-OamFKgmqOIVz6VHeN0JJf2Af66g\"",
5344
- "mtime": "2026-09-25T13:28:52.538Z",
5345
- "size": 4337,
5346
- "path": "../public/_nuxt/Bd32GOUy.js"
5347
- },
5348
5222
  "/_nuxt/BbWJElDN.js": {
5349
5223
  "type": "text/javascript; charset=utf-8",
5350
5224
  "etag": "\"142a-gcnvXQkw+BLtDirIDN1qoykZ1eQ\"",
5351
- "mtime": "2026-09-25T13:28:52.538Z",
5225
+ "mtime": "2026-09-29T10:07:41.516Z",
5352
5226
  "size": 5162,
5353
5227
  "path": "../public/_nuxt/BbWJElDN.js"
5354
5228
  },
5355
5229
  "/_nuxt/Bd8akH9Z.js": {
5356
5230
  "type": "text/javascript; charset=utf-8",
5357
5231
  "etag": "\"d7c-qPEaxTe1e/19xQbh0bDW+7GABkM\"",
5358
- "mtime": "2026-09-25T13:28:52.538Z",
5232
+ "mtime": "2026-09-29T10:07:41.516Z",
5359
5233
  "size": 3452,
5360
5234
  "path": "../public/_nuxt/Bd8akH9Z.js"
5361
5235
  },
5362
5236
  "/_nuxt/BeJ5waoc.js": {
5363
5237
  "type": "text/javascript; charset=utf-8",
5364
5238
  "etag": "\"688-fDBCazkBE0Ve++r7xTYqSjIHPqw\"",
5365
- "mtime": "2026-09-25T13:28:52.538Z",
5239
+ "mtime": "2026-09-29T10:07:41.516Z",
5366
5240
  "size": 1672,
5367
5241
  "path": "../public/_nuxt/BeJ5waoc.js"
5368
5242
  },
5369
5243
  "/_nuxt/Bf6VGUru.js": {
5370
5244
  "type": "text/javascript; charset=utf-8",
5371
5245
  "etag": "\"7ff-Gv7mpIJ7ZogR82C4wudMW57LNnQ\"",
5372
- "mtime": "2026-09-25T13:28:52.538Z",
5246
+ "mtime": "2026-09-29T10:07:41.516Z",
5373
5247
  "size": 2047,
5374
5248
  "path": "../public/_nuxt/Bf6VGUru.js"
5375
5249
  },
5376
- "/_nuxt/BkW5O-1t.js": {
5377
- "type": "text/javascript; charset=utf-8",
5378
- "etag": "\"2787-G/iQTgRGWNywui88yVOLY64apsc\"",
5379
- "mtime": "2026-09-25T13:28:52.538Z",
5380
- "size": 10119,
5381
- "path": "../public/_nuxt/BkW5O-1t.js"
5382
- },
5383
5250
  "/_nuxt/BlNEE0v7.js": {
5384
5251
  "type": "text/javascript; charset=utf-8",
5385
5252
  "etag": "\"340e-XPsjtSBMxJFSpwO3KLzzTelAc8c\"",
5386
- "mtime": "2026-09-25T13:28:52.538Z",
5253
+ "mtime": "2026-09-29T10:07:41.517Z",
5387
5254
  "size": 13326,
5388
5255
  "path": "../public/_nuxt/BlNEE0v7.js"
5389
5256
  },
5390
- "/_nuxt/BlQmLjV4.js": {
5391
- "type": "text/javascript; charset=utf-8",
5392
- "etag": "\"bc2-KuJXcJjmPIC5DAHSoVQ5jQLM1T0\"",
5393
- "mtime": "2026-09-25T13:28:52.538Z",
5394
- "size": 3010,
5395
- "path": "../public/_nuxt/BlQmLjV4.js"
5396
- },
5397
- "/_nuxt/Bs9aos_-.js": {
5257
+ "/_nuxt/BkW5O-1t.js": {
5398
5258
  "type": "text/javascript; charset=utf-8",
5399
- "etag": "\"2d8e-+OAf34Vqp9asPVr2gIyoXG3h7rw\"",
5400
- "mtime": "2026-09-25T13:28:52.538Z",
5401
- "size": 11662,
5402
- "path": "../public/_nuxt/Bs9aos_-.js"
5259
+ "etag": "\"2787-G/iQTgRGWNywui88yVOLY64apsc\"",
5260
+ "mtime": "2026-09-29T10:07:41.516Z",
5261
+ "size": 10119,
5262
+ "path": "../public/_nuxt/BkW5O-1t.js"
5403
5263
  },
5404
5264
  "/_nuxt/Brw8urJB.js": {
5405
5265
  "type": "text/javascript; charset=utf-8",
5406
5266
  "etag": "\"22cc-KnaOFvwgeCLBSd9UO2qvWVfHCX0\"",
5407
- "mtime": "2026-09-25T13:28:52.538Z",
5267
+ "mtime": "2026-09-29T10:07:41.516Z",
5408
5268
  "size": 8908,
5409
5269
  "path": "../public/_nuxt/Brw8urJB.js"
5410
5270
  },
5271
+ "/_nuxt/Bs9aos_-.js": {
5272
+ "type": "text/javascript; charset=utf-8",
5273
+ "etag": "\"2d8e-+OAf34Vqp9asPVr2gIyoXG3h7rw\"",
5274
+ "mtime": "2026-09-29T10:07:41.517Z",
5275
+ "size": 11662,
5276
+ "path": "../public/_nuxt/Bs9aos_-.js"
5277
+ },
5411
5278
  "/_nuxt/Bs9z6M-B.js": {
5412
5279
  "type": "text/javascript; charset=utf-8",
5413
5280
  "etag": "\"1d29-5OK7B2BhDsF1oIZMdmoxMRvjYjc\"",
5414
- "mtime": "2026-09-25T13:28:52.538Z",
5281
+ "mtime": "2026-09-29T10:07:41.517Z",
5415
5282
  "size": 7465,
5416
5283
  "path": "../public/_nuxt/Bs9z6M-B.js"
5417
5284
  },
5418
5285
  "/_nuxt/Btyra-wh.js": {
5419
5286
  "type": "text/javascript; charset=utf-8",
5420
5287
  "etag": "\"a62-n03ZFcwvHyVBGpaAPL8sTXCL3xM\"",
5421
- "mtime": "2026-09-25T13:28:52.538Z",
5288
+ "mtime": "2026-09-29T10:07:41.517Z",
5422
5289
  "size": 2658,
5423
5290
  "path": "../public/_nuxt/Btyra-wh.js"
5424
5291
  },
5425
- "/_nuxt/Bw9ernYp.js": {
5426
- "type": "text/javascript; charset=utf-8",
5427
- "etag": "\"beb-Y9DS887GVG7a2J92jf1FP7iT67I\"",
5428
- "mtime": "2026-09-25T13:28:52.538Z",
5429
- "size": 3051,
5430
- "path": "../public/_nuxt/Bw9ernYp.js"
5431
- },
5432
5292
  "/_nuxt/Bu5POkcn.js": {
5433
5293
  "type": "text/javascript; charset=utf-8",
5434
5294
  "etag": "\"d5a-eK38bQbEiAw/HGqXBvNq08kZZG4\"",
5435
- "mtime": "2026-09-25T13:28:52.538Z",
5295
+ "mtime": "2026-09-29T10:07:41.517Z",
5436
5296
  "size": 3418,
5437
5297
  "path": "../public/_nuxt/Bu5POkcn.js"
5438
5298
  },
5439
- "/_nuxt/BwHxbl9M.js": {
5299
+ "/_nuxt/Bw9ernYp.js": {
5440
5300
  "type": "text/javascript; charset=utf-8",
5441
- "etag": "\"6ab-PLn3WC0GPBiY30NiFfKEp4+1mkk\"",
5442
- "mtime": "2026-09-25T13:28:52.538Z",
5443
- "size": 1707,
5444
- "path": "../public/_nuxt/BwHxbl9M.js"
5301
+ "etag": "\"beb-Y9DS887GVG7a2J92jf1FP7iT67I\"",
5302
+ "mtime": "2026-09-29T10:07:41.517Z",
5303
+ "size": 3051,
5304
+ "path": "../public/_nuxt/Bw9ernYp.js"
5445
5305
  },
5446
5306
  "/_nuxt/BxJiqAUM.js": {
5447
5307
  "type": "text/javascript; charset=utf-8",
5448
5308
  "etag": "\"84a-uI9yfgCiugU9v7cHcK25l+a5KzU\"",
5449
- "mtime": "2026-09-25T13:28:52.538Z",
5309
+ "mtime": "2026-09-29T10:07:41.517Z",
5450
5310
  "size": 2122,
5451
5311
  "path": "../public/_nuxt/BxJiqAUM.js"
5452
5312
  },
5453
- "/_nuxt/BzhSDy30.js": {
5313
+ "/_nuxt/BwHxbl9M.js": {
5454
5314
  "type": "text/javascript; charset=utf-8",
5455
- "etag": "\"327-ui0Sl3iyiKvgKRvJeo7bFLrGSDw\"",
5456
- "mtime": "2026-09-25T13:28:52.538Z",
5457
- "size": 807,
5458
- "path": "../public/_nuxt/BzhSDy30.js"
5315
+ "etag": "\"6ab-PLn3WC0GPBiY30NiFfKEp4+1mkk\"",
5316
+ "mtime": "2026-09-29T10:07:41.517Z",
5317
+ "size": 1707,
5318
+ "path": "../public/_nuxt/BwHxbl9M.js"
5459
5319
  },
5460
5320
  "/_nuxt/BzKRNQWT.js": {
5461
5321
  "type": "text/javascript; charset=utf-8",
5462
5322
  "etag": "\"fb6-0/zdhyEwcnC+KUfsLQHqqIquIRI\"",
5463
- "mtime": "2026-09-25T13:28:52.538Z",
5323
+ "mtime": "2026-09-29T10:07:41.518Z",
5464
5324
  "size": 4022,
5465
5325
  "path": "../public/_nuxt/BzKRNQWT.js"
5466
5326
  },
5467
- "/_nuxt/CBJaRo0y.js": {
5327
+ "/_nuxt/C2BHp-MG.js": {
5468
5328
  "type": "text/javascript; charset=utf-8",
5469
- "etag": "\"187f-TAOu7M5TSNFZv9eK6WPfKQutcjg\"",
5470
- "mtime": "2026-09-25T13:28:52.538Z",
5471
- "size": 6271,
5472
- "path": "../public/_nuxt/CBJaRo0y.js"
5473
- },
5474
- "/_nuxt/CAd-qHfI.js": {
5475
- "type": "text/javascript; charset=utf-8",
5476
- "etag": "\"7005-JJPIve5nARMZBn5XSG4tpEWXo+g\"",
5477
- "mtime": "2026-09-25T13:28:52.538Z",
5478
- "size": 28677,
5479
- "path": "../public/_nuxt/CAd-qHfI.js"
5480
- },
5481
- "/_nuxt/CC3n3Aga.js": {
5482
- "type": "text/javascript; charset=utf-8",
5483
- "etag": "\"2076-x3FNiziqiW+mbzj8WvSLRvrz4YU\"",
5484
- "mtime": "2026-09-25T13:28:52.538Z",
5485
- "size": 8310,
5486
- "path": "../public/_nuxt/CC3n3Aga.js"
5329
+ "etag": "\"327-RwEiytRh/LVFdN6TnD8WzFX+28s\"",
5330
+ "mtime": "2026-09-29T10:07:41.517Z",
5331
+ "size": 807,
5332
+ "path": "../public/_nuxt/C2BHp-MG.js"
5487
5333
  },
5488
5334
  "/_nuxt/CFznDFnq.js": {
5489
5335
  "type": "text/javascript; charset=utf-8",
5490
5336
  "etag": "\"95e-Ym6ce0oG7iVD2TvmuRd+y0a2LVg\"",
5491
- "mtime": "2026-09-25T13:28:52.538Z",
5337
+ "mtime": "2026-09-29T10:07:41.518Z",
5492
5338
  "size": 2398,
5493
5339
  "path": "../public/_nuxt/CFznDFnq.js"
5494
5340
  },
5495
5341
  "/_nuxt/CHwy0fLd.js": {
5496
5342
  "type": "text/javascript; charset=utf-8",
5497
5343
  "etag": "\"1c5d-fsu8CSsQUjWWmWJ6QyDe2G8Hvbs\"",
5498
- "mtime": "2026-09-25T13:28:52.538Z",
5344
+ "mtime": "2026-09-29T10:07:41.518Z",
5499
5345
  "size": 7261,
5500
5346
  "path": "../public/_nuxt/CHwy0fLd.js"
5501
5347
  },
5502
- "/_nuxt/CJ4Cv9fY.js": {
5503
- "type": "text/javascript; charset=utf-8",
5504
- "etag": "\"79eb-cnTfPRsyK2s6W3iOTctPDafog9M\"",
5505
- "mtime": "2026-09-25T13:28:52.538Z",
5506
- "size": 31211,
5507
- "path": "../public/_nuxt/CJ4Cv9fY.js"
5508
- },
5509
5348
  "/_nuxt/CJmd_6j2.js": {
5510
5349
  "type": "text/javascript; charset=utf-8",
5511
5350
  "etag": "\"96e-3trx2EbkUMYYdVFbsrCcpVQWXVI\"",
5512
- "mtime": "2026-09-25T13:28:52.538Z",
5351
+ "mtime": "2026-09-29T10:07:41.518Z",
5513
5352
  "size": 2414,
5514
5353
  "path": "../public/_nuxt/CJmd_6j2.js"
5515
5354
  },
5516
- "/_nuxt/CNZorjDf.js": {
5355
+ "/_nuxt/CBJaRo0y.js": {
5517
5356
  "type": "text/javascript; charset=utf-8",
5518
- "etag": "\"18a2-okS33ebURJ8z5Gwylvr9El0iZz8\"",
5519
- "mtime": "2026-09-25T13:28:52.538Z",
5520
- "size": 6306,
5521
- "path": "../public/_nuxt/CNZorjDf.js"
5357
+ "etag": "\"187f-TAOu7M5TSNFZv9eK6WPfKQutcjg\"",
5358
+ "mtime": "2026-09-29T10:07:41.517Z",
5359
+ "size": 6271,
5360
+ "path": "../public/_nuxt/CBJaRo0y.js"
5361
+ },
5362
+ "/_nuxt/CKULsFUz.js": {
5363
+ "type": "text/javascript; charset=utf-8",
5364
+ "etag": "\"e99-qvywJf2UXHFqlUW8Qi1HMkr4arM\"",
5365
+ "mtime": "2026-09-29T10:07:41.518Z",
5366
+ "size": 3737,
5367
+ "path": "../public/_nuxt/CKULsFUz.js"
5368
+ },
5369
+ "/_nuxt/CMH9iX_E.js": {
5370
+ "type": "text/javascript; charset=utf-8",
5371
+ "etag": "\"17ac5-Ycd0rS0hldu2UkjiIgm8BXAF5HM\"",
5372
+ "mtime": "2026-09-29T10:07:41.518Z",
5373
+ "size": 96965,
5374
+ "path": "../public/_nuxt/CMH9iX_E.js"
5522
5375
  },
5523
5376
  "/_nuxt/COWaemsV.js": {
5524
5377
  "type": "text/javascript; charset=utf-8",
5525
5378
  "etag": "\"c3b-tOwJ5hUYWQ08zZb3SQ5ZGujJOhQ\"",
5526
- "mtime": "2026-09-25T13:28:52.538Z",
5379
+ "mtime": "2026-09-29T10:07:41.518Z",
5527
5380
  "size": 3131,
5528
5381
  "path": "../public/_nuxt/COWaemsV.js"
5529
5382
  },
5530
5383
  "/_nuxt/CXBNlu9o.js": {
5531
5384
  "type": "text/javascript; charset=utf-8",
5532
5385
  "etag": "\"c0b-a/8ur+Uvnhetml4WhYTeUvZcdPQ\"",
5533
- "mtime": "2026-09-25T13:28:52.538Z",
5386
+ "mtime": "2026-09-29T10:07:41.518Z",
5534
5387
  "size": 3083,
5535
5388
  "path": "../public/_nuxt/CXBNlu9o.js"
5536
5389
  },
5537
5390
  "/_nuxt/C_tMU-Nz.js": {
5538
5391
  "type": "text/javascript; charset=utf-8",
5539
5392
  "etag": "\"2b80-Hzdx+2Wi4L4QzSXNdWmXzbSERYo\"",
5540
- "mtime": "2026-09-25T13:28:52.538Z",
5393
+ "mtime": "2026-09-29T10:07:41.518Z",
5541
5394
  "size": 11136,
5542
5395
  "path": "../public/_nuxt/C_tMU-Nz.js"
5543
5396
  },
5544
- "/_nuxt/Ce-T_1aD.js": {
5545
- "type": "text/javascript; charset=utf-8",
5546
- "etag": "\"799-iUatXy1gcxzrLKPC9xGvT/SEHxE\"",
5547
- "mtime": "2026-09-25T13:28:52.538Z",
5548
- "size": 1945,
5549
- "path": "../public/_nuxt/Ce-T_1aD.js"
5550
- },
5551
5397
  "/_nuxt/CiqrrVzr.js": {
5552
5398
  "type": "text/javascript; charset=utf-8",
5553
5399
  "etag": "\"989-Blq/VGs6v4RnRWlMonYeDSId2O0\"",
5554
- "mtime": "2026-09-25T13:28:52.539Z",
5400
+ "mtime": "2026-09-29T10:07:41.518Z",
5555
5401
  "size": 2441,
5556
5402
  "path": "../public/_nuxt/CiqrrVzr.js"
5557
5403
  },
5558
5404
  "/_nuxt/ClhHkBeG.js": {
5559
5405
  "type": "text/javascript; charset=utf-8",
5560
5406
  "etag": "\"27af-nRsYy/UEQy/wu/d8+EL49MBHHFM\"",
5561
- "mtime": "2026-09-25T13:28:52.539Z",
5407
+ "mtime": "2026-09-29T10:07:41.518Z",
5562
5408
  "size": 10159,
5563
5409
  "path": "../public/_nuxt/ClhHkBeG.js"
5564
5410
  },
5411
+ "/_nuxt/CnS9iZB_.js": {
5412
+ "type": "text/javascript; charset=utf-8",
5413
+ "etag": "\"a42-QYFMl2/kiGHCTk16FYDXZVG3s9s\"",
5414
+ "mtime": "2026-09-29T10:07:41.518Z",
5415
+ "size": 2626,
5416
+ "path": "../public/_nuxt/CnS9iZB_.js"
5417
+ },
5565
5418
  "/_nuxt/CnmFD0ga.js": {
5566
5419
  "type": "text/javascript; charset=utf-8",
5567
5420
  "etag": "\"12a6-OamqOWlZ20f/sgLqwvaTuGvLE+I\"",
5568
- "mtime": "2026-09-25T13:28:52.539Z",
5421
+ "mtime": "2026-09-29T10:07:41.519Z",
5569
5422
  "size": 4774,
5570
5423
  "path": "../public/_nuxt/CnmFD0ga.js"
5571
5424
  },
5572
5425
  "/_nuxt/Co3qMtFm.js": {
5573
5426
  "type": "text/javascript; charset=utf-8",
5574
5427
  "etag": "\"1122-VLYaFYADytCHkH1byjlwnEwqLNM\"",
5575
- "mtime": "2026-09-25T13:28:52.539Z",
5428
+ "mtime": "2026-09-29T10:07:41.519Z",
5576
5429
  "size": 4386,
5577
5430
  "path": "../public/_nuxt/Co3qMtFm.js"
5578
5431
  },
5579
- "/_nuxt/CnS9iZB_.js": {
5432
+ "/_nuxt/CocnycG-.js": {
5580
5433
  "type": "text/javascript; charset=utf-8",
5581
- "etag": "\"a42-QYFMl2/kiGHCTk16FYDXZVG3s9s\"",
5582
- "mtime": "2026-09-25T13:28:52.539Z",
5583
- "size": 2626,
5584
- "path": "../public/_nuxt/CnS9iZB_.js"
5434
+ "etag": "\"1e26-FFwOFKedG3tL3W0yLs13Oq+kp1s\"",
5435
+ "mtime": "2026-09-29T10:07:41.519Z",
5436
+ "size": 7718,
5437
+ "path": "../public/_nuxt/CocnycG-.js"
5585
5438
  },
5586
5439
  "/_nuxt/CqXO7rUv.js": {
5587
5440
  "type": "text/javascript; charset=utf-8",
5588
5441
  "etag": "\"eab-1axeWc9wAjztE3YuOaJpDZ7ZbBE\"",
5589
- "mtime": "2026-09-25T13:28:52.539Z",
5442
+ "mtime": "2026-09-29T10:07:41.519Z",
5590
5443
  "size": 3755,
5591
5444
  "path": "../public/_nuxt/CqXO7rUv.js"
5592
5445
  },
5593
- "/_nuxt/Cs8GXJCB.js": {
5594
- "type": "text/javascript; charset=utf-8",
5595
- "etag": "\"e99-T/l1MP2oc8DECTZCrCCCRwXGGb8\"",
5596
- "mtime": "2026-09-25T13:28:52.539Z",
5597
- "size": 3737,
5598
- "path": "../public/_nuxt/Cs8GXJCB.js"
5599
- },
5600
- "/_nuxt/CocnycG-.js": {
5601
- "type": "text/javascript; charset=utf-8",
5602
- "etag": "\"1e26-FFwOFKedG3tL3W0yLs13Oq+kp1s\"",
5603
- "mtime": "2026-09-25T13:28:52.539Z",
5604
- "size": 7718,
5605
- "path": "../public/_nuxt/CocnycG-.js"
5606
- },
5607
5446
  "/_nuxt/Csy3S7wG.js": {
5608
5447
  "type": "text/javascript; charset=utf-8",
5609
5448
  "etag": "\"16cb-xilhkn1Hlq6beJlDBqY4Z/7dbFQ\"",
5610
- "mtime": "2026-09-25T13:28:52.539Z",
5449
+ "mtime": "2026-09-29T10:07:41.519Z",
5611
5450
  "size": 5835,
5612
5451
  "path": "../public/_nuxt/Csy3S7wG.js"
5613
5452
  },
5614
5453
  "/_nuxt/Cyyb5UIc.js": {
5615
5454
  "type": "text/javascript; charset=utf-8",
5616
5455
  "etag": "\"7c1-mK4SLHO4wVeiYlM0Pl6H409caeI\"",
5617
- "mtime": "2026-09-25T13:28:52.539Z",
5456
+ "mtime": "2026-09-29T10:07:41.519Z",
5618
5457
  "size": 1985,
5619
5458
  "path": "../public/_nuxt/Cyyb5UIc.js"
5620
5459
  },
5621
- "/_nuxt/D9hQfWCl.js": {
5460
+ "/_nuxt/BNDnV2op.js": {
5622
5461
  "type": "text/javascript; charset=utf-8",
5623
- "etag": "\"1c0c-s+MlVwUDxaubGuMUOEzLtrq2AP4\"",
5624
- "mtime": "2026-09-25T13:28:52.539Z",
5625
- "size": 7180,
5626
- "path": "../public/_nuxt/D9hQfWCl.js"
5462
+ "etag": "\"38106e-c1pNyjpbxdfhjaYfg990JH/EhQA\"",
5463
+ "mtime": "2026-09-29T10:07:41.517Z",
5464
+ "size": 3674222,
5465
+ "path": "../public/_nuxt/BNDnV2op.js"
5466
+ },
5467
+ "/_nuxt/CzbCpNnc.js": {
5468
+ "type": "text/javascript; charset=utf-8",
5469
+ "etag": "\"560b-ihdpIFyS0NS/Fvue57VEkHWQe4E\"",
5470
+ "mtime": "2026-09-29T10:07:41.519Z",
5471
+ "size": 22027,
5472
+ "path": "../public/_nuxt/CzbCpNnc.js"
5627
5473
  },
5628
5474
  "/_nuxt/D-4FJmMZ.js": {
5629
5475
  "type": "text/javascript; charset=utf-8",
5630
5476
  "etag": "\"501-fRMALPoL/H3CwAldqFY/RaJHYHY\"",
5631
- "mtime": "2026-09-25T13:28:52.539Z",
5477
+ "mtime": "2026-09-29T10:07:41.519Z",
5632
5478
  "size": 1281,
5633
5479
  "path": "../public/_nuxt/D-4FJmMZ.js"
5634
5480
  },
5481
+ "/_nuxt/D9hQfWCl.js": {
5482
+ "type": "text/javascript; charset=utf-8",
5483
+ "etag": "\"1c0c-s+MlVwUDxaubGuMUOEzLtrq2AP4\"",
5484
+ "mtime": "2026-09-29T10:07:41.519Z",
5485
+ "size": 7180,
5486
+ "path": "../public/_nuxt/D9hQfWCl.js"
5487
+ },
5488
+ "/_nuxt/DA0pQuyP.js": {
5489
+ "type": "text/javascript; charset=utf-8",
5490
+ "etag": "\"45db-4UDtgyPOYvKM8VqPZeWY6xJU1j8\"",
5491
+ "mtime": "2026-09-29T10:07:41.519Z",
5492
+ "size": 17883,
5493
+ "path": "../public/_nuxt/DA0pQuyP.js"
5494
+ },
5495
+ "/_nuxt/D87QMS6j.js": {
5496
+ "type": "text/javascript; charset=utf-8",
5497
+ "etag": "\"2076-bxAiRSz5wxHP+rt/PP1LXpnaHCI\"",
5498
+ "mtime": "2026-09-29T10:07:41.519Z",
5499
+ "size": 8310,
5500
+ "path": "../public/_nuxt/D87QMS6j.js"
5501
+ },
5635
5502
  "/_nuxt/DLDM7-KI.js": {
5636
5503
  "type": "text/javascript; charset=utf-8",
5637
5504
  "etag": "\"36c9-NeGvJyvUtaEi2zP8TTycIoN+9ik\"",
5638
- "mtime": "2026-09-25T13:28:52.539Z",
5505
+ "mtime": "2026-09-29T10:07:41.519Z",
5639
5506
  "size": 14025,
5640
5507
  "path": "../public/_nuxt/DLDM7-KI.js"
5641
5508
  },
5642
5509
  "/_nuxt/DNDY2TF8.js": {
5643
5510
  "type": "text/javascript; charset=utf-8",
5644
5511
  "etag": "\"eec-/y88b7oP/vv7ucqPwLxQGQfzNRs\"",
5645
- "mtime": "2026-09-25T13:28:52.539Z",
5512
+ "mtime": "2026-09-29T10:07:41.519Z",
5646
5513
  "size": 3820,
5647
5514
  "path": "../public/_nuxt/DNDY2TF8.js"
5648
5515
  },
5649
5516
  "/_nuxt/DSh2-awV.js": {
5650
5517
  "type": "text/javascript; charset=utf-8",
5651
5518
  "etag": "\"609-gma5J4AsxYswFMs9/q2hPWeL3/w\"",
5652
- "mtime": "2026-09-25T13:28:52.539Z",
5519
+ "mtime": "2026-09-29T10:07:41.519Z",
5653
5520
  "size": 1545,
5654
5521
  "path": "../public/_nuxt/DSh2-awV.js"
5655
5522
  },
5656
5523
  "/_nuxt/Db0IVjzk.js": {
5657
5524
  "type": "text/javascript; charset=utf-8",
5658
5525
  "etag": "\"481b-h+EMNByZJtiUhHL2111jzdwomeU\"",
5659
- "mtime": "2026-09-25T13:28:52.539Z",
5526
+ "mtime": "2026-09-29T10:07:41.519Z",
5660
5527
  "size": 18459,
5661
5528
  "path": "../public/_nuxt/Db0IVjzk.js"
5662
5529
  },
5663
5530
  "/_nuxt/Db0cS2oM.js": {
5664
5531
  "type": "text/javascript; charset=utf-8",
5665
5532
  "etag": "\"1615-zFLqA9G3tON1fz/HkCc2t3XjQjI\"",
5666
- "mtime": "2026-09-25T13:28:52.539Z",
5533
+ "mtime": "2026-09-29T10:07:41.519Z",
5667
5534
  "size": 5653,
5668
5535
  "path": "../public/_nuxt/Db0cS2oM.js"
5669
5536
  },
5537
+ "/_nuxt/DcJ7oPvZ.js": {
5538
+ "type": "text/javascript; charset=utf-8",
5539
+ "etag": "\"1337-zaMtR7IXphNa76fOD4sXiTVMAb4\"",
5540
+ "mtime": "2026-09-29T10:07:41.519Z",
5541
+ "size": 4919,
5542
+ "path": "../public/_nuxt/DcJ7oPvZ.js"
5543
+ },
5670
5544
  "/_nuxt/DdJfP1eB.js": {
5671
5545
  "type": "text/javascript; charset=utf-8",
5672
5546
  "etag": "\"1114-ZiGCRyVUVmAnLZKAbaKEl8oGrBE\"",
5673
- "mtime": "2026-09-25T13:28:52.539Z",
5547
+ "mtime": "2026-09-29T10:07:41.519Z",
5674
5548
  "size": 4372,
5675
5549
  "path": "../public/_nuxt/DdJfP1eB.js"
5676
5550
  },
5677
5551
  "/_nuxt/DiJ1NA_G.js": {
5678
5552
  "type": "text/javascript; charset=utf-8",
5679
5553
  "etag": "\"b77-27guNmtnqK26sUIdwjV/UWag06k\"",
5680
- "mtime": "2026-09-25T13:28:52.539Z",
5554
+ "mtime": "2026-09-29T10:07:41.519Z",
5681
5555
  "size": 2935,
5682
5556
  "path": "../public/_nuxt/DiJ1NA_G.js"
5683
5557
  },
5684
- "/_nuxt/DjPT-NCE.js": {
5558
+ "/_nuxt/Dce9SnGa.js": {
5685
5559
  "type": "text/javascript; charset=utf-8",
5686
- "etag": "\"11c2-z7kpc7An5gCVQINi/mbGALLBB/g\"",
5687
- "mtime": "2026-09-25T13:28:52.539Z",
5688
- "size": 4546,
5689
- "path": "../public/_nuxt/DjPT-NCE.js"
5560
+ "etag": "\"3cfa-wFhzWg18vfmDZCFgACJn/hAo4PM\"",
5561
+ "mtime": "2026-09-29T10:07:41.519Z",
5562
+ "size": 15610,
5563
+ "path": "../public/_nuxt/Dce9SnGa.js"
5690
5564
  },
5691
5565
  "/_nuxt/Dm6ycUr_.js": {
5692
5566
  "type": "text/javascript; charset=utf-8",
5693
5567
  "etag": "\"d69-uvm/T2W7Zql8b4WevPWGxDp31GA\"",
5694
- "mtime": "2026-09-25T13:28:52.539Z",
5568
+ "mtime": "2026-09-29T10:07:41.519Z",
5695
5569
  "size": 3433,
5696
5570
  "path": "../public/_nuxt/Dm6ycUr_.js"
5697
5571
  },
5698
- "/_nuxt/DtV1sZF8.js": {
5699
- "type": "text/javascript; charset=utf-8",
5700
- "etag": "\"d7c-TF/n+eds/qat+FOhi4LDKi7HsQk\"",
5701
- "mtime": "2026-09-25T13:28:52.539Z",
5702
- "size": 3452,
5703
- "path": "../public/_nuxt/DtV1sZF8.js"
5704
- },
5705
5572
  "/_nuxt/DmeGPVcC.js": {
5706
5573
  "type": "text/javascript; charset=utf-8",
5707
5574
  "etag": "\"12a6-IpV48Cn+k80cDAztUr4cVZAz7fk\"",
5708
- "mtime": "2026-09-25T13:28:52.539Z",
5575
+ "mtime": "2026-09-29T10:07:41.519Z",
5709
5576
  "size": 4774,
5710
5577
  "path": "../public/_nuxt/DmeGPVcC.js"
5711
5578
  },
5712
- "/_nuxt/DtZ0uQbO.js": {
5713
- "type": "text/javascript; charset=utf-8",
5714
- "etag": "\"746-RUOXngPrXM//PuRICAmsc/faYQs\"",
5715
- "mtime": "2026-09-25T13:28:52.539Z",
5716
- "size": 1862,
5717
- "path": "../public/_nuxt/DtZ0uQbO.js"
5718
- },
5719
5579
  "/_nuxt/Dnu-v4kV.js": {
5720
5580
  "type": "text/javascript; charset=utf-8",
5721
5581
  "etag": "\"2521-BhMCxe+LzVWeIAHwh4q7WDF+zMc\"",
5722
- "mtime": "2026-09-25T13:28:52.539Z",
5582
+ "mtime": "2026-09-29T10:07:41.519Z",
5723
5583
  "size": 9505,
5724
5584
  "path": "../public/_nuxt/Dnu-v4kV.js"
5725
5585
  },
5726
- "/_nuxt/Ick_23I4.js": {
5586
+ "/_nuxt/DpKrXpkK.js": {
5727
5587
  "type": "text/javascript; charset=utf-8",
5728
- "etag": "\"3cfa-Zb456X275yc3q5QNPCriOZkZVIs\"",
5729
- "mtime": "2026-09-25T13:28:52.539Z",
5730
- "size": 15610,
5731
- "path": "../public/_nuxt/Ick_23I4.js"
5588
+ "etag": "\"7005-3CJRucz00w5zUnQ3yVpCjSYie6o\"",
5589
+ "mtime": "2026-09-29T10:07:41.519Z",
5590
+ "size": 28677,
5591
+ "path": "../public/_nuxt/DpKrXpkK.js"
5732
5592
  },
5733
- "/_nuxt/IxYCG8hB.js": {
5593
+ "/_nuxt/DsnIpnT9.js": {
5734
5594
  "type": "text/javascript; charset=utf-8",
5735
- "etag": "\"da4-phEvdqB4N7tuweI/VozSLFJlqbQ\"",
5736
- "mtime": "2026-09-25T13:28:52.539Z",
5737
- "size": 3492,
5738
- "path": "../public/_nuxt/IxYCG8hB.js"
5595
+ "etag": "\"da8-6OksCyx5weCwY3SBsIVkW+1i4QU\"",
5596
+ "mtime": "2026-09-29T10:07:41.519Z",
5597
+ "size": 3496,
5598
+ "path": "../public/_nuxt/DsnIpnT9.js"
5739
5599
  },
5740
- "/_nuxt/OrD6JF1K.js": {
5600
+ "/_nuxt/DtV1sZF8.js": {
5741
5601
  "type": "text/javascript; charset=utf-8",
5742
- "etag": "\"8fb-KiGVisOmak2as1VB/uqwEGIKDpw\"",
5743
- "mtime": "2026-09-25T13:28:52.539Z",
5744
- "size": 2299,
5745
- "path": "../public/_nuxt/OrD6JF1K.js"
5602
+ "etag": "\"d7c-TF/n+eds/qat+FOhi4LDKi7HsQk\"",
5603
+ "mtime": "2026-09-29T10:07:41.519Z",
5604
+ "size": 3452,
5605
+ "path": "../public/_nuxt/DtV1sZF8.js"
5606
+ },
5607
+ "/_nuxt/I3Ucam2s.js": {
5608
+ "type": "text/javascript; charset=utf-8",
5609
+ "etag": "\"18a2-GXDc4vsbYze1LAjdHWSSweXYsCw\"",
5610
+ "mtime": "2026-09-29T10:07:41.519Z",
5611
+ "size": 6306,
5612
+ "path": "../public/_nuxt/I3Ucam2s.js"
5613
+ },
5614
+ "/_nuxt/DtZ0uQbO.js": {
5615
+ "type": "text/javascript; charset=utf-8",
5616
+ "etag": "\"746-RUOXngPrXM//PuRICAmsc/faYQs\"",
5617
+ "mtime": "2026-09-29T10:07:41.519Z",
5618
+ "size": 1862,
5619
+ "path": "../public/_nuxt/DtZ0uQbO.js"
5746
5620
  },
5747
5621
  "/_nuxt/Kd9XrMLS.js": {
5748
5622
  "type": "text/javascript; charset=utf-8",
5749
5623
  "etag": "\"3c3-UDltCtijZU7FawMyNTyHB77jOcQ\"",
5750
- "mtime": "2026-09-25T13:28:52.539Z",
5624
+ "mtime": "2026-09-29T10:07:41.519Z",
5751
5625
  "size": 963,
5752
5626
  "path": "../public/_nuxt/Kd9XrMLS.js"
5753
5627
  },
5628
+ "/_nuxt/OrD6JF1K.js": {
5629
+ "type": "text/javascript; charset=utf-8",
5630
+ "etag": "\"8fb-KiGVisOmak2as1VB/uqwEGIKDpw\"",
5631
+ "mtime": "2026-09-29T10:07:41.520Z",
5632
+ "size": 2299,
5633
+ "path": "../public/_nuxt/OrD6JF1K.js"
5634
+ },
5754
5635
  "/_nuxt/PahG7c26.js": {
5755
5636
  "type": "text/javascript; charset=utf-8",
5756
5637
  "etag": "\"b1d-bWlWeI4121TNED4AHZm9XOKmyVY\"",
5757
- "mtime": "2026-09-25T13:28:52.539Z",
5638
+ "mtime": "2026-09-29T10:07:41.520Z",
5758
5639
  "size": 2845,
5759
5640
  "path": "../public/_nuxt/PahG7c26.js"
5760
5641
  },
5761
5642
  "/_nuxt/Y6nb8tq_.js": {
5762
5643
  "type": "text/javascript; charset=utf-8",
5763
5644
  "etag": "\"2c6-2RkdP9PGU+pTqWxDG4zosKFLiR4\"",
5764
- "mtime": "2026-09-25T13:28:52.539Z",
5645
+ "mtime": "2026-09-29T10:07:41.520Z",
5765
5646
  "size": 710,
5766
5647
  "path": "../public/_nuxt/Y6nb8tq_.js"
5767
5648
  },
5768
5649
  "/_nuxt/Ub6l9XKa.js": {
5769
5650
  "type": "text/javascript; charset=utf-8",
5770
5651
  "etag": "\"1fb5-EBSbIH3NcQsdpCtwGYIi0JWAQhs\"",
5771
- "mtime": "2026-09-25T13:28:52.539Z",
5652
+ "mtime": "2026-09-29T10:07:41.520Z",
5772
5653
  "size": 8117,
5773
5654
  "path": "../public/_nuxt/Ub6l9XKa.js"
5774
5655
  },
5775
5656
  "/_nuxt/acbASCJo.js": {
5776
5657
  "type": "text/javascript; charset=utf-8",
5777
5658
  "etag": "\"9d7-SLi0hO/Y8EGtV+Lcy2UWJ4mmikI\"",
5778
- "mtime": "2026-09-25T13:28:52.540Z",
5659
+ "mtime": "2026-09-29T10:07:41.520Z",
5779
5660
  "size": 2519,
5780
5661
  "path": "../public/_nuxt/acbASCJo.js"
5781
5662
  },
5782
5663
  "/_nuxt/cTPe9QuQ.js": {
5783
5664
  "type": "text/javascript; charset=utf-8",
5784
5665
  "etag": "\"caf-yZbn8PPUakonW4XhqIhpgeiXewo\"",
5785
- "mtime": "2026-09-25T13:28:52.540Z",
5666
+ "mtime": "2026-09-29T10:07:41.520Z",
5786
5667
  "size": 3247,
5787
5668
  "path": "../public/_nuxt/cTPe9QuQ.js"
5788
5669
  },
5789
- "/_nuxt/cl7-CwDS.js": {
5790
- "type": "text/javascript; charset=utf-8",
5791
- "etag": "\"1b63-QdNi9/6d3b4Hcm8s4FHiVLfduog\"",
5792
- "mtime": "2026-09-25T13:28:52.540Z",
5793
- "size": 7011,
5794
- "path": "../public/_nuxt/cl7-CwDS.js"
5795
- },
5796
- "/_nuxt/editor.CdBKkuhR.css": {
5797
- "type": "text/css; charset=utf-8",
5798
- "etag": "\"23759-zBPviZ9kjoGDK/SONPmPgsNdfbw\"",
5799
- "mtime": "2026-09-25T13:28:52.540Z",
5800
- "size": 145241,
5801
- "path": "../public/_nuxt/editor.CdBKkuhR.css"
5802
- },
5803
5670
  "/_nuxt/codicon.ngg6Pgfi.ttf": {
5804
5671
  "type": "font/ttf",
5805
5672
  "etag": "\"1dc74-XBOjto8AfgSVQjDgT1tQlYjB3+A\"",
5806
- "mtime": "2026-09-25T13:28:52.540Z",
5673
+ "mtime": "2026-09-29T10:07:41.520Z",
5807
5674
  "size": 121972,
5808
5675
  "path": "../public/_nuxt/codicon.ngg6Pgfi.ttf"
5809
5676
  },
5677
+ "/_nuxt/cl7-CwDS.js": {
5678
+ "type": "text/javascript; charset=utf-8",
5679
+ "etag": "\"1b63-QdNi9/6d3b4Hcm8s4FHiVLfduog\"",
5680
+ "mtime": "2026-09-29T10:07:41.520Z",
5681
+ "size": 7011,
5682
+ "path": "../public/_nuxt/cl7-CwDS.js"
5683
+ },
5810
5684
  "/_nuxt/editor.worker-CdQrwHl8.js": {
5811
5685
  "type": "text/javascript; charset=utf-8",
5812
5686
  "etag": "\"3d7a2-wUBOfk+WxdfYdSew1MghFYzMaK8\"",
5813
- "mtime": "2026-09-25T13:28:52.540Z",
5687
+ "mtime": "2026-09-29T10:07:41.520Z",
5814
5688
  "size": 251810,
5815
5689
  "path": "../public/_nuxt/editor.worker-CdQrwHl8.js"
5816
5690
  },
5817
- "/_nuxt/error-404.64pZEiDn.css": {
5691
+ "/_nuxt/error-404.CTSXlFYa.css": {
5818
5692
  "type": "text/css; charset=utf-8",
5819
- "etag": "\"97e-wxj6PCK04tc6IvtURrlaSygI8Ek\"",
5820
- "mtime": "2026-09-25T13:28:52.540Z",
5693
+ "etag": "\"97e-6XyZilOiSk/dB6OJLcCsTDDI+sU\"",
5694
+ "mtime": "2026-09-29T10:07:41.520Z",
5821
5695
  "size": 2430,
5822
- "path": "../public/_nuxt/error-404.64pZEiDn.css"
5696
+ "path": "../public/_nuxt/error-404.CTSXlFYa.css"
5823
5697
  },
5824
- "/_nuxt/entry.J_CbC0oY.css": {
5698
+ "/_nuxt/entry.B-vs1tRH.css": {
5825
5699
  "type": "text/css; charset=utf-8",
5826
- "etag": "\"2aede-AMt/AxqPy+Md+iGd3w3p7jGZSug\"",
5827
- "mtime": "2026-09-25T13:28:52.540Z",
5828
- "size": 175838,
5829
- "path": "../public/_nuxt/entry.J_CbC0oY.css"
5830
- },
5831
- "/_nuxt/css.worker-DBVD8oXr.js": {
5832
- "type": "text/javascript; charset=utf-8",
5833
- "etag": "\"fb8d8-EvsLU5LlgKGfDfWJSsik5yRf4nU\"",
5834
- "mtime": "2026-09-25T13:28:52.540Z",
5835
- "size": 1030360,
5836
- "path": "../public/_nuxt/css.worker-DBVD8oXr.js"
5700
+ "etag": "\"2fecc-db7KT84o0SGor4iSKgPVkQdHylc\"",
5701
+ "mtime": "2026-09-29T10:07:41.520Z",
5702
+ "size": 196300,
5703
+ "path": "../public/_nuxt/entry.B-vs1tRH.css"
5837
5704
  },
5838
- "/_nuxt/error-500.DHOpI0Ir.css": {
5705
+ "/_nuxt/error-500.DqEfQnVZ.css": {
5839
5706
  "type": "text/css; charset=utf-8",
5840
- "etag": "\"773-+X4oHKXZX4eOcOhNgq+W+L5X/Ao\"",
5841
- "mtime": "2026-09-25T13:28:52.540Z",
5707
+ "etag": "\"773-a8XEXHMhOjbIXJYeMNR9gUVj0ik\"",
5708
+ "mtime": "2026-09-29T10:07:41.520Z",
5842
5709
  "size": 1907,
5843
- "path": "../public/_nuxt/error-500.DHOpI0Ir.css"
5710
+ "path": "../public/_nuxt/error-500.DqEfQnVZ.css"
5844
5711
  },
5845
5712
  "/_nuxt/j7ic8hl3.js": {
5846
5713
  "type": "text/javascript; charset=utf-8",
5847
5714
  "etag": "\"bb1-9Sa0UM8wJM2r2qsvCyphIbL8AZg\"",
5848
- "mtime": "2026-09-25T13:28:52.540Z",
5715
+ "mtime": "2026-09-29T10:07:41.520Z",
5849
5716
  "size": 2993,
5850
5717
  "path": "../public/_nuxt/j7ic8hl3.js"
5851
5718
  },
5852
- "/_nuxt/json.worker-BoL8UZqY.js": {
5853
- "type": "text/javascript; charset=utf-8",
5854
- "etag": "\"5d85e-EsskSG2CAA9ynrYCpqRN2KaS2FE\"",
5855
- "mtime": "2026-09-25T13:28:52.540Z",
5856
- "size": 383070,
5857
- "path": "../public/_nuxt/json.worker-BoL8UZqY.js"
5858
- },
5859
- "/_nuxt/nDZOJ7rN.js": {
5860
- "type": "text/javascript; charset=utf-8",
5861
- "etag": "\"3064-TcGnU0WCH/9woelnGRm6ouLpOrg\"",
5862
- "mtime": "2026-09-25T13:28:52.540Z",
5863
- "size": 12388,
5864
- "path": "../public/_nuxt/nDZOJ7rN.js"
5865
- },
5866
- "/_nuxt/qQyvCkbV.js": {
5867
- "type": "text/javascript; charset=utf-8",
5868
- "etag": "\"d7b-Avr5KeobdEot1ISX6OtVBYP3aN0\"",
5869
- "mtime": "2026-09-25T13:28:52.540Z",
5870
- "size": 3451,
5871
- "path": "../public/_nuxt/qQyvCkbV.js"
5872
- },
5873
- "/_nuxt/rH_O4qXT.js": {
5719
+ "/_nuxt/o-NCh2rp.js": {
5874
5720
  "type": "text/javascript; charset=utf-8",
5875
- "etag": "\"d8d-1kHvDYIlu/9zIOuabnFprqVmyAo\"",
5876
- "mtime": "2026-09-25T13:28:52.540Z",
5877
- "size": 3469,
5878
- "path": "../public/_nuxt/rH_O4qXT.js"
5879
- },
5880
- "/_nuxt/qwxNOyg7.js": {
5881
- "type": "text/javascript; charset=utf-8",
5882
- "etag": "\"e98-gHZZoHJQ8PVNoyt0yCRIlQB3wWs\"",
5883
- "mtime": "2026-09-25T13:28:52.540Z",
5884
- "size": 3736,
5885
- "path": "../public/_nuxt/qwxNOyg7.js"
5721
+ "etag": "\"307f-T6jQ7s4/uy+Ib/Hok7UmqxPht5o\"",
5722
+ "mtime": "2026-09-29T10:07:41.521Z",
5723
+ "size": 12415,
5724
+ "path": "../public/_nuxt/o-NCh2rp.js"
5886
5725
  },
5887
5726
  "/_nuxt/s7OhZKlX.js": {
5888
5727
  "type": "text/javascript; charset=utf-8",
5889
5728
  "etag": "\"cbe-Dm9BrC9HzAMmu490V+uHkCppSHQ\"",
5890
- "mtime": "2026-09-25T13:28:52.541Z",
5729
+ "mtime": "2026-09-29T10:07:41.521Z",
5891
5730
  "size": 3262,
5892
5731
  "path": "../public/_nuxt/s7OhZKlX.js"
5893
5732
  },
5894
- "/_nuxt/tzj4nvDE.js": {
5733
+ "/_nuxt/sKEJiAHO.js": {
5734
+ "type": "text/javascript; charset=utf-8",
5735
+ "etag": "\"e98-bzcGaO3VRkHmsfv2I9+a3Tzr5SY\"",
5736
+ "mtime": "2026-09-29T10:07:41.521Z",
5737
+ "size": 3736,
5738
+ "path": "../public/_nuxt/sKEJiAHO.js"
5739
+ },
5740
+ "/_nuxt/monaco.CdBKkuhR.css": {
5741
+ "type": "text/css; charset=utf-8",
5742
+ "etag": "\"23759-zBPviZ9kjoGDK/SONPmPgsNdfbw\"",
5743
+ "mtime": "2026-09-29T10:07:41.521Z",
5744
+ "size": 145241,
5745
+ "path": "../public/_nuxt/monaco.CdBKkuhR.css"
5746
+ },
5747
+ "/_nuxt/json.worker-BoL8UZqY.js": {
5895
5748
  "type": "text/javascript; charset=utf-8",
5896
- "etag": "\"55f0-mDmzC1uEdcbFe1T1Fg8aH8C2oUg\"",
5897
- "mtime": "2026-09-25T13:28:52.541Z",
5898
- "size": 22000,
5899
- "path": "../public/_nuxt/tzj4nvDE.js"
5749
+ "etag": "\"5d85e-EsskSG2CAA9ynrYCpqRN2KaS2FE\"",
5750
+ "mtime": "2026-09-29T10:07:41.521Z",
5751
+ "size": 383070,
5752
+ "path": "../public/_nuxt/json.worker-BoL8UZqY.js"
5900
5753
  },
5901
5754
  "/_nuxt/tScXyioY.js": {
5902
5755
  "type": "text/javascript; charset=utf-8",
5903
5756
  "etag": "\"41a1-nk+NFTZ2H2UrRNYafqTgJU8ebz0\"",
5904
- "mtime": "2026-09-25T13:28:52.541Z",
5757
+ "mtime": "2026-09-29T10:07:41.521Z",
5905
5758
  "size": 16801,
5906
5759
  "path": "../public/_nuxt/tScXyioY.js"
5907
5760
  },
5761
+ "/_nuxt/tqQNlhT9.js": {
5762
+ "type": "text/javascript; charset=utf-8",
5763
+ "etag": "\"de5-JEamnz2dFicZHtsSRcgrnDiXvUA\"",
5764
+ "mtime": "2026-09-29T10:07:41.521Z",
5765
+ "size": 3557,
5766
+ "path": "../public/_nuxt/tqQNlhT9.js"
5767
+ },
5908
5768
  "/_nuxt/vHIfCaH5.js": {
5909
5769
  "type": "text/javascript; charset=utf-8",
5910
5770
  "etag": "\"b29-PFK6LQMWX+z+o5Uu4RxwUH/hoLM\"",
5911
- "mtime": "2026-09-25T13:28:52.541Z",
5771
+ "mtime": "2026-09-29T10:07:41.521Z",
5912
5772
  "size": 2857,
5913
5773
  "path": "../public/_nuxt/vHIfCaH5.js"
5914
5774
  },
5775
+ "/_nuxt/ypRHVLFO.js": {
5776
+ "type": "text/javascript; charset=utf-8",
5777
+ "etag": "\"bdd-bi7c7P3snUj27uJXJbsHDICrHFw\"",
5778
+ "mtime": "2026-09-29T10:07:41.521Z",
5779
+ "size": 3037,
5780
+ "path": "../public/_nuxt/ypRHVLFO.js"
5781
+ },
5915
5782
  "/_nuxt/zBfavPgS.js": {
5916
5783
  "type": "text/javascript; charset=utf-8",
5917
5784
  "etag": "\"20ae-EddstE0hogAcS7TcgzuXbgtStMI\"",
5918
- "mtime": "2026-09-25T13:28:52.541Z",
5785
+ "mtime": "2026-09-29T10:07:41.521Z",
5919
5786
  "size": 8366,
5920
5787
  "path": "../public/_nuxt/zBfavPgS.js"
5921
5788
  },
5922
- "/_nuxt/builds/latest.json": {
5923
- "type": "application/json",
5924
- "etag": "\"47-l/tVut9rjLuND8An8qLe+StVFsI\"",
5925
- "mtime": "2026-09-25T13:28:52.500Z",
5926
- "size": 71,
5927
- "path": "../public/_nuxt/builds/latest.json"
5928
- },
5929
- "/_nuxt/builds/meta/34871c14-b0f4-4898-9ff0-debaff743355.json": {
5930
- "type": "application/json",
5931
- "etag": "\"58-vMHByqsPEjAFYb7GDyq+CfRr2JY\"",
5932
- "mtime": "2026-09-25T13:28:52.495Z",
5933
- "size": 88,
5934
- "path": "../public/_nuxt/builds/meta/34871c14-b0f4-4898-9ff0-debaff743355.json"
5789
+ "/_nuxt/css.worker-DBVD8oXr.js": {
5790
+ "type": "text/javascript; charset=utf-8",
5791
+ "etag": "\"fb8d8-EvsLU5LlgKGfDfWJSsik5yRf4nU\"",
5792
+ "mtime": "2026-09-29T10:07:41.520Z",
5793
+ "size": 1030360,
5794
+ "path": "../public/_nuxt/css.worker-DBVD8oXr.js"
5935
5795
  },
5936
5796
  "/_nuxt/html.worker-CwpTb9lJ.js": {
5937
5797
  "type": "text/javascript; charset=utf-8",
5938
5798
  "etag": "\"a93a9-v76H5kkCqgwj/Gcu1VzC4lCX/cQ\"",
5939
- "mtime": "2026-09-25T13:28:52.540Z",
5799
+ "mtime": "2026-09-29T10:07:41.520Z",
5940
5800
  "size": 693161,
5941
5801
  "path": "../public/_nuxt/html.worker-CwpTb9lJ.js"
5942
5802
  },
5943
- "/_nuxt/ikxafTHA.js": {
5944
- "type": "text/javascript; charset=utf-8",
5945
- "etag": "\"39934d-+QLv/ulQNTxmq9XzCfqNZwZkpIs\"",
5946
- "mtime": "2026-09-25T13:28:52.541Z",
5947
- "size": 3773261,
5948
- "path": "../public/_nuxt/ikxafTHA.js"
5803
+ "/_nuxt/builds/latest.json": {
5804
+ "type": "application/json",
5805
+ "etag": "\"47-2BdphIb9Hr5ESSkqNB3sOQdb6ME\"",
5806
+ "mtime": "2026-09-29T10:07:41.482Z",
5807
+ "size": 71,
5808
+ "path": "../public/_nuxt/builds/latest.json"
5809
+ },
5810
+ "/_nuxt/builds/meta/51f1351c-0667-4235-9ddc-16582a51ce03.json": {
5811
+ "type": "application/json",
5812
+ "etag": "\"58-hhw59AHrrQsHH4j+AQQPEXTBfvg\"",
5813
+ "mtime": "2026-09-29T10:07:41.477Z",
5814
+ "size": 88,
5815
+ "path": "../public/_nuxt/builds/meta/51f1351c-0667-4235-9ddc-16582a51ce03.json"
5949
5816
  },
5950
5817
  "/_nuxt/ts.worker-CTGvpNXs.js": {
5951
5818
  "type": "text/javascript; charset=utf-8",
5952
5819
  "etag": "\"6af794-CJfRH6VLp2lTqjWugbyUmUsVeeg\"",
5953
- "mtime": "2026-09-25T13:28:52.543Z",
5820
+ "mtime": "2026-09-29T10:07:41.522Z",
5954
5821
  "size": 7010196,
5955
5822
  "path": "../public/_nuxt/ts.worker-CTGvpNXs.js"
5956
5823
  }
@@ -6094,7 +5961,7 @@ function getAsset (id) {
6094
5961
 
6095
5962
  const METHODS = /* @__PURE__ */ new Set(["HEAD", "GET"]);
6096
5963
  const EncodingMap = { gzip: ".gz", br: ".br" };
6097
- const _yyTQcL = eventHandler((event) => {
5964
+ const _jvAnmE = eventHandler((event) => {
6098
5965
  if (event.method && !METHODS.has(event.method)) {
6099
5966
  return;
6100
5967
  }
@@ -6159,30 +6026,51 @@ const _yyTQcL = eventHandler((event) => {
6159
6026
  });
6160
6027
 
6161
6028
  const rateLimitMap = /* @__PURE__ */ new Map();
6162
- const RATE_LIMIT = 2;
6029
+ const RATE_LIMIT = 8;
6163
6030
  const TIME_WINDOW = 1e3;
6031
+ const GLOBAL_RATE_LIMIT = 20;
6032
+ let globalWindowStart = 0;
6033
+ let globalRequests = 0;
6164
6034
  const _c_y9US = defineEventHandler((event) => {
6165
- const isDocsMode = process.env.DOCS_MODE === "true";
6035
+ const isDocsMode = useRuntimeConfig(event).public.isDocsMode;
6166
6036
  const path = event.path;
6037
+ if (!isDocsMode && path.startsWith("/api/")) {
6038
+ const host = getHeader(event, "host") || "";
6039
+ const origin = getHeader(event, "origin");
6040
+ const localHost = /^(localhost|127\.0\.0\.1)(:\d+)?$/.test(host);
6041
+ const localOrigin = !origin || /^https?:\/\/(localhost|127\.0\.0\.1)(:\d+)?$/.test(origin);
6042
+ if (!localHost || !localOrigin) throw createError$1({ statusCode: 403, message: "Local Studio accepts only loopback requests." });
6043
+ }
6167
6044
  if (isDocsMode && path.startsWith("/api/resolve")) {
6168
6045
  throw createError$1({
6169
6046
  statusCode: 403,
6170
6047
  message: "Filesystem resolution is disabled in Documentation Mode."
6171
6048
  });
6172
6049
  }
6173
- if (isDocsMode && path.startsWith("/api/parse")) {
6050
+ if (isDocsMode && path === "/api/studio/run") {
6174
6051
  const ip = getRequestIP(event) || "unknown";
6175
6052
  const now = Date.now();
6176
6053
  const timestamps = rateLimitMap.get(ip) || [];
6177
6054
  const recentRequests = timestamps.filter((t) => now - t < TIME_WINDOW);
6178
- if (recentRequests.length >= RATE_LIMIT) {
6055
+ if (now - globalWindowStart >= TIME_WINDOW) {
6056
+ globalWindowStart = now;
6057
+ globalRequests = 0;
6058
+ }
6059
+ if (rateLimitMap.size > 1024) {
6060
+ for (const [key, entries] of rateLimitMap) {
6061
+ if (entries.every((time) => now - time >= TIME_WINDOW)) rateLimitMap.delete(key);
6062
+ }
6063
+ }
6064
+ if (recentRequests.length >= RATE_LIMIT || globalRequests >= GLOBAL_RATE_LIMIT || rateLimitMap.size >= 1024 && !rateLimitMap.has(ip)) {
6065
+ setHeader(event, "Retry-After", 1);
6179
6066
  throw createError$1({
6180
6067
  statusCode: 429,
6181
- message: "Too Many Requests. Limit is 2 requests per second."
6068
+ message: "Too many runs. Wait a moment and try again."
6182
6069
  });
6183
6070
  }
6184
6071
  recentRequests.push(now);
6185
6072
  rateLimitMap.set(ip, recentRequests);
6073
+ globalRequests++;
6186
6074
  }
6187
6075
  });
6188
6076
 
@@ -6245,46 +6133,1674 @@ function publicAssetsURL(...path) {
6245
6133
  return path.length ? joinRelativeURL(publicBase, ...path) : publicBase;
6246
6134
  }
6247
6135
 
6248
- const collections = {
6249
- };
6250
-
6251
- const DEFAULT_ENDPOINT = "https://api.iconify.design";
6252
- const _80_oNC = defineCachedEventHandler(async (event) => {
6253
- const url = getRequestURL(event);
6254
- if (!url)
6255
- return createError$1({ status: 400, message: "Invalid icon request" });
6256
- const options = useAppConfig().icon;
6257
- const collectionName = event.context.params?.collection?.replace(/\.json$/, "");
6258
- const collection = collectionName ? await collections[collectionName]?.() : null;
6259
- const apiEndPoint = options.iconifyApiEndpoint || DEFAULT_ENDPOINT;
6260
- const icons = url.searchParams.get("icons")?.split(",");
6261
- if (collection) {
6262
- if (icons?.length) {
6263
- const data = getIcons(
6264
- collection,
6265
- icons
6266
- );
6267
- consola.debug(`[Icon] serving ${(icons || []).map((i) => "`" + collectionName + ":" + i + "`").join(",")} from bundled collection`);
6268
- return data;
6269
- }
6136
+ var __defProp$1 = Object.defineProperty;
6137
+ var __defNormalProp$1 = (obj, key, value) => key in obj ? __defProp$1(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
6138
+ var __publicField$1 = (obj, key, value) => __defNormalProp$1(obj, typeof key !== "symbol" ? key + "" : key, value);
6139
+ function flatHooks(configHooks, hooks2 = {}, parentName) {
6140
+ for (const key in configHooks) {
6141
+ const subHook = configHooks[key];
6142
+ const name = parentName ? `${parentName}:${key}` : key;
6143
+ if (typeof subHook === "object" && subHook !== null) flatHooks(subHook, hooks2, name);
6144
+ else if (typeof subHook === "function") hooks2[name] = subHook;
6270
6145
  }
6271
- if (options.fallbackToApi === true || options.fallbackToApi === "server-only") {
6272
- const apiUrl = new URL("./" + basename(url.pathname) + url.search, apiEndPoint);
6273
- consola.debug(`[Icon] fetching ${(icons || []).map((i) => "`" + collectionName + ":" + i + "`").join(",")} from iconify api`);
6274
- if (apiUrl.host !== new URL(apiEndPoint).host) {
6275
- return createError$1({ status: 400, message: "Invalid icon request" });
6146
+ return hooks2;
6147
+ }
6148
+ const createTask = /* @__PURE__ */ (() => {
6149
+ if (console.createTask) return console.createTask;
6150
+ const defaultTask = { run: (fn) => fn() };
6151
+ return () => defaultTask;
6152
+ })();
6153
+ function callHooks(hooks2, args, startIndex, task) {
6154
+ for (let i = startIndex; i < hooks2.length; i += 1) try {
6155
+ const result = task ? task.run(() => hooks2[i](...args)) : hooks2[i](...args);
6156
+ if (result instanceof Promise) return result.then(() => callHooks(hooks2, args, i + 1, task));
6157
+ } catch (error) {
6158
+ return Promise.reject(error);
6159
+ }
6160
+ }
6161
+ function serialTaskCaller(hooks2, args, name) {
6162
+ if (hooks2.length > 0) return callHooks(hooks2, args, 0, createTask(name));
6163
+ }
6164
+ function parallelTaskCaller(hooks2, args, name) {
6165
+ if (hooks2.length > 0) {
6166
+ const task = createTask(name);
6167
+ return Promise.all(hooks2.map((hook) => task.run(() => hook(...args))));
6168
+ }
6169
+ }
6170
+ function callEachWith(callbacks, arg0) {
6171
+ for (const callback of [...callbacks]) callback(arg0);
6172
+ }
6173
+ var Hookable = class {
6174
+ constructor() {
6175
+ __publicField$1(this, "_hooks");
6176
+ __publicField$1(this, "_before");
6177
+ __publicField$1(this, "_after");
6178
+ __publicField$1(this, "_deprecatedHooks");
6179
+ __publicField$1(this, "_deprecatedMessages");
6180
+ this._hooks = {};
6181
+ this._before = void 0;
6182
+ this._after = void 0;
6183
+ this._deprecatedMessages = void 0;
6184
+ this._deprecatedHooks = {};
6185
+ this.hook = this.hook.bind(this);
6186
+ this.callHook = this.callHook.bind(this);
6187
+ this.callHookWith = this.callHookWith.bind(this);
6188
+ }
6189
+ hook(name, function_, options = {}) {
6190
+ if (!name || typeof function_ !== "function") return () => {
6191
+ };
6192
+ const originalName = name;
6193
+ let dep;
6194
+ while (this._deprecatedHooks[name]) {
6195
+ dep = this._deprecatedHooks[name];
6196
+ name = dep.to;
6276
6197
  }
6277
- try {
6278
- const data = await $fetch(apiUrl.href);
6279
- return data;
6280
- } catch (e) {
6281
- consola.error(e);
6282
- if (e.status === 404)
6283
- return createError$1({ status: 404 });
6284
- else
6285
- return createError$1({ status: 500, message: "Failed to fetch fallback icon" });
6198
+ if (dep && !options.allowDeprecated) {
6199
+ let message = dep.message;
6200
+ if (!message) message = `${originalName} hook has been deprecated` + (dep.to ? `, please use ${dep.to}` : "");
6201
+ if (!this._deprecatedMessages) this._deprecatedMessages = /* @__PURE__ */ new Set();
6202
+ if (!this._deprecatedMessages.has(message)) {
6203
+ console.warn(message);
6204
+ this._deprecatedMessages.add(message);
6205
+ }
6286
6206
  }
6287
- }
6207
+ if (!function_.name) try {
6208
+ Object.defineProperty(function_, "name", {
6209
+ get: () => "_" + name.replace(/\W+/g, "_") + "_hook_cb",
6210
+ configurable: true
6211
+ });
6212
+ } catch {
6213
+ }
6214
+ this._hooks[name] = this._hooks[name] || [];
6215
+ this._hooks[name].push(function_);
6216
+ return () => {
6217
+ if (function_) {
6218
+ this.removeHook(name, function_);
6219
+ function_ = void 0;
6220
+ }
6221
+ };
6222
+ }
6223
+ hookOnce(name, function_) {
6224
+ let _unreg;
6225
+ let _function = (...arguments_) => {
6226
+ if (typeof _unreg === "function") _unreg();
6227
+ _unreg = void 0;
6228
+ _function = void 0;
6229
+ return function_(...arguments_);
6230
+ };
6231
+ _unreg = this.hook(name, _function);
6232
+ return _unreg;
6233
+ }
6234
+ removeHook(name, function_) {
6235
+ const hooks2 = this._hooks[name];
6236
+ if (hooks2) {
6237
+ const index = hooks2.indexOf(function_);
6238
+ if (index !== -1) hooks2.splice(index, 1);
6239
+ if (hooks2.length === 0) this._hooks[name] = void 0;
6240
+ }
6241
+ }
6242
+ clearHook(name) {
6243
+ this._hooks[name] = void 0;
6244
+ }
6245
+ deprecateHook(name, deprecated) {
6246
+ this._deprecatedHooks[name] = typeof deprecated === "string" ? { to: deprecated } : deprecated;
6247
+ const _hooks = this._hooks[name] || [];
6248
+ this._hooks[name] = void 0;
6249
+ for (const hook of _hooks) this.hook(name, hook);
6250
+ }
6251
+ deprecateHooks(deprecatedHooks) {
6252
+ for (const name in deprecatedHooks) this.deprecateHook(name, deprecatedHooks[name]);
6253
+ }
6254
+ addHooks(configHooks) {
6255
+ const hooks2 = flatHooks(configHooks);
6256
+ const removeFns = Object.keys(hooks2).map((key) => this.hook(key, hooks2[key]));
6257
+ return () => {
6258
+ for (const unreg of removeFns) unreg();
6259
+ removeFns.length = 0;
6260
+ };
6261
+ }
6262
+ removeHooks(configHooks) {
6263
+ const hooks2 = flatHooks(configHooks);
6264
+ for (const key in hooks2) this.removeHook(key, hooks2[key]);
6265
+ }
6266
+ removeAllHooks() {
6267
+ this._hooks = {};
6268
+ }
6269
+ callHook(name, ...args) {
6270
+ return this.callHookWith(serialTaskCaller, name, args);
6271
+ }
6272
+ callHookParallel(name, ...args) {
6273
+ return this.callHookWith(parallelTaskCaller, name, args);
6274
+ }
6275
+ callHookWith(caller, name, args) {
6276
+ const event = this._before || this._after ? {
6277
+ name,
6278
+ args,
6279
+ context: {}
6280
+ } : void 0;
6281
+ if (this._before) callEachWith(this._before, event);
6282
+ const result = caller(this._hooks[name] ? [...this._hooks[name]] : [], args, name);
6283
+ if (result instanceof Promise) return result.finally(() => {
6284
+ if (this._after && event) callEachWith(this._after, event);
6285
+ });
6286
+ if (this._after && event) callEachWith(this._after, event);
6287
+ return result;
6288
+ }
6289
+ beforeEach(function_) {
6290
+ this._before = this._before || [];
6291
+ this._before.push(function_);
6292
+ return () => {
6293
+ if (this._before !== void 0) {
6294
+ const index = this._before.indexOf(function_);
6295
+ if (index !== -1) this._before.splice(index, 1);
6296
+ }
6297
+ };
6298
+ }
6299
+ afterEach(function_) {
6300
+ this._after = this._after || [];
6301
+ this._after.push(function_);
6302
+ return () => {
6303
+ if (this._after !== void 0) {
6304
+ const index = this._after.indexOf(function_);
6305
+ if (index !== -1) this._after.splice(index, 1);
6306
+ }
6307
+ };
6308
+ }
6309
+ };
6310
+ function createHooks() {
6311
+ return new Hookable();
6312
+ }
6313
+ const hooks = createHooks();
6314
+ function callHookSync(name, ...args) {
6315
+ hooks.callHookWith((callbacks, args2) => {
6316
+ for (const callback of callbacks) {
6317
+ callback(...args2);
6318
+ }
6319
+ }, name, args);
6320
+ }
6321
+ const mongooseRegistry = z.registry();
6322
+ function withMongoose(schema, meta = {}) {
6323
+ callHookSync("registry:get:before", { schema });
6324
+ const existing = mongooseRegistry.get(schema) || {};
6325
+ callHookSync("registry:get", { schema, meta: existing });
6326
+ const merged = { ...existing, ...meta };
6327
+ callHookSync("registry:add", { schema, meta: merged });
6328
+ mongooseRegistry.add(schema, merged);
6329
+ callHookSync("registry:added", { schema, meta: merged });
6330
+ return schema;
6331
+ }
6332
+ function getMongooseMeta(schema) {
6333
+ const def = schema._def;
6334
+ if (!def)
6335
+ return {};
6336
+ let meta = mongooseRegistry.get(schema) || {};
6337
+ if (def.innerType) {
6338
+ meta = { ...getMongooseMeta(def.innerType), ...meta };
6339
+ } else if (def.schema) {
6340
+ meta = { ...getMongooseMeta(def.schema), ...meta };
6341
+ }
6342
+ if (def.type === "pipe") {
6343
+ meta = { ...getMongooseMeta(def.in), ...getMongooseMeta(def.out), ...meta };
6344
+ }
6345
+ return meta;
6346
+ }
6347
+ function objectStrictness(schema) {
6348
+ var _a, _b, _c, _d;
6349
+ const catchall = (_b = (_a = schema._zod) == null ? void 0 : _a.def) == null ? void 0 : _b.catchall;
6350
+ if (!catchall)
6351
+ return true;
6352
+ return ((_d = (_c = catchall._zod) == null ? void 0 : _c.def) == null ? void 0 : _d.type) === "never" ? "throw" : false;
6353
+ }
6354
+ function unwrapZodSchema(schema, features = { required: true }, visited = /* @__PURE__ */ new Set()) {
6355
+ var _a, _b, _c, _d, _e;
6356
+ if (!schema)
6357
+ return { schema, features };
6358
+ if (visited.has(schema))
6359
+ return { schema, features };
6360
+ const def = schema._def;
6361
+ if (!def)
6362
+ return { schema, features };
6363
+ if (!(schema instanceof z.ZodOptional) && !(schema instanceof z.ZodNullable) && !(schema instanceof z.ZodDefault) && def.type !== "pipe") {
6364
+ visited.add(schema);
6365
+ }
6366
+ if (schema instanceof z.ZodOptional) {
6367
+ const inner = schema.unwrap();
6368
+ const result = unwrapZodSchema(
6369
+ // @ts-expect-error Zod v4 schema.unwrap() return type mismatch
6370
+ inner,
6371
+ features,
6372
+ visited
6373
+ );
6374
+ return {
6375
+ schema: result.schema,
6376
+ features: {
6377
+ ...result.features,
6378
+ required: false,
6379
+ isOptional: true,
6380
+ isExactOptional: false,
6381
+ isNonOptional: false
6382
+ }
6383
+ };
6384
+ }
6385
+ if (schema instanceof z.ZodExactOptional) {
6386
+ const result = unwrapZodSchema(schema.unwrap(), features, visited);
6387
+ return {
6388
+ schema: result.schema,
6389
+ features: {
6390
+ ...result.features,
6391
+ required: false,
6392
+ isOptional: true,
6393
+ isExactOptional: true,
6394
+ isNonOptional: false
6395
+ }
6396
+ };
6397
+ }
6398
+ if (schema instanceof z.ZodNonOptional) {
6399
+ const result = unwrapZodSchema(schema.unwrap(), features, visited);
6400
+ return {
6401
+ schema: result.schema,
6402
+ features: {
6403
+ ...result.features,
6404
+ required: true,
6405
+ isOptional: false,
6406
+ isExactOptional: false,
6407
+ isNonOptional: true
6408
+ }
6409
+ };
6410
+ }
6411
+ if (schema instanceof z.ZodNullable) {
6412
+ return unwrapZodSchema(
6413
+ // @ts-expect-error Zod v4 schema.unwrap() return type mismatch
6414
+ schema.unwrap(),
6415
+ {
6416
+ ...features,
6417
+ isNullable: true
6418
+ },
6419
+ visited
6420
+ );
6421
+ }
6422
+ if (schema instanceof z.ZodDefault) {
6423
+ const defaultValue = typeof def.defaultValue === "function" ? def.defaultValue() : def.defaultValue;
6424
+ return unwrapZodSchema(def.innerType, {
6425
+ ...features,
6426
+ default: defaultValue
6427
+ }, visited);
6428
+ }
6429
+ const { type } = def;
6430
+ if (type === "pipe") {
6431
+ const inType = (_b = (_a = def.in) == null ? void 0 : _a._def) == null ? void 0 : _b.type;
6432
+ const outType = (_d = (_c = def.out) == null ? void 0 : _c._def) == null ? void 0 : _d.type;
6433
+ if (inType === "transform") {
6434
+ return unwrapZodSchema(def.out, features, visited);
6435
+ }
6436
+ if (outType === "transform" || outType === "refinement") {
6437
+ const transformFeatures = { ...features };
6438
+ const outDef = (_e = def.out) == null ? void 0 : _e._def;
6439
+ const effects = (outDef == null ? void 0 : outDef.effects) || (outDef == null ? void 0 : outDef.transformations) || (outType === "transform" ? [outDef] : []);
6440
+ if (effects && Array.isArray(effects)) {
6441
+ transformFeatures.transformations = [
6442
+ ...transformFeatures.transformations || [],
6443
+ ...effects
6444
+ ];
6445
+ }
6446
+ return unwrapZodSchema(def.in, transformFeatures, visited);
6447
+ }
6448
+ return unwrapZodSchema(def.out, features, visited);
6449
+ }
6450
+ if (type === "transform" || type === "preprocess" || type === "refinement" || type === "effects") {
6451
+ const transformFeatures = { ...features };
6452
+ const effects = def.effects || def.transformations || (def.type === "transform" || type === "transform" ? [def] : []);
6453
+ if (effects && Array.isArray(effects)) {
6454
+ transformFeatures.transformations = [
6455
+ ...transformFeatures.transformations || [],
6456
+ ...effects
6457
+ ];
6458
+ }
6459
+ const inner = def.schema || def.innerType;
6460
+ if (inner) {
6461
+ const result = unwrapZodSchema(inner, transformFeatures, visited);
6462
+ return result;
6463
+ }
6464
+ }
6465
+ if (type === "lazy") {
6466
+ return { schema, features };
6467
+ }
6468
+ if (type === "branded" || type === "readonly") {
6469
+ return unwrapZodSchema(schema.unwrap(), {
6470
+ ...features,
6471
+ ...type === "readonly" ? { readOnly: true } : {}
6472
+ }, visited);
6473
+ }
6474
+ if (def.checks && Array.isArray(def.checks)) {
6475
+ features.checks = [...features.checks || [], ...def.checks];
6476
+ }
6477
+ return { schema, features };
6478
+ }
6479
+ function prepareForZodValidation(schema, value, mongooseSchema, pathPrefix = "") {
6480
+ var _a;
6481
+ if (value === null || value === void 0)
6482
+ return value;
6483
+ const { schema: unwrapped } = unwrapZodSchema(schema);
6484
+ const def = unwrapped == null ? void 0 : unwrapped._def;
6485
+ if ((def == null ? void 0 : def.type) === "lazy") {
6486
+ return prepareForZodValidation(def.getter(), value, mongooseSchema, pathPrefix);
6487
+ }
6488
+ if ((def == null ? void 0 : def.type) === "object" && typeof value === "object" && !Array.isArray(value)) {
6489
+ const { shape } = unwrapped;
6490
+ const result = { ...value };
6491
+ if (mongooseSchema && !pathPrefix && mongooseSchema.options._id !== false && !Object.hasOwn(shape, "_id")) {
6492
+ delete result._id;
6493
+ }
6494
+ const versionKey = !pathPrefix && (mongooseSchema == null ? void 0 : mongooseSchema.options.versionKey);
6495
+ if (typeof versionKey === "string" && !Object.hasOwn(shape, versionKey)) {
6496
+ delete result[versionKey];
6497
+ }
6498
+ const timestamps = !pathPrefix && (mongooseSchema == null ? void 0 : mongooseSchema.options.timestamps);
6499
+ if (timestamps) {
6500
+ for (const key of ["createdAt", "updatedAt"]) {
6501
+ const configured = typeof timestamps === "object" ? timestamps[key] : void 0;
6502
+ if (configured === false)
6503
+ continue;
6504
+ const fieldName = typeof configured === "string" ? configured : key;
6505
+ if (!Object.hasOwn(shape, fieldName))
6506
+ delete result[fieldName];
6507
+ }
6508
+ }
6509
+ for (const [key, fieldSchema] of Object.entries(shape)) {
6510
+ if (!Object.hasOwn(result, key))
6511
+ continue;
6512
+ const path = pathPrefix ? `${pathPrefix}.${key}` : key;
6513
+ const nestedSchema = (_a = mongooseSchema == null ? void 0 : mongooseSchema.path(path)) == null ? void 0 : _a.schema;
6514
+ result[key] = prepareForZodValidation(fieldSchema, result[key], nestedSchema || mongooseSchema, nestedSchema ? "" : path);
6515
+ }
6516
+ return result;
6517
+ }
6518
+ if (Array.isArray(value)) {
6519
+ if ((def == null ? void 0 : def.type) === "array" || (def == null ? void 0 : def.type) === "set") {
6520
+ const element = unwrapped.element || def.valueType;
6521
+ return element ? value.map((item) => prepareForZodValidation(element, item, mongooseSchema, pathPrefix)) : value;
6522
+ }
6523
+ if ((def == null ? void 0 : def.type) === "tuple") {
6524
+ return value.map((item, index) => {
6525
+ var _a2;
6526
+ const element = ((_a2 = def.items) == null ? void 0 : _a2[index]) || def.rest;
6527
+ return element ? prepareForZodValidation(element, item, mongooseSchema, pathPrefix) : item;
6528
+ });
6529
+ }
6530
+ }
6531
+ return value;
6532
+ }
6533
+ let mongooseInstance = null;
6534
+ let isFrontend;
6535
+ const setFrontendMode = (enabled) => {
6536
+ console.warn("[zod-mongoose] setFrontendMode() is deprecated and will be removed in v4. Conditional exports select the appropriate implementation automatically.");
6537
+ isFrontend = enabled;
6538
+ };
6539
+ const getFrontendMode = () => {
6540
+ if (isFrontend === void 0 || isFrontend === null) {
6541
+ return globalThis.window !== void 0 && globalThis.document !== void 0;
6542
+ }
6543
+ return isFrontend;
6544
+ };
6545
+ const setMongoose = (m) => {
6546
+ mongooseInstance = m;
6547
+ };
6548
+ const getMongoose = () => {
6549
+ var _a;
6550
+ if (getFrontendMode()) {
6551
+ return null;
6552
+ }
6553
+ if (mongooseInstance) {
6554
+ return mongooseInstance;
6555
+ }
6556
+ try {
6557
+ if (typeof require !== "undefined") {
6558
+ const m = require("mongoose");
6559
+ if (m && (m.Schema || ((_a = m.default) == null ? void 0 : _a.Schema))) {
6560
+ return m.default || m;
6561
+ }
6562
+ return m;
6563
+ }
6564
+ return null;
6565
+ } catch {
6566
+ if (globalThis.mongoose) {
6567
+ return globalThis.mongoose;
6568
+ }
6569
+ return null;
6570
+ }
6571
+ };
6572
+ function mapZodChecksToMongoose(checks, mongooseProp) {
6573
+ var _a, _b;
6574
+ if (!checks || !Array.isArray(checks))
6575
+ return;
6576
+ for (const check of checks) {
6577
+ const traitSet = (_a = check._zod) == null ? void 0 : _a.traits;
6578
+ const checkDef = (_b = check._zod) == null ? void 0 : _b.def;
6579
+ if (!traitSet || !checkDef)
6580
+ continue;
6581
+ if (traitSet.has("$ZodCheckMinLength")) {
6582
+ mongooseProp.minlength = checkDef.minimum;
6583
+ }
6584
+ if (traitSet.has("$ZodCheckMaxLength")) {
6585
+ mongooseProp.maxlength = checkDef.maximum;
6586
+ }
6587
+ if (traitSet.has("$ZodCheckLengthEquals")) {
6588
+ mongooseProp.minlength = checkDef.length;
6589
+ mongooseProp.maxlength = checkDef.length;
6590
+ }
6591
+ if (traitSet.has("$ZodCheckGreaterThan")) {
6592
+ mongooseProp.min = checkDef.value;
6593
+ }
6594
+ if (traitSet.has("$ZodCheckLessThan")) {
6595
+ mongooseProp.max = checkDef.value;
6596
+ }
6597
+ if (traitSet.has("$ZodCheckRegex")) {
6598
+ mongooseProp.match = checkDef.pattern;
6599
+ }
6600
+ if (traitSet.has("$ZodUUID")) {
6601
+ const mongoose = globalThis.mongoose || globalThis.__mongoose;
6602
+ if (mongoose == null ? void 0 : mongoose.Schema.Types.UUID) {
6603
+ mongooseProp.type = mongoose.Schema.Types.UUID;
6604
+ }
6605
+ }
6606
+ if (traitSet.has("$ZodISODateTime") || traitSet.has("$ZodISODate")) {
6607
+ mongooseProp.type = Date;
6608
+ }
6609
+ if (traitSet.has("$ZodCheckOverwrite") && typeof checkDef.tx === "function") {
6610
+ const txStr = checkDef.tx.toString();
6611
+ if (txStr.includes(".trim()")) {
6612
+ mongooseProp.trim = true;
6613
+ } else if (txStr.includes(".toLowerCase()")) {
6614
+ mongooseProp.lowercase = true;
6615
+ } else if (txStr.includes(".toUpperCase()")) {
6616
+ mongooseProp.uppercase = true;
6617
+ }
6618
+ }
6619
+ }
6620
+ callHookSync("validation:mappers", { checks, mongooseProp });
6621
+ }
6622
+ function handleObject(unwrapped, mongooseProp, visited, extractMongooseDef2, isField = false) {
6623
+ var _a, _b, _c, _d, _e;
6624
+ callHookSync("schema:object:before", { schema: unwrapped, mongooseProp, visited });
6625
+ const { shape } = unwrapped;
6626
+ const objDef = {};
6627
+ const placeholder = mongooseProp.type ? mongooseProp : objDef;
6628
+ visited.set(unwrapped, placeholder);
6629
+ for (const key in shape) {
6630
+ if (!Object.prototype.hasOwnProperty.call(shape, key))
6631
+ continue;
6632
+ if (key === "_id") {
6633
+ const idMeta = mongooseRegistry.get(shape[key]) || {};
6634
+ const unwrappedId = unwrapZodSchema(shape[key]).schema;
6635
+ const unwrappedIdMeta = mongooseRegistry.get(unwrappedId) || {};
6636
+ if (idMeta.includeId !== true && unwrappedIdMeta.includeId !== true && mongooseProp.includeId !== true) {
6637
+ continue;
6638
+ }
6639
+ }
6640
+ const def = extractMongooseDef2(shape[key], visited);
6641
+ if (def && typeof def === "object" && def.__isDiscriminatorUnion) {
6642
+ const mongoose = getMongoose();
6643
+ if (mongoose) {
6644
+ const baseSchema = new mongoose.Schema(def.baseDef, {
6645
+ discriminatorKey: def.discriminatorKey,
6646
+ _id: false
6647
+ });
6648
+ const discriminators = {};
6649
+ for (const [dKey, dDef] of Object.entries(def.discriminators)) {
6650
+ discriminators[dKey] = new mongoose.Schema(dDef, { _id: false });
6651
+ }
6652
+ objDef[key] = {
6653
+ type: baseSchema,
6654
+ discriminators
6655
+ };
6656
+ } else {
6657
+ objDef[key] = def;
6658
+ }
6659
+ } else if (typeof def === "object" && def !== null && !Array.isArray(def)) {
6660
+ const { includeId, ...cleanDef } = def;
6661
+ objDef[key] = cleanDef;
6662
+ } else {
6663
+ objDef[key] = def;
6664
+ }
6665
+ callHookSync("schema:object:field", { key, schema: shape[key], objDef, visited });
6666
+ }
6667
+ let result;
6668
+ const shouldBeSubSchema = isField && mongooseProp.schema !== false;
6669
+ if (isField && mongooseProp.schema === false && !mongooseProp.type && objectStrictness(unwrapped) !== true) {
6670
+ throw new Error("A strict, loose, or catchall Zod object needs a Mongoose subschema. Remove {schema: false} or provide a Mongoose type override.");
6671
+ }
6672
+ if (shouldBeSubSchema && !mongooseProp.type) {
6673
+ const mongoose = getMongoose();
6674
+ if (mongoose) {
6675
+ const options = typeof mongooseProp.schema === "object" ? mongooseProp.schema : {};
6676
+ const { plugins, ...schemaOptions } = options;
6677
+ const strict = (_b = (_a = schemaOptions.strict) != null ? _a : mongooseProp.strict) != null ? _b : objectStrictness(unwrapped);
6678
+ const minimize = (_d = (_c = schemaOptions.minimize) != null ? _c : mongooseProp.minimize) != null ? _d : objectStrictness(unwrapped) === false ? false : void 0;
6679
+ const subSchema = new mongoose.Schema(objDef, {
6680
+ ...schemaOptions,
6681
+ strict,
6682
+ ...minimize === void 0 ? {} : { minimize }
6683
+ });
6684
+ if (plugins && Array.isArray(plugins)) {
6685
+ for (const plugin of plugins) {
6686
+ subSchema.plugin(plugin);
6687
+ }
6688
+ }
6689
+ mongooseProp.type = subSchema;
6690
+ }
6691
+ }
6692
+ if (mongooseProp.type) {
6693
+ const mongoose = getMongoose();
6694
+ const isSchema = mongoose && (mongooseProp.type instanceof mongoose.Schema || ((_e = mongooseProp.type.constructor) == null ? void 0 : _e.name) === "Schema");
6695
+ if (!isSchema) {
6696
+ Object.assign(mongooseProp, objDef);
6697
+ }
6698
+ result = mongooseProp;
6699
+ } else {
6700
+ Object.assign(mongooseProp, objDef);
6701
+ const topLevelOptions = /* @__PURE__ */ new Set([
6702
+ "collection",
6703
+ "versionKey",
6704
+ "timestamps",
6705
+ "discriminatorKey",
6706
+ "strict",
6707
+ "id",
6708
+ "_id",
6709
+ "minimize",
6710
+ "validateBeforeSave",
6711
+ "schema"
6712
+ ]);
6713
+ const hasFieldMetadata = Object.keys(mongooseProp).some((k) => {
6714
+ if (Object.prototype.hasOwnProperty.call(objDef, k))
6715
+ return false;
6716
+ if (topLevelOptions.has(k))
6717
+ return false;
6718
+ if (k === "required" && mongooseProp[k] === false)
6719
+ return false;
6720
+ return true;
6721
+ });
6722
+ result = hasFieldMetadata ? mongooseProp : objDef;
6723
+ }
6724
+ callHookSync("schema:object:after", { schema: unwrapped, mongooseProp, objDef, result });
6725
+ return result;
6726
+ }
6727
+ function handleArray(unwrapped, mongooseProp, visited, extractMongooseDef2) {
6728
+ var _a;
6729
+ callHookSync("schema:array:before", { schema: unwrapped, mongooseProp, visited });
6730
+ const element = unwrapped.element || unwrapped._def.valueType || unwrapped._def.rest || ((_a = unwrapped._def.items) == null ? void 0 : _a[0]);
6731
+ const mongoose = getMongoose();
6732
+ const innerDef = element ? extractMongooseDef2(element, visited) : (mongoose == null ? void 0 : mongoose.Schema.Types.Mixed) || "Mixed";
6733
+ if (!mongooseProp.type) {
6734
+ if (innerDef && typeof innerDef === "object" && innerDef.__isDiscriminatorUnion && mongoose) {
6735
+ const discriminators = {};
6736
+ for (const [dKey, dDef] of Object.entries(innerDef.discriminators)) {
6737
+ discriminators[dKey] = new mongoose.Schema(dDef, { _id: false });
6738
+ }
6739
+ mongooseProp.type = [
6740
+ new mongoose.Schema({}, {
6741
+ discriminatorKey: innerDef.discriminatorKey,
6742
+ _id: false
6743
+ })
6744
+ ];
6745
+ mongooseProp.discriminators = discriminators;
6746
+ } else {
6747
+ const innerType = innerDef.type || innerDef;
6748
+ mongooseProp.type = [innerType];
6749
+ if (typeof innerDef === "object") {
6750
+ const { type: _extractedType, ...innerMeta } = innerDef;
6751
+ Object.assign(mongooseProp, innerMeta);
6752
+ mongooseProp.type = [innerType];
6753
+ }
6754
+ }
6755
+ }
6756
+ callHookSync("schema:array:after", { schema: unwrapped, mongooseProp, innerDef });
6757
+ }
6758
+ function handleRecord(unwrapped, mongooseProp, visited, extractMongooseDef2) {
6759
+ var _a, _b;
6760
+ callHookSync("schema:record:before", { schema: unwrapped, mongooseProp, visited });
6761
+ const type = (_a = unwrapped._def) == null ? void 0 : _a.type;
6762
+ const isMap = type === "map";
6763
+ const valueType = unwrapped.valueType || unwrapped.valueSchema || unwrapped._def.valueType || unwrapped._def.valueSchema || unwrapped._def.innerType;
6764
+ let innerDef;
6765
+ if (!mongooseProp.type || mongooseProp.type === Map || mongooseProp.type === Object) {
6766
+ mongooseProp.type = isMap ? Map : Object;
6767
+ const finalValueType = valueType || unwrapped.valueSchema || ((_b = unwrapped._def) == null ? void 0 : _b.valueSchema);
6768
+ if (finalValueType) {
6769
+ innerDef = extractMongooseDef2(finalValueType, visited);
6770
+ mongooseProp.of = innerDef.type || innerDef;
6771
+ }
6772
+ }
6773
+ callHookSync("schema:record:after", { schema: unwrapped, mongooseProp, innerDef });
6774
+ }
6775
+ function areDefinitionsEqual(left, right, seen = /* @__PURE__ */ new WeakMap()) {
6776
+ if (left === right)
6777
+ return true;
6778
+ if (left === null || right === null || typeof left !== "object" || typeof right !== "object") {
6779
+ return false;
6780
+ }
6781
+ const mongoose = getMongoose();
6782
+ const leftIsSchema = mongoose && left instanceof mongoose.Schema;
6783
+ const rightIsSchema = mongoose && right instanceof mongoose.Schema;
6784
+ if (leftIsSchema || rightIsSchema) {
6785
+ return Boolean(leftIsSchema && rightIsSchema && areDefinitionsEqual(left.obj, right.obj, seen));
6786
+ }
6787
+ let seenRight = seen.get(left);
6788
+ if (seenRight == null ? void 0 : seenRight.has(right))
6789
+ return true;
6790
+ if (!seenRight) {
6791
+ seenRight = /* @__PURE__ */ new WeakSet();
6792
+ seen.set(left, seenRight);
6793
+ }
6794
+ seenRight.add(right);
6795
+ if (Array.isArray(left) || Array.isArray(right)) {
6796
+ return Array.isArray(left) && Array.isArray(right) && left.length === right.length && left.every((value, index) => areDefinitionsEqual(value, right[index], seen));
6797
+ }
6798
+ const leftKeys = Object.keys(left);
6799
+ const rightKeys = Object.keys(right);
6800
+ return leftKeys.length === rightKeys.length && leftKeys.every((key) => Object.prototype.hasOwnProperty.call(right, key) && areDefinitionsEqual(left[key], right[key], seen));
6801
+ }
6802
+ function extractMongooseDef(schema, visited = /* @__PURE__ */ new Map(), isField = false, noWrap = false) {
6803
+ var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k;
6804
+ if (visited.size === 0) {
6805
+ callHookSync("converter:before", { schema, visited });
6806
+ }
6807
+ callHookSync("converter:start", { schema, visited });
6808
+ const { schema: unwrapped, features } = unwrapZodSchema(schema);
6809
+ const meta = mongooseRegistry.get(schema) || {};
6810
+ const mongooseProp = getMongooseMeta(schema);
6811
+ callHookSync("converter:unwrapped", {
6812
+ schema,
6813
+ unwrapped,
6814
+ features,
6815
+ meta: mongooseProp,
6816
+ mongooseProp
6817
+ });
6818
+ if (features.isOptional === true && mongooseProp.type && mongooseProp.required !== true) {
6819
+ mongooseProp.required = false;
6820
+ }
6821
+ if (visited.has(schema)) {
6822
+ const existing = visited.get(schema);
6823
+ if (existing === mongooseProp) {
6824
+ return existing;
6825
+ }
6826
+ if (Object.keys(meta).length > 0) {
6827
+ Object.assign(existing, mongooseProp);
6828
+ }
6829
+ return existing;
6830
+ }
6831
+ visited.set(schema, mongooseProp);
6832
+ if (features.default !== void 0) {
6833
+ mongooseProp.default = features.default;
6834
+ }
6835
+ if (features.required === false) {
6836
+ mongooseProp.required = false;
6837
+ }
6838
+ if (features.isNullable === true && mongooseProp.required === void 0) {
6839
+ mongooseProp.required = false;
6840
+ }
6841
+ if (features.isNonOptional === true && features.isNullable !== true && mongooseProp.required !== false) {
6842
+ mongooseProp.required = true;
6843
+ }
6844
+ if (features.readOnly === true) {
6845
+ mongooseProp.readOnly = true;
6846
+ }
6847
+ if (isField && features.isExactOptional === true) {
6848
+ const previousSetter = mongooseProp.set;
6849
+ mongooseProp.set = function exactOptionalSetter(value) {
6850
+ if (value === void 0) {
6851
+ throw new TypeError("An exactOptional field cannot be set to undefined");
6852
+ }
6853
+ return typeof previousSetter === "function" ? previousSetter.call(this, value) : value;
6854
+ };
6855
+ }
6856
+ mapZodChecksToMongoose(features.checks, mongooseProp);
6857
+ const def = unwrapped._def;
6858
+ if (!def) {
6859
+ callHookSync("converter:after", {
6860
+ schema,
6861
+ mongooseProp
6862
+ });
6863
+ return mongooseProp;
6864
+ }
6865
+ const { type } = def;
6866
+ callHookSync("converter:node", {
6867
+ schema: unwrapped,
6868
+ mongooseProp,
6869
+ type
6870
+ });
6871
+ if (type === "object") {
6872
+ const wrapperFn = (s, v) => extractMongooseDef(s, v, true);
6873
+ const previousUnwrapped = schema === unwrapped ? void 0 : visited.get(unwrapped);
6874
+ const result = handleObject(unwrapped, mongooseProp, visited, wrapperFn, isField && !noWrap);
6875
+ visited.set(schema, result);
6876
+ if (schema !== unwrapped) {
6877
+ if (previousUnwrapped === void 0)
6878
+ visited.delete(unwrapped);
6879
+ else
6880
+ visited.set(unwrapped, previousUnwrapped);
6881
+ }
6882
+ callHookSync("converter:after", {
6883
+ schema,
6884
+ mongooseProp: result
6885
+ });
6886
+ if (typeof result === "object" && result !== null && !Array.isArray(result)) {
6887
+ delete result.includeId;
6888
+ }
6889
+ return result;
6890
+ }
6891
+ if (type === "array" || type === "set" || type === "tuple") {
6892
+ handleArray(unwrapped, mongooseProp, visited, (s, v) => extractMongooseDef(s, v, true));
6893
+ }
6894
+ if (type === "record" || type === "map") {
6895
+ handleRecord(unwrapped, mongooseProp, visited, (s, v) => extractMongooseDef(s, v, true));
6896
+ }
6897
+ if (type === "intersection") {
6898
+ const left = extractMongooseDef(unwrapped._def.left, visited, isField, true);
6899
+ const right = extractMongooseDef(unwrapped._def.right, visited, isField, true);
6900
+ if (typeof left === "object" && typeof right === "object") {
6901
+ Object.assign(mongooseProp, left, right);
6902
+ if (isField && !noWrap && mongooseProp.schema !== false && !mongooseProp.type) {
6903
+ const mongoose = getMongoose();
6904
+ if (mongoose) {
6905
+ const options = typeof mongooseProp.schema === "object" ? mongooseProp.schema : {};
6906
+ const { plugins, ...schemaOptions } = options;
6907
+ const definition = { ...mongooseProp };
6908
+ delete definition.schema;
6909
+ const subSchema = new mongoose.Schema(definition, schemaOptions);
6910
+ if (plugins && Array.isArray(plugins)) {
6911
+ for (const plugin of plugins) {
6912
+ subSchema.plugin(plugin);
6913
+ }
6914
+ }
6915
+ mongooseProp.type = subSchema;
6916
+ for (const key of Object.keys(mongooseProp)) {
6917
+ if (key !== "type")
6918
+ delete mongooseProp[key];
6919
+ }
6920
+ }
6921
+ }
6922
+ } else if (!mongooseProp.type) {
6923
+ mongooseProp.type = ((_a = getMongoose()) == null ? void 0 : _a.Schema.Types.Mixed) || "Mixed";
6924
+ }
6925
+ }
6926
+ if ((type === "union" || type === "discriminatedunion" || type === "discriminated_union" || type === "xor") && !mongooseProp.type) {
6927
+ const mongoose = getMongoose();
6928
+ const options = unwrapped.options || unwrapped._def.options;
6929
+ const discriminatorKey = unwrapped._def.discriminator;
6930
+ const unionCtx = {
6931
+ isSimpleUnion: false,
6932
+ isObjectUnion: false,
6933
+ isXor: type === "xor" || (((_b = unwrapped._def) == null ? void 0 : _b.inclusive) === false || ((_c = schema._def) == null ? void 0 : _c.inclusive) === false) && !discriminatorKey && !((_d = schema._def) == null ? void 0 : _d.discriminator)
6934
+ };
6935
+ if (Array.isArray(options) && options.length > 0) {
6936
+ unionCtx.isSimpleUnion = options.every((opt) => {
6937
+ const { type: type2 } = unwrapZodSchema(opt).schema._def;
6938
+ return ["string", "number", "boolean", "date", "bigint", "literal"].includes(type2);
6939
+ });
6940
+ unionCtx.isObjectUnion = options.every((opt) => {
6941
+ const { type: type2 } = unwrapZodSchema(opt).schema._def;
6942
+ return type2 === "object";
6943
+ });
6944
+ }
6945
+ callHookSync("schema:union:before", { schema: unwrapped, mongooseProp, ctx: unionCtx });
6946
+ if (discriminatorKey && unionCtx.isObjectUnion) {
6947
+ const discriminators = {};
6948
+ const allOptionDefs = [];
6949
+ for (const option of options) {
6950
+ const { schema: unwrappedOpt } = unwrapZodSchema(option);
6951
+ const { shape } = unwrappedOpt._def;
6952
+ const discriminatorProp = shape[discriminatorKey];
6953
+ const { schema: unwrappedDisc } = unwrapZodSchema(discriminatorProp);
6954
+ const discriminatorValue = (_f = unwrappedDisc._def.value) != null ? _f : (_e = unwrappedDisc._def.values) == null ? void 0 : _e[0];
6955
+ const optionDef = extractMongooseDef(option, /* @__PURE__ */ new Map(), true, true);
6956
+ if (optionDef && typeof optionDef === "object" && !Array.isArray(optionDef)) {
6957
+ const cleanOptionDef = { ...optionDef };
6958
+ delete cleanOptionDef[discriminatorKey];
6959
+ discriminators[discriminatorValue] = cleanOptionDef;
6960
+ allOptionDefs.push(cleanOptionDef);
6961
+ }
6962
+ }
6963
+ const baseDef = {};
6964
+ if (allOptionDefs.length > 0) {
6965
+ const firstOption = allOptionDefs[0];
6966
+ for (const key of Object.keys(firstOption)) {
6967
+ const isCommon = allOptionDefs.every((def2) => {
6968
+ if (!(key in def2))
6969
+ return false;
6970
+ return areDefinitionsEqual(def2[key], firstOption[key]);
6971
+ });
6972
+ if (isCommon) {
6973
+ baseDef[key] = firstOption[key];
6974
+ for (const def2 of allOptionDefs) {
6975
+ delete def2[key];
6976
+ }
6977
+ }
6978
+ }
6979
+ }
6980
+ const result = {
6981
+ __isDiscriminatorUnion: true,
6982
+ discriminatorKey,
6983
+ discriminators,
6984
+ baseDef,
6985
+ validate: {
6986
+ validator(_v) {
6987
+ var _a2, _b2;
6988
+ try {
6989
+ const mongoose2 = getMongoose();
6990
+ const doc = mongoose2 && this instanceof mongoose2.Document ? this.toObject() : this || {};
6991
+ schema.parse(doc);
6992
+ return true;
6993
+ } catch (err) {
6994
+ const message = ((_b2 = (_a2 = err == null ? void 0 : err.errors) == null ? void 0 : _a2[0]) == null ? void 0 : _b2.message) || err.message;
6995
+ if (this && typeof this.invalidate === "function") {
6996
+ this.invalidate(discriminatorKey, `Zod validation failed: ${message}`);
6997
+ }
6998
+ return false;
6999
+ }
7000
+ },
7001
+ message: (props) => `Validation failed for ${props.path}`
7002
+ }
7003
+ };
7004
+ if (mongooseProp && typeof mongooseProp === "object" && !Array.isArray(mongooseProp)) {
7005
+ Object.assign(mongooseProp, result);
7006
+ callHookSync("schema:union:after", {
7007
+ schema: unwrapped,
7008
+ mongooseProp,
7009
+ ctx: unionCtx
7010
+ });
7011
+ return mongooseProp;
7012
+ }
7013
+ callHookSync("schema:union:after", {
7014
+ schema: unwrapped,
7015
+ mongooseProp: result,
7016
+ ctx: unionCtx
7017
+ });
7018
+ return result;
7019
+ }
7020
+ if (((_g = getMongoose()) == null ? void 0 : _g.Schema.Types.Union) && unionCtx.isSimpleUnion && options.length > 0 && !unionCtx.isXor) {
7021
+ mongooseProp.type = mongoose.Schema.Types.Union;
7022
+ mongooseProp.of = options.map((opt) => {
7023
+ const def2 = extractMongooseDef(opt, visited, true, true);
7024
+ return def2.type || def2;
7025
+ });
7026
+ } else if (unionCtx.isObjectUnion && options.length > 0) {
7027
+ const mergedDef = {};
7028
+ for (const opt of options) {
7029
+ const def2 = extractMongooseDef(opt, /* @__PURE__ */ new Map(), true, true);
7030
+ if (typeof def2 === "object" && def2 !== null) {
7031
+ for (const [key, prop] of Object.entries(def2)) {
7032
+ if (typeof prop === "object" && prop !== null && !Array.isArray(prop)) {
7033
+ prop.required = false;
7034
+ }
7035
+ if (mergedDef[key] && typeof mergedDef[key] === "object" && typeof prop === "object" && !Array.isArray(mergedDef[key]) && !Array.isArray(prop)) {
7036
+ const existingType = mergedDef[key].type || mergedDef[key].instance || (typeof mergedDef[key] === "function" ? mergedDef[key] : null);
7037
+ const newType = prop.type || prop.instance || (typeof prop === "function" ? prop : null);
7038
+ const isMixed = (t) => {
7039
+ var _a2, _b2;
7040
+ return !t || t === "Mixed" || t === "SchemaMixed" || (t == null ? void 0 : t.name) === "Mixed" || (t == null ? void 0 : t.instance) === "Mixed" || (t == null ? void 0 : t.name) === "SchemaMixed" || (t == null ? void 0 : t.instance) === "SchemaMixed" || ((_a2 = getMongoose()) == null ? void 0 : _a2.Schema.Types.Mixed) && (t === ((_b2 = getMongoose()) == null ? void 0 : _b2.Schema.Types.Mixed) || (t == null ? void 0 : t.instance) === "Mixed" || (t == null ? void 0 : t.instance) === "SchemaMixed");
7041
+ };
7042
+ if (isMixed(existingType) && !isMixed(newType)) {
7043
+ mergedDef[key] = prop;
7044
+ } else if (!isMixed(existingType) && isMixed(newType)) ;
7045
+ else {
7046
+ Object.assign(mergedDef[key], prop);
7047
+ }
7048
+ } else if (!mergedDef[key] || typeof mergedDef[key] !== "object" || Array.isArray(mergedDef[key])) {
7049
+ mergedDef[key] = prop;
7050
+ }
7051
+ }
7052
+ }
7053
+ }
7054
+ if (isField && unionCtx.isXor) {
7055
+ mongooseProp.type = (mongoose == null ? void 0 : mongoose.Schema.Types.Mixed) || "Mixed";
7056
+ mongooseProp.validate = {
7057
+ validator(v) {
7058
+ try {
7059
+ schema.parse(v);
7060
+ return true;
7061
+ } catch {
7062
+ return false;
7063
+ }
7064
+ },
7065
+ message: "XOR validation failed"
7066
+ };
7067
+ } else {
7068
+ if (!mongooseProp.type || mongooseProp.type === (((_h = getMongoose()) == null ? void 0 : _h.Schema.Types.Mixed) || "Mixed")) {
7069
+ delete mongooseProp.type;
7070
+ }
7071
+ Object.assign(mongooseProp, mergedDef);
7072
+ if (isField && Object.prototype.hasOwnProperty.call(mongooseProp, "type") && Object.keys(mongooseProp).length > 1) {
7073
+ const mongooseInstance3 = getMongoose();
7074
+ if (mongooseInstance3) {
7075
+ mongooseProp.type = new mongooseInstance3.Schema(mongooseProp, { _id: false });
7076
+ for (const key of Object.keys(mongooseProp)) {
7077
+ if (key !== "type")
7078
+ delete mongooseProp[key];
7079
+ }
7080
+ }
7081
+ }
7082
+ }
7083
+ } else {
7084
+ mongooseProp.type = (mongoose == null ? void 0 : mongoose.Schema.Types.Mixed) || "Mixed";
7085
+ if (isField && (type === "xor" || type === "discriminated_union" || type === "discriminatedunion" || type === "union") && !mongooseProp.ref && // Skip Zod validation for populated fields
7086
+ !Array.isArray(mongooseProp.type) && // Skip Zod validation for arrays
7087
+ mongooseProp.type !== Map && // Skip Zod validation for maps
7088
+ !mongooseProp.of) {
7089
+ mongooseProp.validate = {
7090
+ validator(v) {
7091
+ try {
7092
+ schema.parse(v);
7093
+ return true;
7094
+ } catch (err) {
7095
+ return false;
7096
+ }
7097
+ },
7098
+ message: (props) => {
7099
+ if (unionCtx.isXor)
7100
+ return "XOR validation failed";
7101
+ try {
7102
+ schema.parse(props.value);
7103
+ } catch (err) {
7104
+ return `Union validation failed: ${err.message}`;
7105
+ }
7106
+ return "Union validation failed";
7107
+ }
7108
+ };
7109
+ }
7110
+ }
7111
+ callHookSync("schema:union:after", {
7112
+ schema: unwrapped,
7113
+ mongooseProp,
7114
+ ctx: unionCtx
7115
+ });
7116
+ }
7117
+ if (type === "literal" && !mongooseProp.type) {
7118
+ mongooseProp.type = ((_i = getMongoose()) == null ? void 0 : _i.Schema.Types.Mixed) || "Mixed";
7119
+ }
7120
+ switch (type) {
7121
+ case "string":
7122
+ case "number":
7123
+ case "boolean":
7124
+ case "date":
7125
+ case "bigint":
7126
+ case "stringbool":
7127
+ case "boolstring":
7128
+ case "booleanstring": {
7129
+ if (!mongooseProp.type) {
7130
+ if (type === "bigint") {
7131
+ mongooseProp.type = typeof BigInt === "undefined" ? Number : BigInt;
7132
+ } else {
7133
+ const typeMap = {
7134
+ string: String,
7135
+ number: Number,
7136
+ boolean: Boolean,
7137
+ date: Date,
7138
+ stringbool: Boolean,
7139
+ boolstring: Boolean,
7140
+ booleanstring: Boolean
7141
+ };
7142
+ mongooseProp.type = typeMap[type];
7143
+ if (mongooseProp.default !== void 0) {
7144
+ const defaultType = typeof mongooseProp.default;
7145
+ if (defaultType === "boolean" && type !== "boolean") {
7146
+ mongooseProp.type = Boolean;
7147
+ } else if (defaultType === "number" && type !== "number") {
7148
+ mongooseProp.type = Number;
7149
+ } else if (defaultType === "string" && type !== "string") {
7150
+ mongooseProp.type = String;
7151
+ } else if (mongooseProp.default instanceof Date && type !== "date") {
7152
+ mongooseProp.type = Date;
7153
+ }
7154
+ }
7155
+ if (mongooseProp.type === String && features.transformations) {
7156
+ for (const tx of features.transformations) {
7157
+ const txStr = ((_j = tx.transform) == null ? void 0 : _j.toString()) || tx.toString();
7158
+ if (txStr.includes("stringbool") || txStr.includes("boolstring") || txStr.includes("booleanstring")) {
7159
+ mongooseProp.type = Boolean;
7160
+ break;
7161
+ }
7162
+ if (txStr.includes('=== "true"') || txStr.includes("=== 'true'")) {
7163
+ mongooseProp.type = Boolean;
7164
+ break;
7165
+ }
7166
+ }
7167
+ }
7168
+ }
7169
+ }
7170
+ if (mongooseProp.required !== false)
7171
+ mongooseProp.required = true;
7172
+ break;
7173
+ }
7174
+ case "enum":
7175
+ case "nativeenum":
7176
+ case "native_enum": {
7177
+ if (!mongooseProp.type)
7178
+ mongooseProp.type = String;
7179
+ mongooseProp.enum = type === "enum" ? unwrapped.options || def.values : Object.values(unwrapped.enum || def.values);
7180
+ if (mongooseProp.required !== false)
7181
+ mongooseProp.required = true;
7182
+ break;
7183
+ }
7184
+ }
7185
+ const mongooseInstance2 = getMongoose();
7186
+ if (type === "any" || type === "unknown" || type === "custom") {
7187
+ const cls = def.cls || unwrapped.cls;
7188
+ if (cls === Buffer || typeof Uint8Array !== "undefined" && cls === Uint8Array) {
7189
+ if (!mongooseProp.type)
7190
+ mongooseProp.type = (mongooseInstance2 == null ? void 0 : mongooseInstance2.Schema.Types.Buffer) || "Buffer";
7191
+ } else if (((cls == null ? void 0 : cls.name) === "ObjectId" || mongooseInstance2 && cls === mongooseInstance2.Types.ObjectId) && !mongooseProp.type) {
7192
+ mongooseProp.type = (mongooseInstance2 == null ? void 0 : mongooseInstance2.Schema.Types.ObjectId) || "ObjectId";
7193
+ }
7194
+ }
7195
+ if (type === "lazy") {
7196
+ const inner = def.getter();
7197
+ const result = extractMongooseDef(inner, visited, isField);
7198
+ if (Object.keys(meta).length > 0 && result !== mongooseProp) {
7199
+ if (typeof result === "object" && !Array.isArray(result)) {
7200
+ Object.assign(mongooseProp, result);
7201
+ } else {
7202
+ mongooseProp.type = result.type || result;
7203
+ }
7204
+ return mongooseProp;
7205
+ }
7206
+ return result;
7207
+ }
7208
+ if (!mongooseProp.type && type !== "object") {
7209
+ mongooseProp.type = ((_k = getMongoose()) == null ? void 0 : _k.Schema.Types.Mixed) || "Mixed";
7210
+ }
7211
+ callHookSync("converter:after", {
7212
+ schema,
7213
+ mongooseProp
7214
+ });
7215
+ if (typeof mongooseProp === "object" && mongooseProp !== null && !Array.isArray(mongooseProp)) {
7216
+ delete mongooseProp.includeId;
7217
+ }
7218
+ return mongooseProp;
7219
+ }
7220
+ function modelNameFromCollection(collection) {
7221
+ const singular = collection.replace(/ies$/i, "y").replace(/(ses|xes|zes|ches|shes)$/i, (suffix) => suffix.slice(0, -2)).replace(/s$/i, "");
7222
+ return singular.slice(0, 1).toUpperCase() + singular.slice(1);
7223
+ }
7224
+ function toMongooseSchema(schema, options) {
7225
+ var _a, _b;
7226
+ const { schema: unwrapped } = unwrapZodSchema(schema);
7227
+ const meta = mongooseRegistry.get(schema) || mongooseRegistry.get(unwrapped) || ((_a = schema.meta) == null ? void 0 : _a.call(schema)) || ((_b = unwrapped.meta) == null ? void 0 : _b.call(unwrapped)) || {};
7228
+ const { plugins, modelName, ...schemaOptions } = options || {};
7229
+ const mergedOptions = {
7230
+ ...unwrapped instanceof z.ZodObject ? { strict: objectStrictness(unwrapped) } : {},
7231
+ ...unwrapped instanceof z.ZodObject && objectStrictness(unwrapped) === false ? { minimize: false } : {},
7232
+ // Also merge other schema options from meta if they exist
7233
+ ...meta.collection ? { collection: meta.collection } : {},
7234
+ // eslint-disable-next-line unicorn/no-negated-condition
7235
+ ...meta.strict !== void 0 ? { strict: meta.strict } : {},
7236
+ // eslint-disable-next-line unicorn/no-negated-condition
7237
+ ...meta.minimize !== void 0 ? { minimize: meta.minimize } : {},
7238
+ // eslint-disable-next-line unicorn/no-negated-condition
7239
+ ...meta.validateBeforeSave !== void 0 ? { validateBeforeSave: meta.validateBeforeSave } : {},
7240
+ // eslint-disable-next-line unicorn/no-negated-condition
7241
+ ...meta.versionKey !== void 0 ? { versionKey: meta.versionKey } : {},
7242
+ ...meta.id === void 0 ? {} : { id: meta.id },
7243
+ ...meta._id === void 0 ? {} : { _id: meta._id },
7244
+ ...meta.timestamps ? { timestamps: meta.timestamps } : {},
7245
+ ...meta.discriminatorKey ? { discriminatorKey: meta.discriminatorKey } : {},
7246
+ ...schemaOptions
7247
+ };
7248
+ let definition = extractMongooseDef(schema, /* @__PURE__ */ new Map(), false);
7249
+ const mongoose = getMongoose();
7250
+ if (!mongoose) {
7251
+ throw new Error("Mongoose must be installed to use toMongooseSchema. If you are in an ESM environment, ensure mongoose is loaded.");
7252
+ }
7253
+ let mongooseSchema;
7254
+ if (definition && typeof definition === "object" && definition.__isDiscriminatorUnion) {
7255
+ const baseModelName = modelName || schemaOptions.collection && modelNameFromCollection(schemaOptions.collection);
7256
+ if (!baseModelName) {
7257
+ throw new Error("toMongooseSchema() found a top-level discriminated union. Provide `modelName` or `collection` so discriminator model names can be made unique, for example `{ modelName: 'Activity' }`.");
7258
+ }
7259
+ const { discriminatorKey, discriminators, baseDef, validate } = definition;
7260
+ mongooseSchema = new mongoose.Schema(baseDef, {
7261
+ ...mergedOptions,
7262
+ discriminatorKey
7263
+ });
7264
+ if (validate) {
7265
+ if (!mongooseSchema.path(discriminatorKey)) {
7266
+ mongooseSchema.add({ [discriminatorKey]: { type: String } });
7267
+ }
7268
+ mongooseSchema.path(discriminatorKey).validate(validate);
7269
+ }
7270
+ for (const [key, dDef] of Object.entries(discriminators)) {
7271
+ const discriminatorModelName = `${baseModelName}_${key}`;
7272
+ if (mongooseSchema.discriminators && mongooseSchema.discriminators[discriminatorModelName]) {
7273
+ continue;
7274
+ }
7275
+ mongooseSchema.discriminator(discriminatorModelName, new mongoose.Schema(dDef, { _id: false }), { value: key });
7276
+ }
7277
+ } else {
7278
+ if (typeof definition === "object" && definition !== null) {
7279
+ const { includeId, ...cleanDefinition } = definition;
7280
+ definition = cleanDefinition;
7281
+ for (const value of Object.values(definition)) {
7282
+ if (value && typeof value === "object" && !Array.isArray(value)) {
7283
+ delete value.includeId;
7284
+ }
7285
+ }
7286
+ }
7287
+ mongooseSchema = new mongoose.Schema(definition, mergedOptions);
7288
+ }
7289
+ if (mergedOptions.validateBeforeSave !== false) {
7290
+ mongooseSchema.post("validate", function() {
7291
+ var _a2, _b2, _c, _d;
7292
+ try {
7293
+ schema.parse(prepareForZodValidation(schema, this.toObject(), mongooseSchema));
7294
+ } catch (e) {
7295
+ if (e instanceof z.ZodError) {
7296
+ e.message = JSON.stringify({
7297
+ context: {
7298
+ model: ((_a2 = this.constructor) == null ? void 0 : _a2.modelName) || ((_b2 = this.constructor) == null ? void 0 : _b2.name) || "_unknown_",
7299
+ id: ((_c = this._id) == null ? void 0 : _c.toString()) || ((_d = this.id) == null ? void 0 : _d.toString()) || "_unknown_"
7300
+ },
7301
+ errors: e.issues || e.errors || []
7302
+ });
7303
+ }
7304
+ throw e;
7305
+ }
7306
+ });
7307
+ }
7308
+ if (plugins && Array.isArray(plugins)) {
7309
+ for (const plugin of plugins) {
7310
+ mongooseSchema.plugin(plugin);
7311
+ }
7312
+ }
7313
+ callHookSync("schema:created", {
7314
+ schema,
7315
+ mongooseSchema,
7316
+ options: mergedOptions
7317
+ });
7318
+ return mongooseSchema;
7319
+ }
7320
+ function populateZodSchema(schema, keys) {
7321
+ const { shape } = schema;
7322
+ const newShape = { ...shape };
7323
+ const keysToPopulate = keys || Object.keys(shape);
7324
+ const populateField = (field) => {
7325
+ const meta = getMongooseMeta(field);
7326
+ const { schema: unwrapped, features } = unwrapZodSchema(field);
7327
+ let result = field;
7328
+ if (meta == null ? void 0 : meta.refSchema) {
7329
+ result = meta.refSchema;
7330
+ } else if (unwrapped instanceof z.ZodArray) {
7331
+ const populatedInner = populateField(unwrapped.element);
7332
+ if (populatedInner !== unwrapped.element) {
7333
+ result = z.array(populatedInner);
7334
+ }
7335
+ } else if (unwrapped instanceof z.ZodObject) {
7336
+ result = populateZodSchema(unwrapped);
7337
+ }
7338
+ if (result !== field && result !== unwrapped) {
7339
+ if (features.isOptional && !(result instanceof z.ZodOptional))
7340
+ result = result.optional();
7341
+ if (features.isNullable && !(result instanceof z.ZodNullable))
7342
+ result = result.nullable();
7343
+ if (features.default !== void 0 && !(result instanceof z.ZodDefault))
7344
+ result = result.default(features.default);
7345
+ }
7346
+ return result;
7347
+ };
7348
+ for (const key of keysToPopulate) {
7349
+ newShape[key] = populateField(shape[key]);
7350
+ }
7351
+ return z.object(newShape);
7352
+ }
7353
+ const genTimestampsSchema = (createdAtField = "createdAt", updatedAtField = "updatedAt") => {
7354
+ if (createdAtField != null && updatedAtField != null && createdAtField === updatedAtField) {
7355
+ throw new Error("`createdAt` and `updatedAt` fields must be different");
7356
+ }
7357
+ const shape = {};
7358
+ if (createdAtField != null)
7359
+ shape[createdAtField] = z.date().default(() => /* @__PURE__ */ new Date());
7360
+ if (updatedAtField != null)
7361
+ shape[updatedAtField] = z.date().default(() => /* @__PURE__ */ new Date());
7362
+ return shape;
7363
+ };
7364
+ const bufferMongooseGetter = (value) => value != null && value._bsontype === "Binary" ? value.buffer : value;
7365
+ const position = z.tuple([z.number(), z.number()]);
7366
+ const zPoint = (options) => withMongoose(z.object({
7367
+ type: withMongoose(z.literal("Point"), { type: String, enum: ["Point"], required: true }),
7368
+ coordinates: withMongoose(position, { required: true })
7369
+ }), { schema: { _id: false }, required: true, ...options });
7370
+ const zPolygon = (options) => withMongoose(z.object({
7371
+ type: withMongoose(z.literal("Polygon"), { type: String, enum: ["Polygon"], required: true }),
7372
+ coordinates: withMongoose(z.array(z.array(position).refine((ring) => {
7373
+ var _a, _b, _c, _d;
7374
+ return ring.length >= 4 && ((_a = ring[0]) == null ? void 0 : _a[0]) === ((_b = ring.at(-1)) == null ? void 0 : _b[0]) && ((_c = ring[0]) == null ? void 0 : _c[1]) === ((_d = ring.at(-1)) == null ? void 0 : _d[1]);
7375
+ }, "Polygon rings must be closed")).refine((rings) => rings.length > 0, "Polygon must have at least one ring"), { required: true })
7376
+ }), { schema: { _id: false }, required: true, ...options });
7377
+ const preprocessFn = (val) => val === null ? void 0 : val;
7378
+ const zObjectId = (options) => {
7379
+ var _a;
7380
+ const objectIdSchema = z.custom((val) => {
7381
+ const mongooseInstance2 = getMongoose();
7382
+ return mongooseInstance2 && val instanceof mongooseInstance2.Types.ObjectId;
7383
+ });
7384
+ const baseUnion = z.preprocess(preprocessFn, z.union([objectIdSchema, z.string().regex(/^[\dA-Fa-f]{24}$/, "Invalid ObjectId")]));
7385
+ const inputSchema = z.codec(baseUnion, objectIdSchema, {
7386
+ decode: (val) => {
7387
+ const mongooseInstance2 = getMongoose();
7388
+ if (!mongooseInstance2)
7389
+ return val;
7390
+ if (val instanceof mongooseInstance2.Types.ObjectId) {
7391
+ return val;
7392
+ }
7393
+ return new mongooseInstance2.Types.ObjectId(val);
7394
+ },
7395
+ encode: (val) => val.toString()
7396
+ });
7397
+ return withMongoose(inputSchema, {
7398
+ type: ((_a = getMongoose()) == null ? void 0 : _a.Schema.Types.ObjectId) || "ObjectId",
7399
+ ...options
7400
+ });
7401
+ };
7402
+ const zBuffer = (options) => {
7403
+ var _a;
7404
+ return withMongoose(z.preprocess((val) => {
7405
+ var _a2;
7406
+ const Binary = (_a2 = getMongoose()) == null ? void 0 : _a2.mongo.Binary;
7407
+ return Binary && val instanceof Binary ? Buffer.from(val.value()) : val;
7408
+ }, z.custom((val) => val instanceof Uint8Array)), { type: ((_a = getMongoose()) == null ? void 0 : _a.Schema.Types.Buffer) || "Buffer", ...options });
7409
+ };
7410
+ const zRef = (ref, schema, options) => {
7411
+ var _a;
7412
+ const objectIdSchema = zObjectId();
7413
+ const base = z.codec(z.union([objectIdSchema, schema]), objectIdSchema, {
7414
+ decode: (val) => typeof val === "object" && val !== null && "_id" in val ? val._id : val,
7415
+ encode: (val) => val
7416
+ });
7417
+ return withMongoose(base, {
7418
+ type: ((_a = getMongoose()) == null ? void 0 : _a.Schema.Types.ObjectId) || "ObjectId",
7419
+ ref,
7420
+ refSchema: schema,
7421
+ ...options
7422
+ });
7423
+ };
7424
+ function toStrictModel(name, mongooseSchema) {
7425
+ const m = getMongoose();
7426
+ if (!m) {
7427
+ throw new Error("Mongoose must be installed to use toStrictModel.");
7428
+ }
7429
+ const rawModel = m.model(name, mongooseSchema);
7430
+ return rawModel;
7431
+ }
7432
+
7433
+ const mongooseZod = /*#__PURE__*/Object.freeze(/*#__PURE__*/Object.defineProperty({
7434
+ __proto__: null,
7435
+ bufferMongooseGetter: bufferMongooseGetter,
7436
+ callHookSync: callHookSync,
7437
+ extractMongooseDef: extractMongooseDef,
7438
+ genTimestampsSchema: genTimestampsSchema,
7439
+ getFrontendMode: getFrontendMode,
7440
+ getMongoose: getMongoose,
7441
+ getMongooseMeta: getMongooseMeta,
7442
+ hooks: hooks,
7443
+ mongooseRegistry: mongooseRegistry,
7444
+ objectStrictness: objectStrictness,
7445
+ populateZodSchema: populateZodSchema,
7446
+ setFrontendMode: setFrontendMode,
7447
+ setMongoose: setMongoose,
7448
+ toMongooseSchema: toMongooseSchema,
7449
+ toStrictModel: toStrictModel,
7450
+ unwrapZodSchema: unwrapZodSchema,
7451
+ withMongoose: withMongoose,
7452
+ zBuffer: zBuffer,
7453
+ zObjectId: zObjectId,
7454
+ zPoint: zPoint,
7455
+ zPolygon: zPolygon,
7456
+ zRef: zRef
7457
+ }, Symbol.toStringTag, { value: 'Module' }));
7458
+
7459
+ function checks(schema) {
7460
+ return (schema._def.checks || []).map((check) => {
7461
+ var _a;
7462
+ return ((_a = check._zod) == null ? void 0 : _a.def) || check.def || {};
7463
+ });
7464
+ }
7465
+ function sampleString(schema, key) {
7466
+ var _a;
7467
+ const rules = checks(schema);
7468
+ const format = schema._def.format || ((_a = rules.find((rule) => rule.format)) == null ? void 0 : _a.format);
7469
+ if (format === "email" || /email/i.test(key)) return "alex@example.com";
7470
+ if (format === "uuid") return "123e4567-e89b-42d3-a456-426614174000";
7471
+ if (format === "url") return "https://example.com";
7472
+ if (format === "datetime") return "2026-01-01T12:00:00.000Z";
7473
+ if (format === "date") return "2026-01-01";
7474
+ const minimum = Math.max(1, ...rules.filter((rule) => rule.check === "min_length").map((rule) => rule.minimum));
7475
+ const base = /name/i.test(key) ? "Alex Morgan" : /title/i.test(key) ? "Example title" : "example";
7476
+ return base.padEnd(Math.min(minimum, 100), "x");
7477
+ }
7478
+ function sampleNumber(schema) {
7479
+ const rules = checks(schema);
7480
+ const lower = rules.find((rule) => rule.check === "greater_than");
7481
+ const upper = rules.find((rule) => rule.check === "less_than");
7482
+ const integer = schema._def.type === "int" || rules.some((rule) => rule.check === "number_format" && rule.format === "safeint");
7483
+ const minimum = lower ? Number(lower.value) + (lower.inclusive ? 0 : integer ? 1 : 0.1) : 1;
7484
+ const maximum = upper ? Number(upper.value) - (upper.inclusive ? 0 : integer ? 1 : 0.1) : Infinity;
7485
+ const candidate = Math.min(Math.max(21, minimum), maximum);
7486
+ return integer ? Math.ceil(candidate) : candidate;
7487
+ }
7488
+ function createExample(schema, key = "value", depth = 0, seen = /* @__PURE__ */ new Set()) {
7489
+ var _a;
7490
+ if (depth > 8 || seen.has(schema)) throw new Error("This recursive schema needs a handwritten example.");
7491
+ const nextSeen = new Set(seen).add(schema);
7492
+ const def = schema._def;
7493
+ const mongooseType = getMongooseMeta(schema).type;
7494
+ if (mongooseType === "ObjectId" || (mongooseType == null ? void 0 : mongooseType.schemaName) === "ObjectId") return "507f1f77bcf86cd799439011";
7495
+ switch (def.type) {
7496
+ case "optional":
7497
+ case "default":
7498
+ case "prefault":
7499
+ return depth === 0 ? createExample(def.innerType, key, depth + 1, nextSeen) : void 0;
7500
+ case "nullable":
7501
+ case "nonoptional":
7502
+ case "readonly":
7503
+ case "catch":
7504
+ return createExample(def.innerType, key, depth + 1, nextSeen);
7505
+ case "pipe":
7506
+ return createExample(def.in, key, depth + 1, nextSeen);
7507
+ case "lazy":
7508
+ return createExample(def.getter(), key, depth + 1, nextSeen);
7509
+ case "object": {
7510
+ const result = {};
7511
+ for (const [field, fieldSchema] of Object.entries(schema.shape || def.shape || {})) {
7512
+ const value = createExample(fieldSchema, field, depth + 1, nextSeen);
7513
+ if (value !== void 0) result[field] = value;
7514
+ }
7515
+ return result;
7516
+ }
7517
+ case "array": {
7518
+ const minimum = Math.max(0, ...checks(schema).filter((rule) => rule.check === "min_length").map((rule) => rule.minimum));
7519
+ return Array.from({ length: Math.min(Math.max(1, minimum), 10) }, () => createExample(def.element, key, depth + 1, nextSeen));
7520
+ }
7521
+ case "tuple":
7522
+ return def.items.map((item) => createExample(item, key, depth + 1, nextSeen));
7523
+ case "string":
7524
+ return sampleString(schema, key);
7525
+ case "number":
7526
+ case "int":
7527
+ return sampleNumber(schema);
7528
+ case "boolean":
7529
+ return true;
7530
+ case "enum":
7531
+ return Object.values(def.entries)[0];
7532
+ case "literal":
7533
+ return (_a = def.values) == null ? void 0 : _a[0];
7534
+ case "union":
7535
+ return createExample(def.options[0], key, depth + 1, nextSeen);
7536
+ case "record":
7537
+ return { example: createExample(def.valueType, key, depth + 1, nextSeen) };
7538
+ case "date":
7539
+ return "2026-01-01T12:00:00.000Z";
7540
+ default:
7541
+ throw new Error(`Automatic examples do not yet support ${def.type || "this schema"}.`);
7542
+ }
7543
+ }
7544
+
7545
+ const MAX_BODY_BYTES = 16e4;
7546
+ async function readStudioRequest(event) {
7547
+ const chunks = [];
7548
+ let size = 0;
7549
+ for await (const chunk of event.node.req) {
7550
+ const bytes = Buffer.isBuffer(chunk) ? chunk : Buffer.from(chunk);
7551
+ size += bytes.length;
7552
+ if (size > MAX_BODY_BYTES) throw createError$1({ statusCode: 413, message: "Studio input is too large." });
7553
+ chunks.push(bytes);
7554
+ }
7555
+ let body;
7556
+ try {
7557
+ body = JSON.parse(Buffer.concat(chunks).toString("utf8"));
7558
+ } catch {
7559
+ throw createError$1({ statusCode: 400, message: "Invalid JSON request." });
7560
+ }
7561
+ if (typeof (body == null ? void 0 : body.sourceCode) !== "string" || !body.sourceCode.trim()) {
7562
+ throw createError$1({ statusCode: 400, message: "Add a Zod schema to the editor first." });
7563
+ }
7564
+ if (body.sourceCode.length > 5e4 || typeof body.inputData !== "string" || body.inputData.length > 1e5 || body.selectedSchema !== void 0 && typeof body.selectedSchema !== "string" || body.action !== void 0 && body.action !== "run" && body.action !== "example") {
7565
+ throw createError$1({ statusCode: 400, message: "Invalid or oversized Studio input." });
7566
+ }
7567
+ return body;
7568
+ }
7569
+
7570
+ const MAX_RESPONSE_BYTES = 1e6;
7571
+ function runInContainer(body, socketPath) {
7572
+ const payload = JSON.stringify(body);
7573
+ return new Promise((resolve, reject) => {
7574
+ const req = request({
7575
+ socketPath,
7576
+ path: "/run",
7577
+ method: "POST",
7578
+ headers: { "content-type": "application/json", "content-length": Buffer.byteLength(payload) }
7579
+ }, (res) => {
7580
+ const chunks = [];
7581
+ let size = 0;
7582
+ res.on("data", (chunk) => {
7583
+ size += chunk.length;
7584
+ if (size > MAX_RESPONSE_BYTES) {
7585
+ req.destroy(new Error("Studio result is too large."));
7586
+ return;
7587
+ }
7588
+ chunks.push(chunk);
7589
+ });
7590
+ res.on("end", () => {
7591
+ try {
7592
+ const result = JSON.parse(Buffer.concat(chunks).toString("utf8"));
7593
+ if (res.statusCode !== 200) {
7594
+ reject(createError$1({ statusCode: res.statusCode === 400 ? 400 : res.statusCode === 504 ? 504 : 503, message: result.error || "Studio runner failed." }));
7595
+ } else resolve(result);
7596
+ } catch {
7597
+ reject(createError$1({ statusCode: 502, message: "Invalid response from Studio runner." }));
7598
+ }
7599
+ });
7600
+ res.on("error", reject);
7601
+ });
7602
+ req.setTimeout(5e3, () => req.destroy(new Error("Studio runner timed out.")));
7603
+ req.on("error", reject);
7604
+ req.end(payload);
7605
+ });
7606
+ }
7607
+
7608
+ var __defProp = Object.defineProperty;
7609
+ var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
7610
+ var __publicField = (obj, key, value) => __defNormalProp(obj, key + "" , value);
7611
+ setMongoose(mongoose);
7612
+ class StudioExecutionError extends Error {
7613
+ constructor() {
7614
+ super(...arguments);
7615
+ __publicField(this, "statusCode", 400);
7616
+ }
7617
+ }
7618
+ function errorMessage(error) {
7619
+ return error instanceof Error ? error.message || error.name : String(error);
7620
+ }
7621
+ function declaredNames(jsCode) {
7622
+ const file = parse(jsCode, { ecmaVersion: "latest", sourceType: "script" });
7623
+ const names = [];
7624
+ for (const statement of file.body) {
7625
+ if (statement.type !== "VariableDeclaration") continue;
7626
+ for (const declaration of statement.declarations) {
7627
+ if (declaration.id.type === "Identifier") names.push(declaration.id.name);
7628
+ }
7629
+ }
7630
+ return names;
7631
+ }
7632
+ function displayValue(value) {
7633
+ const seen = /* @__PURE__ */ new WeakSet();
7634
+ return JSON.stringify(value, (_key, item) => {
7635
+ if (typeof item === "bigint") return `${item.toString()}n`;
7636
+ if (typeof item === "undefined") return "[undefined]";
7637
+ if (typeof item === "number" && !Number.isFinite(item)) return String(item);
7638
+ if (typeof item === "object" && item !== null) {
7639
+ if (item instanceof Date) return item.toISOString();
7640
+ if (typeof item.toHexString === "function") return item.toHexString();
7641
+ if (seen.has(item)) return "[Circular]";
7642
+ seen.add(item);
7643
+ }
7644
+ return item;
7645
+ }, 2) || "undefined";
7646
+ }
7647
+ function formatMongoose(value) {
7648
+ if (typeof value === "function") return value.name || value.toString();
7649
+ if (Array.isArray(value)) return value.map(formatMongoose);
7650
+ if (value !== null && typeof value === "object" && value.constructor === Object) {
7651
+ return Object.fromEntries(Object.entries(value).map(([key, entry]) => [key, formatMongoose(entry)]));
7652
+ }
7653
+ return value;
7654
+ }
7655
+ function executeStudio(body, timeoutMs) {
7656
+ var _a;
7657
+ const sourceCode = body.sourceCode;
7658
+ hooks.removeAllHooks();
7659
+ try {
7660
+ let jsCode;
7661
+ try {
7662
+ jsCode = transformSync(sourceCode, { loader: "ts", format: "cjs", target: "esnext" }).code;
7663
+ } catch (error) {
7664
+ throw new StudioExecutionError(`Compilation error: ${errorMessage(error)}`);
7665
+ }
7666
+ const names = declaredNames(jsCode);
7667
+ const sandboxRequire = (moduleName) => {
7668
+ if (moduleName === "zod" || moduleName === "zod/v4") return zod;
7669
+ if (moduleName === "@nullix/zod-mongoose") return mongooseZod;
7670
+ if (moduleName === "mongoose") return mongoose;
7671
+ throw new Error(`Module "${moduleName}" is unavailable in Studio.`);
7672
+ };
7673
+ const context = vm.createContext({
7674
+ ...mongooseZod,
7675
+ z: zod.z,
7676
+ mongoose,
7677
+ require: sandboxRequire,
7678
+ console: { log: () => {
7679
+ }, warn: () => {
7680
+ }, error: () => {
7681
+ } },
7682
+ __filename: "/sandbox/main.ts",
7683
+ __dirname: "/sandbox"
7684
+ });
7685
+ const captured = names.map((name) => `${JSON.stringify(name)}: typeof ${name} === "undefined" ? undefined : ${name}`).join(",");
7686
+ const script = new vm.Script(`
7687
+ (() => {
7688
+ let exports = {};
7689
+ let module = { exports };
7690
+ ${jsCode}
7691
+ return { exported: module.exports, declared: { ${captured} } };
7692
+ })()
7693
+ `);
7694
+ const result = script.runInContext(context, { timeout: timeoutMs });
7695
+ const choices = /* @__PURE__ */ new Map();
7696
+ for (const [name, value] of Object.entries(result.declared)) {
7697
+ if (value instanceof zod.ZodType && ![...choices.values()].includes(value)) choices.set(name, value);
7698
+ }
7699
+ for (const [name, value] of Object.entries(result.exported || {})) {
7700
+ if (value instanceof zod.ZodType && ![...choices.values()].includes(value)) choices.set(name, value);
7701
+ }
7702
+ const defaultExport = result.exported instanceof zod.ZodType ? result.exported : (_a = result.exported) == null ? void 0 : _a.default;
7703
+ if (defaultExport instanceof zod.ZodType && ![...choices.values()].includes(defaultExport)) choices.set("default", defaultExport);
7704
+ if (!choices.size) throw new Error("Define a Zod schema, such as const UserSchema = z.object({ name: z.string() }).");
7705
+ const selectedSchema = body.selectedSchema && choices.has(body.selectedSchema) ? body.selectedSchema : choices.keys().next().value;
7706
+ const schema = choices.get(selectedSchema);
7707
+ const schemaNames = [...choices.keys()];
7708
+ let example;
7709
+ let exampleError;
7710
+ let inputData = body.inputData;
7711
+ if (body.action === "example") {
7712
+ try {
7713
+ const fixture = result.declared.exampleInput;
7714
+ const generated = fixture !== void 0 ? fixture : createExample(schema);
7715
+ const exampleResult = schema.safeParse(generated);
7716
+ if (!exampleResult.success) throw new Error("The example does not satisfy this schema. Add or update a valid const exampleInput for custom rules.");
7717
+ example = displayValue(generated);
7718
+ inputData = example;
7719
+ } catch (error) {
7720
+ exampleError = errorMessage(error);
7721
+ }
7722
+ }
7723
+ let validation = { status: "empty" };
7724
+ if (typeof inputData !== "string" || !inputData.trim()) {
7725
+ validation = { status: "empty", message: "Add JSON data to try this schema." };
7726
+ } else {
7727
+ let input;
7728
+ let inputValid = false;
7729
+ try {
7730
+ input = JSON.parse(inputData);
7731
+ inputValid = true;
7732
+ } catch (error) {
7733
+ validation = { status: "json-error", message: errorMessage(error) };
7734
+ }
7735
+ if (inputValid) {
7736
+ try {
7737
+ const parsed = schema.safeParse(input);
7738
+ validation = parsed.success ? { status: "valid", parsed: displayValue(parsed.data) } : { status: "invalid", issues: parsed.error.issues.map((issue) => ({ path: issue.path.length ? issue.path.join(".") : "(root)", message: issue.message, code: issue.code })) };
7739
+ } catch (error) {
7740
+ validation = { status: "parse-error", message: `Validation could not run: ${errorMessage(error)}` };
7741
+ }
7742
+ }
7743
+ }
7744
+ let conversion;
7745
+ try {
7746
+ const extracted = extractMongooseDef(schema);
7747
+ const converted = toMongooseSchema(schema, { modelName: "ParsedSchema" });
7748
+ const inspect = (value) => util.inspect(formatMongoose(value), { depth: null, colors: false, showHidden: false });
7749
+ conversion = {
7750
+ definition: inspect(extracted),
7751
+ schemaObj: inspect(converted.obj),
7752
+ schemaTree: inspect(converted.tree),
7753
+ schemaPaths: inspect(converted.paths)
7754
+ };
7755
+ } catch (error) {
7756
+ conversion = { error: errorMessage(error) };
7757
+ }
7758
+ return { schemaNames, selectedSchema, validation, conversion, example, exampleError };
7759
+ } finally {
7760
+ hooks.removeAllHooks();
7761
+ }
7762
+ }
7763
+
7764
+ const collections = {
7765
+ };
7766
+
7767
+ const DEFAULT_ENDPOINT = "https://api.iconify.design";
7768
+ const _rFljpJ = defineCachedEventHandler(async (event) => {
7769
+ const url = getRequestURL(event);
7770
+ if (!url)
7771
+ return createError$1({ status: 400, message: "Invalid icon request" });
7772
+ const options = useAppConfig().icon;
7773
+ const collectionName = event.context.params?.collection?.replace(/\.json$/, "");
7774
+ const collection = collectionName ? await collections[collectionName]?.() : null;
7775
+ const apiEndPoint = options.iconifyApiEndpoint || DEFAULT_ENDPOINT;
7776
+ const icons = url.searchParams.get("icons")?.split(",");
7777
+ if (collection) {
7778
+ if (icons?.length) {
7779
+ const data = getIcons(
7780
+ collection,
7781
+ icons
7782
+ );
7783
+ consola.debug(`[Icon] serving ${(icons || []).map((i) => "`" + collectionName + ":" + i + "`").join(",")} from bundled collection`);
7784
+ return data;
7785
+ }
7786
+ }
7787
+ if (options.fallbackToApi === true || options.fallbackToApi === "server-only") {
7788
+ const apiUrl = new URL("./" + basename(url.pathname) + url.search, apiEndPoint);
7789
+ consola.debug(`[Icon] fetching ${(icons || []).map((i) => "`" + collectionName + ":" + i + "`").join(",")} from iconify api`);
7790
+ if (apiUrl.host !== new URL(apiEndPoint).host) {
7791
+ return createError$1({ status: 400, message: "Invalid icon request" });
7792
+ }
7793
+ try {
7794
+ const data = await $fetch(apiUrl.href);
7795
+ return data;
7796
+ } catch (e) {
7797
+ consola.error(e);
7798
+ if (e.status === 404)
7799
+ return createError$1({ status: 404 });
7800
+ else
7801
+ return createError$1({ status: 500, message: "Failed to fetch fallback icon" });
7802
+ }
7803
+ }
6288
7804
  return createError$1({ status: 404 });
6289
7805
  }, {
6290
7806
  group: "nuxt",
@@ -6299,24 +7815,28 @@ const _80_oNC = defineCachedEventHandler(async (event) => {
6299
7815
  // 1 week
6300
7816
  });
6301
7817
 
7818
+ const _lazy_eqV2hV = () => import('../routes/api/editor-types.get.mjs');
6302
7819
  const _lazy_ops91K = () => import('../routes/api/parse.post.mjs');
6303
7820
  const _lazy__MlMs_ = () => import('../routes/api/resolve.get.mjs');
6304
- const _lazy_lg5hYT = () => import('../routes/renderer.mjs').then(function (n) { return n.r; });
7821
+ const _lazy_XgkH_R = () => import('../routes/api/studio/run.post.mjs');
7822
+ const _lazy_k3cCUd = () => import('../routes/renderer.mjs').then(function (n) { return n.r; });
6305
7823
 
6306
7824
  const handlers = [
6307
- { route: '', handler: _yyTQcL, lazy: false, middleware: true, method: undefined },
7825
+ { route: '', handler: _jvAnmE, lazy: false, middleware: true, method: undefined },
6308
7826
  { route: '', handler: _c_y9US, lazy: false, middleware: true, method: undefined },
7827
+ { route: '/api/editor-types', handler: _lazy_eqV2hV, lazy: true, middleware: false, method: "get" },
6309
7828
  { route: '/api/parse', handler: _lazy_ops91K, lazy: true, middleware: false, method: "post" },
6310
7829
  { route: '/api/resolve', handler: _lazy__MlMs_, lazy: true, middleware: false, method: "get" },
6311
- { route: '/__nuxt_error', handler: _lazy_lg5hYT, lazy: true, middleware: false, method: undefined },
7830
+ { route: '/api/studio/run', handler: _lazy_XgkH_R, lazy: true, middleware: false, method: "post" },
7831
+ { route: '/__nuxt_error', handler: _lazy_k3cCUd, lazy: true, middleware: false, method: undefined },
6312
7832
  { route: '/__nuxt_island/**', handler: _SxA8c9, lazy: false, middleware: false, method: undefined },
6313
- { route: '/api/_nuxt_icon/:collection', handler: _80_oNC, lazy: false, middleware: false, method: undefined },
6314
- { route: '/**', handler: _lazy_lg5hYT, lazy: true, middleware: false, method: undefined }
7833
+ { route: '/api/_nuxt_icon/:collection', handler: _rFljpJ, lazy: false, middleware: false, method: undefined },
7834
+ { route: '/**', handler: _lazy_k3cCUd, lazy: true, middleware: false, method: undefined }
6315
7835
  ];
6316
7836
 
6317
7837
  function createNitroApp() {
6318
7838
  const config = useRuntimeConfig();
6319
- const hooks = createHooks();
7839
+ const hooks = createHooks$1();
6320
7840
  const captureError = (error, context = {}) => {
6321
7841
  const promise = hooks.callHookParallel("error", error, context).catch((error_) => {
6322
7842
  console.error("Error while capturing another error", error_);
@@ -6455,59 +7975,6 @@ function useNitroApp() {
6455
7975
  }
6456
7976
  runNitroPlugins(nitroApp$1);
6457
7977
 
6458
- const NullObject = /* @__PURE__ */ (() => {
6459
- const C = function() {
6460
- };
6461
- C.prototype = /* @__PURE__ */ Object.create(null);
6462
- return C;
6463
- })();
6464
- function parse(str, options) {
6465
- if (typeof str !== "string") {
6466
- throw new TypeError("argument str must be a string");
6467
- }
6468
- const obj = new NullObject();
6469
- const opt = options || {};
6470
- const dec = opt.decode || decode;
6471
- let index = 0;
6472
- while (index < str.length) {
6473
- const eqIdx = str.indexOf("=", index);
6474
- if (eqIdx === -1) {
6475
- break;
6476
- }
6477
- let endIdx = str.indexOf(";", index);
6478
- if (endIdx === -1) {
6479
- endIdx = str.length;
6480
- } else if (endIdx < eqIdx) {
6481
- index = str.lastIndexOf(";", eqIdx - 1) + 1;
6482
- continue;
6483
- }
6484
- const key = str.slice(index, eqIdx).trim();
6485
- if (opt?.filter && !opt?.filter(key)) {
6486
- index = endIdx + 1;
6487
- continue;
6488
- }
6489
- if (void 0 === obj[key]) {
6490
- let val = str.slice(eqIdx + 1, endIdx).trim();
6491
- if (val.codePointAt(0) === 34) {
6492
- val = val.slice(1, -1);
6493
- }
6494
- obj[key] = tryDecode(val, dec);
6495
- }
6496
- index = endIdx + 1;
6497
- }
6498
- return obj;
6499
- }
6500
- function decode(str) {
6501
- return str.includes("%") ? decodeURIComponent(str) : str;
6502
- }
6503
- function tryDecode(str, decode2) {
6504
- try {
6505
- return decode2(str);
6506
- } catch {
6507
- return str;
6508
- }
6509
- }
6510
-
6511
7978
  const debug = (...args) => {
6512
7979
  };
6513
7980
  function GracefulShutdown(server, opts) {
@@ -6780,5 +8247,5 @@ trapUnhandledNodeErrors();
6780
8247
  setupGracefulShutdown(listener, nitroApp);
6781
8248
  const nodeServer = {};
6782
8249
 
6783
- export { $fetch$1 as $, withoutTrailingSlash as A, sanitizeStatusCode as B, baseURL as C, executeAsync as D, parse as E, getRequestHeader as F, isEqual as G, setCookie as H, getCookie as I, deleteCookie as J, nodeServer as K, getResponseStatusText as a, buildAssetsURL as b, createError$1 as c, defineEventHandler as d, getResponseStatus as e, defineRenderHandler as f, getQuery as g, destr as h, getRouteRules as i, joinURL as j, useNitroApp as k, klona as l, defu as m, parseQuery as n, defuFn as o, publicAssetsURL as p, hasProtocol as q, readBody as r, parseURL as s, encodePath as t, useRuntimeConfig as u, decodePath as v, getContext as w, withQuery as x, isScriptProtocol as y, withTrailingSlash as z };
8250
+ export { $fetch$1 as $, StudioExecutionError as S, runInContainer as a, buildAssetsURL as b, createError$1 as c, defineEventHandler as d, executeStudio as e, getResponseStatusText as f, getQuery as g, getResponseStatus as h, defineRenderHandler as i, destr as j, getRouteRules as k, joinURL as l, useNitroApp as m, getContext as n, sanitizeStatusCode as o, publicAssetsURL as p, baseURL as q, readStudioRequest as r, setHeader as s, klona as t, useRuntimeConfig as u, executeAsync as v, defu as w, nodeServer as x };
6784
8251
  //# sourceMappingURL=nitro.mjs.map