@camstack/addon-provider-homematic 1.2.192 → 1.2.194
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/CHANGELOG.md +14 -0
- package/README.md +8 -0
- package/dist/.bundle-modules.json +7 -4
- package/dist/_stub.js +1168 -1012
- package/dist/{_virtual_mf-localSharedImportMap___mfe_internal__addon_provider_homematic_page-DpkPuRM1.mjs → _virtual_mf-localSharedImportMap___mfe_internal__addon_provider_homematic_page-Da2xbO9l.mjs} +4 -4
- package/dist/_virtual_mf___mfe_internal__addon_provider_homematic_page__loadShare___mf_0_camstack_mf_1_ui_mf_2_library__loadShare__.js-CqBgrgbo.mjs +26 -0
- package/dist/addon-provider-homematic.css +1 -1
- package/dist/addon.js +1946 -815
- package/dist/addon.mjs +1947 -816
- package/dist/{hostInit-DnCa060J.mjs → hostInit-DAlzBsEA.mjs} +3 -3
- package/dist/index.mjs +1 -1
- package/dist/remoteEntry.js +1 -1
- package/dist/{virtual_mf-REMOTE_ENTRY_ID___mfe_internal__addon_provider_homematic_page__remoteEntry_js-BJyaKTxj.mjs → virtual_mf-REMOTE_ENTRY_ID___mfe_internal__addon_provider_homematic_page__remoteEntry_js-BvA2vFCp.mjs} +1 -1
- package/i18n/en.json +5 -1
- package/i18n/it.json +5 -1
- package/package.json +3 -3
- package/dist/_virtual_mf___mfe_internal__addon_provider_homematic_page__loadShare___mf_0_camstack_mf_1_ui_mf_2_library__loadShare__.js-vLxa-QXn.mjs +0 -26
package/dist/_stub.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import "./virtualExposes-v5SsyBZj.mjs";
|
|
2
|
-
import "./virtual_mf-REMOTE_ENTRY_ID___mfe_internal__addon_provider_homematic_page__remoteEntry_js-
|
|
2
|
+
import "./virtual_mf-REMOTE_ENTRY_ID___mfe_internal__addon_provider_homematic_page__remoteEntry_js-BvA2vFCp.mjs";
|
|
3
3
|
import { a as e, i as t, n, o as r, r as i, s as a, t as o } from "./_virtual_mf___mfe_internal__addon_provider_homematic_page__loadShare__react__loadShare__.js-iX7UoD9E.mjs";
|
|
4
|
-
import { S as s, _ as c, a as l, b as u, c as d, d as f, f as p, g as m, h, i as g, l as _, m as v, n as y, o as b, p as ee, r as te, s as ne, t as re, u as x, v as ie, x as S, y as ae } from "./_virtual_mf___mfe_internal__addon_provider_homematic_page__loadShare___mf_0_camstack_mf_1_ui_mf_2_library__loadShare__.js-
|
|
4
|
+
import { S as s, _ as c, a as l, b as u, c as d, d as f, f as p, g as m, h, i as g, l as _, m as v, n as y, o as b, p as ee, r as te, s as ne, t as re, u as x, v as ie, x as S, y as ae } from "./_virtual_mf___mfe_internal__addon_provider_homematic_page__loadShare___mf_0_camstack_mf_1_ui_mf_2_library__loadShare__.js-CqBgrgbo.mjs";
|
|
5
5
|
import { n as C, t as w } from "./_virtual_mf___mfe_internal__addon_provider_homematic_page__loadShare__react_mf_1_jsx_mf_2_runtime__loadShare__.js-15LkOsGv.mjs";
|
|
6
6
|
//#region ../../node_modules/lucide-react/dist/esm/shared/src/utils/mergeClasses.js
|
|
7
7
|
var oe = (...e) => e.filter((e, t, n) => !!e && e.trim() !== "" && n.indexOf(e) === t).join(" ").trim(), se = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1-$2").toLowerCase(), ce = (e) => e.replace(/^([A-Z])|[\s-_]+(\w)/g, (e, t, n) => n ? n.toUpperCase() : t.toLowerCase()), le = (e) => {
|
|
@@ -41,19 +41,40 @@ var oe = (...e) => e.filter((e, t, n) => !!e && e.trim() !== "" && n.indexOf(e)
|
|
|
41
41
|
}, pe = T("flame", [["path", {
|
|
42
42
|
d: "M12 3q1 4 4 6.5t3 5.5a1 1 0 0 1-14 0 5 5 0 0 1 1-3 1 1 0 0 0 5 0c0-2-1.5-3-1.5-5q0-2 2.5-4",
|
|
43
43
|
key: "1slcih"
|
|
44
|
-
}]]), me = T("
|
|
44
|
+
}]]), me = T("mouse-pointer-click", [
|
|
45
|
+
["path", {
|
|
46
|
+
d: "M14 4.1 12 6",
|
|
47
|
+
key: "ita8i4"
|
|
48
|
+
}],
|
|
49
|
+
["path", {
|
|
50
|
+
d: "m5.1 8-2.9-.8",
|
|
51
|
+
key: "1go3kf"
|
|
52
|
+
}],
|
|
53
|
+
["path", {
|
|
54
|
+
d: "m6 12-1.9 2",
|
|
55
|
+
key: "mnht97"
|
|
56
|
+
}],
|
|
57
|
+
["path", {
|
|
58
|
+
d: "M7.2 2.2 8 5.1",
|
|
59
|
+
key: "1cfko1"
|
|
60
|
+
}],
|
|
61
|
+
["path", {
|
|
62
|
+
d: "M9.037 9.69a.498.498 0 0 1 .653-.653l11 4.5a.5.5 0 0 1-.074.949l-4.349 1.041a1 1 0 0 0-.74.739l-1.04 4.35a.5.5 0 0 1-.95.074z",
|
|
63
|
+
key: "s0h3yz"
|
|
64
|
+
}]
|
|
65
|
+
]), he = T("pencil", [["path", {
|
|
45
66
|
d: "M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",
|
|
46
67
|
key: "1a8usu"
|
|
47
68
|
}], ["path", {
|
|
48
69
|
d: "m15 5 4 4",
|
|
49
70
|
key: "1mk7zo"
|
|
50
|
-
}]]),
|
|
71
|
+
}]]), ge = T("plus", [["path", {
|
|
51
72
|
d: "M5 12h14",
|
|
52
73
|
key: "1ays0h"
|
|
53
74
|
}], ["path", {
|
|
54
75
|
d: "M12 5v14",
|
|
55
76
|
key: "s699le"
|
|
56
|
-
}]]),
|
|
77
|
+
}]]), _e = T("plug", [
|
|
57
78
|
["path", {
|
|
58
79
|
d: "M12 22v-5",
|
|
59
80
|
key: "1ega77"
|
|
@@ -70,7 +91,7 @@ var oe = (...e) => e.filter((e, t, n) => !!e && e.trim() !== "" && n.indexOf(e)
|
|
|
70
91
|
d: "M9 8V2",
|
|
71
92
|
key: "14iosj"
|
|
72
93
|
}]
|
|
73
|
-
]),
|
|
94
|
+
]), ve = T("radio", [
|
|
74
95
|
["path", {
|
|
75
96
|
d: "M16.247 7.761a6 6 0 0 1 0 8.478",
|
|
76
97
|
key: "1fwjs5"
|
|
@@ -93,7 +114,7 @@ var oe = (...e) => e.filter((e, t, n) => !!e && e.trim() !== "" && n.indexOf(e)
|
|
|
93
114
|
r: "2",
|
|
94
115
|
key: "1c9p78"
|
|
95
116
|
}]
|
|
96
|
-
]),
|
|
117
|
+
]), ye = T("sliders-horizontal", [
|
|
97
118
|
["path", {
|
|
98
119
|
d: "M10 5H3",
|
|
99
120
|
key: "1qgfaw"
|
|
@@ -130,7 +151,7 @@ var oe = (...e) => e.filter((e, t, n) => !!e && e.trim() !== "" && n.indexOf(e)
|
|
|
130
151
|
d: "M8 12H3",
|
|
131
152
|
key: "a7s4jb"
|
|
132
153
|
}]
|
|
133
|
-
]),
|
|
154
|
+
]), be = T("trash-2", [
|
|
134
155
|
["path", {
|
|
135
156
|
d: "M10 11v6",
|
|
136
157
|
key: "nco0om"
|
|
@@ -151,7 +172,7 @@ var oe = (...e) => e.filter((e, t, n) => !!e && e.trim() !== "" && n.indexOf(e)
|
|
|
151
172
|
d: "M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2",
|
|
152
173
|
key: "e791ji"
|
|
153
174
|
}]
|
|
154
|
-
]),
|
|
175
|
+
]), xe = T("triangle-alert", [
|
|
155
176
|
["path", {
|
|
156
177
|
d: "m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3",
|
|
157
178
|
key: "wmoenq"
|
|
@@ -164,7 +185,7 @@ var oe = (...e) => e.filter((e, t, n) => !!e && e.trim() !== "" && n.indexOf(e)
|
|
|
164
185
|
d: "M12 17h.01",
|
|
165
186
|
key: "p32p05"
|
|
166
187
|
}]
|
|
167
|
-
]),
|
|
188
|
+
]), Se;
|
|
168
189
|
function E(e, t, n) {
|
|
169
190
|
function r(n, r) {
|
|
170
191
|
if (n._zod || Object.defineProperty(n, "_zod", {
|
|
@@ -194,30 +215,30 @@ function E(e, t, n) {
|
|
|
194
215
|
}
|
|
195
216
|
return Object.defineProperty(o, "init", { value: r }), Object.defineProperty(o, Symbol.hasInstance, { value: (t) => n?.Parent && t instanceof n.Parent ? !0 : t?._zod?.traits?.has(e) }), Object.defineProperty(o, "name", { value: e }), o;
|
|
196
217
|
}
|
|
197
|
-
var
|
|
218
|
+
var Ce = class extends Error {
|
|
198
219
|
constructor() {
|
|
199
220
|
super("Encountered Promise during synchronous parse. Use .parseAsync() instead.");
|
|
200
221
|
}
|
|
201
|
-
},
|
|
222
|
+
}, we = class extends Error {
|
|
202
223
|
constructor(e) {
|
|
203
224
|
super(`Encountered unidirectional transform during encode: ${e}`), this.name = "ZodEncodeError";
|
|
204
225
|
}
|
|
205
226
|
};
|
|
206
|
-
(
|
|
207
|
-
var
|
|
227
|
+
(Se = globalThis).__zod_globalConfig ?? (Se.__zod_globalConfig = {});
|
|
228
|
+
var Te = globalThis.__zod_globalConfig;
|
|
208
229
|
function D(e) {
|
|
209
|
-
return e && Object.assign(
|
|
230
|
+
return e && Object.assign(Te, e), Te;
|
|
210
231
|
}
|
|
211
232
|
//#endregion
|
|
212
233
|
//#region ../../node_modules/zod/v4/core/util.js
|
|
213
|
-
function
|
|
234
|
+
function Ee(e) {
|
|
214
235
|
let t = Object.values(e).filter((e) => typeof e == "number");
|
|
215
236
|
return Object.entries(e).filter(([e, n]) => t.indexOf(+e) === -1).map(([e, t]) => t);
|
|
216
237
|
}
|
|
217
|
-
function
|
|
238
|
+
function De(e, t) {
|
|
218
239
|
return typeof t == "bigint" ? t.toString() : t;
|
|
219
240
|
}
|
|
220
|
-
function
|
|
241
|
+
function Oe(e) {
|
|
221
242
|
return { get value() {
|
|
222
243
|
{
|
|
223
244
|
let t = e();
|
|
@@ -226,23 +247,23 @@ function De(e) {
|
|
|
226
247
|
throw Error("cached value already set");
|
|
227
248
|
} };
|
|
228
249
|
}
|
|
229
|
-
function
|
|
250
|
+
function ke(e) {
|
|
230
251
|
return e == null;
|
|
231
252
|
}
|
|
232
|
-
function
|
|
253
|
+
function Ae(e) {
|
|
233
254
|
let t = +!!e.startsWith("^"), n = e.endsWith("$") ? e.length - 1 : e.length;
|
|
234
255
|
return e.slice(t, n);
|
|
235
256
|
}
|
|
236
|
-
function
|
|
257
|
+
function je(e, t) {
|
|
237
258
|
let n = e / t, r = Math.round(n), i = 2 ** -52 * Math.max(Math.abs(n), 1);
|
|
238
259
|
return Math.abs(n - r) < i ? 0 : n - r;
|
|
239
260
|
}
|
|
240
|
-
var
|
|
261
|
+
var Me = /* @__PURE__*/ Symbol("evaluating");
|
|
241
262
|
function O(e, t, n) {
|
|
242
263
|
let r;
|
|
243
264
|
Object.defineProperty(e, t, {
|
|
244
265
|
get() {
|
|
245
|
-
if (r !==
|
|
266
|
+
if (r !== Me) return r === void 0 && (r = Me, r = n()), r;
|
|
246
267
|
},
|
|
247
268
|
set(n) {
|
|
248
269
|
Object.defineProperty(e, t, { value: n });
|
|
@@ -263,47 +284,47 @@ function A(...e) {
|
|
|
263
284
|
for (let n of e) Object.assign(t, Object.getOwnPropertyDescriptors(n));
|
|
264
285
|
return Object.defineProperties({}, t);
|
|
265
286
|
}
|
|
266
|
-
function
|
|
287
|
+
function Ne(e) {
|
|
267
288
|
return JSON.stringify(e);
|
|
268
289
|
}
|
|
269
|
-
function
|
|
290
|
+
function Pe(e) {
|
|
270
291
|
return e.toLowerCase().trim().replace(/[^\w\s-]/g, "").replace(/[\s_-]+/g, "-").replace(/^-+|-+$/g, "");
|
|
271
292
|
}
|
|
272
|
-
var
|
|
273
|
-
function
|
|
293
|
+
var Fe = "captureStackTrace" in Error ? Error.captureStackTrace : (...e) => {};
|
|
294
|
+
function Ie(e) {
|
|
274
295
|
return typeof e == "object" && !!e && !Array.isArray(e);
|
|
275
296
|
}
|
|
276
|
-
var
|
|
277
|
-
if (
|
|
297
|
+
var Le = /* @__PURE__*/ Oe(() => {
|
|
298
|
+
if (Te.jitless || typeof navigator < "u" && navigator?.userAgent?.includes("Cloudflare")) return !1;
|
|
278
299
|
try {
|
|
279
300
|
return Function(""), !0;
|
|
280
301
|
} catch {
|
|
281
302
|
return !1;
|
|
282
303
|
}
|
|
283
304
|
});
|
|
284
|
-
function
|
|
285
|
-
if (
|
|
305
|
+
function Re(e) {
|
|
306
|
+
if (Ie(e) === !1) return !1;
|
|
286
307
|
let t = e.constructor;
|
|
287
308
|
if (t === void 0 || typeof t != "function") return !0;
|
|
288
309
|
let n = t.prototype;
|
|
289
|
-
return !(
|
|
310
|
+
return !(Ie(n) === !1 || Object.prototype.hasOwnProperty.call(n, "isPrototypeOf") === !1);
|
|
290
311
|
}
|
|
291
|
-
function
|
|
292
|
-
return
|
|
312
|
+
function ze(e) {
|
|
313
|
+
return Re(e) ? { ...e } : Array.isArray(e) ? [...e] : e instanceof Map ? new Map(e) : e instanceof Set ? new Set(e) : e;
|
|
293
314
|
}
|
|
294
|
-
var
|
|
315
|
+
var Be = /* @__PURE__*/ new Set([
|
|
295
316
|
"string",
|
|
296
317
|
"number",
|
|
297
318
|
"symbol"
|
|
298
319
|
]);
|
|
299
|
-
function
|
|
320
|
+
function j(e) {
|
|
300
321
|
return e.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
|
|
301
322
|
}
|
|
302
|
-
function
|
|
323
|
+
function M(e, t, n) {
|
|
303
324
|
let r = new e._zod.constr(t ?? e._zod.def);
|
|
304
325
|
return (!t || n?.parent) && (r._zod.parent = e), r;
|
|
305
326
|
}
|
|
306
|
-
function
|
|
327
|
+
function N(e) {
|
|
307
328
|
let t = e;
|
|
308
329
|
if (!t) return {};
|
|
309
330
|
if (typeof t == "string") return { error: () => t };
|
|
@@ -329,7 +350,7 @@ var He = {
|
|
|
329
350
|
function Ue(e, t) {
|
|
330
351
|
let n = e._zod.def, r = n.checks;
|
|
331
352
|
if (r && r.length > 0) throw Error(".pick() cannot be used on object schemas containing refinements");
|
|
332
|
-
return
|
|
353
|
+
return M(e, A(e._zod.def, {
|
|
333
354
|
get shape() {
|
|
334
355
|
let e = {};
|
|
335
356
|
for (let r in t) {
|
|
@@ -344,7 +365,7 @@ function Ue(e, t) {
|
|
|
344
365
|
function We(e, t) {
|
|
345
366
|
let n = e._zod.def, r = n.checks;
|
|
346
367
|
if (r && r.length > 0) throw Error(".omit() cannot be used on object schemas containing refinements");
|
|
347
|
-
return
|
|
368
|
+
return M(e, A(e._zod.def, {
|
|
348
369
|
get shape() {
|
|
349
370
|
let r = { ...e._zod.def.shape };
|
|
350
371
|
for (let e in t) {
|
|
@@ -357,13 +378,13 @@ function We(e, t) {
|
|
|
357
378
|
}));
|
|
358
379
|
}
|
|
359
380
|
function Ge(e, t) {
|
|
360
|
-
if (!
|
|
381
|
+
if (!Re(t)) throw Error("Invalid input to extend: expected a plain object");
|
|
361
382
|
let n = e._zod.def.checks;
|
|
362
383
|
if (n && n.length > 0) {
|
|
363
384
|
let n = e._zod.def.shape;
|
|
364
385
|
for (let e in t) if (Object.getOwnPropertyDescriptor(n, e) !== void 0) throw Error("Cannot overwrite keys on object schemas containing refinements. Use `.safeExtend()` instead.");
|
|
365
386
|
}
|
|
366
|
-
return
|
|
387
|
+
return M(e, A(e._zod.def, { get shape() {
|
|
367
388
|
let n = {
|
|
368
389
|
...e._zod.def.shape,
|
|
369
390
|
...t
|
|
@@ -372,8 +393,8 @@ function Ge(e, t) {
|
|
|
372
393
|
} }));
|
|
373
394
|
}
|
|
374
395
|
function Ke(e, t) {
|
|
375
|
-
if (!
|
|
376
|
-
return
|
|
396
|
+
if (!Re(t)) throw Error("Invalid input to safeExtend: expected a plain object");
|
|
397
|
+
return M(e, A(e._zod.def, { get shape() {
|
|
377
398
|
let n = {
|
|
378
399
|
...e._zod.def.shape,
|
|
379
400
|
...t
|
|
@@ -383,7 +404,7 @@ function Ke(e, t) {
|
|
|
383
404
|
}
|
|
384
405
|
function qe(e, t) {
|
|
385
406
|
if (e._zod.def.checks?.length) throw Error(".merge() cannot be used on object schemas containing refinements. Use .safeExtend() instead.");
|
|
386
|
-
return
|
|
407
|
+
return M(e, A(e._zod.def, {
|
|
387
408
|
get shape() {
|
|
388
409
|
let n = {
|
|
389
410
|
...e._zod.def.shape,
|
|
@@ -400,7 +421,7 @@ function qe(e, t) {
|
|
|
400
421
|
function Je(e, t, n) {
|
|
401
422
|
let r = t._zod.def.checks;
|
|
402
423
|
if (r && r.length > 0) throw Error(".partial() cannot be used on object schemas containing refinements");
|
|
403
|
-
return
|
|
424
|
+
return M(t, A(t._zod.def, {
|
|
404
425
|
get shape() {
|
|
405
426
|
let r = t._zod.def.shape, i = { ...r };
|
|
406
427
|
if (n) for (let t in n) {
|
|
@@ -420,7 +441,7 @@ function Je(e, t, n) {
|
|
|
420
441
|
}));
|
|
421
442
|
}
|
|
422
443
|
function Ye(e, t, n) {
|
|
423
|
-
return
|
|
444
|
+
return M(t, A(t._zod.def, { get shape() {
|
|
424
445
|
let r = t._zod.def.shape, i = { ...r };
|
|
425
446
|
if (n) for (let t in n) {
|
|
426
447
|
if (!(t in i)) throw Error(`Unrecognized key: "${t}"`);
|
|
@@ -436,33 +457,33 @@ function Ye(e, t, n) {
|
|
|
436
457
|
return k(this, "shape", i), i;
|
|
437
458
|
} }));
|
|
438
459
|
}
|
|
439
|
-
function
|
|
460
|
+
function Xe(e, t = 0) {
|
|
440
461
|
if (e.aborted === !0) return !0;
|
|
441
462
|
for (let n = t; n < e.issues.length; n++) if (e.issues[n]?.continue !== !0) return !0;
|
|
442
463
|
return !1;
|
|
443
464
|
}
|
|
444
|
-
function
|
|
465
|
+
function Ze(e, t = 0) {
|
|
445
466
|
if (e.aborted === !0) return !0;
|
|
446
467
|
for (let n = t; n < e.issues.length; n++) if (e.issues[n]?.continue === !1) return !0;
|
|
447
468
|
return !1;
|
|
448
469
|
}
|
|
449
|
-
function
|
|
470
|
+
function Qe(e, t) {
|
|
450
471
|
return t.map((t) => {
|
|
451
472
|
var n;
|
|
452
473
|
return (n = t).path ?? (n.path = []), t.path.unshift(e), t;
|
|
453
474
|
});
|
|
454
475
|
}
|
|
455
|
-
function
|
|
476
|
+
function $e(e) {
|
|
456
477
|
return typeof e == "string" ? e : e?.message;
|
|
457
478
|
}
|
|
458
|
-
function
|
|
459
|
-
let r = e.message ? e.message :
|
|
479
|
+
function P(e, t, n) {
|
|
480
|
+
let r = e.message ? e.message : $e(e.inst?._zod.def?.error?.(e)) ?? $e(t?.error?.(e)) ?? $e(n.customError?.(e)) ?? $e(n.localeError?.(e)) ?? "Invalid input", { inst: i, continue: a, input: o, ...s } = e;
|
|
460
481
|
return s.path ??= [], s.message = r, t?.reportInput && (s.input = o), s;
|
|
461
482
|
}
|
|
462
|
-
function
|
|
483
|
+
function et(e) {
|
|
463
484
|
return Array.isArray(e) ? "array" : typeof e == "string" ? "string" : "unknown";
|
|
464
485
|
}
|
|
465
|
-
function
|
|
486
|
+
function tt(...e) {
|
|
466
487
|
let [t, n, r] = e;
|
|
467
488
|
return typeof t == "string" ? {
|
|
468
489
|
message: t,
|
|
@@ -473,19 +494,19 @@ function $e(...e) {
|
|
|
473
494
|
}
|
|
474
495
|
//#endregion
|
|
475
496
|
//#region ../../node_modules/zod/v4/core/errors.js
|
|
476
|
-
var
|
|
497
|
+
var nt = (e, t) => {
|
|
477
498
|
e.name = "$ZodError", Object.defineProperty(e, "_zod", {
|
|
478
499
|
value: e._zod,
|
|
479
500
|
enumerable: !1
|
|
480
501
|
}), Object.defineProperty(e, "issues", {
|
|
481
502
|
value: t,
|
|
482
503
|
enumerable: !1
|
|
483
|
-
}), e.message = JSON.stringify(t,
|
|
504
|
+
}), e.message = JSON.stringify(t, De, 2), Object.defineProperty(e, "toString", {
|
|
484
505
|
value: () => e.message,
|
|
485
506
|
enumerable: !1
|
|
486
507
|
});
|
|
487
|
-
},
|
|
488
|
-
function
|
|
508
|
+
}, rt = E("$ZodError", nt), it = E("$ZodError", nt, { Parent: Error });
|
|
509
|
+
function at(e, t = (e) => e.message) {
|
|
489
510
|
let n = {}, r = [];
|
|
490
511
|
for (let i of e.issues) i.path.length > 0 ? (n[i.path[0]] = n[i.path[0]] || [], n[i.path[0]].push(t(i))) : r.push(t(i));
|
|
491
512
|
return {
|
|
@@ -493,7 +514,7 @@ function rt(e, t = (e) => e.message) {
|
|
|
493
514
|
fieldErrors: n
|
|
494
515
|
};
|
|
495
516
|
}
|
|
496
|
-
function
|
|
517
|
+
function ot(e, t = (e) => e.message) {
|
|
497
518
|
let n = { _errors: [] }, r = (e, i = []) => {
|
|
498
519
|
for (let a of e.issues) if (a.code === "invalid_union" && a.errors.length) a.errors.map((e) => r({ issues: e }, [...i, ...a.path]));
|
|
499
520
|
else if (a.code === "invalid_key") r({ issues: a.issues }, [...i, ...a.path]);
|
|
@@ -514,7 +535,7 @@ function it(e, t = (e) => e.message) {
|
|
|
514
535
|
}
|
|
515
536
|
//#endregion
|
|
516
537
|
//#region ../../node_modules/zod/v4/core/parse.js
|
|
517
|
-
var
|
|
538
|
+
var st = (e) => (t, n, r, i) => {
|
|
518
539
|
let a = r ? {
|
|
519
540
|
...r,
|
|
520
541
|
async: !1
|
|
@@ -522,13 +543,13 @@ var at = (e) => (t, n, r, i) => {
|
|
|
522
543
|
value: n,
|
|
523
544
|
issues: []
|
|
524
545
|
}, a);
|
|
525
|
-
if (o instanceof Promise) throw new
|
|
546
|
+
if (o instanceof Promise) throw new Ce();
|
|
526
547
|
if (o.issues.length) {
|
|
527
|
-
let t = new (i?.Err ?? e)(o.issues.map((e) =>
|
|
528
|
-
throw
|
|
548
|
+
let t = new (i?.Err ?? e)(o.issues.map((e) => P(e, a, D())));
|
|
549
|
+
throw Fe(t, i?.callee), t;
|
|
529
550
|
}
|
|
530
551
|
return o.value;
|
|
531
|
-
},
|
|
552
|
+
}, ct = (e) => async (t, n, r, i) => {
|
|
532
553
|
let a = r ? {
|
|
533
554
|
...r,
|
|
534
555
|
async: !0
|
|
@@ -537,11 +558,11 @@ var at = (e) => (t, n, r, i) => {
|
|
|
537
558
|
issues: []
|
|
538
559
|
}, a);
|
|
539
560
|
if (o instanceof Promise && (o = await o), o.issues.length) {
|
|
540
|
-
let t = new (i?.Err ?? e)(o.issues.map((e) =>
|
|
541
|
-
throw
|
|
561
|
+
let t = new (i?.Err ?? e)(o.issues.map((e) => P(e, a, D())));
|
|
562
|
+
throw Fe(t, i?.callee), t;
|
|
542
563
|
}
|
|
543
564
|
return o.value;
|
|
544
|
-
},
|
|
565
|
+
}, lt = (e) => (t, n, r) => {
|
|
545
566
|
let i = r ? {
|
|
546
567
|
...r,
|
|
547
568
|
async: !1
|
|
@@ -549,15 +570,15 @@ var at = (e) => (t, n, r, i) => {
|
|
|
549
570
|
value: n,
|
|
550
571
|
issues: []
|
|
551
572
|
}, i);
|
|
552
|
-
if (a instanceof Promise) throw new
|
|
573
|
+
if (a instanceof Promise) throw new Ce();
|
|
553
574
|
return a.issues.length ? {
|
|
554
575
|
success: !1,
|
|
555
|
-
error: new (e ??
|
|
576
|
+
error: new (e ?? rt)(a.issues.map((e) => P(e, i, D())))
|
|
556
577
|
} : {
|
|
557
578
|
success: !0,
|
|
558
579
|
data: a.value
|
|
559
580
|
};
|
|
560
|
-
},
|
|
581
|
+
}, ut = /* @__PURE__*/ lt(it), dt = (e) => async (t, n, r) => {
|
|
561
582
|
let i = r ? {
|
|
562
583
|
...r,
|
|
563
584
|
async: !0
|
|
@@ -567,66 +588,66 @@ var at = (e) => (t, n, r, i) => {
|
|
|
567
588
|
}, i);
|
|
568
589
|
return a instanceof Promise && (a = await a), a.issues.length ? {
|
|
569
590
|
success: !1,
|
|
570
|
-
error: new e(a.issues.map((e) =>
|
|
591
|
+
error: new e(a.issues.map((e) => P(e, i, D())))
|
|
571
592
|
} : {
|
|
572
593
|
success: !0,
|
|
573
594
|
data: a.value
|
|
574
595
|
};
|
|
575
|
-
},
|
|
596
|
+
}, ft = /* @__PURE__*/ dt(it), pt = (e) => (t, n, r) => {
|
|
576
597
|
let i = r ? {
|
|
577
598
|
...r,
|
|
578
599
|
direction: "backward"
|
|
579
600
|
} : { direction: "backward" };
|
|
580
|
-
return
|
|
581
|
-
},
|
|
601
|
+
return st(e)(t, n, i);
|
|
602
|
+
}, mt = (e) => (t, n, r) => st(e)(t, n, r), ht = (e) => async (t, n, r) => {
|
|
582
603
|
let i = r ? {
|
|
583
604
|
...r,
|
|
584
605
|
direction: "backward"
|
|
585
606
|
} : { direction: "backward" };
|
|
586
|
-
return
|
|
587
|
-
},
|
|
607
|
+
return ct(e)(t, n, i);
|
|
608
|
+
}, gt = (e) => async (t, n, r) => ct(e)(t, n, r), _t = (e) => (t, n, r) => {
|
|
588
609
|
let i = r ? {
|
|
589
610
|
...r,
|
|
590
611
|
direction: "backward"
|
|
591
612
|
} : { direction: "backward" };
|
|
592
|
-
return
|
|
593
|
-
},
|
|
613
|
+
return lt(e)(t, n, i);
|
|
614
|
+
}, vt = (e) => (t, n, r) => lt(e)(t, n, r), yt = (e) => async (t, n, r) => {
|
|
594
615
|
let i = r ? {
|
|
595
616
|
...r,
|
|
596
617
|
direction: "backward"
|
|
597
618
|
} : { direction: "backward" };
|
|
598
|
-
return
|
|
599
|
-
},
|
|
600
|
-
function
|
|
601
|
-
return new RegExp(
|
|
619
|
+
return dt(e)(t, n, i);
|
|
620
|
+
}, bt = (e) => async (t, n, r) => dt(e)(t, n, r), xt = /^[cC][0-9a-z]{6,}$/, St = /^[0-9a-z]+$/, Ct = /^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$/, wt = /^[0-9a-vA-V]{20}$/, Tt = /^[A-Za-z0-9]{27}$/, Et = /^[a-zA-Z0-9_-]{21}$/, Dt = /^P(?:(\d+W)|(?!.*W)(?=\d|T\d)(\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+([.,]\d+)?S)?)?)$/, Ot = /^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$/, kt = (e) => e ? RegExp(`^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-${e}[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$`) : /^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$/, At = /^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$/, jt = "^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$";
|
|
621
|
+
function Mt() {
|
|
622
|
+
return new RegExp(jt, "u");
|
|
602
623
|
}
|
|
603
|
-
var
|
|
604
|
-
function
|
|
624
|
+
var Nt = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/, Pt = /^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:))$/, Ft = /^((25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/([0-9]|[1-2][0-9]|3[0-2])$/, It = /^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|::|([0-9a-fA-F]{1,4})?::([0-9a-fA-F]{1,4}:?){0,6})\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/, Lt = /^$|^(?:[0-9a-zA-Z+/]{4})*(?:(?:[0-9a-zA-Z+/]{2}==)|(?:[0-9a-zA-Z+/]{3}=))?$/, Rt = /^[A-Za-z0-9_-]*$/, zt = /^https?$/, Bt = /^\+[1-9]\d{6,14}$/, Vt = "(?:(?:\\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])))", Ht = /*@__PURE__*/ RegExp(`^${Vt}$`);
|
|
625
|
+
function Ut(e) {
|
|
605
626
|
let t = "(?:[01]\\d|2[0-3]):[0-5]\\d";
|
|
606
627
|
return typeof e.precision == "number" ? e.precision === -1 ? `${t}` : e.precision === 0 ? `${t}:[0-5]\\d` : `${t}:[0-5]\\d\\.\\d{${e.precision}}` : `${t}(?::[0-5]\\d(?:\\.\\d+)?)?`;
|
|
607
628
|
}
|
|
608
|
-
function
|
|
609
|
-
return RegExp(`^${
|
|
629
|
+
function Wt(e) {
|
|
630
|
+
return RegExp(`^${Ut(e)}$`);
|
|
610
631
|
}
|
|
611
|
-
function
|
|
612
|
-
let t =
|
|
632
|
+
function Gt(e) {
|
|
633
|
+
let t = Ut({ precision: e.precision }), n = ["Z"];
|
|
613
634
|
e.local && n.push(""), e.offset && n.push("([+-](?:[01]\\d|2[0-3]):[0-5]\\d)");
|
|
614
635
|
let r = `${t}(?:${n.join("|")})`;
|
|
615
|
-
return RegExp(`^${
|
|
636
|
+
return RegExp(`^${Vt}T(?:${r})$`);
|
|
616
637
|
}
|
|
617
|
-
var
|
|
638
|
+
var Kt = (e) => {
|
|
618
639
|
let t = e ? `[\\s\\S]{${e?.minimum ?? 0},${e?.maximum ?? ""}}` : "[\\s\\S]*";
|
|
619
640
|
return RegExp(`^${t}$`);
|
|
620
|
-
},
|
|
641
|
+
}, qt = /^-?\d+$/, Jt = /^-?\d+(?:\.\d+)?$/, Yt = /^(?:true|false)$/i, Xt = /^null$/i, Zt = /^[^A-Z]*$/, Qt = /^[^a-z]*$/, F = /*@__PURE__*/ E("$ZodCheck", (e, t) => {
|
|
621
642
|
var n;
|
|
622
643
|
e._zod ??= {}, e._zod.def = t, (n = e._zod).onattach ?? (n.onattach = []);
|
|
623
|
-
}),
|
|
644
|
+
}), $t = {
|
|
624
645
|
number: "number",
|
|
625
646
|
bigint: "bigint",
|
|
626
647
|
object: "date"
|
|
627
|
-
},
|
|
628
|
-
|
|
629
|
-
let n =
|
|
648
|
+
}, en = /*@__PURE__*/ E("$ZodCheckLessThan", (e, t) => {
|
|
649
|
+
F.init(e, t);
|
|
650
|
+
let n = $t[typeof t.value];
|
|
630
651
|
e._zod.onattach.push((e) => {
|
|
631
652
|
let n = e._zod.bag, r = (t.inclusive ? n.maximum : n.exclusiveMaximum) ?? Infinity;
|
|
632
653
|
t.value < r && (t.inclusive ? n.maximum = t.value : n.exclusiveMaximum = t.value);
|
|
@@ -641,9 +662,9 @@ var Wt = (e) => {
|
|
|
641
662
|
continue: !t.abort
|
|
642
663
|
});
|
|
643
664
|
};
|
|
644
|
-
}),
|
|
645
|
-
|
|
646
|
-
let n =
|
|
665
|
+
}), tn = /*@__PURE__*/ E("$ZodCheckGreaterThan", (e, t) => {
|
|
666
|
+
F.init(e, t);
|
|
667
|
+
let n = $t[typeof t.value];
|
|
647
668
|
e._zod.onattach.push((e) => {
|
|
648
669
|
let n = e._zod.bag, r = (t.inclusive ? n.minimum : n.exclusiveMinimum) ?? -Infinity;
|
|
649
670
|
t.value > r && (t.inclusive ? n.minimum = t.value : n.exclusiveMinimum = t.value);
|
|
@@ -658,13 +679,13 @@ var Wt = (e) => {
|
|
|
658
679
|
continue: !t.abort
|
|
659
680
|
});
|
|
660
681
|
};
|
|
661
|
-
}),
|
|
662
|
-
|
|
682
|
+
}), nn = /*@__PURE__*/ E("$ZodCheckMultipleOf", (e, t) => {
|
|
683
|
+
F.init(e, t), e._zod.onattach.push((e) => {
|
|
663
684
|
var n;
|
|
664
685
|
(n = e._zod.bag).multipleOf ?? (n.multipleOf = t.value);
|
|
665
686
|
}), e._zod.check = (n) => {
|
|
666
687
|
if (typeof n.value != typeof t.value) throw Error("Cannot mix number and bigint in multiple_of check.");
|
|
667
|
-
(typeof n.value == "bigint" ? n.value % t.value === BigInt(0) :
|
|
688
|
+
(typeof n.value == "bigint" ? n.value % t.value === BigInt(0) : je(n.value, t.value) === 0) || n.issues.push({
|
|
668
689
|
origin: typeof n.value,
|
|
669
690
|
code: "not_multiple_of",
|
|
670
691
|
divisor: t.value,
|
|
@@ -673,12 +694,12 @@ var Wt = (e) => {
|
|
|
673
694
|
continue: !t.abort
|
|
674
695
|
});
|
|
675
696
|
};
|
|
676
|
-
}),
|
|
677
|
-
|
|
697
|
+
}), rn = /*@__PURE__*/ E("$ZodCheckNumberFormat", (e, t) => {
|
|
698
|
+
F.init(e, t), t.format = t.format || "float64";
|
|
678
699
|
let n = t.format?.includes("int"), r = n ? "int" : "number", [i, a] = He[t.format];
|
|
679
700
|
e._zod.onattach.push((e) => {
|
|
680
701
|
let r = e._zod.bag;
|
|
681
|
-
r.format = t.format, r.minimum = i, r.maximum = a, n && (r.pattern =
|
|
702
|
+
r.format = t.format, r.minimum = i, r.maximum = a, n && (r.pattern = qt);
|
|
682
703
|
}), e._zod.check = (o) => {
|
|
683
704
|
let s = o.value;
|
|
684
705
|
if (n) {
|
|
@@ -734,18 +755,18 @@ var Wt = (e) => {
|
|
|
734
755
|
continue: !t.abort
|
|
735
756
|
});
|
|
736
757
|
};
|
|
737
|
-
}),
|
|
758
|
+
}), an = /*@__PURE__*/ E("$ZodCheckMaxLength", (e, t) => {
|
|
738
759
|
var n;
|
|
739
|
-
|
|
760
|
+
F.init(e, t), (n = e._zod.def).when ?? (n.when = (e) => {
|
|
740
761
|
let t = e.value;
|
|
741
|
-
return !
|
|
762
|
+
return !ke(t) && t.length !== void 0;
|
|
742
763
|
}), e._zod.onattach.push((e) => {
|
|
743
764
|
let n = e._zod.bag.maximum ?? Infinity;
|
|
744
765
|
t.maximum < n && (e._zod.bag.maximum = t.maximum);
|
|
745
766
|
}), e._zod.check = (n) => {
|
|
746
767
|
let r = n.value;
|
|
747
768
|
if (r.length <= t.maximum) return;
|
|
748
|
-
let i =
|
|
769
|
+
let i = et(r);
|
|
749
770
|
n.issues.push({
|
|
750
771
|
origin: i,
|
|
751
772
|
code: "too_big",
|
|
@@ -756,18 +777,18 @@ var Wt = (e) => {
|
|
|
756
777
|
continue: !t.abort
|
|
757
778
|
});
|
|
758
779
|
};
|
|
759
|
-
}),
|
|
780
|
+
}), on = /*@__PURE__*/ E("$ZodCheckMinLength", (e, t) => {
|
|
760
781
|
var n;
|
|
761
|
-
|
|
782
|
+
F.init(e, t), (n = e._zod.def).when ?? (n.when = (e) => {
|
|
762
783
|
let t = e.value;
|
|
763
|
-
return !
|
|
784
|
+
return !ke(t) && t.length !== void 0;
|
|
764
785
|
}), e._zod.onattach.push((e) => {
|
|
765
786
|
let n = e._zod.bag.minimum ?? -Infinity;
|
|
766
787
|
t.minimum > n && (e._zod.bag.minimum = t.minimum);
|
|
767
788
|
}), e._zod.check = (n) => {
|
|
768
789
|
let r = n.value;
|
|
769
790
|
if (r.length >= t.minimum) return;
|
|
770
|
-
let i =
|
|
791
|
+
let i = et(r);
|
|
771
792
|
n.issues.push({
|
|
772
793
|
origin: i,
|
|
773
794
|
code: "too_small",
|
|
@@ -778,18 +799,18 @@ var Wt = (e) => {
|
|
|
778
799
|
continue: !t.abort
|
|
779
800
|
});
|
|
780
801
|
};
|
|
781
|
-
}),
|
|
802
|
+
}), sn = /*@__PURE__*/ E("$ZodCheckLengthEquals", (e, t) => {
|
|
782
803
|
var n;
|
|
783
|
-
|
|
804
|
+
F.init(e, t), (n = e._zod.def).when ?? (n.when = (e) => {
|
|
784
805
|
let t = e.value;
|
|
785
|
-
return !
|
|
806
|
+
return !ke(t) && t.length !== void 0;
|
|
786
807
|
}), e._zod.onattach.push((e) => {
|
|
787
808
|
let n = e._zod.bag;
|
|
788
809
|
n.minimum = t.length, n.maximum = t.length, n.length = t.length;
|
|
789
810
|
}), e._zod.check = (n) => {
|
|
790
811
|
let r = n.value, i = r.length;
|
|
791
812
|
if (i === t.length) return;
|
|
792
|
-
let a =
|
|
813
|
+
let a = et(r), o = i > t.length;
|
|
793
814
|
n.issues.push({
|
|
794
815
|
origin: a,
|
|
795
816
|
...o ? {
|
|
@@ -806,9 +827,9 @@ var Wt = (e) => {
|
|
|
806
827
|
continue: !t.abort
|
|
807
828
|
});
|
|
808
829
|
};
|
|
809
|
-
}),
|
|
830
|
+
}), cn = /*@__PURE__*/ E("$ZodCheckStringFormat", (e, t) => {
|
|
810
831
|
var n, r;
|
|
811
|
-
|
|
832
|
+
F.init(e, t), e._zod.onattach.push((e) => {
|
|
812
833
|
let n = e._zod.bag;
|
|
813
834
|
n.format = t.format, t.pattern && (n.patterns ??= /* @__PURE__ */ new Set(), n.patterns.add(t.pattern));
|
|
814
835
|
}), t.pattern ? (n = e._zod).check ?? (n.check = (n) => {
|
|
@@ -822,8 +843,8 @@ var Wt = (e) => {
|
|
|
822
843
|
continue: !t.abort
|
|
823
844
|
});
|
|
824
845
|
}) : (r = e._zod).check ?? (r.check = () => {});
|
|
825
|
-
}),
|
|
826
|
-
|
|
846
|
+
}), ln = /*@__PURE__*/ E("$ZodCheckRegex", (e, t) => {
|
|
847
|
+
cn.init(e, t), e._zod.check = (n) => {
|
|
827
848
|
t.pattern.lastIndex = 0, !t.pattern.test(n.value) && n.issues.push({
|
|
828
849
|
origin: "string",
|
|
829
850
|
code: "invalid_format",
|
|
@@ -834,13 +855,13 @@ var Wt = (e) => {
|
|
|
834
855
|
continue: !t.abort
|
|
835
856
|
});
|
|
836
857
|
};
|
|
837
|
-
}),
|
|
838
|
-
t.pattern ??=
|
|
839
|
-
}),
|
|
840
|
-
t.pattern ??=
|
|
841
|
-
}),
|
|
842
|
-
|
|
843
|
-
let n =
|
|
858
|
+
}), un = /*@__PURE__*/ E("$ZodCheckLowerCase", (e, t) => {
|
|
859
|
+
t.pattern ??= Zt, cn.init(e, t);
|
|
860
|
+
}), dn = /*@__PURE__*/ E("$ZodCheckUpperCase", (e, t) => {
|
|
861
|
+
t.pattern ??= Qt, cn.init(e, t);
|
|
862
|
+
}), fn = /*@__PURE__*/ E("$ZodCheckIncludes", (e, t) => {
|
|
863
|
+
F.init(e, t);
|
|
864
|
+
let n = j(t.includes), r = new RegExp(typeof t.position == "number" ? `^.{${t.position}}${n}` : n);
|
|
844
865
|
t.pattern = r, e._zod.onattach.push((e) => {
|
|
845
866
|
let t = e._zod.bag;
|
|
846
867
|
t.patterns ??= /* @__PURE__ */ new Set(), t.patterns.add(r);
|
|
@@ -855,9 +876,9 @@ var Wt = (e) => {
|
|
|
855
876
|
continue: !t.abort
|
|
856
877
|
});
|
|
857
878
|
};
|
|
858
|
-
}),
|
|
859
|
-
|
|
860
|
-
let n = RegExp(`^${
|
|
879
|
+
}), pn = /*@__PURE__*/ E("$ZodCheckStartsWith", (e, t) => {
|
|
880
|
+
F.init(e, t);
|
|
881
|
+
let n = RegExp(`^${j(t.prefix)}.*`);
|
|
861
882
|
t.pattern ??= n, e._zod.onattach.push((e) => {
|
|
862
883
|
let t = e._zod.bag;
|
|
863
884
|
t.patterns ??= /* @__PURE__ */ new Set(), t.patterns.add(n);
|
|
@@ -872,9 +893,9 @@ var Wt = (e) => {
|
|
|
872
893
|
continue: !t.abort
|
|
873
894
|
});
|
|
874
895
|
};
|
|
875
|
-
}),
|
|
876
|
-
|
|
877
|
-
let n = RegExp(`.*${
|
|
896
|
+
}), mn = /*@__PURE__*/ E("$ZodCheckEndsWith", (e, t) => {
|
|
897
|
+
F.init(e, t);
|
|
898
|
+
let n = RegExp(`.*${j(t.suffix)}$`);
|
|
878
899
|
t.pattern ??= n, e._zod.onattach.push((e) => {
|
|
879
900
|
let t = e._zod.bag;
|
|
880
901
|
t.patterns ??= /* @__PURE__ */ new Set(), t.patterns.add(n);
|
|
@@ -889,11 +910,11 @@ var Wt = (e) => {
|
|
|
889
910
|
continue: !t.abort
|
|
890
911
|
});
|
|
891
912
|
};
|
|
892
|
-
}),
|
|
893
|
-
|
|
913
|
+
}), hn = /*@__PURE__*/ E("$ZodCheckOverwrite", (e, t) => {
|
|
914
|
+
F.init(e, t), e._zod.check = (e) => {
|
|
894
915
|
e.value = t.tx(e.value);
|
|
895
916
|
};
|
|
896
|
-
}),
|
|
917
|
+
}), gn = class {
|
|
897
918
|
constructor(e = []) {
|
|
898
919
|
this.content = [], this.indent = 0, this && (this.args = e);
|
|
899
920
|
}
|
|
@@ -912,13 +933,13 @@ var Wt = (e) => {
|
|
|
912
933
|
let e = Function, t = this?.args, n = [...(this?.content ?? [""]).map((e) => ` ${e}`)];
|
|
913
934
|
return new e(...t, n.join("\n"));
|
|
914
935
|
}
|
|
915
|
-
},
|
|
936
|
+
}, _n = {
|
|
916
937
|
major: 4,
|
|
917
938
|
minor: 4,
|
|
918
939
|
patch: 3
|
|
919
|
-
},
|
|
940
|
+
}, I = /*@__PURE__*/ E("$ZodType", (e, t) => {
|
|
920
941
|
var n;
|
|
921
|
-
e ??= {}, e._zod.def = t, e._zod.bag = e._zod.bag || {}, e._zod.version =
|
|
942
|
+
e ??= {}, e._zod.def = t, e._zod.bag = e._zod.bag || {}, e._zod.version = _n;
|
|
922
943
|
let r = [...e._zod.def.checks ?? []];
|
|
923
944
|
e._zod.traits.has("$ZodCheck") && r.unshift(e);
|
|
924
945
|
for (let t of r) for (let n of t._zod.onattach) n(e);
|
|
@@ -927,27 +948,27 @@ var Wt = (e) => {
|
|
|
927
948
|
});
|
|
928
949
|
else {
|
|
929
950
|
let t = (e, t, n) => {
|
|
930
|
-
let r =
|
|
951
|
+
let r = Xe(e), i;
|
|
931
952
|
for (let a of t) {
|
|
932
953
|
if (a._zod.def.when) {
|
|
933
|
-
if (
|
|
954
|
+
if (Ze(e) || !a._zod.def.when(e)) continue;
|
|
934
955
|
} else if (r) continue;
|
|
935
956
|
let t = e.issues.length, o = a._zod.check(e);
|
|
936
|
-
if (o instanceof Promise && n?.async === !1) throw new
|
|
957
|
+
if (o instanceof Promise && n?.async === !1) throw new Ce();
|
|
937
958
|
if (i || o instanceof Promise) i = (i ?? Promise.resolve()).then(async () => {
|
|
938
|
-
await o, e.issues.length !== t && (r ||=
|
|
959
|
+
await o, e.issues.length !== t && (r ||= Xe(e, t));
|
|
939
960
|
});
|
|
940
961
|
else {
|
|
941
962
|
if (e.issues.length === t) continue;
|
|
942
|
-
r ||=
|
|
963
|
+
r ||= Xe(e, t);
|
|
943
964
|
}
|
|
944
965
|
}
|
|
945
966
|
return i ? i.then(() => e) : e;
|
|
946
967
|
}, n = (n, i, a) => {
|
|
947
|
-
if (
|
|
968
|
+
if (Xe(n)) return n.aborted = !0, n;
|
|
948
969
|
let o = t(i, r, a);
|
|
949
970
|
if (o instanceof Promise) {
|
|
950
|
-
if (a.async === !1) throw new
|
|
971
|
+
if (a.async === !1) throw new Ce();
|
|
951
972
|
return o.then((t) => e._zod.parse(t, a));
|
|
952
973
|
}
|
|
953
974
|
return e._zod.parse(o, a);
|
|
@@ -966,7 +987,7 @@ var Wt = (e) => {
|
|
|
966
987
|
}
|
|
967
988
|
let o = e._zod.parse(i, a);
|
|
968
989
|
if (o instanceof Promise) {
|
|
969
|
-
if (a.async === !1) throw new
|
|
990
|
+
if (a.async === !1) throw new Ce();
|
|
970
991
|
return o.then((e) => t(e, r, a));
|
|
971
992
|
}
|
|
972
993
|
return t(o, r, a);
|
|
@@ -975,17 +996,17 @@ var Wt = (e) => {
|
|
|
975
996
|
O(e, "~standard", () => ({
|
|
976
997
|
validate: (t) => {
|
|
977
998
|
try {
|
|
978
|
-
let n =
|
|
999
|
+
let n = ut(e, t);
|
|
979
1000
|
return n.success ? { value: n.data } : { issues: n.error?.issues };
|
|
980
1001
|
} catch {
|
|
981
|
-
return
|
|
1002
|
+
return ft(e, t).then((e) => e.success ? { value: e.data } : { issues: e.error?.issues });
|
|
982
1003
|
}
|
|
983
1004
|
},
|
|
984
1005
|
vendor: "zod",
|
|
985
1006
|
version: 1
|
|
986
1007
|
}));
|
|
987
|
-
}),
|
|
988
|
-
|
|
1008
|
+
}), vn = /*@__PURE__*/ E("$ZodString", (e, t) => {
|
|
1009
|
+
I.init(e, t), e._zod.pattern = [...e?._zod.bag?.patterns ?? []].pop() ?? Kt(e._zod.bag), e._zod.parse = (n, r) => {
|
|
989
1010
|
if (t.coerce) try {
|
|
990
1011
|
n.value = String(n.value);
|
|
991
1012
|
} catch {}
|
|
@@ -996,11 +1017,11 @@ var Wt = (e) => {
|
|
|
996
1017
|
inst: e
|
|
997
1018
|
}), n;
|
|
998
1019
|
};
|
|
999
|
-
}),
|
|
1000
|
-
|
|
1001
|
-
}),
|
|
1002
|
-
t.pattern ??=
|
|
1003
|
-
}),
|
|
1020
|
+
}), L = /*@__PURE__*/ E("$ZodStringFormat", (e, t) => {
|
|
1021
|
+
cn.init(e, t), vn.init(e, t);
|
|
1022
|
+
}), yn = /*@__PURE__*/ E("$ZodGUID", (e, t) => {
|
|
1023
|
+
t.pattern ??= Ot, L.init(e, t);
|
|
1024
|
+
}), bn = /*@__PURE__*/ E("$ZodUUID", (e, t) => {
|
|
1004
1025
|
if (t.version) {
|
|
1005
1026
|
let e = {
|
|
1006
1027
|
v1: 1,
|
|
@@ -1013,16 +1034,16 @@ var Wt = (e) => {
|
|
|
1013
1034
|
v8: 8
|
|
1014
1035
|
}[t.version];
|
|
1015
1036
|
if (e === void 0) throw Error(`Invalid UUID version: "${t.version}"`);
|
|
1016
|
-
t.pattern ??=
|
|
1017
|
-
} else t.pattern ??=
|
|
1018
|
-
|
|
1019
|
-
}),
|
|
1020
|
-
t.pattern ??=
|
|
1021
|
-
}),
|
|
1022
|
-
|
|
1037
|
+
t.pattern ??= kt(e);
|
|
1038
|
+
} else t.pattern ??= kt();
|
|
1039
|
+
L.init(e, t);
|
|
1040
|
+
}), xn = /*@__PURE__*/ E("$ZodEmail", (e, t) => {
|
|
1041
|
+
t.pattern ??= At, L.init(e, t);
|
|
1042
|
+
}), Sn = /*@__PURE__*/ E("$ZodURL", (e, t) => {
|
|
1043
|
+
L.init(e, t), e._zod.check = (n) => {
|
|
1023
1044
|
try {
|
|
1024
1045
|
let r = n.value.trim();
|
|
1025
|
-
if (!t.normalize && t.protocol?.source ===
|
|
1046
|
+
if (!t.normalize && t.protocol?.source === zt.source && !/^https?:\/\//i.test(r)) {
|
|
1026
1047
|
n.issues.push({
|
|
1027
1048
|
code: "invalid_format",
|
|
1028
1049
|
format: "url",
|
|
@@ -1062,32 +1083,32 @@ var Wt = (e) => {
|
|
|
1062
1083
|
});
|
|
1063
1084
|
}
|
|
1064
1085
|
};
|
|
1065
|
-
}),
|
|
1066
|
-
t.pattern ??=
|
|
1067
|
-
}),
|
|
1068
|
-
t.pattern ??=
|
|
1069
|
-
}),
|
|
1070
|
-
t.pattern ??=
|
|
1071
|
-
}),
|
|
1072
|
-
t.pattern ??=
|
|
1073
|
-
}),
|
|
1074
|
-
t.pattern ??=
|
|
1075
|
-
}),
|
|
1076
|
-
t.pattern ??=
|
|
1077
|
-
}),
|
|
1078
|
-
t.pattern ??=
|
|
1079
|
-
}),
|
|
1080
|
-
t.pattern ??=
|
|
1081
|
-
}),
|
|
1082
|
-
t.pattern ??=
|
|
1083
|
-
}),
|
|
1084
|
-
t.pattern ??=
|
|
1085
|
-
}),
|
|
1086
|
-
t.pattern ??=
|
|
1087
|
-
}),
|
|
1088
|
-
t.pattern ??=
|
|
1089
|
-
}),
|
|
1090
|
-
t.pattern ??=
|
|
1086
|
+
}), Cn = /*@__PURE__*/ E("$ZodEmoji", (e, t) => {
|
|
1087
|
+
t.pattern ??= Mt(), L.init(e, t);
|
|
1088
|
+
}), wn = /*@__PURE__*/ E("$ZodNanoID", (e, t) => {
|
|
1089
|
+
t.pattern ??= Et, L.init(e, t);
|
|
1090
|
+
}), Tn = /*@__PURE__*/ E("$ZodCUID", (e, t) => {
|
|
1091
|
+
t.pattern ??= xt, L.init(e, t);
|
|
1092
|
+
}), En = /*@__PURE__*/ E("$ZodCUID2", (e, t) => {
|
|
1093
|
+
t.pattern ??= St, L.init(e, t);
|
|
1094
|
+
}), Dn = /*@__PURE__*/ E("$ZodULID", (e, t) => {
|
|
1095
|
+
t.pattern ??= Ct, L.init(e, t);
|
|
1096
|
+
}), On = /*@__PURE__*/ E("$ZodXID", (e, t) => {
|
|
1097
|
+
t.pattern ??= wt, L.init(e, t);
|
|
1098
|
+
}), kn = /*@__PURE__*/ E("$ZodKSUID", (e, t) => {
|
|
1099
|
+
t.pattern ??= Tt, L.init(e, t);
|
|
1100
|
+
}), An = /*@__PURE__*/ E("$ZodISODateTime", (e, t) => {
|
|
1101
|
+
t.pattern ??= Gt(t), L.init(e, t);
|
|
1102
|
+
}), jn = /*@__PURE__*/ E("$ZodISODate", (e, t) => {
|
|
1103
|
+
t.pattern ??= Ht, L.init(e, t);
|
|
1104
|
+
}), Mn = /*@__PURE__*/ E("$ZodISOTime", (e, t) => {
|
|
1105
|
+
t.pattern ??= Wt(t), L.init(e, t);
|
|
1106
|
+
}), Nn = /*@__PURE__*/ E("$ZodISODuration", (e, t) => {
|
|
1107
|
+
t.pattern ??= Dt, L.init(e, t);
|
|
1108
|
+
}), Pn = /*@__PURE__*/ E("$ZodIPv4", (e, t) => {
|
|
1109
|
+
t.pattern ??= Nt, L.init(e, t), e._zod.bag.format = "ipv4";
|
|
1110
|
+
}), Fn = /*@__PURE__*/ E("$ZodIPv6", (e, t) => {
|
|
1111
|
+
t.pattern ??= Pt, L.init(e, t), e._zod.bag.format = "ipv6", e._zod.check = (n) => {
|
|
1091
1112
|
try {
|
|
1092
1113
|
new URL(`http://[${n.value}]`);
|
|
1093
1114
|
} catch {
|
|
@@ -1100,10 +1121,10 @@ var Wt = (e) => {
|
|
|
1100
1121
|
});
|
|
1101
1122
|
}
|
|
1102
1123
|
};
|
|
1103
|
-
}),
|
|
1104
|
-
t.pattern ??=
|
|
1105
|
-
}),
|
|
1106
|
-
t.pattern ??=
|
|
1124
|
+
}), In = /*@__PURE__*/ E("$ZodCIDRv4", (e, t) => {
|
|
1125
|
+
t.pattern ??= Ft, L.init(e, t);
|
|
1126
|
+
}), Ln = /*@__PURE__*/ E("$ZodCIDRv6", (e, t) => {
|
|
1127
|
+
t.pattern ??= It, L.init(e, t), e._zod.check = (n) => {
|
|
1107
1128
|
let r = n.value.split("/");
|
|
1108
1129
|
try {
|
|
1109
1130
|
if (r.length !== 2) throw Error();
|
|
@@ -1123,7 +1144,7 @@ var Wt = (e) => {
|
|
|
1123
1144
|
}
|
|
1124
1145
|
};
|
|
1125
1146
|
});
|
|
1126
|
-
function
|
|
1147
|
+
function Rn(e) {
|
|
1127
1148
|
if (e === "") return !0;
|
|
1128
1149
|
if (/\s/.test(e) || e.length % 4 != 0) return !1;
|
|
1129
1150
|
try {
|
|
@@ -1132,9 +1153,9 @@ function In(e) {
|
|
|
1132
1153
|
return !1;
|
|
1133
1154
|
}
|
|
1134
1155
|
}
|
|
1135
|
-
var
|
|
1136
|
-
t.pattern ??=
|
|
1137
|
-
|
|
1156
|
+
var zn = /*@__PURE__*/ E("$ZodBase64", (e, t) => {
|
|
1157
|
+
t.pattern ??= Lt, L.init(e, t), e._zod.bag.contentEncoding = "base64", e._zod.check = (n) => {
|
|
1158
|
+
Rn(n.value) || n.issues.push({
|
|
1138
1159
|
code: "invalid_format",
|
|
1139
1160
|
format: "base64",
|
|
1140
1161
|
input: n.value,
|
|
@@ -1143,14 +1164,14 @@ var Ln = /*@__PURE__*/ E("$ZodBase64", (e, t) => {
|
|
|
1143
1164
|
});
|
|
1144
1165
|
};
|
|
1145
1166
|
});
|
|
1146
|
-
function
|
|
1147
|
-
if (!
|
|
1167
|
+
function Bn(e) {
|
|
1168
|
+
if (!Rt.test(e)) return !1;
|
|
1148
1169
|
let t = e.replace(/[-_]/g, (e) => e === "-" ? "+" : "/");
|
|
1149
|
-
return
|
|
1170
|
+
return Rn(t.padEnd(Math.ceil(t.length / 4) * 4, "="));
|
|
1150
1171
|
}
|
|
1151
|
-
var
|
|
1152
|
-
t.pattern ??=
|
|
1153
|
-
|
|
1172
|
+
var Vn = /*@__PURE__*/ E("$ZodBase64URL", (e, t) => {
|
|
1173
|
+
t.pattern ??= Rt, L.init(e, t), e._zod.bag.contentEncoding = "base64url", e._zod.check = (n) => {
|
|
1174
|
+
Bn(n.value) || n.issues.push({
|
|
1154
1175
|
code: "invalid_format",
|
|
1155
1176
|
format: "base64url",
|
|
1156
1177
|
input: n.value,
|
|
@@ -1158,10 +1179,10 @@ var zn = /*@__PURE__*/ E("$ZodBase64URL", (e, t) => {
|
|
|
1158
1179
|
continue: !t.abort
|
|
1159
1180
|
});
|
|
1160
1181
|
};
|
|
1161
|
-
}),
|
|
1162
|
-
t.pattern ??=
|
|
1182
|
+
}), Hn = /*@__PURE__*/ E("$ZodE164", (e, t) => {
|
|
1183
|
+
t.pattern ??= Bt, L.init(e, t);
|
|
1163
1184
|
});
|
|
1164
|
-
function
|
|
1185
|
+
function Un(e, t = null) {
|
|
1165
1186
|
try {
|
|
1166
1187
|
let n = e.split(".");
|
|
1167
1188
|
if (n.length !== 3) return !1;
|
|
@@ -1173,9 +1194,9 @@ function Vn(e, t = null) {
|
|
|
1173
1194
|
return !1;
|
|
1174
1195
|
}
|
|
1175
1196
|
}
|
|
1176
|
-
var
|
|
1177
|
-
|
|
1178
|
-
|
|
1197
|
+
var Wn = /*@__PURE__*/ E("$ZodJWT", (e, t) => {
|
|
1198
|
+
L.init(e, t), e._zod.check = (n) => {
|
|
1199
|
+
Un(n.value, t.alg) || n.issues.push({
|
|
1179
1200
|
code: "invalid_format",
|
|
1180
1201
|
format: "jwt",
|
|
1181
1202
|
input: n.value,
|
|
@@ -1183,8 +1204,8 @@ var Hn = /*@__PURE__*/ E("$ZodJWT", (e, t) => {
|
|
|
1183
1204
|
continue: !t.abort
|
|
1184
1205
|
});
|
|
1185
1206
|
};
|
|
1186
|
-
}),
|
|
1187
|
-
|
|
1207
|
+
}), Gn = /*@__PURE__*/ E("$ZodNumber", (e, t) => {
|
|
1208
|
+
I.init(e, t), e._zod.pattern = e._zod.bag.pattern ?? Jt, e._zod.parse = (n, r) => {
|
|
1188
1209
|
if (t.coerce) try {
|
|
1189
1210
|
n.value = Number(n.value);
|
|
1190
1211
|
} catch {}
|
|
@@ -1199,10 +1220,10 @@ var Hn = /*@__PURE__*/ E("$ZodJWT", (e, t) => {
|
|
|
1199
1220
|
...a ? { received: a } : {}
|
|
1200
1221
|
}), n;
|
|
1201
1222
|
};
|
|
1202
|
-
}),
|
|
1203
|
-
|
|
1204
|
-
}),
|
|
1205
|
-
|
|
1223
|
+
}), Kn = /*@__PURE__*/ E("$ZodNumberFormat", (e, t) => {
|
|
1224
|
+
rn.init(e, t), Gn.init(e, t);
|
|
1225
|
+
}), qn = /*@__PURE__*/ E("$ZodBoolean", (e, t) => {
|
|
1226
|
+
I.init(e, t), e._zod.pattern = Yt, e._zod.parse = (n, r) => {
|
|
1206
1227
|
if (t.coerce) try {
|
|
1207
1228
|
n.value = !!n.value;
|
|
1208
1229
|
} catch {}
|
|
@@ -1214,8 +1235,8 @@ var Hn = /*@__PURE__*/ E("$ZodJWT", (e, t) => {
|
|
|
1214
1235
|
inst: e
|
|
1215
1236
|
}), n;
|
|
1216
1237
|
};
|
|
1217
|
-
}),
|
|
1218
|
-
|
|
1238
|
+
}), Jn = /*@__PURE__*/ E("$ZodNull", (e, t) => {
|
|
1239
|
+
I.init(e, t), e._zod.pattern = Xt, e._zod.values = new Set([null]), e._zod.parse = (t, n) => {
|
|
1219
1240
|
let r = t.value;
|
|
1220
1241
|
return r === null || t.issues.push({
|
|
1221
1242
|
expected: "null",
|
|
@@ -1224,21 +1245,21 @@ var Hn = /*@__PURE__*/ E("$ZodJWT", (e, t) => {
|
|
|
1224
1245
|
inst: e
|
|
1225
1246
|
}), t;
|
|
1226
1247
|
};
|
|
1227
|
-
}),
|
|
1228
|
-
|
|
1229
|
-
}),
|
|
1230
|
-
|
|
1248
|
+
}), Yn = /*@__PURE__*/ E("$ZodUnknown", (e, t) => {
|
|
1249
|
+
I.init(e, t), e._zod.parse = (e) => e;
|
|
1250
|
+
}), Xn = /*@__PURE__*/ E("$ZodNever", (e, t) => {
|
|
1251
|
+
I.init(e, t), e._zod.parse = (t, n) => (t.issues.push({
|
|
1231
1252
|
expected: "never",
|
|
1232
1253
|
code: "invalid_type",
|
|
1233
1254
|
input: t.value,
|
|
1234
1255
|
inst: e
|
|
1235
1256
|
}), t);
|
|
1236
1257
|
});
|
|
1237
|
-
function
|
|
1238
|
-
e.issues.length && t.issues.push(...
|
|
1258
|
+
function Zn(e, t, n) {
|
|
1259
|
+
e.issues.length && t.issues.push(...Qe(n, e.issues)), t.value[n] = e.value;
|
|
1239
1260
|
}
|
|
1240
|
-
var
|
|
1241
|
-
|
|
1261
|
+
var Qn = /*@__PURE__*/ E("$ZodArray", (e, t) => {
|
|
1262
|
+
I.init(e, t), e._zod.parse = (n, r) => {
|
|
1242
1263
|
let i = n.value;
|
|
1243
1264
|
if (!Array.isArray(i)) return n.issues.push({
|
|
1244
1265
|
expected: "array",
|
|
@@ -1253,16 +1274,16 @@ var Xn = /*@__PURE__*/ E("$ZodArray", (e, t) => {
|
|
|
1253
1274
|
value: o,
|
|
1254
1275
|
issues: []
|
|
1255
1276
|
}, r);
|
|
1256
|
-
s instanceof Promise ? a.push(s.then((t) =>
|
|
1277
|
+
s instanceof Promise ? a.push(s.then((t) => Zn(t, n, e))) : Zn(s, n, e);
|
|
1257
1278
|
}
|
|
1258
1279
|
return a.length ? Promise.all(a).then(() => n) : n;
|
|
1259
1280
|
};
|
|
1260
1281
|
});
|
|
1261
|
-
function
|
|
1282
|
+
function $n(e, t, n, r, i, a) {
|
|
1262
1283
|
let o = n in r;
|
|
1263
1284
|
if (e.issues.length) {
|
|
1264
1285
|
if (i && a && !o) return;
|
|
1265
|
-
t.issues.push(...
|
|
1286
|
+
t.issues.push(...Qe(n, e.issues));
|
|
1266
1287
|
}
|
|
1267
1288
|
if (!o && !i) {
|
|
1268
1289
|
e.issues.length || t.issues.push({
|
|
@@ -1275,7 +1296,7 @@ function Zn(e, t, n, r, i, a) {
|
|
|
1275
1296
|
}
|
|
1276
1297
|
e.value === void 0 ? o && (t.value[n] = void 0) : t.value[n] = e.value;
|
|
1277
1298
|
}
|
|
1278
|
-
function
|
|
1299
|
+
function er(e) {
|
|
1279
1300
|
let t = Object.keys(e.shape);
|
|
1280
1301
|
for (let n of t) if (!e.shape?.[n]?._zod?.traits?.has("$ZodType")) throw Error(`Invalid element at key "${n}": expected a Zod schema`);
|
|
1281
1302
|
let n = Ve(e.shape);
|
|
@@ -1287,7 +1308,7 @@ function Qn(e) {
|
|
|
1287
1308
|
optionalKeys: new Set(n)
|
|
1288
1309
|
};
|
|
1289
1310
|
}
|
|
1290
|
-
function
|
|
1311
|
+
function tr(e, t, n, r, i, a) {
|
|
1291
1312
|
let o = [], s = i.keySet, c = i.catchall._zod, l = c.def.type, u = c.optin === "optional", d = c.optout === "optional";
|
|
1292
1313
|
for (let i in t) {
|
|
1293
1314
|
if (i === "__proto__" || s.has(i)) continue;
|
|
@@ -1299,7 +1320,7 @@ function $n(e, t, n, r, i, a) {
|
|
|
1299
1320
|
value: t[i],
|
|
1300
1321
|
issues: []
|
|
1301
1322
|
}, r);
|
|
1302
|
-
a instanceof Promise ? e.push(a.then((e) =>
|
|
1323
|
+
a instanceof Promise ? e.push(a.then((e) => $n(e, n, i, t, u, d))) : $n(a, n, i, t, u, d);
|
|
1303
1324
|
}
|
|
1304
1325
|
return o.length && n.issues.push({
|
|
1305
1326
|
code: "unrecognized_keys",
|
|
@@ -1308,15 +1329,15 @@ function $n(e, t, n, r, i, a) {
|
|
|
1308
1329
|
inst: a
|
|
1309
1330
|
}), e.length ? Promise.all(e).then(() => n) : n;
|
|
1310
1331
|
}
|
|
1311
|
-
var
|
|
1312
|
-
if (
|
|
1332
|
+
var nr = /*@__PURE__*/ E("$ZodObject", (e, t) => {
|
|
1333
|
+
if (I.init(e, t), !Object.getOwnPropertyDescriptor(t, "shape")?.get) {
|
|
1313
1334
|
let e = t.shape;
|
|
1314
1335
|
Object.defineProperty(t, "shape", { get: () => {
|
|
1315
1336
|
let n = { ...e };
|
|
1316
1337
|
return Object.defineProperty(t, "shape", { value: n }), n;
|
|
1317
1338
|
} });
|
|
1318
1339
|
}
|
|
1319
|
-
let n =
|
|
1340
|
+
let n = Oe(() => er(t));
|
|
1320
1341
|
O(e._zod, "propValues", () => {
|
|
1321
1342
|
let e = t.shape, n = {};
|
|
1322
1343
|
for (let t in e) {
|
|
@@ -1328,7 +1349,7 @@ var er = /*@__PURE__*/ E("$ZodObject", (e, t) => {
|
|
|
1328
1349
|
}
|
|
1329
1350
|
return n;
|
|
1330
1351
|
});
|
|
1331
|
-
let r =
|
|
1352
|
+
let r = Ie, i = t.catchall, a;
|
|
1332
1353
|
e._zod.parse = (t, o) => {
|
|
1333
1354
|
a ??= n.value;
|
|
1334
1355
|
let s = t.value;
|
|
@@ -1345,19 +1366,19 @@ var er = /*@__PURE__*/ E("$ZodObject", (e, t) => {
|
|
|
1345
1366
|
value: s[e],
|
|
1346
1367
|
issues: []
|
|
1347
1368
|
}, o);
|
|
1348
|
-
a instanceof Promise ? c.push(a.then((n) =>
|
|
1369
|
+
a instanceof Promise ? c.push(a.then((n) => $n(n, t, e, s, r, i))) : $n(a, t, e, s, r, i);
|
|
1349
1370
|
}
|
|
1350
|
-
return i ?
|
|
1371
|
+
return i ? tr(c, s, t, o, n.value, e) : c.length ? Promise.all(c).then(() => t) : t;
|
|
1351
1372
|
};
|
|
1352
|
-
}),
|
|
1353
|
-
|
|
1354
|
-
let n = e._zod.parse, r =
|
|
1355
|
-
let t = new
|
|
1373
|
+
}), rr = /*@__PURE__*/ E("$ZodObjectJIT", (e, t) => {
|
|
1374
|
+
nr.init(e, t);
|
|
1375
|
+
let n = e._zod.parse, r = Oe(() => er(t)), i = (e) => {
|
|
1376
|
+
let t = new gn([
|
|
1356
1377
|
"shape",
|
|
1357
1378
|
"payload",
|
|
1358
1379
|
"ctx"
|
|
1359
1380
|
]), n = r.value, i = (e) => {
|
|
1360
|
-
let t =
|
|
1381
|
+
let t = Ne(e);
|
|
1361
1382
|
return `shape[${t}]._zod.run({ value: input[${t}], issues: [] }, ctx)`;
|
|
1362
1383
|
};
|
|
1363
1384
|
t.write("const input = payload.value;");
|
|
@@ -1365,7 +1386,7 @@ var er = /*@__PURE__*/ E("$ZodObject", (e, t) => {
|
|
|
1365
1386
|
for (let e of n.keys) a[e] = `key_${o++}`;
|
|
1366
1387
|
t.write("const newResult = {};");
|
|
1367
1388
|
for (let r of n.keys) {
|
|
1368
|
-
let n = a[r], o =
|
|
1389
|
+
let n = a[r], o = Ne(r), s = e[r], c = s?._zod?.optin === "optional", l = s?._zod?.optout === "optional";
|
|
1369
1390
|
t.write(`const ${n} = ${i(r)};`), c && l ? t.write(`
|
|
1370
1391
|
if (${n}.issues.length) {
|
|
1371
1392
|
if (${o} in input) {
|
|
@@ -1430,11 +1451,11 @@ var er = /*@__PURE__*/ E("$ZodObject", (e, t) => {
|
|
|
1430
1451
|
t.write("payload.value = newResult;"), t.write("return payload;");
|
|
1431
1452
|
let s = t.compile();
|
|
1432
1453
|
return (t, n) => s(e, t, n);
|
|
1433
|
-
}, a, o =
|
|
1454
|
+
}, a, o = Ie, s = !Te.jitless, c = s && Le.value, l = t.catchall, u;
|
|
1434
1455
|
e._zod.parse = (d, f) => {
|
|
1435
1456
|
u ??= r.value;
|
|
1436
1457
|
let p = d.value;
|
|
1437
|
-
return o(p) ? s && c && f?.async === !1 && f.jitless !== !0 ? (a ||= i(t.shape), d = a(d, f), l ?
|
|
1458
|
+
return o(p) ? s && c && f?.async === !1 && f.jitless !== !0 ? (a ||= i(t.shape), d = a(d, f), l ? tr([], p, d, f, u, e) : d) : n(d, f) : (d.issues.push({
|
|
1438
1459
|
expected: "object",
|
|
1439
1460
|
code: "invalid_type",
|
|
1440
1461
|
input: p,
|
|
@@ -1442,23 +1463,23 @@ var er = /*@__PURE__*/ E("$ZodObject", (e, t) => {
|
|
|
1442
1463
|
}), d);
|
|
1443
1464
|
};
|
|
1444
1465
|
});
|
|
1445
|
-
function
|
|
1466
|
+
function ir(e, t, n, r) {
|
|
1446
1467
|
for (let n of e) if (n.issues.length === 0) return t.value = n.value, t;
|
|
1447
|
-
let i = e.filter((e) => !
|
|
1468
|
+
let i = e.filter((e) => !Xe(e));
|
|
1448
1469
|
return i.length === 1 ? (t.value = i[0].value, i[0]) : (t.issues.push({
|
|
1449
1470
|
code: "invalid_union",
|
|
1450
1471
|
input: t.value,
|
|
1451
1472
|
inst: n,
|
|
1452
|
-
errors: e.map((e) => e.issues.map((e) =>
|
|
1473
|
+
errors: e.map((e) => e.issues.map((e) => P(e, r, D())))
|
|
1453
1474
|
}), t);
|
|
1454
1475
|
}
|
|
1455
|
-
var
|
|
1456
|
-
|
|
1476
|
+
var ar = /*@__PURE__*/ E("$ZodUnion", (e, t) => {
|
|
1477
|
+
I.init(e, t), O(e._zod, "optin", () => t.options.some((e) => e._zod.optin === "optional") ? "optional" : void 0), O(e._zod, "optout", () => t.options.some((e) => e._zod.optout === "optional") ? "optional" : void 0), O(e._zod, "values", () => {
|
|
1457
1478
|
if (t.options.every((e) => e._zod.values)) return new Set(t.options.flatMap((e) => Array.from(e._zod.values)));
|
|
1458
1479
|
}), O(e._zod, "pattern", () => {
|
|
1459
1480
|
if (t.options.every((e) => e._zod.pattern)) {
|
|
1460
1481
|
let e = t.options.map((e) => e._zod.pattern);
|
|
1461
|
-
return RegExp(`^(${e.map((e) =>
|
|
1482
|
+
return RegExp(`^(${e.map((e) => Ae(e.source)).join("|")})$`);
|
|
1462
1483
|
}
|
|
1463
1484
|
});
|
|
1464
1485
|
let n = t.options.length === 1 ? t.options[0]._zod.run : null;
|
|
@@ -1476,10 +1497,10 @@ var rr = /*@__PURE__*/ E("$ZodUnion", (e, t) => {
|
|
|
1476
1497
|
o.push(t);
|
|
1477
1498
|
}
|
|
1478
1499
|
}
|
|
1479
|
-
return a ? Promise.all(o).then((t) =>
|
|
1500
|
+
return a ? Promise.all(o).then((t) => ir(t, r, e, i)) : ir(o, r, e, i);
|
|
1480
1501
|
};
|
|
1481
|
-
}),
|
|
1482
|
-
|
|
1502
|
+
}), or = /*@__PURE__*/ E("$ZodIntersection", (e, t) => {
|
|
1503
|
+
I.init(e, t), e._zod.parse = (e, n) => {
|
|
1483
1504
|
let r = e.value, i = t.left._zod.run({
|
|
1484
1505
|
value: r,
|
|
1485
1506
|
issues: []
|
|
@@ -1487,21 +1508,21 @@ var rr = /*@__PURE__*/ E("$ZodUnion", (e, t) => {
|
|
|
1487
1508
|
value: r,
|
|
1488
1509
|
issues: []
|
|
1489
1510
|
}, n);
|
|
1490
|
-
return i instanceof Promise || a instanceof Promise ? Promise.all([i, a]).then(([t, n]) =>
|
|
1511
|
+
return i instanceof Promise || a instanceof Promise ? Promise.all([i, a]).then(([t, n]) => cr(e, t, n)) : cr(e, i, a);
|
|
1491
1512
|
};
|
|
1492
1513
|
});
|
|
1493
|
-
function
|
|
1514
|
+
function sr(e, t) {
|
|
1494
1515
|
if (e === t || e instanceof Date && t instanceof Date && +e == +t) return {
|
|
1495
1516
|
valid: !0,
|
|
1496
1517
|
data: e
|
|
1497
1518
|
};
|
|
1498
|
-
if (
|
|
1519
|
+
if (Re(e) && Re(t)) {
|
|
1499
1520
|
let n = Object.keys(t), r = Object.keys(e).filter((e) => n.indexOf(e) !== -1), i = {
|
|
1500
1521
|
...e,
|
|
1501
1522
|
...t
|
|
1502
1523
|
};
|
|
1503
1524
|
for (let n of r) {
|
|
1504
|
-
let r =
|
|
1525
|
+
let r = sr(e[n], t[n]);
|
|
1505
1526
|
if (!r.valid) return {
|
|
1506
1527
|
valid: !1,
|
|
1507
1528
|
mergeErrorPath: [n, ...r.mergeErrorPath]
|
|
@@ -1520,7 +1541,7 @@ function ar(e, t) {
|
|
|
1520
1541
|
};
|
|
1521
1542
|
let n = [];
|
|
1522
1543
|
for (let r = 0; r < e.length; r++) {
|
|
1523
|
-
let i = e[r], a = t[r], o =
|
|
1544
|
+
let i = e[r], a = t[r], o = sr(i, a);
|
|
1524
1545
|
if (!o.valid) return {
|
|
1525
1546
|
valid: !1,
|
|
1526
1547
|
mergeErrorPath: [r, ...o.mergeErrorPath]
|
|
@@ -1537,7 +1558,7 @@ function ar(e, t) {
|
|
|
1537
1558
|
mergeErrorPath: []
|
|
1538
1559
|
};
|
|
1539
1560
|
}
|
|
1540
|
-
function
|
|
1561
|
+
function cr(e, t, n) {
|
|
1541
1562
|
let r = /* @__PURE__ */ new Map(), i;
|
|
1542
1563
|
for (let n of t.issues) if (n.code === "unrecognized_keys") {
|
|
1543
1564
|
i ??= n;
|
|
@@ -1549,15 +1570,15 @@ function or(e, t, n) {
|
|
|
1549
1570
|
if (a.length && i && e.issues.push({
|
|
1550
1571
|
...i,
|
|
1551
1572
|
keys: a
|
|
1552
|
-
}),
|
|
1553
|
-
let o =
|
|
1573
|
+
}), Xe(e)) return e;
|
|
1574
|
+
let o = sr(t.value, n.value);
|
|
1554
1575
|
if (!o.valid) throw Error(`Unmergable intersection. Error path: ${JSON.stringify(o.mergeErrorPath)}`);
|
|
1555
1576
|
return e.value = o.data, e;
|
|
1556
1577
|
}
|
|
1557
|
-
var
|
|
1558
|
-
|
|
1578
|
+
var lr = /*@__PURE__*/ E("$ZodRecord", (e, t) => {
|
|
1579
|
+
I.init(e, t), e._zod.parse = (n, r) => {
|
|
1559
1580
|
let i = n.value;
|
|
1560
|
-
if (!
|
|
1581
|
+
if (!Re(i)) return n.issues.push({
|
|
1561
1582
|
expected: "record",
|
|
1562
1583
|
code: "invalid_type",
|
|
1563
1584
|
input: i,
|
|
@@ -1578,7 +1599,7 @@ var sr = /*@__PURE__*/ E("$ZodRecord", (e, t) => {
|
|
|
1578
1599
|
n.issues.push({
|
|
1579
1600
|
code: "invalid_key",
|
|
1580
1601
|
origin: "record",
|
|
1581
|
-
issues: o.issues.map((e) =>
|
|
1602
|
+
issues: o.issues.map((e) => P(e, r, D())),
|
|
1582
1603
|
input: c,
|
|
1583
1604
|
path: [c],
|
|
1584
1605
|
inst: e
|
|
@@ -1590,8 +1611,8 @@ var sr = /*@__PURE__*/ E("$ZodRecord", (e, t) => {
|
|
|
1590
1611
|
issues: []
|
|
1591
1612
|
}, r);
|
|
1592
1613
|
u instanceof Promise ? a.push(u.then((e) => {
|
|
1593
|
-
e.issues.length && n.issues.push(...
|
|
1594
|
-
})) : (u.issues.length && n.issues.push(...
|
|
1614
|
+
e.issues.length && n.issues.push(...Qe(c, e.issues)), n.value[l] = e.value;
|
|
1615
|
+
})) : (u.issues.length && n.issues.push(...Qe(c, u.issues)), n.value[l] = u.value);
|
|
1595
1616
|
}
|
|
1596
1617
|
let c;
|
|
1597
1618
|
for (let e in i) s.has(e) || (c ??= [], c.push(e));
|
|
@@ -1610,7 +1631,7 @@ var sr = /*@__PURE__*/ E("$ZodRecord", (e, t) => {
|
|
|
1610
1631
|
issues: []
|
|
1611
1632
|
}, r);
|
|
1612
1633
|
if (s instanceof Promise) throw Error("Async schemas not supported in object keys currently");
|
|
1613
|
-
if (typeof o == "string" &&
|
|
1634
|
+
if (typeof o == "string" && Jt.test(o) && s.issues.length) {
|
|
1614
1635
|
let e = t.keyType._zod.run({
|
|
1615
1636
|
value: Number(o),
|
|
1616
1637
|
issues: []
|
|
@@ -1622,7 +1643,7 @@ var sr = /*@__PURE__*/ E("$ZodRecord", (e, t) => {
|
|
|
1622
1643
|
t.mode === "loose" ? n.value[o] = i[o] : n.issues.push({
|
|
1623
1644
|
code: "invalid_key",
|
|
1624
1645
|
origin: "record",
|
|
1625
|
-
issues: s.issues.map((e) =>
|
|
1646
|
+
issues: s.issues.map((e) => P(e, r, D())),
|
|
1626
1647
|
input: o,
|
|
1627
1648
|
path: [o],
|
|
1628
1649
|
inst: e
|
|
@@ -1634,16 +1655,16 @@ var sr = /*@__PURE__*/ E("$ZodRecord", (e, t) => {
|
|
|
1634
1655
|
issues: []
|
|
1635
1656
|
}, r);
|
|
1636
1657
|
c instanceof Promise ? a.push(c.then((e) => {
|
|
1637
|
-
e.issues.length && n.issues.push(...
|
|
1638
|
-
})) : (c.issues.length && n.issues.push(...
|
|
1658
|
+
e.issues.length && n.issues.push(...Qe(o, e.issues)), n.value[s.value] = e.value;
|
|
1659
|
+
})) : (c.issues.length && n.issues.push(...Qe(o, c.issues)), n.value[s.value] = c.value);
|
|
1639
1660
|
}
|
|
1640
1661
|
}
|
|
1641
1662
|
return a.length ? Promise.all(a).then(() => n) : n;
|
|
1642
1663
|
};
|
|
1643
|
-
}),
|
|
1644
|
-
|
|
1645
|
-
let n =
|
|
1646
|
-
e._zod.values = r, e._zod.pattern = RegExp(`^(${n.filter((e) =>
|
|
1664
|
+
}), ur = /*@__PURE__*/ E("$ZodEnum", (e, t) => {
|
|
1665
|
+
I.init(e, t);
|
|
1666
|
+
let n = Ee(t.entries), r = new Set(n);
|
|
1667
|
+
e._zod.values = r, e._zod.pattern = RegExp(`^(${n.filter((e) => Be.has(typeof e)).map((e) => typeof e == "string" ? j(e) : e.toString()).join("|")})$`), e._zod.parse = (t, i) => {
|
|
1647
1668
|
let a = t.value;
|
|
1648
1669
|
return r.has(a) || t.issues.push({
|
|
1649
1670
|
code: "invalid_value",
|
|
@@ -1652,10 +1673,10 @@ var sr = /*@__PURE__*/ E("$ZodRecord", (e, t) => {
|
|
|
1652
1673
|
inst: e
|
|
1653
1674
|
}), t;
|
|
1654
1675
|
};
|
|
1655
|
-
}),
|
|
1656
|
-
if (
|
|
1676
|
+
}), dr = /*@__PURE__*/ E("$ZodLiteral", (e, t) => {
|
|
1677
|
+
if (I.init(e, t), t.values.length === 0) throw Error("Cannot create literal schema with no valid values");
|
|
1657
1678
|
let n = new Set(t.values);
|
|
1658
|
-
e._zod.values = n, e._zod.pattern = RegExp(`^(${t.values.map((e) => typeof e == "string" ?
|
|
1679
|
+
e._zod.values = n, e._zod.pattern = RegExp(`^(${t.values.map((e) => typeof e == "string" ? j(e) : e ? j(e.toString()) : String(e)).join("|")})$`), e._zod.parse = (r, i) => {
|
|
1659
1680
|
let a = r.value;
|
|
1660
1681
|
return n.has(a) || r.issues.push({
|
|
1661
1682
|
code: "invalid_value",
|
|
@@ -1664,62 +1685,62 @@ var sr = /*@__PURE__*/ E("$ZodRecord", (e, t) => {
|
|
|
1664
1685
|
inst: e
|
|
1665
1686
|
}), r;
|
|
1666
1687
|
};
|
|
1667
|
-
}),
|
|
1668
|
-
|
|
1669
|
-
if (r.direction === "backward") throw new
|
|
1688
|
+
}), fr = /*@__PURE__*/ E("$ZodTransform", (e, t) => {
|
|
1689
|
+
I.init(e, t), e._zod.optin = "optional", e._zod.parse = (n, r) => {
|
|
1690
|
+
if (r.direction === "backward") throw new we(e.constructor.name);
|
|
1670
1691
|
let i = t.transform(n.value, n);
|
|
1671
1692
|
if (r.async) return (i instanceof Promise ? i : Promise.resolve(i)).then((e) => (n.value = e, n.fallback = !0, n));
|
|
1672
|
-
if (i instanceof Promise) throw new
|
|
1693
|
+
if (i instanceof Promise) throw new Ce();
|
|
1673
1694
|
return n.value = i, n.fallback = !0, n;
|
|
1674
1695
|
};
|
|
1675
1696
|
});
|
|
1676
|
-
function
|
|
1697
|
+
function pr(e, t) {
|
|
1677
1698
|
return t === void 0 && (e.issues.length || e.fallback) ? {
|
|
1678
1699
|
issues: [],
|
|
1679
1700
|
value: void 0
|
|
1680
1701
|
} : e;
|
|
1681
1702
|
}
|
|
1682
|
-
var
|
|
1683
|
-
|
|
1703
|
+
var mr = /*@__PURE__*/ E("$ZodOptional", (e, t) => {
|
|
1704
|
+
I.init(e, t), e._zod.optin = "optional", e._zod.optout = "optional", O(e._zod, "values", () => t.innerType._zod.values ? new Set([...t.innerType._zod.values, void 0]) : void 0), O(e._zod, "pattern", () => {
|
|
1684
1705
|
let e = t.innerType._zod.pattern;
|
|
1685
|
-
return e ? RegExp(`^(${
|
|
1706
|
+
return e ? RegExp(`^(${Ae(e.source)})?$`) : void 0;
|
|
1686
1707
|
}), e._zod.parse = (e, n) => {
|
|
1687
1708
|
if (t.innerType._zod.optin === "optional") {
|
|
1688
1709
|
let r = e.value, i = t.innerType._zod.run(e, n);
|
|
1689
|
-
return i instanceof Promise ? i.then((e) =>
|
|
1710
|
+
return i instanceof Promise ? i.then((e) => pr(e, r)) : pr(i, r);
|
|
1690
1711
|
}
|
|
1691
1712
|
return e.value === void 0 ? e : t.innerType._zod.run(e, n);
|
|
1692
1713
|
};
|
|
1693
|
-
}),
|
|
1694
|
-
|
|
1695
|
-
}),
|
|
1696
|
-
|
|
1714
|
+
}), hr = /*@__PURE__*/ E("$ZodExactOptional", (e, t) => {
|
|
1715
|
+
mr.init(e, t), O(e._zod, "values", () => t.innerType._zod.values), O(e._zod, "pattern", () => t.innerType._zod.pattern), e._zod.parse = (e, n) => t.innerType._zod.run(e, n);
|
|
1716
|
+
}), gr = /*@__PURE__*/ E("$ZodNullable", (e, t) => {
|
|
1717
|
+
I.init(e, t), O(e._zod, "optin", () => t.innerType._zod.optin), O(e._zod, "optout", () => t.innerType._zod.optout), O(e._zod, "pattern", () => {
|
|
1697
1718
|
let e = t.innerType._zod.pattern;
|
|
1698
|
-
return e ? RegExp(`^(${
|
|
1719
|
+
return e ? RegExp(`^(${Ae(e.source)}|null)$`) : void 0;
|
|
1699
1720
|
}), O(e._zod, "values", () => t.innerType._zod.values ? new Set([...t.innerType._zod.values, null]) : void 0), e._zod.parse = (e, n) => e.value === null ? e : t.innerType._zod.run(e, n);
|
|
1700
|
-
}),
|
|
1701
|
-
|
|
1721
|
+
}), _r = /*@__PURE__*/ E("$ZodDefault", (e, t) => {
|
|
1722
|
+
I.init(e, t), e._zod.optin = "optional", O(e._zod, "values", () => t.innerType._zod.values), e._zod.parse = (e, n) => {
|
|
1702
1723
|
if (n.direction === "backward") return t.innerType._zod.run(e, n);
|
|
1703
1724
|
if (e.value === void 0) return e.value = t.defaultValue, e;
|
|
1704
1725
|
let r = t.innerType._zod.run(e, n);
|
|
1705
|
-
return r instanceof Promise ? r.then((e) =>
|
|
1726
|
+
return r instanceof Promise ? r.then((e) => vr(e, t)) : vr(r, t);
|
|
1706
1727
|
};
|
|
1707
1728
|
});
|
|
1708
|
-
function
|
|
1729
|
+
function vr(e, t) {
|
|
1709
1730
|
return e.value === void 0 && (e.value = t.defaultValue), e;
|
|
1710
1731
|
}
|
|
1711
|
-
var
|
|
1712
|
-
|
|
1713
|
-
}),
|
|
1714
|
-
|
|
1732
|
+
var yr = /*@__PURE__*/ E("$ZodPrefault", (e, t) => {
|
|
1733
|
+
I.init(e, t), e._zod.optin = "optional", O(e._zod, "values", () => t.innerType._zod.values), e._zod.parse = (e, n) => (n.direction === "backward" || e.value === void 0 && (e.value = t.defaultValue), t.innerType._zod.run(e, n));
|
|
1734
|
+
}), br = /*@__PURE__*/ E("$ZodNonOptional", (e, t) => {
|
|
1735
|
+
I.init(e, t), O(e._zod, "values", () => {
|
|
1715
1736
|
let e = t.innerType._zod.values;
|
|
1716
1737
|
return e ? new Set([...e].filter((e) => e !== void 0)) : void 0;
|
|
1717
1738
|
}), e._zod.parse = (n, r) => {
|
|
1718
1739
|
let i = t.innerType._zod.run(n, r);
|
|
1719
|
-
return i instanceof Promise ? i.then((t) =>
|
|
1740
|
+
return i instanceof Promise ? i.then((t) => xr(t, e)) : xr(i, e);
|
|
1720
1741
|
};
|
|
1721
1742
|
});
|
|
1722
|
-
function
|
|
1743
|
+
function xr(e, t) {
|
|
1723
1744
|
return !e.issues.length && e.value === void 0 && e.issues.push({
|
|
1724
1745
|
code: "invalid_type",
|
|
1725
1746
|
expected: "nonoptional",
|
|
@@ -1727,55 +1748,55 @@ function yr(e, t) {
|
|
|
1727
1748
|
inst: t
|
|
1728
1749
|
}), e;
|
|
1729
1750
|
}
|
|
1730
|
-
var
|
|
1731
|
-
|
|
1751
|
+
var Sr = /*@__PURE__*/ E("$ZodCatch", (e, t) => {
|
|
1752
|
+
I.init(e, t), e._zod.optin = "optional", O(e._zod, "optout", () => t.innerType._zod.optout), O(e._zod, "values", () => t.innerType._zod.values), e._zod.parse = (e, n) => {
|
|
1732
1753
|
if (n.direction === "backward") return t.innerType._zod.run(e, n);
|
|
1733
1754
|
let r = t.innerType._zod.run(e, n);
|
|
1734
1755
|
return r instanceof Promise ? r.then((r) => (e.value = r.value, r.issues.length && (e.value = t.catchValue({
|
|
1735
1756
|
...e,
|
|
1736
|
-
error: { issues: r.issues.map((e) =>
|
|
1757
|
+
error: { issues: r.issues.map((e) => P(e, n, D())) },
|
|
1737
1758
|
input: e.value
|
|
1738
1759
|
}), e.issues = [], e.fallback = !0), e)) : (e.value = r.value, r.issues.length && (e.value = t.catchValue({
|
|
1739
1760
|
...e,
|
|
1740
|
-
error: { issues: r.issues.map((e) =>
|
|
1761
|
+
error: { issues: r.issues.map((e) => P(e, n, D())) },
|
|
1741
1762
|
input: e.value
|
|
1742
1763
|
}), e.issues = [], e.fallback = !0), e);
|
|
1743
1764
|
};
|
|
1744
|
-
}),
|
|
1745
|
-
|
|
1765
|
+
}), Cr = /*@__PURE__*/ E("$ZodPipe", (e, t) => {
|
|
1766
|
+
I.init(e, t), O(e._zod, "values", () => t.in._zod.values), O(e._zod, "optin", () => t.in._zod.optin), O(e._zod, "optout", () => t.out._zod.optout), O(e._zod, "propValues", () => t.in._zod.propValues), e._zod.parse = (e, n) => {
|
|
1746
1767
|
if (n.direction === "backward") {
|
|
1747
1768
|
let r = t.out._zod.run(e, n);
|
|
1748
|
-
return r instanceof Promise ? r.then((e) =>
|
|
1769
|
+
return r instanceof Promise ? r.then((e) => wr(e, t.in, n)) : wr(r, t.in, n);
|
|
1749
1770
|
}
|
|
1750
1771
|
let r = t.in._zod.run(e, n);
|
|
1751
|
-
return r instanceof Promise ? r.then((e) =>
|
|
1772
|
+
return r instanceof Promise ? r.then((e) => wr(e, t.out, n)) : wr(r, t.out, n);
|
|
1752
1773
|
};
|
|
1753
1774
|
});
|
|
1754
|
-
function
|
|
1775
|
+
function wr(e, t, n) {
|
|
1755
1776
|
return e.issues.length ? (e.aborted = !0, e) : t._zod.run({
|
|
1756
1777
|
value: e.value,
|
|
1757
1778
|
issues: e.issues,
|
|
1758
1779
|
fallback: e.fallback
|
|
1759
1780
|
}, n);
|
|
1760
1781
|
}
|
|
1761
|
-
var
|
|
1762
|
-
|
|
1782
|
+
var Tr = /*@__PURE__*/ E("$ZodReadonly", (e, t) => {
|
|
1783
|
+
I.init(e, t), O(e._zod, "propValues", () => t.innerType._zod.propValues), O(e._zod, "values", () => t.innerType._zod.values), O(e._zod, "optin", () => t.innerType?._zod?.optin), O(e._zod, "optout", () => t.innerType?._zod?.optout), e._zod.parse = (e, n) => {
|
|
1763
1784
|
if (n.direction === "backward") return t.innerType._zod.run(e, n);
|
|
1764
1785
|
let r = t.innerType._zod.run(e, n);
|
|
1765
|
-
return r instanceof Promise ? r.then(
|
|
1786
|
+
return r instanceof Promise ? r.then(Er) : Er(r);
|
|
1766
1787
|
};
|
|
1767
1788
|
});
|
|
1768
|
-
function
|
|
1789
|
+
function Er(e) {
|
|
1769
1790
|
return e.value = Object.freeze(e.value), e;
|
|
1770
1791
|
}
|
|
1771
|
-
var
|
|
1772
|
-
|
|
1792
|
+
var Dr = /*@__PURE__*/ E("$ZodCustom", (e, t) => {
|
|
1793
|
+
F.init(e, t), I.init(e, t), e._zod.parse = (e, t) => e, e._zod.check = (n) => {
|
|
1773
1794
|
let r = n.value, i = t.fn(r);
|
|
1774
|
-
if (i instanceof Promise) return i.then((t) =>
|
|
1775
|
-
|
|
1795
|
+
if (i instanceof Promise) return i.then((t) => Or(t, n, r, e));
|
|
1796
|
+
Or(i, n, r, e);
|
|
1776
1797
|
};
|
|
1777
1798
|
});
|
|
1778
|
-
function
|
|
1799
|
+
function Or(e, t, n, r) {
|
|
1779
1800
|
if (!e) {
|
|
1780
1801
|
let e = {
|
|
1781
1802
|
code: "custom",
|
|
@@ -1784,12 +1805,12 @@ function Er(e, t, n, r) {
|
|
|
1784
1805
|
path: [...r._zod.def.path ?? []],
|
|
1785
1806
|
continue: !r._zod.def.abort
|
|
1786
1807
|
};
|
|
1787
|
-
r._zod.def.params && (e.params = r._zod.def.params), t.issues.push(
|
|
1808
|
+
r._zod.def.params && (e.params = r._zod.def.params), t.issues.push(tt(e));
|
|
1788
1809
|
}
|
|
1789
1810
|
}
|
|
1790
1811
|
//#endregion
|
|
1791
1812
|
//#region ../../node_modules/zod/v4/core/registries.js
|
|
1792
|
-
var
|
|
1813
|
+
var kr, Ar = class {
|
|
1793
1814
|
constructor() {
|
|
1794
1815
|
this._map = /* @__PURE__ */ new WeakMap(), this._idmap = /* @__PURE__ */ new Map();
|
|
1795
1816
|
}
|
|
@@ -1821,245 +1842,245 @@ var Dr, Or = class {
|
|
|
1821
1842
|
return this._map.has(e);
|
|
1822
1843
|
}
|
|
1823
1844
|
};
|
|
1824
|
-
function
|
|
1825
|
-
return new
|
|
1845
|
+
function jr() {
|
|
1846
|
+
return new Ar();
|
|
1826
1847
|
}
|
|
1827
|
-
(
|
|
1828
|
-
var
|
|
1848
|
+
(kr = globalThis).__zod_globalRegistry ?? (kr.__zod_globalRegistry = jr());
|
|
1849
|
+
var Mr = globalThis.__zod_globalRegistry;
|
|
1829
1850
|
//#endregion
|
|
1830
1851
|
//#region ../../node_modules/zod/v4/core/api.js
|
|
1831
1852
|
// @__NO_SIDE_EFFECTS__
|
|
1832
|
-
function
|
|
1853
|
+
function Nr(e, t) {
|
|
1833
1854
|
return new e({
|
|
1834
1855
|
type: "string",
|
|
1835
|
-
...
|
|
1856
|
+
...N(t)
|
|
1836
1857
|
});
|
|
1837
1858
|
}
|
|
1838
1859
|
// @__NO_SIDE_EFFECTS__
|
|
1839
|
-
function
|
|
1860
|
+
function Pr(e, t) {
|
|
1840
1861
|
return new e({
|
|
1841
1862
|
type: "string",
|
|
1842
1863
|
format: "email",
|
|
1843
1864
|
check: "string_format",
|
|
1844
1865
|
abort: !1,
|
|
1845
|
-
...
|
|
1866
|
+
...N(t)
|
|
1846
1867
|
});
|
|
1847
1868
|
}
|
|
1848
1869
|
// @__NO_SIDE_EFFECTS__
|
|
1849
|
-
function
|
|
1870
|
+
function Fr(e, t) {
|
|
1850
1871
|
return new e({
|
|
1851
1872
|
type: "string",
|
|
1852
1873
|
format: "guid",
|
|
1853
1874
|
check: "string_format",
|
|
1854
1875
|
abort: !1,
|
|
1855
|
-
...
|
|
1876
|
+
...N(t)
|
|
1856
1877
|
});
|
|
1857
1878
|
}
|
|
1858
1879
|
// @__NO_SIDE_EFFECTS__
|
|
1859
|
-
function
|
|
1880
|
+
function Ir(e, t) {
|
|
1860
1881
|
return new e({
|
|
1861
1882
|
type: "string",
|
|
1862
1883
|
format: "uuid",
|
|
1863
1884
|
check: "string_format",
|
|
1864
1885
|
abort: !1,
|
|
1865
|
-
...
|
|
1886
|
+
...N(t)
|
|
1866
1887
|
});
|
|
1867
1888
|
}
|
|
1868
1889
|
// @__NO_SIDE_EFFECTS__
|
|
1869
|
-
function
|
|
1890
|
+
function Lr(e, t) {
|
|
1870
1891
|
return new e({
|
|
1871
1892
|
type: "string",
|
|
1872
1893
|
format: "uuid",
|
|
1873
1894
|
check: "string_format",
|
|
1874
1895
|
abort: !1,
|
|
1875
1896
|
version: "v4",
|
|
1876
|
-
...
|
|
1897
|
+
...N(t)
|
|
1877
1898
|
});
|
|
1878
1899
|
}
|
|
1879
1900
|
// @__NO_SIDE_EFFECTS__
|
|
1880
|
-
function
|
|
1901
|
+
function Rr(e, t) {
|
|
1881
1902
|
return new e({
|
|
1882
1903
|
type: "string",
|
|
1883
1904
|
format: "uuid",
|
|
1884
1905
|
check: "string_format",
|
|
1885
1906
|
abort: !1,
|
|
1886
1907
|
version: "v6",
|
|
1887
|
-
...
|
|
1908
|
+
...N(t)
|
|
1888
1909
|
});
|
|
1889
1910
|
}
|
|
1890
1911
|
// @__NO_SIDE_EFFECTS__
|
|
1891
|
-
function
|
|
1912
|
+
function zr(e, t) {
|
|
1892
1913
|
return new e({
|
|
1893
1914
|
type: "string",
|
|
1894
1915
|
format: "uuid",
|
|
1895
1916
|
check: "string_format",
|
|
1896
1917
|
abort: !1,
|
|
1897
1918
|
version: "v7",
|
|
1898
|
-
...
|
|
1919
|
+
...N(t)
|
|
1899
1920
|
});
|
|
1900
1921
|
}
|
|
1901
1922
|
// @__NO_SIDE_EFFECTS__
|
|
1902
|
-
function
|
|
1923
|
+
function Br(e, t) {
|
|
1903
1924
|
return new e({
|
|
1904
1925
|
type: "string",
|
|
1905
1926
|
format: "url",
|
|
1906
1927
|
check: "string_format",
|
|
1907
1928
|
abort: !1,
|
|
1908
|
-
...
|
|
1929
|
+
...N(t)
|
|
1909
1930
|
});
|
|
1910
1931
|
}
|
|
1911
1932
|
// @__NO_SIDE_EFFECTS__
|
|
1912
|
-
function
|
|
1933
|
+
function Vr(e, t) {
|
|
1913
1934
|
return new e({
|
|
1914
1935
|
type: "string",
|
|
1915
1936
|
format: "emoji",
|
|
1916
1937
|
check: "string_format",
|
|
1917
1938
|
abort: !1,
|
|
1918
|
-
...
|
|
1939
|
+
...N(t)
|
|
1919
1940
|
});
|
|
1920
1941
|
}
|
|
1921
1942
|
// @__NO_SIDE_EFFECTS__
|
|
1922
|
-
function
|
|
1943
|
+
function Hr(e, t) {
|
|
1923
1944
|
return new e({
|
|
1924
1945
|
type: "string",
|
|
1925
1946
|
format: "nanoid",
|
|
1926
1947
|
check: "string_format",
|
|
1927
1948
|
abort: !1,
|
|
1928
|
-
...
|
|
1949
|
+
...N(t)
|
|
1929
1950
|
});
|
|
1930
1951
|
}
|
|
1931
1952
|
// @__NO_SIDE_EFFECTS__
|
|
1932
|
-
function
|
|
1953
|
+
function Ur(e, t) {
|
|
1933
1954
|
return new e({
|
|
1934
1955
|
type: "string",
|
|
1935
1956
|
format: "cuid",
|
|
1936
1957
|
check: "string_format",
|
|
1937
1958
|
abort: !1,
|
|
1938
|
-
...
|
|
1959
|
+
...N(t)
|
|
1939
1960
|
});
|
|
1940
1961
|
}
|
|
1941
1962
|
// @__NO_SIDE_EFFECTS__
|
|
1942
|
-
function
|
|
1963
|
+
function Wr(e, t) {
|
|
1943
1964
|
return new e({
|
|
1944
1965
|
type: "string",
|
|
1945
1966
|
format: "cuid2",
|
|
1946
1967
|
check: "string_format",
|
|
1947
1968
|
abort: !1,
|
|
1948
|
-
...
|
|
1969
|
+
...N(t)
|
|
1949
1970
|
});
|
|
1950
1971
|
}
|
|
1951
1972
|
// @__NO_SIDE_EFFECTS__
|
|
1952
|
-
function
|
|
1973
|
+
function Gr(e, t) {
|
|
1953
1974
|
return new e({
|
|
1954
1975
|
type: "string",
|
|
1955
1976
|
format: "ulid",
|
|
1956
1977
|
check: "string_format",
|
|
1957
1978
|
abort: !1,
|
|
1958
|
-
...
|
|
1979
|
+
...N(t)
|
|
1959
1980
|
});
|
|
1960
1981
|
}
|
|
1961
1982
|
// @__NO_SIDE_EFFECTS__
|
|
1962
|
-
function
|
|
1983
|
+
function Kr(e, t) {
|
|
1963
1984
|
return new e({
|
|
1964
1985
|
type: "string",
|
|
1965
1986
|
format: "xid",
|
|
1966
1987
|
check: "string_format",
|
|
1967
1988
|
abort: !1,
|
|
1968
|
-
...
|
|
1989
|
+
...N(t)
|
|
1969
1990
|
});
|
|
1970
1991
|
}
|
|
1971
1992
|
// @__NO_SIDE_EFFECTS__
|
|
1972
|
-
function
|
|
1993
|
+
function qr(e, t) {
|
|
1973
1994
|
return new e({
|
|
1974
1995
|
type: "string",
|
|
1975
1996
|
format: "ksuid",
|
|
1976
1997
|
check: "string_format",
|
|
1977
1998
|
abort: !1,
|
|
1978
|
-
...
|
|
1999
|
+
...N(t)
|
|
1979
2000
|
});
|
|
1980
2001
|
}
|
|
1981
2002
|
// @__NO_SIDE_EFFECTS__
|
|
1982
|
-
function
|
|
2003
|
+
function Jr(e, t) {
|
|
1983
2004
|
return new e({
|
|
1984
2005
|
type: "string",
|
|
1985
2006
|
format: "ipv4",
|
|
1986
2007
|
check: "string_format",
|
|
1987
2008
|
abort: !1,
|
|
1988
|
-
...
|
|
2009
|
+
...N(t)
|
|
1989
2010
|
});
|
|
1990
2011
|
}
|
|
1991
2012
|
// @__NO_SIDE_EFFECTS__
|
|
1992
|
-
function
|
|
2013
|
+
function Yr(e, t) {
|
|
1993
2014
|
return new e({
|
|
1994
2015
|
type: "string",
|
|
1995
2016
|
format: "ipv6",
|
|
1996
2017
|
check: "string_format",
|
|
1997
2018
|
abort: !1,
|
|
1998
|
-
...
|
|
2019
|
+
...N(t)
|
|
1999
2020
|
});
|
|
2000
2021
|
}
|
|
2001
2022
|
// @__NO_SIDE_EFFECTS__
|
|
2002
|
-
function
|
|
2023
|
+
function Xr(e, t) {
|
|
2003
2024
|
return new e({
|
|
2004
2025
|
type: "string",
|
|
2005
2026
|
format: "cidrv4",
|
|
2006
2027
|
check: "string_format",
|
|
2007
2028
|
abort: !1,
|
|
2008
|
-
...
|
|
2029
|
+
...N(t)
|
|
2009
2030
|
});
|
|
2010
2031
|
}
|
|
2011
2032
|
// @__NO_SIDE_EFFECTS__
|
|
2012
|
-
function
|
|
2033
|
+
function Zr(e, t) {
|
|
2013
2034
|
return new e({
|
|
2014
2035
|
type: "string",
|
|
2015
2036
|
format: "cidrv6",
|
|
2016
2037
|
check: "string_format",
|
|
2017
2038
|
abort: !1,
|
|
2018
|
-
...
|
|
2039
|
+
...N(t)
|
|
2019
2040
|
});
|
|
2020
2041
|
}
|
|
2021
2042
|
// @__NO_SIDE_EFFECTS__
|
|
2022
|
-
function
|
|
2043
|
+
function Qr(e, t) {
|
|
2023
2044
|
return new e({
|
|
2024
2045
|
type: "string",
|
|
2025
2046
|
format: "base64",
|
|
2026
2047
|
check: "string_format",
|
|
2027
2048
|
abort: !1,
|
|
2028
|
-
...
|
|
2049
|
+
...N(t)
|
|
2029
2050
|
});
|
|
2030
2051
|
}
|
|
2031
2052
|
// @__NO_SIDE_EFFECTS__
|
|
2032
|
-
function
|
|
2053
|
+
function $r(e, t) {
|
|
2033
2054
|
return new e({
|
|
2034
2055
|
type: "string",
|
|
2035
2056
|
format: "base64url",
|
|
2036
2057
|
check: "string_format",
|
|
2037
2058
|
abort: !1,
|
|
2038
|
-
...
|
|
2059
|
+
...N(t)
|
|
2039
2060
|
});
|
|
2040
2061
|
}
|
|
2041
2062
|
// @__NO_SIDE_EFFECTS__
|
|
2042
|
-
function
|
|
2063
|
+
function ei(e, t) {
|
|
2043
2064
|
return new e({
|
|
2044
2065
|
type: "string",
|
|
2045
2066
|
format: "e164",
|
|
2046
2067
|
check: "string_format",
|
|
2047
2068
|
abort: !1,
|
|
2048
|
-
...
|
|
2069
|
+
...N(t)
|
|
2049
2070
|
});
|
|
2050
2071
|
}
|
|
2051
2072
|
// @__NO_SIDE_EFFECTS__
|
|
2052
|
-
function
|
|
2073
|
+
function ti(e, t) {
|
|
2053
2074
|
return new e({
|
|
2054
2075
|
type: "string",
|
|
2055
2076
|
format: "jwt",
|
|
2056
2077
|
check: "string_format",
|
|
2057
2078
|
abort: !1,
|
|
2058
|
-
...
|
|
2079
|
+
...N(t)
|
|
2059
2080
|
});
|
|
2060
2081
|
}
|
|
2061
2082
|
// @__NO_SIDE_EFFECTS__
|
|
2062
|
-
function
|
|
2083
|
+
function ni(e, t) {
|
|
2063
2084
|
return new e({
|
|
2064
2085
|
type: "string",
|
|
2065
2086
|
format: "datetime",
|
|
@@ -2067,270 +2088,270 @@ function ei(e, t) {
|
|
|
2067
2088
|
offset: !1,
|
|
2068
2089
|
local: !1,
|
|
2069
2090
|
precision: null,
|
|
2070
|
-
...
|
|
2091
|
+
...N(t)
|
|
2071
2092
|
});
|
|
2072
2093
|
}
|
|
2073
2094
|
// @__NO_SIDE_EFFECTS__
|
|
2074
|
-
function
|
|
2095
|
+
function ri(e, t) {
|
|
2075
2096
|
return new e({
|
|
2076
2097
|
type: "string",
|
|
2077
2098
|
format: "date",
|
|
2078
2099
|
check: "string_format",
|
|
2079
|
-
...
|
|
2100
|
+
...N(t)
|
|
2080
2101
|
});
|
|
2081
2102
|
}
|
|
2082
2103
|
// @__NO_SIDE_EFFECTS__
|
|
2083
|
-
function
|
|
2104
|
+
function ii(e, t) {
|
|
2084
2105
|
return new e({
|
|
2085
2106
|
type: "string",
|
|
2086
2107
|
format: "time",
|
|
2087
2108
|
check: "string_format",
|
|
2088
2109
|
precision: null,
|
|
2089
|
-
...
|
|
2110
|
+
...N(t)
|
|
2090
2111
|
});
|
|
2091
2112
|
}
|
|
2092
2113
|
// @__NO_SIDE_EFFECTS__
|
|
2093
|
-
function
|
|
2114
|
+
function ai(e, t) {
|
|
2094
2115
|
return new e({
|
|
2095
2116
|
type: "string",
|
|
2096
2117
|
format: "duration",
|
|
2097
2118
|
check: "string_format",
|
|
2098
|
-
...
|
|
2119
|
+
...N(t)
|
|
2099
2120
|
});
|
|
2100
2121
|
}
|
|
2101
2122
|
// @__NO_SIDE_EFFECTS__
|
|
2102
|
-
function
|
|
2123
|
+
function oi(e, t) {
|
|
2103
2124
|
return new e({
|
|
2104
2125
|
type: "number",
|
|
2105
2126
|
checks: [],
|
|
2106
|
-
...
|
|
2127
|
+
...N(t)
|
|
2107
2128
|
});
|
|
2108
2129
|
}
|
|
2109
2130
|
// @__NO_SIDE_EFFECTS__
|
|
2110
|
-
function
|
|
2131
|
+
function si(e, t) {
|
|
2111
2132
|
return new e({
|
|
2112
2133
|
type: "number",
|
|
2113
2134
|
check: "number_format",
|
|
2114
2135
|
abort: !1,
|
|
2115
2136
|
format: "safeint",
|
|
2116
|
-
...
|
|
2137
|
+
...N(t)
|
|
2117
2138
|
});
|
|
2118
2139
|
}
|
|
2119
2140
|
// @__NO_SIDE_EFFECTS__
|
|
2120
|
-
function
|
|
2141
|
+
function ci(e, t) {
|
|
2121
2142
|
return new e({
|
|
2122
2143
|
type: "boolean",
|
|
2123
|
-
...
|
|
2144
|
+
...N(t)
|
|
2124
2145
|
});
|
|
2125
2146
|
}
|
|
2126
2147
|
// @__NO_SIDE_EFFECTS__
|
|
2127
|
-
function
|
|
2148
|
+
function li(e, t) {
|
|
2128
2149
|
return new e({
|
|
2129
2150
|
type: "null",
|
|
2130
|
-
...
|
|
2151
|
+
...N(t)
|
|
2131
2152
|
});
|
|
2132
2153
|
}
|
|
2133
2154
|
// @__NO_SIDE_EFFECTS__
|
|
2134
|
-
function
|
|
2155
|
+
function ui(e) {
|
|
2135
2156
|
return new e({ type: "unknown" });
|
|
2136
2157
|
}
|
|
2137
2158
|
// @__NO_SIDE_EFFECTS__
|
|
2138
|
-
function
|
|
2159
|
+
function di(e, t) {
|
|
2139
2160
|
return new e({
|
|
2140
2161
|
type: "never",
|
|
2141
|
-
...
|
|
2162
|
+
...N(t)
|
|
2142
2163
|
});
|
|
2143
2164
|
}
|
|
2144
2165
|
// @__NO_SIDE_EFFECTS__
|
|
2145
|
-
function
|
|
2146
|
-
return new
|
|
2166
|
+
function fi(e, t) {
|
|
2167
|
+
return new en({
|
|
2147
2168
|
check: "less_than",
|
|
2148
|
-
...
|
|
2169
|
+
...N(t),
|
|
2149
2170
|
value: e,
|
|
2150
2171
|
inclusive: !1
|
|
2151
2172
|
});
|
|
2152
2173
|
}
|
|
2153
2174
|
// @__NO_SIDE_EFFECTS__
|
|
2154
|
-
function
|
|
2155
|
-
return new
|
|
2175
|
+
function pi(e, t) {
|
|
2176
|
+
return new en({
|
|
2156
2177
|
check: "less_than",
|
|
2157
|
-
...
|
|
2178
|
+
...N(t),
|
|
2158
2179
|
value: e,
|
|
2159
2180
|
inclusive: !0
|
|
2160
2181
|
});
|
|
2161
2182
|
}
|
|
2162
2183
|
// @__NO_SIDE_EFFECTS__
|
|
2163
|
-
function
|
|
2164
|
-
return new
|
|
2184
|
+
function mi(e, t) {
|
|
2185
|
+
return new tn({
|
|
2165
2186
|
check: "greater_than",
|
|
2166
|
-
...
|
|
2187
|
+
...N(t),
|
|
2167
2188
|
value: e,
|
|
2168
2189
|
inclusive: !1
|
|
2169
2190
|
});
|
|
2170
2191
|
}
|
|
2171
2192
|
// @__NO_SIDE_EFFECTS__
|
|
2172
|
-
function
|
|
2173
|
-
return new
|
|
2193
|
+
function hi(e, t) {
|
|
2194
|
+
return new tn({
|
|
2174
2195
|
check: "greater_than",
|
|
2175
|
-
...
|
|
2196
|
+
...N(t),
|
|
2176
2197
|
value: e,
|
|
2177
2198
|
inclusive: !0
|
|
2178
2199
|
});
|
|
2179
2200
|
}
|
|
2180
2201
|
// @__NO_SIDE_EFFECTS__
|
|
2181
|
-
function
|
|
2182
|
-
return new
|
|
2202
|
+
function gi(e, t) {
|
|
2203
|
+
return new nn({
|
|
2183
2204
|
check: "multiple_of",
|
|
2184
|
-
...
|
|
2205
|
+
...N(t),
|
|
2185
2206
|
value: e
|
|
2186
2207
|
});
|
|
2187
2208
|
}
|
|
2188
2209
|
// @__NO_SIDE_EFFECTS__
|
|
2189
|
-
function
|
|
2190
|
-
return new
|
|
2210
|
+
function _i(e, t) {
|
|
2211
|
+
return new an({
|
|
2191
2212
|
check: "max_length",
|
|
2192
|
-
...
|
|
2213
|
+
...N(t),
|
|
2193
2214
|
maximum: e
|
|
2194
2215
|
});
|
|
2195
2216
|
}
|
|
2196
2217
|
// @__NO_SIDE_EFFECTS__
|
|
2197
|
-
function
|
|
2198
|
-
return new
|
|
2218
|
+
function vi(e, t) {
|
|
2219
|
+
return new on({
|
|
2199
2220
|
check: "min_length",
|
|
2200
|
-
...
|
|
2221
|
+
...N(t),
|
|
2201
2222
|
minimum: e
|
|
2202
2223
|
});
|
|
2203
2224
|
}
|
|
2204
2225
|
// @__NO_SIDE_EFFECTS__
|
|
2205
|
-
function
|
|
2206
|
-
return new
|
|
2226
|
+
function yi(e, t) {
|
|
2227
|
+
return new sn({
|
|
2207
2228
|
check: "length_equals",
|
|
2208
|
-
...
|
|
2229
|
+
...N(t),
|
|
2209
2230
|
length: e
|
|
2210
2231
|
});
|
|
2211
2232
|
}
|
|
2212
2233
|
// @__NO_SIDE_EFFECTS__
|
|
2213
|
-
function
|
|
2214
|
-
return new
|
|
2234
|
+
function bi(e, t) {
|
|
2235
|
+
return new ln({
|
|
2215
2236
|
check: "string_format",
|
|
2216
2237
|
format: "regex",
|
|
2217
|
-
...
|
|
2238
|
+
...N(t),
|
|
2218
2239
|
pattern: e
|
|
2219
2240
|
});
|
|
2220
2241
|
}
|
|
2221
2242
|
// @__NO_SIDE_EFFECTS__
|
|
2222
|
-
function
|
|
2223
|
-
return new
|
|
2243
|
+
function xi(e) {
|
|
2244
|
+
return new un({
|
|
2224
2245
|
check: "string_format",
|
|
2225
2246
|
format: "lowercase",
|
|
2226
|
-
...
|
|
2247
|
+
...N(e)
|
|
2227
2248
|
});
|
|
2228
2249
|
}
|
|
2229
2250
|
// @__NO_SIDE_EFFECTS__
|
|
2230
|
-
function
|
|
2231
|
-
return new
|
|
2251
|
+
function Si(e) {
|
|
2252
|
+
return new dn({
|
|
2232
2253
|
check: "string_format",
|
|
2233
2254
|
format: "uppercase",
|
|
2234
|
-
...
|
|
2255
|
+
...N(e)
|
|
2235
2256
|
});
|
|
2236
2257
|
}
|
|
2237
2258
|
// @__NO_SIDE_EFFECTS__
|
|
2238
|
-
function
|
|
2239
|
-
return new
|
|
2259
|
+
function Ci(e, t) {
|
|
2260
|
+
return new fn({
|
|
2240
2261
|
check: "string_format",
|
|
2241
2262
|
format: "includes",
|
|
2242
|
-
...
|
|
2263
|
+
...N(t),
|
|
2243
2264
|
includes: e
|
|
2244
2265
|
});
|
|
2245
2266
|
}
|
|
2246
2267
|
// @__NO_SIDE_EFFECTS__
|
|
2247
|
-
function
|
|
2248
|
-
return new
|
|
2268
|
+
function wi(e, t) {
|
|
2269
|
+
return new pn({
|
|
2249
2270
|
check: "string_format",
|
|
2250
2271
|
format: "starts_with",
|
|
2251
|
-
...
|
|
2272
|
+
...N(t),
|
|
2252
2273
|
prefix: e
|
|
2253
2274
|
});
|
|
2254
2275
|
}
|
|
2255
2276
|
// @__NO_SIDE_EFFECTS__
|
|
2256
|
-
function
|
|
2257
|
-
return new
|
|
2277
|
+
function Ti(e, t) {
|
|
2278
|
+
return new mn({
|
|
2258
2279
|
check: "string_format",
|
|
2259
2280
|
format: "ends_with",
|
|
2260
|
-
...
|
|
2281
|
+
...N(t),
|
|
2261
2282
|
suffix: e
|
|
2262
2283
|
});
|
|
2263
2284
|
}
|
|
2264
2285
|
// @__NO_SIDE_EFFECTS__
|
|
2265
|
-
function
|
|
2266
|
-
return new
|
|
2286
|
+
function Ei(e) {
|
|
2287
|
+
return new hn({
|
|
2267
2288
|
check: "overwrite",
|
|
2268
2289
|
tx: e
|
|
2269
2290
|
});
|
|
2270
2291
|
}
|
|
2271
2292
|
// @__NO_SIDE_EFFECTS__
|
|
2272
|
-
function
|
|
2273
|
-
return /* @__PURE__ */
|
|
2293
|
+
function Di(e) {
|
|
2294
|
+
return /* @__PURE__ */ Ei((t) => t.normalize(e));
|
|
2274
2295
|
}
|
|
2275
2296
|
// @__NO_SIDE_EFFECTS__
|
|
2276
|
-
function
|
|
2277
|
-
return /* @__PURE__ */
|
|
2297
|
+
function Oi() {
|
|
2298
|
+
return /* @__PURE__ */ Ei((e) => e.trim());
|
|
2278
2299
|
}
|
|
2279
2300
|
// @__NO_SIDE_EFFECTS__
|
|
2280
|
-
function
|
|
2281
|
-
return /* @__PURE__ */
|
|
2301
|
+
function ki() {
|
|
2302
|
+
return /* @__PURE__ */ Ei((e) => e.toLowerCase());
|
|
2282
2303
|
}
|
|
2283
2304
|
// @__NO_SIDE_EFFECTS__
|
|
2284
|
-
function
|
|
2285
|
-
return /* @__PURE__ */
|
|
2305
|
+
function Ai() {
|
|
2306
|
+
return /* @__PURE__ */ Ei((e) => e.toUpperCase());
|
|
2286
2307
|
}
|
|
2287
2308
|
// @__NO_SIDE_EFFECTS__
|
|
2288
|
-
function
|
|
2289
|
-
return /* @__PURE__ */
|
|
2309
|
+
function ji() {
|
|
2310
|
+
return /* @__PURE__ */ Ei((e) => Pe(e));
|
|
2290
2311
|
}
|
|
2291
2312
|
// @__NO_SIDE_EFFECTS__
|
|
2292
|
-
function
|
|
2313
|
+
function Mi(e, t, n) {
|
|
2293
2314
|
return new e({
|
|
2294
2315
|
type: "array",
|
|
2295
2316
|
element: t,
|
|
2296
|
-
...
|
|
2317
|
+
...N(n)
|
|
2297
2318
|
});
|
|
2298
2319
|
}
|
|
2299
2320
|
// @__NO_SIDE_EFFECTS__
|
|
2300
|
-
function
|
|
2321
|
+
function Ni(e, t, n) {
|
|
2301
2322
|
return new e({
|
|
2302
2323
|
type: "custom",
|
|
2303
2324
|
check: "custom",
|
|
2304
2325
|
fn: t,
|
|
2305
|
-
...
|
|
2326
|
+
...N(n)
|
|
2306
2327
|
});
|
|
2307
2328
|
}
|
|
2308
2329
|
// @__NO_SIDE_EFFECTS__
|
|
2309
|
-
function
|
|
2310
|
-
let n = /* @__PURE__ */
|
|
2311
|
-
if (typeof e == "string") t.issues.push(
|
|
2330
|
+
function Pi(e, t) {
|
|
2331
|
+
let n = /* @__PURE__ */ Fi((t) => (t.addIssue = (e) => {
|
|
2332
|
+
if (typeof e == "string") t.issues.push(tt(e, t.value, n._zod.def));
|
|
2312
2333
|
else {
|
|
2313
2334
|
let r = e;
|
|
2314
|
-
r.fatal && (r.continue = !1), r.code ??= "custom", r.input ??= t.value, r.inst ??= n, r.continue ??= !n._zod.def.abort, t.issues.push(
|
|
2335
|
+
r.fatal && (r.continue = !1), r.code ??= "custom", r.input ??= t.value, r.inst ??= n, r.continue ??= !n._zod.def.abort, t.issues.push(tt(r));
|
|
2315
2336
|
}
|
|
2316
2337
|
}, e(t.value, t)), t);
|
|
2317
2338
|
return n;
|
|
2318
2339
|
}
|
|
2319
2340
|
// @__NO_SIDE_EFFECTS__
|
|
2320
|
-
function
|
|
2321
|
-
let n = new
|
|
2341
|
+
function Fi(e, t) {
|
|
2342
|
+
let n = new F({
|
|
2322
2343
|
check: "custom",
|
|
2323
|
-
...
|
|
2344
|
+
...N(t)
|
|
2324
2345
|
});
|
|
2325
2346
|
return n._zod.check = e, n;
|
|
2326
2347
|
}
|
|
2327
2348
|
//#endregion
|
|
2328
2349
|
//#region ../../node_modules/zod/v4/core/to-json-schema.js
|
|
2329
|
-
function
|
|
2350
|
+
function Ii(e) {
|
|
2330
2351
|
let t = e?.target ?? "draft-2020-12";
|
|
2331
2352
|
return t === "draft-4" && (t = "draft-04"), t === "draft-7" && (t = "draft-07"), {
|
|
2332
2353
|
processors: e.processors ?? {},
|
|
2333
|
-
metadataRegistry: e?.metadata ??
|
|
2354
|
+
metadataRegistry: e?.metadata ?? Mr,
|
|
2334
2355
|
target: t,
|
|
2335
2356
|
unrepresentable: e?.unrepresentable ?? "throw",
|
|
2336
2357
|
override: e?.override ?? (() => {}),
|
|
@@ -2342,7 +2363,7 @@ function Pi(e) {
|
|
|
2342
2363
|
external: e?.external ?? void 0
|
|
2343
2364
|
};
|
|
2344
2365
|
}
|
|
2345
|
-
function
|
|
2366
|
+
function R(e, t, n = {
|
|
2346
2367
|
path: [],
|
|
2347
2368
|
schemaPath: []
|
|
2348
2369
|
}) {
|
|
@@ -2371,12 +2392,12 @@ function z(e, t, n = {
|
|
|
2371
2392
|
a(e, t, n, r);
|
|
2372
2393
|
}
|
|
2373
2394
|
let a = e._zod.parent;
|
|
2374
|
-
a && (o.ref ||= a,
|
|
2395
|
+
a && (o.ref ||= a, R(a, t, r), t.seen.get(a).isParent = !0);
|
|
2375
2396
|
}
|
|
2376
2397
|
let c = t.metadataRegistry.get(e);
|
|
2377
|
-
return c && Object.assign(o.schema, c), t.io === "input" &&
|
|
2398
|
+
return c && Object.assign(o.schema, c), t.io === "input" && z(e) && (delete o.schema.examples, delete o.schema.default), t.io === "input" && "_prefault" in o.schema && ((r = o.schema).default ?? (r.default = o.schema._prefault)), delete o.schema._prefault, t.seen.get(e).schema;
|
|
2378
2399
|
}
|
|
2379
|
-
function
|
|
2400
|
+
function Li(e, t) {
|
|
2380
2401
|
let n = e.seen.get(t);
|
|
2381
2402
|
if (!n) throw Error("Unprocessed schema. This is a bug in Zod.");
|
|
2382
2403
|
let r = /* @__PURE__ */ new Map();
|
|
@@ -2446,7 +2467,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
2446
2467
|
}
|
|
2447
2468
|
}
|
|
2448
2469
|
}
|
|
2449
|
-
function
|
|
2470
|
+
function Ri(e, t) {
|
|
2450
2471
|
let n = e.seen.get(t);
|
|
2451
2472
|
if (!n) throw Error("Unprocessed schema. This is a bug in Zod.");
|
|
2452
2473
|
let r = (t) => {
|
|
@@ -2493,8 +2514,8 @@ function Ii(e, t) {
|
|
|
2493
2514
|
value: {
|
|
2494
2515
|
...t["~standard"],
|
|
2495
2516
|
jsonSchema: {
|
|
2496
|
-
input:
|
|
2497
|
-
output:
|
|
2517
|
+
input: Bi(t, "input", e.processors),
|
|
2518
|
+
output: Bi(t, "output", e.processors)
|
|
2498
2519
|
}
|
|
2499
2520
|
},
|
|
2500
2521
|
enumerable: !1,
|
|
@@ -2504,79 +2525,79 @@ function Ii(e, t) {
|
|
|
2504
2525
|
throw Error("Error converting schema to JSON.");
|
|
2505
2526
|
}
|
|
2506
2527
|
}
|
|
2507
|
-
function
|
|
2528
|
+
function z(e, t) {
|
|
2508
2529
|
let n = t ?? { seen: /* @__PURE__ */ new Set() };
|
|
2509
2530
|
if (n.seen.has(e)) return !1;
|
|
2510
2531
|
n.seen.add(e);
|
|
2511
2532
|
let r = e._zod.def;
|
|
2512
2533
|
if (r.type === "transform") return !0;
|
|
2513
|
-
if (r.type === "array") return
|
|
2514
|
-
if (r.type === "set") return
|
|
2515
|
-
if (r.type === "lazy") return
|
|
2516
|
-
if (r.type === "promise" || r.type === "optional" || r.type === "nonoptional" || r.type === "nullable" || r.type === "readonly" || r.type === "default" || r.type === "prefault") return
|
|
2517
|
-
if (r.type === "intersection") return
|
|
2518
|
-
if (r.type === "record" || r.type === "map") return
|
|
2519
|
-
if (r.type === "pipe") return e._zod.traits.has("$ZodCodec") ? !0 :
|
|
2534
|
+
if (r.type === "array") return z(r.element, n);
|
|
2535
|
+
if (r.type === "set") return z(r.valueType, n);
|
|
2536
|
+
if (r.type === "lazy") return z(r.getter(), n);
|
|
2537
|
+
if (r.type === "promise" || r.type === "optional" || r.type === "nonoptional" || r.type === "nullable" || r.type === "readonly" || r.type === "default" || r.type === "prefault") return z(r.innerType, n);
|
|
2538
|
+
if (r.type === "intersection") return z(r.left, n) || z(r.right, n);
|
|
2539
|
+
if (r.type === "record" || r.type === "map") return z(r.keyType, n) || z(r.valueType, n);
|
|
2540
|
+
if (r.type === "pipe") return e._zod.traits.has("$ZodCodec") ? !0 : z(r.in, n) || z(r.out, n);
|
|
2520
2541
|
if (r.type === "object") {
|
|
2521
|
-
for (let e in r.shape) if (
|
|
2542
|
+
for (let e in r.shape) if (z(r.shape[e], n)) return !0;
|
|
2522
2543
|
return !1;
|
|
2523
2544
|
}
|
|
2524
2545
|
if (r.type === "union") {
|
|
2525
|
-
for (let e of r.options) if (
|
|
2546
|
+
for (let e of r.options) if (z(e, n)) return !0;
|
|
2526
2547
|
return !1;
|
|
2527
2548
|
}
|
|
2528
2549
|
if (r.type === "tuple") {
|
|
2529
|
-
for (let e of r.items) if (
|
|
2530
|
-
return !!(r.rest &&
|
|
2550
|
+
for (let e of r.items) if (z(e, n)) return !0;
|
|
2551
|
+
return !!(r.rest && z(r.rest, n));
|
|
2531
2552
|
}
|
|
2532
2553
|
return !1;
|
|
2533
2554
|
}
|
|
2534
|
-
var
|
|
2535
|
-
let r =
|
|
2555
|
+
var zi = (e, t = {}) => (n) => {
|
|
2556
|
+
let r = Ii({
|
|
2536
2557
|
...n,
|
|
2537
2558
|
processors: t
|
|
2538
2559
|
});
|
|
2539
|
-
return
|
|
2540
|
-
},
|
|
2541
|
-
let { libraryOptions: i, target: a } = r ?? {}, o =
|
|
2560
|
+
return R(e, r), Li(r, e), Ri(r, e);
|
|
2561
|
+
}, Bi = (e, t, n = {}) => (r) => {
|
|
2562
|
+
let { libraryOptions: i, target: a } = r ?? {}, o = Ii({
|
|
2542
2563
|
...i ?? {},
|
|
2543
2564
|
target: a,
|
|
2544
2565
|
io: t,
|
|
2545
2566
|
processors: n
|
|
2546
2567
|
});
|
|
2547
|
-
return
|
|
2548
|
-
},
|
|
2568
|
+
return R(e, o), Li(o, e), Ri(o, e);
|
|
2569
|
+
}, Vi = {
|
|
2549
2570
|
guid: "uuid",
|
|
2550
2571
|
url: "uri",
|
|
2551
2572
|
datetime: "date-time",
|
|
2552
2573
|
json_string: "json-string",
|
|
2553
2574
|
regex: ""
|
|
2554
|
-
},
|
|
2575
|
+
}, Hi = (e, t, n, r) => {
|
|
2555
2576
|
let i = n;
|
|
2556
2577
|
i.type = "string";
|
|
2557
2578
|
let { minimum: a, maximum: o, format: s, patterns: c, contentEncoding: l } = e._zod.bag;
|
|
2558
|
-
if (typeof a == "number" && (i.minLength = a), typeof o == "number" && (i.maxLength = o), s && (i.format =
|
|
2579
|
+
if (typeof a == "number" && (i.minLength = a), typeof o == "number" && (i.maxLength = o), s && (i.format = Vi[s] ?? s, i.format === "" && delete i.format, s === "time" && delete i.format), l && (i.contentEncoding = l), c && c.size > 0) {
|
|
2559
2580
|
let e = [...c];
|
|
2560
2581
|
e.length === 1 ? i.pattern = e[0].source : e.length > 1 && (i.allOf = [...e.map((e) => ({
|
|
2561
2582
|
...t.target === "draft-07" || t.target === "draft-04" || t.target === "openapi-3.0" ? { type: "string" } : {},
|
|
2562
2583
|
pattern: e.source
|
|
2563
2584
|
}))]);
|
|
2564
2585
|
}
|
|
2565
|
-
},
|
|
2586
|
+
}, Ui = (e, t, n, r) => {
|
|
2566
2587
|
let i = n, { minimum: a, maximum: o, format: s, multipleOf: c, exclusiveMaximum: l, exclusiveMinimum: u } = e._zod.bag;
|
|
2567
2588
|
typeof s == "string" && s.includes("int") ? i.type = "integer" : i.type = "number";
|
|
2568
2589
|
let d = typeof u == "number" && u >= (a ?? -Infinity), f = typeof l == "number" && l <= (o ?? Infinity), p = t.target === "draft-04" || t.target === "openapi-3.0";
|
|
2569
2590
|
d ? p ? (i.minimum = u, i.exclusiveMinimum = !0) : i.exclusiveMinimum = u : typeof a == "number" && (i.minimum = a), f ? p ? (i.maximum = l, i.exclusiveMaximum = !0) : i.exclusiveMaximum = l : typeof o == "number" && (i.maximum = o), typeof c == "number" && (i.multipleOf = c);
|
|
2570
|
-
},
|
|
2591
|
+
}, Wi = (e, t, n, r) => {
|
|
2571
2592
|
n.type = "boolean";
|
|
2572
|
-
},
|
|
2593
|
+
}, Gi = (e, t, n, r) => {
|
|
2573
2594
|
t.target === "openapi-3.0" ? (n.type = "string", n.nullable = !0, n.enum = [null]) : n.type = "null";
|
|
2574
|
-
},
|
|
2595
|
+
}, Ki = (e, t, n, r) => {
|
|
2575
2596
|
n.not = {};
|
|
2576
|
-
},
|
|
2577
|
-
let i = e._zod.def, a =
|
|
2597
|
+
}, qi = (e, t, n, r) => {
|
|
2598
|
+
let i = e._zod.def, a = Ee(i.entries);
|
|
2578
2599
|
a.every((e) => typeof e == "number") && (n.type = "number"), a.every((e) => typeof e == "string") && (n.type = "string"), n.enum = a;
|
|
2579
|
-
},
|
|
2600
|
+
}, Ji = (e, t, n, r) => {
|
|
2580
2601
|
let i = e._zod.def, a = [];
|
|
2581
2602
|
for (let e of i.values) if (e === void 0) {
|
|
2582
2603
|
if (t.unrepresentable === "throw") throw Error("Literal `undefined` cannot be represented in JSON Schema");
|
|
@@ -2588,21 +2609,21 @@ var Li = (e, t = {}) => (n) => {
|
|
|
2588
2609
|
let e = a[0];
|
|
2589
2610
|
n.type = e === null ? "null" : typeof e, t.target === "draft-04" || t.target === "openapi-3.0" ? n.enum = [e] : n.const = e;
|
|
2590
2611
|
} else a.every((e) => typeof e == "number") && (n.type = "number"), a.every((e) => typeof e == "string") && (n.type = "string"), a.every((e) => typeof e == "boolean") && (n.type = "boolean"), a.every((e) => e === null) && (n.type = "null"), n.enum = a;
|
|
2591
|
-
},
|
|
2612
|
+
}, Yi = (e, t, n, r) => {
|
|
2592
2613
|
if (t.unrepresentable === "throw") throw Error("Custom types cannot be represented in JSON Schema");
|
|
2593
|
-
},
|
|
2614
|
+
}, Xi = (e, t, n, r) => {
|
|
2594
2615
|
if (t.unrepresentable === "throw") throw Error("Transforms cannot be represented in JSON Schema");
|
|
2595
|
-
},
|
|
2616
|
+
}, Zi = (e, t, n, r) => {
|
|
2596
2617
|
let i = n, a = e._zod.def, { minimum: o, maximum: s } = e._zod.bag;
|
|
2597
|
-
typeof o == "number" && (i.minItems = o), typeof s == "number" && (i.maxItems = s), i.type = "array", i.items =
|
|
2618
|
+
typeof o == "number" && (i.minItems = o), typeof s == "number" && (i.maxItems = s), i.type = "array", i.items = R(a.element, t, {
|
|
2598
2619
|
...r,
|
|
2599
2620
|
path: [...r.path, "items"]
|
|
2600
2621
|
});
|
|
2601
|
-
},
|
|
2622
|
+
}, Qi = (e, t, n, r) => {
|
|
2602
2623
|
let i = n, a = e._zod.def;
|
|
2603
2624
|
i.type = "object", i.properties = {};
|
|
2604
2625
|
let o = a.shape;
|
|
2605
|
-
for (let e in o) i.properties[e] =
|
|
2626
|
+
for (let e in o) i.properties[e] = R(o[e], t, {
|
|
2606
2627
|
...r,
|
|
2607
2628
|
path: [
|
|
2608
2629
|
...r.path,
|
|
@@ -2614,12 +2635,12 @@ var Li = (e, t = {}) => (n) => {
|
|
|
2614
2635
|
let n = a.shape[e]._zod;
|
|
2615
2636
|
return t.io === "input" ? n.optin === void 0 : n.optout === void 0;
|
|
2616
2637
|
}));
|
|
2617
|
-
c.size > 0 && (i.required = Array.from(c)), a.catchall?._zod.def.type === "never" ? i.additionalProperties = !1 : a.catchall ? a.catchall && (i.additionalProperties =
|
|
2638
|
+
c.size > 0 && (i.required = Array.from(c)), a.catchall?._zod.def.type === "never" ? i.additionalProperties = !1 : a.catchall ? a.catchall && (i.additionalProperties = R(a.catchall, t, {
|
|
2618
2639
|
...r,
|
|
2619
2640
|
path: [...r.path, "additionalProperties"]
|
|
2620
2641
|
})) : t.io === "output" && (i.additionalProperties = !1);
|
|
2621
|
-
},
|
|
2622
|
-
let i = e._zod.def, a = i.inclusive === !1, o = i.options.map((e, n) =>
|
|
2642
|
+
}, $i = (e, t, n, r) => {
|
|
2643
|
+
let i = e._zod.def, a = i.inclusive === !1, o = i.options.map((e, n) => R(e, t, {
|
|
2623
2644
|
...r,
|
|
2624
2645
|
path: [
|
|
2625
2646
|
...r.path,
|
|
@@ -2628,15 +2649,15 @@ var Li = (e, t = {}) => (n) => {
|
|
|
2628
2649
|
]
|
|
2629
2650
|
}));
|
|
2630
2651
|
a ? n.oneOf = o : n.anyOf = o;
|
|
2631
|
-
},
|
|
2632
|
-
let i = e._zod.def, a =
|
|
2652
|
+
}, ea = (e, t, n, r) => {
|
|
2653
|
+
let i = e._zod.def, a = R(i.left, t, {
|
|
2633
2654
|
...r,
|
|
2634
2655
|
path: [
|
|
2635
2656
|
...r.path,
|
|
2636
2657
|
"allOf",
|
|
2637
2658
|
0
|
|
2638
2659
|
]
|
|
2639
|
-
}), o =
|
|
2660
|
+
}), o = R(i.right, t, {
|
|
2640
2661
|
...r,
|
|
2641
2662
|
path: [
|
|
2642
2663
|
...r.path,
|
|
@@ -2645,12 +2666,12 @@ var Li = (e, t = {}) => (n) => {
|
|
|
2645
2666
|
]
|
|
2646
2667
|
}), s = (e) => "allOf" in e && Object.keys(e).length === 1;
|
|
2647
2668
|
n.allOf = [...s(a) ? a.allOf : [a], ...s(o) ? o.allOf : [o]];
|
|
2648
|
-
},
|
|
2669
|
+
}, ta = (e, t, n, r) => {
|
|
2649
2670
|
let i = n, a = e._zod.def;
|
|
2650
2671
|
i.type = "object";
|
|
2651
2672
|
let o = a.keyType, s = o._zod.bag?.patterns;
|
|
2652
2673
|
if (a.mode === "loose" && s && s.size > 0) {
|
|
2653
|
-
let e =
|
|
2674
|
+
let e = R(a.valueType, t, {
|
|
2654
2675
|
...r,
|
|
2655
2676
|
path: [
|
|
2656
2677
|
...r.path,
|
|
@@ -2660,10 +2681,10 @@ var Li = (e, t = {}) => (n) => {
|
|
|
2660
2681
|
});
|
|
2661
2682
|
i.patternProperties = {};
|
|
2662
2683
|
for (let t of s) i.patternProperties[t.source] = e;
|
|
2663
|
-
} else (t.target === "draft-07" || t.target === "draft-2020-12") && (i.propertyNames =
|
|
2684
|
+
} else (t.target === "draft-07" || t.target === "draft-2020-12") && (i.propertyNames = R(a.keyType, t, {
|
|
2664
2685
|
...r,
|
|
2665
2686
|
path: [...r.path, "propertyNames"]
|
|
2666
|
-
})), i.additionalProperties =
|
|
2687
|
+
})), i.additionalProperties = R(a.valueType, t, {
|
|
2667
2688
|
...r,
|
|
2668
2689
|
path: [...r.path, "additionalProperties"]
|
|
2669
2690
|
});
|
|
@@ -2672,27 +2693,27 @@ var Li = (e, t = {}) => (n) => {
|
|
|
2672
2693
|
let e = [...c].filter((e) => typeof e == "string" || typeof e == "number");
|
|
2673
2694
|
e.length > 0 && (i.required = e);
|
|
2674
2695
|
}
|
|
2675
|
-
},
|
|
2676
|
-
let i = e._zod.def, a =
|
|
2696
|
+
}, na = (e, t, n, r) => {
|
|
2697
|
+
let i = e._zod.def, a = R(i.innerType, t, r), o = t.seen.get(e);
|
|
2677
2698
|
t.target === "openapi-3.0" ? (o.ref = i.innerType, n.nullable = !0) : n.anyOf = [a, { type: "null" }];
|
|
2678
|
-
},
|
|
2699
|
+
}, ra = (e, t, n, r) => {
|
|
2679
2700
|
let i = e._zod.def;
|
|
2680
|
-
|
|
2701
|
+
R(i.innerType, t, r);
|
|
2681
2702
|
let a = t.seen.get(e);
|
|
2682
2703
|
a.ref = i.innerType;
|
|
2683
|
-
},
|
|
2704
|
+
}, ia = (e, t, n, r) => {
|
|
2684
2705
|
let i = e._zod.def;
|
|
2685
|
-
|
|
2706
|
+
R(i.innerType, t, r);
|
|
2686
2707
|
let a = t.seen.get(e);
|
|
2687
2708
|
a.ref = i.innerType, n.default = JSON.parse(JSON.stringify(i.defaultValue));
|
|
2688
|
-
},
|
|
2709
|
+
}, aa = (e, t, n, r) => {
|
|
2689
2710
|
let i = e._zod.def;
|
|
2690
|
-
|
|
2711
|
+
R(i.innerType, t, r);
|
|
2691
2712
|
let a = t.seen.get(e);
|
|
2692
2713
|
a.ref = i.innerType, t.io === "input" && (n._prefault = JSON.parse(JSON.stringify(i.defaultValue)));
|
|
2693
|
-
},
|
|
2714
|
+
}, oa = (e, t, n, r) => {
|
|
2694
2715
|
let i = e._zod.def;
|
|
2695
|
-
|
|
2716
|
+
R(i.innerType, t, r);
|
|
2696
2717
|
let a = t.seen.get(e);
|
|
2697
2718
|
a.ref = i.innerType;
|
|
2698
2719
|
let o;
|
|
@@ -2702,63 +2723,63 @@ var Li = (e, t = {}) => (n) => {
|
|
|
2702
2723
|
throw Error("Dynamic catch values are not supported in JSON Schema");
|
|
2703
2724
|
}
|
|
2704
2725
|
n.default = o;
|
|
2705
|
-
},
|
|
2726
|
+
}, sa = (e, t, n, r) => {
|
|
2706
2727
|
let i = e._zod.def, a = i.in._zod.traits.has("$ZodTransform"), o = t.io === "input" ? a ? i.out : i.in : i.out;
|
|
2707
|
-
|
|
2728
|
+
R(o, t, r);
|
|
2708
2729
|
let s = t.seen.get(e);
|
|
2709
2730
|
s.ref = o;
|
|
2710
|
-
},
|
|
2731
|
+
}, ca = (e, t, n, r) => {
|
|
2711
2732
|
let i = e._zod.def;
|
|
2712
|
-
|
|
2733
|
+
R(i.innerType, t, r);
|
|
2713
2734
|
let a = t.seen.get(e);
|
|
2714
2735
|
a.ref = i.innerType, n.readOnly = !0;
|
|
2715
|
-
},
|
|
2736
|
+
}, la = (e, t, n, r) => {
|
|
2716
2737
|
let i = e._zod.def;
|
|
2717
|
-
|
|
2738
|
+
R(i.innerType, t, r);
|
|
2718
2739
|
let a = t.seen.get(e);
|
|
2719
2740
|
a.ref = i.innerType;
|
|
2720
|
-
},
|
|
2721
|
-
|
|
2722
|
-
});
|
|
2723
|
-
function la(e) {
|
|
2724
|
-
return /* @__PURE__ */ ei(ca, e);
|
|
2725
|
-
}
|
|
2726
|
-
var ua = /*@__PURE__*/ E("ZodISODate", (e, t) => {
|
|
2727
|
-
kn.init(e, t), W.init(e, t);
|
|
2741
|
+
}, ua = /*@__PURE__*/ E("ZodISODateTime", (e, t) => {
|
|
2742
|
+
An.init(e, t), U.init(e, t);
|
|
2728
2743
|
});
|
|
2729
2744
|
function da(e) {
|
|
2730
|
-
return /* @__PURE__ */
|
|
2745
|
+
return /* @__PURE__ */ ni(ua, e);
|
|
2731
2746
|
}
|
|
2732
|
-
var fa = /*@__PURE__*/ E("
|
|
2733
|
-
|
|
2747
|
+
var fa = /*@__PURE__*/ E("ZodISODate", (e, t) => {
|
|
2748
|
+
jn.init(e, t), U.init(e, t);
|
|
2734
2749
|
});
|
|
2735
2750
|
function pa(e) {
|
|
2736
|
-
return /* @__PURE__ */
|
|
2751
|
+
return /* @__PURE__ */ ri(fa, e);
|
|
2737
2752
|
}
|
|
2738
|
-
var ma = /*@__PURE__*/ E("
|
|
2739
|
-
|
|
2753
|
+
var ma = /*@__PURE__*/ E("ZodISOTime", (e, t) => {
|
|
2754
|
+
Mn.init(e, t), U.init(e, t);
|
|
2740
2755
|
});
|
|
2741
2756
|
function ha(e) {
|
|
2742
|
-
return /* @__PURE__ */
|
|
2757
|
+
return /* @__PURE__ */ ii(ma, e);
|
|
2743
2758
|
}
|
|
2744
|
-
var
|
|
2745
|
-
|
|
2746
|
-
|
|
2747
|
-
|
|
2759
|
+
var ga = /*@__PURE__*/ E("ZodISODuration", (e, t) => {
|
|
2760
|
+
Nn.init(e, t), U.init(e, t);
|
|
2761
|
+
});
|
|
2762
|
+
function _a(e) {
|
|
2763
|
+
return /* @__PURE__ */ ai(ga, e);
|
|
2764
|
+
}
|
|
2765
|
+
var B = /*@__PURE__*/ E("ZodError", (e, t) => {
|
|
2766
|
+
rt.init(e, t), e.name = "ZodError", Object.defineProperties(e, {
|
|
2767
|
+
format: { value: (t) => ot(e, t) },
|
|
2768
|
+
flatten: { value: (t) => at(e, t) },
|
|
2748
2769
|
addIssue: { value: (t) => {
|
|
2749
|
-
e.issues.push(t), e.message = JSON.stringify(e.issues,
|
|
2770
|
+
e.issues.push(t), e.message = JSON.stringify(e.issues, De, 2);
|
|
2750
2771
|
} },
|
|
2751
2772
|
addIssues: { value: (t) => {
|
|
2752
|
-
e.issues.push(...t), e.message = JSON.stringify(e.issues,
|
|
2773
|
+
e.issues.push(...t), e.message = JSON.stringify(e.issues, De, 2);
|
|
2753
2774
|
} },
|
|
2754
2775
|
isEmpty: { get() {
|
|
2755
2776
|
return e.issues.length === 0;
|
|
2756
2777
|
} }
|
|
2757
2778
|
});
|
|
2758
|
-
}, { Parent: Error }),
|
|
2759
|
-
function
|
|
2760
|
-
let r = Object.getPrototypeOf(e), i =
|
|
2761
|
-
if (i || (i = /* @__PURE__ */ new Set(),
|
|
2779
|
+
}, { Parent: Error }), va = /* @__PURE__ */ st(B), ya = /* @__PURE__ */ ct(B), ba = /* @__PURE__ */ lt(B), xa = /* @__PURE__ */ dt(B), Sa = /* @__PURE__ */ pt(B), Ca = /* @__PURE__ */ mt(B), wa = /* @__PURE__ */ ht(B), Ta = /* @__PURE__ */ gt(B), Ea = /* @__PURE__ */ _t(B), Da = /* @__PURE__ */ vt(B), Oa = /* @__PURE__ */ yt(B), ka = /* @__PURE__ */ bt(B), Aa = /* @__PURE__ */ new WeakMap();
|
|
2780
|
+
function ja(e, t, n) {
|
|
2781
|
+
let r = Object.getPrototypeOf(e), i = Aa.get(r);
|
|
2782
|
+
if (i || (i = /* @__PURE__ */ new Set(), Aa.set(r, i)), !i.has(t)) {
|
|
2762
2783
|
i.add(t);
|
|
2763
2784
|
for (let e in n) {
|
|
2764
2785
|
let t = n[e];
|
|
@@ -2786,10 +2807,10 @@ function ka(e, t, n) {
|
|
|
2786
2807
|
}
|
|
2787
2808
|
}
|
|
2788
2809
|
}
|
|
2789
|
-
var
|
|
2790
|
-
input:
|
|
2791
|
-
output:
|
|
2792
|
-
} }), e.toJSONSchema =
|
|
2810
|
+
var V = /*@__PURE__*/ E("ZodType", (e, t) => (I.init(e, t), Object.assign(e["~standard"], { jsonSchema: {
|
|
2811
|
+
input: Bi(e, "input"),
|
|
2812
|
+
output: Bi(e, "output")
|
|
2813
|
+
} }), e.toJSONSchema = zi(e, {}), e.def = t, e.type = t.type, Object.defineProperty(e, "_def", { value: t }), e.parse = (t, n) => va(e, t, n, { callee: e.parse }), e.safeParse = (t, n) => ba(e, t, n), e.parseAsync = async (t, n) => ya(e, t, n, { callee: e.parseAsync }), e.safeParseAsync = async (t, n) => xa(e, t, n), e.spa = e.safeParseAsync, e.encode = (t, n) => Sa(e, t, n), e.decode = (t, n) => Ca(e, t, n), e.encodeAsync = async (t, n) => wa(e, t, n), e.decodeAsync = async (t, n) => Ta(e, t, n), e.safeEncode = (t, n) => Ea(e, t, n), e.safeDecode = (t, n) => Da(e, t, n), e.safeEncodeAsync = async (t, n) => Oa(e, t, n), e.safeDecodeAsync = async (t, n) => ka(e, t, n), ja(e, "ZodType", {
|
|
2793
2814
|
check(...e) {
|
|
2794
2815
|
let t = this.def;
|
|
2795
2816
|
return this.clone(A(t, { checks: [...t.checks ?? [], ...e.map((e) => typeof e == "function" ? { _zod: {
|
|
@@ -2802,7 +2823,7 @@ var H = /*@__PURE__*/ E("ZodType", (e, t) => (L.init(e, t), Object.assign(e["~st
|
|
|
2802
2823
|
return this.check(...e);
|
|
2803
2824
|
},
|
|
2804
2825
|
clone(e, t) {
|
|
2805
|
-
return
|
|
2826
|
+
return M(this, e, t);
|
|
2806
2827
|
},
|
|
2807
2828
|
brand() {
|
|
2808
2829
|
return this;
|
|
@@ -2811,64 +2832,64 @@ var H = /*@__PURE__*/ E("ZodType", (e, t) => (L.init(e, t), Object.assign(e["~st
|
|
|
2811
2832
|
return e.add(this, t), this;
|
|
2812
2833
|
},
|
|
2813
2834
|
refine(e, t) {
|
|
2814
|
-
return this.check(
|
|
2835
|
+
return this.check(Ho(e, t));
|
|
2815
2836
|
},
|
|
2816
2837
|
superRefine(e, t) {
|
|
2817
|
-
return this.check(
|
|
2838
|
+
return this.check(Uo(e, t));
|
|
2818
2839
|
},
|
|
2819
2840
|
overwrite(e) {
|
|
2820
|
-
return this.check(/* @__PURE__ */
|
|
2841
|
+
return this.check(/* @__PURE__ */ Ei(e));
|
|
2821
2842
|
},
|
|
2822
2843
|
optional() {
|
|
2823
|
-
return
|
|
2844
|
+
return wo(this);
|
|
2824
2845
|
},
|
|
2825
2846
|
exactOptional() {
|
|
2826
|
-
return
|
|
2847
|
+
return Eo(this);
|
|
2827
2848
|
},
|
|
2828
2849
|
nullable() {
|
|
2829
|
-
return
|
|
2850
|
+
return Oo(this);
|
|
2830
2851
|
},
|
|
2831
2852
|
nullish() {
|
|
2832
|
-
return
|
|
2853
|
+
return wo(Oo(this));
|
|
2833
2854
|
},
|
|
2834
2855
|
nonoptional(e) {
|
|
2835
|
-
return
|
|
2856
|
+
return Po(this, e);
|
|
2836
2857
|
},
|
|
2837
2858
|
array() {
|
|
2838
|
-
return
|
|
2859
|
+
return K(this);
|
|
2839
2860
|
},
|
|
2840
2861
|
or(e) {
|
|
2841
|
-
return
|
|
2862
|
+
return po([this, e]);
|
|
2842
2863
|
},
|
|
2843
2864
|
and(e) {
|
|
2844
|
-
return
|
|
2865
|
+
return ho(this, e);
|
|
2845
2866
|
},
|
|
2846
2867
|
transform(e) {
|
|
2847
|
-
return
|
|
2868
|
+
return Ro(this, So(e));
|
|
2848
2869
|
},
|
|
2849
2870
|
default(e) {
|
|
2850
|
-
return
|
|
2871
|
+
return Ao(this, e);
|
|
2851
2872
|
},
|
|
2852
2873
|
prefault(e) {
|
|
2853
|
-
return
|
|
2874
|
+
return Mo(this, e);
|
|
2854
2875
|
},
|
|
2855
2876
|
catch(e) {
|
|
2856
|
-
return
|
|
2877
|
+
return Io(this, e);
|
|
2857
2878
|
},
|
|
2858
2879
|
pipe(e) {
|
|
2859
|
-
return
|
|
2880
|
+
return Ro(this, e);
|
|
2860
2881
|
},
|
|
2861
2882
|
readonly() {
|
|
2862
|
-
return
|
|
2883
|
+
return Bo(this);
|
|
2863
2884
|
},
|
|
2864
2885
|
describe(e) {
|
|
2865
2886
|
let t = this.clone();
|
|
2866
|
-
return
|
|
2887
|
+
return Mr.add(t, { description: e }), t;
|
|
2867
2888
|
},
|
|
2868
2889
|
meta(...e) {
|
|
2869
|
-
if (e.length === 0) return
|
|
2890
|
+
if (e.length === 0) return Mr.get(this);
|
|
2870
2891
|
let t = this.clone();
|
|
2871
|
-
return
|
|
2892
|
+
return Mr.add(t, e[0]), t;
|
|
2872
2893
|
},
|
|
2873
2894
|
isOptional() {
|
|
2874
2895
|
return this.safeParse(void 0).success;
|
|
@@ -2881,148 +2902,148 @@ var H = /*@__PURE__*/ E("ZodType", (e, t) => (L.init(e, t), Object.assign(e["~st
|
|
|
2881
2902
|
}
|
|
2882
2903
|
}), Object.defineProperty(e, "description", {
|
|
2883
2904
|
get() {
|
|
2884
|
-
return
|
|
2905
|
+
return Mr.get(e)?.description;
|
|
2885
2906
|
},
|
|
2886
2907
|
configurable: !0
|
|
2887
|
-
}), e)),
|
|
2888
|
-
|
|
2908
|
+
}), e)), Ma = /*@__PURE__*/ E("_ZodString", (e, t) => {
|
|
2909
|
+
vn.init(e, t), V.init(e, t), e._zod.processJSONSchema = (t, n, r) => Hi(e, t, n, r);
|
|
2889
2910
|
let n = e._zod.bag;
|
|
2890
|
-
e.format = n.format ?? null, e.minLength = n.minimum ?? null, e.maxLength = n.maximum ?? null,
|
|
2911
|
+
e.format = n.format ?? null, e.minLength = n.minimum ?? null, e.maxLength = n.maximum ?? null, ja(e, "_ZodString", {
|
|
2891
2912
|
regex(...e) {
|
|
2892
|
-
return this.check(/* @__PURE__ */
|
|
2913
|
+
return this.check(/* @__PURE__ */ bi(...e));
|
|
2893
2914
|
},
|
|
2894
2915
|
includes(...e) {
|
|
2895
|
-
return this.check(/* @__PURE__ */
|
|
2916
|
+
return this.check(/* @__PURE__ */ Ci(...e));
|
|
2896
2917
|
},
|
|
2897
2918
|
startsWith(...e) {
|
|
2898
|
-
return this.check(/* @__PURE__ */
|
|
2919
|
+
return this.check(/* @__PURE__ */ wi(...e));
|
|
2899
2920
|
},
|
|
2900
2921
|
endsWith(...e) {
|
|
2901
|
-
return this.check(/* @__PURE__ */
|
|
2922
|
+
return this.check(/* @__PURE__ */ Ti(...e));
|
|
2902
2923
|
},
|
|
2903
2924
|
min(...e) {
|
|
2904
|
-
return this.check(/* @__PURE__ */
|
|
2925
|
+
return this.check(/* @__PURE__ */ vi(...e));
|
|
2905
2926
|
},
|
|
2906
2927
|
max(...e) {
|
|
2907
|
-
return this.check(/* @__PURE__ */
|
|
2928
|
+
return this.check(/* @__PURE__ */ _i(...e));
|
|
2908
2929
|
},
|
|
2909
2930
|
length(...e) {
|
|
2910
|
-
return this.check(/* @__PURE__ */
|
|
2931
|
+
return this.check(/* @__PURE__ */ yi(...e));
|
|
2911
2932
|
},
|
|
2912
2933
|
nonempty(...e) {
|
|
2913
|
-
return this.check(/* @__PURE__ */
|
|
2934
|
+
return this.check(/* @__PURE__ */ vi(1, ...e));
|
|
2914
2935
|
},
|
|
2915
2936
|
lowercase(e) {
|
|
2916
|
-
return this.check(/* @__PURE__ */
|
|
2937
|
+
return this.check(/* @__PURE__ */ xi(e));
|
|
2917
2938
|
},
|
|
2918
2939
|
uppercase(e) {
|
|
2919
|
-
return this.check(/* @__PURE__ */
|
|
2940
|
+
return this.check(/* @__PURE__ */ Si(e));
|
|
2920
2941
|
},
|
|
2921
2942
|
trim() {
|
|
2922
|
-
return this.check(/* @__PURE__ */
|
|
2943
|
+
return this.check(/* @__PURE__ */ Oi());
|
|
2923
2944
|
},
|
|
2924
2945
|
normalize(...e) {
|
|
2925
|
-
return this.check(/* @__PURE__ */
|
|
2946
|
+
return this.check(/* @__PURE__ */ Di(...e));
|
|
2926
2947
|
},
|
|
2927
2948
|
toLowerCase() {
|
|
2928
|
-
return this.check(/* @__PURE__ */
|
|
2949
|
+
return this.check(/* @__PURE__ */ ki());
|
|
2929
2950
|
},
|
|
2930
2951
|
toUpperCase() {
|
|
2931
|
-
return this.check(/* @__PURE__ */
|
|
2952
|
+
return this.check(/* @__PURE__ */ Ai());
|
|
2932
2953
|
},
|
|
2933
2954
|
slugify() {
|
|
2934
|
-
return this.check(/* @__PURE__ */
|
|
2955
|
+
return this.check(/* @__PURE__ */ ji());
|
|
2935
2956
|
}
|
|
2936
2957
|
});
|
|
2937
|
-
}),
|
|
2938
|
-
|
|
2958
|
+
}), Na = /*@__PURE__*/ E("ZodString", (e, t) => {
|
|
2959
|
+
vn.init(e, t), Ma.init(e, t), e.email = (t) => e.check(/* @__PURE__ */ Pr(Pa, t)), e.url = (t) => e.check(/* @__PURE__ */ Br(La, t)), e.jwt = (t) => e.check(/* @__PURE__ */ ti(Qa, t)), e.emoji = (t) => e.check(/* @__PURE__ */ Vr(Ra, t)), e.guid = (t) => e.check(/* @__PURE__ */ Fr(Fa, t)), e.uuid = (t) => e.check(/* @__PURE__ */ Ir(Ia, t)), e.uuidv4 = (t) => e.check(/* @__PURE__ */ Lr(Ia, t)), e.uuidv6 = (t) => e.check(/* @__PURE__ */ Rr(Ia, t)), e.uuidv7 = (t) => e.check(/* @__PURE__ */ zr(Ia, t)), e.nanoid = (t) => e.check(/* @__PURE__ */ Hr(za, t)), e.guid = (t) => e.check(/* @__PURE__ */ Fr(Fa, t)), e.cuid = (t) => e.check(/* @__PURE__ */ Ur(Ba, t)), e.cuid2 = (t) => e.check(/* @__PURE__ */ Wr(Va, t)), e.ulid = (t) => e.check(/* @__PURE__ */ Gr(Ha, t)), e.base64 = (t) => e.check(/* @__PURE__ */ Qr(Ya, t)), e.base64url = (t) => e.check(/* @__PURE__ */ $r(Xa, t)), e.xid = (t) => e.check(/* @__PURE__ */ Kr(Ua, t)), e.ksuid = (t) => e.check(/* @__PURE__ */ qr(Wa, t)), e.ipv4 = (t) => e.check(/* @__PURE__ */ Jr(Ga, t)), e.ipv6 = (t) => e.check(/* @__PURE__ */ Yr(Ka, t)), e.cidrv4 = (t) => e.check(/* @__PURE__ */ Xr(qa, t)), e.cidrv6 = (t) => e.check(/* @__PURE__ */ Zr(Ja, t)), e.e164 = (t) => e.check(/* @__PURE__ */ ei(Za, t)), e.datetime = (t) => e.check(da(t)), e.date = (t) => e.check(pa(t)), e.time = (t) => e.check(ha(t)), e.duration = (t) => e.check(_a(t));
|
|
2939
2960
|
});
|
|
2940
|
-
function
|
|
2941
|
-
return /* @__PURE__ */
|
|
2942
|
-
}
|
|
2943
|
-
var
|
|
2944
|
-
|
|
2945
|
-
}),
|
|
2946
|
-
|
|
2947
|
-
}),
|
|
2948
|
-
|
|
2949
|
-
}),
|
|
2950
|
-
|
|
2951
|
-
}),
|
|
2952
|
-
|
|
2953
|
-
}),
|
|
2954
|
-
|
|
2955
|
-
}),
|
|
2956
|
-
|
|
2957
|
-
}),
|
|
2958
|
-
|
|
2959
|
-
}),
|
|
2960
|
-
|
|
2961
|
-
}),
|
|
2962
|
-
|
|
2963
|
-
}),
|
|
2964
|
-
|
|
2965
|
-
}),
|
|
2966
|
-
|
|
2967
|
-
}),
|
|
2968
|
-
|
|
2969
|
-
}),
|
|
2970
|
-
|
|
2971
|
-
}),
|
|
2972
|
-
|
|
2973
|
-
}),
|
|
2974
|
-
|
|
2975
|
-
}),
|
|
2976
|
-
|
|
2977
|
-
}),
|
|
2978
|
-
|
|
2979
|
-
}),
|
|
2980
|
-
|
|
2981
|
-
}),
|
|
2982
|
-
|
|
2983
|
-
}),
|
|
2984
|
-
|
|
2961
|
+
function H(e) {
|
|
2962
|
+
return /* @__PURE__ */ Nr(Na, e);
|
|
2963
|
+
}
|
|
2964
|
+
var U = /*@__PURE__*/ E("ZodStringFormat", (e, t) => {
|
|
2965
|
+
L.init(e, t), Ma.init(e, t);
|
|
2966
|
+
}), Pa = /*@__PURE__*/ E("ZodEmail", (e, t) => {
|
|
2967
|
+
xn.init(e, t), U.init(e, t);
|
|
2968
|
+
}), Fa = /*@__PURE__*/ E("ZodGUID", (e, t) => {
|
|
2969
|
+
yn.init(e, t), U.init(e, t);
|
|
2970
|
+
}), Ia = /*@__PURE__*/ E("ZodUUID", (e, t) => {
|
|
2971
|
+
bn.init(e, t), U.init(e, t);
|
|
2972
|
+
}), La = /*@__PURE__*/ E("ZodURL", (e, t) => {
|
|
2973
|
+
Sn.init(e, t), U.init(e, t);
|
|
2974
|
+
}), Ra = /*@__PURE__*/ E("ZodEmoji", (e, t) => {
|
|
2975
|
+
Cn.init(e, t), U.init(e, t);
|
|
2976
|
+
}), za = /*@__PURE__*/ E("ZodNanoID", (e, t) => {
|
|
2977
|
+
wn.init(e, t), U.init(e, t);
|
|
2978
|
+
}), Ba = /*@__PURE__*/ E("ZodCUID", (e, t) => {
|
|
2979
|
+
Tn.init(e, t), U.init(e, t);
|
|
2980
|
+
}), Va = /*@__PURE__*/ E("ZodCUID2", (e, t) => {
|
|
2981
|
+
En.init(e, t), U.init(e, t);
|
|
2982
|
+
}), Ha = /*@__PURE__*/ E("ZodULID", (e, t) => {
|
|
2983
|
+
Dn.init(e, t), U.init(e, t);
|
|
2984
|
+
}), Ua = /*@__PURE__*/ E("ZodXID", (e, t) => {
|
|
2985
|
+
On.init(e, t), U.init(e, t);
|
|
2986
|
+
}), Wa = /*@__PURE__*/ E("ZodKSUID", (e, t) => {
|
|
2987
|
+
kn.init(e, t), U.init(e, t);
|
|
2988
|
+
}), Ga = /*@__PURE__*/ E("ZodIPv4", (e, t) => {
|
|
2989
|
+
Pn.init(e, t), U.init(e, t);
|
|
2990
|
+
}), Ka = /*@__PURE__*/ E("ZodIPv6", (e, t) => {
|
|
2991
|
+
Fn.init(e, t), U.init(e, t);
|
|
2992
|
+
}), qa = /*@__PURE__*/ E("ZodCIDRv4", (e, t) => {
|
|
2993
|
+
In.init(e, t), U.init(e, t);
|
|
2994
|
+
}), Ja = /*@__PURE__*/ E("ZodCIDRv6", (e, t) => {
|
|
2995
|
+
Ln.init(e, t), U.init(e, t);
|
|
2996
|
+
}), Ya = /*@__PURE__*/ E("ZodBase64", (e, t) => {
|
|
2997
|
+
zn.init(e, t), U.init(e, t);
|
|
2998
|
+
}), Xa = /*@__PURE__*/ E("ZodBase64URL", (e, t) => {
|
|
2999
|
+
Vn.init(e, t), U.init(e, t);
|
|
3000
|
+
}), Za = /*@__PURE__*/ E("ZodE164", (e, t) => {
|
|
3001
|
+
Hn.init(e, t), U.init(e, t);
|
|
3002
|
+
}), Qa = /*@__PURE__*/ E("ZodJWT", (e, t) => {
|
|
3003
|
+
Wn.init(e, t), U.init(e, t);
|
|
3004
|
+
}), $a = /*@__PURE__*/ E("ZodNumber", (e, t) => {
|
|
3005
|
+
Gn.init(e, t), V.init(e, t), e._zod.processJSONSchema = (t, n, r) => Ui(e, t, n, r), ja(e, "ZodNumber", {
|
|
2985
3006
|
gt(e, t) {
|
|
2986
|
-
return this.check(/* @__PURE__ */
|
|
3007
|
+
return this.check(/* @__PURE__ */ mi(e, t));
|
|
2987
3008
|
},
|
|
2988
3009
|
gte(e, t) {
|
|
2989
|
-
return this.check(/* @__PURE__ */
|
|
3010
|
+
return this.check(/* @__PURE__ */ hi(e, t));
|
|
2990
3011
|
},
|
|
2991
3012
|
min(e, t) {
|
|
2992
|
-
return this.check(/* @__PURE__ */
|
|
3013
|
+
return this.check(/* @__PURE__ */ hi(e, t));
|
|
2993
3014
|
},
|
|
2994
3015
|
lt(e, t) {
|
|
2995
|
-
return this.check(/* @__PURE__ */
|
|
3016
|
+
return this.check(/* @__PURE__ */ fi(e, t));
|
|
2996
3017
|
},
|
|
2997
3018
|
lte(e, t) {
|
|
2998
|
-
return this.check(/* @__PURE__ */
|
|
3019
|
+
return this.check(/* @__PURE__ */ pi(e, t));
|
|
2999
3020
|
},
|
|
3000
3021
|
max(e, t) {
|
|
3001
|
-
return this.check(/* @__PURE__ */
|
|
3022
|
+
return this.check(/* @__PURE__ */ pi(e, t));
|
|
3002
3023
|
},
|
|
3003
3024
|
int(e) {
|
|
3004
|
-
return this.check(
|
|
3025
|
+
return this.check(to(e));
|
|
3005
3026
|
},
|
|
3006
3027
|
safe(e) {
|
|
3007
|
-
return this.check(
|
|
3028
|
+
return this.check(to(e));
|
|
3008
3029
|
},
|
|
3009
3030
|
positive(e) {
|
|
3010
|
-
return this.check(/* @__PURE__ */
|
|
3031
|
+
return this.check(/* @__PURE__ */ mi(0, e));
|
|
3011
3032
|
},
|
|
3012
3033
|
nonnegative(e) {
|
|
3013
|
-
return this.check(/* @__PURE__ */
|
|
3034
|
+
return this.check(/* @__PURE__ */ hi(0, e));
|
|
3014
3035
|
},
|
|
3015
3036
|
negative(e) {
|
|
3016
|
-
return this.check(/* @__PURE__ */
|
|
3037
|
+
return this.check(/* @__PURE__ */ fi(0, e));
|
|
3017
3038
|
},
|
|
3018
3039
|
nonpositive(e) {
|
|
3019
|
-
return this.check(/* @__PURE__ */
|
|
3040
|
+
return this.check(/* @__PURE__ */ pi(0, e));
|
|
3020
3041
|
},
|
|
3021
3042
|
multipleOf(e, t) {
|
|
3022
|
-
return this.check(/* @__PURE__ */
|
|
3043
|
+
return this.check(/* @__PURE__ */ gi(e, t));
|
|
3023
3044
|
},
|
|
3024
3045
|
step(e, t) {
|
|
3025
|
-
return this.check(/* @__PURE__ */
|
|
3046
|
+
return this.check(/* @__PURE__ */ gi(e, t));
|
|
3026
3047
|
},
|
|
3027
3048
|
finite() {
|
|
3028
3049
|
return this;
|
|
@@ -3031,65 +3052,65 @@ var W = /*@__PURE__*/ E("ZodStringFormat", (e, t) => {
|
|
|
3031
3052
|
let n = e._zod.bag;
|
|
3032
3053
|
e.minValue = Math.max(n.minimum ?? -Infinity, n.exclusiveMinimum ?? -Infinity) ?? null, e.maxValue = Math.min(n.maximum ?? Infinity, n.exclusiveMaximum ?? Infinity) ?? null, e.isInt = (n.format ?? "").includes("int") || Number.isSafeInteger(n.multipleOf ?? .5), e.isFinite = !0, e.format = n.format ?? null;
|
|
3033
3054
|
});
|
|
3034
|
-
function
|
|
3035
|
-
return /* @__PURE__ */
|
|
3055
|
+
function W(e) {
|
|
3056
|
+
return /* @__PURE__ */ oi($a, e);
|
|
3036
3057
|
}
|
|
3037
|
-
var
|
|
3038
|
-
|
|
3058
|
+
var eo = /*@__PURE__*/ E("ZodNumberFormat", (e, t) => {
|
|
3059
|
+
Kn.init(e, t), $a.init(e, t);
|
|
3039
3060
|
});
|
|
3040
|
-
function
|
|
3041
|
-
return /* @__PURE__ */
|
|
3061
|
+
function to(e) {
|
|
3062
|
+
return /* @__PURE__ */ si(eo, e);
|
|
3042
3063
|
}
|
|
3043
|
-
var
|
|
3044
|
-
|
|
3064
|
+
var no = /*@__PURE__*/ E("ZodBoolean", (e, t) => {
|
|
3065
|
+
qn.init(e, t), V.init(e, t), e._zod.processJSONSchema = (t, n, r) => Wi(e, t, n, r);
|
|
3045
3066
|
});
|
|
3046
|
-
function
|
|
3047
|
-
return /* @__PURE__ */
|
|
3067
|
+
function G(e) {
|
|
3068
|
+
return /* @__PURE__ */ ci(no, e);
|
|
3048
3069
|
}
|
|
3049
|
-
var
|
|
3050
|
-
|
|
3070
|
+
var ro = /*@__PURE__*/ E("ZodNull", (e, t) => {
|
|
3071
|
+
Jn.init(e, t), V.init(e, t), e._zod.processJSONSchema = (t, n, r) => Gi(e, t, n, r);
|
|
3051
3072
|
});
|
|
3052
|
-
function
|
|
3053
|
-
return /* @__PURE__ */
|
|
3073
|
+
function io(e) {
|
|
3074
|
+
return /* @__PURE__ */ li(ro, e);
|
|
3054
3075
|
}
|
|
3055
|
-
var
|
|
3056
|
-
|
|
3076
|
+
var ao = /*@__PURE__*/ E("ZodUnknown", (e, t) => {
|
|
3077
|
+
Yn.init(e, t), V.init(e, t), e._zod.processJSONSchema = (e, t, n) => void 0;
|
|
3057
3078
|
});
|
|
3058
|
-
function
|
|
3059
|
-
return /* @__PURE__ */
|
|
3079
|
+
function oo() {
|
|
3080
|
+
return /* @__PURE__ */ ui(ao);
|
|
3060
3081
|
}
|
|
3061
|
-
var
|
|
3062
|
-
|
|
3082
|
+
var so = /*@__PURE__*/ E("ZodNever", (e, t) => {
|
|
3083
|
+
Xn.init(e, t), V.init(e, t), e._zod.processJSONSchema = (t, n, r) => Ki(e, t, n, r);
|
|
3063
3084
|
});
|
|
3064
|
-
function
|
|
3065
|
-
return /* @__PURE__ */
|
|
3085
|
+
function co(e) {
|
|
3086
|
+
return /* @__PURE__ */ di(so, e);
|
|
3066
3087
|
}
|
|
3067
|
-
var
|
|
3068
|
-
|
|
3088
|
+
var lo = /*@__PURE__*/ E("ZodArray", (e, t) => {
|
|
3089
|
+
Qn.init(e, t), V.init(e, t), e._zod.processJSONSchema = (t, n, r) => Zi(e, t, n, r), e.element = t.element, ja(e, "ZodArray", {
|
|
3069
3090
|
min(e, t) {
|
|
3070
|
-
return this.check(/* @__PURE__ */
|
|
3091
|
+
return this.check(/* @__PURE__ */ vi(e, t));
|
|
3071
3092
|
},
|
|
3072
3093
|
nonempty(e) {
|
|
3073
|
-
return this.check(/* @__PURE__ */
|
|
3094
|
+
return this.check(/* @__PURE__ */ vi(1, e));
|
|
3074
3095
|
},
|
|
3075
3096
|
max(e, t) {
|
|
3076
|
-
return this.check(/* @__PURE__ */
|
|
3097
|
+
return this.check(/* @__PURE__ */ _i(e, t));
|
|
3077
3098
|
},
|
|
3078
3099
|
length(e, t) {
|
|
3079
|
-
return this.check(/* @__PURE__ */
|
|
3100
|
+
return this.check(/* @__PURE__ */ yi(e, t));
|
|
3080
3101
|
},
|
|
3081
3102
|
unwrap() {
|
|
3082
3103
|
return this.element;
|
|
3083
3104
|
}
|
|
3084
3105
|
});
|
|
3085
3106
|
});
|
|
3086
|
-
function
|
|
3087
|
-
return /* @__PURE__ */
|
|
3107
|
+
function K(e, t) {
|
|
3108
|
+
return /* @__PURE__ */ Mi(lo, e, t);
|
|
3088
3109
|
}
|
|
3089
|
-
var
|
|
3090
|
-
|
|
3110
|
+
var uo = /*@__PURE__*/ E("ZodObject", (e, t) => {
|
|
3111
|
+
rr.init(e, t), V.init(e, t), e._zod.processJSONSchema = (t, n, r) => Qi(e, t, n, r), O(e, "shape", () => t.shape), ja(e, "ZodObject", {
|
|
3091
3112
|
keyof() {
|
|
3092
|
-
return
|
|
3113
|
+
return J(Object.keys(this._zod.def.shape));
|
|
3093
3114
|
},
|
|
3094
3115
|
catchall(e) {
|
|
3095
3116
|
return this.clone({
|
|
@@ -3100,19 +3121,19 @@ var co = /*@__PURE__*/ E("ZodObject", (e, t) => {
|
|
|
3100
3121
|
passthrough() {
|
|
3101
3122
|
return this.clone({
|
|
3102
3123
|
...this._zod.def,
|
|
3103
|
-
catchall:
|
|
3124
|
+
catchall: oo()
|
|
3104
3125
|
});
|
|
3105
3126
|
},
|
|
3106
3127
|
loose() {
|
|
3107
3128
|
return this.clone({
|
|
3108
3129
|
...this._zod.def,
|
|
3109
|
-
catchall:
|
|
3130
|
+
catchall: oo()
|
|
3110
3131
|
});
|
|
3111
3132
|
},
|
|
3112
3133
|
strict() {
|
|
3113
3134
|
return this.clone({
|
|
3114
3135
|
...this._zod.def,
|
|
3115
|
-
catchall:
|
|
3136
|
+
catchall: co()
|
|
3116
3137
|
});
|
|
3117
3138
|
},
|
|
3118
3139
|
strip() {
|
|
@@ -3137,393 +3158,410 @@ var co = /*@__PURE__*/ E("ZodObject", (e, t) => {
|
|
|
3137
3158
|
return We(this, e);
|
|
3138
3159
|
},
|
|
3139
3160
|
partial(...e) {
|
|
3140
|
-
return Je(
|
|
3161
|
+
return Je(Co, this, e[0]);
|
|
3141
3162
|
},
|
|
3142
3163
|
required(...e) {
|
|
3143
|
-
return Ye(
|
|
3164
|
+
return Ye(No, this, e[0]);
|
|
3144
3165
|
}
|
|
3145
3166
|
});
|
|
3146
3167
|
});
|
|
3147
|
-
function
|
|
3148
|
-
return new
|
|
3168
|
+
function q(e, t) {
|
|
3169
|
+
return new uo({
|
|
3149
3170
|
type: "object",
|
|
3150
3171
|
shape: e ?? {},
|
|
3151
|
-
...
|
|
3172
|
+
...N(t)
|
|
3152
3173
|
});
|
|
3153
3174
|
}
|
|
3154
|
-
var
|
|
3155
|
-
|
|
3175
|
+
var fo = /*@__PURE__*/ E("ZodUnion", (e, t) => {
|
|
3176
|
+
ar.init(e, t), V.init(e, t), e._zod.processJSONSchema = (t, n, r) => $i(e, t, n, r), e.options = t.options;
|
|
3156
3177
|
});
|
|
3157
|
-
function
|
|
3158
|
-
return new
|
|
3178
|
+
function po(e, t) {
|
|
3179
|
+
return new fo({
|
|
3159
3180
|
type: "union",
|
|
3160
3181
|
options: e,
|
|
3161
|
-
...
|
|
3182
|
+
...N(t)
|
|
3162
3183
|
});
|
|
3163
3184
|
}
|
|
3164
|
-
var
|
|
3165
|
-
|
|
3185
|
+
var mo = /*@__PURE__*/ E("ZodIntersection", (e, t) => {
|
|
3186
|
+
or.init(e, t), V.init(e, t), e._zod.processJSONSchema = (t, n, r) => ea(e, t, n, r);
|
|
3166
3187
|
});
|
|
3167
|
-
function
|
|
3168
|
-
return new
|
|
3188
|
+
function ho(e, t) {
|
|
3189
|
+
return new mo({
|
|
3169
3190
|
type: "intersection",
|
|
3170
3191
|
left: e,
|
|
3171
3192
|
right: t
|
|
3172
3193
|
});
|
|
3173
3194
|
}
|
|
3174
|
-
var
|
|
3175
|
-
|
|
3195
|
+
var go = /*@__PURE__*/ E("ZodRecord", (e, t) => {
|
|
3196
|
+
lr.init(e, t), V.init(e, t), e._zod.processJSONSchema = (t, n, r) => ta(e, t, n, r), e.keyType = t.keyType, e.valueType = t.valueType;
|
|
3176
3197
|
});
|
|
3177
|
-
function
|
|
3178
|
-
return !t || !t._zod ? new
|
|
3198
|
+
function _o(e, t, n) {
|
|
3199
|
+
return !t || !t._zod ? new go({
|
|
3179
3200
|
type: "record",
|
|
3180
|
-
keyType:
|
|
3201
|
+
keyType: H(),
|
|
3181
3202
|
valueType: e,
|
|
3182
|
-
...
|
|
3183
|
-
}) : new
|
|
3203
|
+
...N(t)
|
|
3204
|
+
}) : new go({
|
|
3184
3205
|
type: "record",
|
|
3185
3206
|
keyType: e,
|
|
3186
3207
|
valueType: t,
|
|
3187
|
-
...
|
|
3208
|
+
...N(n)
|
|
3188
3209
|
});
|
|
3189
3210
|
}
|
|
3190
|
-
var
|
|
3191
|
-
|
|
3211
|
+
var vo = /*@__PURE__*/ E("ZodEnum", (e, t) => {
|
|
3212
|
+
ur.init(e, t), V.init(e, t), e._zod.processJSONSchema = (t, n, r) => qi(e, t, n, r), e.enum = t.entries, e.options = Object.values(t.entries);
|
|
3192
3213
|
let n = new Set(Object.keys(t.entries));
|
|
3193
3214
|
e.extract = (e, r) => {
|
|
3194
3215
|
let i = {};
|
|
3195
3216
|
for (let r of e) if (n.has(r)) i[r] = t.entries[r];
|
|
3196
3217
|
else throw Error(`Key ${r} not found in enum`);
|
|
3197
|
-
return new
|
|
3218
|
+
return new vo({
|
|
3198
3219
|
...t,
|
|
3199
3220
|
checks: [],
|
|
3200
|
-
...
|
|
3221
|
+
...N(r),
|
|
3201
3222
|
entries: i
|
|
3202
3223
|
});
|
|
3203
3224
|
}, e.exclude = (e, r) => {
|
|
3204
3225
|
let i = { ...t.entries };
|
|
3205
3226
|
for (let t of e) if (n.has(t)) delete i[t];
|
|
3206
3227
|
else throw Error(`Key ${t} not found in enum`);
|
|
3207
|
-
return new
|
|
3228
|
+
return new vo({
|
|
3208
3229
|
...t,
|
|
3209
3230
|
checks: [],
|
|
3210
|
-
...
|
|
3231
|
+
...N(r),
|
|
3211
3232
|
entries: i
|
|
3212
3233
|
});
|
|
3213
3234
|
};
|
|
3214
3235
|
});
|
|
3215
|
-
function
|
|
3216
|
-
return new
|
|
3236
|
+
function J(e, t) {
|
|
3237
|
+
return new vo({
|
|
3217
3238
|
type: "enum",
|
|
3218
3239
|
entries: Array.isArray(e) ? Object.fromEntries(e.map((e) => [e, e])) : e,
|
|
3219
|
-
...
|
|
3240
|
+
...N(t)
|
|
3220
3241
|
});
|
|
3221
3242
|
}
|
|
3222
|
-
var
|
|
3223
|
-
|
|
3243
|
+
var yo = /*@__PURE__*/ E("ZodLiteral", (e, t) => {
|
|
3244
|
+
dr.init(e, t), V.init(e, t), e._zod.processJSONSchema = (t, n, r) => Ji(e, t, n, r), e.values = new Set(t.values), Object.defineProperty(e, "value", { get() {
|
|
3224
3245
|
if (t.values.length > 1) throw Error("This schema contains multiple valid literal values. Use `.values` instead.");
|
|
3225
3246
|
return t.values[0];
|
|
3226
3247
|
} });
|
|
3227
3248
|
});
|
|
3228
|
-
function
|
|
3229
|
-
return new
|
|
3249
|
+
function bo(e, t) {
|
|
3250
|
+
return new yo({
|
|
3230
3251
|
type: "literal",
|
|
3231
3252
|
values: Array.isArray(e) ? e : [e],
|
|
3232
|
-
...
|
|
3253
|
+
...N(t)
|
|
3233
3254
|
});
|
|
3234
3255
|
}
|
|
3235
|
-
var
|
|
3236
|
-
|
|
3237
|
-
if (r.direction === "backward") throw new
|
|
3256
|
+
var xo = /*@__PURE__*/ E("ZodTransform", (e, t) => {
|
|
3257
|
+
fr.init(e, t), V.init(e, t), e._zod.processJSONSchema = (t, n, r) => Xi(e, t, n, r), e._zod.parse = (n, r) => {
|
|
3258
|
+
if (r.direction === "backward") throw new we(e.constructor.name);
|
|
3238
3259
|
n.addIssue = (r) => {
|
|
3239
|
-
if (typeof r == "string") n.issues.push(
|
|
3260
|
+
if (typeof r == "string") n.issues.push(tt(r, n.value, t));
|
|
3240
3261
|
else {
|
|
3241
3262
|
let t = r;
|
|
3242
|
-
t.fatal && (t.continue = !1), t.code ??= "custom", t.input ??= n.value, t.inst ??= e, n.issues.push(
|
|
3263
|
+
t.fatal && (t.continue = !1), t.code ??= "custom", t.input ??= n.value, t.inst ??= e, n.issues.push(tt(t));
|
|
3243
3264
|
}
|
|
3244
3265
|
};
|
|
3245
3266
|
let i = t.transform(n.value, n);
|
|
3246
3267
|
return i instanceof Promise ? i.then((e) => (n.value = e, n.fallback = !0, n)) : (n.value = i, n.fallback = !0, n);
|
|
3247
3268
|
};
|
|
3248
3269
|
});
|
|
3249
|
-
function
|
|
3250
|
-
return new
|
|
3270
|
+
function So(e) {
|
|
3271
|
+
return new xo({
|
|
3251
3272
|
type: "transform",
|
|
3252
3273
|
transform: e
|
|
3253
3274
|
});
|
|
3254
3275
|
}
|
|
3255
|
-
var
|
|
3256
|
-
|
|
3276
|
+
var Co = /*@__PURE__*/ E("ZodOptional", (e, t) => {
|
|
3277
|
+
mr.init(e, t), V.init(e, t), e._zod.processJSONSchema = (t, n, r) => la(e, t, n, r), e.unwrap = () => e._zod.def.innerType;
|
|
3257
3278
|
});
|
|
3258
|
-
function
|
|
3259
|
-
return new
|
|
3279
|
+
function wo(e) {
|
|
3280
|
+
return new Co({
|
|
3260
3281
|
type: "optional",
|
|
3261
3282
|
innerType: e
|
|
3262
3283
|
});
|
|
3263
3284
|
}
|
|
3264
|
-
var
|
|
3265
|
-
|
|
3285
|
+
var To = /*@__PURE__*/ E("ZodExactOptional", (e, t) => {
|
|
3286
|
+
hr.init(e, t), V.init(e, t), e._zod.processJSONSchema = (t, n, r) => la(e, t, n, r), e.unwrap = () => e._zod.def.innerType;
|
|
3266
3287
|
});
|
|
3267
|
-
function
|
|
3268
|
-
return new
|
|
3288
|
+
function Eo(e) {
|
|
3289
|
+
return new To({
|
|
3269
3290
|
type: "optional",
|
|
3270
3291
|
innerType: e
|
|
3271
3292
|
});
|
|
3272
3293
|
}
|
|
3273
|
-
var
|
|
3274
|
-
|
|
3294
|
+
var Do = /*@__PURE__*/ E("ZodNullable", (e, t) => {
|
|
3295
|
+
gr.init(e, t), V.init(e, t), e._zod.processJSONSchema = (t, n, r) => na(e, t, n, r), e.unwrap = () => e._zod.def.innerType;
|
|
3275
3296
|
});
|
|
3276
|
-
function
|
|
3277
|
-
return new
|
|
3297
|
+
function Oo(e) {
|
|
3298
|
+
return new Do({
|
|
3278
3299
|
type: "nullable",
|
|
3279
3300
|
innerType: e
|
|
3280
3301
|
});
|
|
3281
3302
|
}
|
|
3282
|
-
var
|
|
3283
|
-
|
|
3303
|
+
var ko = /*@__PURE__*/ E("ZodDefault", (e, t) => {
|
|
3304
|
+
_r.init(e, t), V.init(e, t), e._zod.processJSONSchema = (t, n, r) => ia(e, t, n, r), e.unwrap = () => e._zod.def.innerType, e.removeDefault = e.unwrap;
|
|
3284
3305
|
});
|
|
3285
|
-
function
|
|
3286
|
-
return new
|
|
3306
|
+
function Ao(e, t) {
|
|
3307
|
+
return new ko({
|
|
3287
3308
|
type: "default",
|
|
3288
3309
|
innerType: e,
|
|
3289
3310
|
get defaultValue() {
|
|
3290
|
-
return typeof t == "function" ? t() :
|
|
3311
|
+
return typeof t == "function" ? t() : ze(t);
|
|
3291
3312
|
}
|
|
3292
3313
|
});
|
|
3293
3314
|
}
|
|
3294
|
-
var
|
|
3295
|
-
|
|
3315
|
+
var jo = /*@__PURE__*/ E("ZodPrefault", (e, t) => {
|
|
3316
|
+
yr.init(e, t), V.init(e, t), e._zod.processJSONSchema = (t, n, r) => aa(e, t, n, r), e.unwrap = () => e._zod.def.innerType;
|
|
3296
3317
|
});
|
|
3297
|
-
function
|
|
3298
|
-
return new
|
|
3318
|
+
function Mo(e, t) {
|
|
3319
|
+
return new jo({
|
|
3299
3320
|
type: "prefault",
|
|
3300
3321
|
innerType: e,
|
|
3301
3322
|
get defaultValue() {
|
|
3302
|
-
return typeof t == "function" ? t() :
|
|
3323
|
+
return typeof t == "function" ? t() : ze(t);
|
|
3303
3324
|
}
|
|
3304
3325
|
});
|
|
3305
3326
|
}
|
|
3306
|
-
var
|
|
3307
|
-
|
|
3327
|
+
var No = /*@__PURE__*/ E("ZodNonOptional", (e, t) => {
|
|
3328
|
+
br.init(e, t), V.init(e, t), e._zod.processJSONSchema = (t, n, r) => ra(e, t, n, r), e.unwrap = () => e._zod.def.innerType;
|
|
3308
3329
|
});
|
|
3309
|
-
function
|
|
3310
|
-
return new
|
|
3330
|
+
function Po(e, t) {
|
|
3331
|
+
return new No({
|
|
3311
3332
|
type: "nonoptional",
|
|
3312
3333
|
innerType: e,
|
|
3313
|
-
...
|
|
3334
|
+
...N(t)
|
|
3314
3335
|
});
|
|
3315
3336
|
}
|
|
3316
|
-
var
|
|
3317
|
-
|
|
3337
|
+
var Fo = /*@__PURE__*/ E("ZodCatch", (e, t) => {
|
|
3338
|
+
Sr.init(e, t), V.init(e, t), e._zod.processJSONSchema = (t, n, r) => oa(e, t, n, r), e.unwrap = () => e._zod.def.innerType, e.removeCatch = e.unwrap;
|
|
3318
3339
|
});
|
|
3319
|
-
function
|
|
3320
|
-
return new
|
|
3340
|
+
function Io(e, t) {
|
|
3341
|
+
return new Fo({
|
|
3321
3342
|
type: "catch",
|
|
3322
3343
|
innerType: e,
|
|
3323
3344
|
catchValue: typeof t == "function" ? t : () => t
|
|
3324
3345
|
});
|
|
3325
3346
|
}
|
|
3326
|
-
var
|
|
3327
|
-
|
|
3347
|
+
var Lo = /*@__PURE__*/ E("ZodPipe", (e, t) => {
|
|
3348
|
+
Cr.init(e, t), V.init(e, t), e._zod.processJSONSchema = (t, n, r) => sa(e, t, n, r), e.in = t.in, e.out = t.out;
|
|
3328
3349
|
});
|
|
3329
|
-
function
|
|
3330
|
-
return new
|
|
3350
|
+
function Ro(e, t) {
|
|
3351
|
+
return new Lo({
|
|
3331
3352
|
type: "pipe",
|
|
3332
3353
|
in: e,
|
|
3333
3354
|
out: t
|
|
3334
3355
|
});
|
|
3335
3356
|
}
|
|
3336
|
-
var
|
|
3337
|
-
|
|
3357
|
+
var zo = /*@__PURE__*/ E("ZodReadonly", (e, t) => {
|
|
3358
|
+
Tr.init(e, t), V.init(e, t), e._zod.processJSONSchema = (t, n, r) => ca(e, t, n, r), e.unwrap = () => e._zod.def.innerType;
|
|
3338
3359
|
});
|
|
3339
|
-
function
|
|
3340
|
-
return new
|
|
3360
|
+
function Bo(e) {
|
|
3361
|
+
return new zo({
|
|
3341
3362
|
type: "readonly",
|
|
3342
3363
|
innerType: e
|
|
3343
3364
|
});
|
|
3344
3365
|
}
|
|
3345
|
-
var
|
|
3346
|
-
|
|
3366
|
+
var Vo = /*@__PURE__*/ E("ZodCustom", (e, t) => {
|
|
3367
|
+
Dr.init(e, t), V.init(e, t), e._zod.processJSONSchema = (t, n, r) => Yi(e, t, n, r);
|
|
3347
3368
|
});
|
|
3348
|
-
function
|
|
3349
|
-
return /* @__PURE__ */
|
|
3369
|
+
function Ho(e, t = {}) {
|
|
3370
|
+
return /* @__PURE__ */ Ni(Vo, e, t);
|
|
3350
3371
|
}
|
|
3351
|
-
function
|
|
3352
|
-
return /* @__PURE__ */
|
|
3372
|
+
function Uo(e, t) {
|
|
3373
|
+
return /* @__PURE__ */ Pi(e, t);
|
|
3353
3374
|
}
|
|
3354
3375
|
//#endregion
|
|
3355
3376
|
//#region src/ccu/ccu-schemas.ts
|
|
3356
|
-
var Y =
|
|
3357
|
-
integrationId:
|
|
3358
|
-
name:
|
|
3359
|
-
connected:
|
|
3360
|
-
}),
|
|
3361
|
-
version:
|
|
3362
|
-
product:
|
|
3363
|
-
productFamily:
|
|
3377
|
+
var Y = q({ integrationId: H().min(1) }), X = G(), Wo = q({
|
|
3378
|
+
integrationId: H(),
|
|
3379
|
+
name: H(),
|
|
3380
|
+
connected: G()
|
|
3381
|
+
}), Go = q({
|
|
3382
|
+
version: H().nullable(),
|
|
3383
|
+
product: H().nullable(),
|
|
3384
|
+
productFamily: J([
|
|
3364
3385
|
"ccu3",
|
|
3365
3386
|
"openccu",
|
|
3366
3387
|
"unknown"
|
|
3367
3388
|
]),
|
|
3368
|
-
platform:
|
|
3369
|
-
serial:
|
|
3370
|
-
hostname:
|
|
3371
|
-
}),
|
|
3372
|
-
address:
|
|
3373
|
-
description:
|
|
3374
|
-
dutyCycle:
|
|
3375
|
-
connected:
|
|
3376
|
-
isDefault:
|
|
3377
|
-
firmware:
|
|
3378
|
-
type:
|
|
3379
|
-
}),
|
|
3380
|
-
name:
|
|
3381
|
-
port:
|
|
3382
|
-
info:
|
|
3383
|
-
connected:
|
|
3384
|
-
dutyCycle:
|
|
3385
|
-
firmware:
|
|
3386
|
-
type:
|
|
3387
|
-
gateways:
|
|
3388
|
-
}),
|
|
3389
|
-
info:
|
|
3390
|
-
infoError:
|
|
3391
|
-
interfaces:
|
|
3392
|
-
interfacesError:
|
|
3393
|
-
}),
|
|
3394
|
-
messages: q(
|
|
3395
|
-
id:
|
|
3396
|
-
name:
|
|
3397
|
-
address:
|
|
3398
|
-
channel:
|
|
3399
|
-
type:
|
|
3400
|
-
timestamp:
|
|
3401
|
-
acknowledgeable:
|
|
3389
|
+
platform: H().nullable(),
|
|
3390
|
+
serial: H().nullable(),
|
|
3391
|
+
hostname: H().nullable()
|
|
3392
|
+
}), Ko = q({
|
|
3393
|
+
address: H(),
|
|
3394
|
+
description: H().nullable(),
|
|
3395
|
+
dutyCycle: W().nullable(),
|
|
3396
|
+
connected: G().nullable(),
|
|
3397
|
+
isDefault: G(),
|
|
3398
|
+
firmware: H().nullable(),
|
|
3399
|
+
type: H().nullable()
|
|
3400
|
+
}), qo = q({
|
|
3401
|
+
name: H(),
|
|
3402
|
+
port: W().nullable(),
|
|
3403
|
+
info: H().nullable(),
|
|
3404
|
+
connected: G().nullable(),
|
|
3405
|
+
dutyCycle: W().nullable(),
|
|
3406
|
+
firmware: H().nullable(),
|
|
3407
|
+
type: H().nullable(),
|
|
3408
|
+
gateways: K(Ko)
|
|
3409
|
+
}), Jo = q({
|
|
3410
|
+
info: Go.nullable(),
|
|
3411
|
+
infoError: H().nullable(),
|
|
3412
|
+
interfaces: K(qo),
|
|
3413
|
+
interfacesError: H().nullable()
|
|
3414
|
+
}), Yo = q({
|
|
3415
|
+
messages: K(q({
|
|
3416
|
+
id: H(),
|
|
3417
|
+
name: H().nullable(),
|
|
3418
|
+
address: H().nullable(),
|
|
3419
|
+
channel: W().nullable(),
|
|
3420
|
+
type: H().nullable(),
|
|
3421
|
+
timestamp: W().nullable(),
|
|
3422
|
+
acknowledgeable: G()
|
|
3402
3423
|
})),
|
|
3403
|
-
error:
|
|
3424
|
+
error: H().nullable()
|
|
3404
3425
|
});
|
|
3405
3426
|
Y.extend({
|
|
3406
|
-
id:
|
|
3427
|
+
id: H().min(1),
|
|
3407
3428
|
confirmed: X
|
|
3408
3429
|
});
|
|
3409
|
-
var
|
|
3410
|
-
|
|
3411
|
-
|
|
3412
|
-
|
|
3413
|
-
|
|
3414
|
-
|
|
3415
|
-
|
|
3416
|
-
|
|
3417
|
-
|
|
3418
|
-
|
|
3419
|
-
|
|
3420
|
-
|
|
3421
|
-
|
|
3422
|
-
|
|
3423
|
-
|
|
3424
|
-
|
|
3425
|
-
|
|
3426
|
-
|
|
3427
|
-
|
|
3428
|
-
|
|
3429
|
-
|
|
3430
|
-
|
|
3431
|
-
|
|
3432
|
-
|
|
3433
|
-
|
|
3434
|
-
|
|
3435
|
-
|
|
3436
|
-
|
|
3437
|
-
|
|
3438
|
-
|
|
3439
|
-
|
|
3440
|
-
|
|
3441
|
-
|
|
3442
|
-
|
|
3443
|
-
|
|
3444
|
-
|
|
3430
|
+
var Xo = q({ ok: bo(!0) });
|
|
3431
|
+
Y.extend({
|
|
3432
|
+
address: H().min(1),
|
|
3433
|
+
enabled: G(),
|
|
3434
|
+
confirmed: X
|
|
3435
|
+
});
|
|
3436
|
+
var Zo = q({
|
|
3437
|
+
address: H(),
|
|
3438
|
+
index: H(),
|
|
3439
|
+
name: H().nullable(),
|
|
3440
|
+
central: J([
|
|
3441
|
+
"on",
|
|
3442
|
+
"off",
|
|
3443
|
+
"unsupported",
|
|
3444
|
+
"unknown"
|
|
3445
|
+
])
|
|
3446
|
+
}), Qo = q({ devices: K(q({
|
|
3447
|
+
address: H(),
|
|
3448
|
+
type: H(),
|
|
3449
|
+
name: H().nullable(),
|
|
3450
|
+
rooms: K(H()),
|
|
3451
|
+
functions: K(H()),
|
|
3452
|
+
firmware: H().nullable(),
|
|
3453
|
+
availableFirmware: H().nullable(),
|
|
3454
|
+
updatable: G().nullable(),
|
|
3455
|
+
rssi: W().nullable(),
|
|
3456
|
+
rssiPeer: W().nullable(),
|
|
3457
|
+
dutyCycle: W().nullable(),
|
|
3458
|
+
dutyCycleLimited: G().nullable(),
|
|
3459
|
+
lowBattery: G().nullable(),
|
|
3460
|
+
unreach: G().nullable(),
|
|
3461
|
+
configPending: G().nullable(),
|
|
3462
|
+
sabotage: G().nullable(),
|
|
3463
|
+
keyChannels: K(Zo).default([])
|
|
3464
|
+
})) }), $o = ["hmip.heating.group", "HomeMatic.heating"], es = q({
|
|
3465
|
+
address: H(),
|
|
3466
|
+
type: H(),
|
|
3467
|
+
deviceName: H().nullable()
|
|
3468
|
+
}), ts = q({
|
|
3469
|
+
id: W(),
|
|
3470
|
+
name: H(),
|
|
3471
|
+
type: H(),
|
|
3472
|
+
typeLabel: H().nullable(),
|
|
3473
|
+
deviceAddress: H().nullable(),
|
|
3474
|
+
forbidSingleOperation: G(),
|
|
3475
|
+
members: K(es)
|
|
3476
|
+
}), ns = q({
|
|
3477
|
+
device: H(),
|
|
3478
|
+
channel: H(),
|
|
3479
|
+
name: H().nullable(),
|
|
3480
|
+
currentTemperature: W().nullable(),
|
|
3481
|
+
targetTemperature: W().nullable(),
|
|
3482
|
+
mode: J([
|
|
3445
3483
|
"auto",
|
|
3446
3484
|
"heat",
|
|
3447
3485
|
"off"
|
|
3448
3486
|
]),
|
|
3449
|
-
activity:
|
|
3487
|
+
activity: J([
|
|
3450
3488
|
"heating",
|
|
3451
3489
|
"idle",
|
|
3452
3490
|
"off"
|
|
3453
3491
|
])
|
|
3454
|
-
}),
|
|
3455
|
-
address:
|
|
3456
|
-
type:
|
|
3457
|
-
deviceName:
|
|
3458
|
-
}),
|
|
3459
|
-
groups:
|
|
3460
|
-
groupsError:
|
|
3461
|
-
thermostats:
|
|
3462
|
-
candidates:
|
|
3492
|
+
}), rs = q({
|
|
3493
|
+
address: H(),
|
|
3494
|
+
type: H(),
|
|
3495
|
+
deviceName: H().nullable()
|
|
3496
|
+
}), is = q({
|
|
3497
|
+
groups: K(ts),
|
|
3498
|
+
groupsError: H().nullable(),
|
|
3499
|
+
thermostats: K(ns),
|
|
3500
|
+
candidates: K(rs)
|
|
3463
3501
|
});
|
|
3464
3502
|
Y.extend({
|
|
3465
|
-
name:
|
|
3466
|
-
type:
|
|
3467
|
-
members:
|
|
3503
|
+
name: H(),
|
|
3504
|
+
type: J($o),
|
|
3505
|
+
members: K(H()),
|
|
3468
3506
|
confirmed: X
|
|
3469
3507
|
}), Y.extend({
|
|
3470
|
-
id:
|
|
3471
|
-
name:
|
|
3472
|
-
members:
|
|
3508
|
+
id: W(),
|
|
3509
|
+
name: H().optional(),
|
|
3510
|
+
members: K(H()).optional(),
|
|
3473
3511
|
confirmed: X
|
|
3474
3512
|
}), Y.extend({
|
|
3475
|
-
id:
|
|
3513
|
+
id: W(),
|
|
3476
3514
|
confirmed: X
|
|
3477
3515
|
});
|
|
3478
|
-
var
|
|
3479
|
-
interfaces: q(
|
|
3480
|
-
name:
|
|
3481
|
-
secondsLeft:
|
|
3482
|
-
supportsSecure:
|
|
3483
|
-
error:
|
|
3516
|
+
var as = ["normal", "secure"], os = q({
|
|
3517
|
+
interfaces: K(q({
|
|
3518
|
+
name: H(),
|
|
3519
|
+
secondsLeft: W().nullable(),
|
|
3520
|
+
supportsSecure: G(),
|
|
3521
|
+
error: H().nullable()
|
|
3484
3522
|
})),
|
|
3485
|
-
error:
|
|
3523
|
+
error: H().nullable()
|
|
3486
3524
|
});
|
|
3487
3525
|
Y.extend({
|
|
3488
|
-
interface:
|
|
3489
|
-
on:
|
|
3490
|
-
seconds:
|
|
3491
|
-
mode:
|
|
3526
|
+
interface: H().min(1),
|
|
3527
|
+
on: G(),
|
|
3528
|
+
seconds: W().int().min(1).max(3600).optional(),
|
|
3529
|
+
mode: J(as).optional(),
|
|
3492
3530
|
confirmed: X
|
|
3493
3531
|
}), Y.extend({
|
|
3494
|
-
address:
|
|
3495
|
-
reset:
|
|
3496
|
-
force:
|
|
3532
|
+
address: H().min(1),
|
|
3533
|
+
reset: G(),
|
|
3534
|
+
force: G(),
|
|
3497
3535
|
confirmed: X
|
|
3498
3536
|
});
|
|
3499
|
-
var
|
|
3500
|
-
K(),
|
|
3537
|
+
var ss = po([
|
|
3501
3538
|
G(),
|
|
3502
|
-
|
|
3503
|
-
|
|
3504
|
-
|
|
3505
|
-
|
|
3506
|
-
|
|
3507
|
-
|
|
3508
|
-
|
|
3509
|
-
|
|
3510
|
-
|
|
3511
|
-
|
|
3512
|
-
|
|
3513
|
-
|
|
3514
|
-
|
|
3515
|
-
|
|
3516
|
-
|
|
3517
|
-
|
|
3539
|
+
W(),
|
|
3540
|
+
H(),
|
|
3541
|
+
io()
|
|
3542
|
+
]), cs = q({
|
|
3543
|
+
parameter: H(),
|
|
3544
|
+
type: H(),
|
|
3545
|
+
min: W().nullable(),
|
|
3546
|
+
max: W().nullable(),
|
|
3547
|
+
unit: H().nullable(),
|
|
3548
|
+
valueList: K(H()).nullable(),
|
|
3549
|
+
writable: G(),
|
|
3550
|
+
value: ss
|
|
3551
|
+
}), ls = q({ channels: K(q({
|
|
3552
|
+
channel: H(),
|
|
3553
|
+
channelType: H().nullable(),
|
|
3554
|
+
params: K(cs),
|
|
3555
|
+
error: H().nullable()
|
|
3518
3556
|
})) });
|
|
3519
|
-
Y.extend({ address:
|
|
3520
|
-
channel:
|
|
3521
|
-
values:
|
|
3557
|
+
Y.extend({ address: H().min(1) }), Y.extend({
|
|
3558
|
+
channel: H().min(1),
|
|
3559
|
+
values: _o(H(), ss),
|
|
3522
3560
|
confirmed: X
|
|
3523
3561
|
});
|
|
3524
3562
|
//#endregion
|
|
3525
3563
|
//#region src/i18n/index.ts
|
|
3526
|
-
var { useT: Z, Trans:
|
|
3564
|
+
var { useT: Z, Trans: us, translate: ds } = s("provider-homematic", {
|
|
3527
3565
|
en: {
|
|
3528
3566
|
common: { loading: "Loading…" },
|
|
3529
3567
|
write: { failedTitle: "The CCU refused the change" },
|
|
@@ -3608,7 +3646,21 @@ var { useT: Z, Trans: cs, translate: ls } = s("provider-homematic", {
|
|
|
3608
3646
|
deleteMessage: "{{name}} will be removed from the CCU. Its programs and links on the CCU are lost.",
|
|
3609
3647
|
deleteMessageReset: "{{name}} will be factory-reset and removed from the CCU. Its programs and links on the CCU are lost.",
|
|
3610
3648
|
deleteConfirm: "Delete device",
|
|
3611
|
-
configureAction: "Configure"
|
|
3649
|
+
configureAction: "Configure",
|
|
3650
|
+
buttonEventsOn: "on",
|
|
3651
|
+
buttonEventsOff: "off",
|
|
3652
|
+
buttonEventsUnsupported: "unavailable",
|
|
3653
|
+
buttonEventsUnknown: "unknown",
|
|
3654
|
+
buttonEventsAction: "Button events",
|
|
3655
|
+
buttonEventsTitle: "Button events — {{name}}",
|
|
3656
|
+
buttonEventsHint: "The CCU sends a press only when the key channel has a central link. Direct links stay.",
|
|
3657
|
+
buttonEventsStatus: "button events: {{state}}",
|
|
3658
|
+
buttonEventsBadge: "ch{{index}} {{state}}",
|
|
3659
|
+
buttonChannel: "Channel {{index}}",
|
|
3660
|
+
enableButtonEvents: "Enable button events",
|
|
3661
|
+
disableButtonEvents: "Disable button events",
|
|
3662
|
+
enableButtonEventsMessage: "Create a central link for {{name}}. Direct links stay.",
|
|
3663
|
+
disableButtonEventsMessage: "Remove the central link for {{name}}. Direct links stay."
|
|
3612
3664
|
},
|
|
3613
3665
|
heating: {
|
|
3614
3666
|
loadFailed: "Could not read the heating setup",
|
|
@@ -3772,7 +3824,21 @@ var { useT: Z, Trans: cs, translate: ls } = s("provider-homematic", {
|
|
|
3772
3824
|
deleteMessage: "{{name}} sarà rimosso dalla CCU. Programmi e collegamenti sulla CCU andranno persi.",
|
|
3773
3825
|
deleteMessageReset: "{{name}} sarà ripristinato di fabbrica e rimosso dalla CCU. Programmi e collegamenti sulla CCU andranno persi.",
|
|
3774
3826
|
deleteConfirm: "Elimina dispositivo",
|
|
3775
|
-
configureAction: "Configura"
|
|
3827
|
+
configureAction: "Configura",
|
|
3828
|
+
buttonEventsOn: "attivo",
|
|
3829
|
+
buttonEventsOff: "disattivo",
|
|
3830
|
+
buttonEventsUnsupported: "non disponibile",
|
|
3831
|
+
buttonEventsUnknown: "sconosciuto",
|
|
3832
|
+
buttonEventsAction: "Eventi pulsante",
|
|
3833
|
+
buttonEventsTitle: "Eventi pulsante — {{name}}",
|
|
3834
|
+
buttonEventsHint: "La CCU invia una pressione solo se il canale tasto ha un collegamento centrale. I collegamenti diretti restano.",
|
|
3835
|
+
buttonEventsStatus: "eventi pulsante: {{state}}",
|
|
3836
|
+
buttonEventsBadge: "ch{{index}} {{state}}",
|
|
3837
|
+
buttonChannel: "Canale {{index}}",
|
|
3838
|
+
enableButtonEvents: "Abilita eventi pulsante",
|
|
3839
|
+
disableButtonEvents: "Disabilita eventi pulsante",
|
|
3840
|
+
enableButtonEventsMessage: "Crea un collegamento centrale per {{name}}. I collegamenti diretti restano.",
|
|
3841
|
+
disableButtonEventsMessage: "Rimuove il collegamento centrale di {{name}}. I collegamenti diretti restano."
|
|
3776
3842
|
},
|
|
3777
3843
|
heating: {
|
|
3778
3844
|
loadFailed: "Impossibile leggere il riscaldamento",
|
|
@@ -3855,21 +3921,21 @@ var { useT: Z, Trans: cs, translate: ls } = s("provider-homematic", {
|
|
|
3855
3921
|
});
|
|
3856
3922
|
//#endregion
|
|
3857
3923
|
//#region src/ui/format.ts
|
|
3858
|
-
function
|
|
3924
|
+
function fs(e) {
|
|
3859
3925
|
return e === null ? "—" : `${Math.round(e * 10) / 10}%`;
|
|
3860
3926
|
}
|
|
3861
3927
|
function Q(e) {
|
|
3862
3928
|
return e == null || e === "" ? "—" : e;
|
|
3863
3929
|
}
|
|
3864
|
-
function
|
|
3930
|
+
function ps(e) {
|
|
3865
3931
|
return e === null ? "—" : new Date(e).toLocaleString();
|
|
3866
3932
|
}
|
|
3867
3933
|
//#endregion
|
|
3868
3934
|
//#region src/ui/ccu-client.ts
|
|
3869
|
-
var
|
|
3870
|
-
async function
|
|
3935
|
+
var ms = "provider-homematic";
|
|
3936
|
+
async function hs(e, t, n, r) {
|
|
3871
3937
|
let i = await e.addons.custom.mutate({
|
|
3872
|
-
addonId:
|
|
3938
|
+
addonId: ms,
|
|
3873
3939
|
action: t,
|
|
3874
3940
|
input: n
|
|
3875
3941
|
});
|
|
@@ -3885,7 +3951,7 @@ function $(e, n, o, s, c = {}) {
|
|
|
3885
3951
|
return;
|
|
3886
3952
|
}
|
|
3887
3953
|
let t = ++_.current, r, i = (a) => {
|
|
3888
|
-
a && m(!0),
|
|
3954
|
+
a && m(!0), hs(e, n, o, s).then((e) => {
|
|
3889
3955
|
_.current === t && (u(e), f(null), m(!1), y !== void 0 && (r = setTimeout(() => i(!1), y)));
|
|
3890
3956
|
}, (e) => {
|
|
3891
3957
|
_.current === t && (f(e instanceof Error ? e.message : String(e)), m(!1), y !== void 0 && (r = setTimeout(() => i(!1), y)));
|
|
@@ -3910,7 +3976,7 @@ function $(e, n, o, s, c = {}) {
|
|
|
3910
3976
|
}
|
|
3911
3977
|
//#endregion
|
|
3912
3978
|
//#region src/ui/use-ccu-write.ts
|
|
3913
|
-
function
|
|
3979
|
+
function gs(e) {
|
|
3914
3980
|
let t = te(), n = y(), { t: r } = Z();
|
|
3915
3981
|
return i(async (i) => {
|
|
3916
3982
|
if (!await t({
|
|
@@ -3920,7 +3986,7 @@ function ms(e) {
|
|
|
3920
3986
|
variant: i.variant ?? "default"
|
|
3921
3987
|
})) return null;
|
|
3922
3988
|
try {
|
|
3923
|
-
return await
|
|
3989
|
+
return await hs(e, i.action, {
|
|
3924
3990
|
...i.input,
|
|
3925
3991
|
confirmed: !0
|
|
3926
3992
|
}, i.schema);
|
|
@@ -3940,7 +4006,7 @@ function ms(e) {
|
|
|
3940
4006
|
}
|
|
3941
4007
|
//#endregion
|
|
3942
4008
|
//#region src/ui/ChannelConfigDialog.tsx
|
|
3943
|
-
function
|
|
4009
|
+
function _s(e, t) {
|
|
3944
4010
|
if (typeof t == "boolean") return t;
|
|
3945
4011
|
if (e.type === "INTEGER" || e.type === "FLOAT") {
|
|
3946
4012
|
if (t.trim() === "") return;
|
|
@@ -3949,7 +4015,7 @@ function hs(e, t) {
|
|
|
3949
4015
|
}
|
|
3950
4016
|
return t;
|
|
3951
4017
|
}
|
|
3952
|
-
function
|
|
4018
|
+
function vs(e) {
|
|
3953
4019
|
let { param: t, edit: n, onEdit: r } = e, { t: i } = Z(), a = t.unit === null ? t.parameter : `${t.parameter} (${t.unit})`, o = t.min !== null && t.max !== null ? i("config.range", {
|
|
3954
4020
|
min: t.min,
|
|
3955
4021
|
max: t.max
|
|
@@ -3997,16 +4063,16 @@ function gs(e) {
|
|
|
3997
4063
|
})
|
|
3998
4064
|
});
|
|
3999
4065
|
}
|
|
4000
|
-
function
|
|
4001
|
-
let { trpc: n, integrationId: r, device: i, onClose: o } = t, { t: s } = Z(), l =
|
|
4066
|
+
function ys(t) {
|
|
4067
|
+
let { trpc: n, integrationId: r, device: i, onClose: o } = t, { t: s } = Z(), l = gs(n), u = $(n, "getCcuDeviceConfig", e(() => ({
|
|
4002
4068
|
integrationId: r,
|
|
4003
4069
|
address: i.address
|
|
4004
|
-
}), [r, i.address]),
|
|
4070
|
+
}), [r, i.address]), ls), [d, f] = a(null), [m, h] = a({}), [g, v] = a(!1), y = u.data?.channels ?? [], b = y.find((e) => e.channel === d) ?? y[0], ee = e(() => {
|
|
4005
4071
|
let e = {};
|
|
4006
4072
|
for (let t of b?.params ?? []) {
|
|
4007
4073
|
let n = m[`${b?.channel}/${t.parameter}`];
|
|
4008
4074
|
if (n === void 0) continue;
|
|
4009
|
-
let r =
|
|
4075
|
+
let r = _s(t, n);
|
|
4010
4076
|
r !== void 0 && r !== t.value && (e[t.parameter] = r);
|
|
4011
4077
|
}
|
|
4012
4078
|
return e;
|
|
@@ -4021,7 +4087,7 @@ function _s(t) {
|
|
|
4021
4087
|
channel: b.channel,
|
|
4022
4088
|
values: ee
|
|
4023
4089
|
},
|
|
4024
|
-
schema:
|
|
4090
|
+
schema: Xo,
|
|
4025
4091
|
title: s("config.confirmTitle"),
|
|
4026
4092
|
message: s("config.confirmMessage", {
|
|
4027
4093
|
channel: b.channel,
|
|
@@ -4039,7 +4105,7 @@ function _s(t) {
|
|
|
4039
4105
|
return /* @__PURE__ */ w(p, {
|
|
4040
4106
|
open: !0,
|
|
4041
4107
|
onClose: o,
|
|
4042
|
-
icon:
|
|
4108
|
+
icon: ye,
|
|
4043
4109
|
width: "lg",
|
|
4044
4110
|
title: s("config.title", { name: i.name ?? i.address }),
|
|
4045
4111
|
testId: "hm-config-dialog",
|
|
@@ -4075,7 +4141,7 @@ function _s(t) {
|
|
|
4075
4141
|
className: "text-xs text-danger",
|
|
4076
4142
|
children: s("config.valuesUnreadable", { error: b.error })
|
|
4077
4143
|
}),
|
|
4078
|
-
b.params.map((e) => /* @__PURE__ */ w(
|
|
4144
|
+
b.params.map((e) => /* @__PURE__ */ w(vs, {
|
|
4079
4145
|
param: e,
|
|
4080
4146
|
edit: m[`${b.channel}/${e.parameter}`],
|
|
4081
4147
|
onEdit: (t) => h((n) => ({
|
|
@@ -4092,8 +4158,73 @@ function _s(t) {
|
|
|
4092
4158
|
});
|
|
4093
4159
|
}
|
|
4094
4160
|
//#endregion
|
|
4161
|
+
//#region src/ui/central-key.ts
|
|
4162
|
+
function bs(e) {
|
|
4163
|
+
return e === "on" ? "devices.buttonEventsOn" : e === "off" ? "devices.buttonEventsOff" : e === "unsupported" ? "devices.buttonEventsUnsupported" : "devices.buttonEventsUnknown";
|
|
4164
|
+
}
|
|
4165
|
+
//#endregion
|
|
4166
|
+
//#region src/ui/ButtonEventsDialog.tsx
|
|
4167
|
+
function xs(e) {
|
|
4168
|
+
let { trpc: t, integrationId: n, device: r, onClose: i, onChanged: o } = e, { t: s } = Z(), c = gs(t), [l, u] = a(null), d = async (e) => {
|
|
4169
|
+
let t = e.central !== "on";
|
|
4170
|
+
u(e.address);
|
|
4171
|
+
try {
|
|
4172
|
+
await c({
|
|
4173
|
+
action: "setButtonEvents",
|
|
4174
|
+
input: {
|
|
4175
|
+
integrationId: n,
|
|
4176
|
+
address: e.address,
|
|
4177
|
+
enabled: t
|
|
4178
|
+
},
|
|
4179
|
+
schema: Xo,
|
|
4180
|
+
title: s(t ? "devices.enableButtonEvents" : "devices.disableButtonEvents"),
|
|
4181
|
+
message: s(t ? "devices.enableButtonEventsMessage" : "devices.disableButtonEventsMessage", { name: e.name ?? `${r.name ?? r.address} ch${e.index}` }),
|
|
4182
|
+
confirmLabel: s(t ? "devices.enableButtonEvents" : "devices.disableButtonEvents")
|
|
4183
|
+
}) !== null && o();
|
|
4184
|
+
} finally {
|
|
4185
|
+
u(null);
|
|
4186
|
+
}
|
|
4187
|
+
};
|
|
4188
|
+
return /* @__PURE__ */ w(p, {
|
|
4189
|
+
open: !0,
|
|
4190
|
+
onClose: i,
|
|
4191
|
+
icon: me,
|
|
4192
|
+
width: "md",
|
|
4193
|
+
title: s("devices.buttonEventsTitle", { name: r.name ?? r.address }),
|
|
4194
|
+
testId: "hm-button-events-dialog",
|
|
4195
|
+
children: /* @__PURE__ */ C("div", {
|
|
4196
|
+
className: "flex flex-col gap-3",
|
|
4197
|
+
children: [/* @__PURE__ */ w("p", {
|
|
4198
|
+
className: "text-sm text-foreground-subtle",
|
|
4199
|
+
children: s("devices.buttonEventsHint")
|
|
4200
|
+
}), r.keyChannels.map((e) => /* @__PURE__ */ C("div", {
|
|
4201
|
+
className: "flex items-center justify-between gap-3",
|
|
4202
|
+
children: [/* @__PURE__ */ C("div", {
|
|
4203
|
+
className: "flex flex-col",
|
|
4204
|
+
children: [/* @__PURE__ */ w("span", {
|
|
4205
|
+
className: "text-sm text-foreground",
|
|
4206
|
+
children: e.name ?? s("devices.buttonChannel", { index: e.index })
|
|
4207
|
+
}), /* @__PURE__ */ w("span", {
|
|
4208
|
+
className: "text-xs text-foreground-subtle",
|
|
4209
|
+
children: s("devices.buttonEventsStatus", { state: s(bs(e.central)) })
|
|
4210
|
+
})]
|
|
4211
|
+
}), e.central === "on" || e.central === "off" ? /* @__PURE__ */ w(S, {
|
|
4212
|
+
type: "button",
|
|
4213
|
+
variant: e.central === "on" ? "secondary" : "primary",
|
|
4214
|
+
disabled: l !== null,
|
|
4215
|
+
onClick: () => void d(e),
|
|
4216
|
+
children: s(e.central === "on" ? "devices.disableButtonEvents" : "devices.enableButtonEvents")
|
|
4217
|
+
}) : /* @__PURE__ */ w(v, {
|
|
4218
|
+
variant: "info",
|
|
4219
|
+
children: s(bs(e.central))
|
|
4220
|
+
})]
|
|
4221
|
+
}, e.address))]
|
|
4222
|
+
})
|
|
4223
|
+
});
|
|
4224
|
+
}
|
|
4225
|
+
//#endregion
|
|
4095
4226
|
//#region src/ui/DeleteDeviceDialog.tsx
|
|
4096
|
-
function
|
|
4227
|
+
function Ss(e) {
|
|
4097
4228
|
let { device: t, onClose: n, onDelete: r } = e, { t: i } = Z(), [o, s] = a(!1), [c, l] = a(!1), [u, d] = a(!1), f = async () => {
|
|
4098
4229
|
d(!0);
|
|
4099
4230
|
try {
|
|
@@ -4108,7 +4239,7 @@ function vs(e) {
|
|
|
4108
4239
|
return /* @__PURE__ */ w(p, {
|
|
4109
4240
|
open: !0,
|
|
4110
4241
|
onClose: n,
|
|
4111
|
-
icon:
|
|
4242
|
+
icon: be,
|
|
4112
4243
|
width: "md",
|
|
4113
4244
|
title: i("devices.deleteDialogTitle", { name: t.name ?? t.address }),
|
|
4114
4245
|
testId: "hm-delete-device-dialog",
|
|
@@ -4147,10 +4278,10 @@ function vs(e) {
|
|
|
4147
4278
|
}
|
|
4148
4279
|
//#endregion
|
|
4149
4280
|
//#region src/ui/CcuDevicesTab.tsx
|
|
4150
|
-
function
|
|
4281
|
+
function Cs(e) {
|
|
4151
4282
|
return e.unreach === !0 ? "unreach" : e.sabotage === !0 ? "sabotage" : e.lowBattery === !0 ? "lowBattery" : e.configPending === !0 ? "configPending" : "ok";
|
|
4152
4283
|
}
|
|
4153
|
-
var
|
|
4284
|
+
var ws = {
|
|
4154
4285
|
searchText: (e) => [
|
|
4155
4286
|
e.name ?? "",
|
|
4156
4287
|
e.address,
|
|
@@ -4160,17 +4291,17 @@ var bs = {
|
|
|
4160
4291
|
],
|
|
4161
4292
|
facetGroups: [{
|
|
4162
4293
|
id: "issue",
|
|
4163
|
-
value:
|
|
4294
|
+
value: Cs
|
|
4164
4295
|
}, {
|
|
4165
4296
|
id: "type",
|
|
4166
4297
|
value: (e) => e.type
|
|
4167
4298
|
}]
|
|
4168
4299
|
};
|
|
4169
|
-
function
|
|
4300
|
+
function Ts(e) {
|
|
4170
4301
|
return e.rssi === null ? "—" : `${e.rssi} dBm`;
|
|
4171
4302
|
}
|
|
4172
|
-
function
|
|
4173
|
-
let { trpc: n, integrationId: r } = t, { t: i } = Z(), o = $(n, "listCcuDevices", e(() => ({ integrationId: r }), [r]),
|
|
4303
|
+
function Es(t) {
|
|
4304
|
+
let { trpc: n, integrationId: r } = t, { t: i } = Z(), o = $(n, "listCcuDevices", e(() => ({ integrationId: r }), [r]), Qo), s = g(e(() => o.data?.devices ?? [], [o.data]), ws), c = gs(n), [u, d] = a(null), [f, p] = a(null), [m, h] = a(null), y = async (e, t) => {
|
|
4174
4305
|
await c({
|
|
4175
4306
|
action: "deleteCcuDevice",
|
|
4176
4307
|
input: {
|
|
@@ -4179,13 +4310,13 @@ function Ss(t) {
|
|
|
4179
4310
|
reset: t.reset,
|
|
4180
4311
|
force: t.force
|
|
4181
4312
|
},
|
|
4182
|
-
schema:
|
|
4313
|
+
schema: Xo,
|
|
4183
4314
|
title: i("devices.deleteTitle"),
|
|
4184
4315
|
message: i(t.reset ? "devices.deleteMessageReset" : "devices.deleteMessage", { name: e.name ?? e.address }),
|
|
4185
4316
|
confirmLabel: i("devices.deleteConfirm"),
|
|
4186
4317
|
variant: "danger"
|
|
4187
4318
|
}) !== null && (d(null), o.reload());
|
|
4188
|
-
},
|
|
4319
|
+
}, te = e(() => [
|
|
4189
4320
|
{
|
|
4190
4321
|
key: "name",
|
|
4191
4322
|
header: i("devices.colDevice"),
|
|
@@ -4230,7 +4361,7 @@ function Ss(t) {
|
|
|
4230
4361
|
key: "signal",
|
|
4231
4362
|
header: i("devices.colSignal"),
|
|
4232
4363
|
align: "right",
|
|
4233
|
-
render:
|
|
4364
|
+
render: Ts,
|
|
4234
4365
|
sortValue: (e) => e.rssi
|
|
4235
4366
|
},
|
|
4236
4367
|
{
|
|
@@ -4240,7 +4371,7 @@ function Ss(t) {
|
|
|
4240
4371
|
render: (e) => e.dutyCycleLimited === !0 ? /* @__PURE__ */ w(v, {
|
|
4241
4372
|
variant: "warning",
|
|
4242
4373
|
children: i("devices.dutyLimited")
|
|
4243
|
-
}) :
|
|
4374
|
+
}) : fs(e.dutyCycle),
|
|
4244
4375
|
sortValue: (e) => e.dutyCycle
|
|
4245
4376
|
},
|
|
4246
4377
|
{
|
|
@@ -4267,10 +4398,17 @@ function Ss(t) {
|
|
|
4267
4398
|
variant: "info",
|
|
4268
4399
|
children: i("devices.configPending")
|
|
4269
4400
|
}),
|
|
4270
|
-
|
|
4401
|
+
Cs(e) === "ok" && /* @__PURE__ */ w(v, {
|
|
4271
4402
|
variant: "success",
|
|
4272
4403
|
children: i("devices.ok")
|
|
4273
|
-
})
|
|
4404
|
+
}),
|
|
4405
|
+
e.keyChannels.map((e) => /* @__PURE__ */ w(v, {
|
|
4406
|
+
variant: e.central === "on" ? "success" : "warning",
|
|
4407
|
+
children: i("devices.buttonEventsBadge", {
|
|
4408
|
+
index: e.index,
|
|
4409
|
+
state: i(bs(e.central))
|
|
4410
|
+
})
|
|
4411
|
+
}, e.address))
|
|
4274
4412
|
]
|
|
4275
4413
|
})
|
|
4276
4414
|
},
|
|
@@ -4279,18 +4417,27 @@ function Ss(t) {
|
|
|
4279
4417
|
header: "",
|
|
4280
4418
|
align: "right",
|
|
4281
4419
|
notSortableReason: "Action column",
|
|
4282
|
-
render: (e) => /* @__PURE__ */ w(ee, { items: [
|
|
4283
|
-
|
|
4284
|
-
|
|
4285
|
-
|
|
4286
|
-
|
|
4287
|
-
|
|
4288
|
-
|
|
4289
|
-
|
|
4290
|
-
|
|
4291
|
-
|
|
4292
|
-
|
|
4293
|
-
|
|
4420
|
+
render: (e) => /* @__PURE__ */ w(ee, { items: [
|
|
4421
|
+
...e.keyChannels.length > 0 ? [{
|
|
4422
|
+
id: "button-events",
|
|
4423
|
+
label: i("devices.buttonEventsAction"),
|
|
4424
|
+
icon: me,
|
|
4425
|
+
onClick: () => h(e)
|
|
4426
|
+
}] : [],
|
|
4427
|
+
{
|
|
4428
|
+
id: "configure",
|
|
4429
|
+
label: i("devices.configureAction"),
|
|
4430
|
+
icon: ye,
|
|
4431
|
+
onClick: () => p(e)
|
|
4432
|
+
},
|
|
4433
|
+
{
|
|
4434
|
+
id: "delete",
|
|
4435
|
+
label: i("devices.deleteAction"),
|
|
4436
|
+
icon: be,
|
|
4437
|
+
danger: !0,
|
|
4438
|
+
onClick: () => d(e)
|
|
4439
|
+
}
|
|
4440
|
+
] })
|
|
4294
4441
|
}
|
|
4295
4442
|
], [i]);
|
|
4296
4443
|
if (o.error !== null) return /* @__PURE__ */ w(_, {
|
|
@@ -4298,10 +4445,10 @@ function Ss(t) {
|
|
|
4298
4445
|
message: o.error,
|
|
4299
4446
|
onRetry: o.reload
|
|
4300
4447
|
});
|
|
4301
|
-
let
|
|
4448
|
+
let ne = {
|
|
4302
4449
|
issue: i("devices.groupIssue"),
|
|
4303
4450
|
type: i("devices.groupType")
|
|
4304
|
-
},
|
|
4451
|
+
}, re = (e) => e === "unreach" || e === "sabotage" || e === "lowBattery" || e === "configPending" || e === "ok" ? i(`devices.${e}`) : e;
|
|
4305
4452
|
return /* @__PURE__ */ C("div", {
|
|
4306
4453
|
className: "flex flex-col gap-3",
|
|
4307
4454
|
children: [
|
|
@@ -4310,8 +4457,8 @@ function Ss(t) {
|
|
|
4310
4457
|
facets: s.facets,
|
|
4311
4458
|
groups: s.groups.map((e) => ({
|
|
4312
4459
|
...e,
|
|
4313
|
-
label:
|
|
4314
|
-
...e.id === "issue" ? { facetLabel:
|
|
4460
|
+
label: ne[e.id] ?? e.id,
|
|
4461
|
+
...e.id === "issue" ? { facetLabel: re } : {}
|
|
4315
4462
|
})),
|
|
4316
4463
|
labels: {
|
|
4317
4464
|
searchPlaceholder: i("devices.searchPlaceholder"),
|
|
@@ -4325,31 +4472,40 @@ function Ss(t) {
|
|
|
4325
4472
|
onClear: s.clear
|
|
4326
4473
|
}),
|
|
4327
4474
|
/* @__PURE__ */ w(l, {
|
|
4328
|
-
columns:
|
|
4475
|
+
columns: te,
|
|
4329
4476
|
rows: s.rows,
|
|
4330
4477
|
rowKey: (e) => e.address,
|
|
4331
4478
|
minWidthPx: 760,
|
|
4332
4479
|
pageSize: 25,
|
|
4333
4480
|
emptyMessage: o.loading ? i("common.loading") : s.active ? i("devices.noMatch") : i("devices.none")
|
|
4334
4481
|
}),
|
|
4335
|
-
f !== null && /* @__PURE__ */ w(
|
|
4482
|
+
f !== null && /* @__PURE__ */ w(ys, {
|
|
4336
4483
|
trpc: n,
|
|
4337
4484
|
integrationId: r,
|
|
4338
4485
|
device: f,
|
|
4339
4486
|
onClose: () => p(null)
|
|
4340
4487
|
}),
|
|
4341
|
-
|
|
4488
|
+
m !== null && /* @__PURE__ */ w(xs, {
|
|
4489
|
+
trpc: n,
|
|
4490
|
+
integrationId: r,
|
|
4491
|
+
device: m,
|
|
4492
|
+
onClose: () => h(null),
|
|
4493
|
+
onChanged: () => {
|
|
4494
|
+
h(null), o.reload();
|
|
4495
|
+
}
|
|
4496
|
+
}),
|
|
4497
|
+
u !== null && /* @__PURE__ */ w(Ss, {
|
|
4342
4498
|
device: u,
|
|
4343
4499
|
onClose: () => d(null),
|
|
4344
|
-
onDelete: (e) =>
|
|
4500
|
+
onDelete: (e) => y(u, e)
|
|
4345
4501
|
})
|
|
4346
4502
|
]
|
|
4347
4503
|
});
|
|
4348
4504
|
}
|
|
4349
4505
|
//#endregion
|
|
4350
4506
|
//#region src/ui/GroupFormDialog.tsx
|
|
4351
|
-
function
|
|
4352
|
-
let { group: t, candidates: n, onClose: r, onSave: i } = e, { t: o } = Z(), [s, l] = a(t?.name ?? ""), [u, d] = a(t?.type ??
|
|
4507
|
+
function Ds(e) {
|
|
4508
|
+
let { group: t, candidates: n, onClose: r, onSave: i } = e, { t: o } = Z(), [s, l] = a(t?.name ?? ""), [u, d] = a(t?.type ?? $o[0]), [m, h] = a(() => t?.members.map((e) => e.address) ?? []), [g, _] = a(!1), v = (e) => h((t) => t.includes(e) ? t.filter((t) => t !== e) : [...t, e]), y = s.trim() !== "" && m.length > 0 && !g, b = async () => {
|
|
4353
4509
|
_(!0);
|
|
4354
4510
|
try {
|
|
4355
4511
|
await i({
|
|
@@ -4390,7 +4546,7 @@ function Cs(e) {
|
|
|
4390
4546
|
children: /* @__PURE__ */ w(c, {
|
|
4391
4547
|
value: u,
|
|
4392
4548
|
onChange: (e) => d(e.target.value),
|
|
4393
|
-
options:
|
|
4549
|
+
options: $o.map((e) => ({
|
|
4394
4550
|
value: e,
|
|
4395
4551
|
label: o(e === "hmip.heating.group" ? "heating.typeHmip" : "heating.typeHomematic")
|
|
4396
4552
|
}))
|
|
@@ -4426,11 +4582,11 @@ function Cs(e) {
|
|
|
4426
4582
|
}
|
|
4427
4583
|
//#endregion
|
|
4428
4584
|
//#region src/ui/CcuHeatingTab.tsx
|
|
4429
|
-
function
|
|
4585
|
+
function Os(e) {
|
|
4430
4586
|
return e === null ? "—" : `${e} °C`;
|
|
4431
4587
|
}
|
|
4432
|
-
function
|
|
4433
|
-
let { trpc: n, integrationId: r } = t, { t: i } = Z(), o = $(n, "listHeatingGroups", e(() => ({ integrationId: r }), [r]),
|
|
4588
|
+
function ks(t) {
|
|
4589
|
+
let { trpc: n, integrationId: r } = t, { t: i } = Z(), o = $(n, "listHeatingGroups", e(() => ({ integrationId: r }), [r]), is), s = gs(n), [c, u] = a({ kind: "closed" }), d = async (e, t) => {
|
|
4434
4590
|
(e === null ? await s({
|
|
4435
4591
|
action: "createHeatingGroup",
|
|
4436
4592
|
input: {
|
|
@@ -4439,7 +4595,7 @@ function Ts(t) {
|
|
|
4439
4595
|
type: t.type,
|
|
4440
4596
|
members: t.members
|
|
4441
4597
|
},
|
|
4442
|
-
schema:
|
|
4598
|
+
schema: ts,
|
|
4443
4599
|
title: i("heating.createTitle"),
|
|
4444
4600
|
message: i("heating.createMessage", {
|
|
4445
4601
|
name: t.name.trim(),
|
|
@@ -4454,7 +4610,7 @@ function Ts(t) {
|
|
|
4454
4610
|
name: t.name,
|
|
4455
4611
|
members: t.members
|
|
4456
4612
|
},
|
|
4457
|
-
schema:
|
|
4613
|
+
schema: ts,
|
|
4458
4614
|
title: i("heating.updateTitle"),
|
|
4459
4615
|
message: i("heating.updateMessage", {
|
|
4460
4616
|
name: e.name,
|
|
@@ -4469,7 +4625,7 @@ function Ts(t) {
|
|
|
4469
4625
|
integrationId: r,
|
|
4470
4626
|
id: e.id
|
|
4471
4627
|
},
|
|
4472
|
-
schema:
|
|
4628
|
+
schema: Xo,
|
|
4473
4629
|
title: i("heating.deleteTitle"),
|
|
4474
4630
|
message: i("heating.deleteMessage", { name: e.name }),
|
|
4475
4631
|
confirmLabel: i("heating.deleteConfirm"),
|
|
@@ -4503,7 +4659,7 @@ function Ts(t) {
|
|
|
4503
4659
|
render: (e) => /* @__PURE__ */ w(ee, { items: [{
|
|
4504
4660
|
id: "edit",
|
|
4505
4661
|
label: i("heating.edit"),
|
|
4506
|
-
icon:
|
|
4662
|
+
icon: he,
|
|
4507
4663
|
onClick: () => u({
|
|
4508
4664
|
kind: "form",
|
|
4509
4665
|
group: e
|
|
@@ -4511,7 +4667,7 @@ function Ts(t) {
|
|
|
4511
4667
|
}, {
|
|
4512
4668
|
id: "delete",
|
|
4513
4669
|
label: i("heating.delete"),
|
|
4514
|
-
icon:
|
|
4670
|
+
icon: be,
|
|
4515
4671
|
onClick: () => void f(e)
|
|
4516
4672
|
}] })
|
|
4517
4673
|
}
|
|
@@ -4526,14 +4682,14 @@ function Ts(t) {
|
|
|
4526
4682
|
key: "current",
|
|
4527
4683
|
header: i("heating.colCurrent"),
|
|
4528
4684
|
align: "right",
|
|
4529
|
-
render: (e) =>
|
|
4685
|
+
render: (e) => Os(e.currentTemperature),
|
|
4530
4686
|
sortValue: (e) => e.currentTemperature
|
|
4531
4687
|
},
|
|
4532
4688
|
{
|
|
4533
4689
|
key: "target",
|
|
4534
4690
|
header: i("heating.colTarget"),
|
|
4535
4691
|
align: "right",
|
|
4536
|
-
render: (e) =>
|
|
4692
|
+
render: (e) => Os(e.targetTemperature),
|
|
4537
4693
|
sortValue: (e) => e.targetTemperature
|
|
4538
4694
|
},
|
|
4539
4695
|
{
|
|
@@ -4572,7 +4728,7 @@ function Ts(t) {
|
|
|
4572
4728
|
kind: "form",
|
|
4573
4729
|
group: null
|
|
4574
4730
|
}),
|
|
4575
|
-
children: [/* @__PURE__ */ w(
|
|
4731
|
+
children: [/* @__PURE__ */ w(ge, { className: "h-4 w-4" }), i("heating.newGroup")]
|
|
4576
4732
|
}),
|
|
4577
4733
|
children: g?.groupsError ? /* @__PURE__ */ w(_, {
|
|
4578
4734
|
variant: "warning",
|
|
@@ -4597,7 +4753,7 @@ function Ts(t) {
|
|
|
4597
4753
|
emptyMessage: o.loading ? i("common.loading") : i("heating.noThermostats")
|
|
4598
4754
|
})
|
|
4599
4755
|
}),
|
|
4600
|
-
c.kind === "form" && g !== void 0 && /* @__PURE__ */ w(
|
|
4756
|
+
c.kind === "form" && g !== void 0 && /* @__PURE__ */ w(Ds, {
|
|
4601
4757
|
group: c.group,
|
|
4602
4758
|
candidates: g.candidates,
|
|
4603
4759
|
onClose: () => u({ kind: "closed" }),
|
|
@@ -4608,18 +4764,18 @@ function Ts(t) {
|
|
|
4608
4764
|
}
|
|
4609
4765
|
//#endregion
|
|
4610
4766
|
//#region src/ui/CcuOverviewTab.tsx
|
|
4611
|
-
function
|
|
4767
|
+
function As(e) {
|
|
4612
4768
|
return e === null ? "unknown" : e ? "online" : "offline";
|
|
4613
4769
|
}
|
|
4614
|
-
function
|
|
4615
|
-
let { trpc: n, integrationId: r } = t, { t: i } = Z(), a = e(() => ({ integrationId: r }), [r]), o = $(n, "ccuOverview", a,
|
|
4770
|
+
function js(t) {
|
|
4771
|
+
let { trpc: n, integrationId: r } = t, { t: i } = Z(), a = e(() => ({ integrationId: r }), [r]), o = $(n, "ccuOverview", a, Jo), s = $(n, "listServiceMessages", a, Yo), c = gs(n), f = async (e) => {
|
|
4616
4772
|
await c({
|
|
4617
4773
|
action: "acknowledgeServiceMessage",
|
|
4618
4774
|
input: {
|
|
4619
4775
|
integrationId: r,
|
|
4620
4776
|
id: e.id
|
|
4621
4777
|
},
|
|
4622
|
-
schema:
|
|
4778
|
+
schema: Xo,
|
|
4623
4779
|
title: i("overview.ackTitle"),
|
|
4624
4780
|
message: i("overview.ackMessage", {
|
|
4625
4781
|
type: Q(e.type),
|
|
@@ -4637,14 +4793,14 @@ function Ds(t) {
|
|
|
4637
4793
|
{
|
|
4638
4794
|
key: "state",
|
|
4639
4795
|
header: i("overview.colState"),
|
|
4640
|
-
render: (e) => /* @__PURE__ */ w(u, { status:
|
|
4796
|
+
render: (e) => /* @__PURE__ */ w(u, { status: As(e.connected) }),
|
|
4641
4797
|
sortValue: (e) => e.connected === null ? null : +!!e.connected
|
|
4642
4798
|
},
|
|
4643
4799
|
{
|
|
4644
4800
|
key: "duty",
|
|
4645
4801
|
header: i("overview.colDutyCycle"),
|
|
4646
4802
|
align: "right",
|
|
4647
|
-
render: (e) =>
|
|
4803
|
+
render: (e) => fs(e.dutyCycle),
|
|
4648
4804
|
sortValue: (e) => e.dutyCycle
|
|
4649
4805
|
},
|
|
4650
4806
|
{
|
|
@@ -4670,7 +4826,7 @@ function Ds(t) {
|
|
|
4670
4826
|
{
|
|
4671
4827
|
key: "time",
|
|
4672
4828
|
header: i("overview.colWhen"),
|
|
4673
|
-
render: (e) =>
|
|
4829
|
+
render: (e) => ps(e.timestamp),
|
|
4674
4830
|
sortValue: (e) => e.timestamp
|
|
4675
4831
|
},
|
|
4676
4832
|
{
|
|
@@ -4713,7 +4869,7 @@ function Ds(t) {
|
|
|
4713
4869
|
/* @__PURE__ */ w(h, {
|
|
4714
4870
|
headingId: "hm-ccu-info",
|
|
4715
4871
|
title: i("overview.ccuTitle"),
|
|
4716
|
-
icon:
|
|
4872
|
+
icon: ve,
|
|
4717
4873
|
children: o.loading && o.data === void 0 ? /* @__PURE__ */ w(ie, { className: "h-16 w-full" }) : g === null ? /* @__PURE__ */ w(_, {
|
|
4718
4874
|
variant: "warning",
|
|
4719
4875
|
title: i("overview.infoUnavailable"),
|
|
@@ -4759,7 +4915,7 @@ function Ds(t) {
|
|
|
4759
4915
|
/* @__PURE__ */ w(h, {
|
|
4760
4916
|
headingId: "hm-ccu-messages",
|
|
4761
4917
|
title: i("overview.messagesTitle"),
|
|
4762
|
-
icon:
|
|
4918
|
+
icon: xe,
|
|
4763
4919
|
children: s.data?.error ? /* @__PURE__ */ w(_, {
|
|
4764
4920
|
variant: "warning",
|
|
4765
4921
|
title: i("overview.messagesUnavailable"),
|
|
@@ -4784,15 +4940,15 @@ function Ds(t) {
|
|
|
4784
4940
|
}
|
|
4785
4941
|
//#endregion
|
|
4786
4942
|
//#region src/ui/CcuPairingTab.tsx
|
|
4787
|
-
var
|
|
4788
|
-
function
|
|
4943
|
+
var Ms = 3e3, Ns = 4e3, Ps = 60;
|
|
4944
|
+
function Fs(e) {
|
|
4789
4945
|
return e.secondsLeft !== null && e.secondsLeft > 0;
|
|
4790
4946
|
}
|
|
4791
|
-
function
|
|
4792
|
-
let { iface: t, busy: n, onStart: r, onStop: i } = e, { t: o } = Z(), [s, l] = a(String(
|
|
4947
|
+
function Is(e) {
|
|
4948
|
+
let { iface: t, busy: n, onStart: r, onStop: i } = e, { t: o } = Z(), [s, l] = a(String(Ps)), [u, d] = a(as[0]), p = Number(s), m = Number.isInteger(p) && p >= 1 && p <= 3600, g = t.error === null ? t.secondsLeft === null ? /* @__PURE__ */ w(v, {
|
|
4793
4949
|
variant: "neutral",
|
|
4794
4950
|
children: o("pairing.statusUnknown")
|
|
4795
|
-
}) :
|
|
4951
|
+
}) : Fs(t) ? /* @__PURE__ */ w(v, {
|
|
4796
4952
|
variant: "success",
|
|
4797
4953
|
children: o("pairing.statusOpen", { seconds: t.secondsLeft })
|
|
4798
4954
|
}) : /* @__PURE__ */ w(v, {
|
|
@@ -4830,7 +4986,7 @@ function Ms(e) {
|
|
|
4830
4986
|
children: /* @__PURE__ */ w(c, {
|
|
4831
4987
|
value: u,
|
|
4832
4988
|
onChange: (e) => d(e.target.value),
|
|
4833
|
-
options:
|
|
4989
|
+
options: as.map((e) => ({
|
|
4834
4990
|
value: e,
|
|
4835
4991
|
label: o(e === "secure" ? "pairing.modeSecure" : "pairing.modeNormal")
|
|
4836
4992
|
}))
|
|
@@ -4842,7 +4998,7 @@ function Ms(e) {
|
|
|
4842
4998
|
onClick: () => r(p, t.supportsSecure ? u : void 0),
|
|
4843
4999
|
children: o("pairing.start")
|
|
4844
5000
|
}),
|
|
4845
|
-
|
|
5001
|
+
Fs(t) && /* @__PURE__ */ w(S, {
|
|
4846
5002
|
type: "button",
|
|
4847
5003
|
variant: "secondary",
|
|
4848
5004
|
disabled: n,
|
|
@@ -4854,8 +5010,8 @@ function Ms(e) {
|
|
|
4854
5010
|
})
|
|
4855
5011
|
});
|
|
4856
5012
|
}
|
|
4857
|
-
function
|
|
4858
|
-
let { trpc: r, integrationId: i } = n, { t: o } = Z(), s =
|
|
5013
|
+
function Ls(n) {
|
|
5014
|
+
let { trpc: r, integrationId: i } = n, { t: o } = Z(), s = gs(r), c = e(() => ({ integrationId: i }), [i]), l = $(r, "ccuPairingStatus", c, os, { pollMs: Ms }), u = (l.data?.interfaces ?? []).some(Fs), d = $(r, "listCcuDevices", c, Qo, { ...u ? { pollMs: Ns } : {} }), [f, p] = a(!1), [m, g] = a(null);
|
|
4859
5015
|
t(() => {
|
|
4860
5016
|
m === null && d.data !== void 0 && g(new Set(d.data.devices.map((e) => e.address)));
|
|
4861
5017
|
}, [m, d.data]);
|
|
@@ -4871,7 +5027,7 @@ function Ns(n) {
|
|
|
4871
5027
|
...t ? { seconds: n } : {},
|
|
4872
5028
|
...t && r !== void 0 ? { mode: r } : {}
|
|
4873
5029
|
},
|
|
4874
|
-
schema:
|
|
5030
|
+
schema: Xo,
|
|
4875
5031
|
title: o(t ? "pairing.startTitle" : "pairing.stopTitle", { name: e.name }),
|
|
4876
5032
|
message: t ? o("pairing.startMessage", {
|
|
4877
5033
|
name: e.name,
|
|
@@ -4897,7 +5053,7 @@ function Ns(n) {
|
|
|
4897
5053
|
l.data.interfaces.length === 0 ? /* @__PURE__ */ w("p", {
|
|
4898
5054
|
className: "text-sm text-foreground-subtle",
|
|
4899
5055
|
children: o("pairing.noInterfaces")
|
|
4900
|
-
}) : l.data.interfaces.map((e) => /* @__PURE__ */ w(
|
|
5056
|
+
}) : l.data.interfaces.map((e) => /* @__PURE__ */ w(Is, {
|
|
4901
5057
|
iface: e,
|
|
4902
5058
|
busy: f,
|
|
4903
5059
|
onStart: (t, n) => void y(e, !0, t, n),
|
|
@@ -4942,9 +5098,9 @@ function Ns(n) {
|
|
|
4942
5098
|
}
|
|
4943
5099
|
//#endregion
|
|
4944
5100
|
//#region src/page.tsx
|
|
4945
|
-
var
|
|
4946
|
-
function
|
|
4947
|
-
let n = t.trpc, { t: r } = Z(), [i, a] = ne("ccu"), [o, s] = ne("tab"), l = $(n, "listCcus",
|
|
5101
|
+
var Rs = K(Wo), zs = {};
|
|
5102
|
+
function Bs(t) {
|
|
5103
|
+
let n = t.trpc, { t: r } = Z(), [i, a] = ne("ccu"), [o, s] = ne("tab"), l = $(n, "listCcus", zs, Rs), u = l.data, f = e(() => u === void 0 || u.length === 0 ? null : u.find((e) => e.integrationId === i) ?? u.find((e) => e.connected) ?? u[0] ?? null, [u, i]), p = (e) => l.error === null ? u === void 0 ? /* @__PURE__ */ w(ie, { className: "h-32 w-full" }) : f === null ? /* @__PURE__ */ w(d, {
|
|
4948
5104
|
title: r("page.noCcu"),
|
|
4949
5105
|
description: r("page.noCcuHint")
|
|
4950
5106
|
}) : f.connected ? e : /* @__PURE__ */ w(d, {
|
|
@@ -4956,7 +5112,7 @@ function Is(t) {
|
|
|
4956
5112
|
onRetry: l.reload
|
|
4957
5113
|
}), h = f?.integrationId ?? "";
|
|
4958
5114
|
return /* @__PURE__ */ w(m, {
|
|
4959
|
-
icon:
|
|
5115
|
+
icon: _e,
|
|
4960
5116
|
title: r("page.title"),
|
|
4961
5117
|
subtitle: f === null ? r("page.subtitle") : f.name,
|
|
4962
5118
|
defaultSection: "overview",
|
|
@@ -4976,7 +5132,7 @@ function Is(t) {
|
|
|
4976
5132
|
{
|
|
4977
5133
|
id: "overview",
|
|
4978
5134
|
label: r("page.tabOverview"),
|
|
4979
|
-
content: p(/* @__PURE__ */ w(
|
|
5135
|
+
content: p(/* @__PURE__ */ w(js, {
|
|
4980
5136
|
trpc: n,
|
|
4981
5137
|
integrationId: h
|
|
4982
5138
|
}))
|
|
@@ -4984,7 +5140,7 @@ function Is(t) {
|
|
|
4984
5140
|
{
|
|
4985
5141
|
id: "devices",
|
|
4986
5142
|
label: r("page.tabDevices"),
|
|
4987
|
-
content: p(/* @__PURE__ */ w(
|
|
5143
|
+
content: p(/* @__PURE__ */ w(Es, {
|
|
4988
5144
|
trpc: n,
|
|
4989
5145
|
integrationId: h
|
|
4990
5146
|
}))
|
|
@@ -4992,7 +5148,7 @@ function Is(t) {
|
|
|
4992
5148
|
{
|
|
4993
5149
|
id: "heating",
|
|
4994
5150
|
label: r("page.tabHeating"),
|
|
4995
|
-
content: p(/* @__PURE__ */ w(
|
|
5151
|
+
content: p(/* @__PURE__ */ w(ks, {
|
|
4996
5152
|
trpc: n,
|
|
4997
5153
|
integrationId: h
|
|
4998
5154
|
}))
|
|
@@ -5000,7 +5156,7 @@ function Is(t) {
|
|
|
5000
5156
|
{
|
|
5001
5157
|
id: "pairing",
|
|
5002
5158
|
label: r("page.tabPairing"),
|
|
5003
|
-
content: p(/* @__PURE__ */ w(
|
|
5159
|
+
content: p(/* @__PURE__ */ w(Ls, {
|
|
5004
5160
|
trpc: n,
|
|
5005
5161
|
integrationId: h
|
|
5006
5162
|
}))
|
|
@@ -5009,4 +5165,4 @@ function Is(t) {
|
|
|
5009
5165
|
});
|
|
5010
5166
|
}
|
|
5011
5167
|
//#endregion
|
|
5012
|
-
export {
|
|
5168
|
+
export { Bs as default };
|