@bahmni/services 0.0.1-dev.297 → 0.0.1-dev.301

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -43,12 +43,12 @@ const As = yc(), Ns = typeof As.FormData < "u" ? As.FormData : void 0, wc = (t)
43
43
  const r = Kr(t);
44
44
  return r === "formdata" || // detect form-data instance
45
45
  r === "object" && Ne(t.toString) && t.toString() === "[object FormData]";
46
- }, Ec = xe("URLSearchParams"), [bc, _c, vc, Rc] = [
46
+ }, Ec = xe("URLSearchParams"), [bc, _c, vc, Tc] = [
47
47
  "ReadableStream",
48
48
  "Request",
49
49
  "Response",
50
50
  "Headers"
51
- ].map(xe), Sc = (t) => t.trim ? t.trim() : t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, "");
51
+ ].map(xe), Rc = (t) => t.trim ? t.trim() : t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, "");
52
52
  function Ft(t, e, { allOwnKeys: r = !1 } = {}) {
53
53
  if (t === null || typeof t > "u")
54
54
  return;
@@ -88,7 +88,7 @@ function Mn(...t) {
88
88
  t[o] && Ft(t[o], s);
89
89
  return n;
90
90
  }
91
- const Tc = (t, e, r, { allOwnKeys: n } = {}) => (Ft(
91
+ const Sc = (t, e, r, { allOwnKeys: n } = {}) => (Ft(
92
92
  e,
93
93
  (s, o) => {
94
94
  r && Ne(s) ? Object.defineProperty(t, o, {
@@ -232,7 +232,7 @@ const Vc = (t) => {
232
232
  isReadableStream: bc,
233
233
  isRequest: _c,
234
234
  isResponse: vc,
235
- isHeaders: Rc,
235
+ isHeaders: Tc,
236
236
  isUndefined: mt,
237
237
  isDate: lc,
238
238
  isFile: dc,
@@ -247,8 +247,8 @@ const Vc = (t) => {
247
247
  isFileList: mc,
248
248
  forEach: Ft,
249
249
  merge: Mn,
250
- extend: Tc,
251
- trim: Sc,
250
+ extend: Sc,
251
+ trim: Rc,
252
252
  stripBOM: Oc,
253
253
  inherits: Ac,
254
254
  toFlatObject: Nc,
@@ -320,7 +320,7 @@ function Jc(t) {
320
320
  }
321
321
  return e === 0 && r === t.length ? t : t.slice(e, r);
322
322
  }
323
- function St(t) {
323
+ function Rt(t) {
324
324
  return t && String(t).trim().toLowerCase();
325
325
  }
326
326
  function Qc(t) {
@@ -364,14 +364,14 @@ function tu(t, e) {
364
364
  });
365
365
  });
366
366
  }
367
- let Te = class {
367
+ let Se = class {
368
368
  constructor(e) {
369
369
  e && this.set(e);
370
370
  }
371
371
  set(e, r, n) {
372
372
  const s = this;
373
373
  function o(i, c, u) {
374
- const l = St(c);
374
+ const l = Rt(c);
375
375
  if (!l)
376
376
  throw new Error("header name must be a non-empty string");
377
377
  const h = $.findKey(s, l);
@@ -395,7 +395,7 @@ let Te = class {
395
395
  return this;
396
396
  }
397
397
  get(e, r) {
398
- if (e = St(e), e) {
398
+ if (e = Rt(e), e) {
399
399
  const n = $.findKey(this, e);
400
400
  if (n) {
401
401
  const s = this[n];
@@ -412,7 +412,7 @@ let Te = class {
412
412
  }
413
413
  }
414
414
  has(e, r) {
415
- if (e = St(e), e) {
415
+ if (e = Rt(e), e) {
416
416
  const n = $.findKey(this, e);
417
417
  return !!(n && this[n] !== void 0 && (!r || pn(this, this[n], n, r)));
418
418
  }
@@ -422,7 +422,7 @@ let Te = class {
422
422
  const n = this;
423
423
  let s = !1;
424
424
  function o(a) {
425
- if (a = St(a), a) {
425
+ if (a = Rt(a), a) {
426
426
  const i = $.findKey(n, a);
427
427
  i && (!r || pn(n, n[i], i, r)) && (delete n[i], s = !0);
428
428
  }
@@ -484,13 +484,13 @@ let Te = class {
484
484
  accessors: {}
485
485
  }).accessors, s = this.prototype;
486
486
  function o(a) {
487
- const i = St(a);
487
+ const i = Rt(a);
488
488
  n[i] || (tu(s, a), n[i] = !0);
489
489
  }
490
490
  return $.isArray(e) ? e.forEach(o) : o(e), this;
491
491
  }
492
492
  };
493
- Te.accessor([
493
+ Se.accessor([
494
494
  "Content-Type",
495
495
  "Content-Length",
496
496
  "Accept",
@@ -498,7 +498,7 @@ Te.accessor([
498
498
  "User-Agent",
499
499
  "Authorization"
500
500
  ]);
501
- $.reduceDescriptors(Te.prototype, ({ value: t }, e) => {
501
+ $.reduceDescriptors(Se.prototype, ({ value: t }, e) => {
502
502
  let r = e[0].toUpperCase() + e.slice(1);
503
503
  return {
504
504
  get: () => t,
@@ -507,7 +507,7 @@ $.reduceDescriptors(Te.prototype, ({ value: t }, e) => {
507
507
  }
508
508
  };
509
509
  });
510
- $.freezeMethods(Te);
510
+ $.freezeMethods(Se);
511
511
  const ru = "[REDACTED ****]";
512
512
  function nu(t) {
513
513
  if ($.hasOwnProp(t, "toJSON"))
@@ -524,7 +524,7 @@ function su(t, e) {
524
524
  const r = new Set(e.map((o) => String(o).toLowerCase())), n = [], s = (o) => {
525
525
  if (o === null || typeof o != "object" || $.isBuffer(o)) return o;
526
526
  if (n.indexOf(o) !== -1) return;
527
- o instanceof Te && (o = o.toJSON()), n.push(o);
527
+ o instanceof Se && (o = o.toJSON()), n.push(o);
528
528
  let a;
529
529
  if ($.isArray(o))
530
530
  a = [], o.forEach((i, c) => {
@@ -660,11 +660,11 @@ function Jr(t, e, r) {
660
660
  if ($.endsWith(f, "{}"))
661
661
  f = n ? f : f.slice(0, -2), _ = JSON.stringify(_);
662
662
  else if ($.isArray(_) && au(_) || ($.isFileList(_) || $.endsWith(f, "[]")) && (p = $.toArray(_)))
663
- return f = ja(f), p.forEach(function(T, d) {
664
- !($.isUndefined(T) || T === null) && e.append(
663
+ return f = ja(f), p.forEach(function(S, d) {
664
+ !($.isUndefined(S) || S === null) && e.append(
665
665
  // eslint-disable-next-line no-nested-ternary
666
666
  a === !0 ? hn([f], d, o) : a === null ? f : f + "[]",
667
- l(T)
667
+ l(S)
668
668
  );
669
669
  }), !1;
670
670
  }
@@ -675,7 +675,7 @@ function Jr(t, e, r) {
675
675
  convertValue: l,
676
676
  isVisitable: qn
677
677
  });
678
- function S(_, f, g = 0) {
678
+ function R(_, f, g = 0) {
679
679
  if (!$.isUndefined(_)) {
680
680
  if (g > c)
681
681
  throw new Y(
@@ -684,14 +684,14 @@ function Jr(t, e, r) {
684
684
  );
685
685
  if (y.indexOf(_) !== -1)
686
686
  throw Error("Circular reference detected in " + f.join("."));
687
- y.push(_), $.forEach(_, function(b, T) {
688
- (!($.isUndefined(b) || b === null) && s.call(e, b, $.isString(T) ? T.trim() : T, f, v)) === !0 && S(b, f ? f.concat(T) : [T], g + 1);
687
+ y.push(_), $.forEach(_, function(b, S) {
688
+ (!($.isUndefined(b) || b === null) && s.call(e, b, $.isString(S) ? S.trim() : S, f, v)) === !0 && R(b, f ? f.concat(S) : [S], g + 1);
689
689
  }), y.pop();
690
690
  }
691
691
  }
692
692
  if (!$.isObject(t))
693
693
  throw new TypeError("data must be an object");
694
- return S(t), e;
694
+ return R(t), e;
695
695
  }
696
696
  function Is(t) {
697
697
  const e = {
@@ -813,14 +813,14 @@ self instanceof WorkerGlobalScope && typeof self.importScripts == "function", mu
813
813
  hasStandardBrowserWebWorkerEnv: hu,
814
814
  navigator: Fn,
815
815
  origin: mu
816
- }, Symbol.toStringTag, { value: "Module" })), Re = {
816
+ }, Symbol.toStringTag, { value: "Module" })), Te = {
817
817
  ...gu,
818
818
  ...fu
819
819
  };
820
820
  function yu(t, e) {
821
- return Jr(t, new Re.classes.URLSearchParams(), {
821
+ return Jr(t, new Te.classes.URLSearchParams(), {
822
822
  visitor: function(r, n, s, o) {
823
- return Re.isNode && $.isBuffer(r) ? (this.append(n, r.toString("base64")), !1) : o.defaultVisitor.apply(this, arguments);
823
+ return Te.isNode && $.isBuffer(r) ? (this.append(n, r.toString("base64")), !1) : o.defaultVisitor.apply(this, arguments);
824
824
  },
825
825
  ...e
826
826
  });
@@ -921,8 +921,8 @@ const jt = {
921
921
  maxContentLength: -1,
922
922
  maxBodyLength: -1,
923
923
  env: {
924
- FormData: Re.classes.FormData,
925
- Blob: Re.classes.Blob
924
+ FormData: Te.classes.FormData,
925
+ Blob: Te.classes.Blob
926
926
  },
927
927
  validateStatus: function(e) {
928
928
  return e >= 200 && e < 300;
@@ -938,7 +938,7 @@ $.forEach(["delete", "get", "head", "post", "put", "patch", "query"], (t) => {
938
938
  jt.headers[t] = {};
939
939
  });
940
940
  function mn(t, e) {
941
- const r = this || jt, n = e || r, s = Te.from(n.headers);
941
+ const r = this || jt, n = e || r, s = Se.from(n.headers);
942
942
  let o = n.data;
943
943
  return $.forEach(t, function(i) {
944
944
  o = i.call(r, o, s.normalize(), e ? e.status : void 0);
@@ -991,7 +991,7 @@ function vu(t, e) {
991
991
  return v ? Math.round(y * 1e3 / v) : void 0;
992
992
  };
993
993
  }
994
- function Ru(t, e) {
994
+ function Tu(t, e) {
995
995
  let r = 0, n = 1e3 / e, s, o;
996
996
  const a = (u, l = Date.now()) => {
997
997
  r = l, s = null, o && (clearTimeout(o), o = null), t(...u);
@@ -1006,7 +1006,7 @@ function Ru(t, e) {
1006
1006
  const kr = (t, e, r = 3) => {
1007
1007
  let n = 0;
1008
1008
  const s = vu(50, 250);
1009
- return Ru((o) => {
1009
+ return Tu((o) => {
1010
1010
  const a = o.loaded, i = o.lengthComputable ? o.total : void 0, c = i != null ? Math.min(a, i) : a, u = Math.max(0, c - n), l = s(u);
1011
1011
  n = Math.max(n, c);
1012
1012
  const h = {
@@ -1032,10 +1032,10 @@ const kr = (t, e, r = 3) => {
1032
1032
  }),
1033
1033
  e[1]
1034
1034
  ];
1035
- }, Cs = (t) => (...e) => $.asap(() => t(...e)), Su = Re.hasStandardBrowserEnv ? /* @__PURE__ */ ((t, e) => (r) => (r = new URL(r, Re.origin), t.protocol === r.protocol && t.host === r.host && (e || t.port === r.port)))(
1036
- new URL(Re.origin),
1037
- Re.navigator && /(msie|trident)/i.test(Re.navigator.userAgent)
1038
- ) : () => !0, Tu = Re.hasStandardBrowserEnv ? (
1035
+ }, Cs = (t) => (...e) => $.asap(() => t(...e)), Ru = Te.hasStandardBrowserEnv ? /* @__PURE__ */ ((t, e) => (r) => (r = new URL(r, Te.origin), t.protocol === r.protocol && t.host === r.host && (e || t.port === r.port)))(
1036
+ new URL(Te.origin),
1037
+ Te.navigator && /(msie|trident)/i.test(Te.navigator.userAgent)
1038
+ ) : () => !0, Su = Te.hasStandardBrowserEnv ? (
1039
1039
  // Standard browser envs support document.cookie
1040
1040
  {
1041
1041
  write(t, e, r, n, s, o, a) {
@@ -1079,7 +1079,7 @@ function Ga(t, e, r) {
1079
1079
  let n = !Ou(e);
1080
1080
  return t && (n || r === !1) ? Au(t, e) : e;
1081
1081
  }
1082
- const Ls = (t) => t instanceof Te ? { ...t } : t;
1082
+ const Ls = (t) => t instanceof Se ? { ...t } : t;
1083
1083
  function nt(t, e) {
1084
1084
  e = e || {};
1085
1085
  const r = /* @__PURE__ */ Object.create(null);
@@ -1151,8 +1151,8 @@ function nt(t, e) {
1151
1151
  };
1152
1152
  return $.forEach(Object.keys({ ...t, ...e }), function(l) {
1153
1153
  if (l === "__proto__" || l === "constructor" || l === "prototype") return;
1154
- const h = $.hasOwnProp(c, l) ? c[l] : s, y = $.hasOwnProp(t, l) ? t[l] : void 0, v = $.hasOwnProp(e, l) ? e[l] : void 0, S = h(y, v, l);
1155
- $.isUndefined(S) && h !== i || (r[l] = S);
1154
+ const h = $.hasOwnProp(c, l) ? c[l] : s, y = $.hasOwnProp(t, l) ? t[l] : void 0, v = $.hasOwnProp(e, l) ? e[l] : void 0, R = h(y, v, l);
1155
+ $.isUndefined(R) && h !== i || (r[l] = R);
1156
1156
  }), r;
1157
1157
  }
1158
1158
  const Nu = ["content-type", "content-length"];
@@ -1174,15 +1174,15 @@ const Iu = (t) => encodeURIComponent(t).replace(
1174
1174
  const o = r("xsrfHeaderName"), a = r("xsrfCookieName");
1175
1175
  let i = r("headers");
1176
1176
  const c = r("auth"), u = r("baseURL"), l = r("allowAbsoluteUrls"), h = r("url");
1177
- if (e.headers = i = Te.from(i), e.url = Ha(
1177
+ if (e.headers = i = Se.from(i), e.url = Ha(
1178
1178
  Ga(u, h, l),
1179
1179
  t.params,
1180
1180
  t.paramsSerializer
1181
1181
  ), c && i.set(
1182
1182
  "Authorization",
1183
1183
  "Basic " + btoa((c.username || "") + ":" + (c.password ? Iu(c.password) : ""))
1184
- ), $.isFormData(n) && (Re.hasStandardBrowserEnv || Re.hasStandardBrowserWebWorkerEnv ? i.setContentType(void 0) : $.isFunction(n.getHeaders) && Pu(i, n.getHeaders(), r("formDataHeaderPolicy"))), Re.hasStandardBrowserEnv && ($.isFunction(s) && (s = s(e)), s === !0 || s == null && Su(e.url))) {
1185
- const v = o && a && Tu.read(a);
1184
+ ), $.isFormData(n) && (Te.hasStandardBrowserEnv || Te.hasStandardBrowserWebWorkerEnv ? i.setContentType(void 0) : $.isFunction(n.getHeaders) && Pu(i, n.getHeaders(), r("formDataHeaderPolicy"))), Te.hasStandardBrowserEnv && ($.isFunction(s) && (s = s(e)), s === !0 || s == null && Ru(e.url))) {
1185
+ const v = o && a && Su.read(a);
1186
1186
  v && i.set(o, v);
1187
1187
  }
1188
1188
  return e;
@@ -1190,17 +1190,17 @@ const Iu = (t) => encodeURIComponent(t).replace(
1190
1190
  return new Promise(function(r, n) {
1191
1191
  const s = Ka(t);
1192
1192
  let o = s.data;
1193
- const a = Te.from(s.headers).normalize();
1194
- let { responseType: i, onUploadProgress: c, onDownloadProgress: u } = s, l, h, y, v, S;
1193
+ const a = Se.from(s.headers).normalize();
1194
+ let { responseType: i, onUploadProgress: c, onDownloadProgress: u } = s, l, h, y, v, R;
1195
1195
  function _() {
1196
- v && v(), S && S(), s.cancelToken && s.cancelToken.unsubscribe(l), s.signal && s.signal.removeEventListener("abort", l);
1196
+ v && v(), R && R(), s.cancelToken && s.cancelToken.unsubscribe(l), s.signal && s.signal.removeEventListener("abort", l);
1197
1197
  }
1198
1198
  let f = new XMLHttpRequest();
1199
1199
  f.open(s.method.toUpperCase(), s.url, !0), f.timeout = s.timeout;
1200
1200
  function g() {
1201
1201
  if (!f)
1202
1202
  return;
1203
- const b = Te.from(
1203
+ const b = Se.from(
1204
1204
  "getAllResponseHeaders" in f && f.getAllResponseHeaders()
1205
1205
  ), d = {
1206
1206
  data: !i || i === "text" || i === "json" ? f.responseText : f.response,
@@ -1224,27 +1224,27 @@ const Iu = (t) => encodeURIComponent(t).replace(
1224
1224
  !f || f.readyState !== 4 || f.status === 0 && !(f.responseURL && f.responseURL.startsWith("file:")) || setTimeout(g);
1225
1225
  }, f.onabort = function() {
1226
1226
  f && (n(new Y("Request aborted", Y.ECONNABORTED, t, f)), _(), f = null);
1227
- }, f.onerror = function(T) {
1228
- const d = T && T.message ? T.message : "Network Error", m = new Y(d, Y.ERR_NETWORK, t, f);
1229
- m.event = T || null, n(m), _(), f = null;
1227
+ }, f.onerror = function(S) {
1228
+ const d = S && S.message ? S.message : "Network Error", m = new Y(d, Y.ERR_NETWORK, t, f);
1229
+ m.event = S || null, n(m), _(), f = null;
1230
1230
  }, f.ontimeout = function() {
1231
- let T = s.timeout ? "timeout of " + s.timeout + "ms exceeded" : "timeout exceeded";
1231
+ let S = s.timeout ? "timeout of " + s.timeout + "ms exceeded" : "timeout exceeded";
1232
1232
  const d = s.transitional || es;
1233
- s.timeoutErrorMessage && (T = s.timeoutErrorMessage), n(
1233
+ s.timeoutErrorMessage && (S = s.timeoutErrorMessage), n(
1234
1234
  new Y(
1235
- T,
1235
+ S,
1236
1236
  d.clarifyTimeoutError ? Y.ETIMEDOUT : Y.ECONNABORTED,
1237
1237
  t,
1238
1238
  f
1239
1239
  )
1240
1240
  ), _(), f = null;
1241
- }, o === void 0 && a.setContentType(null), "setRequestHeader" in f && $.forEach(a.toJSON(), function(T, d) {
1242
- f.setRequestHeader(d, T);
1243
- }), $.isUndefined(s.withCredentials) || (f.withCredentials = !!s.withCredentials), i && i !== "json" && (f.responseType = s.responseType), u && ([y, S] = kr(u, !0), f.addEventListener("progress", y)), c && f.upload && ([h, v] = kr(c), f.upload.addEventListener("progress", h), f.upload.addEventListener("loadend", v)), (s.cancelToken || s.signal) && (l = (b) => {
1241
+ }, o === void 0 && a.setContentType(null), "setRequestHeader" in f && $.forEach(a.toJSON(), function(S, d) {
1242
+ f.setRequestHeader(d, S);
1243
+ }), $.isUndefined(s.withCredentials) || (f.withCredentials = !!s.withCredentials), i && i !== "json" && (f.responseType = s.responseType), u && ([y, R] = kr(u, !0), f.addEventListener("progress", y)), c && f.upload && ([h, v] = kr(c), f.upload.addEventListener("progress", h), f.upload.addEventListener("loadend", v)), (s.cancelToken || s.signal) && (l = (b) => {
1244
1244
  f && (n(!b || b.type ? new Vt(null, t, f) : b), f.abort(), _(), f = null);
1245
1245
  }, s.cancelToken && s.cancelToken.subscribe(l), s.signal && (s.signal.aborted ? l() : s.signal.addEventListener("abort", l)));
1246
1246
  const p = _u(s.url);
1247
- if (p && !Re.protocols.includes(p)) {
1247
+ if (p && !Te.protocols.includes(p)) {
1248
1248
  n(
1249
1249
  new Y(
1250
1250
  "Unsupported protocol " + p + ":",
@@ -1352,8 +1352,8 @@ function Mu(t) {
1352
1352
  const i = n.length;
1353
1353
  for (let v = 0; v < i; v++)
1354
1354
  if (n.charCodeAt(v) === 37 && v + 2 < i) {
1355
- const S = n.charCodeAt(v + 1), _ = n.charCodeAt(v + 2);
1356
- (S >= 48 && S <= 57 || S >= 65 && S <= 70 || S >= 97 && S <= 102) && (_ >= 48 && _ <= 57 || _ >= 65 && _ <= 70 || _ >= 97 && _ <= 102) && (a -= 2, v += 2);
1355
+ const R = n.charCodeAt(v + 1), _ = n.charCodeAt(v + 2);
1356
+ (R >= 48 && R <= 57 || R >= 65 && R <= 70 || R >= 97 && R <= 102) && (_ >= 48 && _ <= 57 || _ >= 65 && _ <= 70 || _ >= 97 && _ <= 102) && (a -= 2, v += 2);
1357
1357
  }
1358
1358
  let c = 0, u = i - 1;
1359
1359
  const l = (v) => v >= 2 && n.charCodeAt(v - 2) === 37 && // '%'
@@ -1403,7 +1403,7 @@ const rs = "1.16.0", ks = 64 * 1024, { isFunction: Bt } = $, Ms = (t, ...e) => {
1403
1403
  return !1;
1404
1404
  const l = i && Bt(r), h = i && (typeof n == "function" ? /* @__PURE__ */ ((g) => (p) => g.encode(p))(new n()) : async (g) => new Uint8Array(await new o(g).arrayBuffer())), y = c && l && Ms(() => {
1405
1405
  let g = !1;
1406
- const p = new o(Re.origin, {
1406
+ const p = new o(Te.origin, {
1407
1407
  body: new r(),
1408
1408
  method: "POST",
1409
1409
  get duplex() {
@@ -1411,14 +1411,14 @@ const rs = "1.16.0", ks = 64 * 1024, { isFunction: Bt } = $, Ms = (t, ...e) => {
1411
1411
  }
1412
1412
  }), b = p.headers.has("Content-Type");
1413
1413
  return p.body != null && p.body.cancel(), g && !b;
1414
- }), v = u && l && Ms(() => $.isReadableStream(new a("").body)), S = {
1414
+ }), v = u && l && Ms(() => $.isReadableStream(new a("").body)), R = {
1415
1415
  stream: v && ((g) => g.body)
1416
1416
  };
1417
1417
  i && ["text", "arrayBuffer", "blob", "formData", "stream"].forEach((g) => {
1418
- !S[g] && (S[g] = (p, b) => {
1419
- let T = p && p[g];
1420
- if (T)
1421
- return T.call(p);
1418
+ !R[g] && (R[g] = (p, b) => {
1419
+ let S = p && p[g];
1420
+ if (S)
1421
+ return S.call(p);
1422
1422
  throw new Y(
1423
1423
  `Response type '${g}' is not supported`,
1424
1424
  Y.ERR_NOT_SUPPORT,
@@ -1432,7 +1432,7 @@ const rs = "1.16.0", ks = 64 * 1024, { isFunction: Bt } = $, Ms = (t, ...e) => {
1432
1432
  if ($.isBlob(g))
1433
1433
  return g.size;
1434
1434
  if ($.isSpecCompliantForm(g))
1435
- return (await new o(Re.origin, {
1435
+ return (await new o(Te.origin, {
1436
1436
  method: "POST",
1437
1437
  body: g
1438
1438
  }).arrayBuffer()).byteLength;
@@ -1448,11 +1448,11 @@ const rs = "1.16.0", ks = 64 * 1024, { isFunction: Bt } = $, Ms = (t, ...e) => {
1448
1448
  let {
1449
1449
  url: p,
1450
1450
  method: b,
1451
- data: T,
1451
+ data: S,
1452
1452
  signal: d,
1453
1453
  cancelToken: m,
1454
1454
  timeout: w,
1455
- onDownloadProgress: R,
1455
+ onDownloadProgress: T,
1456
1456
  onUploadProgress: I,
1457
1457
  responseType: L,
1458
1458
  headers: N,
@@ -1481,7 +1481,7 @@ const rs = "1.16.0", ks = 64 * 1024, { isFunction: Bt } = $, Ms = (t, ...e) => {
1481
1481
  q
1482
1482
  );
1483
1483
  if (we && b !== "get" && b !== "head") {
1484
- const j = await f(N, T);
1484
+ const j = await f(N, S);
1485
1485
  if (typeof j == "number" && isFinite(j) && j > J)
1486
1486
  throw new Y(
1487
1487
  "Request body larger than maxBodyLength limit",
@@ -1490,23 +1490,23 @@ const rs = "1.16.0", ks = 64 * 1024, { isFunction: Bt } = $, Ms = (t, ...e) => {
1490
1490
  q
1491
1491
  );
1492
1492
  }
1493
- if (I && y && b !== "get" && b !== "head" && (U = await f(N, T)) !== 0) {
1493
+ if (I && y && b !== "get" && b !== "head" && (U = await f(N, S)) !== 0) {
1494
1494
  let j = new o(p, {
1495
1495
  method: "POST",
1496
- body: T,
1496
+ body: S,
1497
1497
  duplex: "half"
1498
1498
  }), Z;
1499
- if ($.isFormData(T) && (Z = j.headers.get("content-type")) && N.setContentType(Z), j.body) {
1499
+ if ($.isFormData(S) && (Z = j.headers.get("content-type")) && N.setContentType(Z), j.body) {
1500
1500
  const [Q, A] = Ds(
1501
1501
  U,
1502
1502
  kr(Cs(I))
1503
1503
  );
1504
- T = xs(j.body, ks, Q, A);
1504
+ S = xs(j.body, ks, Q, A);
1505
1505
  }
1506
1506
  }
1507
1507
  $.isString(k) || (k = k ? "include" : "omit");
1508
1508
  const D = c && "credentials" in o.prototype;
1509
- if ($.isFormData(T)) {
1509
+ if ($.isFormData(S)) {
1510
1510
  const j = N.getContentType();
1511
1511
  j && /^multipart\/form-data/i.test(j) && !/boundary=/i.test(j) && N.delete("content-type");
1512
1512
  }
@@ -1516,7 +1516,7 @@ const rs = "1.16.0", ks = 64 * 1024, { isFunction: Bt } = $, Ms = (t, ...e) => {
1516
1516
  signal: oe,
1517
1517
  method: b.toUpperCase(),
1518
1518
  headers: N.normalize().toJSON(),
1519
- body: T,
1519
+ body: S,
1520
1520
  duplex: "half",
1521
1521
  credentials: D ? k : void 0
1522
1522
  };
@@ -1533,14 +1533,14 @@ const rs = "1.16.0", ks = 64 * 1024, { isFunction: Bt } = $, Ms = (t, ...e) => {
1533
1533
  );
1534
1534
  }
1535
1535
  const x = v && (L === "stream" || L === "response");
1536
- if (v && O.body && (R || ne || x && P)) {
1536
+ if (v && O.body && (T || ne || x && P)) {
1537
1537
  const j = {};
1538
1538
  ["status", "statusText", "headers"].forEach((F) => {
1539
1539
  j[F] = O[F];
1540
1540
  });
1541
- const Z = $.toFiniteNumber(O.headers.get("content-length")), [Q, A] = R && Ds(
1541
+ const Z = $.toFiniteNumber(O.headers.get("content-length")), [Q, A] = T && Ds(
1542
1542
  Z,
1543
- kr(Cs(R), !0)
1543
+ kr(Cs(T), !0)
1544
1544
  ) || [];
1545
1545
  let C = 0;
1546
1546
  const M = (F) => {
@@ -1561,7 +1561,7 @@ const rs = "1.16.0", ks = 64 * 1024, { isFunction: Bt } = $, Ms = (t, ...e) => {
1561
1561
  );
1562
1562
  }
1563
1563
  L = L || "text";
1564
- let z = await S[$.findKey(S, L) || "text"](
1564
+ let z = await R[$.findKey(R, L) || "text"](
1565
1565
  O,
1566
1566
  g
1567
1567
  );
@@ -1578,7 +1578,7 @@ const rs = "1.16.0", ks = 64 * 1024, { isFunction: Bt } = $, Ms = (t, ...e) => {
1578
1578
  return !x && P && P(), await new Promise((j, Z) => {
1579
1579
  Ya(j, Z, {
1580
1580
  data: z,
1581
- headers: Te.from(O.headers),
1581
+ headers: Se.from(O.headers),
1582
1582
  status: O.status,
1583
1583
  statusText: O.statusText,
1584
1584
  config: g,
@@ -1675,7 +1675,7 @@ function gn(t) {
1675
1675
  throw new Vt(null, t);
1676
1676
  }
1677
1677
  function qs(t) {
1678
- return gn(t), t.headers = Te.from(t.headers), t.data = mn.call(t, t.transformRequest), ["post", "put", "patch"].indexOf(t.method) !== -1 && t.headers.setContentType("application/x-www-form-urlencoded", !1), Ja.getAdapter(t.adapter || jt.adapter, t)(t).then(
1678
+ return gn(t), t.headers = Se.from(t.headers), t.data = mn.call(t, t.transformRequest), ["post", "put", "patch"].indexOf(t.method) !== -1 && t.headers.setContentType("application/x-www-form-urlencoded", !1), Ja.getAdapter(t.adapter || jt.adapter, t)(t).then(
1679
1679
  function(n) {
1680
1680
  gn(t), t.response = n;
1681
1681
  try {
@@ -1683,7 +1683,7 @@ function qs(t) {
1683
1683
  } finally {
1684
1684
  delete t.response;
1685
1685
  }
1686
- return n.headers = Te.from(n.headers), n;
1686
+ return n.headers = Se.from(n.headers), n;
1687
1687
  },
1688
1688
  function(n) {
1689
1689
  if (!za(n) && (gn(t), n && n.response)) {
@@ -1697,7 +1697,7 @@ function qs(t) {
1697
1697
  } finally {
1698
1698
  delete t.response;
1699
1699
  }
1700
- n.response.headers = Te.from(n.response.headers);
1700
+ n.response.headers = Se.from(n.response.headers);
1701
1701
  }
1702
1702
  return Promise.reject(n);
1703
1703
  }
@@ -1830,9 +1830,9 @@ let tt = class {
1830
1830
  !0
1831
1831
  ), r.method = (r.method || this.defaults.method || "get").toLowerCase();
1832
1832
  let a = o && $.merge(o.common, o[r.method]);
1833
- o && $.forEach(["delete", "get", "head", "post", "put", "patch", "query", "common"], (S) => {
1834
- delete o[S];
1835
- }), r.headers = Te.concat(a, o);
1833
+ o && $.forEach(["delete", "get", "head", "post", "put", "patch", "query", "common"], (R) => {
1834
+ delete o[R];
1835
+ }), r.headers = Se.concat(a, o);
1836
1836
  const i = [];
1837
1837
  let c = !0;
1838
1838
  this.interceptors.request.forEach(function(_) {
@@ -1848,17 +1848,17 @@ let tt = class {
1848
1848
  });
1849
1849
  let l, h = 0, y;
1850
1850
  if (!c) {
1851
- const S = [qs.bind(this), void 0];
1852
- for (S.unshift(...i), S.push(...u), y = S.length, l = Promise.resolve(r); h < y; )
1853
- l = l.then(S[h++], S[h++]);
1851
+ const R = [qs.bind(this), void 0];
1852
+ for (R.unshift(...i), R.push(...u), y = R.length, l = Promise.resolve(r); h < y; )
1853
+ l = l.then(R[h++], R[h++]);
1854
1854
  return l;
1855
1855
  }
1856
1856
  y = i.length;
1857
1857
  let v = r;
1858
1858
  for (; h < y; ) {
1859
- const S = i[h++], _ = i[h++];
1859
+ const R = i[h++], _ = i[h++];
1860
1860
  try {
1861
- v = S(v);
1861
+ v = R(v);
1862
1862
  } catch (f) {
1863
1863
  _.call(this, f);
1864
1864
  break;
@@ -1866,8 +1866,8 @@ let tt = class {
1866
1866
  }
1867
1867
  try {
1868
1868
  l = qs.call(this, v);
1869
- } catch (S) {
1870
- return Promise.reject(S);
1869
+ } catch (R) {
1870
+ return Promise.reject(R);
1871
1871
  }
1872
1872
  for (h = 0, y = u.length; h < y; )
1873
1873
  l = l.then(u[h++], u[h++]);
@@ -2083,7 +2083,7 @@ pe.all = function(e) {
2083
2083
  pe.spread = Bu;
2084
2084
  pe.isAxiosError = zu;
2085
2085
  pe.mergeConfig = nt;
2086
- pe.AxiosHeaders = Te;
2086
+ pe.AxiosHeaders = Se;
2087
2087
  pe.formToJSON = (t) => Ba($.isHTMLForm(t) ? new FormData(t) : t);
2088
2088
  pe.getAdapter = Ja.getAdapter;
2089
2089
  pe.HttpStatusCode = jn;
@@ -2310,7 +2310,7 @@ Ge.interceptors.response.use(
2310
2310
  return r.startsWith("ERROR_") || /^[A-Z_]+$/.test(r) ? Promise.reject(new Error(r)) : Promise.reject(`${e}: ${r}`);
2311
2311
  }
2312
2312
  );
2313
- const H = async (t, e) => (await Ge.get(t, e)).data, ve = async (t, e) => (await Ge.post(t, e)).data, is = async (t, e) => (await Ge.put(t, e)).data, hw = async (t, e) => (await Ge.patch(t, e)).data, ti = async (t) => (await Ge.delete(t)).data, W = (t) => typeof t == "string", Tt = () => {
2313
+ const H = async (t, e) => (await Ge.get(t, e)).data, ve = async (t, e) => (await Ge.post(t, e)).data, is = async (t, e) => (await Ge.put(t, e)).data, hw = async (t, e) => (await Ge.patch(t, e)).data, ti = async (t) => (await Ge.delete(t)).data, W = (t) => typeof t == "string", St = () => {
2314
2314
  let t, e;
2315
2315
  const r = new Promise((n, s) => {
2316
2316
  t = n, e = s;
@@ -2663,25 +2663,25 @@ class jr extends Xr {
2663
2663
  }
2664
2664
  const h = this.resolve(e, r);
2665
2665
  let y = h?.res;
2666
- const v = h?.usedKey || a, S = h?.exactUsedKey || a, _ = ["[object Number]", "[object Function]", "[object RegExp]"], f = r.joinArrays !== void 0 ? r.joinArrays : this.options.joinArrays, g = !this.i18nFormat || this.i18nFormat.handleAsObject, p = r.count !== void 0 && !W(r.count), b = jr.hasDefaultValue(r), T = p ? this.pluralResolver.getSuffix(u, r.count, r) : "", d = r.ordinal && p ? this.pluralResolver.getSuffix(u, r.count, {
2666
+ const v = h?.usedKey || a, R = h?.exactUsedKey || a, _ = ["[object Number]", "[object Function]", "[object RegExp]"], f = r.joinArrays !== void 0 ? r.joinArrays : this.options.joinArrays, g = !this.i18nFormat || this.i18nFormat.handleAsObject, p = r.count !== void 0 && !W(r.count), b = jr.hasDefaultValue(r), S = p ? this.pluralResolver.getSuffix(u, r.count, r) : "", d = r.ordinal && p ? this.pluralResolver.getSuffix(u, r.count, {
2667
2667
  ordinal: !1
2668
- }) : "", m = p && !r.ordinal && r.count === 0, w = m && r[`defaultValue${this.options.pluralSeparator}zero`] || r[`defaultValue${T}`] || r[`defaultValue${d}`] || r.defaultValue;
2669
- let R = y;
2670
- g && !y && b && (R = w);
2671
- const I = Ks(R), L = Object.prototype.toString.apply(R);
2672
- if (g && R && I && _.indexOf(L) < 0 && !(W(f) && Array.isArray(R))) {
2668
+ }) : "", m = p && !r.ordinal && r.count === 0, w = m && r[`defaultValue${this.options.pluralSeparator}zero`] || r[`defaultValue${S}`] || r[`defaultValue${d}`] || r.defaultValue;
2669
+ let T = y;
2670
+ g && !y && b && (T = w);
2671
+ const I = Ks(T), L = Object.prototype.toString.apply(T);
2672
+ if (g && T && I && _.indexOf(L) < 0 && !(W(f) && Array.isArray(T))) {
2673
2673
  if (!r.returnObjects && !this.options.returnObjects) {
2674
2674
  this.options.returnedObjectHandler || this.logger.warn("accessing an object - but returnObjects options is not enabled!");
2675
- const N = this.options.returnedObjectHandler ? this.options.returnedObjectHandler(v, R, {
2675
+ const N = this.options.returnedObjectHandler ? this.options.returnedObjectHandler(v, T, {
2676
2676
  ...r,
2677
2677
  ns: i
2678
2678
  }) : `key '${a} (${this.language})' returned an object instead of string.`;
2679
2679
  return s ? (h.res = N, h.usedParams = this.getUsedParamsDetails(r), h) : N;
2680
2680
  }
2681
2681
  if (o) {
2682
- const N = Array.isArray(R), k = N ? [] : {}, B = N ? S : v;
2683
- for (const V in R)
2684
- if (Object.prototype.hasOwnProperty.call(R, V)) {
2682
+ const N = Array.isArray(T), k = N ? [] : {}, B = N ? R : v;
2683
+ for (const V in T)
2684
+ if (Object.prototype.hasOwnProperty.call(T, V)) {
2685
2685
  const J = `${B}${o}${V}`;
2686
2686
  b && !y ? k[V] = this.translate(J, {
2687
2687
  ...r,
@@ -2692,7 +2692,7 @@ class jr extends Xr {
2692
2692
  ...r,
2693
2693
  joinArrays: !1,
2694
2694
  ns: i
2695
- }), k[V] === J && (k[V] = R[V]);
2695
+ }), k[V] === J && (k[V] = T[V]);
2696
2696
  }
2697
2697
  y = k;
2698
2698
  }
@@ -2763,8 +2763,8 @@ class jr extends Xr {
2763
2763
  l < v && (n.nest = !1);
2764
2764
  }
2765
2765
  !n.lng && s && s.res && (n.lng = this.language || s.usedLng), n.nest !== !1 && (e = this.interpolator.nest(e, function() {
2766
- for (var y = arguments.length, v = new Array(y), S = 0; S < y; S++)
2767
- v[S] = arguments[S];
2766
+ for (var y = arguments.length, v = new Array(y), R = 0; R < y; R++)
2767
+ v[R] = arguments[R];
2768
2768
  return o?.[0] === v[0] && !n.context ? (a.logger.warn(`It seems you are nesting recursively key: ${v[0]} in key: ${r[0]}`), null) : a.translate(...v, r);
2769
2769
  }, n)), n.interpolation && this.interpolator.reset();
2770
2770
  }
@@ -2785,7 +2785,7 @@ class jr extends Xr {
2785
2785
  s = l;
2786
2786
  let h = u.namespaces;
2787
2787
  this.options.fallbackNS && (h = h.concat(this.options.fallbackNS));
2788
- const y = r.count !== void 0 && !W(r.count), v = y && !r.ordinal && r.count === 0, S = r.context !== void 0 && (W(r.context) || typeof r.context == "number") && r.context !== "", _ = r.lngs ? r.lngs : this.languageUtils.toResolveHierarchy(r.lng || this.language, r.fallbackLng);
2788
+ const y = r.count !== void 0 && !W(r.count), v = y && !r.ordinal && r.count === 0, R = r.context !== void 0 && (W(r.context) || typeof r.context == "number") && r.context !== "", _ = r.lngs ? r.lngs : this.languageUtils.toResolveHierarchy(r.lng || this.language, r.fallbackLng);
2789
2789
  h.forEach((f) => {
2790
2790
  this.isValidLookup(n) || (i = f, !Gs[`${_[0]}-${f}`] && this.utils?.hasLoadedNamespace && !this.utils?.hasLoadedNamespace(i) && (Gs[`${_[0]}-${f}`] = !0, this.logger.warn(`key "${s}" for languages "${_.join(", ")}" won't get resolved as namespace "${i}" was not yet loaded`, "This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")), _.forEach((g) => {
2791
2791
  if (this.isValidLookup(n)) return;
@@ -2794,12 +2794,12 @@ class jr extends Xr {
2794
2794
  if (this.i18nFormat?.addLookupKeys)
2795
2795
  this.i18nFormat.addLookupKeys(p, l, g, f, r);
2796
2796
  else {
2797
- let T;
2798
- y && (T = this.pluralResolver.getSuffix(g, r.count, r));
2797
+ let S;
2798
+ y && (S = this.pluralResolver.getSuffix(g, r.count, r));
2799
2799
  const d = `${this.options.pluralSeparator}zero`, m = `${this.options.pluralSeparator}ordinal${this.options.pluralSeparator}`;
2800
- if (y && (p.push(l + T), r.ordinal && T.indexOf(m) === 0 && p.push(l + T.replace(m, this.options.pluralSeparator)), v && p.push(l + d)), S) {
2800
+ if (y && (p.push(l + S), r.ordinal && S.indexOf(m) === 0 && p.push(l + S.replace(m, this.options.pluralSeparator)), v && p.push(l + d)), R) {
2801
2801
  const w = `${l}${this.options.contextSeparator}${r.context}`;
2802
- p.push(w), y && (p.push(w + T), r.ordinal && T.indexOf(m) === 0 && p.push(w + T.replace(m, this.options.pluralSeparator)), v && p.push(w + d));
2802
+ p.push(w), y && (p.push(w + S), r.ordinal && S.indexOf(m) === 0 && p.push(w + S.replace(m, this.options.pluralSeparator)), v && p.push(w + d));
2803
2803
  }
2804
2804
  }
2805
2805
  let b;
@@ -2976,7 +2976,7 @@ const Xs = function(t, e, r) {
2976
2976
  let n = arguments.length > 3 && arguments[3] !== void 0 ? arguments[3] : ".", s = arguments.length > 4 && arguments[4] !== void 0 ? arguments[4] : !0, o = hl(t, e, r);
2977
2977
  return !o && s && W(r) && (o = Hn(t, r, n), o === void 0 && (o = Hn(e, r, n))), o;
2978
2978
  }, bn = (t) => t.replace(/\$/g, "$$$$");
2979
- class Rl {
2979
+ class Tl {
2980
2980
  constructor() {
2981
2981
  let e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
2982
2982
  this.logger = qe.create("interpolator"), this.options = e, this.format = e?.interpolation?.format || ((r) => r), this.init(e);
@@ -2999,13 +2999,13 @@ class Rl {
2999
2999
  unescapePrefix: h,
3000
3000
  nestingPrefix: y,
3001
3001
  nestingPrefixEscaped: v,
3002
- nestingSuffix: S,
3002
+ nestingSuffix: R,
3003
3003
  nestingSuffixEscaped: _,
3004
3004
  nestingOptionsSeparator: f,
3005
3005
  maxReplaces: g,
3006
3006
  alwaysFormat: p
3007
3007
  } = e.interpolation;
3008
- this.escape = r !== void 0 ? r : gl, this.escapeValue = n !== void 0 ? n : !0, this.useRawValueToEscape = s !== void 0 ? s : !1, this.prefix = o ? at(o) : a || "{{", this.suffix = i ? at(i) : c || "}}", this.formatSeparator = u || ",", this.unescapePrefix = l ? "" : h || "-", this.unescapeSuffix = this.unescapePrefix ? "" : l || "", this.nestingPrefix = y ? at(y) : v || at("$t("), this.nestingSuffix = S ? at(S) : _ || at(")"), this.nestingOptionsSeparator = f || ",", this.maxReplaces = g || 1e3, this.alwaysFormat = p !== void 0 ? p : !1, this.resetRegExp();
3008
+ this.escape = r !== void 0 ? r : gl, this.escapeValue = n !== void 0 ? n : !0, this.useRawValueToEscape = s !== void 0 ? s : !1, this.prefix = o ? at(o) : a || "{{", this.suffix = i ? at(i) : c || "}}", this.formatSeparator = u || ",", this.unescapePrefix = l ? "" : h || "-", this.unescapeSuffix = this.unescapePrefix ? "" : l || "", this.nestingPrefix = y ? at(y) : v || at("$t("), this.nestingSuffix = R ? at(R) : _ || at(")"), this.nestingOptionsSeparator = f || ",", this.maxReplaces = g || 1e3, this.alwaysFormat = p !== void 0 ? p : !1, this.resetRegExp();
3009
3009
  }
3010
3010
  reset() {
3011
3011
  this.options && this.init(this.options);
@@ -3025,7 +3025,7 @@ class Rl {
3025
3025
  interpolationkey: v
3026
3026
  }) : g;
3027
3027
  }
3028
- const S = v.split(this.formatSeparator), _ = S.shift().trim(), f = S.join(this.formatSeparator).trim();
3028
+ const R = v.split(this.formatSeparator), _ = R.shift().trim(), f = R.join(this.formatSeparator).trim();
3029
3029
  return this.format(Xs(r, c, _, this.options.keySeparator, this.options.ignoreJSONStructure), f, n, {
3030
3030
  ...s,
3031
3031
  ...r,
@@ -3042,18 +3042,18 @@ class Rl {
3042
3042
  safeValue: (v) => this.escapeValue ? bn(this.escape(v)) : bn(v)
3043
3043
  }].forEach((v) => {
3044
3044
  for (i = 0; o = v.regex.exec(e); ) {
3045
- const S = o[1].trim();
3046
- if (a = u(S), a === void 0)
3045
+ const R = o[1].trim();
3046
+ if (a = u(R), a === void 0)
3047
3047
  if (typeof l == "function") {
3048
3048
  const f = l(e, o, s);
3049
3049
  a = W(f) ? f : "";
3050
- } else if (s && Object.prototype.hasOwnProperty.call(s, S))
3050
+ } else if (s && Object.prototype.hasOwnProperty.call(s, R))
3051
3051
  a = "";
3052
3052
  else if (h) {
3053
3053
  a = o[0];
3054
3054
  continue;
3055
3055
  } else
3056
- this.logger.warn(`missed to pass in variable ${S} for interpolating ${e}`), a = "";
3056
+ this.logger.warn(`missed to pass in variable ${R} for interpolating ${e}`), a = "";
3057
3057
  else !W(a) && !this.useRawValueToEscape && (a = Vs(a));
3058
3058
  const _ = v.safeValue(a);
3059
3059
  if (e = e.replace(o[0], _), h ? (v.regex.lastIndex += a.length, v.regex.lastIndex -= o[0].length) : v.regex.lastIndex = 0, i++, i >= this.maxReplaces)
@@ -3069,8 +3069,8 @@ class Rl {
3069
3069
  const h = c.split(new RegExp(`${l}[ ]*{`));
3070
3070
  let y = `{${h[1]}`;
3071
3071
  c = h[0], y = this.interpolate(y, a);
3072
- const v = y.match(/'/g), S = y.match(/"/g);
3073
- ((v?.length ?? 0) % 2 === 0 && !S || S.length % 2 !== 0) && (y = y.replace(/'/g, '"'));
3072
+ const v = y.match(/'/g), R = y.match(/"/g);
3073
+ ((v?.length ?? 0) % 2 === 0 && !R || R.length % 2 !== 0) && (y = y.replace(/'/g, '"'));
3074
3074
  try {
3075
3075
  a = JSON.parse(y), u && (a = {
3076
3076
  ...u,
@@ -3100,7 +3100,7 @@ class Rl {
3100
3100
  return e;
3101
3101
  }
3102
3102
  }
3103
- const Sl = (t) => {
3103
+ const Rl = (t) => {
3104
3104
  let e = t.toLowerCase().trim();
3105
3105
  const r = {};
3106
3106
  if (t.indexOf("(") > -1) {
@@ -3131,7 +3131,7 @@ const Sl = (t) => {
3131
3131
  return i || (i = t(qr(n), s), e[a] = i), i(r);
3132
3132
  };
3133
3133
  };
3134
- class Tl {
3134
+ class Sl {
3135
3135
  constructor() {
3136
3136
  let e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
3137
3137
  this.logger = qe.create("formatter"), this.options = e, this.formats = {
@@ -3191,7 +3191,7 @@ class Tl {
3191
3191
  const {
3192
3192
  formatName: u,
3193
3193
  formatOptions: l
3194
- } = Sl(c);
3194
+ } = Rl(c);
3195
3195
  if (this.formats[u]) {
3196
3196
  let h = i;
3197
3197
  try {
@@ -3441,21 +3441,21 @@ class kt extends Xr {
3441
3441
  if (!this.options.isClone) {
3442
3442
  this.modules.logger ? qe.init(o(this.modules.logger), this.options) : qe.init(null, this.options);
3443
3443
  let l;
3444
- this.modules.formatter ? l = this.modules.formatter : l = Tl;
3444
+ this.modules.formatter ? l = this.modules.formatter : l = Sl;
3445
3445
  const h = new Ws(this.options);
3446
3446
  this.store = new Ys(this.options.resources, this.options);
3447
3447
  const y = this.services;
3448
3448
  y.logger = qe, y.resourceStore = this.store, y.languageUtils = h, y.pluralResolver = new vl(h, {
3449
3449
  prepend: this.options.pluralSeparator,
3450
3450
  simplifyPluralSuffix: this.options.simplifyPluralSuffix
3451
- }), l && (!this.options.interpolation.format || this.options.interpolation.format === s.interpolation.format) && (y.formatter = o(l), y.formatter.init(y, this.options), this.options.interpolation.format = y.formatter.format.bind(y.formatter)), y.interpolator = new Rl(this.options), y.utils = {
3451
+ }), l && (!this.options.interpolation.format || this.options.interpolation.format === s.interpolation.format) && (y.formatter = o(l), y.formatter.init(y, this.options), this.options.interpolation.format = y.formatter.format.bind(y.formatter)), y.interpolator = new Tl(this.options), y.utils = {
3452
3452
  hasLoadedNamespace: this.hasLoadedNamespace.bind(this)
3453
3453
  }, y.backendConnector = new Al(o(this.modules.backend), y.resourceStore, y, this.options), y.backendConnector.on("*", function(v) {
3454
- for (var S = arguments.length, _ = new Array(S > 1 ? S - 1 : 0), f = 1; f < S; f++)
3454
+ for (var R = arguments.length, _ = new Array(R > 1 ? R - 1 : 0), f = 1; f < R; f++)
3455
3455
  _[f - 1] = arguments[f];
3456
3456
  e.emit(v, ..._);
3457
3457
  }), this.modules.languageDetector && (y.languageDetector = o(this.modules.languageDetector), y.languageDetector.init && y.languageDetector.init(y, this.options.detection, this.options)), this.modules.i18nFormat && (y.i18nFormat = o(this.modules.i18nFormat), y.i18nFormat.init && y.i18nFormat.init(this)), this.translator = new jr(this.services, this.options), this.translator.on("*", function(v) {
3458
- for (var S = arguments.length, _ = new Array(S > 1 ? S - 1 : 0), f = 1; f < S; f++)
3458
+ for (var R = arguments.length, _ = new Array(R > 1 ? R - 1 : 0), f = 1; f < R; f++)
3459
3459
  _[f - 1] = arguments[f];
3460
3460
  e.emit(v, ..._);
3461
3461
  }), this.modules.external.forEach((v) => {
@@ -3475,7 +3475,7 @@ class kt extends Xr {
3475
3475
  return e.store[l](...arguments), e;
3476
3476
  };
3477
3477
  });
3478
- const c = Tt(), u = () => {
3478
+ const c = St(), u = () => {
3479
3479
  const l = (h, y) => {
3480
3480
  this.isInitializing = !1, this.isInitialized && !this.initializedStoreOnce && this.logger.warn("init: i18next is already initialized. You should call init just once!"), this.isInitialized = !0, this.options.isClone || this.logger.log("initialized", this.options), this.emit("initialized", this.options), c.resolve(y), n(h, y);
3481
3481
  };
@@ -3502,7 +3502,7 @@ class kt extends Xr {
3502
3502
  n(null);
3503
3503
  }
3504
3504
  reloadResources(e, r, n) {
3505
- const s = Tt();
3505
+ const s = St();
3506
3506
  return typeof e == "function" && (n = e, e = void 0), typeof r == "function" && (n = r, r = void 0), e || (e = this.languages), r || (r = this.options.ns), n || (n = zt), this.services.backendConnector.reload(e, r, (o) => {
3507
3507
  s.resolve(), n(o);
3508
3508
  }), s;
@@ -3525,7 +3525,7 @@ class kt extends Xr {
3525
3525
  changeLanguage(e, r) {
3526
3526
  var n = this;
3527
3527
  this.isLanguageChangingTo = e;
3528
- const s = Tt();
3528
+ const s = St();
3529
3529
  this.emit("languageChanging", e);
3530
3530
  const o = (c) => {
3531
3531
  this.language = c, this.languages = this.services.languageUtils.toResolveHierarchy(c), this.resolvedLanguage = void 0, this.setResolvedLanguage(c);
@@ -3559,7 +3559,7 @@ class kt extends Xr {
3559
3559
  c.lng = c.lng || o.lng, c.lngs = c.lngs || o.lngs, c.ns = c.ns || o.ns, c.keyPrefix !== "" && (c.keyPrefix = c.keyPrefix || n || o.keyPrefix);
3560
3560
  const y = s.options.keySeparator || ".";
3561
3561
  let v;
3562
- return c.keyPrefix && Array.isArray(a) ? v = a.map((S) => `${c.keyPrefix}${y}${S}`) : v = c.keyPrefix ? `${c.keyPrefix}${y}${a}` : a, s.t(v, c);
3562
+ return c.keyPrefix && Array.isArray(a) ? v = a.map((R) => `${c.keyPrefix}${y}${R}`) : v = c.keyPrefix ? `${c.keyPrefix}${y}${a}` : a, s.t(v, c);
3563
3563
  };
3564
3564
  return W(e) ? o.lng = e : o.lngs = e, o.ns = r, o.keyPrefix = n, o;
3565
3565
  }
@@ -3595,7 +3595,7 @@ class kt extends Xr {
3595
3595
  return !!(this.hasResourceBundle(n, e) || !this.services.backendConnector.backend || this.options.resources && !this.options.partialBundledLanguages || a(n, e) && (!s || a(o, e)));
3596
3596
  }
3597
3597
  loadNamespaces(e, r) {
3598
- const n = Tt();
3598
+ const n = St();
3599
3599
  return this.options.ns ? (W(e) && (e = [e]), e.forEach((s) => {
3600
3600
  this.options.ns.indexOf(s) < 0 && this.options.ns.push(s);
3601
3601
  }), this.loadResources((s) => {
@@ -3603,7 +3603,7 @@ class kt extends Xr {
3603
3603
  }), n) : (r && r(), Promise.resolve());
3604
3604
  }
3605
3605
  loadLanguages(e, r) {
3606
- const n = Tt();
3606
+ const n = St();
3607
3607
  W(e) && (e = [e]);
3608
3608
  const s = this.options.preload || [], o = e.filter((a) => s.indexOf(a) < 0 && this.services.languageUtils.isSupportedCode(a));
3609
3609
  return o.length ? (this.options.preload = s.concat(o), this.loadResources((a) => {
@@ -4066,9 +4066,9 @@ function yw() {
4066
4066
  const h = document.createElement("canvas"), y = h.getContext("2d");
4067
4067
  if (y) {
4068
4068
  if (o && a) {
4069
- const v = o / a, S = u / l;
4069
+ const v = o / a, R = u / l;
4070
4070
  let _ = 0, f = 0, g = u, p = l;
4071
- S > v ? (g = Math.round(l * v), _ = Math.round((u - g) / 2)) : (p = Math.round(u / v), f = Math.round((l - p) / 2)), h.width = o, h.height = a, y.drawImage(
4071
+ R > v ? (g = Math.round(l * v), _ = Math.round((u - g) / 2)) : (p = Math.round(u / v), f = Math.round((l - p) / 2)), h.width = o, h.height = a, y.drawImage(
4072
4072
  c,
4073
4073
  _,
4074
4074
  f,
@@ -4121,7 +4121,7 @@ function Ql(t) {
4121
4121
  function _w(t, e) {
4122
4122
  document.cookie = `${t}=${e}; path=/;`;
4123
4123
  }
4124
- const vw = (t) => !t || t.trim().length === 0, Rw = (t, e) => {
4124
+ const vw = (t) => !t || t.trim().length === 0, Tw = (t, e) => {
4125
4125
  if (!t || !e || e.length === 0)
4126
4126
  return 999;
4127
4127
  const r = e.findIndex(
@@ -4129,7 +4129,7 @@ const vw = (t) => !t || t.trim().length === 0, Rw = (t, e) => {
4129
4129
  );
4130
4130
  return r === -1 ? 999 : r;
4131
4131
  };
4132
- function Sw(t, e) {
4132
+ function Rw(t, e) {
4133
4133
  if (!t || t.length === 0)
4134
4134
  return [];
4135
4135
  const r = /* @__PURE__ */ new Map();
@@ -4141,7 +4141,7 @@ function Sw(t, e) {
4141
4141
  items: s
4142
4142
  }));
4143
4143
  }
4144
- function Tw(t, e, r) {
4144
+ function Sw(t, e, r) {
4145
4145
  if (!t || t.length === 0)
4146
4146
  return [];
4147
4147
  const n = /* @__PURE__ */ new Set(), s = /* @__PURE__ */ new Set();
@@ -4288,10 +4288,10 @@ const cs = () => {
4288
4288
  }, fi = K + "/idgen/identifiertype", fd = (t) => K + `/bahmni/app/setting?module=${t}`, pd = "bahmni.primaryIdentifierType", hd = K + "/bahmnicore/patientprofile", md = (t) => K + `/bahmnicore/patientprofile/${t}`, gd = ae + "/Patient", yd = (t) => K + `/idgen/identifiersource/${t}/identifier`, wd = (t) => K + `/patientprofile/${t}?v=full`, Ed = (t, e, r = 20, n) => {
4289
4289
  let s = `/openmrs/module/addresshierarchy/ajax/getPossibleAddressHierarchyEntriesWithParents.form?addressField=${t}&limit=${r}&searchString=${encodeURIComponent(e)}`;
4290
4290
  return n && (s += `&parent=${n}`), s;
4291
- }, bd = "/openmrs/module/addresshierarchy/ajax/getOrderedAddressHierarchyLevels.form", _d = K + "/relationshiptype?v=custom:(aIsToB,bIsToA,uuid)&limit=150", vd = 20, Rd = 2, Mw = 120, Uw = 50, qw = 15, Sd = /^[a-f0-9-]{36}$/i, Td = K + "/personattributetype?v=custom:(uuid,name,sortWeight,description,format,concept:(uuid,display,answers:(uuid,name)))", Od = async (t) => {
4291
+ }, bd = "/openmrs/module/addresshierarchy/ajax/getOrderedAddressHierarchyLevels.form", _d = K + "/relationshiptype?v=custom:(aIsToB,bIsToA,uuid)&limit=150", vd = 20, Td = 2, Mw = 120, Uw = 50, qw = 15, Rd = /^[a-f0-9-]{36}$/i, Sd = K + "/personattributetype?v=custom:(uuid,name,sortWeight,description,format,concept:(uuid,display,answers:(uuid,name)))", Od = async (t) => {
4292
4292
  if (!t || t.trim() === "")
4293
4293
  throw new Error("Invalid patient UUID: UUID cannot be empty");
4294
- if (!Sd.test(t))
4294
+ if (!Rd.test(t))
4295
4295
  throw new Error(`Invalid patient UUID format: ${t}`);
4296
4296
  return H(di(t));
4297
4297
  }, Ad = (t) => !t.extension || !Array.isArray(t.extension) ? [] : t.extension.flatMap((e) => e.extension && Array.isArray(e.extension) ? e.extension.filter((r) => r.valueString).map((r) => r.valueString) : []), Nd = (t) => {
@@ -4382,7 +4382,7 @@ const cs = () => {
4382
4382
  md(t),
4383
4383
  e
4384
4384
  ), Kw = (t) => ve(gd, t), Ww = (t) => ve(yd(t), {}), Jw = (t, e) => is(di(t), e), Qw = async () => H(ci("mrs.genders")), Xw = async (t, e, r = vd, n) => {
4385
- if (!e || e.length < Rd)
4385
+ if (!e || e.length < Td)
4386
4386
  return [];
4387
4387
  try {
4388
4388
  return await H(
@@ -4407,7 +4407,7 @@ const cs = () => {
4407
4407
  `Failed to fetch relationship types: ${t instanceof Error ? t.message : "Unknown error"}`
4408
4408
  );
4409
4409
  }
4410
- }, rE = async () => H(Td);
4410
+ }, rE = async () => H(Sd);
4411
4411
  var Cd = /* @__PURE__ */ ((t) => (t.BOOLEAN = "java.lang.Boolean", t.BOOLEAN_DATATYPE = "org.openmrs.customdatatype.datatype.BooleanDatatype", t.CONCEPT = "org.openmrs.Concept", t.CODED_CONCEPT = "org.bahmni.module.bahmnicore.customdatatype.datatype.CodedConceptDatatype", t.CONCEPT_DATATYPE = "org.openmrs.customdatatype.datatype.ConceptDatatype", t.STRING = "java.lang.String", t.FREE_TEXT = "org.openmrs.customdatatype.datatype.FreeTextDatatype", t.REGEX_VALIDATED_TEXT = "org.openmrs.customdatatype.datatype.RegexValidatedTextDatatype", t.INTEGER = "java.lang.Integer", t.FLOAT = "java.lang.Float", t.ATTRIBUTABLE_DATE = "org.openmrs.util.AttributableDate", t.DATE_DATATYPE = "org.openmrs.customdatatype.datatype.DateDatatype", t))(Cd || {}), Ld = /* @__PURE__ */ ((t) => (t.CHECKBOX = "checkbox", t.DROPDOWN = "dropdown", t.TEXT = "text", t.NUMBER = "number", t.DATE = "date", t))(Ld || {});
4412
4412
  const nE = (t) => t === "java.lang.Boolean" || t === "org.openmrs.customdatatype.datatype.BooleanDatatype" ? "checkbox" : t === "org.openmrs.Concept" || t === "org.bahmni.module.bahmnicore.customdatatype.datatype.CodedConceptDatatype" || t === "org.openmrs.customdatatype.datatype.ConceptDatatype" ? "dropdown" : t === "java.lang.Integer" || t === "java.lang.Float" ? "number" : t === "org.openmrs.util.AttributableDate" || t === "org.openmrs.customdatatype.datatype.DateDatatype" ? "date" : "text", sE = (t) => t === "java.lang.Boolean" || t === "org.openmrs.customdatatype.datatype.BooleanDatatype", oE = (t) => t === "org.openmrs.Concept" || t === "org.bahmni.module.bahmnicore.customdatatype.datatype.CodedConceptDatatype" || t === "org.openmrs.customdatatype.datatype.ConceptDatatype", aE = (t) => t === "java.lang.Integer" || t === "java.lang.Float", iE = (t) => t === "org.openmrs.util.AttributableDate" || t === "org.openmrs.customdatatype.datatype.DateDatatype", cE = (t) => t === "java.lang.String" || t === "org.openmrs.customdatatype.datatype.FreeTextDatatype" || t === "org.openmrs.customdatatype.datatype.RegexValidatedTextDatatype", xd = (t) => {
4413
4413
  const e = new CustomEvent("bahmni-audit-log", { detail: t });
@@ -4460,6 +4460,10 @@ const nE = (t) => t === "java.lang.Boolean" || t === "org.openmrs.customdatatype
4460
4460
  eventType: "VIEWED_RADIOLOGY_RESULTS",
4461
4461
  message: "VIEWED_RADIOLOGY_RESULTS_MESSAGE"
4462
4462
  },
4463
+ STOP_MEDICATION: {
4464
+ eventType: "STOP_MEDICATION",
4465
+ message: "STOP_MEDICATION_MESSAGE"
4466
+ },
4463
4467
  CREATE_ENCOUNTER: {
4464
4468
  eventType: "CREATE_ENCOUNTER",
4465
4469
  message: "CREATE_ENCOUNTER_MESSAGE",
@@ -4959,7 +4963,7 @@ function vf(t, e) {
4959
4963
  if (e(t[r]))
4960
4964
  return r;
4961
4965
  }
4962
- function Rf(t) {
4966
+ function Tf(t) {
4963
4967
  return (e, r = {}) => {
4964
4968
  const n = e.match(t.matchPattern);
4965
4969
  if (!n) return null;
@@ -4971,7 +4975,7 @@ function Rf(t) {
4971
4975
  return { value: a, rest: i };
4972
4976
  };
4973
4977
  }
4974
- const Sf = /^(\d+)(th|st|nd|rd)?/i, Tf = /\d+/i, Of = {
4978
+ const Rf = /^(\d+)(th|st|nd|rd)?/i, Sf = /\d+/i, Of = {
4975
4979
  narrow: /^(b|a)/i,
4976
4980
  abbreviated: /^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,
4977
4981
  wide: /^(before christ|before common era|anno domini|common era)/i
@@ -5039,9 +5043,9 @@ const Sf = /^(\d+)(th|st|nd|rd)?/i, Tf = /\d+/i, Of = {
5039
5043
  night: /night/i
5040
5044
  }
5041
5045
  }, kf = {
5042
- ordinalNumber: Rf({
5043
- matchPattern: Sf,
5044
- parsePattern: Tf,
5046
+ ordinalNumber: Tf({
5047
+ matchPattern: Rf,
5048
+ parsePattern: Sf,
5045
5049
  valueCallback: (t) => parseInt(t, 10)
5046
5050
  }),
5047
5051
  era: At({
@@ -5830,13 +5834,13 @@ function Zf(t) {
5830
5834
  return typeof t == "function" && t.prototype?.constructor === t;
5831
5835
  }
5832
5836
  const ep = 10;
5833
- class Ri {
5837
+ class Ti {
5834
5838
  subPriority = 0;
5835
5839
  validate(e, r) {
5836
5840
  return !0;
5837
5841
  }
5838
5842
  }
5839
- class tp extends Ri {
5843
+ class tp extends Ti {
5840
5844
  constructor(e, r, n, s, o) {
5841
5845
  super(), this.value = e, this.validateValue = r, this.setValue = n, this.priority = s, o && (this.subPriority = o);
5842
5846
  }
@@ -5847,7 +5851,7 @@ class tp extends Ri {
5847
5851
  return this.setValue(e, r, this.value, n);
5848
5852
  }
5849
5853
  }
5850
- class rp extends Ri {
5854
+ class rp extends Ti {
5851
5855
  priority = ep;
5852
5856
  subPriority = -1;
5853
5857
  constructor(e, r) {
@@ -5969,7 +5973,7 @@ function Ue(t, e) {
5969
5973
  rest: e.slice(r[0].length)
5970
5974
  };
5971
5975
  }
5972
- function Si(t) {
5976
+ function Ri(t) {
5973
5977
  return fe(me.anyDigitsSigned, t);
5974
5978
  }
5975
5979
  function he(t, e) {
@@ -6014,7 +6018,7 @@ function ms(t) {
6014
6018
  return 0;
6015
6019
  }
6016
6020
  }
6017
- function Ti(t, e) {
6021
+ function Si(t, e) {
6018
6022
  const r = e > 0, n = r ? e : 1 - e;
6019
6023
  let s;
6020
6024
  if (n <= 50)
@@ -6056,7 +6060,7 @@ class sp extends ie {
6056
6060
  set(e, r, n) {
6057
6061
  const s = e.getFullYear();
6058
6062
  if (n.isTwoDigitYear) {
6059
- const a = Ti(
6063
+ const a = Si(
6060
6064
  n.year,
6061
6065
  s
6062
6066
  );
@@ -6093,7 +6097,7 @@ class op extends ie {
6093
6097
  set(e, r, n, s) {
6094
6098
  const o = hs(e, s);
6095
6099
  if (n.isTwoDigitYear) {
6096
- const i = Ti(
6100
+ const i = Si(
6097
6101
  n.year,
6098
6102
  o
6099
6103
  );
@@ -6746,11 +6750,11 @@ class vp extends ie {
6746
6750
  "T"
6747
6751
  ];
6748
6752
  }
6749
- function Rp(t, e, r) {
6753
+ function Tp(t, e, r) {
6750
6754
  const n = de(t, r?.in), s = Qf(n, r), o = e - s;
6751
6755
  return tn(n, o, r);
6752
6756
  }
6753
- class Sp extends ie {
6757
+ class Rp extends ie {
6754
6758
  priority = 90;
6755
6759
  parse(e, r, n) {
6756
6760
  const s = (o) => o === 0 ? 7 : o;
@@ -6821,7 +6825,7 @@ class Sp extends ie {
6821
6825
  return r >= 1 && r <= 7;
6822
6826
  }
6823
6827
  set(e, r, n) {
6824
- return e = Rp(e, n), e.setHours(0, 0, 0, 0), e;
6828
+ return e = Tp(e, n), e.setHours(0, 0, 0, 0), e;
6825
6829
  }
6826
6830
  incompatibleTokens = [
6827
6831
  "y",
@@ -6841,7 +6845,7 @@ class Sp extends ie {
6841
6845
  "T"
6842
6846
  ];
6843
6847
  }
6844
- class Tp extends ie {
6848
+ class Sp extends ie {
6845
6849
  priority = 80;
6846
6850
  parse(e, r, n) {
6847
6851
  switch (r) {
@@ -7154,7 +7158,7 @@ class kp extends ie {
7154
7158
  class Mp extends ie {
7155
7159
  priority = 40;
7156
7160
  parse(e) {
7157
- return Si(e);
7161
+ return Ri(e);
7158
7162
  }
7159
7163
  set(e, r, n) {
7160
7164
  return [ye(e, n * 1e3), { timestampIsSet: !0 }];
@@ -7164,7 +7168,7 @@ class Mp extends ie {
7164
7168
  class Up extends ie {
7165
7169
  priority = 20;
7166
7170
  parse(e) {
7167
- return Si(e);
7171
+ return Ri(e);
7168
7172
  }
7169
7173
  set(e, r, n) {
7170
7174
  return [ye(e, n), { timestampIsSet: !0 }];
@@ -7188,8 +7192,8 @@ const qp = {
7188
7192
  E: new bp(),
7189
7193
  e: new _p(),
7190
7194
  c: new vp(),
7191
- i: new Sp(),
7192
- a: new Tp(),
7195
+ i: new Rp(),
7196
+ a: new Sp(),
7193
7197
  b: new Op(),
7194
7198
  B: new Ap(),
7195
7199
  h: new Np(),
@@ -7235,15 +7239,15 @@ function Yp(t, e, r, n) {
7235
7239
  `The format string mustn't contain \`${f}\` and any other token at the same time`
7236
7240
  );
7237
7241
  y.push({ token: g, fullToken: f });
7238
- const T = p.run(
7242
+ const S = p.run(
7239
7243
  t,
7240
7244
  f,
7241
7245
  a.match,
7242
7246
  u
7243
7247
  );
7244
- if (!T)
7248
+ if (!S)
7245
7249
  return s();
7246
- l.push(T.setter), t = T.rest;
7250
+ l.push(S.setter), t = S.rest;
7247
7251
  } else {
7248
7252
  if (g.match(zp))
7249
7253
  throw new RangeError(
@@ -7260,16 +7264,16 @@ function Yp(t, e, r, n) {
7260
7264
  const v = l.map((f) => f.priority).sort((f, g) => g - f).filter((f, g, p) => p.indexOf(f) === g).map(
7261
7265
  (f) => l.filter((g) => g.priority === f).sort((g, p) => p.subPriority - g.subPriority)
7262
7266
  ).map((f) => f[0]);
7263
- let S = de(r, n?.in);
7264
- if (isNaN(+S)) return s();
7267
+ let R = de(r, n?.in);
7268
+ if (isNaN(+R)) return s();
7265
7269
  const _ = {};
7266
7270
  for (const f of v) {
7267
- if (!f.validate(S, u))
7271
+ if (!f.validate(R, u))
7268
7272
  return s();
7269
- const g = f.set(S, _, u);
7270
- Array.isArray(g) ? (S = g[0], Object.assign(_, g[1])) : S = g;
7273
+ const g = f.set(R, _, u);
7274
+ Array.isArray(g) ? (R = g[0], Object.assign(_, g[1])) : R = g;
7271
7275
  }
7272
- return S;
7276
+ return R;
7273
7277
  }
7274
7278
  function Gp(t) {
7275
7279
  return t.match(Vp)[1].replace(Hp, "'");
@@ -7447,9 +7451,9 @@ async function vE(t, e = 10, r = 1) {
7447
7451
  );
7448
7452
  return { bundle: s, total: s.total ?? s.entry?.length ?? 0 };
7449
7453
  }
7450
- const RE = async () => await H(Pi), SE = async (t) => {
7454
+ const TE = async () => await H(Pi), RE = async (t) => {
7451
7455
  await ve(Pi, t);
7452
- }, Ii = "dd/MM/yyyy", vh = "default_dateFormat", Rh = "h:mm a", TE = "yyyy-MM-dd", De = {
7456
+ }, Ii = "dd/MM/yyyy", vh = "default_dateFormat", Th = "h:mm a", SE = "yyyy-MM-dd", De = {
7453
7457
  PARSE_ERROR: "DATE_ERROR_PARSE",
7454
7458
  FORMAT_ERROR: "DATE_ERROR_FORMAT",
7455
7459
  EMPTY_OR_INVALID: "DATE_ERROR_EMPTY_OR_INVALID",
@@ -7484,7 +7488,7 @@ function $i(t, e) {
7484
7488
  }
7485
7489
  };
7486
7490
  }
7487
- function Sh(t, e, r) {
7491
+ function Rh(t, e, r) {
7488
7492
  if (t == null)
7489
7493
  return {
7490
7494
  formattedResult: "",
@@ -7512,7 +7516,7 @@ function Sh(t, e, r) {
7512
7516
  }
7513
7517
  } : { formattedResult: vi(n, e) };
7514
7518
  }
7515
- function Th() {
7519
+ function Sh() {
7516
7520
  try {
7517
7521
  const t = new Intl.DateTimeFormat().formatToParts(/* @__PURE__ */ new Date()), e = {
7518
7522
  day: "dd",
@@ -7528,11 +7532,11 @@ function AE(t, e, r = !1, n) {
7528
7532
  const s = e ?? ((a) => a);
7529
7533
  let o;
7530
7534
  try {
7531
- o = n ?? localStorage.getItem(vh) ?? Th();
7535
+ o = n ?? localStorage.getItem(vh) ?? Sh();
7532
7536
  } catch {
7533
7537
  o = Ii;
7534
7538
  }
7535
- return r && !n && (o = `${o} ${Rh}`), Sh(t, o, s);
7539
+ return r && !n && (o = `${o} ${Th}`), Rh(t, o, s);
7536
7540
  }
7537
7541
  function NE(t, e, r) {
7538
7542
  if (!t || !vt(t) || e === null || e === void 0 || !r || typeof e != "number")
@@ -7616,8 +7620,8 @@ function $E(t, e) {
7616
7620
  days: " days"
7617
7621
  }, h = zn(n, r);
7618
7622
  if (h <= 90) {
7619
- const S = e ? e(u.days, { count: h }) : l.days;
7620
- return `${h}${S}`;
7623
+ const R = e ? e(u.days, { count: h }) : l.days;
7624
+ return `${h}${R}`;
7621
7625
  }
7622
7626
  return (s >= 1 ? [
7623
7627
  [s, u.years, l.years],
@@ -7626,9 +7630,9 @@ function $E(t, e) {
7626
7630
  ] : [
7627
7631
  [a, u.months, l.months],
7628
7632
  [c, u.days, l.days]
7629
- ]).map(([S, _, f]) => {
7630
- const g = e ? e(_, { count: S }) : f;
7631
- return `${S}${g}`;
7633
+ ]).map(([R, _, f]) => {
7634
+ const g = e ? e(_, { count: R }) : f;
7635
+ return `${R}${g}`;
7632
7636
  }).join(" ");
7633
7637
  }
7634
7638
  const Oh = {
@@ -7742,7 +7746,7 @@ const Uh = (t) => ae + `/AllergyIntolerance?patient=${t}&_count=100&_sort=-_last
7742
7746
  uuid: t.code ?? "",
7743
7747
  display: t.display ?? "",
7744
7748
  type: e
7745
- }), Rn = (t, e) => {
7749
+ }), Tn = (t, e) => {
7746
7750
  const r = t.expansion?.contains ?? [];
7747
7751
  return Fh(r).map((s) => jh(s, e));
7748
7752
  }, FE = async (t, e, r) => {
@@ -7752,15 +7756,15 @@ const Uh = (t) => ae + `/AllergyIntolerance?patient=${t}&_count=100&_sort=-_last
7752
7756
  Lr(o)
7753
7757
  ]);
7754
7758
  return [
7755
- ...Rn(
7759
+ ...Tn(
7756
7760
  a,
7757
7761
  dt.MEDICATION.display
7758
7762
  ),
7759
- ...Rn(
7763
+ ...Tn(
7760
7764
  i,
7761
7765
  dt.FOOD.display
7762
7766
  ),
7763
- ...Rn(
7767
+ ...Tn(
7764
7768
  c,
7765
7769
  dt.ENVIRONMENT.display
7766
7770
  )
@@ -7832,20 +7836,23 @@ function HE(t) {
7832
7836
  const BE = "http://fhir.openmrs.org/code-system/encounter-type", zE = "http://terminology.hl7.org/CodeSystem/v3-ActCode", YE = "http://fhir.openmrs.org/ext/encounter-tag", Di = "problem-list-item", GE = "http://terminology.hl7.org/CodeSystem/condition-ver-status", Ci = "encounter-diagnosis", Gh = "http://terminology.hl7.org/CodeSystem/condition-clinical", KE = "http://terminology.hl7.org/CodeSystem/condition-category", WE = "http://fhir.bahmni.org/ext/lab-order-concept-type", JE = "http://terminology.hl7.org/CodeSystem/v3-ObservationInterpretation", QE = "http://fhir.bahmni.org/ext/observation/form-namespace-path", XE = "http://fhir.bahmni.org/ext/observation/obs-value-attachment", ZE = "Numeric", eb = "Complex", tb = "final", rb = "Observation", nb = /^\d{4}-\d{2}-\d{2}/, Kh = /^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}/, sb = {
7833
7837
  ABNORMAL: { code: "A", display: "Abnormal" },
7834
7838
  NORMAL: { code: "N", display: "Normal" }
7835
- }, Wh = ae + "/Condition", Jh = (t) => ae + `/Condition?category=${Di}&patient=${t}&_count=100&_sort=-_lastUpdated`, Qh = (t, e = 10, r = 0) => ae + `/Condition?category=${Di}&patient=${t}&_count=${e}&_getpagesoffset=${r}&_sort=-_lastUpdated`;
7839
+ }, Wh = ae + "/Condition", Jh = (t) => ae + `/Condition?category=${Di}&patient=${t}&_count=100&_sort=-_lastUpdated`, Qh = (t, e = 10, r = 0, n) => {
7840
+ const s = ae + `/Condition?category=${Di}&patient=${t}&_count=${e}&_getpagesoffset=${r}&_sort=-_lastUpdated`;
7841
+ return n ? `${s}&clinical-status=${n}` : s;
7842
+ };
7836
7843
  async function Xh(t) {
7837
7844
  return await H(`${Jh(t)}`);
7838
7845
  }
7839
7846
  async function ob(t) {
7840
7847
  return (await Xh(t)).entry?.filter((n) => n.resource?.resourceType === "Condition").map((n) => n.resource) ?? [];
7841
7848
  }
7842
- async function ab(t, e = 10, r = 1) {
7843
- const n = (r - 1) * e, s = await H(
7844
- Qh(t, e, n)
7849
+ async function ab(t, e = 10, r = 1, n) {
7850
+ const s = (r - 1) * e, o = await H(
7851
+ Qh(t, e, s, n)
7845
7852
  );
7846
7853
  return {
7847
- conditions: s.entry?.filter((a) => a.resource?.resourceType === "Condition").map((a) => a.resource) ?? [],
7848
- total: s.total
7854
+ conditions: o.entry?.filter((i) => i.resource?.resourceType === "Condition").map((i) => i.resource) ?? [],
7855
+ total: o.total
7849
7856
  };
7850
7857
  }
7851
7858
  async function ib(t) {
@@ -7867,7 +7874,7 @@ async function ib(t) {
7867
7874
  e
7868
7875
  );
7869
7876
  }
7870
- const Zh = (t) => ae + `/Condition?category=${Ci}&patient=${t}&_count=100&_sort=-_lastUpdated`, em = (t, e = 10, r = 0) => ae + `/Condition?category=${Ci}&patient=${t}&_count=${e}&_getpagesoffset=${r}&_sort=-_lastUpdated`, Sn = [
7877
+ const Zh = (t) => ae + `/Condition?category=${Ci}&patient=${t}&_count=100&_sort=-_lastUpdated`, em = (t, e = 10, r = 0) => ae + `/Condition?category=${Ci}&patient=${t}&_count=${e}&_getpagesoffset=${r}&_sort=-_lastUpdated`, Rn = [
7871
7878
  {
7872
7879
  code: "confirmed",
7873
7880
  display: "CERTAINITY_CONFIRMED",
@@ -7890,11 +7897,11 @@ async function sm(t, e, r) {
7890
7897
  const om = (t) => {
7891
7898
  switch (t.verificationStatus?.coding?.[0]?.code) {
7892
7899
  case tm:
7893
- return Sn[0];
7900
+ return Rn[0];
7894
7901
  case rm:
7895
- return Sn[1];
7902
+ return Rn[1];
7896
7903
  default:
7897
- return Sn[1];
7904
+ return Rn[1];
7898
7905
  }
7899
7906
  }, am = (t) => !!(t.id && t.code && t.recordedDate);
7900
7907
  function Li(t) {
@@ -8029,7 +8036,7 @@ function _m(t) {
8029
8036
  function vm(t) {
8030
8037
  return !t || t.length === 0 ? "" : t.map((e) => e.text).filter(Boolean).join(" ");
8031
8038
  }
8032
- function Rm(t, e, r) {
8039
+ function Tm(t, e, r) {
8033
8040
  if (t?.display)
8034
8041
  return t.display;
8035
8042
  if (t?.reference) {
@@ -8045,7 +8052,7 @@ function Rm(t, e, r) {
8045
8052
  );
8046
8053
  return n?.code?.text ? n.code.text : t?.reference ? t.reference : "Medication";
8047
8054
  }
8048
- function Sm(t, e, r) {
8055
+ function Rm(t, e, r) {
8049
8056
  if (t?.reference) {
8050
8057
  const s = t.reference.split("/").pop();
8051
8058
  if (s) {
@@ -8059,7 +8066,7 @@ function Sm(t, e, r) {
8059
8066
  );
8060
8067
  return n?.form ? n.form.text ?? n.form.coding?.[0]?.display ?? "" : "";
8061
8068
  }
8062
- function Tm(t) {
8069
+ function Sm(t) {
8063
8070
  const e = t.entry?.filter((n) => {
8064
8071
  const s = n.resource;
8065
8072
  return s?.resourceType === "MedicationRequest" && !!s?.id;
@@ -8068,11 +8075,11 @@ function Tm(t) {
8068
8075
  const s = n.resource;
8069
8076
  s.resourceType === "Medication" && r.set(s.id, s);
8070
8077
  }), e.map((n) => {
8071
- const s = n.medicationReference, o = n.requester, a = pm(n), i = Rm(
8078
+ const s = n.medicationReference, o = n.requester, a = pm(n), i = Tm(
8072
8079
  s,
8073
8080
  n,
8074
8081
  r
8075
- ), c = Sm(
8082
+ ), c = Rm(
8076
8083
  s,
8077
8084
  n,
8078
8085
  r
@@ -8098,6 +8105,14 @@ function Tm(t) {
8098
8105
  ),
8099
8106
  note: vm(n.note),
8100
8107
  doseForm: c,
8108
+ statusReason: n.statusReason?.text ?? n.statusReason?.coding?.[0]?.display ?? void 0,
8109
+ dateStopped: (() => {
8110
+ const u = n.extension?.find(
8111
+ (l) => l.url === "http://fhir.bahmni.org/ext/medicationRequest/dateStopped"
8112
+ // NOSONAR
8113
+ );
8114
+ return u?.valueDateTime ?? u?.valueDate;
8115
+ })(),
8101
8116
  fhirResource: n
8102
8117
  };
8103
8118
  });
@@ -8110,7 +8125,7 @@ async function db(t, e, r, n = !1) {
8110
8125
  r,
8111
8126
  n
8112
8127
  );
8113
- return Tm(s);
8128
+ return Sm(s);
8114
8129
  }
8115
8130
  async function fb() {
8116
8131
  return await H(
@@ -8194,17 +8209,17 @@ async function vb(t) {
8194
8209
  const e = $m(t);
8195
8210
  return await H(e);
8196
8211
  }
8197
- async function Rb(t, e) {
8212
+ async function Tb(t, e) {
8198
8213
  const r = Dm(t);
8199
8214
  return await ve(r, e);
8200
8215
  }
8201
- const Sb = [
8216
+ const Rb = [
8202
8217
  "preliminary",
8203
8218
  "final",
8204
8219
  "amended",
8205
8220
  "corrected",
8206
8221
  "appended"
8207
- ], Tb = [
8222
+ ], Sb = [
8208
8223
  "registered",
8209
8224
  "unknown",
8210
8225
  "partial"
@@ -8268,7 +8283,7 @@ const Sb = [
8268
8283
  function jm(t) {
8269
8284
  return t && t.__esModule && Object.prototype.hasOwnProperty.call(t, "default") ? t.default : t;
8270
8285
  }
8271
- var Gt = { exports: {} }, Tn = {}, Fe = {}, We = {}, On = {}, An = {}, Nn = {}, go;
8286
+ var Gt = { exports: {} }, Sn = {}, Fe = {}, We = {}, On = {}, An = {}, Nn = {}, go;
8272
8287
  function Br() {
8273
8288
  return go || (go = 1, (function(t) {
8274
8289
  Object.defineProperty(t, "__esModule", { value: !0 }), t.regexpCode = t.getEsmExportName = t.getProperty = t.safeStringify = t.stringify = t.strConcat = t.addCodeArg = t.str = t._ = t.nil = t._Code = t.Name = t.IDENTIFIER = t._CodeOrName = void 0;
@@ -8307,28 +8322,28 @@ function Br() {
8307
8322
  }
8308
8323
  get str() {
8309
8324
  var p;
8310
- return (p = this._str) !== null && p !== void 0 ? p : this._str = this._items.reduce((b, T) => `${b}${T}`, "");
8325
+ return (p = this._str) !== null && p !== void 0 ? p : this._str = this._items.reduce((b, S) => `${b}${S}`, "");
8311
8326
  }
8312
8327
  get names() {
8313
8328
  var p;
8314
- return (p = this._names) !== null && p !== void 0 ? p : this._names = this._items.reduce((b, T) => (T instanceof r && (b[T.str] = (b[T.str] || 0) + 1), b), {});
8329
+ return (p = this._names) !== null && p !== void 0 ? p : this._names = this._items.reduce((b, S) => (S instanceof r && (b[S.str] = (b[S.str] || 0) + 1), b), {});
8315
8330
  }
8316
8331
  }
8317
8332
  t._Code = n, t.nil = new n("");
8318
8333
  function s(g, ...p) {
8319
8334
  const b = [g[0]];
8320
- let T = 0;
8321
- for (; T < p.length; )
8322
- i(b, p[T]), b.push(g[++T]);
8335
+ let S = 0;
8336
+ for (; S < p.length; )
8337
+ i(b, p[S]), b.push(g[++S]);
8323
8338
  return new n(b);
8324
8339
  }
8325
8340
  t._ = s;
8326
8341
  const o = new n("+");
8327
8342
  function a(g, ...p) {
8328
8343
  const b = [v(g[0])];
8329
- let T = 0;
8330
- for (; T < p.length; )
8331
- b.push(o), i(b, p[T]), b.push(o, v(g[++T]));
8344
+ let S = 0;
8345
+ for (; S < p.length; )
8346
+ b.push(o), i(b, p[S]), b.push(o, v(g[++S]));
8332
8347
  return c(b), new n(b);
8333
8348
  }
8334
8349
  t.str = a;
@@ -8375,10 +8390,10 @@ function Br() {
8375
8390
  return JSON.stringify(g).replace(/\u2028/g, "\\u2028").replace(/\u2029/g, "\\u2029");
8376
8391
  }
8377
8392
  t.safeStringify = v;
8378
- function S(g) {
8393
+ function R(g) {
8379
8394
  return typeof g == "string" && t.IDENTIFIER.test(g) ? new n(`.${g}`) : s`[${g}]`;
8380
8395
  }
8381
- t.getProperty = S;
8396
+ t.getProperty = R;
8382
8397
  function _(g) {
8383
8398
  if (typeof g == "string" && t.IDENTIFIER.test(g))
8384
8399
  return new n(`${g}`);
@@ -8455,15 +8470,15 @@ function wo() {
8455
8470
  var h;
8456
8471
  if (l.ref === void 0)
8457
8472
  throw new Error("CodeGen: ref must be passed in value");
8458
- const y = this.toName(u), { prefix: v } = y, S = (h = l.key) !== null && h !== void 0 ? h : l.ref;
8473
+ const y = this.toName(u), { prefix: v } = y, R = (h = l.key) !== null && h !== void 0 ? h : l.ref;
8459
8474
  let _ = this._values[v];
8460
8475
  if (_) {
8461
- const p = _.get(S);
8476
+ const p = _.get(R);
8462
8477
  if (p)
8463
8478
  return p;
8464
8479
  } else
8465
8480
  _ = this._values[v] = /* @__PURE__ */ new Map();
8466
- _.set(S, y);
8481
+ _.set(R, y);
8467
8482
  const f = this._scope[v] || (this._scope[v] = []), g = f.length;
8468
8483
  return f[g] = l.ref, y.setValue(l, { property: v, itemIndex: g }), y;
8469
8484
  }
@@ -8488,11 +8503,11 @@ function wo() {
8488
8503
  }
8489
8504
  _reduceValues(u, l, h = {}, y) {
8490
8505
  let v = e.nil;
8491
- for (const S in u) {
8492
- const _ = u[S];
8506
+ for (const R in u) {
8507
+ const _ = u[R];
8493
8508
  if (!_)
8494
8509
  continue;
8495
- const f = h[S] = h[S] || /* @__PURE__ */ new Map();
8510
+ const f = h[R] = h[R] || /* @__PURE__ */ new Map();
8496
8511
  _.forEach((g) => {
8497
8512
  if (f.has(g))
8498
8513
  return;
@@ -8679,17 +8694,17 @@ function te() {
8679
8694
  return this.nodes.reduce((E, O) => k(E, O.names), {});
8680
8695
  }
8681
8696
  }
8682
- class S extends v {
8697
+ class R extends v {
8683
8698
  render(E) {
8684
8699
  return "{" + E._n + super.render(E) + "}" + E._n;
8685
8700
  }
8686
8701
  }
8687
8702
  class _ extends v {
8688
8703
  }
8689
- class f extends S {
8704
+ class f extends R {
8690
8705
  }
8691
8706
  f.kind = "else";
8692
- class g extends S {
8707
+ class g extends R {
8693
8708
  constructor(E, O) {
8694
8709
  super(O), this.condition = E;
8695
8710
  }
@@ -8723,7 +8738,7 @@ function te() {
8723
8738
  }
8724
8739
  }
8725
8740
  g.kind = "if";
8726
- class p extends S {
8741
+ class p extends R {
8727
8742
  }
8728
8743
  p.kind = "for";
8729
8744
  class b extends p {
@@ -8741,7 +8756,7 @@ function te() {
8741
8756
  return k(super.names, this.iteration.names);
8742
8757
  }
8743
8758
  }
8744
- class T extends p {
8759
+ class S extends p {
8745
8760
  constructor(E, O, x, z) {
8746
8761
  super(), this.varKind = E, this.name = O, this.from = x, this.to = z;
8747
8762
  }
@@ -8769,7 +8784,7 @@ function te() {
8769
8784
  return k(super.names, this.iterable.names);
8770
8785
  }
8771
8786
  }
8772
- class m extends S {
8787
+ class m extends R {
8773
8788
  constructor(E, O, x) {
8774
8789
  super(), this.name = E, this.args = O, this.async = x;
8775
8790
  }
@@ -8784,7 +8799,7 @@ function te() {
8784
8799
  }
8785
8800
  }
8786
8801
  w.kind = "return";
8787
- class R extends S {
8802
+ class T extends R {
8788
8803
  render(E) {
8789
8804
  let O = "try" + super.render(E);
8790
8805
  return this.catch && (O += this.catch.render(E)), this.finally && (O += this.finally.render(E)), O;
@@ -8802,7 +8817,7 @@ function te() {
8802
8817
  return this.catch && k(E, this.catch.names), this.finally && k(E, this.finally.names), E;
8803
8818
  }
8804
8819
  }
8805
- class I extends S {
8820
+ class I extends R {
8806
8821
  constructor(E) {
8807
8822
  super(), this.error = E;
8808
8823
  }
@@ -8811,7 +8826,7 @@ function te() {
8811
8826
  }
8812
8827
  }
8813
8828
  I.kind = "catch";
8814
- class L extends S {
8829
+ class L extends R {
8815
8830
  render(E) {
8816
8831
  return "finally" + super.render(E);
8817
8832
  }
@@ -8916,7 +8931,7 @@ function te() {
8916
8931
  // `for` statement for a range of values
8917
8932
  forRange(E, O, x, z, j = this.opts.es5 ? r.varKinds.var : r.varKinds.let) {
8918
8933
  const Z = this._scope.toName(E);
8919
- return this._for(new T(j, Z, O, x), () => z(Z));
8934
+ return this._for(new S(j, Z, O, x), () => z(Z));
8920
8935
  }
8921
8936
  // `for-of` statement (in es5 mode replace with a normal for loop)
8922
8937
  forOf(E, O, x, z = r.varKinds.const) {
@@ -8960,7 +8975,7 @@ function te() {
8960
8975
  try(E, O, x) {
8961
8976
  if (!O && !x)
8962
8977
  throw new Error('CodeGen: "try" without "catch" and "finally"');
8963
- const z = new R();
8978
+ const z = new T();
8964
8979
  if (this._blockNode(z), this.code(E), O) {
8965
8980
  const j = this.name("e");
8966
8981
  this._currNode = z.catch = new I(j), O(j);
@@ -9093,12 +9108,12 @@ function se() {
9093
9108
  }
9094
9109
  X.alwaysValidSchema = n;
9095
9110
  function s(d, m = d.schema) {
9096
- const { opts: w, self: R } = d;
9111
+ const { opts: w, self: T } = d;
9097
9112
  if (!w.strictSchema || typeof m == "boolean")
9098
9113
  return;
9099
- const I = R.RULES.keywords;
9114
+ const I = T.RULES.keywords;
9100
9115
  for (const L in m)
9101
- I[L] || T(d, `unknown keyword: "${L}"`);
9116
+ I[L] || S(d, `unknown keyword: "${L}"`);
9102
9117
  }
9103
9118
  X.checkUnknownRules = s;
9104
9119
  function o(d, m) {
@@ -9119,14 +9134,14 @@ function se() {
9119
9134
  return !1;
9120
9135
  }
9121
9136
  X.schemaHasRulesButRef = a;
9122
- function i({ topSchemaRef: d, schemaPath: m }, w, R, I) {
9137
+ function i({ topSchemaRef: d, schemaPath: m }, w, T, I) {
9123
9138
  if (!I) {
9124
9139
  if (typeof w == "number" || typeof w == "boolean")
9125
9140
  return w;
9126
9141
  if (typeof w == "string")
9127
9142
  return (0, t._)`${w}`;
9128
9143
  }
9129
- return (0, t._)`${d}${m}${(0, t.getProperty)(R)}`;
9144
+ return (0, t._)`${d}${m}${(0, t.getProperty)(T)}`;
9130
9145
  }
9131
9146
  X.schemaRefOrVal = i;
9132
9147
  function c(d) {
@@ -9153,10 +9168,10 @@ function se() {
9153
9168
  m(d);
9154
9169
  }
9155
9170
  X.eachItem = y;
9156
- function v({ mergeNames: d, mergeToName: m, mergeValues: w, resultToName: R }) {
9171
+ function v({ mergeNames: d, mergeToName: m, mergeValues: w, resultToName: T }) {
9157
9172
  return (I, L, N, k) => {
9158
9173
  const B = N === void 0 ? L : N instanceof t.Name ? (L instanceof t.Name ? d(I, L, N) : m(I, L, N), N) : L instanceof t.Name ? (m(I, N, L), L) : w(L, N);
9159
- return k === t.Name && !(B instanceof t.Name) ? R(I, B) : B;
9174
+ return k === t.Name && !(B instanceof t.Name) ? T(I, B) : B;
9160
9175
  };
9161
9176
  }
9162
9177
  X.mergeEvaluated = {
@@ -9168,7 +9183,7 @@ function se() {
9168
9183
  m === !0 ? d.assign(w, !0) : (d.assign(w, (0, t._)`${w} || {}`), _(d, w, m));
9169
9184
  }),
9170
9185
  mergeValues: (d, m) => d === !0 ? !0 : { ...d, ...m },
9171
- resultToName: S
9186
+ resultToName: R
9172
9187
  }),
9173
9188
  items: v({
9174
9189
  mergeNames: (d, m, w) => d.if((0, t._)`${w} !== true && ${m} !== undefined`, () => d.assign(w, (0, t._)`${m} === true ? true : ${w} > ${m} ? ${w} : ${m}`)),
@@ -9177,15 +9192,15 @@ function se() {
9177
9192
  resultToName: (d, m) => d.var("items", m)
9178
9193
  })
9179
9194
  };
9180
- function S(d, m) {
9195
+ function R(d, m) {
9181
9196
  if (m === !0)
9182
9197
  return d.var("props", !0);
9183
9198
  const w = d.var("props", (0, t._)`{}`);
9184
9199
  return m !== void 0 && _(d, w, m), w;
9185
9200
  }
9186
- X.evaluatedPropsToName = S;
9201
+ X.evaluatedPropsToName = R;
9187
9202
  function _(d, m, w) {
9188
- Object.keys(w).forEach((R) => d.assign((0, t._)`${m}${(0, t.getProperty)(R)}`, !0));
9203
+ Object.keys(w).forEach((T) => d.assign((0, t._)`${m}${(0, t.getProperty)(T)}`, !0));
9189
9204
  }
9190
9205
  X.setEvaluated = _;
9191
9206
  const f = {};
@@ -9202,20 +9217,20 @@ function se() {
9202
9217
  })(p || (X.Type = p = {}));
9203
9218
  function b(d, m, w) {
9204
9219
  if (d instanceof t.Name) {
9205
- const R = m === p.Num;
9206
- return w ? R ? (0, t._)`"[" + ${d} + "]"` : (0, t._)`"['" + ${d} + "']"` : R ? (0, t._)`"/" + ${d}` : (0, t._)`"/" + ${d}.replace(/~/g, "~0").replace(/\\//g, "~1")`;
9220
+ const T = m === p.Num;
9221
+ return w ? T ? (0, t._)`"[" + ${d} + "]"` : (0, t._)`"['" + ${d} + "']"` : T ? (0, t._)`"/" + ${d}` : (0, t._)`"/" + ${d}.replace(/~/g, "~0").replace(/\\//g, "~1")`;
9207
9222
  }
9208
9223
  return w ? (0, t.getProperty)(d).toString() : "/" + l(d);
9209
9224
  }
9210
9225
  X.getErrorPath = b;
9211
- function T(d, m, w = d.opts.strictSchema) {
9226
+ function S(d, m, w = d.opts.strictSchema) {
9212
9227
  if (w) {
9213
9228
  if (m = `strict mode: ${m}`, w === !0)
9214
9229
  throw new Error(m);
9215
9230
  d.self.logger.warn(m);
9216
9231
  }
9217
9232
  }
9218
- return X.checkStrictMode = T, X;
9233
+ return X.checkStrictMode = S, X;
9219
9234
  }
9220
9235
  var Kt = {}, _o;
9221
9236
  function Ke() {
@@ -9263,24 +9278,24 @@ function sn() {
9263
9278
  message: ({ keyword: f, schemaType: g }) => g ? (0, e.str)`"${f}" keyword must be ${g} ($data)` : (0, e.str)`"${f}" keyword is invalid ($data)`
9264
9279
  };
9265
9280
  function s(f, g = t.keywordError, p, b) {
9266
- const { it: T } = f, { gen: d, compositeRule: m, allErrors: w } = T, R = h(f, g, p);
9267
- b ?? (m || w) ? c(d, R) : u(T, (0, e._)`[${R}]`);
9281
+ const { it: S } = f, { gen: d, compositeRule: m, allErrors: w } = S, T = h(f, g, p);
9282
+ b ?? (m || w) ? c(d, T) : u(S, (0, e._)`[${T}]`);
9268
9283
  }
9269
9284
  t.reportError = s;
9270
9285
  function o(f, g = t.keywordError, p) {
9271
- const { it: b } = f, { gen: T, compositeRule: d, allErrors: m } = b, w = h(f, g, p);
9272
- c(T, w), d || m || u(b, n.default.vErrors);
9286
+ const { it: b } = f, { gen: S, compositeRule: d, allErrors: m } = b, w = h(f, g, p);
9287
+ c(S, w), d || m || u(b, n.default.vErrors);
9273
9288
  }
9274
9289
  t.reportExtraError = o;
9275
9290
  function a(f, g) {
9276
9291
  f.assign(n.default.errors, g), f.if((0, e._)`${n.default.vErrors} !== null`, () => f.if(g, () => f.assign((0, e._)`${n.default.vErrors}.length`, g), () => f.assign(n.default.vErrors, null)));
9277
9292
  }
9278
9293
  t.resetErrorsCount = a;
9279
- function i({ gen: f, keyword: g, schemaValue: p, data: b, errsCount: T, it: d }) {
9280
- if (T === void 0)
9294
+ function i({ gen: f, keyword: g, schemaValue: p, data: b, errsCount: S, it: d }) {
9295
+ if (S === void 0)
9281
9296
  throw new Error("ajv implementation error");
9282
9297
  const m = f.name("err");
9283
- f.forRange("i", T, n.default.errors, (w) => {
9298
+ f.forRange("i", S, n.default.errors, (w) => {
9284
9299
  f.const(m, (0, e._)`${n.default.vErrors}[${w}]`), f.if((0, e._)`${m}.instancePath === undefined`, () => f.assign((0, e._)`${m}.instancePath`, (0, e.strConcat)(n.default.instancePath, d.errorPath))), f.assign((0, e._)`${m}.schemaPath`, (0, e.str)`${d.errSchemaPath}/${g}`), d.opts.verbose && (f.assign((0, e._)`${m}.schema`, p), f.assign((0, e._)`${m}.data`, b));
9285
9300
  });
9286
9301
  }
@@ -9290,8 +9305,8 @@ function sn() {
9290
9305
  f.if((0, e._)`${n.default.vErrors} === null`, () => f.assign(n.default.vErrors, (0, e._)`[${p}]`), (0, e._)`${n.default.vErrors}.push(${p})`), f.code((0, e._)`${n.default.errors}++`);
9291
9306
  }
9292
9307
  function u(f, g) {
9293
- const { gen: p, validateName: b, schemaEnv: T } = f;
9294
- T.$async ? p.throw((0, e._)`new ${f.ValidationError}(${g})`) : (p.assign((0, e._)`${b}.errors`, g), p.return(!1));
9308
+ const { gen: p, validateName: b, schemaEnv: S } = f;
9309
+ S.$async ? p.throw((0, e._)`new ${f.ValidationError}(${g})`) : (p.assign((0, e._)`${b}.errors`, g), p.return(!1));
9295
9310
  }
9296
9311
  const l = {
9297
9312
  keyword: new e.Name("keyword"),
@@ -9308,9 +9323,9 @@ function sn() {
9308
9323
  return b === !1 ? (0, e._)`{}` : y(f, g, p);
9309
9324
  }
9310
9325
  function y(f, g, p = {}) {
9311
- const { gen: b, it: T } = f, d = [
9312
- v(T, p),
9313
- S(f, p)
9326
+ const { gen: b, it: S } = f, d = [
9327
+ v(S, p),
9328
+ R(f, p)
9314
9329
  ];
9315
9330
  return _(f, g, d), b.object(...d);
9316
9331
  }
@@ -9318,20 +9333,20 @@ function sn() {
9318
9333
  const p = g ? (0, e.str)`${f}${(0, r.getErrorPath)(g, r.Type.Str)}` : f;
9319
9334
  return [n.default.instancePath, (0, e.strConcat)(n.default.instancePath, p)];
9320
9335
  }
9321
- function S({ keyword: f, it: { errSchemaPath: g } }, { schemaPath: p, parentSchema: b }) {
9322
- let T = b ? g : (0, e.str)`${g}/${f}`;
9323
- return p && (T = (0, e.str)`${T}${(0, r.getErrorPath)(p, r.Type.Str)}`), [l.schemaPath, T];
9336
+ function R({ keyword: f, it: { errSchemaPath: g } }, { schemaPath: p, parentSchema: b }) {
9337
+ let S = b ? g : (0, e.str)`${g}/${f}`;
9338
+ return p && (S = (0, e.str)`${S}${(0, r.getErrorPath)(p, r.Type.Str)}`), [l.schemaPath, S];
9324
9339
  }
9325
9340
  function _(f, { params: g, message: p }, b) {
9326
- const { keyword: T, data: d, schemaValue: m, it: w } = f, { opts: R, propertyName: I, topSchemaRef: L, schemaPath: N } = w;
9327
- b.push([l.keyword, T], [l.params, typeof g == "function" ? g(f) : g || (0, e._)`{}`]), R.messages && b.push([l.message, typeof p == "function" ? p(f) : p]), R.verbose && b.push([l.schema, m], [l.parentSchema, (0, e._)`${L}${N}`], [n.default.data, d]), I && b.push([l.propertyName, I]);
9341
+ const { keyword: S, data: d, schemaValue: m, it: w } = f, { opts: T, propertyName: I, topSchemaRef: L, schemaPath: N } = w;
9342
+ b.push([l.keyword, S], [l.params, typeof g == "function" ? g(f) : g || (0, e._)`{}`]), T.messages && b.push([l.message, typeof p == "function" ? p(f) : p]), T.verbose && b.push([l.schema, m], [l.parentSchema, (0, e._)`${L}${N}`], [n.default.data, d]), I && b.push([l.propertyName, I]);
9328
9343
  }
9329
9344
  })(On)), On;
9330
9345
  }
9331
- var Ro;
9346
+ var To;
9332
9347
  function Vm() {
9333
- if (Ro) return We;
9334
- Ro = 1, Object.defineProperty(We, "__esModule", { value: !0 }), We.boolOrEmptySchema = We.topBoolOrEmptySchema = void 0;
9348
+ if (To) return We;
9349
+ To = 1, Object.defineProperty(We, "__esModule", { value: !0 }), We.boolOrEmptySchema = We.topBoolOrEmptySchema = void 0;
9335
9350
  const t = sn(), e = te(), r = Ke(), n = {
9336
9351
  message: "boolean schema is false"
9337
9352
  };
@@ -9360,10 +9375,10 @@ function Vm() {
9360
9375
  }
9361
9376
  return We;
9362
9377
  }
9363
- var _e = {}, Je = {}, So;
9378
+ var _e = {}, Je = {}, Ro;
9364
9379
  function ki() {
9365
- if (So) return Je;
9366
- So = 1, Object.defineProperty(Je, "__esModule", { value: !0 }), Je.getRules = Je.isJSONType = void 0;
9380
+ if (Ro) return Je;
9381
+ Ro = 1, Object.defineProperty(Je, "__esModule", { value: !0 }), Je.getRules = Je.isJSONType = void 0;
9367
9382
  const t = ["string", "number", "integer", "boolean", "null", "object", "array"], e = new Set(t);
9368
9383
  function r(s) {
9369
9384
  return typeof s == "string" && e.has(s);
@@ -9386,10 +9401,10 @@ function ki() {
9386
9401
  }
9387
9402
  return Je.getRules = n, Je;
9388
9403
  }
9389
- var je = {}, To;
9404
+ var je = {}, So;
9390
9405
  function Mi() {
9391
- if (To) return je;
9392
- To = 1, Object.defineProperty(je, "__esModule", { value: !0 }), je.shouldUseRule = je.shouldUseGroup = je.schemaHasRulesForType = void 0;
9406
+ if (So) return je;
9407
+ So = 1, Object.defineProperty(je, "__esModule", { value: !0 }), je.shouldUseRule = je.shouldUseGroup = je.schemaHasRulesForType = void 0;
9393
9408
  function t({ schema: n, self: s }, o) {
9394
9409
  const a = s.RULES.types[o];
9395
9410
  return a && a !== !0 && e(n, a);
@@ -9435,24 +9450,24 @@ function zr() {
9435
9450
  }
9436
9451
  _e.getJSONTypes = i;
9437
9452
  function c(p, b) {
9438
- const { gen: T, data: d, opts: m } = p, w = l(b, m.coerceTypes), R = b.length > 0 && !(w.length === 0 && b.length === 1 && (0, e.schemaHasRulesForType)(p, b[0]));
9439
- if (R) {
9440
- const I = S(b, d, m.strictNumbers, o.Wrong);
9441
- T.if(I, () => {
9453
+ const { gen: S, data: d, opts: m } = p, w = l(b, m.coerceTypes), T = b.length > 0 && !(w.length === 0 && b.length === 1 && (0, e.schemaHasRulesForType)(p, b[0]));
9454
+ if (T) {
9455
+ const I = R(b, d, m.strictNumbers, o.Wrong);
9456
+ S.if(I, () => {
9442
9457
  w.length ? h(p, b, w) : f(p);
9443
9458
  });
9444
9459
  }
9445
- return R;
9460
+ return T;
9446
9461
  }
9447
9462
  _e.coerceAndCheckDataType = c;
9448
9463
  const u = /* @__PURE__ */ new Set(["string", "number", "integer", "boolean", "null"]);
9449
9464
  function l(p, b) {
9450
- return b ? p.filter((T) => u.has(T) || b === "array" && T === "array") : [];
9465
+ return b ? p.filter((S) => u.has(S) || b === "array" && S === "array") : [];
9451
9466
  }
9452
- function h(p, b, T) {
9453
- const { gen: d, data: m, opts: w } = p, R = d.let("dataType", (0, n._)`typeof ${m}`), I = d.let("coerced", (0, n._)`undefined`);
9454
- w.coerceTypes === "array" && d.if((0, n._)`${R} == 'object' && Array.isArray(${m}) && ${m}.length == 1`, () => d.assign(m, (0, n._)`${m}[0]`).assign(R, (0, n._)`typeof ${m}`).if(S(b, m, w.strictNumbers), () => d.assign(I, m))), d.if((0, n._)`${I} !== undefined`);
9455
- for (const N of T)
9467
+ function h(p, b, S) {
9468
+ const { gen: d, data: m, opts: w } = p, T = d.let("dataType", (0, n._)`typeof ${m}`), I = d.let("coerced", (0, n._)`undefined`);
9469
+ w.coerceTypes === "array" && d.if((0, n._)`${T} == 'object' && Array.isArray(${m}) && ${m}.length == 1`, () => d.assign(m, (0, n._)`${m}[0]`).assign(T, (0, n._)`typeof ${m}`).if(R(b, m, w.strictNumbers), () => d.assign(I, m))), d.if((0, n._)`${I} !== undefined`);
9470
+ for (const N of S)
9456
9471
  (u.has(N) || N === "array" && w.coerceTypes === "array") && L(N);
9457
9472
  d.else(), f(p), d.endIf(), d.if((0, n._)`${I} !== undefined`, () => {
9458
9473
  d.assign(m, I), y(p, I);
@@ -9460,15 +9475,15 @@ function zr() {
9460
9475
  function L(N) {
9461
9476
  switch (N) {
9462
9477
  case "string":
9463
- d.elseIf((0, n._)`${R} == "number" || ${R} == "boolean"`).assign(I, (0, n._)`"" + ${m}`).elseIf((0, n._)`${m} === null`).assign(I, (0, n._)`""`);
9478
+ d.elseIf((0, n._)`${T} == "number" || ${T} == "boolean"`).assign(I, (0, n._)`"" + ${m}`).elseIf((0, n._)`${m} === null`).assign(I, (0, n._)`""`);
9464
9479
  return;
9465
9480
  case "number":
9466
- d.elseIf((0, n._)`${R} == "boolean" || ${m} === null
9467
- || (${R} == "string" && ${m} && ${m} == +${m})`).assign(I, (0, n._)`+${m}`);
9481
+ d.elseIf((0, n._)`${T} == "boolean" || ${m} === null
9482
+ || (${T} == "string" && ${m} && ${m} == +${m})`).assign(I, (0, n._)`+${m}`);
9468
9483
  return;
9469
9484
  case "integer":
9470
- d.elseIf((0, n._)`${R} === "boolean" || ${m} === null
9471
- || (${R} === "string" && ${m} && ${m} == +${m} && !(${m} % 1))`).assign(I, (0, n._)`+${m}`);
9485
+ d.elseIf((0, n._)`${T} === "boolean" || ${m} === null
9486
+ || (${T} === "string" && ${m} && ${m} == +${m} && !(${m} % 1))`).assign(I, (0, n._)`+${m}`);
9472
9487
  return;
9473
9488
  case "boolean":
9474
9489
  d.elseIf((0, n._)`${m} === "false" || ${m} === 0 || ${m} === null`).assign(I, !1).elseIf((0, n._)`${m} === "true" || ${m} === 1`).assign(I, !0);
@@ -9477,15 +9492,15 @@ function zr() {
9477
9492
  d.elseIf((0, n._)`${m} === "" || ${m} === 0 || ${m} === false`), d.assign(I, null);
9478
9493
  return;
9479
9494
  case "array":
9480
- d.elseIf((0, n._)`${R} === "string" || ${R} === "number"
9481
- || ${R} === "boolean" || ${m} === null`).assign(I, (0, n._)`[${m}]`);
9495
+ d.elseIf((0, n._)`${T} === "string" || ${T} === "number"
9496
+ || ${T} === "boolean" || ${m} === null`).assign(I, (0, n._)`[${m}]`);
9482
9497
  }
9483
9498
  }
9484
9499
  }
9485
- function y({ gen: p, parentData: b, parentDataProperty: T }, d) {
9486
- p.if((0, n._)`${b} !== undefined`, () => p.assign((0, n._)`${b}[${T}]`, d));
9500
+ function y({ gen: p, parentData: b, parentDataProperty: S }, d) {
9501
+ p.if((0, n._)`${b} !== undefined`, () => p.assign((0, n._)`${b}[${S}]`, d));
9487
9502
  }
9488
- function v(p, b, T, d = o.Correct) {
9503
+ function v(p, b, S, d = o.Correct) {
9489
9504
  const m = d === o.Correct ? n.operators.EQ : n.operators.NEQ;
9490
9505
  let w;
9491
9506
  switch (p) {
@@ -9498,36 +9513,36 @@ function zr() {
9498
9513
  w = (0, n._)`${b} && typeof ${b} == "object" && !Array.isArray(${b})`;
9499
9514
  break;
9500
9515
  case "integer":
9501
- w = R((0, n._)`!(${b} % 1) && !isNaN(${b})`);
9516
+ w = T((0, n._)`!(${b} % 1) && !isNaN(${b})`);
9502
9517
  break;
9503
9518
  case "number":
9504
- w = R();
9519
+ w = T();
9505
9520
  break;
9506
9521
  default:
9507
9522
  return (0, n._)`typeof ${b} ${m} ${p}`;
9508
9523
  }
9509
9524
  return d === o.Correct ? w : (0, n.not)(w);
9510
- function R(I = n.nil) {
9511
- return (0, n.and)((0, n._)`typeof ${b} == "number"`, I, T ? (0, n._)`isFinite(${b})` : n.nil);
9525
+ function T(I = n.nil) {
9526
+ return (0, n.and)((0, n._)`typeof ${b} == "number"`, I, S ? (0, n._)`isFinite(${b})` : n.nil);
9512
9527
  }
9513
9528
  }
9514
9529
  _e.checkDataType = v;
9515
- function S(p, b, T, d) {
9530
+ function R(p, b, S, d) {
9516
9531
  if (p.length === 1)
9517
- return v(p[0], b, T, d);
9532
+ return v(p[0], b, S, d);
9518
9533
  let m;
9519
9534
  const w = (0, s.toHash)(p);
9520
9535
  if (w.array && w.object) {
9521
- const R = (0, n._)`typeof ${b} != "object"`;
9522
- m = w.null ? R : (0, n._)`!${b} || ${R}`, delete w.null, delete w.array, delete w.object;
9536
+ const T = (0, n._)`typeof ${b} != "object"`;
9537
+ m = w.null ? T : (0, n._)`!${b} || ${T}`, delete w.null, delete w.array, delete w.object;
9523
9538
  } else
9524
9539
  m = n.nil;
9525
9540
  w.number && delete w.integer;
9526
- for (const R in w)
9527
- m = (0, n.and)(m, v(R, b, T, d));
9541
+ for (const T in w)
9542
+ m = (0, n.and)(m, v(T, b, S, d));
9528
9543
  return m;
9529
9544
  }
9530
- _e.checkDataTypes = S;
9545
+ _e.checkDataTypes = R;
9531
9546
  const _ = {
9532
9547
  message: ({ schema: p }) => `must be ${p}`,
9533
9548
  params: ({ schema: p, schemaValue: b }) => typeof p == "string" ? (0, n._)`{type: ${p}}` : (0, n._)`{type: ${b}}`
@@ -9538,11 +9553,11 @@ function zr() {
9538
9553
  }
9539
9554
  _e.reportTypeError = f;
9540
9555
  function g(p) {
9541
- const { gen: b, data: T, schema: d } = p, m = (0, s.schemaRefOrVal)(p, d, "type");
9556
+ const { gen: b, data: S, schema: d } = p, m = (0, s.schemaRefOrVal)(p, d, "type");
9542
9557
  return {
9543
9558
  gen: b,
9544
9559
  keyword: "type",
9545
- data: T,
9560
+ data: S,
9546
9561
  schema: d.type,
9547
9562
  schemaCode: m,
9548
9563
  schemaValue: m,
@@ -9586,14 +9601,14 @@ function ke() {
9586
9601
  No = 1, Object.defineProperty(ce, "__esModule", { value: !0 }), ce.validateUnion = ce.validateArray = ce.usePattern = ce.callValidateCode = ce.schemaProperties = ce.allSchemaProperties = ce.noPropertyInData = ce.propertyInData = ce.isOwnProperty = ce.hasPropFunc = ce.reportMissingProp = ce.checkMissingProp = ce.checkReportMissingProp = void 0;
9587
9602
  const t = te(), e = se(), r = Ke(), n = se();
9588
9603
  function s(p, b) {
9589
- const { gen: T, data: d, it: m } = p;
9590
- T.if(l(T, d, b, m.opts.ownProperties), () => {
9604
+ const { gen: S, data: d, it: m } = p;
9605
+ S.if(l(S, d, b, m.opts.ownProperties), () => {
9591
9606
  p.setParams({ missingProperty: (0, t._)`${b}` }, !0), p.error();
9592
9607
  });
9593
9608
  }
9594
9609
  ce.checkReportMissingProp = s;
9595
- function o({ gen: p, data: b, it: { opts: T } }, d, m) {
9596
- return (0, t.or)(...d.map((w) => (0, t.and)(l(p, b, w, T.ownProperties), (0, t._)`${m} = ${w}`)));
9610
+ function o({ gen: p, data: b, it: { opts: S } }, d, m) {
9611
+ return (0, t.or)(...d.map((w) => (0, t.and)(l(p, b, w, S.ownProperties), (0, t._)`${m} = ${w}`)));
9597
9612
  }
9598
9613
  ce.checkMissingProp = o;
9599
9614
  function a(p, b) {
@@ -9608,18 +9623,18 @@ function ke() {
9608
9623
  });
9609
9624
  }
9610
9625
  ce.hasPropFunc = i;
9611
- function c(p, b, T) {
9612
- return (0, t._)`${i(p)}.call(${b}, ${T})`;
9626
+ function c(p, b, S) {
9627
+ return (0, t._)`${i(p)}.call(${b}, ${S})`;
9613
9628
  }
9614
9629
  ce.isOwnProperty = c;
9615
- function u(p, b, T, d) {
9616
- const m = (0, t._)`${b}${(0, t.getProperty)(T)} !== undefined`;
9617
- return d ? (0, t._)`${m} && ${c(p, b, T)}` : m;
9630
+ function u(p, b, S, d) {
9631
+ const m = (0, t._)`${b}${(0, t.getProperty)(S)} !== undefined`;
9632
+ return d ? (0, t._)`${m} && ${c(p, b, S)}` : m;
9618
9633
  }
9619
9634
  ce.propertyInData = u;
9620
- function l(p, b, T, d) {
9621
- const m = (0, t._)`${b}${(0, t.getProperty)(T)} === undefined`;
9622
- return d ? (0, t.or)(m, (0, t.not)(c(p, b, T))) : m;
9635
+ function l(p, b, S, d) {
9636
+ const m = (0, t._)`${b}${(0, t.getProperty)(S)} === undefined`;
9637
+ return d ? (0, t.or)(m, (0, t.not)(c(p, b, S))) : m;
9623
9638
  }
9624
9639
  ce.noPropertyInData = l;
9625
9640
  function h(p) {
@@ -9627,40 +9642,40 @@ function ke() {
9627
9642
  }
9628
9643
  ce.allSchemaProperties = h;
9629
9644
  function y(p, b) {
9630
- return h(b).filter((T) => !(0, e.alwaysValidSchema)(p, b[T]));
9645
+ return h(b).filter((S) => !(0, e.alwaysValidSchema)(p, b[S]));
9631
9646
  }
9632
9647
  ce.schemaProperties = y;
9633
- function v({ schemaCode: p, data: b, it: { gen: T, topSchemaRef: d, schemaPath: m, errorPath: w }, it: R }, I, L, N) {
9648
+ function v({ schemaCode: p, data: b, it: { gen: S, topSchemaRef: d, schemaPath: m, errorPath: w }, it: T }, I, L, N) {
9634
9649
  const k = N ? (0, t._)`${p}, ${b}, ${d}${m}` : b, B = [
9635
9650
  [r.default.instancePath, (0, t.strConcat)(r.default.instancePath, w)],
9636
- [r.default.parentData, R.parentData],
9637
- [r.default.parentDataProperty, R.parentDataProperty],
9651
+ [r.default.parentData, T.parentData],
9652
+ [r.default.parentDataProperty, T.parentDataProperty],
9638
9653
  [r.default.rootData, r.default.rootData]
9639
9654
  ];
9640
- R.opts.dynamicRef && B.push([r.default.dynamicAnchors, r.default.dynamicAnchors]);
9641
- const V = (0, t._)`${k}, ${T.object(...B)}`;
9655
+ T.opts.dynamicRef && B.push([r.default.dynamicAnchors, r.default.dynamicAnchors]);
9656
+ const V = (0, t._)`${k}, ${S.object(...B)}`;
9642
9657
  return L !== t.nil ? (0, t._)`${I}.call(${L}, ${V})` : (0, t._)`${I}(${V})`;
9643
9658
  }
9644
9659
  ce.callValidateCode = v;
9645
- const S = (0, t._)`new RegExp`;
9646
- function _({ gen: p, it: { opts: b } }, T) {
9647
- const d = b.unicodeRegExp ? "u" : "", { regExp: m } = b.code, w = m(T, d);
9660
+ const R = (0, t._)`new RegExp`;
9661
+ function _({ gen: p, it: { opts: b } }, S) {
9662
+ const d = b.unicodeRegExp ? "u" : "", { regExp: m } = b.code, w = m(S, d);
9648
9663
  return p.scopeValue("pattern", {
9649
9664
  key: w.toString(),
9650
9665
  ref: w,
9651
- code: (0, t._)`${m.code === "new RegExp" ? S : (0, n.useFunc)(p, m)}(${T}, ${d})`
9666
+ code: (0, t._)`${m.code === "new RegExp" ? R : (0, n.useFunc)(p, m)}(${S}, ${d})`
9652
9667
  });
9653
9668
  }
9654
9669
  ce.usePattern = _;
9655
9670
  function f(p) {
9656
- const { gen: b, data: T, keyword: d, it: m } = p, w = b.name("valid");
9671
+ const { gen: b, data: S, keyword: d, it: m } = p, w = b.name("valid");
9657
9672
  if (m.allErrors) {
9658
9673
  const I = b.let("valid", !0);
9659
- return R(() => b.assign(I, !1)), I;
9674
+ return T(() => b.assign(I, !1)), I;
9660
9675
  }
9661
- return b.var(w, !0), R(() => b.break()), w;
9662
- function R(I) {
9663
- const L = b.const("len", (0, t._)`${T}.length`);
9676
+ return b.var(w, !0), T(() => b.break()), w;
9677
+ function T(I) {
9678
+ const L = b.const("len", (0, t._)`${S}.length`);
9664
9679
  b.forRange("i", 0, L, (N) => {
9665
9680
  p.subschema({
9666
9681
  keyword: d,
@@ -9672,20 +9687,20 @@ function ke() {
9672
9687
  }
9673
9688
  ce.validateArray = f;
9674
9689
  function g(p) {
9675
- const { gen: b, schema: T, keyword: d, it: m } = p;
9676
- if (!Array.isArray(T))
9690
+ const { gen: b, schema: S, keyword: d, it: m } = p;
9691
+ if (!Array.isArray(S))
9677
9692
  throw new Error("ajv implementation error");
9678
- if (T.some((L) => (0, e.alwaysValidSchema)(m, L)) && !m.opts.unevaluated)
9693
+ if (S.some((L) => (0, e.alwaysValidSchema)(m, L)) && !m.opts.unevaluated)
9679
9694
  return;
9680
- const R = b.let("valid", !1), I = b.name("_valid");
9681
- b.block(() => T.forEach((L, N) => {
9695
+ const T = b.let("valid", !1), I = b.name("_valid");
9696
+ b.block(() => S.forEach((L, N) => {
9682
9697
  const k = p.subschema({
9683
9698
  keyword: d,
9684
9699
  schemaProp: N,
9685
9700
  compositeRule: !0
9686
9701
  }, I);
9687
- b.assign(R, (0, t._)`${R} || ${I}`), p.mergeValidEvaluated(k, I) || b.if((0, t.not)(R));
9688
- })), p.result(R, () => p.reset(), () => p.error(!0));
9702
+ b.assign(T, (0, t._)`${T} || ${I}`), p.mergeValidEvaluated(k, I) || b.if((0, t.not)(T));
9703
+ })), p.result(T, () => p.reset(), () => p.error(!0));
9689
9704
  }
9690
9705
  return ce.validateUnion = g, ce;
9691
9706
  }
@@ -9695,25 +9710,25 @@ function Bm() {
9695
9710
  Po = 1, Object.defineProperty(Le, "__esModule", { value: !0 }), Le.validateKeywordUsage = Le.validSchemaType = Le.funcKeywordCode = Le.macroKeywordCode = void 0;
9696
9711
  const t = te(), e = Ke(), r = ke(), n = sn();
9697
9712
  function s(y, v) {
9698
- const { gen: S, keyword: _, schema: f, parentSchema: g, it: p } = y, b = v.macro.call(p.self, f, g, p), T = u(S, _, b);
9713
+ const { gen: R, keyword: _, schema: f, parentSchema: g, it: p } = y, b = v.macro.call(p.self, f, g, p), S = u(R, _, b);
9699
9714
  p.opts.validateSchema !== !1 && p.self.validateSchema(b, !0);
9700
- const d = S.name("valid");
9715
+ const d = R.name("valid");
9701
9716
  y.subschema({
9702
9717
  schema: b,
9703
9718
  schemaPath: t.nil,
9704
9719
  errSchemaPath: `${p.errSchemaPath}/${_}`,
9705
- topSchemaRef: T,
9720
+ topSchemaRef: S,
9706
9721
  compositeRule: !0
9707
9722
  }, d), y.pass(d, () => y.error(!0));
9708
9723
  }
9709
9724
  Le.macroKeywordCode = s;
9710
9725
  function o(y, v) {
9711
- var S;
9712
- const { gen: _, keyword: f, schema: g, parentSchema: p, $data: b, it: T } = y;
9713
- c(T, v);
9714
- const d = !b && v.compile ? v.compile.call(T.self, g, p, T) : v.validate, m = u(_, f, d), w = _.let("valid");
9715
- y.block$data(w, R), y.ok((S = v.valid) !== null && S !== void 0 ? S : w);
9716
- function R() {
9726
+ var R;
9727
+ const { gen: _, keyword: f, schema: g, parentSchema: p, $data: b, it: S } = y;
9728
+ c(S, v);
9729
+ const d = !b && v.compile ? v.compile.call(S.self, g, p, S) : v.validate, m = u(_, f, d), w = _.let("valid");
9730
+ y.block$data(w, T), y.ok((R = v.valid) !== null && R !== void 0 ? R : w);
9731
+ function T() {
9717
9732
  if (v.errors === !1)
9718
9733
  N(), v.modifying && a(y), k(() => y.error());
9719
9734
  else {
@@ -9723,14 +9738,14 @@ function Bm() {
9723
9738
  }
9724
9739
  function I() {
9725
9740
  const B = _.let("ruleErrs", null);
9726
- return _.try(() => N((0, t._)`await `), (V) => _.assign(w, !1).if((0, t._)`${V} instanceof ${T.ValidationError}`, () => _.assign(B, (0, t._)`${V}.errors`), () => _.throw(V))), B;
9741
+ return _.try(() => N((0, t._)`await `), (V) => _.assign(w, !1).if((0, t._)`${V} instanceof ${S.ValidationError}`, () => _.assign(B, (0, t._)`${V}.errors`), () => _.throw(V))), B;
9727
9742
  }
9728
9743
  function L() {
9729
9744
  const B = (0, t._)`${m}.errors`;
9730
9745
  return _.assign(B, null), N(t.nil), B;
9731
9746
  }
9732
9747
  function N(B = v.async ? (0, t._)`await ` : t.nil) {
9733
- const V = T.opts.passContext ? e.default.this : e.default.self, J = !("compile" in v && !b || v.schema === !1);
9748
+ const V = S.opts.passContext ? e.default.this : e.default.self, J = !("compile" in v && !b || v.schema === !1);
9734
9749
  _.assign(w, (0, t._)`${B}${(0, r.callValidateCode)(y, m, V, J)}`, v.modifying);
9735
9750
  }
9736
9751
  function k(B) {
@@ -9740,40 +9755,40 @@ function Bm() {
9740
9755
  }
9741
9756
  Le.funcKeywordCode = o;
9742
9757
  function a(y) {
9743
- const { gen: v, data: S, it: _ } = y;
9744
- v.if(_.parentData, () => v.assign(S, (0, t._)`${_.parentData}[${_.parentDataProperty}]`));
9758
+ const { gen: v, data: R, it: _ } = y;
9759
+ v.if(_.parentData, () => v.assign(R, (0, t._)`${_.parentData}[${_.parentDataProperty}]`));
9745
9760
  }
9746
9761
  function i(y, v) {
9747
- const { gen: S } = y;
9748
- S.if((0, t._)`Array.isArray(${v})`, () => {
9749
- S.assign(e.default.vErrors, (0, t._)`${e.default.vErrors} === null ? ${v} : ${e.default.vErrors}.concat(${v})`).assign(e.default.errors, (0, t._)`${e.default.vErrors}.length`), (0, n.extendErrors)(y);
9762
+ const { gen: R } = y;
9763
+ R.if((0, t._)`Array.isArray(${v})`, () => {
9764
+ R.assign(e.default.vErrors, (0, t._)`${e.default.vErrors} === null ? ${v} : ${e.default.vErrors}.concat(${v})`).assign(e.default.errors, (0, t._)`${e.default.vErrors}.length`), (0, n.extendErrors)(y);
9750
9765
  }, () => y.error());
9751
9766
  }
9752
9767
  function c({ schemaEnv: y }, v) {
9753
9768
  if (v.async && !y.$async)
9754
9769
  throw new Error("async keyword in sync schema");
9755
9770
  }
9756
- function u(y, v, S) {
9757
- if (S === void 0)
9771
+ function u(y, v, R) {
9772
+ if (R === void 0)
9758
9773
  throw new Error(`keyword "${v}" failed to compile`);
9759
- return y.scopeValue("keyword", typeof S == "function" ? { ref: S } : { ref: S, code: (0, t.stringify)(S) });
9774
+ return y.scopeValue("keyword", typeof R == "function" ? { ref: R } : { ref: R, code: (0, t.stringify)(R) });
9760
9775
  }
9761
- function l(y, v, S = !1) {
9762
- return !v.length || v.some((_) => _ === "array" ? Array.isArray(y) : _ === "object" ? y && typeof y == "object" && !Array.isArray(y) : typeof y == _ || S && typeof y > "u");
9776
+ function l(y, v, R = !1) {
9777
+ return !v.length || v.some((_) => _ === "array" ? Array.isArray(y) : _ === "object" ? y && typeof y == "object" && !Array.isArray(y) : typeof y == _ || R && typeof y > "u");
9763
9778
  }
9764
9779
  Le.validSchemaType = l;
9765
- function h({ schema: y, opts: v, self: S, errSchemaPath: _ }, f, g) {
9780
+ function h({ schema: y, opts: v, self: R, errSchemaPath: _ }, f, g) {
9766
9781
  if (Array.isArray(f.keyword) ? !f.keyword.includes(g) : f.keyword !== g)
9767
9782
  throw new Error("ajv implementation error");
9768
9783
  const p = f.dependencies;
9769
9784
  if (p?.some((b) => !Object.prototype.hasOwnProperty.call(y, b)))
9770
9785
  throw new Error(`parent schema must have dependencies of ${g}: ${p.join(",")}`);
9771
9786
  if (f.validateSchema && !f.validateSchema(y[g])) {
9772
- const T = `keyword "${g}" value is invalid at path "${_}": ` + S.errorsText(f.validateSchema.errors);
9787
+ const S = `keyword "${g}" value is invalid at path "${_}": ` + R.errorsText(f.validateSchema.errors);
9773
9788
  if (v.validateSchema === "log")
9774
- S.logger.error(T);
9789
+ R.logger.error(S);
9775
9790
  else
9776
- throw new Error(T);
9791
+ throw new Error(S);
9777
9792
  }
9778
9793
  }
9779
9794
  return Le.validateKeywordUsage = h, Le;
@@ -9816,16 +9831,16 @@ function zm() {
9816
9831
  throw new Error('both "data" and "dataProp" passed, only one allowed');
9817
9832
  const { gen: y } = a;
9818
9833
  if (i !== void 0) {
9819
- const { errorPath: S, dataPathArr: _, opts: f } = a, g = y.let("data", (0, t._)`${a.data}${(0, t.getProperty)(i)}`, !0);
9820
- v(g), o.errorPath = (0, t.str)`${S}${(0, e.getErrorPath)(i, c, f.jsPropertySyntax)}`, o.parentDataProperty = (0, t._)`${i}`, o.dataPathArr = [..._, o.parentDataProperty];
9834
+ const { errorPath: R, dataPathArr: _, opts: f } = a, g = y.let("data", (0, t._)`${a.data}${(0, t.getProperty)(i)}`, !0);
9835
+ v(g), o.errorPath = (0, t.str)`${R}${(0, e.getErrorPath)(i, c, f.jsPropertySyntax)}`, o.parentDataProperty = (0, t._)`${i}`, o.dataPathArr = [..._, o.parentDataProperty];
9821
9836
  }
9822
9837
  if (u !== void 0) {
9823
- const S = u instanceof t.Name ? u : y.let("data", u, !0);
9824
- v(S), h !== void 0 && (o.propertyName = h);
9838
+ const R = u instanceof t.Name ? u : y.let("data", u, !0);
9839
+ v(R), h !== void 0 && (o.propertyName = h);
9825
9840
  }
9826
9841
  l && (o.dataTypes = l);
9827
- function v(S) {
9828
- o.data = S, o.dataLevel = a.dataLevel + 1, o.dataTypes = [], a.definedProperties = /* @__PURE__ */ new Set(), o.parentData = a.data, o.dataNames = [...a.dataNames, S];
9842
+ function v(R) {
9843
+ o.data = R, o.dataLevel = a.dataLevel + 1, o.dataTypes = [], a.definedProperties = /* @__PURE__ */ new Set(), o.parentData = a.data, o.dataNames = [...a.dataNames, R];
9829
9844
  }
9830
9845
  }
9831
9846
  Ve.extendSubschemaData = n;
@@ -9834,7 +9849,7 @@ function zm() {
9834
9849
  }
9835
9850
  return Ve.extendSubschemaMode = s, Ve;
9836
9851
  }
9837
- var Se = {}, In, $o;
9852
+ var Re = {}, In, $o;
9838
9853
  function Ui() {
9839
9854
  return $o || ($o = 1, In = function t(e, r) {
9840
9855
  if (e === r) return !0;
@@ -9918,16 +9933,16 @@ function Ym() {
9918
9933
  if (a && typeof a == "object" && !Array.isArray(a)) {
9919
9934
  s(a, i, c, u, l, h, y);
9920
9935
  for (var v in a) {
9921
- var S = a[v];
9922
- if (Array.isArray(S)) {
9936
+ var R = a[v];
9937
+ if (Array.isArray(R)) {
9923
9938
  if (v in t.arrayKeywords)
9924
- for (var _ = 0; _ < S.length; _++)
9925
- e(n, s, o, S[_], i + "/" + v + "/" + _, c, i, v, a, _);
9939
+ for (var _ = 0; _ < R.length; _++)
9940
+ e(n, s, o, R[_], i + "/" + v + "/" + _, c, i, v, a, _);
9926
9941
  } else if (v in t.propsKeywords) {
9927
- if (S && typeof S == "object")
9928
- for (var f in S)
9929
- e(n, s, o, S[f], i + "/" + v + "/" + r(f), c, i, v, a, f);
9930
- } else (v in t.keywords || n.allKeys && !(v in t.skipKeywords)) && e(n, s, o, S, i + "/" + v, c, i, v, a);
9942
+ if (R && typeof R == "object")
9943
+ for (var f in R)
9944
+ e(n, s, o, R[f], i + "/" + v + "/" + r(f), c, i, v, a, f);
9945
+ } else (v in t.keywords || n.allKeys && !(v in t.skipKeywords)) && e(n, s, o, R, i + "/" + v, c, i, v, a);
9931
9946
  }
9932
9947
  o(a, i, c, u, l, h, y);
9933
9948
  }
@@ -9939,8 +9954,8 @@ function Ym() {
9939
9954
  }
9940
9955
  var Co;
9941
9956
  function on() {
9942
- if (Co) return Se;
9943
- Co = 1, Object.defineProperty(Se, "__esModule", { value: !0 }), Se.getSchemaRefs = Se.resolveUrl = Se.normalizeId = Se._getFullPath = Se.getFullPath = Se.inlineRef = void 0;
9957
+ if (Co) return Re;
9958
+ Co = 1, Object.defineProperty(Re, "__esModule", { value: !0 }), Re.getSchemaRefs = Re.resolveUrl = Re.normalizeId = Re._getFullPath = Re.getFullPath = Re.inlineRef = void 0;
9944
9959
  const t = se(), e = Ui(), r = Ym(), n = /* @__PURE__ */ new Set([
9945
9960
  "type",
9946
9961
  "format",
@@ -9962,7 +9977,7 @@ function on() {
9962
9977
  function s(_, f = !0) {
9963
9978
  return typeof _ == "boolean" ? !0 : f === !0 ? !a(_) : f ? i(_) <= f : !1;
9964
9979
  }
9965
- Se.inlineRef = s;
9980
+ Re.inlineRef = s;
9966
9981
  const o = /* @__PURE__ */ new Set([
9967
9982
  "$ref",
9968
9983
  "$recursiveRef",
@@ -9995,38 +10010,38 @@ function on() {
9995
10010
  const p = _.parse(f);
9996
10011
  return u(_, p);
9997
10012
  }
9998
- Se.getFullPath = c;
10013
+ Re.getFullPath = c;
9999
10014
  function u(_, f) {
10000
10015
  return _.serialize(f).split("#")[0] + "#";
10001
10016
  }
10002
- Se._getFullPath = u;
10017
+ Re._getFullPath = u;
10003
10018
  const l = /#\/?$/;
10004
10019
  function h(_) {
10005
10020
  return _ ? _.replace(l, "") : "";
10006
10021
  }
10007
- Se.normalizeId = h;
10022
+ Re.normalizeId = h;
10008
10023
  function y(_, f, g) {
10009
10024
  return g = h(g), _.resolve(f, g);
10010
10025
  }
10011
- Se.resolveUrl = y;
10026
+ Re.resolveUrl = y;
10012
10027
  const v = /^[a-z_][-a-z0-9._]*$/i;
10013
- function S(_, f) {
10028
+ function R(_, f) {
10014
10029
  if (typeof _ == "boolean")
10015
10030
  return {};
10016
- const { schemaId: g, uriResolver: p } = this.opts, b = h(_[g] || f), T = { "": b }, d = c(p, b, !1), m = {}, w = /* @__PURE__ */ new Set();
10031
+ const { schemaId: g, uriResolver: p } = this.opts, b = h(_[g] || f), S = { "": b }, d = c(p, b, !1), m = {}, w = /* @__PURE__ */ new Set();
10017
10032
  return r(_, { allKeys: !0 }, (L, N, k, B) => {
10018
10033
  if (B === void 0)
10019
10034
  return;
10020
10035
  const V = d + N;
10021
- let J = T[B];
10022
- typeof L[g] == "string" && (J = ne.call(this, L[g])), we.call(this, L.$anchor), we.call(this, L.$dynamicAnchor), T[N] = J;
10036
+ let J = S[B];
10037
+ typeof L[g] == "string" && (J = ne.call(this, L[g])), we.call(this, L.$anchor), we.call(this, L.$dynamicAnchor), S[N] = J;
10023
10038
  function ne(re) {
10024
10039
  const oe = this.opts.uriResolver.resolve;
10025
10040
  if (re = h(J ? oe(J, re) : re), w.has(re))
10026
10041
  throw I(re);
10027
10042
  w.add(re);
10028
10043
  let q = this.refs[re];
10029
- return typeof q == "string" && (q = this.refs[q]), typeof q == "object" ? R(L, q.schema, re) : re !== h(V) && (re[0] === "#" ? (R(L, m[re], re), m[re] = L) : this.refs[re] = V), re;
10044
+ return typeof q == "string" && (q = this.refs[q]), typeof q == "object" ? T(L, q.schema, re) : re !== h(V) && (re[0] === "#" ? (T(L, m[re], re), m[re] = L) : this.refs[re] = V), re;
10030
10045
  }
10031
10046
  function we(re) {
10032
10047
  if (typeof re == "string") {
@@ -10036,7 +10051,7 @@ function on() {
10036
10051
  }
10037
10052
  }
10038
10053
  }), m;
10039
- function R(L, N, k) {
10054
+ function T(L, N, k) {
10040
10055
  if (N !== void 0 && !e(L, N))
10041
10056
  throw I(k);
10042
10057
  }
@@ -10044,7 +10059,7 @@ function on() {
10044
10059
  return new Error(`reference "${L}" resolves to more than one schema`);
10045
10060
  }
10046
10061
  }
10047
- return Se.getSchemaRefs = S, Se;
10062
+ return Re.getSchemaRefs = R, Re;
10048
10063
  }
10049
10064
  var Lo;
10050
10065
  function an() {
@@ -10052,7 +10067,7 @@ function an() {
10052
10067
  Lo = 1, Object.defineProperty(Fe, "__esModule", { value: !0 }), Fe.getData = Fe.KeywordCxt = Fe.validateFunctionCode = void 0;
10053
10068
  const t = Vm(), e = zr(), r = Mi(), n = zr(), s = Hm(), o = Bm(), a = zm(), i = te(), c = Ke(), u = on(), l = se(), h = sn();
10054
10069
  function y(A) {
10055
- if (d(A) && (w(A), T(A))) {
10070
+ if (d(A) && (w(A), S(A))) {
10056
10071
  f(A);
10057
10072
  return;
10058
10073
  }
@@ -10062,9 +10077,9 @@ function an() {
10062
10077
  function v({ gen: A, validateName: C, schema: M, schemaEnv: F, opts: G }, ee) {
10063
10078
  G.code.es5 ? A.func(C, (0, i._)`${c.default.data}, ${c.default.valCxt}`, F.$async, () => {
10064
10079
  A.code((0, i._)`"use strict"; ${p(M, G)}`), _(A, G), A.code(ee);
10065
- }) : A.func(C, (0, i._)`${c.default.data}, ${S(G)}`, F.$async, () => A.code(p(M, G)).code(ee));
10080
+ }) : A.func(C, (0, i._)`${c.default.data}, ${R(G)}`, F.$async, () => A.code(p(M, G)).code(ee));
10066
10081
  }
10067
- function S(A) {
10082
+ function R(A) {
10068
10083
  return (0, i._)`{${c.default.instancePath}="", ${c.default.parentData}, ${c.default.parentDataProperty}, ${c.default.rootData}=${c.default.data}${A.dynamicRef ? (0, i._)`, ${c.default.dynamicAnchors}={}` : i.nil}}={}`;
10069
10084
  }
10070
10085
  function _(A, C) {
@@ -10077,7 +10092,7 @@ function an() {
10077
10092
  function f(A) {
10078
10093
  const { schema: C, opts: M, gen: F } = A;
10079
10094
  v(A, () => {
10080
- M.$comment && C.$comment && B(A), L(A), F.let(c.default.vErrors, null), F.let(c.default.errors, 0), M.unevaluated && g(A), R(A), V(A);
10095
+ M.$comment && C.$comment && B(A), L(A), F.let(c.default.vErrors, null), F.let(c.default.errors, 0), M.unevaluated && g(A), T(A), V(A);
10081
10096
  });
10082
10097
  }
10083
10098
  function g(A) {
@@ -10089,13 +10104,13 @@ function an() {
10089
10104
  return M && (C.code.source || C.code.process) ? (0, i._)`/*# sourceURL=${M} */` : i.nil;
10090
10105
  }
10091
10106
  function b(A, C) {
10092
- if (d(A) && (w(A), T(A))) {
10107
+ if (d(A) && (w(A), S(A))) {
10093
10108
  m(A, C);
10094
10109
  return;
10095
10110
  }
10096
10111
  (0, t.boolOrEmptySchema)(A, C);
10097
10112
  }
10098
- function T({ schema: A, self: C }) {
10113
+ function S({ schema: A, self: C }) {
10099
10114
  if (typeof A == "boolean")
10100
10115
  return !A;
10101
10116
  for (const M in A)
@@ -10110,12 +10125,12 @@ function an() {
10110
10125
  const { schema: M, gen: F, opts: G } = A;
10111
10126
  G.$comment && M.$comment && B(A), N(A), k(A);
10112
10127
  const ee = F.const("_errs", c.default.errors);
10113
- R(A, ee), F.var(C, (0, i._)`${ee} === ${c.default.errors}`);
10128
+ T(A, ee), F.var(C, (0, i._)`${ee} === ${c.default.errors}`);
10114
10129
  }
10115
10130
  function w(A) {
10116
10131
  (0, l.checkUnknownRules)(A), I(A);
10117
10132
  }
10118
- function R(A, C) {
10133
+ function T(A, C) {
10119
10134
  if (A.opts.jtd)
10120
10135
  return ne(A, [], !1, C);
10121
10136
  const M = (0, e.getSchemaTypes)(A.schema), F = (0, e.coerceAndCheckDataType)(A, M);
@@ -10400,14 +10415,14 @@ function bs() {
10400
10415
  const g = l.call(this, f);
10401
10416
  if (g)
10402
10417
  return g;
10403
- const p = (0, n.getFullPath)(this.opts.uriResolver, f.root.baseId), { es5: b, lines: T } = this.opts.code, { ownProperties: d } = this.opts, m = new t.CodeGen(this.scope, { es5: b, lines: T, ownProperties: d });
10418
+ const p = (0, n.getFullPath)(this.opts.uriResolver, f.root.baseId), { es5: b, lines: S } = this.opts.code, { ownProperties: d } = this.opts, m = new t.CodeGen(this.scope, { es5: b, lines: S, ownProperties: d });
10404
10419
  let w;
10405
10420
  f.$async && (w = m.scopeValue("Error", {
10406
10421
  ref: e.default,
10407
10422
  code: (0, t._)`require("ajv/dist/runtime/validation_error").default`
10408
10423
  }));
10409
- const R = m.scopeName("validate");
10410
- f.validateName = R;
10424
+ const T = m.scopeName("validate");
10425
+ f.validateName = T;
10411
10426
  const I = {
10412
10427
  gen: m,
10413
10428
  allErrors: this.opts.allErrors,
@@ -10421,7 +10436,7 @@ function bs() {
10421
10436
  dataTypes: [],
10422
10437
  definedProperties: /* @__PURE__ */ new Set(),
10423
10438
  topSchemaRef: m.scopeValue("schema", this.opts.code.source === !0 ? { ref: f.schema, code: (0, t.stringify)(f.schema) } : { ref: f.schema }),
10424
- validateName: R,
10439
+ validateName: T,
10425
10440
  ValidationError: w,
10426
10441
  schema: f.schema,
10427
10442
  schemaEnv: f,
@@ -10439,7 +10454,7 @@ function bs() {
10439
10454
  const N = m.toString();
10440
10455
  L = `${m.scopeRefs(r.default.scope)}return ${N}`, this.opts.code.process && (L = this.opts.code.process(L, f));
10441
10456
  const B = new Function(`${r.default.self}`, `${r.default.scope}`, L)(this, this.scope.get());
10442
- if (this.scope.value(R, { ref: B }), B.errors = null, B.schema = f.schema, B.schemaEnv = f, f.$async && (B.$async = !0), this.opts.code.source === !0 && (B.source = { validateName: R, validateCode: N, scopeValues: m._values }), this.opts.unevaluated) {
10457
+ if (this.scope.value(T, { ref: B }), B.errors = null, B.schema = f.schema, B.schemaEnv = f, f.$async && (B.$async = !0), this.opts.code.source === !0 && (B.source = { validateName: T, validateCode: N, scopeValues: m._values }), this.opts.unevaluated) {
10443
10458
  const { props: V, items: J } = I;
10444
10459
  B.evaluated = {
10445
10460
  props: V instanceof t.Name ? void 0 : V,
@@ -10459,9 +10474,9 @@ function bs() {
10459
10474
  function c(f, g, p) {
10460
10475
  var b;
10461
10476
  p = (0, n.resolveUrl)(this.opts.uriResolver, g, p);
10462
- const T = f.refs[p];
10463
- if (T)
10464
- return T;
10477
+ const S = f.refs[p];
10478
+ if (S)
10479
+ return S;
10465
10480
  let d = y.call(this, f, p);
10466
10481
  if (d === void 0) {
10467
10482
  const m = (b = f.localRefs) === null || b === void 0 ? void 0 : b[p], { schemaId: w } = this.opts;
@@ -10491,8 +10506,8 @@ function bs() {
10491
10506
  }
10492
10507
  function v(f, g) {
10493
10508
  const p = this.opts.uriResolver.parse(g), b = (0, n._getFullPath)(this.opts.uriResolver, p);
10494
- let T = (0, n.getFullPath)(this.opts.uriResolver, f.baseId, void 0);
10495
- if (Object.keys(f.schema).length > 0 && b === T)
10509
+ let S = (0, n.getFullPath)(this.opts.uriResolver, f.baseId, void 0);
10510
+ if (Object.keys(f.schema).length > 0 && b === S)
10496
10511
  return _.call(this, p, f);
10497
10512
  const d = (0, n.normalizeId)(b), m = this.refs[d] || this.schemas[d];
10498
10513
  if (typeof m == "string") {
@@ -10501,14 +10516,14 @@ function bs() {
10501
10516
  }
10502
10517
  if (typeof m?.schema == "object") {
10503
10518
  if (m.validate || i.call(this, m), d === (0, n.normalizeId)(g)) {
10504
- const { schema: w } = m, { schemaId: R } = this.opts, I = w[R];
10505
- return I && (T = (0, n.resolveUrl)(this.opts.uriResolver, T, I)), new a({ schema: w, schemaId: R, root: f, baseId: T });
10519
+ const { schema: w } = m, { schemaId: T } = this.opts, I = w[T];
10520
+ return I && (S = (0, n.resolveUrl)(this.opts.uriResolver, S, I)), new a({ schema: w, schemaId: T, root: f, baseId: S });
10506
10521
  }
10507
10522
  return _.call(this, p, m);
10508
10523
  }
10509
10524
  }
10510
10525
  Pe.resolveSchema = v;
10511
- const S = /* @__PURE__ */ new Set([
10526
+ const R = /* @__PURE__ */ new Set([
10512
10527
  "properties",
10513
10528
  "patternProperties",
10514
10529
  "enum",
@@ -10516,18 +10531,18 @@ function bs() {
10516
10531
  "definitions"
10517
10532
  ]);
10518
10533
  function _(f, { baseId: g, schema: p, root: b }) {
10519
- var T;
10520
- if (((T = f.fragment) === null || T === void 0 ? void 0 : T[0]) !== "/")
10534
+ var S;
10535
+ if (((S = f.fragment) === null || S === void 0 ? void 0 : S[0]) !== "/")
10521
10536
  return;
10522
10537
  for (const w of f.fragment.slice(1).split("/")) {
10523
10538
  if (typeof p == "boolean")
10524
10539
  return;
10525
- const R = p[(0, s.unescapeFragment)(w)];
10526
- if (R === void 0)
10540
+ const T = p[(0, s.unescapeFragment)(w)];
10541
+ if (T === void 0)
10527
10542
  return;
10528
- p = R;
10543
+ p = T;
10529
10544
  const I = typeof p == "object" && p[this.opts.schemaId];
10530
- !S.has(w) && I && (g = (0, n.resolveUrl)(this.opts.uriResolver, g, I));
10545
+ !R.has(w) && I && (g = (0, n.resolveUrl)(this.opts.uriResolver, g, I));
10531
10546
  }
10532
10547
  let d;
10533
10548
  if (typeof p != "boolean" && p.$ref && !(0, s.schemaHasRulesButRef)(p, this.RULES)) {
@@ -10554,18 +10569,18 @@ function qi() {
10554
10569
  Uo = 1;
10555
10570
  const t = RegExp.prototype.test.bind(/^[\da-f]{8}-[\da-f]{4}-[\da-f]{4}-[\da-f]{4}-[\da-f]{12}$/iu), e = RegExp.prototype.test.bind(/^(?:(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)\.){3}(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)$/u), r = RegExp.prototype.test.bind(/^[\da-f]{2}$/iu), n = RegExp.prototype.test.bind(/^[\da-z\-._~]$/iu), s = RegExp.prototype.test.bind(/^[\da-z\-._~!$&'()*+,;=:@/]$/iu);
10556
10571
  function o(d) {
10557
- let m = "", w = 0, R = 0;
10558
- for (R = 0; R < d.length; R++)
10559
- if (w = d[R].charCodeAt(0), w !== 48) {
10572
+ let m = "", w = 0, T = 0;
10573
+ for (T = 0; T < d.length; T++)
10574
+ if (w = d[T].charCodeAt(0), w !== 48) {
10560
10575
  if (!(w >= 48 && w <= 57 || w >= 65 && w <= 70 || w >= 97 && w <= 102))
10561
10576
  return "";
10562
- m += d[R];
10577
+ m += d[T];
10563
10578
  break;
10564
10579
  }
10565
- for (R += 1; R < d.length; R++) {
10566
- if (w = d[R].charCodeAt(0), !(w >= 48 && w <= 57 || w >= 65 && w <= 70 || w >= 97 && w <= 102))
10580
+ for (T += 1; T < d.length; T++) {
10581
+ if (w = d[T].charCodeAt(0), !(w >= 48 && w <= 57 || w >= 65 && w <= 70 || w >= 97 && w <= 102))
10567
10582
  return "";
10568
- m += d[R];
10583
+ m += d[T];
10569
10584
  }
10570
10585
  return m;
10571
10586
  }
@@ -10575,9 +10590,9 @@ function qi() {
10575
10590
  }
10576
10591
  function c(d, m, w) {
10577
10592
  if (d.length) {
10578
- const R = o(d);
10579
- if (R !== "")
10580
- m.push(R);
10593
+ const T = o(d);
10594
+ if (T !== "")
10595
+ m.push(T);
10581
10596
  else
10582
10597
  return w.error = !0, !1;
10583
10598
  d.length = 0;
@@ -10586,22 +10601,22 @@ function qi() {
10586
10601
  }
10587
10602
  function u(d) {
10588
10603
  let m = 0;
10589
- const w = { error: !1, address: "", zone: "" }, R = [], I = [];
10604
+ const w = { error: !1, address: "", zone: "" }, T = [], I = [];
10590
10605
  let L = !1, N = !1, k = c;
10591
10606
  for (let B = 0; B < d.length; B++) {
10592
10607
  const V = d[B];
10593
10608
  if (!(V === "[" || V === "]"))
10594
10609
  if (V === ":") {
10595
- if (L === !0 && (N = !0), !k(I, R, w))
10610
+ if (L === !0 && (N = !0), !k(I, T, w))
10596
10611
  break;
10597
10612
  if (++m > 7) {
10598
10613
  w.error = !0;
10599
10614
  break;
10600
10615
  }
10601
- B > 0 && d[B - 1] === ":" && (L = !0), R.push(":");
10616
+ B > 0 && d[B - 1] === ":" && (L = !0), T.push(":");
10602
10617
  continue;
10603
10618
  } else if (V === "%") {
10604
- if (!k(I, R, w))
10619
+ if (!k(I, T, w))
10605
10620
  break;
10606
10621
  k = i;
10607
10622
  } else {
@@ -10609,7 +10624,7 @@ function qi() {
10609
10624
  continue;
10610
10625
  }
10611
10626
  }
10612
- return I.length && (k === i ? w.zone = I.join("") : N ? R.push(I.join("")) : R.push(o(I))), w.address = R.join(""), w;
10627
+ return I.length && (k === i ? w.zone = I.join("") : N ? T.push(I.join("")) : T.push(o(I))), w.address = T.join(""), w;
10613
10628
  }
10614
10629
  function l(d) {
10615
10630
  if (h(d, ":") < 2)
@@ -10618,20 +10633,20 @@ function qi() {
10618
10633
  if (m.error)
10619
10634
  return { host: d, isIPV6: !1 };
10620
10635
  {
10621
- let w = m.address, R = m.address;
10622
- return m.zone && (w += "%" + m.zone, R += "%25" + m.zone), { host: w, isIPV6: !0, escapedHost: R };
10636
+ let w = m.address, T = m.address;
10637
+ return m.zone && (w += "%" + m.zone, T += "%25" + m.zone), { host: w, isIPV6: !0, escapedHost: T };
10623
10638
  }
10624
10639
  }
10625
10640
  function h(d, m) {
10626
10641
  let w = 0;
10627
- for (let R = 0; R < d.length; R++)
10628
- d[R] === m && w++;
10642
+ for (let T = 0; T < d.length; T++)
10643
+ d[T] === m && w++;
10629
10644
  return w;
10630
10645
  }
10631
10646
  function y(d) {
10632
10647
  let m = d;
10633
10648
  const w = [];
10634
- let R = -1, I = 0;
10649
+ let T = -1, I = 0;
10635
10650
  for (; I = m.length; ) {
10636
10651
  if (I === 1) {
10637
10652
  if (m === ".")
@@ -10678,33 +10693,33 @@ function qi() {
10678
10693
  continue;
10679
10694
  }
10680
10695
  }
10681
- if ((R = m.indexOf("/", 1)) === -1) {
10696
+ if ((T = m.indexOf("/", 1)) === -1) {
10682
10697
  w.push(m);
10683
10698
  break;
10684
10699
  } else
10685
- w.push(m.slice(0, R)), m = m.slice(R);
10700
+ w.push(m.slice(0, T)), m = m.slice(T);
10686
10701
  }
10687
10702
  return w.join("");
10688
10703
  }
10689
- const v = { "@": "%40", "/": "%2F", "?": "%3F", "#": "%23", ":": "%3A" }, S = /[@/?#:]/g, _ = /[@/?#]/g;
10704
+ const v = { "@": "%40", "/": "%2F", "?": "%3F", "#": "%23", ":": "%3A" }, R = /[@/?#:]/g, _ = /[@/?#]/g;
10690
10705
  function f(d, m) {
10691
- const w = m ? _ : S;
10692
- return w.lastIndex = 0, d.replace(w, (R) => v[R]);
10706
+ const w = m ? _ : R;
10707
+ return w.lastIndex = 0, d.replace(w, (T) => v[T]);
10693
10708
  }
10694
10709
  function g(d, m = !1) {
10695
10710
  if (d.indexOf("%") === -1)
10696
10711
  return d;
10697
10712
  let w = "";
10698
- for (let R = 0; R < d.length; R++) {
10699
- if (d[R] === "%" && R + 2 < d.length) {
10700
- const I = d.slice(R + 1, R + 3);
10713
+ for (let T = 0; T < d.length; T++) {
10714
+ if (d[T] === "%" && T + 2 < d.length) {
10715
+ const I = d.slice(T + 1, T + 3);
10701
10716
  if (r(I)) {
10702
10717
  const L = I.toUpperCase(), N = String.fromCharCode(parseInt(L, 16));
10703
- m && n(N) ? w += N : w += "%" + L, R += 2;
10718
+ m && n(N) ? w += N : w += "%" + L, T += 2;
10704
10719
  continue;
10705
10720
  }
10706
10721
  }
10707
- w += d[R];
10722
+ w += d[T];
10708
10723
  }
10709
10724
  return w;
10710
10725
  }
@@ -10712,9 +10727,9 @@ function qi() {
10712
10727
  let m = "";
10713
10728
  for (let w = 0; w < d.length; w++) {
10714
10729
  if (d[w] === "%" && w + 2 < d.length) {
10715
- const R = d.slice(w + 1, w + 3);
10716
- if (r(R)) {
10717
- const I = R.toUpperCase(), L = String.fromCharCode(parseInt(I, 16));
10730
+ const T = d.slice(w + 1, w + 3);
10731
+ if (r(T)) {
10732
+ const I = T.toUpperCase(), L = String.fromCharCode(parseInt(I, 16));
10718
10733
  L !== "." && n(L) ? m += L : m += "%" + I, w += 2;
10719
10734
  continue;
10720
10735
  }
@@ -10727,9 +10742,9 @@ function qi() {
10727
10742
  let m = "";
10728
10743
  for (let w = 0; w < d.length; w++) {
10729
10744
  if (d[w] === "%" && w + 2 < d.length) {
10730
- const R = d.slice(w + 1, w + 3);
10731
- if (r(R)) {
10732
- m += "%" + R.toUpperCase(), w += 2;
10745
+ const T = d.slice(w + 1, w + 3);
10746
+ if (r(T)) {
10747
+ m += "%" + T.toUpperCase(), w += 2;
10733
10748
  continue;
10734
10749
  }
10735
10750
  }
@@ -10737,13 +10752,13 @@ function qi() {
10737
10752
  }
10738
10753
  return m;
10739
10754
  }
10740
- function T(d) {
10755
+ function S(d) {
10741
10756
  const m = [];
10742
10757
  if (d.userinfo !== void 0 && (m.push(d.userinfo), m.push("@")), d.host !== void 0) {
10743
10758
  let w = unescape(d.host);
10744
10759
  if (!e(w)) {
10745
- const R = l(w);
10746
- R.isIPV6 === !0 ? w = `[${R.escapedHost}]` : w = f(w, !1);
10760
+ const T = l(w);
10761
+ T.isIPV6 === !0 ? w = `[${T.escapedHost}]` : w = f(w, !1);
10747
10762
  }
10748
10763
  m.push(w);
10749
10764
  }
@@ -10751,7 +10766,7 @@ function qi() {
10751
10766
  }
10752
10767
  return Dn = {
10753
10768
  nonSimpleDomain: a,
10754
- recomposeAuthority: T,
10769
+ recomposeAuthority: S,
10755
10770
  reescapeHostDelimiters: f,
10756
10771
  normalizePercentEncoding: g,
10757
10772
  normalizePathEncoding: p,
@@ -10809,9 +10824,9 @@ function eg() {
10809
10824
  return d.error = "URN can not be parsed", d;
10810
10825
  const w = d.path.match(e);
10811
10826
  if (w) {
10812
- const R = m.scheme || d.scheme || "urn";
10827
+ const T = m.scheme || d.scheme || "urn";
10813
10828
  d.nid = w[1].toLowerCase(), d.nss = w[2];
10814
- const I = `${R}:${m.nid || d.nid}`, L = T(I);
10829
+ const I = `${T}:${m.nid || d.nid}`, L = S(I);
10815
10830
  d.path = void 0, L && (d = L.parse(d, m));
10816
10831
  } else
10817
10832
  d.error = d.error || "URN can not be parsed.";
@@ -10820,10 +10835,10 @@ function eg() {
10820
10835
  function l(d, m) {
10821
10836
  if (d.nid === void 0)
10822
10837
  throw new Error("URN without nid cannot be serialized");
10823
- const w = m.scheme || d.scheme || "urn", R = d.nid.toLowerCase(), I = `${w}:${m.nid || R}`, L = T(I);
10838
+ const w = m.scheme || d.scheme || "urn", T = d.nid.toLowerCase(), I = `${w}:${m.nid || T}`, L = S(I);
10824
10839
  L && (d = L.serialize(d, m));
10825
10840
  const N = d, k = d.nss;
10826
- return N.path = `${R || m.nid}:${k}`, m.skipEscape = !0, N;
10841
+ return N.path = `${T || m.nid}:${k}`, m.skipEscape = !0, N;
10827
10842
  }
10828
10843
  function h(d, m) {
10829
10844
  const w = d;
@@ -10841,7 +10856,7 @@ function eg() {
10841
10856
  parse: o,
10842
10857
  serialize: a
10843
10858
  }
10844
- ), S = (
10859
+ ), R = (
10845
10860
  /** @type {SchemeHandler} */
10846
10861
  {
10847
10862
  scheme: "https",
@@ -10869,7 +10884,7 @@ function eg() {
10869
10884
  /** @type {Record<SchemeName, SchemeHandler>} */
10870
10885
  {
10871
10886
  http: v,
10872
- https: S,
10887
+ https: R,
10873
10888
  ws: _,
10874
10889
  wss: f,
10875
10890
  urn: (
@@ -10893,7 +10908,7 @@ function eg() {
10893
10908
  }
10894
10909
  );
10895
10910
  Object.setPrototypeOf(b, null);
10896
- function T(d) {
10911
+ function S(d) {
10897
10912
  return d && (b[
10898
10913
  /** @type {SchemeName} */
10899
10914
  d
@@ -10906,7 +10921,7 @@ function eg() {
10906
10921
  wsIsSecure: s,
10907
10922
  SCHEMES: b,
10908
10923
  isValidSchemeName: n,
10909
- getSchemeHandler: T
10924
+ getSchemeHandler: S
10910
10925
  }, Cn;
10911
10926
  }
10912
10927
  var Fo;
@@ -10914,38 +10929,38 @@ function tg() {
10914
10929
  if (Fo) return It.exports;
10915
10930
  Fo = 1;
10916
10931
  const { normalizeIPv6: t, removeDotSegments: e, recomposeAuthority: r, normalizePercentEncoding: n, normalizePathEncoding: s, escapePreservingEscapes: o, reescapeHostDelimiters: a, isIPv4: i, nonSimpleDomain: c } = qi(), { SCHEMES: u, getSchemeHandler: l } = eg();
10917
- function h(R, I) {
10918
- return typeof R == "string" ? R = /** @type {T} */
10919
- T(R, I) : typeof R == "object" && (R = /** @type {T} */
10920
- b(_(R, I), I)), R;
10932
+ function h(T, I) {
10933
+ return typeof T == "string" ? T = /** @type {T} */
10934
+ S(T, I) : typeof T == "object" && (T = /** @type {T} */
10935
+ b(_(T, I), I)), T;
10921
10936
  }
10922
- function y(R, I, L) {
10923
- const N = L ? Object.assign({ scheme: "null" }, L) : { scheme: "null" }, k = v(b(R, N), b(I, N), N, !0);
10937
+ function y(T, I, L) {
10938
+ const N = L ? Object.assign({ scheme: "null" }, L) : { scheme: "null" }, k = v(b(T, N), b(I, N), N, !0);
10924
10939
  return N.skipEscape = !0, _(k, N);
10925
10940
  }
10926
- function v(R, I, L, N) {
10941
+ function v(T, I, L, N) {
10927
10942
  const k = {};
10928
- return N || (R = b(_(R, L), L), I = b(_(I, L), L)), L = L || {}, !L.tolerant && I.scheme ? (k.scheme = I.scheme, k.userinfo = I.userinfo, k.host = I.host, k.port = I.port, k.path = e(I.path || ""), k.query = I.query) : (I.userinfo !== void 0 || I.host !== void 0 || I.port !== void 0 ? (k.userinfo = I.userinfo, k.host = I.host, k.port = I.port, k.path = e(I.path || ""), k.query = I.query) : (I.path ? (I.path[0] === "/" ? k.path = e(I.path) : ((R.userinfo !== void 0 || R.host !== void 0 || R.port !== void 0) && !R.path ? k.path = "/" + I.path : R.path ? k.path = R.path.slice(0, R.path.lastIndexOf("/") + 1) + I.path : k.path = I.path, k.path = e(k.path)), k.query = I.query) : (k.path = R.path, I.query !== void 0 ? k.query = I.query : k.query = R.query), k.userinfo = R.userinfo, k.host = R.host, k.port = R.port), k.scheme = R.scheme), k.fragment = I.fragment, k;
10943
+ return N || (T = b(_(T, L), L), I = b(_(I, L), L)), L = L || {}, !L.tolerant && I.scheme ? (k.scheme = I.scheme, k.userinfo = I.userinfo, k.host = I.host, k.port = I.port, k.path = e(I.path || ""), k.query = I.query) : (I.userinfo !== void 0 || I.host !== void 0 || I.port !== void 0 ? (k.userinfo = I.userinfo, k.host = I.host, k.port = I.port, k.path = e(I.path || ""), k.query = I.query) : (I.path ? (I.path[0] === "/" ? k.path = e(I.path) : ((T.userinfo !== void 0 || T.host !== void 0 || T.port !== void 0) && !T.path ? k.path = "/" + I.path : T.path ? k.path = T.path.slice(0, T.path.lastIndexOf("/") + 1) + I.path : k.path = I.path, k.path = e(k.path)), k.query = I.query) : (k.path = T.path, I.query !== void 0 ? k.query = I.query : k.query = T.query), k.userinfo = T.userinfo, k.host = T.host, k.port = T.port), k.scheme = T.scheme), k.fragment = I.fragment, k;
10929
10944
  }
10930
- function S(R, I, L) {
10931
- const N = m(R, L), k = m(I, L);
10945
+ function R(T, I, L) {
10946
+ const N = m(T, L), k = m(I, L);
10932
10947
  return N !== void 0 && k !== void 0 && N.toLowerCase() === k.toLowerCase();
10933
10948
  }
10934
- function _(R, I) {
10949
+ function _(T, I) {
10935
10950
  const L = {
10936
- host: R.host,
10937
- scheme: R.scheme,
10938
- userinfo: R.userinfo,
10939
- port: R.port,
10940
- path: R.path,
10941
- query: R.query,
10942
- nid: R.nid,
10943
- nss: R.nss,
10944
- uuid: R.uuid,
10945
- fragment: R.fragment,
10946
- reference: R.reference,
10947
- resourceName: R.resourceName,
10948
- secure: R.secure,
10951
+ host: T.host,
10952
+ scheme: T.scheme,
10953
+ userinfo: T.userinfo,
10954
+ port: T.port,
10955
+ path: T.path,
10956
+ query: T.query,
10957
+ nid: T.nid,
10958
+ nss: T.nss,
10959
+ uuid: T.uuid,
10960
+ fragment: T.fragment,
10961
+ reference: T.reference,
10962
+ resourceName: T.resourceName,
10963
+ secure: T.secure,
10949
10964
  error: ""
10950
10965
  }, N = Object.assign({}, I), k = [], B = l(N.scheme || L.scheme);
10951
10966
  B && B.serialize && B.serialize(L, N), L.path !== void 0 && (N.skipEscape ? L.path = n(L.path) : (L.path = o(L.path), L.scheme !== void 0 && (L.path = L.path.split("%3A").join(":")))), N.reference !== "suffix" && L.scheme && k.push(L.scheme, ":");
@@ -10957,13 +10972,13 @@ function tg() {
10957
10972
  return L.query !== void 0 && k.push("?", L.query), L.fragment !== void 0 && k.push("#", L.fragment), k.join("");
10958
10973
  }
10959
10974
  const f = /^(?:([^#/:?]+):)?(?:\/\/((?:([^#/?@]*)@)?(\[[^#/?\]]+\]|[^#/:?]*)(?::(\d*))?))?([^#?]*)(?:\?([^#]*))?(?:#((?:.|[\n\r])*))?/u;
10960
- function g(R, I) {
10961
- if (I[2] !== void 0 && R.path && R.path[0] !== "/")
10975
+ function g(T, I) {
10976
+ if (I[2] !== void 0 && T.path && T.path[0] !== "/")
10962
10977
  return 'URI path must start with "/" when authority is present.';
10963
- if (typeof R.port == "number" && (R.port < 0 || R.port > 65535))
10978
+ if (typeof T.port == "number" && (T.port < 0 || T.port > 65535))
10964
10979
  return "URI port is malformed.";
10965
10980
  }
10966
- function p(R, I) {
10981
+ function p(T, I) {
10967
10982
  const L = Object.assign({}, I), N = {
10968
10983
  scheme: void 0,
10969
10984
  userinfo: void 0,
@@ -10974,8 +10989,8 @@ function tg() {
10974
10989
  fragment: void 0
10975
10990
  };
10976
10991
  let k = !1, B = !1;
10977
- L.reference === "suffix" && (L.scheme ? R = L.scheme + ":" + R : R = "//" + R);
10978
- const V = R.match(f);
10992
+ L.reference === "suffix" && (L.scheme ? T = L.scheme + ":" + T : T = "//" + T);
10993
+ const V = T.match(f);
10979
10994
  if (V) {
10980
10995
  N.scheme = V[1], N.userinfo = V[3], N.host = V[4], N.port = parseInt(V[5], 10), N.path = V[6] || "", N.query = V[7], N.fragment = V[8], isNaN(N.port) && (N.port = V[5]);
10981
10996
  const J = g(N, V);
@@ -10993,7 +11008,7 @@ function tg() {
10993
11008
  } catch (we) {
10994
11009
  N.error = N.error || "Host's domain name can not be converted to ASCII: " + we;
10995
11010
  }
10996
- if ((!ne || ne && !ne.skipNormalize) && (R.indexOf("%") !== -1 && (N.scheme !== void 0 && (N.scheme = unescape(N.scheme)), N.host !== void 0 && (N.host = a(unescape(N.host), B))), N.path && (N.path = s(N.path)), N.fragment))
11011
+ if ((!ne || ne && !ne.skipNormalize) && (T.indexOf("%") !== -1 && (N.scheme !== void 0 && (N.scheme = unescape(N.scheme)), N.host !== void 0 && (N.host = a(unescape(N.host), B))), N.path && (N.path = s(N.path)), N.fragment))
10997
11012
  try {
10998
11013
  N.fragment = encodeURI(decodeURIComponent(N.fragment));
10999
11014
  } catch {
@@ -11004,33 +11019,33 @@ function tg() {
11004
11019
  N.error = N.error || "URI can not be parsed.";
11005
11020
  return { parsed: N, malformedAuthorityOrPort: k };
11006
11021
  }
11007
- function b(R, I) {
11008
- return p(R, I).parsed;
11022
+ function b(T, I) {
11023
+ return p(T, I).parsed;
11009
11024
  }
11010
- function T(R, I) {
11011
- return d(R, I).normalized;
11025
+ function S(T, I) {
11026
+ return d(T, I).normalized;
11012
11027
  }
11013
- function d(R, I) {
11014
- const { parsed: L, malformedAuthorityOrPort: N } = p(R, I);
11028
+ function d(T, I) {
11029
+ const { parsed: L, malformedAuthorityOrPort: N } = p(T, I);
11015
11030
  return {
11016
- normalized: N ? R : _(L, I),
11031
+ normalized: N ? T : _(L, I),
11017
11032
  malformedAuthorityOrPort: N
11018
11033
  };
11019
11034
  }
11020
- function m(R, I) {
11021
- if (typeof R == "string") {
11022
- const { normalized: L, malformedAuthorityOrPort: N } = d(R, I);
11035
+ function m(T, I) {
11036
+ if (typeof T == "string") {
11037
+ const { normalized: L, malformedAuthorityOrPort: N } = d(T, I);
11023
11038
  return N ? void 0 : L;
11024
11039
  }
11025
- if (typeof R == "object")
11026
- return _(R, I);
11040
+ if (typeof T == "object")
11041
+ return _(T, I);
11027
11042
  }
11028
11043
  const w = {
11029
11044
  SCHEMES: u,
11030
11045
  normalize: h,
11031
11046
  resolve: y,
11032
11047
  resolveComponent: v,
11033
- equal: S,
11048
+ equal: R,
11034
11049
  serialize: _,
11035
11050
  parse: b
11036
11051
  };
@@ -11067,7 +11082,7 @@ function ng() {
11067
11082
  } });
11068
11083
  const n = Es(), s = cn(), o = ki(), a = bs(), i = te(), c = on(), u = zr(), l = se(), h = Zm, y = rg(), v = (q, P) => new RegExp(q, P);
11069
11084
  v.code = "new RegExp";
11070
- const S = ["removeAdditional", "useDefaults", "coerceTypes"], _ = /* @__PURE__ */ new Set([
11085
+ const R = ["removeAdditional", "useDefaults", "coerceTypes"], _ = /* @__PURE__ */ new Set([
11071
11086
  "validate",
11072
11087
  "serialize",
11073
11088
  "parse",
@@ -11104,14 +11119,14 @@ function ng() {
11104
11119
  }, p = 200;
11105
11120
  function b(q) {
11106
11121
  var P, U, D, E, O, x, z, j, Z, Q, A, C, M, F, G, ee, Ee, Ce, Oe, Ae, be, st, Ie, un, ln;
11107
- const Rt = q.strict, dn = (P = q.code) === null || P === void 0 ? void 0 : P.optimize, Ts = dn === !0 || dn === void 0 ? 1 : dn || 0, Os = (D = (U = q.code) === null || U === void 0 ? void 0 : U.regExp) !== null && D !== void 0 ? D : v, rc = (E = q.uriResolver) !== null && E !== void 0 ? E : y.default;
11122
+ const Tt = q.strict, dn = (P = q.code) === null || P === void 0 ? void 0 : P.optimize, Ss = dn === !0 || dn === void 0 ? 1 : dn || 0, Os = (D = (U = q.code) === null || U === void 0 ? void 0 : U.regExp) !== null && D !== void 0 ? D : v, rc = (E = q.uriResolver) !== null && E !== void 0 ? E : y.default;
11108
11123
  return {
11109
- strictSchema: (x = (O = q.strictSchema) !== null && O !== void 0 ? O : Rt) !== null && x !== void 0 ? x : !0,
11110
- strictNumbers: (j = (z = q.strictNumbers) !== null && z !== void 0 ? z : Rt) !== null && j !== void 0 ? j : !0,
11111
- strictTypes: (Q = (Z = q.strictTypes) !== null && Z !== void 0 ? Z : Rt) !== null && Q !== void 0 ? Q : "log",
11112
- strictTuples: (C = (A = q.strictTuples) !== null && A !== void 0 ? A : Rt) !== null && C !== void 0 ? C : "log",
11113
- strictRequired: (F = (M = q.strictRequired) !== null && M !== void 0 ? M : Rt) !== null && F !== void 0 ? F : !1,
11114
- code: q.code ? { ...q.code, optimize: Ts, regExp: Os } : { optimize: Ts, regExp: Os },
11124
+ strictSchema: (x = (O = q.strictSchema) !== null && O !== void 0 ? O : Tt) !== null && x !== void 0 ? x : !0,
11125
+ strictNumbers: (j = (z = q.strictNumbers) !== null && z !== void 0 ? z : Tt) !== null && j !== void 0 ? j : !0,
11126
+ strictTypes: (Q = (Z = q.strictTypes) !== null && Z !== void 0 ? Z : Tt) !== null && Q !== void 0 ? Q : "log",
11127
+ strictTuples: (C = (A = q.strictTuples) !== null && A !== void 0 ? A : Tt) !== null && C !== void 0 ? C : "log",
11128
+ strictRequired: (F = (M = q.strictRequired) !== null && M !== void 0 ? M : Tt) !== null && F !== void 0 ? F : !1,
11129
+ code: q.code ? { ...q.code, optimize: Ss, regExp: Os } : { optimize: Ss, regExp: Os },
11115
11130
  loopRequired: (G = q.loopRequired) !== null && G !== void 0 ? G : p,
11116
11131
  loopEnum: (ee = q.loopEnum) !== null && ee !== void 0 ? ee : p,
11117
11132
  meta: (Ee = q.meta) !== null && Ee !== void 0 ? Ee : !0,
@@ -11126,13 +11141,13 @@ function ng() {
11126
11141
  uriResolver: rc
11127
11142
  };
11128
11143
  }
11129
- class T {
11144
+ class S {
11130
11145
  constructor(P = {}) {
11131
11146
  this.schemas = {}, this.refs = {}, this.formats = {}, this._compilations = /* @__PURE__ */ new Set(), this._loading = {}, this._cache = /* @__PURE__ */ new Map(), P = this.opts = { ...P, ...b(P) };
11132
11147
  const { es5: U, lines: D } = this.opts.code;
11133
11148
  this.scope = new i.ValueScope({ scope: {}, prefixes: _, es5: U, lines: D }), this.logger = k(P.logger);
11134
11149
  const E = P.validateFormats;
11135
- P.validateFormats = !1, this.RULES = (0, o.getRules)(), d.call(this, f, P, "NOT SUPPORTED"), d.call(this, g, P, "DEPRECATED", "warn"), this._metaOpts = L.call(this), P.formats && R.call(this), this._addVocabularies(), this._addDefaultMetaSchema(), P.keywords && I.call(this, P.keywords), typeof P.meta == "object" && this.addMetaSchema(P.meta), w.call(this), P.validateFormats = E;
11150
+ P.validateFormats = !1, this.RULES = (0, o.getRules)(), d.call(this, f, P, "NOT SUPPORTED"), d.call(this, g, P, "DEPRECATED", "warn"), this._metaOpts = L.call(this), P.formats && T.call(this), this._addVocabularies(), this._addDefaultMetaSchema(), P.keywords && I.call(this, P.keywords), typeof P.meta == "object" && this.addMetaSchema(P.meta), w.call(this), P.validateFormats = E;
11136
11151
  }
11137
11152
  _addVocabularies() {
11138
11153
  this.addKeyword("$async");
@@ -11385,7 +11400,7 @@ function ng() {
11385
11400
  }
11386
11401
  }
11387
11402
  }
11388
- T.ValidationError = n.default, T.MissingRefError = s.default, t.default = T;
11403
+ S.ValidationError = n.default, S.MissingRefError = s.default, t.default = S;
11389
11404
  function d(q, P, U, D = "error") {
11390
11405
  for (const E in q) {
11391
11406
  const O = E;
@@ -11404,7 +11419,7 @@ function ng() {
11404
11419
  for (const P in q)
11405
11420
  this.addSchema(q[P], P);
11406
11421
  }
11407
- function R() {
11422
+ function T() {
11408
11423
  for (const q in this.opts.formats) {
11409
11424
  const P = this.opts.formats[q];
11410
11425
  P && this.addFormat(q, P);
@@ -11423,7 +11438,7 @@ function ng() {
11423
11438
  }
11424
11439
  function L() {
11425
11440
  const q = { ...this.opts };
11426
- for (const P of S)
11441
+ for (const P of R)
11427
11442
  delete q[P];
11428
11443
  return q;
11429
11444
  }
@@ -11484,7 +11499,7 @@ function ng() {
11484
11499
  function oe(q) {
11485
11500
  return { anyOf: [q, re] };
11486
11501
  }
11487
- })(Tn)), Tn;
11502
+ })(Sn)), Sn;
11488
11503
  }
11489
11504
  var Xt = {}, Zt = {}, er = {}, Ho;
11490
11505
  function sg() {
@@ -11506,31 +11521,31 @@ function og() {
11506
11521
  keyword: "$ref",
11507
11522
  schemaType: "string",
11508
11523
  code(u) {
11509
- const { gen: l, schema: h, it: y } = u, { baseId: v, schemaEnv: S, validateName: _, opts: f, self: g } = y, { root: p } = S;
11524
+ const { gen: l, schema: h, it: y } = u, { baseId: v, schemaEnv: R, validateName: _, opts: f, self: g } = y, { root: p } = R;
11510
11525
  if ((h === "#" || h === "#/") && v === p.baseId)
11511
- return T();
11526
+ return S();
11512
11527
  const b = s.resolveRef.call(g, p, v, h);
11513
11528
  if (b === void 0)
11514
11529
  throw new t.default(y.opts.uriResolver, v, h);
11515
11530
  if (b instanceof s.SchemaEnv)
11516
11531
  return d(b);
11517
11532
  return m(b);
11518
- function T() {
11519
- if (S === p)
11520
- return c(u, _, S, S.$async);
11533
+ function S() {
11534
+ if (R === p)
11535
+ return c(u, _, R, R.$async);
11521
11536
  const w = l.scopeValue("root", { ref: p });
11522
11537
  return c(u, (0, r._)`${w}.validate`, p, p.$async);
11523
11538
  }
11524
11539
  function d(w) {
11525
- const R = i(u, w);
11526
- c(u, R, w, w.$async);
11540
+ const T = i(u, w);
11541
+ c(u, T, w, w.$async);
11527
11542
  }
11528
11543
  function m(w) {
11529
- const R = l.scopeValue("schema", f.code.source === !0 ? { ref: w, code: (0, r.stringify)(w) } : { ref: w }), I = l.name("valid"), L = u.subschema({
11544
+ const T = l.scopeValue("schema", f.code.source === !0 ? { ref: w, code: (0, r.stringify)(w) } : { ref: w }), I = l.name("valid"), L = u.subschema({
11530
11545
  schema: w,
11531
11546
  dataTypes: [],
11532
11547
  schemaPath: r.nil,
11533
- topSchemaRef: R,
11548
+ topSchemaRef: T,
11534
11549
  errSchemaPath: h
11535
11550
  }, I);
11536
11551
  u.mergeEvaluated(L), u.ok(I);
@@ -11543,43 +11558,43 @@ function og() {
11543
11558
  }
11544
11559
  ze.getValidate = i;
11545
11560
  function c(u, l, h, y) {
11546
- const { gen: v, it: S } = u, { allErrors: _, schemaEnv: f, opts: g } = S, p = g.passContext ? n.default.this : r.nil;
11547
- y ? b() : T();
11561
+ const { gen: v, it: R } = u, { allErrors: _, schemaEnv: f, opts: g } = R, p = g.passContext ? n.default.this : r.nil;
11562
+ y ? b() : S();
11548
11563
  function b() {
11549
11564
  if (!f.$async)
11550
11565
  throw new Error("async schema referenced by sync schema");
11551
11566
  const w = v.let("valid");
11552
11567
  v.try(() => {
11553
11568
  v.code((0, r._)`await ${(0, e.callValidateCode)(u, l, p)}`), m(l), _ || v.assign(w, !0);
11554
- }, (R) => {
11555
- v.if((0, r._)`!(${R} instanceof ${S.ValidationError})`, () => v.throw(R)), d(R), _ || v.assign(w, !1);
11569
+ }, (T) => {
11570
+ v.if((0, r._)`!(${T} instanceof ${R.ValidationError})`, () => v.throw(T)), d(T), _ || v.assign(w, !1);
11556
11571
  }), u.ok(w);
11557
11572
  }
11558
- function T() {
11573
+ function S() {
11559
11574
  u.result((0, e.callValidateCode)(u, l, p), () => m(l), () => d(l));
11560
11575
  }
11561
11576
  function d(w) {
11562
- const R = (0, r._)`${w}.errors`;
11563
- v.assign(n.default.vErrors, (0, r._)`${n.default.vErrors} === null ? ${R} : ${n.default.vErrors}.concat(${R})`), v.assign(n.default.errors, (0, r._)`${n.default.vErrors}.length`);
11577
+ const T = (0, r._)`${w}.errors`;
11578
+ v.assign(n.default.vErrors, (0, r._)`${n.default.vErrors} === null ? ${T} : ${n.default.vErrors}.concat(${T})`), v.assign(n.default.errors, (0, r._)`${n.default.vErrors}.length`);
11564
11579
  }
11565
11580
  function m(w) {
11566
- var R;
11567
- if (!S.opts.unevaluated)
11581
+ var T;
11582
+ if (!R.opts.unevaluated)
11568
11583
  return;
11569
- const I = (R = h?.validate) === null || R === void 0 ? void 0 : R.evaluated;
11570
- if (S.props !== !0)
11584
+ const I = (T = h?.validate) === null || T === void 0 ? void 0 : T.evaluated;
11585
+ if (R.props !== !0)
11571
11586
  if (I && !I.dynamicProps)
11572
- I.props !== void 0 && (S.props = o.mergeEvaluated.props(v, I.props, S.props));
11587
+ I.props !== void 0 && (R.props = o.mergeEvaluated.props(v, I.props, R.props));
11573
11588
  else {
11574
11589
  const L = v.var("props", (0, r._)`${w}.evaluated.props`);
11575
- S.props = o.mergeEvaluated.props(v, L, S.props, r.Name);
11590
+ R.props = o.mergeEvaluated.props(v, L, R.props, r.Name);
11576
11591
  }
11577
- if (S.items !== !0)
11592
+ if (R.items !== !0)
11578
11593
  if (I && !I.dynamicItems)
11579
- I.items !== void 0 && (S.items = o.mergeEvaluated.items(v, I.items, S.items));
11594
+ I.items !== void 0 && (R.items = o.mergeEvaluated.items(v, I.items, R.items));
11580
11595
  else {
11581
11596
  const L = v.var("items", (0, r._)`${w}.evaluated.items`);
11582
- S.items = o.mergeEvaluated.items(v, L, S.items, r.Name);
11597
+ R.items = o.mergeEvaluated.items(v, L, R.items, r.Name);
11583
11598
  }
11584
11599
  }
11585
11600
  }
@@ -11743,15 +11758,15 @@ function pg() {
11743
11758
  if (!l && i.length === 0)
11744
11759
  return;
11745
11760
  const v = i.length >= y.loopRequired;
11746
- if (h.allErrors ? S() : _(), y.strictRequired) {
11761
+ if (h.allErrors ? R() : _(), y.strictRequired) {
11747
11762
  const p = o.parentSchema.properties, { definedProperties: b } = o.it;
11748
- for (const T of i)
11749
- if (p?.[T] === void 0 && !b.has(T)) {
11750
- const d = h.schemaEnv.baseId + h.errSchemaPath, m = `required property "${T}" is not defined at "${d}" (strictRequired)`;
11763
+ for (const S of i)
11764
+ if (p?.[S] === void 0 && !b.has(S)) {
11765
+ const d = h.schemaEnv.baseId + h.errSchemaPath, m = `required property "${S}" is not defined at "${d}" (strictRequired)`;
11751
11766
  (0, r.checkStrictMode)(h, m, h.opts.strictRequired);
11752
11767
  }
11753
11768
  }
11754
- function S() {
11769
+ function R() {
11755
11770
  if (v || l)
11756
11771
  o.block$data(e.nil, f);
11757
11772
  else
@@ -11829,27 +11844,27 @@ function mg() {
11829
11844
  const { gen: i, data: c, $data: u, schema: l, parentSchema: h, schemaCode: y, it: v } = a;
11830
11845
  if (!u && !l)
11831
11846
  return;
11832
- const S = i.let("valid"), _ = h.items ? (0, t.getSchemaTypes)(h.items) : [];
11833
- a.block$data(S, f, (0, e._)`${y} === false`), a.ok(S);
11847
+ const R = i.let("valid"), _ = h.items ? (0, t.getSchemaTypes)(h.items) : [];
11848
+ a.block$data(R, f, (0, e._)`${y} === false`), a.ok(R);
11834
11849
  function f() {
11835
- const T = i.let("i", (0, e._)`${c}.length`), d = i.let("j");
11836
- a.setParams({ i: T, j: d }), i.assign(S, !0), i.if((0, e._)`${T} > 1`, () => (g() ? p : b)(T, d));
11850
+ const S = i.let("i", (0, e._)`${c}.length`), d = i.let("j");
11851
+ a.setParams({ i: S, j: d }), i.assign(R, !0), i.if((0, e._)`${S} > 1`, () => (g() ? p : b)(S, d));
11837
11852
  }
11838
11853
  function g() {
11839
- return _.length > 0 && !_.some((T) => T === "object" || T === "array");
11840
- }
11841
- function p(T, d) {
11842
- const m = i.name("item"), w = (0, t.checkDataTypes)(_, m, v.opts.strictNumbers, t.DataType.Wrong), R = i.const("indices", (0, e._)`{}`);
11843
- i.for((0, e._)`;${T}--;`, () => {
11844
- i.let(m, (0, e._)`${c}[${T}]`), i.if(w, (0, e._)`continue`), _.length > 1 && i.if((0, e._)`typeof ${m} == "string"`, (0, e._)`${m} += "_"`), i.if((0, e._)`typeof ${R}[${m}] == "number"`, () => {
11845
- i.assign(d, (0, e._)`${R}[${m}]`), a.error(), i.assign(S, !1).break();
11846
- }).code((0, e._)`${R}[${m}] = ${T}`);
11854
+ return _.length > 0 && !_.some((S) => S === "object" || S === "array");
11855
+ }
11856
+ function p(S, d) {
11857
+ const m = i.name("item"), w = (0, t.checkDataTypes)(_, m, v.opts.strictNumbers, t.DataType.Wrong), T = i.const("indices", (0, e._)`{}`);
11858
+ i.for((0, e._)`;${S}--;`, () => {
11859
+ i.let(m, (0, e._)`${c}[${S}]`), i.if(w, (0, e._)`continue`), _.length > 1 && i.if((0, e._)`typeof ${m} == "string"`, (0, e._)`${m} += "_"`), i.if((0, e._)`typeof ${T}[${m}] == "number"`, () => {
11860
+ i.assign(d, (0, e._)`${T}[${m}]`), a.error(), i.assign(R, !1).break();
11861
+ }).code((0, e._)`${T}[${m}] = ${S}`);
11847
11862
  });
11848
11863
  }
11849
- function b(T, d) {
11864
+ function b(S, d) {
11850
11865
  const m = (0, r.useFunc)(i, n.default), w = i.name("outer");
11851
- i.label(w).for((0, e._)`;${T}--;`, () => i.for((0, e._)`${d} = ${T}; ${d}--;`, () => i.if((0, e._)`${m}(${c}[${T}], ${c}[${d}])`, () => {
11852
- a.error(), i.assign(S, !1).break(w);
11866
+ i.label(w).for((0, e._)`;${S}--;`, () => i.for((0, e._)`${d} = ${S}; ${d}--;`, () => i.if((0, e._)`${m}(${c}[${S}], ${c}[${d}])`, () => {
11867
+ a.error(), i.assign(R, !1).break(w);
11853
11868
  })));
11854
11869
  }
11855
11870
  }
@@ -11892,7 +11907,7 @@ function yg() {
11892
11907
  throw new Error("enum must have non-empty array");
11893
11908
  const y = u.length >= h.opts.loopEnum;
11894
11909
  let v;
11895
- const S = () => v ?? (v = (0, e.useFunc)(a, r.default));
11910
+ const R = () => v ?? (v = (0, e.useFunc)(a, r.default));
11896
11911
  let _;
11897
11912
  if (y || c)
11898
11913
  _ = a.let("valid"), o.block$data(_, f);
@@ -11900,15 +11915,15 @@ function yg() {
11900
11915
  if (!Array.isArray(u))
11901
11916
  throw new Error("ajv implementation error");
11902
11917
  const p = a.const("vSchema", l);
11903
- _ = (0, t.or)(...u.map((b, T) => g(p, T)));
11918
+ _ = (0, t.or)(...u.map((b, S) => g(p, S)));
11904
11919
  }
11905
11920
  o.pass(_);
11906
11921
  function f() {
11907
- a.assign(_, !1), a.forOf("v", l, (p) => a.if((0, t._)`${S()}(${i}, ${p})`, () => a.assign(_, !0).break()));
11922
+ a.assign(_, !1), a.forOf("v", l, (p) => a.if((0, t._)`${R()}(${i}, ${p})`, () => a.assign(_, !0).break()));
11908
11923
  }
11909
11924
  function g(p, b) {
11910
- const T = u[b];
11911
- return typeof T == "object" && T !== null ? (0, t._)`${S()}(${i}, ${p}[${b}])` : (0, t._)`${i} === ${T}`;
11925
+ const S = u[b];
11926
+ return typeof S == "object" && S !== null ? (0, t._)`${R()}(${i}, ${p}[${b}])` : (0, t._)`${i} === ${S}`;
11912
11927
  }
11913
11928
  }
11914
11929
  };
@@ -11968,12 +11983,12 @@ function Fi() {
11968
11983
  if (c === !1)
11969
11984
  o.setParams({ len: a.length }), o.pass((0, t._)`${y} <= ${a.length}`);
11970
11985
  else if (typeof c == "object" && !(0, e.alwaysValidSchema)(h, c)) {
11971
- const S = i.var("valid", (0, t._)`${y} <= ${a.length}`);
11972
- i.if((0, t.not)(S), () => v(S)), o.ok(S);
11986
+ const R = i.var("valid", (0, t._)`${y} <= ${a.length}`);
11987
+ i.if((0, t.not)(R), () => v(R)), o.ok(R);
11973
11988
  }
11974
- function v(S) {
11989
+ function v(R) {
11975
11990
  i.forRange("i", a.length, y, (_) => {
11976
- o.subschema({ keyword: l, dataProp: _, dataPropType: e.Type.Num }, S), h.allErrors || i.if((0, t.not)(S), () => i.break());
11991
+ o.subschema({ keyword: l, dataProp: _, dataPropType: e.Type.Num }, R), h.allErrors || i.if((0, t.not)(R), () => i.break());
11977
11992
  });
11978
11993
  }
11979
11994
  }
@@ -11998,17 +12013,17 @@ function ji() {
11998
12013
  function s(o, a, i = o.schema) {
11999
12014
  const { gen: c, parentSchema: u, data: l, keyword: h, it: y } = o;
12000
12015
  _(u), y.opts.unevaluated && i.length && y.items !== !0 && (y.items = e.mergeEvaluated.items(c, i.length, y.items));
12001
- const v = c.name("valid"), S = c.const("len", (0, t._)`${l}.length`);
12016
+ const v = c.name("valid"), R = c.const("len", (0, t._)`${l}.length`);
12002
12017
  i.forEach((f, g) => {
12003
- (0, e.alwaysValidSchema)(y, f) || (c.if((0, t._)`${S} > ${g}`, () => o.subschema({
12018
+ (0, e.alwaysValidSchema)(y, f) || (c.if((0, t._)`${R} > ${g}`, () => o.subschema({
12004
12019
  keyword: h,
12005
12020
  schemaProp: g,
12006
12021
  dataProp: g
12007
12022
  }, v)), o.ok(v));
12008
12023
  });
12009
12024
  function _(f) {
12010
- const { opts: g, errSchemaPath: p } = y, b = i.length, T = b === f.minItems && (b === f.maxItems || f[a] === !1);
12011
- if (g.strictTuples && !T) {
12025
+ const { opts: g, errSchemaPath: p } = y, b = i.length, S = b === f.minItems && (b === f.maxItems || f[a] === !1);
12026
+ if (g.strictTuples && !S) {
12012
12027
  const d = `"${h}" is ${b}-tuple, but minItems or maxItems/${a} are not specified or different at path "${p}"`;
12013
12028
  (0, e.checkStrictMode)(y, d, g.strictTuples);
12014
12029
  }
@@ -12068,7 +12083,7 @@ function _g() {
12068
12083
  let l, h;
12069
12084
  const { minContains: y, maxContains: v } = i;
12070
12085
  u.opts.next ? (l = y === void 0 ? 1 : y, h = v) : l = 1;
12071
- const S = o.const("len", (0, t._)`${c}.length`);
12086
+ const R = o.const("len", (0, t._)`${c}.length`);
12072
12087
  if (s.setParams({ min: l, max: h }), h === void 0 && l === 0) {
12073
12088
  (0, e.checkStrictMode)(u, '"minContains" == 0 without "maxContains": "contains" keyword ignored');
12074
12089
  return;
@@ -12078,25 +12093,25 @@ function _g() {
12078
12093
  return;
12079
12094
  }
12080
12095
  if ((0, e.alwaysValidSchema)(u, a)) {
12081
- let b = (0, t._)`${S} >= ${l}`;
12082
- h !== void 0 && (b = (0, t._)`${b} && ${S} <= ${h}`), s.pass(b);
12096
+ let b = (0, t._)`${R} >= ${l}`;
12097
+ h !== void 0 && (b = (0, t._)`${b} && ${R} <= ${h}`), s.pass(b);
12083
12098
  return;
12084
12099
  }
12085
12100
  u.items = !0;
12086
12101
  const _ = o.name("valid");
12087
12102
  h === void 0 && l === 1 ? g(_, () => o.if(_, () => o.break())) : l === 0 ? (o.let(_, !0), h !== void 0 && o.if((0, t._)`${c}.length > 0`, f)) : (o.let(_, !1), f()), s.result(_, () => s.reset());
12088
12103
  function f() {
12089
- const b = o.name("_valid"), T = o.let("count", 0);
12090
- g(b, () => o.if(b, () => p(T)));
12104
+ const b = o.name("_valid"), S = o.let("count", 0);
12105
+ g(b, () => o.if(b, () => p(S)));
12091
12106
  }
12092
- function g(b, T) {
12093
- o.forRange("i", 0, S, (d) => {
12107
+ function g(b, S) {
12108
+ o.forRange("i", 0, R, (d) => {
12094
12109
  s.subschema({
12095
12110
  keyword: "contains",
12096
12111
  dataProp: d,
12097
12112
  dataPropType: e.Type.Num,
12098
12113
  compositeRule: !0
12099
- }, b), T();
12114
+ }, b), S();
12100
12115
  });
12101
12116
  }
12102
12117
  function p(b) {
@@ -12147,13 +12162,13 @@ function vg() {
12147
12162
  if (Object.keys(u).length === 0)
12148
12163
  return;
12149
12164
  const v = l.let("missing");
12150
- for (const S in u) {
12151
- const _ = u[S];
12165
+ for (const R in u) {
12166
+ const _ = u[R];
12152
12167
  if (_.length === 0)
12153
12168
  continue;
12154
- const f = (0, n.propertyInData)(l, h, S, y.opts.ownProperties);
12169
+ const f = (0, n.propertyInData)(l, h, R, y.opts.ownProperties);
12155
12170
  c.setParams({
12156
- property: S,
12171
+ property: R,
12157
12172
  depsCount: _.length,
12158
12173
  deps: _.join(", ")
12159
12174
  }), y.allErrors ? l.if(f, () => {
@@ -12164,23 +12179,23 @@ function vg() {
12164
12179
  }
12165
12180
  t.validatePropertyDeps = a;
12166
12181
  function i(c, u = c.schema) {
12167
- const { gen: l, data: h, keyword: y, it: v } = c, S = l.name("valid");
12182
+ const { gen: l, data: h, keyword: y, it: v } = c, R = l.name("valid");
12168
12183
  for (const _ in u)
12169
12184
  (0, r.alwaysValidSchema)(v, u[_]) || (l.if(
12170
12185
  (0, n.propertyInData)(l, h, _, v.opts.ownProperties),
12171
12186
  () => {
12172
- const f = c.subschema({ keyword: y, schemaProp: _ }, S);
12173
- c.mergeValidEvaluated(f, S);
12187
+ const f = c.subschema({ keyword: y, schemaProp: _ }, R);
12188
+ c.mergeValidEvaluated(f, R);
12174
12189
  },
12175
- () => l.var(S, !0)
12190
+ () => l.var(R, !0)
12176
12191
  // TODO var
12177
- ), c.ok(S));
12192
+ ), c.ok(R));
12178
12193
  }
12179
12194
  t.validateSchemaDeps = i, t.default = s;
12180
12195
  })(Ln)), Ln;
12181
12196
  }
12182
12197
  var wr = {}, da;
12183
- function Rg() {
12198
+ function Tg() {
12184
12199
  if (da) return wr;
12185
12200
  da = 1, Object.defineProperty(wr, "__esModule", { value: !0 });
12186
12201
  const t = te(), e = se(), n = {
@@ -12229,29 +12244,29 @@ function Vi() {
12229
12244
  const { gen: i, schema: c, parentSchema: u, data: l, errsCount: h, it: y } = a;
12230
12245
  if (!h)
12231
12246
  throw new Error("ajv implementation error");
12232
- const { allErrors: v, opts: S } = y;
12233
- if (y.props = !0, S.removeAdditional !== "all" && (0, n.alwaysValidSchema)(y, c))
12247
+ const { allErrors: v, opts: R } = y;
12248
+ if (y.props = !0, R.removeAdditional !== "all" && (0, n.alwaysValidSchema)(y, c))
12234
12249
  return;
12235
12250
  const _ = (0, t.allSchemaProperties)(u.properties), f = (0, t.allSchemaProperties)(u.patternProperties);
12236
12251
  g(), a.ok((0, e._)`${h} === ${r.default.errors}`);
12237
12252
  function g() {
12238
12253
  i.forIn("key", l, (m) => {
12239
- !_.length && !f.length ? T(m) : i.if(p(m), () => T(m));
12254
+ !_.length && !f.length ? S(m) : i.if(p(m), () => S(m));
12240
12255
  });
12241
12256
  }
12242
12257
  function p(m) {
12243
12258
  let w;
12244
12259
  if (_.length > 8) {
12245
- const R = (0, n.schemaRefOrVal)(y, u.properties, "properties");
12246
- w = (0, t.isOwnProperty)(i, R, m);
12247
- } else _.length ? w = (0, e.or)(..._.map((R) => (0, e._)`${m} === ${R}`)) : w = e.nil;
12248
- return f.length && (w = (0, e.or)(w, ...f.map((R) => (0, e._)`${(0, t.usePattern)(a, R)}.test(${m})`))), (0, e.not)(w);
12260
+ const T = (0, n.schemaRefOrVal)(y, u.properties, "properties");
12261
+ w = (0, t.isOwnProperty)(i, T, m);
12262
+ } else _.length ? w = (0, e.or)(..._.map((T) => (0, e._)`${m} === ${T}`)) : w = e.nil;
12263
+ return f.length && (w = (0, e.or)(w, ...f.map((T) => (0, e._)`${(0, t.usePattern)(a, T)}.test(${m})`))), (0, e.not)(w);
12249
12264
  }
12250
12265
  function b(m) {
12251
12266
  i.code((0, e._)`delete ${l}[${m}]`);
12252
12267
  }
12253
- function T(m) {
12254
- if (S.removeAdditional === "all" || S.removeAdditional && c === !1) {
12268
+ function S(m) {
12269
+ if (R.removeAdditional === "all" || R.removeAdditional && c === !1) {
12255
12270
  b(m);
12256
12271
  return;
12257
12272
  }
@@ -12261,18 +12276,18 @@ function Vi() {
12261
12276
  }
12262
12277
  if (typeof c == "object" && !(0, n.alwaysValidSchema)(y, c)) {
12263
12278
  const w = i.name("valid");
12264
- S.removeAdditional === "failing" ? (d(m, w, !1), i.if((0, e.not)(w), () => {
12279
+ R.removeAdditional === "failing" ? (d(m, w, !1), i.if((0, e.not)(w), () => {
12265
12280
  a.reset(), b(m);
12266
12281
  })) : (d(m, w), v || i.if((0, e.not)(w), () => i.break()));
12267
12282
  }
12268
12283
  }
12269
- function d(m, w, R) {
12284
+ function d(m, w, T) {
12270
12285
  const I = {
12271
12286
  keyword: "additionalProperties",
12272
12287
  dataProp: m,
12273
12288
  dataPropType: n.Type.Str
12274
12289
  };
12275
- R === !1 && Object.assign(I, {
12290
+ T === !1 && Object.assign(I, {
12276
12291
  compositeRule: !0,
12277
12292
  createErrors: !1,
12278
12293
  allErrors: !1
@@ -12283,7 +12298,7 @@ function Vi() {
12283
12298
  return Er.default = o, Er;
12284
12299
  }
12285
12300
  var br = {}, pa;
12286
- function Sg() {
12301
+ function Rg() {
12287
12302
  if (pa) return br;
12288
12303
  pa = 1, Object.defineProperty(br, "__esModule", { value: !0 });
12289
12304
  const t = an(), e = ke(), r = se(), n = Vi(), s = {
@@ -12302,8 +12317,8 @@ function Sg() {
12302
12317
  return;
12303
12318
  const v = a.name("valid");
12304
12319
  for (const f of y)
12305
- S(f) ? _(f) : (a.if((0, e.propertyInData)(a, u, f, l.opts.ownProperties)), _(f), l.allErrors || a.else().var(v, !0), a.endIf()), o.it.definedProperties.add(f), o.ok(v);
12306
- function S(f) {
12320
+ R(f) ? _(f) : (a.if((0, e.propertyInData)(a, u, f, l.opts.ownProperties)), _(f), l.allErrors || a.else().var(v, !0), a.endIf()), o.it.definedProperties.add(f), o.ok(v);
12321
+ function R(f) {
12307
12322
  return l.opts.useDefaults && !l.compositeRule && i[f].default !== void 0;
12308
12323
  }
12309
12324
  function _(f) {
@@ -12318,7 +12333,7 @@ function Sg() {
12318
12333
  return br.default = s, br;
12319
12334
  }
12320
12335
  var _r = {}, ha;
12321
- function Tg() {
12336
+ function Sg() {
12322
12337
  if (ha) return _r;
12323
12338
  ha = 1, Object.defineProperty(_r, "__esModule", { value: !0 });
12324
12339
  const t = ke(), e = te(), r = se(), n = se(), s = {
@@ -12326,28 +12341,28 @@ function Tg() {
12326
12341
  type: "object",
12327
12342
  schemaType: "object",
12328
12343
  code(o) {
12329
- const { gen: a, schema: i, data: c, parentSchema: u, it: l } = o, { opts: h } = l, y = (0, t.allSchemaProperties)(i), v = y.filter((T) => (0, r.alwaysValidSchema)(l, i[T]));
12344
+ const { gen: a, schema: i, data: c, parentSchema: u, it: l } = o, { opts: h } = l, y = (0, t.allSchemaProperties)(i), v = y.filter((S) => (0, r.alwaysValidSchema)(l, i[S]));
12330
12345
  if (y.length === 0 || v.length === y.length && (!l.opts.unevaluated || l.props === !0))
12331
12346
  return;
12332
- const S = h.strictSchema && !h.allowMatchingProperties && u.properties, _ = a.name("valid");
12347
+ const R = h.strictSchema && !h.allowMatchingProperties && u.properties, _ = a.name("valid");
12333
12348
  l.props !== !0 && !(l.props instanceof e.Name) && (l.props = (0, n.evaluatedPropsToName)(a, l.props));
12334
12349
  const { props: f } = l;
12335
12350
  g();
12336
12351
  function g() {
12337
- for (const T of y)
12338
- S && p(T), l.allErrors ? b(T) : (a.var(_, !0), b(T), a.if(_));
12352
+ for (const S of y)
12353
+ R && p(S), l.allErrors ? b(S) : (a.var(_, !0), b(S), a.if(_));
12339
12354
  }
12340
- function p(T) {
12341
- for (const d in S)
12342
- new RegExp(T).test(d) && (0, r.checkStrictMode)(l, `property ${d} matches pattern ${T} (use allowMatchingProperties)`);
12355
+ function p(S) {
12356
+ for (const d in R)
12357
+ new RegExp(S).test(d) && (0, r.checkStrictMode)(l, `property ${d} matches pattern ${S} (use allowMatchingProperties)`);
12343
12358
  }
12344
- function b(T) {
12359
+ function b(S) {
12345
12360
  a.forIn("key", c, (d) => {
12346
- a.if((0, e._)`${(0, t.usePattern)(o, T)}.test(${d})`, () => {
12347
- const m = v.includes(T);
12361
+ a.if((0, e._)`${(0, t.usePattern)(o, S)}.test(${d})`, () => {
12362
+ const m = v.includes(S);
12348
12363
  m || o.subschema({
12349
12364
  keyword: "patternProperties",
12350
- schemaProp: T,
12365
+ schemaProp: S,
12351
12366
  dataProp: d,
12352
12367
  dataPropType: n.Type.Str
12353
12368
  }, _), l.opts.unevaluated && f !== !0 ? a.assign((0, e._)`${f}[${d}]`, !0) : !m && !l.allErrors && a.if((0, e.not)(_), () => a.break());
@@ -12384,10 +12399,10 @@ function Og() {
12384
12399
  };
12385
12400
  return vr.default = e, vr;
12386
12401
  }
12387
- var Rr = {}, ga;
12402
+ var Tr = {}, ga;
12388
12403
  function Ag() {
12389
- if (ga) return Rr;
12390
- ga = 1, Object.defineProperty(Rr, "__esModule", { value: !0 });
12404
+ if (ga) return Tr;
12405
+ ga = 1, Object.defineProperty(Tr, "__esModule", { value: !0 });
12391
12406
  const e = {
12392
12407
  keyword: "anyOf",
12393
12408
  schemaType: "array",
@@ -12395,12 +12410,12 @@ function Ag() {
12395
12410
  code: ke().validateUnion,
12396
12411
  error: { message: "must match a schema in anyOf" }
12397
12412
  };
12398
- return Rr.default = e, Rr;
12413
+ return Tr.default = e, Tr;
12399
12414
  }
12400
- var Sr = {}, ya;
12415
+ var Rr = {}, ya;
12401
12416
  function Ng() {
12402
- if (ya) return Sr;
12403
- ya = 1, Object.defineProperty(Sr, "__esModule", { value: !0 });
12417
+ if (ya) return Rr;
12418
+ ya = 1, Object.defineProperty(Rr, "__esModule", { value: !0 });
12404
12419
  const t = te(), e = se(), n = {
12405
12420
  keyword: "oneOf",
12406
12421
  schemaType: "array",
@@ -12418,9 +12433,9 @@ function Ng() {
12418
12433
  const u = a, l = o.let("valid", !1), h = o.let("passing", null), y = o.name("_valid");
12419
12434
  s.setParams({ passing: h }), o.block(v), s.result(l, () => s.reset(), () => s.error(!0));
12420
12435
  function v() {
12421
- u.forEach((S, _) => {
12436
+ u.forEach((R, _) => {
12422
12437
  let f;
12423
- (0, e.alwaysValidSchema)(c, S) ? o.var(y, !0) : f = s.subschema({
12438
+ (0, e.alwaysValidSchema)(c, R) ? o.var(y, !0) : f = s.subschema({
12424
12439
  keyword: "oneOf",
12425
12440
  schemaProp: _,
12426
12441
  compositeRule: !0
@@ -12431,12 +12446,12 @@ function Ng() {
12431
12446
  }
12432
12447
  }
12433
12448
  };
12434
- return Sr.default = n, Sr;
12449
+ return Rr.default = n, Rr;
12435
12450
  }
12436
- var Tr = {}, wa;
12451
+ var Sr = {}, wa;
12437
12452
  function Pg() {
12438
- if (wa) return Tr;
12439
- wa = 1, Object.defineProperty(Tr, "__esModule", { value: !0 });
12453
+ if (wa) return Sr;
12454
+ wa = 1, Object.defineProperty(Sr, "__esModule", { value: !0 });
12440
12455
  const t = se(), e = {
12441
12456
  keyword: "allOf",
12442
12457
  schemaType: "array",
@@ -12453,7 +12468,7 @@ function Pg() {
12453
12468
  });
12454
12469
  }
12455
12470
  };
12456
- return Tr.default = e, Tr;
12471
+ return Sr.default = e, Sr;
12457
12472
  }
12458
12473
  var Or = {}, Ea;
12459
12474
  function Ig() {
@@ -12476,8 +12491,8 @@ function Ig() {
12476
12491
  const h = a.let("valid", !0), y = a.name("_valid");
12477
12492
  if (v(), o.reset(), u && l) {
12478
12493
  const _ = a.let("ifClause");
12479
- o.setParams({ ifClause: _ }), a.if(y, S("then", _), S("else", _));
12480
- } else u ? a.if(y, S("then")) : a.if((0, t.not)(y), S("else"));
12494
+ o.setParams({ ifClause: _ }), a.if(y, R("then", _), R("else", _));
12495
+ } else u ? a.if(y, R("then")) : a.if((0, t.not)(y), R("else"));
12481
12496
  o.pass(h, () => o.error(!0));
12482
12497
  function v() {
12483
12498
  const _ = o.subschema({
@@ -12488,7 +12503,7 @@ function Ig() {
12488
12503
  }, y);
12489
12504
  o.mergeEvaluated(_);
12490
12505
  }
12491
- function S(_, f) {
12506
+ function R(_, f) {
12492
12507
  return () => {
12493
12508
  const g = o.subschema({ keyword: _ }, y);
12494
12509
  a.assign(h, y), o.mergeValidEvaluated(g, h), f ? a.assign(f, (0, t._)`${_}`) : o.setParams({ ifClause: _ });
@@ -12519,7 +12534,7 @@ var _a;
12519
12534
  function Dg() {
12520
12535
  if (_a) return hr;
12521
12536
  _a = 1, Object.defineProperty(hr, "__esModule", { value: !0 });
12522
- const t = Fi(), e = Eg(), r = ji(), n = bg(), s = _g(), o = vg(), a = Rg(), i = Vi(), c = Sg(), u = Tg(), l = Og(), h = Ag(), y = Ng(), v = Pg(), S = Ig(), _ = $g();
12537
+ const t = Fi(), e = Eg(), r = ji(), n = bg(), s = _g(), o = vg(), a = Tg(), i = Vi(), c = Rg(), u = Sg(), l = Og(), h = Ag(), y = Ng(), v = Pg(), R = Ig(), _ = $g();
12523
12538
  function f(g = !1) {
12524
12539
  const p = [
12525
12540
  // any
@@ -12527,7 +12542,7 @@ function Dg() {
12527
12542
  h.default,
12528
12543
  y.default,
12529
12544
  v.default,
12530
- S.default,
12545
+ R.default,
12531
12546
  _.default,
12532
12547
  // object
12533
12548
  a.default,
@@ -12554,71 +12569,71 @@ function Cg() {
12554
12569
  params: ({ schemaCode: n }) => (0, t._)`{format: ${n}}`
12555
12570
  },
12556
12571
  code(n, s) {
12557
- const { gen: o, data: a, $data: i, schema: c, schemaCode: u, it: l } = n, { opts: h, errSchemaPath: y, schemaEnv: v, self: S } = l;
12572
+ const { gen: o, data: a, $data: i, schema: c, schemaCode: u, it: l } = n, { opts: h, errSchemaPath: y, schemaEnv: v, self: R } = l;
12558
12573
  if (!h.validateFormats)
12559
12574
  return;
12560
12575
  i ? _() : f();
12561
12576
  function _() {
12562
12577
  const g = o.scopeValue("formats", {
12563
- ref: S.formats,
12578
+ ref: R.formats,
12564
12579
  code: h.code.formats
12565
- }), p = o.const("fDef", (0, t._)`${g}[${u}]`), b = o.let("fType"), T = o.let("format");
12566
- o.if((0, t._)`typeof ${p} == "object" && !(${p} instanceof RegExp)`, () => o.assign(b, (0, t._)`${p}.type || "string"`).assign(T, (0, t._)`${p}.validate`), () => o.assign(b, (0, t._)`"string"`).assign(T, p)), n.fail$data((0, t.or)(d(), m()));
12580
+ }), p = o.const("fDef", (0, t._)`${g}[${u}]`), b = o.let("fType"), S = o.let("format");
12581
+ o.if((0, t._)`typeof ${p} == "object" && !(${p} instanceof RegExp)`, () => o.assign(b, (0, t._)`${p}.type || "string"`).assign(S, (0, t._)`${p}.validate`), () => o.assign(b, (0, t._)`"string"`).assign(S, p)), n.fail$data((0, t.or)(d(), m()));
12567
12582
  function d() {
12568
- return h.strictSchema === !1 ? t.nil : (0, t._)`${u} && !${T}`;
12583
+ return h.strictSchema === !1 ? t.nil : (0, t._)`${u} && !${S}`;
12569
12584
  }
12570
12585
  function m() {
12571
- const w = v.$async ? (0, t._)`(${p}.async ? await ${T}(${a}) : ${T}(${a}))` : (0, t._)`${T}(${a})`, R = (0, t._)`(typeof ${T} == "function" ? ${w} : ${T}.test(${a}))`;
12572
- return (0, t._)`${T} && ${T} !== true && ${b} === ${s} && !${R}`;
12586
+ const w = v.$async ? (0, t._)`(${p}.async ? await ${S}(${a}) : ${S}(${a}))` : (0, t._)`${S}(${a})`, T = (0, t._)`(typeof ${S} == "function" ? ${w} : ${S}.test(${a}))`;
12587
+ return (0, t._)`${S} && ${S} !== true && ${b} === ${s} && !${T}`;
12573
12588
  }
12574
12589
  }
12575
12590
  function f() {
12576
- const g = S.formats[c];
12591
+ const g = R.formats[c];
12577
12592
  if (!g) {
12578
12593
  d();
12579
12594
  return;
12580
12595
  }
12581
12596
  if (g === !0)
12582
12597
  return;
12583
- const [p, b, T] = m(g);
12598
+ const [p, b, S] = m(g);
12584
12599
  p === s && n.pass(w());
12585
12600
  function d() {
12586
12601
  if (h.strictSchema === !1) {
12587
- S.logger.warn(R());
12602
+ R.logger.warn(T());
12588
12603
  return;
12589
12604
  }
12590
- throw new Error(R());
12591
- function R() {
12605
+ throw new Error(T());
12606
+ function T() {
12592
12607
  return `unknown format "${c}" ignored in schema at path "${y}"`;
12593
12608
  }
12594
12609
  }
12595
- function m(R) {
12596
- const I = R instanceof RegExp ? (0, t.regexpCode)(R) : h.code.formats ? (0, t._)`${h.code.formats}${(0, t.getProperty)(c)}` : void 0, L = o.scopeValue("formats", { key: c, ref: R, code: I });
12597
- return typeof R == "object" && !(R instanceof RegExp) ? [R.type || "string", R.validate, (0, t._)`${L}.validate`] : ["string", R, L];
12610
+ function m(T) {
12611
+ const I = T instanceof RegExp ? (0, t.regexpCode)(T) : h.code.formats ? (0, t._)`${h.code.formats}${(0, t.getProperty)(c)}` : void 0, L = o.scopeValue("formats", { key: c, ref: T, code: I });
12612
+ return typeof T == "object" && !(T instanceof RegExp) ? [T.type || "string", T.validate, (0, t._)`${L}.validate`] : ["string", T, L];
12598
12613
  }
12599
12614
  function w() {
12600
12615
  if (typeof g == "object" && !(g instanceof RegExp) && g.async) {
12601
12616
  if (!v.$async)
12602
12617
  throw new Error("async format in sync schema");
12603
- return (0, t._)`await ${T}(${a})`;
12618
+ return (0, t._)`await ${S}(${a})`;
12604
12619
  }
12605
- return typeof b == "function" ? (0, t._)`${T}(${a})` : (0, t._)`${T}.test(${a})`;
12620
+ return typeof b == "function" ? (0, t._)`${S}(${a})` : (0, t._)`${S}.test(${a})`;
12606
12621
  }
12607
12622
  }
12608
12623
  }
12609
12624
  };
12610
12625
  return Pr.default = r, Pr;
12611
12626
  }
12612
- var Ra;
12627
+ var Ta;
12613
12628
  function Lg() {
12614
- if (Ra) return Nr;
12615
- Ra = 1, Object.defineProperty(Nr, "__esModule", { value: !0 });
12629
+ if (Ta) return Nr;
12630
+ Ta = 1, Object.defineProperty(Nr, "__esModule", { value: !0 });
12616
12631
  const e = [Cg().default];
12617
12632
  return Nr.default = e, Nr;
12618
12633
  }
12619
- var Qe = {}, Sa;
12634
+ var Qe = {}, Ra;
12620
12635
  function xg() {
12621
- return Sa || (Sa = 1, Object.defineProperty(Qe, "__esModule", { value: !0 }), Qe.contentVocabulary = Qe.metadataVocabulary = void 0, Qe.metadataVocabulary = [
12636
+ return Ra || (Ra = 1, Object.defineProperty(Qe, "__esModule", { value: !0 }), Qe.contentVocabulary = Qe.metadataVocabulary = void 0, Qe.metadataVocabulary = [
12622
12637
  "title",
12623
12638
  "description",
12624
12639
  "default",
@@ -12632,10 +12647,10 @@ function xg() {
12632
12647
  "contentSchema"
12633
12648
  ]), Qe;
12634
12649
  }
12635
- var Ta;
12650
+ var Sa;
12636
12651
  function kg() {
12637
- if (Ta) return Xt;
12638
- Ta = 1, Object.defineProperty(Xt, "__esModule", { value: !0 });
12652
+ if (Sa) return Xt;
12653
+ Sa = 1, Object.defineProperty(Xt, "__esModule", { value: !0 });
12639
12654
  const t = ag(), e = wg(), r = Dg(), n = Lg(), s = xg(), o = [
12640
12655
  t.default,
12641
12656
  e.default,
@@ -12671,29 +12686,29 @@ function Ug() {
12671
12686
  const { gen: c, data: u, schema: l, parentSchema: h, it: y } = i, { oneOf: v } = h;
12672
12687
  if (!y.opts.discriminator)
12673
12688
  throw new Error("discriminator: requires discriminator option");
12674
- const S = l.propertyName;
12675
- if (typeof S != "string")
12689
+ const R = l.propertyName;
12690
+ if (typeof R != "string")
12676
12691
  throw new Error("discriminator: requires propertyName");
12677
12692
  if (l.mapping)
12678
12693
  throw new Error("discriminator: mapping is not supported");
12679
12694
  if (!v)
12680
12695
  throw new Error("discriminator: requires oneOf keyword");
12681
- const _ = c.let("valid", !1), f = c.const("tag", (0, t._)`${u}${(0, t.getProperty)(S)}`);
12682
- c.if((0, t._)`typeof ${f} == "string"`, () => g(), () => i.error(!1, { discrError: e.DiscrError.Tag, tag: f, tagName: S })), i.ok(_);
12696
+ const _ = c.let("valid", !1), f = c.const("tag", (0, t._)`${u}${(0, t.getProperty)(R)}`);
12697
+ c.if((0, t._)`typeof ${f} == "string"`, () => g(), () => i.error(!1, { discrError: e.DiscrError.Tag, tag: f, tagName: R })), i.ok(_);
12683
12698
  function g() {
12684
- const T = b();
12699
+ const S = b();
12685
12700
  c.if(!1);
12686
- for (const d in T)
12687
- c.elseIf((0, t._)`${f} === ${d}`), c.assign(_, p(T[d]));
12688
- c.else(), i.error(!1, { discrError: e.DiscrError.Mapping, tag: f, tagName: S }), c.endIf();
12701
+ for (const d in S)
12702
+ c.elseIf((0, t._)`${f} === ${d}`), c.assign(_, p(S[d]));
12703
+ c.else(), i.error(!1, { discrError: e.DiscrError.Mapping, tag: f, tagName: R }), c.endIf();
12689
12704
  }
12690
- function p(T) {
12691
- const d = c.name("valid"), m = i.subschema({ keyword: "oneOf", schemaProp: T }, d);
12705
+ function p(S) {
12706
+ const d = c.name("valid"), m = i.subschema({ keyword: "oneOf", schemaProp: S }, d);
12692
12707
  return i.mergeEvaluated(m, t.Name), d;
12693
12708
  }
12694
12709
  function b() {
12695
- var T;
12696
- const d = {}, m = R(h);
12710
+ var S;
12711
+ const d = {}, m = T(h);
12697
12712
  let w = !0;
12698
12713
  for (let N = 0; N < v.length; N++) {
12699
12714
  let k = v[N];
@@ -12702,16 +12717,16 @@ function Ug() {
12702
12717
  if (k = r.resolveRef.call(y.self, y.schemaEnv.root, y.baseId, V), k instanceof r.SchemaEnv && (k = k.schema), k === void 0)
12703
12718
  throw new n.default(y.opts.uriResolver, y.baseId, V);
12704
12719
  }
12705
- const B = (T = k?.properties) === null || T === void 0 ? void 0 : T[S];
12720
+ const B = (S = k?.properties) === null || S === void 0 ? void 0 : S[R];
12706
12721
  if (typeof B != "object")
12707
- throw new Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${S}"`);
12708
- w = w && (m || R(k)), I(B, N);
12722
+ throw new Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${R}"`);
12723
+ w = w && (m || T(k)), I(B, N);
12709
12724
  }
12710
12725
  if (!w)
12711
- throw new Error(`discriminator: "${S}" must be required`);
12726
+ throw new Error(`discriminator: "${R}" must be required`);
12712
12727
  return d;
12713
- function R({ required: N }) {
12714
- return Array.isArray(N) && N.includes(S);
12728
+ function T({ required: N }) {
12729
+ return Array.isArray(N) && N.includes(R);
12715
12730
  }
12716
12731
  function I(N, k) {
12717
12732
  if (N.const)
@@ -12720,11 +12735,11 @@ function Ug() {
12720
12735
  for (const B of N.enum)
12721
12736
  L(B, k);
12722
12737
  else
12723
- throw new Error(`discriminator: "properties/${S}" must have "const" or "enum"`);
12738
+ throw new Error(`discriminator: "properties/${R}" must have "const" or "enum"`);
12724
12739
  }
12725
12740
  function L(N, k) {
12726
12741
  if (typeof N != "string" || N in d)
12727
- throw new Error(`discriminator: "${S}" values must be unique strings`);
12742
+ throw new Error(`discriminator: "${R}" values must be unique strings`);
12728
12743
  d[N] = k;
12729
12744
  }
12730
12745
  }
@@ -12748,13 +12763,13 @@ function Yg() {
12748
12763
  const r = ng(), n = kg(), s = Ug(), o = zg, a = ["/properties"], i = "http://json-schema.org/draft-07/schema";
12749
12764
  class c extends r.default {
12750
12765
  _addVocabularies() {
12751
- super._addVocabularies(), n.default.forEach((S) => this.addVocabulary(S)), this.opts.discriminator && this.addKeyword(s.default);
12766
+ super._addVocabularies(), n.default.forEach((R) => this.addVocabulary(R)), this.opts.discriminator && this.addKeyword(s.default);
12752
12767
  }
12753
12768
  _addDefaultMetaSchema() {
12754
12769
  if (super._addDefaultMetaSchema(), !this.opts.meta)
12755
12770
  return;
12756
- const S = this.opts.$data ? this.$dataMetaSchema(o, a) : o;
12757
- this.addMetaSchema(S, i, !1), this.refs["http://json-schema.org/schema"] = i;
12771
+ const R = this.opts.$data ? this.$dataMetaSchema(o, a) : o;
12772
+ this.addMetaSchema(R, i, !1), this.refs["http://json-schema.org/schema"] = i;
12758
12773
  }
12759
12774
  defaultMeta() {
12760
12775
  return this.opts.defaultMeta = super.defaultMeta() || (this.getSchema(i) ? i : void 0);
@@ -12989,7 +13004,7 @@ async function zb(t, e, r, n) {
12989
13004
  l.filter(
12990
13005
  (g) => y(g, e)
12991
13006
  )
12992
- ), S = xn(
13007
+ ), R = xn(
12993
13008
  l.filter(
12994
13009
  (g) => !y(g, e)
12995
13010
  )
@@ -13000,7 +13015,7 @@ async function zb(t, e, r, n) {
13000
13015
  }
13001
13016
  const _ = [];
13002
13017
  let f = null;
13003
- return S.length > 0 && (_.push("PROVIDER_MISMATCH"), f = S[0]), h.length > 0 && (_.push("SESSION_EXPIRED"), f ??= h[0]), f && !Ia(f, r) && _.push("LOCATION_MISMATCH"), _.length === 0 ? {
13018
+ return R.length > 0 && (_.push("PROVIDER_MISMATCH"), f = R[0]), h.length > 0 && (_.push("SESSION_EXPIRED"), f ??= h[0]), f && !Ia(f, r) && _.push("LOCATION_MISMATCH"), _.length === 0 ? {
13004
13019
  matched: !1,
13005
13020
  encounter: null,
13006
13021
  reasons: ["NO_ACTIVE_ENCOUNTER"]
@@ -13026,13 +13041,12 @@ const Gi = {
13026
13041
  isLoading: !1
13027
13042
  }, fy = [
13028
13043
  "MATCHED",
13029
- "SESSION_EXPIRED",
13030
13044
  "LOCATION_MISMATCH",
13031
13045
  "PROVIDER_MISMATCH"
13032
13046
  ];
13033
13047
  let Mt = { ...Gi };
13034
13048
  const Wn = /* @__PURE__ */ new Set();
13035
- function Rs() {
13049
+ function Ts() {
13036
13050
  Wn.forEach((t) => t());
13037
13051
  }
13038
13052
  function py(t) {
@@ -13052,13 +13066,13 @@ function Gb(t) {
13052
13066
  activeEncounter: t.encounter,
13053
13067
  canEditOrCreate: e,
13054
13068
  isLoading: !1
13055
- }, Rs();
13069
+ }, Ts();
13056
13070
  }
13057
13071
  function Kb(t) {
13058
- Mt = { ...Mt, isLoading: t }, Rs();
13072
+ Mt = { ...Mt, isLoading: t }, Ts();
13059
13073
  }
13060
13074
  function Wb() {
13061
- Mt = { ...Gi }, Rs();
13075
+ Mt = { ...Gi }, Ts();
13062
13076
  }
13063
13077
  function Jb() {
13064
13078
  return sc(
@@ -13385,15 +13399,15 @@ const vy = K + "/bahmnicore/diseaseSummaryData?", u_ = async (t, e, r, n) => {
13385
13399
  });
13386
13400
  const o = vy + s.toString();
13387
13401
  return H(o);
13388
- }, Ss = "custom:(uuid,episodeUuid,patient,program,display,dateEnrolled,dateCompleted,location,voided,allowedStates,outcome,states:(uuid,startDate,endDate,voided,state:(uuid,concept:(uuid,display,name,names)),auditInfo),auditInfo,attributes)", Ry = (t) => `${K}/bahmniprogramenrollment?patient=${t}&v=${Ss}`, Sy = (t, e = 15, r = 0) => `${K}/bahmniprogramenrollment?patient=${t}&v=${Ss}&limit=${e}&startIndex=${r}&totalCount=true`, Xi = (t) => `${K}/bahmniprogramenrollment/${t}`, Ty = (t) => `${Xi(t)}?v=${Ss}`, l_ = async (t) => await H(Ry(t)), d_ = async (t, e = 15, r = 1) => {
13402
+ }, Rs = "custom:(uuid,episodeUuid,patient,program,display,dateEnrolled,dateCompleted,location,voided,allowedStates,outcome,states:(uuid,startDate,endDate,voided,state:(uuid,concept:(uuid,display,name,names)),auditInfo),auditInfo,attributes)", Ty = (t) => `${K}/bahmniprogramenrollment?patient=${t}&v=${Rs}`, Ry = (t, e = 15, r = 0) => `${K}/bahmniprogramenrollment?patient=${t}&v=${Rs}&limit=${e}&startIndex=${r}&totalCount=true`, Xi = (t) => `${K}/bahmniprogramenrollment/${t}`, Sy = (t) => `${Xi(t)}?v=${Rs}`, l_ = async (t) => await H(Ty(t)), d_ = async (t, e = 15, r = 1) => {
13389
13403
  const n = (r - 1) * e, s = await H(
13390
- Sy(t, e, n)
13404
+ Ry(t, e, n)
13391
13405
  );
13392
13406
  return {
13393
13407
  programs: s.results,
13394
13408
  total: s.totalCount
13395
13409
  };
13396
- }, f_ = async (t) => await H(Ty(t)), p_ = async (t, e) => {
13410
+ }, f_ = async (t) => await H(Sy(t)), p_ = async (t, e) => {
13397
13411
  const r = {
13398
13412
  uuid: t,
13399
13413
  states: [
@@ -13518,7 +13532,7 @@ async function v_(t, e) {
13518
13532
  );
13519
13533
  return ec(n);
13520
13534
  }
13521
- async function R_(t, e, r = 10, n = 1) {
13535
+ async function T_(t, e, r = 10, n = 1) {
13522
13536
  const s = (n - 1) * r, o = Zi(
13523
13537
  t,
13524
13538
  e,
@@ -13533,10 +13547,10 @@ async function R_(t, e, r = 10, n = 1) {
13533
13547
  };
13534
13548
  }
13535
13549
  const Ay = (t) => `${K}/location?operator=ALL&s=byTags&tags=${encodeURIComponent(t)}&v=custom:(uuid,display,childLocations:(uuid,display,retired))`, Ny = (t) => `${ae}/Location?_tag=${encodeURIComponent(t)}`;
13536
- async function S_(t) {
13550
+ async function R_(t) {
13537
13551
  return (await H(Ay(t))).results ?? [];
13538
13552
  }
13539
- async function T_(t) {
13553
+ async function S_(t) {
13540
13554
  return await H(Ny(t));
13541
13555
  }
13542
13556
  const Py = ae + "/Immunization", Iy = (t, e) => {
@@ -13698,7 +13712,7 @@ export {
13698
13712
  nb as DATE_REGEX_PATTERN,
13699
13713
  Ii as DEFAULT_DATE_FORMAT,
13700
13714
  vh as DEFAULT_DATE_FORMAT_STORAGE_KEY,
13701
- Rh as DEFAULT_TIME_FORMAT,
13715
+ Th as DEFAULT_TIME_FORMAT,
13702
13716
  Oh as DURATION_UNIT_TO_DAYS,
13703
13717
  zE as FHIR_ENCOUNTER_CLASS_CODE_SYSTEM,
13704
13718
  YE as FHIR_ENCOUNTER_TAG_SYSTEM,
@@ -13715,7 +13729,7 @@ export {
13715
13729
  Gh as HL7_CONDITION_CLINICAL_STATUS_CODE_SYSTEM,
13716
13730
  GE as HL7_CONDITION_VERIFICATION_STATUS_CODE_SYSTEM,
13717
13731
  sb as INTERPRETATION_TO_CODE,
13718
- TE as ISO_DATE_FORMAT,
13732
+ SE as ISO_DATE_FORMAT,
13719
13733
  Ku as LOGIN_PATH,
13720
13734
  Hb as MATCH_REASON_MESSAGES,
13721
13735
  Uw as MAX_NAME_LENGTH,
@@ -13726,8 +13740,8 @@ export {
13726
13740
  ae as OPENMRS_FHIR_R4,
13727
13741
  K as OPENMRS_REST_V1,
13728
13742
  Ob as ORDER_TYPE_QUERY_KEY,
13729
- Tb as PENDING_REPORT_STATUSES,
13730
- Sb as PROCESSED_REPORT_STATUSES,
13743
+ Sb as PENDING_REPORT_STATUSES,
13744
+ Rb as PROCESSED_REPORT_STATUSES,
13731
13745
  Db as USER_PINNED_PREFERENCE_URL,
13732
13746
  OE as calculateAge,
13733
13747
  DE as calculateEndDate,
@@ -13739,7 +13753,7 @@ export {
13739
13753
  i_ as convertImmutableToPlainObject,
13740
13754
  Ah as convertTo24HourFormat,
13741
13755
  Iw as convertToSentenceCase,
13742
- SE as createAppointmentUnavailability,
13756
+ RE as createAppointmentUnavailability,
13743
13757
  Fb as createFhirEncounter,
13744
13758
  Kw as createFhirPatient,
13745
13759
  Yw as createPatient,
@@ -13766,7 +13780,7 @@ export {
13766
13780
  Fy as filterByOnlineStatus,
13767
13781
  qy as filterByPrivilege,
13768
13782
  $_ as filterCdsCardsForItems,
13769
- Tw as filterReplacementEntries,
13783
+ Sw as filterReplacementEntries,
13770
13784
  Bb as findActiveEncounterInSession,
13771
13785
  PE as formatDateDistance,
13772
13786
  AE as formatDateTime,
@@ -13781,7 +13795,7 @@ export {
13781
13795
  EE as getAllAppointmentServices,
13782
13796
  Hh as getAllergies,
13783
13797
  wE as getAppointmentById,
13784
- RE as getAppointmentUnavailabilities,
13798
+ TE as getAppointmentUnavailabilities,
13785
13799
  Cw as getAvailableLocations,
13786
13800
  P_ as getAvailableStocks,
13787
13801
  Nb as getCategoryUuidFromOrderTypes,
@@ -13798,7 +13812,7 @@ export {
13798
13812
  ub as getDiagnosesPage,
13799
13813
  vb as getDiagnosticReportBundle,
13800
13814
  _b as getDiagnosticReports,
13801
- R_ as getDocumentReferencePage,
13815
+ T_ as getDocumentReferencePage,
13802
13816
  Oy as getDocumentReferences,
13803
13817
  Ub as getEncounterByUuid,
13804
13818
  Yi as getEncounterSessionDuration,
@@ -13806,7 +13820,7 @@ export {
13806
13820
  Qb as getEncountersAndVisitsForEOC,
13807
13821
  Ib as getExistingServiceRequestsForAllCategories,
13808
13822
  Uy as getExtensionsByPoint,
13809
- T_ as getFHIRLocationsByTag,
13823
+ S_ as getFHIRLocationsByTag,
13810
13824
  Ab as getFlattenedInvestigations,
13811
13825
  $E as getFormattedAge,
13812
13826
  VE as getFormattedAllergies,
@@ -13818,7 +13832,7 @@ export {
13818
13832
  Bw as getIdentifierTypes,
13819
13833
  nE as getInputTypeForFormat,
13820
13834
  bb as getLabInvestigationsBundle,
13821
- S_ as getLocationByTag,
13835
+ R_ as getLocationByTag,
13822
13836
  mb as getMedicationByUuid,
13823
13837
  qb as getObservationsBundleByEncounterUuid,
13824
13838
  Pb as getOrderTypeNames,
@@ -13843,7 +13857,7 @@ export {
13843
13857
  wb as getPatientRadiologyInvestigations,
13844
13858
  rE as getPersonAttributeTypes,
13845
13859
  Dd as getPrimaryIdentifierType,
13846
- Rw as getPriorityByOrder,
13860
+ Tw as getPriorityByOrder,
13847
13861
  f_ as getProgramByUUID,
13848
13862
  Mb as getProviderLoginLocations,
13849
13863
  tE as getRelationshipTypes,
@@ -13861,7 +13875,7 @@ export {
13861
13875
  uE as getVisitTypes,
13862
13876
  cy as getVisits,
13863
13877
  u_ as getVitalFlowSheetData,
13864
- Sw as groupByDate,
13878
+ Rw as groupByDate,
13865
13879
  e_ as hasPrivilege,
13866
13880
  gw as initAppI18n,
13867
13881
  Xb as initializeAuditListener,
@@ -13908,7 +13922,7 @@ export {
13908
13922
  s_ as transformFormDataToObservations,
13909
13923
  o_ as transformObservationsToFormData,
13910
13924
  yE as updateAppointmentStatus,
13911
- Rb as updateDiagnosticReportBundle,
13925
+ Tb as updateDiagnosticReportBundle,
13912
13926
  jb as updateFhirEncounter,
13913
13927
  Jw as updateFhirPatient,
13914
13928
  Gw as updatePatient,