@ogc-maps/storybook-components 0.15.0 → 0.16.0
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/LICENSE +661 -0
- package/dist/{BasemapSwitcher-BW7lyZ2Y.js → BasemapSwitcher-DuqVusX0.js} +9 -9
- package/dist/CollapsibleControl-BTIkiTmU.js +60 -0
- package/dist/CoordinateDisplay-BblQ34mS.js +154 -0
- package/dist/{ExportButton-Ck1dESnc.js → ExportButton-C8hCCsav.js} +7 -7
- package/dist/{FeatureDetailPanel-CkFpdEKW.js → FeatureDetailPanel-DgCHiNi9.js} +16 -16
- package/dist/FeatureTooltip-DHjMZC0u.js +49 -0
- package/dist/{LayerPanel-C6H74vhO.js → LayerPanel-BkDbZ66Z.js} +28 -28
- package/dist/Legend-CvBd-v0n.js +285 -0
- package/dist/PropertyList-0EonV_BQ.js +33 -0
- package/dist/SearchPanel-DIb7aYVs.js +725 -0
- package/dist/components/BasemapSwitcher/index.js +1 -1
- package/dist/components/CollapsibleControl/CollapsibleControl.d.ts +4 -1
- package/dist/components/CollapsibleControl/CollapsibleControl.d.ts.map +1 -1
- package/dist/components/CollapsibleControl/index.js +1 -1
- package/dist/components/CompassControl/CompassControl.d.ts +19 -0
- package/dist/components/CompassControl/CompassControl.d.ts.map +1 -0
- package/dist/components/CompassControl/index.d.ts +3 -0
- package/dist/components/CompassControl/index.d.ts.map +1 -0
- package/dist/components/CoordinateDisplay/CoordinateDisplay.d.ts +35 -4
- package/dist/components/CoordinateDisplay/CoordinateDisplay.d.ts.map +1 -1
- package/dist/components/CoordinateDisplay/CoordinateDisplay.test.d.ts +2 -0
- package/dist/components/CoordinateDisplay/CoordinateDisplay.test.d.ts.map +1 -0
- package/dist/components/CoordinateDisplay/index.d.ts +1 -1
- package/dist/components/CoordinateDisplay/index.d.ts.map +1 -1
- package/dist/components/CoordinateDisplay/index.js +5 -3
- package/dist/components/Cql2FilterEditor/Cql2FilterEditor.d.ts.map +1 -1
- package/dist/components/Cql2FilterEditor/FilterRuleGroupEditor.d.ts.map +1 -1
- package/dist/components/Cql2FilterEditor/ParameterizableField.d.ts +30 -0
- package/dist/components/Cql2FilterEditor/ParameterizableField.d.ts.map +1 -0
- package/dist/components/Cql2FilterEditor/styles.d.ts +2 -2
- package/dist/components/Cql2FilterEditor/styles.d.ts.map +1 -1
- package/dist/components/ExportButton/index.js +1 -1
- package/dist/components/ExportModal/ExportModal.d.ts +20 -1
- package/dist/components/ExportModal/ExportModal.d.ts.map +1 -1
- package/dist/components/ExportModal/index.d.ts +1 -1
- package/dist/components/ExportModal/index.d.ts.map +1 -1
- package/dist/components/FeatureDetailPanel/index.js +1 -1
- package/dist/components/FeatureTooltip/index.js +1 -1
- package/dist/components/GlobalSearchBar/GlobalSearchBar.d.ts +25 -0
- package/dist/components/GlobalSearchBar/GlobalSearchBar.d.ts.map +1 -0
- package/dist/components/GlobalSearchBar/GlobalSearchBar.test.d.ts +2 -0
- package/dist/components/GlobalSearchBar/GlobalSearchBar.test.d.ts.map +1 -0
- package/dist/components/GlobalSearchBar/index.d.ts +3 -0
- package/dist/components/GlobalSearchBar/index.d.ts.map +1 -0
- package/dist/components/GlobalSearchConfigEditor/GlobalSearchConfigEditor.d.ts +22 -0
- package/dist/components/GlobalSearchConfigEditor/GlobalSearchConfigEditor.d.ts.map +1 -0
- package/dist/components/GlobalSearchConfigEditor/GlobalSearchConfigEditor.test.d.ts +2 -0
- package/dist/components/GlobalSearchConfigEditor/GlobalSearchConfigEditor.test.d.ts.map +1 -0
- package/dist/components/GlobalSearchConfigEditor/index.d.ts +3 -0
- package/dist/components/GlobalSearchConfigEditor/index.d.ts.map +1 -0
- package/dist/components/ImageryEditor/ImageryEditor.d.ts +0 -1
- package/dist/components/ImageryEditor/ImageryEditor.d.ts.map +1 -1
- package/dist/components/ImageryEditor/index.d.ts +2 -1
- package/dist/components/ImageryEditor/index.d.ts.map +1 -1
- package/dist/components/ImageryPanel/ImageryPanel.d.ts.map +1 -1
- package/dist/components/InfoControl/InfoControl.d.ts +12 -0
- package/dist/components/InfoControl/InfoControl.d.ts.map +1 -0
- package/dist/components/InfoControl/InfoModal.d.ts +16 -0
- package/dist/components/InfoControl/InfoModal.d.ts.map +1 -0
- package/dist/components/InfoControl/index.d.ts +5 -0
- package/dist/components/InfoControl/index.d.ts.map +1 -0
- package/dist/components/LayerEditor/LayerEditor.d.ts +6 -1
- package/dist/components/LayerEditor/LayerEditor.d.ts.map +1 -1
- package/dist/components/LayerEditor/LayerList.d.ts +8 -1
- package/dist/components/LayerEditor/LayerList.d.ts.map +1 -1
- package/dist/components/LayerEditor/index.d.ts +1 -1
- package/dist/components/LayerEditor/index.d.ts.map +1 -1
- package/dist/components/LayerPanel/index.js +1 -1
- package/dist/components/Legend/Legend.d.ts +7 -1
- package/dist/components/Legend/Legend.d.ts.map +1 -1
- package/dist/components/Legend/index.js +1 -1
- package/dist/components/PropertyFilterPanel/PropertyFilterPanel.d.ts +21 -0
- package/dist/components/PropertyFilterPanel/PropertyFilterPanel.d.ts.map +1 -0
- package/dist/components/PropertyFilterPanel/index.d.ts +3 -0
- package/dist/components/PropertyFilterPanel/index.d.ts.map +1 -0
- package/dist/components/QueryPanel/QueryPanel.d.ts.map +1 -1
- package/dist/components/ResultsDrawer/ResultsDrawer.d.ts +12 -1
- package/dist/components/ResultsDrawer/ResultsDrawer.d.ts.map +1 -1
- package/dist/components/ResultsDrawer/index.d.ts +1 -1
- package/dist/components/ResultsDrawer/index.d.ts.map +1 -1
- package/dist/components/ResultsDrawer/tableUtils.d.ts +11 -0
- package/dist/components/ResultsDrawer/tableUtils.d.ts.map +1 -0
- package/dist/components/ScaleBarControl/ScaleBarControl.d.ts +32 -0
- package/dist/components/ScaleBarControl/ScaleBarControl.d.ts.map +1 -0
- package/dist/components/ScaleBarControl/index.d.ts +2 -0
- package/dist/components/ScaleBarControl/index.d.ts.map +1 -0
- package/dist/components/SearchPanel/SearchPanel.d.ts +15 -2
- package/dist/components/SearchPanel/SearchPanel.d.ts.map +1 -1
- package/dist/components/SearchPanel/index.js +1 -1
- package/dist/components/SideMenuPanel/SideMenuPanel.d.ts +51 -0
- package/dist/components/SideMenuPanel/SideMenuPanel.d.ts.map +1 -0
- package/dist/components/SideMenuPanel/index.d.ts +3 -0
- package/dist/components/SideMenuPanel/index.d.ts.map +1 -0
- package/dist/components/SourceEditor/SourceEditor.d.ts +3 -1
- package/dist/components/SourceEditor/SourceEditor.d.ts.map +1 -1
- package/dist/components/SourceEditor/SourceList.d.ts +6 -1
- package/dist/components/SourceEditor/SourceList.d.ts.map +1 -1
- package/dist/components/SourceEditor/index.d.ts +1 -1
- package/dist/components/SourceEditor/index.d.ts.map +1 -1
- package/dist/components/StyleEditor/DataDrivenColorEditor.d.ts +6 -1
- package/dist/components/StyleEditor/DataDrivenColorEditor.d.ts.map +1 -1
- package/dist/components/StyleEditor/PropertyField.d.ts +4 -1
- package/dist/components/StyleEditor/PropertyField.d.ts.map +1 -1
- package/dist/components/StyleEditor/PropertyGroup.d.ts +4 -1
- package/dist/components/StyleEditor/PropertyGroup.d.ts.map +1 -1
- package/dist/components/StyleEditor/StyleEditor.d.ts +5 -1
- package/dist/components/StyleEditor/StyleEditor.d.ts.map +1 -1
- package/dist/components/UIConfigEditor/UIConfigEditor.d.ts +13 -2
- package/dist/components/UIConfigEditor/UIConfigEditor.d.ts.map +1 -1
- package/dist/components/UserMenu/UserMenu.d.ts +15 -0
- package/dist/components/UserMenu/UserMenu.d.ts.map +1 -0
- package/dist/components/UserMenu/index.d.ts +3 -0
- package/dist/components/UserMenu/index.d.ts.map +1 -0
- package/dist/components/ViewEditor/ViewEditor.d.ts.map +1 -1
- package/dist/components/index.d.ts +22 -5
- package/dist/components/index.d.ts.map +1 -1
- package/dist/components/shared/controlIcons.d.ts +10 -0
- package/dist/components/shared/controlIcons.d.ts.map +1 -0
- package/dist/{geo-BXaVaxak.js → geo-DUdRIR7u.js} +1288 -1219
- package/dist/hooks/index.js +2 -2
- package/dist/hooks/useExport.d.ts +6 -0
- package/dist/hooks/useExport.d.ts.map +1 -1
- package/dist/id-C2J6iu8_.js +11 -0
- package/dist/{index-CzYEPGO9.js → index-BtQnyWPg.js} +1318 -1171
- package/dist/main.js +13448 -2959
- package/dist/schemas/config.d.ts +341 -2
- package/dist/schemas/config.d.ts.map +1 -1
- package/dist/schemas/index.d.ts +1 -1
- package/dist/schemas/index.d.ts.map +1 -1
- package/dist/schemas/index.js +35 -24
- package/dist/style.css +1 -1
- package/dist/types/index.d.ts +10 -2
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/index.js +56 -44
- package/dist/useSelection-BFHYsPvU.js +224 -0
- package/dist/utils/colorPalettes.d.ts +4 -2
- package/dist/utils/colorPalettes.d.ts.map +1 -1
- package/dist/utils/colorThemes.d.ts +12 -0
- package/dist/utils/colorThemes.d.ts.map +1 -0
- package/dist/utils/cql2.d.ts.map +1 -1
- package/dist/utils/exportConverters.d.ts.map +1 -1
- package/dist/utils/geo.d.ts +53 -0
- package/dist/utils/geo.d.ts.map +1 -1
- package/dist/utils/id.d.ts +2 -0
- package/dist/utils/id.d.ts.map +1 -0
- package/dist/utils/index.d.ts +4 -0
- package/dist/utils/index.d.ts.map +1 -1
- package/dist/utils/index.js +352 -150
- package/dist/utils/ogcApi.d.ts +10 -5
- package/dist/utils/ogcApi.d.ts.map +1 -1
- package/dist/utils/propertyFilters.d.ts +35 -0
- package/dist/utils/propertyFilters.d.ts.map +1 -0
- package/dist/utils/queryParameters.d.ts +1 -0
- package/dist/utils/queryParameters.d.ts.map +1 -1
- package/dist/utils/slugify.d.ts +2 -0
- package/dist/utils/slugify.d.ts.map +1 -0
- package/package.json +13 -7
- package/dist/CollapsibleControl-qo9daiD8.js +0 -53
- package/dist/CoordinateDisplay-PxPmVjpm.js +0 -47
- package/dist/FeatureTooltip-DxzN-jnp.js +0 -49
- package/dist/Legend-BLWBzD7Y.js +0 -275
- package/dist/PropertyList-BGXHLVBM.js +0 -33
- package/dist/SearchPanel-4Y12jfuP.js +0 -401
- package/dist/useSelection-B1RnQZlj.js +0 -206
|
@@ -1,37 +1,37 @@
|
|
|
1
1
|
function l(e, t, n) {
|
|
2
|
-
function o(
|
|
3
|
-
if (
|
|
2
|
+
function o(a, c) {
|
|
3
|
+
if (a._zod || Object.defineProperty(a, "_zod", {
|
|
4
4
|
value: {
|
|
5
|
-
def:
|
|
5
|
+
def: c,
|
|
6
6
|
constr: s,
|
|
7
7
|
traits: /* @__PURE__ */ new Set()
|
|
8
8
|
},
|
|
9
9
|
enumerable: !1
|
|
10
|
-
}),
|
|
10
|
+
}), a._zod.traits.has(e))
|
|
11
11
|
return;
|
|
12
|
-
|
|
12
|
+
a._zod.traits.add(e), t(a, c);
|
|
13
13
|
const u = s.prototype, p = Object.keys(u);
|
|
14
14
|
for (let f = 0; f < p.length; f++) {
|
|
15
|
-
const
|
|
16
|
-
|
|
15
|
+
const _ = p[f];
|
|
16
|
+
_ in a || (a[_] = u[_].bind(a));
|
|
17
17
|
}
|
|
18
18
|
}
|
|
19
19
|
const r = (n == null ? void 0 : n.Parent) ?? Object;
|
|
20
20
|
class i extends r {
|
|
21
21
|
}
|
|
22
22
|
Object.defineProperty(i, "name", { value: e });
|
|
23
|
-
function s(
|
|
24
|
-
var
|
|
23
|
+
function s(a) {
|
|
24
|
+
var c;
|
|
25
25
|
const u = n != null && n.Parent ? new i() : this;
|
|
26
|
-
o(u,
|
|
26
|
+
o(u, a), (c = u._zod).deferred ?? (c.deferred = []);
|
|
27
27
|
for (const p of u._zod.deferred)
|
|
28
28
|
p();
|
|
29
29
|
return u;
|
|
30
30
|
}
|
|
31
31
|
return Object.defineProperty(s, "init", { value: o }), Object.defineProperty(s, Symbol.hasInstance, {
|
|
32
|
-
value: (
|
|
33
|
-
var
|
|
34
|
-
return n != null && n.Parent &&
|
|
32
|
+
value: (a) => {
|
|
33
|
+
var c, u;
|
|
34
|
+
return n != null && n.Parent && a instanceof n.Parent ? !0 : (u = (c = a == null ? void 0 : a._zod) == null ? void 0 : c.traits) == null ? void 0 : u.has(e);
|
|
35
35
|
}
|
|
36
36
|
}), Object.defineProperty(s, "name", { value: e }), s;
|
|
37
37
|
}
|
|
@@ -40,23 +40,23 @@ class q extends Error {
|
|
|
40
40
|
super("Encountered Promise during synchronous parse. Use .parseAsync() instead.");
|
|
41
41
|
}
|
|
42
42
|
}
|
|
43
|
-
class
|
|
43
|
+
class it extends Error {
|
|
44
44
|
constructor(t) {
|
|
45
45
|
super(`Encountered unidirectional transform during encode: ${t}`), this.name = "ZodEncodeError";
|
|
46
46
|
}
|
|
47
47
|
}
|
|
48
|
-
const
|
|
49
|
-
function
|
|
50
|
-
return
|
|
48
|
+
const st = {};
|
|
49
|
+
function M(e) {
|
|
50
|
+
return st;
|
|
51
51
|
}
|
|
52
|
-
function
|
|
52
|
+
function at(e) {
|
|
53
53
|
const t = Object.values(e).filter((o) => typeof o == "number");
|
|
54
54
|
return Object.entries(e).filter(([o, r]) => t.indexOf(+o) === -1).map(([o, r]) => r);
|
|
55
55
|
}
|
|
56
|
-
function
|
|
56
|
+
function we(e, t) {
|
|
57
57
|
return typeof t == "bigint" ? t.toString() : t;
|
|
58
58
|
}
|
|
59
|
-
function
|
|
59
|
+
function fe(e) {
|
|
60
60
|
return {
|
|
61
61
|
get value() {
|
|
62
62
|
{
|
|
@@ -69,22 +69,22 @@ function pe(e) {
|
|
|
69
69
|
function $e(e) {
|
|
70
70
|
return e == null;
|
|
71
71
|
}
|
|
72
|
-
function
|
|
72
|
+
function Oe(e) {
|
|
73
73
|
const t = e.startsWith("^") ? 1 : 0, n = e.endsWith("$") ? e.length - 1 : e.length;
|
|
74
74
|
return e.slice(t, n);
|
|
75
75
|
}
|
|
76
|
-
function
|
|
76
|
+
function Gt(e, t) {
|
|
77
77
|
const n = (e.toString().split(".")[1] || "").length, o = t.toString();
|
|
78
78
|
let r = (o.split(".")[1] || "").length;
|
|
79
79
|
if (r === 0 && /\d?e-\d?/.test(o)) {
|
|
80
|
-
const
|
|
81
|
-
|
|
80
|
+
const c = o.match(/\d?e-(\d?)/);
|
|
81
|
+
c != null && c[1] && (r = Number.parseInt(c[1]));
|
|
82
82
|
}
|
|
83
|
-
const i = n > r ? n : r, s = Number.parseInt(e.toFixed(i).replace(".", "")),
|
|
84
|
-
return s %
|
|
83
|
+
const i = n > r ? n : r, s = Number.parseInt(e.toFixed(i).replace(".", "")), a = Number.parseInt(t.toFixed(i).replace(".", ""));
|
|
84
|
+
return s % a / 10 ** i;
|
|
85
85
|
}
|
|
86
86
|
const je = Symbol("evaluating");
|
|
87
|
-
function
|
|
87
|
+
function w(e, t, n) {
|
|
88
88
|
let o;
|
|
89
89
|
Object.defineProperty(e, t, {
|
|
90
90
|
get() {
|
|
@@ -108,7 +108,7 @@ function W(e, t, n) {
|
|
|
108
108
|
configurable: !0
|
|
109
109
|
});
|
|
110
110
|
}
|
|
111
|
-
function
|
|
111
|
+
function V(...e) {
|
|
112
112
|
const t = {};
|
|
113
113
|
for (const n of e) {
|
|
114
114
|
const o = Object.getOwnPropertyDescriptors(n);
|
|
@@ -116,18 +116,18 @@ function J(...e) {
|
|
|
116
116
|
}
|
|
117
117
|
return Object.defineProperties({}, t);
|
|
118
118
|
}
|
|
119
|
-
function
|
|
119
|
+
function xe(e) {
|
|
120
120
|
return JSON.stringify(e);
|
|
121
121
|
}
|
|
122
|
-
function
|
|
122
|
+
function Kt(e) {
|
|
123
123
|
return e.toLowerCase().trim().replace(/[^\w\s-]/g, "").replace(/[\s_-]+/g, "-").replace(/^-+|-+$/g, "");
|
|
124
124
|
}
|
|
125
|
-
const
|
|
125
|
+
const ct = "captureStackTrace" in Error ? Error.captureStackTrace : (...e) => {
|
|
126
126
|
};
|
|
127
|
-
function
|
|
127
|
+
function ne(e) {
|
|
128
128
|
return typeof e == "object" && e !== null && !Array.isArray(e);
|
|
129
129
|
}
|
|
130
|
-
const
|
|
130
|
+
const qt = fe(() => {
|
|
131
131
|
var e;
|
|
132
132
|
if (typeof navigator < "u" && ((e = navigator == null ? void 0 : navigator.userAgent) != null && e.includes("Cloudflare")))
|
|
133
133
|
return !1;
|
|
@@ -139,22 +139,22 @@ const Mt = pe(() => {
|
|
|
139
139
|
}
|
|
140
140
|
});
|
|
141
141
|
function Y(e) {
|
|
142
|
-
if (
|
|
142
|
+
if (ne(e) === !1)
|
|
143
143
|
return !1;
|
|
144
144
|
const t = e.constructor;
|
|
145
145
|
if (t === void 0 || typeof t != "function")
|
|
146
146
|
return !0;
|
|
147
147
|
const n = t.prototype;
|
|
148
|
-
return !(
|
|
148
|
+
return !(ne(n) === !1 || Object.prototype.hasOwnProperty.call(n, "isPrototypeOf") === !1);
|
|
149
149
|
}
|
|
150
|
-
function
|
|
150
|
+
function ut(e) {
|
|
151
151
|
return Y(e) ? { ...e } : Array.isArray(e) ? [...e] : e;
|
|
152
152
|
}
|
|
153
|
-
const
|
|
153
|
+
const Yt = /* @__PURE__ */ new Set(["string", "number", "symbol"]);
|
|
154
154
|
function X(e) {
|
|
155
155
|
return e.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
|
|
156
156
|
}
|
|
157
|
-
function
|
|
157
|
+
function U(e, t, n) {
|
|
158
158
|
const o = new e._zod.constr(t ?? e._zod.def);
|
|
159
159
|
return (!t || n != null && n.parent) && (o._zod.parent = e), o;
|
|
160
160
|
}
|
|
@@ -171,53 +171,53 @@ function m(e) {
|
|
|
171
171
|
}
|
|
172
172
|
return delete t.message, typeof t.error == "string" ? { ...t, error: () => t.error } : t;
|
|
173
173
|
}
|
|
174
|
-
function
|
|
174
|
+
function Xt(e) {
|
|
175
175
|
return Object.keys(e).filter((t) => e[t]._zod.optin === "optional" && e[t]._zod.optout === "optional");
|
|
176
176
|
}
|
|
177
|
-
const
|
|
177
|
+
const Ht = {
|
|
178
178
|
safeint: [Number.MIN_SAFE_INTEGER, Number.MAX_SAFE_INTEGER],
|
|
179
179
|
int32: [-2147483648, 2147483647],
|
|
180
180
|
uint32: [0, 4294967295],
|
|
181
181
|
float32: [-34028234663852886e22, 34028234663852886e22],
|
|
182
182
|
float64: [-Number.MAX_VALUE, Number.MAX_VALUE]
|
|
183
183
|
};
|
|
184
|
-
function
|
|
184
|
+
function Qt(e, t) {
|
|
185
185
|
const n = e._zod.def, o = n.checks;
|
|
186
186
|
if (o && o.length > 0)
|
|
187
187
|
throw new Error(".pick() cannot be used on object schemas containing refinements");
|
|
188
|
-
const i =
|
|
188
|
+
const i = V(e._zod.def, {
|
|
189
189
|
get shape() {
|
|
190
190
|
const s = {};
|
|
191
|
-
for (const
|
|
192
|
-
if (!(
|
|
193
|
-
throw new Error(`Unrecognized key: "${
|
|
194
|
-
t[
|
|
191
|
+
for (const a in t) {
|
|
192
|
+
if (!(a in n.shape))
|
|
193
|
+
throw new Error(`Unrecognized key: "${a}"`);
|
|
194
|
+
t[a] && (s[a] = n.shape[a]);
|
|
195
195
|
}
|
|
196
196
|
return W(this, "shape", s), s;
|
|
197
197
|
},
|
|
198
198
|
checks: []
|
|
199
199
|
});
|
|
200
|
-
return
|
|
200
|
+
return U(e, i);
|
|
201
201
|
}
|
|
202
|
-
function
|
|
202
|
+
function en(e, t) {
|
|
203
203
|
const n = e._zod.def, o = n.checks;
|
|
204
204
|
if (o && o.length > 0)
|
|
205
205
|
throw new Error(".omit() cannot be used on object schemas containing refinements");
|
|
206
|
-
const i =
|
|
206
|
+
const i = V(e._zod.def, {
|
|
207
207
|
get shape() {
|
|
208
208
|
const s = { ...e._zod.def.shape };
|
|
209
|
-
for (const
|
|
210
|
-
if (!(
|
|
211
|
-
throw new Error(`Unrecognized key: "${
|
|
212
|
-
t[
|
|
209
|
+
for (const a in t) {
|
|
210
|
+
if (!(a in n.shape))
|
|
211
|
+
throw new Error(`Unrecognized key: "${a}"`);
|
|
212
|
+
t[a] && delete s[a];
|
|
213
213
|
}
|
|
214
214
|
return W(this, "shape", s), s;
|
|
215
215
|
},
|
|
216
216
|
checks: []
|
|
217
217
|
});
|
|
218
|
-
return
|
|
218
|
+
return U(e, i);
|
|
219
219
|
}
|
|
220
|
-
function
|
|
220
|
+
function tn(e, t) {
|
|
221
221
|
if (!Y(t))
|
|
222
222
|
throw new Error("Invalid input to extend: expected a plain object");
|
|
223
223
|
const n = e._zod.def.checks;
|
|
@@ -227,27 +227,27 @@ function Gt(e, t) {
|
|
|
227
227
|
if (Object.getOwnPropertyDescriptor(i, s) !== void 0)
|
|
228
228
|
throw new Error("Cannot overwrite keys on object schemas containing refinements. Use `.safeExtend()` instead.");
|
|
229
229
|
}
|
|
230
|
-
const r =
|
|
230
|
+
const r = V(e._zod.def, {
|
|
231
231
|
get shape() {
|
|
232
232
|
const i = { ...e._zod.def.shape, ...t };
|
|
233
233
|
return W(this, "shape", i), i;
|
|
234
234
|
}
|
|
235
235
|
});
|
|
236
|
-
return
|
|
236
|
+
return U(e, r);
|
|
237
237
|
}
|
|
238
|
-
function
|
|
238
|
+
function nn(e, t) {
|
|
239
239
|
if (!Y(t))
|
|
240
240
|
throw new Error("Invalid input to safeExtend: expected a plain object");
|
|
241
|
-
const n =
|
|
241
|
+
const n = V(e._zod.def, {
|
|
242
242
|
get shape() {
|
|
243
243
|
const o = { ...e._zod.def.shape, ...t };
|
|
244
244
|
return W(this, "shape", o), o;
|
|
245
245
|
}
|
|
246
246
|
});
|
|
247
|
-
return
|
|
247
|
+
return U(e, n);
|
|
248
248
|
}
|
|
249
|
-
function
|
|
250
|
-
const n =
|
|
249
|
+
function on(e, t) {
|
|
250
|
+
const n = V(e._zod.def, {
|
|
251
251
|
get shape() {
|
|
252
252
|
const o = { ...e._zod.def.shape, ...t._zod.def.shape };
|
|
253
253
|
return W(this, "shape", o), o;
|
|
@@ -258,38 +258,38 @@ function Yt(e, t) {
|
|
|
258
258
|
checks: []
|
|
259
259
|
// delete existing checks
|
|
260
260
|
});
|
|
261
|
-
return
|
|
261
|
+
return U(e, n);
|
|
262
262
|
}
|
|
263
|
-
function
|
|
263
|
+
function rn(e, t, n) {
|
|
264
264
|
const r = t._zod.def.checks;
|
|
265
265
|
if (r && r.length > 0)
|
|
266
266
|
throw new Error(".partial() cannot be used on object schemas containing refinements");
|
|
267
|
-
const s =
|
|
267
|
+
const s = V(t._zod.def, {
|
|
268
268
|
get shape() {
|
|
269
|
-
const
|
|
269
|
+
const a = t._zod.def.shape, c = { ...a };
|
|
270
270
|
if (n)
|
|
271
271
|
for (const u in n) {
|
|
272
|
-
if (!(u in
|
|
272
|
+
if (!(u in a))
|
|
273
273
|
throw new Error(`Unrecognized key: "${u}"`);
|
|
274
|
-
n[u] && (
|
|
274
|
+
n[u] && (c[u] = e ? new e({
|
|
275
275
|
type: "optional",
|
|
276
|
-
innerType:
|
|
277
|
-
}) :
|
|
276
|
+
innerType: a[u]
|
|
277
|
+
}) : a[u]);
|
|
278
278
|
}
|
|
279
279
|
else
|
|
280
|
-
for (const u in
|
|
281
|
-
|
|
280
|
+
for (const u in a)
|
|
281
|
+
c[u] = e ? new e({
|
|
282
282
|
type: "optional",
|
|
283
|
-
innerType:
|
|
284
|
-
}) :
|
|
285
|
-
return W(this, "shape",
|
|
283
|
+
innerType: a[u]
|
|
284
|
+
}) : a[u];
|
|
285
|
+
return W(this, "shape", c), c;
|
|
286
286
|
},
|
|
287
287
|
checks: []
|
|
288
288
|
});
|
|
289
|
-
return
|
|
289
|
+
return U(t, s);
|
|
290
290
|
}
|
|
291
|
-
function
|
|
292
|
-
const o =
|
|
291
|
+
function sn(e, t, n) {
|
|
292
|
+
const o = V(t._zod.def, {
|
|
293
293
|
get shape() {
|
|
294
294
|
const r = t._zod.def.shape, i = { ...r };
|
|
295
295
|
if (n)
|
|
@@ -310,9 +310,9 @@ function Ht(e, t, n) {
|
|
|
310
310
|
return W(this, "shape", i), i;
|
|
311
311
|
}
|
|
312
312
|
});
|
|
313
|
-
return
|
|
313
|
+
return U(t, o);
|
|
314
314
|
}
|
|
315
|
-
function
|
|
315
|
+
function G(e, t = 0) {
|
|
316
316
|
var n;
|
|
317
317
|
if (e.aborted === !0)
|
|
318
318
|
return !0;
|
|
@@ -327,22 +327,22 @@ function B(e, t) {
|
|
|
327
327
|
return (o = n).path ?? (o.path = []), n.path.unshift(e), n;
|
|
328
328
|
});
|
|
329
329
|
}
|
|
330
|
-
function
|
|
330
|
+
function ie(e) {
|
|
331
331
|
return typeof e == "string" ? e : e == null ? void 0 : e.message;
|
|
332
332
|
}
|
|
333
|
-
function
|
|
334
|
-
var r, i, s,
|
|
333
|
+
function J(e, t, n) {
|
|
334
|
+
var r, i, s, a, c, u;
|
|
335
335
|
const o = { ...e, path: e.path ?? [] };
|
|
336
336
|
if (!e.message) {
|
|
337
|
-
const p =
|
|
337
|
+
const p = ie((s = (i = (r = e.inst) == null ? void 0 : r._zod.def) == null ? void 0 : i.error) == null ? void 0 : s.call(i, e)) ?? ie((a = t == null ? void 0 : t.error) == null ? void 0 : a.call(t, e)) ?? ie((c = n.customError) == null ? void 0 : c.call(n, e)) ?? ie((u = n.localeError) == null ? void 0 : u.call(n, e)) ?? "Invalid input";
|
|
338
338
|
o.message = p;
|
|
339
339
|
}
|
|
340
340
|
return delete o.inst, delete o.continue, t != null && t.reportInput || delete o.input, o;
|
|
341
341
|
}
|
|
342
|
-
function
|
|
342
|
+
function Te(e) {
|
|
343
343
|
return Array.isArray(e) ? "array" : typeof e == "string" ? "string" : "unknown";
|
|
344
344
|
}
|
|
345
|
-
function
|
|
345
|
+
function oe(...e) {
|
|
346
346
|
const [t, n, o] = e;
|
|
347
347
|
return typeof t == "string" ? {
|
|
348
348
|
message: t,
|
|
@@ -351,25 +351,25 @@ function ne(...e) {
|
|
|
351
351
|
inst: o
|
|
352
352
|
} : { ...t };
|
|
353
353
|
}
|
|
354
|
-
const
|
|
354
|
+
const lt = (e, t) => {
|
|
355
355
|
e.name = "$ZodError", Object.defineProperty(e, "_zod", {
|
|
356
356
|
value: e._zod,
|
|
357
357
|
enumerable: !1
|
|
358
358
|
}), Object.defineProperty(e, "issues", {
|
|
359
359
|
value: t,
|
|
360
360
|
enumerable: !1
|
|
361
|
-
}), e.message = JSON.stringify(t,
|
|
361
|
+
}), e.message = JSON.stringify(t, we, 2), Object.defineProperty(e, "toString", {
|
|
362
362
|
value: () => e.message,
|
|
363
363
|
enumerable: !1
|
|
364
364
|
});
|
|
365
|
-
},
|
|
366
|
-
function
|
|
365
|
+
}, pt = l("$ZodError", lt), ft = l("$ZodError", lt, { Parent: Error });
|
|
366
|
+
function an(e, t = (n) => n.message) {
|
|
367
367
|
const n = {}, o = [];
|
|
368
368
|
for (const r of e.issues)
|
|
369
369
|
r.path.length > 0 ? (n[r.path[0]] = n[r.path[0]] || [], n[r.path[0]].push(t(r))) : o.push(t(r));
|
|
370
370
|
return { formErrors: o, fieldErrors: n };
|
|
371
371
|
}
|
|
372
|
-
function
|
|
372
|
+
function cn(e, t = (n) => n.message) {
|
|
373
373
|
const n = { _errors: [] }, o = (r) => {
|
|
374
374
|
for (const i of r.issues)
|
|
375
375
|
if (i.code === "invalid_union" && i.errors.length)
|
|
@@ -381,90 +381,90 @@ function en(e, t = (n) => n.message) {
|
|
|
381
381
|
else if (i.path.length === 0)
|
|
382
382
|
n._errors.push(t(i));
|
|
383
383
|
else {
|
|
384
|
-
let s = n,
|
|
385
|
-
for (;
|
|
386
|
-
const
|
|
387
|
-
|
|
384
|
+
let s = n, a = 0;
|
|
385
|
+
for (; a < i.path.length; ) {
|
|
386
|
+
const c = i.path[a];
|
|
387
|
+
a === i.path.length - 1 ? (s[c] = s[c] || { _errors: [] }, s[c]._errors.push(t(i))) : s[c] = s[c] || { _errors: [] }, s = s[c], a++;
|
|
388
388
|
}
|
|
389
389
|
}
|
|
390
390
|
};
|
|
391
391
|
return o(e), n;
|
|
392
392
|
}
|
|
393
|
-
const
|
|
393
|
+
const Ie = (e) => (t, n, o, r) => {
|
|
394
394
|
const i = o ? Object.assign(o, { async: !1 }) : { async: !1 }, s = t._zod.run({ value: n, issues: [] }, i);
|
|
395
395
|
if (s instanceof Promise)
|
|
396
396
|
throw new q();
|
|
397
397
|
if (s.issues.length) {
|
|
398
|
-
const
|
|
399
|
-
throw
|
|
398
|
+
const a = new ((r == null ? void 0 : r.Err) ?? e)(s.issues.map((c) => J(c, i, M())));
|
|
399
|
+
throw ct(a, r == null ? void 0 : r.callee), a;
|
|
400
400
|
}
|
|
401
401
|
return s.value;
|
|
402
402
|
}, Pe = (e) => async (t, n, o, r) => {
|
|
403
403
|
const i = o ? Object.assign(o, { async: !0 }) : { async: !0 };
|
|
404
404
|
let s = t._zod.run({ value: n, issues: [] }, i);
|
|
405
405
|
if (s instanceof Promise && (s = await s), s.issues.length) {
|
|
406
|
-
const
|
|
407
|
-
throw
|
|
406
|
+
const a = new ((r == null ? void 0 : r.Err) ?? e)(s.issues.map((c) => J(c, i, M())));
|
|
407
|
+
throw ct(a, r == null ? void 0 : r.callee), a;
|
|
408
408
|
}
|
|
409
409
|
return s.value;
|
|
410
|
-
},
|
|
410
|
+
}, de = (e) => (t, n, o) => {
|
|
411
411
|
const r = o ? { ...o, async: !1 } : { async: !1 }, i = t._zod.run({ value: n, issues: [] }, r);
|
|
412
412
|
if (i instanceof Promise)
|
|
413
413
|
throw new q();
|
|
414
414
|
return i.issues.length ? {
|
|
415
415
|
success: !1,
|
|
416
|
-
error: new (e ??
|
|
416
|
+
error: new (e ?? pt)(i.issues.map((s) => J(s, r, M())))
|
|
417
417
|
} : { success: !0, data: i.value };
|
|
418
|
-
},
|
|
418
|
+
}, un = /* @__PURE__ */ de(ft), he = (e) => async (t, n, o) => {
|
|
419
419
|
const r = o ? Object.assign(o, { async: !0 }) : { async: !0 };
|
|
420
420
|
let i = t._zod.run({ value: n, issues: [] }, r);
|
|
421
421
|
return i instanceof Promise && (i = await i), i.issues.length ? {
|
|
422
422
|
success: !1,
|
|
423
|
-
error: new e(i.issues.map((s) =>
|
|
423
|
+
error: new e(i.issues.map((s) => J(s, r, M())))
|
|
424
424
|
} : { success: !0, data: i.value };
|
|
425
|
-
},
|
|
425
|
+
}, ln = /* @__PURE__ */ he(ft), pn = (e) => (t, n, o) => {
|
|
426
426
|
const r = o ? Object.assign(o, { direction: "backward" }) : { direction: "backward" };
|
|
427
|
-
return
|
|
428
|
-
},
|
|
427
|
+
return Ie(e)(t, n, r);
|
|
428
|
+
}, fn = (e) => (t, n, o) => Ie(e)(t, n, o), dn = (e) => async (t, n, o) => {
|
|
429
429
|
const r = o ? Object.assign(o, { direction: "backward" }) : { direction: "backward" };
|
|
430
430
|
return Pe(e)(t, n, r);
|
|
431
|
-
},
|
|
432
|
-
const r = o ? Object.assign(o, { direction: "backward" }) : { direction: "backward" };
|
|
433
|
-
return fe(e)(t, n, r);
|
|
434
|
-
}, un = (e) => (t, n, o) => fe(e)(t, n, o), ln = (e) => async (t, n, o) => {
|
|
431
|
+
}, hn = (e) => async (t, n, o) => Pe(e)(t, n, o), mn = (e) => (t, n, o) => {
|
|
435
432
|
const r = o ? Object.assign(o, { direction: "backward" }) : { direction: "backward" };
|
|
436
433
|
return de(e)(t, n, r);
|
|
437
|
-
},
|
|
438
|
-
|
|
439
|
-
return
|
|
434
|
+
}, gn = (e) => (t, n, o) => de(e)(t, n, o), _n = (e) => async (t, n, o) => {
|
|
435
|
+
const r = o ? Object.assign(o, { direction: "backward" }) : { direction: "backward" };
|
|
436
|
+
return he(e)(t, n, r);
|
|
437
|
+
}, vn = (e) => async (t, n, o) => he(e)(t, n, o), yn = /^[cC][^\s-]{8,}$/, bn = /^[0-9a-z]+$/, wn = /^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$/, zn = /^[0-9a-vA-V]{20}$/, kn = /^[A-Za-z0-9]{27}$/, Sn = /^[a-zA-Z0-9_-]{21}$/, Zn = /^P(?:(\d+W)|(?!.*W)(?=\d|T\d)(\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+([.,]\d+)?S)?)?)$/, $n = /^([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})$/, Re = (e) => e ? new 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)$/, On = /^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$/, Tn = "^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$";
|
|
438
|
+
function In() {
|
|
439
|
+
return new RegExp(Tn, "u");
|
|
440
440
|
}
|
|
441
|
-
const
|
|
442
|
-
function
|
|
441
|
+
const Pn = /^(?:(?: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])$/, En = /^(([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}|:))$/, Nn = /^((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])$/, Cn = /^(([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])$/, An = /^$|^(?:[0-9a-zA-Z+/]{4})*(?:(?:[0-9a-zA-Z+/]{2}==)|(?:[0-9a-zA-Z+/]{3}=))?$/, dt = /^[A-Za-z0-9_-]*$/, jn = /^\+[1-9]\d{6,14}$/, ht = "(?:(?:\\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])))", xn = /* @__PURE__ */ new RegExp(`^${ht}$`);
|
|
442
|
+
function mt(e) {
|
|
443
443
|
const t = "(?:[01]\\d|2[0-3]):[0-5]\\d";
|
|
444
444
|
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+)?)?`;
|
|
445
445
|
}
|
|
446
|
-
function
|
|
447
|
-
return new RegExp(`^${
|
|
446
|
+
function Rn(e) {
|
|
447
|
+
return new RegExp(`^${mt(e)}$`);
|
|
448
448
|
}
|
|
449
|
-
function
|
|
450
|
-
const t =
|
|
449
|
+
function Dn(e) {
|
|
450
|
+
const t = mt({ precision: e.precision }), n = ["Z"];
|
|
451
451
|
e.local && n.push(""), e.offset && n.push("([+-](?:[01]\\d|2[0-3]):[0-5]\\d)");
|
|
452
452
|
const o = `${t}(?:${n.join("|")})`;
|
|
453
|
-
return new RegExp(`^${
|
|
453
|
+
return new RegExp(`^${ht}T(?:${o})$`);
|
|
454
454
|
}
|
|
455
|
-
const
|
|
455
|
+
const Fn = (e) => {
|
|
456
456
|
const t = e ? `[\\s\\S]{${(e == null ? void 0 : e.minimum) ?? 0},${(e == null ? void 0 : e.maximum) ?? ""}}` : "[\\s\\S]*";
|
|
457
457
|
return new RegExp(`^${t}$`);
|
|
458
|
-
},
|
|
458
|
+
}, Ln = /^-?\d+$/, gt = /^-?\d+(?:\.\d+)?$/, Un = /^(?:true|false)$/i, Mn = /^null$/i, Jn = /^[^A-Z]*$/, Vn = /^[^a-z]*$/, j = /* @__PURE__ */ l("$ZodCheck", (e, t) => {
|
|
459
459
|
var n;
|
|
460
460
|
e._zod ?? (e._zod = {}), e._zod.def = t, (n = e._zod).onattach ?? (n.onattach = []);
|
|
461
|
-
}),
|
|
461
|
+
}), _t = {
|
|
462
462
|
number: "number",
|
|
463
463
|
bigint: "bigint",
|
|
464
464
|
object: "date"
|
|
465
|
-
},
|
|
466
|
-
|
|
467
|
-
const n =
|
|
465
|
+
}, vt = /* @__PURE__ */ l("$ZodCheckLessThan", (e, t) => {
|
|
466
|
+
j.init(e, t);
|
|
467
|
+
const n = _t[typeof t.value];
|
|
468
468
|
e._zod.onattach.push((o) => {
|
|
469
469
|
const r = o._zod.bag, i = (t.inclusive ? r.maximum : r.exclusiveMaximum) ?? Number.POSITIVE_INFINITY;
|
|
470
470
|
t.value < i && (t.inclusive ? r.maximum = t.value : r.exclusiveMaximum = t.value);
|
|
@@ -479,9 +479,9 @@ const Nn = (e) => {
|
|
|
479
479
|
continue: !t.abort
|
|
480
480
|
});
|
|
481
481
|
};
|
|
482
|
-
}),
|
|
483
|
-
|
|
484
|
-
const n =
|
|
482
|
+
}), yt = /* @__PURE__ */ l("$ZodCheckGreaterThan", (e, t) => {
|
|
483
|
+
j.init(e, t);
|
|
484
|
+
const n = _t[typeof t.value];
|
|
485
485
|
e._zod.onattach.push((o) => {
|
|
486
486
|
const r = o._zod.bag, i = (t.inclusive ? r.minimum : r.exclusiveMinimum) ?? Number.NEGATIVE_INFINITY;
|
|
487
487
|
t.value > i && (t.inclusive ? r.minimum = t.value : r.exclusiveMinimum = t.value);
|
|
@@ -496,14 +496,14 @@ const Nn = (e) => {
|
|
|
496
496
|
continue: !t.abort
|
|
497
497
|
});
|
|
498
498
|
};
|
|
499
|
-
}),
|
|
500
|
-
|
|
499
|
+
}), Bn = /* @__PURE__ */ l("$ZodCheckMultipleOf", (e, t) => {
|
|
500
|
+
j.init(e, t), e._zod.onattach.push((n) => {
|
|
501
501
|
var o;
|
|
502
502
|
(o = n._zod.bag).multipleOf ?? (o.multipleOf = t.value);
|
|
503
503
|
}), e._zod.check = (n) => {
|
|
504
504
|
if (typeof n.value != typeof t.value)
|
|
505
505
|
throw new Error("Cannot mix number and bigint in multiple_of check.");
|
|
506
|
-
(typeof n.value == "bigint" ? n.value % t.value === BigInt(0) :
|
|
506
|
+
(typeof n.value == "bigint" ? n.value % t.value === BigInt(0) : Gt(n.value, t.value) === 0) || n.issues.push({
|
|
507
507
|
origin: typeof n.value,
|
|
508
508
|
code: "not_multiple_of",
|
|
509
509
|
divisor: t.value,
|
|
@@ -512,30 +512,30 @@ const Nn = (e) => {
|
|
|
512
512
|
continue: !t.abort
|
|
513
513
|
});
|
|
514
514
|
};
|
|
515
|
-
}),
|
|
515
|
+
}), Wn = /* @__PURE__ */ l("$ZodCheckNumberFormat", (e, t) => {
|
|
516
516
|
var s;
|
|
517
|
-
|
|
518
|
-
const n = (s = t.format) == null ? void 0 : s.includes("int"), o = n ? "int" : "number", [r, i] =
|
|
519
|
-
e._zod.onattach.push((
|
|
520
|
-
const
|
|
521
|
-
|
|
522
|
-
}), e._zod.check = (
|
|
523
|
-
const
|
|
517
|
+
j.init(e, t), t.format = t.format || "float64";
|
|
518
|
+
const n = (s = t.format) == null ? void 0 : s.includes("int"), o = n ? "int" : "number", [r, i] = Ht[t.format];
|
|
519
|
+
e._zod.onattach.push((a) => {
|
|
520
|
+
const c = a._zod.bag;
|
|
521
|
+
c.format = t.format, c.minimum = r, c.maximum = i, n && (c.pattern = Ln);
|
|
522
|
+
}), e._zod.check = (a) => {
|
|
523
|
+
const c = a.value;
|
|
524
524
|
if (n) {
|
|
525
|
-
if (!Number.isInteger(
|
|
526
|
-
|
|
525
|
+
if (!Number.isInteger(c)) {
|
|
526
|
+
a.issues.push({
|
|
527
527
|
expected: o,
|
|
528
528
|
format: t.format,
|
|
529
529
|
code: "invalid_type",
|
|
530
530
|
continue: !1,
|
|
531
|
-
input:
|
|
531
|
+
input: c,
|
|
532
532
|
inst: e
|
|
533
533
|
});
|
|
534
534
|
return;
|
|
535
535
|
}
|
|
536
|
-
if (!Number.isSafeInteger(
|
|
537
|
-
|
|
538
|
-
input:
|
|
536
|
+
if (!Number.isSafeInteger(c)) {
|
|
537
|
+
c > 0 ? a.issues.push({
|
|
538
|
+
input: c,
|
|
539
539
|
code: "too_big",
|
|
540
540
|
maximum: Number.MAX_SAFE_INTEGER,
|
|
541
541
|
note: "Integers must be within the safe integer range.",
|
|
@@ -543,8 +543,8 @@ const Nn = (e) => {
|
|
|
543
543
|
origin: o,
|
|
544
544
|
inclusive: !0,
|
|
545
545
|
continue: !t.abort
|
|
546
|
-
}) :
|
|
547
|
-
input:
|
|
546
|
+
}) : a.issues.push({
|
|
547
|
+
input: c,
|
|
548
548
|
code: "too_small",
|
|
549
549
|
minimum: Number.MIN_SAFE_INTEGER,
|
|
550
550
|
note: "Integers must be within the safe integer range.",
|
|
@@ -556,17 +556,17 @@ const Nn = (e) => {
|
|
|
556
556
|
return;
|
|
557
557
|
}
|
|
558
558
|
}
|
|
559
|
-
|
|
559
|
+
c < r && a.issues.push({
|
|
560
560
|
origin: "number",
|
|
561
|
-
input:
|
|
561
|
+
input: c,
|
|
562
562
|
code: "too_small",
|
|
563
563
|
minimum: r,
|
|
564
564
|
inclusive: !0,
|
|
565
565
|
inst: e,
|
|
566
566
|
continue: !t.abort
|
|
567
|
-
}),
|
|
567
|
+
}), c > i && a.issues.push({
|
|
568
568
|
origin: "number",
|
|
569
|
-
input:
|
|
569
|
+
input: c,
|
|
570
570
|
code: "too_big",
|
|
571
571
|
maximum: i,
|
|
572
572
|
inclusive: !0,
|
|
@@ -574,9 +574,9 @@ const Nn = (e) => {
|
|
|
574
574
|
continue: !t.abort
|
|
575
575
|
});
|
|
576
576
|
};
|
|
577
|
-
}),
|
|
577
|
+
}), Gn = /* @__PURE__ */ l("$ZodCheckMaxLength", (e, t) => {
|
|
578
578
|
var n;
|
|
579
|
-
|
|
579
|
+
j.init(e, t), (n = e._zod.def).when ?? (n.when = (o) => {
|
|
580
580
|
const r = o.value;
|
|
581
581
|
return !$e(r) && r.length !== void 0;
|
|
582
582
|
}), e._zod.onattach.push((o) => {
|
|
@@ -586,7 +586,7 @@ const Nn = (e) => {
|
|
|
586
586
|
const r = o.value;
|
|
587
587
|
if (r.length <= t.maximum)
|
|
588
588
|
return;
|
|
589
|
-
const s =
|
|
589
|
+
const s = Te(r);
|
|
590
590
|
o.issues.push({
|
|
591
591
|
origin: s,
|
|
592
592
|
code: "too_big",
|
|
@@ -597,9 +597,9 @@ const Nn = (e) => {
|
|
|
597
597
|
continue: !t.abort
|
|
598
598
|
});
|
|
599
599
|
};
|
|
600
|
-
}),
|
|
600
|
+
}), Kn = /* @__PURE__ */ l("$ZodCheckMinLength", (e, t) => {
|
|
601
601
|
var n;
|
|
602
|
-
|
|
602
|
+
j.init(e, t), (n = e._zod.def).when ?? (n.when = (o) => {
|
|
603
603
|
const r = o.value;
|
|
604
604
|
return !$e(r) && r.length !== void 0;
|
|
605
605
|
}), e._zod.onattach.push((o) => {
|
|
@@ -609,7 +609,7 @@ const Nn = (e) => {
|
|
|
609
609
|
const r = o.value;
|
|
610
610
|
if (r.length >= t.minimum)
|
|
611
611
|
return;
|
|
612
|
-
const s =
|
|
612
|
+
const s = Te(r);
|
|
613
613
|
o.issues.push({
|
|
614
614
|
origin: s,
|
|
615
615
|
code: "too_small",
|
|
@@ -620,9 +620,9 @@ const Nn = (e) => {
|
|
|
620
620
|
continue: !t.abort
|
|
621
621
|
});
|
|
622
622
|
};
|
|
623
|
-
}),
|
|
623
|
+
}), qn = /* @__PURE__ */ l("$ZodCheckLengthEquals", (e, t) => {
|
|
624
624
|
var n;
|
|
625
|
-
|
|
625
|
+
j.init(e, t), (n = e._zod.def).when ?? (n.when = (o) => {
|
|
626
626
|
const r = o.value;
|
|
627
627
|
return !$e(r) && r.length !== void 0;
|
|
628
628
|
}), e._zod.onattach.push((o) => {
|
|
@@ -632,10 +632,10 @@ const Nn = (e) => {
|
|
|
632
632
|
const r = o.value, i = r.length;
|
|
633
633
|
if (i === t.length)
|
|
634
634
|
return;
|
|
635
|
-
const s =
|
|
635
|
+
const s = Te(r), a = i > t.length;
|
|
636
636
|
o.issues.push({
|
|
637
637
|
origin: s,
|
|
638
|
-
...
|
|
638
|
+
...a ? { code: "too_big", maximum: t.length } : { code: "too_small", minimum: t.length },
|
|
639
639
|
inclusive: !0,
|
|
640
640
|
exact: !0,
|
|
641
641
|
input: o.value,
|
|
@@ -643,9 +643,9 @@ const Nn = (e) => {
|
|
|
643
643
|
continue: !t.abort
|
|
644
644
|
});
|
|
645
645
|
};
|
|
646
|
-
}),
|
|
646
|
+
}), me = /* @__PURE__ */ l("$ZodCheckStringFormat", (e, t) => {
|
|
647
647
|
var n, o;
|
|
648
|
-
|
|
648
|
+
j.init(e, t), e._zod.onattach.push((r) => {
|
|
649
649
|
const i = r._zod.bag;
|
|
650
650
|
i.format = t.format, t.pattern && (i.patterns ?? (i.patterns = /* @__PURE__ */ new Set()), i.patterns.add(t.pattern));
|
|
651
651
|
}), t.pattern ? (n = e._zod).check ?? (n.check = (r) => {
|
|
@@ -660,8 +660,8 @@ const Nn = (e) => {
|
|
|
660
660
|
});
|
|
661
661
|
}) : (o = e._zod).check ?? (o.check = () => {
|
|
662
662
|
});
|
|
663
|
-
}),
|
|
664
|
-
|
|
663
|
+
}), Yn = /* @__PURE__ */ l("$ZodCheckRegex", (e, t) => {
|
|
664
|
+
me.init(e, t), e._zod.check = (n) => {
|
|
665
665
|
t.pattern.lastIndex = 0, !t.pattern.test(n.value) && n.issues.push({
|
|
666
666
|
origin: "string",
|
|
667
667
|
code: "invalid_format",
|
|
@@ -672,12 +672,12 @@ const Nn = (e) => {
|
|
|
672
672
|
continue: !t.abort
|
|
673
673
|
});
|
|
674
674
|
};
|
|
675
|
-
}),
|
|
676
|
-
t.pattern ?? (t.pattern =
|
|
677
|
-
}),
|
|
678
|
-
t.pattern ?? (t.pattern =
|
|
679
|
-
}),
|
|
680
|
-
|
|
675
|
+
}), Xn = /* @__PURE__ */ l("$ZodCheckLowerCase", (e, t) => {
|
|
676
|
+
t.pattern ?? (t.pattern = Jn), me.init(e, t);
|
|
677
|
+
}), Hn = /* @__PURE__ */ l("$ZodCheckUpperCase", (e, t) => {
|
|
678
|
+
t.pattern ?? (t.pattern = Vn), me.init(e, t);
|
|
679
|
+
}), Qn = /* @__PURE__ */ l("$ZodCheckIncludes", (e, t) => {
|
|
680
|
+
j.init(e, t);
|
|
681
681
|
const n = X(t.includes), o = new RegExp(typeof t.position == "number" ? `^.{${t.position}}${n}` : n);
|
|
682
682
|
t.pattern = o, e._zod.onattach.push((r) => {
|
|
683
683
|
const i = r._zod.bag;
|
|
@@ -693,8 +693,8 @@ const Nn = (e) => {
|
|
|
693
693
|
continue: !t.abort
|
|
694
694
|
});
|
|
695
695
|
};
|
|
696
|
-
}),
|
|
697
|
-
|
|
696
|
+
}), eo = /* @__PURE__ */ l("$ZodCheckStartsWith", (e, t) => {
|
|
697
|
+
j.init(e, t);
|
|
698
698
|
const n = new RegExp(`^${X(t.prefix)}.*`);
|
|
699
699
|
t.pattern ?? (t.pattern = n), e._zod.onattach.push((o) => {
|
|
700
700
|
const r = o._zod.bag;
|
|
@@ -710,8 +710,8 @@ const Nn = (e) => {
|
|
|
710
710
|
continue: !t.abort
|
|
711
711
|
});
|
|
712
712
|
};
|
|
713
|
-
}),
|
|
714
|
-
|
|
713
|
+
}), to = /* @__PURE__ */ l("$ZodCheckEndsWith", (e, t) => {
|
|
714
|
+
j.init(e, t);
|
|
715
715
|
const n = new RegExp(`.*${X(t.suffix)}$`);
|
|
716
716
|
t.pattern ?? (t.pattern = n), e._zod.onattach.push((o) => {
|
|
717
717
|
const r = o._zod.bag;
|
|
@@ -727,12 +727,12 @@ const Nn = (e) => {
|
|
|
727
727
|
continue: !t.abort
|
|
728
728
|
});
|
|
729
729
|
};
|
|
730
|
-
}),
|
|
731
|
-
|
|
730
|
+
}), no = /* @__PURE__ */ l("$ZodCheckOverwrite", (e, t) => {
|
|
731
|
+
j.init(e, t), e._zod.check = (n) => {
|
|
732
732
|
n.value = t.tx(n.value);
|
|
733
733
|
};
|
|
734
734
|
});
|
|
735
|
-
class
|
|
735
|
+
class oo {
|
|
736
736
|
constructor(t = []) {
|
|
737
737
|
this.content = [], this.indent = 0, this && (this.args = t);
|
|
738
738
|
}
|
|
@@ -755,14 +755,14 @@ class Yn {
|
|
|
755
755
|
`));
|
|
756
756
|
}
|
|
757
757
|
}
|
|
758
|
-
const
|
|
758
|
+
const ro = {
|
|
759
759
|
major: 4,
|
|
760
760
|
minor: 3,
|
|
761
761
|
patch: 6
|
|
762
762
|
}, S = /* @__PURE__ */ l("$ZodType", (e, t) => {
|
|
763
763
|
var r;
|
|
764
764
|
var n;
|
|
765
|
-
e ?? (e = {}), e._zod.def = t, e._zod.bag = e._zod.bag || {}, e._zod.version =
|
|
765
|
+
e ?? (e = {}), e._zod.def = t, e._zod.bag = e._zod.bag || {}, e._zod.version = ro;
|
|
766
766
|
const o = [...e._zod.def.checks ?? []];
|
|
767
767
|
e._zod.traits.has("$ZodCheck") && o.unshift(e);
|
|
768
768
|
for (const i of o)
|
|
@@ -773,32 +773,32 @@ const Xn = {
|
|
|
773
773
|
e._zod.run = e._zod.parse;
|
|
774
774
|
});
|
|
775
775
|
else {
|
|
776
|
-
const i = (
|
|
777
|
-
let p =
|
|
778
|
-
for (const
|
|
779
|
-
if (
|
|
780
|
-
if (!
|
|
776
|
+
const i = (a, c, u) => {
|
|
777
|
+
let p = G(a), f;
|
|
778
|
+
for (const _ of c) {
|
|
779
|
+
if (_._zod.def.when) {
|
|
780
|
+
if (!_._zod.def.when(a))
|
|
781
781
|
continue;
|
|
782
782
|
} else if (p)
|
|
783
783
|
continue;
|
|
784
|
-
const
|
|
784
|
+
const b = a.issues.length, k = _._zod.check(a);
|
|
785
785
|
if (k instanceof Promise && (u == null ? void 0 : u.async) === !1)
|
|
786
786
|
throw new q();
|
|
787
787
|
if (f || k instanceof Promise)
|
|
788
788
|
f = (f ?? Promise.resolve()).then(async () => {
|
|
789
|
-
await k,
|
|
789
|
+
await k, a.issues.length !== b && (p || (p = G(a, b)));
|
|
790
790
|
});
|
|
791
791
|
else {
|
|
792
|
-
if (
|
|
792
|
+
if (a.issues.length === b)
|
|
793
793
|
continue;
|
|
794
|
-
p || (p =
|
|
794
|
+
p || (p = G(a, b));
|
|
795
795
|
}
|
|
796
796
|
}
|
|
797
|
-
return f ? f.then(() =>
|
|
798
|
-
}, s = (
|
|
799
|
-
if (
|
|
800
|
-
return
|
|
801
|
-
const p = i(
|
|
797
|
+
return f ? f.then(() => a) : a;
|
|
798
|
+
}, s = (a, c, u) => {
|
|
799
|
+
if (G(a))
|
|
800
|
+
return a.aborted = !0, a;
|
|
801
|
+
const p = i(c, o, u);
|
|
802
802
|
if (p instanceof Promise) {
|
|
803
803
|
if (u.async === !1)
|
|
804
804
|
throw new q();
|
|
@@ -806,41 +806,41 @@ const Xn = {
|
|
|
806
806
|
}
|
|
807
807
|
return e._zod.parse(p, u);
|
|
808
808
|
};
|
|
809
|
-
e._zod.run = (
|
|
810
|
-
if (
|
|
811
|
-
return e._zod.parse(
|
|
812
|
-
if (
|
|
813
|
-
const p = e._zod.parse({ value:
|
|
814
|
-
return p instanceof Promise ? p.then((f) => s(f,
|
|
809
|
+
e._zod.run = (a, c) => {
|
|
810
|
+
if (c.skipChecks)
|
|
811
|
+
return e._zod.parse(a, c);
|
|
812
|
+
if (c.direction === "backward") {
|
|
813
|
+
const p = e._zod.parse({ value: a.value, issues: [] }, { ...c, skipChecks: !0 });
|
|
814
|
+
return p instanceof Promise ? p.then((f) => s(f, a, c)) : s(p, a, c);
|
|
815
815
|
}
|
|
816
|
-
const u = e._zod.parse(
|
|
816
|
+
const u = e._zod.parse(a, c);
|
|
817
817
|
if (u instanceof Promise) {
|
|
818
|
-
if (
|
|
818
|
+
if (c.async === !1)
|
|
819
819
|
throw new q();
|
|
820
|
-
return u.then((p) => i(p, o,
|
|
820
|
+
return u.then((p) => i(p, o, c));
|
|
821
821
|
}
|
|
822
|
-
return i(u, o,
|
|
822
|
+
return i(u, o, c);
|
|
823
823
|
};
|
|
824
824
|
}
|
|
825
|
-
|
|
825
|
+
w(e, "~standard", () => ({
|
|
826
826
|
validate: (i) => {
|
|
827
827
|
var s;
|
|
828
828
|
try {
|
|
829
|
-
const
|
|
830
|
-
return
|
|
829
|
+
const a = un(e, i);
|
|
830
|
+
return a.success ? { value: a.data } : { issues: (s = a.error) == null ? void 0 : s.issues };
|
|
831
831
|
} catch {
|
|
832
|
-
return
|
|
832
|
+
return ln(e, i).then((c) => {
|
|
833
833
|
var u;
|
|
834
|
-
return
|
|
834
|
+
return c.success ? { value: c.data } : { issues: (u = c.error) == null ? void 0 : u.issues };
|
|
835
835
|
});
|
|
836
836
|
}
|
|
837
837
|
},
|
|
838
838
|
vendor: "zod",
|
|
839
839
|
version: 1
|
|
840
840
|
}));
|
|
841
|
-
}),
|
|
841
|
+
}), Ee = /* @__PURE__ */ l("$ZodString", (e, t) => {
|
|
842
842
|
var n;
|
|
843
|
-
S.init(e, t), e._zod.pattern = [...((n = e == null ? void 0 : e._zod.bag) == null ? void 0 : n.patterns) ?? []].pop() ??
|
|
843
|
+
S.init(e, t), e._zod.pattern = [...((n = e == null ? void 0 : e._zod.bag) == null ? void 0 : n.patterns) ?? []].pop() ?? Fn(e._zod.bag), e._zod.parse = (o, r) => {
|
|
844
844
|
if (t.coerce)
|
|
845
845
|
try {
|
|
846
846
|
o.value = String(o.value);
|
|
@@ -853,11 +853,11 @@ const Xn = {
|
|
|
853
853
|
inst: e
|
|
854
854
|
}), o;
|
|
855
855
|
};
|
|
856
|
-
}),
|
|
857
|
-
|
|
858
|
-
}),
|
|
859
|
-
t.pattern ?? (t.pattern =
|
|
860
|
-
}),
|
|
856
|
+
}), O = /* @__PURE__ */ l("$ZodStringFormat", (e, t) => {
|
|
857
|
+
me.init(e, t), Ee.init(e, t);
|
|
858
|
+
}), io = /* @__PURE__ */ l("$ZodGUID", (e, t) => {
|
|
859
|
+
t.pattern ?? (t.pattern = $n), O.init(e, t);
|
|
860
|
+
}), so = /* @__PURE__ */ l("$ZodUUID", (e, t) => {
|
|
861
861
|
if (t.version) {
|
|
862
862
|
const o = {
|
|
863
863
|
v1: 1,
|
|
@@ -871,14 +871,14 @@ const Xn = {
|
|
|
871
871
|
}[t.version];
|
|
872
872
|
if (o === void 0)
|
|
873
873
|
throw new Error(`Invalid UUID version: "${t.version}"`);
|
|
874
|
-
t.pattern ?? (t.pattern =
|
|
874
|
+
t.pattern ?? (t.pattern = Re(o));
|
|
875
875
|
} else
|
|
876
|
-
t.pattern ?? (t.pattern =
|
|
877
|
-
|
|
878
|
-
}),
|
|
879
|
-
t.pattern ?? (t.pattern =
|
|
880
|
-
}),
|
|
881
|
-
|
|
876
|
+
t.pattern ?? (t.pattern = Re());
|
|
877
|
+
O.init(e, t);
|
|
878
|
+
}), ao = /* @__PURE__ */ l("$ZodEmail", (e, t) => {
|
|
879
|
+
t.pattern ?? (t.pattern = On), O.init(e, t);
|
|
880
|
+
}), co = /* @__PURE__ */ l("$ZodURL", (e, t) => {
|
|
881
|
+
O.init(e, t), e._zod.check = (n) => {
|
|
882
882
|
try {
|
|
883
883
|
const o = n.value.trim(), r = new URL(o);
|
|
884
884
|
t.hostname && (t.hostname.lastIndex = 0, t.hostname.test(r.hostname) || n.issues.push({
|
|
@@ -909,32 +909,32 @@ const Xn = {
|
|
|
909
909
|
});
|
|
910
910
|
}
|
|
911
911
|
};
|
|
912
|
-
}),
|
|
913
|
-
t.pattern ?? (t.pattern =
|
|
914
|
-
}),
|
|
915
|
-
t.pattern ?? (t.pattern =
|
|
916
|
-
}),
|
|
917
|
-
t.pattern ?? (t.pattern =
|
|
918
|
-
}),
|
|
919
|
-
t.pattern ?? (t.pattern =
|
|
920
|
-
}),
|
|
921
|
-
t.pattern ?? (t.pattern =
|
|
922
|
-
}),
|
|
923
|
-
t.pattern ?? (t.pattern =
|
|
924
|
-
}),
|
|
925
|
-
t.pattern ?? (t.pattern =
|
|
926
|
-
}),
|
|
927
|
-
t.pattern ?? (t.pattern =
|
|
928
|
-
}),
|
|
929
|
-
t.pattern ?? (t.pattern =
|
|
930
|
-
}),
|
|
931
|
-
t.pattern ?? (t.pattern =
|
|
932
|
-
}),
|
|
933
|
-
t.pattern ?? (t.pattern =
|
|
934
|
-
}),
|
|
935
|
-
t.pattern ?? (t.pattern =
|
|
936
|
-
}),
|
|
937
|
-
t.pattern ?? (t.pattern =
|
|
912
|
+
}), uo = /* @__PURE__ */ l("$ZodEmoji", (e, t) => {
|
|
913
|
+
t.pattern ?? (t.pattern = In()), O.init(e, t);
|
|
914
|
+
}), lo = /* @__PURE__ */ l("$ZodNanoID", (e, t) => {
|
|
915
|
+
t.pattern ?? (t.pattern = Sn), O.init(e, t);
|
|
916
|
+
}), po = /* @__PURE__ */ l("$ZodCUID", (e, t) => {
|
|
917
|
+
t.pattern ?? (t.pattern = yn), O.init(e, t);
|
|
918
|
+
}), fo = /* @__PURE__ */ l("$ZodCUID2", (e, t) => {
|
|
919
|
+
t.pattern ?? (t.pattern = bn), O.init(e, t);
|
|
920
|
+
}), ho = /* @__PURE__ */ l("$ZodULID", (e, t) => {
|
|
921
|
+
t.pattern ?? (t.pattern = wn), O.init(e, t);
|
|
922
|
+
}), mo = /* @__PURE__ */ l("$ZodXID", (e, t) => {
|
|
923
|
+
t.pattern ?? (t.pattern = zn), O.init(e, t);
|
|
924
|
+
}), go = /* @__PURE__ */ l("$ZodKSUID", (e, t) => {
|
|
925
|
+
t.pattern ?? (t.pattern = kn), O.init(e, t);
|
|
926
|
+
}), _o = /* @__PURE__ */ l("$ZodISODateTime", (e, t) => {
|
|
927
|
+
t.pattern ?? (t.pattern = Dn(t)), O.init(e, t);
|
|
928
|
+
}), vo = /* @__PURE__ */ l("$ZodISODate", (e, t) => {
|
|
929
|
+
t.pattern ?? (t.pattern = xn), O.init(e, t);
|
|
930
|
+
}), yo = /* @__PURE__ */ l("$ZodISOTime", (e, t) => {
|
|
931
|
+
t.pattern ?? (t.pattern = Rn(t)), O.init(e, t);
|
|
932
|
+
}), bo = /* @__PURE__ */ l("$ZodISODuration", (e, t) => {
|
|
933
|
+
t.pattern ?? (t.pattern = Zn), O.init(e, t);
|
|
934
|
+
}), wo = /* @__PURE__ */ l("$ZodIPv4", (e, t) => {
|
|
935
|
+
t.pattern ?? (t.pattern = Pn), O.init(e, t), e._zod.bag.format = "ipv4";
|
|
936
|
+
}), zo = /* @__PURE__ */ l("$ZodIPv6", (e, t) => {
|
|
937
|
+
t.pattern ?? (t.pattern = En), O.init(e, t), e._zod.bag.format = "ipv6", e._zod.check = (n) => {
|
|
938
938
|
try {
|
|
939
939
|
new URL(`http://[${n.value}]`);
|
|
940
940
|
} catch {
|
|
@@ -947,10 +947,10 @@ const Xn = {
|
|
|
947
947
|
});
|
|
948
948
|
}
|
|
949
949
|
};
|
|
950
|
-
}),
|
|
951
|
-
t.pattern ?? (t.pattern =
|
|
952
|
-
}),
|
|
953
|
-
t.pattern ?? (t.pattern =
|
|
950
|
+
}), ko = /* @__PURE__ */ l("$ZodCIDRv4", (e, t) => {
|
|
951
|
+
t.pattern ?? (t.pattern = Nn), O.init(e, t);
|
|
952
|
+
}), So = /* @__PURE__ */ l("$ZodCIDRv6", (e, t) => {
|
|
953
|
+
t.pattern ?? (t.pattern = Cn), O.init(e, t), e._zod.check = (n) => {
|
|
954
954
|
const o = n.value.split("/");
|
|
955
955
|
try {
|
|
956
956
|
if (o.length !== 2)
|
|
@@ -975,7 +975,7 @@ const Xn = {
|
|
|
975
975
|
}
|
|
976
976
|
};
|
|
977
977
|
});
|
|
978
|
-
function
|
|
978
|
+
function bt(e) {
|
|
979
979
|
if (e === "")
|
|
980
980
|
return !0;
|
|
981
981
|
if (e.length % 4 !== 0)
|
|
@@ -986,9 +986,9 @@ function mt(e) {
|
|
|
986
986
|
return !1;
|
|
987
987
|
}
|
|
988
988
|
}
|
|
989
|
-
const
|
|
990
|
-
t.pattern ?? (t.pattern =
|
|
991
|
-
|
|
989
|
+
const Zo = /* @__PURE__ */ l("$ZodBase64", (e, t) => {
|
|
990
|
+
t.pattern ?? (t.pattern = An), O.init(e, t), e._zod.bag.contentEncoding = "base64", e._zod.check = (n) => {
|
|
991
|
+
bt(n.value) || n.issues.push({
|
|
992
992
|
code: "invalid_format",
|
|
993
993
|
format: "base64",
|
|
994
994
|
input: n.value,
|
|
@@ -997,15 +997,15 @@ const vo = /* @__PURE__ */ l("$ZodBase64", (e, t) => {
|
|
|
997
997
|
});
|
|
998
998
|
};
|
|
999
999
|
});
|
|
1000
|
-
function
|
|
1001
|
-
if (!
|
|
1000
|
+
function $o(e) {
|
|
1001
|
+
if (!dt.test(e))
|
|
1002
1002
|
return !1;
|
|
1003
1003
|
const t = e.replace(/[-_]/g, (o) => o === "-" ? "+" : "/"), n = t.padEnd(Math.ceil(t.length / 4) * 4, "=");
|
|
1004
|
-
return
|
|
1004
|
+
return bt(n);
|
|
1005
1005
|
}
|
|
1006
|
-
const
|
|
1007
|
-
t.pattern ?? (t.pattern =
|
|
1008
|
-
|
|
1006
|
+
const Oo = /* @__PURE__ */ l("$ZodBase64URL", (e, t) => {
|
|
1007
|
+
t.pattern ?? (t.pattern = dt), O.init(e, t), e._zod.bag.contentEncoding = "base64url", e._zod.check = (n) => {
|
|
1008
|
+
$o(n.value) || n.issues.push({
|
|
1009
1009
|
code: "invalid_format",
|
|
1010
1010
|
format: "base64url",
|
|
1011
1011
|
input: n.value,
|
|
@@ -1013,10 +1013,10 @@ const bo = /* @__PURE__ */ l("$ZodBase64URL", (e, t) => {
|
|
|
1013
1013
|
continue: !t.abort
|
|
1014
1014
|
});
|
|
1015
1015
|
};
|
|
1016
|
-
}),
|
|
1017
|
-
t.pattern ?? (t.pattern =
|
|
1016
|
+
}), To = /* @__PURE__ */ l("$ZodE164", (e, t) => {
|
|
1017
|
+
t.pattern ?? (t.pattern = jn), O.init(e, t);
|
|
1018
1018
|
});
|
|
1019
|
-
function
|
|
1019
|
+
function Io(e, t = null) {
|
|
1020
1020
|
try {
|
|
1021
1021
|
const n = e.split(".");
|
|
1022
1022
|
if (n.length !== 3)
|
|
@@ -1030,9 +1030,9 @@ function wo(e, t = null) {
|
|
|
1030
1030
|
return !1;
|
|
1031
1031
|
}
|
|
1032
1032
|
}
|
|
1033
|
-
const
|
|
1034
|
-
|
|
1035
|
-
|
|
1033
|
+
const Po = /* @__PURE__ */ l("$ZodJWT", (e, t) => {
|
|
1034
|
+
O.init(e, t), e._zod.check = (n) => {
|
|
1035
|
+
Io(n.value, t.alg) || n.issues.push({
|
|
1036
1036
|
code: "invalid_format",
|
|
1037
1037
|
format: "jwt",
|
|
1038
1038
|
input: n.value,
|
|
@@ -1040,8 +1040,8 @@ const ko = /* @__PURE__ */ l("$ZodJWT", (e, t) => {
|
|
|
1040
1040
|
continue: !t.abort
|
|
1041
1041
|
});
|
|
1042
1042
|
};
|
|
1043
|
-
}),
|
|
1044
|
-
S.init(e, t), e._zod.pattern = e._zod.bag.pattern ??
|
|
1043
|
+
}), wt = /* @__PURE__ */ l("$ZodNumber", (e, t) => {
|
|
1044
|
+
S.init(e, t), e._zod.pattern = e._zod.bag.pattern ?? gt, e._zod.parse = (n, o) => {
|
|
1045
1045
|
if (t.coerce)
|
|
1046
1046
|
try {
|
|
1047
1047
|
n.value = Number(n.value);
|
|
@@ -1059,10 +1059,10 @@ const ko = /* @__PURE__ */ l("$ZodJWT", (e, t) => {
|
|
|
1059
1059
|
...i ? { received: i } : {}
|
|
1060
1060
|
}), n;
|
|
1061
1061
|
};
|
|
1062
|
-
}),
|
|
1063
|
-
|
|
1064
|
-
}),
|
|
1065
|
-
S.init(e, t), e._zod.pattern =
|
|
1062
|
+
}), Eo = /* @__PURE__ */ l("$ZodNumberFormat", (e, t) => {
|
|
1063
|
+
Wn.init(e, t), wt.init(e, t);
|
|
1064
|
+
}), No = /* @__PURE__ */ l("$ZodBoolean", (e, t) => {
|
|
1065
|
+
S.init(e, t), e._zod.pattern = Un, e._zod.parse = (n, o) => {
|
|
1066
1066
|
if (t.coerce)
|
|
1067
1067
|
try {
|
|
1068
1068
|
n.value = !!n.value;
|
|
@@ -1076,8 +1076,8 @@ const ko = /* @__PURE__ */ l("$ZodJWT", (e, t) => {
|
|
|
1076
1076
|
inst: e
|
|
1077
1077
|
}), n;
|
|
1078
1078
|
};
|
|
1079
|
-
}),
|
|
1080
|
-
S.init(e, t), e._zod.pattern =
|
|
1079
|
+
}), Co = /* @__PURE__ */ l("$ZodNull", (e, t) => {
|
|
1080
|
+
S.init(e, t), e._zod.pattern = Mn, e._zod.values = /* @__PURE__ */ new Set([null]), e._zod.parse = (n, o) => {
|
|
1081
1081
|
const r = n.value;
|
|
1082
1082
|
return r === null || n.issues.push({
|
|
1083
1083
|
expected: "null",
|
|
@@ -1086,9 +1086,9 @@ const ko = /* @__PURE__ */ l("$ZodJWT", (e, t) => {
|
|
|
1086
1086
|
inst: e
|
|
1087
1087
|
}), n;
|
|
1088
1088
|
};
|
|
1089
|
-
}),
|
|
1089
|
+
}), Ao = /* @__PURE__ */ l("$ZodUnknown", (e, t) => {
|
|
1090
1090
|
S.init(e, t), e._zod.parse = (n) => n;
|
|
1091
|
-
}),
|
|
1091
|
+
}), jo = /* @__PURE__ */ l("$ZodNever", (e, t) => {
|
|
1092
1092
|
S.init(e, t), e._zod.parse = (n, o) => (n.issues.push({
|
|
1093
1093
|
expected: "never",
|
|
1094
1094
|
code: "invalid_type",
|
|
@@ -1096,10 +1096,10 @@ const ko = /* @__PURE__ */ l("$ZodJWT", (e, t) => {
|
|
|
1096
1096
|
inst: e
|
|
1097
1097
|
}), n);
|
|
1098
1098
|
});
|
|
1099
|
-
function
|
|
1099
|
+
function De(e, t, n) {
|
|
1100
1100
|
e.issues.length && t.issues.push(...B(n, e.issues)), t.value[n] = e.value;
|
|
1101
1101
|
}
|
|
1102
|
-
const
|
|
1102
|
+
const xo = /* @__PURE__ */ l("$ZodArray", (e, t) => {
|
|
1103
1103
|
S.init(e, t), e._zod.parse = (n, o) => {
|
|
1104
1104
|
const r = n.value;
|
|
1105
1105
|
if (!Array.isArray(r))
|
|
@@ -1112,16 +1112,16 @@ const Po = /* @__PURE__ */ l("$ZodArray", (e, t) => {
|
|
|
1112
1112
|
n.value = Array(r.length);
|
|
1113
1113
|
const i = [];
|
|
1114
1114
|
for (let s = 0; s < r.length; s++) {
|
|
1115
|
-
const
|
|
1116
|
-
value:
|
|
1115
|
+
const a = r[s], c = t.element._zod.run({
|
|
1116
|
+
value: a,
|
|
1117
1117
|
issues: []
|
|
1118
1118
|
}, o);
|
|
1119
|
-
|
|
1119
|
+
c instanceof Promise ? i.push(c.then((u) => De(u, n, s))) : De(c, n, s);
|
|
1120
1120
|
}
|
|
1121
1121
|
return i.length ? Promise.all(i).then(() => n) : n;
|
|
1122
1122
|
};
|
|
1123
1123
|
});
|
|
1124
|
-
function
|
|
1124
|
+
function ue(e, t, n, o, r) {
|
|
1125
1125
|
if (e.issues.length) {
|
|
1126
1126
|
if (r && !(n in o))
|
|
1127
1127
|
return;
|
|
@@ -1129,13 +1129,13 @@ function ae(e, t, n, o, r) {
|
|
|
1129
1129
|
}
|
|
1130
1130
|
e.value === void 0 ? n in o && (t.value[n] = void 0) : t.value[n] = e.value;
|
|
1131
1131
|
}
|
|
1132
|
-
function
|
|
1132
|
+
function zt(e) {
|
|
1133
1133
|
var o, r, i, s;
|
|
1134
1134
|
const t = Object.keys(e.shape);
|
|
1135
|
-
for (const
|
|
1136
|
-
if (!((s = (i = (r = (o = e.shape) == null ? void 0 : o[
|
|
1137
|
-
throw new Error(`Invalid element at key "${
|
|
1138
|
-
const n =
|
|
1135
|
+
for (const a of t)
|
|
1136
|
+
if (!((s = (i = (r = (o = e.shape) == null ? void 0 : o[a]) == null ? void 0 : r._zod) == null ? void 0 : i.traits) != null && s.has("$ZodType")))
|
|
1137
|
+
throw new Error(`Invalid element at key "${a}": expected a Zod schema`);
|
|
1138
|
+
const n = Xt(e.shape);
|
|
1139
1139
|
return {
|
|
1140
1140
|
...e,
|
|
1141
1141
|
keys: t,
|
|
@@ -1144,17 +1144,17 @@ function _t(e) {
|
|
|
1144
1144
|
optionalKeys: new Set(n)
|
|
1145
1145
|
};
|
|
1146
1146
|
}
|
|
1147
|
-
function
|
|
1148
|
-
const s = [],
|
|
1147
|
+
function kt(e, t, n, o, r, i) {
|
|
1148
|
+
const s = [], a = r.keySet, c = r.catchall._zod, u = c.def.type, p = c.optout === "optional";
|
|
1149
1149
|
for (const f in t) {
|
|
1150
|
-
if (
|
|
1150
|
+
if (a.has(f))
|
|
1151
1151
|
continue;
|
|
1152
1152
|
if (u === "never") {
|
|
1153
1153
|
s.push(f);
|
|
1154
1154
|
continue;
|
|
1155
1155
|
}
|
|
1156
|
-
const
|
|
1157
|
-
|
|
1156
|
+
const _ = c.run({ value: t[f], issues: [] }, o);
|
|
1157
|
+
_ instanceof Promise ? e.push(_.then((b) => ue(b, n, f, t, p))) : ue(_, n, f, t, p);
|
|
1158
1158
|
}
|
|
1159
1159
|
return s.length && n.issues.push({
|
|
1160
1160
|
code: "unrecognized_keys",
|
|
@@ -1163,143 +1163,143 @@ function vt(e, t, n, o, r, i) {
|
|
|
1163
1163
|
inst: i
|
|
1164
1164
|
}), e.length ? Promise.all(e).then(() => n) : n;
|
|
1165
1165
|
}
|
|
1166
|
-
const
|
|
1166
|
+
const Ro = /* @__PURE__ */ l("$ZodObject", (e, t) => {
|
|
1167
1167
|
S.init(e, t);
|
|
1168
1168
|
const n = Object.getOwnPropertyDescriptor(t, "shape");
|
|
1169
1169
|
if (!(n != null && n.get)) {
|
|
1170
|
-
const
|
|
1170
|
+
const a = t.shape;
|
|
1171
1171
|
Object.defineProperty(t, "shape", {
|
|
1172
1172
|
get: () => {
|
|
1173
|
-
const
|
|
1173
|
+
const c = { ...a };
|
|
1174
1174
|
return Object.defineProperty(t, "shape", {
|
|
1175
|
-
value:
|
|
1176
|
-
}),
|
|
1175
|
+
value: c
|
|
1176
|
+
}), c;
|
|
1177
1177
|
}
|
|
1178
1178
|
});
|
|
1179
1179
|
}
|
|
1180
|
-
const o =
|
|
1181
|
-
|
|
1182
|
-
const
|
|
1183
|
-
for (const u in
|
|
1184
|
-
const p =
|
|
1180
|
+
const o = fe(() => zt(t));
|
|
1181
|
+
w(e._zod, "propValues", () => {
|
|
1182
|
+
const a = t.shape, c = {};
|
|
1183
|
+
for (const u in a) {
|
|
1184
|
+
const p = a[u]._zod;
|
|
1185
1185
|
if (p.values) {
|
|
1186
|
-
|
|
1186
|
+
c[u] ?? (c[u] = /* @__PURE__ */ new Set());
|
|
1187
1187
|
for (const f of p.values)
|
|
1188
|
-
|
|
1188
|
+
c[u].add(f);
|
|
1189
1189
|
}
|
|
1190
1190
|
}
|
|
1191
|
-
return
|
|
1191
|
+
return c;
|
|
1192
1192
|
});
|
|
1193
|
-
const r =
|
|
1193
|
+
const r = ne, i = t.catchall;
|
|
1194
1194
|
let s;
|
|
1195
|
-
e._zod.parse = (
|
|
1195
|
+
e._zod.parse = (a, c) => {
|
|
1196
1196
|
s ?? (s = o.value);
|
|
1197
|
-
const u =
|
|
1197
|
+
const u = a.value;
|
|
1198
1198
|
if (!r(u))
|
|
1199
|
-
return
|
|
1199
|
+
return a.issues.push({
|
|
1200
1200
|
expected: "object",
|
|
1201
1201
|
code: "invalid_type",
|
|
1202
1202
|
input: u,
|
|
1203
1203
|
inst: e
|
|
1204
|
-
}),
|
|
1205
|
-
|
|
1204
|
+
}), a;
|
|
1205
|
+
a.value = {};
|
|
1206
1206
|
const p = [], f = s.shape;
|
|
1207
|
-
for (const
|
|
1208
|
-
const
|
|
1209
|
-
|
|
1207
|
+
for (const _ of s.keys) {
|
|
1208
|
+
const b = f[_], k = b._zod.optout === "optional", z = b._zod.run({ value: u[_], issues: [] }, c);
|
|
1209
|
+
z instanceof Promise ? p.push(z.then((P) => ue(P, a, _, u, k))) : ue(z, a, _, u, k);
|
|
1210
1210
|
}
|
|
1211
|
-
return i ?
|
|
1211
|
+
return i ? kt(p, u, a, c, o.value, e) : p.length ? Promise.all(p).then(() => a) : a;
|
|
1212
1212
|
};
|
|
1213
|
-
}),
|
|
1214
|
-
|
|
1215
|
-
const n = e._zod.parse, o =
|
|
1216
|
-
var
|
|
1217
|
-
const
|
|
1218
|
-
const A =
|
|
1213
|
+
}), Do = /* @__PURE__ */ l("$ZodObjectJIT", (e, t) => {
|
|
1214
|
+
Ro.init(e, t);
|
|
1215
|
+
const n = e._zod.parse, o = fe(() => zt(t)), r = (_) => {
|
|
1216
|
+
var re;
|
|
1217
|
+
const b = new oo(["shape", "payload", "ctx"]), k = o.value, z = (F) => {
|
|
1218
|
+
const A = xe(F);
|
|
1219
1219
|
return `shape[${A}]._zod.run({ value: input[${A}], issues: [] }, ctx)`;
|
|
1220
1220
|
};
|
|
1221
|
-
|
|
1222
|
-
const
|
|
1221
|
+
b.write("const input = payload.value;");
|
|
1222
|
+
const P = /* @__PURE__ */ Object.create(null);
|
|
1223
1223
|
let Q = 0;
|
|
1224
|
-
for (const
|
|
1225
|
-
|
|
1226
|
-
|
|
1227
|
-
for (const
|
|
1228
|
-
const A =
|
|
1229
|
-
|
|
1224
|
+
for (const F of k.keys)
|
|
1225
|
+
P[F] = `key_${Q++}`;
|
|
1226
|
+
b.write("const newResult = {};");
|
|
1227
|
+
for (const F of k.keys) {
|
|
1228
|
+
const A = P[F], D = xe(F), ve = _[F], Wt = ((re = ve == null ? void 0 : ve._zod) == null ? void 0 : re.optout) === "optional";
|
|
1229
|
+
b.write(`const ${A} = ${z(F)};`), Wt ? b.write(`
|
|
1230
1230
|
if (${A}.issues.length) {
|
|
1231
|
-
if (${
|
|
1231
|
+
if (${D} in input) {
|
|
1232
1232
|
payload.issues = payload.issues.concat(${A}.issues.map(iss => ({
|
|
1233
1233
|
...iss,
|
|
1234
|
-
path: iss.path ? [${
|
|
1234
|
+
path: iss.path ? [${D}, ...iss.path] : [${D}]
|
|
1235
1235
|
})));
|
|
1236
1236
|
}
|
|
1237
1237
|
}
|
|
1238
1238
|
|
|
1239
1239
|
if (${A}.value === undefined) {
|
|
1240
|
-
if (${
|
|
1241
|
-
newResult[${
|
|
1240
|
+
if (${D} in input) {
|
|
1241
|
+
newResult[${D}] = undefined;
|
|
1242
1242
|
}
|
|
1243
1243
|
} else {
|
|
1244
|
-
newResult[${
|
|
1244
|
+
newResult[${D}] = ${A}.value;
|
|
1245
1245
|
}
|
|
1246
1246
|
|
|
1247
|
-
`) :
|
|
1247
|
+
`) : b.write(`
|
|
1248
1248
|
if (${A}.issues.length) {
|
|
1249
1249
|
payload.issues = payload.issues.concat(${A}.issues.map(iss => ({
|
|
1250
1250
|
...iss,
|
|
1251
|
-
path: iss.path ? [${
|
|
1251
|
+
path: iss.path ? [${D}, ...iss.path] : [${D}]
|
|
1252
1252
|
})));
|
|
1253
1253
|
}
|
|
1254
1254
|
|
|
1255
1255
|
if (${A}.value === undefined) {
|
|
1256
|
-
if (${
|
|
1257
|
-
newResult[${
|
|
1256
|
+
if (${D} in input) {
|
|
1257
|
+
newResult[${D}] = undefined;
|
|
1258
1258
|
}
|
|
1259
1259
|
} else {
|
|
1260
|
-
newResult[${
|
|
1260
|
+
newResult[${D}] = ${A}.value;
|
|
1261
1261
|
}
|
|
1262
1262
|
|
|
1263
1263
|
`);
|
|
1264
1264
|
}
|
|
1265
|
-
|
|
1266
|
-
const N =
|
|
1267
|
-
return (
|
|
1265
|
+
b.write("payload.value = newResult;"), b.write("return payload;");
|
|
1266
|
+
const N = b.compile();
|
|
1267
|
+
return (F, A) => N(_, F, A);
|
|
1268
1268
|
};
|
|
1269
1269
|
let i;
|
|
1270
|
-
const s =
|
|
1270
|
+
const s = ne, a = !st.jitless, u = a && qt.value, p = t.catchall;
|
|
1271
1271
|
let f;
|
|
1272
|
-
e._zod.parse = (
|
|
1272
|
+
e._zod.parse = (_, b) => {
|
|
1273
1273
|
f ?? (f = o.value);
|
|
1274
|
-
const k =
|
|
1275
|
-
return s(k) ?
|
|
1274
|
+
const k = _.value;
|
|
1275
|
+
return s(k) ? a && u && (b == null ? void 0 : b.async) === !1 && b.jitless !== !0 ? (i || (i = r(t.shape)), _ = i(_, b), p ? kt([], k, _, b, f, e) : _) : n(_, b) : (_.issues.push({
|
|
1276
1276
|
expected: "object",
|
|
1277
1277
|
code: "invalid_type",
|
|
1278
1278
|
input: k,
|
|
1279
1279
|
inst: e
|
|
1280
|
-
}),
|
|
1280
|
+
}), _);
|
|
1281
1281
|
};
|
|
1282
1282
|
});
|
|
1283
|
-
function
|
|
1283
|
+
function Fe(e, t, n, o) {
|
|
1284
1284
|
for (const i of e)
|
|
1285
1285
|
if (i.issues.length === 0)
|
|
1286
1286
|
return t.value = i.value, t;
|
|
1287
|
-
const r = e.filter((i) => !
|
|
1287
|
+
const r = e.filter((i) => !G(i));
|
|
1288
1288
|
return r.length === 1 ? (t.value = r[0].value, r[0]) : (t.issues.push({
|
|
1289
1289
|
code: "invalid_union",
|
|
1290
1290
|
input: t.value,
|
|
1291
1291
|
inst: n,
|
|
1292
|
-
errors: e.map((i) => i.issues.map((s) =>
|
|
1292
|
+
errors: e.map((i) => i.issues.map((s) => J(s, o, M())))
|
|
1293
1293
|
}), t);
|
|
1294
1294
|
}
|
|
1295
|
-
const
|
|
1296
|
-
S.init(e, t),
|
|
1295
|
+
const St = /* @__PURE__ */ l("$ZodUnion", (e, t) => {
|
|
1296
|
+
S.init(e, t), w(e._zod, "optin", () => t.options.some((r) => r._zod.optin === "optional") ? "optional" : void 0), w(e._zod, "optout", () => t.options.some((r) => r._zod.optout === "optional") ? "optional" : void 0), w(e._zod, "values", () => {
|
|
1297
1297
|
if (t.options.every((r) => r._zod.values))
|
|
1298
1298
|
return new Set(t.options.flatMap((r) => Array.from(r._zod.values)));
|
|
1299
|
-
}),
|
|
1299
|
+
}), w(e._zod, "pattern", () => {
|
|
1300
1300
|
if (t.options.every((r) => r._zod.pattern)) {
|
|
1301
1301
|
const r = t.options.map((i) => i._zod.pattern);
|
|
1302
|
-
return new RegExp(`^(${r.map((i) =>
|
|
1302
|
+
return new RegExp(`^(${r.map((i) => Oe(i.source)).join("|")})$`);
|
|
1303
1303
|
}
|
|
1304
1304
|
});
|
|
1305
1305
|
const n = t.options.length === 1, o = t.options[0]._zod.run;
|
|
@@ -1307,65 +1307,65 @@ const yt = /* @__PURE__ */ l("$ZodUnion", (e, t) => {
|
|
|
1307
1307
|
if (n)
|
|
1308
1308
|
return o(r, i);
|
|
1309
1309
|
let s = !1;
|
|
1310
|
-
const
|
|
1311
|
-
for (const
|
|
1312
|
-
const u =
|
|
1310
|
+
const a = [];
|
|
1311
|
+
for (const c of t.options) {
|
|
1312
|
+
const u = c._zod.run({
|
|
1313
1313
|
value: r.value,
|
|
1314
1314
|
issues: []
|
|
1315
1315
|
}, i);
|
|
1316
1316
|
if (u instanceof Promise)
|
|
1317
|
-
|
|
1317
|
+
a.push(u), s = !0;
|
|
1318
1318
|
else {
|
|
1319
1319
|
if (u.issues.length === 0)
|
|
1320
1320
|
return u;
|
|
1321
|
-
|
|
1321
|
+
a.push(u);
|
|
1322
1322
|
}
|
|
1323
1323
|
}
|
|
1324
|
-
return s ? Promise.all(
|
|
1324
|
+
return s ? Promise.all(a).then((c) => Fe(c, r, e, i)) : Fe(a, r, e, i);
|
|
1325
1325
|
};
|
|
1326
|
-
}),
|
|
1327
|
-
t.inclusive = !1,
|
|
1326
|
+
}), Fo = /* @__PURE__ */ l("$ZodDiscriminatedUnion", (e, t) => {
|
|
1327
|
+
t.inclusive = !1, St.init(e, t);
|
|
1328
1328
|
const n = e._zod.parse;
|
|
1329
|
-
|
|
1329
|
+
w(e._zod, "propValues", () => {
|
|
1330
1330
|
const r = {};
|
|
1331
1331
|
for (const i of t.options) {
|
|
1332
1332
|
const s = i._zod.propValues;
|
|
1333
1333
|
if (!s || Object.keys(s).length === 0)
|
|
1334
1334
|
throw new Error(`Invalid discriminated union option at index "${t.options.indexOf(i)}"`);
|
|
1335
|
-
for (const [
|
|
1336
|
-
r[
|
|
1337
|
-
for (const u of
|
|
1338
|
-
r[
|
|
1335
|
+
for (const [a, c] of Object.entries(s)) {
|
|
1336
|
+
r[a] || (r[a] = /* @__PURE__ */ new Set());
|
|
1337
|
+
for (const u of c)
|
|
1338
|
+
r[a].add(u);
|
|
1339
1339
|
}
|
|
1340
1340
|
}
|
|
1341
1341
|
return r;
|
|
1342
1342
|
});
|
|
1343
|
-
const o =
|
|
1343
|
+
const o = fe(() => {
|
|
1344
1344
|
var s;
|
|
1345
1345
|
const r = t.options, i = /* @__PURE__ */ new Map();
|
|
1346
|
-
for (const
|
|
1347
|
-
const
|
|
1348
|
-
if (!
|
|
1349
|
-
throw new Error(`Invalid discriminated union option at index "${t.options.indexOf(
|
|
1350
|
-
for (const u of
|
|
1346
|
+
for (const a of r) {
|
|
1347
|
+
const c = (s = a._zod.propValues) == null ? void 0 : s[t.discriminator];
|
|
1348
|
+
if (!c || c.size === 0)
|
|
1349
|
+
throw new Error(`Invalid discriminated union option at index "${t.options.indexOf(a)}"`);
|
|
1350
|
+
for (const u of c) {
|
|
1351
1351
|
if (i.has(u))
|
|
1352
1352
|
throw new Error(`Duplicate discriminator value "${String(u)}"`);
|
|
1353
|
-
i.set(u,
|
|
1353
|
+
i.set(u, a);
|
|
1354
1354
|
}
|
|
1355
1355
|
}
|
|
1356
1356
|
return i;
|
|
1357
1357
|
});
|
|
1358
1358
|
e._zod.parse = (r, i) => {
|
|
1359
1359
|
const s = r.value;
|
|
1360
|
-
if (!
|
|
1360
|
+
if (!ne(s))
|
|
1361
1361
|
return r.issues.push({
|
|
1362
1362
|
code: "invalid_type",
|
|
1363
1363
|
expected: "object",
|
|
1364
1364
|
input: s,
|
|
1365
1365
|
inst: e
|
|
1366
1366
|
}), r;
|
|
1367
|
-
const
|
|
1368
|
-
return
|
|
1367
|
+
const a = o.value.get(s == null ? void 0 : s[t.discriminator]);
|
|
1368
|
+
return a ? a._zod.run(r, i) : t.unionFallback ? n(r, i) : (r.issues.push({
|
|
1369
1369
|
code: "invalid_union",
|
|
1370
1370
|
errors: [],
|
|
1371
1371
|
note: "No matching discriminator",
|
|
@@ -1375,10 +1375,10 @@ const yt = /* @__PURE__ */ l("$ZodUnion", (e, t) => {
|
|
|
1375
1375
|
inst: e
|
|
1376
1376
|
}), r);
|
|
1377
1377
|
};
|
|
1378
|
-
}),
|
|
1378
|
+
}), Lo = /* @__PURE__ */ l("$ZodIntersection", (e, t) => {
|
|
1379
1379
|
S.init(e, t), e._zod.parse = (n, o) => {
|
|
1380
1380
|
const r = n.value, i = t.left._zod.run({ value: r, issues: [] }, o), s = t.right._zod.run({ value: r, issues: [] }, o);
|
|
1381
|
-
return i instanceof Promise || s instanceof Promise ? Promise.all([i, s]).then(([
|
|
1381
|
+
return i instanceof Promise || s instanceof Promise ? Promise.all([i, s]).then(([c, u]) => Le(n, c, u)) : Le(n, i, s);
|
|
1382
1382
|
};
|
|
1383
1383
|
});
|
|
1384
1384
|
function ze(e, t) {
|
|
@@ -1416,31 +1416,31 @@ function ze(e, t) {
|
|
|
1416
1416
|
}
|
|
1417
1417
|
return { valid: !1, mergeErrorPath: [] };
|
|
1418
1418
|
}
|
|
1419
|
-
function
|
|
1419
|
+
function Le(e, t, n) {
|
|
1420
1420
|
const o = /* @__PURE__ */ new Map();
|
|
1421
1421
|
let r;
|
|
1422
|
-
for (const
|
|
1423
|
-
if (
|
|
1424
|
-
r ?? (r =
|
|
1425
|
-
for (const
|
|
1426
|
-
o.has(
|
|
1422
|
+
for (const a of t.issues)
|
|
1423
|
+
if (a.code === "unrecognized_keys") {
|
|
1424
|
+
r ?? (r = a);
|
|
1425
|
+
for (const c of a.keys)
|
|
1426
|
+
o.has(c) || o.set(c, {}), o.get(c).l = !0;
|
|
1427
1427
|
} else
|
|
1428
|
-
e.issues.push(
|
|
1429
|
-
for (const
|
|
1430
|
-
if (
|
|
1431
|
-
for (const
|
|
1432
|
-
o.has(
|
|
1428
|
+
e.issues.push(a);
|
|
1429
|
+
for (const a of n.issues)
|
|
1430
|
+
if (a.code === "unrecognized_keys")
|
|
1431
|
+
for (const c of a.keys)
|
|
1432
|
+
o.has(c) || o.set(c, {}), o.get(c).r = !0;
|
|
1433
1433
|
else
|
|
1434
|
-
e.issues.push(
|
|
1435
|
-
const i = [...o].filter(([,
|
|
1436
|
-
if (i.length && r && e.issues.push({ ...r, keys: i }),
|
|
1434
|
+
e.issues.push(a);
|
|
1435
|
+
const i = [...o].filter(([, a]) => a.l && a.r).map(([a]) => a);
|
|
1436
|
+
if (i.length && r && e.issues.push({ ...r, keys: i }), G(e))
|
|
1437
1437
|
return e;
|
|
1438
1438
|
const s = ze(t.value, n.value);
|
|
1439
1439
|
if (!s.valid)
|
|
1440
1440
|
throw new Error(`Unmergable intersection. Error path: ${JSON.stringify(s.mergeErrorPath)}`);
|
|
1441
1441
|
return e.value = s.data, e;
|
|
1442
1442
|
}
|
|
1443
|
-
const
|
|
1443
|
+
const Uo = /* @__PURE__ */ l("$ZodTuple", (e, t) => {
|
|
1444
1444
|
S.init(e, t);
|
|
1445
1445
|
const n = t.items;
|
|
1446
1446
|
e._zod.parse = (o, r) => {
|
|
@@ -1453,9 +1453,9 @@ const Ao = /* @__PURE__ */ l("$ZodTuple", (e, t) => {
|
|
|
1453
1453
|
code: "invalid_type"
|
|
1454
1454
|
}), o;
|
|
1455
1455
|
o.value = [];
|
|
1456
|
-
const s = [],
|
|
1456
|
+
const s = [], a = [...n].reverse().findIndex((p) => p._zod.optin !== "optional"), c = a === -1 ? 0 : n.length - a;
|
|
1457
1457
|
if (!t.rest) {
|
|
1458
|
-
const p = i.length > n.length, f = i.length <
|
|
1458
|
+
const p = i.length > n.length, f = i.length < c - 1;
|
|
1459
1459
|
if (p || f)
|
|
1460
1460
|
return o.issues.push({
|
|
1461
1461
|
...p ? { code: "too_big", maximum: n.length, inclusive: !0 } : { code: "too_small", minimum: n.length },
|
|
@@ -1466,32 +1466,32 @@ const Ao = /* @__PURE__ */ l("$ZodTuple", (e, t) => {
|
|
|
1466
1466
|
}
|
|
1467
1467
|
let u = -1;
|
|
1468
1468
|
for (const p of n) {
|
|
1469
|
-
if (u++, u >= i.length && u >=
|
|
1469
|
+
if (u++, u >= i.length && u >= c)
|
|
1470
1470
|
continue;
|
|
1471
1471
|
const f = p._zod.run({
|
|
1472
1472
|
value: i[u],
|
|
1473
1473
|
issues: []
|
|
1474
1474
|
}, r);
|
|
1475
|
-
f instanceof Promise ? s.push(f.then((
|
|
1475
|
+
f instanceof Promise ? s.push(f.then((_) => se(_, o, u))) : se(f, o, u);
|
|
1476
1476
|
}
|
|
1477
1477
|
if (t.rest) {
|
|
1478
1478
|
const p = i.slice(n.length);
|
|
1479
1479
|
for (const f of p) {
|
|
1480
1480
|
u++;
|
|
1481
|
-
const
|
|
1481
|
+
const _ = t.rest._zod.run({
|
|
1482
1482
|
value: f,
|
|
1483
1483
|
issues: []
|
|
1484
1484
|
}, r);
|
|
1485
|
-
|
|
1485
|
+
_ instanceof Promise ? s.push(_.then((b) => se(b, o, u))) : se(_, o, u);
|
|
1486
1486
|
}
|
|
1487
1487
|
}
|
|
1488
1488
|
return s.length ? Promise.all(s).then(() => o) : o;
|
|
1489
1489
|
};
|
|
1490
1490
|
});
|
|
1491
|
-
function
|
|
1491
|
+
function se(e, t, n) {
|
|
1492
1492
|
e.issues.length && t.issues.push(...B(n, e.issues)), t.value[n] = e.value;
|
|
1493
1493
|
}
|
|
1494
|
-
const
|
|
1494
|
+
const Mo = /* @__PURE__ */ l("$ZodRecord", (e, t) => {
|
|
1495
1495
|
S.init(e, t), e._zod.parse = (n, o) => {
|
|
1496
1496
|
const r = n.value;
|
|
1497
1497
|
if (!Y(r))
|
|
@@ -1504,61 +1504,61 @@ const Co = /* @__PURE__ */ l("$ZodRecord", (e, t) => {
|
|
|
1504
1504
|
const i = [], s = t.keyType._zod.values;
|
|
1505
1505
|
if (s) {
|
|
1506
1506
|
n.value = {};
|
|
1507
|
-
const
|
|
1507
|
+
const a = /* @__PURE__ */ new Set();
|
|
1508
1508
|
for (const u of s)
|
|
1509
1509
|
if (typeof u == "string" || typeof u == "number" || typeof u == "symbol") {
|
|
1510
|
-
|
|
1510
|
+
a.add(typeof u == "number" ? u.toString() : u);
|
|
1511
1511
|
const p = t.valueType._zod.run({ value: r[u], issues: [] }, o);
|
|
1512
1512
|
p instanceof Promise ? i.push(p.then((f) => {
|
|
1513
1513
|
f.issues.length && n.issues.push(...B(u, f.issues)), n.value[u] = f.value;
|
|
1514
1514
|
})) : (p.issues.length && n.issues.push(...B(u, p.issues)), n.value[u] = p.value);
|
|
1515
1515
|
}
|
|
1516
|
-
let
|
|
1516
|
+
let c;
|
|
1517
1517
|
for (const u in r)
|
|
1518
|
-
|
|
1519
|
-
|
|
1518
|
+
a.has(u) || (c = c ?? [], c.push(u));
|
|
1519
|
+
c && c.length > 0 && n.issues.push({
|
|
1520
1520
|
code: "unrecognized_keys",
|
|
1521
1521
|
input: r,
|
|
1522
1522
|
inst: e,
|
|
1523
|
-
keys:
|
|
1523
|
+
keys: c
|
|
1524
1524
|
});
|
|
1525
1525
|
} else {
|
|
1526
1526
|
n.value = {};
|
|
1527
|
-
for (const
|
|
1528
|
-
if (
|
|
1527
|
+
for (const a of Reflect.ownKeys(r)) {
|
|
1528
|
+
if (a === "__proto__")
|
|
1529
1529
|
continue;
|
|
1530
|
-
let
|
|
1531
|
-
if (
|
|
1530
|
+
let c = t.keyType._zod.run({ value: a, issues: [] }, o);
|
|
1531
|
+
if (c instanceof Promise)
|
|
1532
1532
|
throw new Error("Async schemas not supported in object keys currently");
|
|
1533
|
-
if (typeof
|
|
1534
|
-
const f = t.keyType._zod.run({ value: Number(
|
|
1533
|
+
if (typeof a == "string" && gt.test(a) && c.issues.length) {
|
|
1534
|
+
const f = t.keyType._zod.run({ value: Number(a), issues: [] }, o);
|
|
1535
1535
|
if (f instanceof Promise)
|
|
1536
1536
|
throw new Error("Async schemas not supported in object keys currently");
|
|
1537
|
-
f.issues.length === 0 && (
|
|
1537
|
+
f.issues.length === 0 && (c = f);
|
|
1538
1538
|
}
|
|
1539
|
-
if (
|
|
1540
|
-
t.mode === "loose" ? n.value[
|
|
1539
|
+
if (c.issues.length) {
|
|
1540
|
+
t.mode === "loose" ? n.value[a] = r[a] : n.issues.push({
|
|
1541
1541
|
code: "invalid_key",
|
|
1542
1542
|
origin: "record",
|
|
1543
|
-
issues:
|
|
1544
|
-
input:
|
|
1545
|
-
path: [
|
|
1543
|
+
issues: c.issues.map((f) => J(f, o, M())),
|
|
1544
|
+
input: a,
|
|
1545
|
+
path: [a],
|
|
1546
1546
|
inst: e
|
|
1547
1547
|
});
|
|
1548
1548
|
continue;
|
|
1549
1549
|
}
|
|
1550
|
-
const p = t.valueType._zod.run({ value: r[
|
|
1550
|
+
const p = t.valueType._zod.run({ value: r[a], issues: [] }, o);
|
|
1551
1551
|
p instanceof Promise ? i.push(p.then((f) => {
|
|
1552
|
-
f.issues.length && n.issues.push(...B(
|
|
1553
|
-
})) : (p.issues.length && n.issues.push(...B(
|
|
1552
|
+
f.issues.length && n.issues.push(...B(a, f.issues)), n.value[c.value] = f.value;
|
|
1553
|
+
})) : (p.issues.length && n.issues.push(...B(a, p.issues)), n.value[c.value] = p.value);
|
|
1554
1554
|
}
|
|
1555
1555
|
}
|
|
1556
1556
|
return i.length ? Promise.all(i).then(() => n) : n;
|
|
1557
1557
|
};
|
|
1558
|
-
}),
|
|
1558
|
+
}), Jo = /* @__PURE__ */ l("$ZodEnum", (e, t) => {
|
|
1559
1559
|
S.init(e, t);
|
|
1560
|
-
const n =
|
|
1561
|
-
e._zod.values = o, e._zod.pattern = new RegExp(`^(${n.filter((r) =>
|
|
1560
|
+
const n = at(t.entries), o = new Set(n);
|
|
1561
|
+
e._zod.values = o, e._zod.pattern = new RegExp(`^(${n.filter((r) => Yt.has(typeof r)).map((r) => typeof r == "string" ? X(r) : r.toString()).join("|")})$`), e._zod.parse = (r, i) => {
|
|
1562
1562
|
const s = r.value;
|
|
1563
1563
|
return o.has(s) || r.issues.push({
|
|
1564
1564
|
code: "invalid_value",
|
|
@@ -1567,7 +1567,7 @@ const Co = /* @__PURE__ */ l("$ZodRecord", (e, t) => {
|
|
|
1567
1567
|
inst: e
|
|
1568
1568
|
}), r;
|
|
1569
1569
|
};
|
|
1570
|
-
}),
|
|
1570
|
+
}), Vo = /* @__PURE__ */ l("$ZodLiteral", (e, t) => {
|
|
1571
1571
|
if (S.init(e, t), t.values.length === 0)
|
|
1572
1572
|
throw new Error("Cannot create literal schema with no valid values");
|
|
1573
1573
|
const n = new Set(t.values);
|
|
@@ -1580,10 +1580,10 @@ const Co = /* @__PURE__ */ l("$ZodRecord", (e, t) => {
|
|
|
1580
1580
|
inst: e
|
|
1581
1581
|
}), o;
|
|
1582
1582
|
};
|
|
1583
|
-
}),
|
|
1583
|
+
}), Bo = /* @__PURE__ */ l("$ZodTransform", (e, t) => {
|
|
1584
1584
|
S.init(e, t), e._zod.parse = (n, o) => {
|
|
1585
1585
|
if (o.direction === "backward")
|
|
1586
|
-
throw new
|
|
1586
|
+
throw new it(e.constructor.name);
|
|
1587
1587
|
const r = t.transform(n.value, n);
|
|
1588
1588
|
if (o.async)
|
|
1589
1589
|
return (r instanceof Promise ? r : Promise.resolve(r)).then((s) => (n.value = s, n));
|
|
@@ -1592,52 +1592,52 @@ const Co = /* @__PURE__ */ l("$ZodRecord", (e, t) => {
|
|
|
1592
1592
|
return n.value = r, n;
|
|
1593
1593
|
};
|
|
1594
1594
|
});
|
|
1595
|
-
function
|
|
1595
|
+
function Ue(e, t) {
|
|
1596
1596
|
return e.issues.length && t === void 0 ? { issues: [], value: void 0 } : e;
|
|
1597
1597
|
}
|
|
1598
|
-
const
|
|
1599
|
-
S.init(e, t), e._zod.optin = "optional", e._zod.optout = "optional",
|
|
1598
|
+
const Zt = /* @__PURE__ */ l("$ZodOptional", (e, t) => {
|
|
1599
|
+
S.init(e, t), e._zod.optin = "optional", e._zod.optout = "optional", w(e._zod, "values", () => t.innerType._zod.values ? /* @__PURE__ */ new Set([...t.innerType._zod.values, void 0]) : void 0), w(e._zod, "pattern", () => {
|
|
1600
1600
|
const n = t.innerType._zod.pattern;
|
|
1601
|
-
return n ? new RegExp(`^(${
|
|
1601
|
+
return n ? new RegExp(`^(${Oe(n.source)})?$`) : void 0;
|
|
1602
1602
|
}), e._zod.parse = (n, o) => {
|
|
1603
1603
|
if (t.innerType._zod.optin === "optional") {
|
|
1604
1604
|
const r = t.innerType._zod.run(n, o);
|
|
1605
|
-
return r instanceof Promise ? r.then((i) =>
|
|
1605
|
+
return r instanceof Promise ? r.then((i) => Ue(i, n.value)) : Ue(r, n.value);
|
|
1606
1606
|
}
|
|
1607
1607
|
return n.value === void 0 ? n : t.innerType._zod.run(n, o);
|
|
1608
1608
|
};
|
|
1609
|
-
}),
|
|
1610
|
-
|
|
1611
|
-
}),
|
|
1612
|
-
S.init(e, t),
|
|
1609
|
+
}), Wo = /* @__PURE__ */ l("$ZodExactOptional", (e, t) => {
|
|
1610
|
+
Zt.init(e, t), w(e._zod, "values", () => t.innerType._zod.values), w(e._zod, "pattern", () => t.innerType._zod.pattern), e._zod.parse = (n, o) => t.innerType._zod.run(n, o);
|
|
1611
|
+
}), Go = /* @__PURE__ */ l("$ZodNullable", (e, t) => {
|
|
1612
|
+
S.init(e, t), w(e._zod, "optin", () => t.innerType._zod.optin), w(e._zod, "optout", () => t.innerType._zod.optout), w(e._zod, "pattern", () => {
|
|
1613
1613
|
const n = t.innerType._zod.pattern;
|
|
1614
|
-
return n ? new RegExp(`^(${
|
|
1615
|
-
}),
|
|
1616
|
-
}),
|
|
1617
|
-
S.init(e, t), e._zod.optin = "optional",
|
|
1614
|
+
return n ? new RegExp(`^(${Oe(n.source)}|null)$`) : void 0;
|
|
1615
|
+
}), w(e._zod, "values", () => t.innerType._zod.values ? /* @__PURE__ */ new Set([...t.innerType._zod.values, null]) : void 0), e._zod.parse = (n, o) => n.value === null ? n : t.innerType._zod.run(n, o);
|
|
1616
|
+
}), Ko = /* @__PURE__ */ l("$ZodDefault", (e, t) => {
|
|
1617
|
+
S.init(e, t), e._zod.optin = "optional", w(e._zod, "values", () => t.innerType._zod.values), e._zod.parse = (n, o) => {
|
|
1618
1618
|
if (o.direction === "backward")
|
|
1619
1619
|
return t.innerType._zod.run(n, o);
|
|
1620
1620
|
if (n.value === void 0)
|
|
1621
1621
|
return n.value = t.defaultValue, n;
|
|
1622
1622
|
const r = t.innerType._zod.run(n, o);
|
|
1623
|
-
return r instanceof Promise ? r.then((i) =>
|
|
1623
|
+
return r instanceof Promise ? r.then((i) => Me(i, t)) : Me(r, t);
|
|
1624
1624
|
};
|
|
1625
1625
|
});
|
|
1626
|
-
function
|
|
1626
|
+
function Me(e, t) {
|
|
1627
1627
|
return e.value === void 0 && (e.value = t.defaultValue), e;
|
|
1628
1628
|
}
|
|
1629
|
-
const
|
|
1630
|
-
S.init(e, t), e._zod.optin = "optional",
|
|
1631
|
-
}),
|
|
1632
|
-
S.init(e, t),
|
|
1629
|
+
const qo = /* @__PURE__ */ l("$ZodPrefault", (e, t) => {
|
|
1630
|
+
S.init(e, t), e._zod.optin = "optional", w(e._zod, "values", () => t.innerType._zod.values), e._zod.parse = (n, o) => (o.direction === "backward" || n.value === void 0 && (n.value = t.defaultValue), t.innerType._zod.run(n, o));
|
|
1631
|
+
}), Yo = /* @__PURE__ */ l("$ZodNonOptional", (e, t) => {
|
|
1632
|
+
S.init(e, t), w(e._zod, "values", () => {
|
|
1633
1633
|
const n = t.innerType._zod.values;
|
|
1634
1634
|
return n ? new Set([...n].filter((o) => o !== void 0)) : void 0;
|
|
1635
1635
|
}), e._zod.parse = (n, o) => {
|
|
1636
1636
|
const r = t.innerType._zod.run(n, o);
|
|
1637
|
-
return r instanceof Promise ? r.then((i) =>
|
|
1637
|
+
return r instanceof Promise ? r.then((i) => Je(i, e)) : Je(r, e);
|
|
1638
1638
|
};
|
|
1639
1639
|
});
|
|
1640
|
-
function
|
|
1640
|
+
function Je(e, t) {
|
|
1641
1641
|
return !e.issues.length && e.value === void 0 && e.issues.push({
|
|
1642
1642
|
code: "invalid_type",
|
|
1643
1643
|
expected: "nonoptional",
|
|
@@ -1645,78 +1645,78 @@ function Le(e, t) {
|
|
|
1645
1645
|
inst: t
|
|
1646
1646
|
}), e;
|
|
1647
1647
|
}
|
|
1648
|
-
const
|
|
1649
|
-
S.init(e, t),
|
|
1648
|
+
const Xo = /* @__PURE__ */ l("$ZodCatch", (e, t) => {
|
|
1649
|
+
S.init(e, t), w(e._zod, "optin", () => t.innerType._zod.optin), w(e._zod, "optout", () => t.innerType._zod.optout), w(e._zod, "values", () => t.innerType._zod.values), e._zod.parse = (n, o) => {
|
|
1650
1650
|
if (o.direction === "backward")
|
|
1651
1651
|
return t.innerType._zod.run(n, o);
|
|
1652
1652
|
const r = t.innerType._zod.run(n, o);
|
|
1653
1653
|
return r instanceof Promise ? r.then((i) => (n.value = i.value, i.issues.length && (n.value = t.catchValue({
|
|
1654
1654
|
...n,
|
|
1655
1655
|
error: {
|
|
1656
|
-
issues: i.issues.map((s) =>
|
|
1656
|
+
issues: i.issues.map((s) => J(s, o, M()))
|
|
1657
1657
|
},
|
|
1658
1658
|
input: n.value
|
|
1659
1659
|
}), n.issues = []), n)) : (n.value = r.value, r.issues.length && (n.value = t.catchValue({
|
|
1660
1660
|
...n,
|
|
1661
1661
|
error: {
|
|
1662
|
-
issues: r.issues.map((i) =>
|
|
1662
|
+
issues: r.issues.map((i) => J(i, o, M()))
|
|
1663
1663
|
},
|
|
1664
1664
|
input: n.value
|
|
1665
1665
|
}), n.issues = []), n);
|
|
1666
1666
|
};
|
|
1667
|
-
}),
|
|
1668
|
-
S.init(e, t),
|
|
1667
|
+
}), Ho = /* @__PURE__ */ l("$ZodPipe", (e, t) => {
|
|
1668
|
+
S.init(e, t), w(e._zod, "values", () => t.in._zod.values), w(e._zod, "optin", () => t.in._zod.optin), w(e._zod, "optout", () => t.out._zod.optout), w(e._zod, "propValues", () => t.in._zod.propValues), e._zod.parse = (n, o) => {
|
|
1669
1669
|
if (o.direction === "backward") {
|
|
1670
1670
|
const i = t.out._zod.run(n, o);
|
|
1671
|
-
return i instanceof Promise ? i.then((s) =>
|
|
1671
|
+
return i instanceof Promise ? i.then((s) => ae(s, t.in, o)) : ae(i, t.in, o);
|
|
1672
1672
|
}
|
|
1673
1673
|
const r = t.in._zod.run(n, o);
|
|
1674
|
-
return r instanceof Promise ? r.then((i) =>
|
|
1674
|
+
return r instanceof Promise ? r.then((i) => ae(i, t.out, o)) : ae(r, t.out, o);
|
|
1675
1675
|
};
|
|
1676
1676
|
});
|
|
1677
|
-
function
|
|
1677
|
+
function ae(e, t, n) {
|
|
1678
1678
|
return e.issues.length ? (e.aborted = !0, e) : t._zod.run({ value: e.value, issues: e.issues }, n);
|
|
1679
1679
|
}
|
|
1680
|
-
const
|
|
1681
|
-
S.init(e, t),
|
|
1680
|
+
const Qo = /* @__PURE__ */ l("$ZodReadonly", (e, t) => {
|
|
1681
|
+
S.init(e, t), w(e._zod, "propValues", () => t.innerType._zod.propValues), w(e._zod, "values", () => t.innerType._zod.values), w(e._zod, "optin", () => {
|
|
1682
1682
|
var n, o;
|
|
1683
1683
|
return (o = (n = t.innerType) == null ? void 0 : n._zod) == null ? void 0 : o.optin;
|
|
1684
|
-
}),
|
|
1684
|
+
}), w(e._zod, "optout", () => {
|
|
1685
1685
|
var n, o;
|
|
1686
1686
|
return (o = (n = t.innerType) == null ? void 0 : n._zod) == null ? void 0 : o.optout;
|
|
1687
1687
|
}), e._zod.parse = (n, o) => {
|
|
1688
1688
|
if (o.direction === "backward")
|
|
1689
1689
|
return t.innerType._zod.run(n, o);
|
|
1690
1690
|
const r = t.innerType._zod.run(n, o);
|
|
1691
|
-
return r instanceof Promise ? r.then(
|
|
1691
|
+
return r instanceof Promise ? r.then(Ve) : Ve(r);
|
|
1692
1692
|
};
|
|
1693
1693
|
});
|
|
1694
|
-
function
|
|
1694
|
+
function Ve(e) {
|
|
1695
1695
|
return e.value = Object.freeze(e.value), e;
|
|
1696
1696
|
}
|
|
1697
|
-
const
|
|
1698
|
-
S.init(e, t),
|
|
1697
|
+
const er = /* @__PURE__ */ l("$ZodLazy", (e, t) => {
|
|
1698
|
+
S.init(e, t), w(e._zod, "innerType", () => t.getter()), w(e._zod, "pattern", () => {
|
|
1699
1699
|
var n, o;
|
|
1700
1700
|
return (o = (n = e._zod.innerType) == null ? void 0 : n._zod) == null ? void 0 : o.pattern;
|
|
1701
|
-
}),
|
|
1701
|
+
}), w(e._zod, "propValues", () => {
|
|
1702
1702
|
var n, o;
|
|
1703
1703
|
return (o = (n = e._zod.innerType) == null ? void 0 : n._zod) == null ? void 0 : o.propValues;
|
|
1704
|
-
}),
|
|
1704
|
+
}), w(e._zod, "optin", () => {
|
|
1705
1705
|
var n, o;
|
|
1706
1706
|
return ((o = (n = e._zod.innerType) == null ? void 0 : n._zod) == null ? void 0 : o.optin) ?? void 0;
|
|
1707
|
-
}),
|
|
1707
|
+
}), w(e._zod, "optout", () => {
|
|
1708
1708
|
var n, o;
|
|
1709
1709
|
return ((o = (n = e._zod.innerType) == null ? void 0 : n._zod) == null ? void 0 : o.optout) ?? void 0;
|
|
1710
1710
|
}), e._zod.parse = (n, o) => e._zod.innerType._zod.run(n, o);
|
|
1711
|
-
}),
|
|
1712
|
-
|
|
1711
|
+
}), tr = /* @__PURE__ */ l("$ZodCustom", (e, t) => {
|
|
1712
|
+
j.init(e, t), S.init(e, t), e._zod.parse = (n, o) => n, e._zod.check = (n) => {
|
|
1713
1713
|
const o = n.value, r = t.fn(o);
|
|
1714
1714
|
if (r instanceof Promise)
|
|
1715
|
-
return r.then((i) =>
|
|
1716
|
-
|
|
1715
|
+
return r.then((i) => Be(i, n, o, e));
|
|
1716
|
+
Be(r, n, o, e);
|
|
1717
1717
|
};
|
|
1718
1718
|
});
|
|
1719
|
-
function
|
|
1719
|
+
function Be(e, t, n, o) {
|
|
1720
1720
|
if (!e) {
|
|
1721
1721
|
const r = {
|
|
1722
1722
|
code: "custom",
|
|
@@ -1728,11 +1728,11 @@ function Je(e, t, n, o) {
|
|
|
1728
1728
|
continue: !o._zod.def.abort
|
|
1729
1729
|
// params: inst._zod.def.params,
|
|
1730
1730
|
};
|
|
1731
|
-
o._zod.def.params && (r.params = o._zod.def.params), t.issues.push(
|
|
1731
|
+
o._zod.def.params && (r.params = o._zod.def.params), t.issues.push(oe(r));
|
|
1732
1732
|
}
|
|
1733
1733
|
}
|
|
1734
|
-
var
|
|
1735
|
-
class
|
|
1734
|
+
var We;
|
|
1735
|
+
class nr {
|
|
1736
1736
|
constructor() {
|
|
1737
1737
|
this._map = /* @__PURE__ */ new WeakMap(), this._idmap = /* @__PURE__ */ new Map();
|
|
1738
1738
|
}
|
|
@@ -1761,20 +1761,20 @@ class qo {
|
|
|
1761
1761
|
return this._map.has(t);
|
|
1762
1762
|
}
|
|
1763
1763
|
}
|
|
1764
|
-
function
|
|
1765
|
-
return new
|
|
1764
|
+
function or() {
|
|
1765
|
+
return new nr();
|
|
1766
1766
|
}
|
|
1767
|
-
(
|
|
1767
|
+
(We = globalThis).__zod_globalRegistry ?? (We.__zod_globalRegistry = or());
|
|
1768
1768
|
const ee = globalThis.__zod_globalRegistry;
|
|
1769
1769
|
// @__NO_SIDE_EFFECTS__
|
|
1770
|
-
function
|
|
1770
|
+
function rr(e, t) {
|
|
1771
1771
|
return new e({
|
|
1772
1772
|
type: "string",
|
|
1773
1773
|
...m(t)
|
|
1774
1774
|
});
|
|
1775
1775
|
}
|
|
1776
1776
|
// @__NO_SIDE_EFFECTS__
|
|
1777
|
-
function
|
|
1777
|
+
function ir(e, t) {
|
|
1778
1778
|
return new e({
|
|
1779
1779
|
type: "string",
|
|
1780
1780
|
format: "email",
|
|
@@ -1784,7 +1784,7 @@ function Ho(e, t) {
|
|
|
1784
1784
|
});
|
|
1785
1785
|
}
|
|
1786
1786
|
// @__NO_SIDE_EFFECTS__
|
|
1787
|
-
function
|
|
1787
|
+
function Ge(e, t) {
|
|
1788
1788
|
return new e({
|
|
1789
1789
|
type: "string",
|
|
1790
1790
|
format: "guid",
|
|
@@ -1794,7 +1794,7 @@ function Be(e, t) {
|
|
|
1794
1794
|
});
|
|
1795
1795
|
}
|
|
1796
1796
|
// @__NO_SIDE_EFFECTS__
|
|
1797
|
-
function
|
|
1797
|
+
function sr(e, t) {
|
|
1798
1798
|
return new e({
|
|
1799
1799
|
type: "string",
|
|
1800
1800
|
format: "uuid",
|
|
@@ -1804,7 +1804,7 @@ function Qo(e, t) {
|
|
|
1804
1804
|
});
|
|
1805
1805
|
}
|
|
1806
1806
|
// @__NO_SIDE_EFFECTS__
|
|
1807
|
-
function
|
|
1807
|
+
function ar(e, t) {
|
|
1808
1808
|
return new e({
|
|
1809
1809
|
type: "string",
|
|
1810
1810
|
format: "uuid",
|
|
@@ -1815,7 +1815,7 @@ function er(e, t) {
|
|
|
1815
1815
|
});
|
|
1816
1816
|
}
|
|
1817
1817
|
// @__NO_SIDE_EFFECTS__
|
|
1818
|
-
function
|
|
1818
|
+
function cr(e, t) {
|
|
1819
1819
|
return new e({
|
|
1820
1820
|
type: "string",
|
|
1821
1821
|
format: "uuid",
|
|
@@ -1826,7 +1826,7 @@ function tr(e, t) {
|
|
|
1826
1826
|
});
|
|
1827
1827
|
}
|
|
1828
1828
|
// @__NO_SIDE_EFFECTS__
|
|
1829
|
-
function
|
|
1829
|
+
function ur(e, t) {
|
|
1830
1830
|
return new e({
|
|
1831
1831
|
type: "string",
|
|
1832
1832
|
format: "uuid",
|
|
@@ -1837,7 +1837,7 @@ function nr(e, t) {
|
|
|
1837
1837
|
});
|
|
1838
1838
|
}
|
|
1839
1839
|
// @__NO_SIDE_EFFECTS__
|
|
1840
|
-
function
|
|
1840
|
+
function lr(e, t) {
|
|
1841
1841
|
return new e({
|
|
1842
1842
|
type: "string",
|
|
1843
1843
|
format: "url",
|
|
@@ -1847,7 +1847,7 @@ function or(e, t) {
|
|
|
1847
1847
|
});
|
|
1848
1848
|
}
|
|
1849
1849
|
// @__NO_SIDE_EFFECTS__
|
|
1850
|
-
function
|
|
1850
|
+
function pr(e, t) {
|
|
1851
1851
|
return new e({
|
|
1852
1852
|
type: "string",
|
|
1853
1853
|
format: "emoji",
|
|
@@ -1857,7 +1857,7 @@ function rr(e, t) {
|
|
|
1857
1857
|
});
|
|
1858
1858
|
}
|
|
1859
1859
|
// @__NO_SIDE_EFFECTS__
|
|
1860
|
-
function
|
|
1860
|
+
function fr(e, t) {
|
|
1861
1861
|
return new e({
|
|
1862
1862
|
type: "string",
|
|
1863
1863
|
format: "nanoid",
|
|
@@ -1867,7 +1867,7 @@ function ir(e, t) {
|
|
|
1867
1867
|
});
|
|
1868
1868
|
}
|
|
1869
1869
|
// @__NO_SIDE_EFFECTS__
|
|
1870
|
-
function
|
|
1870
|
+
function dr(e, t) {
|
|
1871
1871
|
return new e({
|
|
1872
1872
|
type: "string",
|
|
1873
1873
|
format: "cuid",
|
|
@@ -1877,7 +1877,7 @@ function sr(e, t) {
|
|
|
1877
1877
|
});
|
|
1878
1878
|
}
|
|
1879
1879
|
// @__NO_SIDE_EFFECTS__
|
|
1880
|
-
function
|
|
1880
|
+
function hr(e, t) {
|
|
1881
1881
|
return new e({
|
|
1882
1882
|
type: "string",
|
|
1883
1883
|
format: "cuid2",
|
|
@@ -1887,7 +1887,7 @@ function cr(e, t) {
|
|
|
1887
1887
|
});
|
|
1888
1888
|
}
|
|
1889
1889
|
// @__NO_SIDE_EFFECTS__
|
|
1890
|
-
function
|
|
1890
|
+
function mr(e, t) {
|
|
1891
1891
|
return new e({
|
|
1892
1892
|
type: "string",
|
|
1893
1893
|
format: "ulid",
|
|
@@ -1897,7 +1897,7 @@ function ar(e, t) {
|
|
|
1897
1897
|
});
|
|
1898
1898
|
}
|
|
1899
1899
|
// @__NO_SIDE_EFFECTS__
|
|
1900
|
-
function
|
|
1900
|
+
function gr(e, t) {
|
|
1901
1901
|
return new e({
|
|
1902
1902
|
type: "string",
|
|
1903
1903
|
format: "xid",
|
|
@@ -1907,7 +1907,7 @@ function ur(e, t) {
|
|
|
1907
1907
|
});
|
|
1908
1908
|
}
|
|
1909
1909
|
// @__NO_SIDE_EFFECTS__
|
|
1910
|
-
function
|
|
1910
|
+
function _r(e, t) {
|
|
1911
1911
|
return new e({
|
|
1912
1912
|
type: "string",
|
|
1913
1913
|
format: "ksuid",
|
|
@@ -1917,7 +1917,7 @@ function lr(e, t) {
|
|
|
1917
1917
|
});
|
|
1918
1918
|
}
|
|
1919
1919
|
// @__NO_SIDE_EFFECTS__
|
|
1920
|
-
function
|
|
1920
|
+
function vr(e, t) {
|
|
1921
1921
|
return new e({
|
|
1922
1922
|
type: "string",
|
|
1923
1923
|
format: "ipv4",
|
|
@@ -1927,7 +1927,7 @@ function pr(e, t) {
|
|
|
1927
1927
|
});
|
|
1928
1928
|
}
|
|
1929
1929
|
// @__NO_SIDE_EFFECTS__
|
|
1930
|
-
function
|
|
1930
|
+
function yr(e, t) {
|
|
1931
1931
|
return new e({
|
|
1932
1932
|
type: "string",
|
|
1933
1933
|
format: "ipv6",
|
|
@@ -1937,7 +1937,7 @@ function fr(e, t) {
|
|
|
1937
1937
|
});
|
|
1938
1938
|
}
|
|
1939
1939
|
// @__NO_SIDE_EFFECTS__
|
|
1940
|
-
function
|
|
1940
|
+
function br(e, t) {
|
|
1941
1941
|
return new e({
|
|
1942
1942
|
type: "string",
|
|
1943
1943
|
format: "cidrv4",
|
|
@@ -1947,7 +1947,7 @@ function dr(e, t) {
|
|
|
1947
1947
|
});
|
|
1948
1948
|
}
|
|
1949
1949
|
// @__NO_SIDE_EFFECTS__
|
|
1950
|
-
function
|
|
1950
|
+
function wr(e, t) {
|
|
1951
1951
|
return new e({
|
|
1952
1952
|
type: "string",
|
|
1953
1953
|
format: "cidrv6",
|
|
@@ -1957,7 +1957,7 @@ function hr(e, t) {
|
|
|
1957
1957
|
});
|
|
1958
1958
|
}
|
|
1959
1959
|
// @__NO_SIDE_EFFECTS__
|
|
1960
|
-
function
|
|
1960
|
+
function zr(e, t) {
|
|
1961
1961
|
return new e({
|
|
1962
1962
|
type: "string",
|
|
1963
1963
|
format: "base64",
|
|
@@ -1967,7 +1967,7 @@ function mr(e, t) {
|
|
|
1967
1967
|
});
|
|
1968
1968
|
}
|
|
1969
1969
|
// @__NO_SIDE_EFFECTS__
|
|
1970
|
-
function
|
|
1970
|
+
function kr(e, t) {
|
|
1971
1971
|
return new e({
|
|
1972
1972
|
type: "string",
|
|
1973
1973
|
format: "base64url",
|
|
@@ -1977,7 +1977,7 @@ function gr(e, t) {
|
|
|
1977
1977
|
});
|
|
1978
1978
|
}
|
|
1979
1979
|
// @__NO_SIDE_EFFECTS__
|
|
1980
|
-
function
|
|
1980
|
+
function Sr(e, t) {
|
|
1981
1981
|
return new e({
|
|
1982
1982
|
type: "string",
|
|
1983
1983
|
format: "e164",
|
|
@@ -1987,7 +1987,7 @@ function _r(e, t) {
|
|
|
1987
1987
|
});
|
|
1988
1988
|
}
|
|
1989
1989
|
// @__NO_SIDE_EFFECTS__
|
|
1990
|
-
function
|
|
1990
|
+
function Zr(e, t) {
|
|
1991
1991
|
return new e({
|
|
1992
1992
|
type: "string",
|
|
1993
1993
|
format: "jwt",
|
|
@@ -1997,7 +1997,7 @@ function vr(e, t) {
|
|
|
1997
1997
|
});
|
|
1998
1998
|
}
|
|
1999
1999
|
// @__NO_SIDE_EFFECTS__
|
|
2000
|
-
function
|
|
2000
|
+
function $r(e, t) {
|
|
2001
2001
|
return new e({
|
|
2002
2002
|
type: "string",
|
|
2003
2003
|
format: "datetime",
|
|
@@ -2009,7 +2009,7 @@ function yr(e, t) {
|
|
|
2009
2009
|
});
|
|
2010
2010
|
}
|
|
2011
2011
|
// @__NO_SIDE_EFFECTS__
|
|
2012
|
-
function
|
|
2012
|
+
function Or(e, t) {
|
|
2013
2013
|
return new e({
|
|
2014
2014
|
type: "string",
|
|
2015
2015
|
format: "date",
|
|
@@ -2018,7 +2018,7 @@ function br(e, t) {
|
|
|
2018
2018
|
});
|
|
2019
2019
|
}
|
|
2020
2020
|
// @__NO_SIDE_EFFECTS__
|
|
2021
|
-
function
|
|
2021
|
+
function Tr(e, t) {
|
|
2022
2022
|
return new e({
|
|
2023
2023
|
type: "string",
|
|
2024
2024
|
format: "time",
|
|
@@ -2028,7 +2028,7 @@ function zr(e, t) {
|
|
|
2028
2028
|
});
|
|
2029
2029
|
}
|
|
2030
2030
|
// @__NO_SIDE_EFFECTS__
|
|
2031
|
-
function
|
|
2031
|
+
function Ir(e, t) {
|
|
2032
2032
|
return new e({
|
|
2033
2033
|
type: "string",
|
|
2034
2034
|
format: "duration",
|
|
@@ -2037,7 +2037,7 @@ function wr(e, t) {
|
|
|
2037
2037
|
});
|
|
2038
2038
|
}
|
|
2039
2039
|
// @__NO_SIDE_EFFECTS__
|
|
2040
|
-
function
|
|
2040
|
+
function Pr(e, t) {
|
|
2041
2041
|
return new e({
|
|
2042
2042
|
type: "number",
|
|
2043
2043
|
checks: [],
|
|
@@ -2045,7 +2045,7 @@ function kr(e, t) {
|
|
|
2045
2045
|
});
|
|
2046
2046
|
}
|
|
2047
2047
|
// @__NO_SIDE_EFFECTS__
|
|
2048
|
-
function
|
|
2048
|
+
function Er(e, t) {
|
|
2049
2049
|
return new e({
|
|
2050
2050
|
type: "number",
|
|
2051
2051
|
check: "number_format",
|
|
@@ -2055,35 +2055,35 @@ function Sr(e, t) {
|
|
|
2055
2055
|
});
|
|
2056
2056
|
}
|
|
2057
2057
|
// @__NO_SIDE_EFFECTS__
|
|
2058
|
-
function
|
|
2058
|
+
function Nr(e, t) {
|
|
2059
2059
|
return new e({
|
|
2060
2060
|
type: "boolean",
|
|
2061
2061
|
...m(t)
|
|
2062
2062
|
});
|
|
2063
2063
|
}
|
|
2064
2064
|
// @__NO_SIDE_EFFECTS__
|
|
2065
|
-
function
|
|
2065
|
+
function Cr(e, t) {
|
|
2066
2066
|
return new e({
|
|
2067
2067
|
type: "null",
|
|
2068
2068
|
...m(t)
|
|
2069
2069
|
});
|
|
2070
2070
|
}
|
|
2071
2071
|
// @__NO_SIDE_EFFECTS__
|
|
2072
|
-
function
|
|
2072
|
+
function Ar(e) {
|
|
2073
2073
|
return new e({
|
|
2074
2074
|
type: "unknown"
|
|
2075
2075
|
});
|
|
2076
2076
|
}
|
|
2077
2077
|
// @__NO_SIDE_EFFECTS__
|
|
2078
|
-
function
|
|
2078
|
+
function jr(e, t) {
|
|
2079
2079
|
return new e({
|
|
2080
2080
|
type: "never",
|
|
2081
2081
|
...m(t)
|
|
2082
2082
|
});
|
|
2083
2083
|
}
|
|
2084
2084
|
// @__NO_SIDE_EFFECTS__
|
|
2085
|
-
function
|
|
2086
|
-
return new
|
|
2085
|
+
function Ke(e, t) {
|
|
2086
|
+
return new vt({
|
|
2087
2087
|
check: "less_than",
|
|
2088
2088
|
...m(t),
|
|
2089
2089
|
value: e,
|
|
@@ -2091,8 +2091,8 @@ function We(e, t) {
|
|
|
2091
2091
|
});
|
|
2092
2092
|
}
|
|
2093
2093
|
// @__NO_SIDE_EFFECTS__
|
|
2094
|
-
function
|
|
2095
|
-
return new
|
|
2094
|
+
function ye(e, t) {
|
|
2095
|
+
return new vt({
|
|
2096
2096
|
check: "less_than",
|
|
2097
2097
|
...m(t),
|
|
2098
2098
|
value: e,
|
|
@@ -2100,8 +2100,8 @@ function ve(e, t) {
|
|
|
2100
2100
|
});
|
|
2101
2101
|
}
|
|
2102
2102
|
// @__NO_SIDE_EFFECTS__
|
|
2103
|
-
function
|
|
2104
|
-
return new
|
|
2103
|
+
function qe(e, t) {
|
|
2104
|
+
return new yt({
|
|
2105
2105
|
check: "greater_than",
|
|
2106
2106
|
...m(t),
|
|
2107
2107
|
value: e,
|
|
@@ -2109,8 +2109,8 @@ function Ke(e, t) {
|
|
|
2109
2109
|
});
|
|
2110
2110
|
}
|
|
2111
2111
|
// @__NO_SIDE_EFFECTS__
|
|
2112
|
-
function
|
|
2113
|
-
return new
|
|
2112
|
+
function be(e, t) {
|
|
2113
|
+
return new yt({
|
|
2114
2114
|
check: "greater_than",
|
|
2115
2115
|
...m(t),
|
|
2116
2116
|
value: e,
|
|
@@ -2118,40 +2118,40 @@ function ye(e, t) {
|
|
|
2118
2118
|
});
|
|
2119
2119
|
}
|
|
2120
2120
|
// @__NO_SIDE_EFFECTS__
|
|
2121
|
-
function
|
|
2122
|
-
return new
|
|
2121
|
+
function Ye(e, t) {
|
|
2122
|
+
return new Bn({
|
|
2123
2123
|
check: "multiple_of",
|
|
2124
2124
|
...m(t),
|
|
2125
2125
|
value: e
|
|
2126
2126
|
});
|
|
2127
2127
|
}
|
|
2128
2128
|
// @__NO_SIDE_EFFECTS__
|
|
2129
|
-
function
|
|
2130
|
-
return new
|
|
2129
|
+
function $t(e, t) {
|
|
2130
|
+
return new Gn({
|
|
2131
2131
|
check: "max_length",
|
|
2132
2132
|
...m(t),
|
|
2133
2133
|
maximum: e
|
|
2134
2134
|
});
|
|
2135
2135
|
}
|
|
2136
2136
|
// @__NO_SIDE_EFFECTS__
|
|
2137
|
-
function
|
|
2138
|
-
return new
|
|
2137
|
+
function le(e, t) {
|
|
2138
|
+
return new Kn({
|
|
2139
2139
|
check: "min_length",
|
|
2140
2140
|
...m(t),
|
|
2141
2141
|
minimum: e
|
|
2142
2142
|
});
|
|
2143
2143
|
}
|
|
2144
2144
|
// @__NO_SIDE_EFFECTS__
|
|
2145
|
-
function
|
|
2146
|
-
return new
|
|
2145
|
+
function Ot(e, t) {
|
|
2146
|
+
return new qn({
|
|
2147
2147
|
check: "length_equals",
|
|
2148
2148
|
...m(t),
|
|
2149
2149
|
length: e
|
|
2150
2150
|
});
|
|
2151
2151
|
}
|
|
2152
2152
|
// @__NO_SIDE_EFFECTS__
|
|
2153
|
-
function
|
|
2154
|
-
return new
|
|
2153
|
+
function xr(e, t) {
|
|
2154
|
+
return new Yn({
|
|
2155
2155
|
check: "string_format",
|
|
2156
2156
|
format: "regex",
|
|
2157
2157
|
...m(t),
|
|
@@ -2159,24 +2159,24 @@ function Pr(e, t) {
|
|
|
2159
2159
|
});
|
|
2160
2160
|
}
|
|
2161
2161
|
// @__NO_SIDE_EFFECTS__
|
|
2162
|
-
function
|
|
2163
|
-
return new
|
|
2162
|
+
function Rr(e) {
|
|
2163
|
+
return new Xn({
|
|
2164
2164
|
check: "string_format",
|
|
2165
2165
|
format: "lowercase",
|
|
2166
2166
|
...m(e)
|
|
2167
2167
|
});
|
|
2168
2168
|
}
|
|
2169
2169
|
// @__NO_SIDE_EFFECTS__
|
|
2170
|
-
function
|
|
2171
|
-
return new
|
|
2170
|
+
function Dr(e) {
|
|
2171
|
+
return new Hn({
|
|
2172
2172
|
check: "string_format",
|
|
2173
2173
|
format: "uppercase",
|
|
2174
2174
|
...m(e)
|
|
2175
2175
|
});
|
|
2176
2176
|
}
|
|
2177
2177
|
// @__NO_SIDE_EFFECTS__
|
|
2178
|
-
function
|
|
2179
|
-
return new
|
|
2178
|
+
function Fr(e, t) {
|
|
2179
|
+
return new Qn({
|
|
2180
2180
|
check: "string_format",
|
|
2181
2181
|
format: "includes",
|
|
2182
2182
|
...m(t),
|
|
@@ -2184,8 +2184,8 @@ function Nr(e, t) {
|
|
|
2184
2184
|
});
|
|
2185
2185
|
}
|
|
2186
2186
|
// @__NO_SIDE_EFFECTS__
|
|
2187
|
-
function
|
|
2188
|
-
return new
|
|
2187
|
+
function Lr(e, t) {
|
|
2188
|
+
return new eo({
|
|
2189
2189
|
check: "string_format",
|
|
2190
2190
|
format: "starts_with",
|
|
2191
2191
|
...m(t),
|
|
@@ -2193,8 +2193,8 @@ function jr(e, t) {
|
|
|
2193
2193
|
});
|
|
2194
2194
|
}
|
|
2195
2195
|
// @__NO_SIDE_EFFECTS__
|
|
2196
|
-
function
|
|
2197
|
-
return new
|
|
2196
|
+
function Ur(e, t) {
|
|
2197
|
+
return new to({
|
|
2198
2198
|
check: "string_format",
|
|
2199
2199
|
format: "ends_with",
|
|
2200
2200
|
...m(t),
|
|
@@ -2203,33 +2203,33 @@ function Ar(e, t) {
|
|
|
2203
2203
|
}
|
|
2204
2204
|
// @__NO_SIDE_EFFECTS__
|
|
2205
2205
|
function H(e) {
|
|
2206
|
-
return new
|
|
2206
|
+
return new no({
|
|
2207
2207
|
check: "overwrite",
|
|
2208
2208
|
tx: e
|
|
2209
2209
|
});
|
|
2210
2210
|
}
|
|
2211
2211
|
// @__NO_SIDE_EFFECTS__
|
|
2212
|
-
function
|
|
2212
|
+
function Mr(e) {
|
|
2213
2213
|
return /* @__PURE__ */ H((t) => t.normalize(e));
|
|
2214
2214
|
}
|
|
2215
2215
|
// @__NO_SIDE_EFFECTS__
|
|
2216
|
-
function
|
|
2216
|
+
function Jr() {
|
|
2217
2217
|
return /* @__PURE__ */ H((e) => e.trim());
|
|
2218
2218
|
}
|
|
2219
2219
|
// @__NO_SIDE_EFFECTS__
|
|
2220
|
-
function
|
|
2220
|
+
function Vr() {
|
|
2221
2221
|
return /* @__PURE__ */ H((e) => e.toLowerCase());
|
|
2222
2222
|
}
|
|
2223
2223
|
// @__NO_SIDE_EFFECTS__
|
|
2224
|
-
function
|
|
2224
|
+
function Br() {
|
|
2225
2225
|
return /* @__PURE__ */ H((e) => e.toUpperCase());
|
|
2226
2226
|
}
|
|
2227
2227
|
// @__NO_SIDE_EFFECTS__
|
|
2228
|
-
function
|
|
2229
|
-
return /* @__PURE__ */ H((e) =>
|
|
2228
|
+
function Wr() {
|
|
2229
|
+
return /* @__PURE__ */ H((e) => Kt(e));
|
|
2230
2230
|
}
|
|
2231
2231
|
// @__NO_SIDE_EFFECTS__
|
|
2232
|
-
function
|
|
2232
|
+
function Gr(e, t, n) {
|
|
2233
2233
|
return new e({
|
|
2234
2234
|
type: "array",
|
|
2235
2235
|
element: t,
|
|
@@ -2240,7 +2240,7 @@ function Ur(e, t, n) {
|
|
|
2240
2240
|
});
|
|
2241
2241
|
}
|
|
2242
2242
|
// @__NO_SIDE_EFFECTS__
|
|
2243
|
-
function
|
|
2243
|
+
function Kr(e, t, n) {
|
|
2244
2244
|
return new e({
|
|
2245
2245
|
type: "custom",
|
|
2246
2246
|
check: "custom",
|
|
@@ -2249,26 +2249,26 @@ function Lr(e, t, n) {
|
|
|
2249
2249
|
});
|
|
2250
2250
|
}
|
|
2251
2251
|
// @__NO_SIDE_EFFECTS__
|
|
2252
|
-
function
|
|
2253
|
-
const t = /* @__PURE__ */
|
|
2252
|
+
function qr(e) {
|
|
2253
|
+
const t = /* @__PURE__ */ Yr((n) => (n.addIssue = (o) => {
|
|
2254
2254
|
if (typeof o == "string")
|
|
2255
|
-
n.issues.push(
|
|
2255
|
+
n.issues.push(oe(o, n.value, t._zod.def));
|
|
2256
2256
|
else {
|
|
2257
2257
|
const r = o;
|
|
2258
|
-
r.fatal && (r.continue = !1), r.code ?? (r.code = "custom"), r.input ?? (r.input = n.value), r.inst ?? (r.inst = t), r.continue ?? (r.continue = !t._zod.def.abort), n.issues.push(
|
|
2258
|
+
r.fatal && (r.continue = !1), r.code ?? (r.code = "custom"), r.input ?? (r.input = n.value), r.inst ?? (r.inst = t), r.continue ?? (r.continue = !t._zod.def.abort), n.issues.push(oe(r));
|
|
2259
2259
|
}
|
|
2260
2260
|
}, e(n.value, n)));
|
|
2261
2261
|
return t;
|
|
2262
2262
|
}
|
|
2263
2263
|
// @__NO_SIDE_EFFECTS__
|
|
2264
|
-
function
|
|
2265
|
-
const n = new
|
|
2264
|
+
function Yr(e, t) {
|
|
2265
|
+
const n = new j({
|
|
2266
2266
|
check: "custom",
|
|
2267
2267
|
...m(t)
|
|
2268
2268
|
});
|
|
2269
2269
|
return n._zod.check = e, n;
|
|
2270
2270
|
}
|
|
2271
|
-
function
|
|
2271
|
+
function Tt(e) {
|
|
2272
2272
|
let t = (e == null ? void 0 : e.target) ?? "draft-2020-12";
|
|
2273
2273
|
return t === "draft-4" && (t = "draft-04"), t === "draft-7" && (t = "draft-07"), {
|
|
2274
2274
|
processors: e.processors ?? {},
|
|
@@ -2285,7 +2285,7 @@ function kt(e) {
|
|
|
2285
2285
|
external: (e == null ? void 0 : e.external) ?? void 0
|
|
2286
2286
|
};
|
|
2287
2287
|
}
|
|
2288
|
-
function
|
|
2288
|
+
function T(e, t, n = { path: [], schemaPath: [] }) {
|
|
2289
2289
|
var p, f;
|
|
2290
2290
|
var o;
|
|
2291
2291
|
const r = e._zod.def, i = t.seen.get(e);
|
|
@@ -2293,31 +2293,31 @@ function O(e, t, n = { path: [], schemaPath: [] }) {
|
|
|
2293
2293
|
return i.count++, n.schemaPath.includes(e) && (i.cycle = n.path), i.schema;
|
|
2294
2294
|
const s = { schema: {}, count: 1, cycle: void 0, path: n.path };
|
|
2295
2295
|
t.seen.set(e, s);
|
|
2296
|
-
const
|
|
2297
|
-
if (
|
|
2298
|
-
s.schema =
|
|
2296
|
+
const a = (f = (p = e._zod).toJSONSchema) == null ? void 0 : f.call(p);
|
|
2297
|
+
if (a)
|
|
2298
|
+
s.schema = a;
|
|
2299
2299
|
else {
|
|
2300
|
-
const
|
|
2300
|
+
const _ = {
|
|
2301
2301
|
...n,
|
|
2302
2302
|
schemaPath: [...n.schemaPath, e],
|
|
2303
2303
|
path: n.path
|
|
2304
2304
|
};
|
|
2305
2305
|
if (e._zod.processJSONSchema)
|
|
2306
|
-
e._zod.processJSONSchema(t, s.schema,
|
|
2306
|
+
e._zod.processJSONSchema(t, s.schema, _);
|
|
2307
2307
|
else {
|
|
2308
|
-
const k = s.schema,
|
|
2309
|
-
if (!
|
|
2308
|
+
const k = s.schema, z = t.processors[r.type];
|
|
2309
|
+
if (!z)
|
|
2310
2310
|
throw new Error(`[toJSONSchema]: Non-representable type encountered: ${r.type}`);
|
|
2311
|
-
|
|
2311
|
+
z(e, t, k, _);
|
|
2312
2312
|
}
|
|
2313
|
-
const
|
|
2314
|
-
|
|
2313
|
+
const b = e._zod.parent;
|
|
2314
|
+
b && (s.ref || (s.ref = b), T(b, t, _), t.seen.get(b).isParent = !0);
|
|
2315
2315
|
}
|
|
2316
|
-
const
|
|
2317
|
-
return
|
|
2316
|
+
const c = t.metadataRegistry.get(e);
|
|
2317
|
+
return c && Object.assign(s.schema, c), t.io === "input" && C(e) && (delete s.schema.examples, delete s.schema.default), t.io === "input" && s.schema._prefault && ((o = s.schema).default ?? (o.default = s.schema._prefault)), delete s.schema._prefault, t.seen.get(e).schema;
|
|
2318
2318
|
}
|
|
2319
|
-
function
|
|
2320
|
-
var s,
|
|
2319
|
+
function It(e, t) {
|
|
2320
|
+
var s, a, c, u;
|
|
2321
2321
|
const n = e.seen.get(t);
|
|
2322
2322
|
if (!n)
|
|
2323
2323
|
throw new Error("Unprocessed schema. This is a bug in Zod.");
|
|
@@ -2325,41 +2325,41 @@ function St(e, t) {
|
|
|
2325
2325
|
for (const p of e.seen.entries()) {
|
|
2326
2326
|
const f = (s = e.metadataRegistry.get(p[0])) == null ? void 0 : s.id;
|
|
2327
2327
|
if (f) {
|
|
2328
|
-
const
|
|
2329
|
-
if (
|
|
2328
|
+
const _ = o.get(f);
|
|
2329
|
+
if (_ && _ !== p[0])
|
|
2330
2330
|
throw new Error(`Duplicate schema id "${f}" detected during JSON Schema conversion. Two different schemas cannot share the same id when converted together.`);
|
|
2331
2331
|
o.set(f, p[0]);
|
|
2332
2332
|
}
|
|
2333
2333
|
}
|
|
2334
2334
|
const r = (p) => {
|
|
2335
|
-
var
|
|
2335
|
+
var z;
|
|
2336
2336
|
const f = e.target === "draft-2020-12" ? "$defs" : "definitions";
|
|
2337
2337
|
if (e.external) {
|
|
2338
|
-
const
|
|
2339
|
-
if (
|
|
2340
|
-
return { ref: Q(
|
|
2338
|
+
const P = (z = e.external.registry.get(p[0])) == null ? void 0 : z.id, Q = e.external.uri ?? ((re) => re);
|
|
2339
|
+
if (P)
|
|
2340
|
+
return { ref: Q(P) };
|
|
2341
2341
|
const N = p[1].defId ?? p[1].schema.id ?? `schema${e.counter++}`;
|
|
2342
2342
|
return p[1].defId = N, { defId: N, ref: `${Q("__shared")}#/${f}/${N}` };
|
|
2343
2343
|
}
|
|
2344
2344
|
if (p[1] === n)
|
|
2345
2345
|
return { ref: "#" };
|
|
2346
|
-
const
|
|
2347
|
-
return { defId: k, ref:
|
|
2346
|
+
const b = `#/${f}/`, k = p[1].schema.id ?? `__schema${e.counter++}`;
|
|
2347
|
+
return { defId: k, ref: b + k };
|
|
2348
2348
|
}, i = (p) => {
|
|
2349
2349
|
if (p[1].schema.$ref)
|
|
2350
2350
|
return;
|
|
2351
|
-
const f = p[1], { ref:
|
|
2352
|
-
f.def = { ...f.schema },
|
|
2351
|
+
const f = p[1], { ref: _, defId: b } = r(p);
|
|
2352
|
+
f.def = { ...f.schema }, b && (f.defId = b);
|
|
2353
2353
|
const k = f.schema;
|
|
2354
|
-
for (const
|
|
2355
|
-
delete k[
|
|
2356
|
-
k.$ref =
|
|
2354
|
+
for (const z in k)
|
|
2355
|
+
delete k[z];
|
|
2356
|
+
k.$ref = _;
|
|
2357
2357
|
};
|
|
2358
2358
|
if (e.cycles === "throw")
|
|
2359
2359
|
for (const p of e.seen.entries()) {
|
|
2360
2360
|
const f = p[1];
|
|
2361
2361
|
if (f.cycle)
|
|
2362
|
-
throw new Error(`Cycle detected: #/${(
|
|
2362
|
+
throw new Error(`Cycle detected: #/${(a = f.cycle) == null ? void 0 : a.join("/")}/<root>
|
|
2363
2363
|
|
|
2364
2364
|
Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.`);
|
|
2365
2365
|
}
|
|
@@ -2370,8 +2370,8 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
2370
2370
|
continue;
|
|
2371
2371
|
}
|
|
2372
2372
|
if (e.external) {
|
|
2373
|
-
const
|
|
2374
|
-
if (t !== p[0] &&
|
|
2373
|
+
const b = (c = e.external.registry.get(p[0])) == null ? void 0 : c.id;
|
|
2374
|
+
if (t !== p[0] && b) {
|
|
2375
2375
|
i(p);
|
|
2376
2376
|
continue;
|
|
2377
2377
|
}
|
|
@@ -2390,8 +2390,8 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
2390
2390
|
}
|
|
2391
2391
|
}
|
|
2392
2392
|
}
|
|
2393
|
-
function
|
|
2394
|
-
var s,
|
|
2393
|
+
function Pt(e, t) {
|
|
2394
|
+
var s, a, c;
|
|
2395
2395
|
const n = e.seen.get(t);
|
|
2396
2396
|
if (!n)
|
|
2397
2397
|
throw new Error("Unprocessed schema. This is a bug in Zod.");
|
|
@@ -2399,24 +2399,24 @@ function $t(e, t) {
|
|
|
2399
2399
|
const p = e.seen.get(u);
|
|
2400
2400
|
if (p.ref === null)
|
|
2401
2401
|
return;
|
|
2402
|
-
const f = p.def ?? p.schema,
|
|
2403
|
-
if (p.ref = null,
|
|
2404
|
-
o(
|
|
2405
|
-
const
|
|
2406
|
-
if (
|
|
2402
|
+
const f = p.def ?? p.schema, _ = { ...f }, b = p.ref;
|
|
2403
|
+
if (p.ref = null, b) {
|
|
2404
|
+
o(b);
|
|
2405
|
+
const z = e.seen.get(b), P = z.schema;
|
|
2406
|
+
if (P.$ref && (e.target === "draft-07" || e.target === "draft-04" || e.target === "openapi-3.0") ? (f.allOf = f.allOf ?? [], f.allOf.push(P)) : Object.assign(f, P), Object.assign(f, _), u._zod.parent === b)
|
|
2407
2407
|
for (const N in f)
|
|
2408
|
-
N === "$ref" || N === "allOf" || N in
|
|
2409
|
-
if (
|
|
2408
|
+
N === "$ref" || N === "allOf" || N in _ || delete f[N];
|
|
2409
|
+
if (P.$ref && z.def)
|
|
2410
2410
|
for (const N in f)
|
|
2411
|
-
N === "$ref" || N === "allOf" || N in
|
|
2411
|
+
N === "$ref" || N === "allOf" || N in z.def && JSON.stringify(f[N]) === JSON.stringify(z.def[N]) && delete f[N];
|
|
2412
2412
|
}
|
|
2413
2413
|
const k = u._zod.parent;
|
|
2414
|
-
if (k && k !==
|
|
2414
|
+
if (k && k !== b) {
|
|
2415
2415
|
o(k);
|
|
2416
|
-
const
|
|
2417
|
-
if (
|
|
2418
|
-
for (const
|
|
2419
|
-
|
|
2416
|
+
const z = e.seen.get(k);
|
|
2417
|
+
if (z != null && z.schema.$ref && (f.$ref = z.schema.$ref, z.def))
|
|
2418
|
+
for (const P in f)
|
|
2419
|
+
P === "$ref" || P === "allOf" || P in z.def && JSON.stringify(f[P]) === JSON.stringify(z.def[P]) && delete f[P];
|
|
2420
2420
|
}
|
|
2421
2421
|
e.override({
|
|
2422
2422
|
zodSchema: u,
|
|
@@ -2428,13 +2428,13 @@ function $t(e, t) {
|
|
|
2428
2428
|
o(u[0]);
|
|
2429
2429
|
const r = {};
|
|
2430
2430
|
if (e.target === "draft-2020-12" ? r.$schema = "https://json-schema.org/draft/2020-12/schema" : e.target === "draft-07" ? r.$schema = "http://json-schema.org/draft-07/schema#" : e.target === "draft-04" ? r.$schema = "http://json-schema.org/draft-04/schema#" : e.target, (s = e.external) != null && s.uri) {
|
|
2431
|
-
const u = (
|
|
2431
|
+
const u = (a = e.external.registry.get(t)) == null ? void 0 : a.id;
|
|
2432
2432
|
if (!u)
|
|
2433
2433
|
throw new Error("Schema is missing an `id` property");
|
|
2434
2434
|
r.$id = e.external.uri(u);
|
|
2435
2435
|
}
|
|
2436
2436
|
Object.assign(r, n.def ?? n.schema);
|
|
2437
|
-
const i = ((
|
|
2437
|
+
const i = ((c = e.external) == null ? void 0 : c.defs) ?? {};
|
|
2438
2438
|
for (const u of e.seen.entries()) {
|
|
2439
2439
|
const p = u[1];
|
|
2440
2440
|
p.def && p.defId && (i[p.defId] = p.def);
|
|
@@ -2446,8 +2446,8 @@ function $t(e, t) {
|
|
|
2446
2446
|
value: {
|
|
2447
2447
|
...t["~standard"],
|
|
2448
2448
|
jsonSchema: {
|
|
2449
|
-
input:
|
|
2450
|
-
output:
|
|
2449
|
+
input: pe(t, "input", e.processors),
|
|
2450
|
+
output: pe(t, "output", e.processors)
|
|
2451
2451
|
}
|
|
2452
2452
|
},
|
|
2453
2453
|
enumerable: !1,
|
|
@@ -2457,7 +2457,7 @@ function $t(e, t) {
|
|
|
2457
2457
|
throw new Error("Error converting schema to JSON.");
|
|
2458
2458
|
}
|
|
2459
2459
|
}
|
|
2460
|
-
function
|
|
2460
|
+
function C(e, t) {
|
|
2461
2461
|
const n = t ?? { seen: /* @__PURE__ */ new Set() };
|
|
2462
2462
|
if (n.seen.has(e))
|
|
2463
2463
|
return !1;
|
|
@@ -2466,58 +2466,58 @@ function j(e, t) {
|
|
|
2466
2466
|
if (o.type === "transform")
|
|
2467
2467
|
return !0;
|
|
2468
2468
|
if (o.type === "array")
|
|
2469
|
-
return
|
|
2469
|
+
return C(o.element, n);
|
|
2470
2470
|
if (o.type === "set")
|
|
2471
|
-
return
|
|
2471
|
+
return C(o.valueType, n);
|
|
2472
2472
|
if (o.type === "lazy")
|
|
2473
|
-
return
|
|
2473
|
+
return C(o.getter(), n);
|
|
2474
2474
|
if (o.type === "promise" || o.type === "optional" || o.type === "nonoptional" || o.type === "nullable" || o.type === "readonly" || o.type === "default" || o.type === "prefault")
|
|
2475
|
-
return
|
|
2475
|
+
return C(o.innerType, n);
|
|
2476
2476
|
if (o.type === "intersection")
|
|
2477
|
-
return
|
|
2477
|
+
return C(o.left, n) || C(o.right, n);
|
|
2478
2478
|
if (o.type === "record" || o.type === "map")
|
|
2479
|
-
return
|
|
2479
|
+
return C(o.keyType, n) || C(o.valueType, n);
|
|
2480
2480
|
if (o.type === "pipe")
|
|
2481
|
-
return
|
|
2481
|
+
return C(o.in, n) || C(o.out, n);
|
|
2482
2482
|
if (o.type === "object") {
|
|
2483
2483
|
for (const r in o.shape)
|
|
2484
|
-
if (
|
|
2484
|
+
if (C(o.shape[r], n))
|
|
2485
2485
|
return !0;
|
|
2486
2486
|
return !1;
|
|
2487
2487
|
}
|
|
2488
2488
|
if (o.type === "union") {
|
|
2489
2489
|
for (const r of o.options)
|
|
2490
|
-
if (
|
|
2490
|
+
if (C(r, n))
|
|
2491
2491
|
return !0;
|
|
2492
2492
|
return !1;
|
|
2493
2493
|
}
|
|
2494
2494
|
if (o.type === "tuple") {
|
|
2495
2495
|
for (const r of o.items)
|
|
2496
|
-
if (
|
|
2496
|
+
if (C(r, n))
|
|
2497
2497
|
return !0;
|
|
2498
|
-
return !!(o.rest &&
|
|
2498
|
+
return !!(o.rest && C(o.rest, n));
|
|
2499
2499
|
}
|
|
2500
2500
|
return !1;
|
|
2501
2501
|
}
|
|
2502
|
-
const
|
|
2503
|
-
const o =
|
|
2504
|
-
return
|
|
2505
|
-
},
|
|
2506
|
-
const { libraryOptions: r, target: i } = o ?? {}, s =
|
|
2507
|
-
return
|
|
2508
|
-
},
|
|
2502
|
+
const Xr = (e, t = {}) => (n) => {
|
|
2503
|
+
const o = Tt({ ...n, processors: t });
|
|
2504
|
+
return T(e, o), It(o, e), Pt(o, e);
|
|
2505
|
+
}, pe = (e, t, n = {}) => (o) => {
|
|
2506
|
+
const { libraryOptions: r, target: i } = o ?? {}, s = Tt({ ...r ?? {}, target: i, io: t, processors: n });
|
|
2507
|
+
return T(e, s), It(s, e), Pt(s, e);
|
|
2508
|
+
}, Hr = {
|
|
2509
2509
|
guid: "uuid",
|
|
2510
2510
|
url: "uri",
|
|
2511
2511
|
datetime: "date-time",
|
|
2512
2512
|
json_string: "json-string",
|
|
2513
2513
|
regex: ""
|
|
2514
2514
|
// do not set
|
|
2515
|
-
},
|
|
2515
|
+
}, Qr = (e, t, n, o) => {
|
|
2516
2516
|
const r = n;
|
|
2517
2517
|
r.type = "string";
|
|
2518
|
-
const { minimum: i, maximum: s, format:
|
|
2519
|
-
if (typeof i == "number" && (r.minLength = i), typeof s == "number" && (r.maxLength = s),
|
|
2520
|
-
const p = [...
|
|
2518
|
+
const { minimum: i, maximum: s, format: a, patterns: c, contentEncoding: u } = e._zod.bag;
|
|
2519
|
+
if (typeof i == "number" && (r.minLength = i), typeof s == "number" && (r.maxLength = s), a && (r.format = Hr[a] ?? a, r.format === "" && delete r.format, a === "time" && delete r.format), u && (r.contentEncoding = u), c && c.size > 0) {
|
|
2520
|
+
const p = [...c];
|
|
2521
2521
|
p.length === 1 ? r.pattern = p[0].source : p.length > 1 && (r.allOf = [
|
|
2522
2522
|
...p.map((f) => ({
|
|
2523
2523
|
...t.target === "draft-07" || t.target === "draft-04" || t.target === "openapi-3.0" ? { type: "string" } : {},
|
|
@@ -2525,20 +2525,20 @@ const Vr = (e, t = {}) => (n) => {
|
|
|
2525
2525
|
}))
|
|
2526
2526
|
]);
|
|
2527
2527
|
}
|
|
2528
|
-
},
|
|
2529
|
-
const r = n, { minimum: i, maximum: s, format:
|
|
2530
|
-
typeof
|
|
2531
|
-
},
|
|
2528
|
+
}, ei = (e, t, n, o) => {
|
|
2529
|
+
const r = n, { minimum: i, maximum: s, format: a, multipleOf: c, exclusiveMaximum: u, exclusiveMinimum: p } = e._zod.bag;
|
|
2530
|
+
typeof a == "string" && a.includes("int") ? r.type = "integer" : r.type = "number", typeof p == "number" && (t.target === "draft-04" || t.target === "openapi-3.0" ? (r.minimum = p, r.exclusiveMinimum = !0) : r.exclusiveMinimum = p), typeof i == "number" && (r.minimum = i, typeof p == "number" && t.target !== "draft-04" && (p >= i ? delete r.minimum : delete r.exclusiveMinimum)), typeof u == "number" && (t.target === "draft-04" || t.target === "openapi-3.0" ? (r.maximum = u, r.exclusiveMaximum = !0) : r.exclusiveMaximum = u), typeof s == "number" && (r.maximum = s, typeof u == "number" && t.target !== "draft-04" && (u <= s ? delete r.maximum : delete r.exclusiveMaximum)), typeof c == "number" && (r.multipleOf = c);
|
|
2531
|
+
}, ti = (e, t, n, o) => {
|
|
2532
2532
|
n.type = "boolean";
|
|
2533
|
-
},
|
|
2533
|
+
}, ni = (e, t, n, o) => {
|
|
2534
2534
|
t.target === "openapi-3.0" ? (n.type = "string", n.nullable = !0, n.enum = [null]) : n.type = "null";
|
|
2535
|
-
},
|
|
2535
|
+
}, oi = (e, t, n, o) => {
|
|
2536
2536
|
n.not = {};
|
|
2537
|
-
},
|
|
2538
|
-
},
|
|
2539
|
-
const r = e._zod.def, i =
|
|
2537
|
+
}, ri = (e, t, n, o) => {
|
|
2538
|
+
}, ii = (e, t, n, o) => {
|
|
2539
|
+
const r = e._zod.def, i = at(r.entries);
|
|
2540
2540
|
i.every((s) => typeof s == "number") && (n.type = "number"), i.every((s) => typeof s == "string") && (n.type = "string"), n.enum = i;
|
|
2541
|
-
},
|
|
2541
|
+
}, si = (e, t, n, o) => {
|
|
2542
2542
|
const r = e._zod.def, i = [];
|
|
2543
2543
|
for (const s of r.values)
|
|
2544
2544
|
if (s === void 0) {
|
|
@@ -2555,83 +2555,83 @@ const Vr = (e, t = {}) => (n) => {
|
|
|
2555
2555
|
n.type = s === null ? "null" : typeof s, t.target === "draft-04" || t.target === "openapi-3.0" ? n.enum = [s] : n.const = s;
|
|
2556
2556
|
} else
|
|
2557
2557
|
i.every((s) => typeof s == "number") && (n.type = "number"), i.every((s) => typeof s == "string") && (n.type = "string"), i.every((s) => typeof s == "boolean") && (n.type = "boolean"), i.every((s) => s === null) && (n.type = "null"), n.enum = i;
|
|
2558
|
-
},
|
|
2558
|
+
}, ai = (e, t, n, o) => {
|
|
2559
2559
|
if (t.unrepresentable === "throw")
|
|
2560
2560
|
throw new Error("Custom types cannot be represented in JSON Schema");
|
|
2561
|
-
},
|
|
2561
|
+
}, ci = (e, t, n, o) => {
|
|
2562
2562
|
if (t.unrepresentable === "throw")
|
|
2563
2563
|
throw new Error("Transforms cannot be represented in JSON Schema");
|
|
2564
|
-
},
|
|
2565
|
-
const r = n, i = e._zod.def, { minimum: s, maximum:
|
|
2566
|
-
typeof s == "number" && (r.minItems = s), typeof
|
|
2567
|
-
},
|
|
2564
|
+
}, ui = (e, t, n, o) => {
|
|
2565
|
+
const r = n, i = e._zod.def, { minimum: s, maximum: a } = e._zod.bag;
|
|
2566
|
+
typeof s == "number" && (r.minItems = s), typeof a == "number" && (r.maxItems = a), r.type = "array", r.items = T(i.element, t, { ...o, path: [...o.path, "items"] });
|
|
2567
|
+
}, li = (e, t, n, o) => {
|
|
2568
2568
|
var u;
|
|
2569
2569
|
const r = n, i = e._zod.def;
|
|
2570
2570
|
r.type = "object", r.properties = {};
|
|
2571
2571
|
const s = i.shape;
|
|
2572
2572
|
for (const p in s)
|
|
2573
|
-
r.properties[p] =
|
|
2573
|
+
r.properties[p] = T(s[p], t, {
|
|
2574
2574
|
...o,
|
|
2575
2575
|
path: [...o.path, "properties", p]
|
|
2576
2576
|
});
|
|
2577
|
-
const
|
|
2577
|
+
const a = new Set(Object.keys(s)), c = new Set([...a].filter((p) => {
|
|
2578
2578
|
const f = i.shape[p]._zod;
|
|
2579
2579
|
return t.io === "input" ? f.optin === void 0 : f.optout === void 0;
|
|
2580
2580
|
}));
|
|
2581
|
-
|
|
2581
|
+
c.size > 0 && (r.required = Array.from(c)), ((u = i.catchall) == null ? void 0 : u._zod.def.type) === "never" ? r.additionalProperties = !1 : i.catchall ? i.catchall && (r.additionalProperties = T(i.catchall, t, {
|
|
2582
2582
|
...o,
|
|
2583
2583
|
path: [...o.path, "additionalProperties"]
|
|
2584
2584
|
})) : t.io === "output" && (r.additionalProperties = !1);
|
|
2585
|
-
},
|
|
2586
|
-
const r = e._zod.def, i = r.inclusive === !1, s = r.options.map((
|
|
2585
|
+
}, pi = (e, t, n, o) => {
|
|
2586
|
+
const r = e._zod.def, i = r.inclusive === !1, s = r.options.map((a, c) => T(a, t, {
|
|
2587
2587
|
...o,
|
|
2588
|
-
path: [...o.path, i ? "oneOf" : "anyOf",
|
|
2588
|
+
path: [...o.path, i ? "oneOf" : "anyOf", c]
|
|
2589
2589
|
}));
|
|
2590
2590
|
i ? n.oneOf = s : n.anyOf = s;
|
|
2591
|
-
},
|
|
2592
|
-
const r = e._zod.def, i =
|
|
2591
|
+
}, fi = (e, t, n, o) => {
|
|
2592
|
+
const r = e._zod.def, i = T(r.left, t, {
|
|
2593
2593
|
...o,
|
|
2594
2594
|
path: [...o.path, "allOf", 0]
|
|
2595
|
-
}), s =
|
|
2595
|
+
}), s = T(r.right, t, {
|
|
2596
2596
|
...o,
|
|
2597
2597
|
path: [...o.path, "allOf", 1]
|
|
2598
|
-
}),
|
|
2599
|
-
...
|
|
2600
|
-
...
|
|
2598
|
+
}), a = (u) => "allOf" in u && Object.keys(u).length === 1, c = [
|
|
2599
|
+
...a(i) ? i.allOf : [i],
|
|
2600
|
+
...a(s) ? s.allOf : [s]
|
|
2601
2601
|
];
|
|
2602
|
-
n.allOf =
|
|
2603
|
-
},
|
|
2602
|
+
n.allOf = c;
|
|
2603
|
+
}, di = (e, t, n, o) => {
|
|
2604
2604
|
const r = n, i = e._zod.def;
|
|
2605
2605
|
r.type = "array";
|
|
2606
|
-
const s = t.target === "draft-2020-12" ? "prefixItems" : "items",
|
|
2606
|
+
const s = t.target === "draft-2020-12" ? "prefixItems" : "items", a = t.target === "draft-2020-12" || t.target === "openapi-3.0" ? "items" : "additionalItems", c = i.items.map((_, b) => T(_, t, {
|
|
2607
2607
|
...o,
|
|
2608
|
-
path: [...o.path, s,
|
|
2609
|
-
})), u = i.rest ?
|
|
2608
|
+
path: [...o.path, s, b]
|
|
2609
|
+
})), u = i.rest ? T(i.rest, t, {
|
|
2610
2610
|
...o,
|
|
2611
|
-
path: [...o.path,
|
|
2611
|
+
path: [...o.path, a, ...t.target === "openapi-3.0" ? [i.items.length] : []]
|
|
2612
2612
|
}) : null;
|
|
2613
|
-
t.target === "draft-2020-12" ? (r.prefixItems =
|
|
2614
|
-
anyOf:
|
|
2615
|
-
}, u && r.items.anyOf.push(u), r.minItems =
|
|
2613
|
+
t.target === "draft-2020-12" ? (r.prefixItems = c, u && (r.items = u)) : t.target === "openapi-3.0" ? (r.items = {
|
|
2614
|
+
anyOf: c
|
|
2615
|
+
}, u && r.items.anyOf.push(u), r.minItems = c.length, u || (r.maxItems = c.length)) : (r.items = c, u && (r.additionalItems = u));
|
|
2616
2616
|
const { minimum: p, maximum: f } = e._zod.bag;
|
|
2617
2617
|
typeof p == "number" && (r.minItems = p), typeof f == "number" && (r.maxItems = f);
|
|
2618
|
-
},
|
|
2618
|
+
}, hi = (e, t, n, o) => {
|
|
2619
2619
|
const r = n, i = e._zod.def;
|
|
2620
2620
|
r.type = "object";
|
|
2621
|
-
const s = i.keyType,
|
|
2622
|
-
if (i.mode === "loose" &&
|
|
2623
|
-
const p =
|
|
2621
|
+
const s = i.keyType, a = s._zod.bag, c = a == null ? void 0 : a.patterns;
|
|
2622
|
+
if (i.mode === "loose" && c && c.size > 0) {
|
|
2623
|
+
const p = T(i.valueType, t, {
|
|
2624
2624
|
...o,
|
|
2625
2625
|
path: [...o.path, "patternProperties", "*"]
|
|
2626
2626
|
});
|
|
2627
2627
|
r.patternProperties = {};
|
|
2628
|
-
for (const f of
|
|
2628
|
+
for (const f of c)
|
|
2629
2629
|
r.patternProperties[f.source] = p;
|
|
2630
2630
|
} else
|
|
2631
|
-
(t.target === "draft-07" || t.target === "draft-2020-12") && (r.propertyNames =
|
|
2631
|
+
(t.target === "draft-07" || t.target === "draft-2020-12") && (r.propertyNames = T(i.keyType, t, {
|
|
2632
2632
|
...o,
|
|
2633
2633
|
path: [...o.path, "propertyNames"]
|
|
2634
|
-
})), r.additionalProperties =
|
|
2634
|
+
})), r.additionalProperties = T(i.valueType, t, {
|
|
2635
2635
|
...o,
|
|
2636
2636
|
path: [...o.path, "additionalProperties"]
|
|
2637
2637
|
});
|
|
@@ -2640,27 +2640,27 @@ const Vr = (e, t = {}) => (n) => {
|
|
|
2640
2640
|
const p = [...u].filter((f) => typeof f == "string" || typeof f == "number");
|
|
2641
2641
|
p.length > 0 && (r.required = p);
|
|
2642
2642
|
}
|
|
2643
|
-
},
|
|
2644
|
-
const r = e._zod.def, i =
|
|
2643
|
+
}, mi = (e, t, n, o) => {
|
|
2644
|
+
const r = e._zod.def, i = T(r.innerType, t, o), s = t.seen.get(e);
|
|
2645
2645
|
t.target === "openapi-3.0" ? (s.ref = r.innerType, n.nullable = !0) : n.anyOf = [i, { type: "null" }];
|
|
2646
|
-
},
|
|
2646
|
+
}, gi = (e, t, n, o) => {
|
|
2647
2647
|
const r = e._zod.def;
|
|
2648
|
-
|
|
2648
|
+
T(r.innerType, t, o);
|
|
2649
2649
|
const i = t.seen.get(e);
|
|
2650
2650
|
i.ref = r.innerType;
|
|
2651
|
-
},
|
|
2651
|
+
}, _i = (e, t, n, o) => {
|
|
2652
2652
|
const r = e._zod.def;
|
|
2653
|
-
|
|
2653
|
+
T(r.innerType, t, o);
|
|
2654
2654
|
const i = t.seen.get(e);
|
|
2655
2655
|
i.ref = r.innerType, n.default = JSON.parse(JSON.stringify(r.defaultValue));
|
|
2656
|
-
},
|
|
2656
|
+
}, vi = (e, t, n, o) => {
|
|
2657
2657
|
const r = e._zod.def;
|
|
2658
|
-
|
|
2658
|
+
T(r.innerType, t, o);
|
|
2659
2659
|
const i = t.seen.get(e);
|
|
2660
2660
|
i.ref = r.innerType, t.io === "input" && (n._prefault = JSON.parse(JSON.stringify(r.defaultValue)));
|
|
2661
|
-
},
|
|
2661
|
+
}, yi = (e, t, n, o) => {
|
|
2662
2662
|
const r = e._zod.def;
|
|
2663
|
-
|
|
2663
|
+
T(r.innerType, t, o);
|
|
2664
2664
|
const i = t.seen.get(e);
|
|
2665
2665
|
i.ref = r.innerType;
|
|
2666
2666
|
let s;
|
|
@@ -2670,69 +2670,69 @@ const Vr = (e, t = {}) => (n) => {
|
|
|
2670
2670
|
throw new Error("Dynamic catch values are not supported in JSON Schema");
|
|
2671
2671
|
}
|
|
2672
2672
|
n.default = s;
|
|
2673
|
-
},
|
|
2673
|
+
}, bi = (e, t, n, o) => {
|
|
2674
2674
|
const r = e._zod.def, i = t.io === "input" ? r.in._zod.def.type === "transform" ? r.out : r.in : r.out;
|
|
2675
|
-
|
|
2675
|
+
T(i, t, o);
|
|
2676
2676
|
const s = t.seen.get(e);
|
|
2677
2677
|
s.ref = i;
|
|
2678
|
-
},
|
|
2678
|
+
}, wi = (e, t, n, o) => {
|
|
2679
2679
|
const r = e._zod.def;
|
|
2680
|
-
|
|
2680
|
+
T(r.innerType, t, o);
|
|
2681
2681
|
const i = t.seen.get(e);
|
|
2682
2682
|
i.ref = r.innerType, n.readOnly = !0;
|
|
2683
|
-
},
|
|
2683
|
+
}, Et = (e, t, n, o) => {
|
|
2684
2684
|
const r = e._zod.def;
|
|
2685
|
-
|
|
2685
|
+
T(r.innerType, t, o);
|
|
2686
2686
|
const i = t.seen.get(e);
|
|
2687
2687
|
i.ref = r.innerType;
|
|
2688
|
-
},
|
|
2688
|
+
}, zi = (e, t, n, o) => {
|
|
2689
2689
|
const r = e._zod.innerType;
|
|
2690
|
-
|
|
2690
|
+
T(r, t, o);
|
|
2691
2691
|
const i = t.seen.get(e);
|
|
2692
2692
|
i.ref = r;
|
|
2693
|
-
},
|
|
2694
|
-
|
|
2693
|
+
}, ki = /* @__PURE__ */ l("ZodISODateTime", (e, t) => {
|
|
2694
|
+
_o.init(e, t), I.init(e, t);
|
|
2695
2695
|
});
|
|
2696
|
-
function
|
|
2697
|
-
return /* @__PURE__ */
|
|
2696
|
+
function Si(e) {
|
|
2697
|
+
return /* @__PURE__ */ $r(ki, e);
|
|
2698
2698
|
}
|
|
2699
|
-
const
|
|
2700
|
-
|
|
2699
|
+
const Zi = /* @__PURE__ */ l("ZodISODate", (e, t) => {
|
|
2700
|
+
vo.init(e, t), I.init(e, t);
|
|
2701
2701
|
});
|
|
2702
|
-
function
|
|
2703
|
-
return /* @__PURE__ */
|
|
2702
|
+
function $i(e) {
|
|
2703
|
+
return /* @__PURE__ */ Or(Zi, e);
|
|
2704
2704
|
}
|
|
2705
|
-
const
|
|
2706
|
-
|
|
2705
|
+
const Oi = /* @__PURE__ */ l("ZodISOTime", (e, t) => {
|
|
2706
|
+
yo.init(e, t), I.init(e, t);
|
|
2707
2707
|
});
|
|
2708
|
-
function
|
|
2709
|
-
return /* @__PURE__ */
|
|
2708
|
+
function Ti(e) {
|
|
2709
|
+
return /* @__PURE__ */ Tr(Oi, e);
|
|
2710
2710
|
}
|
|
2711
|
-
const
|
|
2712
|
-
|
|
2711
|
+
const Ii = /* @__PURE__ */ l("ZodISODuration", (e, t) => {
|
|
2712
|
+
bo.init(e, t), I.init(e, t);
|
|
2713
2713
|
});
|
|
2714
|
-
function
|
|
2715
|
-
return /* @__PURE__ */
|
|
2714
|
+
function Pi(e) {
|
|
2715
|
+
return /* @__PURE__ */ Ir(Ii, e);
|
|
2716
2716
|
}
|
|
2717
|
-
const
|
|
2718
|
-
|
|
2717
|
+
const Ei = (e, t) => {
|
|
2718
|
+
pt.init(e, t), e.name = "ZodError", Object.defineProperties(e, {
|
|
2719
2719
|
format: {
|
|
2720
|
-
value: (n) =>
|
|
2720
|
+
value: (n) => cn(e, n)
|
|
2721
2721
|
// enumerable: false,
|
|
2722
2722
|
},
|
|
2723
2723
|
flatten: {
|
|
2724
|
-
value: (n) =>
|
|
2724
|
+
value: (n) => an(e, n)
|
|
2725
2725
|
// enumerable: false,
|
|
2726
2726
|
},
|
|
2727
2727
|
addIssue: {
|
|
2728
2728
|
value: (n) => {
|
|
2729
|
-
e.issues.push(n), e.message = JSON.stringify(e.issues,
|
|
2729
|
+
e.issues.push(n), e.message = JSON.stringify(e.issues, we, 2);
|
|
2730
2730
|
}
|
|
2731
2731
|
// enumerable: false,
|
|
2732
2732
|
},
|
|
2733
2733
|
addIssues: {
|
|
2734
2734
|
value: (n) => {
|
|
2735
|
-
e.issues.push(...n), e.message = JSON.stringify(e.issues,
|
|
2735
|
+
e.issues.push(...n), e.message = JSON.stringify(e.issues, we, 2);
|
|
2736
2736
|
}
|
|
2737
2737
|
// enumerable: false,
|
|
2738
2738
|
},
|
|
@@ -2743,21 +2743,21 @@ const Si = (e, t) => {
|
|
|
2743
2743
|
// enumerable: false,
|
|
2744
2744
|
}
|
|
2745
2745
|
});
|
|
2746
|
-
},
|
|
2746
|
+
}, R = l("ZodError", Ei, {
|
|
2747
2747
|
Parent: Error
|
|
2748
|
-
}),
|
|
2748
|
+
}), Ni = /* @__PURE__ */ Ie(R), Ci = /* @__PURE__ */ Pe(R), Ai = /* @__PURE__ */ de(R), ji = /* @__PURE__ */ he(R), xi = /* @__PURE__ */ pn(R), Ri = /* @__PURE__ */ fn(R), Di = /* @__PURE__ */ dn(R), Fi = /* @__PURE__ */ hn(R), Li = /* @__PURE__ */ mn(R), Ui = /* @__PURE__ */ gn(R), Mi = /* @__PURE__ */ _n(R), Ji = /* @__PURE__ */ vn(R), $ = /* @__PURE__ */ l("ZodType", (e, t) => (S.init(e, t), Object.assign(e["~standard"], {
|
|
2749
2749
|
jsonSchema: {
|
|
2750
|
-
input:
|
|
2751
|
-
output:
|
|
2750
|
+
input: pe(e, "input"),
|
|
2751
|
+
output: pe(e, "output")
|
|
2752
2752
|
}
|
|
2753
|
-
}), e.toJSONSchema =
|
|
2753
|
+
}), e.toJSONSchema = Xr(e, {}), e.def = t, e.type = t.type, Object.defineProperty(e, "_def", { value: t }), e.check = (...n) => e.clone(V(t, {
|
|
2754
2754
|
checks: [
|
|
2755
2755
|
...t.checks ?? [],
|
|
2756
2756
|
...n.map((o) => typeof o == "function" ? { _zod: { check: o, def: { check: "custom" }, onattach: [] } } : o)
|
|
2757
2757
|
]
|
|
2758
2758
|
}), {
|
|
2759
2759
|
parent: !0
|
|
2760
|
-
}), e.with = e.check, e.clone = (n, o) =>
|
|
2760
|
+
}), e.with = e.check, e.clone = (n, o) => U(e, n, o), e.brand = () => e, e.register = ((n, o) => (n.add(e, o), e)), e.parse = (n, o) => Ni(e, n, o, { callee: e.parse }), e.safeParse = (n, o) => Ai(e, n, o), e.parseAsync = async (n, o) => Ci(e, n, o, { callee: e.parseAsync }), e.safeParseAsync = async (n, o) => ji(e, n, o), e.spa = e.safeParseAsync, e.encode = (n, o) => xi(e, n, o), e.decode = (n, o) => Ri(e, n, o), e.encodeAsync = async (n, o) => Di(e, n, o), e.decodeAsync = async (n, o) => Fi(e, n, o), e.safeEncode = (n, o) => Li(e, n, o), e.safeDecode = (n, o) => Ui(e, n, o), e.safeEncodeAsync = async (n, o) => Mi(e, n, o), e.safeDecodeAsync = async (n, o) => Ji(e, n, o), e.refine = (n, o) => e.check(Fs(n, o)), e.superRefine = (n) => e.check(Ls(n)), e.overwrite = (n) => e.check(/* @__PURE__ */ H(n)), e.optional = () => et(e), e.exactOptional = () => Ss(e), e.nullable = () => tt(e), e.nullish = () => et(tt(e)), e.nonoptional = (n) => Ps(e, n), e.array = () => Z(e), e.or = (n) => x([e, n]), e.and = (n) => ys(e, n), e.transform = (n) => Ze(e, Rt(n)), e.default = (n) => Os(e, n), e.prefault = (n) => Is(e, n), e.catch = (n) => Ns(e, n), e.pipe = (n) => Ze(e, n), e.readonly = () => js(e), e.describe = (n) => {
|
|
2761
2761
|
const o = e.clone();
|
|
2762
2762
|
return ee.add(o, { description: n }), o;
|
|
2763
2763
|
}, Object.defineProperty(e, "description", {
|
|
@@ -2771,170 +2771,179 @@ const Si = (e, t) => {
|
|
|
2771
2771
|
return ee.get(e);
|
|
2772
2772
|
const o = e.clone();
|
|
2773
2773
|
return ee.add(o, n[0]), o;
|
|
2774
|
-
}, e.isOptional = () => e.safeParse(void 0).success, e.isNullable = () => e.safeParse(null).success, e.apply = (n) => n(e), e)),
|
|
2775
|
-
|
|
2774
|
+
}, e.isOptional = () => e.safeParse(void 0).success, e.isNullable = () => e.safeParse(null).success, e.apply = (n) => n(e), e)), Nt = /* @__PURE__ */ l("_ZodString", (e, t) => {
|
|
2775
|
+
Ee.init(e, t), $.init(e, t), e._zod.processJSONSchema = (o, r, i) => Qr(e, o, r);
|
|
2776
2776
|
const n = e._zod.bag;
|
|
2777
|
-
e.format = n.format ?? null, e.minLength = n.minimum ?? null, e.maxLength = n.maximum ?? null, e.regex = (...o) => e.check(/* @__PURE__ */
|
|
2778
|
-
}),
|
|
2779
|
-
|
|
2777
|
+
e.format = n.format ?? null, e.minLength = n.minimum ?? null, e.maxLength = n.maximum ?? null, e.regex = (...o) => e.check(/* @__PURE__ */ xr(...o)), e.includes = (...o) => e.check(/* @__PURE__ */ Fr(...o)), e.startsWith = (...o) => e.check(/* @__PURE__ */ Lr(...o)), e.endsWith = (...o) => e.check(/* @__PURE__ */ Ur(...o)), e.min = (...o) => e.check(/* @__PURE__ */ le(...o)), e.max = (...o) => e.check(/* @__PURE__ */ $t(...o)), e.length = (...o) => e.check(/* @__PURE__ */ Ot(...o)), e.nonempty = (...o) => e.check(/* @__PURE__ */ le(1, ...o)), e.lowercase = (o) => e.check(/* @__PURE__ */ Rr(o)), e.uppercase = (o) => e.check(/* @__PURE__ */ Dr(o)), e.trim = () => e.check(/* @__PURE__ */ Jr()), e.normalize = (...o) => e.check(/* @__PURE__ */ Mr(...o)), e.toLowerCase = () => e.check(/* @__PURE__ */ Vr()), e.toUpperCase = () => e.check(/* @__PURE__ */ Br()), e.slugify = () => e.check(/* @__PURE__ */ Wr());
|
|
2778
|
+
}), Vi = /* @__PURE__ */ l("ZodString", (e, t) => {
|
|
2779
|
+
Ee.init(e, t), Nt.init(e, t), e.email = (n) => e.check(/* @__PURE__ */ ir(Bi, n)), e.url = (n) => e.check(/* @__PURE__ */ lr(Wi, n)), e.jwt = (n) => e.check(/* @__PURE__ */ Zr(as, n)), e.emoji = (n) => e.check(/* @__PURE__ */ pr(Gi, n)), e.guid = (n) => e.check(/* @__PURE__ */ Ge(Xe, n)), e.uuid = (n) => e.check(/* @__PURE__ */ sr(ce, n)), e.uuidv4 = (n) => e.check(/* @__PURE__ */ ar(ce, n)), e.uuidv6 = (n) => e.check(/* @__PURE__ */ cr(ce, n)), e.uuidv7 = (n) => e.check(/* @__PURE__ */ ur(ce, n)), e.nanoid = (n) => e.check(/* @__PURE__ */ fr(Ki, n)), e.guid = (n) => e.check(/* @__PURE__ */ Ge(Xe, n)), e.cuid = (n) => e.check(/* @__PURE__ */ dr(qi, n)), e.cuid2 = (n) => e.check(/* @__PURE__ */ hr(Yi, n)), e.ulid = (n) => e.check(/* @__PURE__ */ mr(Xi, n)), e.base64 = (n) => e.check(/* @__PURE__ */ zr(rs, n)), e.base64url = (n) => e.check(/* @__PURE__ */ kr(is, n)), e.xid = (n) => e.check(/* @__PURE__ */ gr(Hi, n)), e.ksuid = (n) => e.check(/* @__PURE__ */ _r(Qi, n)), e.ipv4 = (n) => e.check(/* @__PURE__ */ vr(es, n)), e.ipv6 = (n) => e.check(/* @__PURE__ */ yr(ts, n)), e.cidrv4 = (n) => e.check(/* @__PURE__ */ br(ns, n)), e.cidrv6 = (n) => e.check(/* @__PURE__ */ wr(os, n)), e.e164 = (n) => e.check(/* @__PURE__ */ Sr(ss, n)), e.datetime = (n) => e.check(Si(n)), e.date = (n) => e.check($i(n)), e.time = (n) => e.check(Ti(n)), e.duration = (n) => e.check(Pi(n));
|
|
2780
2780
|
});
|
|
2781
2781
|
function h(e) {
|
|
2782
|
-
return /* @__PURE__ */
|
|
2783
|
-
}
|
|
2784
|
-
const
|
|
2785
|
-
|
|
2786
|
-
}),
|
|
2787
|
-
|
|
2788
|
-
}),
|
|
2789
|
-
|
|
2782
|
+
return /* @__PURE__ */ rr(Vi, e);
|
|
2783
|
+
}
|
|
2784
|
+
const I = /* @__PURE__ */ l("ZodStringFormat", (e, t) => {
|
|
2785
|
+
O.init(e, t), Nt.init(e, t);
|
|
2786
|
+
}), Bi = /* @__PURE__ */ l("ZodEmail", (e, t) => {
|
|
2787
|
+
ao.init(e, t), I.init(e, t);
|
|
2788
|
+
}), Xe = /* @__PURE__ */ l("ZodGUID", (e, t) => {
|
|
2789
|
+
io.init(e, t), I.init(e, t);
|
|
2790
2790
|
}), ce = /* @__PURE__ */ l("ZodUUID", (e, t) => {
|
|
2791
|
-
|
|
2792
|
-
}),
|
|
2793
|
-
|
|
2794
|
-
}),
|
|
2795
|
-
|
|
2796
|
-
}),
|
|
2797
|
-
|
|
2798
|
-
}),
|
|
2799
|
-
|
|
2800
|
-
}),
|
|
2801
|
-
|
|
2802
|
-
}),
|
|
2803
|
-
|
|
2804
|
-
}),
|
|
2805
|
-
|
|
2806
|
-
}),
|
|
2807
|
-
|
|
2808
|
-
}),
|
|
2809
|
-
|
|
2810
|
-
}),
|
|
2811
|
-
|
|
2812
|
-
}),
|
|
2813
|
-
|
|
2814
|
-
}),
|
|
2815
|
-
|
|
2816
|
-
}),
|
|
2817
|
-
|
|
2818
|
-
}),
|
|
2819
|
-
|
|
2820
|
-
}),
|
|
2821
|
-
|
|
2822
|
-
}),
|
|
2823
|
-
|
|
2824
|
-
}),
|
|
2825
|
-
|
|
2791
|
+
so.init(e, t), I.init(e, t);
|
|
2792
|
+
}), Wi = /* @__PURE__ */ l("ZodURL", (e, t) => {
|
|
2793
|
+
co.init(e, t), I.init(e, t);
|
|
2794
|
+
}), Gi = /* @__PURE__ */ l("ZodEmoji", (e, t) => {
|
|
2795
|
+
uo.init(e, t), I.init(e, t);
|
|
2796
|
+
}), Ki = /* @__PURE__ */ l("ZodNanoID", (e, t) => {
|
|
2797
|
+
lo.init(e, t), I.init(e, t);
|
|
2798
|
+
}), qi = /* @__PURE__ */ l("ZodCUID", (e, t) => {
|
|
2799
|
+
po.init(e, t), I.init(e, t);
|
|
2800
|
+
}), Yi = /* @__PURE__ */ l("ZodCUID2", (e, t) => {
|
|
2801
|
+
fo.init(e, t), I.init(e, t);
|
|
2802
|
+
}), Xi = /* @__PURE__ */ l("ZodULID", (e, t) => {
|
|
2803
|
+
ho.init(e, t), I.init(e, t);
|
|
2804
|
+
}), Hi = /* @__PURE__ */ l("ZodXID", (e, t) => {
|
|
2805
|
+
mo.init(e, t), I.init(e, t);
|
|
2806
|
+
}), Qi = /* @__PURE__ */ l("ZodKSUID", (e, t) => {
|
|
2807
|
+
go.init(e, t), I.init(e, t);
|
|
2808
|
+
}), es = /* @__PURE__ */ l("ZodIPv4", (e, t) => {
|
|
2809
|
+
wo.init(e, t), I.init(e, t);
|
|
2810
|
+
}), ts = /* @__PURE__ */ l("ZodIPv6", (e, t) => {
|
|
2811
|
+
zo.init(e, t), I.init(e, t);
|
|
2812
|
+
}), ns = /* @__PURE__ */ l("ZodCIDRv4", (e, t) => {
|
|
2813
|
+
ko.init(e, t), I.init(e, t);
|
|
2814
|
+
}), os = /* @__PURE__ */ l("ZodCIDRv6", (e, t) => {
|
|
2815
|
+
So.init(e, t), I.init(e, t);
|
|
2816
|
+
}), rs = /* @__PURE__ */ l("ZodBase64", (e, t) => {
|
|
2817
|
+
Zo.init(e, t), I.init(e, t);
|
|
2818
|
+
}), is = /* @__PURE__ */ l("ZodBase64URL", (e, t) => {
|
|
2819
|
+
Oo.init(e, t), I.init(e, t);
|
|
2820
|
+
}), ss = /* @__PURE__ */ l("ZodE164", (e, t) => {
|
|
2821
|
+
To.init(e, t), I.init(e, t);
|
|
2822
|
+
}), as = /* @__PURE__ */ l("ZodJWT", (e, t) => {
|
|
2823
|
+
Po.init(e, t), I.init(e, t);
|
|
2824
|
+
}), Ct = /* @__PURE__ */ l("ZodNumber", (e, t) => {
|
|
2825
|
+
wt.init(e, t), $.init(e, t), e._zod.processJSONSchema = (o, r, i) => ei(e, o, r), e.gt = (o, r) => e.check(/* @__PURE__ */ qe(o, r)), e.gte = (o, r) => e.check(/* @__PURE__ */ be(o, r)), e.min = (o, r) => e.check(/* @__PURE__ */ be(o, r)), e.lt = (o, r) => e.check(/* @__PURE__ */ Ke(o, r)), e.lte = (o, r) => e.check(/* @__PURE__ */ ye(o, r)), e.max = (o, r) => e.check(/* @__PURE__ */ ye(o, r)), e.int = (o) => e.check(He(o)), e.safe = (o) => e.check(He(o)), e.positive = (o) => e.check(/* @__PURE__ */ qe(0, o)), e.nonnegative = (o) => e.check(/* @__PURE__ */ be(0, o)), e.negative = (o) => e.check(/* @__PURE__ */ Ke(0, o)), e.nonpositive = (o) => e.check(/* @__PURE__ */ ye(0, o)), e.multipleOf = (o, r) => e.check(/* @__PURE__ */ Ye(o, r)), e.step = (o, r) => e.check(/* @__PURE__ */ Ye(o, r)), e.finite = () => e;
|
|
2826
2826
|
const n = e._zod.bag;
|
|
2827
2827
|
e.minValue = Math.max(n.minimum ?? Number.NEGATIVE_INFINITY, n.exclusiveMinimum ?? Number.NEGATIVE_INFINITY) ?? null, e.maxValue = Math.min(n.maximum ?? Number.POSITIVE_INFINITY, n.exclusiveMaximum ?? Number.POSITIVE_INFINITY) ?? null, e.isInt = (n.format ?? "").includes("int") || Number.isSafeInteger(n.multipleOf ?? 0.5), e.isFinite = !0, e.format = n.format ?? null;
|
|
2828
2828
|
});
|
|
2829
2829
|
function d(e) {
|
|
2830
|
-
return /* @__PURE__ */
|
|
2830
|
+
return /* @__PURE__ */ Pr(Ct, e);
|
|
2831
2831
|
}
|
|
2832
|
-
const
|
|
2833
|
-
|
|
2832
|
+
const cs = /* @__PURE__ */ l("ZodNumberFormat", (e, t) => {
|
|
2833
|
+
Eo.init(e, t), Ct.init(e, t);
|
|
2834
2834
|
});
|
|
2835
|
-
function
|
|
2836
|
-
return /* @__PURE__ */
|
|
2835
|
+
function He(e) {
|
|
2836
|
+
return /* @__PURE__ */ Er(cs, e);
|
|
2837
2837
|
}
|
|
2838
|
-
const
|
|
2839
|
-
|
|
2838
|
+
const us = /* @__PURE__ */ l("ZodBoolean", (e, t) => {
|
|
2839
|
+
No.init(e, t), $.init(e, t), e._zod.processJSONSchema = (n, o, r) => ti(e, n, o);
|
|
2840
2840
|
});
|
|
2841
|
-
function
|
|
2842
|
-
return /* @__PURE__ */
|
|
2841
|
+
function y(e) {
|
|
2842
|
+
return /* @__PURE__ */ Nr(us, e);
|
|
2843
2843
|
}
|
|
2844
|
-
const
|
|
2845
|
-
|
|
2844
|
+
const ls = /* @__PURE__ */ l("ZodNull", (e, t) => {
|
|
2845
|
+
Co.init(e, t), $.init(e, t), e._zod.processJSONSchema = (n, o, r) => ni(e, n, o);
|
|
2846
2846
|
});
|
|
2847
|
-
function
|
|
2848
|
-
return /* @__PURE__ */
|
|
2847
|
+
function ps(e) {
|
|
2848
|
+
return /* @__PURE__ */ Cr(ls, e);
|
|
2849
2849
|
}
|
|
2850
|
-
const
|
|
2851
|
-
|
|
2850
|
+
const fs = /* @__PURE__ */ l("ZodUnknown", (e, t) => {
|
|
2851
|
+
Ao.init(e, t), $.init(e, t), e._zod.processJSONSchema = (n, o, r) => ri();
|
|
2852
2852
|
});
|
|
2853
|
-
function
|
|
2854
|
-
return /* @__PURE__ */
|
|
2853
|
+
function ke() {
|
|
2854
|
+
return /* @__PURE__ */ Ar(fs);
|
|
2855
2855
|
}
|
|
2856
|
-
const
|
|
2857
|
-
|
|
2856
|
+
const ds = /* @__PURE__ */ l("ZodNever", (e, t) => {
|
|
2857
|
+
jo.init(e, t), $.init(e, t), e._zod.processJSONSchema = (n, o, r) => oi(e, n, o);
|
|
2858
2858
|
});
|
|
2859
|
-
function
|
|
2860
|
-
return /* @__PURE__ */
|
|
2859
|
+
function hs(e) {
|
|
2860
|
+
return /* @__PURE__ */ jr(ds, e);
|
|
2861
2861
|
}
|
|
2862
|
-
const
|
|
2863
|
-
|
|
2862
|
+
const ms = /* @__PURE__ */ l("ZodArray", (e, t) => {
|
|
2863
|
+
xo.init(e, t), $.init(e, t), e._zod.processJSONSchema = (n, o, r) => ui(e, n, o, r), e.element = t.element, e.min = (n, o) => e.check(/* @__PURE__ */ le(n, o)), e.nonempty = (n) => e.check(/* @__PURE__ */ le(1, n)), e.max = (n, o) => e.check(/* @__PURE__ */ $t(n, o)), e.length = (n, o) => e.check(/* @__PURE__ */ Ot(n, o)), e.unwrap = () => e.element;
|
|
2864
2864
|
});
|
|
2865
|
-
function
|
|
2866
|
-
return /* @__PURE__ */
|
|
2865
|
+
function Z(e, t) {
|
|
2866
|
+
return /* @__PURE__ */ Gr(ms, e, t);
|
|
2867
2867
|
}
|
|
2868
|
-
const
|
|
2869
|
-
|
|
2868
|
+
const gs = /* @__PURE__ */ l("ZodObject", (e, t) => {
|
|
2869
|
+
Do.init(e, t), $.init(e, t), e._zod.processJSONSchema = (n, o, r) => li(e, n, o, r), w(e, "shape", () => t.shape), e.keyof = () => v(Object.keys(e._zod.def.shape)), e.catchall = (n) => e.clone({ ...e._zod.def, catchall: n }), e.passthrough = () => e.clone({ ...e._zod.def, catchall: ke() }), e.loose = () => e.clone({ ...e._zod.def, catchall: ke() }), e.strict = () => e.clone({ ...e._zod.def, catchall: hs() }), e.strip = () => e.clone({ ...e._zod.def, catchall: void 0 }), e.extend = (n) => tn(e, n), e.safeExtend = (n) => nn(e, n), e.merge = (n) => on(e, n), e.pick = (n) => Qt(e, n), e.omit = (n) => en(e, n), e.partial = (...n) => rn(Dt, e, n[0]), e.required = (...n) => sn(Ft, e, n[0]);
|
|
2870
2870
|
});
|
|
2871
|
-
function
|
|
2871
|
+
function g(e, t) {
|
|
2872
2872
|
const n = {
|
|
2873
2873
|
type: "object",
|
|
2874
2874
|
shape: e ?? {},
|
|
2875
2875
|
...m(t)
|
|
2876
2876
|
};
|
|
2877
|
-
return new
|
|
2877
|
+
return new gs(n);
|
|
2878
2878
|
}
|
|
2879
|
-
const
|
|
2880
|
-
|
|
2879
|
+
const At = /* @__PURE__ */ l("ZodUnion", (e, t) => {
|
|
2880
|
+
St.init(e, t), $.init(e, t), e._zod.processJSONSchema = (n, o, r) => pi(e, n, o, r), e.options = t.options;
|
|
2881
2881
|
});
|
|
2882
|
-
function
|
|
2883
|
-
return new
|
|
2882
|
+
function x(e, t) {
|
|
2883
|
+
return new At({
|
|
2884
2884
|
type: "union",
|
|
2885
2885
|
options: e,
|
|
2886
2886
|
...m(t)
|
|
2887
2887
|
});
|
|
2888
2888
|
}
|
|
2889
|
-
const
|
|
2890
|
-
|
|
2889
|
+
const _s = /* @__PURE__ */ l("ZodDiscriminatedUnion", (e, t) => {
|
|
2890
|
+
At.init(e, t), Fo.init(e, t);
|
|
2891
2891
|
});
|
|
2892
|
-
function
|
|
2893
|
-
return new
|
|
2892
|
+
function Ne(e, t, n) {
|
|
2893
|
+
return new _s({
|
|
2894
2894
|
type: "union",
|
|
2895
2895
|
options: t,
|
|
2896
2896
|
discriminator: e,
|
|
2897
2897
|
...m(n)
|
|
2898
2898
|
});
|
|
2899
2899
|
}
|
|
2900
|
-
const
|
|
2901
|
-
|
|
2900
|
+
const vs = /* @__PURE__ */ l("ZodIntersection", (e, t) => {
|
|
2901
|
+
Lo.init(e, t), $.init(e, t), e._zod.processJSONSchema = (n, o, r) => fi(e, n, o, r);
|
|
2902
2902
|
});
|
|
2903
|
-
function
|
|
2904
|
-
return new
|
|
2903
|
+
function ys(e, t) {
|
|
2904
|
+
return new vs({
|
|
2905
2905
|
type: "intersection",
|
|
2906
2906
|
left: e,
|
|
2907
2907
|
right: t
|
|
2908
2908
|
});
|
|
2909
2909
|
}
|
|
2910
|
-
const
|
|
2911
|
-
|
|
2910
|
+
const bs = /* @__PURE__ */ l("ZodTuple", (e, t) => {
|
|
2911
|
+
Uo.init(e, t), $.init(e, t), e._zod.processJSONSchema = (n, o, r) => di(e, n, o, r), e.rest = (n) => e.clone({
|
|
2912
2912
|
...e._zod.def,
|
|
2913
2913
|
rest: n
|
|
2914
2914
|
});
|
|
2915
2915
|
});
|
|
2916
|
-
function
|
|
2916
|
+
function L(e, t, n) {
|
|
2917
2917
|
const o = t instanceof S, r = o ? n : t, i = o ? t : null;
|
|
2918
|
-
return new
|
|
2918
|
+
return new bs({
|
|
2919
2919
|
type: "tuple",
|
|
2920
2920
|
items: e,
|
|
2921
2921
|
rest: i,
|
|
2922
2922
|
...m(r)
|
|
2923
2923
|
});
|
|
2924
2924
|
}
|
|
2925
|
-
const
|
|
2926
|
-
|
|
2925
|
+
const jt = /* @__PURE__ */ l("ZodRecord", (e, t) => {
|
|
2926
|
+
Mo.init(e, t), $.init(e, t), e._zod.processJSONSchema = (n, o, r) => hi(e, n, o, r), e.keyType = t.keyType, e.valueType = t.valueType;
|
|
2927
2927
|
});
|
|
2928
|
-
function
|
|
2929
|
-
return new
|
|
2928
|
+
function xt(e, t, n) {
|
|
2929
|
+
return new jt({
|
|
2930
2930
|
type: "record",
|
|
2931
2931
|
keyType: e,
|
|
2932
2932
|
valueType: t,
|
|
2933
2933
|
...m(n)
|
|
2934
2934
|
});
|
|
2935
2935
|
}
|
|
2936
|
-
|
|
2937
|
-
|
|
2936
|
+
function Qe(e, t, n) {
|
|
2937
|
+
const o = U(e);
|
|
2938
|
+
return o._zod.values = void 0, new jt({
|
|
2939
|
+
type: "record",
|
|
2940
|
+
keyType: o,
|
|
2941
|
+
valueType: t,
|
|
2942
|
+
...m(n)
|
|
2943
|
+
});
|
|
2944
|
+
}
|
|
2945
|
+
const Se = /* @__PURE__ */ l("ZodEnum", (e, t) => {
|
|
2946
|
+
Jo.init(e, t), $.init(e, t), e._zod.processJSONSchema = (o, r, i) => ii(e, o, r), e.enum = t.entries, e.options = Object.values(t.entries);
|
|
2938
2947
|
const n = new Set(Object.keys(t.entries));
|
|
2939
2948
|
e.extract = (o, r) => {
|
|
2940
2949
|
const i = {};
|
|
@@ -2943,7 +2952,7 @@ const ke = /* @__PURE__ */ l("ZodEnum", (e, t) => {
|
|
|
2943
2952
|
i[s] = t.entries[s];
|
|
2944
2953
|
else
|
|
2945
2954
|
throw new Error(`Key ${s} not found in enum`);
|
|
2946
|
-
return new
|
|
2955
|
+
return new Se({
|
|
2947
2956
|
...t,
|
|
2948
2957
|
checks: [],
|
|
2949
2958
|
...m(r),
|
|
@@ -2956,7 +2965,7 @@ const ke = /* @__PURE__ */ l("ZodEnum", (e, t) => {
|
|
|
2956
2965
|
delete i[s];
|
|
2957
2966
|
else
|
|
2958
2967
|
throw new Error(`Key ${s} not found in enum`);
|
|
2959
|
-
return new
|
|
2968
|
+
return new Se({
|
|
2960
2969
|
...t,
|
|
2961
2970
|
checks: [],
|
|
2962
2971
|
...m(r),
|
|
@@ -2964,16 +2973,16 @@ const ke = /* @__PURE__ */ l("ZodEnum", (e, t) => {
|
|
|
2964
2973
|
});
|
|
2965
2974
|
};
|
|
2966
2975
|
});
|
|
2967
|
-
function
|
|
2976
|
+
function v(e, t) {
|
|
2968
2977
|
const n = Array.isArray(e) ? Object.fromEntries(e.map((o) => [o, o])) : e;
|
|
2969
|
-
return new
|
|
2978
|
+
return new Se({
|
|
2970
2979
|
type: "enum",
|
|
2971
2980
|
entries: n,
|
|
2972
2981
|
...m(t)
|
|
2973
2982
|
});
|
|
2974
2983
|
}
|
|
2975
|
-
const
|
|
2976
|
-
|
|
2984
|
+
const ws = /* @__PURE__ */ l("ZodLiteral", (e, t) => {
|
|
2985
|
+
Vo.init(e, t), $.init(e, t), e._zod.processJSONSchema = (n, o, r) => si(e, n, o), e.values = new Set(t.values), Object.defineProperty(e, "value", {
|
|
2977
2986
|
get() {
|
|
2978
2987
|
if (t.values.length > 1)
|
|
2979
2988
|
throw new Error("This schema contains multiple valid literal values. Use `.values` instead.");
|
|
@@ -2982,353 +2991,384 @@ const ms = /* @__PURE__ */ l("ZodLiteral", (e, t) => {
|
|
|
2982
2991
|
});
|
|
2983
2992
|
});
|
|
2984
2993
|
function E(e, t) {
|
|
2985
|
-
return new
|
|
2994
|
+
return new ws({
|
|
2986
2995
|
type: "literal",
|
|
2987
2996
|
values: Array.isArray(e) ? e : [e],
|
|
2988
2997
|
...m(t)
|
|
2989
2998
|
});
|
|
2990
2999
|
}
|
|
2991
|
-
const
|
|
2992
|
-
|
|
3000
|
+
const zs = /* @__PURE__ */ l("ZodTransform", (e, t) => {
|
|
3001
|
+
Bo.init(e, t), $.init(e, t), e._zod.processJSONSchema = (n, o, r) => ci(e, n), e._zod.parse = (n, o) => {
|
|
2993
3002
|
if (o.direction === "backward")
|
|
2994
|
-
throw new
|
|
3003
|
+
throw new it(e.constructor.name);
|
|
2995
3004
|
n.addIssue = (i) => {
|
|
2996
3005
|
if (typeof i == "string")
|
|
2997
|
-
n.issues.push(
|
|
3006
|
+
n.issues.push(oe(i, n.value, t));
|
|
2998
3007
|
else {
|
|
2999
3008
|
const s = i;
|
|
3000
|
-
s.fatal && (s.continue = !1), s.code ?? (s.code = "custom"), s.input ?? (s.input = n.value), s.inst ?? (s.inst = e), n.issues.push(
|
|
3009
|
+
s.fatal && (s.continue = !1), s.code ?? (s.code = "custom"), s.input ?? (s.input = n.value), s.inst ?? (s.inst = e), n.issues.push(oe(s));
|
|
3001
3010
|
}
|
|
3002
3011
|
};
|
|
3003
3012
|
const r = t.transform(n.value, n);
|
|
3004
3013
|
return r instanceof Promise ? r.then((i) => (n.value = i, n)) : (n.value = r, n);
|
|
3005
3014
|
};
|
|
3006
3015
|
});
|
|
3007
|
-
function
|
|
3008
|
-
return new
|
|
3016
|
+
function Rt(e) {
|
|
3017
|
+
return new zs({
|
|
3009
3018
|
type: "transform",
|
|
3010
3019
|
transform: e
|
|
3011
3020
|
});
|
|
3012
3021
|
}
|
|
3013
|
-
const
|
|
3014
|
-
|
|
3022
|
+
const Dt = /* @__PURE__ */ l("ZodOptional", (e, t) => {
|
|
3023
|
+
Zt.init(e, t), $.init(e, t), e._zod.processJSONSchema = (n, o, r) => Et(e, n, o, r), e.unwrap = () => e._zod.def.innerType;
|
|
3015
3024
|
});
|
|
3016
|
-
function
|
|
3017
|
-
return new
|
|
3025
|
+
function et(e) {
|
|
3026
|
+
return new Dt({
|
|
3018
3027
|
type: "optional",
|
|
3019
3028
|
innerType: e
|
|
3020
3029
|
});
|
|
3021
3030
|
}
|
|
3022
|
-
const
|
|
3023
|
-
|
|
3031
|
+
const ks = /* @__PURE__ */ l("ZodExactOptional", (e, t) => {
|
|
3032
|
+
Wo.init(e, t), $.init(e, t), e._zod.processJSONSchema = (n, o, r) => Et(e, n, o, r), e.unwrap = () => e._zod.def.innerType;
|
|
3024
3033
|
});
|
|
3025
|
-
function
|
|
3026
|
-
return new
|
|
3034
|
+
function Ss(e) {
|
|
3035
|
+
return new ks({
|
|
3027
3036
|
type: "optional",
|
|
3028
3037
|
innerType: e
|
|
3029
3038
|
});
|
|
3030
3039
|
}
|
|
3031
|
-
const
|
|
3032
|
-
|
|
3040
|
+
const Zs = /* @__PURE__ */ l("ZodNullable", (e, t) => {
|
|
3041
|
+
Go.init(e, t), $.init(e, t), e._zod.processJSONSchema = (n, o, r) => mi(e, n, o, r), e.unwrap = () => e._zod.def.innerType;
|
|
3033
3042
|
});
|
|
3034
|
-
function
|
|
3035
|
-
return new
|
|
3043
|
+
function tt(e) {
|
|
3044
|
+
return new Zs({
|
|
3036
3045
|
type: "nullable",
|
|
3037
3046
|
innerType: e
|
|
3038
3047
|
});
|
|
3039
3048
|
}
|
|
3040
|
-
const
|
|
3041
|
-
|
|
3049
|
+
const $s = /* @__PURE__ */ l("ZodDefault", (e, t) => {
|
|
3050
|
+
Ko.init(e, t), $.init(e, t), e._zod.processJSONSchema = (n, o, r) => _i(e, n, o, r), e.unwrap = () => e._zod.def.innerType, e.removeDefault = e.unwrap;
|
|
3042
3051
|
});
|
|
3043
|
-
function
|
|
3044
|
-
return new
|
|
3052
|
+
function Os(e, t) {
|
|
3053
|
+
return new $s({
|
|
3045
3054
|
type: "default",
|
|
3046
3055
|
innerType: e,
|
|
3047
3056
|
get defaultValue() {
|
|
3048
|
-
return typeof t == "function" ? t() :
|
|
3057
|
+
return typeof t == "function" ? t() : ut(t);
|
|
3049
3058
|
}
|
|
3050
3059
|
});
|
|
3051
3060
|
}
|
|
3052
|
-
const
|
|
3053
|
-
|
|
3061
|
+
const Ts = /* @__PURE__ */ l("ZodPrefault", (e, t) => {
|
|
3062
|
+
qo.init(e, t), $.init(e, t), e._zod.processJSONSchema = (n, o, r) => vi(e, n, o, r), e.unwrap = () => e._zod.def.innerType;
|
|
3054
3063
|
});
|
|
3055
|
-
function
|
|
3056
|
-
return new
|
|
3064
|
+
function Is(e, t) {
|
|
3065
|
+
return new Ts({
|
|
3057
3066
|
type: "prefault",
|
|
3058
3067
|
innerType: e,
|
|
3059
3068
|
get defaultValue() {
|
|
3060
|
-
return typeof t == "function" ? t() :
|
|
3069
|
+
return typeof t == "function" ? t() : ut(t);
|
|
3061
3070
|
}
|
|
3062
3071
|
});
|
|
3063
3072
|
}
|
|
3064
|
-
const
|
|
3065
|
-
|
|
3073
|
+
const Ft = /* @__PURE__ */ l("ZodNonOptional", (e, t) => {
|
|
3074
|
+
Yo.init(e, t), $.init(e, t), e._zod.processJSONSchema = (n, o, r) => gi(e, n, o, r), e.unwrap = () => e._zod.def.innerType;
|
|
3066
3075
|
});
|
|
3067
|
-
function
|
|
3068
|
-
return new
|
|
3076
|
+
function Ps(e, t) {
|
|
3077
|
+
return new Ft({
|
|
3069
3078
|
type: "nonoptional",
|
|
3070
3079
|
innerType: e,
|
|
3071
3080
|
...m(t)
|
|
3072
3081
|
});
|
|
3073
3082
|
}
|
|
3074
|
-
const
|
|
3075
|
-
|
|
3083
|
+
const Es = /* @__PURE__ */ l("ZodCatch", (e, t) => {
|
|
3084
|
+
Xo.init(e, t), $.init(e, t), e._zod.processJSONSchema = (n, o, r) => yi(e, n, o, r), e.unwrap = () => e._zod.def.innerType, e.removeCatch = e.unwrap;
|
|
3076
3085
|
});
|
|
3077
|
-
function
|
|
3078
|
-
return new
|
|
3086
|
+
function Ns(e, t) {
|
|
3087
|
+
return new Es({
|
|
3079
3088
|
type: "catch",
|
|
3080
3089
|
innerType: e,
|
|
3081
3090
|
catchValue: typeof t == "function" ? t : () => t
|
|
3082
3091
|
});
|
|
3083
3092
|
}
|
|
3084
|
-
const
|
|
3085
|
-
|
|
3093
|
+
const Cs = /* @__PURE__ */ l("ZodPipe", (e, t) => {
|
|
3094
|
+
Ho.init(e, t), $.init(e, t), e._zod.processJSONSchema = (n, o, r) => bi(e, n, o, r), e.in = t.in, e.out = t.out;
|
|
3086
3095
|
});
|
|
3087
|
-
function
|
|
3088
|
-
return new
|
|
3096
|
+
function Ze(e, t) {
|
|
3097
|
+
return new Cs({
|
|
3089
3098
|
type: "pipe",
|
|
3090
3099
|
in: e,
|
|
3091
3100
|
out: t
|
|
3092
3101
|
// ...util.normalizeParams(params),
|
|
3093
3102
|
});
|
|
3094
3103
|
}
|
|
3095
|
-
const
|
|
3096
|
-
|
|
3104
|
+
const As = /* @__PURE__ */ l("ZodReadonly", (e, t) => {
|
|
3105
|
+
Qo.init(e, t), $.init(e, t), e._zod.processJSONSchema = (n, o, r) => wi(e, n, o, r), e.unwrap = () => e._zod.def.innerType;
|
|
3097
3106
|
});
|
|
3098
|
-
function
|
|
3099
|
-
return new
|
|
3107
|
+
function js(e) {
|
|
3108
|
+
return new As({
|
|
3100
3109
|
type: "readonly",
|
|
3101
3110
|
innerType: e
|
|
3102
3111
|
});
|
|
3103
3112
|
}
|
|
3104
|
-
const
|
|
3105
|
-
|
|
3113
|
+
const xs = /* @__PURE__ */ l("ZodLazy", (e, t) => {
|
|
3114
|
+
er.init(e, t), $.init(e, t), e._zod.processJSONSchema = (n, o, r) => zi(e, n, o, r), e.unwrap = () => e._zod.def.getter();
|
|
3106
3115
|
});
|
|
3107
|
-
function
|
|
3108
|
-
return new
|
|
3116
|
+
function Rs(e) {
|
|
3117
|
+
return new xs({
|
|
3109
3118
|
type: "lazy",
|
|
3110
3119
|
getter: e
|
|
3111
3120
|
});
|
|
3112
3121
|
}
|
|
3113
|
-
const
|
|
3114
|
-
|
|
3122
|
+
const Ds = /* @__PURE__ */ l("ZodCustom", (e, t) => {
|
|
3123
|
+
tr.init(e, t), $.init(e, t), e._zod.processJSONSchema = (n, o, r) => ai(e, n);
|
|
3115
3124
|
});
|
|
3116
|
-
function
|
|
3117
|
-
return /* @__PURE__ */
|
|
3125
|
+
function Fs(e, t = {}) {
|
|
3126
|
+
return /* @__PURE__ */ Kr(Ds, e, t);
|
|
3118
3127
|
}
|
|
3119
|
-
function
|
|
3120
|
-
return /* @__PURE__ */
|
|
3128
|
+
function Ls(e) {
|
|
3129
|
+
return /* @__PURE__ */ qr(e);
|
|
3121
3130
|
}
|
|
3122
|
-
function
|
|
3123
|
-
return
|
|
3131
|
+
function Us(e, t) {
|
|
3132
|
+
return Ze(Rt(e), t);
|
|
3124
3133
|
}
|
|
3125
|
-
const
|
|
3134
|
+
const ge = v([
|
|
3126
3135
|
"Point",
|
|
3127
3136
|
"MultiPoint",
|
|
3128
3137
|
"LineString",
|
|
3129
3138
|
"MultiLineString",
|
|
3130
3139
|
"Polygon",
|
|
3131
3140
|
"MultiPolygon"
|
|
3132
|
-
]),
|
|
3141
|
+
]), Lt = Z(ke()), Ce = (e) => x([h(), Lt]).default(e), K = () => x([h(), Lt]).optional(), Ms = g({
|
|
3133
3142
|
latitude: d().min(-90).max(90),
|
|
3134
3143
|
longitude: d().min(-180).max(180),
|
|
3135
3144
|
zoom: d().min(0).max(24),
|
|
3136
3145
|
pitch: d().min(0).max(85).default(0),
|
|
3137
|
-
bearing: d().min(-180).max(180).default(0)
|
|
3138
|
-
|
|
3139
|
-
|
|
3146
|
+
bearing: d().min(-180).max(180).default(0),
|
|
3147
|
+
minZoom: d().min(0).max(24).optional(),
|
|
3148
|
+
maxZoom: d().min(0).max(24).optional()
|
|
3149
|
+
}).superRefine((e, t) => {
|
|
3150
|
+
e.minZoom != null && e.maxZoom != null && e.minZoom > e.maxZoom && t.addIssue({
|
|
3151
|
+
code: "custom",
|
|
3152
|
+
path: ["minZoom"],
|
|
3153
|
+
message: "minZoom must be less than or equal to maxZoom"
|
|
3154
|
+
}), e.minZoom != null && e.zoom < e.minZoom && t.addIssue({
|
|
3155
|
+
code: "custom",
|
|
3156
|
+
path: ["zoom"],
|
|
3157
|
+
message: `Zoom must be at least ${e.minZoom} (minZoom)`
|
|
3158
|
+
}), e.maxZoom != null && e.zoom > e.maxZoom && t.addIssue({
|
|
3159
|
+
code: "custom",
|
|
3160
|
+
path: ["zoom"],
|
|
3161
|
+
message: `Zoom must be at most ${e.maxZoom} (maxZoom)`
|
|
3162
|
+
});
|
|
3163
|
+
}), Js = g({
|
|
3164
|
+
type: v(["query_param", "header"]),
|
|
3140
3165
|
name: h().min(1),
|
|
3141
3166
|
value: h().min(1)
|
|
3142
|
-
}),
|
|
3167
|
+
}), Vs = g({
|
|
3143
3168
|
id: h().min(1),
|
|
3144
3169
|
url: h().url(),
|
|
3145
3170
|
label: h().optional(),
|
|
3146
3171
|
tileMatrixSetId: h().optional().default("WebMercatorQuad"),
|
|
3147
|
-
type:
|
|
3148
|
-
auth:
|
|
3149
|
-
proxy:
|
|
3150
|
-
}),
|
|
3151
|
-
"fill-color":
|
|
3172
|
+
type: v(["features", "imagery"]).optional(),
|
|
3173
|
+
auth: Js.optional(),
|
|
3174
|
+
proxy: y().optional()
|
|
3175
|
+
}), Bs = g({
|
|
3176
|
+
"fill-color": Ce("#000000"),
|
|
3152
3177
|
"fill-opacity": d().min(0).max(1).default(1),
|
|
3153
|
-
"fill-outline-color":
|
|
3154
|
-
"fill-antialias":
|
|
3155
|
-
"fill-translate":
|
|
3156
|
-
"fill-translate-anchor":
|
|
3178
|
+
"fill-outline-color": K(),
|
|
3179
|
+
"fill-antialias": y().optional(),
|
|
3180
|
+
"fill-translate": L([d(), d()]).optional(),
|
|
3181
|
+
"fill-translate-anchor": v(["map", "viewport"]).optional(),
|
|
3157
3182
|
"fill-pattern": h().optional()
|
|
3158
|
-
}),
|
|
3159
|
-
"line-color":
|
|
3183
|
+
}), Ws = g({
|
|
3184
|
+
"line-color": Ce("#000000"),
|
|
3160
3185
|
"line-width": d().min(0).default(1),
|
|
3161
3186
|
"line-opacity": d().min(0).max(1).default(1),
|
|
3162
|
-
"line-dasharray":
|
|
3163
|
-
"line-translate":
|
|
3164
|
-
"line-translate-anchor":
|
|
3187
|
+
"line-dasharray": Z(d()).optional(),
|
|
3188
|
+
"line-translate": L([d(), d()]).optional(),
|
|
3189
|
+
"line-translate-anchor": v(["map", "viewport"]).optional(),
|
|
3165
3190
|
"line-gap-width": d().min(0).optional(),
|
|
3166
3191
|
"line-offset": d().optional(),
|
|
3167
3192
|
"line-blur": d().min(0).optional(),
|
|
3168
3193
|
"line-pattern": h().optional(),
|
|
3169
3194
|
"line-gradient": h().optional()
|
|
3170
|
-
}),
|
|
3171
|
-
"circle-color":
|
|
3195
|
+
}), Gs = g({
|
|
3196
|
+
"circle-color": Ce("#000000"),
|
|
3172
3197
|
"circle-radius": d().min(0).default(5),
|
|
3173
3198
|
"circle-opacity": d().min(0).max(1).default(1),
|
|
3174
|
-
"circle-stroke-color":
|
|
3199
|
+
"circle-stroke-color": K(),
|
|
3175
3200
|
"circle-stroke-width": d().min(0).optional(),
|
|
3176
3201
|
"circle-blur": d().min(0).optional(),
|
|
3177
|
-
"circle-translate":
|
|
3178
|
-
"circle-translate-anchor":
|
|
3179
|
-
"circle-pitch-scale":
|
|
3180
|
-
"circle-pitch-alignment":
|
|
3202
|
+
"circle-translate": L([d(), d()]).optional(),
|
|
3203
|
+
"circle-translate-anchor": v(["map", "viewport"]).optional(),
|
|
3204
|
+
"circle-pitch-scale": v(["map", "viewport"]).optional(),
|
|
3205
|
+
"circle-pitch-alignment": v(["map", "viewport"]).optional(),
|
|
3181
3206
|
"circle-stroke-opacity": d().min(0).max(1).optional()
|
|
3182
|
-
}),
|
|
3207
|
+
}), Ks = g({
|
|
3183
3208
|
"icon-opacity": d().min(0).max(1).optional(),
|
|
3184
|
-
"icon-color":
|
|
3185
|
-
"icon-halo-color":
|
|
3209
|
+
"icon-color": K(),
|
|
3210
|
+
"icon-halo-color": K(),
|
|
3186
3211
|
"icon-halo-width": d().min(0).optional(),
|
|
3187
3212
|
"icon-halo-blur": d().min(0).optional(),
|
|
3188
|
-
"icon-translate":
|
|
3189
|
-
"icon-translate-anchor":
|
|
3213
|
+
"icon-translate": L([d(), d()]).optional(),
|
|
3214
|
+
"icon-translate-anchor": v(["map", "viewport"]).optional(),
|
|
3190
3215
|
"text-opacity": d().min(0).max(1).optional(),
|
|
3191
|
-
"text-color":
|
|
3192
|
-
"text-halo-color":
|
|
3216
|
+
"text-color": K(),
|
|
3217
|
+
"text-halo-color": K(),
|
|
3193
3218
|
"text-halo-width": d().min(0).optional(),
|
|
3194
3219
|
"text-halo-blur": d().min(0).optional(),
|
|
3195
|
-
"text-translate":
|
|
3196
|
-
"text-translate-anchor":
|
|
3197
|
-
}),
|
|
3220
|
+
"text-translate": L([d(), d()]).optional(),
|
|
3221
|
+
"text-translate-anchor": v(["map", "viewport"]).optional()
|
|
3222
|
+
}), qs = g({
|
|
3198
3223
|
"fill-sort-key": d().optional(),
|
|
3199
|
-
visibility:
|
|
3200
|
-
}),
|
|
3201
|
-
"line-cap":
|
|
3202
|
-
"line-join":
|
|
3224
|
+
visibility: v(["visible", "none"]).optional()
|
|
3225
|
+
}), Ys = g({
|
|
3226
|
+
"line-cap": v(["butt", "round", "square"]).optional(),
|
|
3227
|
+
"line-join": v(["bevel", "round", "miter"]).optional(),
|
|
3203
3228
|
"line-miter-limit": d().optional(),
|
|
3204
3229
|
"line-round-limit": d().optional(),
|
|
3205
3230
|
"line-sort-key": d().optional(),
|
|
3206
|
-
visibility:
|
|
3207
|
-
}),
|
|
3231
|
+
visibility: v(["visible", "none"]).optional()
|
|
3232
|
+
}), Xs = g({
|
|
3208
3233
|
"circle-sort-key": d().optional(),
|
|
3209
|
-
visibility:
|
|
3210
|
-
}),
|
|
3211
|
-
"symbol-placement":
|
|
3234
|
+
visibility: v(["visible", "none"]).optional()
|
|
3235
|
+
}), Hs = g({
|
|
3236
|
+
"symbol-placement": v(["point", "line", "line-center"]).optional(),
|
|
3212
3237
|
"symbol-spacing": d().min(1).optional(),
|
|
3213
|
-
"symbol-avoid-edges":
|
|
3238
|
+
"symbol-avoid-edges": y().optional(),
|
|
3214
3239
|
"symbol-sort-key": d().optional(),
|
|
3215
|
-
"symbol-z-order":
|
|
3216
|
-
"icon-allow-overlap":
|
|
3217
|
-
"icon-ignore-placement":
|
|
3218
|
-
"icon-optional":
|
|
3219
|
-
"icon-rotation-alignment":
|
|
3240
|
+
"symbol-z-order": v(["auto", "viewport-y", "source"]).optional(),
|
|
3241
|
+
"icon-allow-overlap": y().optional(),
|
|
3242
|
+
"icon-ignore-placement": y().optional(),
|
|
3243
|
+
"icon-optional": y().optional(),
|
|
3244
|
+
"icon-rotation-alignment": v(["map", "viewport", "auto"]).optional(),
|
|
3220
3245
|
"icon-size": d().min(0).optional(),
|
|
3221
|
-
"icon-text-fit":
|
|
3222
|
-
"icon-text-fit-padding":
|
|
3246
|
+
"icon-text-fit": v(["none", "width", "height", "both"]).optional(),
|
|
3247
|
+
"icon-text-fit-padding": L([d(), d(), d(), d()]).optional(),
|
|
3223
3248
|
"icon-image": h().optional(),
|
|
3224
3249
|
"icon-rotate": d().optional(),
|
|
3225
3250
|
"icon-padding": d().min(0).optional(),
|
|
3226
|
-
"icon-keep-upright":
|
|
3227
|
-
"icon-offset":
|
|
3228
|
-
"icon-anchor":
|
|
3229
|
-
"icon-pitch-alignment":
|
|
3230
|
-
"text-pitch-alignment":
|
|
3231
|
-
"text-rotation-alignment":
|
|
3251
|
+
"icon-keep-upright": y().optional(),
|
|
3252
|
+
"icon-offset": L([d(), d()]).optional(),
|
|
3253
|
+
"icon-anchor": v(["center", "left", "right", "top", "bottom", "top-left", "top-right", "bottom-left", "bottom-right"]).optional(),
|
|
3254
|
+
"icon-pitch-alignment": v(["map", "viewport", "auto"]).optional(),
|
|
3255
|
+
"text-pitch-alignment": v(["map", "viewport", "auto"]).optional(),
|
|
3256
|
+
"text-rotation-alignment": v(["map", "viewport", "viewport-glyph", "auto"]).optional(),
|
|
3232
3257
|
"text-field": h().optional(),
|
|
3233
|
-
"text-font":
|
|
3258
|
+
"text-font": Z(h()).optional(),
|
|
3234
3259
|
"text-size": d().min(0).optional(),
|
|
3235
3260
|
"text-max-width": d().min(0).optional(),
|
|
3236
3261
|
"text-line-height": d().optional(),
|
|
3237
3262
|
"text-letter-spacing": d().optional(),
|
|
3238
|
-
"text-justify":
|
|
3239
|
-
"text-anchor":
|
|
3263
|
+
"text-justify": v(["auto", "left", "center", "right"]).optional(),
|
|
3264
|
+
"text-anchor": v(["center", "left", "right", "top", "bottom", "top-left", "top-right", "bottom-left", "bottom-right"]).optional(),
|
|
3240
3265
|
"text-max-angle": d().optional(),
|
|
3241
3266
|
"text-rotate": d().optional(),
|
|
3242
3267
|
"text-padding": d().min(0).optional(),
|
|
3243
|
-
"text-keep-upright":
|
|
3244
|
-
"text-transform":
|
|
3245
|
-
"text-offset":
|
|
3246
|
-
"text-allow-overlap":
|
|
3247
|
-
"text-ignore-placement":
|
|
3248
|
-
"text-optional":
|
|
3249
|
-
visibility:
|
|
3250
|
-
}),
|
|
3268
|
+
"text-keep-upright": y().optional(),
|
|
3269
|
+
"text-transform": v(["none", "uppercase", "lowercase"]).optional(),
|
|
3270
|
+
"text-offset": L([d(), d()]).optional(),
|
|
3271
|
+
"text-allow-overlap": y().optional(),
|
|
3272
|
+
"text-ignore-placement": y().optional(),
|
|
3273
|
+
"text-optional": y().optional(),
|
|
3274
|
+
visibility: v(["visible", "none"]).optional()
|
|
3275
|
+
}), Qs = g({
|
|
3251
3276
|
type: E("fill"),
|
|
3252
|
-
paint:
|
|
3253
|
-
layout:
|
|
3254
|
-
geometryFilter:
|
|
3255
|
-
}),
|
|
3277
|
+
paint: Bs,
|
|
3278
|
+
layout: qs.optional(),
|
|
3279
|
+
geometryFilter: Z(ge).optional()
|
|
3280
|
+
}), ea = g({
|
|
3256
3281
|
type: E("line"),
|
|
3257
|
-
paint:
|
|
3258
|
-
layout:
|
|
3259
|
-
geometryFilter:
|
|
3260
|
-
}),
|
|
3282
|
+
paint: Ws,
|
|
3283
|
+
layout: Ys.optional(),
|
|
3284
|
+
geometryFilter: Z(ge).optional()
|
|
3285
|
+
}), ta = g({
|
|
3261
3286
|
type: E("circle"),
|
|
3262
|
-
paint:
|
|
3263
|
-
layout:
|
|
3264
|
-
geometryFilter:
|
|
3265
|
-
}),
|
|
3287
|
+
paint: Gs,
|
|
3288
|
+
layout: Xs.optional(),
|
|
3289
|
+
geometryFilter: Z(ge).optional()
|
|
3290
|
+
}), na = g({
|
|
3266
3291
|
type: E("symbol"),
|
|
3267
|
-
paint:
|
|
3268
|
-
layout:
|
|
3269
|
-
geometryFilter:
|
|
3270
|
-
}),
|
|
3271
|
-
|
|
3272
|
-
|
|
3273
|
-
|
|
3274
|
-
|
|
3275
|
-
]),
|
|
3292
|
+
paint: Ks,
|
|
3293
|
+
layout: Hs.optional(),
|
|
3294
|
+
geometryFilter: Z(ge).optional()
|
|
3295
|
+
}), oa = Ne("type", [
|
|
3296
|
+
Qs,
|
|
3297
|
+
ea,
|
|
3298
|
+
ta,
|
|
3299
|
+
na
|
|
3300
|
+
]), ra = g({
|
|
3276
3301
|
label: h(),
|
|
3277
3302
|
color: h(),
|
|
3278
|
-
shape:
|
|
3279
|
-
}),
|
|
3280
|
-
entries:
|
|
3281
|
-
displayMode:
|
|
3282
|
-
showLabelsCollapsed:
|
|
3283
|
-
showColorBar:
|
|
3284
|
-
showDisclosureArrow:
|
|
3303
|
+
shape: v(["circle", "line", "square"]).optional()
|
|
3304
|
+
}), ia = g({
|
|
3305
|
+
entries: Z(ra).min(1),
|
|
3306
|
+
displayMode: v(["categorical", "gradient", "simple"]).optional(),
|
|
3307
|
+
showLabelsCollapsed: y().optional(),
|
|
3308
|
+
showColorBar: y().optional(),
|
|
3309
|
+
showDisclosureArrow: y().optional(),
|
|
3285
3310
|
gradientProperty: h().optional()
|
|
3286
|
-
}),
|
|
3311
|
+
}), _e = {
|
|
3287
3312
|
property: h().min(1),
|
|
3288
3313
|
label: h(),
|
|
3289
3314
|
placeholder: h().optional()
|
|
3290
|
-
},
|
|
3291
|
-
...
|
|
3315
|
+
}, sa = g({
|
|
3316
|
+
..._e,
|
|
3292
3317
|
type: E("text"),
|
|
3293
|
-
autocomplete:
|
|
3294
|
-
prefetch:
|
|
3295
|
-
options:
|
|
3296
|
-
zoomTo:
|
|
3297
|
-
}),
|
|
3298
|
-
...
|
|
3318
|
+
autocomplete: y().default(!1),
|
|
3319
|
+
prefetch: y().optional(),
|
|
3320
|
+
options: Z(h()).optional(),
|
|
3321
|
+
zoomTo: y().optional()
|
|
3322
|
+
}), aa = g({
|
|
3323
|
+
..._e,
|
|
3299
3324
|
type: E("number"),
|
|
3300
|
-
inputMode:
|
|
3301
|
-
operator:
|
|
3302
|
-
operatorLabelStyle:
|
|
3303
|
-
showRange:
|
|
3325
|
+
inputMode: v(["input", "slider"]).default("input"),
|
|
3326
|
+
operator: v(["eq", "gt", "lt", "gte", "lte", "between"]).default("eq"),
|
|
3327
|
+
operatorLabelStyle: v(["symbol", "word"]).optional(),
|
|
3328
|
+
showRange: y().optional(),
|
|
3304
3329
|
min: d().optional(),
|
|
3305
3330
|
max: d().optional(),
|
|
3306
3331
|
step: d().optional()
|
|
3307
|
-
}),
|
|
3308
|
-
...
|
|
3332
|
+
}), ca = g({
|
|
3333
|
+
..._e,
|
|
3309
3334
|
type: E("datetime"),
|
|
3310
|
-
range:
|
|
3311
|
-
}),
|
|
3312
|
-
...
|
|
3335
|
+
range: y().default(!1)
|
|
3336
|
+
}), ua = g({
|
|
3337
|
+
..._e,
|
|
3313
3338
|
type: E("select"),
|
|
3314
|
-
options:
|
|
3315
|
-
prefetch:
|
|
3316
|
-
zoomTo:
|
|
3317
|
-
}),
|
|
3318
|
-
|
|
3319
|
-
|
|
3320
|
-
|
|
3321
|
-
|
|
3322
|
-
]),
|
|
3323
|
-
fields:
|
|
3324
|
-
}),
|
|
3339
|
+
options: Z(h()).optional(),
|
|
3340
|
+
prefetch: y().optional(),
|
|
3341
|
+
zoomTo: y().optional()
|
|
3342
|
+
}), la = Ne("type", [
|
|
3343
|
+
sa,
|
|
3344
|
+
aa,
|
|
3345
|
+
ca,
|
|
3346
|
+
ua
|
|
3347
|
+
]), pa = g({
|
|
3348
|
+
fields: Z(la).min(1)
|
|
3349
|
+
}), fa = g({
|
|
3350
|
+
property: h().min(1),
|
|
3351
|
+
label: h().optional(),
|
|
3352
|
+
autocomplete: y().optional(),
|
|
3353
|
+
prefetch: y().optional()
|
|
3354
|
+
}), da = g({
|
|
3355
|
+
layerId: h().min(1),
|
|
3356
|
+
properties: Z(fa).min(1)
|
|
3357
|
+
}), ha = g({
|
|
3358
|
+
enabled: y().default(!0),
|
|
3359
|
+
placeholder: h().optional(),
|
|
3360
|
+
maxResultsPerLayer: d().int().min(1).max(50).default(10),
|
|
3361
|
+
debounceMs: d().int().min(0).default(250),
|
|
3362
|
+
minQueryLength: d().int().min(1).default(2),
|
|
3363
|
+
layers: Z(da).default([])
|
|
3364
|
+
}), ma = g({
|
|
3325
3365
|
label: h().optional(),
|
|
3326
|
-
visible:
|
|
3327
|
-
}),
|
|
3328
|
-
properties:
|
|
3329
|
-
bbox:
|
|
3366
|
+
visible: y().optional().default(!0)
|
|
3367
|
+
}), ga = xt(h(), ma), _a = g({
|
|
3368
|
+
properties: xt(h(), x([h(), d(), y(), Z(h())])).optional(),
|
|
3369
|
+
bbox: L([d(), d(), d(), d()]).optional(),
|
|
3330
3370
|
datetime: h().optional()
|
|
3331
|
-
}),
|
|
3371
|
+
}), va = v([
|
|
3332
3372
|
"=",
|
|
3333
3373
|
"<>",
|
|
3334
3374
|
">",
|
|
@@ -3345,100 +3385,107 @@ const me = y([
|
|
|
3345
3385
|
"s_intersects",
|
|
3346
3386
|
"s_within",
|
|
3347
3387
|
"s_dwithin"
|
|
3348
|
-
]),
|
|
3388
|
+
]), ya = g({
|
|
3349
3389
|
kind: E("static"),
|
|
3350
|
-
value:
|
|
3390
|
+
value: x([
|
|
3351
3391
|
h(),
|
|
3352
3392
|
d(),
|
|
3353
|
-
|
|
3354
|
-
|
|
3355
|
-
|
|
3356
|
-
|
|
3357
|
-
|
|
3393
|
+
y(),
|
|
3394
|
+
ps(),
|
|
3395
|
+
Z(h()),
|
|
3396
|
+
g({ lower: d(), upper: d() }),
|
|
3397
|
+
g({ start: h(), end: h() })
|
|
3358
3398
|
])
|
|
3359
|
-
}),
|
|
3399
|
+
}), ba = g({
|
|
3360
3400
|
kind: E("parameter"),
|
|
3361
3401
|
name: h().min(1),
|
|
3362
3402
|
label: h(),
|
|
3363
|
-
inputType:
|
|
3364
|
-
default:
|
|
3365
|
-
}),
|
|
3366
|
-
|
|
3367
|
-
|
|
3368
|
-
]),
|
|
3403
|
+
inputType: v(["text", "number", "date", "select"]),
|
|
3404
|
+
default: x([h(), d()]).optional()
|
|
3405
|
+
}), Ut = x([
|
|
3406
|
+
g({ kind: E("static"), value: d() }),
|
|
3407
|
+
g({ kind: E("parameter"), name: h().min(1), label: h(), default: d().optional() })
|
|
3408
|
+
]), Mt = g({
|
|
3369
3409
|
kind: E("relativeDate"),
|
|
3370
|
-
direction:
|
|
3371
|
-
offset:
|
|
3372
|
-
unit:
|
|
3373
|
-
}),
|
|
3374
|
-
|
|
3375
|
-
|
|
3376
|
-
|
|
3377
|
-
]),
|
|
3410
|
+
direction: v(["past", "future"]),
|
|
3411
|
+
offset: Ut,
|
|
3412
|
+
unit: v(["days", "months", "years"])
|
|
3413
|
+
}), nt = x([
|
|
3414
|
+
g({ kind: E("static"), value: h() }),
|
|
3415
|
+
Mt,
|
|
3416
|
+
g({ kind: E("parameter"), name: h(), label: h(), default: h().optional() })
|
|
3417
|
+
]), wa = g({
|
|
3378
3418
|
kind: E("dateRange"),
|
|
3379
|
-
start:
|
|
3380
|
-
end:
|
|
3381
|
-
}),
|
|
3419
|
+
start: nt,
|
|
3420
|
+
end: nt
|
|
3421
|
+
}), za = g({
|
|
3382
3422
|
kind: E("computedRange"),
|
|
3383
3423
|
baseParam: h().min(1),
|
|
3384
3424
|
baseLabel: h(),
|
|
3385
|
-
offsetType:
|
|
3386
|
-
offsetAmount:
|
|
3387
|
-
}),
|
|
3388
|
-
|
|
3389
|
-
|
|
3390
|
-
|
|
3391
|
-
|
|
3392
|
-
|
|
3393
|
-
]),
|
|
3425
|
+
offsetType: v(["percentage", "absolute"]),
|
|
3426
|
+
offsetAmount: Ut
|
|
3427
|
+
}), ka = Ne("kind", [
|
|
3428
|
+
ya,
|
|
3429
|
+
ba,
|
|
3430
|
+
Mt,
|
|
3431
|
+
wa,
|
|
3432
|
+
za
|
|
3433
|
+
]), Sa = ["meters", "kilometers", "miles", "feet"], Ae = v(Sa), Jt = g({
|
|
3394
3434
|
kind: E("parameter"),
|
|
3395
3435
|
name: h().min(1),
|
|
3396
3436
|
label: h(),
|
|
3397
3437
|
default: d().optional()
|
|
3398
|
-
}),
|
|
3399
|
-
|
|
3400
|
-
|
|
3401
|
-
|
|
3438
|
+
}), Za = g({
|
|
3439
|
+
kind: E("parameter"),
|
|
3440
|
+
name: h().min(1),
|
|
3441
|
+
label: h(),
|
|
3442
|
+
default: Ae.optional()
|
|
3443
|
+
}), $a = g({
|
|
3444
|
+
distance: x([d(), Jt]).optional(),
|
|
3445
|
+
units: Ae.optional()
|
|
3446
|
+
}), Oa = g({
|
|
3402
3447
|
id: h(),
|
|
3403
3448
|
property: h(),
|
|
3404
|
-
operator:
|
|
3405
|
-
value:
|
|
3406
|
-
spatial:
|
|
3407
|
-
}),
|
|
3449
|
+
operator: va,
|
|
3450
|
+
value: ka,
|
|
3451
|
+
spatial: $a.optional()
|
|
3452
|
+
}), Ta = g({
|
|
3408
3453
|
property: h(),
|
|
3409
|
-
direction:
|
|
3410
|
-
}),
|
|
3411
|
-
operator:
|
|
3454
|
+
direction: v(["asc", "desc"])
|
|
3455
|
+
}), Ia = g({
|
|
3456
|
+
operator: v(["s_intersects", "s_within", "s_dwithin"]),
|
|
3412
3457
|
geometryProperty: h(),
|
|
3413
|
-
distance: d().optional(),
|
|
3414
|
-
distanceUnits:
|
|
3415
|
-
}),
|
|
3416
|
-
() =>
|
|
3458
|
+
distance: x([d(), Jt]).optional(),
|
|
3459
|
+
distanceUnits: x([Ae, Za]).optional()
|
|
3460
|
+
}), Vt = Rs(
|
|
3461
|
+
() => g({
|
|
3417
3462
|
id: h(),
|
|
3418
|
-
combinator:
|
|
3419
|
-
rules:
|
|
3420
|
-
sortby:
|
|
3463
|
+
combinator: v(["and", "or"]),
|
|
3464
|
+
rules: Z(x([Oa, Vt])),
|
|
3465
|
+
sortby: Z(Ta).optional(),
|
|
3421
3466
|
limit: d().min(1).optional(),
|
|
3422
|
-
spatialConstraint:
|
|
3467
|
+
spatialConstraint: Ia.optional()
|
|
3423
3468
|
})
|
|
3424
|
-
),
|
|
3469
|
+
), Pa = Vt, Ea = {
|
|
3425
3470
|
id: h().min(1),
|
|
3426
3471
|
sourceId: h().min(1),
|
|
3427
3472
|
collection: h().min(1),
|
|
3428
3473
|
label: h(),
|
|
3429
|
-
visible:
|
|
3430
|
-
dataMode:
|
|
3474
|
+
visible: y().default(!0),
|
|
3475
|
+
dataMode: v(["vector-tiles", "geojson"]),
|
|
3431
3476
|
minZoom: d().min(0).max(24).optional(),
|
|
3432
3477
|
maxZoom: d().min(0).max(24).optional(),
|
|
3433
|
-
|
|
3434
|
-
|
|
3435
|
-
|
|
3436
|
-
|
|
3437
|
-
|
|
3438
|
-
|
|
3439
|
-
|
|
3440
|
-
|
|
3441
|
-
|
|
3478
|
+
/** Preferred zoom level used when zooming to a point/zero-area feature in this layer. */
|
|
3479
|
+
zoomToLevel: d().min(0).max(24).optional(),
|
|
3480
|
+
styles: Z(oa).optional(),
|
|
3481
|
+
legend: ia.optional(),
|
|
3482
|
+
filters: _a.optional(),
|
|
3483
|
+
search: pa.optional(),
|
|
3484
|
+
propertyDisplay: ga.optional(),
|
|
3485
|
+
cql2Filter: Pa.optional(),
|
|
3486
|
+
showTooltip: y().optional(),
|
|
3487
|
+
showDetailPanel: y().optional()
|
|
3488
|
+
}, Na = Us(
|
|
3442
3489
|
(e) => {
|
|
3443
3490
|
if (e && typeof e == "object" && "style" in e && !("styles" in e)) {
|
|
3444
3491
|
const { style: t, ...n } = e;
|
|
@@ -3446,56 +3493,134 @@ const me = y([
|
|
|
3446
3493
|
}
|
|
3447
3494
|
return e;
|
|
3448
3495
|
},
|
|
3449
|
-
|
|
3450
|
-
),
|
|
3496
|
+
g(Ea)
|
|
3497
|
+
), ot = h().refine(
|
|
3498
|
+
(e) => e.startsWith("/") || /^https?:\/\//i.test(e),
|
|
3499
|
+
{ message: 'Must be an absolute http(s) URL or a path starting with "/"' }
|
|
3500
|
+
), Ca = g({
|
|
3451
3501
|
id: h().min(1),
|
|
3452
3502
|
label: h(),
|
|
3453
|
-
url:
|
|
3454
|
-
thumbnail:
|
|
3455
|
-
}),
|
|
3503
|
+
url: ot,
|
|
3504
|
+
thumbnail: ot.optional()
|
|
3505
|
+
}), Aa = g({
|
|
3456
3506
|
id: h().min(1),
|
|
3457
3507
|
url: h().url()
|
|
3458
|
-
}),
|
|
3459
|
-
|
|
3460
|
-
|
|
3461
|
-
|
|
3462
|
-
|
|
3463
|
-
|
|
3464
|
-
|
|
3465
|
-
|
|
3466
|
-
showExportButton
|
|
3467
|
-
|
|
3468
|
-
|
|
3469
|
-
|
|
3470
|
-
|
|
3471
|
-
|
|
3508
|
+
}), te = [
|
|
3509
|
+
"showLegend",
|
|
3510
|
+
"showSearchPanel",
|
|
3511
|
+
"showLayerPanel",
|
|
3512
|
+
"showMeasureTool",
|
|
3513
|
+
"showSelectionTool",
|
|
3514
|
+
"showImageryPanel",
|
|
3515
|
+
"showBasemapSwitcher",
|
|
3516
|
+
"showExportButton",
|
|
3517
|
+
"showCompass",
|
|
3518
|
+
"showInfoControl"
|
|
3519
|
+
], rt = ["top-right", "top-left", "bottom-right", "bottom-left"], ja = ["individual", "side-menu", "auto"], xa = ["decimal-degrees", "ddm", "dms"], Ra = g({
|
|
3520
|
+
showLayerPanel: y().default(!0),
|
|
3521
|
+
showLegend: y().default(!0),
|
|
3522
|
+
showBasemapSwitcher: y().default(!0),
|
|
3523
|
+
showSearchPanel: y().default(!1),
|
|
3524
|
+
showCoordinateDisplay: y().default(!0),
|
|
3525
|
+
showFeatureDetail: y().default(!0),
|
|
3526
|
+
showFeatureTooltip: y().default(!0),
|
|
3527
|
+
showExportButton: y().default(!0),
|
|
3528
|
+
/** When true, surfaces a "Export as PDF" option in the export modal. */
|
|
3529
|
+
showExportPdf: y().default(!1),
|
|
3530
|
+
showLegendOpacity: y().default(!1),
|
|
3531
|
+
showMeasureTool: y().default(!1),
|
|
3532
|
+
showSelectionTool: y().default(!1),
|
|
3533
|
+
showImageryPanel: y().default(!1),
|
|
3534
|
+
showCompass: y().default(!0),
|
|
3535
|
+
showGlobalSearch: y().default(!1),
|
|
3536
|
+
showScaleBar: y().default(!1),
|
|
3537
|
+
controlOrder: Z(v(te)).optional(),
|
|
3538
|
+
/**
|
|
3539
|
+
* Optional per-control corner override. When absent or a control is not
|
|
3540
|
+
* listed, the control falls back to 'top-right' (existing behavior).
|
|
3541
|
+
*/
|
|
3542
|
+
controlPositions: Qe(v(te), v(rt)).optional(),
|
|
3543
|
+
/**
|
|
3544
|
+
* How controls are presented: 'individual' renders each as its own button,
|
|
3545
|
+
* 'side-menu' collapses them into a SideMenuPanel, 'auto' picks based on
|
|
3546
|
+
* viewport width.
|
|
3547
|
+
*/
|
|
3548
|
+
controlLayout: v(ja).default("individual"),
|
|
3549
|
+
/**
|
|
3550
|
+
* Corner where the side-menu toggle (hamburger) button appears when using
|
|
3551
|
+
* 'side-menu' or 'auto' layout. Defaults to 'top-right'.
|
|
3552
|
+
*/
|
|
3553
|
+
sideMenuToggleCorner: v(rt).default("top-right"),
|
|
3554
|
+
/**
|
|
3555
|
+
* Optional per-control icon override. Keys are control keys (e.g. `showSearchPanel`),
|
|
3556
|
+
* values are icon names from `CONTROL_ICON_MAP`. Unknown names fall back to the
|
|
3557
|
+
* control's default icon.
|
|
3558
|
+
*/
|
|
3559
|
+
controlIcons: Qe(v(te), h()).optional(),
|
|
3560
|
+
/**
|
|
3561
|
+
* Optional display order for legend layers (array of layer IDs).
|
|
3562
|
+
* When absent, the legend renders visible layers in their natural order.
|
|
3563
|
+
* IDs not in the list are appended in natural order; unknown IDs are ignored.
|
|
3564
|
+
*/
|
|
3565
|
+
legendOrder: Z(h()).optional(),
|
|
3566
|
+
coordinateFormat: v(xa).default("decimal-degrees")
|
|
3567
|
+
});
|
|
3568
|
+
function Da(e) {
|
|
3569
|
+
if (!e.controlOrder || e.controlOrder.length === 0)
|
|
3570
|
+
return te;
|
|
3571
|
+
const t = new Set(e.controlOrder), n = te.filter((o) => !t.has(o));
|
|
3572
|
+
return [...e.controlOrder, ...n];
|
|
3573
|
+
}
|
|
3574
|
+
function Fa(e, t) {
|
|
3575
|
+
var n;
|
|
3576
|
+
return ((n = e.controlPositions) == null ? void 0 : n[t]) ?? "top-right";
|
|
3577
|
+
}
|
|
3578
|
+
function Va(e) {
|
|
3579
|
+
const t = {
|
|
3580
|
+
"top-right": [],
|
|
3581
|
+
"top-left": [],
|
|
3582
|
+
"bottom-right": [],
|
|
3583
|
+
"bottom-left": []
|
|
3584
|
+
};
|
|
3585
|
+
for (const n of Da(e))
|
|
3586
|
+
t[Fa(e, n)].push(n);
|
|
3587
|
+
return t;
|
|
3588
|
+
}
|
|
3589
|
+
const Ba = "#1e293b", La = g({
|
|
3472
3590
|
headerTitle: h().optional(),
|
|
3473
3591
|
headerColor: h().optional(),
|
|
3474
3592
|
browserTitle: h().optional(),
|
|
3475
3593
|
faviconDataUrl: h().optional(),
|
|
3476
3594
|
logoDataUrl: h().optional(),
|
|
3477
3595
|
logoHeight: d().int().min(16).max(200).optional()
|
|
3478
|
-
}),
|
|
3596
|
+
}), Ua = g({
|
|
3479
3597
|
id: h().min(1),
|
|
3480
3598
|
sourceId: h().default(""),
|
|
3481
3599
|
collection: h().default(""),
|
|
3482
3600
|
label: h(),
|
|
3483
|
-
visible:
|
|
3601
|
+
visible: y().default(!1),
|
|
3484
3602
|
opacity: d().min(0).max(1).default(1),
|
|
3485
|
-
exclusive:
|
|
3603
|
+
exclusive: y().default(!1),
|
|
3486
3604
|
minZoom: d().min(0).max(24).optional(),
|
|
3487
3605
|
maxZoom: d().min(0).max(24).optional(),
|
|
3488
3606
|
tileSize: d().default(256),
|
|
3489
|
-
tileUrlTemplate: h().optional()
|
|
3607
|
+
tileUrlTemplate: h().optional(),
|
|
3608
|
+
/** Optional thumbnail image URL rendered beside the layer in ImageryPanel. */
|
|
3609
|
+
thumbnailUrl: h().optional()
|
|
3490
3610
|
}).superRefine((e, t) => {
|
|
3491
3611
|
e.tileUrlTemplate || (e.sourceId || t.addIssue({ code: "custom", path: ["sourceId"], message: "Source is required when not using a custom tile URL" }), e.collection || t.addIssue({ code: "custom", path: ["collection"], message: "Collection is required when not using a custom tile URL" }));
|
|
3492
|
-
}),
|
|
3493
|
-
|
|
3494
|
-
|
|
3495
|
-
|
|
3496
|
-
|
|
3497
|
-
|
|
3498
|
-
|
|
3612
|
+
}), Ma = ["top-right", "top-left", "bottom-right", "bottom-left"], Ja = g({
|
|
3613
|
+
enabled: y().default(!1),
|
|
3614
|
+
title: h().optional(),
|
|
3615
|
+
markdown: h().default(""),
|
|
3616
|
+
position: v(Ma).default("top-right")
|
|
3617
|
+
}), Bt = g({
|
|
3618
|
+
sources: Z(Vs).min(1),
|
|
3619
|
+
layers: Z(Na),
|
|
3620
|
+
imageryLayers: Z(Ua).optional(),
|
|
3621
|
+
basemaps: Z(Ca).min(1),
|
|
3622
|
+
sprites: Z(Aa).optional(),
|
|
3623
|
+
ui: Ra.default({
|
|
3499
3624
|
showLayerPanel: !0,
|
|
3500
3625
|
showLegend: !0,
|
|
3501
3626
|
showBasemapSwitcher: !0,
|
|
@@ -3504,68 +3629,90 @@ const me = y([
|
|
|
3504
3629
|
showFeatureDetail: !0,
|
|
3505
3630
|
showFeatureTooltip: !0,
|
|
3506
3631
|
showExportButton: !0,
|
|
3632
|
+
showExportPdf: !1,
|
|
3507
3633
|
showLegendOpacity: !1,
|
|
3508
3634
|
showMeasureTool: !1,
|
|
3509
3635
|
showSelectionTool: !1,
|
|
3510
|
-
showImageryPanel: !1
|
|
3636
|
+
showImageryPanel: !1,
|
|
3637
|
+
showCompass: !0,
|
|
3638
|
+
showGlobalSearch: !1,
|
|
3639
|
+
showScaleBar: !1,
|
|
3640
|
+
controlLayout: "individual",
|
|
3641
|
+
sideMenuToggleCorner: "top-right",
|
|
3642
|
+
coordinateFormat: "decimal-degrees"
|
|
3511
3643
|
}),
|
|
3512
|
-
initialView:
|
|
3513
|
-
branding:
|
|
3644
|
+
initialView: Ms,
|
|
3645
|
+
branding: La.optional(),
|
|
3646
|
+
globalSearch: ha.optional(),
|
|
3647
|
+
info: Ja.optional()
|
|
3514
3648
|
});
|
|
3515
|
-
function
|
|
3516
|
-
return
|
|
3649
|
+
function Wa(e) {
|
|
3650
|
+
return Bt.parse(e);
|
|
3517
3651
|
}
|
|
3518
|
-
function
|
|
3519
|
-
return
|
|
3652
|
+
function Ga(e) {
|
|
3653
|
+
return Bt.safeParse(e);
|
|
3520
3654
|
}
|
|
3521
3655
|
export {
|
|
3522
|
-
|
|
3523
|
-
|
|
3524
|
-
|
|
3525
|
-
|
|
3526
|
-
|
|
3527
|
-
|
|
3528
|
-
|
|
3529
|
-
|
|
3530
|
-
|
|
3656
|
+
oa as $,
|
|
3657
|
+
ia as A,
|
|
3658
|
+
Ca as B,
|
|
3659
|
+
ja as C,
|
|
3660
|
+
Sa as D,
|
|
3661
|
+
ra as E,
|
|
3662
|
+
qs as F,
|
|
3663
|
+
ge as G,
|
|
3664
|
+
Ys as H,
|
|
3665
|
+
Ma as I,
|
|
3531
3666
|
Ws as J,
|
|
3532
|
-
|
|
3533
|
-
|
|
3534
|
-
|
|
3535
|
-
|
|
3536
|
-
|
|
3537
|
-
|
|
3538
|
-
|
|
3539
|
-
|
|
3540
|
-
|
|
3541
|
-
|
|
3542
|
-
|
|
3543
|
-
|
|
3544
|
-
|
|
3545
|
-
|
|
3546
|
-
|
|
3547
|
-
|
|
3548
|
-
|
|
3549
|
-
|
|
3550
|
-
|
|
3551
|
-
|
|
3552
|
-
|
|
3553
|
-
|
|
3554
|
-
|
|
3555
|
-
|
|
3556
|
-
|
|
3557
|
-
|
|
3558
|
-
|
|
3559
|
-
|
|
3560
|
-
|
|
3561
|
-
|
|
3562
|
-
|
|
3563
|
-
|
|
3564
|
-
|
|
3565
|
-
|
|
3566
|
-
|
|
3567
|
-
|
|
3568
|
-
|
|
3569
|
-
|
|
3570
|
-
|
|
3667
|
+
ea as K,
|
|
3668
|
+
Na as L,
|
|
3669
|
+
Bt as M,
|
|
3670
|
+
aa as N,
|
|
3671
|
+
te as O,
|
|
3672
|
+
Vs as P,
|
|
3673
|
+
ga as Q,
|
|
3674
|
+
ma as R,
|
|
3675
|
+
Mt as S,
|
|
3676
|
+
pa as T,
|
|
3677
|
+
la as U,
|
|
3678
|
+
ua as V,
|
|
3679
|
+
Ta as W,
|
|
3680
|
+
Js as X,
|
|
3681
|
+
$a as Y,
|
|
3682
|
+
Ia as Z,
|
|
3683
|
+
Aa as _,
|
|
3684
|
+
rt as a,
|
|
3685
|
+
Hs as a0,
|
|
3686
|
+
Ks as a1,
|
|
3687
|
+
na as a2,
|
|
3688
|
+
sa as a3,
|
|
3689
|
+
Ra as a4,
|
|
3690
|
+
Ms as a5,
|
|
3691
|
+
Va as a6,
|
|
3692
|
+
Wa as a7,
|
|
3693
|
+
Fa as b,
|
|
3694
|
+
xa as c,
|
|
3695
|
+
La as d,
|
|
3696
|
+
Xs as e,
|
|
3697
|
+
Gs as f,
|
|
3698
|
+
ta as g,
|
|
3699
|
+
za as h,
|
|
3700
|
+
Pa as i,
|
|
3701
|
+
Ba as j,
|
|
3702
|
+
wa as k,
|
|
3703
|
+
ca as l,
|
|
3704
|
+
Bs as m,
|
|
3705
|
+
Qs as n,
|
|
3706
|
+
_a as o,
|
|
3707
|
+
va as p,
|
|
3708
|
+
Vt as q,
|
|
3709
|
+
Da as r,
|
|
3710
|
+
Ga as s,
|
|
3711
|
+
Oa as t,
|
|
3712
|
+
ka as u,
|
|
3713
|
+
ha as v,
|
|
3714
|
+
da as w,
|
|
3715
|
+
fa as x,
|
|
3716
|
+
Ua as y,
|
|
3717
|
+
Ja as z
|
|
3571
3718
|
};
|