sunpeak 0.20.11 → 0.20.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin/commands/dev.mjs +3 -3
- package/bin/sunpeak.js +13 -8
- package/dist/chatgpt/index.cjs +1 -1
- package/dist/chatgpt/index.js +2 -2
- package/dist/claude/index.cjs +1 -1
- package/dist/claude/index.js +1 -1
- package/dist/host/chatgpt/index.cjs +1 -1
- package/dist/host/chatgpt/index.js +1 -1
- package/dist/index.cjs +5 -5
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +5 -5
- package/dist/index.js.map +1 -1
- package/dist/inspector/index.cjs +1 -1
- package/dist/inspector/index.js +2 -2
- package/dist/{inspector-JirXykqh.js → inspector-BVYIkjfw.js} +110 -16
- package/dist/inspector-BVYIkjfw.js.map +1 -0
- package/dist/{inspector-CjEFyXqc.cjs → inspector-mL_Ysqj6.cjs} +110 -16
- package/dist/inspector-mL_Ysqj6.cjs.map +1 -0
- package/dist/mcp/index.cjs +13 -13
- package/dist/mcp/index.cjs.map +1 -1
- package/dist/mcp/index.js +13 -13
- package/dist/mcp/index.js.map +1 -1
- package/dist/{protocol-VbxlTDik.js → protocol-C58brCtf.js} +51 -51
- package/dist/protocol-C58brCtf.js.map +1 -0
- package/dist/{protocol-WZSAhsV8.cjs → protocol-CFifOG2U.cjs} +51 -51
- package/dist/protocol-CFifOG2U.cjs.map +1 -0
- package/dist/{use-app-BEelk4Pj.cjs → use-app-BXVq24n8.cjs} +5 -5
- package/dist/{use-app-BEelk4Pj.cjs.map → use-app-BXVq24n8.cjs.map} +1 -1
- package/dist/{use-app-imsRg_Sq.js → use-app-L0OZBROc.js} +5 -5
- package/dist/{use-app-imsRg_Sq.js.map → use-app-L0OZBROc.js.map} +1 -1
- package/dist/{v4-81B3d_AO.cjs → v4-BtFbnniV.cjs} +1133 -403
- package/dist/v4-BtFbnniV.cjs.map +1 -0
- package/dist/{v4-zo4hA9Qs.js → v4-DfWETn4d.js} +1133 -403
- package/dist/v4-DfWETn4d.js.map +1 -0
- package/package.json +12 -12
- package/template/dist/albums/albums.html +42 -17
- package/template/dist/albums/albums.json +1 -1
- package/template/dist/carousel/carousel.html +42 -17
- package/template/dist/carousel/carousel.json +1 -1
- package/template/dist/map/map.html +337 -296
- package/template/dist/map/map.json +1 -1
- package/template/dist/review/review.html +42 -17
- package/template/dist/review/review.json +1 -1
- package/template/node_modules/.vite/deps/_metadata.json +3 -3
- package/template/node_modules/.vite-mcp/deps/@modelcontextprotocol_ext-apps.js +4 -4
- package/template/node_modules/.vite-mcp/deps/@modelcontextprotocol_ext-apps.js.map +1 -1
- package/template/node_modules/.vite-mcp/deps/@modelcontextprotocol_ext-apps_app-bridge.js +3 -3
- package/template/node_modules/.vite-mcp/deps/@modelcontextprotocol_ext-apps_app-bridge.js.map +1 -1
- package/template/node_modules/.vite-mcp/deps/@modelcontextprotocol_ext-apps_react.js +4 -4
- package/template/node_modules/.vite-mcp/deps/@modelcontextprotocol_ext-apps_react.js.map +1 -1
- package/template/node_modules/.vite-mcp/deps/_metadata.json +30 -30
- package/template/node_modules/.vite-mcp/deps/{external-B0TEY49X.js → external-BzlnL8_g.js} +1132 -403
- package/template/node_modules/.vite-mcp/deps/external-BzlnL8_g.js.map +1 -0
- package/template/node_modules/.vite-mcp/deps/mapbox-gl.js +9470 -9295
- package/template/node_modules/.vite-mcp/deps/mapbox-gl.js.map +1 -1
- package/template/node_modules/.vite-mcp/deps/{protocol-C6_cc6NO.js → protocol-Depaaj0Z.js} +6 -6
- package/template/node_modules/.vite-mcp/deps/{protocol-C6_cc6NO.js.map → protocol-Depaaj0Z.js.map} +1 -1
- package/template/node_modules/.vite-mcp/deps/{v4-Dqc4MOHZ.js → v4-3k5wOzJw.js} +4 -3
- package/template/node_modules/.vite-mcp/deps/v4-3k5wOzJw.js.map +1 -0
- package/template/node_modules/.vite-mcp/deps/zod.js +3 -3
- package/template/node_modules/.vite-mcp/deps/zod.js.map +1 -1
- package/template/package.json +2 -2
- package/dist/inspector-CjEFyXqc.cjs.map +0 -1
- package/dist/inspector-JirXykqh.js.map +0 -1
- package/dist/protocol-VbxlTDik.js.map +0 -1
- package/dist/protocol-WZSAhsV8.cjs.map +0 -1
- package/dist/v4-81B3d_AO.cjs.map +0 -1
- package/dist/v4-zo4hA9Qs.js.map +0 -1
- package/template/node_modules/.vite-mcp/deps/external-B0TEY49X.js.map +0 -1
- package/template/node_modules/.vite-mcp/deps/v4-Dqc4MOHZ.js.map +0 -1
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
const require_chunk = require("./chunk-CoPdw6nB.cjs");
|
|
2
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
2
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/core/core.js
|
|
3
|
+
var _a$1;
|
|
3
4
|
/** A special constant with type `never` */
|
|
4
|
-
var NEVER = Object.freeze({ status: "aborted" });
|
|
5
|
+
var NEVER = /* @__PURE__ */ Object.freeze({ status: "aborted" });
|
|
5
6
|
function $constructor(name, initializer, params) {
|
|
6
7
|
function init(inst, def) {
|
|
7
8
|
if (!inst._zod) Object.defineProperty(inst, "_zod", {
|
|
@@ -53,13 +54,14 @@ var $ZodEncodeError = class extends Error {
|
|
|
53
54
|
this.name = "ZodEncodeError";
|
|
54
55
|
}
|
|
55
56
|
};
|
|
56
|
-
|
|
57
|
+
(_a$1 = globalThis).__zod_globalConfig ?? (_a$1.__zod_globalConfig = {});
|
|
58
|
+
var globalConfig = globalThis.__zod_globalConfig;
|
|
57
59
|
function config(newConfig) {
|
|
58
60
|
if (newConfig) Object.assign(globalConfig, newConfig);
|
|
59
61
|
return globalConfig;
|
|
60
62
|
}
|
|
61
63
|
//#endregion
|
|
62
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
64
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/core/util.js
|
|
63
65
|
var util_exports = /* @__PURE__ */ require_chunk.__exportAll({
|
|
64
66
|
BIGINT_FORMAT_RANGES: () => BIGINT_FORMAT_RANGES,
|
|
65
67
|
Class: () => Class,
|
|
@@ -84,6 +86,7 @@ var util_exports = /* @__PURE__ */ require_chunk.__exportAll({
|
|
|
84
86
|
defineLazy: () => defineLazy,
|
|
85
87
|
esc: () => esc,
|
|
86
88
|
escapeRegex: () => escapeRegex,
|
|
89
|
+
explicitlyAborted: () => explicitlyAborted,
|
|
87
90
|
extend: () => extend,
|
|
88
91
|
finalizeIssue: () => finalizeIssue,
|
|
89
92
|
floatSafeRemainder: () => floatSafeRemainder,
|
|
@@ -165,17 +168,13 @@ function cleanRegex(source) {
|
|
|
165
168
|
return source.slice(start, end);
|
|
166
169
|
}
|
|
167
170
|
function floatSafeRemainder(val, step) {
|
|
168
|
-
const
|
|
169
|
-
const
|
|
170
|
-
|
|
171
|
-
if (
|
|
172
|
-
|
|
173
|
-
if (match?.[1]) stepDecCount = Number.parseInt(match[1]);
|
|
174
|
-
}
|
|
175
|
-
const decCount = valDecCount > stepDecCount ? valDecCount : stepDecCount;
|
|
176
|
-
return Number.parseInt(val.toFixed(decCount).replace(".", "")) % Number.parseInt(step.toFixed(decCount).replace(".", "")) / 10 ** decCount;
|
|
171
|
+
const ratio = val / step;
|
|
172
|
+
const roundedRatio = Math.round(ratio);
|
|
173
|
+
const tolerance = Number.EPSILON * Math.max(Math.abs(ratio), 1);
|
|
174
|
+
if (Math.abs(ratio - roundedRatio) < tolerance) return 0;
|
|
175
|
+
return ratio - roundedRatio;
|
|
177
176
|
}
|
|
178
|
-
var EVALUATING = Symbol("evaluating");
|
|
177
|
+
var EVALUATING = /* @__PURE__ */ Symbol("evaluating");
|
|
179
178
|
function defineLazy(object, key, getter) {
|
|
180
179
|
let value = void 0;
|
|
181
180
|
Object.defineProperty(object, key, {
|
|
@@ -241,7 +240,8 @@ var captureStackTrace = "captureStackTrace" in Error ? Error.captureStackTrace :
|
|
|
241
240
|
function isObject(data) {
|
|
242
241
|
return typeof data === "object" && data !== null && !Array.isArray(data);
|
|
243
242
|
}
|
|
244
|
-
var allowsEval = cached(() => {
|
|
243
|
+
var allowsEval = /* @__PURE__ */ cached(() => {
|
|
244
|
+
if (globalConfig.jitless) return false;
|
|
245
245
|
if (typeof navigator !== "undefined" && navigator?.userAgent?.includes("Cloudflare")) return false;
|
|
246
246
|
try {
|
|
247
247
|
new Function("");
|
|
@@ -263,6 +263,8 @@ function isPlainObject(o) {
|
|
|
263
263
|
function shallowClone(o) {
|
|
264
264
|
if (isPlainObject(o)) return { ...o };
|
|
265
265
|
if (Array.isArray(o)) return [...o];
|
|
266
|
+
if (o instanceof Map) return new Map(o);
|
|
267
|
+
if (o instanceof Set) return new Set(o);
|
|
266
268
|
return o;
|
|
267
269
|
}
|
|
268
270
|
function numKeys(data) {
|
|
@@ -292,12 +294,12 @@ var getParsedType = (data) => {
|
|
|
292
294
|
default: throw new Error(`Unknown data type: ${t}`);
|
|
293
295
|
}
|
|
294
296
|
};
|
|
295
|
-
var propertyKeyTypes = new Set([
|
|
297
|
+
var propertyKeyTypes = /* @__PURE__ */ new Set([
|
|
296
298
|
"string",
|
|
297
299
|
"number",
|
|
298
300
|
"symbol"
|
|
299
301
|
]);
|
|
300
|
-
var primitiveTypes = new Set([
|
|
302
|
+
var primitiveTypes = /* @__PURE__ */ new Set([
|
|
301
303
|
"string",
|
|
302
304
|
"number",
|
|
303
305
|
"bigint",
|
|
@@ -446,6 +448,7 @@ function safeExtend(schema, shape) {
|
|
|
446
448
|
} }));
|
|
447
449
|
}
|
|
448
450
|
function merge(a, b) {
|
|
451
|
+
if (a._zod.def.checks?.length) throw new Error(".merge() cannot be used on object schemas containing refinements. Use .safeExtend() instead.");
|
|
449
452
|
return clone(a, mergeDefs(a._zod.def, {
|
|
450
453
|
get shape() {
|
|
451
454
|
const _shape = {
|
|
@@ -458,7 +461,7 @@ function merge(a, b) {
|
|
|
458
461
|
get catchall() {
|
|
459
462
|
return b._zod.def.catchall;
|
|
460
463
|
},
|
|
461
|
-
checks: []
|
|
464
|
+
checks: b._zod.def.checks ?? []
|
|
462
465
|
}));
|
|
463
466
|
}
|
|
464
467
|
function partial(Class, schema, mask) {
|
|
@@ -511,6 +514,11 @@ function aborted(x, startIndex = 0) {
|
|
|
511
514
|
for (let i = startIndex; i < x.issues.length; i++) if (x.issues[i]?.continue !== true) return true;
|
|
512
515
|
return false;
|
|
513
516
|
}
|
|
517
|
+
function explicitlyAborted(x, startIndex = 0) {
|
|
518
|
+
if (x.aborted === true) return true;
|
|
519
|
+
for (let i = startIndex; i < x.issues.length; i++) if (x.issues[i]?.continue === false) return true;
|
|
520
|
+
return false;
|
|
521
|
+
}
|
|
514
522
|
function prefixIssues(path, issues) {
|
|
515
523
|
return issues.map((iss) => {
|
|
516
524
|
var _a;
|
|
@@ -523,15 +531,12 @@ function unwrapMessage(message) {
|
|
|
523
531
|
return typeof message === "string" ? message : message?.message;
|
|
524
532
|
}
|
|
525
533
|
function finalizeIssue(iss, ctx, config) {
|
|
526
|
-
const
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
if (
|
|
531
|
-
|
|
532
|
-
delete full.continue;
|
|
533
|
-
if (!ctx?.reportInput) delete full.input;
|
|
534
|
-
return full;
|
|
534
|
+
const message = iss.message ? iss.message : unwrapMessage(iss.inst?._zod.def?.error?.(iss)) ?? unwrapMessage(ctx?.error?.(iss)) ?? unwrapMessage(config.customError?.(iss)) ?? unwrapMessage(config.localeError?.(iss)) ?? "Invalid input";
|
|
535
|
+
const { inst: _inst, continue: _continue, input: _input, ...rest } = iss;
|
|
536
|
+
rest.path ?? (rest.path = []);
|
|
537
|
+
rest.message = message;
|
|
538
|
+
if (ctx?.reportInput) rest.input = _input;
|
|
539
|
+
return rest;
|
|
535
540
|
}
|
|
536
541
|
function getSizableOrigin(input) {
|
|
537
542
|
if (input instanceof Set) return "set";
|
|
@@ -604,7 +609,7 @@ var Class = class {
|
|
|
604
609
|
constructor(..._args) {}
|
|
605
610
|
};
|
|
606
611
|
//#endregion
|
|
607
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
612
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/core/errors.js
|
|
608
613
|
var initializer$1 = (inst, def) => {
|
|
609
614
|
inst.name = "$ZodError";
|
|
610
615
|
Object.defineProperty(inst, "_zod", {
|
|
@@ -637,23 +642,26 @@ function flattenError(error, mapper = (issue) => issue.message) {
|
|
|
637
642
|
}
|
|
638
643
|
function formatError(error, mapper = (issue) => issue.message) {
|
|
639
644
|
const fieldErrors = { _errors: [] };
|
|
640
|
-
const processError = (error) => {
|
|
641
|
-
for (const issue of error.issues) if (issue.code === "invalid_union" && issue.errors.length) issue.errors.map((issues) => processError({ issues }));
|
|
642
|
-
else if (issue.code === "invalid_key") processError({ issues: issue.issues });
|
|
643
|
-
else if (issue.code === "invalid_element") processError({ issues: issue.issues });
|
|
644
|
-
else if (issue.path.length === 0) fieldErrors._errors.push(mapper(issue));
|
|
645
|
+
const processError = (error, path = []) => {
|
|
646
|
+
for (const issue of error.issues) if (issue.code === "invalid_union" && issue.errors.length) issue.errors.map((issues) => processError({ issues }, [...path, ...issue.path]));
|
|
647
|
+
else if (issue.code === "invalid_key") processError({ issues: issue.issues }, [...path, ...issue.path]);
|
|
648
|
+
else if (issue.code === "invalid_element") processError({ issues: issue.issues }, [...path, ...issue.path]);
|
|
645
649
|
else {
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
|
|
653
|
-
curr[el]
|
|
650
|
+
const fullpath = [...path, ...issue.path];
|
|
651
|
+
if (fullpath.length === 0) fieldErrors._errors.push(mapper(issue));
|
|
652
|
+
else {
|
|
653
|
+
let curr = fieldErrors;
|
|
654
|
+
let i = 0;
|
|
655
|
+
while (i < fullpath.length) {
|
|
656
|
+
const el = fullpath[i];
|
|
657
|
+
if (!(i === fullpath.length - 1)) curr[el] = curr[el] || { _errors: [] };
|
|
658
|
+
else {
|
|
659
|
+
curr[el] = curr[el] || { _errors: [] };
|
|
660
|
+
curr[el]._errors.push(mapper(issue));
|
|
661
|
+
}
|
|
662
|
+
curr = curr[el];
|
|
663
|
+
i++;
|
|
654
664
|
}
|
|
655
|
-
curr = curr[el];
|
|
656
|
-
i++;
|
|
657
665
|
}
|
|
658
666
|
}
|
|
659
667
|
};
|
|
@@ -664,9 +672,9 @@ function treeifyError(error, mapper = (issue) => issue.message) {
|
|
|
664
672
|
const result = { errors: [] };
|
|
665
673
|
const processError = (error, path = []) => {
|
|
666
674
|
var _a, _b;
|
|
667
|
-
for (const issue of error.issues) if (issue.code === "invalid_union" && issue.errors.length) issue.errors.map((issues) => processError({ issues }, issue.path));
|
|
668
|
-
else if (issue.code === "invalid_key") processError({ issues: issue.issues }, issue.path);
|
|
669
|
-
else if (issue.code === "invalid_element") processError({ issues: issue.issues }, issue.path);
|
|
675
|
+
for (const issue of error.issues) if (issue.code === "invalid_union" && issue.errors.length) issue.errors.map((issues) => processError({ issues }, [...path, ...issue.path]));
|
|
676
|
+
else if (issue.code === "invalid_key") processError({ issues: issue.issues }, [...path, ...issue.path]);
|
|
677
|
+
else if (issue.code === "invalid_element") processError({ issues: issue.issues }, [...path, ...issue.path]);
|
|
670
678
|
else {
|
|
671
679
|
const fullpath = [...path, ...issue.path];
|
|
672
680
|
if (fullpath.length === 0) {
|
|
@@ -749,9 +757,12 @@ function prettifyError(error) {
|
|
|
749
757
|
return lines.join("\n");
|
|
750
758
|
}
|
|
751
759
|
//#endregion
|
|
752
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
760
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/core/parse.js
|
|
753
761
|
var _parse = (_Err) => (schema, value, _ctx, _params) => {
|
|
754
|
-
const ctx = _ctx ?
|
|
762
|
+
const ctx = _ctx ? {
|
|
763
|
+
..._ctx,
|
|
764
|
+
async: false
|
|
765
|
+
} : { async: false };
|
|
755
766
|
const result = schema._zod.run({
|
|
756
767
|
value,
|
|
757
768
|
issues: []
|
|
@@ -766,7 +777,10 @@ var _parse = (_Err) => (schema, value, _ctx, _params) => {
|
|
|
766
777
|
};
|
|
767
778
|
var parse$1 = /* @__PURE__ */ _parse($ZodRealError);
|
|
768
779
|
var _parseAsync = (_Err) => async (schema, value, _ctx, params) => {
|
|
769
|
-
const ctx = _ctx ?
|
|
780
|
+
const ctx = _ctx ? {
|
|
781
|
+
..._ctx,
|
|
782
|
+
async: true
|
|
783
|
+
} : { async: true };
|
|
770
784
|
let result = schema._zod.run({
|
|
771
785
|
value,
|
|
772
786
|
issues: []
|
|
@@ -800,7 +814,10 @@ var _safeParse = (_Err) => (schema, value, _ctx) => {
|
|
|
800
814
|
};
|
|
801
815
|
var safeParse$1 = /* @__PURE__ */ _safeParse($ZodRealError);
|
|
802
816
|
var _safeParseAsync = (_Err) => async (schema, value, _ctx) => {
|
|
803
|
-
const ctx = _ctx ?
|
|
817
|
+
const ctx = _ctx ? {
|
|
818
|
+
..._ctx,
|
|
819
|
+
async: true
|
|
820
|
+
} : { async: true };
|
|
804
821
|
let result = schema._zod.run({
|
|
805
822
|
value,
|
|
806
823
|
issues: []
|
|
@@ -816,7 +833,10 @@ var _safeParseAsync = (_Err) => async (schema, value, _ctx) => {
|
|
|
816
833
|
};
|
|
817
834
|
var safeParseAsync$1 = /* @__PURE__ */ _safeParseAsync($ZodRealError);
|
|
818
835
|
var _encode = (_Err) => (schema, value, _ctx) => {
|
|
819
|
-
const ctx = _ctx ?
|
|
836
|
+
const ctx = _ctx ? {
|
|
837
|
+
..._ctx,
|
|
838
|
+
direction: "backward"
|
|
839
|
+
} : { direction: "backward" };
|
|
820
840
|
return _parse(_Err)(schema, value, ctx);
|
|
821
841
|
};
|
|
822
842
|
var encode$1 = /* @__PURE__ */ _encode($ZodRealError);
|
|
@@ -825,7 +845,10 @@ var _decode = (_Err) => (schema, value, _ctx) => {
|
|
|
825
845
|
};
|
|
826
846
|
var decode$1 = /* @__PURE__ */ _decode($ZodRealError);
|
|
827
847
|
var _encodeAsync = (_Err) => async (schema, value, _ctx) => {
|
|
828
|
-
const ctx = _ctx ?
|
|
848
|
+
const ctx = _ctx ? {
|
|
849
|
+
..._ctx,
|
|
850
|
+
direction: "backward"
|
|
851
|
+
} : { direction: "backward" };
|
|
829
852
|
return _parseAsync(_Err)(schema, value, ctx);
|
|
830
853
|
};
|
|
831
854
|
var encodeAsync$1 = /* @__PURE__ */ _encodeAsync($ZodRealError);
|
|
@@ -834,7 +857,10 @@ var _decodeAsync = (_Err) => async (schema, value, _ctx) => {
|
|
|
834
857
|
};
|
|
835
858
|
var decodeAsync$1 = /* @__PURE__ */ _decodeAsync($ZodRealError);
|
|
836
859
|
var _safeEncode = (_Err) => (schema, value, _ctx) => {
|
|
837
|
-
const ctx = _ctx ?
|
|
860
|
+
const ctx = _ctx ? {
|
|
861
|
+
..._ctx,
|
|
862
|
+
direction: "backward"
|
|
863
|
+
} : { direction: "backward" };
|
|
838
864
|
return _safeParse(_Err)(schema, value, ctx);
|
|
839
865
|
};
|
|
840
866
|
var safeEncode$1 = /* @__PURE__ */ _safeEncode($ZodRealError);
|
|
@@ -843,7 +869,10 @@ var _safeDecode = (_Err) => (schema, value, _ctx) => {
|
|
|
843
869
|
};
|
|
844
870
|
var safeDecode$1 = /* @__PURE__ */ _safeDecode($ZodRealError);
|
|
845
871
|
var _safeEncodeAsync = (_Err) => async (schema, value, _ctx) => {
|
|
846
|
-
const ctx = _ctx ?
|
|
872
|
+
const ctx = _ctx ? {
|
|
873
|
+
..._ctx,
|
|
874
|
+
direction: "backward"
|
|
875
|
+
} : { direction: "backward" };
|
|
847
876
|
return _safeParseAsync(_Err)(schema, value, ctx);
|
|
848
877
|
};
|
|
849
878
|
var safeEncodeAsync$1 = /* @__PURE__ */ _safeEncodeAsync($ZodRealError);
|
|
@@ -852,7 +881,7 @@ var _safeDecodeAsync = (_Err) => async (schema, value, _ctx) => {
|
|
|
852
881
|
};
|
|
853
882
|
var safeDecodeAsync$1 = /* @__PURE__ */ _safeDecodeAsync($ZodRealError);
|
|
854
883
|
//#endregion
|
|
855
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
884
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/core/regexes.js
|
|
856
885
|
var regexes_exports = /* @__PURE__ */ require_chunk.__exportAll({
|
|
857
886
|
base64: () => base64$1,
|
|
858
887
|
base64url: () => base64url$1,
|
|
@@ -875,6 +904,7 @@ var regexes_exports = /* @__PURE__ */ require_chunk.__exportAll({
|
|
|
875
904
|
hex: () => hex$1,
|
|
876
905
|
hostname: () => hostname$1,
|
|
877
906
|
html5Email: () => html5Email,
|
|
907
|
+
httpProtocol: () => httpProtocol,
|
|
878
908
|
idnEmail: () => idnEmail,
|
|
879
909
|
integer: () => integer,
|
|
880
910
|
ipv4: () => ipv4$1,
|
|
@@ -913,7 +943,12 @@ var regexes_exports = /* @__PURE__ */ require_chunk.__exportAll({
|
|
|
913
943
|
uuid7: () => uuid7,
|
|
914
944
|
xid: () => xid$1
|
|
915
945
|
});
|
|
916
|
-
|
|
946
|
+
/**
|
|
947
|
+
* @deprecated CUID v1 is deprecated by its authors due to information leakage
|
|
948
|
+
* (timestamps embedded in the id). Use {@link cuid2} instead.
|
|
949
|
+
* See https://github.com/paralleldrive/cuid.
|
|
950
|
+
*/
|
|
951
|
+
var cuid$1 = /^[cC][0-9a-z]{6,}$/;
|
|
917
952
|
var cuid2$1 = /^[0-9a-z]+$/;
|
|
918
953
|
var ulid$1 = /^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$/;
|
|
919
954
|
var xid$1 = /^[0-9a-vA-V]{20}$/;
|
|
@@ -961,6 +996,7 @@ var base64$1 = /^$|^(?:[0-9a-zA-Z+/]{4})*(?:(?:[0-9a-zA-Z+/]{2}==)|(?:[0-9a-zA-Z
|
|
|
961
996
|
var base64url$1 = /^[A-Za-z0-9_-]*$/;
|
|
962
997
|
var hostname$1 = /^(?=.{1,253}\.?$)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[-0-9a-zA-Z]{0,61}[0-9a-zA-Z])?)*\.?$/;
|
|
963
998
|
var domain = /^([a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?\.)+[a-zA-Z]{2,}$/;
|
|
999
|
+
var httpProtocol = /^https?$/;
|
|
964
1000
|
var e164$1 = /^\+[1-9]\d{6,14}$/;
|
|
965
1001
|
var dateSource = `(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))`;
|
|
966
1002
|
var date$3 = /* @__PURE__ */ new RegExp(`^${dateSource}$`);
|
|
@@ -1014,7 +1050,7 @@ var sha512_hex = /^[0-9a-fA-F]{128}$/;
|
|
|
1014
1050
|
var sha512_base64 = /* @__PURE__ */ fixedBase64(86, "==");
|
|
1015
1051
|
var sha512_base64url = /* @__PURE__ */ fixedBase64url(86);
|
|
1016
1052
|
//#endregion
|
|
1017
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
1053
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/core/checks.js
|
|
1018
1054
|
var $ZodCheck = /* @__PURE__ */ $constructor("$ZodCheck", (inst, def) => {
|
|
1019
1055
|
var _a;
|
|
1020
1056
|
inst._zod ?? (inst._zod = {});
|
|
@@ -1519,7 +1555,7 @@ var $ZodCheckOverwrite = /* @__PURE__ */ $constructor("$ZodCheckOverwrite", (ins
|
|
|
1519
1555
|
};
|
|
1520
1556
|
});
|
|
1521
1557
|
//#endregion
|
|
1522
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
1558
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/core/doc.js
|
|
1523
1559
|
var Doc = class {
|
|
1524
1560
|
constructor(args = []) {
|
|
1525
1561
|
this.content = [];
|
|
@@ -1550,14 +1586,14 @@ var Doc = class {
|
|
|
1550
1586
|
}
|
|
1551
1587
|
};
|
|
1552
1588
|
//#endregion
|
|
1553
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
1589
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/core/versions.js
|
|
1554
1590
|
var version = {
|
|
1555
1591
|
major: 4,
|
|
1556
|
-
minor:
|
|
1557
|
-
patch:
|
|
1592
|
+
minor: 4,
|
|
1593
|
+
patch: 1
|
|
1558
1594
|
};
|
|
1559
1595
|
//#endregion
|
|
1560
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
1596
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/core/schemas.js
|
|
1561
1597
|
var $ZodType = /* @__PURE__ */ $constructor("$ZodType", (inst, def) => {
|
|
1562
1598
|
var _a;
|
|
1563
1599
|
inst ?? (inst = {});
|
|
@@ -1578,6 +1614,7 @@ var $ZodType = /* @__PURE__ */ $constructor("$ZodType", (inst, def) => {
|
|
|
1578
1614
|
let asyncResult;
|
|
1579
1615
|
for (const ch of checks) {
|
|
1580
1616
|
if (ch._zod.def.when) {
|
|
1617
|
+
if (explicitlyAborted(payload)) continue;
|
|
1581
1618
|
if (!ch._zod.def.when(payload)) continue;
|
|
1582
1619
|
} else if (isAborted) continue;
|
|
1583
1620
|
const currLen = payload.issues.length;
|
|
@@ -1697,6 +1734,19 @@ var $ZodURL = /* @__PURE__ */ $constructor("$ZodURL", (inst, def) => {
|
|
|
1697
1734
|
inst._zod.check = (payload) => {
|
|
1698
1735
|
try {
|
|
1699
1736
|
const trimmed = payload.value.trim();
|
|
1737
|
+
if (!def.normalize && def.protocol?.source === httpProtocol.source) {
|
|
1738
|
+
if (!/^https?:\/\//i.test(trimmed)) {
|
|
1739
|
+
payload.issues.push({
|
|
1740
|
+
code: "invalid_format",
|
|
1741
|
+
format: "url",
|
|
1742
|
+
note: "Invalid URL format",
|
|
1743
|
+
input: payload.value,
|
|
1744
|
+
inst,
|
|
1745
|
+
continue: !def.abort
|
|
1746
|
+
});
|
|
1747
|
+
return;
|
|
1748
|
+
}
|
|
1749
|
+
}
|
|
1700
1750
|
const url = new URL(trimmed);
|
|
1701
1751
|
if (def.hostname) {
|
|
1702
1752
|
def.hostname.lastIndex = 0;
|
|
@@ -1744,6 +1794,11 @@ var $ZodNanoID = /* @__PURE__ */ $constructor("$ZodNanoID", (inst, def) => {
|
|
|
1744
1794
|
def.pattern ?? (def.pattern = nanoid$1);
|
|
1745
1795
|
$ZodStringFormat.init(inst, def);
|
|
1746
1796
|
});
|
|
1797
|
+
/**
|
|
1798
|
+
* @deprecated CUID v1 is deprecated by its authors due to information leakage
|
|
1799
|
+
* (timestamps embedded in the id). Use {@link $ZodCUID2} instead.
|
|
1800
|
+
* See https://github.com/paralleldrive/cuid.
|
|
1801
|
+
*/
|
|
1747
1802
|
var $ZodCUID = /* @__PURE__ */ $constructor("$ZodCUID", (inst, def) => {
|
|
1748
1803
|
def.pattern ?? (def.pattern = cuid$1);
|
|
1749
1804
|
$ZodStringFormat.init(inst, def);
|
|
@@ -1838,6 +1893,7 @@ var $ZodCIDRv6 = /* @__PURE__ */ $constructor("$ZodCIDRv6", (inst, def) => {
|
|
|
1838
1893
|
});
|
|
1839
1894
|
function isValidBase64(data) {
|
|
1840
1895
|
if (data === "") return true;
|
|
1896
|
+
if (/\s/.test(data)) return false;
|
|
1841
1897
|
if (data.length % 4 !== 0) return false;
|
|
1842
1898
|
try {
|
|
1843
1899
|
atob(data);
|
|
@@ -2007,8 +2063,6 @@ var $ZodUndefined = /* @__PURE__ */ $constructor("$ZodUndefined", (inst, def) =>
|
|
|
2007
2063
|
$ZodType.init(inst, def);
|
|
2008
2064
|
inst._zod.pattern = _undefined$2;
|
|
2009
2065
|
inst._zod.values = new Set([void 0]);
|
|
2010
|
-
inst._zod.optin = "optional";
|
|
2011
|
-
inst._zod.optout = "optional";
|
|
2012
2066
|
inst._zod.parse = (payload, _ctx) => {
|
|
2013
2067
|
const input = payload.value;
|
|
2014
2068
|
if (typeof input === "undefined") return payload;
|
|
@@ -2122,13 +2176,23 @@ var $ZodArray = /* @__PURE__ */ $constructor("$ZodArray", (inst, def) => {
|
|
|
2122
2176
|
return payload;
|
|
2123
2177
|
};
|
|
2124
2178
|
});
|
|
2125
|
-
function handlePropertyResult(result, final, key, input, isOptionalOut) {
|
|
2179
|
+
function handlePropertyResult(result, final, key, input, isOptionalIn, isOptionalOut) {
|
|
2180
|
+
const isPresent = key in input;
|
|
2126
2181
|
if (result.issues.length) {
|
|
2127
|
-
if (isOptionalOut && !
|
|
2182
|
+
if (isOptionalIn && isOptionalOut && !isPresent) return;
|
|
2128
2183
|
final.issues.push(...prefixIssues(key, result.issues));
|
|
2129
2184
|
}
|
|
2185
|
+
if (!isPresent && !isOptionalIn) {
|
|
2186
|
+
if (!result.issues.length) final.issues.push({
|
|
2187
|
+
code: "invalid_type",
|
|
2188
|
+
expected: "nonoptional",
|
|
2189
|
+
input: void 0,
|
|
2190
|
+
path: [key]
|
|
2191
|
+
});
|
|
2192
|
+
return;
|
|
2193
|
+
}
|
|
2130
2194
|
if (result.value === void 0) {
|
|
2131
|
-
if (
|
|
2195
|
+
if (isPresent) final.value[key] = void 0;
|
|
2132
2196
|
} else final.value[key] = result.value;
|
|
2133
2197
|
}
|
|
2134
2198
|
function normalizeDef(def) {
|
|
@@ -2148,8 +2212,10 @@ function handleCatchall(proms, input, payload, ctx, def, inst) {
|
|
|
2148
2212
|
const keySet = def.keySet;
|
|
2149
2213
|
const _catchall = def.catchall._zod;
|
|
2150
2214
|
const t = _catchall.def.type;
|
|
2215
|
+
const isOptionalIn = _catchall.optin === "optional";
|
|
2151
2216
|
const isOptionalOut = _catchall.optout === "optional";
|
|
2152
2217
|
for (const key in input) {
|
|
2218
|
+
if (key === "__proto__") continue;
|
|
2153
2219
|
if (keySet.has(key)) continue;
|
|
2154
2220
|
if (t === "never") {
|
|
2155
2221
|
unrecognized.push(key);
|
|
@@ -2159,8 +2225,8 @@ function handleCatchall(proms, input, payload, ctx, def, inst) {
|
|
|
2159
2225
|
value: input[key],
|
|
2160
2226
|
issues: []
|
|
2161
2227
|
}, ctx);
|
|
2162
|
-
if (r instanceof Promise) proms.push(r.then((r) => handlePropertyResult(r, payload, key, input, isOptionalOut)));
|
|
2163
|
-
else handlePropertyResult(r, payload, key, input, isOptionalOut);
|
|
2228
|
+
if (r instanceof Promise) proms.push(r.then((r) => handlePropertyResult(r, payload, key, input, isOptionalIn, isOptionalOut)));
|
|
2229
|
+
else handlePropertyResult(r, payload, key, input, isOptionalIn, isOptionalOut);
|
|
2164
2230
|
}
|
|
2165
2231
|
if (unrecognized.length) payload.issues.push({
|
|
2166
2232
|
code: "unrecognized_keys",
|
|
@@ -2196,13 +2262,13 @@ var $ZodObject = /* @__PURE__ */ $constructor("$ZodObject", (inst, def) => {
|
|
|
2196
2262
|
}
|
|
2197
2263
|
return propValues;
|
|
2198
2264
|
});
|
|
2199
|
-
const isObject$
|
|
2265
|
+
const isObject$1 = isObject;
|
|
2200
2266
|
const catchall = def.catchall;
|
|
2201
2267
|
let value;
|
|
2202
2268
|
inst._zod.parse = (payload, ctx) => {
|
|
2203
2269
|
value ?? (value = _normalized.value);
|
|
2204
2270
|
const input = payload.value;
|
|
2205
|
-
if (!isObject$
|
|
2271
|
+
if (!isObject$1(input)) {
|
|
2206
2272
|
payload.issues.push({
|
|
2207
2273
|
expected: "object",
|
|
2208
2274
|
code: "invalid_type",
|
|
@@ -2216,13 +2282,14 @@ var $ZodObject = /* @__PURE__ */ $constructor("$ZodObject", (inst, def) => {
|
|
|
2216
2282
|
const shape = value.shape;
|
|
2217
2283
|
for (const key of value.keys) {
|
|
2218
2284
|
const el = shape[key];
|
|
2285
|
+
const isOptionalIn = el._zod.optin === "optional";
|
|
2219
2286
|
const isOptionalOut = el._zod.optout === "optional";
|
|
2220
2287
|
const r = el._zod.run({
|
|
2221
2288
|
value: input[key],
|
|
2222
2289
|
issues: []
|
|
2223
2290
|
}, ctx);
|
|
2224
|
-
if (r instanceof Promise) proms.push(r.then((r) => handlePropertyResult(r, payload, key, input, isOptionalOut)));
|
|
2225
|
-
else handlePropertyResult(r, payload, key, input, isOptionalOut);
|
|
2291
|
+
if (r instanceof Promise) proms.push(r.then((r) => handlePropertyResult(r, payload, key, input, isOptionalIn, isOptionalOut)));
|
|
2292
|
+
else handlePropertyResult(r, payload, key, input, isOptionalIn, isOptionalOut);
|
|
2226
2293
|
}
|
|
2227
2294
|
if (!catchall) return proms.length ? Promise.all(proms).then(() => payload) : payload;
|
|
2228
2295
|
return handleCatchall(proms, input, payload, ctx, _normalized.value, inst);
|
|
@@ -2251,9 +2318,11 @@ var $ZodObjectJIT = /* @__PURE__ */ $constructor("$ZodObjectJIT", (inst, def) =>
|
|
|
2251
2318
|
for (const key of normalized.keys) {
|
|
2252
2319
|
const id = ids[key];
|
|
2253
2320
|
const k = esc(key);
|
|
2254
|
-
const
|
|
2321
|
+
const schema = shape[key];
|
|
2322
|
+
const isOptionalIn = schema?._zod?.optin === "optional";
|
|
2323
|
+
const isOptionalOut = schema?._zod?.optout === "optional";
|
|
2255
2324
|
doc.write(`const ${id} = ${parseStr(key)};`);
|
|
2256
|
-
if (isOptionalOut) doc.write(`
|
|
2325
|
+
if (isOptionalIn && isOptionalOut) doc.write(`
|
|
2257
2326
|
if (${id}.issues.length) {
|
|
2258
2327
|
if (${k} in input) {
|
|
2259
2328
|
payload.issues = payload.issues.concat(${id}.issues.map(iss => ({
|
|
@@ -2271,6 +2340,32 @@ var $ZodObjectJIT = /* @__PURE__ */ $constructor("$ZodObjectJIT", (inst, def) =>
|
|
|
2271
2340
|
newResult[${k}] = ${id}.value;
|
|
2272
2341
|
}
|
|
2273
2342
|
|
|
2343
|
+
`);
|
|
2344
|
+
else if (!isOptionalIn) doc.write(`
|
|
2345
|
+
const ${id}_present = ${k} in input;
|
|
2346
|
+
if (${id}.issues.length) {
|
|
2347
|
+
payload.issues = payload.issues.concat(${id}.issues.map(iss => ({
|
|
2348
|
+
...iss,
|
|
2349
|
+
path: iss.path ? [${k}, ...iss.path] : [${k}]
|
|
2350
|
+
})));
|
|
2351
|
+
}
|
|
2352
|
+
if (!${id}_present && !${id}.issues.length) {
|
|
2353
|
+
payload.issues.push({
|
|
2354
|
+
code: "invalid_type",
|
|
2355
|
+
expected: "nonoptional",
|
|
2356
|
+
input: undefined,
|
|
2357
|
+
path: [${k}]
|
|
2358
|
+
});
|
|
2359
|
+
}
|
|
2360
|
+
|
|
2361
|
+
if (${id}_present) {
|
|
2362
|
+
if (${id}.value === undefined) {
|
|
2363
|
+
newResult[${k}] = undefined;
|
|
2364
|
+
} else {
|
|
2365
|
+
newResult[${k}] = ${id}.value;
|
|
2366
|
+
}
|
|
2367
|
+
}
|
|
2368
|
+
|
|
2274
2369
|
`);
|
|
2275
2370
|
else doc.write(`
|
|
2276
2371
|
if (${id}.issues.length) {
|
|
@@ -2296,7 +2391,7 @@ var $ZodObjectJIT = /* @__PURE__ */ $constructor("$ZodObjectJIT", (inst, def) =>
|
|
|
2296
2391
|
return (payload, ctx) => fn(shape, payload, ctx);
|
|
2297
2392
|
};
|
|
2298
2393
|
let fastpass;
|
|
2299
|
-
const isObject$
|
|
2394
|
+
const isObject$2 = isObject;
|
|
2300
2395
|
const jit = !globalConfig.jitless;
|
|
2301
2396
|
const fastEnabled = jit && allowsEval.value;
|
|
2302
2397
|
const catchall = def.catchall;
|
|
@@ -2304,7 +2399,7 @@ var $ZodObjectJIT = /* @__PURE__ */ $constructor("$ZodObjectJIT", (inst, def) =>
|
|
|
2304
2399
|
inst._zod.parse = (payload, ctx) => {
|
|
2305
2400
|
value ?? (value = _normalized.value);
|
|
2306
2401
|
const input = payload.value;
|
|
2307
|
-
if (!isObject$
|
|
2402
|
+
if (!isObject$2(input)) {
|
|
2308
2403
|
payload.issues.push({
|
|
2309
2404
|
expected: "object",
|
|
2310
2405
|
code: "invalid_type",
|
|
@@ -2353,10 +2448,9 @@ var $ZodUnion = /* @__PURE__ */ $constructor("$ZodUnion", (inst, def) => {
|
|
|
2353
2448
|
return new RegExp(`^(${patterns.map((p) => cleanRegex(p.source)).join("|")})$`);
|
|
2354
2449
|
}
|
|
2355
2450
|
});
|
|
2356
|
-
const
|
|
2357
|
-
const first = def.options[0]._zod.run;
|
|
2451
|
+
const first = def.options.length === 1 ? def.options[0]._zod.run : null;
|
|
2358
2452
|
inst._zod.parse = (payload, ctx) => {
|
|
2359
|
-
if (
|
|
2453
|
+
if (first) return first(payload, ctx);
|
|
2360
2454
|
let async = false;
|
|
2361
2455
|
const results = [];
|
|
2362
2456
|
for (const option of def.options) {
|
|
@@ -2402,10 +2496,9 @@ function handleExclusiveUnionResults(results, final, inst, ctx) {
|
|
|
2402
2496
|
var $ZodXor = /* @__PURE__ */ $constructor("$ZodXor", (inst, def) => {
|
|
2403
2497
|
$ZodUnion.init(inst, def);
|
|
2404
2498
|
def.inclusive = false;
|
|
2405
|
-
const
|
|
2406
|
-
const first = def.options[0]._zod.run;
|
|
2499
|
+
const first = def.options.length === 1 ? def.options[0]._zod.run : null;
|
|
2407
2500
|
inst._zod.parse = (payload, ctx) => {
|
|
2408
|
-
if (
|
|
2501
|
+
if (first) return first(payload, ctx);
|
|
2409
2502
|
let async = false;
|
|
2410
2503
|
const results = [];
|
|
2411
2504
|
for (const option of def.options) {
|
|
@@ -2466,12 +2559,13 @@ var $ZodDiscriminatedUnion = /* @__PURE__ */ $constructor("$ZodDiscriminatedUnio
|
|
|
2466
2559
|
}
|
|
2467
2560
|
const opt = disc.value.get(input?.[def.discriminator]);
|
|
2468
2561
|
if (opt) return opt._zod.run(payload, ctx);
|
|
2469
|
-
if (def.unionFallback) return _super(payload, ctx);
|
|
2562
|
+
if (def.unionFallback || ctx.direction === "backward") return _super(payload, ctx);
|
|
2470
2563
|
payload.issues.push({
|
|
2471
2564
|
code: "invalid_union",
|
|
2472
2565
|
errors: [],
|
|
2473
2566
|
note: "No matching discriminator",
|
|
2474
2567
|
discriminator: def.discriminator,
|
|
2568
|
+
options: Array.from(disc.value.keys()),
|
|
2475
2569
|
input,
|
|
2476
2570
|
path: [def.discriminator],
|
|
2477
2571
|
inst
|
|
@@ -2594,42 +2688,42 @@ var $ZodTuple = /* @__PURE__ */ $constructor("$ZodTuple", (inst, def) => {
|
|
|
2594
2688
|
}
|
|
2595
2689
|
payload.value = [];
|
|
2596
2690
|
const proms = [];
|
|
2597
|
-
const
|
|
2598
|
-
const
|
|
2691
|
+
const optinStart = getTupleOptStart(items, "optin");
|
|
2692
|
+
const optoutStart = getTupleOptStart(items, "optout");
|
|
2599
2693
|
if (!def.rest) {
|
|
2600
|
-
|
|
2601
|
-
const tooSmall = input.length < optStart - 1;
|
|
2602
|
-
if (tooBig || tooSmall) {
|
|
2694
|
+
if (input.length < optinStart) {
|
|
2603
2695
|
payload.issues.push({
|
|
2604
|
-
|
|
2605
|
-
|
|
2606
|
-
|
|
2607
|
-
inclusive: true
|
|
2608
|
-
} : {
|
|
2609
|
-
code: "too_small",
|
|
2610
|
-
minimum: items.length
|
|
2611
|
-
},
|
|
2696
|
+
code: "too_small",
|
|
2697
|
+
minimum: optinStart,
|
|
2698
|
+
inclusive: true,
|
|
2612
2699
|
input,
|
|
2613
2700
|
inst,
|
|
2614
2701
|
origin: "array"
|
|
2615
2702
|
});
|
|
2616
2703
|
return payload;
|
|
2617
2704
|
}
|
|
2705
|
+
if (input.length > items.length) payload.issues.push({
|
|
2706
|
+
code: "too_big",
|
|
2707
|
+
maximum: items.length,
|
|
2708
|
+
inclusive: true,
|
|
2709
|
+
input,
|
|
2710
|
+
inst,
|
|
2711
|
+
origin: "array"
|
|
2712
|
+
});
|
|
2618
2713
|
}
|
|
2619
|
-
|
|
2620
|
-
for (
|
|
2621
|
-
i
|
|
2622
|
-
if (i >= input.length) {
|
|
2623
|
-
if (i >= optStart) continue;
|
|
2624
|
-
}
|
|
2625
|
-
const result = item._zod.run({
|
|
2714
|
+
const itemResults = new Array(items.length);
|
|
2715
|
+
for (let i = 0; i < items.length; i++) {
|
|
2716
|
+
const r = items[i]._zod.run({
|
|
2626
2717
|
value: input[i],
|
|
2627
2718
|
issues: []
|
|
2628
2719
|
}, ctx);
|
|
2629
|
-
if (
|
|
2630
|
-
|
|
2720
|
+
if (r instanceof Promise) proms.push(r.then((rr) => {
|
|
2721
|
+
itemResults[i] = rr;
|
|
2722
|
+
}));
|
|
2723
|
+
else itemResults[i] = r;
|
|
2631
2724
|
}
|
|
2632
2725
|
if (def.rest) {
|
|
2726
|
+
let i = items.length - 1;
|
|
2633
2727
|
const rest = input.slice(items.length);
|
|
2634
2728
|
for (const el of rest) {
|
|
2635
2729
|
i++;
|
|
@@ -2637,18 +2731,39 @@ var $ZodTuple = /* @__PURE__ */ $constructor("$ZodTuple", (inst, def) => {
|
|
|
2637
2731
|
value: el,
|
|
2638
2732
|
issues: []
|
|
2639
2733
|
}, ctx);
|
|
2640
|
-
if (result instanceof Promise) proms.push(result.then((
|
|
2734
|
+
if (result instanceof Promise) proms.push(result.then((r) => handleTupleResult(r, payload, i)));
|
|
2641
2735
|
else handleTupleResult(result, payload, i);
|
|
2642
2736
|
}
|
|
2643
2737
|
}
|
|
2644
|
-
if (proms.length) return Promise.all(proms).then(() => payload);
|
|
2645
|
-
return payload;
|
|
2738
|
+
if (proms.length) return Promise.all(proms).then(() => handleTupleResults(itemResults, payload, items, input, optoutStart));
|
|
2739
|
+
return handleTupleResults(itemResults, payload, items, input, optoutStart);
|
|
2646
2740
|
};
|
|
2647
2741
|
});
|
|
2742
|
+
function getTupleOptStart(items, key) {
|
|
2743
|
+
for (let i = items.length - 1; i >= 0; i--) if (items[i]._zod[key] !== "optional") return i + 1;
|
|
2744
|
+
return 0;
|
|
2745
|
+
}
|
|
2648
2746
|
function handleTupleResult(result, final, index) {
|
|
2649
2747
|
if (result.issues.length) final.issues.push(...prefixIssues(index, result.issues));
|
|
2650
2748
|
final.value[index] = result.value;
|
|
2651
2749
|
}
|
|
2750
|
+
function handleTupleResults(itemResults, final, items, input, optoutStart) {
|
|
2751
|
+
for (let i = 0; i < items.length; i++) {
|
|
2752
|
+
const r = itemResults[i];
|
|
2753
|
+
const isPresent = i < input.length;
|
|
2754
|
+
if (r.issues.length) {
|
|
2755
|
+
if (!isPresent && i >= optoutStart) {
|
|
2756
|
+
final.value.length = i;
|
|
2757
|
+
break;
|
|
2758
|
+
}
|
|
2759
|
+
final.issues.push(...prefixIssues(i, r.issues));
|
|
2760
|
+
}
|
|
2761
|
+
final.value[i] = r.value;
|
|
2762
|
+
}
|
|
2763
|
+
for (let i = final.value.length - 1; i >= input.length; i--) if (items[i]._zod.optout === "optional" && final.value[i] === void 0) final.value.length = i;
|
|
2764
|
+
else break;
|
|
2765
|
+
return final;
|
|
2766
|
+
}
|
|
2652
2767
|
var $ZodRecord = /* @__PURE__ */ $constructor("$ZodRecord", (inst, def) => {
|
|
2653
2768
|
$ZodType.init(inst, def);
|
|
2654
2769
|
inst._zod.parse = (payload, ctx) => {
|
|
@@ -2669,17 +2784,34 @@ var $ZodRecord = /* @__PURE__ */ $constructor("$ZodRecord", (inst, def) => {
|
|
|
2669
2784
|
const recordKeys = /* @__PURE__ */ new Set();
|
|
2670
2785
|
for (const key of values) if (typeof key === "string" || typeof key === "number" || typeof key === "symbol") {
|
|
2671
2786
|
recordKeys.add(typeof key === "number" ? key.toString() : key);
|
|
2787
|
+
const keyResult = def.keyType._zod.run({
|
|
2788
|
+
value: key,
|
|
2789
|
+
issues: []
|
|
2790
|
+
}, ctx);
|
|
2791
|
+
if (keyResult instanceof Promise) throw new Error("Async schemas not supported in object keys currently");
|
|
2792
|
+
if (keyResult.issues.length) {
|
|
2793
|
+
payload.issues.push({
|
|
2794
|
+
code: "invalid_key",
|
|
2795
|
+
origin: "record",
|
|
2796
|
+
issues: keyResult.issues.map((iss) => finalizeIssue(iss, ctx, config())),
|
|
2797
|
+
input: key,
|
|
2798
|
+
path: [key],
|
|
2799
|
+
inst
|
|
2800
|
+
});
|
|
2801
|
+
continue;
|
|
2802
|
+
}
|
|
2803
|
+
const outKey = keyResult.value;
|
|
2672
2804
|
const result = def.valueType._zod.run({
|
|
2673
2805
|
value: input[key],
|
|
2674
2806
|
issues: []
|
|
2675
2807
|
}, ctx);
|
|
2676
2808
|
if (result instanceof Promise) proms.push(result.then((result) => {
|
|
2677
2809
|
if (result.issues.length) payload.issues.push(...prefixIssues(key, result.issues));
|
|
2678
|
-
payload.value[
|
|
2810
|
+
payload.value[outKey] = result.value;
|
|
2679
2811
|
}));
|
|
2680
2812
|
else {
|
|
2681
2813
|
if (result.issues.length) payload.issues.push(...prefixIssues(key, result.issues));
|
|
2682
|
-
payload.value[
|
|
2814
|
+
payload.value[outKey] = result.value;
|
|
2683
2815
|
}
|
|
2684
2816
|
}
|
|
2685
2817
|
let unrecognized;
|
|
@@ -2697,6 +2829,7 @@ var $ZodRecord = /* @__PURE__ */ $constructor("$ZodRecord", (inst, def) => {
|
|
|
2697
2829
|
payload.value = {};
|
|
2698
2830
|
for (const key of Reflect.ownKeys(input)) {
|
|
2699
2831
|
if (key === "__proto__") continue;
|
|
2832
|
+
if (!Object.prototype.propertyIsEnumerable.call(input, key)) continue;
|
|
2700
2833
|
let keyResult = def.keyType._zod.run({
|
|
2701
2834
|
value: key,
|
|
2702
2835
|
issues: []
|
|
@@ -3251,7 +3384,11 @@ var $ZodPromise = /* @__PURE__ */ $constructor("$ZodPromise", (inst, def) => {
|
|
|
3251
3384
|
});
|
|
3252
3385
|
var $ZodLazy = /* @__PURE__ */ $constructor("$ZodLazy", (inst, def) => {
|
|
3253
3386
|
$ZodType.init(inst, def);
|
|
3254
|
-
defineLazy(inst._zod, "innerType", () =>
|
|
3387
|
+
defineLazy(inst._zod, "innerType", () => {
|
|
3388
|
+
const d = def;
|
|
3389
|
+
if (!d._cachedInner) d._cachedInner = def.getter();
|
|
3390
|
+
return d._cachedInner;
|
|
3391
|
+
});
|
|
3255
3392
|
defineLazy(inst._zod, "pattern", () => inst._zod.innerType?._zod?.pattern);
|
|
3256
3393
|
defineLazy(inst._zod, "propValues", () => inst._zod.innerType?._zod?.propValues);
|
|
3257
3394
|
defineLazy(inst._zod, "optin", () => inst._zod.innerType?._zod?.optin ?? void 0);
|
|
@@ -3287,8 +3424,8 @@ function handleRefineResult(result, payload, input, inst) {
|
|
|
3287
3424
|
}
|
|
3288
3425
|
}
|
|
3289
3426
|
//#endregion
|
|
3290
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
3291
|
-
var error$
|
|
3427
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/ar.js
|
|
3428
|
+
var error$49 = () => {
|
|
3292
3429
|
const Sizable = {
|
|
3293
3430
|
string: {
|
|
3294
3431
|
unit: "حرف",
|
|
@@ -3383,11 +3520,11 @@ var error$46 = () => {
|
|
|
3383
3520
|
};
|
|
3384
3521
|
};
|
|
3385
3522
|
function ar_default() {
|
|
3386
|
-
return { localeError: error$
|
|
3523
|
+
return { localeError: error$49() };
|
|
3387
3524
|
}
|
|
3388
3525
|
//#endregion
|
|
3389
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
3390
|
-
var error$
|
|
3526
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/az.js
|
|
3527
|
+
var error$48 = () => {
|
|
3391
3528
|
const Sizable = {
|
|
3392
3529
|
string: {
|
|
3393
3530
|
unit: "simvol",
|
|
@@ -3482,10 +3619,10 @@ var error$45 = () => {
|
|
|
3482
3619
|
};
|
|
3483
3620
|
};
|
|
3484
3621
|
function az_default() {
|
|
3485
|
-
return { localeError: error$
|
|
3622
|
+
return { localeError: error$48() };
|
|
3486
3623
|
}
|
|
3487
3624
|
//#endregion
|
|
3488
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
3625
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/be.js
|
|
3489
3626
|
function getBelarusianPlural(count, one, few, many) {
|
|
3490
3627
|
const absCount = Math.abs(count);
|
|
3491
3628
|
const lastDigit = absCount % 10;
|
|
@@ -3495,7 +3632,7 @@ function getBelarusianPlural(count, one, few, many) {
|
|
|
3495
3632
|
if (lastDigit >= 2 && lastDigit <= 4) return few;
|
|
3496
3633
|
return many;
|
|
3497
3634
|
}
|
|
3498
|
-
var error$
|
|
3635
|
+
var error$47 = () => {
|
|
3499
3636
|
const Sizable = {
|
|
3500
3637
|
string: {
|
|
3501
3638
|
unit: {
|
|
@@ -3616,11 +3753,11 @@ var error$44 = () => {
|
|
|
3616
3753
|
};
|
|
3617
3754
|
};
|
|
3618
3755
|
function be_default() {
|
|
3619
|
-
return { localeError: error$
|
|
3756
|
+
return { localeError: error$47() };
|
|
3620
3757
|
}
|
|
3621
3758
|
//#endregion
|
|
3622
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
3623
|
-
var error$
|
|
3759
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/bg.js
|
|
3760
|
+
var error$46 = () => {
|
|
3624
3761
|
const Sizable = {
|
|
3625
3762
|
string: {
|
|
3626
3763
|
unit: "символа",
|
|
@@ -3725,11 +3862,11 @@ var error$43 = () => {
|
|
|
3725
3862
|
};
|
|
3726
3863
|
};
|
|
3727
3864
|
function bg_default() {
|
|
3728
|
-
return { localeError: error$
|
|
3865
|
+
return { localeError: error$46() };
|
|
3729
3866
|
}
|
|
3730
3867
|
//#endregion
|
|
3731
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
3732
|
-
var error$
|
|
3868
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/ca.js
|
|
3869
|
+
var error$45 = () => {
|
|
3733
3870
|
const Sizable = {
|
|
3734
3871
|
string: {
|
|
3735
3872
|
unit: "caràcters",
|
|
@@ -3824,11 +3961,11 @@ var error$42 = () => {
|
|
|
3824
3961
|
};
|
|
3825
3962
|
};
|
|
3826
3963
|
function ca_default() {
|
|
3827
|
-
return { localeError: error$
|
|
3964
|
+
return { localeError: error$45() };
|
|
3828
3965
|
}
|
|
3829
3966
|
//#endregion
|
|
3830
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
3831
|
-
var error$
|
|
3967
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/cs.js
|
|
3968
|
+
var error$44 = () => {
|
|
3832
3969
|
const Sizable = {
|
|
3833
3970
|
string: {
|
|
3834
3971
|
unit: "znaků",
|
|
@@ -3929,11 +4066,11 @@ var error$41 = () => {
|
|
|
3929
4066
|
};
|
|
3930
4067
|
};
|
|
3931
4068
|
function cs_default() {
|
|
3932
|
-
return { localeError: error$
|
|
4069
|
+
return { localeError: error$44() };
|
|
3933
4070
|
}
|
|
3934
4071
|
//#endregion
|
|
3935
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
3936
|
-
var error$
|
|
4072
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/da.js
|
|
4073
|
+
var error$43 = () => {
|
|
3937
4074
|
const Sizable = {
|
|
3938
4075
|
string: {
|
|
3939
4076
|
unit: "tegn",
|
|
@@ -4039,11 +4176,11 @@ var error$40 = () => {
|
|
|
4039
4176
|
};
|
|
4040
4177
|
};
|
|
4041
4178
|
function da_default() {
|
|
4042
|
-
return { localeError: error$
|
|
4179
|
+
return { localeError: error$43() };
|
|
4043
4180
|
}
|
|
4044
4181
|
//#endregion
|
|
4045
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
4046
|
-
var error$
|
|
4182
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/de.js
|
|
4183
|
+
var error$42 = () => {
|
|
4047
4184
|
const Sizable = {
|
|
4048
4185
|
string: {
|
|
4049
4186
|
unit: "Zeichen",
|
|
@@ -4142,11 +4279,115 @@ var error$39 = () => {
|
|
|
4142
4279
|
};
|
|
4143
4280
|
};
|
|
4144
4281
|
function de_default() {
|
|
4145
|
-
return { localeError: error$
|
|
4282
|
+
return { localeError: error$42() };
|
|
4146
4283
|
}
|
|
4147
4284
|
//#endregion
|
|
4148
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
4149
|
-
var error$
|
|
4285
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/el.js
|
|
4286
|
+
var error$41 = () => {
|
|
4287
|
+
const Sizable = {
|
|
4288
|
+
string: {
|
|
4289
|
+
unit: "χαρακτήρες",
|
|
4290
|
+
verb: "να έχει"
|
|
4291
|
+
},
|
|
4292
|
+
file: {
|
|
4293
|
+
unit: "bytes",
|
|
4294
|
+
verb: "να έχει"
|
|
4295
|
+
},
|
|
4296
|
+
array: {
|
|
4297
|
+
unit: "στοιχεία",
|
|
4298
|
+
verb: "να έχει"
|
|
4299
|
+
},
|
|
4300
|
+
set: {
|
|
4301
|
+
unit: "στοιχεία",
|
|
4302
|
+
verb: "να έχει"
|
|
4303
|
+
},
|
|
4304
|
+
map: {
|
|
4305
|
+
unit: "καταχωρήσεις",
|
|
4306
|
+
verb: "να έχει"
|
|
4307
|
+
}
|
|
4308
|
+
};
|
|
4309
|
+
function getSizing(origin) {
|
|
4310
|
+
return Sizable[origin] ?? null;
|
|
4311
|
+
}
|
|
4312
|
+
const FormatDictionary = {
|
|
4313
|
+
regex: "είσοδος",
|
|
4314
|
+
email: "διεύθυνση email",
|
|
4315
|
+
url: "URL",
|
|
4316
|
+
emoji: "emoji",
|
|
4317
|
+
uuid: "UUID",
|
|
4318
|
+
uuidv4: "UUIDv4",
|
|
4319
|
+
uuidv6: "UUIDv6",
|
|
4320
|
+
nanoid: "nanoid",
|
|
4321
|
+
guid: "GUID",
|
|
4322
|
+
cuid: "cuid",
|
|
4323
|
+
cuid2: "cuid2",
|
|
4324
|
+
ulid: "ULID",
|
|
4325
|
+
xid: "XID",
|
|
4326
|
+
ksuid: "KSUID",
|
|
4327
|
+
datetime: "ISO ημερομηνία και ώρα",
|
|
4328
|
+
date: "ISO ημερομηνία",
|
|
4329
|
+
time: "ISO ώρα",
|
|
4330
|
+
duration: "ISO διάρκεια",
|
|
4331
|
+
ipv4: "διεύθυνση IPv4",
|
|
4332
|
+
ipv6: "διεύθυνση IPv6",
|
|
4333
|
+
mac: "διεύθυνση MAC",
|
|
4334
|
+
cidrv4: "εύρος IPv4",
|
|
4335
|
+
cidrv6: "εύρος IPv6",
|
|
4336
|
+
base64: "συμβολοσειρά κωδικοποιημένη σε base64",
|
|
4337
|
+
base64url: "συμβολοσειρά κωδικοποιημένη σε base64url",
|
|
4338
|
+
json_string: "συμβολοσειρά JSON",
|
|
4339
|
+
e164: "αριθμός E.164",
|
|
4340
|
+
jwt: "JWT",
|
|
4341
|
+
template_literal: "είσοδος"
|
|
4342
|
+
};
|
|
4343
|
+
const TypeDictionary = { nan: "NaN" };
|
|
4344
|
+
return (issue) => {
|
|
4345
|
+
switch (issue.code) {
|
|
4346
|
+
case "invalid_type": {
|
|
4347
|
+
const expected = TypeDictionary[issue.expected] ?? issue.expected;
|
|
4348
|
+
const receivedType = parsedType(issue.input);
|
|
4349
|
+
const received = TypeDictionary[receivedType] ?? receivedType;
|
|
4350
|
+
if (typeof issue.expected === "string" && /^[A-Z]/.test(issue.expected)) return `Μη έγκυρη είσοδος: αναμενόταν instanceof ${issue.expected}, λήφθηκε ${received}`;
|
|
4351
|
+
return `Μη έγκυρη είσοδος: αναμενόταν ${expected}, λήφθηκε ${received}`;
|
|
4352
|
+
}
|
|
4353
|
+
case "invalid_value":
|
|
4354
|
+
if (issue.values.length === 1) return `Μη έγκυρη είσοδος: αναμενόταν ${stringifyPrimitive(issue.values[0])}`;
|
|
4355
|
+
return `Μη έγκυρη επιλογή: αναμενόταν ένα από ${joinValues(issue.values, "|")}`;
|
|
4356
|
+
case "too_big": {
|
|
4357
|
+
const adj = issue.inclusive ? "<=" : "<";
|
|
4358
|
+
const sizing = getSizing(issue.origin);
|
|
4359
|
+
if (sizing) return `Πολύ μεγάλο: αναμενόταν ${issue.origin ?? "τιμή"} να έχει ${adj}${issue.maximum.toString()} ${sizing.unit ?? "στοιχεία"}`;
|
|
4360
|
+
return `Πολύ μεγάλο: αναμενόταν ${issue.origin ?? "τιμή"} να είναι ${adj}${issue.maximum.toString()}`;
|
|
4361
|
+
}
|
|
4362
|
+
case "too_small": {
|
|
4363
|
+
const adj = issue.inclusive ? ">=" : ">";
|
|
4364
|
+
const sizing = getSizing(issue.origin);
|
|
4365
|
+
if (sizing) return `Πολύ μικρό: αναμενόταν ${issue.origin} να έχει ${adj}${issue.minimum.toString()} ${sizing.unit}`;
|
|
4366
|
+
return `Πολύ μικρό: αναμενόταν ${issue.origin} να είναι ${adj}${issue.minimum.toString()}`;
|
|
4367
|
+
}
|
|
4368
|
+
case "invalid_format": {
|
|
4369
|
+
const _issue = issue;
|
|
4370
|
+
if (_issue.format === "starts_with") return `Μη έγκυρη συμβολοσειρά: πρέπει να ξεκινά με "${_issue.prefix}"`;
|
|
4371
|
+
if (_issue.format === "ends_with") return `Μη έγκυρη συμβολοσειρά: πρέπει να τελειώνει με "${_issue.suffix}"`;
|
|
4372
|
+
if (_issue.format === "includes") return `Μη έγκυρη συμβολοσειρά: πρέπει να περιέχει "${_issue.includes}"`;
|
|
4373
|
+
if (_issue.format === "regex") return `Μη έγκυρη συμβολοσειρά: πρέπει να ταιριάζει με το μοτίβο ${_issue.pattern}`;
|
|
4374
|
+
return `Μη έγκυρο: ${FormatDictionary[_issue.format] ?? issue.format}`;
|
|
4375
|
+
}
|
|
4376
|
+
case "not_multiple_of": return `Μη έγκυρος αριθμός: πρέπει να είναι πολλαπλάσιο του ${issue.divisor}`;
|
|
4377
|
+
case "unrecognized_keys": return `Άγνωστ${issue.keys.length > 1 ? "α" : "ο"} κλειδ${issue.keys.length > 1 ? "ιά" : "ί"}: ${joinValues(issue.keys, ", ")}`;
|
|
4378
|
+
case "invalid_key": return `Μη έγκυρο κλειδί στο ${issue.origin}`;
|
|
4379
|
+
case "invalid_union": return "Μη έγκυρη είσοδος";
|
|
4380
|
+
case "invalid_element": return `Μη έγκυρη τιμή στο ${issue.origin}`;
|
|
4381
|
+
default: return `Μη έγκυρη είσοδος`;
|
|
4382
|
+
}
|
|
4383
|
+
};
|
|
4384
|
+
};
|
|
4385
|
+
function el_default() {
|
|
4386
|
+
return { localeError: error$41() };
|
|
4387
|
+
}
|
|
4388
|
+
//#endregion
|
|
4389
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/en.js
|
|
4390
|
+
var error$40 = () => {
|
|
4150
4391
|
const Sizable = {
|
|
4151
4392
|
string: {
|
|
4152
4393
|
unit: "characters",
|
|
@@ -4237,18 +4478,20 @@ var error$38 = () => {
|
|
|
4237
4478
|
case "not_multiple_of": return `Invalid number: must be a multiple of ${issue.divisor}`;
|
|
4238
4479
|
case "unrecognized_keys": return `Unrecognized key${issue.keys.length > 1 ? "s" : ""}: ${joinValues(issue.keys, ", ")}`;
|
|
4239
4480
|
case "invalid_key": return `Invalid key in ${issue.origin}`;
|
|
4240
|
-
case "invalid_union":
|
|
4481
|
+
case "invalid_union":
|
|
4482
|
+
if (issue.options && Array.isArray(issue.options) && issue.options.length > 0) return `Invalid discriminator value. Expected ${issue.options.map((o) => `'${o}'`).join(" | ")}`;
|
|
4483
|
+
return "Invalid input";
|
|
4241
4484
|
case "invalid_element": return `Invalid value in ${issue.origin}`;
|
|
4242
4485
|
default: return `Invalid input`;
|
|
4243
4486
|
}
|
|
4244
4487
|
};
|
|
4245
4488
|
};
|
|
4246
4489
|
function en_default() {
|
|
4247
|
-
return { localeError: error$
|
|
4490
|
+
return { localeError: error$40() };
|
|
4248
4491
|
}
|
|
4249
4492
|
//#endregion
|
|
4250
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
4251
|
-
var error$
|
|
4493
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/eo.js
|
|
4494
|
+
var error$39 = () => {
|
|
4252
4495
|
const Sizable = {
|
|
4253
4496
|
string: {
|
|
4254
4497
|
unit: "karaktrojn",
|
|
@@ -4348,11 +4591,11 @@ var error$37 = () => {
|
|
|
4348
4591
|
};
|
|
4349
4592
|
};
|
|
4350
4593
|
function eo_default() {
|
|
4351
|
-
return { localeError: error$
|
|
4594
|
+
return { localeError: error$39() };
|
|
4352
4595
|
}
|
|
4353
4596
|
//#endregion
|
|
4354
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
4355
|
-
var error$
|
|
4597
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/es.js
|
|
4598
|
+
var error$38 = () => {
|
|
4356
4599
|
const Sizable = {
|
|
4357
4600
|
string: {
|
|
4358
4601
|
unit: "caracteres",
|
|
@@ -4475,11 +4718,11 @@ var error$36 = () => {
|
|
|
4475
4718
|
};
|
|
4476
4719
|
};
|
|
4477
4720
|
function es_default() {
|
|
4478
|
-
return { localeError: error$
|
|
4721
|
+
return { localeError: error$38() };
|
|
4479
4722
|
}
|
|
4480
4723
|
//#endregion
|
|
4481
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
4482
|
-
var error$
|
|
4724
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/fa.js
|
|
4725
|
+
var error$37 = () => {
|
|
4483
4726
|
const Sizable = {
|
|
4484
4727
|
string: {
|
|
4485
4728
|
unit: "کاراکتر",
|
|
@@ -4578,11 +4821,11 @@ var error$35 = () => {
|
|
|
4578
4821
|
};
|
|
4579
4822
|
};
|
|
4580
4823
|
function fa_default() {
|
|
4581
|
-
return { localeError: error$
|
|
4824
|
+
return { localeError: error$37() };
|
|
4582
4825
|
}
|
|
4583
4826
|
//#endregion
|
|
4584
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
4585
|
-
var error$
|
|
4827
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/fi.js
|
|
4828
|
+
var error$36 = () => {
|
|
4586
4829
|
const Sizable = {
|
|
4587
4830
|
string: {
|
|
4588
4831
|
unit: "merkkiä",
|
|
@@ -4693,11 +4936,11 @@ var error$34 = () => {
|
|
|
4693
4936
|
};
|
|
4694
4937
|
};
|
|
4695
4938
|
function fi_default() {
|
|
4696
|
-
return { localeError: error$
|
|
4939
|
+
return { localeError: error$36() };
|
|
4697
4940
|
}
|
|
4698
4941
|
//#endregion
|
|
4699
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
4700
|
-
var error$
|
|
4942
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/fr.js
|
|
4943
|
+
var error$35 = () => {
|
|
4701
4944
|
const Sizable = {
|
|
4702
4945
|
string: {
|
|
4703
4946
|
unit: "caractères",
|
|
@@ -4750,9 +4993,27 @@ var error$33 = () => {
|
|
|
4750
4993
|
template_literal: "entrée"
|
|
4751
4994
|
};
|
|
4752
4995
|
const TypeDictionary = {
|
|
4753
|
-
|
|
4996
|
+
string: "chaîne",
|
|
4754
4997
|
number: "nombre",
|
|
4755
|
-
|
|
4998
|
+
int: "entier",
|
|
4999
|
+
boolean: "booléen",
|
|
5000
|
+
bigint: "grand entier",
|
|
5001
|
+
symbol: "symbole",
|
|
5002
|
+
undefined: "indéfini",
|
|
5003
|
+
null: "null",
|
|
5004
|
+
never: "jamais",
|
|
5005
|
+
void: "vide",
|
|
5006
|
+
date: "date",
|
|
5007
|
+
array: "tableau",
|
|
5008
|
+
object: "objet",
|
|
5009
|
+
tuple: "tuple",
|
|
5010
|
+
record: "enregistrement",
|
|
5011
|
+
map: "carte",
|
|
5012
|
+
set: "ensemble",
|
|
5013
|
+
file: "fichier",
|
|
5014
|
+
nonoptional: "non-optionnel",
|
|
5015
|
+
nan: "NaN",
|
|
5016
|
+
function: "fonction"
|
|
4756
5017
|
};
|
|
4757
5018
|
return (issue) => {
|
|
4758
5019
|
switch (issue.code) {
|
|
@@ -4769,14 +5030,14 @@ var error$33 = () => {
|
|
|
4769
5030
|
case "too_big": {
|
|
4770
5031
|
const adj = issue.inclusive ? "<=" : "<";
|
|
4771
5032
|
const sizing = getSizing(issue.origin);
|
|
4772
|
-
if (sizing) return `Trop grand : ${issue.origin ?? "valeur"} doit ${sizing.verb} ${adj}${issue.maximum.toString()} ${sizing.unit ?? "élément(s)"}`;
|
|
4773
|
-
return `Trop grand : ${issue.origin ?? "valeur"} doit être ${adj}${issue.maximum.toString()}`;
|
|
5033
|
+
if (sizing) return `Trop grand : ${TypeDictionary[issue.origin] ?? "valeur"} doit ${sizing.verb} ${adj}${issue.maximum.toString()} ${sizing.unit ?? "élément(s)"}`;
|
|
5034
|
+
return `Trop grand : ${TypeDictionary[issue.origin] ?? "valeur"} doit être ${adj}${issue.maximum.toString()}`;
|
|
4774
5035
|
}
|
|
4775
5036
|
case "too_small": {
|
|
4776
5037
|
const adj = issue.inclusive ? ">=" : ">";
|
|
4777
5038
|
const sizing = getSizing(issue.origin);
|
|
4778
|
-
if (sizing) return `Trop petit : ${issue.origin} doit ${sizing.verb} ${adj}${issue.minimum.toString()} ${sizing.unit}`;
|
|
4779
|
-
return `Trop petit : ${issue.origin} doit être ${adj}${issue.minimum.toString()}`;
|
|
5039
|
+
if (sizing) return `Trop petit : ${TypeDictionary[issue.origin] ?? "valeur"} doit ${sizing.verb} ${adj}${issue.minimum.toString()} ${sizing.unit}`;
|
|
5040
|
+
return `Trop petit : ${TypeDictionary[issue.origin] ?? "valeur"} doit être ${adj}${issue.minimum.toString()}`;
|
|
4780
5041
|
}
|
|
4781
5042
|
case "invalid_format": {
|
|
4782
5043
|
const _issue = issue;
|
|
@@ -4796,11 +5057,11 @@ var error$33 = () => {
|
|
|
4796
5057
|
};
|
|
4797
5058
|
};
|
|
4798
5059
|
function fr_default() {
|
|
4799
|
-
return { localeError: error$
|
|
5060
|
+
return { localeError: error$35() };
|
|
4800
5061
|
}
|
|
4801
5062
|
//#endregion
|
|
4802
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
4803
|
-
var error$
|
|
5063
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/fr-CA.js
|
|
5064
|
+
var error$34 = () => {
|
|
4804
5065
|
const Sizable = {
|
|
4805
5066
|
string: {
|
|
4806
5067
|
unit: "caractères",
|
|
@@ -4895,11 +5156,11 @@ var error$32 = () => {
|
|
|
4895
5156
|
};
|
|
4896
5157
|
};
|
|
4897
5158
|
function fr_CA_default() {
|
|
4898
|
-
return { localeError: error$
|
|
5159
|
+
return { localeError: error$34() };
|
|
4899
5160
|
}
|
|
4900
5161
|
//#endregion
|
|
4901
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
4902
|
-
var error$
|
|
5162
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/he.js
|
|
5163
|
+
var error$33 = () => {
|
|
4903
5164
|
const TypeNames = {
|
|
4904
5165
|
string: {
|
|
4905
5166
|
label: "מחרוזת",
|
|
@@ -5200,11 +5461,128 @@ var error$31 = () => {
|
|
|
5200
5461
|
};
|
|
5201
5462
|
};
|
|
5202
5463
|
function he_default() {
|
|
5203
|
-
return { localeError: error$
|
|
5464
|
+
return { localeError: error$33() };
|
|
5204
5465
|
}
|
|
5205
5466
|
//#endregion
|
|
5206
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
5207
|
-
var error$
|
|
5467
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/hr.js
|
|
5468
|
+
var error$32 = () => {
|
|
5469
|
+
const Sizable = {
|
|
5470
|
+
string: {
|
|
5471
|
+
unit: "znakova",
|
|
5472
|
+
verb: "imati"
|
|
5473
|
+
},
|
|
5474
|
+
file: {
|
|
5475
|
+
unit: "bajtova",
|
|
5476
|
+
verb: "imati"
|
|
5477
|
+
},
|
|
5478
|
+
array: {
|
|
5479
|
+
unit: "stavki",
|
|
5480
|
+
verb: "imati"
|
|
5481
|
+
},
|
|
5482
|
+
set: {
|
|
5483
|
+
unit: "stavki",
|
|
5484
|
+
verb: "imati"
|
|
5485
|
+
}
|
|
5486
|
+
};
|
|
5487
|
+
function getSizing(origin) {
|
|
5488
|
+
return Sizable[origin] ?? null;
|
|
5489
|
+
}
|
|
5490
|
+
const FormatDictionary = {
|
|
5491
|
+
regex: "unos",
|
|
5492
|
+
email: "email adresa",
|
|
5493
|
+
url: "URL",
|
|
5494
|
+
emoji: "emoji",
|
|
5495
|
+
uuid: "UUID",
|
|
5496
|
+
uuidv4: "UUIDv4",
|
|
5497
|
+
uuidv6: "UUIDv6",
|
|
5498
|
+
nanoid: "nanoid",
|
|
5499
|
+
guid: "GUID",
|
|
5500
|
+
cuid: "cuid",
|
|
5501
|
+
cuid2: "cuid2",
|
|
5502
|
+
ulid: "ULID",
|
|
5503
|
+
xid: "XID",
|
|
5504
|
+
ksuid: "KSUID",
|
|
5505
|
+
datetime: "ISO datum i vrijeme",
|
|
5506
|
+
date: "ISO datum",
|
|
5507
|
+
time: "ISO vrijeme",
|
|
5508
|
+
duration: "ISO trajanje",
|
|
5509
|
+
ipv4: "IPv4 adresa",
|
|
5510
|
+
ipv6: "IPv6 adresa",
|
|
5511
|
+
cidrv4: "IPv4 raspon",
|
|
5512
|
+
cidrv6: "IPv6 raspon",
|
|
5513
|
+
base64: "base64 kodirani tekst",
|
|
5514
|
+
base64url: "base64url kodirani tekst",
|
|
5515
|
+
json_string: "JSON tekst",
|
|
5516
|
+
e164: "E.164 broj",
|
|
5517
|
+
jwt: "JWT",
|
|
5518
|
+
template_literal: "unos"
|
|
5519
|
+
};
|
|
5520
|
+
const TypeDictionary = {
|
|
5521
|
+
nan: "NaN",
|
|
5522
|
+
string: "tekst",
|
|
5523
|
+
number: "broj",
|
|
5524
|
+
boolean: "boolean",
|
|
5525
|
+
array: "niz",
|
|
5526
|
+
object: "objekt",
|
|
5527
|
+
set: "skup",
|
|
5528
|
+
file: "datoteka",
|
|
5529
|
+
date: "datum",
|
|
5530
|
+
bigint: "bigint",
|
|
5531
|
+
symbol: "simbol",
|
|
5532
|
+
undefined: "undefined",
|
|
5533
|
+
null: "null",
|
|
5534
|
+
function: "funkcija",
|
|
5535
|
+
map: "mapa"
|
|
5536
|
+
};
|
|
5537
|
+
return (issue) => {
|
|
5538
|
+
switch (issue.code) {
|
|
5539
|
+
case "invalid_type": {
|
|
5540
|
+
const expected = TypeDictionary[issue.expected] ?? issue.expected;
|
|
5541
|
+
const receivedType = parsedType(issue.input);
|
|
5542
|
+
const received = TypeDictionary[receivedType] ?? receivedType;
|
|
5543
|
+
if (/^[A-Z]/.test(issue.expected)) return `Neispravan unos: očekuje se instanceof ${issue.expected}, a primljeno je ${received}`;
|
|
5544
|
+
return `Neispravan unos: očekuje se ${expected}, a primljeno je ${received}`;
|
|
5545
|
+
}
|
|
5546
|
+
case "invalid_value":
|
|
5547
|
+
if (issue.values.length === 1) return `Neispravna vrijednost: očekivano ${stringifyPrimitive(issue.values[0])}`;
|
|
5548
|
+
return `Neispravna opcija: očekivano jedno od ${joinValues(issue.values, "|")}`;
|
|
5549
|
+
case "too_big": {
|
|
5550
|
+
const adj = issue.inclusive ? "<=" : "<";
|
|
5551
|
+
const sizing = getSizing(issue.origin);
|
|
5552
|
+
const origin = TypeDictionary[issue.origin] ?? issue.origin;
|
|
5553
|
+
if (sizing) return `Preveliko: očekivano da ${origin ?? "vrijednost"} ima ${adj}${issue.maximum.toString()} ${sizing.unit ?? "elemenata"}`;
|
|
5554
|
+
return `Preveliko: očekivano da ${origin ?? "vrijednost"} bude ${adj}${issue.maximum.toString()}`;
|
|
5555
|
+
}
|
|
5556
|
+
case "too_small": {
|
|
5557
|
+
const adj = issue.inclusive ? ">=" : ">";
|
|
5558
|
+
const sizing = getSizing(issue.origin);
|
|
5559
|
+
const origin = TypeDictionary[issue.origin] ?? issue.origin;
|
|
5560
|
+
if (sizing) return `Premalo: očekivano da ${origin} ima ${adj}${issue.minimum.toString()} ${sizing.unit}`;
|
|
5561
|
+
return `Premalo: očekivano da ${origin} bude ${adj}${issue.minimum.toString()}`;
|
|
5562
|
+
}
|
|
5563
|
+
case "invalid_format": {
|
|
5564
|
+
const _issue = issue;
|
|
5565
|
+
if (_issue.format === "starts_with") return `Neispravan tekst: mora započinjati s "${_issue.prefix}"`;
|
|
5566
|
+
if (_issue.format === "ends_with") return `Neispravan tekst: mora završavati s "${_issue.suffix}"`;
|
|
5567
|
+
if (_issue.format === "includes") return `Neispravan tekst: mora sadržavati "${_issue.includes}"`;
|
|
5568
|
+
if (_issue.format === "regex") return `Neispravan tekst: mora odgovarati uzorku ${_issue.pattern}`;
|
|
5569
|
+
return `Neispravna ${FormatDictionary[_issue.format] ?? issue.format}`;
|
|
5570
|
+
}
|
|
5571
|
+
case "not_multiple_of": return `Neispravan broj: mora biti višekratnik od ${issue.divisor}`;
|
|
5572
|
+
case "unrecognized_keys": return `Neprepoznat${issue.keys.length > 1 ? "i ključevi" : " ključ"}: ${joinValues(issue.keys, ", ")}`;
|
|
5573
|
+
case "invalid_key": return `Neispravan ključ u ${TypeDictionary[issue.origin] ?? issue.origin}`;
|
|
5574
|
+
case "invalid_union": return "Neispravan unos";
|
|
5575
|
+
case "invalid_element": return `Neispravna vrijednost u ${TypeDictionary[issue.origin] ?? issue.origin}`;
|
|
5576
|
+
default: return `Neispravan unos`;
|
|
5577
|
+
}
|
|
5578
|
+
};
|
|
5579
|
+
};
|
|
5580
|
+
function hr_default() {
|
|
5581
|
+
return { localeError: error$32() };
|
|
5582
|
+
}
|
|
5583
|
+
//#endregion
|
|
5584
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/hu.js
|
|
5585
|
+
var error$31 = () => {
|
|
5208
5586
|
const Sizable = {
|
|
5209
5587
|
string: {
|
|
5210
5588
|
unit: "karakter",
|
|
@@ -5303,10 +5681,10 @@ var error$30 = () => {
|
|
|
5303
5681
|
};
|
|
5304
5682
|
};
|
|
5305
5683
|
function hu_default() {
|
|
5306
|
-
return { localeError: error$
|
|
5684
|
+
return { localeError: error$31() };
|
|
5307
5685
|
}
|
|
5308
5686
|
//#endregion
|
|
5309
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
5687
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/hy.js
|
|
5310
5688
|
function getArmenianPlural(count, one, many) {
|
|
5311
5689
|
return Math.abs(count) === 1 ? one : many;
|
|
5312
5690
|
}
|
|
@@ -5324,7 +5702,7 @@ function withDefiniteArticle(word) {
|
|
|
5324
5702
|
const lastChar = word[word.length - 1];
|
|
5325
5703
|
return word + (vowels.includes(lastChar) ? "ն" : "ը");
|
|
5326
5704
|
}
|
|
5327
|
-
var error$
|
|
5705
|
+
var error$30 = () => {
|
|
5328
5706
|
const Sizable = {
|
|
5329
5707
|
string: {
|
|
5330
5708
|
unit: {
|
|
@@ -5441,11 +5819,11 @@ var error$29 = () => {
|
|
|
5441
5819
|
};
|
|
5442
5820
|
};
|
|
5443
5821
|
function hy_default() {
|
|
5444
|
-
return { localeError: error$
|
|
5822
|
+
return { localeError: error$30() };
|
|
5445
5823
|
}
|
|
5446
5824
|
//#endregion
|
|
5447
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
5448
|
-
var error$
|
|
5825
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/id.js
|
|
5826
|
+
var error$29 = () => {
|
|
5449
5827
|
const Sizable = {
|
|
5450
5828
|
string: {
|
|
5451
5829
|
unit: "karakter",
|
|
@@ -5540,11 +5918,11 @@ var error$28 = () => {
|
|
|
5540
5918
|
};
|
|
5541
5919
|
};
|
|
5542
5920
|
function id_default() {
|
|
5543
|
-
return { localeError: error$
|
|
5921
|
+
return { localeError: error$29() };
|
|
5544
5922
|
}
|
|
5545
5923
|
//#endregion
|
|
5546
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
5547
|
-
var error$
|
|
5924
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/is.js
|
|
5925
|
+
var error$28 = () => {
|
|
5548
5926
|
const Sizable = {
|
|
5549
5927
|
string: {
|
|
5550
5928
|
unit: "stafi",
|
|
@@ -5643,11 +6021,11 @@ var error$27 = () => {
|
|
|
5643
6021
|
};
|
|
5644
6022
|
};
|
|
5645
6023
|
function is_default() {
|
|
5646
|
-
return { localeError: error$
|
|
6024
|
+
return { localeError: error$28() };
|
|
5647
6025
|
}
|
|
5648
6026
|
//#endregion
|
|
5649
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
5650
|
-
var error$
|
|
6027
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/it.js
|
|
6028
|
+
var error$27 = () => {
|
|
5651
6029
|
const Sizable = {
|
|
5652
6030
|
string: {
|
|
5653
6031
|
unit: "caratteri",
|
|
@@ -5734,7 +6112,7 @@ var error$26 = () => {
|
|
|
5734
6112
|
if (_issue.format === "ends_with") return `Stringa non valida: deve terminare con "${_issue.suffix}"`;
|
|
5735
6113
|
if (_issue.format === "includes") return `Stringa non valida: deve includere "${_issue.includes}"`;
|
|
5736
6114
|
if (_issue.format === "regex") return `Stringa non valida: deve corrispondere al pattern ${_issue.pattern}`;
|
|
5737
|
-
return `
|
|
6115
|
+
return `Input non valido: ${FormatDictionary[_issue.format] ?? issue.format}`;
|
|
5738
6116
|
}
|
|
5739
6117
|
case "not_multiple_of": return `Numero non valido: deve essere un multiplo di ${issue.divisor}`;
|
|
5740
6118
|
case "unrecognized_keys": return `Chiav${issue.keys.length > 1 ? "i" : "e"} non riconosciut${issue.keys.length > 1 ? "e" : "a"}: ${joinValues(issue.keys, ", ")}`;
|
|
@@ -5746,11 +6124,11 @@ var error$26 = () => {
|
|
|
5746
6124
|
};
|
|
5747
6125
|
};
|
|
5748
6126
|
function it_default() {
|
|
5749
|
-
return { localeError: error$
|
|
6127
|
+
return { localeError: error$27() };
|
|
5750
6128
|
}
|
|
5751
6129
|
//#endregion
|
|
5752
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
5753
|
-
var error$
|
|
6130
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/ja.js
|
|
6131
|
+
var error$26 = () => {
|
|
5754
6132
|
const Sizable = {
|
|
5755
6133
|
string: {
|
|
5756
6134
|
unit: "文字",
|
|
@@ -5849,11 +6227,11 @@ var error$25 = () => {
|
|
|
5849
6227
|
};
|
|
5850
6228
|
};
|
|
5851
6229
|
function ja_default() {
|
|
5852
|
-
return { localeError: error$
|
|
6230
|
+
return { localeError: error$26() };
|
|
5853
6231
|
}
|
|
5854
6232
|
//#endregion
|
|
5855
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
5856
|
-
var error$
|
|
6233
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/ka.js
|
|
6234
|
+
var error$25 = () => {
|
|
5857
6235
|
const Sizable = {
|
|
5858
6236
|
string: {
|
|
5859
6237
|
unit: "სიმბოლო",
|
|
@@ -5898,9 +6276,9 @@ var error$24 = () => {
|
|
|
5898
6276
|
ipv6: "IPv6 მისამართი",
|
|
5899
6277
|
cidrv4: "IPv4 დიაპაზონი",
|
|
5900
6278
|
cidrv6: "IPv6 დიაპაზონი",
|
|
5901
|
-
base64: "base64-კოდირებული
|
|
5902
|
-
base64url: "base64url-კოდირებული
|
|
5903
|
-
json_string: "JSON
|
|
6279
|
+
base64: "base64-კოდირებული ველი",
|
|
6280
|
+
base64url: "base64url-კოდირებული ველი",
|
|
6281
|
+
json_string: "JSON ველი",
|
|
5904
6282
|
e164: "E.164 ნომერი",
|
|
5905
6283
|
jwt: "JWT",
|
|
5906
6284
|
template_literal: "შეყვანა"
|
|
@@ -5908,7 +6286,7 @@ var error$24 = () => {
|
|
|
5908
6286
|
const TypeDictionary = {
|
|
5909
6287
|
nan: "NaN",
|
|
5910
6288
|
number: "რიცხვი",
|
|
5911
|
-
string: "
|
|
6289
|
+
string: "ველი",
|
|
5912
6290
|
boolean: "ბულეანი",
|
|
5913
6291
|
function: "ფუნქცია",
|
|
5914
6292
|
array: "მასივი"
|
|
@@ -5939,10 +6317,10 @@ var error$24 = () => {
|
|
|
5939
6317
|
}
|
|
5940
6318
|
case "invalid_format": {
|
|
5941
6319
|
const _issue = issue;
|
|
5942
|
-
if (_issue.format === "starts_with") return `არასწორი
|
|
5943
|
-
if (_issue.format === "ends_with") return `არასწორი
|
|
5944
|
-
if (_issue.format === "includes") return `არასწორი
|
|
5945
|
-
if (_issue.format === "regex") return `არასწორი
|
|
6320
|
+
if (_issue.format === "starts_with") return `არასწორი ველი: უნდა იწყებოდეს "${_issue.prefix}"-ით`;
|
|
6321
|
+
if (_issue.format === "ends_with") return `არასწორი ველი: უნდა მთავრდებოდეს "${_issue.suffix}"-ით`;
|
|
6322
|
+
if (_issue.format === "includes") return `არასწორი ველი: უნდა შეიცავდეს "${_issue.includes}"-ს`;
|
|
6323
|
+
if (_issue.format === "regex") return `არასწორი ველი: უნდა შეესაბამებოდეს შაბლონს ${_issue.pattern}`;
|
|
5946
6324
|
return `არასწორი ${FormatDictionary[_issue.format] ?? issue.format}`;
|
|
5947
6325
|
}
|
|
5948
6326
|
case "not_multiple_of": return `არასწორი რიცხვი: უნდა იყოს ${issue.divisor}-ის ჯერადი`;
|
|
@@ -5955,11 +6333,11 @@ var error$24 = () => {
|
|
|
5955
6333
|
};
|
|
5956
6334
|
};
|
|
5957
6335
|
function ka_default() {
|
|
5958
|
-
return { localeError: error$
|
|
6336
|
+
return { localeError: error$25() };
|
|
5959
6337
|
}
|
|
5960
6338
|
//#endregion
|
|
5961
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
5962
|
-
var error$
|
|
6339
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/km.js
|
|
6340
|
+
var error$24 = () => {
|
|
5963
6341
|
const Sizable = {
|
|
5964
6342
|
string: {
|
|
5965
6343
|
unit: "តួអក្សរ",
|
|
@@ -6059,17 +6437,17 @@ var error$23 = () => {
|
|
|
6059
6437
|
};
|
|
6060
6438
|
};
|
|
6061
6439
|
function km_default() {
|
|
6062
|
-
return { localeError: error$
|
|
6440
|
+
return { localeError: error$24() };
|
|
6063
6441
|
}
|
|
6064
6442
|
//#endregion
|
|
6065
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
6443
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/kh.js
|
|
6066
6444
|
/** @deprecated Use `km` instead. */
|
|
6067
6445
|
function kh_default() {
|
|
6068
6446
|
return km_default();
|
|
6069
6447
|
}
|
|
6070
6448
|
//#endregion
|
|
6071
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
6072
|
-
var error$
|
|
6449
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/ko.js
|
|
6450
|
+
var error$23 = () => {
|
|
6073
6451
|
const Sizable = {
|
|
6074
6452
|
string: {
|
|
6075
6453
|
unit: "문자",
|
|
@@ -6168,10 +6546,10 @@ var error$22 = () => {
|
|
|
6168
6546
|
};
|
|
6169
6547
|
};
|
|
6170
6548
|
function ko_default() {
|
|
6171
|
-
return { localeError: error$
|
|
6549
|
+
return { localeError: error$23() };
|
|
6172
6550
|
}
|
|
6173
6551
|
//#endregion
|
|
6174
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
6552
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/lt.js
|
|
6175
6553
|
var capitalizeFirstCharacter = (text) => {
|
|
6176
6554
|
return text.charAt(0).toUpperCase() + text.slice(1);
|
|
6177
6555
|
};
|
|
@@ -6183,7 +6561,7 @@ function getUnitTypeFromNumber(number) {
|
|
|
6183
6561
|
if (last === 1) return "one";
|
|
6184
6562
|
return "few";
|
|
6185
6563
|
}
|
|
6186
|
-
var error$
|
|
6564
|
+
var error$22 = () => {
|
|
6187
6565
|
const Sizable = {
|
|
6188
6566
|
string: {
|
|
6189
6567
|
unit: {
|
|
@@ -6349,11 +6727,11 @@ var error$21 = () => {
|
|
|
6349
6727
|
};
|
|
6350
6728
|
};
|
|
6351
6729
|
function lt_default() {
|
|
6352
|
-
return { localeError: error$
|
|
6730
|
+
return { localeError: error$22() };
|
|
6353
6731
|
}
|
|
6354
6732
|
//#endregion
|
|
6355
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
6356
|
-
var error$
|
|
6733
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/mk.js
|
|
6734
|
+
var error$21 = () => {
|
|
6357
6735
|
const Sizable = {
|
|
6358
6736
|
string: {
|
|
6359
6737
|
unit: "знаци",
|
|
@@ -6452,11 +6830,11 @@ var error$20 = () => {
|
|
|
6452
6830
|
};
|
|
6453
6831
|
};
|
|
6454
6832
|
function mk_default() {
|
|
6455
|
-
return { localeError: error$
|
|
6833
|
+
return { localeError: error$21() };
|
|
6456
6834
|
}
|
|
6457
6835
|
//#endregion
|
|
6458
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
6459
|
-
var error$
|
|
6836
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/ms.js
|
|
6837
|
+
var error$20 = () => {
|
|
6460
6838
|
const Sizable = {
|
|
6461
6839
|
string: {
|
|
6462
6840
|
unit: "aksara",
|
|
@@ -6554,11 +6932,11 @@ var error$19 = () => {
|
|
|
6554
6932
|
};
|
|
6555
6933
|
};
|
|
6556
6934
|
function ms_default() {
|
|
6557
|
-
return { localeError: error$
|
|
6935
|
+
return { localeError: error$20() };
|
|
6558
6936
|
}
|
|
6559
6937
|
//#endregion
|
|
6560
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
6561
|
-
var error$
|
|
6938
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/nl.js
|
|
6939
|
+
var error$19 = () => {
|
|
6562
6940
|
const Sizable = {
|
|
6563
6941
|
string: {
|
|
6564
6942
|
unit: "tekens",
|
|
@@ -6658,11 +7036,11 @@ var error$18 = () => {
|
|
|
6658
7036
|
};
|
|
6659
7037
|
};
|
|
6660
7038
|
function nl_default() {
|
|
6661
|
-
return { localeError: error$
|
|
7039
|
+
return { localeError: error$19() };
|
|
6662
7040
|
}
|
|
6663
7041
|
//#endregion
|
|
6664
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
6665
|
-
var error$
|
|
7042
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/no.js
|
|
7043
|
+
var error$18 = () => {
|
|
6666
7044
|
const Sizable = {
|
|
6667
7045
|
string: {
|
|
6668
7046
|
unit: "tegn",
|
|
@@ -6761,11 +7139,11 @@ var error$17 = () => {
|
|
|
6761
7139
|
};
|
|
6762
7140
|
};
|
|
6763
7141
|
function no_default() {
|
|
6764
|
-
return { localeError: error$
|
|
7142
|
+
return { localeError: error$18() };
|
|
6765
7143
|
}
|
|
6766
7144
|
//#endregion
|
|
6767
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
6768
|
-
var error$
|
|
7145
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/ota.js
|
|
7146
|
+
var error$17 = () => {
|
|
6769
7147
|
const Sizable = {
|
|
6770
7148
|
string: {
|
|
6771
7149
|
unit: "harf",
|
|
@@ -6865,11 +7243,11 @@ var error$16 = () => {
|
|
|
6865
7243
|
};
|
|
6866
7244
|
};
|
|
6867
7245
|
function ota_default() {
|
|
6868
|
-
return { localeError: error$
|
|
7246
|
+
return { localeError: error$17() };
|
|
6869
7247
|
}
|
|
6870
7248
|
//#endregion
|
|
6871
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
6872
|
-
var error$
|
|
7249
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/ps.js
|
|
7250
|
+
var error$16 = () => {
|
|
6873
7251
|
const Sizable = {
|
|
6874
7252
|
string: {
|
|
6875
7253
|
unit: "توکي",
|
|
@@ -6968,11 +7346,11 @@ var error$15 = () => {
|
|
|
6968
7346
|
};
|
|
6969
7347
|
};
|
|
6970
7348
|
function ps_default() {
|
|
6971
|
-
return { localeError: error$
|
|
7349
|
+
return { localeError: error$16() };
|
|
6972
7350
|
}
|
|
6973
7351
|
//#endregion
|
|
6974
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
6975
|
-
var error$
|
|
7352
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/pl.js
|
|
7353
|
+
var error$15 = () => {
|
|
6976
7354
|
const Sizable = {
|
|
6977
7355
|
string: {
|
|
6978
7356
|
unit: "znaków",
|
|
@@ -7071,11 +7449,11 @@ var error$14 = () => {
|
|
|
7071
7449
|
};
|
|
7072
7450
|
};
|
|
7073
7451
|
function pl_default() {
|
|
7074
|
-
return { localeError: error$
|
|
7452
|
+
return { localeError: error$15() };
|
|
7075
7453
|
}
|
|
7076
7454
|
//#endregion
|
|
7077
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
7078
|
-
var error$
|
|
7455
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/pt.js
|
|
7456
|
+
var error$14 = () => {
|
|
7079
7457
|
const Sizable = {
|
|
7080
7458
|
string: {
|
|
7081
7459
|
unit: "caracteres",
|
|
@@ -7174,10 +7552,127 @@ var error$13 = () => {
|
|
|
7174
7552
|
};
|
|
7175
7553
|
};
|
|
7176
7554
|
function pt_default() {
|
|
7555
|
+
return { localeError: error$14() };
|
|
7556
|
+
}
|
|
7557
|
+
//#endregion
|
|
7558
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/ro.js
|
|
7559
|
+
var error$13 = () => {
|
|
7560
|
+
const Sizable = {
|
|
7561
|
+
string: {
|
|
7562
|
+
unit: "caractere",
|
|
7563
|
+
verb: "să aibă"
|
|
7564
|
+
},
|
|
7565
|
+
file: {
|
|
7566
|
+
unit: "octeți",
|
|
7567
|
+
verb: "să aibă"
|
|
7568
|
+
},
|
|
7569
|
+
array: {
|
|
7570
|
+
unit: "elemente",
|
|
7571
|
+
verb: "să aibă"
|
|
7572
|
+
},
|
|
7573
|
+
set: {
|
|
7574
|
+
unit: "elemente",
|
|
7575
|
+
verb: "să aibă"
|
|
7576
|
+
},
|
|
7577
|
+
map: {
|
|
7578
|
+
unit: "intrări",
|
|
7579
|
+
verb: "să aibă"
|
|
7580
|
+
}
|
|
7581
|
+
};
|
|
7582
|
+
function getSizing(origin) {
|
|
7583
|
+
return Sizable[origin] ?? null;
|
|
7584
|
+
}
|
|
7585
|
+
const FormatDictionary = {
|
|
7586
|
+
regex: "intrare",
|
|
7587
|
+
email: "adresă de email",
|
|
7588
|
+
url: "URL",
|
|
7589
|
+
emoji: "emoji",
|
|
7590
|
+
uuid: "UUID",
|
|
7591
|
+
uuidv4: "UUIDv4",
|
|
7592
|
+
uuidv6: "UUIDv6",
|
|
7593
|
+
nanoid: "nanoid",
|
|
7594
|
+
guid: "GUID",
|
|
7595
|
+
cuid: "cuid",
|
|
7596
|
+
cuid2: "cuid2",
|
|
7597
|
+
ulid: "ULID",
|
|
7598
|
+
xid: "XID",
|
|
7599
|
+
ksuid: "KSUID",
|
|
7600
|
+
datetime: "dată și oră ISO",
|
|
7601
|
+
date: "dată ISO",
|
|
7602
|
+
time: "oră ISO",
|
|
7603
|
+
duration: "durată ISO",
|
|
7604
|
+
ipv4: "adresă IPv4",
|
|
7605
|
+
ipv6: "adresă IPv6",
|
|
7606
|
+
mac: "adresă MAC",
|
|
7607
|
+
cidrv4: "interval IPv4",
|
|
7608
|
+
cidrv6: "interval IPv6",
|
|
7609
|
+
base64: "șir codat base64",
|
|
7610
|
+
base64url: "șir codat base64url",
|
|
7611
|
+
json_string: "șir JSON",
|
|
7612
|
+
e164: "număr E.164",
|
|
7613
|
+
jwt: "JWT",
|
|
7614
|
+
template_literal: "intrare"
|
|
7615
|
+
};
|
|
7616
|
+
const TypeDictionary = {
|
|
7617
|
+
nan: "NaN",
|
|
7618
|
+
string: "șir",
|
|
7619
|
+
number: "număr",
|
|
7620
|
+
boolean: "boolean",
|
|
7621
|
+
function: "funcție",
|
|
7622
|
+
array: "matrice",
|
|
7623
|
+
object: "obiect",
|
|
7624
|
+
undefined: "nedefinit",
|
|
7625
|
+
symbol: "simbol",
|
|
7626
|
+
bigint: "număr mare",
|
|
7627
|
+
void: "void",
|
|
7628
|
+
never: "never",
|
|
7629
|
+
map: "hartă",
|
|
7630
|
+
set: "set"
|
|
7631
|
+
};
|
|
7632
|
+
return (issue) => {
|
|
7633
|
+
switch (issue.code) {
|
|
7634
|
+
case "invalid_type": {
|
|
7635
|
+
const expected = TypeDictionary[issue.expected] ?? issue.expected;
|
|
7636
|
+
const receivedType = parsedType(issue.input);
|
|
7637
|
+
return `Intrare invalidă: așteptat ${expected}, primit ${TypeDictionary[receivedType] ?? receivedType}`;
|
|
7638
|
+
}
|
|
7639
|
+
case "invalid_value":
|
|
7640
|
+
if (issue.values.length === 1) return `Intrare invalidă: așteptat ${stringifyPrimitive(issue.values[0])}`;
|
|
7641
|
+
return `Opțiune invalidă: așteptat una dintre ${joinValues(issue.values, "|")}`;
|
|
7642
|
+
case "too_big": {
|
|
7643
|
+
const adj = issue.inclusive ? "<=" : "<";
|
|
7644
|
+
const sizing = getSizing(issue.origin);
|
|
7645
|
+
if (sizing) return `Prea mare: așteptat ca ${issue.origin ?? "valoarea"} ${sizing.verb} ${adj}${issue.maximum.toString()} ${sizing.unit ?? "elemente"}`;
|
|
7646
|
+
return `Prea mare: așteptat ca ${issue.origin ?? "valoarea"} să fie ${adj}${issue.maximum.toString()}`;
|
|
7647
|
+
}
|
|
7648
|
+
case "too_small": {
|
|
7649
|
+
const adj = issue.inclusive ? ">=" : ">";
|
|
7650
|
+
const sizing = getSizing(issue.origin);
|
|
7651
|
+
if (sizing) return `Prea mic: așteptat ca ${issue.origin} ${sizing.verb} ${adj}${issue.minimum.toString()} ${sizing.unit}`;
|
|
7652
|
+
return `Prea mic: așteptat ca ${issue.origin} să fie ${adj}${issue.minimum.toString()}`;
|
|
7653
|
+
}
|
|
7654
|
+
case "invalid_format": {
|
|
7655
|
+
const _issue = issue;
|
|
7656
|
+
if (_issue.format === "starts_with") return `Șir invalid: trebuie să înceapă cu "${_issue.prefix}"`;
|
|
7657
|
+
if (_issue.format === "ends_with") return `Șir invalid: trebuie să se termine cu "${_issue.suffix}"`;
|
|
7658
|
+
if (_issue.format === "includes") return `Șir invalid: trebuie să includă "${_issue.includes}"`;
|
|
7659
|
+
if (_issue.format === "regex") return `Șir invalid: trebuie să se potrivească cu modelul ${_issue.pattern}`;
|
|
7660
|
+
return `Format invalid: ${FormatDictionary[_issue.format] ?? issue.format}`;
|
|
7661
|
+
}
|
|
7662
|
+
case "not_multiple_of": return `Număr invalid: trebuie să fie multiplu de ${issue.divisor}`;
|
|
7663
|
+
case "unrecognized_keys": return `Chei nerecunoscute: ${joinValues(issue.keys, ", ")}`;
|
|
7664
|
+
case "invalid_key": return `Cheie invalidă în ${issue.origin}`;
|
|
7665
|
+
case "invalid_union": return "Intrare invalidă";
|
|
7666
|
+
case "invalid_element": return `Valoare invalidă în ${issue.origin}`;
|
|
7667
|
+
default: return `Intrare invalidă`;
|
|
7668
|
+
}
|
|
7669
|
+
};
|
|
7670
|
+
};
|
|
7671
|
+
function ro_default() {
|
|
7177
7672
|
return { localeError: error$13() };
|
|
7178
7673
|
}
|
|
7179
7674
|
//#endregion
|
|
7180
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
7675
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/ru.js
|
|
7181
7676
|
function getRussianPlural(count, one, few, many) {
|
|
7182
7677
|
const absCount = Math.abs(count);
|
|
7183
7678
|
const lastDigit = absCount % 10;
|
|
@@ -7311,7 +7806,7 @@ function ru_default() {
|
|
|
7311
7806
|
return { localeError: error$12() };
|
|
7312
7807
|
}
|
|
7313
7808
|
//#endregion
|
|
7314
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
7809
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/sl.js
|
|
7315
7810
|
var error$11 = () => {
|
|
7316
7811
|
const Sizable = {
|
|
7317
7812
|
string: {
|
|
@@ -7414,7 +7909,7 @@ function sl_default() {
|
|
|
7414
7909
|
return { localeError: error$11() };
|
|
7415
7910
|
}
|
|
7416
7911
|
//#endregion
|
|
7417
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
7912
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/sv.js
|
|
7418
7913
|
var error$10 = () => {
|
|
7419
7914
|
const Sizable = {
|
|
7420
7915
|
string: {
|
|
@@ -7517,7 +8012,7 @@ function sv_default() {
|
|
|
7517
8012
|
return { localeError: error$10() };
|
|
7518
8013
|
}
|
|
7519
8014
|
//#endregion
|
|
7520
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
8015
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/ta.js
|
|
7521
8016
|
var error$9 = () => {
|
|
7522
8017
|
const Sizable = {
|
|
7523
8018
|
string: {
|
|
@@ -7621,7 +8116,7 @@ function ta_default() {
|
|
|
7621
8116
|
return { localeError: error$9() };
|
|
7622
8117
|
}
|
|
7623
8118
|
//#endregion
|
|
7624
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
8119
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/th.js
|
|
7625
8120
|
var error$8 = () => {
|
|
7626
8121
|
const Sizable = {
|
|
7627
8122
|
string: {
|
|
@@ -7725,7 +8220,7 @@ function th_default() {
|
|
|
7725
8220
|
return { localeError: error$8() };
|
|
7726
8221
|
}
|
|
7727
8222
|
//#endregion
|
|
7728
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
8223
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/tr.js
|
|
7729
8224
|
var error$7 = () => {
|
|
7730
8225
|
const Sizable = {
|
|
7731
8226
|
string: {
|
|
@@ -7824,7 +8319,7 @@ function tr_default() {
|
|
|
7824
8319
|
return { localeError: error$7() };
|
|
7825
8320
|
}
|
|
7826
8321
|
//#endregion
|
|
7827
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
8322
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/uk.js
|
|
7828
8323
|
var error$6 = () => {
|
|
7829
8324
|
const Sizable = {
|
|
7830
8325
|
string: {
|
|
@@ -7927,13 +8422,13 @@ function uk_default() {
|
|
|
7927
8422
|
return { localeError: error$6() };
|
|
7928
8423
|
}
|
|
7929
8424
|
//#endregion
|
|
7930
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
8425
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/ua.js
|
|
7931
8426
|
/** @deprecated Use `uk` instead. */
|
|
7932
8427
|
function ua_default() {
|
|
7933
8428
|
return uk_default();
|
|
7934
8429
|
}
|
|
7935
8430
|
//#endregion
|
|
7936
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
8431
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/ur.js
|
|
7937
8432
|
var error$5 = () => {
|
|
7938
8433
|
const Sizable = {
|
|
7939
8434
|
string: {
|
|
@@ -8037,7 +8532,7 @@ function ur_default() {
|
|
|
8037
8532
|
return { localeError: error$5() };
|
|
8038
8533
|
}
|
|
8039
8534
|
//#endregion
|
|
8040
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
8535
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/uz.js
|
|
8041
8536
|
var error$4 = () => {
|
|
8042
8537
|
const Sizable = {
|
|
8043
8538
|
string: {
|
|
@@ -8055,6 +8550,10 @@ var error$4 = () => {
|
|
|
8055
8550
|
set: {
|
|
8056
8551
|
unit: "element",
|
|
8057
8552
|
verb: "bo‘lishi kerak"
|
|
8553
|
+
},
|
|
8554
|
+
map: {
|
|
8555
|
+
unit: "yozuv",
|
|
8556
|
+
verb: "bo‘lishi kerak"
|
|
8058
8557
|
}
|
|
8059
8558
|
};
|
|
8060
8559
|
function getSizing(origin) {
|
|
@@ -8141,7 +8640,7 @@ function uz_default() {
|
|
|
8141
8640
|
return { localeError: error$4() };
|
|
8142
8641
|
}
|
|
8143
8642
|
//#endregion
|
|
8144
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
8643
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/vi.js
|
|
8145
8644
|
var error$3 = () => {
|
|
8146
8645
|
const Sizable = {
|
|
8147
8646
|
string: {
|
|
@@ -8244,7 +8743,7 @@ function vi_default() {
|
|
|
8244
8743
|
return { localeError: error$3() };
|
|
8245
8744
|
}
|
|
8246
8745
|
//#endregion
|
|
8247
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
8746
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/zh-CN.js
|
|
8248
8747
|
var error$2 = () => {
|
|
8249
8748
|
const Sizable = {
|
|
8250
8749
|
string: {
|
|
@@ -8348,7 +8847,7 @@ function zh_CN_default() {
|
|
|
8348
8847
|
return { localeError: error$2() };
|
|
8349
8848
|
}
|
|
8350
8849
|
//#endregion
|
|
8351
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
8850
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/zh-TW.js
|
|
8352
8851
|
var error$1 = () => {
|
|
8353
8852
|
const Sizable = {
|
|
8354
8853
|
string: {
|
|
@@ -8447,7 +8946,7 @@ function zh_TW_default() {
|
|
|
8447
8946
|
return { localeError: error$1() };
|
|
8448
8947
|
}
|
|
8449
8948
|
//#endregion
|
|
8450
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
8949
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/yo.js
|
|
8451
8950
|
var error = () => {
|
|
8452
8951
|
const Sizable = {
|
|
8453
8952
|
string: {
|
|
@@ -8550,7 +9049,7 @@ function yo_default() {
|
|
|
8550
9049
|
return { localeError: error() };
|
|
8551
9050
|
}
|
|
8552
9051
|
//#endregion
|
|
8553
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
9052
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/locales/index.js
|
|
8554
9053
|
var locales_exports = /* @__PURE__ */ require_chunk.__exportAll({
|
|
8555
9054
|
ar: () => ar_default,
|
|
8556
9055
|
az: () => az_default,
|
|
@@ -8560,6 +9059,7 @@ var locales_exports = /* @__PURE__ */ require_chunk.__exportAll({
|
|
|
8560
9059
|
cs: () => cs_default,
|
|
8561
9060
|
da: () => da_default,
|
|
8562
9061
|
de: () => de_default,
|
|
9062
|
+
el: () => el_default,
|
|
8563
9063
|
en: () => en_default,
|
|
8564
9064
|
eo: () => eo_default,
|
|
8565
9065
|
es: () => es_default,
|
|
@@ -8568,6 +9068,7 @@ var locales_exports = /* @__PURE__ */ require_chunk.__exportAll({
|
|
|
8568
9068
|
fr: () => fr_default,
|
|
8569
9069
|
frCA: () => fr_CA_default,
|
|
8570
9070
|
he: () => he_default,
|
|
9071
|
+
hr: () => hr_default,
|
|
8571
9072
|
hu: () => hu_default,
|
|
8572
9073
|
hy: () => hy_default,
|
|
8573
9074
|
id: () => id_default,
|
|
@@ -8587,6 +9088,7 @@ var locales_exports = /* @__PURE__ */ require_chunk.__exportAll({
|
|
|
8587
9088
|
pl: () => pl_default,
|
|
8588
9089
|
ps: () => ps_default,
|
|
8589
9090
|
pt: () => pt_default,
|
|
9091
|
+
ro: () => ro_default,
|
|
8590
9092
|
ru: () => ru_default,
|
|
8591
9093
|
sl: () => sl_default,
|
|
8592
9094
|
sv: () => sv_default,
|
|
@@ -8603,7 +9105,7 @@ var locales_exports = /* @__PURE__ */ require_chunk.__exportAll({
|
|
|
8603
9105
|
zhTW: () => zh_TW_default
|
|
8604
9106
|
});
|
|
8605
9107
|
//#endregion
|
|
8606
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
9108
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/core/registries.js
|
|
8607
9109
|
var _a;
|
|
8608
9110
|
var $output = Symbol("ZodOutput");
|
|
8609
9111
|
var $input = Symbol("ZodInput");
|
|
@@ -8652,7 +9154,7 @@ function registry() {
|
|
|
8652
9154
|
(_a = globalThis).__zod_globalRegistry ?? (_a.__zod_globalRegistry = registry());
|
|
8653
9155
|
var globalRegistry = globalThis.__zod_globalRegistry;
|
|
8654
9156
|
//#endregion
|
|
8655
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
9157
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/core/api.js
|
|
8656
9158
|
/* @__NO_SIDE_EFFECTS__ */
|
|
8657
9159
|
function _string(Class, params) {
|
|
8658
9160
|
return new Class({
|
|
@@ -8761,6 +9263,11 @@ function _nanoid(Class, params) {
|
|
|
8761
9263
|
...normalizeParams(params)
|
|
8762
9264
|
});
|
|
8763
9265
|
}
|
|
9266
|
+
/**
|
|
9267
|
+
* @deprecated CUID v1 is deprecated by its authors due to information leakage
|
|
9268
|
+
* (timestamps embedded in the id). Use {@link _cuid2} instead.
|
|
9269
|
+
* See https://github.com/paralleldrive/cuid.
|
|
9270
|
+
*/
|
|
8764
9271
|
/* @__NO_SIDE_EFFECTS__ */
|
|
8765
9272
|
function _cuid(Class, params) {
|
|
8766
9273
|
return new Class({
|
|
@@ -9561,7 +10068,7 @@ function _refine(Class, fn, _params) {
|
|
|
9561
10068
|
});
|
|
9562
10069
|
}
|
|
9563
10070
|
/* @__NO_SIDE_EFFECTS__ */
|
|
9564
|
-
function _superRefine(fn) {
|
|
10071
|
+
function _superRefine(fn, params) {
|
|
9565
10072
|
const ch = /* @__PURE__ */ _check((payload) => {
|
|
9566
10073
|
payload.addIssue = (issue$2) => {
|
|
9567
10074
|
if (typeof issue$2 === "string") payload.issues.push(issue(issue$2, payload.value, ch._zod.def));
|
|
@@ -9576,7 +10083,7 @@ function _superRefine(fn) {
|
|
|
9576
10083
|
}
|
|
9577
10084
|
};
|
|
9578
10085
|
return fn(payload.value, payload);
|
|
9579
|
-
});
|
|
10086
|
+
}, params);
|
|
9580
10087
|
return ch;
|
|
9581
10088
|
}
|
|
9582
10089
|
/* @__NO_SIDE_EFFECTS__ */
|
|
@@ -9691,7 +10198,7 @@ function _stringFormat(Class, format, fnOrRegex, _params = {}) {
|
|
|
9691
10198
|
return new Class(def);
|
|
9692
10199
|
}
|
|
9693
10200
|
//#endregion
|
|
9694
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
10201
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/core/to-json-schema.js
|
|
9695
10202
|
function initializeContext(params) {
|
|
9696
10203
|
let target = params?.target ?? "draft-2020-12";
|
|
9697
10204
|
if (target === "draft-4") target = "draft-04";
|
|
@@ -9757,7 +10264,7 @@ function process(schema, ctx, _params = {
|
|
|
9757
10264
|
delete result.schema.examples;
|
|
9758
10265
|
delete result.schema.default;
|
|
9759
10266
|
}
|
|
9760
|
-
if (ctx.io === "input" && result.schema
|
|
10267
|
+
if (ctx.io === "input" && "_prefault" in result.schema) (_a = result.schema).default ?? (_a.default = result.schema._prefault);
|
|
9761
10268
|
delete result.schema._prefault;
|
|
9762
10269
|
return ctx.seen.get(schema).schema;
|
|
9763
10270
|
}
|
|
@@ -9897,10 +10404,15 @@ function finalize(ctx, schema) {
|
|
|
9897
10404
|
result.$id = ctx.external.uri(id);
|
|
9898
10405
|
}
|
|
9899
10406
|
Object.assign(result, root.def ?? root.schema);
|
|
10407
|
+
const rootMetaId = ctx.metadataRegistry.get(schema)?.id;
|
|
10408
|
+
if (rootMetaId !== void 0 && result.id === rootMetaId) delete result.id;
|
|
9900
10409
|
const defs = ctx.external?.defs ?? {};
|
|
9901
10410
|
for (const entry of ctx.seen.entries()) {
|
|
9902
10411
|
const seen = entry[1];
|
|
9903
|
-
if (seen.def && seen.defId)
|
|
10412
|
+
if (seen.def && seen.defId) {
|
|
10413
|
+
if (seen.def.id === seen.defId) delete seen.def.id;
|
|
10414
|
+
defs[seen.defId] = seen.def;
|
|
10415
|
+
}
|
|
9904
10416
|
}
|
|
9905
10417
|
if (ctx.external) {} else if (Object.keys(defs).length > 0) if (ctx.target === "draft-2020-12") result.$defs = defs;
|
|
9906
10418
|
else result.definitions = defs;
|
|
@@ -9976,7 +10488,7 @@ var createStandardJSONSchemaMethod = (schema, io, processors = {}) => (params) =
|
|
|
9976
10488
|
return finalize(ctx, schema);
|
|
9977
10489
|
};
|
|
9978
10490
|
//#endregion
|
|
9979
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
10491
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/core/json-schema-processors.js
|
|
9980
10492
|
var formatMap = {
|
|
9981
10493
|
guid: "uuid",
|
|
9982
10494
|
url: "uri",
|
|
@@ -10010,24 +10522,19 @@ var numberProcessor = (schema, ctx, _json, _params) => {
|
|
|
10010
10522
|
const { minimum, maximum, format, multipleOf, exclusiveMaximum, exclusiveMinimum } = schema._zod.bag;
|
|
10011
10523
|
if (typeof format === "string" && format.includes("int")) json.type = "integer";
|
|
10012
10524
|
else json.type = "number";
|
|
10013
|
-
|
|
10525
|
+
const exMin = typeof exclusiveMinimum === "number" && exclusiveMinimum >= (minimum ?? Number.NEGATIVE_INFINITY);
|
|
10526
|
+
const exMax = typeof exclusiveMaximum === "number" && exclusiveMaximum <= (maximum ?? Number.POSITIVE_INFINITY);
|
|
10527
|
+
const legacy = ctx.target === "draft-04" || ctx.target === "openapi-3.0";
|
|
10528
|
+
if (exMin) if (legacy) {
|
|
10014
10529
|
json.minimum = exclusiveMinimum;
|
|
10015
10530
|
json.exclusiveMinimum = true;
|
|
10016
10531
|
} else json.exclusiveMinimum = exclusiveMinimum;
|
|
10017
|
-
if (typeof minimum === "number")
|
|
10018
|
-
|
|
10019
|
-
if (typeof exclusiveMinimum === "number" && ctx.target !== "draft-04") if (exclusiveMinimum >= minimum) delete json.minimum;
|
|
10020
|
-
else delete json.exclusiveMinimum;
|
|
10021
|
-
}
|
|
10022
|
-
if (typeof exclusiveMaximum === "number") if (ctx.target === "draft-04" || ctx.target === "openapi-3.0") {
|
|
10532
|
+
else if (typeof minimum === "number") json.minimum = minimum;
|
|
10533
|
+
if (exMax) if (legacy) {
|
|
10023
10534
|
json.maximum = exclusiveMaximum;
|
|
10024
10535
|
json.exclusiveMaximum = true;
|
|
10025
10536
|
} else json.exclusiveMaximum = exclusiveMaximum;
|
|
10026
|
-
if (typeof maximum === "number")
|
|
10027
|
-
json.maximum = maximum;
|
|
10028
|
-
if (typeof exclusiveMaximum === "number" && ctx.target !== "draft-04") if (exclusiveMaximum <= maximum) delete json.maximum;
|
|
10029
|
-
else delete json.exclusiveMaximum;
|
|
10030
|
-
}
|
|
10537
|
+
else if (typeof maximum === "number") json.maximum = maximum;
|
|
10031
10538
|
if (typeof multipleOf === "number") json.multipleOf = multipleOf;
|
|
10032
10539
|
};
|
|
10033
10540
|
var booleanProcessor = (_schema, _ctx, json, _params) => {
|
|
@@ -10432,7 +10939,7 @@ function toJSONSchema(input, params) {
|
|
|
10432
10939
|
return finalize(ctx, input);
|
|
10433
10940
|
}
|
|
10434
10941
|
//#endregion
|
|
10435
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
10942
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/core/json-schema-generator.js
|
|
10436
10943
|
/**
|
|
10437
10944
|
* Legacy class-based interface for JSON Schema generation.
|
|
10438
10945
|
* This class wraps the new functional implementation to provide backward compatibility.
|
|
@@ -10521,10 +11028,10 @@ var JSONSchemaGenerator = class {
|
|
|
10521
11028
|
}
|
|
10522
11029
|
};
|
|
10523
11030
|
//#endregion
|
|
10524
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
11031
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/core/json-schema.js
|
|
10525
11032
|
var json_schema_exports = /* @__PURE__ */ require_chunk.__exportAll({});
|
|
10526
11033
|
//#endregion
|
|
10527
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
11034
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/core/index.js
|
|
10528
11035
|
var core_exports = /* @__PURE__ */ require_chunk.__exportAll({
|
|
10529
11036
|
$ZodAny: () => $ZodAny,
|
|
10530
11037
|
$ZodArray: () => $ZodArray,
|
|
@@ -10801,7 +11308,7 @@ var core_exports = /* @__PURE__ */ require_chunk.__exportAll({
|
|
|
10801
11308
|
version: () => version
|
|
10802
11309
|
});
|
|
10803
11310
|
//#endregion
|
|
10804
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
11311
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/classic/checks.js
|
|
10805
11312
|
var checks_exports = /* @__PURE__ */ require_chunk.__exportAll({
|
|
10806
11313
|
endsWith: () => _endsWith,
|
|
10807
11314
|
gt: () => _gt,
|
|
@@ -10834,7 +11341,7 @@ var checks_exports = /* @__PURE__ */ require_chunk.__exportAll({
|
|
|
10834
11341
|
uppercase: () => _uppercase
|
|
10835
11342
|
});
|
|
10836
11343
|
//#endregion
|
|
10837
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
11344
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/classic/iso.js
|
|
10838
11345
|
var iso_exports = /* @__PURE__ */ require_chunk.__exportAll({
|
|
10839
11346
|
ZodISODate: () => ZodISODate,
|
|
10840
11347
|
ZodISODateTime: () => ZodISODateTime,
|
|
@@ -10874,7 +11381,7 @@ function duration(params) {
|
|
|
10874
11381
|
return /* @__PURE__ */ _isoDuration(ZodISODuration, params);
|
|
10875
11382
|
}
|
|
10876
11383
|
//#endregion
|
|
10877
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
11384
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/classic/errors.js
|
|
10878
11385
|
var initializer = (inst, issues) => {
|
|
10879
11386
|
$ZodError.init(inst, issues);
|
|
10880
11387
|
inst.name = "ZodError";
|
|
@@ -10894,10 +11401,10 @@ var initializer = (inst, issues) => {
|
|
|
10894
11401
|
} }
|
|
10895
11402
|
});
|
|
10896
11403
|
};
|
|
10897
|
-
var ZodError = $constructor("ZodError", initializer);
|
|
10898
|
-
var ZodRealError = $constructor("ZodError", initializer, { Parent: Error });
|
|
11404
|
+
var ZodError = /* @__PURE__ */ $constructor("ZodError", initializer);
|
|
11405
|
+
var ZodRealError = /* @__PURE__ */ $constructor("ZodError", initializer, { Parent: Error });
|
|
10899
11406
|
//#endregion
|
|
10900
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
11407
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/classic/parse.js
|
|
10901
11408
|
var parse = /* @__PURE__ */ _parse(ZodRealError);
|
|
10902
11409
|
var parseAsync = /* @__PURE__ */ _parseAsync(ZodRealError);
|
|
10903
11410
|
var safeParse = /* @__PURE__ */ _safeParse(ZodRealError);
|
|
@@ -10911,7 +11418,7 @@ var safeDecode = /* @__PURE__ */ _safeDecode(ZodRealError);
|
|
|
10911
11418
|
var safeEncodeAsync = /* @__PURE__ */ _safeEncodeAsync(ZodRealError);
|
|
10912
11419
|
var safeDecodeAsync = /* @__PURE__ */ _safeDecodeAsync(ZodRealError);
|
|
10913
11420
|
//#endregion
|
|
10914
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
11421
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/classic/schemas.js
|
|
10915
11422
|
var schemas_exports = /* @__PURE__ */ require_chunk.__exportAll({
|
|
10916
11423
|
ZodAny: () => ZodAny,
|
|
10917
11424
|
ZodArray: () => ZodArray,
|
|
@@ -11020,6 +11527,7 @@ var schemas_exports = /* @__PURE__ */ require_chunk.__exportAll({
|
|
|
11020
11527
|
int32: () => int32,
|
|
11021
11528
|
int64: () => int64,
|
|
11022
11529
|
intersection: () => intersection,
|
|
11530
|
+
invertCodec: () => invertCodec,
|
|
11023
11531
|
ipv4: () => ipv4,
|
|
11024
11532
|
ipv6: () => ipv6,
|
|
11025
11533
|
json: () => json,
|
|
@@ -11078,6 +11586,42 @@ var schemas_exports = /* @__PURE__ */ require_chunk.__exportAll({
|
|
|
11078
11586
|
xid: () => xid,
|
|
11079
11587
|
xor: () => xor
|
|
11080
11588
|
});
|
|
11589
|
+
var _installedGroups = /* @__PURE__ */ new WeakMap();
|
|
11590
|
+
function _installLazyMethods(inst, group, methods) {
|
|
11591
|
+
const proto = Object.getPrototypeOf(inst);
|
|
11592
|
+
let installed = _installedGroups.get(proto);
|
|
11593
|
+
if (!installed) {
|
|
11594
|
+
installed = /* @__PURE__ */ new Set();
|
|
11595
|
+
_installedGroups.set(proto, installed);
|
|
11596
|
+
}
|
|
11597
|
+
if (installed.has(group)) return;
|
|
11598
|
+
installed.add(group);
|
|
11599
|
+
for (const key in methods) {
|
|
11600
|
+
const fn = methods[key];
|
|
11601
|
+
Object.defineProperty(proto, key, {
|
|
11602
|
+
configurable: true,
|
|
11603
|
+
enumerable: false,
|
|
11604
|
+
get() {
|
|
11605
|
+
const bound = fn.bind(this);
|
|
11606
|
+
Object.defineProperty(this, key, {
|
|
11607
|
+
configurable: true,
|
|
11608
|
+
writable: true,
|
|
11609
|
+
enumerable: true,
|
|
11610
|
+
value: bound
|
|
11611
|
+
});
|
|
11612
|
+
return bound;
|
|
11613
|
+
},
|
|
11614
|
+
set(v) {
|
|
11615
|
+
Object.defineProperty(this, key, {
|
|
11616
|
+
configurable: true,
|
|
11617
|
+
writable: true,
|
|
11618
|
+
enumerable: true,
|
|
11619
|
+
value: v
|
|
11620
|
+
});
|
|
11621
|
+
}
|
|
11622
|
+
});
|
|
11623
|
+
}
|
|
11624
|
+
}
|
|
11081
11625
|
var ZodType = /* @__PURE__ */ $constructor("ZodType", (inst, def) => {
|
|
11082
11626
|
$ZodType.init(inst, def);
|
|
11083
11627
|
Object.assign(inst["~standard"], { jsonSchema: {
|
|
@@ -11088,20 +11632,6 @@ var ZodType = /* @__PURE__ */ $constructor("ZodType", (inst, def) => {
|
|
|
11088
11632
|
inst.def = def;
|
|
11089
11633
|
inst.type = def.type;
|
|
11090
11634
|
Object.defineProperty(inst, "_def", { value: def });
|
|
11091
|
-
inst.check = (...checks) => {
|
|
11092
|
-
return inst.clone(mergeDefs(def, { checks: [...def.checks ?? [], ...checks.map((ch) => typeof ch === "function" ? { _zod: {
|
|
11093
|
-
check: ch,
|
|
11094
|
-
def: { check: "custom" },
|
|
11095
|
-
onattach: []
|
|
11096
|
-
} } : ch)] }), { parent: true });
|
|
11097
|
-
};
|
|
11098
|
-
inst.with = inst.check;
|
|
11099
|
-
inst.clone = (def, params) => clone(inst, def, params);
|
|
11100
|
-
inst.brand = () => inst;
|
|
11101
|
-
inst.register = ((reg, meta) => {
|
|
11102
|
-
reg.add(inst, meta);
|
|
11103
|
-
return inst;
|
|
11104
|
-
});
|
|
11105
11635
|
inst.parse = (data, params) => parse(inst, data, params, { callee: inst.parse });
|
|
11106
11636
|
inst.safeParse = (data, params) => safeParse(inst, data, params);
|
|
11107
11637
|
inst.parseAsync = async (data, params) => parseAsync(inst, data, params, { callee: inst.parseAsync });
|
|
@@ -11115,43 +11645,106 @@ var ZodType = /* @__PURE__ */ $constructor("ZodType", (inst, def) => {
|
|
|
11115
11645
|
inst.safeDecode = (data, params) => safeDecode(inst, data, params);
|
|
11116
11646
|
inst.safeEncodeAsync = async (data, params) => safeEncodeAsync(inst, data, params);
|
|
11117
11647
|
inst.safeDecodeAsync = async (data, params) => safeDecodeAsync(inst, data, params);
|
|
11118
|
-
inst
|
|
11119
|
-
|
|
11120
|
-
|
|
11121
|
-
|
|
11122
|
-
|
|
11123
|
-
|
|
11124
|
-
|
|
11125
|
-
|
|
11126
|
-
|
|
11127
|
-
|
|
11128
|
-
|
|
11129
|
-
|
|
11130
|
-
|
|
11131
|
-
|
|
11132
|
-
|
|
11133
|
-
|
|
11134
|
-
|
|
11135
|
-
|
|
11136
|
-
|
|
11137
|
-
|
|
11138
|
-
|
|
11139
|
-
|
|
11648
|
+
_installLazyMethods(inst, "ZodType", {
|
|
11649
|
+
check(...chks) {
|
|
11650
|
+
const def = this.def;
|
|
11651
|
+
return this.clone(mergeDefs(def, { checks: [...def.checks ?? [], ...chks.map((ch) => typeof ch === "function" ? { _zod: {
|
|
11652
|
+
check: ch,
|
|
11653
|
+
def: { check: "custom" },
|
|
11654
|
+
onattach: []
|
|
11655
|
+
} } : ch)] }), { parent: true });
|
|
11656
|
+
},
|
|
11657
|
+
with(...chks) {
|
|
11658
|
+
return this.check(...chks);
|
|
11659
|
+
},
|
|
11660
|
+
clone(def, params) {
|
|
11661
|
+
return clone(this, def, params);
|
|
11662
|
+
},
|
|
11663
|
+
brand() {
|
|
11664
|
+
return this;
|
|
11665
|
+
},
|
|
11666
|
+
register(reg, meta) {
|
|
11667
|
+
reg.add(this, meta);
|
|
11668
|
+
return this;
|
|
11669
|
+
},
|
|
11670
|
+
refine(check, params) {
|
|
11671
|
+
return this.check(refine(check, params));
|
|
11672
|
+
},
|
|
11673
|
+
superRefine(refinement, params) {
|
|
11674
|
+
return this.check(superRefine(refinement, params));
|
|
11675
|
+
},
|
|
11676
|
+
overwrite(fn) {
|
|
11677
|
+
return this.check(/* @__PURE__ */ _overwrite(fn));
|
|
11678
|
+
},
|
|
11679
|
+
optional() {
|
|
11680
|
+
return optional(this);
|
|
11681
|
+
},
|
|
11682
|
+
exactOptional() {
|
|
11683
|
+
return exactOptional(this);
|
|
11684
|
+
},
|
|
11685
|
+
nullable() {
|
|
11686
|
+
return nullable(this);
|
|
11687
|
+
},
|
|
11688
|
+
nullish() {
|
|
11689
|
+
return optional(nullable(this));
|
|
11690
|
+
},
|
|
11691
|
+
nonoptional(params) {
|
|
11692
|
+
return nonoptional(this, params);
|
|
11693
|
+
},
|
|
11694
|
+
array() {
|
|
11695
|
+
return array(this);
|
|
11696
|
+
},
|
|
11697
|
+
or(arg) {
|
|
11698
|
+
return union([this, arg]);
|
|
11699
|
+
},
|
|
11700
|
+
and(arg) {
|
|
11701
|
+
return intersection(this, arg);
|
|
11702
|
+
},
|
|
11703
|
+
transform(tx) {
|
|
11704
|
+
return pipe(this, transform(tx));
|
|
11705
|
+
},
|
|
11706
|
+
default(d) {
|
|
11707
|
+
return _default(this, d);
|
|
11708
|
+
},
|
|
11709
|
+
prefault(d) {
|
|
11710
|
+
return prefault(this, d);
|
|
11711
|
+
},
|
|
11712
|
+
catch(params) {
|
|
11713
|
+
return _catch(this, params);
|
|
11714
|
+
},
|
|
11715
|
+
pipe(target) {
|
|
11716
|
+
return pipe(this, target);
|
|
11717
|
+
},
|
|
11718
|
+
readonly() {
|
|
11719
|
+
return readonly(this);
|
|
11720
|
+
},
|
|
11721
|
+
describe(description) {
|
|
11722
|
+
const cl = this.clone();
|
|
11723
|
+
globalRegistry.add(cl, { description });
|
|
11724
|
+
return cl;
|
|
11725
|
+
},
|
|
11726
|
+
meta(...args) {
|
|
11727
|
+
if (args.length === 0) return globalRegistry.get(this);
|
|
11728
|
+
const cl = this.clone();
|
|
11729
|
+
globalRegistry.add(cl, args[0]);
|
|
11730
|
+
return cl;
|
|
11731
|
+
},
|
|
11732
|
+
isOptional() {
|
|
11733
|
+
return this.safeParse(void 0).success;
|
|
11734
|
+
},
|
|
11735
|
+
isNullable() {
|
|
11736
|
+
return this.safeParse(null).success;
|
|
11737
|
+
},
|
|
11738
|
+
apply(fn) {
|
|
11739
|
+
return fn(this);
|
|
11740
|
+
}
|
|
11741
|
+
});
|
|
11140
11742
|
Object.defineProperty(inst, "description", {
|
|
11141
11743
|
get() {
|
|
11142
11744
|
return globalRegistry.get(inst)?.description;
|
|
11143
11745
|
},
|
|
11144
11746
|
configurable: true
|
|
11145
11747
|
});
|
|
11146
|
-
inst.meta = (...args) => {
|
|
11147
|
-
if (args.length === 0) return globalRegistry.get(inst);
|
|
11148
|
-
const cl = inst.clone();
|
|
11149
|
-
globalRegistry.add(cl, args[0]);
|
|
11150
|
-
return cl;
|
|
11151
|
-
};
|
|
11152
|
-
inst.isOptional = () => inst.safeParse(void 0).success;
|
|
11153
|
-
inst.isNullable = () => inst.safeParse(null).success;
|
|
11154
|
-
inst.apply = (fn) => fn(inst);
|
|
11155
11748
|
return inst;
|
|
11156
11749
|
});
|
|
11157
11750
|
/** @internal */
|
|
@@ -11163,21 +11756,53 @@ var _ZodString = /* @__PURE__ */ $constructor("_ZodString", (inst, def) => {
|
|
|
11163
11756
|
inst.format = bag.format ?? null;
|
|
11164
11757
|
inst.minLength = bag.minimum ?? null;
|
|
11165
11758
|
inst.maxLength = bag.maximum ?? null;
|
|
11166
|
-
|
|
11167
|
-
|
|
11168
|
-
|
|
11169
|
-
|
|
11170
|
-
|
|
11171
|
-
|
|
11172
|
-
|
|
11173
|
-
|
|
11174
|
-
|
|
11175
|
-
|
|
11176
|
-
|
|
11177
|
-
|
|
11178
|
-
|
|
11179
|
-
|
|
11180
|
-
|
|
11759
|
+
_installLazyMethods(inst, "_ZodString", {
|
|
11760
|
+
regex(...args) {
|
|
11761
|
+
return this.check(/* @__PURE__ */ _regex(...args));
|
|
11762
|
+
},
|
|
11763
|
+
includes(...args) {
|
|
11764
|
+
return this.check(/* @__PURE__ */ _includes(...args));
|
|
11765
|
+
},
|
|
11766
|
+
startsWith(...args) {
|
|
11767
|
+
return this.check(/* @__PURE__ */ _startsWith(...args));
|
|
11768
|
+
},
|
|
11769
|
+
endsWith(...args) {
|
|
11770
|
+
return this.check(/* @__PURE__ */ _endsWith(...args));
|
|
11771
|
+
},
|
|
11772
|
+
min(...args) {
|
|
11773
|
+
return this.check(/* @__PURE__ */ _minLength(...args));
|
|
11774
|
+
},
|
|
11775
|
+
max(...args) {
|
|
11776
|
+
return this.check(/* @__PURE__ */ _maxLength(...args));
|
|
11777
|
+
},
|
|
11778
|
+
length(...args) {
|
|
11779
|
+
return this.check(/* @__PURE__ */ _length(...args));
|
|
11780
|
+
},
|
|
11781
|
+
nonempty(...args) {
|
|
11782
|
+
return this.check(/* @__PURE__ */ _minLength(1, ...args));
|
|
11783
|
+
},
|
|
11784
|
+
lowercase(params) {
|
|
11785
|
+
return this.check(/* @__PURE__ */ _lowercase(params));
|
|
11786
|
+
},
|
|
11787
|
+
uppercase(params) {
|
|
11788
|
+
return this.check(/* @__PURE__ */ _uppercase(params));
|
|
11789
|
+
},
|
|
11790
|
+
trim() {
|
|
11791
|
+
return this.check(/* @__PURE__ */ _trim());
|
|
11792
|
+
},
|
|
11793
|
+
normalize(...args) {
|
|
11794
|
+
return this.check(/* @__PURE__ */ _normalize(...args));
|
|
11795
|
+
},
|
|
11796
|
+
toLowerCase() {
|
|
11797
|
+
return this.check(/* @__PURE__ */ _toLowerCase());
|
|
11798
|
+
},
|
|
11799
|
+
toUpperCase() {
|
|
11800
|
+
return this.check(/* @__PURE__ */ _toUpperCase());
|
|
11801
|
+
},
|
|
11802
|
+
slugify() {
|
|
11803
|
+
return this.check(/* @__PURE__ */ _slugify());
|
|
11804
|
+
}
|
|
11805
|
+
});
|
|
11181
11806
|
});
|
|
11182
11807
|
var ZodString = /* @__PURE__ */ $constructor("ZodString", (inst, def) => {
|
|
11183
11808
|
$ZodString.init(inst, def);
|
|
@@ -11256,7 +11881,7 @@ function url(params) {
|
|
|
11256
11881
|
}
|
|
11257
11882
|
function httpUrl(params) {
|
|
11258
11883
|
return /* @__PURE__ */ _url(ZodURL, {
|
|
11259
|
-
protocol:
|
|
11884
|
+
protocol: httpProtocol,
|
|
11260
11885
|
hostname: domain,
|
|
11261
11886
|
...normalizeParams(params)
|
|
11262
11887
|
});
|
|
@@ -11275,10 +11900,22 @@ var ZodNanoID = /* @__PURE__ */ $constructor("ZodNanoID", (inst, def) => {
|
|
|
11275
11900
|
function nanoid(params) {
|
|
11276
11901
|
return /* @__PURE__ */ _nanoid(ZodNanoID, params);
|
|
11277
11902
|
}
|
|
11903
|
+
/**
|
|
11904
|
+
* @deprecated CUID v1 is deprecated by its authors due to information leakage
|
|
11905
|
+
* (timestamps embedded in the id). Use {@link ZodCUID2} instead.
|
|
11906
|
+
* See https://github.com/paralleldrive/cuid.
|
|
11907
|
+
*/
|
|
11278
11908
|
var ZodCUID = /* @__PURE__ */ $constructor("ZodCUID", (inst, def) => {
|
|
11279
11909
|
$ZodCUID.init(inst, def);
|
|
11280
11910
|
ZodStringFormat.init(inst, def);
|
|
11281
11911
|
});
|
|
11912
|
+
/**
|
|
11913
|
+
* Validates a CUID v1 string.
|
|
11914
|
+
*
|
|
11915
|
+
* @deprecated CUID v1 is deprecated by its authors due to information leakage
|
|
11916
|
+
* (timestamps embedded in the id). Use {@link cuid2 | `z.cuid2()`} instead.
|
|
11917
|
+
* See https://github.com/paralleldrive/cuid.
|
|
11918
|
+
*/
|
|
11282
11919
|
function cuid(params) {
|
|
11283
11920
|
return /* @__PURE__ */ _cuid(ZodCUID, params);
|
|
11284
11921
|
}
|
|
@@ -11396,21 +12033,53 @@ var ZodNumber = /* @__PURE__ */ $constructor("ZodNumber", (inst, def) => {
|
|
|
11396
12033
|
$ZodNumber.init(inst, def);
|
|
11397
12034
|
ZodType.init(inst, def);
|
|
11398
12035
|
inst._zod.processJSONSchema = (ctx, json, params) => numberProcessor(inst, ctx, json, params);
|
|
11399
|
-
inst
|
|
11400
|
-
|
|
11401
|
-
|
|
11402
|
-
|
|
11403
|
-
|
|
11404
|
-
|
|
11405
|
-
|
|
11406
|
-
|
|
11407
|
-
|
|
11408
|
-
|
|
11409
|
-
|
|
11410
|
-
|
|
11411
|
-
|
|
11412
|
-
|
|
11413
|
-
|
|
12036
|
+
_installLazyMethods(inst, "ZodNumber", {
|
|
12037
|
+
gt(value, params) {
|
|
12038
|
+
return this.check(/* @__PURE__ */ _gt(value, params));
|
|
12039
|
+
},
|
|
12040
|
+
gte(value, params) {
|
|
12041
|
+
return this.check(/* @__PURE__ */ _gte(value, params));
|
|
12042
|
+
},
|
|
12043
|
+
min(value, params) {
|
|
12044
|
+
return this.check(/* @__PURE__ */ _gte(value, params));
|
|
12045
|
+
},
|
|
12046
|
+
lt(value, params) {
|
|
12047
|
+
return this.check(/* @__PURE__ */ _lt(value, params));
|
|
12048
|
+
},
|
|
12049
|
+
lte(value, params) {
|
|
12050
|
+
return this.check(/* @__PURE__ */ _lte(value, params));
|
|
12051
|
+
},
|
|
12052
|
+
max(value, params) {
|
|
12053
|
+
return this.check(/* @__PURE__ */ _lte(value, params));
|
|
12054
|
+
},
|
|
12055
|
+
int(params) {
|
|
12056
|
+
return this.check(int(params));
|
|
12057
|
+
},
|
|
12058
|
+
safe(params) {
|
|
12059
|
+
return this.check(int(params));
|
|
12060
|
+
},
|
|
12061
|
+
positive(params) {
|
|
12062
|
+
return this.check(/* @__PURE__ */ _gt(0, params));
|
|
12063
|
+
},
|
|
12064
|
+
nonnegative(params) {
|
|
12065
|
+
return this.check(/* @__PURE__ */ _gte(0, params));
|
|
12066
|
+
},
|
|
12067
|
+
negative(params) {
|
|
12068
|
+
return this.check(/* @__PURE__ */ _lt(0, params));
|
|
12069
|
+
},
|
|
12070
|
+
nonpositive(params) {
|
|
12071
|
+
return this.check(/* @__PURE__ */ _lte(0, params));
|
|
12072
|
+
},
|
|
12073
|
+
multipleOf(value, params) {
|
|
12074
|
+
return this.check(/* @__PURE__ */ _multipleOf(value, params));
|
|
12075
|
+
},
|
|
12076
|
+
step(value, params) {
|
|
12077
|
+
return this.check(/* @__PURE__ */ _multipleOf(value, params));
|
|
12078
|
+
},
|
|
12079
|
+
finite() {
|
|
12080
|
+
return this;
|
|
12081
|
+
}
|
|
12082
|
+
});
|
|
11414
12083
|
const bag = inst._zod.bag;
|
|
11415
12084
|
inst.minValue = Math.max(bag.minimum ?? Number.NEGATIVE_INFINITY, bag.exclusiveMinimum ?? Number.NEGATIVE_INFINITY) ?? null;
|
|
11416
12085
|
inst.maxValue = Math.min(bag.maximum ?? Number.POSITIVE_INFINITY, bag.exclusiveMaximum ?? Number.POSITIVE_INFINITY) ?? null;
|
|
@@ -11557,11 +12226,23 @@ var ZodArray = /* @__PURE__ */ $constructor("ZodArray", (inst, def) => {
|
|
|
11557
12226
|
ZodType.init(inst, def);
|
|
11558
12227
|
inst._zod.processJSONSchema = (ctx, json, params) => arrayProcessor(inst, ctx, json, params);
|
|
11559
12228
|
inst.element = def.element;
|
|
11560
|
-
inst
|
|
11561
|
-
|
|
11562
|
-
|
|
11563
|
-
|
|
11564
|
-
|
|
12229
|
+
_installLazyMethods(inst, "ZodArray", {
|
|
12230
|
+
min(n, params) {
|
|
12231
|
+
return this.check(/* @__PURE__ */ _minLength(n, params));
|
|
12232
|
+
},
|
|
12233
|
+
nonempty(params) {
|
|
12234
|
+
return this.check(/* @__PURE__ */ _minLength(1, params));
|
|
12235
|
+
},
|
|
12236
|
+
max(n, params) {
|
|
12237
|
+
return this.check(/* @__PURE__ */ _maxLength(n, params));
|
|
12238
|
+
},
|
|
12239
|
+
length(n, params) {
|
|
12240
|
+
return this.check(/* @__PURE__ */ _length(n, params));
|
|
12241
|
+
},
|
|
12242
|
+
unwrap() {
|
|
12243
|
+
return this.element;
|
|
12244
|
+
}
|
|
12245
|
+
});
|
|
11565
12246
|
});
|
|
11566
12247
|
function array(element, params) {
|
|
11567
12248
|
return /* @__PURE__ */ _array(ZodArray, element, params);
|
|
@@ -11577,38 +12258,62 @@ var ZodObject = /* @__PURE__ */ $constructor("ZodObject", (inst, def) => {
|
|
|
11577
12258
|
defineLazy(inst, "shape", () => {
|
|
11578
12259
|
return def.shape;
|
|
11579
12260
|
});
|
|
11580
|
-
inst
|
|
11581
|
-
|
|
11582
|
-
|
|
11583
|
-
|
|
11584
|
-
|
|
11585
|
-
|
|
11586
|
-
|
|
11587
|
-
|
|
11588
|
-
|
|
11589
|
-
|
|
11590
|
-
|
|
11591
|
-
|
|
11592
|
-
|
|
11593
|
-
|
|
11594
|
-
|
|
11595
|
-
|
|
11596
|
-
|
|
11597
|
-
|
|
11598
|
-
|
|
11599
|
-
|
|
12261
|
+
_installLazyMethods(inst, "ZodObject", {
|
|
12262
|
+
keyof() {
|
|
12263
|
+
return _enum(Object.keys(this._zod.def.shape));
|
|
12264
|
+
},
|
|
12265
|
+
catchall(catchall) {
|
|
12266
|
+
return this.clone({
|
|
12267
|
+
...this._zod.def,
|
|
12268
|
+
catchall
|
|
12269
|
+
});
|
|
12270
|
+
},
|
|
12271
|
+
passthrough() {
|
|
12272
|
+
return this.clone({
|
|
12273
|
+
...this._zod.def,
|
|
12274
|
+
catchall: unknown()
|
|
12275
|
+
});
|
|
12276
|
+
},
|
|
12277
|
+
loose() {
|
|
12278
|
+
return this.clone({
|
|
12279
|
+
...this._zod.def,
|
|
12280
|
+
catchall: unknown()
|
|
12281
|
+
});
|
|
12282
|
+
},
|
|
12283
|
+
strict() {
|
|
12284
|
+
return this.clone({
|
|
12285
|
+
...this._zod.def,
|
|
12286
|
+
catchall: never()
|
|
12287
|
+
});
|
|
12288
|
+
},
|
|
12289
|
+
strip() {
|
|
12290
|
+
return this.clone({
|
|
12291
|
+
...this._zod.def,
|
|
12292
|
+
catchall: void 0
|
|
12293
|
+
});
|
|
12294
|
+
},
|
|
12295
|
+
extend(incoming) {
|
|
12296
|
+
return extend(this, incoming);
|
|
12297
|
+
},
|
|
12298
|
+
safeExtend(incoming) {
|
|
12299
|
+
return safeExtend(this, incoming);
|
|
12300
|
+
},
|
|
12301
|
+
merge(other) {
|
|
12302
|
+
return merge(this, other);
|
|
12303
|
+
},
|
|
12304
|
+
pick(mask) {
|
|
12305
|
+
return pick(this, mask);
|
|
12306
|
+
},
|
|
12307
|
+
omit(mask) {
|
|
12308
|
+
return omit(this, mask);
|
|
12309
|
+
},
|
|
12310
|
+
partial(...args) {
|
|
12311
|
+
return partial(ZodOptional, this, args[0]);
|
|
12312
|
+
},
|
|
12313
|
+
required(...args) {
|
|
12314
|
+
return required(ZodNonOptional, this, args[0]);
|
|
12315
|
+
}
|
|
11600
12316
|
});
|
|
11601
|
-
inst.extend = (incoming) => {
|
|
11602
|
-
return extend(inst, incoming);
|
|
11603
|
-
};
|
|
11604
|
-
inst.safeExtend = (incoming) => {
|
|
11605
|
-
return safeExtend(inst, incoming);
|
|
11606
|
-
};
|
|
11607
|
-
inst.merge = (other) => merge(inst, other);
|
|
11608
|
-
inst.pick = (mask) => pick(inst, mask);
|
|
11609
|
-
inst.omit = (mask) => omit(inst, mask);
|
|
11610
|
-
inst.partial = (...args) => partial(ZodOptional, inst, args[0]);
|
|
11611
|
-
inst.required = (...args) => required(ZodNonOptional, inst, args[0]);
|
|
11612
12317
|
});
|
|
11613
12318
|
function object(shape, params) {
|
|
11614
12319
|
return new ZodObject({
|
|
@@ -11713,6 +12418,12 @@ var ZodRecord = /* @__PURE__ */ $constructor("ZodRecord", (inst, def) => {
|
|
|
11713
12418
|
inst.valueType = def.valueType;
|
|
11714
12419
|
});
|
|
11715
12420
|
function record(keyType, valueType, params) {
|
|
12421
|
+
if (!valueType || !valueType._zod) return new ZodRecord({
|
|
12422
|
+
type: "record",
|
|
12423
|
+
keyType: string$1(),
|
|
12424
|
+
valueType: keyType,
|
|
12425
|
+
...normalizeParams(valueType)
|
|
12426
|
+
});
|
|
11716
12427
|
return new ZodRecord({
|
|
11717
12428
|
type: "record",
|
|
11718
12429
|
keyType,
|
|
@@ -12029,6 +12740,16 @@ function codec(in_, out, params) {
|
|
|
12029
12740
|
reverseTransform: params.encode
|
|
12030
12741
|
});
|
|
12031
12742
|
}
|
|
12743
|
+
function invertCodec(codec) {
|
|
12744
|
+
const def = codec._zod.def;
|
|
12745
|
+
return new ZodCodec({
|
|
12746
|
+
type: "pipe",
|
|
12747
|
+
in: def.out,
|
|
12748
|
+
out: def.in,
|
|
12749
|
+
transform: def.reverseTransform,
|
|
12750
|
+
reverseTransform: def.transform
|
|
12751
|
+
});
|
|
12752
|
+
}
|
|
12032
12753
|
var ZodReadonly = /* @__PURE__ */ $constructor("ZodReadonly", (inst, def) => {
|
|
12033
12754
|
$ZodReadonly.init(inst, def);
|
|
12034
12755
|
ZodType.init(inst, def);
|
|
@@ -12105,8 +12826,8 @@ function custom(fn, _params) {
|
|
|
12105
12826
|
function refine(fn, _params = {}) {
|
|
12106
12827
|
return /* @__PURE__ */ _refine(ZodCustom, fn, _params);
|
|
12107
12828
|
}
|
|
12108
|
-
function superRefine(fn) {
|
|
12109
|
-
return /* @__PURE__ */ _superRefine(fn);
|
|
12829
|
+
function superRefine(fn, params) {
|
|
12830
|
+
return /* @__PURE__ */ _superRefine(fn, params);
|
|
12110
12831
|
}
|
|
12111
12832
|
var describe = describe$1;
|
|
12112
12833
|
var meta = meta$1;
|
|
@@ -12152,7 +12873,7 @@ function preprocess(fn, schema) {
|
|
|
12152
12873
|
return pipe(transform(fn), schema);
|
|
12153
12874
|
}
|
|
12154
12875
|
//#endregion
|
|
12155
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
12876
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/classic/compat.js
|
|
12156
12877
|
/** @deprecated Use the raw string literal codes instead, e.g. "invalid_type". */
|
|
12157
12878
|
var ZodIssueCode = {
|
|
12158
12879
|
invalid_type: "invalid_type",
|
|
@@ -12179,13 +12900,13 @@ function getErrorMap() {
|
|
|
12179
12900
|
var ZodFirstPartyTypeKind;
|
|
12180
12901
|
(function(ZodFirstPartyTypeKind) {})(ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {}));
|
|
12181
12902
|
//#endregion
|
|
12182
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
12903
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/classic/from-json-schema.js
|
|
12183
12904
|
var z = {
|
|
12184
12905
|
...schemas_exports,
|
|
12185
12906
|
...checks_exports,
|
|
12186
12907
|
iso: iso_exports
|
|
12187
12908
|
};
|
|
12188
|
-
var RECOGNIZED_KEYS = new Set([
|
|
12909
|
+
var RECOGNIZED_KEYS = /* @__PURE__ */ new Set([
|
|
12189
12910
|
"$schema",
|
|
12190
12911
|
"$ref",
|
|
12191
12912
|
"$defs",
|
|
@@ -12443,8 +13164,6 @@ function convertBaseSchema(schema, ctx) {
|
|
|
12443
13164
|
}
|
|
12444
13165
|
default: throw new Error(`Unsupported type: ${type}`);
|
|
12445
13166
|
}
|
|
12446
|
-
if (schema.description) zodSchema = zodSchema.describe(schema.description);
|
|
12447
|
-
if (schema.default !== void 0) zodSchema = zodSchema.default(schema.default);
|
|
12448
13167
|
return zodSchema;
|
|
12449
13168
|
}
|
|
12450
13169
|
function convertSchema(schema, ctx) {
|
|
@@ -12470,6 +13189,7 @@ function convertSchema(schema, ctx) {
|
|
|
12470
13189
|
}
|
|
12471
13190
|
if (schema.nullable === true && ctx.version === "openapi-3.0") baseSchema = z.nullable(baseSchema);
|
|
12472
13191
|
if (schema.readOnly === true) baseSchema = z.readonly(baseSchema);
|
|
13192
|
+
if (schema.default !== void 0) baseSchema = baseSchema.default(schema.default);
|
|
12473
13193
|
const extraMeta = {};
|
|
12474
13194
|
for (const key of [
|
|
12475
13195
|
"$id",
|
|
@@ -12487,23 +13207,31 @@ function convertSchema(schema, ctx) {
|
|
|
12487
13207
|
]) if (key in schema) extraMeta[key] = schema[key];
|
|
12488
13208
|
for (const key of Object.keys(schema)) if (!RECOGNIZED_KEYS.has(key)) extraMeta[key] = schema[key];
|
|
12489
13209
|
if (Object.keys(extraMeta).length > 0) ctx.registry.add(baseSchema, extraMeta);
|
|
13210
|
+
if (schema.description) baseSchema = baseSchema.describe(schema.description);
|
|
12490
13211
|
return baseSchema;
|
|
12491
13212
|
}
|
|
12492
13213
|
/**
|
|
12493
13214
|
* Converts a JSON Schema to a Zod schema. This function should be considered semi-experimental. It's behavior is liable to change. */
|
|
12494
13215
|
function fromJSONSchema(schema, params) {
|
|
12495
13216
|
if (typeof schema === "boolean") return schema ? z.any() : z.never();
|
|
12496
|
-
|
|
12497
|
-
|
|
12498
|
-
|
|
13217
|
+
let normalized;
|
|
13218
|
+
try {
|
|
13219
|
+
normalized = JSON.parse(JSON.stringify(schema));
|
|
13220
|
+
} catch {
|
|
13221
|
+
throw new Error("fromJSONSchema input is not valid JSON (possibly cyclic); use $defs/$ref for recursive schemas");
|
|
13222
|
+
}
|
|
13223
|
+
const ctx = {
|
|
13224
|
+
version: detectVersion(normalized, params?.defaultTarget),
|
|
13225
|
+
defs: normalized.$defs || normalized.definitions || {},
|
|
12499
13226
|
refs: /* @__PURE__ */ new Map(),
|
|
12500
13227
|
processing: /* @__PURE__ */ new Set(),
|
|
12501
|
-
rootSchema:
|
|
13228
|
+
rootSchema: normalized,
|
|
12502
13229
|
registry: params?.registry ?? globalRegistry
|
|
12503
|
-
}
|
|
13230
|
+
};
|
|
13231
|
+
return convertSchema(normalized, ctx);
|
|
12504
13232
|
}
|
|
12505
13233
|
//#endregion
|
|
12506
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
13234
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/classic/coerce.js
|
|
12507
13235
|
var coerce_exports = /* @__PURE__ */ require_chunk.__exportAll({
|
|
12508
13236
|
bigint: () => bigint,
|
|
12509
13237
|
boolean: () => boolean,
|
|
@@ -12527,7 +13255,7 @@ function date(params) {
|
|
|
12527
13255
|
return /* @__PURE__ */ _coercedDate(ZodDate, params);
|
|
12528
13256
|
}
|
|
12529
13257
|
//#endregion
|
|
12530
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
13258
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/classic/external.js
|
|
12531
13259
|
var external_exports = /* @__PURE__ */ require_chunk.__exportAll({
|
|
12532
13260
|
$brand: () => $brand,
|
|
12533
13261
|
$input: () => $input,
|
|
@@ -12666,6 +13394,7 @@ var external_exports = /* @__PURE__ */ require_chunk.__exportAll({
|
|
|
12666
13394
|
int32: () => int32,
|
|
12667
13395
|
int64: () => int64,
|
|
12668
13396
|
intersection: () => intersection,
|
|
13397
|
+
invertCodec: () => invertCodec,
|
|
12669
13398
|
ipv4: () => ipv4,
|
|
12670
13399
|
ipv6: () => ipv6,
|
|
12671
13400
|
iso: () => iso_exports,
|
|
@@ -12768,7 +13497,7 @@ var external_exports = /* @__PURE__ */ require_chunk.__exportAll({
|
|
|
12768
13497
|
});
|
|
12769
13498
|
config(en_default());
|
|
12770
13499
|
//#endregion
|
|
12771
|
-
//#region ../../node_modules/.pnpm/zod@4.
|
|
13500
|
+
//#region ../../node_modules/.pnpm/zod@4.4.1/node_modules/zod/v4/index.js
|
|
12772
13501
|
var v4_exports = /* @__PURE__ */ require_chunk.__exportAll({
|
|
12773
13502
|
$brand: () => $brand,
|
|
12774
13503
|
$input: () => $input,
|
|
@@ -12907,6 +13636,7 @@ var v4_exports = /* @__PURE__ */ require_chunk.__exportAll({
|
|
|
12907
13636
|
int32: () => int32,
|
|
12908
13637
|
int64: () => int64,
|
|
12909
13638
|
intersection: () => intersection,
|
|
13639
|
+
invertCodec: () => invertCodec,
|
|
12910
13640
|
ipv4: () => ipv4,
|
|
12911
13641
|
ipv6: () => ipv6,
|
|
12912
13642
|
iso: () => iso_exports,
|
|
@@ -13208,4 +13938,4 @@ Object.defineProperty(exports, "v4_exports", {
|
|
|
13208
13938
|
}
|
|
13209
13939
|
});
|
|
13210
13940
|
|
|
13211
|
-
//# sourceMappingURL=v4-
|
|
13941
|
+
//# sourceMappingURL=v4-BtFbnniV.cjs.map
|