@wp-playground/client 0.5.1 → 0.5.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/index.cjs +16 -16
  2. package/index.js +414 -413
  3. package/package.json +2 -2
package/index.js CHANGED
@@ -7,7 +7,7 @@ var H = (e, t, r) => (vn(e, t, "read from private field"), r ? r.call(e) : t.get
7
7
  throw TypeError("Cannot add the same private member more than once");
8
8
  t instanceof WeakSet ? t.add(e) : t.set(e, r);
9
9
  }, pe = (e, t, r, n) => (vn(e, t, "write to private field"), n ? n.call(e, r) : t.set(e, r), r);
10
- var $e = (e, t, r) => (vn(e, t, "access private method"), r);
10
+ var _e = (e, t, r) => (vn(e, t, "access private method"), r);
11
11
  if (typeof File > "u") {
12
12
  class e extends Blob {
13
13
  constructor(r, n, s) {
@@ -737,7 +737,7 @@ class Mn {
737
737
  }
738
738
  }
739
739
  }
740
- function ve(...e) {
740
+ function ye(...e) {
741
741
  let t = e.join("/");
742
742
  const r = t[0] === "/", n = t.substring(t.length - 1) === "/";
743
743
  return t = ji(t), !t && !r && (t = "."), t && n && (t += "/"), t;
@@ -854,9 +854,9 @@ const ma = async (e, { sql: t }, r) => {
854
854
  );
855
855
  const o = Ea(i);
856
856
  o.fetch_attachments = "1";
857
- for (const p in o)
858
- if (p.startsWith("user_map[")) {
859
- const u = "user_new[" + p.slice(9, -1) + "]";
857
+ for (const d in o)
858
+ if (d.startsWith("user_map[")) {
859
+ const u = "user_new[" + d.slice(9, -1) + "]";
860
860
  o[u] = "1";
861
861
  }
862
862
  await e.request({
@@ -887,41 +887,41 @@ const Ln = async (e, { zipPath: t, extractToPath: r }) => {
887
887
  new Uint8Array(await t.arrayBuffer())
888
888
  );
889
889
  const s = await e.documentRoot;
890
- let i = ve("/tmp", "import");
891
- await e.mkdir(i), await Ln(e, { zipPath: n, extractToPath: i }), await e.unlink(n), i = ve(i, r);
892
- const o = ve(i, "wp-content"), l = ve(s, "wp-content");
890
+ let i = ye("/tmp", "import");
891
+ await e.mkdir(i), await Ln(e, { zipPath: n, extractToPath: i }), await e.unlink(n), i = ye(i, r);
892
+ const o = ye(i, "wp-content"), l = ye(s, "wp-content");
893
893
  for (const h of Ti) {
894
- const w = ve(
894
+ const w = ye(
895
895
  o,
896
896
  h
897
897
  );
898
898
  await Ws(e, w);
899
- const T = ve(l, h);
899
+ const T = ye(l, h);
900
900
  await e.fileExists(T) && (await e.mkdir(da(w)), await e.mv(T, w));
901
901
  }
902
- const p = ve(
902
+ const d = ye(
903
903
  i,
904
904
  "wp-content",
905
905
  "database"
906
906
  );
907
- await e.fileExists(p) || await e.mv(
908
- ve(s, "wp-content", "database"),
909
- p
907
+ await e.fileExists(d) || await e.mv(
908
+ ye(s, "wp-content", "database"),
909
+ d
910
910
  );
911
911
  const u = await e.listFiles(i);
912
912
  for (const h of u)
913
- await Ws(e, ve(s, h)), await e.mv(
914
- ve(i, h),
915
- ve(s, h)
913
+ await Ws(e, ye(s, h)), await e.mv(
914
+ ye(i, h),
915
+ ye(s, h)
916
916
  );
917
917
  await e.rmdir(i);
918
- const d = $r(
919
- ve(s, "wp-admin", "upgrade.php")
918
+ const p = $r(
919
+ ye(s, "wp-admin", "upgrade.php")
920
920
  );
921
921
  await e.run({
922
922
  code: `<?php
923
923
  $_GET['step'] = 'upgrade_db';
924
- require ${d};
924
+ require ${p};
925
925
  `
926
926
  });
927
927
  };
@@ -941,31 +941,32 @@ async function Ra(e) {
941
941
  return new File([t.bytes], "export.wxz");
942
942
  }
943
943
  async function Ai(e, { targetPath: t, zipFile: r }) {
944
- const n = r.name, s = n.replace(/\.zip$/, ""), i = `/tmp/assets/${s}`, o = `/tmp/${n}`, l = () => e.rmdir(i, {
944
+ const n = r.name, s = n.replace(/\.zip$/, ""), i = ye(await e.documentRoot, "wp-content"), o = ye(i, crypto.randomUUID()), l = ye(o, n), d = ye(o, "assets", s);
945
+ await e.fileExists(d) && await e.rmdir(o, {
945
946
  recursive: !0
946
- });
947
- await e.fileExists(i) && await l(), await Ii(e, {
948
- path: o,
947
+ }), await e.mkdir(o), await Ii(e, {
948
+ path: l,
949
949
  data: r
950
950
  });
951
- const p = () => Promise.all([l, () => e.unlink(o)]);
952
951
  try {
953
952
  await Ln(e, {
954
- zipPath: o,
955
- extractToPath: i
953
+ zipPath: l,
954
+ extractToPath: d
956
955
  });
957
- const u = await e.listFiles(i, {
956
+ const u = await e.listFiles(d, {
958
957
  prependPath: !0
959
- }), d = u.length === 1 && await e.isDir(u[0]);
958
+ }), p = u.length === 1 && await e.isDir(u[0]);
960
959
  let h, w = "";
961
- d ? (w = u[0], h = u[0].split("/").pop()) : (w = i, h = s);
960
+ p ? (w = u[0], h = u[0].split("/").pop()) : (w = d, h = s);
962
961
  const T = `${t}/${h}`;
963
- return await e.mv(w, T), await p(), {
962
+ return await e.mv(w, T), {
964
963
  assetFolderPath: T,
965
964
  assetFolderName: h
966
965
  };
967
- } catch (u) {
968
- throw await p(), u;
966
+ } finally {
967
+ await e.rmdir(o, {
968
+ recursive: !0
969
+ });
969
970
  }
970
971
  }
971
972
  const Oa = async (e, { pluginZipFile: t, options: r = {} }, n) => {
@@ -1075,18 +1076,18 @@ async function Di(e) {
1075
1076
  throw console.log(e), new Error(`Failed to run code: ${e.text} ${e.errors}`);
1076
1077
  }
1077
1078
  const Da = async (e, { selfContained: t = !1 } = {}) => {
1078
- const r = "/tmp/wordpress-playground.zip", n = await e.documentRoot, s = ve(n, "wp-content");
1079
+ const r = "/tmp/wordpress-playground.zip", n = await e.documentRoot, s = ye(n, "wp-content");
1079
1080
  let i = Ti;
1080
- t && (i = i.filter((p) => !p.startsWith("themes/twenty")).filter((p) => p !== "plugins/sqlite-database-integration"));
1081
+ t && (i = i.filter((d) => !d.startsWith("themes/twenty")).filter((d) => d !== "plugins/sqlite-database-integration"));
1081
1082
  const o = Un({
1082
1083
  zipPath: r,
1083
1084
  wpContentPath: s,
1084
1085
  documentRoot: n,
1085
1086
  exceptPaths: i.map(
1086
- (p) => ve(n, "wp-content", p)
1087
+ (d) => ye(n, "wp-content", d)
1087
1088
  ),
1088
1089
  additionalPaths: t ? {
1089
- [ve(n, "wp-config.php")]: "wp-config.php"
1090
+ [ye(n, "wp-config.php")]: "wp-config.php"
1090
1091
  } : {}
1091
1092
  });
1092
1093
  await Ri(
@@ -1153,14 +1154,14 @@ function Ma(e, t) {
1153
1154
  let l = 0;
1154
1155
  for (; ; )
1155
1156
  try {
1156
- const { done: p, value: u } = await o.read();
1157
- if (u && (l += u.byteLength), p) {
1157
+ const { done: d, value: u } = await o.read();
1158
+ if (u && (l += u.byteLength), d) {
1158
1159
  s(l, l), i.close();
1159
1160
  break;
1160
1161
  } else
1161
1162
  s(l, n), i.enqueue(u);
1162
- } catch (p) {
1163
- console.error({ e: p }), i.error(p);
1163
+ } catch (d) {
1164
+ console.error({ e: d }), i.error(d);
1164
1165
  break;
1165
1166
  }
1166
1167
  }
@@ -1726,7 +1727,7 @@ class Xa {
1726
1727
  n.pathname,
1727
1728
  H(this, xe)
1728
1729
  ), i = `${H(this, We)}${s}`;
1729
- return rc(i) ? await $e(this, Xr, Mi).call(this, t, n) : $e(this, Zr, qi).call(this, i);
1730
+ return rc(i) ? await _e(this, Xr, Mi).call(this, t, n) : _e(this, Zr, qi).call(this, i);
1730
1731
  }
1731
1732
  }
1732
1733
  We = new WeakMap(), Ht = new WeakMap(), wr = new WeakMap(), _t = new WeakMap(), Vt = new WeakMap(), xe = new WeakMap(), Wt = new WeakMap(), xt = new WeakMap(), Zr = new WeakSet(), qi = function(t) {
@@ -1769,10 +1770,10 @@ We = new WeakMap(), Ht = new WeakMap(), wr = new WeakMap(), _t = new WeakMap(),
1769
1770
  }, l = [];
1770
1771
  if (t.files && Object.keys(t.files).length) {
1771
1772
  i = "POST";
1772
- for (const d in t.files) {
1773
- const h = t.files[d];
1773
+ for (const p in t.files) {
1774
+ const h = t.files[p];
1774
1775
  l.push({
1775
- key: d,
1776
+ key: p,
1776
1777
  name: h.name,
1777
1778
  type: h.type,
1778
1779
  data: new Uint8Array(await h.arrayBuffer())
@@ -1782,13 +1783,13 @@ We = new WeakMap(), Ht = new WeakMap(), wr = new WeakMap(), _t = new WeakMap(),
1782
1783
  t.body || ""
1783
1784
  ), o["content-type"] = "application/x-www-form-urlencoded", delete t.body);
1784
1785
  }
1785
- let p;
1786
- t.formData !== void 0 ? (i = "POST", o["content-type"] = o["content-type"] || "application/x-www-form-urlencoded", p = new URLSearchParams(
1786
+ let d;
1787
+ t.formData !== void 0 ? (i = "POST", o["content-type"] = o["content-type"] || "application/x-www-form-urlencoded", d = new URLSearchParams(
1787
1788
  t.formData
1788
- ).toString()) : p = t.body;
1789
+ ).toString()) : d = t.body;
1789
1790
  let u;
1790
1791
  try {
1791
- u = $e(this, en, Ui).call(this, r.pathname);
1792
+ u = _e(this, en, Ui).call(this, r.pathname);
1792
1793
  } catch {
1793
1794
  return new bt(
1794
1795
  404,
@@ -1803,7 +1804,7 @@ We = new WeakMap(), Ht = new WeakMap(), wr = new WeakMap(), _t = new WeakMap(),
1803
1804
  ),
1804
1805
  protocol: H(this, Ht),
1805
1806
  method: t.method || i,
1806
- body: p,
1807
+ body: d,
1807
1808
  fileInfos: l,
1808
1809
  scriptPath: u,
1809
1810
  headers: o
@@ -1829,10 +1830,10 @@ function ec(e) {
1829
1830
  return s.shift(), s.pop(), s.forEach((i) => {
1830
1831
  const o = i.indexOf(`\r
1831
1832
  \r
1832
- `), l = i.substring(0, o).trim(), p = i.substring(o + 4).trim(), u = l.match(/name="([^"]+)"/);
1833
+ `), l = i.substring(0, o).trim(), d = i.substring(o + 4).trim(), u = l.match(/name="([^"]+)"/);
1833
1834
  if (u) {
1834
- const d = u[1];
1835
- t[d] = p;
1835
+ const p = u[1];
1836
+ t[p] = d;
1836
1837
  }
1837
1838
  }), t;
1838
1839
  }
@@ -1971,9 +1972,9 @@ function De(e = "") {
1971
1972
  try {
1972
1973
  return i.apply(this, o);
1973
1974
  } catch (l) {
1974
- const p = typeof l == "object" ? l == null ? void 0 : l.errno : null;
1975
- if (p in ei) {
1976
- const u = ei[p], d = typeof o[0] == "string" ? o[0] : null, h = d !== null ? e.replaceAll("{path}", d) : e;
1975
+ const d = typeof l == "object" ? l == null ? void 0 : l.errno : null;
1976
+ if (d in ei) {
1977
+ const u = ei[d], p = typeof o[0] == "string" ? o[0] : null, h = p !== null ? e.replaceAll("{path}", p) : e;
1977
1978
  throw new Error(`${h}: ${u}`, {
1978
1979
  cause: l
1979
1980
  });
@@ -1996,7 +1997,7 @@ var ac = Object.defineProperty, cc = Object.getOwnPropertyDescriptor, Fe = (e, t
1996
1997
  (o = e[i]) && (s = (n ? o(t, r, s) : o(s)) || s);
1997
1998
  return n && s && ac(t, r, s), s;
1998
1999
  };
1999
- const _e = "string", Dt = "number", te = Symbol("__private__dont__use");
2000
+ const we = "string", Dt = "number", te = Symbol("__private__dont__use");
2000
2001
  var wt, nt, vt, st, Ye, Bt, vr, tn, Li, rn, zi, nn, Hi, sn, Vi, on, Wi, an, xi, cn, Bi, ln, Ki, un, Gi, dn, Ji, pn, Yi, fn, Qi;
2001
2002
  class qe {
2002
2003
  /**
@@ -2124,12 +2125,12 @@ class qe {
2124
2125
  async run(t) {
2125
2126
  const r = await H(this, vr).acquire();
2126
2127
  try {
2127
- H(this, nt) || ($e(this, tn, Li).call(this), pe(this, nt, !0)), $e(this, ln, Ki).call(this, t.scriptPath || ""), $e(this, nn, Hi).call(this, t.relativeUri || ""), $e(this, on, Wi).call(this, t.method || "GET");
2128
+ H(this, nt) || (_e(this, tn, Li).call(this), pe(this, nt, !0)), _e(this, ln, Ki).call(this, t.scriptPath || ""), _e(this, nn, Hi).call(this, t.relativeUri || ""), _e(this, on, Wi).call(this, t.method || "GET");
2128
2129
  const n = Zi(t.headers || {}), s = n.host || "example.com:443";
2129
- if ($e(this, sn, Vi).call(this, s, t.protocol || "http"), $e(this, an, xi).call(this, n), t.body && $e(this, cn, Bi).call(this, t.body), t.fileInfos)
2130
+ if (_e(this, sn, Vi).call(this, s, t.protocol || "http"), _e(this, an, xi).call(this, n), t.body && _e(this, cn, Bi).call(this, t.body), t.fileInfos)
2130
2131
  for (const i of t.fileInfos)
2131
- $e(this, dn, Ji).call(this, i);
2132
- return t.code && $e(this, pn, Yi).call(this, " ?>" + t.code), $e(this, un, Gi).call(this), await $e(this, fn, Qi).call(this);
2132
+ _e(this, dn, Ji).call(this, i);
2133
+ return t.code && _e(this, pn, Yi).call(this, " ?>" + t.code), _e(this, un, Gi).call(this), await _e(this, fn, Qi).call(this);
2133
2134
  } finally {
2134
2135
  r(), this.dispatchEvent({
2135
2136
  type: "request.end"
@@ -2234,7 +2235,7 @@ wt = new WeakMap(), nt = new WeakMap(), vt = new WeakMap(), st = new WeakMap(),
2234
2235
  this[te].ccall(
2235
2236
  "wasm_set_phpini_entries",
2236
2237
  null,
2237
- [_e],
2238
+ [we],
2238
2239
  [t]
2239
2240
  );
2240
2241
  }
@@ -2260,14 +2261,14 @@ wt = new WeakMap(), nt = new WeakMap(), vt = new WeakMap(), st = new WeakMap(),
2260
2261
  if (this[te].ccall(
2261
2262
  "wasm_set_request_uri",
2262
2263
  null,
2263
- [_e],
2264
+ [we],
2264
2265
  [t]
2265
2266
  ), t.includes("?")) {
2266
2267
  const r = t.substring(t.indexOf("?") + 1);
2267
2268
  this[te].ccall(
2268
2269
  "wasm_set_query_string",
2269
2270
  null,
2270
- [_e],
2271
+ [we],
2271
2272
  [r]
2272
2273
  );
2273
2274
  }
@@ -2275,7 +2276,7 @@ wt = new WeakMap(), nt = new WeakMap(), vt = new WeakMap(), st = new WeakMap(),
2275
2276
  this[te].ccall(
2276
2277
  "wasm_set_request_host",
2277
2278
  null,
2278
- [_e],
2279
+ [we],
2279
2280
  [t]
2280
2281
  );
2281
2282
  let n;
@@ -2293,19 +2294,19 @@ wt = new WeakMap(), nt = new WeakMap(), vt = new WeakMap(), st = new WeakMap(),
2293
2294
  this[te].ccall(
2294
2295
  "wasm_set_request_method",
2295
2296
  null,
2296
- [_e],
2297
+ [we],
2297
2298
  [t]
2298
2299
  );
2299
2300
  }, an = new WeakSet(), xi = function(t) {
2300
2301
  t.cookie && this[te].ccall(
2301
2302
  "wasm_set_cookies",
2302
2303
  null,
2303
- [_e],
2304
+ [we],
2304
2305
  [t.cookie]
2305
2306
  ), t["content-type"] && this[te].ccall(
2306
2307
  "wasm_set_content_type",
2307
2308
  null,
2308
- [_e],
2309
+ [we],
2309
2310
  [t["content-type"]]
2310
2311
  ), t["content-length"] && this[te].ccall(
2311
2312
  "wasm_set_content_length",
@@ -2324,7 +2325,7 @@ wt = new WeakMap(), nt = new WeakMap(), vt = new WeakMap(), st = new WeakMap(),
2324
2325
  this[te].ccall(
2325
2326
  "wasm_set_request_body",
2326
2327
  null,
2327
- [_e],
2328
+ [we],
2328
2329
  [t]
2329
2330
  ), this[te].ccall(
2330
2331
  "wasm_set_content_length",
@@ -2336,7 +2337,7 @@ wt = new WeakMap(), nt = new WeakMap(), vt = new WeakMap(), st = new WeakMap(),
2336
2337
  this[te].ccall(
2337
2338
  "wasm_set_path_translated",
2338
2339
  null,
2339
- [_e],
2340
+ [we],
2340
2341
  [t]
2341
2342
  );
2342
2343
  }, un = new WeakSet(), Gi = function() {
@@ -2344,7 +2345,7 @@ wt = new WeakMap(), nt = new WeakMap(), vt = new WeakMap(), st = new WeakMap(),
2344
2345
  this[te].ccall(
2345
2346
  "wasm_add_SERVER_entry",
2346
2347
  null,
2347
- [_e, _e],
2348
+ [we, we],
2348
2349
  [t, H(this, st)[t]]
2349
2350
  );
2350
2351
  }, dn = new WeakSet(), Ji = function(t) {
@@ -2354,14 +2355,14 @@ wt = new WeakMap(), nt = new WeakMap(), vt = new WeakMap(), st = new WeakMap(),
2354
2355
  this[te].ccall(
2355
2356
  "wasm_add_uploaded_file",
2356
2357
  null,
2357
- [_e, _e, _e, _e, Dt, Dt],
2358
+ [we, we, we, we, Dt, Dt],
2358
2359
  [r, n, s, o, l, i.byteLength]
2359
2360
  );
2360
2361
  }, pn = new WeakSet(), Yi = function(t) {
2361
2362
  this[te].ccall(
2362
2363
  "wasm_set_php_code",
2363
2364
  null,
2364
- [_e],
2365
+ [we],
2365
2366
  [t]
2366
2367
  );
2367
2368
  }, fn = new WeakSet(), Qi = async function() {
@@ -2370,36 +2371,36 @@ wt = new WeakMap(), nt = new WeakMap(), vt = new WeakMap(), st = new WeakMap(),
2370
2371
  try {
2371
2372
  t = await new Promise((o, l) => {
2372
2373
  var u;
2373
- r = (d) => {
2374
+ r = (p) => {
2374
2375
  const h = new Error("Rethrown");
2375
- h.cause = d.error, h.betterMessage = d.message, l(h);
2376
+ h.cause = p.error, h.betterMessage = p.message, l(h);
2376
2377
  }, (u = H(this, vt)) == null || u.addEventListener(
2377
2378
  "error",
2378
2379
  r
2379
2380
  );
2380
- const p = this[te].ccall(
2381
+ const d = this[te].ccall(
2381
2382
  "wasm_sapi_handle_request",
2382
2383
  Dt,
2383
2384
  [],
2384
2385
  [],
2385
2386
  { async: !0 }
2386
2387
  );
2387
- return p instanceof Promise ? p.then(o, l) : o(p);
2388
+ return d instanceof Promise ? d.then(o, l) : o(d);
2388
2389
  });
2389
2390
  } catch (o) {
2390
- for (const d in this)
2391
- typeof this[d] == "function" && (this[d] = () => {
2391
+ for (const p in this)
2392
+ typeof this[p] == "function" && (this[p] = () => {
2392
2393
  throw new Error(
2393
2394
  "PHP runtime has crashed – see the earlier error for details."
2394
2395
  );
2395
2396
  });
2396
2397
  this.functionsMaybeMissingFromAsyncify = Va();
2397
- const l = o, p = "betterMessage" in l ? l.betterMessage : l.message, u = new Error(p);
2398
+ const l = o, d = "betterMessage" in l ? l.betterMessage : l.message, u = new Error(d);
2398
2399
  throw u.cause = l, u;
2399
2400
  } finally {
2400
2401
  (i = H(this, vt)) == null || i.removeEventListener("error", r), pe(this, st, {});
2401
2402
  }
2402
- const { headers: n, httpStatusCode: s } = $e(this, rn, zi).call(this);
2403
+ const { headers: n, httpStatusCode: s } = _e(this, rn, zi).call(this);
2403
2404
  return new bt(
2404
2405
  s,
2405
2406
  n,
@@ -2734,14 +2735,14 @@ var Nn = { exports: {} }, to = {}, Ae = {}, Kt = {}, br = {}, K = {}, _r = {};
2734
2735
  let j = 0;
2735
2736
  for (; j < O.length; )
2736
2737
  C.push(i), l(C, O[j]), C.push(i, T(g[++j]));
2737
- return p(C), new n(C);
2738
+ return d(C), new n(C);
2738
2739
  }
2739
2740
  e.str = o;
2740
2741
  function l(g, O) {
2741
2742
  O instanceof n ? g.push(...O._items) : O instanceof r ? g.push(O) : g.push(h(O));
2742
2743
  }
2743
2744
  e.addCodeArg = l;
2744
- function p(g) {
2745
+ function d(g) {
2745
2746
  let O = 1;
2746
2747
  for (; O < g.length - 1; ) {
2747
2748
  if (g[O] === i) {
@@ -2765,10 +2766,10 @@ var Nn = { exports: {} }, to = {}, Ae = {}, Kt = {}, br = {}, K = {}, _r = {};
2765
2766
  if (typeof O == "string" && O[0] === '"' && !(g instanceof r))
2766
2767
  return `"${g}${O.slice(1)}`;
2767
2768
  }
2768
- function d(g, O) {
2769
+ function p(g, O) {
2769
2770
  return O.emptyStr() ? g : g.emptyStr() ? O : o`${g}${O}`;
2770
2771
  }
2771
- e.strConcat = d;
2772
+ e.strConcat = p;
2772
2773
  function h(g) {
2773
2774
  return typeof g == "number" || typeof g == "boolean" || g === null ? g : T(Array.isArray(g) ? g.join(",") : g);
2774
2775
  }
@@ -2805,16 +2806,16 @@ var kn = {};
2805
2806
  }
2806
2807
  }
2807
2808
  var n;
2808
- (function(p) {
2809
- p[p.Started = 0] = "Started", p[p.Completed = 1] = "Completed";
2809
+ (function(d) {
2810
+ d[d.Started = 0] = "Started", d[d.Completed = 1] = "Completed";
2810
2811
  })(n = e.UsedValueState || (e.UsedValueState = {})), e.varKinds = {
2811
2812
  const: new t.Name("const"),
2812
2813
  let: new t.Name("let"),
2813
2814
  var: new t.Name("var")
2814
2815
  };
2815
2816
  class s {
2816
- constructor({ prefixes: u, parent: d } = {}) {
2817
- this._names = {}, this._prefixes = u, this._parent = d;
2817
+ constructor({ prefixes: u, parent: p } = {}) {
2818
+ this._names = {}, this._prefixes = u, this._parent = p;
2818
2819
  }
2819
2820
  toName(u) {
2820
2821
  return u instanceof t.Name ? u : this.name(u);
@@ -2823,23 +2824,23 @@ var kn = {};
2823
2824
  return new t.Name(this._newName(u));
2824
2825
  }
2825
2826
  _newName(u) {
2826
- const d = this._names[u] || this._nameGroup(u);
2827
- return `${u}${d.index++}`;
2827
+ const p = this._names[u] || this._nameGroup(u);
2828
+ return `${u}${p.index++}`;
2828
2829
  }
2829
2830
  _nameGroup(u) {
2830
- var d, h;
2831
- if (!((h = (d = this._parent) === null || d === void 0 ? void 0 : d._prefixes) === null || h === void 0) && h.has(u) || this._prefixes && !this._prefixes.has(u))
2831
+ var p, h;
2832
+ if (!((h = (p = this._parent) === null || p === void 0 ? void 0 : p._prefixes) === null || h === void 0) && h.has(u) || this._prefixes && !this._prefixes.has(u))
2832
2833
  throw new Error(`CodeGen: prefix "${u}" is not allowed in this scope`);
2833
2834
  return this._names[u] = { prefix: u, index: 0 };
2834
2835
  }
2835
2836
  }
2836
2837
  e.Scope = s;
2837
2838
  class i extends t.Name {
2838
- constructor(u, d) {
2839
- super(d), this.prefix = u;
2839
+ constructor(u, p) {
2840
+ super(p), this.prefix = u;
2840
2841
  }
2841
- setValue(u, { property: d, itemIndex: h }) {
2842
- this.value = u, this.scopePath = (0, t._)`.${new t.Name(d)}[${h}]`;
2842
+ setValue(u, { property: p, itemIndex: h }) {
2843
+ this.value = u, this.scopePath = (0, t._)`.${new t.Name(p)}[${h}]`;
2843
2844
  }
2844
2845
  }
2845
2846
  e.ValueScopeName = i;
@@ -2854,11 +2855,11 @@ var kn = {};
2854
2855
  name(u) {
2855
2856
  return new i(u, this._newName(u));
2856
2857
  }
2857
- value(u, d) {
2858
+ value(u, p) {
2858
2859
  var h;
2859
- if (d.ref === void 0)
2860
+ if (p.ref === void 0)
2860
2861
  throw new Error("CodeGen: ref must be passed in value");
2861
- const w = this.toName(u), { prefix: T } = w, v = (h = d.key) !== null && h !== void 0 ? h : d.ref;
2862
+ const w = this.toName(u), { prefix: T } = w, v = (h = p.key) !== null && h !== void 0 ? h : p.ref;
2862
2863
  let R = this._values[T];
2863
2864
  if (R) {
2864
2865
  const O = R.get(v);
@@ -2868,28 +2869,28 @@ var kn = {};
2868
2869
  R = this._values[T] = /* @__PURE__ */ new Map();
2869
2870
  R.set(v, w);
2870
2871
  const _ = this._scope[T] || (this._scope[T] = []), g = _.length;
2871
- return _[g] = d.ref, w.setValue(d, { property: T, itemIndex: g }), w;
2872
+ return _[g] = p.ref, w.setValue(p, { property: T, itemIndex: g }), w;
2872
2873
  }
2873
- getValue(u, d) {
2874
+ getValue(u, p) {
2874
2875
  const h = this._values[u];
2875
2876
  if (h)
2876
- return h.get(d);
2877
+ return h.get(p);
2877
2878
  }
2878
- scopeRefs(u, d = this._values) {
2879
- return this._reduceValues(d, (h) => {
2879
+ scopeRefs(u, p = this._values) {
2880
+ return this._reduceValues(p, (h) => {
2880
2881
  if (h.scopePath === void 0)
2881
2882
  throw new Error(`CodeGen: name "${h}" has no value`);
2882
2883
  return (0, t._)`${u}${h.scopePath}`;
2883
2884
  });
2884
2885
  }
2885
- scopeCode(u = this._values, d, h) {
2886
+ scopeCode(u = this._values, p, h) {
2886
2887
  return this._reduceValues(u, (w) => {
2887
2888
  if (w.value === void 0)
2888
2889
  throw new Error(`CodeGen: name "${w}" has no value`);
2889
2890
  return w.value.code;
2890
- }, d, h);
2891
+ }, p, h);
2891
2892
  }
2892
- _reduceValues(u, d, h = {}, w) {
2893
+ _reduceValues(u, p, h = {}, w) {
2893
2894
  let T = t.nil;
2894
2895
  for (const v in u) {
2895
2896
  const R = u[v];
@@ -2900,7 +2901,7 @@ var kn = {};
2900
2901
  if (_.has(g))
2901
2902
  return;
2902
2903
  _.set(g, n.Started);
2903
- let O = d(g);
2904
+ let O = p(g);
2904
2905
  if (O) {
2905
2906
  const C = this.opts.es5 ? e.varKinds.var : e.varKinds.const;
2906
2907
  T = (0, t._)`${T}${C} ${g} = ${O};${this.opts._n}`;
@@ -2998,7 +2999,7 @@ var kn = {};
2998
2999
  return Re(a, this.rhs);
2999
3000
  }
3000
3001
  }
3001
- class p extends l {
3002
+ class d extends l {
3002
3003
  constructor(a, m, k, q) {
3003
3004
  super(a, k, q), this.op = m;
3004
3005
  }
@@ -3014,7 +3015,7 @@ var kn = {};
3014
3015
  return `${this.label}:` + a;
3015
3016
  }
3016
3017
  }
3017
- class d extends i {
3018
+ class p extends i {
3018
3019
  constructor(a) {
3019
3020
  super(), this.label = a, this.names = {};
3020
3021
  }
@@ -3271,7 +3272,7 @@ var kn = {};
3271
3272
  }
3272
3273
  // `+=` code
3273
3274
  add(a, m) {
3274
- return this._leafNode(new p(a, e.operators.ADD, m));
3275
+ return this._leafNode(new d(a, e.operators.ADD, m));
3275
3276
  }
3276
3277
  // appends passed SafeExpr to code or executes Block
3277
3278
  code(a) {
@@ -3347,7 +3348,7 @@ var kn = {};
3347
3348
  }
3348
3349
  // `break` statement
3349
3350
  break(a) {
3350
- return this._leafNode(new d(a));
3351
+ return this._leafNode(new p(a));
3351
3352
  }
3352
3353
  // `return` statement
3353
3354
  return(a) {
@@ -3517,7 +3518,7 @@ var re = {};
3517
3518
  return !1;
3518
3519
  }
3519
3520
  e.schemaHasRulesButRef = l;
3520
- function p({ topSchemaRef: b, schemaPath: N }, A, W, G) {
3521
+ function d({ topSchemaRef: b, schemaPath: N }, A, W, G) {
3521
3522
  if (!G) {
3522
3523
  if (typeof A == "number" || typeof A == "boolean")
3523
3524
  return A;
@@ -3526,15 +3527,15 @@ var re = {};
3526
3527
  }
3527
3528
  return (0, t._)`${b}${N}${(0, t.getProperty)(W)}`;
3528
3529
  }
3529
- e.schemaRefOrVal = p;
3530
+ e.schemaRefOrVal = d;
3530
3531
  function u(b) {
3531
3532
  return w(decodeURIComponent(b));
3532
3533
  }
3533
3534
  e.unescapeFragment = u;
3534
- function d(b) {
3535
+ function p(b) {
3535
3536
  return encodeURIComponent(h(b));
3536
3537
  }
3537
- e.escapeFragment = d;
3538
+ e.escapeFragment = p;
3538
3539
  function h(b) {
3539
3540
  return typeof b == "number" ? `${b}` : b.replace(/~/g, "~0").replace(/\//g, "~1");
3540
3541
  }
@@ -3617,28 +3618,28 @@ var re = {};
3617
3618
  })(re);
3618
3619
  var Ge = {};
3619
3620
  Object.defineProperty(Ge, "__esModule", { value: !0 });
3620
- const we = K, vc = {
3621
+ const ve = K, vc = {
3621
3622
  // validation function arguments
3622
- data: new we.Name("data"),
3623
+ data: new ve.Name("data"),
3623
3624
  // args passed from referencing schema
3624
- valCxt: new we.Name("valCxt"),
3625
- instancePath: new we.Name("instancePath"),
3626
- parentData: new we.Name("parentData"),
3627
- parentDataProperty: new we.Name("parentDataProperty"),
3628
- rootData: new we.Name("rootData"),
3629
- dynamicAnchors: new we.Name("dynamicAnchors"),
3625
+ valCxt: new ve.Name("valCxt"),
3626
+ instancePath: new ve.Name("instancePath"),
3627
+ parentData: new ve.Name("parentData"),
3628
+ parentDataProperty: new ve.Name("parentDataProperty"),
3629
+ rootData: new ve.Name("rootData"),
3630
+ dynamicAnchors: new ve.Name("dynamicAnchors"),
3630
3631
  // function scoped variables
3631
- vErrors: new we.Name("vErrors"),
3632
- errors: new we.Name("errors"),
3633
- this: new we.Name("this"),
3632
+ vErrors: new ve.Name("vErrors"),
3633
+ errors: new ve.Name("errors"),
3634
+ this: new ve.Name("this"),
3634
3635
  // "globals"
3635
- self: new we.Name("self"),
3636
- scope: new we.Name("scope"),
3636
+ self: new ve.Name("self"),
3637
+ scope: new ve.Name("scope"),
3637
3638
  // JTD serialize/parse name for JSON string and position
3638
- json: new we.Name("json"),
3639
- jsonPos: new we.Name("jsonPos"),
3640
- jsonLen: new we.Name("jsonLen"),
3641
- jsonPart: new we.Name("jsonPart")
3639
+ json: new ve.Name("json"),
3640
+ jsonPos: new ve.Name("jsonPos"),
3641
+ jsonLen: new ve.Name("jsonLen"),
3642
+ jsonPart: new ve.Name("jsonPart")
3642
3643
  };
3643
3644
  Ge.default = vc;
3644
3645
  (function(e) {
@@ -3651,12 +3652,12 @@ Ge.default = vc;
3651
3652
  };
3652
3653
  function s(_, g = e.keywordError, O, C) {
3653
3654
  const { it: j } = _, { gen: D, compositeRule: b, allErrors: N } = j, A = h(_, g, O);
3654
- C ?? (b || N) ? p(D, A) : u(j, (0, t._)`[${A}]`);
3655
+ C ?? (b || N) ? d(D, A) : u(j, (0, t._)`[${A}]`);
3655
3656
  }
3656
3657
  e.reportError = s;
3657
3658
  function i(_, g = e.keywordError, O) {
3658
3659
  const { it: C } = _, { gen: j, compositeRule: D, allErrors: b } = C, N = h(_, g, O);
3659
- p(j, N), D || b || u(C, n.default.vErrors);
3660
+ d(j, N), D || b || u(C, n.default.vErrors);
3660
3661
  }
3661
3662
  e.reportExtraError = i;
3662
3663
  function o(_, g) {
@@ -3672,7 +3673,7 @@ Ge.default = vc;
3672
3673
  });
3673
3674
  }
3674
3675
  e.extendErrors = l;
3675
- function p(_, g) {
3676
+ function d(_, g) {
3676
3677
  const O = _.const("err", g);
3677
3678
  _.if((0, t._)`${n.default.vErrors} === null`, () => _.assign(n.default.vErrors, (0, t._)`[${O}]`), (0, t._)`${n.default.vErrors}.push(${O})`), _.code((0, t._)`${n.default.errors}++`);
3678
3679
  }
@@ -3680,7 +3681,7 @@ Ge.default = vc;
3680
3681
  const { gen: O, validateName: C, schemaEnv: j } = _;
3681
3682
  j.$async ? O.throw((0, t._)`new ${_.ValidationError}(${g})`) : (O.assign((0, t._)`${C}.errors`, g), O.return(!1));
3682
3683
  }
3683
- const d = {
3684
+ const p = {
3684
3685
  keyword: new t.Name("keyword"),
3685
3686
  schemaPath: new t.Name("schemaPath"),
3686
3687
  params: new t.Name("params"),
@@ -3706,11 +3707,11 @@ Ge.default = vc;
3706
3707
  }
3707
3708
  function v({ keyword: _, it: { errSchemaPath: g } }, { schemaPath: O, parentSchema: C }) {
3708
3709
  let j = C ? g : (0, t.str)`${g}/${_}`;
3709
- return O && (j = (0, t.str)`${j}${(0, r.getErrorPath)(O, r.Type.Str)}`), [d.schemaPath, j];
3710
+ return O && (j = (0, t.str)`${j}${(0, r.getErrorPath)(O, r.Type.Str)}`), [p.schemaPath, j];
3710
3711
  }
3711
3712
  function R(_, { params: g, message: O }, C) {
3712
3713
  const { keyword: j, data: D, schemaValue: b, it: N } = _, { opts: A, propertyName: W, topSchemaRef: G, schemaPath: ce } = N;
3713
- C.push([d.keyword, j], [d.params, typeof g == "function" ? g(_) : g || (0, t._)`{}`]), A.messages && C.push([d.message, typeof O == "function" ? O(_) : O]), A.verbose && C.push([d.schema, b], [d.parentSchema, (0, t._)`${G}${ce}`], [n.default.data, D]), W && C.push([d.propertyName, W]);
3714
+ C.push([p.keyword, j], [p.params, typeof g == "function" ? g(_) : g || (0, t._)`{}`]), A.messages && C.push([p.message, typeof O == "function" ? O(_) : O]), A.verbose && C.push([p.schema, b], [p.parentSchema, (0, t._)`${G}${ce}`], [n.default.data, D]), W && C.push([p.propertyName, W]);
3714
3715
  }
3715
3716
  })(br);
3716
3717
  Object.defineProperty(Kt, "__esModule", { value: !0 });
@@ -3790,7 +3791,7 @@ Qe.shouldUseRule = so;
3790
3791
  C[C.Correct = 0] = "Correct", C[C.Wrong = 1] = "Wrong";
3791
3792
  })(o = e.DataType || (e.DataType = {}));
3792
3793
  function l(C) {
3793
- const j = p(C.type);
3794
+ const j = d(C.type);
3794
3795
  if (j.includes("null")) {
3795
3796
  if (C.nullable === !1)
3796
3797
  throw new Error("type: null contradicts nullable: false");
@@ -3802,13 +3803,13 @@ Qe.shouldUseRule = so;
3802
3803
  return j;
3803
3804
  }
3804
3805
  e.getSchemaTypes = l;
3805
- function p(C) {
3806
+ function d(C) {
3806
3807
  const j = Array.isArray(C) ? C : C ? [C] : [];
3807
3808
  if (j.every(t.isJSONType))
3808
3809
  return j;
3809
3810
  throw new Error("type must be JSONType or JSONType[]: " + j.join(","));
3810
3811
  }
3811
- e.getJSONTypes = p;
3812
+ e.getJSONTypes = d;
3812
3813
  function u(C, j) {
3813
3814
  const { gen: D, data: b, opts: N } = C, A = h(j, N.coerceTypes), W = j.length > 0 && !(A.length === 0 && j.length === 1 && (0, r.schemaHasRulesForType)(C, j[0]));
3814
3815
  if (W) {
@@ -3820,15 +3821,15 @@ Qe.shouldUseRule = so;
3820
3821
  return W;
3821
3822
  }
3822
3823
  e.coerceAndCheckDataType = u;
3823
- const d = /* @__PURE__ */ new Set(["string", "number", "integer", "boolean", "null"]);
3824
+ const p = /* @__PURE__ */ new Set(["string", "number", "integer", "boolean", "null"]);
3824
3825
  function h(C, j) {
3825
- return j ? C.filter((D) => d.has(D) || j === "array" && D === "array") : [];
3826
+ return j ? C.filter((D) => p.has(D) || j === "array" && D === "array") : [];
3826
3827
  }
3827
3828
  function w(C, j, D) {
3828
3829
  const { gen: b, data: N, opts: A } = C, W = b.let("dataType", (0, s._)`typeof ${N}`), G = b.let("coerced", (0, s._)`undefined`);
3829
3830
  A.coerceTypes === "array" && b.if((0, s._)`${W} == 'object' && Array.isArray(${N}) && ${N}.length == 1`, () => b.assign(N, (0, s._)`${N}[0]`).assign(W, (0, s._)`typeof ${N}`).if(R(j, N, A.strictNumbers), () => b.assign(G, N))), b.if((0, s._)`${G} !== undefined`);
3830
3831
  for (const Z of D)
3831
- (d.has(Z) || Z === "array" && A.coerceTypes === "array") && ce(Z);
3832
+ (p.has(Z) || Z === "array" && A.coerceTypes === "array") && ce(Z);
3832
3833
  b.else(), g(C), b.endIf(), b.if((0, s._)`${G} !== undefined`, () => {
3833
3834
  b.assign(N, G), T(C, G);
3834
3835
  });
@@ -3949,8 +3950,8 @@ function ti(e, t, r) {
3949
3950
  (0, Ic.checkStrictMode)(e, `default is ignored for: ${l}`);
3950
3951
  return;
3951
3952
  }
3952
- let p = (0, Ft._)`${l} === undefined`;
3953
- o.useDefaults === "empty" && (p = (0, Ft._)`${p} || ${l} === null || ${l} === ""`), n.if(p, (0, Ft._)`${l} = ${(0, Ft.stringify)(r)}`);
3953
+ let d = (0, Ft._)`${l} === undefined`;
3954
+ o.useDefaults === "empty" && (d = (0, Ft._)`${d} || ${l} === null || ${l} === ""`), n.if(d, (0, Ft._)`${l} = ${(0, Ft.stringify)(r)}`);
3954
3955
  }
3955
3956
  var Ke = {}, B = {};
3956
3957
  Object.defineProperty(B, "__esModule", { value: !0 });
@@ -4001,16 +4002,16 @@ function Lc(e, t) {
4001
4002
  return oo(t).filter((r) => !(0, Wn.alwaysValidSchema)(e, t[r]));
4002
4003
  }
4003
4004
  B.schemaProperties = Lc;
4004
- function zc({ schemaCode: e, data: t, it: { gen: r, topSchemaRef: n, schemaPath: s, errorPath: i }, it: o }, l, p, u) {
4005
- const d = u ? (0, ie._)`${e}, ${t}, ${n}${s}` : t, h = [
4005
+ function zc({ schemaCode: e, data: t, it: { gen: r, topSchemaRef: n, schemaPath: s, errorPath: i }, it: o }, l, d, u) {
4006
+ const p = u ? (0, ie._)`${e}, ${t}, ${n}${s}` : t, h = [
4006
4007
  [tt.default.instancePath, (0, ie.strConcat)(tt.default.instancePath, i)],
4007
4008
  [tt.default.parentData, o.parentData],
4008
4009
  [tt.default.parentDataProperty, o.parentDataProperty],
4009
4010
  [tt.default.rootData, tt.default.rootData]
4010
4011
  ];
4011
4012
  o.opts.dynamicRef && h.push([tt.default.dynamicAnchors, tt.default.dynamicAnchors]);
4012
- const w = (0, ie._)`${d}, ${r.object(...h)}`;
4013
- return p !== ie.nil ? (0, ie._)`${l}.call(${p}, ${w})` : (0, ie._)`${l}(${w})`;
4013
+ const w = (0, ie._)`${p}, ${r.object(...h)}`;
4014
+ return d !== ie.nil ? (0, ie._)`${l}.call(${d}, ${w})` : (0, ie._)`${l}(${w})`;
4014
4015
  }
4015
4016
  B.callValidateCode = zc;
4016
4017
  const Hc = (0, ie._)`new RegExp`;
@@ -4031,8 +4032,8 @@ function Wc(e) {
4031
4032
  }
4032
4033
  return t.var(i, !0), o(() => t.break()), i;
4033
4034
  function o(l) {
4034
- const p = t.const("len", (0, ie._)`${r}.length`);
4035
- t.forRange("i", 0, p, (u) => {
4035
+ const d = t.const("len", (0, ie._)`${r}.length`);
4036
+ t.forRange("i", 0, d, (u) => {
4036
4037
  e.subschema({
4037
4038
  keyword: n,
4038
4039
  dataProp: u,
@@ -4046,16 +4047,16 @@ function xc(e) {
4046
4047
  const { gen: t, schema: r, keyword: n, it: s } = e;
4047
4048
  if (!Array.isArray(r))
4048
4049
  throw new Error("ajv implementation error");
4049
- if (r.some((p) => (0, Wn.alwaysValidSchema)(s, p)) && !s.opts.unevaluated)
4050
+ if (r.some((d) => (0, Wn.alwaysValidSchema)(s, d)) && !s.opts.unevaluated)
4050
4051
  return;
4051
4052
  const o = t.let("valid", !1), l = t.name("_valid");
4052
- t.block(() => r.forEach((p, u) => {
4053
- const d = e.subschema({
4053
+ t.block(() => r.forEach((d, u) => {
4054
+ const p = e.subschema({
4054
4055
  keyword: n,
4055
4056
  schemaProp: u,
4056
4057
  compositeRule: !0
4057
4058
  }, l);
4058
- t.assign(o, (0, ie._)`${o} || ${l}`), e.mergeValidEvaluated(d, l) || t.if((0, ie.not)(o));
4059
+ t.assign(o, (0, ie._)`${o} || ${l}`), e.mergeValidEvaluated(p, l) || t.if((0, ie.not)(o));
4059
4060
  })), e.result(o, () => e.reset(), () => e.error(!0));
4060
4061
  }
4061
4062
  B.validateUnion = xc;
@@ -4063,23 +4064,23 @@ Object.defineProperty(Ke, "__esModule", { value: !0 });
4063
4064
  Ke.validateKeywordUsage = Ke.validSchemaType = Ke.funcKeywordCode = Ke.macroKeywordCode = void 0;
4064
4065
  const be = K, ht = Ge, Bc = B, Kc = br;
4065
4066
  function Gc(e, t) {
4066
- const { gen: r, keyword: n, schema: s, parentSchema: i, it: o } = e, l = t.macro.call(o.self, s, i, o), p = ao(r, n, l);
4067
+ const { gen: r, keyword: n, schema: s, parentSchema: i, it: o } = e, l = t.macro.call(o.self, s, i, o), d = ao(r, n, l);
4067
4068
  o.opts.validateSchema !== !1 && o.self.validateSchema(l, !0);
4068
4069
  const u = r.name("valid");
4069
4070
  e.subschema({
4070
4071
  schema: l,
4071
4072
  schemaPath: be.nil,
4072
4073
  errSchemaPath: `${o.errSchemaPath}/${n}`,
4073
- topSchemaRef: p,
4074
+ topSchemaRef: d,
4074
4075
  compositeRule: !0
4075
4076
  }, u), e.pass(u, () => e.error(!0));
4076
4077
  }
4077
4078
  Ke.macroKeywordCode = Gc;
4078
4079
  function Jc(e, t) {
4079
4080
  var r;
4080
- const { gen: n, keyword: s, schema: i, parentSchema: o, $data: l, it: p } = e;
4081
- Qc(p, t);
4082
- const u = !l && t.compile ? t.compile.call(p.self, i, o, p) : t.validate, d = ao(n, s, u), h = n.let("valid");
4081
+ const { gen: n, keyword: s, schema: i, parentSchema: o, $data: l, it: d } = e;
4082
+ Qc(d, t);
4083
+ const u = !l && t.compile ? t.compile.call(d.self, i, o, d) : t.validate, p = ao(n, s, u), h = n.let("valid");
4083
4084
  e.block$data(h, w), e.ok((r = t.valid) !== null && r !== void 0 ? r : h);
4084
4085
  function w() {
4085
4086
  if (t.errors === !1)
@@ -4091,15 +4092,15 @@ function Jc(e, t) {
4091
4092
  }
4092
4093
  function T() {
4093
4094
  const g = n.let("ruleErrs", null);
4094
- return n.try(() => R((0, be._)`await `), (O) => n.assign(h, !1).if((0, be._)`${O} instanceof ${p.ValidationError}`, () => n.assign(g, (0, be._)`${O}.errors`), () => n.throw(O))), g;
4095
+ return n.try(() => R((0, be._)`await `), (O) => n.assign(h, !1).if((0, be._)`${O} instanceof ${d.ValidationError}`, () => n.assign(g, (0, be._)`${O}.errors`), () => n.throw(O))), g;
4095
4096
  }
4096
4097
  function v() {
4097
- const g = (0, be._)`${d}.errors`;
4098
+ const g = (0, be._)`${p}.errors`;
4098
4099
  return n.assign(g, null), R(be.nil), g;
4099
4100
  }
4100
4101
  function R(g = t.async ? (0, be._)`await ` : be.nil) {
4101
- const O = p.opts.passContext ? ht.default.this : ht.default.self, C = !("compile" in t && !l || t.schema === !1);
4102
- n.assign(h, (0, be._)`${g}${(0, Bc.callValidateCode)(e, d, O, C)}`, t.modifying);
4102
+ const O = d.opts.passContext ? ht.default.this : ht.default.self, C = !("compile" in t && !l || t.schema === !1);
4103
+ n.assign(h, (0, be._)`${g}${(0, Bc.callValidateCode)(e, p, O, C)}`, t.modifying);
4103
4104
  }
4104
4105
  function _(g) {
4105
4106
  var O;
@@ -4137,11 +4138,11 @@ function Xc({ schema: e, opts: t, self: r, errSchemaPath: n }, s, i) {
4137
4138
  if (o != null && o.some((l) => !Object.prototype.hasOwnProperty.call(e, l)))
4138
4139
  throw new Error(`parent schema must have dependencies of ${i}: ${o.join(",")}`);
4139
4140
  if (s.validateSchema && !s.validateSchema(e[i])) {
4140
- const p = `keyword "${i}" value is invalid at path "${n}": ` + r.errorsText(s.validateSchema.errors);
4141
+ const d = `keyword "${i}" value is invalid at path "${n}": ` + r.errorsText(s.validateSchema.errors);
4141
4142
  if (t.validateSchema === "log")
4142
- r.logger.error(p);
4143
+ r.logger.error(d);
4143
4144
  else
4144
- throw new Error(p);
4145
+ throw new Error(d);
4145
4146
  }
4146
4147
  }
4147
4148
  Ke.validateKeywordUsage = Xc;
@@ -4182,15 +4183,15 @@ function tl(e, t, { dataProp: r, dataPropType: n, data: s, dataTypes: i, propert
4182
4183
  throw new Error('both "data" and "dataProp" passed, only one allowed');
4183
4184
  const { gen: l } = t;
4184
4185
  if (r !== void 0) {
4185
- const { errorPath: u, dataPathArr: d, opts: h } = t, w = l.let("data", (0, Be._)`${t.data}${(0, Be.getProperty)(r)}`, !0);
4186
- p(w), e.errorPath = (0, Be.str)`${u}${(0, co.getErrorPath)(r, n, h.jsPropertySyntax)}`, e.parentDataProperty = (0, Be._)`${r}`, e.dataPathArr = [...d, e.parentDataProperty];
4186
+ const { errorPath: u, dataPathArr: p, opts: h } = t, w = l.let("data", (0, Be._)`${t.data}${(0, Be.getProperty)(r)}`, !0);
4187
+ d(w), e.errorPath = (0, Be.str)`${u}${(0, co.getErrorPath)(r, n, h.jsPropertySyntax)}`, e.parentDataProperty = (0, Be._)`${r}`, e.dataPathArr = [...p, e.parentDataProperty];
4187
4188
  }
4188
4189
  if (s !== void 0) {
4189
4190
  const u = s instanceof Be.Name ? s : l.let("data", s, !0);
4190
- p(u), o !== void 0 && (e.propertyName = o);
4191
+ d(u), o !== void 0 && (e.propertyName = o);
4191
4192
  }
4192
4193
  i && (e.dataTypes = i);
4193
- function p(u) {
4194
+ function d(u) {
4194
4195
  e.data = u, e.dataLevel = t.dataLevel + 1, e.dataTypes = [], t.definedProperties = /* @__PURE__ */ new Set(), e.parentData = t.data, e.dataNames = [...t.dataNames, u];
4195
4196
  }
4196
4197
  }
@@ -4199,7 +4200,7 @@ function rl(e, { jtdDiscriminator: t, jtdMetadata: r, compositeRule: n, createEr
4199
4200
  n !== void 0 && (e.compositeRule = n), s !== void 0 && (e.createErrors = s), i !== void 0 && (e.allErrors = i), e.jtdDiscriminator = t, e.jtdMetadata = r;
4200
4201
  }
4201
4202
  ot.extendSubschemaMode = rl;
4202
- var ge = {}, lo = function e(t, r) {
4203
+ var $e = {}, lo = function e(t, r) {
4203
4204
  if (t === r)
4204
4205
  return !0;
4205
4206
  if (t && r && typeof t == "object" && typeof r == "object") {
@@ -4284,31 +4285,31 @@ it.skipKeywords = {
4284
4285
  maxProperties: !0,
4285
4286
  minProperties: !0
4286
4287
  };
4287
- function Mr(e, t, r, n, s, i, o, l, p, u) {
4288
+ function Mr(e, t, r, n, s, i, o, l, d, u) {
4288
4289
  if (n && typeof n == "object" && !Array.isArray(n)) {
4289
- t(n, s, i, o, l, p, u);
4290
- for (var d in n) {
4291
- var h = n[d];
4290
+ t(n, s, i, o, l, d, u);
4291
+ for (var p in n) {
4292
+ var h = n[p];
4292
4293
  if (Array.isArray(h)) {
4293
- if (d in it.arrayKeywords)
4294
+ if (p in it.arrayKeywords)
4294
4295
  for (var w = 0; w < h.length; w++)
4295
- Mr(e, t, r, h[w], s + "/" + d + "/" + w, i, s, d, n, w);
4296
- } else if (d in it.propsKeywords) {
4296
+ Mr(e, t, r, h[w], s + "/" + p + "/" + w, i, s, p, n, w);
4297
+ } else if (p in it.propsKeywords) {
4297
4298
  if (h && typeof h == "object")
4298
4299
  for (var T in h)
4299
- Mr(e, t, r, h[T], s + "/" + d + "/" + nl(T), i, s, d, n, T);
4300
+ Mr(e, t, r, h[T], s + "/" + p + "/" + nl(T), i, s, p, n, T);
4300
4301
  } else
4301
- (d in it.keywords || e.allKeys && !(d in it.skipKeywords)) && Mr(e, t, r, h, s + "/" + d, i, s, d, n);
4302
+ (p in it.keywords || e.allKeys && !(p in it.skipKeywords)) && Mr(e, t, r, h, s + "/" + p, i, s, p, n);
4302
4303
  }
4303
- r(n, s, i, o, l, p, u);
4304
+ r(n, s, i, o, l, d, u);
4304
4305
  }
4305
4306
  }
4306
4307
  function nl(e) {
4307
4308
  return e.replace(/~/g, "~0").replace(/\//g, "~1");
4308
4309
  }
4309
4310
  var sl = uo.exports;
4310
- Object.defineProperty(ge, "__esModule", { value: !0 });
4311
- ge.getSchemaRefs = ge.resolveUrl = ge.normalizeId = ge._getFullPath = ge.getFullPath = ge.inlineRef = void 0;
4311
+ Object.defineProperty($e, "__esModule", { value: !0 });
4312
+ $e.getSchemaRefs = $e.resolveUrl = $e.normalizeId = $e._getFullPath = $e.getFullPath = $e.inlineRef = void 0;
4312
4313
  const il = re, ol = lo, al = sl, cl = /* @__PURE__ */ new Set([
4313
4314
  "type",
4314
4315
  "format",
@@ -4330,7 +4331,7 @@ const il = re, ol = lo, al = sl, cl = /* @__PURE__ */ new Set([
4330
4331
  function ll(e, t = !0) {
4331
4332
  return typeof e == "boolean" ? !0 : t === !0 ? !jn(e) : t ? po(e) <= t : !1;
4332
4333
  }
4333
- ge.inlineRef = ll;
4334
+ $e.inlineRef = ll;
4334
4335
  const ul = /* @__PURE__ */ new Set([
4335
4336
  "$ref",
4336
4337
  "$recursiveRef",
@@ -4363,25 +4364,25 @@ function fo(e, t = "", r) {
4363
4364
  const n = e.parse(t);
4364
4365
  return ho(e, n);
4365
4366
  }
4366
- ge.getFullPath = fo;
4367
+ $e.getFullPath = fo;
4367
4368
  function ho(e, t) {
4368
4369
  return e.serialize(t).split("#")[0] + "#";
4369
4370
  }
4370
- ge._getFullPath = ho;
4371
+ $e._getFullPath = ho;
4371
4372
  const dl = /#\/?$/;
4372
4373
  function Lt(e) {
4373
4374
  return e ? e.replace(dl, "") : "";
4374
4375
  }
4375
- ge.normalizeId = Lt;
4376
+ $e.normalizeId = Lt;
4376
4377
  function pl(e, t, r) {
4377
4378
  return r = Lt(r), e.resolve(t, r);
4378
4379
  }
4379
- ge.resolveUrl = pl;
4380
+ $e.resolveUrl = pl;
4380
4381
  const fl = /^[a-z_][-a-z0-9._]*$/i;
4381
4382
  function hl(e, t) {
4382
4383
  if (typeof e == "boolean")
4383
4384
  return {};
4384
- const { schemaId: r, uriResolver: n } = this.opts, s = Lt(e[r] || t), i = { "": s }, o = fo(n, s, !1), l = {}, p = /* @__PURE__ */ new Set();
4385
+ const { schemaId: r, uriResolver: n } = this.opts, s = Lt(e[r] || t), i = { "": s }, o = fo(n, s, !1), l = {}, d = /* @__PURE__ */ new Set();
4385
4386
  return al(e, { allKeys: !0 }, (h, w, T, v) => {
4386
4387
  if (v === void 0)
4387
4388
  return;
@@ -4390,9 +4391,9 @@ function hl(e, t) {
4390
4391
  typeof h[r] == "string" && (_ = g.call(this, h[r])), O.call(this, h.$anchor), O.call(this, h.$dynamicAnchor), i[w] = _;
4391
4392
  function g(C) {
4392
4393
  const j = this.opts.uriResolver.resolve;
4393
- if (C = Lt(_ ? j(_, C) : C), p.has(C))
4394
- throw d(C);
4395
- p.add(C);
4394
+ if (C = Lt(_ ? j(_, C) : C), d.has(C))
4395
+ throw p(C);
4396
+ d.add(C);
4396
4397
  let D = this.refs[C];
4397
4398
  return typeof D == "string" && (D = this.refs[D]), typeof D == "object" ? u(h, D.schema, C) : C !== Lt(R) && (C[0] === "#" ? (u(h, l[C], C), l[C] = h) : this.refs[C] = R), C;
4398
4399
  }
@@ -4406,16 +4407,16 @@ function hl(e, t) {
4406
4407
  }), l;
4407
4408
  function u(h, w, T) {
4408
4409
  if (w !== void 0 && !ol(h, w))
4409
- throw d(T);
4410
+ throw p(T);
4410
4411
  }
4411
- function d(h) {
4412
+ function p(h) {
4412
4413
  return new Error(`reference "${h}" resolves to more than one schema`);
4413
4414
  }
4414
4415
  }
4415
- ge.getSchemaRefs = hl;
4416
+ $e.getSchemaRefs = hl;
4416
4417
  Object.defineProperty(Ae, "__esModule", { value: !0 });
4417
4418
  Ae.getData = Ae.KeywordCxt = Ae.validateFunctionCode = void 0;
4418
- const mo = Kt, ni = Pr, Kn = Qe, Wr = Pr, ml = yn, pr = Ke, Pn = ot, U = K, V = Ge, yl = ge, Ze = re, ar = br;
4419
+ const mo = Kt, ni = Pr, Kn = Qe, Wr = Pr, ml = yn, pr = Ke, Pn = ot, U = K, V = Ge, yl = $e, Ze = re, ar = br;
4419
4420
  function gl(e) {
4420
4421
  if ($o(e) && (_o(e), go(e))) {
4421
4422
  wl(e);
@@ -4519,18 +4520,18 @@ function Cl({ gen: e, evaluated: t, props: r, items: n }) {
4519
4520
  r instanceof U.Name && e.assign((0, U._)`${t}.props`, r), n instanceof U.Name && e.assign((0, U._)`${t}.items`, n);
4520
4521
  }
4521
4522
  function ii(e, t, r, n) {
4522
- const { gen: s, schema: i, data: o, allErrors: l, opts: p, self: u } = e, { RULES: d } = u;
4523
- if (i.$ref && (p.ignoreKeywordsWithRef || !(0, Ze.schemaHasRulesButRef)(i, d))) {
4524
- s.block(() => Eo(e, "$ref", d.all.$ref.definition));
4523
+ const { gen: s, schema: i, data: o, allErrors: l, opts: d, self: u } = e, { RULES: p } = u;
4524
+ if (i.$ref && (d.ignoreKeywordsWithRef || !(0, Ze.schemaHasRulesButRef)(i, p))) {
4525
+ s.block(() => Eo(e, "$ref", p.all.$ref.definition));
4525
4526
  return;
4526
4527
  }
4527
- p.jtd || Nl(e, t), s.block(() => {
4528
- for (const w of d.rules)
4528
+ d.jtd || Nl(e, t), s.block(() => {
4529
+ for (const w of p.rules)
4529
4530
  h(w);
4530
- h(d.post);
4531
+ h(p.post);
4531
4532
  });
4532
4533
  function h(w) {
4533
- (0, Kn.shouldUseGroup)(i, w) && (w.type ? (s.if((0, Wr.checkDataType)(w.type, o, p.strictNumbers)), oi(e, w), t.length === 1 && t[0] === w.type && r && (s.else(), (0, Wr.reportTypeError)(e)), s.endIf()) : oi(e, w), l || s.if((0, U._)`${V.default.errors} === ${n || 0}`));
4534
+ (0, Kn.shouldUseGroup)(i, w) && (w.type ? (s.if((0, Wr.checkDataType)(w.type, o, d.strictNumbers)), oi(e, w), t.length === 1 && t[0] === w.type && r && (s.else(), (0, Wr.reportTypeError)(e)), s.endIf()) : oi(e, w), l || s.if((0, U._)`${V.default.errors} === ${n || 0}`));
4534
4535
  }
4535
4536
  }
4536
4537
  function oi(e, t) {
@@ -4655,15 +4656,15 @@ class Po {
4655
4656
  if (n.length) {
4656
4657
  if (!(r instanceof U.Name))
4657
4658
  throw new Error("ajv implementation error");
4658
- const p = Array.isArray(n) ? n : [n];
4659
- return (0, U._)`${(0, Wr.checkDataTypes)(p, r, i.opts.strictNumbers, Wr.DataType.Wrong)}`;
4659
+ const d = Array.isArray(n) ? n : [n];
4660
+ return (0, U._)`${(0, Wr.checkDataTypes)(d, r, i.opts.strictNumbers, Wr.DataType.Wrong)}`;
4660
4661
  }
4661
4662
  return U.nil;
4662
4663
  }
4663
4664
  function l() {
4664
4665
  if (s.validateSchema) {
4665
- const p = t.scopeValue("validate$data", { ref: s.validateSchema });
4666
- return (0, U._)`!${p}(${r})`;
4666
+ const d = t.scopeValue("validate$data", { ref: s.validateSchema });
4667
+ return (0, U._)`!${d}(${r})`;
4667
4668
  }
4668
4669
  return U.nil;
4669
4670
  }
@@ -4702,15 +4703,15 @@ function So(e, { dataLevel: t, dataNames: r, dataPathArr: n }) {
4702
4703
  const u = ql.exec(e);
4703
4704
  if (!u)
4704
4705
  throw new Error(`Invalid JSON-pointer: ${e}`);
4705
- const d = +u[1];
4706
+ const p = +u[1];
4706
4707
  if (s = u[2], s === "#") {
4707
- if (d >= t)
4708
- throw new Error(p("property/index", d));
4709
- return n[t - d];
4708
+ if (p >= t)
4709
+ throw new Error(d("property/index", p));
4710
+ return n[t - p];
4710
4711
  }
4711
- if (d > t)
4712
- throw new Error(p("data", d));
4713
- if (i = r[t - d], !s)
4712
+ if (p > t)
4713
+ throw new Error(d("data", p));
4714
+ if (i = r[t - p], !s)
4714
4715
  return i;
4715
4716
  }
4716
4717
  let o = i;
@@ -4718,8 +4719,8 @@ function So(e, { dataLevel: t, dataNames: r, dataPathArr: n }) {
4718
4719
  for (const u of l)
4719
4720
  u && (i = (0, U._)`${i}${(0, U.getProperty)((0, Ze.unescapeJsonPointer)(u))}`, o = (0, U._)`${o} && ${i}`);
4720
4721
  return o;
4721
- function p(u, d) {
4722
- return `Cannot access ${u} ${d} levels up, current level is ${t}`;
4722
+ function d(u, p) {
4723
+ return `Cannot access ${u} ${p} levels up, current level is ${t}`;
4723
4724
  }
4724
4725
  }
4725
4726
  Ae.getData = So;
@@ -4733,7 +4734,7 @@ class Ml extends Error {
4733
4734
  Er.default = Ml;
4734
4735
  var Sr = {};
4735
4736
  Object.defineProperty(Sr, "__esModule", { value: !0 });
4736
- const En = ge;
4737
+ const En = $e;
4737
4738
  class Ul extends Error {
4738
4739
  constructor(t, r, n, s) {
4739
4740
  super(s || `can't resolve reference ${n} from id ${r}`), this.missingRef = (0, En.resolveUrl)(t, r, n), this.missingSchema = (0, En.normalizeId)((0, En.getFullPath)(t, this.missingRef));
@@ -4743,7 +4744,7 @@ Sr.default = Ul;
4743
4744
  var Se = {};
4744
4745
  Object.defineProperty(Se, "__esModule", { value: !0 });
4745
4746
  Se.resolveSchema = Se.getCompilingSchema = Se.resolveRef = Se.compileSchema = Se.SchemaEnv = void 0;
4746
- const ke = K, Ll = Er, ft = Ge, Ie = ge, ai = re, zl = Ae;
4747
+ const ke = K, Ll = Er, ft = Ge, Ie = $e, ai = re, zl = Ae;
4747
4748
  class gn {
4748
4749
  constructor(t) {
4749
4750
  var r;
@@ -4763,8 +4764,8 @@ function Jn(e) {
4763
4764
  ref: Ll.default,
4764
4765
  code: (0, ke._)`require("ajv/dist/runtime/validation_error").default`
4765
4766
  }));
4766
- const p = o.scopeName("validate");
4767
- e.validateName = p;
4767
+ const d = o.scopeName("validate");
4768
+ e.validateName = d;
4768
4769
  const u = {
4769
4770
  gen: o,
4770
4771
  allErrors: this.opts.allErrors,
@@ -4777,7 +4778,7 @@ function Jn(e) {
4777
4778
  dataTypes: [],
4778
4779
  definedProperties: /* @__PURE__ */ new Set(),
4779
4780
  topSchemaRef: o.scopeValue("schema", this.opts.code.source === !0 ? { ref: e.schema, code: (0, ke.stringify)(e.schema) } : { ref: e.schema }),
4780
- validateName: p,
4781
+ validateName: d,
4781
4782
  ValidationError: l,
4782
4783
  schema: e.schema,
4783
4784
  schemaEnv: e,
@@ -4789,13 +4790,13 @@ function Jn(e) {
4789
4790
  opts: this.opts,
4790
4791
  self: this
4791
4792
  };
4792
- let d;
4793
+ let p;
4793
4794
  try {
4794
4795
  this._compilations.add(e), (0, zl.validateFunctionCode)(u), o.optimize(this.opts.code.optimize);
4795
4796
  const h = o.toString();
4796
- d = `${o.scopeRefs(ft.default.scope)}return ${h}`, this.opts.code.process && (d = this.opts.code.process(d, e));
4797
- const T = new Function(`${ft.default.self}`, `${ft.default.scope}`, d)(this, this.scope.get());
4798
- if (this.scope.value(p, { ref: T }), T.errors = null, T.schema = e.schema, T.schemaEnv = e, e.$async && (T.$async = !0), this.opts.code.source === !0 && (T.source = { validateName: p, validateCode: h, scopeValues: o._values }), this.opts.unevaluated) {
4797
+ p = `${o.scopeRefs(ft.default.scope)}return ${h}`, this.opts.code.process && (p = this.opts.code.process(p, e));
4798
+ const T = new Function(`${ft.default.self}`, `${ft.default.scope}`, p)(this, this.scope.get());
4799
+ if (this.scope.value(d, { ref: T }), T.errors = null, T.schema = e.schema, T.schemaEnv = e, e.$async && (T.$async = !0), this.opts.code.source === !0 && (T.source = { validateName: d, validateCode: h, scopeValues: o._values }), this.opts.unevaluated) {
4799
4800
  const { props: v, items: R } = u;
4800
4801
  T.evaluated = {
4801
4802
  props: v instanceof ke.Name ? void 0 : v,
@@ -4806,7 +4807,7 @@ function Jn(e) {
4806
4807
  }
4807
4808
  return e.validate = T, e;
4808
4809
  } catch (h) {
4809
- throw delete e.validate, delete e.validateName, d && this.logger.error("Error compiling schema, function code:", d), h;
4810
+ throw delete e.validate, delete e.validateName, p && this.logger.error("Error compiling schema, function code:", p), h;
4810
4811
  } finally {
4811
4812
  this._compilations.delete(e);
4812
4813
  }
@@ -4857,8 +4858,8 @@ function $n(e, t) {
4857
4858
  }
4858
4859
  if (typeof (o == null ? void 0 : o.schema) == "object") {
4859
4860
  if (o.validate || Jn.call(this, o), i === (0, Ie.normalizeId)(t)) {
4860
- const { schema: l } = o, { schemaId: p } = this.opts, u = l[p];
4861
- return u && (s = (0, Ie.resolveUrl)(this.opts.uriResolver, s, u)), new gn({ schema: l, schemaId: p, root: e, baseId: s });
4861
+ const { schema: l } = o, { schemaId: d } = this.opts, u = l[d];
4862
+ return u && (s = (0, Ie.resolveUrl)(this.opts.uriResolver, s, u)), new gn({ schema: l, schemaId: d, root: e, baseId: s });
4862
4863
  }
4863
4864
  return Sn.call(this, r, o);
4864
4865
  }
@@ -4878,10 +4879,10 @@ function Sn(e, { baseId: t, schema: r, root: n }) {
4878
4879
  for (const l of e.fragment.slice(1).split("/")) {
4879
4880
  if (typeof r == "boolean")
4880
4881
  return;
4881
- const p = r[(0, ai.unescapeFragment)(l)];
4882
- if (p === void 0)
4882
+ const d = r[(0, ai.unescapeFragment)(l)];
4883
+ if (d === void 0)
4883
4884
  return;
4884
- r = p;
4885
+ r = d;
4885
4886
  const u = typeof r == "object" && r[this.opts.schemaId];
4886
4887
  !Bl.has(l) && u && (t = (0, Ie.resolveUrl)(this.opts.uriResolver, t, u));
4887
4888
  }
@@ -4945,7 +4946,7 @@ var Yn = {}, In = { exports: {} };
4945
4946
  function l(f) {
4946
4947
  return f != null ? f instanceof Array ? f : typeof f.length != "number" || f.split || f.setInterval || f.call ? [f] : Array.prototype.slice.call(f) : [];
4947
4948
  }
4948
- function p(f, c) {
4949
+ function d(f, c) {
4949
4950
  var y = f;
4950
4951
  if (c)
4951
4952
  for (var S in c)
@@ -4975,7 +4976,7 @@ var Yn = {}, In = { exports: {} };
4975
4976
  //RFC 6874, with relaxed parsing rules
4976
4977
  };
4977
4978
  }
4978
- var d = u(!1), h = u(!0), w = function() {
4979
+ var p = u(!1), h = u(!0), w = function() {
4979
4980
  function f(c, y) {
4980
4981
  var S = [], E = !0, L = !1, z = void 0;
4981
4982
  try {
@@ -5249,7 +5250,7 @@ var Yn = {}, In = { exports: {} };
5249
5250
  }
5250
5251
  var Zt = /^(?:([^:\/?#]+):)?(?:\/\/((?:([^\/?#@]*)@)?(\[[^\/?#\]]+\]|[^\/?#:]*)(?:\:(\d*))?))?([^?#]*)(?:\?([^#]*))?(?:#((?:.|\n|\r)*))?/i, Xt = "".match(/(){0}/)[1] === void 0;
5251
5252
  function Te(f) {
5252
- var c = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, y = {}, S = c.iri !== !1 ? h : d;
5253
+ var c = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, y = {}, S = c.iri !== !1 ? h : p;
5253
5254
  c.reference === "suffix" && (f = (c.scheme ? c.scheme + ":" : "") + "//" + f);
5254
5255
  var E = f.match(Zt);
5255
5256
  if (E) {
@@ -5262,7 +5263,7 @@ var Yn = {}, In = { exports: {} };
5262
5263
  } catch (z) {
5263
5264
  y.error = y.error || "Host's domain name can not be converted to ASCII via punycode: " + z;
5264
5265
  }
5265
- Q(y, d);
5266
+ Q(y, p);
5266
5267
  } else
5267
5268
  Q(y, S);
5268
5269
  L && L.parse && L.parse(y, c);
@@ -5271,7 +5272,7 @@ var Yn = {}, In = { exports: {} };
5271
5272
  return y;
5272
5273
  }
5273
5274
  function er(f, c) {
5274
- var y = c.iri !== !1 ? h : d, S = [];
5275
+ var y = c.iri !== !1 ? h : p, S = [];
5275
5276
  return f.userinfo !== void 0 && (S.push(f.userinfo), S.push("@")), f.host !== void 0 && S.push(Ot(Me(String(f.host), y), y).replace(y.IPV6ADDRESS, function(E, L, z) {
5276
5277
  return "[" + L + (z ? "%25" + z : "") + "]";
5277
5278
  })), (typeof f.port == "number" || typeof f.port == "string") && (S.push(":"), S.push(String(f.port))), S.length ? S.join("") : void 0;
@@ -5298,7 +5299,7 @@ var Yn = {}, In = { exports: {} };
5298
5299
  return c.join("");
5299
5300
  }
5300
5301
  function Pe(f) {
5301
- var c = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, y = c.iri ? h : d, S = [], E = q[(c.scheme || f.scheme || "").toLowerCase()];
5302
+ var c = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, y = c.iri ? h : p, S = [], E = q[(c.scheme || f.scheme || "").toLowerCase()];
5302
5303
  if (E && E.serialize && E.serialize(f, c), f.host && !y.IPV6ADDRESS.test(f.host)) {
5303
5304
  if (c.domainHost || E && E.domainHost)
5304
5305
  try {
@@ -5320,7 +5321,7 @@ var Yn = {}, In = { exports: {} };
5320
5321
  return S || (f = Te(Pe(f, y), y), c = Te(Pe(c, y), y)), y = y || {}, !y.tolerant && c.scheme ? (E.scheme = c.scheme, E.userinfo = c.userinfo, E.host = c.host, E.port = c.port, E.path = Ue(c.path || ""), E.query = c.query) : (c.userinfo !== void 0 || c.host !== void 0 || c.port !== void 0 ? (E.userinfo = c.userinfo, E.host = c.host, E.port = c.port, E.path = Ue(c.path || ""), E.query = c.query) : (c.path ? (c.path.charAt(0) === "/" ? E.path = Ue(c.path) : ((f.userinfo !== void 0 || f.host !== void 0 || f.port !== void 0) && !f.path ? E.path = "/" + c.path : f.path ? E.path = f.path.slice(0, f.path.lastIndexOf("/") + 1) + c.path : E.path = c.path, E.path = Ue(E.path)), E.query = c.query) : (E.path = f.path, c.query !== void 0 ? E.query = c.query : E.query = f.query), E.userinfo = f.userinfo, E.host = f.host, E.port = f.port), E.scheme = f.scheme), E.fragment = c.fragment, E;
5321
5322
  }
5322
5323
  function rr(f, c, y) {
5323
- var S = p({ scheme: "null" }, y);
5324
+ var S = d({ scheme: "null" }, y);
5324
5325
  return Pe(jt(Te(f, S), Te(c, S), S, !0), S);
5325
5326
  }
5326
5327
  function lt(f, c) {
@@ -5330,10 +5331,10 @@ var Yn = {}, In = { exports: {} };
5330
5331
  return typeof f == "string" ? f = Pe(Te(f, y), y) : i(f) === "object" && (f = Pe(f, y)), typeof c == "string" ? c = Pe(Te(c, y), y) : i(c) === "object" && (c = Pe(c, y)), f === c;
5331
5332
  }
5332
5333
  function Rr(f, c) {
5333
- return f && f.toString().replace(!c || !c.iri ? d.ESCAPE : h.ESCAPE, M);
5334
+ return f && f.toString().replace(!c || !c.iri ? p.ESCAPE : h.ESCAPE, M);
5334
5335
  }
5335
5336
  function Oe(f, c) {
5336
- return f && f.toString().replace(!c || !c.iri ? d.PCT_ENCODED : h.PCT_ENCODED, J);
5337
+ return f && f.toString().replace(!c || !c.iri ? p.PCT_ENCODED : h.PCT_ENCODED, J);
5337
5338
  }
5338
5339
  var ut = {
5339
5340
  scheme: "http",
@@ -5495,7 +5496,7 @@ Yn.default = Ro;
5495
5496
  } }), Object.defineProperty(e, "CodeGen", { enumerable: !0, get: function() {
5496
5497
  return r.CodeGen;
5497
5498
  } });
5498
- const n = Er, s = Sr, i = Pt, o = Se, l = K, p = ge, u = Pr, d = re, h = Xl, w = Yn, T = (F, $) => new RegExp(F, $);
5499
+ const n = Er, s = Sr, i = Pt, o = Se, l = K, d = $e, u = Pr, p = re, h = Xl, w = Yn, T = (F, $) => new RegExp(F, $);
5499
5500
  T.code = "new RegExp";
5500
5501
  const v = ["removeAdditional", "useDefaults", "coerceTypes"], R = /* @__PURE__ */ new Set([
5501
5502
  "validate",
@@ -5644,7 +5645,7 @@ Yn.default = Ro;
5644
5645
  if (m = $[k], m !== void 0 && typeof m != "string")
5645
5646
  throw new Error(`schema ${k} must be string`);
5646
5647
  }
5647
- return I = (0, p.normalizeId)(I || m), this._checkUnique(I), this.schemas[I] = this._addSchema($, P, I, a, !0), this;
5648
+ return I = (0, d.normalizeId)(I || m), this._checkUnique(I), this.schemas[I] = this._addSchema($, P, I, a, !0), this;
5648
5649
  }
5649
5650
  // Add schema that will be used to validate other schemas
5650
5651
  // options in META_IGNORE_OPTIONS are alway set to false
@@ -5702,7 +5703,7 @@ Yn.default = Ro;
5702
5703
  const I = $;
5703
5704
  this._cache.delete(I);
5704
5705
  let P = $[this.opts.schemaId];
5705
- return P && (P = (0, p.normalizeId)(P), delete this.schemas[P], delete this.refs[P]), this;
5706
+ return P && (P = (0, d.normalizeId)(P), delete this.schemas[P], delete this.refs[P]), this;
5706
5707
  }
5707
5708
  default:
5708
5709
  throw new Error("ajv.removeSchema: invalid parameter");
@@ -5724,14 +5725,14 @@ Yn.default = Ro;
5724
5725
  } else
5725
5726
  throw new Error("invalid addKeywords parameters");
5726
5727
  if (he.call(this, P, I), !I)
5727
- return (0, d.eachItem)(P, (m) => at.call(this, m)), this;
5728
+ return (0, p.eachItem)(P, (m) => at.call(this, m)), this;
5728
5729
  Tt.call(this, I);
5729
5730
  const a = {
5730
5731
  ...I,
5731
5732
  type: (0, u.getJSONTypes)(I.type),
5732
5733
  schemaType: (0, u.getJSONTypes)(I.schemaType)
5733
5734
  };
5734
- return (0, d.eachItem)(P, a.type.length === 0 ? (m) => at.call(this, m, a) : (m) => a.type.forEach((k) => at.call(this, m, a, k))), this;
5735
+ return (0, p.eachItem)(P, a.type.length === 0 ? (m) => at.call(this, m, a) : (m) => a.type.forEach((k) => at.call(this, m, a, k))), this;
5735
5736
  }
5736
5737
  getKeyword($) {
5737
5738
  const I = this.RULES.all[$];
@@ -5792,8 +5793,8 @@ Yn.default = Ro;
5792
5793
  let M = this._cache.get($);
5793
5794
  if (M !== void 0)
5794
5795
  return M;
5795
- P = (0, p.normalizeId)(k || P);
5796
- const J = p.getSchemaRefs.call(this, $, P);
5796
+ P = (0, d.normalizeId)(k || P);
5797
+ const J = d.getSchemaRefs.call(this, $, P);
5797
5798
  return M = new o.SchemaEnv({ schema: $, schemaId: q, meta: I, baseId: P, localRefs: J }), this._cache.set(M.schema, M), m && !P.startsWith("#") && (P && this._checkUnique(P), this.refs[P] = M), a && this.validateSchema($, !0), M;
5798
5799
  }
5799
5800
  _checkUnique($) {
@@ -5823,7 +5824,7 @@ Yn.default = Ro;
5823
5824
  }
5824
5825
  }
5825
5826
  function b(F) {
5826
- return F = (0, p.normalizeId)(F), this.schemas[F] || this.refs[F];
5827
+ return F = (0, d.normalizeId)(F), this.schemas[F] || this.refs[F];
5827
5828
  }
5828
5829
  function N() {
5829
5830
  const F = this.opts.schemas;
@@ -5873,7 +5874,7 @@ Yn.default = Ro;
5873
5874
  const Re = /^[a-z_$][a-z0-9_$:-]*$/i;
5874
5875
  function he(F, $) {
5875
5876
  const { RULES: I } = this;
5876
- if ((0, d.eachItem)(F, (P) => {
5877
+ if ((0, p.eachItem)(F, (P) => {
5877
5878
  if (I.keywords[P])
5878
5879
  throw new Error(`Keyword ${P} is already defined`);
5879
5880
  if (!Re.test(P))
@@ -5931,15 +5932,15 @@ const ru = Sr, ci = B, Ee = K, qt = Ge, li = Se, kr = re, nu = {
5931
5932
  keyword: "$ref",
5932
5933
  schemaType: "string",
5933
5934
  code(e) {
5934
- const { gen: t, schema: r, it: n } = e, { baseId: s, schemaEnv: i, validateName: o, opts: l, self: p } = n, { root: u } = i;
5935
+ const { gen: t, schema: r, it: n } = e, { baseId: s, schemaEnv: i, validateName: o, opts: l, self: d } = n, { root: u } = i;
5935
5936
  if ((r === "#" || r === "#/") && s === u.baseId)
5936
5937
  return h();
5937
- const d = li.resolveRef.call(p, u, s, r);
5938
- if (d === void 0)
5938
+ const p = li.resolveRef.call(d, u, s, r);
5939
+ if (p === void 0)
5939
5940
  throw new ru.default(n.opts.uriResolver, s, r);
5940
- if (d instanceof li.SchemaEnv)
5941
- return w(d);
5942
- return T(d);
5941
+ if (p instanceof li.SchemaEnv)
5942
+ return w(p);
5943
+ return T(p);
5943
5944
  function h() {
5944
5945
  if (i === u)
5945
5946
  return Ur(e, o, i, i.$async);
@@ -5968,9 +5969,9 @@ function Oo(e, t) {
5968
5969
  }
5969
5970
  Et.getValidate = Oo;
5970
5971
  function Ur(e, t, r, n) {
5971
- const { gen: s, it: i } = e, { allErrors: o, schemaEnv: l, opts: p } = i, u = p.passContext ? qt.default.this : Ee.nil;
5972
- n ? d() : h();
5973
- function d() {
5972
+ const { gen: s, it: i } = e, { allErrors: o, schemaEnv: l, opts: d } = i, u = d.passContext ? qt.default.this : Ee.nil;
5973
+ n ? p() : h();
5974
+ function p() {
5974
5975
  if (!l.$async)
5975
5976
  throw new Error("async schema referenced by sync schema");
5976
5977
  const v = s.let("valid");
@@ -6143,8 +6144,8 @@ const cr = B, mr = K, wu = re, vu = {
6143
6144
  const { gen: t, schema: r, schemaCode: n, data: s, $data: i, it: o } = e, { opts: l } = o;
6144
6145
  if (!i && r.length === 0)
6145
6146
  return;
6146
- const p = r.length >= l.loopRequired;
6147
- if (o.allErrors ? u() : d(), l.strictRequired) {
6147
+ const d = r.length >= l.loopRequired;
6148
+ if (o.allErrors ? u() : p(), l.strictRequired) {
6148
6149
  const T = e.parentSchema.properties, { definedProperties: v } = e.it;
6149
6150
  for (const R of r)
6150
6151
  if ((T == null ? void 0 : T[R]) === void 0 && !v.has(R)) {
@@ -6153,15 +6154,15 @@ const cr = B, mr = K, wu = re, vu = {
6153
6154
  }
6154
6155
  }
6155
6156
  function u() {
6156
- if (p || i)
6157
+ if (d || i)
6157
6158
  e.block$data(mr.nil, h);
6158
6159
  else
6159
6160
  for (const T of r)
6160
6161
  (0, cr.checkReportMissingProp)(e, T);
6161
6162
  }
6162
- function d() {
6163
+ function p() {
6163
6164
  const T = t.let("missing");
6164
- if (p || i) {
6165
+ if (d || i) {
6165
6166
  const v = t.let("valid", !0);
6166
6167
  e.block$data(v, () => w(T, v)), e.ok(v);
6167
6168
  } else
@@ -6208,9 +6209,9 @@ const No = lo;
6208
6209
  No.code = 'require("ajv/dist/runtime/equal").default';
6209
6210
  Tr.default = No;
6210
6211
  Object.defineProperty(ls, "__esModule", { value: !0 });
6211
- const Tn = Pr, ye = K, Su = re, Tu = Tr, Ru = {
6212
- message: ({ params: { i: e, j: t } }) => (0, ye.str)`must NOT have duplicate items (items ## ${t} and ${e} are identical)`,
6213
- params: ({ params: { i: e, j: t } }) => (0, ye._)`{i: ${e}, j: ${t}}`
6212
+ const Tn = Pr, ge = K, Su = re, Tu = Tr, Ru = {
6213
+ message: ({ params: { i: e, j: t } }) => (0, ge.str)`must NOT have duplicate items (items ## ${t} and ${e} are identical)`,
6214
+ params: ({ params: { i: e, j: t } }) => (0, ge._)`{i: ${e}, j: ${t}}`
6214
6215
  }, Ou = {
6215
6216
  keyword: "uniqueItems",
6216
6217
  type: "array",
@@ -6221,27 +6222,27 @@ const Tn = Pr, ye = K, Su = re, Tu = Tr, Ru = {
6221
6222
  const { gen: t, data: r, $data: n, schema: s, parentSchema: i, schemaCode: o, it: l } = e;
6222
6223
  if (!n && !s)
6223
6224
  return;
6224
- const p = t.let("valid"), u = i.items ? (0, Tn.getSchemaTypes)(i.items) : [];
6225
- e.block$data(p, d, (0, ye._)`${o} === false`), e.ok(p);
6226
- function d() {
6227
- const v = t.let("i", (0, ye._)`${r}.length`), R = t.let("j");
6228
- e.setParams({ i: v, j: R }), t.assign(p, !0), t.if((0, ye._)`${v} > 1`, () => (h() ? w : T)(v, R));
6225
+ const d = t.let("valid"), u = i.items ? (0, Tn.getSchemaTypes)(i.items) : [];
6226
+ e.block$data(d, p, (0, ge._)`${o} === false`), e.ok(d);
6227
+ function p() {
6228
+ const v = t.let("i", (0, ge._)`${r}.length`), R = t.let("j");
6229
+ e.setParams({ i: v, j: R }), t.assign(d, !0), t.if((0, ge._)`${v} > 1`, () => (h() ? w : T)(v, R));
6229
6230
  }
6230
6231
  function h() {
6231
6232
  return u.length > 0 && !u.some((v) => v === "object" || v === "array");
6232
6233
  }
6233
6234
  function w(v, R) {
6234
- const _ = t.name("item"), g = (0, Tn.checkDataTypes)(u, _, l.opts.strictNumbers, Tn.DataType.Wrong), O = t.const("indices", (0, ye._)`{}`);
6235
- t.for((0, ye._)`;${v}--;`, () => {
6236
- t.let(_, (0, ye._)`${r}[${v}]`), t.if(g, (0, ye._)`continue`), u.length > 1 && t.if((0, ye._)`typeof ${_} == "string"`, (0, ye._)`${_} += "_"`), t.if((0, ye._)`typeof ${O}[${_}] == "number"`, () => {
6237
- t.assign(R, (0, ye._)`${O}[${_}]`), e.error(), t.assign(p, !1).break();
6238
- }).code((0, ye._)`${O}[${_}] = ${v}`);
6235
+ const _ = t.name("item"), g = (0, Tn.checkDataTypes)(u, _, l.opts.strictNumbers, Tn.DataType.Wrong), O = t.const("indices", (0, ge._)`{}`);
6236
+ t.for((0, ge._)`;${v}--;`, () => {
6237
+ t.let(_, (0, ge._)`${r}[${v}]`), t.if(g, (0, ge._)`continue`), u.length > 1 && t.if((0, ge._)`typeof ${_} == "string"`, (0, ge._)`${_} += "_"`), t.if((0, ge._)`typeof ${O}[${_}] == "number"`, () => {
6238
+ t.assign(R, (0, ge._)`${O}[${_}]`), e.error(), t.assign(d, !1).break();
6239
+ }).code((0, ge._)`${O}[${_}] = ${v}`);
6239
6240
  });
6240
6241
  }
6241
6242
  function T(v, R) {
6242
6243
  const _ = (0, Su.useFunc)(t, Tu.default), g = t.name("outer");
6243
- t.label(g).for((0, ye._)`;${v}--;`, () => t.for((0, ye._)`${R} = ${v}; ${R}--;`, () => t.if((0, ye._)`${_}(${r}[${v}], ${r}[${R}])`, () => {
6244
- e.error(), t.assign(p, !1).break(g);
6244
+ t.label(g).for((0, ge._)`;${v}--;`, () => t.for((0, ge._)`${R} = ${v}; ${R}--;`, () => t.if((0, ge._)`${_}(${r}[${v}], ${r}[${R}])`, () => {
6245
+ e.error(), t.assign(d, !1).break(g);
6245
6246
  })));
6246
6247
  }
6247
6248
  }
@@ -6277,20 +6278,20 @@ const ur = K, Iu = re, Au = Tr, Du = {
6277
6278
  if (!n && s.length === 0)
6278
6279
  throw new Error("enum must have non-empty array");
6279
6280
  const l = s.length >= o.opts.loopEnum;
6280
- let p;
6281
- const u = () => p ?? (p = (0, Iu.useFunc)(t, Au.default));
6282
6281
  let d;
6282
+ const u = () => d ?? (d = (0, Iu.useFunc)(t, Au.default));
6283
+ let p;
6283
6284
  if (l || n)
6284
- d = t.let("valid"), e.block$data(d, h);
6285
+ p = t.let("valid"), e.block$data(p, h);
6285
6286
  else {
6286
6287
  if (!Array.isArray(s))
6287
6288
  throw new Error("ajv implementation error");
6288
6289
  const T = t.const("vSchema", i);
6289
- d = (0, ur.or)(...s.map((v, R) => w(T, R)));
6290
+ p = (0, ur.or)(...s.map((v, R) => w(T, R)));
6290
6291
  }
6291
- e.pass(d);
6292
+ e.pass(p);
6292
6293
  function h() {
6293
- t.assign(d, !1), t.forOf("v", i, (T) => t.if((0, ur._)`${u()}(${r}, ${T})`, () => t.assign(d, !0).break()));
6294
+ t.assign(p, !1), t.forOf("v", i, (T) => t.if((0, ur._)`${u()}(${r}, ${T})`, () => t.assign(p, !0).break()));
6294
6295
  }
6295
6296
  function w(T, v) {
6296
6297
  const R = s[v];
@@ -6349,11 +6350,11 @@ function ko(e, t) {
6349
6350
  e.setParams({ len: t.length }), e.pass((0, yt._)`${l} <= ${t.length}`);
6350
6351
  else if (typeof n == "object" && !(0, Dn.alwaysValidSchema)(o, n)) {
6351
6352
  const u = r.var("valid", (0, yt._)`${l} <= ${t.length}`);
6352
- r.if((0, yt.not)(u), () => p(u)), e.ok(u);
6353
+ r.if((0, yt.not)(u), () => d(u)), e.ok(u);
6353
6354
  }
6354
- function p(u) {
6355
- r.forRange("i", t.length, l, (d) => {
6356
- e.subschema({ keyword: i, dataProp: d, dataPropType: Dn.Type.Num }, u), o.allErrors || r.if((0, yt.not)(u), () => r.break());
6355
+ function d(u) {
6356
+ r.forRange("i", t.length, l, (p) => {
6357
+ e.subschema({ keyword: i, dataProp: p, dataPropType: Dn.Type.Num }, u), o.allErrors || r.if((0, yt.not)(u), () => r.break());
6357
6358
  });
6358
6359
  }
6359
6360
  }
@@ -6376,16 +6377,16 @@ const ui = K, Lr = re, Yu = B, Qu = {
6376
6377
  };
6377
6378
  function jo(e, t, r = e.schema) {
6378
6379
  const { gen: n, parentSchema: s, data: i, keyword: o, it: l } = e;
6379
- d(s), l.opts.unevaluated && r.length && l.items !== !0 && (l.items = Lr.mergeEvaluated.items(n, r.length, l.items));
6380
- const p = n.name("valid"), u = n.const("len", (0, ui._)`${i}.length`);
6380
+ p(s), l.opts.unevaluated && r.length && l.items !== !0 && (l.items = Lr.mergeEvaluated.items(n, r.length, l.items));
6381
+ const d = n.name("valid"), u = n.const("len", (0, ui._)`${i}.length`);
6381
6382
  r.forEach((h, w) => {
6382
6383
  (0, Lr.alwaysValidSchema)(l, h) || (n.if((0, ui._)`${u} > ${w}`, () => e.subschema({
6383
6384
  keyword: o,
6384
6385
  schemaProp: w,
6385
6386
  dataProp: w
6386
- }, p)), e.ok(p));
6387
+ }, d)), e.ok(d));
6387
6388
  });
6388
- function d(h) {
6389
+ function p(h) {
6389
6390
  const { opts: w, errSchemaPath: T } = l, v = r.length, R = v === h.minItems && (v === h.maxItems || h[t] === !1);
6390
6391
  if (w.strictTuples && !R) {
6391
6392
  const _ = `"${o}" is ${v}-tuple, but minItems or maxItems/${t} are not specified or different at path "${T}"`;
@@ -6436,9 +6437,9 @@ const Ne = K, jr = re, id = {
6436
6437
  code(e) {
6437
6438
  const { gen: t, schema: r, parentSchema: n, data: s, it: i } = e;
6438
6439
  let o, l;
6439
- const { minContains: p, maxContains: u } = n;
6440
- i.opts.next ? (o = p === void 0 ? 1 : p, l = u) : o = 1;
6441
- const d = t.const("len", (0, Ne._)`${s}.length`);
6440
+ const { minContains: d, maxContains: u } = n;
6441
+ i.opts.next ? (o = d === void 0 ? 1 : d, l = u) : o = 1;
6442
+ const p = t.const("len", (0, Ne._)`${s}.length`);
6442
6443
  if (e.setParams({ min: o, max: l }), l === void 0 && o === 0) {
6443
6444
  (0, jr.checkStrictMode)(i, '"minContains" == 0 without "maxContains": "contains" keyword ignored');
6444
6445
  return;
@@ -6448,8 +6449,8 @@ const Ne = K, jr = re, id = {
6448
6449
  return;
6449
6450
  }
6450
6451
  if ((0, jr.alwaysValidSchema)(i, r)) {
6451
- let R = (0, Ne._)`${d} >= ${o}`;
6452
- l !== void 0 && (R = (0, Ne._)`${R} && ${d} <= ${l}`), e.pass(R);
6452
+ let R = (0, Ne._)`${p} >= ${o}`;
6453
+ l !== void 0 && (R = (0, Ne._)`${R} && ${p} <= ${l}`), e.pass(R);
6453
6454
  return;
6454
6455
  }
6455
6456
  i.items = !0;
@@ -6460,7 +6461,7 @@ const Ne = K, jr = re, id = {
6460
6461
  T(R, () => t.if(R, () => v(_)));
6461
6462
  }
6462
6463
  function T(R, _) {
6463
- t.forRange("i", 0, d, (g) => {
6464
+ t.forRange("i", 0, p, (g) => {
6464
6465
  e.subschema({
6465
6466
  keyword: "contains",
6466
6467
  dataProp: g,
@@ -6480,14 +6481,14 @@ var Io = {};
6480
6481
  Object.defineProperty(e, "__esModule", { value: !0 }), e.validateSchemaDeps = e.validatePropertyDeps = e.error = void 0;
6481
6482
  const t = K, r = re, n = B;
6482
6483
  e.error = {
6483
- message: ({ params: { property: p, depsCount: u, deps: d } }) => {
6484
+ message: ({ params: { property: d, depsCount: u, deps: p } }) => {
6484
6485
  const h = u === 1 ? "property" : "properties";
6485
- return (0, t.str)`must have ${h} ${d} when property ${p} is present`;
6486
+ return (0, t.str)`must have ${h} ${p} when property ${d} is present`;
6486
6487
  },
6487
- params: ({ params: { property: p, depsCount: u, deps: d, missingProperty: h } }) => (0, t._)`{property: ${p},
6488
+ params: ({ params: { property: d, depsCount: u, deps: p, missingProperty: h } }) => (0, t._)`{property: ${d},
6488
6489
  missingProperty: ${h},
6489
6490
  depsCount: ${u},
6490
- deps: ${d}}`
6491
+ deps: ${p}}`
6491
6492
  // TODO change to reference
6492
6493
  };
6493
6494
  const s = {
@@ -6495,54 +6496,54 @@ var Io = {};
6495
6496
  type: "object",
6496
6497
  schemaType: "object",
6497
6498
  error: e.error,
6498
- code(p) {
6499
- const [u, d] = i(p);
6500
- o(p, u), l(p, d);
6499
+ code(d) {
6500
+ const [u, p] = i(d);
6501
+ o(d, u), l(d, p);
6501
6502
  }
6502
6503
  };
6503
- function i({ schema: p }) {
6504
- const u = {}, d = {};
6505
- for (const h in p) {
6504
+ function i({ schema: d }) {
6505
+ const u = {}, p = {};
6506
+ for (const h in d) {
6506
6507
  if (h === "__proto__")
6507
6508
  continue;
6508
- const w = Array.isArray(p[h]) ? u : d;
6509
- w[h] = p[h];
6509
+ const w = Array.isArray(d[h]) ? u : p;
6510
+ w[h] = d[h];
6510
6511
  }
6511
- return [u, d];
6512
+ return [u, p];
6512
6513
  }
6513
- function o(p, u = p.schema) {
6514
- const { gen: d, data: h, it: w } = p;
6514
+ function o(d, u = d.schema) {
6515
+ const { gen: p, data: h, it: w } = d;
6515
6516
  if (Object.keys(u).length === 0)
6516
6517
  return;
6517
- const T = d.let("missing");
6518
+ const T = p.let("missing");
6518
6519
  for (const v in u) {
6519
6520
  const R = u[v];
6520
6521
  if (R.length === 0)
6521
6522
  continue;
6522
- const _ = (0, n.propertyInData)(d, h, v, w.opts.ownProperties);
6523
- p.setParams({
6523
+ const _ = (0, n.propertyInData)(p, h, v, w.opts.ownProperties);
6524
+ d.setParams({
6524
6525
  property: v,
6525
6526
  depsCount: R.length,
6526
6527
  deps: R.join(", ")
6527
- }), w.allErrors ? d.if(_, () => {
6528
+ }), w.allErrors ? p.if(_, () => {
6528
6529
  for (const g of R)
6529
- (0, n.checkReportMissingProp)(p, g);
6530
- }) : (d.if((0, t._)`${_} && (${(0, n.checkMissingProp)(p, R, T)})`), (0, n.reportMissingProp)(p, T), d.else());
6530
+ (0, n.checkReportMissingProp)(d, g);
6531
+ }) : (p.if((0, t._)`${_} && (${(0, n.checkMissingProp)(d, R, T)})`), (0, n.reportMissingProp)(d, T), p.else());
6531
6532
  }
6532
6533
  }
6533
6534
  e.validatePropertyDeps = o;
6534
- function l(p, u = p.schema) {
6535
- const { gen: d, data: h, keyword: w, it: T } = p, v = d.name("valid");
6535
+ function l(d, u = d.schema) {
6536
+ const { gen: p, data: h, keyword: w, it: T } = d, v = p.name("valid");
6536
6537
  for (const R in u)
6537
- (0, r.alwaysValidSchema)(T, u[R]) || (d.if(
6538
- (0, n.propertyInData)(d, h, R, T.opts.ownProperties),
6538
+ (0, r.alwaysValidSchema)(T, u[R]) || (p.if(
6539
+ (0, n.propertyInData)(p, h, R, T.opts.ownProperties),
6539
6540
  () => {
6540
- const _ = p.subschema({ keyword: w, schemaProp: R }, v);
6541
- p.mergeValidEvaluated(_, v);
6541
+ const _ = d.subschema({ keyword: w, schemaProp: R }, v);
6542
+ d.mergeValidEvaluated(_, v);
6542
6543
  },
6543
- () => d.var(v, !0)
6544
+ () => p.var(v, !0)
6544
6545
  // TODO var
6545
- ), p.ok(v));
6546
+ ), d.ok(v));
6546
6547
  }
6547
6548
  e.validateSchemaDeps = l, e.default = s;
6548
6549
  })(Io);
@@ -6591,14 +6592,14 @@ const Ir = B, je = K, ud = Ge, Ar = re, dd = {
6591
6592
  const { gen: t, schema: r, parentSchema: n, data: s, errsCount: i, it: o } = e;
6592
6593
  if (!i)
6593
6594
  throw new Error("ajv implementation error");
6594
- const { allErrors: l, opts: p } = o;
6595
- if (o.props = !0, p.removeAdditional !== "all" && (0, Ar.alwaysValidSchema)(o, r))
6595
+ const { allErrors: l, opts: d } = o;
6596
+ if (o.props = !0, d.removeAdditional !== "all" && (0, Ar.alwaysValidSchema)(o, r))
6596
6597
  return;
6597
- const u = (0, Ir.allSchemaProperties)(n.properties), d = (0, Ir.allSchemaProperties)(n.patternProperties);
6598
+ const u = (0, Ir.allSchemaProperties)(n.properties), p = (0, Ir.allSchemaProperties)(n.patternProperties);
6598
6599
  h(), e.ok((0, je._)`${i} === ${ud.default.errors}`);
6599
6600
  function h() {
6600
6601
  t.forIn("key", s, (_) => {
6601
- !u.length && !d.length ? v(_) : t.if(w(_), () => v(_));
6602
+ !u.length && !p.length ? v(_) : t.if(w(_), () => v(_));
6602
6603
  });
6603
6604
  }
6604
6605
  function w(_) {
@@ -6608,13 +6609,13 @@ const Ir = B, je = K, ud = Ge, Ar = re, dd = {
6608
6609
  g = (0, Ir.isOwnProperty)(t, O, _);
6609
6610
  } else
6610
6611
  u.length ? g = (0, je.or)(...u.map((O) => (0, je._)`${_} === ${O}`)) : g = je.nil;
6611
- return d.length && (g = (0, je.or)(g, ...d.map((O) => (0, je._)`${(0, Ir.usePattern)(e, O)}.test(${_})`))), (0, je.not)(g);
6612
+ return p.length && (g = (0, je.or)(g, ...p.map((O) => (0, je._)`${(0, Ir.usePattern)(e, O)}.test(${_})`))), (0, je.not)(g);
6612
6613
  }
6613
6614
  function T(_) {
6614
6615
  t.code((0, je._)`delete ${s}[${_}]`);
6615
6616
  }
6616
6617
  function v(_) {
6617
- if (p.removeAdditional === "all" || p.removeAdditional && r === !1) {
6618
+ if (d.removeAdditional === "all" || d.removeAdditional && r === !1) {
6618
6619
  T(_);
6619
6620
  return;
6620
6621
  }
@@ -6624,7 +6625,7 @@ const Ir = B, je = K, ud = Ge, Ar = re, dd = {
6624
6625
  }
6625
6626
  if (typeof r == "object" && !(0, Ar.alwaysValidSchema)(o, r)) {
6626
6627
  const g = t.name("valid");
6627
- p.removeAdditional === "failing" ? (R(_, g, !1), t.if((0, je.not)(g), () => {
6628
+ d.removeAdditional === "failing" ? (R(_, g, !1), t.if((0, je.not)(g), () => {
6628
6629
  e.reset(), T(_);
6629
6630
  })) : (R(_, g), l || t.if((0, je.not)(g), () => t.break()));
6630
6631
  }
@@ -6660,18 +6661,18 @@ const fd = Ae, pi = B, Rn = re, fi = _n, hd = {
6660
6661
  const l = o.filter((h) => !(0, Rn.alwaysValidSchema)(i, r[h]));
6661
6662
  if (l.length === 0)
6662
6663
  return;
6663
- const p = t.name("valid");
6664
+ const d = t.name("valid");
6664
6665
  for (const h of l)
6665
- u(h) ? d(h) : (t.if((0, pi.propertyInData)(t, s, h, i.opts.ownProperties)), d(h), i.allErrors || t.else().var(p, !0), t.endIf()), e.it.definedProperties.add(h), e.ok(p);
6666
+ u(h) ? p(h) : (t.if((0, pi.propertyInData)(t, s, h, i.opts.ownProperties)), p(h), i.allErrors || t.else().var(d, !0), t.endIf()), e.it.definedProperties.add(h), e.ok(d);
6666
6667
  function u(h) {
6667
6668
  return i.opts.useDefaults && !i.compositeRule && r[h].default !== void 0;
6668
6669
  }
6669
- function d(h) {
6670
+ function p(h) {
6670
6671
  e.subschema({
6671
6672
  keyword: "properties",
6672
6673
  schemaProp: h,
6673
6674
  dataProp: h
6674
- }, p);
6675
+ }, d);
6675
6676
  }
6676
6677
  }
6677
6678
  };
@@ -6683,16 +6684,16 @@ const hi = B, Dr = K, mi = re, yi = re, md = {
6683
6684
  type: "object",
6684
6685
  schemaType: "object",
6685
6686
  code(e) {
6686
- const { gen: t, schema: r, data: n, parentSchema: s, it: i } = e, { opts: o } = i, l = (0, hi.allSchemaProperties)(r), p = l.filter((R) => (0, mi.alwaysValidSchema)(i, r[R]));
6687
- if (l.length === 0 || p.length === l.length && (!i.opts.unevaluated || i.props === !0))
6687
+ const { gen: t, schema: r, data: n, parentSchema: s, it: i } = e, { opts: o } = i, l = (0, hi.allSchemaProperties)(r), d = l.filter((R) => (0, mi.alwaysValidSchema)(i, r[R]));
6688
+ if (l.length === 0 || d.length === l.length && (!i.opts.unevaluated || i.props === !0))
6688
6689
  return;
6689
- const u = o.strictSchema && !o.allowMatchingProperties && s.properties, d = t.name("valid");
6690
+ const u = o.strictSchema && !o.allowMatchingProperties && s.properties, p = t.name("valid");
6690
6691
  i.props !== !0 && !(i.props instanceof Dr.Name) && (i.props = (0, yi.evaluatedPropsToName)(t, i.props));
6691
6692
  const { props: h } = i;
6692
6693
  w();
6693
6694
  function w() {
6694
6695
  for (const R of l)
6695
- u && T(R), i.allErrors ? v(R) : (t.var(d, !0), v(R), t.if(d));
6696
+ u && T(R), i.allErrors ? v(R) : (t.var(p, !0), v(R), t.if(p));
6696
6697
  }
6697
6698
  function T(R) {
6698
6699
  for (const _ in u)
@@ -6701,13 +6702,13 @@ const hi = B, Dr = K, mi = re, yi = re, md = {
6701
6702
  function v(R) {
6702
6703
  t.forIn("key", n, (_) => {
6703
6704
  t.if((0, Dr._)`${(0, hi.usePattern)(e, R)}.test(${_})`, () => {
6704
- const g = p.includes(R);
6705
+ const g = d.includes(R);
6705
6706
  g || e.subschema({
6706
6707
  keyword: "patternProperties",
6707
6708
  schemaProp: R,
6708
6709
  dataProp: _,
6709
6710
  dataPropType: yi.Type.Str
6710
- }, d), i.opts.unevaluated && h !== !0 ? t.assign((0, Dr._)`${h}[${_}]`, !0) : !g && !i.allErrors && t.if((0, Dr.not)(d), () => t.break());
6711
+ }, p), i.opts.unevaluated && h !== !0 ? t.assign((0, Dr._)`${h}[${_}]`, !0) : !g && !i.allErrors && t.if((0, Dr.not)(p), () => t.break());
6711
6712
  });
6712
6713
  });
6713
6714
  }
@@ -6763,16 +6764,16 @@ const zr = K, wd = re, vd = {
6763
6764
  throw new Error("ajv implementation error");
6764
6765
  if (s.opts.discriminator && n.discriminator)
6765
6766
  return;
6766
- const i = r, o = t.let("valid", !1), l = t.let("passing", null), p = t.name("_valid");
6767
+ const i = r, o = t.let("valid", !1), l = t.let("passing", null), d = t.name("_valid");
6767
6768
  e.setParams({ passing: l }), t.block(u), e.result(o, () => e.reset(), () => e.error(!0));
6768
6769
  function u() {
6769
- i.forEach((d, h) => {
6770
+ i.forEach((p, h) => {
6770
6771
  let w;
6771
- (0, wd.alwaysValidSchema)(s, d) ? t.var(p, !0) : w = e.subschema({
6772
+ (0, wd.alwaysValidSchema)(s, p) ? t.var(d, !0) : w = e.subschema({
6772
6773
  keyword: "oneOf",
6773
6774
  schemaProp: h,
6774
6775
  compositeRule: !0
6775
- }, p), h > 0 && t.if((0, zr._)`${p} && ${o}`).assign(o, !1).assign(l, (0, zr._)`[${l}, ${h}]`).else(), t.if(p, () => {
6776
+ }, d), h > 0 && t.if((0, zr._)`${d} && ${o}`).assign(o, !1).assign(l, (0, zr._)`[${l}, ${h}]`).else(), t.if(d, () => {
6776
6777
  t.assign(o, !0), t.assign(l, h), w && e.mergeEvaluated(w, zr.Name);
6777
6778
  });
6778
6779
  });
@@ -6816,25 +6817,25 @@ const Gr = K, Do = re, Sd = {
6816
6817
  if (!s && !i)
6817
6818
  return;
6818
6819
  const o = t.let("valid", !0), l = t.name("_valid");
6819
- if (p(), e.reset(), s && i) {
6820
- const d = t.let("ifClause");
6821
- e.setParams({ ifClause: d }), t.if(l, u("then", d), u("else", d));
6820
+ if (d(), e.reset(), s && i) {
6821
+ const p = t.let("ifClause");
6822
+ e.setParams({ ifClause: p }), t.if(l, u("then", p), u("else", p));
6822
6823
  } else
6823
6824
  s ? t.if(l, u("then")) : t.if((0, Gr.not)(l), u("else"));
6824
6825
  e.pass(o, () => e.error(!0));
6825
- function p() {
6826
- const d = e.subschema({
6826
+ function d() {
6827
+ const p = e.subschema({
6827
6828
  keyword: "if",
6828
6829
  compositeRule: !0,
6829
6830
  createErrors: !1,
6830
6831
  allErrors: !1
6831
6832
  }, l);
6832
- e.mergeEvaluated(d);
6833
+ e.mergeEvaluated(p);
6833
6834
  }
6834
- function u(d, h) {
6835
+ function u(p, h) {
6835
6836
  return () => {
6836
- const w = e.subschema({ keyword: d }, l);
6837
- t.assign(o, l), e.mergeValidEvaluated(w, o), h ? t.assign(h, (0, Gr._)`${d}`) : e.setParams({ ifClause: d });
6837
+ const w = e.subschema({ keyword: p }, l);
6838
+ t.assign(o, l), e.mergeValidEvaluated(w, o), h ? t.assign(h, (0, Gr._)`${p}`) : e.setParams({ ifClause: p });
6838
6839
  };
6839
6840
  }
6840
6841
  }
@@ -6887,21 +6888,21 @@ const fe = K, Bd = {
6887
6888
  $data: !0,
6888
6889
  error: Bd,
6889
6890
  code(e, t) {
6890
- const { gen: r, data: n, $data: s, schema: i, schemaCode: o, it: l } = e, { opts: p, errSchemaPath: u, schemaEnv: d, self: h } = l;
6891
- if (!p.validateFormats)
6891
+ const { gen: r, data: n, $data: s, schema: i, schemaCode: o, it: l } = e, { opts: d, errSchemaPath: u, schemaEnv: p, self: h } = l;
6892
+ if (!d.validateFormats)
6892
6893
  return;
6893
6894
  s ? w() : T();
6894
6895
  function w() {
6895
6896
  const v = r.scopeValue("formats", {
6896
6897
  ref: h.formats,
6897
- code: p.code.formats
6898
+ code: d.code.formats
6898
6899
  }), R = r.const("fDef", (0, fe._)`${v}[${o}]`), _ = r.let("fType"), g = r.let("format");
6899
6900
  r.if((0, fe._)`typeof ${R} == "object" && !(${R} instanceof RegExp)`, () => r.assign(_, (0, fe._)`${R}.type || "string"`).assign(g, (0, fe._)`${R}.validate`), () => r.assign(_, (0, fe._)`"string"`).assign(g, R)), e.fail$data((0, fe.or)(O(), C()));
6900
6901
  function O() {
6901
- return p.strictSchema === !1 ? fe.nil : (0, fe._)`${o} && !${g}`;
6902
+ return d.strictSchema === !1 ? fe.nil : (0, fe._)`${o} && !${g}`;
6902
6903
  }
6903
6904
  function C() {
6904
- const j = d.$async ? (0, fe._)`(${R}.async ? await ${g}(${n}) : ${g}(${n}))` : (0, fe._)`${g}(${n})`, D = (0, fe._)`(typeof ${g} == "function" ? ${j} : ${g}.test(${n}))`;
6905
+ const j = p.$async ? (0, fe._)`(${R}.async ? await ${g}(${n}) : ${g}(${n}))` : (0, fe._)`${g}(${n})`, D = (0, fe._)`(typeof ${g} == "function" ? ${j} : ${g}.test(${n}))`;
6905
6906
  return (0, fe._)`${g} && ${g} !== true && ${_} === ${t} && !${D}`;
6906
6907
  }
6907
6908
  }
@@ -6916,7 +6917,7 @@ const fe = K, Bd = {
6916
6917
  const [R, _, g] = C(v);
6917
6918
  R === t && e.pass(j());
6918
6919
  function O() {
6919
- if (p.strictSchema === !1) {
6920
+ if (d.strictSchema === !1) {
6920
6921
  h.logger.warn(D());
6921
6922
  return;
6922
6923
  }
@@ -6926,12 +6927,12 @@ const fe = K, Bd = {
6926
6927
  }
6927
6928
  }
6928
6929
  function C(D) {
6929
- const b = D instanceof RegExp ? (0, fe.regexpCode)(D) : p.code.formats ? (0, fe._)`${p.code.formats}${(0, fe.getProperty)(i)}` : void 0, N = r.scopeValue("formats", { key: i, ref: D, code: b });
6930
+ const b = D instanceof RegExp ? (0, fe.regexpCode)(D) : d.code.formats ? (0, fe._)`${d.code.formats}${(0, fe.getProperty)(i)}` : void 0, N = r.scopeValue("formats", { key: i, ref: D, code: b });
6930
6931
  return typeof D == "object" && !(D instanceof RegExp) ? [D.type || "string", D.validate, (0, fe._)`${N}.validate`] : ["string", D, N];
6931
6932
  }
6932
6933
  function j() {
6933
6934
  if (typeof v == "object" && !(v instanceof RegExp) && v.async) {
6934
- if (!d.$async)
6935
+ if (!p.$async)
6935
6936
  throw new Error("async format in sync schema");
6936
6937
  return (0, fe._)`await ${g}(${n})`;
6937
6938
  }
@@ -6997,13 +6998,13 @@ const Mt = K, Fn = Fo, _i = Se, tp = re, rp = {
6997
6998
  throw new Error("discriminator: mapping is not supported");
6998
6999
  if (!o)
6999
7000
  throw new Error("discriminator: requires oneOf keyword");
7000
- const p = t.let("valid", !1), u = t.const("tag", (0, Mt._)`${r}${(0, Mt.getProperty)(l)}`);
7001
- t.if((0, Mt._)`typeof ${u} == "string"`, () => d(), () => e.error(!1, { discrError: Fn.DiscrError.Tag, tag: u, tagName: l })), e.ok(p);
7002
- function d() {
7001
+ const d = t.let("valid", !1), u = t.const("tag", (0, Mt._)`${r}${(0, Mt.getProperty)(l)}`);
7002
+ t.if((0, Mt._)`typeof ${u} == "string"`, () => p(), () => e.error(!1, { discrError: Fn.DiscrError.Tag, tag: u, tagName: l })), e.ok(d);
7003
+ function p() {
7003
7004
  const T = w();
7004
7005
  t.if(!1);
7005
7006
  for (const v in T)
7006
- t.elseIf((0, Mt._)`${u} === ${v}`), t.assign(p, h(T[v]));
7007
+ t.elseIf((0, Mt._)`${u} === ${v}`), t.assign(d, h(T[v]));
7007
7008
  t.else(), e.error(!1, { discrError: Fn.DiscrError.Mapping, tag: u, tagName: l }), t.endIf();
7008
7009
  }
7009
7010
  function h(T) {
@@ -7290,7 +7291,7 @@ const sp = "http://json-schema.org/draft-07/schema#", ip = "http://json-schema.o
7290
7291
  (function(e, t) {
7291
7292
  Object.defineProperty(t, "__esModule", { value: !0 }), t.MissingRefError = t.ValidationError = t.CodeGen = t.Name = t.nil = t.stringify = t.str = t._ = t.KeywordCxt = void 0;
7292
7293
  const r = to, n = Qn, s = Rs, i = up, o = ["/properties"], l = "http://json-schema.org/draft-07/schema";
7293
- class p extends r.default {
7294
+ class d extends r.default {
7294
7295
  _addVocabularies() {
7295
7296
  super._addVocabularies(), n.default.forEach((v) => this.addVocabulary(v)), this.opts.discriminator && this.addKeyword(s.default);
7296
7297
  }
@@ -7304,24 +7305,24 @@ const sp = "http://json-schema.org/draft-07/schema#", ip = "http://json-schema.o
7304
7305
  return this.opts.defaultMeta = super.defaultMeta() || (this.getSchema(l) ? l : void 0);
7305
7306
  }
7306
7307
  }
7307
- e.exports = t = p, Object.defineProperty(t, "__esModule", { value: !0 }), t.default = p;
7308
+ e.exports = t = d, Object.defineProperty(t, "__esModule", { value: !0 }), t.default = d;
7308
7309
  var u = Ae;
7309
7310
  Object.defineProperty(t, "KeywordCxt", { enumerable: !0, get: function() {
7310
7311
  return u.KeywordCxt;
7311
7312
  } });
7312
- var d = K;
7313
+ var p = K;
7313
7314
  Object.defineProperty(t, "_", { enumerable: !0, get: function() {
7314
- return d._;
7315
+ return p._;
7315
7316
  } }), Object.defineProperty(t, "str", { enumerable: !0, get: function() {
7316
- return d.str;
7317
+ return p.str;
7317
7318
  } }), Object.defineProperty(t, "stringify", { enumerable: !0, get: function() {
7318
- return d.stringify;
7319
+ return p.stringify;
7319
7320
  } }), Object.defineProperty(t, "nil", { enumerable: !0, get: function() {
7320
- return d.nil;
7321
+ return p.nil;
7321
7322
  } }), Object.defineProperty(t, "Name", { enumerable: !0, get: function() {
7322
- return d.Name;
7323
+ return p.Name;
7323
7324
  } }), Object.defineProperty(t, "CodeGen", { enumerable: !0, get: function() {
7324
- return d.CodeGen;
7325
+ return p.CodeGen;
7325
7326
  } });
7326
7327
  var h = Er;
7327
7328
  Object.defineProperty(t, "ValidationError", { enumerable: !0, get: function() {
@@ -8776,7 +8777,7 @@ function gp(e, {
8776
8777
  onStepCompleted: n = () => {
8777
8778
  }
8778
8779
  } = {}) {
8779
- var u, d, h;
8780
+ var u, p, h;
8780
8781
  if (e = {
8781
8782
  ...e,
8782
8783
  steps: (e.steps || []).filter(bp)
@@ -8816,7 +8817,7 @@ function gp(e, {
8816
8817
  return w + (((v = T.progress) == null ? void 0 : v.weight) || 1);
8817
8818
  },
8818
8819
  0
8819
- ), p = o.map(
8820
+ ), d = o.map(
8820
8821
  (w) => Pp(w, {
8821
8822
  semaphore: r,
8822
8823
  rootProgressTracker: t,
@@ -8830,7 +8831,7 @@ function gp(e, {
8830
8831
  Hn,
8831
8832
  Ja
8832
8833
  ),
8833
- wp: ((d = e.preferredVersions) == null ? void 0 : d.wp) || "latest"
8834
+ wp: ((p = e.preferredVersions) == null ? void 0 : p.wp) || "latest"
8834
8835
  },
8835
8836
  phpExtensions: vp(
8836
8837
  [],
@@ -8842,10 +8843,10 @@ function gp(e, {
8842
8843
  },
8843
8844
  run: async (w) => {
8844
8845
  try {
8845
- for (const { resources: T } of p)
8846
+ for (const { resources: T } of d)
8846
8847
  for (const v of T)
8847
8848
  v.setPlayground(w), v.isAsync && v.resolve();
8848
- for (const { run: T, step: v } of p) {
8849
+ for (const { run: T, step: v } of d) {
8849
8850
  const R = await T(w);
8850
8851
  n(R, v);
8851
8852
  }
@@ -8899,9 +8900,9 @@ function Pp(e, {
8899
8900
  rootProgressTracker: r,
8900
8901
  totalProgressWeight: n
8901
8902
  }) {
8902
- var d;
8903
+ var p;
8903
8904
  const s = r.stage(
8904
- (((d = e.progress) == null ? void 0 : d.weight) || 1) / n
8905
+ (((p = e.progress) == null ? void 0 : p.weight) || 1) / n
8905
8906
  ), i = {};
8906
8907
  for (const h of Object.keys(e)) {
8907
8908
  let w = e[h];
@@ -8923,10 +8924,10 @@ function Pp(e, {
8923
8924
  } finally {
8924
8925
  s.finish();
8925
8926
  }
8926
- }, l = wi(i), p = wi(i).filter(
8927
+ }, l = wi(i), d = wi(i).filter(
8927
8928
  (h) => h.isAsync
8928
- ), u = 1 / (p.length + 1);
8929
- for (const h of p)
8929
+ ), u = 1 / (d.length + 1);
8930
+ for (const h of d)
8930
8931
  h.progress = s.stage(u);
8931
8932
  return { run: o, step: e, resources: l };
8932
8933
  }
@@ -8999,23 +9000,23 @@ function Os(e, t = globalThis, r = ["*"]) {
8999
9000
  console.warn(`Invalid origin '${s.origin}' for comlink proxy`);
9000
9001
  return;
9001
9002
  }
9002
- const { id: i, type: o, path: l } = Object.assign({ path: [] }, s.data), p = (s.data.argumentList || []).map(gt);
9003
+ const { id: i, type: o, path: l } = Object.assign({ path: [] }, s.data), d = (s.data.argumentList || []).map(gt);
9003
9004
  let u;
9004
9005
  try {
9005
- const d = l.slice(0, -1).reduce((w, T) => w[T], e), h = l.reduce((w, T) => w[T], e);
9006
+ const p = l.slice(0, -1).reduce((w, T) => w[T], e), h = l.reduce((w, T) => w[T], e);
9006
9007
  switch (o) {
9007
9008
  case "GET":
9008
9009
  u = h;
9009
9010
  break;
9010
9011
  case "SET":
9011
- d[l.slice(-1)[0]] = gt(s.data.value), u = !0;
9012
+ p[l.slice(-1)[0]] = gt(s.data.value), u = !0;
9012
9013
  break;
9013
9014
  case "APPLY":
9014
- u = h.apply(d, p);
9015
+ u = h.apply(p, d);
9015
9016
  break;
9016
9017
  case "CONSTRUCT":
9017
9018
  {
9018
- const w = new h(...p);
9019
+ const w = new h(...d);
9019
9020
  u = Ho(w);
9020
9021
  }
9021
9022
  break;
@@ -9031,13 +9032,13 @@ function Os(e, t = globalThis, r = ["*"]) {
9031
9032
  default:
9032
9033
  return;
9033
9034
  }
9034
- } catch (d) {
9035
- u = { value: d, [Hr]: 0 };
9035
+ } catch (p) {
9036
+ u = { value: p, [Hr]: 0 };
9036
9037
  }
9037
- Promise.resolve(u).catch((d) => ({ value: d, [Hr]: 0 })).then((d) => {
9038
- const [h, w] = Qr(d);
9038
+ Promise.resolve(u).catch((p) => ({ value: p, [Hr]: 0 })).then((p) => {
9039
+ const [h, w] = Qr(p);
9039
9040
  t.postMessage(Object.assign(Object.assign({}, h), { id: i }), w), o === "RELEASE" && (t.removeEventListener("message", n), Uo(t), On in e && typeof e[On] == "function" && e[On]());
9040
- }).catch((d) => {
9041
+ }).catch((p) => {
9041
9042
  const [h, w] = Qr({
9042
9043
  value: new TypeError("Unserializable return value"),
9043
9044
  [Hr]: 0
@@ -9091,7 +9092,7 @@ function qn(e, t = [], r = function() {
9091
9092
  return { then: () => s };
9092
9093
  const l = Ut(e, {
9093
9094
  type: "GET",
9094
- path: t.map((p) => p.toString())
9095
+ path: t.map((d) => d.toString())
9095
9096
  }).then(gt);
9096
9097
  return l.then.bind(l);
9097
9098
  }
@@ -9099,37 +9100,37 @@ function qn(e, t = [], r = function() {
9099
9100
  },
9100
9101
  set(i, o, l) {
9101
9102
  qr(n);
9102
- const [p, u] = Qr(l);
9103
+ const [d, u] = Qr(l);
9103
9104
  return Ut(e, {
9104
9105
  type: "SET",
9105
- path: [...t, o].map((d) => d.toString()),
9106
- value: p
9106
+ path: [...t, o].map((p) => p.toString()),
9107
+ value: d
9107
9108
  }, u).then(gt);
9108
9109
  },
9109
9110
  apply(i, o, l) {
9110
9111
  qr(n);
9111
- const p = t[t.length - 1];
9112
- if (p === Tp)
9112
+ const d = t[t.length - 1];
9113
+ if (d === Tp)
9113
9114
  return Ut(e, {
9114
9115
  type: "ENDPOINT"
9115
9116
  }).then(gt);
9116
- if (p === "bind")
9117
+ if (d === "bind")
9117
9118
  return qn(e, t.slice(0, -1));
9118
- const [u, d] = vi(l);
9119
+ const [u, p] = vi(l);
9119
9120
  return Ut(e, {
9120
9121
  type: "APPLY",
9121
9122
  path: t.map((h) => h.toString()),
9122
9123
  argumentList: u
9123
- }, d).then(gt);
9124
+ }, p).then(gt);
9124
9125
  },
9125
9126
  construct(i, o) {
9126
9127
  qr(n);
9127
- const [l, p] = vi(o);
9128
+ const [l, d] = vi(o);
9128
9129
  return Ut(e, {
9129
9130
  type: "CONSTRUCT",
9130
9131
  path: t.map((u) => u.toString()),
9131
9132
  argumentList: l
9132
- }, p).then(gt);
9133
+ }, d).then(gt);
9133
9134
  }
9134
9135
  });
9135
9136
  return jp(s, e), s;