@settlemint/sdk-utils 2.5.1-prd40d4da9 → 2.5.1-pre6103334
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/environment.cjs +1071 -727
- package/dist/environment.cjs.map +1 -1
- package/dist/environment.js +1071 -727
- package/dist/environment.js.map +1 -1
- package/dist/logging.d.cts +1 -1
- package/dist/logging.d.ts +1 -1
- package/dist/terminal.d.cts +1 -1
- package/dist/terminal.d.ts +1 -1
- package/dist/validation.cjs +1035 -691
- package/dist/validation.cjs.map +1 -1
- package/dist/validation.d.cts +1 -1
- package/dist/validation.d.ts +1 -1
- package/dist/validation.js +1035 -691
- package/dist/validation.js.map +1 -1
- package/package.json +1 -1
package/dist/environment.cjs
CHANGED
|
@@ -349,10 +349,10 @@ var SpinnerError = class extends Error {
|
|
|
349
349
|
* });
|
|
350
350
|
*/
|
|
351
351
|
const spinner = async (options) => {
|
|
352
|
-
const handleError = (error$
|
|
353
|
-
const errorMessage = maskTokens(error$
|
|
354
|
-
note((0, yoctocolors.redBright)(`${errorMessage}\n\n${error$
|
|
355
|
-
throw new SpinnerError(errorMessage, error$
|
|
352
|
+
const handleError = (error$39) => {
|
|
353
|
+
const errorMessage = maskTokens(error$39.message);
|
|
354
|
+
note((0, yoctocolors.redBright)(`${errorMessage}\n\n${error$39.stack}`));
|
|
355
|
+
throw new SpinnerError(errorMessage, error$39);
|
|
356
356
|
};
|
|
357
357
|
if (is_in_ci.default || !shouldPrint()) {
|
|
358
358
|
try {
|
|
@@ -480,7 +480,9 @@ function table(title, data) {
|
|
|
480
480
|
}
|
|
481
481
|
|
|
482
482
|
//#endregion
|
|
483
|
-
//#region ../../node_modules/zod/
|
|
483
|
+
//#region ../../node_modules/zod/v4/core/core.js
|
|
484
|
+
/** A special constant with type `never` */
|
|
485
|
+
const NEVER = Object.freeze({ status: "aborted" });
|
|
484
486
|
function $constructor(name, initializer$2, params) {
|
|
485
487
|
function init(inst, def) {
|
|
486
488
|
var _a;
|
|
@@ -531,7 +533,7 @@ function config$2(newConfig) {
|
|
|
531
533
|
}
|
|
532
534
|
|
|
533
535
|
//#endregion
|
|
534
|
-
//#region ../../node_modules/zod/
|
|
536
|
+
//#region ../../node_modules/zod/v4/core/util.js
|
|
535
537
|
var util_exports = {};
|
|
536
538
|
__export(util_exports, {
|
|
537
539
|
BIGINT_FORMAT_RANGES: () => BIGINT_FORMAT_RANGES,
|
|
@@ -546,6 +548,7 @@ __export(util_exports, {
|
|
|
546
548
|
assertNotEqual: () => assertNotEqual,
|
|
547
549
|
assignProp: () => assignProp,
|
|
548
550
|
cached: () => cached,
|
|
551
|
+
captureStackTrace: () => captureStackTrace,
|
|
549
552
|
cleanEnum: () => cleanEnum,
|
|
550
553
|
cleanRegex: () => cleanRegex,
|
|
551
554
|
clone: () => clone,
|
|
@@ -684,10 +687,14 @@ function randomString(length = 10) {
|
|
|
684
687
|
function esc(str) {
|
|
685
688
|
return JSON.stringify(str);
|
|
686
689
|
}
|
|
690
|
+
const captureStackTrace = Error.captureStackTrace ? Error.captureStackTrace : (..._args) => {};
|
|
687
691
|
function isObject(data) {
|
|
688
692
|
return typeof data === "object" && data !== null && !Array.isArray(data);
|
|
689
693
|
}
|
|
690
694
|
const allowsEval = cached(() => {
|
|
695
|
+
if (typeof navigator !== "undefined" && navigator?.userAgent?.includes("Cloudflare")) {
|
|
696
|
+
return false;
|
|
697
|
+
}
|
|
691
698
|
try {
|
|
692
699
|
const F = Function;
|
|
693
700
|
new F("");
|
|
@@ -696,9 +703,6 @@ const allowsEval = cached(() => {
|
|
|
696
703
|
return false;
|
|
697
704
|
}
|
|
698
705
|
});
|
|
699
|
-
function _isObject(o) {
|
|
700
|
-
return Object.prototype.toString.call(o) === "[object Object]";
|
|
701
|
-
}
|
|
702
706
|
function isPlainObject(o) {
|
|
703
707
|
if (isObject(o) === false) return false;
|
|
704
708
|
const ctor = o.constructor;
|
|
@@ -878,6 +882,9 @@ function omit(schema, mask) {
|
|
|
878
882
|
});
|
|
879
883
|
}
|
|
880
884
|
function extend(schema, shape) {
|
|
885
|
+
if (!isPlainObject(shape)) {
|
|
886
|
+
throw new Error("Invalid input to extend: expected a plain object");
|
|
887
|
+
}
|
|
881
888
|
const def = {
|
|
882
889
|
...schema._zod.def,
|
|
883
890
|
get shape() {
|
|
@@ -965,7 +972,7 @@ function required(Class$1, schema, mask) {
|
|
|
965
972
|
}
|
|
966
973
|
function aborted(x, startIndex = 0) {
|
|
967
974
|
for (let i = startIndex; i < x.issues.length; i++) {
|
|
968
|
-
if (x.issues[i]
|
|
975
|
+
if (x.issues[i]?.continue !== true) return true;
|
|
969
976
|
}
|
|
970
977
|
return false;
|
|
971
978
|
}
|
|
@@ -1029,7 +1036,7 @@ var Class = class {
|
|
|
1029
1036
|
};
|
|
1030
1037
|
|
|
1031
1038
|
//#endregion
|
|
1032
|
-
//#region ../../node_modules/zod/
|
|
1039
|
+
//#region ../../node_modules/zod/v4/core/errors.js
|
|
1033
1040
|
const initializer$1 = (inst, def) => {
|
|
1034
1041
|
inst.name = "$ZodError";
|
|
1035
1042
|
Object.defineProperty(inst, "_zod", {
|
|
@@ -1046,13 +1053,17 @@ const initializer$1 = (inst, def) => {
|
|
|
1046
1053
|
},
|
|
1047
1054
|
enumerable: true
|
|
1048
1055
|
});
|
|
1056
|
+
Object.defineProperty(inst, "toString", {
|
|
1057
|
+
value: () => inst.message,
|
|
1058
|
+
enumerable: false
|
|
1059
|
+
});
|
|
1049
1060
|
};
|
|
1050
1061
|
const $ZodError = $constructor("$ZodError", initializer$1);
|
|
1051
1062
|
const $ZodRealError = $constructor("$ZodError", initializer$1, { Parent: Error });
|
|
1052
|
-
function flattenError(error$
|
|
1063
|
+
function flattenError(error$39, mapper = (issue$1) => issue$1.message) {
|
|
1053
1064
|
const fieldErrors = {};
|
|
1054
1065
|
const formErrors = [];
|
|
1055
|
-
for (const sub of error$
|
|
1066
|
+
for (const sub of error$39.issues) {
|
|
1056
1067
|
if (sub.path.length > 0) {
|
|
1057
1068
|
fieldErrors[sub.path[0]] = fieldErrors[sub.path[0]] || [];
|
|
1058
1069
|
fieldErrors[sub.path[0]].push(mapper(sub));
|
|
@@ -1065,13 +1076,13 @@ function flattenError(error$37, mapper = (issue$1) => issue$1.message) {
|
|
|
1065
1076
|
fieldErrors
|
|
1066
1077
|
};
|
|
1067
1078
|
}
|
|
1068
|
-
function formatError(error$
|
|
1079
|
+
function formatError(error$39, _mapper) {
|
|
1069
1080
|
const mapper = _mapper || function(issue$1) {
|
|
1070
1081
|
return issue$1.message;
|
|
1071
1082
|
};
|
|
1072
1083
|
const fieldErrors = { _errors: [] };
|
|
1073
|
-
const processError = (error$
|
|
1074
|
-
for (const issue$1 of error$
|
|
1084
|
+
const processError = (error$40) => {
|
|
1085
|
+
for (const issue$1 of error$40.issues) {
|
|
1075
1086
|
if (issue$1.code === "invalid_union" && issue$1.errors.length) {
|
|
1076
1087
|
issue$1.errors.map((issues) => processError({ issues }));
|
|
1077
1088
|
} else if (issue$1.code === "invalid_key") {
|
|
@@ -1098,17 +1109,17 @@ function formatError(error$37, _mapper) {
|
|
|
1098
1109
|
}
|
|
1099
1110
|
}
|
|
1100
1111
|
};
|
|
1101
|
-
processError(error$
|
|
1112
|
+
processError(error$39);
|
|
1102
1113
|
return fieldErrors;
|
|
1103
1114
|
}
|
|
1104
|
-
function treeifyError(error$
|
|
1115
|
+
function treeifyError(error$39, _mapper) {
|
|
1105
1116
|
const mapper = _mapper || function(issue$1) {
|
|
1106
1117
|
return issue$1.message;
|
|
1107
1118
|
};
|
|
1108
1119
|
const result = { errors: [] };
|
|
1109
|
-
const processError = (error$
|
|
1120
|
+
const processError = (error$40, path$1 = []) => {
|
|
1110
1121
|
var _a, _b;
|
|
1111
|
-
for (const issue$1 of error$
|
|
1122
|
+
for (const issue$1 of error$40.issues) {
|
|
1112
1123
|
if (issue$1.code === "invalid_union" && issue$1.errors.length) {
|
|
1113
1124
|
issue$1.errors.map((issues) => processError({ issues }, issue$1.path));
|
|
1114
1125
|
} else if (issue$1.code === "invalid_key") {
|
|
@@ -1143,7 +1154,7 @@ function treeifyError(error$37, _mapper) {
|
|
|
1143
1154
|
}
|
|
1144
1155
|
}
|
|
1145
1156
|
};
|
|
1146
|
-
processError(error$
|
|
1157
|
+
processError(error$39);
|
|
1147
1158
|
return result;
|
|
1148
1159
|
}
|
|
1149
1160
|
/** Format a ZodError as a human-readable string in the following form.
|
|
@@ -1191,9 +1202,9 @@ function toDotPath(path$1) {
|
|
|
1191
1202
|
}
|
|
1192
1203
|
return segs.join("");
|
|
1193
1204
|
}
|
|
1194
|
-
function prettifyError(error$
|
|
1205
|
+
function prettifyError(error$39) {
|
|
1195
1206
|
const lines = [];
|
|
1196
|
-
const issues = [...error$
|
|
1207
|
+
const issues = [...error$39.issues].sort((a, b) => a.path.length - b.path.length);
|
|
1197
1208
|
for (const issue$1 of issues) {
|
|
1198
1209
|
lines.push(`✖ ${issue$1.message}`);
|
|
1199
1210
|
if (issue$1.path?.length) lines.push(` → at ${toDotPath(issue$1.path)}`);
|
|
@@ -1202,7 +1213,7 @@ function prettifyError(error$37) {
|
|
|
1202
1213
|
}
|
|
1203
1214
|
|
|
1204
1215
|
//#endregion
|
|
1205
|
-
//#region ../../node_modules/zod/
|
|
1216
|
+
//#region ../../node_modules/zod/v4/core/parse.js
|
|
1206
1217
|
const _parse = (_Err) => (schema, value, _ctx, _params) => {
|
|
1207
1218
|
const ctx = _ctx ? Object.assign(_ctx, { async: false }) : { async: false };
|
|
1208
1219
|
const result = schema._zod.run({
|
|
@@ -1214,7 +1225,7 @@ const _parse = (_Err) => (schema, value, _ctx, _params) => {
|
|
|
1214
1225
|
}
|
|
1215
1226
|
if (result.issues.length) {
|
|
1216
1227
|
const e = new (_params?.Err ?? _Err)(result.issues.map((iss) => finalizeIssue(iss, ctx, config$2())));
|
|
1217
|
-
|
|
1228
|
+
captureStackTrace(e, _params?.callee);
|
|
1218
1229
|
throw e;
|
|
1219
1230
|
}
|
|
1220
1231
|
return result.value;
|
|
@@ -1229,7 +1240,7 @@ const _parseAsync = (_Err) => async (schema, value, _ctx, params) => {
|
|
|
1229
1240
|
if (result instanceof Promise) result = await result;
|
|
1230
1241
|
if (result.issues.length) {
|
|
1231
1242
|
const e = new (params?.Err ?? _Err)(result.issues.map((iss) => finalizeIssue(iss, ctx, config$2())));
|
|
1232
|
-
|
|
1243
|
+
captureStackTrace(e, params?.callee);
|
|
1233
1244
|
throw e;
|
|
1234
1245
|
}
|
|
1235
1246
|
return result.value;
|
|
@@ -1274,10 +1285,9 @@ const _safeParseAsync = (_Err) => async (schema, value, _ctx) => {
|
|
|
1274
1285
|
const safeParseAsync$1 = /* @__PURE__ */ _safeParseAsync($ZodRealError);
|
|
1275
1286
|
|
|
1276
1287
|
//#endregion
|
|
1277
|
-
//#region ../../node_modules/zod/
|
|
1288
|
+
//#region ../../node_modules/zod/v4/core/regexes.js
|
|
1278
1289
|
var regexes_exports = {};
|
|
1279
1290
|
__export(regexes_exports, {
|
|
1280
|
-
_emoji: () => _emoji$1,
|
|
1281
1291
|
base64: () => base64$1,
|
|
1282
1292
|
base64url: () => base64url$1,
|
|
1283
1293
|
bigint: () => bigint$2,
|
|
@@ -1363,27 +1373,23 @@ const base64url$1 = /^[A-Za-z0-9_-]*$/;
|
|
|
1363
1373
|
const hostname = /^([a-zA-Z0-9-]+\.)*[a-zA-Z0-9-]+$/;
|
|
1364
1374
|
const domain = /^([a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?\.)+[a-zA-Z]{2,}$/;
|
|
1365
1375
|
const e164$1 = /^\+(?:[0-9]){6,14}[0-9]$/;
|
|
1366
|
-
const dateSource = `((
|
|
1376
|
+
const 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])))`;
|
|
1367
1377
|
const date$3 = /* @__PURE__ */ new RegExp(`^${dateSource}$`);
|
|
1368
1378
|
function timeSource(args) {
|
|
1369
|
-
|
|
1370
|
-
|
|
1371
|
-
regex = `${regex}\\.\\d{${args.precision}}`;
|
|
1372
|
-
} else if (args.precision == null) {
|
|
1373
|
-
regex = `${regex}(\\.\\d+)?`;
|
|
1374
|
-
}
|
|
1379
|
+
const hhmm = `(?:[01]\\d|2[0-3]):[0-5]\\d`;
|
|
1380
|
+
const regex = typeof args.precision === "number" ? args.precision === -1 ? `${hhmm}` : args.precision === 0 ? `${hhmm}:[0-5]\\d` : `${hhmm}:[0-5]\\d\\.\\d{${args.precision}}` : `${hhmm}(?::[0-5]\\d(?:\\.\\d+)?)?`;
|
|
1375
1381
|
return regex;
|
|
1376
1382
|
}
|
|
1377
1383
|
function time$1(args) {
|
|
1378
1384
|
return new RegExp(`^${timeSource(args)}$`);
|
|
1379
1385
|
}
|
|
1380
1386
|
function datetime$1(args) {
|
|
1381
|
-
|
|
1382
|
-
const opts = [];
|
|
1383
|
-
|
|
1384
|
-
if (args.offset) opts.push(`([+-]\\d{2}
|
|
1385
|
-
|
|
1386
|
-
return new RegExp(`^${
|
|
1387
|
+
const time$2 = timeSource({ precision: args.precision });
|
|
1388
|
+
const opts = ["Z"];
|
|
1389
|
+
if (args.local) opts.push("");
|
|
1390
|
+
if (args.offset) opts.push(`([+-]\\d{2}:\\d{2})`);
|
|
1391
|
+
const timeRegex = `${time$2}(?:${opts.join("|")})`;
|
|
1392
|
+
return new RegExp(`^${dateSource}T(?:${timeRegex})$`);
|
|
1387
1393
|
}
|
|
1388
1394
|
const string$2 = (params) => {
|
|
1389
1395
|
const regex = params ? `[\\s\\S]{${params?.minimum ?? 0},${params?.maximum ?? ""}}` : `[\\s\\S]*`;
|
|
@@ -1399,7 +1405,7 @@ const lowercase = /^[^A-Z]*$/;
|
|
|
1399
1405
|
const uppercase = /^[^a-z]*$/;
|
|
1400
1406
|
|
|
1401
1407
|
//#endregion
|
|
1402
|
-
//#region ../../node_modules/zod/
|
|
1408
|
+
//#region ../../node_modules/zod/v4/core/checks.js
|
|
1403
1409
|
const $ZodCheck = /* @__PURE__ */ $constructor("$ZodCheck", (inst, def) => {
|
|
1404
1410
|
var _a;
|
|
1405
1411
|
inst._zod ?? (inst._zod = {});
|
|
@@ -1590,11 +1596,12 @@ const $ZodCheckBigIntFormat = /* @__PURE__ */ $constructor("$ZodCheckBigIntForma
|
|
|
1590
1596
|
};
|
|
1591
1597
|
});
|
|
1592
1598
|
const $ZodCheckMaxSize = /* @__PURE__ */ $constructor("$ZodCheckMaxSize", (inst, def) => {
|
|
1599
|
+
var _a;
|
|
1593
1600
|
$ZodCheck.init(inst, def);
|
|
1594
|
-
inst._zod.when = (payload) => {
|
|
1601
|
+
(_a = inst._zod.def).when ?? (_a.when = (payload) => {
|
|
1595
1602
|
const val = payload.value;
|
|
1596
1603
|
return !nullish$1(val) && val.size !== undefined;
|
|
1597
|
-
};
|
|
1604
|
+
});
|
|
1598
1605
|
inst._zod.onattach.push((inst$1) => {
|
|
1599
1606
|
const curr = inst$1._zod.bag.maximum ?? Number.POSITIVE_INFINITY;
|
|
1600
1607
|
if (def.maximum < curr) inst$1._zod.bag.maximum = def.maximum;
|
|
@@ -1614,11 +1621,12 @@ const $ZodCheckMaxSize = /* @__PURE__ */ $constructor("$ZodCheckMaxSize", (inst,
|
|
|
1614
1621
|
};
|
|
1615
1622
|
});
|
|
1616
1623
|
const $ZodCheckMinSize = /* @__PURE__ */ $constructor("$ZodCheckMinSize", (inst, def) => {
|
|
1624
|
+
var _a;
|
|
1617
1625
|
$ZodCheck.init(inst, def);
|
|
1618
|
-
inst._zod.when = (payload) => {
|
|
1626
|
+
(_a = inst._zod.def).when ?? (_a.when = (payload) => {
|
|
1619
1627
|
const val = payload.value;
|
|
1620
1628
|
return !nullish$1(val) && val.size !== undefined;
|
|
1621
|
-
};
|
|
1629
|
+
});
|
|
1622
1630
|
inst._zod.onattach.push((inst$1) => {
|
|
1623
1631
|
const curr = inst$1._zod.bag.minimum ?? Number.NEGATIVE_INFINITY;
|
|
1624
1632
|
if (def.minimum > curr) inst$1._zod.bag.minimum = def.minimum;
|
|
@@ -1638,11 +1646,12 @@ const $ZodCheckMinSize = /* @__PURE__ */ $constructor("$ZodCheckMinSize", (inst,
|
|
|
1638
1646
|
};
|
|
1639
1647
|
});
|
|
1640
1648
|
const $ZodCheckSizeEquals = /* @__PURE__ */ $constructor("$ZodCheckSizeEquals", (inst, def) => {
|
|
1649
|
+
var _a;
|
|
1641
1650
|
$ZodCheck.init(inst, def);
|
|
1642
|
-
inst._zod.when = (payload) => {
|
|
1651
|
+
(_a = inst._zod.def).when ?? (_a.when = (payload) => {
|
|
1643
1652
|
const val = payload.value;
|
|
1644
1653
|
return !nullish$1(val) && val.size !== undefined;
|
|
1645
|
-
};
|
|
1654
|
+
});
|
|
1646
1655
|
inst._zod.onattach.push((inst$1) => {
|
|
1647
1656
|
const bag = inst$1._zod.bag;
|
|
1648
1657
|
bag.minimum = def.size;
|
|
@@ -1663,6 +1672,8 @@ const $ZodCheckSizeEquals = /* @__PURE__ */ $constructor("$ZodCheckSizeEquals",
|
|
|
1663
1672
|
code: "too_small",
|
|
1664
1673
|
minimum: def.size
|
|
1665
1674
|
},
|
|
1675
|
+
inclusive: true,
|
|
1676
|
+
exact: true,
|
|
1666
1677
|
input: payload.value,
|
|
1667
1678
|
inst,
|
|
1668
1679
|
continue: !def.abort
|
|
@@ -1670,11 +1681,12 @@ const $ZodCheckSizeEquals = /* @__PURE__ */ $constructor("$ZodCheckSizeEquals",
|
|
|
1670
1681
|
};
|
|
1671
1682
|
});
|
|
1672
1683
|
const $ZodCheckMaxLength = /* @__PURE__ */ $constructor("$ZodCheckMaxLength", (inst, def) => {
|
|
1684
|
+
var _a;
|
|
1673
1685
|
$ZodCheck.init(inst, def);
|
|
1674
|
-
inst._zod.when = (payload) => {
|
|
1686
|
+
(_a = inst._zod.def).when ?? (_a.when = (payload) => {
|
|
1675
1687
|
const val = payload.value;
|
|
1676
1688
|
return !nullish$1(val) && val.length !== undefined;
|
|
1677
|
-
};
|
|
1689
|
+
});
|
|
1678
1690
|
inst._zod.onattach.push((inst$1) => {
|
|
1679
1691
|
const curr = inst$1._zod.bag.maximum ?? Number.POSITIVE_INFINITY;
|
|
1680
1692
|
if (def.maximum < curr) inst$1._zod.bag.maximum = def.maximum;
|
|
@@ -1696,11 +1708,12 @@ const $ZodCheckMaxLength = /* @__PURE__ */ $constructor("$ZodCheckMaxLength", (i
|
|
|
1696
1708
|
};
|
|
1697
1709
|
});
|
|
1698
1710
|
const $ZodCheckMinLength = /* @__PURE__ */ $constructor("$ZodCheckMinLength", (inst, def) => {
|
|
1711
|
+
var _a;
|
|
1699
1712
|
$ZodCheck.init(inst, def);
|
|
1700
|
-
inst._zod.when = (payload) => {
|
|
1713
|
+
(_a = inst._zod.def).when ?? (_a.when = (payload) => {
|
|
1701
1714
|
const val = payload.value;
|
|
1702
1715
|
return !nullish$1(val) && val.length !== undefined;
|
|
1703
|
-
};
|
|
1716
|
+
});
|
|
1704
1717
|
inst._zod.onattach.push((inst$1) => {
|
|
1705
1718
|
const curr = inst$1._zod.bag.minimum ?? Number.NEGATIVE_INFINITY;
|
|
1706
1719
|
if (def.minimum > curr) inst$1._zod.bag.minimum = def.minimum;
|
|
@@ -1722,11 +1735,12 @@ const $ZodCheckMinLength = /* @__PURE__ */ $constructor("$ZodCheckMinLength", (i
|
|
|
1722
1735
|
};
|
|
1723
1736
|
});
|
|
1724
1737
|
const $ZodCheckLengthEquals = /* @__PURE__ */ $constructor("$ZodCheckLengthEquals", (inst, def) => {
|
|
1738
|
+
var _a;
|
|
1725
1739
|
$ZodCheck.init(inst, def);
|
|
1726
|
-
inst._zod.when = (payload) => {
|
|
1740
|
+
(_a = inst._zod.def).when ?? (_a.when = (payload) => {
|
|
1727
1741
|
const val = payload.value;
|
|
1728
1742
|
return !nullish$1(val) && val.length !== undefined;
|
|
1729
|
-
};
|
|
1743
|
+
});
|
|
1730
1744
|
inst._zod.onattach.push((inst$1) => {
|
|
1731
1745
|
const bag = inst$1._zod.bag;
|
|
1732
1746
|
bag.minimum = def.length;
|
|
@@ -1748,6 +1762,8 @@ const $ZodCheckLengthEquals = /* @__PURE__ */ $constructor("$ZodCheckLengthEqual
|
|
|
1748
1762
|
code: "too_small",
|
|
1749
1763
|
minimum: def.length
|
|
1750
1764
|
},
|
|
1765
|
+
inclusive: true,
|
|
1766
|
+
exact: true,
|
|
1751
1767
|
input: payload.value,
|
|
1752
1768
|
inst,
|
|
1753
1769
|
continue: !def.abort
|
|
@@ -1755,7 +1771,7 @@ const $ZodCheckLengthEquals = /* @__PURE__ */ $constructor("$ZodCheckLengthEqual
|
|
|
1755
1771
|
};
|
|
1756
1772
|
});
|
|
1757
1773
|
const $ZodCheckStringFormat = /* @__PURE__ */ $constructor("$ZodCheckStringFormat", (inst, def) => {
|
|
1758
|
-
var _a;
|
|
1774
|
+
var _a, _b;
|
|
1759
1775
|
$ZodCheck.init(inst, def);
|
|
1760
1776
|
inst._zod.onattach.push((inst$1) => {
|
|
1761
1777
|
const bag = inst$1._zod.bag;
|
|
@@ -1765,8 +1781,7 @@ const $ZodCheckStringFormat = /* @__PURE__ */ $constructor("$ZodCheckStringForma
|
|
|
1765
1781
|
bag.patterns.add(def.pattern);
|
|
1766
1782
|
}
|
|
1767
1783
|
});
|
|
1768
|
-
(_a = inst._zod).check ?? (_a.check = (payload) => {
|
|
1769
|
-
if (!def.pattern) throw new Error("Not implemented.");
|
|
1784
|
+
if (def.pattern) (_a = inst._zod).check ?? (_a.check = (payload) => {
|
|
1770
1785
|
def.pattern.lastIndex = 0;
|
|
1771
1786
|
if (def.pattern.test(payload.value)) return;
|
|
1772
1787
|
payload.issues.push({
|
|
@@ -1779,6 +1794,7 @@ const $ZodCheckStringFormat = /* @__PURE__ */ $constructor("$ZodCheckStringForma
|
|
|
1779
1794
|
continue: !def.abort
|
|
1780
1795
|
});
|
|
1781
1796
|
});
|
|
1797
|
+
else (_b = inst._zod).check ?? (_b.check = () => {});
|
|
1782
1798
|
});
|
|
1783
1799
|
const $ZodCheckRegex = /* @__PURE__ */ $constructor("$ZodCheckRegex", (inst, def) => {
|
|
1784
1800
|
$ZodCheckStringFormat.init(inst, def);
|
|
@@ -1902,7 +1918,6 @@ const $ZodCheckMimeType = /* @__PURE__ */ $constructor("$ZodCheckMimeType", (ins
|
|
|
1902
1918
|
code: "invalid_value",
|
|
1903
1919
|
values: def.mime,
|
|
1904
1920
|
input: payload.value.type,
|
|
1905
|
-
path: ["type"],
|
|
1906
1921
|
inst
|
|
1907
1922
|
});
|
|
1908
1923
|
};
|
|
@@ -1915,7 +1930,7 @@ const $ZodCheckOverwrite = /* @__PURE__ */ $constructor("$ZodCheckOverwrite", (i
|
|
|
1915
1930
|
});
|
|
1916
1931
|
|
|
1917
1932
|
//#endregion
|
|
1918
|
-
//#region ../../node_modules/zod/
|
|
1933
|
+
//#region ../../node_modules/zod/v4/core/doc.js
|
|
1919
1934
|
var Doc = class {
|
|
1920
1935
|
constructor(args = []) {
|
|
1921
1936
|
this.content = [];
|
|
@@ -1951,19 +1966,18 @@ var Doc = class {
|
|
|
1951
1966
|
};
|
|
1952
1967
|
|
|
1953
1968
|
//#endregion
|
|
1954
|
-
//#region ../../node_modules/zod/
|
|
1969
|
+
//#region ../../node_modules/zod/v4/core/versions.js
|
|
1955
1970
|
const version = {
|
|
1956
1971
|
major: 4,
|
|
1957
1972
|
minor: 0,
|
|
1958
|
-
patch:
|
|
1973
|
+
patch: 5
|
|
1959
1974
|
};
|
|
1960
1975
|
|
|
1961
1976
|
//#endregion
|
|
1962
|
-
//#region ../../node_modules/zod/
|
|
1977
|
+
//#region ../../node_modules/zod/v4/core/schemas.js
|
|
1963
1978
|
const $ZodType = /* @__PURE__ */ $constructor("$ZodType", (inst, def) => {
|
|
1964
1979
|
var _a;
|
|
1965
1980
|
inst ?? (inst = {});
|
|
1966
|
-
inst._zod.id = def.type + "_" + randomString(10);
|
|
1967
1981
|
inst._zod.def = def;
|
|
1968
1982
|
inst._zod.bag = inst._zod.bag || {};
|
|
1969
1983
|
inst._zod.version = version;
|
|
@@ -1986,13 +2000,11 @@ const $ZodType = /* @__PURE__ */ $constructor("$ZodType", (inst, def) => {
|
|
|
1986
2000
|
let isAborted = aborted(payload);
|
|
1987
2001
|
let asyncResult;
|
|
1988
2002
|
for (const ch of checks$1) {
|
|
1989
|
-
if (ch._zod.when) {
|
|
1990
|
-
const shouldRun = ch._zod.when(payload);
|
|
2003
|
+
if (ch._zod.def.when) {
|
|
2004
|
+
const shouldRun = ch._zod.def.when(payload);
|
|
1991
2005
|
if (!shouldRun) continue;
|
|
1992
|
-
} else {
|
|
1993
|
-
|
|
1994
|
-
continue;
|
|
1995
|
-
}
|
|
2006
|
+
} else if (isAborted) {
|
|
2007
|
+
continue;
|
|
1996
2008
|
}
|
|
1997
2009
|
const currLen = payload.issues.length;
|
|
1998
2010
|
const _ = ch._zod.check(payload);
|
|
@@ -2092,7 +2104,9 @@ const $ZodURL = /* @__PURE__ */ $constructor("$ZodURL", (inst, def) => {
|
|
|
2092
2104
|
$ZodStringFormat.init(inst, def);
|
|
2093
2105
|
inst._zod.check = (payload) => {
|
|
2094
2106
|
try {
|
|
2095
|
-
const
|
|
2107
|
+
const orig = payload.value;
|
|
2108
|
+
const url$1 = new URL(orig);
|
|
2109
|
+
const href = url$1.href;
|
|
2096
2110
|
if (def.hostname) {
|
|
2097
2111
|
def.hostname.lastIndex = 0;
|
|
2098
2112
|
if (!def.hostname.test(url$1.hostname)) {
|
|
@@ -2121,6 +2135,11 @@ const $ZodURL = /* @__PURE__ */ $constructor("$ZodURL", (inst, def) => {
|
|
|
2121
2135
|
});
|
|
2122
2136
|
}
|
|
2123
2137
|
}
|
|
2138
|
+
if (!orig.endsWith("/") && href.endsWith("/")) {
|
|
2139
|
+
payload.value = href.slice(0, -1);
|
|
2140
|
+
} else {
|
|
2141
|
+
payload.value = href;
|
|
2142
|
+
}
|
|
2124
2143
|
return;
|
|
2125
2144
|
} catch (_) {
|
|
2126
2145
|
payload.issues.push({
|
|
@@ -2291,6 +2310,7 @@ function isValidJWT(token, algorithm = null) {
|
|
|
2291
2310
|
const tokensParts = token.split(".");
|
|
2292
2311
|
if (tokensParts.length !== 3) return false;
|
|
2293
2312
|
const [header] = tokensParts;
|
|
2313
|
+
if (!header) return false;
|
|
2294
2314
|
const parsedHeader = JSON.parse(atob(header));
|
|
2295
2315
|
if ("typ" in parsedHeader && parsedHeader?.typ !== "JWT") return false;
|
|
2296
2316
|
if (!parsedHeader.alg) return false;
|
|
@@ -2313,6 +2333,19 @@ const $ZodJWT = /* @__PURE__ */ $constructor("$ZodJWT", (inst, def) => {
|
|
|
2313
2333
|
});
|
|
2314
2334
|
};
|
|
2315
2335
|
});
|
|
2336
|
+
const $ZodCustomStringFormat = /* @__PURE__ */ $constructor("$ZodCustomStringFormat", (inst, def) => {
|
|
2337
|
+
$ZodStringFormat.init(inst, def);
|
|
2338
|
+
inst._zod.check = (payload) => {
|
|
2339
|
+
if (def.fn(payload.value)) return;
|
|
2340
|
+
payload.issues.push({
|
|
2341
|
+
code: "invalid_format",
|
|
2342
|
+
format: def.format,
|
|
2343
|
+
input: payload.value,
|
|
2344
|
+
inst,
|
|
2345
|
+
continue: !def.abort
|
|
2346
|
+
});
|
|
2347
|
+
};
|
|
2348
|
+
});
|
|
2316
2349
|
const $ZodNumber = /* @__PURE__ */ $constructor("$ZodNumber", (inst, def) => {
|
|
2317
2350
|
$ZodType.init(inst, def);
|
|
2318
2351
|
inst._zod.pattern = inst._zod.bag.pattern ?? number$2;
|
|
@@ -2364,12 +2397,11 @@ const $ZodBigInt = /* @__PURE__ */ $constructor("$ZodBigInt", (inst, def) => {
|
|
|
2364
2397
|
if (def.coerce) try {
|
|
2365
2398
|
payload.value = BigInt(payload.value);
|
|
2366
2399
|
} catch (_) {}
|
|
2367
|
-
|
|
2368
|
-
if (typeof input === "bigint") return payload;
|
|
2400
|
+
if (typeof payload.value === "bigint") return payload;
|
|
2369
2401
|
payload.issues.push({
|
|
2370
2402
|
expected: "bigint",
|
|
2371
2403
|
code: "invalid_type",
|
|
2372
|
-
input,
|
|
2404
|
+
input: payload.value,
|
|
2373
2405
|
inst
|
|
2374
2406
|
});
|
|
2375
2407
|
return payload;
|
|
@@ -2382,7 +2414,7 @@ const $ZodBigIntFormat = /* @__PURE__ */ $constructor("$ZodBigInt", (inst, def)
|
|
|
2382
2414
|
const $ZodSymbol = /* @__PURE__ */ $constructor("$ZodSymbol", (inst, def) => {
|
|
2383
2415
|
$ZodType.init(inst, def);
|
|
2384
2416
|
inst._zod.parse = (payload, _ctx) => {
|
|
2385
|
-
const
|
|
2417
|
+
const input = payload.value;
|
|
2386
2418
|
if (typeof input === "symbol") return payload;
|
|
2387
2419
|
payload.issues.push({
|
|
2388
2420
|
expected: "symbol",
|
|
@@ -2397,8 +2429,10 @@ const $ZodUndefined = /* @__PURE__ */ $constructor("$ZodUndefined", (inst, def)
|
|
|
2397
2429
|
$ZodType.init(inst, def);
|
|
2398
2430
|
inst._zod.pattern = _undefined$2;
|
|
2399
2431
|
inst._zod.values = new Set([undefined]);
|
|
2432
|
+
inst._zod.optin = "optional";
|
|
2433
|
+
inst._zod.optout = "optional";
|
|
2400
2434
|
inst._zod.parse = (payload, _ctx) => {
|
|
2401
|
-
const
|
|
2435
|
+
const input = payload.value;
|
|
2402
2436
|
if (typeof input === "undefined") return payload;
|
|
2403
2437
|
payload.issues.push({
|
|
2404
2438
|
expected: "undefined",
|
|
@@ -2414,7 +2448,7 @@ const $ZodNull = /* @__PURE__ */ $constructor("$ZodNull", (inst, def) => {
|
|
|
2414
2448
|
inst._zod.pattern = _null$2;
|
|
2415
2449
|
inst._zod.values = new Set([null]);
|
|
2416
2450
|
inst._zod.parse = (payload, _ctx) => {
|
|
2417
|
-
const
|
|
2451
|
+
const input = payload.value;
|
|
2418
2452
|
if (input === null) return payload;
|
|
2419
2453
|
payload.issues.push({
|
|
2420
2454
|
expected: "null",
|
|
@@ -2448,7 +2482,7 @@ const $ZodNever = /* @__PURE__ */ $constructor("$ZodNever", (inst, def) => {
|
|
|
2448
2482
|
const $ZodVoid = /* @__PURE__ */ $constructor("$ZodVoid", (inst, def) => {
|
|
2449
2483
|
$ZodType.init(inst, def);
|
|
2450
2484
|
inst._zod.parse = (payload, _ctx) => {
|
|
2451
|
-
const
|
|
2485
|
+
const input = payload.value;
|
|
2452
2486
|
if (typeof input === "undefined") return payload;
|
|
2453
2487
|
payload.issues.push({
|
|
2454
2488
|
expected: "void",
|
|
@@ -2579,19 +2613,20 @@ const $ZodObject = /* @__PURE__ */ $constructor("$ZodObject", (inst, def) => {
|
|
|
2579
2613
|
"payload",
|
|
2580
2614
|
"ctx"
|
|
2581
2615
|
]);
|
|
2582
|
-
const
|
|
2616
|
+
const normalized = _normalized.value;
|
|
2583
2617
|
const parseStr = (key) => {
|
|
2584
2618
|
const k = esc(key);
|
|
2585
2619
|
return `shape[${k}]._zod.run({ value: input[${k}], issues: [] }, ctx)`;
|
|
2586
2620
|
};
|
|
2587
2621
|
doc.write(`const input = payload.value;`);
|
|
2588
2622
|
const ids = Object.create(null);
|
|
2589
|
-
|
|
2590
|
-
|
|
2623
|
+
let counter = 0;
|
|
2624
|
+
for (const key of normalized.keys) {
|
|
2625
|
+
ids[key] = `key_${counter++}`;
|
|
2591
2626
|
}
|
|
2592
2627
|
doc.write(`const newResult = {}`);
|
|
2593
|
-
for (const key of keys) {
|
|
2594
|
-
if (optionalKeys
|
|
2628
|
+
for (const key of normalized.keys) {
|
|
2629
|
+
if (normalized.optionalKeys.has(key)) {
|
|
2595
2630
|
const id = ids[key];
|
|
2596
2631
|
doc.write(`const ${id} = ${parseStr(key)};`);
|
|
2597
2632
|
const k = esc(key);
|
|
@@ -2636,7 +2671,7 @@ const $ZodObject = /* @__PURE__ */ $constructor("$ZodObject", (inst, def) => {
|
|
|
2636
2671
|
const jit = !globalConfig.jitless;
|
|
2637
2672
|
const allowsEval$1 = allowsEval;
|
|
2638
2673
|
const fastEnabled = jit && allowsEval$1.value;
|
|
2639
|
-
const
|
|
2674
|
+
const catchall = def.catchall;
|
|
2640
2675
|
let value;
|
|
2641
2676
|
inst._zod.parse = (payload, ctx) => {
|
|
2642
2677
|
value ?? (value = _normalized.value);
|
|
@@ -2666,12 +2701,10 @@ const $ZodObject = /* @__PURE__ */ $constructor("$ZodObject", (inst, def) => {
|
|
|
2666
2701
|
const isOptional = el._zod.optin === "optional" && el._zod.optout === "optional";
|
|
2667
2702
|
if (r instanceof Promise) {
|
|
2668
2703
|
proms.push(r.then((r$1) => isOptional ? handleOptionalObjectResult(r$1, payload, key, input) : handleObjectResult(r$1, payload, key)));
|
|
2704
|
+
} else if (isOptional) {
|
|
2705
|
+
handleOptionalObjectResult(r, payload, key, input);
|
|
2669
2706
|
} else {
|
|
2670
|
-
|
|
2671
|
-
handleOptionalObjectResult(r, payload, key, input);
|
|
2672
|
-
} else {
|
|
2673
|
-
handleObjectResult(r, payload, key);
|
|
2674
|
-
}
|
|
2707
|
+
handleObjectResult(r, payload, key);
|
|
2675
2708
|
}
|
|
2676
2709
|
}
|
|
2677
2710
|
}
|
|
@@ -2729,6 +2762,8 @@ function handleUnionResults(results, final, inst, ctx) {
|
|
|
2729
2762
|
}
|
|
2730
2763
|
const $ZodUnion = /* @__PURE__ */ $constructor("$ZodUnion", (inst, def) => {
|
|
2731
2764
|
$ZodType.init(inst, def);
|
|
2765
|
+
defineLazy(inst._zod, "optin", () => def.options.some((o) => o._zod.optin === "optional") ? "optional" : undefined);
|
|
2766
|
+
defineLazy(inst._zod, "optout", () => def.options.some((o) => o._zod.optout === "optional") ? "optional" : undefined);
|
|
2732
2767
|
defineLazy(inst._zod, "values", () => {
|
|
2733
2768
|
if (def.options.every((o) => o._zod.values)) {
|
|
2734
2769
|
return new Set(def.options.flatMap((option) => Array.from(option._zod.values)));
|
|
@@ -2785,7 +2820,7 @@ const $ZodDiscriminatedUnion = /* @__PURE__ */ $constructor("$ZodDiscriminatedUn
|
|
|
2785
2820
|
const opts = def.options;
|
|
2786
2821
|
const map$1 = new Map();
|
|
2787
2822
|
for (const o of opts) {
|
|
2788
|
-
const values = o._zod.propValues[def.discriminator];
|
|
2823
|
+
const values = o._zod.propValues?.[def.discriminator];
|
|
2789
2824
|
if (!values || values.size === 0) throw new Error(`Invalid discriminated union option at index "${def.options.indexOf(o)}"`);
|
|
2790
2825
|
for (const v of values) {
|
|
2791
2826
|
if (map$1.has(v)) {
|
|
@@ -2828,7 +2863,7 @@ const $ZodDiscriminatedUnion = /* @__PURE__ */ $constructor("$ZodDiscriminatedUn
|
|
|
2828
2863
|
const $ZodIntersection = /* @__PURE__ */ $constructor("$ZodIntersection", (inst, def) => {
|
|
2829
2864
|
$ZodType.init(inst, def);
|
|
2830
2865
|
inst._zod.parse = (payload, ctx) => {
|
|
2831
|
-
const
|
|
2866
|
+
const input = payload.value;
|
|
2832
2867
|
const left = def.left._zod.run({
|
|
2833
2868
|
value: input,
|
|
2834
2869
|
issues: []
|
|
@@ -3285,6 +3320,9 @@ const $ZodOptional = /* @__PURE__ */ $constructor("$ZodOptional", (inst, def) =>
|
|
|
3285
3320
|
return pattern ? new RegExp(`^(${cleanRegex(pattern.source)})?$`) : undefined;
|
|
3286
3321
|
});
|
|
3287
3322
|
inst._zod.parse = (payload, ctx) => {
|
|
3323
|
+
if (def.innerType._zod.optin === "optional") {
|
|
3324
|
+
return def.innerType._zod.run(payload, ctx);
|
|
3325
|
+
}
|
|
3288
3326
|
if (payload.value === undefined) {
|
|
3289
3327
|
return payload;
|
|
3290
3328
|
}
|
|
@@ -3384,7 +3422,7 @@ const $ZodSuccess = /* @__PURE__ */ $constructor("$ZodSuccess", (inst, def) => {
|
|
|
3384
3422
|
});
|
|
3385
3423
|
const $ZodCatch = /* @__PURE__ */ $constructor("$ZodCatch", (inst, def) => {
|
|
3386
3424
|
$ZodType.init(inst, def);
|
|
3387
|
-
|
|
3425
|
+
inst._zod.optin = "optional";
|
|
3388
3426
|
defineLazy(inst._zod, "optout", () => def.innerType._zod.optout);
|
|
3389
3427
|
defineLazy(inst._zod, "values", () => def.innerType._zod.values);
|
|
3390
3428
|
inst._zod.parse = (payload, ctx) => {
|
|
@@ -3435,6 +3473,7 @@ const $ZodPipe = /* @__PURE__ */ $constructor("$ZodPipe", (inst, def) => {
|
|
|
3435
3473
|
defineLazy(inst._zod, "values", () => def.in._zod.values);
|
|
3436
3474
|
defineLazy(inst._zod, "optin", () => def.in._zod.optin);
|
|
3437
3475
|
defineLazy(inst._zod, "optout", () => def.out._zod.optout);
|
|
3476
|
+
defineLazy(inst._zod, "propValues", () => def.in._zod.propValues);
|
|
3438
3477
|
inst._zod.parse = (payload, ctx) => {
|
|
3439
3478
|
const left = def.in._zod.run(payload, ctx);
|
|
3440
3479
|
if (left instanceof Promise) {
|
|
@@ -3455,6 +3494,7 @@ function handlePipeResult(left, def, ctx) {
|
|
|
3455
3494
|
const $ZodReadonly = /* @__PURE__ */ $constructor("$ZodReadonly", (inst, def) => {
|
|
3456
3495
|
$ZodType.init(inst, def);
|
|
3457
3496
|
defineLazy(inst._zod, "propValues", () => def.innerType._zod.propValues);
|
|
3497
|
+
defineLazy(inst._zod, "values", () => def.innerType._zod.values);
|
|
3458
3498
|
defineLazy(inst._zod, "optin", () => def.innerType._zod.optin);
|
|
3459
3499
|
defineLazy(inst._zod, "optout", () => def.innerType._zod.optout);
|
|
3460
3500
|
inst._zod.parse = (payload, ctx) => {
|
|
@@ -3505,7 +3545,7 @@ const $ZodTemplateLiteral = /* @__PURE__ */ $constructor("$ZodTemplateLiteral",
|
|
|
3505
3545
|
input: payload.value,
|
|
3506
3546
|
inst,
|
|
3507
3547
|
code: "invalid_format",
|
|
3508
|
-
format: "template_literal",
|
|
3548
|
+
format: def.format ?? "template_literal",
|
|
3509
3549
|
pattern: inst._zod.pattern.source
|
|
3510
3550
|
});
|
|
3511
3551
|
return payload;
|
|
@@ -3565,8 +3605,8 @@ function handleRefineResult(result, payload, input, inst) {
|
|
|
3565
3605
|
}
|
|
3566
3606
|
|
|
3567
3607
|
//#endregion
|
|
3568
|
-
//#region ../../node_modules/zod/
|
|
3569
|
-
const error$
|
|
3608
|
+
//#region ../../node_modules/zod/v4/locales/ar.js
|
|
3609
|
+
const error$38 = () => {
|
|
3570
3610
|
const Sizable = {
|
|
3571
3611
|
string: {
|
|
3572
3612
|
unit: "حرف",
|
|
@@ -3588,7 +3628,7 @@ const error$36 = () => {
|
|
|
3588
3628
|
function getSizing(origin) {
|
|
3589
3629
|
return Sizable[origin] ?? null;
|
|
3590
3630
|
}
|
|
3591
|
-
const parsedType$
|
|
3631
|
+
const parsedType$3 = (data) => {
|
|
3592
3632
|
const t = typeof data;
|
|
3593
3633
|
switch (t) {
|
|
3594
3634
|
case "number": {
|
|
@@ -3640,7 +3680,7 @@ const error$36 = () => {
|
|
|
3640
3680
|
};
|
|
3641
3681
|
return (issue$1) => {
|
|
3642
3682
|
switch (issue$1.code) {
|
|
3643
|
-
case "invalid_type": return `مدخلات غير مقبولة: يفترض إدخال ${issue$1.expected}، ولكن تم إدخال ${parsedType$
|
|
3683
|
+
case "invalid_type": return `مدخلات غير مقبولة: يفترض إدخال ${issue$1.expected}، ولكن تم إدخال ${parsedType$3(issue$1.input)}`;
|
|
3644
3684
|
case "invalid_value":
|
|
3645
3685
|
if (issue$1.values.length === 1) return `مدخلات غير مقبولة: يفترض إدخال ${stringifyPrimitive(issue$1.values[0])}`;
|
|
3646
3686
|
return `اختيار غير مقبول: يتوقع انتقاء أحد هذه الخيارات: ${joinValues(issue$1.values, "|")}`;
|
|
@@ -3676,12 +3716,12 @@ const error$36 = () => {
|
|
|
3676
3716
|
};
|
|
3677
3717
|
};
|
|
3678
3718
|
function ar_default() {
|
|
3679
|
-
return { localeError: error$
|
|
3719
|
+
return { localeError: error$38() };
|
|
3680
3720
|
}
|
|
3681
3721
|
|
|
3682
3722
|
//#endregion
|
|
3683
|
-
//#region ../../node_modules/zod/
|
|
3684
|
-
const error$
|
|
3723
|
+
//#region ../../node_modules/zod/v4/locales/az.js
|
|
3724
|
+
const error$37 = () => {
|
|
3685
3725
|
const Sizable = {
|
|
3686
3726
|
string: {
|
|
3687
3727
|
unit: "simvol",
|
|
@@ -3703,7 +3743,7 @@ const error$35 = () => {
|
|
|
3703
3743
|
function getSizing(origin) {
|
|
3704
3744
|
return Sizable[origin] ?? null;
|
|
3705
3745
|
}
|
|
3706
|
-
const parsedType$
|
|
3746
|
+
const parsedType$3 = (data) => {
|
|
3707
3747
|
const t = typeof data;
|
|
3708
3748
|
switch (t) {
|
|
3709
3749
|
case "number": {
|
|
@@ -3755,7 +3795,7 @@ const error$35 = () => {
|
|
|
3755
3795
|
};
|
|
3756
3796
|
return (issue$1) => {
|
|
3757
3797
|
switch (issue$1.code) {
|
|
3758
|
-
case "invalid_type": return `Yanlış dəyər: gözlənilən ${issue$1.expected}, daxil olan ${parsedType$
|
|
3798
|
+
case "invalid_type": return `Yanlış dəyər: gözlənilən ${issue$1.expected}, daxil olan ${parsedType$3(issue$1.input)}`;
|
|
3759
3799
|
case "invalid_value":
|
|
3760
3800
|
if (issue$1.values.length === 1) return `Yanlış dəyər: gözlənilən ${stringifyPrimitive(issue$1.values[0])}`;
|
|
3761
3801
|
return `Yanlış seçim: aşağıdakılardan biri olmalıdır: ${joinValues(issue$1.values, "|")}`;
|
|
@@ -3789,11 +3829,11 @@ const error$35 = () => {
|
|
|
3789
3829
|
};
|
|
3790
3830
|
};
|
|
3791
3831
|
function az_default() {
|
|
3792
|
-
return { localeError: error$
|
|
3832
|
+
return { localeError: error$37() };
|
|
3793
3833
|
}
|
|
3794
3834
|
|
|
3795
3835
|
//#endregion
|
|
3796
|
-
//#region ../../node_modules/zod/
|
|
3836
|
+
//#region ../../node_modules/zod/v4/locales/be.js
|
|
3797
3837
|
function getBelarusianPlural(count, one, few, many) {
|
|
3798
3838
|
const absCount = Math.abs(count);
|
|
3799
3839
|
const lastDigit = absCount % 10;
|
|
@@ -3809,7 +3849,7 @@ function getBelarusianPlural(count, one, few, many) {
|
|
|
3809
3849
|
}
|
|
3810
3850
|
return many;
|
|
3811
3851
|
}
|
|
3812
|
-
const error$
|
|
3852
|
+
const error$36 = () => {
|
|
3813
3853
|
const Sizable = {
|
|
3814
3854
|
string: {
|
|
3815
3855
|
unit: {
|
|
@@ -3847,7 +3887,7 @@ const error$34 = () => {
|
|
|
3847
3887
|
function getSizing(origin) {
|
|
3848
3888
|
return Sizable[origin] ?? null;
|
|
3849
3889
|
}
|
|
3850
|
-
const parsedType$
|
|
3890
|
+
const parsedType$3 = (data) => {
|
|
3851
3891
|
const t = typeof data;
|
|
3852
3892
|
switch (t) {
|
|
3853
3893
|
case "number": {
|
|
@@ -3899,7 +3939,7 @@ const error$34 = () => {
|
|
|
3899
3939
|
};
|
|
3900
3940
|
return (issue$1) => {
|
|
3901
3941
|
switch (issue$1.code) {
|
|
3902
|
-
case "invalid_type": return `Няправільны ўвод: чакаўся ${issue$1.expected}, атрымана ${parsedType$
|
|
3942
|
+
case "invalid_type": return `Няправільны ўвод: чакаўся ${issue$1.expected}, атрымана ${parsedType$3(issue$1.input)}`;
|
|
3903
3943
|
case "invalid_value":
|
|
3904
3944
|
if (issue$1.values.length === 1) return `Няправільны ўвод: чакалася ${stringifyPrimitive(issue$1.values[0])}`;
|
|
3905
3945
|
return `Няправільны варыянт: чакаўся адзін з ${joinValues(issue$1.values, "|")}`;
|
|
@@ -3941,12 +3981,12 @@ const error$34 = () => {
|
|
|
3941
3981
|
};
|
|
3942
3982
|
};
|
|
3943
3983
|
function be_default() {
|
|
3944
|
-
return { localeError: error$
|
|
3984
|
+
return { localeError: error$36() };
|
|
3945
3985
|
}
|
|
3946
3986
|
|
|
3947
3987
|
//#endregion
|
|
3948
|
-
//#region ../../node_modules/zod/
|
|
3949
|
-
const error$
|
|
3988
|
+
//#region ../../node_modules/zod/v4/locales/ca.js
|
|
3989
|
+
const error$35 = () => {
|
|
3950
3990
|
const Sizable = {
|
|
3951
3991
|
string: {
|
|
3952
3992
|
unit: "caràcters",
|
|
@@ -3968,7 +4008,7 @@ const error$33 = () => {
|
|
|
3968
4008
|
function getSizing(origin) {
|
|
3969
4009
|
return Sizable[origin] ?? null;
|
|
3970
4010
|
}
|
|
3971
|
-
const parsedType$
|
|
4011
|
+
const parsedType$3 = (data) => {
|
|
3972
4012
|
const t = typeof data;
|
|
3973
4013
|
switch (t) {
|
|
3974
4014
|
case "number": {
|
|
@@ -4020,7 +4060,7 @@ const error$33 = () => {
|
|
|
4020
4060
|
};
|
|
4021
4061
|
return (issue$1) => {
|
|
4022
4062
|
switch (issue$1.code) {
|
|
4023
|
-
case "invalid_type": return `Tipus invàlid: s'esperava ${issue$1.expected}, s'ha rebut ${parsedType$
|
|
4063
|
+
case "invalid_type": return `Tipus invàlid: s'esperava ${issue$1.expected}, s'ha rebut ${parsedType$3(issue$1.input)}`;
|
|
4024
4064
|
case "invalid_value":
|
|
4025
4065
|
if (issue$1.values.length === 1) return `Valor invàlid: s'esperava ${stringifyPrimitive(issue$1.values[0])}`;
|
|
4026
4066
|
return `Opció invàlida: s'esperava una de ${joinValues(issue$1.values, " o ")}`;
|
|
@@ -4058,12 +4098,12 @@ const error$33 = () => {
|
|
|
4058
4098
|
};
|
|
4059
4099
|
};
|
|
4060
4100
|
function ca_default() {
|
|
4061
|
-
return { localeError: error$
|
|
4101
|
+
return { localeError: error$35() };
|
|
4062
4102
|
}
|
|
4063
4103
|
|
|
4064
4104
|
//#endregion
|
|
4065
|
-
//#region ../../node_modules/zod/
|
|
4066
|
-
const error$
|
|
4105
|
+
//#region ../../node_modules/zod/v4/locales/cs.js
|
|
4106
|
+
const error$34 = () => {
|
|
4067
4107
|
const Sizable = {
|
|
4068
4108
|
string: {
|
|
4069
4109
|
unit: "znaků",
|
|
@@ -4085,7 +4125,7 @@ const error$32 = () => {
|
|
|
4085
4125
|
function getSizing(origin) {
|
|
4086
4126
|
return Sizable[origin] ?? null;
|
|
4087
4127
|
}
|
|
4088
|
-
const parsedType$
|
|
4128
|
+
const parsedType$3 = (data) => {
|
|
4089
4129
|
const t = typeof data;
|
|
4090
4130
|
switch (t) {
|
|
4091
4131
|
case "number": {
|
|
@@ -4155,7 +4195,7 @@ const error$32 = () => {
|
|
|
4155
4195
|
};
|
|
4156
4196
|
return (issue$1) => {
|
|
4157
4197
|
switch (issue$1.code) {
|
|
4158
|
-
case "invalid_type": return `Neplatný vstup: očekáváno ${issue$1.expected}, obdrženo ${parsedType$
|
|
4198
|
+
case "invalid_type": return `Neplatný vstup: očekáváno ${issue$1.expected}, obdrženo ${parsedType$3(issue$1.input)}`;
|
|
4159
4199
|
case "invalid_value":
|
|
4160
4200
|
if (issue$1.values.length === 1) return `Neplatný vstup: očekáváno ${stringifyPrimitive(issue$1.values[0])}`;
|
|
4161
4201
|
return `Neplatná možnost: očekávána jedna z hodnot ${joinValues(issue$1.values, "|")}`;
|
|
@@ -4193,12 +4233,12 @@ const error$32 = () => {
|
|
|
4193
4233
|
};
|
|
4194
4234
|
};
|
|
4195
4235
|
function cs_default() {
|
|
4196
|
-
return { localeError: error$
|
|
4236
|
+
return { localeError: error$34() };
|
|
4197
4237
|
}
|
|
4198
4238
|
|
|
4199
4239
|
//#endregion
|
|
4200
|
-
//#region ../../node_modules/zod/
|
|
4201
|
-
const error$
|
|
4240
|
+
//#region ../../node_modules/zod/v4/locales/de.js
|
|
4241
|
+
const error$33 = () => {
|
|
4202
4242
|
const Sizable = {
|
|
4203
4243
|
string: {
|
|
4204
4244
|
unit: "Zeichen",
|
|
@@ -4220,7 +4260,7 @@ const error$31 = () => {
|
|
|
4220
4260
|
function getSizing(origin) {
|
|
4221
4261
|
return Sizable[origin] ?? null;
|
|
4222
4262
|
}
|
|
4223
|
-
const parsedType$
|
|
4263
|
+
const parsedType$3 = (data) => {
|
|
4224
4264
|
const t = typeof data;
|
|
4225
4265
|
switch (t) {
|
|
4226
4266
|
case "number": {
|
|
@@ -4272,7 +4312,7 @@ const error$31 = () => {
|
|
|
4272
4312
|
};
|
|
4273
4313
|
return (issue$1) => {
|
|
4274
4314
|
switch (issue$1.code) {
|
|
4275
|
-
case "invalid_type": return `Ungültige Eingabe: erwartet ${issue$1.expected}, erhalten ${parsedType$
|
|
4315
|
+
case "invalid_type": return `Ungültige Eingabe: erwartet ${issue$1.expected}, erhalten ${parsedType$3(issue$1.input)}`;
|
|
4276
4316
|
case "invalid_value":
|
|
4277
4317
|
if (issue$1.values.length === 1) return `Ungültige Eingabe: erwartet ${stringifyPrimitive(issue$1.values[0])}`;
|
|
4278
4318
|
return `Ungültige Option: erwartet eine von ${joinValues(issue$1.values, "|")}`;
|
|
@@ -4308,12 +4348,12 @@ const error$31 = () => {
|
|
|
4308
4348
|
};
|
|
4309
4349
|
};
|
|
4310
4350
|
function de_default() {
|
|
4311
|
-
return { localeError: error$
|
|
4351
|
+
return { localeError: error$33() };
|
|
4312
4352
|
}
|
|
4313
4353
|
|
|
4314
4354
|
//#endregion
|
|
4315
|
-
//#region ../../node_modules/zod/
|
|
4316
|
-
const parsedType$
|
|
4355
|
+
//#region ../../node_modules/zod/v4/locales/en.js
|
|
4356
|
+
const parsedType$2 = (data) => {
|
|
4317
4357
|
const t = typeof data;
|
|
4318
4358
|
switch (t) {
|
|
4319
4359
|
case "number": {
|
|
@@ -4333,7 +4373,7 @@ const parsedType$1 = (data) => {
|
|
|
4333
4373
|
}
|
|
4334
4374
|
return t;
|
|
4335
4375
|
};
|
|
4336
|
-
const error$
|
|
4376
|
+
const error$32 = () => {
|
|
4337
4377
|
const Sizable = {
|
|
4338
4378
|
string: {
|
|
4339
4379
|
unit: "characters",
|
|
@@ -4387,7 +4427,7 @@ const error$30 = () => {
|
|
|
4387
4427
|
};
|
|
4388
4428
|
return (issue$1) => {
|
|
4389
4429
|
switch (issue$1.code) {
|
|
4390
|
-
case "invalid_type": return `Invalid input: expected ${issue$1.expected}, received ${parsedType$
|
|
4430
|
+
case "invalid_type": return `Invalid input: expected ${issue$1.expected}, received ${parsedType$2(issue$1.input)}`;
|
|
4391
4431
|
case "invalid_value":
|
|
4392
4432
|
if (issue$1.values.length === 1) return `Invalid input: expected ${stringifyPrimitive(issue$1.values[0])}`;
|
|
4393
4433
|
return `Invalid option: expected one of ${joinValues(issue$1.values, "|")}`;
|
|
@@ -4425,12 +4465,127 @@ const error$30 = () => {
|
|
|
4425
4465
|
};
|
|
4426
4466
|
};
|
|
4427
4467
|
function en_default() {
|
|
4428
|
-
return { localeError: error$
|
|
4468
|
+
return { localeError: error$32() };
|
|
4429
4469
|
}
|
|
4430
4470
|
|
|
4431
4471
|
//#endregion
|
|
4432
|
-
//#region ../../node_modules/zod/
|
|
4433
|
-
const
|
|
4472
|
+
//#region ../../node_modules/zod/v4/locales/eo.js
|
|
4473
|
+
const parsedType$1 = (data) => {
|
|
4474
|
+
const t = typeof data;
|
|
4475
|
+
switch (t) {
|
|
4476
|
+
case "number": {
|
|
4477
|
+
return Number.isNaN(data) ? "NaN" : "nombro";
|
|
4478
|
+
}
|
|
4479
|
+
case "object": {
|
|
4480
|
+
if (Array.isArray(data)) {
|
|
4481
|
+
return "tabelo";
|
|
4482
|
+
}
|
|
4483
|
+
if (data === null) {
|
|
4484
|
+
return "senvalora";
|
|
4485
|
+
}
|
|
4486
|
+
if (Object.getPrototypeOf(data) !== Object.prototype && data.constructor) {
|
|
4487
|
+
return data.constructor.name;
|
|
4488
|
+
}
|
|
4489
|
+
}
|
|
4490
|
+
}
|
|
4491
|
+
return t;
|
|
4492
|
+
};
|
|
4493
|
+
const error$31 = () => {
|
|
4494
|
+
const Sizable = {
|
|
4495
|
+
string: {
|
|
4496
|
+
unit: "karaktrojn",
|
|
4497
|
+
verb: "havi"
|
|
4498
|
+
},
|
|
4499
|
+
file: {
|
|
4500
|
+
unit: "bajtojn",
|
|
4501
|
+
verb: "havi"
|
|
4502
|
+
},
|
|
4503
|
+
array: {
|
|
4504
|
+
unit: "elementojn",
|
|
4505
|
+
verb: "havi"
|
|
4506
|
+
},
|
|
4507
|
+
set: {
|
|
4508
|
+
unit: "elementojn",
|
|
4509
|
+
verb: "havi"
|
|
4510
|
+
}
|
|
4511
|
+
};
|
|
4512
|
+
function getSizing(origin) {
|
|
4513
|
+
return Sizable[origin] ?? null;
|
|
4514
|
+
}
|
|
4515
|
+
const Nouns = {
|
|
4516
|
+
regex: "enigo",
|
|
4517
|
+
email: "retadreso",
|
|
4518
|
+
url: "URL",
|
|
4519
|
+
emoji: "emoĝio",
|
|
4520
|
+
uuid: "UUID",
|
|
4521
|
+
uuidv4: "UUIDv4",
|
|
4522
|
+
uuidv6: "UUIDv6",
|
|
4523
|
+
nanoid: "nanoid",
|
|
4524
|
+
guid: "GUID",
|
|
4525
|
+
cuid: "cuid",
|
|
4526
|
+
cuid2: "cuid2",
|
|
4527
|
+
ulid: "ULID",
|
|
4528
|
+
xid: "XID",
|
|
4529
|
+
ksuid: "KSUID",
|
|
4530
|
+
datetime: "ISO-datotempo",
|
|
4531
|
+
date: "ISO-dato",
|
|
4532
|
+
time: "ISO-tempo",
|
|
4533
|
+
duration: "ISO-daŭro",
|
|
4534
|
+
ipv4: "IPv4-adreso",
|
|
4535
|
+
ipv6: "IPv6-adreso",
|
|
4536
|
+
cidrv4: "IPv4-rango",
|
|
4537
|
+
cidrv6: "IPv6-rango",
|
|
4538
|
+
base64: "64-ume kodita karaktraro",
|
|
4539
|
+
base64url: "URL-64-ume kodita karaktraro",
|
|
4540
|
+
json_string: "JSON-karaktraro",
|
|
4541
|
+
e164: "E.164-nombro",
|
|
4542
|
+
jwt: "JWT",
|
|
4543
|
+
template_literal: "enigo"
|
|
4544
|
+
};
|
|
4545
|
+
return (issue$1) => {
|
|
4546
|
+
switch (issue$1.code) {
|
|
4547
|
+
case "invalid_type": return `Nevalida enigo: atendiĝis ${issue$1.expected}, riceviĝis ${parsedType$1(issue$1.input)}`;
|
|
4548
|
+
case "invalid_value":
|
|
4549
|
+
if (issue$1.values.length === 1) return `Nevalida enigo: atendiĝis ${stringifyPrimitive(issue$1.values[0])}`;
|
|
4550
|
+
return `Nevalida opcio: atendiĝis unu el ${joinValues(issue$1.values, "|")}`;
|
|
4551
|
+
case "too_big": {
|
|
4552
|
+
const adj = issue$1.inclusive ? "<=" : "<";
|
|
4553
|
+
const sizing = getSizing(issue$1.origin);
|
|
4554
|
+
if (sizing) return `Tro granda: atendiĝis ke ${issue$1.origin ?? "valoro"} havu ${adj}${issue$1.maximum.toString()} ${sizing.unit ?? "elementojn"}`;
|
|
4555
|
+
return `Tro granda: atendiĝis ke ${issue$1.origin ?? "valoro"} havu ${adj}${issue$1.maximum.toString()}`;
|
|
4556
|
+
}
|
|
4557
|
+
case "too_small": {
|
|
4558
|
+
const adj = issue$1.inclusive ? ">=" : ">";
|
|
4559
|
+
const sizing = getSizing(issue$1.origin);
|
|
4560
|
+
if (sizing) {
|
|
4561
|
+
return `Tro malgranda: atendiĝis ke ${issue$1.origin} havu ${adj}${issue$1.minimum.toString()} ${sizing.unit}`;
|
|
4562
|
+
}
|
|
4563
|
+
return `Tro malgranda: atendiĝis ke ${issue$1.origin} estu ${adj}${issue$1.minimum.toString()}`;
|
|
4564
|
+
}
|
|
4565
|
+
case "invalid_format": {
|
|
4566
|
+
const _issue = issue$1;
|
|
4567
|
+
if (_issue.format === "starts_with") return `Nevalida karaktraro: devas komenciĝi per "${_issue.prefix}"`;
|
|
4568
|
+
if (_issue.format === "ends_with") return `Nevalida karaktraro: devas finiĝi per "${_issue.suffix}"`;
|
|
4569
|
+
if (_issue.format === "includes") return `Nevalida karaktraro: devas inkluzivi "${_issue.includes}"`;
|
|
4570
|
+
if (_issue.format === "regex") return `Nevalida karaktraro: devas kongrui kun la modelo ${_issue.pattern}`;
|
|
4571
|
+
return `Nevalida ${Nouns[_issue.format] ?? issue$1.format}`;
|
|
4572
|
+
}
|
|
4573
|
+
case "not_multiple_of": return `Nevalida nombro: devas esti oblo de ${issue$1.divisor}`;
|
|
4574
|
+
case "unrecognized_keys": return `Nekonata${issue$1.keys.length > 1 ? "j" : ""} ŝlosilo${issue$1.keys.length > 1 ? "j" : ""}: ${joinValues(issue$1.keys, ", ")}`;
|
|
4575
|
+
case "invalid_key": return `Nevalida ŝlosilo en ${issue$1.origin}`;
|
|
4576
|
+
case "invalid_union": return "Nevalida enigo";
|
|
4577
|
+
case "invalid_element": return `Nevalida valoro en ${issue$1.origin}`;
|
|
4578
|
+
default: return `Nevalida enigo`;
|
|
4579
|
+
}
|
|
4580
|
+
};
|
|
4581
|
+
};
|
|
4582
|
+
function eo_default() {
|
|
4583
|
+
return { localeError: error$31() };
|
|
4584
|
+
}
|
|
4585
|
+
|
|
4586
|
+
//#endregion
|
|
4587
|
+
//#region ../../node_modules/zod/v4/locales/es.js
|
|
4588
|
+
const error$30 = () => {
|
|
4434
4589
|
const Sizable = {
|
|
4435
4590
|
string: {
|
|
4436
4591
|
unit: "caracteres",
|
|
@@ -4452,7 +4607,7 @@ const error$29 = () => {
|
|
|
4452
4607
|
function getSizing(origin) {
|
|
4453
4608
|
return Sizable[origin] ?? null;
|
|
4454
4609
|
}
|
|
4455
|
-
const parsedType$
|
|
4610
|
+
const parsedType$3 = (data) => {
|
|
4456
4611
|
const t = typeof data;
|
|
4457
4612
|
switch (t) {
|
|
4458
4613
|
case "number": {
|
|
@@ -4504,7 +4659,7 @@ const error$29 = () => {
|
|
|
4504
4659
|
};
|
|
4505
4660
|
return (issue$1) => {
|
|
4506
4661
|
switch (issue$1.code) {
|
|
4507
|
-
case "invalid_type": return `Entrada inválida: se esperaba ${issue$1.expected}, recibido ${parsedType$
|
|
4662
|
+
case "invalid_type": return `Entrada inválida: se esperaba ${issue$1.expected}, recibido ${parsedType$3(issue$1.input)}`;
|
|
4508
4663
|
case "invalid_value":
|
|
4509
4664
|
if (issue$1.values.length === 1) return `Entrada inválida: se esperaba ${stringifyPrimitive(issue$1.values[0])}`;
|
|
4510
4665
|
return `Opción inválida: se esperaba una de ${joinValues(issue$1.values, "|")}`;
|
|
@@ -4540,12 +4695,12 @@ const error$29 = () => {
|
|
|
4540
4695
|
};
|
|
4541
4696
|
};
|
|
4542
4697
|
function es_default() {
|
|
4543
|
-
return { localeError: error$
|
|
4698
|
+
return { localeError: error$30() };
|
|
4544
4699
|
}
|
|
4545
4700
|
|
|
4546
4701
|
//#endregion
|
|
4547
|
-
//#region ../../node_modules/zod/
|
|
4548
|
-
const error$
|
|
4702
|
+
//#region ../../node_modules/zod/v4/locales/fa.js
|
|
4703
|
+
const error$29 = () => {
|
|
4549
4704
|
const Sizable = {
|
|
4550
4705
|
string: {
|
|
4551
4706
|
unit: "کاراکتر",
|
|
@@ -4567,7 +4722,7 @@ const error$28 = () => {
|
|
|
4567
4722
|
function getSizing(origin) {
|
|
4568
4723
|
return Sizable[origin] ?? null;
|
|
4569
4724
|
}
|
|
4570
|
-
const parsedType$
|
|
4725
|
+
const parsedType$3 = (data) => {
|
|
4571
4726
|
const t = typeof data;
|
|
4572
4727
|
switch (t) {
|
|
4573
4728
|
case "number": {
|
|
@@ -4619,7 +4774,7 @@ const error$28 = () => {
|
|
|
4619
4774
|
};
|
|
4620
4775
|
return (issue$1) => {
|
|
4621
4776
|
switch (issue$1.code) {
|
|
4622
|
-
case "invalid_type": return `ورودی نامعتبر: میبایست ${issue$1.expected} میبود، ${parsedType$
|
|
4777
|
+
case "invalid_type": return `ورودی نامعتبر: میبایست ${issue$1.expected} میبود، ${parsedType$3(issue$1.input)} دریافت شد`;
|
|
4623
4778
|
case "invalid_value":
|
|
4624
4779
|
if (issue$1.values.length === 1) {
|
|
4625
4780
|
return `ورودی نامعتبر: میبایست ${stringifyPrimitive(issue$1.values[0])} میبود`;
|
|
@@ -4667,12 +4822,12 @@ const error$28 = () => {
|
|
|
4667
4822
|
};
|
|
4668
4823
|
};
|
|
4669
4824
|
function fa_default() {
|
|
4670
|
-
return { localeError: error$
|
|
4825
|
+
return { localeError: error$29() };
|
|
4671
4826
|
}
|
|
4672
4827
|
|
|
4673
4828
|
//#endregion
|
|
4674
|
-
//#region ../../node_modules/zod/
|
|
4675
|
-
const error$
|
|
4829
|
+
//#region ../../node_modules/zod/v4/locales/fi.js
|
|
4830
|
+
const error$28 = () => {
|
|
4676
4831
|
const Sizable = {
|
|
4677
4832
|
string: {
|
|
4678
4833
|
unit: "merkkiä",
|
|
@@ -4710,7 +4865,7 @@ const error$27 = () => {
|
|
|
4710
4865
|
function getSizing(origin) {
|
|
4711
4866
|
return Sizable[origin] ?? null;
|
|
4712
4867
|
}
|
|
4713
|
-
const parsedType$
|
|
4868
|
+
const parsedType$3 = (data) => {
|
|
4714
4869
|
const t = typeof data;
|
|
4715
4870
|
switch (t) {
|
|
4716
4871
|
case "number": {
|
|
@@ -4762,7 +4917,7 @@ const error$27 = () => {
|
|
|
4762
4917
|
};
|
|
4763
4918
|
return (issue$1) => {
|
|
4764
4919
|
switch (issue$1.code) {
|
|
4765
|
-
case "invalid_type": return `Virheellinen tyyppi: odotettiin ${issue$1.expected}, oli ${parsedType$
|
|
4920
|
+
case "invalid_type": return `Virheellinen tyyppi: odotettiin ${issue$1.expected}, oli ${parsedType$3(issue$1.input)}`;
|
|
4766
4921
|
case "invalid_value":
|
|
4767
4922
|
if (issue$1.values.length === 1) return `Virheellinen syöte: täytyy olla ${stringifyPrimitive(issue$1.values[0])}`;
|
|
4768
4923
|
return `Virheellinen valinta: täytyy olla yksi seuraavista: ${joinValues(issue$1.values, "|")}`;
|
|
@@ -4802,12 +4957,12 @@ const error$27 = () => {
|
|
|
4802
4957
|
};
|
|
4803
4958
|
};
|
|
4804
4959
|
function fi_default() {
|
|
4805
|
-
return { localeError: error$
|
|
4960
|
+
return { localeError: error$28() };
|
|
4806
4961
|
}
|
|
4807
4962
|
|
|
4808
4963
|
//#endregion
|
|
4809
|
-
//#region ../../node_modules/zod/
|
|
4810
|
-
const error$
|
|
4964
|
+
//#region ../../node_modules/zod/v4/locales/fr.js
|
|
4965
|
+
const error$27 = () => {
|
|
4811
4966
|
const Sizable = {
|
|
4812
4967
|
string: {
|
|
4813
4968
|
unit: "caractères",
|
|
@@ -4829,7 +4984,7 @@ const error$26 = () => {
|
|
|
4829
4984
|
function getSizing(origin) {
|
|
4830
4985
|
return Sizable[origin] ?? null;
|
|
4831
4986
|
}
|
|
4832
|
-
const parsedType$
|
|
4987
|
+
const parsedType$3 = (data) => {
|
|
4833
4988
|
const t = typeof data;
|
|
4834
4989
|
switch (t) {
|
|
4835
4990
|
case "number": {
|
|
@@ -4881,7 +5036,7 @@ const error$26 = () => {
|
|
|
4881
5036
|
};
|
|
4882
5037
|
return (issue$1) => {
|
|
4883
5038
|
switch (issue$1.code) {
|
|
4884
|
-
case "invalid_type": return `Entrée invalide : ${issue$1.expected} attendu, ${parsedType$
|
|
5039
|
+
case "invalid_type": return `Entrée invalide : ${issue$1.expected} attendu, ${parsedType$3(issue$1.input)} reçu`;
|
|
4885
5040
|
case "invalid_value":
|
|
4886
5041
|
if (issue$1.values.length === 1) return `Entrée invalide : ${stringifyPrimitive(issue$1.values[0])} attendu`;
|
|
4887
5042
|
return `Option invalide : une valeur parmi ${joinValues(issue$1.values, "|")} attendue`;
|
|
@@ -4917,12 +5072,12 @@ const error$26 = () => {
|
|
|
4917
5072
|
};
|
|
4918
5073
|
};
|
|
4919
5074
|
function fr_default() {
|
|
4920
|
-
return { localeError: error$
|
|
5075
|
+
return { localeError: error$27() };
|
|
4921
5076
|
}
|
|
4922
5077
|
|
|
4923
5078
|
//#endregion
|
|
4924
|
-
//#region ../../node_modules/zod/
|
|
4925
|
-
const error$
|
|
5079
|
+
//#region ../../node_modules/zod/v4/locales/fr-CA.js
|
|
5080
|
+
const error$26 = () => {
|
|
4926
5081
|
const Sizable = {
|
|
4927
5082
|
string: {
|
|
4928
5083
|
unit: "caractères",
|
|
@@ -4944,7 +5099,7 @@ const error$25 = () => {
|
|
|
4944
5099
|
function getSizing(origin) {
|
|
4945
5100
|
return Sizable[origin] ?? null;
|
|
4946
5101
|
}
|
|
4947
|
-
const parsedType$
|
|
5102
|
+
const parsedType$3 = (data) => {
|
|
4948
5103
|
const t = typeof data;
|
|
4949
5104
|
switch (t) {
|
|
4950
5105
|
case "number": {
|
|
@@ -4996,7 +5151,7 @@ const error$25 = () => {
|
|
|
4996
5151
|
};
|
|
4997
5152
|
return (issue$1) => {
|
|
4998
5153
|
switch (issue$1.code) {
|
|
4999
|
-
case "invalid_type": return `Entrée invalide : attendu ${issue$1.expected}, reçu ${parsedType$
|
|
5154
|
+
case "invalid_type": return `Entrée invalide : attendu ${issue$1.expected}, reçu ${parsedType$3(issue$1.input)}`;
|
|
5000
5155
|
case "invalid_value":
|
|
5001
5156
|
if (issue$1.values.length === 1) return `Entrée invalide : attendu ${stringifyPrimitive(issue$1.values[0])}`;
|
|
5002
5157
|
return `Option invalide : attendu l'une des valeurs suivantes ${joinValues(issue$1.values, "|")}`;
|
|
@@ -5034,12 +5189,12 @@ const error$25 = () => {
|
|
|
5034
5189
|
};
|
|
5035
5190
|
};
|
|
5036
5191
|
function fr_CA_default() {
|
|
5037
|
-
return { localeError: error$
|
|
5192
|
+
return { localeError: error$26() };
|
|
5038
5193
|
}
|
|
5039
5194
|
|
|
5040
5195
|
//#endregion
|
|
5041
|
-
//#region ../../node_modules/zod/
|
|
5042
|
-
const error$
|
|
5196
|
+
//#region ../../node_modules/zod/v4/locales/he.js
|
|
5197
|
+
const error$25 = () => {
|
|
5043
5198
|
const Sizable = {
|
|
5044
5199
|
string: {
|
|
5045
5200
|
unit: "אותיות",
|
|
@@ -5061,7 +5216,7 @@ const error$24 = () => {
|
|
|
5061
5216
|
function getSizing(origin) {
|
|
5062
5217
|
return Sizable[origin] ?? null;
|
|
5063
5218
|
}
|
|
5064
|
-
const parsedType$
|
|
5219
|
+
const parsedType$3 = (data) => {
|
|
5065
5220
|
const t = typeof data;
|
|
5066
5221
|
switch (t) {
|
|
5067
5222
|
case "number": {
|
|
@@ -5113,7 +5268,7 @@ const error$24 = () => {
|
|
|
5113
5268
|
};
|
|
5114
5269
|
return (issue$1) => {
|
|
5115
5270
|
switch (issue$1.code) {
|
|
5116
|
-
case "invalid_type": return `קלט לא תקין: צריך ${issue$1.expected}, התקבל ${parsedType$
|
|
5271
|
+
case "invalid_type": return `קלט לא תקין: צריך ${issue$1.expected}, התקבל ${parsedType$3(issue$1.input)}`;
|
|
5117
5272
|
case "invalid_value":
|
|
5118
5273
|
if (issue$1.values.length === 1) return `קלט לא תקין: צריך ${stringifyPrimitive(issue$1.values[0])}`;
|
|
5119
5274
|
return `קלט לא תקין: צריך אחת מהאפשרויות ${joinValues(issue$1.values, "|")}`;
|
|
@@ -5149,12 +5304,12 @@ const error$24 = () => {
|
|
|
5149
5304
|
};
|
|
5150
5305
|
};
|
|
5151
5306
|
function he_default() {
|
|
5152
|
-
return { localeError: error$
|
|
5307
|
+
return { localeError: error$25() };
|
|
5153
5308
|
}
|
|
5154
5309
|
|
|
5155
5310
|
//#endregion
|
|
5156
|
-
//#region ../../node_modules/zod/
|
|
5157
|
-
const error$
|
|
5311
|
+
//#region ../../node_modules/zod/v4/locales/hu.js
|
|
5312
|
+
const error$24 = () => {
|
|
5158
5313
|
const Sizable = {
|
|
5159
5314
|
string: {
|
|
5160
5315
|
unit: "karakter",
|
|
@@ -5176,7 +5331,7 @@ const error$23 = () => {
|
|
|
5176
5331
|
function getSizing(origin) {
|
|
5177
5332
|
return Sizable[origin] ?? null;
|
|
5178
5333
|
}
|
|
5179
|
-
const parsedType$
|
|
5334
|
+
const parsedType$3 = (data) => {
|
|
5180
5335
|
const t = typeof data;
|
|
5181
5336
|
switch (t) {
|
|
5182
5337
|
case "number": {
|
|
@@ -5228,7 +5383,7 @@ const error$23 = () => {
|
|
|
5228
5383
|
};
|
|
5229
5384
|
return (issue$1) => {
|
|
5230
5385
|
switch (issue$1.code) {
|
|
5231
|
-
case "invalid_type": return `Érvénytelen bemenet: a várt érték ${issue$1.expected}, a kapott érték ${parsedType$
|
|
5386
|
+
case "invalid_type": return `Érvénytelen bemenet: a várt érték ${issue$1.expected}, a kapott érték ${parsedType$3(issue$1.input)}`;
|
|
5232
5387
|
case "invalid_value":
|
|
5233
5388
|
if (issue$1.values.length === 1) return `Érvénytelen bemenet: a várt érték ${stringifyPrimitive(issue$1.values[0])}`;
|
|
5234
5389
|
return `Érvénytelen opció: valamelyik érték várt ${joinValues(issue$1.values, "|")}`;
|
|
@@ -5264,12 +5419,12 @@ const error$23 = () => {
|
|
|
5264
5419
|
};
|
|
5265
5420
|
};
|
|
5266
5421
|
function hu_default() {
|
|
5267
|
-
return { localeError: error$
|
|
5422
|
+
return { localeError: error$24() };
|
|
5268
5423
|
}
|
|
5269
5424
|
|
|
5270
5425
|
//#endregion
|
|
5271
|
-
//#region ../../node_modules/zod/
|
|
5272
|
-
const error$
|
|
5426
|
+
//#region ../../node_modules/zod/v4/locales/id.js
|
|
5427
|
+
const error$23 = () => {
|
|
5273
5428
|
const Sizable = {
|
|
5274
5429
|
string: {
|
|
5275
5430
|
unit: "karakter",
|
|
@@ -5291,7 +5446,7 @@ const error$22 = () => {
|
|
|
5291
5446
|
function getSizing(origin) {
|
|
5292
5447
|
return Sizable[origin] ?? null;
|
|
5293
5448
|
}
|
|
5294
|
-
const parsedType$
|
|
5449
|
+
const parsedType$3 = (data) => {
|
|
5295
5450
|
const t = typeof data;
|
|
5296
5451
|
switch (t) {
|
|
5297
5452
|
case "number": {
|
|
@@ -5343,7 +5498,7 @@ const error$22 = () => {
|
|
|
5343
5498
|
};
|
|
5344
5499
|
return (issue$1) => {
|
|
5345
5500
|
switch (issue$1.code) {
|
|
5346
|
-
case "invalid_type": return `Input tidak valid: diharapkan ${issue$1.expected}, diterima ${parsedType$
|
|
5501
|
+
case "invalid_type": return `Input tidak valid: diharapkan ${issue$1.expected}, diterima ${parsedType$3(issue$1.input)}`;
|
|
5347
5502
|
case "invalid_value":
|
|
5348
5503
|
if (issue$1.values.length === 1) return `Input tidak valid: diharapkan ${stringifyPrimitive(issue$1.values[0])}`;
|
|
5349
5504
|
return `Pilihan tidak valid: diharapkan salah satu dari ${joinValues(issue$1.values, "|")}`;
|
|
@@ -5379,12 +5534,12 @@ const error$22 = () => {
|
|
|
5379
5534
|
};
|
|
5380
5535
|
};
|
|
5381
5536
|
function id_default() {
|
|
5382
|
-
return { localeError: error$
|
|
5537
|
+
return { localeError: error$23() };
|
|
5383
5538
|
}
|
|
5384
5539
|
|
|
5385
5540
|
//#endregion
|
|
5386
|
-
//#region ../../node_modules/zod/
|
|
5387
|
-
const error$
|
|
5541
|
+
//#region ../../node_modules/zod/v4/locales/it.js
|
|
5542
|
+
const error$22 = () => {
|
|
5388
5543
|
const Sizable = {
|
|
5389
5544
|
string: {
|
|
5390
5545
|
unit: "caratteri",
|
|
@@ -5406,7 +5561,7 @@ const error$21 = () => {
|
|
|
5406
5561
|
function getSizing(origin) {
|
|
5407
5562
|
return Sizable[origin] ?? null;
|
|
5408
5563
|
}
|
|
5409
|
-
const parsedType$
|
|
5564
|
+
const parsedType$3 = (data) => {
|
|
5410
5565
|
const t = typeof data;
|
|
5411
5566
|
switch (t) {
|
|
5412
5567
|
case "number": {
|
|
@@ -5458,7 +5613,7 @@ const error$21 = () => {
|
|
|
5458
5613
|
};
|
|
5459
5614
|
return (issue$1) => {
|
|
5460
5615
|
switch (issue$1.code) {
|
|
5461
|
-
case "invalid_type": return `Input non valido: atteso ${issue$1.expected}, ricevuto ${parsedType$
|
|
5616
|
+
case "invalid_type": return `Input non valido: atteso ${issue$1.expected}, ricevuto ${parsedType$3(issue$1.input)}`;
|
|
5462
5617
|
case "invalid_value":
|
|
5463
5618
|
if (issue$1.values.length === 1) return `Input non valido: atteso ${stringifyPrimitive(issue$1.values[0])}`;
|
|
5464
5619
|
return `Opzione non valida: atteso uno tra ${joinValues(issue$1.values, "|")}`;
|
|
@@ -5494,12 +5649,12 @@ const error$21 = () => {
|
|
|
5494
5649
|
};
|
|
5495
5650
|
};
|
|
5496
5651
|
function it_default() {
|
|
5497
|
-
return { localeError: error$
|
|
5652
|
+
return { localeError: error$22() };
|
|
5498
5653
|
}
|
|
5499
5654
|
|
|
5500
5655
|
//#endregion
|
|
5501
|
-
//#region ../../node_modules/zod/
|
|
5502
|
-
const error$
|
|
5656
|
+
//#region ../../node_modules/zod/v4/locales/ja.js
|
|
5657
|
+
const error$21 = () => {
|
|
5503
5658
|
const Sizable = {
|
|
5504
5659
|
string: {
|
|
5505
5660
|
unit: "文字",
|
|
@@ -5521,7 +5676,7 @@ const error$20 = () => {
|
|
|
5521
5676
|
function getSizing(origin) {
|
|
5522
5677
|
return Sizable[origin] ?? null;
|
|
5523
5678
|
}
|
|
5524
|
-
const parsedType$
|
|
5679
|
+
const parsedType$3 = (data) => {
|
|
5525
5680
|
const t = typeof data;
|
|
5526
5681
|
switch (t) {
|
|
5527
5682
|
case "number": {
|
|
@@ -5573,21 +5728,21 @@ const error$20 = () => {
|
|
|
5573
5728
|
};
|
|
5574
5729
|
return (issue$1) => {
|
|
5575
5730
|
switch (issue$1.code) {
|
|
5576
|
-
case "invalid_type": return `無効な入力: ${issue$1.expected}が期待されましたが、${parsedType$
|
|
5731
|
+
case "invalid_type": return `無効な入力: ${issue$1.expected}が期待されましたが、${parsedType$3(issue$1.input)}が入力されました`;
|
|
5577
5732
|
case "invalid_value":
|
|
5578
5733
|
if (issue$1.values.length === 1) return `無効な入力: ${stringifyPrimitive(issue$1.values[0])}が期待されました`;
|
|
5579
5734
|
return `無効な選択: ${joinValues(issue$1.values, "、")}のいずれかである必要があります`;
|
|
5580
5735
|
case "too_big": {
|
|
5581
|
-
const adj = issue$1.inclusive ? "
|
|
5736
|
+
const adj = issue$1.inclusive ? "以下である" : "より小さい";
|
|
5582
5737
|
const sizing = getSizing(issue$1.origin);
|
|
5583
|
-
if (sizing) return `大きすぎる値: ${issue$1.origin ?? "値"}は${issue$1.maximum.toString()}${sizing.unit ?? "要素"}${adj}
|
|
5584
|
-
return `大きすぎる値: ${issue$1.origin ?? "値"}は${issue$1.maximum.toString()}${adj}
|
|
5738
|
+
if (sizing) return `大きすぎる値: ${issue$1.origin ?? "値"}は${issue$1.maximum.toString()}${sizing.unit ?? "要素"}${adj}必要があります`;
|
|
5739
|
+
return `大きすぎる値: ${issue$1.origin ?? "値"}は${issue$1.maximum.toString()}${adj}必要があります`;
|
|
5585
5740
|
}
|
|
5586
5741
|
case "too_small": {
|
|
5587
|
-
const adj = issue$1.inclusive ? "
|
|
5742
|
+
const adj = issue$1.inclusive ? "以上である" : "より大きい";
|
|
5588
5743
|
const sizing = getSizing(issue$1.origin);
|
|
5589
|
-
if (sizing) return `小さすぎる値: ${issue$1.origin}は${issue$1.minimum.toString()}${sizing.unit}${adj}
|
|
5590
|
-
return `小さすぎる値: ${issue$1.origin}は${issue$1.minimum.toString()}${adj}
|
|
5744
|
+
if (sizing) return `小さすぎる値: ${issue$1.origin}は${issue$1.minimum.toString()}${sizing.unit}${adj}必要があります`;
|
|
5745
|
+
return `小さすぎる値: ${issue$1.origin}は${issue$1.minimum.toString()}${adj}必要があります`;
|
|
5591
5746
|
}
|
|
5592
5747
|
case "invalid_format": {
|
|
5593
5748
|
const _issue = issue$1;
|
|
@@ -5607,12 +5762,12 @@ const error$20 = () => {
|
|
|
5607
5762
|
};
|
|
5608
5763
|
};
|
|
5609
5764
|
function ja_default() {
|
|
5610
|
-
return { localeError: error$
|
|
5765
|
+
return { localeError: error$21() };
|
|
5611
5766
|
}
|
|
5612
5767
|
|
|
5613
5768
|
//#endregion
|
|
5614
|
-
//#region ../../node_modules/zod/
|
|
5615
|
-
const error$
|
|
5769
|
+
//#region ../../node_modules/zod/v4/locales/kh.js
|
|
5770
|
+
const error$20 = () => {
|
|
5616
5771
|
const Sizable = {
|
|
5617
5772
|
string: {
|
|
5618
5773
|
unit: "តួអក្សរ",
|
|
@@ -5634,7 +5789,7 @@ const error$19 = () => {
|
|
|
5634
5789
|
function getSizing(origin) {
|
|
5635
5790
|
return Sizable[origin] ?? null;
|
|
5636
5791
|
}
|
|
5637
|
-
const parsedType$
|
|
5792
|
+
const parsedType$3 = (data) => {
|
|
5638
5793
|
const t = typeof data;
|
|
5639
5794
|
switch (t) {
|
|
5640
5795
|
case "number": {
|
|
@@ -5686,7 +5841,7 @@ const error$19 = () => {
|
|
|
5686
5841
|
};
|
|
5687
5842
|
return (issue$1) => {
|
|
5688
5843
|
switch (issue$1.code) {
|
|
5689
|
-
case "invalid_type": return `ទិន្នន័យបញ្ចូលមិនត្រឹមត្រូវ៖ ត្រូវការ ${issue$1.expected} ប៉ុន្តែទទួលបាន ${parsedType$
|
|
5844
|
+
case "invalid_type": return `ទិន្នន័យបញ្ចូលមិនត្រឹមត្រូវ៖ ត្រូវការ ${issue$1.expected} ប៉ុន្តែទទួលបាន ${parsedType$3(issue$1.input)}`;
|
|
5690
5845
|
case "invalid_value":
|
|
5691
5846
|
if (issue$1.values.length === 1) return `ទិន្នន័យបញ្ចូលមិនត្រឹមត្រូវ៖ ត្រូវការ ${stringifyPrimitive(issue$1.values[0])}`;
|
|
5692
5847
|
return `ជម្រើសមិនត្រឹមត្រូវ៖ ត្រូវជាមួយក្នុងចំណោម ${joinValues(issue$1.values, "|")}`;
|
|
@@ -5724,12 +5879,12 @@ const error$19 = () => {
|
|
|
5724
5879
|
};
|
|
5725
5880
|
};
|
|
5726
5881
|
function kh_default() {
|
|
5727
|
-
return { localeError: error$
|
|
5882
|
+
return { localeError: error$20() };
|
|
5728
5883
|
}
|
|
5729
5884
|
|
|
5730
5885
|
//#endregion
|
|
5731
|
-
//#region ../../node_modules/zod/
|
|
5732
|
-
const error$
|
|
5886
|
+
//#region ../../node_modules/zod/v4/locales/ko.js
|
|
5887
|
+
const error$19 = () => {
|
|
5733
5888
|
const Sizable = {
|
|
5734
5889
|
string: {
|
|
5735
5890
|
unit: "문자",
|
|
@@ -5751,7 +5906,7 @@ const error$18 = () => {
|
|
|
5751
5906
|
function getSizing(origin) {
|
|
5752
5907
|
return Sizable[origin] ?? null;
|
|
5753
5908
|
}
|
|
5754
|
-
const parsedType$
|
|
5909
|
+
const parsedType$3 = (data) => {
|
|
5755
5910
|
const t = typeof data;
|
|
5756
5911
|
switch (t) {
|
|
5757
5912
|
case "number": {
|
|
@@ -5803,7 +5958,7 @@ const error$18 = () => {
|
|
|
5803
5958
|
};
|
|
5804
5959
|
return (issue$1) => {
|
|
5805
5960
|
switch (issue$1.code) {
|
|
5806
|
-
case "invalid_type": return `잘못된 입력: 예상 타입은 ${issue$1.expected}, 받은 타입은 ${parsedType$
|
|
5961
|
+
case "invalid_type": return `잘못된 입력: 예상 타입은 ${issue$1.expected}, 받은 타입은 ${parsedType$3(issue$1.input)}입니다`;
|
|
5807
5962
|
case "invalid_value":
|
|
5808
5963
|
if (issue$1.values.length === 1) return `잘못된 입력: 값은 ${stringifyPrimitive(issue$1.values[0])} 이어야 합니다`;
|
|
5809
5964
|
return `잘못된 옵션: ${joinValues(issue$1.values, "또는 ")} 중 하나여야 합니다`;
|
|
@@ -5845,12 +6000,12 @@ const error$18 = () => {
|
|
|
5845
6000
|
};
|
|
5846
6001
|
};
|
|
5847
6002
|
function ko_default() {
|
|
5848
|
-
return { localeError: error$
|
|
6003
|
+
return { localeError: error$19() };
|
|
5849
6004
|
}
|
|
5850
6005
|
|
|
5851
6006
|
//#endregion
|
|
5852
|
-
//#region ../../node_modules/zod/
|
|
5853
|
-
const error$
|
|
6007
|
+
//#region ../../node_modules/zod/v4/locales/mk.js
|
|
6008
|
+
const error$18 = () => {
|
|
5854
6009
|
const Sizable = {
|
|
5855
6010
|
string: {
|
|
5856
6011
|
unit: "знаци",
|
|
@@ -5872,7 +6027,7 @@ const error$17 = () => {
|
|
|
5872
6027
|
function getSizing(origin) {
|
|
5873
6028
|
return Sizable[origin] ?? null;
|
|
5874
6029
|
}
|
|
5875
|
-
const parsedType$
|
|
6030
|
+
const parsedType$3 = (data) => {
|
|
5876
6031
|
const t = typeof data;
|
|
5877
6032
|
switch (t) {
|
|
5878
6033
|
case "number": {
|
|
@@ -5924,7 +6079,7 @@ const error$17 = () => {
|
|
|
5924
6079
|
};
|
|
5925
6080
|
return (issue$1) => {
|
|
5926
6081
|
switch (issue$1.code) {
|
|
5927
|
-
case "invalid_type": return `Грешен внес: се очекува ${issue$1.expected}, примено ${parsedType$
|
|
6082
|
+
case "invalid_type": return `Грешен внес: се очекува ${issue$1.expected}, примено ${parsedType$3(issue$1.input)}`;
|
|
5928
6083
|
case "invalid_value":
|
|
5929
6084
|
if (issue$1.values.length === 1) return `Invalid input: expected ${stringifyPrimitive(issue$1.values[0])}`;
|
|
5930
6085
|
return `Грешана опција: се очекува една ${joinValues(issue$1.values, "|")}`;
|
|
@@ -5962,12 +6117,12 @@ const error$17 = () => {
|
|
|
5962
6117
|
};
|
|
5963
6118
|
};
|
|
5964
6119
|
function mk_default() {
|
|
5965
|
-
return { localeError: error$
|
|
6120
|
+
return { localeError: error$18() };
|
|
5966
6121
|
}
|
|
5967
6122
|
|
|
5968
6123
|
//#endregion
|
|
5969
|
-
//#region ../../node_modules/zod/
|
|
5970
|
-
const error$
|
|
6124
|
+
//#region ../../node_modules/zod/v4/locales/ms.js
|
|
6125
|
+
const error$17 = () => {
|
|
5971
6126
|
const Sizable = {
|
|
5972
6127
|
string: {
|
|
5973
6128
|
unit: "aksara",
|
|
@@ -5989,7 +6144,7 @@ const error$16 = () => {
|
|
|
5989
6144
|
function getSizing(origin) {
|
|
5990
6145
|
return Sizable[origin] ?? null;
|
|
5991
6146
|
}
|
|
5992
|
-
const parsedType$
|
|
6147
|
+
const parsedType$3 = (data) => {
|
|
5993
6148
|
const t = typeof data;
|
|
5994
6149
|
switch (t) {
|
|
5995
6150
|
case "number": {
|
|
@@ -6041,7 +6196,7 @@ const error$16 = () => {
|
|
|
6041
6196
|
};
|
|
6042
6197
|
return (issue$1) => {
|
|
6043
6198
|
switch (issue$1.code) {
|
|
6044
|
-
case "invalid_type": return `Input tidak sah: dijangka ${issue$1.expected}, diterima ${parsedType$
|
|
6199
|
+
case "invalid_type": return `Input tidak sah: dijangka ${issue$1.expected}, diterima ${parsedType$3(issue$1.input)}`;
|
|
6045
6200
|
case "invalid_value":
|
|
6046
6201
|
if (issue$1.values.length === 1) return `Input tidak sah: dijangka ${stringifyPrimitive(issue$1.values[0])}`;
|
|
6047
6202
|
return `Pilihan tidak sah: dijangka salah satu daripada ${joinValues(issue$1.values, "|")}`;
|
|
@@ -6077,12 +6232,12 @@ const error$16 = () => {
|
|
|
6077
6232
|
};
|
|
6078
6233
|
};
|
|
6079
6234
|
function ms_default() {
|
|
6080
|
-
return { localeError: error$
|
|
6235
|
+
return { localeError: error$17() };
|
|
6081
6236
|
}
|
|
6082
6237
|
|
|
6083
6238
|
//#endregion
|
|
6084
|
-
//#region ../../node_modules/zod/
|
|
6085
|
-
const error$
|
|
6239
|
+
//#region ../../node_modules/zod/v4/locales/nl.js
|
|
6240
|
+
const error$16 = () => {
|
|
6086
6241
|
const Sizable = {
|
|
6087
6242
|
string: { unit: "tekens" },
|
|
6088
6243
|
file: { unit: "bytes" },
|
|
@@ -6092,7 +6247,7 @@ const error$15 = () => {
|
|
|
6092
6247
|
function getSizing(origin) {
|
|
6093
6248
|
return Sizable[origin] ?? null;
|
|
6094
6249
|
}
|
|
6095
|
-
const parsedType$
|
|
6250
|
+
const parsedType$3 = (data) => {
|
|
6096
6251
|
const t = typeof data;
|
|
6097
6252
|
switch (t) {
|
|
6098
6253
|
case "number": {
|
|
@@ -6144,7 +6299,7 @@ const error$15 = () => {
|
|
|
6144
6299
|
};
|
|
6145
6300
|
return (issue$1) => {
|
|
6146
6301
|
switch (issue$1.code) {
|
|
6147
|
-
case "invalid_type": return `Ongeldige invoer: verwacht ${issue$1.expected}, ontving ${parsedType$
|
|
6302
|
+
case "invalid_type": return `Ongeldige invoer: verwacht ${issue$1.expected}, ontving ${parsedType$3(issue$1.input)}`;
|
|
6148
6303
|
case "invalid_value":
|
|
6149
6304
|
if (issue$1.values.length === 1) return `Ongeldige invoer: verwacht ${stringifyPrimitive(issue$1.values[0])}`;
|
|
6150
6305
|
return `Ongeldige optie: verwacht één van ${joinValues(issue$1.values, "|")}`;
|
|
@@ -6182,12 +6337,12 @@ const error$15 = () => {
|
|
|
6182
6337
|
};
|
|
6183
6338
|
};
|
|
6184
6339
|
function nl_default() {
|
|
6185
|
-
return { localeError: error$
|
|
6340
|
+
return { localeError: error$16() };
|
|
6186
6341
|
}
|
|
6187
6342
|
|
|
6188
6343
|
//#endregion
|
|
6189
|
-
//#region ../../node_modules/zod/
|
|
6190
|
-
const error$
|
|
6344
|
+
//#region ../../node_modules/zod/v4/locales/no.js
|
|
6345
|
+
const error$15 = () => {
|
|
6191
6346
|
const Sizable = {
|
|
6192
6347
|
string: {
|
|
6193
6348
|
unit: "tegn",
|
|
@@ -6209,7 +6364,7 @@ const error$14 = () => {
|
|
|
6209
6364
|
function getSizing(origin) {
|
|
6210
6365
|
return Sizable[origin] ?? null;
|
|
6211
6366
|
}
|
|
6212
|
-
const parsedType$
|
|
6367
|
+
const parsedType$3 = (data) => {
|
|
6213
6368
|
const t = typeof data;
|
|
6214
6369
|
switch (t) {
|
|
6215
6370
|
case "number": {
|
|
@@ -6261,7 +6416,7 @@ const error$14 = () => {
|
|
|
6261
6416
|
};
|
|
6262
6417
|
return (issue$1) => {
|
|
6263
6418
|
switch (issue$1.code) {
|
|
6264
|
-
case "invalid_type": return `Ugyldig input: forventet ${issue$1.expected}, fikk ${parsedType$
|
|
6419
|
+
case "invalid_type": return `Ugyldig input: forventet ${issue$1.expected}, fikk ${parsedType$3(issue$1.input)}`;
|
|
6265
6420
|
case "invalid_value":
|
|
6266
6421
|
if (issue$1.values.length === 1) return `Ugyldig verdi: forventet ${stringifyPrimitive(issue$1.values[0])}`;
|
|
6267
6422
|
return `Ugyldig valg: forventet en av ${joinValues(issue$1.values, "|")}`;
|
|
@@ -6297,12 +6452,12 @@ const error$14 = () => {
|
|
|
6297
6452
|
};
|
|
6298
6453
|
};
|
|
6299
6454
|
function no_default() {
|
|
6300
|
-
return { localeError: error$
|
|
6455
|
+
return { localeError: error$15() };
|
|
6301
6456
|
}
|
|
6302
6457
|
|
|
6303
6458
|
//#endregion
|
|
6304
|
-
//#region ../../node_modules/zod/
|
|
6305
|
-
const error$
|
|
6459
|
+
//#region ../../node_modules/zod/v4/locales/ota.js
|
|
6460
|
+
const error$14 = () => {
|
|
6306
6461
|
const Sizable = {
|
|
6307
6462
|
string: {
|
|
6308
6463
|
unit: "harf",
|
|
@@ -6324,7 +6479,7 @@ const error$13 = () => {
|
|
|
6324
6479
|
function getSizing(origin) {
|
|
6325
6480
|
return Sizable[origin] ?? null;
|
|
6326
6481
|
}
|
|
6327
|
-
const parsedType$
|
|
6482
|
+
const parsedType$3 = (data) => {
|
|
6328
6483
|
const t = typeof data;
|
|
6329
6484
|
switch (t) {
|
|
6330
6485
|
case "number": {
|
|
@@ -6376,7 +6531,7 @@ const error$13 = () => {
|
|
|
6376
6531
|
};
|
|
6377
6532
|
return (issue$1) => {
|
|
6378
6533
|
switch (issue$1.code) {
|
|
6379
|
-
case "invalid_type": return `Fâsit giren: umulan ${issue$1.expected}, alınan ${parsedType$
|
|
6534
|
+
case "invalid_type": return `Fâsit giren: umulan ${issue$1.expected}, alınan ${parsedType$3(issue$1.input)}`;
|
|
6380
6535
|
case "invalid_value":
|
|
6381
6536
|
if (issue$1.values.length === 1) return `Fâsit giren: umulan ${stringifyPrimitive(issue$1.values[0])}`;
|
|
6382
6537
|
return `Fâsit tercih: mûteberler ${joinValues(issue$1.values, "|")}`;
|
|
@@ -6412,42 +6567,42 @@ const error$13 = () => {
|
|
|
6412
6567
|
};
|
|
6413
6568
|
};
|
|
6414
6569
|
function ota_default() {
|
|
6415
|
-
return { localeError: error$
|
|
6570
|
+
return { localeError: error$14() };
|
|
6416
6571
|
}
|
|
6417
6572
|
|
|
6418
6573
|
//#endregion
|
|
6419
|
-
//#region ../../node_modules/zod/
|
|
6420
|
-
const error$
|
|
6574
|
+
//#region ../../node_modules/zod/v4/locales/ps.js
|
|
6575
|
+
const error$13 = () => {
|
|
6421
6576
|
const Sizable = {
|
|
6422
6577
|
string: {
|
|
6423
|
-
unit: "
|
|
6424
|
-
verb: "
|
|
6578
|
+
unit: "توکي",
|
|
6579
|
+
verb: "ولري"
|
|
6425
6580
|
},
|
|
6426
6581
|
file: {
|
|
6427
|
-
unit: "
|
|
6428
|
-
verb: "
|
|
6582
|
+
unit: "بایټس",
|
|
6583
|
+
verb: "ولري"
|
|
6429
6584
|
},
|
|
6430
6585
|
array: {
|
|
6431
|
-
unit: "
|
|
6432
|
-
verb: "
|
|
6586
|
+
unit: "توکي",
|
|
6587
|
+
verb: "ولري"
|
|
6433
6588
|
},
|
|
6434
6589
|
set: {
|
|
6435
|
-
unit: "
|
|
6436
|
-
verb: "
|
|
6590
|
+
unit: "توکي",
|
|
6591
|
+
verb: "ولري"
|
|
6437
6592
|
}
|
|
6438
6593
|
};
|
|
6439
6594
|
function getSizing(origin) {
|
|
6440
6595
|
return Sizable[origin] ?? null;
|
|
6441
6596
|
}
|
|
6442
|
-
const parsedType$
|
|
6597
|
+
const parsedType$3 = (data) => {
|
|
6443
6598
|
const t = typeof data;
|
|
6444
6599
|
switch (t) {
|
|
6445
6600
|
case "number": {
|
|
6446
|
-
return Number.isNaN(data) ? "NaN" : "
|
|
6601
|
+
return Number.isNaN(data) ? "NaN" : "عدد";
|
|
6447
6602
|
}
|
|
6448
6603
|
case "object": {
|
|
6449
6604
|
if (Array.isArray(data)) {
|
|
6450
|
-
return "
|
|
6605
|
+
return "ارې";
|
|
6451
6606
|
}
|
|
6452
6607
|
if (data === null) {
|
|
6453
6608
|
return "null";
|
|
@@ -6460,10 +6615,10 @@ const error$12 = () => {
|
|
|
6460
6615
|
return t;
|
|
6461
6616
|
};
|
|
6462
6617
|
const Nouns = {
|
|
6463
|
-
regex: "
|
|
6464
|
-
email: "
|
|
6465
|
-
url: "
|
|
6466
|
-
emoji: "
|
|
6618
|
+
regex: "ورودي",
|
|
6619
|
+
email: "بریښنالیک",
|
|
6620
|
+
url: "یو آر ال",
|
|
6621
|
+
emoji: "ایموجي",
|
|
6467
6622
|
uuid: "UUID",
|
|
6468
6623
|
uuidv4: "UUIDv4",
|
|
6469
6624
|
uuidv6: "UUIDv6",
|
|
@@ -6474,26 +6629,153 @@ const error$12 = () => {
|
|
|
6474
6629
|
ulid: "ULID",
|
|
6475
6630
|
xid: "XID",
|
|
6476
6631
|
ksuid: "KSUID",
|
|
6477
|
-
datetime: "
|
|
6478
|
-
date: "
|
|
6479
|
-
time: "
|
|
6480
|
-
duration: "
|
|
6481
|
-
ipv4: "
|
|
6482
|
-
ipv6: "
|
|
6483
|
-
cidrv4: "
|
|
6484
|
-
cidrv6: "
|
|
6485
|
-
base64: "
|
|
6486
|
-
base64url: "
|
|
6487
|
-
json_string: "
|
|
6488
|
-
e164: "
|
|
6632
|
+
datetime: "نیټه او وخت",
|
|
6633
|
+
date: "نېټه",
|
|
6634
|
+
time: "وخت",
|
|
6635
|
+
duration: "موده",
|
|
6636
|
+
ipv4: "د IPv4 پته",
|
|
6637
|
+
ipv6: "د IPv6 پته",
|
|
6638
|
+
cidrv4: "د IPv4 ساحه",
|
|
6639
|
+
cidrv6: "د IPv6 ساحه",
|
|
6640
|
+
base64: "base64-encoded متن",
|
|
6641
|
+
base64url: "base64url-encoded متن",
|
|
6642
|
+
json_string: "JSON متن",
|
|
6643
|
+
e164: "د E.164 شمېره",
|
|
6489
6644
|
jwt: "JWT",
|
|
6490
|
-
template_literal: "
|
|
6645
|
+
template_literal: "ورودي"
|
|
6491
6646
|
};
|
|
6492
6647
|
return (issue$1) => {
|
|
6493
6648
|
switch (issue$1.code) {
|
|
6494
|
-
case "invalid_type": return
|
|
6649
|
+
case "invalid_type": return `ناسم ورودي: باید ${issue$1.expected} وای, مګر ${parsedType$3(issue$1.input)} ترلاسه شو`;
|
|
6495
6650
|
case "invalid_value":
|
|
6496
|
-
if (issue$1.values.length === 1)
|
|
6651
|
+
if (issue$1.values.length === 1) {
|
|
6652
|
+
return `ناسم ورودي: باید ${stringifyPrimitive(issue$1.values[0])} وای`;
|
|
6653
|
+
}
|
|
6654
|
+
return `ناسم انتخاب: باید یو له ${joinValues(issue$1.values, "|")} څخه وای`;
|
|
6655
|
+
case "too_big": {
|
|
6656
|
+
const adj = issue$1.inclusive ? "<=" : "<";
|
|
6657
|
+
const sizing = getSizing(issue$1.origin);
|
|
6658
|
+
if (sizing) {
|
|
6659
|
+
return `ډیر لوی: ${issue$1.origin ?? "ارزښت"} باید ${adj}${issue$1.maximum.toString()} ${sizing.unit ?? "عنصرونه"} ولري`;
|
|
6660
|
+
}
|
|
6661
|
+
return `ډیر لوی: ${issue$1.origin ?? "ارزښت"} باید ${adj}${issue$1.maximum.toString()} وي`;
|
|
6662
|
+
}
|
|
6663
|
+
case "too_small": {
|
|
6664
|
+
const adj = issue$1.inclusive ? ">=" : ">";
|
|
6665
|
+
const sizing = getSizing(issue$1.origin);
|
|
6666
|
+
if (sizing) {
|
|
6667
|
+
return `ډیر کوچنی: ${issue$1.origin} باید ${adj}${issue$1.minimum.toString()} ${sizing.unit} ولري`;
|
|
6668
|
+
}
|
|
6669
|
+
return `ډیر کوچنی: ${issue$1.origin} باید ${adj}${issue$1.minimum.toString()} وي`;
|
|
6670
|
+
}
|
|
6671
|
+
case "invalid_format": {
|
|
6672
|
+
const _issue = issue$1;
|
|
6673
|
+
if (_issue.format === "starts_with") {
|
|
6674
|
+
return `ناسم متن: باید د "${_issue.prefix}" سره پیل شي`;
|
|
6675
|
+
}
|
|
6676
|
+
if (_issue.format === "ends_with") {
|
|
6677
|
+
return `ناسم متن: باید د "${_issue.suffix}" سره پای ته ورسيږي`;
|
|
6678
|
+
}
|
|
6679
|
+
if (_issue.format === "includes") {
|
|
6680
|
+
return `ناسم متن: باید "${_issue.includes}" ولري`;
|
|
6681
|
+
}
|
|
6682
|
+
if (_issue.format === "regex") {
|
|
6683
|
+
return `ناسم متن: باید د ${_issue.pattern} سره مطابقت ولري`;
|
|
6684
|
+
}
|
|
6685
|
+
return `${Nouns[_issue.format] ?? issue$1.format} ناسم دی`;
|
|
6686
|
+
}
|
|
6687
|
+
case "not_multiple_of": return `ناسم عدد: باید د ${issue$1.divisor} مضرب وي`;
|
|
6688
|
+
case "unrecognized_keys": return `ناسم ${issue$1.keys.length > 1 ? "کلیډونه" : "کلیډ"}: ${joinValues(issue$1.keys, ", ")}`;
|
|
6689
|
+
case "invalid_key": return `ناسم کلیډ په ${issue$1.origin} کې`;
|
|
6690
|
+
case "invalid_union": return `ناسمه ورودي`;
|
|
6691
|
+
case "invalid_element": return `ناسم عنصر په ${issue$1.origin} کې`;
|
|
6692
|
+
default: return `ناسمه ورودي`;
|
|
6693
|
+
}
|
|
6694
|
+
};
|
|
6695
|
+
};
|
|
6696
|
+
function ps_default() {
|
|
6697
|
+
return { localeError: error$13() };
|
|
6698
|
+
}
|
|
6699
|
+
|
|
6700
|
+
//#endregion
|
|
6701
|
+
//#region ../../node_modules/zod/v4/locales/pl.js
|
|
6702
|
+
const error$12 = () => {
|
|
6703
|
+
const Sizable = {
|
|
6704
|
+
string: {
|
|
6705
|
+
unit: "znaków",
|
|
6706
|
+
verb: "mieć"
|
|
6707
|
+
},
|
|
6708
|
+
file: {
|
|
6709
|
+
unit: "bajtów",
|
|
6710
|
+
verb: "mieć"
|
|
6711
|
+
},
|
|
6712
|
+
array: {
|
|
6713
|
+
unit: "elementów",
|
|
6714
|
+
verb: "mieć"
|
|
6715
|
+
},
|
|
6716
|
+
set: {
|
|
6717
|
+
unit: "elementów",
|
|
6718
|
+
verb: "mieć"
|
|
6719
|
+
}
|
|
6720
|
+
};
|
|
6721
|
+
function getSizing(origin) {
|
|
6722
|
+
return Sizable[origin] ?? null;
|
|
6723
|
+
}
|
|
6724
|
+
const parsedType$3 = (data) => {
|
|
6725
|
+
const t = typeof data;
|
|
6726
|
+
switch (t) {
|
|
6727
|
+
case "number": {
|
|
6728
|
+
return Number.isNaN(data) ? "NaN" : "liczba";
|
|
6729
|
+
}
|
|
6730
|
+
case "object": {
|
|
6731
|
+
if (Array.isArray(data)) {
|
|
6732
|
+
return "tablica";
|
|
6733
|
+
}
|
|
6734
|
+
if (data === null) {
|
|
6735
|
+
return "null";
|
|
6736
|
+
}
|
|
6737
|
+
if (Object.getPrototypeOf(data) !== Object.prototype && data.constructor) {
|
|
6738
|
+
return data.constructor.name;
|
|
6739
|
+
}
|
|
6740
|
+
}
|
|
6741
|
+
}
|
|
6742
|
+
return t;
|
|
6743
|
+
};
|
|
6744
|
+
const Nouns = {
|
|
6745
|
+
regex: "wyrażenie",
|
|
6746
|
+
email: "adres email",
|
|
6747
|
+
url: "URL",
|
|
6748
|
+
emoji: "emoji",
|
|
6749
|
+
uuid: "UUID",
|
|
6750
|
+
uuidv4: "UUIDv4",
|
|
6751
|
+
uuidv6: "UUIDv6",
|
|
6752
|
+
nanoid: "nanoid",
|
|
6753
|
+
guid: "GUID",
|
|
6754
|
+
cuid: "cuid",
|
|
6755
|
+
cuid2: "cuid2",
|
|
6756
|
+
ulid: "ULID",
|
|
6757
|
+
xid: "XID",
|
|
6758
|
+
ksuid: "KSUID",
|
|
6759
|
+
datetime: "data i godzina w formacie ISO",
|
|
6760
|
+
date: "data w formacie ISO",
|
|
6761
|
+
time: "godzina w formacie ISO",
|
|
6762
|
+
duration: "czas trwania ISO",
|
|
6763
|
+
ipv4: "adres IPv4",
|
|
6764
|
+
ipv6: "adres IPv6",
|
|
6765
|
+
cidrv4: "zakres IPv4",
|
|
6766
|
+
cidrv6: "zakres IPv6",
|
|
6767
|
+
base64: "ciąg znaków zakodowany w formacie base64",
|
|
6768
|
+
base64url: "ciąg znaków zakodowany w formacie base64url",
|
|
6769
|
+
json_string: "ciąg znaków w formacie JSON",
|
|
6770
|
+
e164: "liczba E.164",
|
|
6771
|
+
jwt: "JWT",
|
|
6772
|
+
template_literal: "wejście"
|
|
6773
|
+
};
|
|
6774
|
+
return (issue$1) => {
|
|
6775
|
+
switch (issue$1.code) {
|
|
6776
|
+
case "invalid_type": return `Nieprawidłowe dane wejściowe: oczekiwano ${issue$1.expected}, otrzymano ${parsedType$3(issue$1.input)}`;
|
|
6777
|
+
case "invalid_value":
|
|
6778
|
+
if (issue$1.values.length === 1) return `Nieprawidłowe dane wejściowe: oczekiwano ${stringifyPrimitive(issue$1.values[0])}`;
|
|
6497
6779
|
return `Nieprawidłowa opcja: oczekiwano jednej z wartości ${joinValues(issue$1.values, "|")}`;
|
|
6498
6780
|
case "too_big": {
|
|
6499
6781
|
const adj = issue$1.inclusive ? "<=" : "<";
|
|
@@ -6533,7 +6815,7 @@ function pl_default() {
|
|
|
6533
6815
|
}
|
|
6534
6816
|
|
|
6535
6817
|
//#endregion
|
|
6536
|
-
//#region ../../node_modules/zod/
|
|
6818
|
+
//#region ../../node_modules/zod/v4/locales/pt.js
|
|
6537
6819
|
const error$11 = () => {
|
|
6538
6820
|
const Sizable = {
|
|
6539
6821
|
string: {
|
|
@@ -6556,7 +6838,7 @@ const error$11 = () => {
|
|
|
6556
6838
|
function getSizing(origin) {
|
|
6557
6839
|
return Sizable[origin] ?? null;
|
|
6558
6840
|
}
|
|
6559
|
-
const parsedType$
|
|
6841
|
+
const parsedType$3 = (data) => {
|
|
6560
6842
|
const t = typeof data;
|
|
6561
6843
|
switch (t) {
|
|
6562
6844
|
case "number": {
|
|
@@ -6608,7 +6890,7 @@ const error$11 = () => {
|
|
|
6608
6890
|
};
|
|
6609
6891
|
return (issue$1) => {
|
|
6610
6892
|
switch (issue$1.code) {
|
|
6611
|
-
case "invalid_type": return `Tipo inválido: esperado ${issue$1.expected}, recebido ${parsedType$
|
|
6893
|
+
case "invalid_type": return `Tipo inválido: esperado ${issue$1.expected}, recebido ${parsedType$3(issue$1.input)}`;
|
|
6612
6894
|
case "invalid_value":
|
|
6613
6895
|
if (issue$1.values.length === 1) return `Entrada inválida: esperado ${stringifyPrimitive(issue$1.values[0])}`;
|
|
6614
6896
|
return `Opção inválida: esperada uma das ${joinValues(issue$1.values, "|")}`;
|
|
@@ -6648,7 +6930,7 @@ function pt_default() {
|
|
|
6648
6930
|
}
|
|
6649
6931
|
|
|
6650
6932
|
//#endregion
|
|
6651
|
-
//#region ../../node_modules/zod/
|
|
6933
|
+
//#region ../../node_modules/zod/v4/locales/ru.js
|
|
6652
6934
|
function getRussianPlural(count, one, few, many) {
|
|
6653
6935
|
const absCount = Math.abs(count);
|
|
6654
6936
|
const lastDigit = absCount % 10;
|
|
@@ -6702,7 +6984,7 @@ const error$10 = () => {
|
|
|
6702
6984
|
function getSizing(origin) {
|
|
6703
6985
|
return Sizable[origin] ?? null;
|
|
6704
6986
|
}
|
|
6705
|
-
const parsedType$
|
|
6987
|
+
const parsedType$3 = (data) => {
|
|
6706
6988
|
const t = typeof data;
|
|
6707
6989
|
switch (t) {
|
|
6708
6990
|
case "number": {
|
|
@@ -6754,7 +7036,7 @@ const error$10 = () => {
|
|
|
6754
7036
|
};
|
|
6755
7037
|
return (issue$1) => {
|
|
6756
7038
|
switch (issue$1.code) {
|
|
6757
|
-
case "invalid_type": return `Неверный ввод: ожидалось ${issue$1.expected}, получено ${parsedType$
|
|
7039
|
+
case "invalid_type": return `Неверный ввод: ожидалось ${issue$1.expected}, получено ${parsedType$3(issue$1.input)}`;
|
|
6758
7040
|
case "invalid_value":
|
|
6759
7041
|
if (issue$1.values.length === 1) return `Неверный ввод: ожидалось ${stringifyPrimitive(issue$1.values[0])}`;
|
|
6760
7042
|
return `Неверный вариант: ожидалось одно из ${joinValues(issue$1.values, "|")}`;
|
|
@@ -6800,7 +7082,7 @@ function ru_default() {
|
|
|
6800
7082
|
}
|
|
6801
7083
|
|
|
6802
7084
|
//#endregion
|
|
6803
|
-
//#region ../../node_modules/zod/
|
|
7085
|
+
//#region ../../node_modules/zod/v4/locales/sl.js
|
|
6804
7086
|
const error$9 = () => {
|
|
6805
7087
|
const Sizable = {
|
|
6806
7088
|
string: {
|
|
@@ -6823,7 +7105,7 @@ const error$9 = () => {
|
|
|
6823
7105
|
function getSizing(origin) {
|
|
6824
7106
|
return Sizable[origin] ?? null;
|
|
6825
7107
|
}
|
|
6826
|
-
const parsedType$
|
|
7108
|
+
const parsedType$3 = (data) => {
|
|
6827
7109
|
const t = typeof data;
|
|
6828
7110
|
switch (t) {
|
|
6829
7111
|
case "number": {
|
|
@@ -6875,7 +7157,7 @@ const error$9 = () => {
|
|
|
6875
7157
|
};
|
|
6876
7158
|
return (issue$1) => {
|
|
6877
7159
|
switch (issue$1.code) {
|
|
6878
|
-
case "invalid_type": return `Neveljaven vnos: pričakovano ${issue$1.expected}, prejeto ${parsedType$
|
|
7160
|
+
case "invalid_type": return `Neveljaven vnos: pričakovano ${issue$1.expected}, prejeto ${parsedType$3(issue$1.input)}`;
|
|
6879
7161
|
case "invalid_value":
|
|
6880
7162
|
if (issue$1.values.length === 1) return `Neveljaven vnos: pričakovano ${stringifyPrimitive(issue$1.values[0])}`;
|
|
6881
7163
|
return `Neveljavna možnost: pričakovano eno izmed ${joinValues(issue$1.values, "|")}`;
|
|
@@ -6917,7 +7199,7 @@ function sl_default() {
|
|
|
6917
7199
|
}
|
|
6918
7200
|
|
|
6919
7201
|
//#endregion
|
|
6920
|
-
//#region ../../node_modules/zod/
|
|
7202
|
+
//#region ../../node_modules/zod/v4/locales/sv.js
|
|
6921
7203
|
const error$8 = () => {
|
|
6922
7204
|
const Sizable = {
|
|
6923
7205
|
string: {
|
|
@@ -6940,7 +7222,7 @@ const error$8 = () => {
|
|
|
6940
7222
|
function getSizing(origin) {
|
|
6941
7223
|
return Sizable[origin] ?? null;
|
|
6942
7224
|
}
|
|
6943
|
-
const parsedType$
|
|
7225
|
+
const parsedType$3 = (data) => {
|
|
6944
7226
|
const t = typeof data;
|
|
6945
7227
|
switch (t) {
|
|
6946
7228
|
case "number": {
|
|
@@ -6992,7 +7274,7 @@ const error$8 = () => {
|
|
|
6992
7274
|
};
|
|
6993
7275
|
return (issue$1) => {
|
|
6994
7276
|
switch (issue$1.code) {
|
|
6995
|
-
case "invalid_type": return `Ogiltig inmatning: förväntat ${issue$1.expected}, fick ${parsedType$
|
|
7277
|
+
case "invalid_type": return `Ogiltig inmatning: förväntat ${issue$1.expected}, fick ${parsedType$3(issue$1.input)}`;
|
|
6996
7278
|
case "invalid_value":
|
|
6997
7279
|
if (issue$1.values.length === 1) return `Ogiltig inmatning: förväntat ${stringifyPrimitive(issue$1.values[0])}`;
|
|
6998
7280
|
return `Ogiltigt val: förväntade en av ${joinValues(issue$1.values, "|")}`;
|
|
@@ -7036,7 +7318,7 @@ function sv_default() {
|
|
|
7036
7318
|
}
|
|
7037
7319
|
|
|
7038
7320
|
//#endregion
|
|
7039
|
-
//#region ../../node_modules/zod/
|
|
7321
|
+
//#region ../../node_modules/zod/v4/locales/ta.js
|
|
7040
7322
|
const error$7 = () => {
|
|
7041
7323
|
const Sizable = {
|
|
7042
7324
|
string: {
|
|
@@ -7059,7 +7341,7 @@ const error$7 = () => {
|
|
|
7059
7341
|
function getSizing(origin) {
|
|
7060
7342
|
return Sizable[origin] ?? null;
|
|
7061
7343
|
}
|
|
7062
|
-
const parsedType$
|
|
7344
|
+
const parsedType$3 = (data) => {
|
|
7063
7345
|
const t = typeof data;
|
|
7064
7346
|
switch (t) {
|
|
7065
7347
|
case "number": {
|
|
@@ -7111,7 +7393,7 @@ const error$7 = () => {
|
|
|
7111
7393
|
};
|
|
7112
7394
|
return (issue$1) => {
|
|
7113
7395
|
switch (issue$1.code) {
|
|
7114
|
-
case "invalid_type": return `தவறான உள்ளீடு: எதிர்பார்க்கப்பட்டது ${issue$1.expected}, பெறப்பட்டது ${parsedType$
|
|
7396
|
+
case "invalid_type": return `தவறான உள்ளீடு: எதிர்பார்க்கப்பட்டது ${issue$1.expected}, பெறப்பட்டது ${parsedType$3(issue$1.input)}`;
|
|
7115
7397
|
case "invalid_value":
|
|
7116
7398
|
if (issue$1.values.length === 1) return `தவறான உள்ளீடு: எதிர்பார்க்கப்பட்டது ${stringifyPrimitive(issue$1.values[0])}`;
|
|
7117
7399
|
return `தவறான விருப்பம்: எதிர்பார்க்கப்பட்டது ${joinValues(issue$1.values, "|")} இல் ஒன்று`;
|
|
@@ -7153,7 +7435,7 @@ function ta_default() {
|
|
|
7153
7435
|
}
|
|
7154
7436
|
|
|
7155
7437
|
//#endregion
|
|
7156
|
-
//#region ../../node_modules/zod/
|
|
7438
|
+
//#region ../../node_modules/zod/v4/locales/th.js
|
|
7157
7439
|
const error$6 = () => {
|
|
7158
7440
|
const Sizable = {
|
|
7159
7441
|
string: {
|
|
@@ -7176,7 +7458,7 @@ const error$6 = () => {
|
|
|
7176
7458
|
function getSizing(origin) {
|
|
7177
7459
|
return Sizable[origin] ?? null;
|
|
7178
7460
|
}
|
|
7179
|
-
const parsedType$
|
|
7461
|
+
const parsedType$3 = (data) => {
|
|
7180
7462
|
const t = typeof data;
|
|
7181
7463
|
switch (t) {
|
|
7182
7464
|
case "number": {
|
|
@@ -7228,7 +7510,7 @@ const error$6 = () => {
|
|
|
7228
7510
|
};
|
|
7229
7511
|
return (issue$1) => {
|
|
7230
7512
|
switch (issue$1.code) {
|
|
7231
|
-
case "invalid_type": return `ประเภทข้อมูลไม่ถูกต้อง: ควรเป็น ${issue$1.expected} แต่ได้รับ ${parsedType$
|
|
7513
|
+
case "invalid_type": return `ประเภทข้อมูลไม่ถูกต้อง: ควรเป็น ${issue$1.expected} แต่ได้รับ ${parsedType$3(issue$1.input)}`;
|
|
7232
7514
|
case "invalid_value":
|
|
7233
7515
|
if (issue$1.values.length === 1) return `ค่าไม่ถูกต้อง: ควรเป็น ${stringifyPrimitive(issue$1.values[0])}`;
|
|
7234
7516
|
return `ตัวเลือกไม่ถูกต้อง: ควรเป็นหนึ่งใน ${joinValues(issue$1.values, "|")}`;
|
|
@@ -7270,7 +7552,7 @@ function th_default() {
|
|
|
7270
7552
|
}
|
|
7271
7553
|
|
|
7272
7554
|
//#endregion
|
|
7273
|
-
//#region ../../node_modules/zod/
|
|
7555
|
+
//#region ../../node_modules/zod/v4/locales/tr.js
|
|
7274
7556
|
const parsedType = (data) => {
|
|
7275
7557
|
const t = typeof data;
|
|
7276
7558
|
switch (t) {
|
|
@@ -7383,7 +7665,7 @@ function tr_default() {
|
|
|
7383
7665
|
}
|
|
7384
7666
|
|
|
7385
7667
|
//#endregion
|
|
7386
|
-
//#region ../../node_modules/zod/
|
|
7668
|
+
//#region ../../node_modules/zod/v4/locales/ua.js
|
|
7387
7669
|
const error$4 = () => {
|
|
7388
7670
|
const Sizable = {
|
|
7389
7671
|
string: {
|
|
@@ -7406,7 +7688,7 @@ const error$4 = () => {
|
|
|
7406
7688
|
function getSizing(origin) {
|
|
7407
7689
|
return Sizable[origin] ?? null;
|
|
7408
7690
|
}
|
|
7409
|
-
const parsedType$
|
|
7691
|
+
const parsedType$3 = (data) => {
|
|
7410
7692
|
const t = typeof data;
|
|
7411
7693
|
switch (t) {
|
|
7412
7694
|
case "number": {
|
|
@@ -7458,7 +7740,7 @@ const error$4 = () => {
|
|
|
7458
7740
|
};
|
|
7459
7741
|
return (issue$1) => {
|
|
7460
7742
|
switch (issue$1.code) {
|
|
7461
|
-
case "invalid_type": return `Неправильні вхідні дані: очікується ${issue$1.expected}, отримано ${parsedType$
|
|
7743
|
+
case "invalid_type": return `Неправильні вхідні дані: очікується ${issue$1.expected}, отримано ${parsedType$3(issue$1.input)}`;
|
|
7462
7744
|
case "invalid_value":
|
|
7463
7745
|
if (issue$1.values.length === 1) return `Неправильні вхідні дані: очікується ${stringifyPrimitive(issue$1.values[0])}`;
|
|
7464
7746
|
return `Неправильна опція: очікується одне з ${joinValues(issue$1.values, "|")}`;
|
|
@@ -7498,7 +7780,7 @@ function ua_default() {
|
|
|
7498
7780
|
}
|
|
7499
7781
|
|
|
7500
7782
|
//#endregion
|
|
7501
|
-
//#region ../../node_modules/zod/
|
|
7783
|
+
//#region ../../node_modules/zod/v4/locales/ur.js
|
|
7502
7784
|
const error$3 = () => {
|
|
7503
7785
|
const Sizable = {
|
|
7504
7786
|
string: {
|
|
@@ -7521,7 +7803,7 @@ const error$3 = () => {
|
|
|
7521
7803
|
function getSizing(origin) {
|
|
7522
7804
|
return Sizable[origin] ?? null;
|
|
7523
7805
|
}
|
|
7524
|
-
const parsedType$
|
|
7806
|
+
const parsedType$3 = (data) => {
|
|
7525
7807
|
const t = typeof data;
|
|
7526
7808
|
switch (t) {
|
|
7527
7809
|
case "number": {
|
|
@@ -7573,7 +7855,7 @@ const error$3 = () => {
|
|
|
7573
7855
|
};
|
|
7574
7856
|
return (issue$1) => {
|
|
7575
7857
|
switch (issue$1.code) {
|
|
7576
|
-
case "invalid_type": return `غلط ان پٹ: ${issue$1.expected} متوقع تھا، ${parsedType$
|
|
7858
|
+
case "invalid_type": return `غلط ان پٹ: ${issue$1.expected} متوقع تھا، ${parsedType$3(issue$1.input)} موصول ہوا`;
|
|
7577
7859
|
case "invalid_value":
|
|
7578
7860
|
if (issue$1.values.length === 1) return `غلط ان پٹ: ${stringifyPrimitive(issue$1.values[0])} متوقع تھا`;
|
|
7579
7861
|
return `غلط آپشن: ${joinValues(issue$1.values, "|")} میں سے ایک متوقع تھا`;
|
|
@@ -7615,7 +7897,7 @@ function ur_default() {
|
|
|
7615
7897
|
}
|
|
7616
7898
|
|
|
7617
7899
|
//#endregion
|
|
7618
|
-
//#region ../../node_modules/zod/
|
|
7900
|
+
//#region ../../node_modules/zod/v4/locales/vi.js
|
|
7619
7901
|
const error$2 = () => {
|
|
7620
7902
|
const Sizable = {
|
|
7621
7903
|
string: {
|
|
@@ -7638,7 +7920,7 @@ const error$2 = () => {
|
|
|
7638
7920
|
function getSizing(origin) {
|
|
7639
7921
|
return Sizable[origin] ?? null;
|
|
7640
7922
|
}
|
|
7641
|
-
const parsedType$
|
|
7923
|
+
const parsedType$3 = (data) => {
|
|
7642
7924
|
const t = typeof data;
|
|
7643
7925
|
switch (t) {
|
|
7644
7926
|
case "number": {
|
|
@@ -7690,7 +7972,7 @@ const error$2 = () => {
|
|
|
7690
7972
|
};
|
|
7691
7973
|
return (issue$1) => {
|
|
7692
7974
|
switch (issue$1.code) {
|
|
7693
|
-
case "invalid_type": return `Đầu vào không hợp lệ: mong đợi ${issue$1.expected}, nhận được ${parsedType$
|
|
7975
|
+
case "invalid_type": return `Đầu vào không hợp lệ: mong đợi ${issue$1.expected}, nhận được ${parsedType$3(issue$1.input)}`;
|
|
7694
7976
|
case "invalid_value":
|
|
7695
7977
|
if (issue$1.values.length === 1) return `Đầu vào không hợp lệ: mong đợi ${stringifyPrimitive(issue$1.values[0])}`;
|
|
7696
7978
|
return `Tùy chọn không hợp lệ: mong đợi một trong các giá trị ${joinValues(issue$1.values, "|")}`;
|
|
@@ -7730,7 +8012,7 @@ function vi_default() {
|
|
|
7730
8012
|
}
|
|
7731
8013
|
|
|
7732
8014
|
//#endregion
|
|
7733
|
-
//#region ../../node_modules/zod/
|
|
8015
|
+
//#region ../../node_modules/zod/v4/locales/zh-CN.js
|
|
7734
8016
|
const error$1 = () => {
|
|
7735
8017
|
const Sizable = {
|
|
7736
8018
|
string: {
|
|
@@ -7753,7 +8035,7 @@ const error$1 = () => {
|
|
|
7753
8035
|
function getSizing(origin) {
|
|
7754
8036
|
return Sizable[origin] ?? null;
|
|
7755
8037
|
}
|
|
7756
|
-
const parsedType$
|
|
8038
|
+
const parsedType$3 = (data) => {
|
|
7757
8039
|
const t = typeof data;
|
|
7758
8040
|
switch (t) {
|
|
7759
8041
|
case "number": {
|
|
@@ -7805,7 +8087,7 @@ const error$1 = () => {
|
|
|
7805
8087
|
};
|
|
7806
8088
|
return (issue$1) => {
|
|
7807
8089
|
switch (issue$1.code) {
|
|
7808
|
-
case "invalid_type": return `无效输入:期望 ${issue$1.expected},实际接收 ${parsedType$
|
|
8090
|
+
case "invalid_type": return `无效输入:期望 ${issue$1.expected},实际接收 ${parsedType$3(issue$1.input)}`;
|
|
7809
8091
|
case "invalid_value":
|
|
7810
8092
|
if (issue$1.values.length === 1) return `无效输入:期望 ${stringifyPrimitive(issue$1.values[0])}`;
|
|
7811
8093
|
return `无效选项:期望以下之一 ${joinValues(issue$1.values, "|")}`;
|
|
@@ -7845,7 +8127,7 @@ function zh_CN_default() {
|
|
|
7845
8127
|
}
|
|
7846
8128
|
|
|
7847
8129
|
//#endregion
|
|
7848
|
-
//#region ../../node_modules/zod/
|
|
8130
|
+
//#region ../../node_modules/zod/v4/locales/zh-TW.js
|
|
7849
8131
|
const error = () => {
|
|
7850
8132
|
const Sizable = {
|
|
7851
8133
|
string: {
|
|
@@ -7868,7 +8150,7 @@ const error = () => {
|
|
|
7868
8150
|
function getSizing(origin) {
|
|
7869
8151
|
return Sizable[origin] ?? null;
|
|
7870
8152
|
}
|
|
7871
|
-
const parsedType$
|
|
8153
|
+
const parsedType$3 = (data) => {
|
|
7872
8154
|
const t = typeof data;
|
|
7873
8155
|
switch (t) {
|
|
7874
8156
|
case "number": {
|
|
@@ -7920,7 +8202,7 @@ const error = () => {
|
|
|
7920
8202
|
};
|
|
7921
8203
|
return (issue$1) => {
|
|
7922
8204
|
switch (issue$1.code) {
|
|
7923
|
-
case "invalid_type": return `無效的輸入值:預期為 ${issue$1.expected},但收到 ${parsedType$
|
|
8205
|
+
case "invalid_type": return `無效的輸入值:預期為 ${issue$1.expected},但收到 ${parsedType$3(issue$1.input)}`;
|
|
7924
8206
|
case "invalid_value":
|
|
7925
8207
|
if (issue$1.values.length === 1) return `無效的輸入值:預期為 ${stringifyPrimitive(issue$1.values[0])}`;
|
|
7926
8208
|
return `無效的選項:預期為以下其中之一 ${joinValues(issue$1.values, "|")}`;
|
|
@@ -7962,7 +8244,7 @@ function zh_TW_default() {
|
|
|
7962
8244
|
}
|
|
7963
8245
|
|
|
7964
8246
|
//#endregion
|
|
7965
|
-
//#region ../../node_modules/zod/
|
|
8247
|
+
//#region ../../node_modules/zod/v4/locales/index.js
|
|
7966
8248
|
var locales_exports = {};
|
|
7967
8249
|
__export(locales_exports, {
|
|
7968
8250
|
ar: () => ar_default,
|
|
@@ -7972,6 +8254,7 @@ __export(locales_exports, {
|
|
|
7972
8254
|
cs: () => cs_default,
|
|
7973
8255
|
de: () => de_default,
|
|
7974
8256
|
en: () => en_default,
|
|
8257
|
+
eo: () => eo_default,
|
|
7975
8258
|
es: () => es_default,
|
|
7976
8259
|
fa: () => fa_default,
|
|
7977
8260
|
fi: () => fi_default,
|
|
@@ -7990,6 +8273,7 @@ __export(locales_exports, {
|
|
|
7990
8273
|
no: () => no_default,
|
|
7991
8274
|
ota: () => ota_default,
|
|
7992
8275
|
pl: () => pl_default,
|
|
8276
|
+
ps: () => ps_default,
|
|
7993
8277
|
pt: () => pt_default,
|
|
7994
8278
|
ru: () => ru_default,
|
|
7995
8279
|
sl: () => sl_default,
|
|
@@ -8005,12 +8289,12 @@ __export(locales_exports, {
|
|
|
8005
8289
|
});
|
|
8006
8290
|
|
|
8007
8291
|
//#endregion
|
|
8008
|
-
//#region ../../node_modules/zod/
|
|
8292
|
+
//#region ../../node_modules/zod/v4/core/registries.js
|
|
8009
8293
|
const $output = Symbol("ZodOutput");
|
|
8010
8294
|
const $input = Symbol("ZodInput");
|
|
8011
8295
|
var $ZodRegistry = class {
|
|
8012
8296
|
constructor() {
|
|
8013
|
-
this._map = new
|
|
8297
|
+
this._map = new Map();
|
|
8014
8298
|
this._idmap = new Map();
|
|
8015
8299
|
}
|
|
8016
8300
|
add(schema, ..._meta) {
|
|
@@ -8024,7 +8308,16 @@ var $ZodRegistry = class {
|
|
|
8024
8308
|
}
|
|
8025
8309
|
return this;
|
|
8026
8310
|
}
|
|
8311
|
+
clear() {
|
|
8312
|
+
this._map = new Map();
|
|
8313
|
+
this._idmap = new Map();
|
|
8314
|
+
return this;
|
|
8315
|
+
}
|
|
8027
8316
|
remove(schema) {
|
|
8317
|
+
const meta = this._map.get(schema);
|
|
8318
|
+
if (meta && typeof meta === "object" && "id" in meta) {
|
|
8319
|
+
this._idmap.delete(meta.id);
|
|
8320
|
+
}
|
|
8028
8321
|
this._map.delete(schema);
|
|
8029
8322
|
return this;
|
|
8030
8323
|
}
|
|
@@ -8050,7 +8343,7 @@ function registry() {
|
|
|
8050
8343
|
const globalRegistry = /* @__PURE__ */ registry();
|
|
8051
8344
|
|
|
8052
8345
|
//#endregion
|
|
8053
|
-
//#region ../../node_modules/zod/
|
|
8346
|
+
//#region ../../node_modules/zod/v4/core/api.js
|
|
8054
8347
|
function _string(Class$1, params) {
|
|
8055
8348
|
return new Class$1({
|
|
8056
8349
|
type: "string",
|
|
@@ -8265,6 +8558,13 @@ function _jwt(Class$1, params) {
|
|
|
8265
8558
|
...normalizeParams(params)
|
|
8266
8559
|
});
|
|
8267
8560
|
}
|
|
8561
|
+
const TimePrecision = {
|
|
8562
|
+
Any: null,
|
|
8563
|
+
Minute: -1,
|
|
8564
|
+
Second: 0,
|
|
8565
|
+
Millisecond: 3,
|
|
8566
|
+
Microsecond: 6
|
|
8567
|
+
};
|
|
8268
8568
|
function _isoDateTime(Class$1, params) {
|
|
8269
8569
|
return new Class$1({
|
|
8270
8570
|
type: "string",
|
|
@@ -8831,8 +9131,8 @@ function _refine(Class$1, fn, _params) {
|
|
|
8831
9131
|
return schema;
|
|
8832
9132
|
}
|
|
8833
9133
|
function _stringbool(Classes, _params) {
|
|
8834
|
-
const
|
|
8835
|
-
let truthyArray = truthy ?? [
|
|
9134
|
+
const params = normalizeParams(_params);
|
|
9135
|
+
let truthyArray = params.truthy ?? [
|
|
8836
9136
|
"true",
|
|
8837
9137
|
"1",
|
|
8838
9138
|
"yes",
|
|
@@ -8840,7 +9140,7 @@ function _stringbool(Classes, _params) {
|
|
|
8840
9140
|
"y",
|
|
8841
9141
|
"enabled"
|
|
8842
9142
|
];
|
|
8843
|
-
let falsyArray = falsy ?? [
|
|
9143
|
+
let falsyArray = params.falsy ?? [
|
|
8844
9144
|
"false",
|
|
8845
9145
|
"0",
|
|
8846
9146
|
"no",
|
|
@@ -8848,7 +9148,7 @@ function _stringbool(Classes, _params) {
|
|
|
8848
9148
|
"n",
|
|
8849
9149
|
"disabled"
|
|
8850
9150
|
];
|
|
8851
|
-
if (
|
|
9151
|
+
if (params.case !== "sensitive") {
|
|
8852
9152
|
truthyArray = truthyArray.map((v) => typeof v === "string" ? v.toLowerCase() : v);
|
|
8853
9153
|
falsyArray = falsyArray.map((v) => typeof v === "string" ? v.toLowerCase() : v);
|
|
8854
9154
|
}
|
|
@@ -8862,7 +9162,7 @@ function _stringbool(Classes, _params) {
|
|
|
8862
9162
|
type: "transform",
|
|
8863
9163
|
transform: (input, payload) => {
|
|
8864
9164
|
let data = input;
|
|
8865
|
-
if (
|
|
9165
|
+
if (params.case !== "sensitive") data = data.toLowerCase();
|
|
8866
9166
|
if (truthySet.has(data)) {
|
|
8867
9167
|
return true;
|
|
8868
9168
|
} else if (falsySet.has(data)) {
|
|
@@ -8878,31 +9178,47 @@ function _stringbool(Classes, _params) {
|
|
|
8878
9178
|
return {};
|
|
8879
9179
|
}
|
|
8880
9180
|
},
|
|
8881
|
-
error: error
|
|
9181
|
+
error: params.error
|
|
8882
9182
|
});
|
|
8883
9183
|
const innerPipe = new _Pipe({
|
|
8884
9184
|
type: "pipe",
|
|
8885
9185
|
in: new _String({
|
|
8886
9186
|
type: "string",
|
|
8887
|
-
error: error
|
|
9187
|
+
error: params.error
|
|
8888
9188
|
}),
|
|
8889
9189
|
out: tx,
|
|
8890
|
-
error: error
|
|
9190
|
+
error: params.error
|
|
8891
9191
|
});
|
|
8892
9192
|
const outerPipe = new _Pipe({
|
|
8893
9193
|
type: "pipe",
|
|
8894
9194
|
in: innerPipe,
|
|
8895
9195
|
out: new _Boolean({
|
|
8896
9196
|
type: "boolean",
|
|
8897
|
-
error: error
|
|
9197
|
+
error: params.error
|
|
8898
9198
|
}),
|
|
8899
|
-
error: error
|
|
9199
|
+
error: params.error
|
|
8900
9200
|
});
|
|
8901
9201
|
return outerPipe;
|
|
8902
9202
|
}
|
|
9203
|
+
function _stringFormat(Class$1, format, fnOrRegex, _params = {}) {
|
|
9204
|
+
const params = normalizeParams(_params);
|
|
9205
|
+
const def = {
|
|
9206
|
+
...normalizeParams(_params),
|
|
9207
|
+
check: "string_format",
|
|
9208
|
+
type: "string",
|
|
9209
|
+
format,
|
|
9210
|
+
fn: typeof fnOrRegex === "function" ? fnOrRegex : (val) => fnOrRegex.test(val),
|
|
9211
|
+
...params
|
|
9212
|
+
};
|
|
9213
|
+
if (fnOrRegex instanceof RegExp) {
|
|
9214
|
+
def.pattern = fnOrRegex;
|
|
9215
|
+
}
|
|
9216
|
+
const inst = new Class$1(def);
|
|
9217
|
+
return inst;
|
|
9218
|
+
}
|
|
8903
9219
|
|
|
8904
9220
|
//#endregion
|
|
8905
|
-
//#region ../../node_modules/zod/
|
|
9221
|
+
//#region ../../node_modules/zod/v4/core/function.js
|
|
8906
9222
|
var $ZodFunction = class {
|
|
8907
9223
|
constructor(def) {
|
|
8908
9224
|
this._def = def;
|
|
@@ -8973,7 +9289,7 @@ function _function(params) {
|
|
|
8973
9289
|
}
|
|
8974
9290
|
|
|
8975
9291
|
//#endregion
|
|
8976
|
-
//#region ../../node_modules/zod/
|
|
9292
|
+
//#region ../../node_modules/zod/v4/core/to-json-schema.js
|
|
8977
9293
|
var JSONSchemaGenerator = class {
|
|
8978
9294
|
constructor(params) {
|
|
8979
9295
|
this.counter = 0;
|
|
@@ -9009,431 +9325,435 @@ var JSONSchemaGenerator = class {
|
|
|
9009
9325
|
const result = {
|
|
9010
9326
|
schema: {},
|
|
9011
9327
|
count: 1,
|
|
9012
|
-
cycle: undefined
|
|
9013
|
-
};
|
|
9014
|
-
this.seen.set(schema, result);
|
|
9015
|
-
if (schema._zod.toJSONSchema) {
|
|
9016
|
-
result.schema = schema._zod.toJSONSchema();
|
|
9017
|
-
}
|
|
9018
|
-
const params = {
|
|
9019
|
-
..._params,
|
|
9020
|
-
schemaPath: [..._params.schemaPath, schema],
|
|
9328
|
+
cycle: undefined,
|
|
9021
9329
|
path: _params.path
|
|
9022
9330
|
};
|
|
9023
|
-
|
|
9024
|
-
|
|
9025
|
-
|
|
9026
|
-
|
|
9027
|
-
this.seen.get(parent).isParent = true;
|
|
9331
|
+
this.seen.set(schema, result);
|
|
9332
|
+
const overrideSchema = schema._zod.toJSONSchema?.();
|
|
9333
|
+
if (overrideSchema) {
|
|
9334
|
+
result.schema = overrideSchema;
|
|
9028
9335
|
} else {
|
|
9029
|
-
const
|
|
9030
|
-
|
|
9031
|
-
|
|
9032
|
-
|
|
9033
|
-
|
|
9034
|
-
|
|
9035
|
-
|
|
9036
|
-
|
|
9037
|
-
|
|
9038
|
-
|
|
9039
|
-
|
|
9336
|
+
const params = {
|
|
9337
|
+
..._params,
|
|
9338
|
+
schemaPath: [..._params.schemaPath, schema],
|
|
9339
|
+
path: _params.path
|
|
9340
|
+
};
|
|
9341
|
+
const parent = schema._zod.parent;
|
|
9342
|
+
if (parent) {
|
|
9343
|
+
result.ref = parent;
|
|
9344
|
+
this.process(parent, params);
|
|
9345
|
+
this.seen.get(parent).isParent = true;
|
|
9346
|
+
} else {
|
|
9347
|
+
const _json = result.schema;
|
|
9348
|
+
switch (def.type) {
|
|
9349
|
+
case "string": {
|
|
9350
|
+
const json$1 = _json;
|
|
9351
|
+
json$1.type = "string";
|
|
9352
|
+
const { minimum, maximum, format, patterns, contentEncoding } = schema._zod.bag;
|
|
9353
|
+
if (typeof minimum === "number") json$1.minLength = minimum;
|
|
9354
|
+
if (typeof maximum === "number") json$1.maxLength = maximum;
|
|
9355
|
+
if (format) {
|
|
9356
|
+
json$1.format = formatMap[format] ?? format;
|
|
9357
|
+
if (json$1.format === "") delete json$1.format;
|
|
9358
|
+
}
|
|
9359
|
+
if (contentEncoding) json$1.contentEncoding = contentEncoding;
|
|
9360
|
+
if (patterns && patterns.size > 0) {
|
|
9361
|
+
const regexes = [...patterns];
|
|
9362
|
+
if (regexes.length === 1) json$1.pattern = regexes[0].source;
|
|
9363
|
+
else if (regexes.length > 1) {
|
|
9364
|
+
result.schema.allOf = [...regexes.map((regex) => ({
|
|
9365
|
+
...this.target === "draft-7" ? { type: "string" } : {},
|
|
9366
|
+
pattern: regex.source
|
|
9367
|
+
}))];
|
|
9368
|
+
}
|
|
9369
|
+
}
|
|
9370
|
+
break;
|
|
9040
9371
|
}
|
|
9041
|
-
|
|
9042
|
-
|
|
9043
|
-
const
|
|
9044
|
-
if (
|
|
9045
|
-
else
|
|
9046
|
-
|
|
9047
|
-
|
|
9048
|
-
|
|
9049
|
-
|
|
9372
|
+
case "number": {
|
|
9373
|
+
const json$1 = _json;
|
|
9374
|
+
const { minimum, maximum, format, multipleOf, exclusiveMaximum, exclusiveMinimum } = schema._zod.bag;
|
|
9375
|
+
if (typeof format === "string" && format.includes("int")) json$1.type = "integer";
|
|
9376
|
+
else json$1.type = "number";
|
|
9377
|
+
if (typeof exclusiveMinimum === "number") json$1.exclusiveMinimum = exclusiveMinimum;
|
|
9378
|
+
if (typeof minimum === "number") {
|
|
9379
|
+
json$1.minimum = minimum;
|
|
9380
|
+
if (typeof exclusiveMinimum === "number") {
|
|
9381
|
+
if (exclusiveMinimum >= minimum) delete json$1.minimum;
|
|
9382
|
+
else delete json$1.exclusiveMinimum;
|
|
9383
|
+
}
|
|
9050
9384
|
}
|
|
9385
|
+
if (typeof exclusiveMaximum === "number") json$1.exclusiveMaximum = exclusiveMaximum;
|
|
9386
|
+
if (typeof maximum === "number") {
|
|
9387
|
+
json$1.maximum = maximum;
|
|
9388
|
+
if (typeof exclusiveMaximum === "number") {
|
|
9389
|
+
if (exclusiveMaximum <= maximum) delete json$1.maximum;
|
|
9390
|
+
else delete json$1.exclusiveMaximum;
|
|
9391
|
+
}
|
|
9392
|
+
}
|
|
9393
|
+
if (typeof multipleOf === "number") json$1.multipleOf = multipleOf;
|
|
9394
|
+
break;
|
|
9051
9395
|
}
|
|
9052
|
-
|
|
9053
|
-
|
|
9054
|
-
|
|
9055
|
-
|
|
9056
|
-
|
|
9057
|
-
|
|
9058
|
-
|
|
9059
|
-
|
|
9060
|
-
if (typeof minimum === "number") {
|
|
9061
|
-
json$1.minimum = minimum;
|
|
9062
|
-
if (typeof exclusiveMinimum === "number") {
|
|
9063
|
-
if (exclusiveMinimum >= minimum) delete json$1.minimum;
|
|
9064
|
-
else delete json$1.exclusiveMinimum;
|
|
9396
|
+
case "boolean": {
|
|
9397
|
+
const json$1 = _json;
|
|
9398
|
+
json$1.type = "boolean";
|
|
9399
|
+
break;
|
|
9400
|
+
}
|
|
9401
|
+
case "bigint": {
|
|
9402
|
+
if (this.unrepresentable === "throw") {
|
|
9403
|
+
throw new Error("BigInt cannot be represented in JSON Schema");
|
|
9065
9404
|
}
|
|
9405
|
+
break;
|
|
9066
9406
|
}
|
|
9067
|
-
|
|
9068
|
-
|
|
9069
|
-
|
|
9070
|
-
if (typeof exclusiveMaximum === "number") {
|
|
9071
|
-
if (exclusiveMaximum <= maximum) delete json$1.maximum;
|
|
9072
|
-
else delete json$1.exclusiveMaximum;
|
|
9407
|
+
case "symbol": {
|
|
9408
|
+
if (this.unrepresentable === "throw") {
|
|
9409
|
+
throw new Error("Symbols cannot be represented in JSON Schema");
|
|
9073
9410
|
}
|
|
9411
|
+
break;
|
|
9074
9412
|
}
|
|
9075
|
-
|
|
9076
|
-
|
|
9077
|
-
|
|
9078
|
-
case "boolean": {
|
|
9079
|
-
const json$1 = _json;
|
|
9080
|
-
json$1.type = "boolean";
|
|
9081
|
-
break;
|
|
9082
|
-
}
|
|
9083
|
-
case "bigint": {
|
|
9084
|
-
if (this.unrepresentable === "throw") {
|
|
9085
|
-
throw new Error("BigInt cannot be represented in JSON Schema");
|
|
9413
|
+
case "null": {
|
|
9414
|
+
_json.type = "null";
|
|
9415
|
+
break;
|
|
9086
9416
|
}
|
|
9087
|
-
|
|
9088
|
-
|
|
9089
|
-
case "symbol": {
|
|
9090
|
-
if (this.unrepresentable === "throw") {
|
|
9091
|
-
throw new Error("Symbols cannot be represented in JSON Schema");
|
|
9417
|
+
case "any": {
|
|
9418
|
+
break;
|
|
9092
9419
|
}
|
|
9093
|
-
|
|
9094
|
-
|
|
9095
|
-
case "undefined": {
|
|
9096
|
-
const json$1 = _json;
|
|
9097
|
-
json$1.type = "null";
|
|
9098
|
-
break;
|
|
9099
|
-
}
|
|
9100
|
-
case "null": {
|
|
9101
|
-
_json.type = "null";
|
|
9102
|
-
break;
|
|
9103
|
-
}
|
|
9104
|
-
case "any": {
|
|
9105
|
-
break;
|
|
9106
|
-
}
|
|
9107
|
-
case "unknown": {
|
|
9108
|
-
break;
|
|
9109
|
-
}
|
|
9110
|
-
case "never": {
|
|
9111
|
-
_json.not = {};
|
|
9112
|
-
break;
|
|
9113
|
-
}
|
|
9114
|
-
case "void": {
|
|
9115
|
-
if (this.unrepresentable === "throw") {
|
|
9116
|
-
throw new Error("Void cannot be represented in JSON Schema");
|
|
9420
|
+
case "unknown": {
|
|
9421
|
+
break;
|
|
9117
9422
|
}
|
|
9118
|
-
|
|
9119
|
-
|
|
9120
|
-
|
|
9121
|
-
|
|
9122
|
-
|
|
9423
|
+
case "undefined": {
|
|
9424
|
+
if (this.unrepresentable === "throw") {
|
|
9425
|
+
throw new Error("Undefined cannot be represented in JSON Schema");
|
|
9426
|
+
}
|
|
9427
|
+
break;
|
|
9123
9428
|
}
|
|
9124
|
-
|
|
9125
|
-
|
|
9126
|
-
|
|
9127
|
-
|
|
9128
|
-
|
|
9129
|
-
if (typeof minimum === "number") json$1.minItems = minimum;
|
|
9130
|
-
if (typeof maximum === "number") json$1.maxItems = maximum;
|
|
9131
|
-
json$1.type = "array";
|
|
9132
|
-
json$1.items = this.process(def.element, {
|
|
9133
|
-
...params,
|
|
9134
|
-
path: [...params.path, "items"]
|
|
9135
|
-
});
|
|
9136
|
-
break;
|
|
9137
|
-
}
|
|
9138
|
-
case "object": {
|
|
9139
|
-
const json$1 = _json;
|
|
9140
|
-
json$1.type = "object";
|
|
9141
|
-
json$1.properties = {};
|
|
9142
|
-
const shape = def.shape;
|
|
9143
|
-
for (const key in shape) {
|
|
9144
|
-
json$1.properties[key] = this.process(shape[key], {
|
|
9145
|
-
...params,
|
|
9146
|
-
path: [
|
|
9147
|
-
...params.path,
|
|
9148
|
-
"properties",
|
|
9149
|
-
key
|
|
9150
|
-
]
|
|
9151
|
-
});
|
|
9429
|
+
case "void": {
|
|
9430
|
+
if (this.unrepresentable === "throw") {
|
|
9431
|
+
throw new Error("Void cannot be represented in JSON Schema");
|
|
9432
|
+
}
|
|
9433
|
+
break;
|
|
9152
9434
|
}
|
|
9153
|
-
|
|
9154
|
-
|
|
9155
|
-
|
|
9156
|
-
|
|
9157
|
-
|
|
9158
|
-
|
|
9159
|
-
|
|
9435
|
+
case "never": {
|
|
9436
|
+
_json.not = {};
|
|
9437
|
+
break;
|
|
9438
|
+
}
|
|
9439
|
+
case "date": {
|
|
9440
|
+
if (this.unrepresentable === "throw") {
|
|
9441
|
+
throw new Error("Date cannot be represented in JSON Schema");
|
|
9160
9442
|
}
|
|
9161
|
-
|
|
9162
|
-
if (requiredKeys.size > 0) {
|
|
9163
|
-
json$1.required = Array.from(requiredKeys);
|
|
9443
|
+
break;
|
|
9164
9444
|
}
|
|
9165
|
-
|
|
9166
|
-
json$1
|
|
9167
|
-
|
|
9168
|
-
if (
|
|
9169
|
-
|
|
9170
|
-
json$1.
|
|
9445
|
+
case "array": {
|
|
9446
|
+
const json$1 = _json;
|
|
9447
|
+
const { minimum, maximum } = schema._zod.bag;
|
|
9448
|
+
if (typeof minimum === "number") json$1.minItems = minimum;
|
|
9449
|
+
if (typeof maximum === "number") json$1.maxItems = maximum;
|
|
9450
|
+
json$1.type = "array";
|
|
9451
|
+
json$1.items = this.process(def.element, {
|
|
9171
9452
|
...params,
|
|
9172
|
-
path: [...params.path, "
|
|
9453
|
+
path: [...params.path, "items"]
|
|
9173
9454
|
});
|
|
9455
|
+
break;
|
|
9174
9456
|
}
|
|
9175
|
-
|
|
9176
|
-
|
|
9177
|
-
|
|
9178
|
-
|
|
9179
|
-
|
|
9180
|
-
|
|
9181
|
-
|
|
9182
|
-
|
|
9183
|
-
|
|
9184
|
-
|
|
9185
|
-
|
|
9186
|
-
|
|
9187
|
-
|
|
9188
|
-
|
|
9189
|
-
|
|
9190
|
-
|
|
9191
|
-
|
|
9192
|
-
|
|
9193
|
-
|
|
9194
|
-
|
|
9195
|
-
|
|
9196
|
-
|
|
9197
|
-
|
|
9198
|
-
|
|
9199
|
-
|
|
9200
|
-
|
|
9201
|
-
|
|
9202
|
-
|
|
9203
|
-
|
|
9204
|
-
|
|
9205
|
-
|
|
9206
|
-
|
|
9207
|
-
|
|
9208
|
-
|
|
9209
|
-
|
|
9210
|
-
|
|
9211
|
-
|
|
9212
|
-
|
|
9213
|
-
const json$1 = _json;
|
|
9214
|
-
json$1.type = "array";
|
|
9215
|
-
const prefixItems = def.items.map((x, i) => this.process(x, {
|
|
9216
|
-
...params,
|
|
9217
|
-
path: [
|
|
9218
|
-
...params.path,
|
|
9219
|
-
"prefixItems",
|
|
9220
|
-
i
|
|
9221
|
-
]
|
|
9222
|
-
}));
|
|
9223
|
-
if (this.target === "draft-2020-12") {
|
|
9224
|
-
json$1.prefixItems = prefixItems;
|
|
9225
|
-
} else {
|
|
9226
|
-
json$1.items = prefixItems;
|
|
9457
|
+
case "object": {
|
|
9458
|
+
const json$1 = _json;
|
|
9459
|
+
json$1.type = "object";
|
|
9460
|
+
json$1.properties = {};
|
|
9461
|
+
const shape = def.shape;
|
|
9462
|
+
for (const key in shape) {
|
|
9463
|
+
json$1.properties[key] = this.process(shape[key], {
|
|
9464
|
+
...params,
|
|
9465
|
+
path: [
|
|
9466
|
+
...params.path,
|
|
9467
|
+
"properties",
|
|
9468
|
+
key
|
|
9469
|
+
]
|
|
9470
|
+
});
|
|
9471
|
+
}
|
|
9472
|
+
const allKeys = new Set(Object.keys(shape));
|
|
9473
|
+
const requiredKeys = new Set([...allKeys].filter((key) => {
|
|
9474
|
+
const v = def.shape[key]._zod;
|
|
9475
|
+
if (this.io === "input") {
|
|
9476
|
+
return v.optin === undefined;
|
|
9477
|
+
} else {
|
|
9478
|
+
return v.optout === undefined;
|
|
9479
|
+
}
|
|
9480
|
+
}));
|
|
9481
|
+
if (requiredKeys.size > 0) {
|
|
9482
|
+
json$1.required = Array.from(requiredKeys);
|
|
9483
|
+
}
|
|
9484
|
+
if (def.catchall?._zod.def.type === "never") {
|
|
9485
|
+
json$1.additionalProperties = false;
|
|
9486
|
+
} else if (!def.catchall) {
|
|
9487
|
+
if (this.io === "output") json$1.additionalProperties = false;
|
|
9488
|
+
} else if (def.catchall) {
|
|
9489
|
+
json$1.additionalProperties = this.process(def.catchall, {
|
|
9490
|
+
...params,
|
|
9491
|
+
path: [...params.path, "additionalProperties"]
|
|
9492
|
+
});
|
|
9493
|
+
}
|
|
9494
|
+
break;
|
|
9227
9495
|
}
|
|
9228
|
-
|
|
9229
|
-
const
|
|
9496
|
+
case "union": {
|
|
9497
|
+
const json$1 = _json;
|
|
9498
|
+
json$1.anyOf = def.options.map((x, i) => this.process(x, {
|
|
9230
9499
|
...params,
|
|
9231
|
-
path: [
|
|
9500
|
+
path: [
|
|
9501
|
+
...params.path,
|
|
9502
|
+
"anyOf",
|
|
9503
|
+
i
|
|
9504
|
+
]
|
|
9505
|
+
}));
|
|
9506
|
+
break;
|
|
9507
|
+
}
|
|
9508
|
+
case "intersection": {
|
|
9509
|
+
const json$1 = _json;
|
|
9510
|
+
const a = this.process(def.left, {
|
|
9511
|
+
...params,
|
|
9512
|
+
path: [
|
|
9513
|
+
...params.path,
|
|
9514
|
+
"allOf",
|
|
9515
|
+
0
|
|
9516
|
+
]
|
|
9517
|
+
});
|
|
9518
|
+
const b = this.process(def.right, {
|
|
9519
|
+
...params,
|
|
9520
|
+
path: [
|
|
9521
|
+
...params.path,
|
|
9522
|
+
"allOf",
|
|
9523
|
+
1
|
|
9524
|
+
]
|
|
9232
9525
|
});
|
|
9526
|
+
const isSimpleIntersection = (val) => "allOf" in val && Object.keys(val).length === 1;
|
|
9527
|
+
const allOf = [...isSimpleIntersection(a) ? a.allOf : [a], ...isSimpleIntersection(b) ? b.allOf : [b]];
|
|
9528
|
+
json$1.allOf = allOf;
|
|
9529
|
+
break;
|
|
9530
|
+
}
|
|
9531
|
+
case "tuple": {
|
|
9532
|
+
const json$1 = _json;
|
|
9533
|
+
json$1.type = "array";
|
|
9534
|
+
const prefixItems = def.items.map((x, i) => this.process(x, {
|
|
9535
|
+
...params,
|
|
9536
|
+
path: [
|
|
9537
|
+
...params.path,
|
|
9538
|
+
"prefixItems",
|
|
9539
|
+
i
|
|
9540
|
+
]
|
|
9541
|
+
}));
|
|
9233
9542
|
if (this.target === "draft-2020-12") {
|
|
9234
|
-
json$1.
|
|
9543
|
+
json$1.prefixItems = prefixItems;
|
|
9235
9544
|
} else {
|
|
9236
|
-
json$1.
|
|
9545
|
+
json$1.items = prefixItems;
|
|
9546
|
+
}
|
|
9547
|
+
if (def.rest) {
|
|
9548
|
+
const rest = this.process(def.rest, {
|
|
9549
|
+
...params,
|
|
9550
|
+
path: [...params.path, "items"]
|
|
9551
|
+
});
|
|
9552
|
+
if (this.target === "draft-2020-12") {
|
|
9553
|
+
json$1.items = rest;
|
|
9554
|
+
} else {
|
|
9555
|
+
json$1.additionalItems = rest;
|
|
9556
|
+
}
|
|
9237
9557
|
}
|
|
9558
|
+
if (def.rest) {
|
|
9559
|
+
json$1.items = this.process(def.rest, {
|
|
9560
|
+
...params,
|
|
9561
|
+
path: [...params.path, "items"]
|
|
9562
|
+
});
|
|
9563
|
+
}
|
|
9564
|
+
const { minimum, maximum } = schema._zod.bag;
|
|
9565
|
+
if (typeof minimum === "number") json$1.minItems = minimum;
|
|
9566
|
+
if (typeof maximum === "number") json$1.maxItems = maximum;
|
|
9567
|
+
break;
|
|
9238
9568
|
}
|
|
9239
|
-
|
|
9240
|
-
json$1
|
|
9569
|
+
case "record": {
|
|
9570
|
+
const json$1 = _json;
|
|
9571
|
+
json$1.type = "object";
|
|
9572
|
+
json$1.propertyNames = this.process(def.keyType, {
|
|
9241
9573
|
...params,
|
|
9242
|
-
path: [...params.path, "
|
|
9574
|
+
path: [...params.path, "propertyNames"]
|
|
9243
9575
|
});
|
|
9576
|
+
json$1.additionalProperties = this.process(def.valueType, {
|
|
9577
|
+
...params,
|
|
9578
|
+
path: [...params.path, "additionalProperties"]
|
|
9579
|
+
});
|
|
9580
|
+
break;
|
|
9244
9581
|
}
|
|
9245
|
-
|
|
9246
|
-
|
|
9247
|
-
|
|
9248
|
-
|
|
9249
|
-
|
|
9250
|
-
case "record": {
|
|
9251
|
-
const json$1 = _json;
|
|
9252
|
-
json$1.type = "object";
|
|
9253
|
-
json$1.propertyNames = this.process(def.keyType, {
|
|
9254
|
-
...params,
|
|
9255
|
-
path: [...params.path, "propertyNames"]
|
|
9256
|
-
});
|
|
9257
|
-
json$1.additionalProperties = this.process(def.valueType, {
|
|
9258
|
-
...params,
|
|
9259
|
-
path: [...params.path, "additionalProperties"]
|
|
9260
|
-
});
|
|
9261
|
-
break;
|
|
9262
|
-
}
|
|
9263
|
-
case "map": {
|
|
9264
|
-
if (this.unrepresentable === "throw") {
|
|
9265
|
-
throw new Error("Map cannot be represented in JSON Schema");
|
|
9582
|
+
case "map": {
|
|
9583
|
+
if (this.unrepresentable === "throw") {
|
|
9584
|
+
throw new Error("Map cannot be represented in JSON Schema");
|
|
9585
|
+
}
|
|
9586
|
+
break;
|
|
9266
9587
|
}
|
|
9267
|
-
|
|
9268
|
-
|
|
9269
|
-
|
|
9270
|
-
|
|
9271
|
-
|
|
9588
|
+
case "set": {
|
|
9589
|
+
if (this.unrepresentable === "throw") {
|
|
9590
|
+
throw new Error("Set cannot be represented in JSON Schema");
|
|
9591
|
+
}
|
|
9592
|
+
break;
|
|
9272
9593
|
}
|
|
9273
|
-
|
|
9274
|
-
|
|
9275
|
-
|
|
9276
|
-
|
|
9277
|
-
|
|
9278
|
-
|
|
9279
|
-
|
|
9280
|
-
|
|
9281
|
-
|
|
9282
|
-
|
|
9283
|
-
|
|
9284
|
-
|
|
9285
|
-
|
|
9286
|
-
|
|
9287
|
-
|
|
9288
|
-
|
|
9289
|
-
|
|
9290
|
-
|
|
9291
|
-
|
|
9292
|
-
|
|
9293
|
-
|
|
9594
|
+
case "enum": {
|
|
9595
|
+
const json$1 = _json;
|
|
9596
|
+
const values = getEnumValues(def.entries);
|
|
9597
|
+
if (values.every((v) => typeof v === "number")) json$1.type = "number";
|
|
9598
|
+
if (values.every((v) => typeof v === "string")) json$1.type = "string";
|
|
9599
|
+
json$1.enum = values;
|
|
9600
|
+
break;
|
|
9601
|
+
}
|
|
9602
|
+
case "literal": {
|
|
9603
|
+
const json$1 = _json;
|
|
9604
|
+
const vals = [];
|
|
9605
|
+
for (const val of def.values) {
|
|
9606
|
+
if (val === undefined) {
|
|
9607
|
+
if (this.unrepresentable === "throw") {
|
|
9608
|
+
throw new Error("Literal `undefined` cannot be represented in JSON Schema");
|
|
9609
|
+
} else {}
|
|
9610
|
+
} else if (typeof val === "bigint") {
|
|
9611
|
+
if (this.unrepresentable === "throw") {
|
|
9612
|
+
throw new Error("BigInt literals cannot be represented in JSON Schema");
|
|
9613
|
+
} else {
|
|
9614
|
+
vals.push(Number(val));
|
|
9615
|
+
}
|
|
9294
9616
|
} else {
|
|
9295
|
-
vals.push(
|
|
9617
|
+
vals.push(val);
|
|
9296
9618
|
}
|
|
9619
|
+
}
|
|
9620
|
+
if (vals.length === 0) {} else if (vals.length === 1) {
|
|
9621
|
+
const val = vals[0];
|
|
9622
|
+
json$1.type = val === null ? "null" : typeof val;
|
|
9623
|
+
json$1.const = val;
|
|
9297
9624
|
} else {
|
|
9298
|
-
vals.
|
|
9625
|
+
if (vals.every((v) => typeof v === "number")) json$1.type = "number";
|
|
9626
|
+
if (vals.every((v) => typeof v === "string")) json$1.type = "string";
|
|
9627
|
+
if (vals.every((v) => typeof v === "boolean")) json$1.type = "string";
|
|
9628
|
+
if (vals.every((v) => v === null)) json$1.type = "null";
|
|
9629
|
+
json$1.enum = vals;
|
|
9299
9630
|
}
|
|
9631
|
+
break;
|
|
9300
9632
|
}
|
|
9301
|
-
|
|
9302
|
-
const
|
|
9303
|
-
|
|
9304
|
-
|
|
9305
|
-
|
|
9306
|
-
|
|
9307
|
-
|
|
9308
|
-
|
|
9309
|
-
if (
|
|
9310
|
-
|
|
9311
|
-
|
|
9312
|
-
|
|
9313
|
-
|
|
9314
|
-
|
|
9315
|
-
|
|
9316
|
-
|
|
9317
|
-
|
|
9318
|
-
|
|
9319
|
-
|
|
9320
|
-
|
|
9321
|
-
|
|
9322
|
-
|
|
9323
|
-
|
|
9324
|
-
if (mime) {
|
|
9325
|
-
if (mime.length === 1) {
|
|
9326
|
-
file$1.contentMediaType = mime[0];
|
|
9327
|
-
Object.assign(json$1, file$1);
|
|
9633
|
+
case "file": {
|
|
9634
|
+
const json$1 = _json;
|
|
9635
|
+
const file$1 = {
|
|
9636
|
+
type: "string",
|
|
9637
|
+
format: "binary",
|
|
9638
|
+
contentEncoding: "binary"
|
|
9639
|
+
};
|
|
9640
|
+
const { minimum, maximum, mime } = schema._zod.bag;
|
|
9641
|
+
if (minimum !== undefined) file$1.minLength = minimum;
|
|
9642
|
+
if (maximum !== undefined) file$1.maxLength = maximum;
|
|
9643
|
+
if (mime) {
|
|
9644
|
+
if (mime.length === 1) {
|
|
9645
|
+
file$1.contentMediaType = mime[0];
|
|
9646
|
+
Object.assign(json$1, file$1);
|
|
9647
|
+
} else {
|
|
9648
|
+
json$1.anyOf = mime.map((m) => {
|
|
9649
|
+
const mFile = {
|
|
9650
|
+
...file$1,
|
|
9651
|
+
contentMediaType: m
|
|
9652
|
+
};
|
|
9653
|
+
return mFile;
|
|
9654
|
+
});
|
|
9655
|
+
}
|
|
9328
9656
|
} else {
|
|
9329
|
-
json$1
|
|
9330
|
-
const mFile = {
|
|
9331
|
-
...file$1,
|
|
9332
|
-
contentMediaType: m
|
|
9333
|
-
};
|
|
9334
|
-
return mFile;
|
|
9335
|
-
});
|
|
9657
|
+
Object.assign(json$1, file$1);
|
|
9336
9658
|
}
|
|
9337
|
-
|
|
9338
|
-
Object.assign(json$1, file$1);
|
|
9659
|
+
break;
|
|
9339
9660
|
}
|
|
9340
|
-
|
|
9341
|
-
|
|
9342
|
-
|
|
9343
|
-
|
|
9344
|
-
|
|
9661
|
+
case "transform": {
|
|
9662
|
+
if (this.unrepresentable === "throw") {
|
|
9663
|
+
throw new Error("Transforms cannot be represented in JSON Schema");
|
|
9664
|
+
}
|
|
9665
|
+
break;
|
|
9345
9666
|
}
|
|
9346
|
-
|
|
9347
|
-
|
|
9348
|
-
|
|
9349
|
-
|
|
9350
|
-
_json.anyOf = [inner, { type: "null" }];
|
|
9351
|
-
break;
|
|
9352
|
-
}
|
|
9353
|
-
case "nonoptional": {
|
|
9354
|
-
this.process(def.innerType, params);
|
|
9355
|
-
result.ref = def.innerType;
|
|
9356
|
-
break;
|
|
9357
|
-
}
|
|
9358
|
-
case "success": {
|
|
9359
|
-
const json$1 = _json;
|
|
9360
|
-
json$1.type = "boolean";
|
|
9361
|
-
break;
|
|
9362
|
-
}
|
|
9363
|
-
case "default": {
|
|
9364
|
-
this.process(def.innerType, params);
|
|
9365
|
-
result.ref = def.innerType;
|
|
9366
|
-
_json.default = def.defaultValue;
|
|
9367
|
-
break;
|
|
9368
|
-
}
|
|
9369
|
-
case "prefault": {
|
|
9370
|
-
this.process(def.innerType, params);
|
|
9371
|
-
result.ref = def.innerType;
|
|
9372
|
-
if (this.io === "input") _json._prefault = def.defaultValue;
|
|
9373
|
-
break;
|
|
9374
|
-
}
|
|
9375
|
-
case "catch": {
|
|
9376
|
-
this.process(def.innerType, params);
|
|
9377
|
-
result.ref = def.innerType;
|
|
9378
|
-
let catchValue;
|
|
9379
|
-
try {
|
|
9380
|
-
catchValue = def.catchValue(undefined);
|
|
9381
|
-
} catch {
|
|
9382
|
-
throw new Error("Dynamic catch values are not supported in JSON Schema");
|
|
9667
|
+
case "nullable": {
|
|
9668
|
+
const inner = this.process(def.innerType, params);
|
|
9669
|
+
_json.anyOf = [inner, { type: "null" }];
|
|
9670
|
+
break;
|
|
9383
9671
|
}
|
|
9384
|
-
|
|
9385
|
-
|
|
9386
|
-
|
|
9387
|
-
|
|
9388
|
-
if (this.unrepresentable === "throw") {
|
|
9389
|
-
throw new Error("NaN cannot be represented in JSON Schema");
|
|
9672
|
+
case "nonoptional": {
|
|
9673
|
+
this.process(def.innerType, params);
|
|
9674
|
+
result.ref = def.innerType;
|
|
9675
|
+
break;
|
|
9390
9676
|
}
|
|
9391
|
-
|
|
9392
|
-
|
|
9393
|
-
|
|
9394
|
-
|
|
9395
|
-
|
|
9396
|
-
|
|
9397
|
-
|
|
9398
|
-
|
|
9399
|
-
|
|
9400
|
-
|
|
9401
|
-
|
|
9402
|
-
|
|
9403
|
-
|
|
9404
|
-
|
|
9405
|
-
|
|
9406
|
-
|
|
9407
|
-
|
|
9408
|
-
|
|
9409
|
-
|
|
9410
|
-
|
|
9411
|
-
|
|
9412
|
-
|
|
9413
|
-
|
|
9414
|
-
|
|
9415
|
-
|
|
9416
|
-
|
|
9417
|
-
|
|
9418
|
-
|
|
9419
|
-
|
|
9420
|
-
|
|
9421
|
-
|
|
9422
|
-
|
|
9423
|
-
|
|
9424
|
-
|
|
9425
|
-
|
|
9426
|
-
|
|
9427
|
-
|
|
9428
|
-
|
|
9429
|
-
|
|
9430
|
-
|
|
9431
|
-
|
|
9677
|
+
case "success": {
|
|
9678
|
+
const json$1 = _json;
|
|
9679
|
+
json$1.type = "boolean";
|
|
9680
|
+
break;
|
|
9681
|
+
}
|
|
9682
|
+
case "default": {
|
|
9683
|
+
this.process(def.innerType, params);
|
|
9684
|
+
result.ref = def.innerType;
|
|
9685
|
+
_json.default = JSON.parse(JSON.stringify(def.defaultValue));
|
|
9686
|
+
break;
|
|
9687
|
+
}
|
|
9688
|
+
case "prefault": {
|
|
9689
|
+
this.process(def.innerType, params);
|
|
9690
|
+
result.ref = def.innerType;
|
|
9691
|
+
if (this.io === "input") _json._prefault = JSON.parse(JSON.stringify(def.defaultValue));
|
|
9692
|
+
break;
|
|
9693
|
+
}
|
|
9694
|
+
case "catch": {
|
|
9695
|
+
this.process(def.innerType, params);
|
|
9696
|
+
result.ref = def.innerType;
|
|
9697
|
+
let catchValue;
|
|
9698
|
+
try {
|
|
9699
|
+
catchValue = def.catchValue(undefined);
|
|
9700
|
+
} catch {
|
|
9701
|
+
throw new Error("Dynamic catch values are not supported in JSON Schema");
|
|
9702
|
+
}
|
|
9703
|
+
_json.default = catchValue;
|
|
9704
|
+
break;
|
|
9705
|
+
}
|
|
9706
|
+
case "nan": {
|
|
9707
|
+
if (this.unrepresentable === "throw") {
|
|
9708
|
+
throw new Error("NaN cannot be represented in JSON Schema");
|
|
9709
|
+
}
|
|
9710
|
+
break;
|
|
9711
|
+
}
|
|
9712
|
+
case "template_literal": {
|
|
9713
|
+
const json$1 = _json;
|
|
9714
|
+
const pattern = schema._zod.pattern;
|
|
9715
|
+
if (!pattern) throw new Error("Pattern not found in template literal");
|
|
9716
|
+
json$1.type = "string";
|
|
9717
|
+
json$1.pattern = pattern.source;
|
|
9718
|
+
break;
|
|
9719
|
+
}
|
|
9720
|
+
case "pipe": {
|
|
9721
|
+
const innerType = this.io === "input" ? def.in._zod.def.type === "transform" ? def.out : def.in : def.out;
|
|
9722
|
+
this.process(innerType, params);
|
|
9723
|
+
result.ref = innerType;
|
|
9724
|
+
break;
|
|
9725
|
+
}
|
|
9726
|
+
case "readonly": {
|
|
9727
|
+
this.process(def.innerType, params);
|
|
9728
|
+
result.ref = def.innerType;
|
|
9729
|
+
_json.readOnly = true;
|
|
9730
|
+
break;
|
|
9731
|
+
}
|
|
9732
|
+
case "promise": {
|
|
9733
|
+
this.process(def.innerType, params);
|
|
9734
|
+
result.ref = def.innerType;
|
|
9735
|
+
break;
|
|
9736
|
+
}
|
|
9737
|
+
case "optional": {
|
|
9738
|
+
this.process(def.innerType, params);
|
|
9739
|
+
result.ref = def.innerType;
|
|
9740
|
+
break;
|
|
9741
|
+
}
|
|
9742
|
+
case "lazy": {
|
|
9743
|
+
const innerType = schema._zod.innerType;
|
|
9744
|
+
this.process(innerType, params);
|
|
9745
|
+
result.ref = innerType;
|
|
9746
|
+
break;
|
|
9747
|
+
}
|
|
9748
|
+
case "custom": {
|
|
9749
|
+
if (this.unrepresentable === "throw") {
|
|
9750
|
+
throw new Error("Custom types cannot be represented in JSON Schema");
|
|
9751
|
+
}
|
|
9752
|
+
break;
|
|
9753
|
+
}
|
|
9754
|
+
default: {
|
|
9755
|
+
def;
|
|
9432
9756
|
}
|
|
9433
|
-
break;
|
|
9434
|
-
}
|
|
9435
|
-
default: {
|
|
9436
|
-
def;
|
|
9437
9757
|
}
|
|
9438
9758
|
}
|
|
9439
9759
|
}
|
|
@@ -9460,12 +9780,15 @@ var JSONSchemaGenerator = class {
|
|
|
9460
9780
|
const defsSegment = this.target === "draft-2020-12" ? "$defs" : "definitions";
|
|
9461
9781
|
if (params.external) {
|
|
9462
9782
|
const externalId = params.external.registry.get(entry[0])?.id;
|
|
9463
|
-
|
|
9783
|
+
const uriGenerator = params.external.uri ?? ((id$1) => id$1);
|
|
9784
|
+
if (externalId) {
|
|
9785
|
+
return { ref: uriGenerator(externalId) };
|
|
9786
|
+
}
|
|
9464
9787
|
const id = entry[1].defId ?? entry[1].schema.id ?? `schema${this.counter++}`;
|
|
9465
9788
|
entry[1].defId = id;
|
|
9466
9789
|
return {
|
|
9467
9790
|
defId: id,
|
|
9468
|
-
ref: `${
|
|
9791
|
+
ref: `${uriGenerator("__shared")}#/${defsSegment}/${id}`
|
|
9469
9792
|
};
|
|
9470
9793
|
}
|
|
9471
9794
|
if (entry[1] === root) {
|
|
@@ -9493,6 +9816,14 @@ var JSONSchemaGenerator = class {
|
|
|
9493
9816
|
}
|
|
9494
9817
|
schema$1.$ref = ref;
|
|
9495
9818
|
};
|
|
9819
|
+
if (params.cycles === "throw") {
|
|
9820
|
+
for (const entry of this.seen.entries()) {
|
|
9821
|
+
const seen = entry[1];
|
|
9822
|
+
if (seen.cycle) {
|
|
9823
|
+
throw new Error("Cycle detected: " + `#/${seen.cycle?.join("/")}/<root>` + "\n\nSet the `cycles` parameter to `\"ref\"` to resolve cyclical schemas with defs.");
|
|
9824
|
+
}
|
|
9825
|
+
}
|
|
9826
|
+
}
|
|
9496
9827
|
for (const entry of this.seen.entries()) {
|
|
9497
9828
|
const seen = entry[1];
|
|
9498
9829
|
if (schema === entry[0]) {
|
|
@@ -9512,11 +9843,7 @@ var JSONSchemaGenerator = class {
|
|
|
9512
9843
|
continue;
|
|
9513
9844
|
}
|
|
9514
9845
|
if (seen.cycle) {
|
|
9515
|
-
|
|
9516
|
-
throw new Error("Cycle detected: " + `#/${seen.cycle?.join("/")}/<root>` + "\n\nSet the `cycles` parameter to `\"ref\"` to resolve cyclical schemas with defs.");
|
|
9517
|
-
} else if (params.cycles === "ref") {
|
|
9518
|
-
extractToDef(entry);
|
|
9519
|
-
}
|
|
9846
|
+
extractToDef(entry);
|
|
9520
9847
|
continue;
|
|
9521
9848
|
}
|
|
9522
9849
|
if (seen.count > 1) {
|
|
@@ -9548,7 +9875,8 @@ var JSONSchemaGenerator = class {
|
|
|
9548
9875
|
}
|
|
9549
9876
|
if (!seen.isParent) this.override({
|
|
9550
9877
|
zodSchema,
|
|
9551
|
-
jsonSchema: schema$1
|
|
9878
|
+
jsonSchema: schema$1,
|
|
9879
|
+
path: seen.path ?? []
|
|
9552
9880
|
});
|
|
9553
9881
|
};
|
|
9554
9882
|
for (const entry of [...this.seen.entries()].reverse()) {
|
|
@@ -9562,6 +9890,11 @@ var JSONSchemaGenerator = class {
|
|
|
9562
9890
|
} else {
|
|
9563
9891
|
console.warn(`Invalid target: ${this.target}`);
|
|
9564
9892
|
}
|
|
9893
|
+
if (params.external?.uri) {
|
|
9894
|
+
const id = params.external.registry.get(schema)?.id;
|
|
9895
|
+
if (!id) throw new Error("Schema is missing an `id` property");
|
|
9896
|
+
result.$id = params.external.uri(id);
|
|
9897
|
+
}
|
|
9565
9898
|
Object.assign(result, root.def);
|
|
9566
9899
|
const defs = params.external?.defs ?? {};
|
|
9567
9900
|
for (const entry of this.seen.entries()) {
|
|
@@ -9570,11 +9903,13 @@ var JSONSchemaGenerator = class {
|
|
|
9570
9903
|
defs[seen.defId] = seen.def;
|
|
9571
9904
|
}
|
|
9572
9905
|
}
|
|
9573
|
-
if (
|
|
9574
|
-
if (
|
|
9575
|
-
|
|
9576
|
-
|
|
9577
|
-
|
|
9906
|
+
if (params.external) {} else {
|
|
9907
|
+
if (Object.keys(defs).length > 0) {
|
|
9908
|
+
if (this.target === "draft-2020-12") {
|
|
9909
|
+
result.$defs = defs;
|
|
9910
|
+
} else {
|
|
9911
|
+
result.definitions = defs;
|
|
9912
|
+
}
|
|
9578
9913
|
}
|
|
9579
9914
|
}
|
|
9580
9915
|
try {
|
|
@@ -9595,7 +9930,7 @@ function toJSONSchema(input, _params) {
|
|
|
9595
9930
|
const schemas = {};
|
|
9596
9931
|
const external = {
|
|
9597
9932
|
registry: input,
|
|
9598
|
-
uri: _params?.uri
|
|
9933
|
+
uri: _params?.uri,
|
|
9599
9934
|
defs
|
|
9600
9935
|
};
|
|
9601
9936
|
for (const entry of input._idmap.entries()) {
|
|
@@ -9706,11 +10041,11 @@ function isTransforming(_schema, _ctx) {
|
|
|
9706
10041
|
}
|
|
9707
10042
|
|
|
9708
10043
|
//#endregion
|
|
9709
|
-
//#region ../../node_modules/zod/
|
|
10044
|
+
//#region ../../node_modules/zod/v4/core/json-schema.js
|
|
9710
10045
|
var json_schema_exports = {};
|
|
9711
10046
|
|
|
9712
10047
|
//#endregion
|
|
9713
|
-
//#region ../../node_modules/zod/
|
|
10048
|
+
//#region ../../node_modules/zod/v4/core/index.js
|
|
9714
10049
|
var core_exports = {};
|
|
9715
10050
|
__export(core_exports, {
|
|
9716
10051
|
$ZodAny: () => $ZodAny,
|
|
@@ -9749,6 +10084,7 @@ __export(core_exports, {
|
|
|
9749
10084
|
$ZodCheckStringFormat: () => $ZodCheckStringFormat,
|
|
9750
10085
|
$ZodCheckUpperCase: () => $ZodCheckUpperCase,
|
|
9751
10086
|
$ZodCustom: () => $ZodCustom,
|
|
10087
|
+
$ZodCustomStringFormat: () => $ZodCustomStringFormat,
|
|
9752
10088
|
$ZodDate: () => $ZodDate,
|
|
9753
10089
|
$ZodDefault: () => $ZodDefault,
|
|
9754
10090
|
$ZodDiscriminatedUnion: () => $ZodDiscriminatedUnion,
|
|
@@ -9813,6 +10149,8 @@ __export(core_exports, {
|
|
|
9813
10149
|
Doc: () => Doc,
|
|
9814
10150
|
JSONSchema: () => json_schema_exports,
|
|
9815
10151
|
JSONSchemaGenerator: () => JSONSchemaGenerator,
|
|
10152
|
+
NEVER: () => NEVER,
|
|
10153
|
+
TimePrecision: () => TimePrecision,
|
|
9816
10154
|
_any: () => _any,
|
|
9817
10155
|
_array: () => _array,
|
|
9818
10156
|
_base64: () => _base64,
|
|
@@ -9902,6 +10240,7 @@ __export(core_exports, {
|
|
|
9902
10240
|
_size: () => _size,
|
|
9903
10241
|
_startsWith: () => _startsWith,
|
|
9904
10242
|
_string: () => _string,
|
|
10243
|
+
_stringFormat: () => _stringFormat,
|
|
9905
10244
|
_stringbool: () => _stringbool,
|
|
9906
10245
|
_success: () => _success,
|
|
9907
10246
|
_symbol: () => _symbol,
|
|
@@ -9951,7 +10290,7 @@ __export(core_exports, {
|
|
|
9951
10290
|
});
|
|
9952
10291
|
|
|
9953
10292
|
//#endregion
|
|
9954
|
-
//#region ../../node_modules/zod/
|
|
10293
|
+
//#region ../../node_modules/zod/v4/classic/iso.js
|
|
9955
10294
|
var iso_exports = {};
|
|
9956
10295
|
__export(iso_exports, {
|
|
9957
10296
|
ZodISODate: () => ZodISODate,
|
|
@@ -9993,7 +10332,7 @@ function duration(params) {
|
|
|
9993
10332
|
}
|
|
9994
10333
|
|
|
9995
10334
|
//#endregion
|
|
9996
|
-
//#region ../../node_modules/zod/
|
|
10335
|
+
//#region ../../node_modules/zod/v4/classic/errors.js
|
|
9997
10336
|
const initializer = (inst, issues) => {
|
|
9998
10337
|
$ZodError.init(inst, issues);
|
|
9999
10338
|
inst.name = "ZodError";
|
|
@@ -10011,14 +10350,14 @@ const ZodError = $constructor("ZodError", initializer);
|
|
|
10011
10350
|
const ZodRealError = $constructor("ZodError", initializer, { Parent: Error });
|
|
10012
10351
|
|
|
10013
10352
|
//#endregion
|
|
10014
|
-
//#region ../../node_modules/zod/
|
|
10353
|
+
//#region ../../node_modules/zod/v4/classic/parse.js
|
|
10015
10354
|
const parse = /* @__PURE__ */ _parse(ZodRealError);
|
|
10016
10355
|
const parseAsync = /* @__PURE__ */ _parseAsync(ZodRealError);
|
|
10017
10356
|
const safeParse = /* @__PURE__ */ _safeParse(ZodRealError);
|
|
10018
10357
|
const safeParseAsync = /* @__PURE__ */ _safeParseAsync(ZodRealError);
|
|
10019
10358
|
|
|
10020
10359
|
//#endregion
|
|
10021
|
-
//#region ../../node_modules/zod/
|
|
10360
|
+
//#region ../../node_modules/zod/v4/classic/schemas.js
|
|
10022
10361
|
const ZodType = /* @__PURE__ */ $constructor("ZodType", (inst, def) => {
|
|
10023
10362
|
$ZodType.init(inst, def);
|
|
10024
10363
|
inst.def = def;
|
|
@@ -10286,6 +10625,13 @@ const ZodJWT = /* @__PURE__ */ $constructor("ZodJWT", (inst, def) => {
|
|
|
10286
10625
|
function jwt(params) {
|
|
10287
10626
|
return _jwt(ZodJWT, params);
|
|
10288
10627
|
}
|
|
10628
|
+
const ZodCustomStringFormat = /* @__PURE__ */ $constructor("ZodCustomStringFormat", (inst, def) => {
|
|
10629
|
+
$ZodCustomStringFormat.init(inst, def);
|
|
10630
|
+
ZodStringFormat.init(inst, def);
|
|
10631
|
+
});
|
|
10632
|
+
function stringFormat(format, fnOrRegex, _params = {}) {
|
|
10633
|
+
return _stringFormat(ZodCustomStringFormat, format, fnOrRegex, _params);
|
|
10634
|
+
}
|
|
10289
10635
|
const ZodNumber = /* @__PURE__ */ $constructor("ZodNumber", (inst, def) => {
|
|
10290
10636
|
$ZodNumber.init(inst, def);
|
|
10291
10637
|
ZodType.init(inst, def);
|
|
@@ -10455,9 +10801,7 @@ function keyof(schema) {
|
|
|
10455
10801
|
const ZodObject = /* @__PURE__ */ $constructor("ZodObject", (inst, def) => {
|
|
10456
10802
|
$ZodObject.init(inst, def);
|
|
10457
10803
|
ZodType.init(inst, def);
|
|
10458
|
-
defineLazy(inst, "shape", () =>
|
|
10459
|
-
return Object.fromEntries(Object.entries(inst._zod.def.shape));
|
|
10460
|
-
});
|
|
10804
|
+
defineLazy(inst, "shape", () => def.shape);
|
|
10461
10805
|
inst.keyof = () => _enum(Object.keys(inst._zod.def.shape));
|
|
10462
10806
|
inst.catchall = (catchall) => inst.clone({
|
|
10463
10807
|
...inst._zod.def,
|
|
@@ -10902,11 +11246,8 @@ const ZodCustom = /* @__PURE__ */ $constructor("ZodCustom", (inst, def) => {
|
|
|
10902
11246
|
$ZodCustom.init(inst, def);
|
|
10903
11247
|
ZodType.init(inst, def);
|
|
10904
11248
|
});
|
|
10905
|
-
function check(fn
|
|
10906
|
-
const ch = new $ZodCheck({
|
|
10907
|
-
check: "custom",
|
|
10908
|
-
...normalizeParams(params)
|
|
10909
|
-
});
|
|
11249
|
+
function check(fn) {
|
|
11250
|
+
const ch = new $ZodCheck({ check: "custom" });
|
|
10910
11251
|
ch._zod.check = fn;
|
|
10911
11252
|
return ch;
|
|
10912
11253
|
}
|
|
@@ -10916,7 +11257,7 @@ function custom(fn, _params) {
|
|
|
10916
11257
|
function refine(fn, _params = {}) {
|
|
10917
11258
|
return _refine(ZodCustom, fn, _params);
|
|
10918
11259
|
}
|
|
10919
|
-
function superRefine(fn
|
|
11260
|
+
function superRefine(fn) {
|
|
10920
11261
|
const ch = check((payload) => {
|
|
10921
11262
|
payload.addIssue = (issue$1) => {
|
|
10922
11263
|
if (typeof issue$1 === "string") {
|
|
@@ -10932,7 +11273,7 @@ function superRefine(fn, params) {
|
|
|
10932
11273
|
}
|
|
10933
11274
|
};
|
|
10934
11275
|
return fn(payload.value, payload);
|
|
10935
|
-
}
|
|
11276
|
+
});
|
|
10936
11277
|
return ch;
|
|
10937
11278
|
}
|
|
10938
11279
|
function _instanceof(cls, params = { error: `Input not instance of ${cls.name}` }) {
|
|
@@ -10970,7 +11311,7 @@ function preprocess(fn, schema) {
|
|
|
10970
11311
|
}
|
|
10971
11312
|
|
|
10972
11313
|
//#endregion
|
|
10973
|
-
//#region ../../node_modules/zod/
|
|
11314
|
+
//#region ../../node_modules/zod/v4/classic/compat.js
|
|
10974
11315
|
/** @deprecated Use the raw string literal codes instead, e.g. "invalid_type". */
|
|
10975
11316
|
const ZodIssueCode = {
|
|
10976
11317
|
invalid_type: "invalid_type",
|
|
@@ -10985,10 +11326,6 @@ const ZodIssueCode = {
|
|
|
10985
11326
|
invalid_value: "invalid_value",
|
|
10986
11327
|
custom: "custom"
|
|
10987
11328
|
};
|
|
10988
|
-
/** @deprecated Not necessary in Zod 4. */
|
|
10989
|
-
const INVALID = Object.freeze({ status: "aborted" });
|
|
10990
|
-
/** A special constant with type `never` */
|
|
10991
|
-
const NEVER = INVALID;
|
|
10992
11329
|
/** @deprecated Use `z.config(params)` instead. */
|
|
10993
11330
|
function setErrorMap(map$1) {
|
|
10994
11331
|
config$2({ customError: map$1 });
|
|
@@ -10997,9 +11334,12 @@ function setErrorMap(map$1) {
|
|
|
10997
11334
|
function getErrorMap() {
|
|
10998
11335
|
return config$2().customError;
|
|
10999
11336
|
}
|
|
11337
|
+
/** @deprecated Do not use. Stub definition, only included for zod-to-json-schema compatibility. */
|
|
11338
|
+
var ZodFirstPartyTypeKind;
|
|
11339
|
+
(function(ZodFirstPartyTypeKind$1) {})(ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {}));
|
|
11000
11340
|
|
|
11001
11341
|
//#endregion
|
|
11002
|
-
//#region ../../node_modules/zod/
|
|
11342
|
+
//#region ../../node_modules/zod/v4/classic/coerce.js
|
|
11003
11343
|
var coerce_exports = {};
|
|
11004
11344
|
__export(coerce_exports, {
|
|
11005
11345
|
bigint: () => bigint,
|
|
@@ -11025,13 +11365,14 @@ function date(params) {
|
|
|
11025
11365
|
}
|
|
11026
11366
|
|
|
11027
11367
|
//#endregion
|
|
11028
|
-
//#region ../../node_modules/zod/
|
|
11368
|
+
//#region ../../node_modules/zod/v4/classic/external.js
|
|
11029
11369
|
var external_exports = {};
|
|
11030
11370
|
__export(external_exports, {
|
|
11031
11371
|
$brand: () => $brand,
|
|
11032
11372
|
$input: () => $input,
|
|
11033
11373
|
$output: () => $output,
|
|
11034
11374
|
NEVER: () => NEVER,
|
|
11375
|
+
TimePrecision: () => TimePrecision,
|
|
11035
11376
|
ZodAny: () => ZodAny,
|
|
11036
11377
|
ZodArray: () => ZodArray,
|
|
11037
11378
|
ZodBase64: () => ZodBase64,
|
|
@@ -11045,6 +11386,7 @@ __export(external_exports, {
|
|
|
11045
11386
|
ZodCUID2: () => ZodCUID2,
|
|
11046
11387
|
ZodCatch: () => ZodCatch,
|
|
11047
11388
|
ZodCustom: () => ZodCustom,
|
|
11389
|
+
ZodCustomStringFormat: () => ZodCustomStringFormat,
|
|
11048
11390
|
ZodDate: () => ZodDate,
|
|
11049
11391
|
ZodDefault: () => ZodDefault,
|
|
11050
11392
|
ZodDiscriminatedUnion: () => ZodDiscriminatedUnion,
|
|
@@ -11054,6 +11396,7 @@ __export(external_exports, {
|
|
|
11054
11396
|
ZodEnum: () => ZodEnum,
|
|
11055
11397
|
ZodError: () => ZodError,
|
|
11056
11398
|
ZodFile: () => ZodFile,
|
|
11399
|
+
ZodFirstPartyTypeKind: () => ZodFirstPartyTypeKind,
|
|
11057
11400
|
ZodGUID: () => ZodGUID,
|
|
11058
11401
|
ZodIPv4: () => ZodIPv4,
|
|
11059
11402
|
ZodIPv6: () => ZodIPv6,
|
|
@@ -11206,6 +11549,7 @@ __export(external_exports, {
|
|
|
11206
11549
|
startsWith: () => _startsWith,
|
|
11207
11550
|
strictObject: () => strictObject,
|
|
11208
11551
|
string: () => string$1,
|
|
11552
|
+
stringFormat: () => stringFormat,
|
|
11209
11553
|
stringbool: () => stringbool,
|
|
11210
11554
|
success: () => success,
|
|
11211
11555
|
superRefine: () => superRefine,
|
|
@@ -11236,11 +11580,11 @@ __export(external_exports, {
|
|
|
11236
11580
|
config$2(en_default());
|
|
11237
11581
|
|
|
11238
11582
|
//#endregion
|
|
11239
|
-
//#region ../../node_modules/zod/
|
|
11583
|
+
//#region ../../node_modules/zod/v4/classic/index.js
|
|
11240
11584
|
var classic_default = external_exports;
|
|
11241
11585
|
|
|
11242
11586
|
//#endregion
|
|
11243
|
-
//#region ../../node_modules/zod/
|
|
11587
|
+
//#region ../../node_modules/zod/v4/index.js
|
|
11244
11588
|
var v4_default = classic_default;
|
|
11245
11589
|
|
|
11246
11590
|
//#endregion
|
|
@@ -11261,12 +11605,12 @@ var v4_default = classic_default;
|
|
|
11261
11605
|
function validate(schema, value) {
|
|
11262
11606
|
try {
|
|
11263
11607
|
return schema.parse(value);
|
|
11264
|
-
} catch (error$
|
|
11265
|
-
if (error$
|
|
11266
|
-
const formattedErrors = error$
|
|
11267
|
-
throw new Error(`Validation error${error$
|
|
11608
|
+
} catch (error$39) {
|
|
11609
|
+
if (error$39 instanceof ZodError) {
|
|
11610
|
+
const formattedErrors = error$39.issues.map((err) => `- ${err.path.join(".")}: ${err.message}`).join("\n");
|
|
11611
|
+
throw new Error(`Validation error${error$39.issues.length > 1 ? "s" : ""}:\n${formattedErrors}`);
|
|
11268
11612
|
}
|
|
11269
|
-
throw error$
|
|
11613
|
+
throw error$39;
|
|
11270
11614
|
}
|
|
11271
11615
|
}
|
|
11272
11616
|
|
|
@@ -11569,8 +11913,8 @@ async function loadEnvironmentEnv(validateEnv, prod, path$1 = process.cwd()) {
|
|
|
11569
11913
|
...parsed,
|
|
11570
11914
|
...defaultEnv
|
|
11571
11915
|
});
|
|
11572
|
-
} catch (error$
|
|
11573
|
-
cancel(error$
|
|
11916
|
+
} catch (error$39) {
|
|
11917
|
+
cancel(error$39.message);
|
|
11574
11918
|
return {};
|
|
11575
11919
|
}
|
|
11576
11920
|
}
|