@ingridab/sdk 0.1.0 → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -1,47 +1,18 @@
1
1
  import { z as p } from "zod";
2
2
  import { QueryClient as Xt } from "@tanstack/react-query";
3
3
  import { atom as te, createStore as Or } from "jotai";
4
- const wi = ({ mode: r, customization: e }) => ({
4
+ const vi = ({ mode: r, customization: e }) => ({
5
5
  type: "address",
6
6
  customization: e,
7
7
  params: {
8
8
  mode: r
9
9
  }
10
- }), vi = ({
11
- mode: r,
12
- name: e
13
- }) => ({
14
- type: "countrySelector",
15
- params: {
16
- mode: r,
17
- name: e
18
- }
19
- }), Si = ({
20
- mode: r,
21
- name: e,
22
- customization: t
23
- }) => ({
24
- type: "delivery",
25
- customization: t,
26
- params: {
27
- mode: r,
28
- name: e
29
- }
30
- }), xi = ({
31
- name: r,
32
- customization: e
33
- }) => ({
34
- type: "freeShippingIndicator",
35
- customization: e,
36
- params: {
37
- name: r
38
- }
39
10
  }), Ye = ["en-US", "pl-PL", "sv-SE"];
40
11
  p.union([
41
- p.object({ token: p.string(), locale: p.enum(Ye) }),
12
+ p.object({ token: p.string().optional(), locale: p.enum(Ye) }),
42
13
  p.object({ email: p.string(), tos_id: p.string(), locale: p.enum(Ye) })
43
14
  ]);
44
- p.object({ sessionId: p.string(), token: p.string() });
15
+ p.object({ sessionId: p.string(), token: p.string().optional() });
45
16
  p.object({
46
17
  id: p.string().optional(),
47
18
  recipientName: p.string().optional(),
@@ -62,7 +33,7 @@ p.object({
62
33
  additionalFormValues: p.array(p.any()).optional()
63
34
  });
64
35
  p.object({
65
- mode: p.enum(["addressForm"]),
36
+ mode: p.enum(["addressForm", "searchDriven"]),
66
37
  customization: p.object({
67
38
  address: p.object({
68
39
  vatTypes: p.array(p.string()).optional()
@@ -135,17 +106,6 @@ const pt = p.number().int().min(0).max(24).optional(), Rr = p.object({
135
106
  }).optional();
136
107
  p.object({
137
108
  customization: Rr,
138
- // TODO: the passive `mode` has hardcoded logic, but IMHO the behaviour should come from granular config (components + policies), not from `mode` branches.
139
- // Just an simple example:
140
- // components: {
141
- // continue_button: { display: 'hidden' },
142
- // pickup_location: { display: 'popup', interaction: 'preview' // or edit }
143
- // }
144
- //
145
- // actionPolicy: {
146
- // select_item: 'deny'
147
- // }
148
- //
149
109
  mode: p.enum(["active", "passive"]),
150
110
  name: p.string()
151
111
  });
@@ -165,7 +125,7 @@ const ht = {
165
125
  warn: 1,
166
126
  info: 2,
167
127
  debug: 3
168
- }, Cr = async (r) => await import(r), Ar = {
128
+ }, Cr = async (r) => await import(r), Pr = {
169
129
  "address.address_book.billing.modal.aria.label": "Choose a billing address from your address book",
170
130
  "address.address_book.delivery.modal.aria.label": "Choose a delivery address from your address book",
171
131
  "address.confirm": "Confirm address",
@@ -355,7 +315,7 @@ const ht = {
355
315
  "time.tuesday": "Tuesday",
356
316
  "time.wednesday": "Wednesday",
357
317
  "tracking.track_delivery_with": "Track delivery with {{carrierName}}"
358
- }, Pr = {
318
+ }, Ar = {
359
319
  "address.address_book.billing.modal.aria.label": "Wybierz adres rozliczeniowy z książki adresowej",
360
320
  "address.address_book.delivery.modal.aria.label": "Wybierz adres dostawy z książki adresowej",
361
321
  "address.confirm": "Potwierdź adres",
@@ -739,20 +699,23 @@ const ht = {
739
699
  "time.wednesday": "Onsdag",
740
700
  "tracking.track_delivery_with": "Spåra leverans med {{carrierName}}"
741
701
  }, Tr = {
742
- "en-US": Ar,
743
- "pl-PL": Pr,
702
+ "en-US": Pr,
703
+ "pl-PL": Ar,
744
704
  "sv-SE": Lr
745
705
  }, jr = async ({ token: r, initUrl: e, siteId: t }) => (await Promise.resolve(), {
746
706
  token: r,
747
707
  initUrl: e,
748
708
  siteId: t
749
- }), Nr = async (r) => (await Promise.resolve(), Tr[r] || "en-US"), Dr = new Xt({
709
+ }), Nr = async (r) => (await Promise.resolve(), Tr[r] || "en-US"), Dr = (r) => {
710
+ const e = "0.2.0".split(".").slice(0, 2).join("."), t = r.versions.sdkCompatibility?.[e];
711
+ return typeof t == "string" && t.trim().length > 0 ? t : "0.2.2";
712
+ }, Fr = new Xt({
750
713
  defaultOptions: {
751
714
  queries: {
752
715
  refetchOnWindowFocus: !1
753
716
  }
754
717
  }
755
- }), Fr = (r) => r === "stage" ? "https://cdn-stage.ingrid.com/experience-kit/molecules" : "https://cdn.ingrid.com/experience-kit/molecules", zr = async (r, e) => {
718
+ }), zr = (r) => r === "stage" ? "https://cdn-stage.ingrid.com/experience-kit/molecules" : "https://cdn.ingrid.com/experience-kit/molecules", Ir = async (r, e) => {
756
719
  try {
757
720
  const t = await fetch(`${r}/release-index.json`);
758
721
  if (!t.ok)
@@ -762,12 +725,12 @@ const ht = {
762
725
  } catch (t) {
763
726
  return e.error("Error fetching release index", { error: t }), null;
764
727
  }
765
- }, Ir = async ({
728
+ }, Ur = async ({
766
729
  moleculesUrl: r,
767
730
  logger: e
768
- }) => Dr.fetchQuery({
731
+ }) => Fr.fetchQuery({
769
732
  queryKey: [r, "release-index"],
770
- queryFn: () => zr(r, e),
733
+ queryFn: () => Ir(r, e),
771
734
  staleTime: 1 / 0
772
735
  });
773
736
  function Qt(r, e) {
@@ -775,24 +738,24 @@ function Qt(r, e) {
775
738
  return r.apply(e, arguments);
776
739
  };
777
740
  }
778
- const { toString: Ur } = Object.prototype, { getPrototypeOf: Ie } = Object, { iterator: Ue, toStringTag: er } = Symbol, $e = /* @__PURE__ */ ((r) => (e) => {
779
- const t = Ur.call(e);
741
+ const { toString: $r } = Object.prototype, { getPrototypeOf: Ie } = Object, { iterator: Ue, toStringTag: er } = Symbol, $e = /* @__PURE__ */ ((r) => (e) => {
742
+ const t = $r.call(e);
780
743
  return r[t] || (r[t] = t.slice(8, -1).toLowerCase());
781
- })(/* @__PURE__ */ Object.create(null)), J = (r) => (r = r.toLowerCase(), (e) => $e(e) === r), Be = (r) => (e) => typeof e === r, { isArray: pe } = Array, fe = Be("undefined");
744
+ })(/* @__PURE__ */ Object.create(null)), J = (r) => (r = r.toLowerCase(), (e) => $e(e) === r), Be = (r) => (e) => typeof e === r, { isArray: fe } = Array, ce = Be("undefined");
782
745
  function Se(r) {
783
- return r !== null && !fe(r) && r.constructor !== null && !fe(r.constructor) && I(r.constructor.isBuffer) && r.constructor.isBuffer(r);
746
+ return r !== null && !ce(r) && r.constructor !== null && !ce(r.constructor) && I(r.constructor.isBuffer) && r.constructor.isBuffer(r);
784
747
  }
785
748
  const tr = J("ArrayBuffer");
786
- function $r(r) {
749
+ function Br(r) {
787
750
  let e;
788
751
  return typeof ArrayBuffer < "u" && ArrayBuffer.isView ? e = ArrayBuffer.isView(r) : e = r && r.buffer && tr(r.buffer), e;
789
752
  }
790
- const Br = Be("string"), I = Be("function"), rr = Be("number"), xe = (r) => r !== null && typeof r == "object", Mr = (r) => r === !0 || r === !1, Le = (r) => {
753
+ const Mr = Be("string"), I = Be("function"), rr = Be("number"), xe = (r) => r !== null && typeof r == "object", Vr = (r) => r === !0 || r === !1, Le = (r) => {
791
754
  if ($e(r) !== "object")
792
755
  return !1;
793
756
  const e = Ie(r);
794
757
  return (e === null || e === Object.prototype || Object.getPrototypeOf(e) === null) && !(er in r) && !(Ue in r);
795
- }, Vr = (r) => {
758
+ }, qr = (r) => {
796
759
  if (!xe(r) || Se(r))
797
760
  return !1;
798
761
  try {
@@ -800,11 +763,11 @@ const Br = Be("string"), I = Be("function"), rr = Be("number"), xe = (r) => r !=
800
763
  } catch {
801
764
  return !1;
802
765
  }
803
- }, qr = J("Date"), Hr = J("File"), Kr = (r) => !!(r && typeof r.uri < "u"), Wr = (r) => r && typeof r.getParts < "u", Jr = J("Blob"), Gr = J("FileList"), Zr = (r) => xe(r) && I(r.pipe);
804
- function Yr() {
766
+ }, Hr = J("Date"), Kr = J("File"), Wr = (r) => !!(r && typeof r.uri < "u"), Jr = (r) => r && typeof r.getParts < "u", Gr = J("Blob"), Zr = J("FileList"), Yr = (r) => xe(r) && I(r.pipe);
767
+ function Xr() {
805
768
  return typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : typeof global < "u" ? global : {};
806
769
  }
807
- const gt = Yr(), mt = typeof gt.FormData < "u" ? gt.FormData : void 0, Xr = (r) => {
770
+ const gt = Xr(), mt = typeof gt.FormData < "u" ? gt.FormData : void 0, Qr = (r) => {
808
771
  if (!r) return !1;
809
772
  if (mt && r instanceof mt) return !0;
810
773
  const e = Ie(r);
@@ -812,17 +775,17 @@ const gt = Yr(), mt = typeof gt.FormData < "u" ? gt.FormData : void 0, Xr = (r)
812
775
  const t = $e(r);
813
776
  return t === "formdata" || // detect form-data instance
814
777
  t === "object" && I(r.toString) && r.toString() === "[object FormData]";
815
- }, Qr = J("URLSearchParams"), [es, ts, rs, ss] = [
778
+ }, es = J("URLSearchParams"), [ts, rs, ss, ns] = [
816
779
  "ReadableStream",
817
780
  "Request",
818
781
  "Response",
819
782
  "Headers"
820
- ].map(J), ns = (r) => r.trim ? r.trim() : r.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, "");
783
+ ].map(J), is = (r) => r.trim ? r.trim() : r.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, "");
821
784
  function Ee(r, e, { allOwnKeys: t = !1 } = {}) {
822
785
  if (r === null || typeof r > "u")
823
786
  return;
824
787
  let s, n;
825
- if (typeof r != "object" && (r = [r]), pe(r))
788
+ if (typeof r != "object" && (r = [r]), fe(r))
826
789
  for (s = 0, n = r.length; s < n; s++)
827
790
  e.call(null, r[s], s, r);
828
791
  else {
@@ -845,19 +808,19 @@ function sr(r, e) {
845
808
  return n;
846
809
  return null;
847
810
  }
848
- const se = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : global, nr = (r) => !fe(r) && r !== se;
811
+ const re = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : global, nr = (r) => !ce(r) && r !== re;
849
812
  function Xe(...r) {
850
813
  const { caseless: e, skipUndefined: t } = nr(this) && this || {}, s = {}, n = (i, o) => {
851
814
  if (o === "__proto__" || o === "constructor" || o === "prototype")
852
815
  return;
853
816
  const a = e && sr(s, o) || o, l = Qe(s, a) ? s[a] : void 0;
854
- Le(l) && Le(i) ? s[a] = Xe(l, i) : Le(i) ? s[a] = Xe({}, i) : pe(i) ? s[a] = i.slice() : (!t || !fe(i)) && (s[a] = i);
817
+ Le(l) && Le(i) ? s[a] = Xe(l, i) : Le(i) ? s[a] = Xe({}, i) : fe(i) ? s[a] = i.slice() : (!t || !ce(i)) && (s[a] = i);
855
818
  };
856
819
  for (let i = 0, o = r.length; i < o; i++)
857
820
  r[i] && Ee(r[i], n);
858
821
  return s;
859
822
  }
860
- const is = (r, e, t, { allOwnKeys: s } = {}) => (Ee(
823
+ const os = (r, e, t, { allOwnKeys: s } = {}) => (Ee(
861
824
  e,
862
825
  (n, i) => {
863
826
  t && I(n) ? Object.defineProperty(r, i, {
@@ -877,7 +840,7 @@ const is = (r, e, t, { allOwnKeys: s } = {}) => (Ee(
877
840
  });
878
841
  },
879
842
  { allOwnKeys: s }
880
- ), r), os = (r) => (r.charCodeAt(0) === 65279 && (r = r.slice(1)), r), as = (r, e, t, s) => {
843
+ ), r), as = (r) => (r.charCodeAt(0) === 65279 && (r = r.slice(1)), r), ls = (r, e, t, s) => {
881
844
  r.prototype = Object.create(e.prototype, s), Object.defineProperty(r.prototype, "constructor", {
882
845
  __proto__: null,
883
846
  value: r,
@@ -888,7 +851,7 @@ const is = (r, e, t, { allOwnKeys: s } = {}) => (Ee(
888
851
  __proto__: null,
889
852
  value: e.prototype
890
853
  }), t && Object.assign(r.prototype, t);
891
- }, ls = (r, e, t, s) => {
854
+ }, ds = (r, e, t, s) => {
892
855
  let n, i, o;
893
856
  const a = {};
894
857
  if (e = e || {}, r == null) return e;
@@ -898,41 +861,41 @@ const is = (r, e, t, { allOwnKeys: s } = {}) => (Ee(
898
861
  r = t !== !1 && Ie(r);
899
862
  } while (r && (!t || t(r, e)) && r !== Object.prototype);
900
863
  return e;
901
- }, ds = (r, e, t) => {
864
+ }, us = (r, e, t) => {
902
865
  r = String(r), (t === void 0 || t > r.length) && (t = r.length), t -= e.length;
903
866
  const s = r.indexOf(e, t);
904
867
  return s !== -1 && s === t;
905
- }, us = (r) => {
868
+ }, cs = (r) => {
906
869
  if (!r) return null;
907
- if (pe(r)) return r;
870
+ if (fe(r)) return r;
908
871
  let e = r.length;
909
872
  if (!rr(e)) return null;
910
873
  const t = new Array(e);
911
874
  for (; e-- > 0; )
912
875
  t[e] = r[e];
913
876
  return t;
914
- }, cs = /* @__PURE__ */ ((r) => (e) => r && e instanceof r)(typeof Uint8Array < "u" && Ie(Uint8Array)), fs = (r, e) => {
877
+ }, fs = /* @__PURE__ */ ((r) => (e) => r && e instanceof r)(typeof Uint8Array < "u" && Ie(Uint8Array)), ps = (r, e) => {
915
878
  const s = (r && r[Ue]).call(r);
916
879
  let n;
917
880
  for (; (n = s.next()) && !n.done; ) {
918
881
  const i = n.value;
919
882
  e.call(r, i[0], i[1]);
920
883
  }
921
- }, ps = (r, e) => {
884
+ }, hs = (r, e) => {
922
885
  let t;
923
886
  const s = [];
924
887
  for (; (t = r.exec(e)) !== null; )
925
888
  s.push(t);
926
889
  return s;
927
- }, hs = J("HTMLFormElement"), gs = (r) => r.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g, function(t, s, n) {
890
+ }, gs = J("HTMLFormElement"), ms = (r) => r.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g, function(t, s, n) {
928
891
  return s.toUpperCase() + n;
929
- }), Qe = (({ hasOwnProperty: r }) => (e, t) => r.call(e, t))(Object.prototype), ms = J("RegExp"), ir = (r, e) => {
892
+ }), Qe = (({ hasOwnProperty: r }) => (e, t) => r.call(e, t))(Object.prototype), ys = J("RegExp"), ir = (r, e) => {
930
893
  const t = Object.getOwnPropertyDescriptors(r), s = {};
931
894
  Ee(t, (n, i) => {
932
895
  let o;
933
896
  (o = e(n, i, r)) !== !1 && (s[i] = o || n);
934
897
  }), Object.defineProperties(r, s);
935
- }, ys = (r) => {
898
+ }, bs = (r) => {
936
899
  ir(r, (e, t) => {
937
900
  if (I(r) && ["arguments", "caller", "callee"].includes(t))
938
901
  return !1;
@@ -947,19 +910,19 @@ const is = (r, e, t, { allOwnKeys: s } = {}) => (Ee(
947
910
  });
948
911
  }
949
912
  });
950
- }, bs = (r, e) => {
913
+ }, _s = (r, e) => {
951
914
  const t = {}, s = (n) => {
952
915
  n.forEach((i) => {
953
916
  t[i] = !0;
954
917
  });
955
918
  };
956
- return pe(r) ? s(r) : s(String(r).split(e)), t;
957
- }, _s = () => {
958
- }, ws = (r, e) => r != null && Number.isFinite(r = +r) ? r : e;
959
- function vs(r) {
919
+ return fe(r) ? s(r) : s(String(r).split(e)), t;
920
+ }, ws = () => {
921
+ }, vs = (r, e) => r != null && Number.isFinite(r = +r) ? r : e;
922
+ function Ss(r) {
960
923
  return !!(r && I(r.append) && r[er] === "FormData" && r[Ue]);
961
924
  }
962
- const Ss = (r) => {
925
+ const xs = (r) => {
963
926
  const e = /* @__PURE__ */ new WeakSet(), t = (s) => {
964
927
  if (xe(s)) {
965
928
  if (e.has(s))
@@ -968,86 +931,86 @@ const Ss = (r) => {
968
931
  return s;
969
932
  if (!("toJSON" in s)) {
970
933
  e.add(s);
971
- const n = pe(s) ? [] : {};
934
+ const n = fe(s) ? [] : {};
972
935
  return Ee(s, (i, o) => {
973
936
  const a = t(i);
974
- !fe(a) && (n[o] = a);
937
+ !ce(a) && (n[o] = a);
975
938
  }), e.delete(s), n;
976
939
  }
977
940
  }
978
941
  return s;
979
942
  };
980
943
  return t(r);
981
- }, xs = J("AsyncFunction"), Es = (r) => r && (xe(r) || I(r)) && I(r.then) && I(r.catch), or = ((r, e) => r ? setImmediate : e ? ((t, s) => (se.addEventListener(
944
+ }, Es = J("AsyncFunction"), ks = (r) => r && (xe(r) || I(r)) && I(r.then) && I(r.catch), or = ((r, e) => r ? setImmediate : e ? ((t, s) => (re.addEventListener(
982
945
  "message",
983
946
  ({ source: n, data: i }) => {
984
- n === se && i === t && s.length && s.shift()();
947
+ n === re && i === t && s.length && s.shift()();
985
948
  },
986
949
  !1
987
950
  ), (n) => {
988
- s.push(n), se.postMessage(t, "*");
989
- }))(`axios@${Math.random()}`, []) : (t) => setTimeout(t))(typeof setImmediate == "function", I(se.postMessage)), ks = typeof queueMicrotask < "u" ? queueMicrotask.bind(se) : typeof process < "u" && process.nextTick || or, Os = (r) => r != null && I(r[Ue]), c = {
990
- isArray: pe,
951
+ s.push(n), re.postMessage(t, "*");
952
+ }))(`axios@${Math.random()}`, []) : (t) => setTimeout(t))(typeof setImmediate == "function", I(re.postMessage)), Os = typeof queueMicrotask < "u" ? queueMicrotask.bind(re) : typeof process < "u" && process.nextTick || or, Rs = (r) => r != null && I(r[Ue]), c = {
953
+ isArray: fe,
991
954
  isArrayBuffer: tr,
992
955
  isBuffer: Se,
993
- isFormData: Xr,
994
- isArrayBufferView: $r,
995
- isString: Br,
956
+ isFormData: Qr,
957
+ isArrayBufferView: Br,
958
+ isString: Mr,
996
959
  isNumber: rr,
997
- isBoolean: Mr,
960
+ isBoolean: Vr,
998
961
  isObject: xe,
999
962
  isPlainObject: Le,
1000
- isEmptyObject: Vr,
1001
- isReadableStream: es,
1002
- isRequest: ts,
1003
- isResponse: rs,
1004
- isHeaders: ss,
1005
- isUndefined: fe,
1006
- isDate: qr,
1007
- isFile: Hr,
1008
- isReactNativeBlob: Kr,
1009
- isReactNative: Wr,
1010
- isBlob: Jr,
1011
- isRegExp: ms,
963
+ isEmptyObject: qr,
964
+ isReadableStream: ts,
965
+ isRequest: rs,
966
+ isResponse: ss,
967
+ isHeaders: ns,
968
+ isUndefined: ce,
969
+ isDate: Hr,
970
+ isFile: Kr,
971
+ isReactNativeBlob: Wr,
972
+ isReactNative: Jr,
973
+ isBlob: Gr,
974
+ isRegExp: ys,
1012
975
  isFunction: I,
1013
- isStream: Zr,
1014
- isURLSearchParams: Qr,
1015
- isTypedArray: cs,
1016
- isFileList: Gr,
976
+ isStream: Yr,
977
+ isURLSearchParams: es,
978
+ isTypedArray: fs,
979
+ isFileList: Zr,
1017
980
  forEach: Ee,
1018
981
  merge: Xe,
1019
- extend: is,
1020
- trim: ns,
1021
- stripBOM: os,
1022
- inherits: as,
1023
- toFlatObject: ls,
982
+ extend: os,
983
+ trim: is,
984
+ stripBOM: as,
985
+ inherits: ls,
986
+ toFlatObject: ds,
1024
987
  kindOf: $e,
1025
988
  kindOfTest: J,
1026
- endsWith: ds,
1027
- toArray: us,
1028
- forEachEntry: fs,
1029
- matchAll: ps,
1030
- isHTMLForm: hs,
989
+ endsWith: us,
990
+ toArray: cs,
991
+ forEachEntry: ps,
992
+ matchAll: hs,
993
+ isHTMLForm: gs,
1031
994
  hasOwnProperty: Qe,
1032
995
  hasOwnProp: Qe,
1033
996
  // an alias to avoid ESLint no-prototype-builtins detection
1034
997
  reduceDescriptors: ir,
1035
- freezeMethods: ys,
1036
- toObjectSet: bs,
1037
- toCamelCase: gs,
1038
- noop: _s,
1039
- toFiniteNumber: ws,
998
+ freezeMethods: bs,
999
+ toObjectSet: _s,
1000
+ toCamelCase: ms,
1001
+ noop: ws,
1002
+ toFiniteNumber: vs,
1040
1003
  findKey: sr,
1041
- global: se,
1004
+ global: re,
1042
1005
  isContextDefined: nr,
1043
- isSpecCompliantForm: vs,
1044
- toJSONObject: Ss,
1045
- isAsyncFn: xs,
1046
- isThenable: Es,
1006
+ isSpecCompliantForm: Ss,
1007
+ toJSONObject: xs,
1008
+ isAsyncFn: Es,
1009
+ isThenable: ks,
1047
1010
  setImmediate: or,
1048
- asap: ks,
1049
- isIterable: Os
1050
- }, Rs = c.toObjectSet([
1011
+ asap: Os,
1012
+ isIterable: Rs
1013
+ }, Cs = c.toObjectSet([
1051
1014
  "age",
1052
1015
  "authorization",
1053
1016
  "content-length",
@@ -1065,12 +1028,12 @@ const Ss = (r) => {
1065
1028
  "referer",
1066
1029
  "retry-after",
1067
1030
  "user-agent"
1068
- ]), Cs = (r) => {
1031
+ ]), Ps = (r) => {
1069
1032
  const e = {};
1070
1033
  let t, s, n;
1071
1034
  return r && r.split(`
1072
1035
  `).forEach(function(o) {
1073
- n = o.indexOf(":"), t = o.substring(0, n).trim().toLowerCase(), s = o.substring(n + 1).trim(), !(!t || e[t] && Rs[t]) && (t === "set-cookie" ? e[t] ? e[t].push(s) : e[t] = [s] : e[t] = e[t] ? e[t] + ", " + s : s);
1036
+ n = o.indexOf(":"), t = o.substring(0, n).trim().toLowerCase(), s = o.substring(n + 1).trim(), !(!t || e[t] && Cs[t]) && (t === "set-cookie" ? e[t] ? e[t].push(s) : e[t] = [s] : e[t] = e[t] ? e[t] + ", " + s : s);
1074
1037
  }), e;
1075
1038
  };
1076
1039
  function As(r) {
@@ -1089,32 +1052,32 @@ function As(r) {
1089
1052
  }
1090
1053
  return e === 0 && t === r.length ? r : r.slice(e, t);
1091
1054
  }
1092
- const Ps = new RegExp("[\\u0000-\\u0008\\u000a-\\u001f\\u007f]+", "g"), Ls = new RegExp("[^\\u0009\\u0020-\\u007e\\u0080-\\u00ff]+", "g");
1055
+ const Ls = new RegExp("[\\u0000-\\u0008\\u000a-\\u001f\\u007f]+", "g"), Ts = new RegExp("[^\\u0009\\u0020-\\u007e\\u0080-\\u00ff]+", "g");
1093
1056
  function it(r, e) {
1094
1057
  return c.isArray(r) ? r.map((t) => it(t, e)) : As(String(r).replace(e, ""));
1095
1058
  }
1096
- const Ts = (r) => it(r, Ps), js = (r) => it(r, Ls);
1059
+ const js = (r) => it(r, Ls), Ns = (r) => it(r, Ts);
1097
1060
  function ar(r) {
1098
1061
  const e = /* @__PURE__ */ Object.create(null);
1099
1062
  return c.forEach(r.toJSON(), (t, s) => {
1100
- e[s] = js(t);
1063
+ e[s] = Ns(t);
1101
1064
  }), e;
1102
1065
  }
1103
1066
  const yt = /* @__PURE__ */ Symbol("internals");
1104
- function me(r) {
1067
+ function ge(r) {
1105
1068
  return r && String(r).trim().toLowerCase();
1106
1069
  }
1107
1070
  function Te(r) {
1108
- return r === !1 || r == null ? r : c.isArray(r) ? r.map(Te) : Ts(String(r));
1071
+ return r === !1 || r == null ? r : c.isArray(r) ? r.map(Te) : js(String(r));
1109
1072
  }
1110
- function Ns(r) {
1073
+ function Ds(r) {
1111
1074
  const e = /* @__PURE__ */ Object.create(null), t = /([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;
1112
1075
  let s;
1113
1076
  for (; s = t.exec(r); )
1114
1077
  e[s[1]] = s[2];
1115
1078
  return e;
1116
1079
  }
1117
- const Ds = (r) => /^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(r.trim());
1080
+ const Fs = (r) => /^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(r.trim());
1118
1081
  function Ke(r, e, t, s, n) {
1119
1082
  if (c.isFunction(s))
1120
1083
  return s.call(this, e, t);
@@ -1125,10 +1088,10 @@ function Ke(r, e, t, s, n) {
1125
1088
  return s.test(e);
1126
1089
  }
1127
1090
  }
1128
- function Fs(r) {
1091
+ function zs(r) {
1129
1092
  return r.trim().toLowerCase().replace(/([a-z\d])(\w*)/g, (e, t, s) => t.toUpperCase() + s);
1130
1093
  }
1131
- function zs(r, e) {
1094
+ function Is(r, e) {
1132
1095
  const t = c.toCamelCase(" " + e);
1133
1096
  ["get", "set", "has"].forEach((s) => {
1134
1097
  Object.defineProperty(r, s + t, {
@@ -1149,7 +1112,7 @@ let F = class {
1149
1112
  set(e, t, s) {
1150
1113
  const n = this;
1151
1114
  function i(a, l, d) {
1152
- const u = me(l);
1115
+ const u = ge(l);
1153
1116
  if (!u)
1154
1117
  throw new Error("header name must be a non-empty string");
1155
1118
  const f = c.findKey(n, u);
@@ -1158,8 +1121,8 @@ let F = class {
1158
1121
  const o = (a, l) => c.forEach(a, (d, u) => i(d, u, l));
1159
1122
  if (c.isPlainObject(e) || e instanceof this.constructor)
1160
1123
  o(e, t);
1161
- else if (c.isString(e) && (e = e.trim()) && !Ds(e))
1162
- o(Cs(e), t);
1124
+ else if (c.isString(e) && (e = e.trim()) && !Fs(e))
1125
+ o(Ps(e), t);
1163
1126
  else if (c.isObject(e) && c.isIterable(e)) {
1164
1127
  let a = {}, l, d;
1165
1128
  for (const u of e) {
@@ -1173,14 +1136,14 @@ let F = class {
1173
1136
  return this;
1174
1137
  }
1175
1138
  get(e, t) {
1176
- if (e = me(e), e) {
1139
+ if (e = ge(e), e) {
1177
1140
  const s = c.findKey(this, e);
1178
1141
  if (s) {
1179
1142
  const n = this[s];
1180
1143
  if (!t)
1181
1144
  return n;
1182
1145
  if (t === !0)
1183
- return Ns(n);
1146
+ return Ds(n);
1184
1147
  if (c.isFunction(t))
1185
1148
  return t.call(this, n, s);
1186
1149
  if (c.isRegExp(t))
@@ -1190,7 +1153,7 @@ let F = class {
1190
1153
  }
1191
1154
  }
1192
1155
  has(e, t) {
1193
- if (e = me(e), e) {
1156
+ if (e = ge(e), e) {
1194
1157
  const s = c.findKey(this, e);
1195
1158
  return !!(s && this[s] !== void 0 && (!t || Ke(this, this[s], s, t)));
1196
1159
  }
@@ -1200,7 +1163,7 @@ let F = class {
1200
1163
  const s = this;
1201
1164
  let n = !1;
1202
1165
  function i(o) {
1203
- if (o = me(o), o) {
1166
+ if (o = ge(o), o) {
1204
1167
  const a = c.findKey(s, o);
1205
1168
  a && (!t || Ke(s, s[a], a, t)) && (delete s[a], n = !0);
1206
1169
  }
@@ -1224,7 +1187,7 @@ let F = class {
1224
1187
  t[o] = Te(n), delete t[i];
1225
1188
  return;
1226
1189
  }
1227
- const a = e ? Fs(i) : String(i).trim();
1190
+ const a = e ? zs(i) : String(i).trim();
1228
1191
  a !== i && delete t[i], t[a] = Te(n), s[a] = !0;
1229
1192
  }), this;
1230
1193
  }
@@ -1262,8 +1225,8 @@ let F = class {
1262
1225
  accessors: {}
1263
1226
  }).accessors, n = this.prototype;
1264
1227
  function i(o) {
1265
- const a = me(o);
1266
- s[a] || (zs(n, o), s[a] = !0);
1228
+ const a = ge(o);
1229
+ s[a] || (Is(n, o), s[a] = !0);
1267
1230
  }
1268
1231
  return c.isArray(e) ? e.forEach(i) : i(e), this;
1269
1232
  }
@@ -1286,8 +1249,8 @@ c.reduceDescriptors(F.prototype, ({ value: r }, e) => {
1286
1249
  };
1287
1250
  });
1288
1251
  c.freezeMethods(F);
1289
- const Is = "[REDACTED ****]";
1290
- function Us(r) {
1252
+ const Us = "[REDACTED ****]";
1253
+ function $s(r) {
1291
1254
  if (c.hasOwnProp(r, "toJSON"))
1292
1255
  return !0;
1293
1256
  let e = Object.getPrototypeOf(r);
@@ -1298,7 +1261,7 @@ function Us(r) {
1298
1261
  }
1299
1262
  return !1;
1300
1263
  }
1301
- function $s(r, e) {
1264
+ function Bs(r, e) {
1302
1265
  const t = new Set(e.map((i) => String(i).toLowerCase())), s = [], n = (i) => {
1303
1266
  if (i === null || typeof i != "object" || c.isBuffer(i)) return i;
1304
1267
  if (s.indexOf(i) !== -1) return;
@@ -1310,11 +1273,11 @@ function $s(r, e) {
1310
1273
  c.isUndefined(d) || (o[l] = d);
1311
1274
  });
1312
1275
  else {
1313
- if (!c.isPlainObject(i) && Us(i))
1276
+ if (!c.isPlainObject(i) && $s(i))
1314
1277
  return s.pop(), i;
1315
1278
  o = /* @__PURE__ */ Object.create(null);
1316
1279
  for (const [a, l] of Object.entries(i)) {
1317
- const d = t.has(a.toLowerCase()) ? Is : n(l);
1280
+ const d = t.has(a.toLowerCase()) ? Us : n(l);
1318
1281
  c.isUndefined(d) || (o[a] = d);
1319
1282
  }
1320
1283
  }
@@ -1350,7 +1313,7 @@ let w = class lr extends Error {
1350
1313
  }), this.name = "AxiosError", this.isAxiosError = !0, t && (this.code = t), s && (this.config = s), n && (this.request = n), i && (this.response = i, this.status = i.status);
1351
1314
  }
1352
1315
  toJSON() {
1353
- const e = this.config, t = e && c.hasOwnProp(e, "redact") ? e.redact : void 0, s = c.isArray(t) && t.length > 0 ? $s(e, t) : c.toJSONObject(e);
1316
+ const e = this.config, t = e && c.hasOwnProp(e, "redact") ? e.redact : void 0, s = c.isArray(t) && t.length > 0 ? Bs(e, t) : c.toJSONObject(e);
1354
1317
  return {
1355
1318
  // Standard
1356
1319
  message: this.message,
@@ -1384,7 +1347,7 @@ w.ERR_CANCELED = "ERR_CANCELED";
1384
1347
  w.ERR_NOT_SUPPORT = "ERR_NOT_SUPPORT";
1385
1348
  w.ERR_INVALID_URL = "ERR_INVALID_URL";
1386
1349
  w.ERR_FORM_DATA_DEPTH_EXCEEDED = "ERR_FORM_DATA_DEPTH_EXCEEDED";
1387
- const Bs = null;
1350
+ const Ms = null;
1388
1351
  function et(r) {
1389
1352
  return c.isPlainObject(r) || c.isArray(r);
1390
1353
  }
@@ -1396,10 +1359,10 @@ function We(r, e, t) {
1396
1359
  return n = dr(n), !t && i ? "[" + n + "]" : n;
1397
1360
  }).join(t ? "." : "") : e;
1398
1361
  }
1399
- function Ms(r) {
1362
+ function Vs(r) {
1400
1363
  return c.isArray(r) && !r.some(et);
1401
1364
  }
1402
- const Vs = c.toFlatObject(c, {}, null, function(e) {
1365
+ const qs = c.toFlatObject(c, {}, null, function(e) {
1403
1366
  return /^is[A-Z]/.test(e);
1404
1367
  });
1405
1368
  function Me(r, e, t) {
@@ -1437,18 +1400,18 @@ function Me(r, e, t) {
1437
1400
  if (y && !b && typeof y == "object") {
1438
1401
  if (c.endsWith(h, "{}"))
1439
1402
  h = s ? h : h.slice(0, -2), y = JSON.stringify(y);
1440
- else if (c.isArray(y) && Ms(y) || (c.isFileList(y) || c.endsWith(h, "[]")) && (v = c.toArray(y)))
1441
- return h = dr(h), v.forEach(function(S, A) {
1403
+ else if (c.isArray(y) && Vs(y) || (c.isFileList(y) || c.endsWith(h, "[]")) && (v = c.toArray(y)))
1404
+ return h = dr(h), v.forEach(function(S, P) {
1442
1405
  !(c.isUndefined(S) || S === null) && e.append(
1443
1406
  // eslint-disable-next-line no-nested-ternary
1444
- o === !0 ? We([h], A, i) : o === null ? h : h + "[]",
1407
+ o === !0 ? We([h], P, i) : o === null ? h : h + "[]",
1445
1408
  u(S)
1446
1409
  );
1447
1410
  }), !1;
1448
1411
  }
1449
1412
  return et(y) ? !0 : (e.append(We(b, h, i), u(y)), !1);
1450
1413
  }
1451
- const _ = [], g = Object.assign(Vs, {
1414
+ const _ = [], g = Object.assign(qs, {
1452
1415
  defaultVisitor: f,
1453
1416
  convertValue: u,
1454
1417
  isVisitable: et
@@ -1499,13 +1462,13 @@ ur.toString = function(e) {
1499
1462
  return t(n[0]) + "=" + t(n[1]);
1500
1463
  }, "").join("&");
1501
1464
  };
1502
- function qs(r) {
1465
+ function Hs(r) {
1503
1466
  return encodeURIComponent(r).replace(/%3A/gi, ":").replace(/%24/g, "$").replace(/%2C/gi, ",").replace(/%20/g, "+");
1504
1467
  }
1505
1468
  function cr(r, e, t) {
1506
1469
  if (!e)
1507
1470
  return r;
1508
- const s = t && t.encode || qs, n = c.isFunction(t) ? {
1471
+ const s = t && t.encode || Hs, n = c.isFunction(t) ? {
1509
1472
  serialize: t
1510
1473
  } : t, i = n && n.serialize;
1511
1474
  let o;
@@ -1575,27 +1538,27 @@ const at = {
1575
1538
  forcedJSONParsing: !0,
1576
1539
  clarifyTimeoutError: !1,
1577
1540
  legacyInterceptorReqResOrdering: !0
1578
- }, Hs = typeof URLSearchParams < "u" ? URLSearchParams : ot, Ks = typeof FormData < "u" ? FormData : null, Ws = typeof Blob < "u" ? Blob : null, Js = {
1541
+ }, Ks = typeof URLSearchParams < "u" ? URLSearchParams : ot, Ws = typeof FormData < "u" ? FormData : null, Js = typeof Blob < "u" ? Blob : null, Gs = {
1579
1542
  isBrowser: !0,
1580
1543
  classes: {
1581
- URLSearchParams: Hs,
1582
- FormData: Ks,
1583
- Blob: Ws
1544
+ URLSearchParams: Ks,
1545
+ FormData: Ws,
1546
+ Blob: Js
1584
1547
  },
1585
1548
  protocols: ["http", "https", "file", "blob", "url", "data"]
1586
- }, lt = typeof window < "u" && typeof document < "u", tt = typeof navigator == "object" && navigator || void 0, Gs = lt && (!tt || ["ReactNative", "NativeScript", "NS"].indexOf(tt.product) < 0), Zs = typeof WorkerGlobalScope < "u" && // eslint-disable-next-line no-undef
1587
- self instanceof WorkerGlobalScope && typeof self.importScripts == "function", Ys = lt && window.location.href || "http://localhost", Xs = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1549
+ }, lt = typeof window < "u" && typeof document < "u", tt = typeof navigator == "object" && navigator || void 0, Zs = lt && (!tt || ["ReactNative", "NativeScript", "NS"].indexOf(tt.product) < 0), Ys = typeof WorkerGlobalScope < "u" && // eslint-disable-next-line no-undef
1550
+ self instanceof WorkerGlobalScope && typeof self.importScripts == "function", Xs = lt && window.location.href || "http://localhost", Qs = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1588
1551
  __proto__: null,
1589
1552
  hasBrowserEnv: lt,
1590
- hasStandardBrowserEnv: Gs,
1591
- hasStandardBrowserWebWorkerEnv: Zs,
1553
+ hasStandardBrowserEnv: Zs,
1554
+ hasStandardBrowserWebWorkerEnv: Ys,
1592
1555
  navigator: tt,
1593
- origin: Ys
1556
+ origin: Xs
1594
1557
  }, Symbol.toStringTag, { value: "Module" })), N = {
1595
- ...Xs,
1596
- ...Js
1558
+ ...Qs,
1559
+ ...Gs
1597
1560
  };
1598
- function Qs(r, e) {
1561
+ function en(r, e) {
1599
1562
  return Me(r, new N.classes.URLSearchParams(), {
1600
1563
  visitor: function(t, s, n, i) {
1601
1564
  return N.isNode && c.isBuffer(t) ? (this.append(s, t.toString("base64")), !1) : i.defaultVisitor.apply(this, arguments);
@@ -1603,10 +1566,10 @@ function Qs(r, e) {
1603
1566
  ...e
1604
1567
  });
1605
1568
  }
1606
- function en(r) {
1569
+ function tn(r) {
1607
1570
  return c.matchAll(/\w+|\[(\w*)]/g, r).map((e) => e[0] === "[]" ? "" : e[1] || e[0]);
1608
1571
  }
1609
- function tn(r) {
1572
+ function rn(r) {
1610
1573
  const e = {}, t = Object.keys(r);
1611
1574
  let s;
1612
1575
  const n = t.length;
@@ -1620,18 +1583,18 @@ function fr(r) {
1620
1583
  let o = t[i++];
1621
1584
  if (o === "__proto__") return !0;
1622
1585
  const a = Number.isFinite(+o), l = i >= t.length;
1623
- return o = !o && c.isArray(n) ? n.length : o, l ? (c.hasOwnProp(n, o) ? n[o] = c.isArray(n[o]) ? n[o].concat(s) : [n[o], s] : n[o] = s, !a) : ((!c.hasOwnProp(n, o) || !c.isObject(n[o])) && (n[o] = []), e(t, s, n[o], i) && c.isArray(n[o]) && (n[o] = tn(n[o])), !a);
1586
+ return o = !o && c.isArray(n) ? n.length : o, l ? (c.hasOwnProp(n, o) ? n[o] = c.isArray(n[o]) ? n[o].concat(s) : [n[o], s] : n[o] = s, !a) : ((!c.hasOwnProp(n, o) || !c.isObject(n[o])) && (n[o] = []), e(t, s, n[o], i) && c.isArray(n[o]) && (n[o] = rn(n[o])), !a);
1624
1587
  }
1625
1588
  if (c.isFormData(r) && c.isFunction(r.entries)) {
1626
1589
  const t = {};
1627
1590
  return c.forEachEntry(r, (s, n) => {
1628
- e(en(s), n, t, 0);
1591
+ e(tn(s), n, t, 0);
1629
1592
  }), t;
1630
1593
  }
1631
1594
  return null;
1632
1595
  }
1633
- const ue = (r, e) => r != null && c.hasOwnProp(r, e) ? r[e] : void 0;
1634
- function rn(r, e, t) {
1596
+ const de = (r, e) => r != null && c.hasOwnProp(r, e) ? r[e] : void 0;
1597
+ function sn(r, e, t) {
1635
1598
  if (c.isString(r))
1636
1599
  try {
1637
1600
  return (e || JSON.parse)(r), c.trim(r);
@@ -1657,11 +1620,11 @@ const ke = {
1657
1620
  return t.setContentType("application/x-www-form-urlencoded;charset=utf-8", !1), e.toString();
1658
1621
  let a;
1659
1622
  if (i) {
1660
- const l = ue(this, "formSerializer");
1623
+ const l = de(this, "formSerializer");
1661
1624
  if (s.indexOf("application/x-www-form-urlencoded") > -1)
1662
- return Qs(e, l).toString();
1625
+ return en(e, l).toString();
1663
1626
  if ((a = c.isFileList(e)) || s.indexOf("multipart/form-data") > -1) {
1664
- const d = ue(this, "env"), u = d && d.FormData;
1627
+ const d = de(this, "env"), u = d && d.FormData;
1665
1628
  return Me(
1666
1629
  a ? { "files[]": e } : e,
1667
1630
  u && new u(),
@@ -1669,21 +1632,21 @@ const ke = {
1669
1632
  );
1670
1633
  }
1671
1634
  }
1672
- return i || n ? (t.setContentType("application/json", !1), rn(e)) : e;
1635
+ return i || n ? (t.setContentType("application/json", !1), sn(e)) : e;
1673
1636
  }
1674
1637
  ],
1675
1638
  transformResponse: [
1676
1639
  function(e) {
1677
- const t = ue(this, "transitional") || ke.transitional, s = t && t.forcedJSONParsing, n = ue(this, "responseType"), i = n === "json";
1640
+ const t = de(this, "transitional") || ke.transitional, s = t && t.forcedJSONParsing, n = de(this, "responseType"), i = n === "json";
1678
1641
  if (c.isResponse(e) || c.isReadableStream(e))
1679
1642
  return e;
1680
1643
  if (e && c.isString(e) && (s && !n || i)) {
1681
1644
  const a = !(t && t.silentJSONParsing) && i;
1682
1645
  try {
1683
- return JSON.parse(e, ue(this, "parseReviver"));
1646
+ return JSON.parse(e, de(this, "parseReviver"));
1684
1647
  } catch (l) {
1685
1648
  if (a)
1686
- throw l.name === "SyntaxError" ? w.from(l, w.ERR_BAD_RESPONSE, this, null, ue(this, "response")) : l;
1649
+ throw l.name === "SyntaxError" ? w.from(l, w.ERR_BAD_RESPONSE, this, null, de(this, "response")) : l;
1687
1650
  }
1688
1651
  }
1689
1652
  return e;
@@ -1749,11 +1712,11 @@ function hr(r, e, t) {
1749
1712
  t
1750
1713
  ));
1751
1714
  }
1752
- function sn(r) {
1715
+ function nn(r) {
1753
1716
  const e = /^([-+\w]{1,25}):(?:\/\/)?/.exec(r);
1754
1717
  return e && e[1] || "";
1755
1718
  }
1756
- function nn(r, e) {
1719
+ function on(r, e) {
1757
1720
  r = r || 10;
1758
1721
  const t = new Array(r), s = new Array(r);
1759
1722
  let n = 0, i = 0, o;
@@ -1769,7 +1732,7 @@ function nn(r, e) {
1769
1732
  return g ? Math.round(_ * 1e3 / g) : void 0;
1770
1733
  };
1771
1734
  }
1772
- function on(r, e) {
1735
+ function an(r, e) {
1773
1736
  let t = 0, s = 1e3 / e, n, i;
1774
1737
  const o = (d, u = Date.now()) => {
1775
1738
  t = u, n = null, i && (clearTimeout(i), i = null), r(...d);
@@ -1783,8 +1746,8 @@ function on(r, e) {
1783
1746
  }
1784
1747
  const Ne = (r, e, t = 3) => {
1785
1748
  let s = 0;
1786
- const n = nn(50, 250);
1787
- return on((i) => {
1749
+ const n = on(50, 250);
1750
+ return an((i) => {
1788
1751
  if (!i || typeof i.loaded != "number")
1789
1752
  return;
1790
1753
  const o = i.loaded, a = i.lengthComputable ? i.total : void 0, l = a != null ? Math.min(o, a) : o, d = Math.max(0, l - s), u = n(d);
@@ -1812,10 +1775,10 @@ const Ne = (r, e, t = 3) => {
1812
1775
  }),
1813
1776
  e[1]
1814
1777
  ];
1815
- }, vt = (r) => (...e) => c.asap(() => r(...e)), an = N.hasStandardBrowserEnv ? /* @__PURE__ */ ((r, e) => (t) => (t = new URL(t, N.origin), r.protocol === t.protocol && r.host === t.host && (e || r.port === t.port)))(
1778
+ }, vt = (r) => (...e) => c.asap(() => r(...e)), ln = N.hasStandardBrowserEnv ? /* @__PURE__ */ ((r, e) => (t) => (t = new URL(t, N.origin), r.protocol === t.protocol && r.host === t.host && (e || r.port === t.port)))(
1816
1779
  new URL(N.origin),
1817
1780
  N.navigator && /(msie|trident)/i.test(N.navigator.userAgent)
1818
- ) : () => !0, ln = N.hasStandardBrowserEnv ? (
1781
+ ) : () => !0, dn = N.hasStandardBrowserEnv ? (
1819
1782
  // Standard browser envs support document.cookie
1820
1783
  {
1821
1784
  write(r, e, t, s, n, i, o) {
@@ -1849,18 +1812,18 @@ const Ne = (r, e, t = 3) => {
1849
1812
  }
1850
1813
  }
1851
1814
  );
1852
- function dn(r) {
1815
+ function un(r) {
1853
1816
  return typeof r != "string" ? !1 : /^([a-z][a-z\d+\-.]*:)?\/\//i.test(r);
1854
1817
  }
1855
- function un(r, e) {
1818
+ function cn(r, e) {
1856
1819
  return e ? r.replace(/\/?\/$/, "") + "/" + e.replace(/^\/+/, "") : r;
1857
1820
  }
1858
1821
  function gr(r, e, t) {
1859
- let s = !dn(e);
1860
- return r && (s || t === !1) ? un(r, e) : e;
1822
+ let s = !un(e);
1823
+ return r && (s || t === !1) ? cn(r, e) : e;
1861
1824
  }
1862
1825
  const St = (r) => r instanceof F ? { ...r } : r;
1863
- function ie(r, e) {
1826
+ function ne(r, e) {
1864
1827
  e = e || {};
1865
1828
  const t = /* @__PURE__ */ Object.create(null);
1866
1829
  Object.defineProperty(t, "hasOwnProperty", {
@@ -1935,21 +1898,21 @@ function ie(r, e) {
1935
1898
  c.isUndefined(m) && f !== a || (t[u] = m);
1936
1899
  }), t;
1937
1900
  }
1938
- const cn = ["content-type", "content-length"];
1939
- function fn(r, e, t) {
1901
+ const fn = ["content-type", "content-length"];
1902
+ function pn(r, e, t) {
1940
1903
  if (t !== "content-only") {
1941
1904
  r.set(e);
1942
1905
  return;
1943
1906
  }
1944
1907
  Object.entries(e).forEach(([s, n]) => {
1945
- cn.includes(s.toLowerCase()) && r.set(s, n);
1908
+ fn.includes(s.toLowerCase()) && r.set(s, n);
1946
1909
  });
1947
1910
  }
1948
- const pn = (r) => encodeURIComponent(r).replace(
1911
+ const hn = (r) => encodeURIComponent(r).replace(
1949
1912
  /%([0-9A-F]{2})/gi,
1950
1913
  (e, t) => String.fromCharCode(parseInt(t, 16))
1951
1914
  ), mr = (r) => {
1952
- const e = ie({}, r), t = (_) => c.hasOwnProp(e, _) ? e[_] : void 0, s = t("data");
1915
+ const e = ne({}, r), t = (_) => c.hasOwnProp(e, _) ? e[_] : void 0, s = t("data");
1953
1916
  let n = t("withXSRFToken");
1954
1917
  const i = t("xsrfHeaderName"), o = t("xsrfCookieName");
1955
1918
  let a = t("headers");
@@ -1960,13 +1923,13 @@ const pn = (r) => encodeURIComponent(r).replace(
1960
1923
  r.paramsSerializer
1961
1924
  ), l && a.set(
1962
1925
  "Authorization",
1963
- "Basic " + btoa((l.username || "") + ":" + (l.password ? pn(l.password) : ""))
1964
- ), c.isFormData(s) && (N.hasStandardBrowserEnv || N.hasStandardBrowserWebWorkerEnv ? a.setContentType(void 0) : c.isFunction(s.getHeaders) && fn(a, s.getHeaders(), t("formDataHeaderPolicy"))), N.hasStandardBrowserEnv && (c.isFunction(n) && (n = n(e)), n === !0 || n == null && an(e.url))) {
1965
- const g = i && o && ln.read(o);
1926
+ "Basic " + btoa((l.username || "") + ":" + (l.password ? hn(l.password) : ""))
1927
+ ), c.isFormData(s) && (N.hasStandardBrowserEnv || N.hasStandardBrowserWebWorkerEnv ? a.setContentType(void 0) : c.isFunction(s.getHeaders) && pn(a, s.getHeaders(), t("formDataHeaderPolicy"))), N.hasStandardBrowserEnv && (c.isFunction(n) && (n = n(e)), n === !0 || n == null && ln(e.url))) {
1928
+ const g = i && o && dn.read(o);
1966
1929
  g && a.set(i, g);
1967
1930
  }
1968
1931
  return e;
1969
- }, hn = typeof XMLHttpRequest < "u", gn = hn && function(r) {
1932
+ }, gn = typeof XMLHttpRequest < "u", mn = gn && function(r) {
1970
1933
  return new Promise(function(t, s) {
1971
1934
  const n = mr(r);
1972
1935
  let i = n.data;
@@ -1982,7 +1945,7 @@ const pn = (r) => encodeURIComponent(r).replace(
1982
1945
  return;
1983
1946
  const x = F.from(
1984
1947
  "getAllResponseHeaders" in h && h.getAllResponseHeaders()
1985
- ), A = {
1948
+ ), P = {
1986
1949
  data: !a || a === "text" || a === "json" ? h.responseText : h.response,
1987
1950
  status: h.status,
1988
1951
  statusText: h.statusText,
@@ -1997,7 +1960,7 @@ const pn = (r) => encodeURIComponent(r).replace(
1997
1960
  function(B) {
1998
1961
  s(B), y();
1999
1962
  },
2000
- A
1963
+ P
2001
1964
  ), h = null;
2002
1965
  }
2003
1966
  "onloadend" in h ? h.onloadend = b : h.onreadystatechange = function() {
@@ -2005,25 +1968,25 @@ const pn = (r) => encodeURIComponent(r).replace(
2005
1968
  }, h.onabort = function() {
2006
1969
  h && (s(new w("Request aborted", w.ECONNABORTED, r, h)), y(), h = null);
2007
1970
  }, h.onerror = function(S) {
2008
- const A = S && S.message ? S.message : "Network Error", z = new w(A, w.ERR_NETWORK, r, h);
1971
+ const P = S && S.message ? S.message : "Network Error", z = new w(P, w.ERR_NETWORK, r, h);
2009
1972
  z.event = S || null, s(z), y(), h = null;
2010
1973
  }, h.ontimeout = function() {
2011
1974
  let S = n.timeout ? "timeout of " + n.timeout + "ms exceeded" : "timeout exceeded";
2012
- const A = n.transitional || at;
1975
+ const P = n.transitional || at;
2013
1976
  n.timeoutErrorMessage && (S = n.timeoutErrorMessage), s(
2014
1977
  new w(
2015
1978
  S,
2016
- A.clarifyTimeoutError ? w.ETIMEDOUT : w.ECONNABORTED,
1979
+ P.clarifyTimeoutError ? w.ETIMEDOUT : w.ECONNABORTED,
2017
1980
  r,
2018
1981
  h
2019
1982
  )
2020
1983
  ), y(), h = null;
2021
- }, i === void 0 && o.setContentType(null), "setRequestHeader" in h && c.forEach(ar(o), function(S, A) {
2022
- h.setRequestHeader(A, S);
1984
+ }, i === void 0 && o.setContentType(null), "setRequestHeader" in h && c.forEach(ar(o), function(S, P) {
1985
+ h.setRequestHeader(P, S);
2023
1986
  }), c.isUndefined(n.withCredentials) || (h.withCredentials = !!n.withCredentials), a && a !== "json" && (h.responseType = n.responseType), d && ([_, m] = Ne(d, !0), h.addEventListener("progress", _)), l && h.upload && ([f, g] = Ne(l), h.upload.addEventListener("progress", f), h.upload.addEventListener("loadend", g)), (n.cancelToken || n.signal) && (u = (x) => {
2024
1987
  h && (s(!x || x.type ? new Oe(null, r, h) : x), h.abort(), y(), h = null);
2025
1988
  }, n.cancelToken && n.cancelToken.subscribe(u), n.signal && (n.signal.aborted ? u() : n.signal.addEventListener("abort", u)));
2026
- const v = sn(n.url);
1989
+ const v = nn(n.url);
2027
1990
  if (v && !N.protocols.includes(v)) {
2028
1991
  s(
2029
1992
  new w(
@@ -2036,7 +1999,7 @@ const pn = (r) => encodeURIComponent(r).replace(
2036
1999
  }
2037
2000
  h.send(i || null);
2038
2001
  });
2039
- }, mn = (r, e) => {
2002
+ }, yn = (r, e) => {
2040
2003
  if (r = r ? r.filter(Boolean) : [], !e && !r.length)
2041
2004
  return;
2042
2005
  const t = new AbortController();
@@ -2061,7 +2024,7 @@ const pn = (r) => encodeURIComponent(r).replace(
2061
2024
  r.forEach((l) => l.addEventListener("abort", n));
2062
2025
  const { signal: a } = t;
2063
2026
  return a.unsubscribe = () => c.asap(o), a;
2064
- }, yn = function* (r, e) {
2027
+ }, bn = function* (r, e) {
2065
2028
  let t = r.byteLength;
2066
2029
  if (t < e) {
2067
2030
  yield r;
@@ -2070,10 +2033,10 @@ const pn = (r) => encodeURIComponent(r).replace(
2070
2033
  let s = 0, n;
2071
2034
  for (; s < t; )
2072
2035
  n = s + e, yield r.slice(s, n), s = n;
2073
- }, bn = async function* (r, e) {
2074
- for await (const t of _n(r))
2075
- yield* yn(t, e);
2076
- }, _n = async function* (r) {
2036
+ }, _n = async function* (r, e) {
2037
+ for await (const t of wn(r))
2038
+ yield* bn(t, e);
2039
+ }, wn = async function* (r) {
2077
2040
  if (r[Symbol.asyncIterator]) {
2078
2041
  yield* r;
2079
2042
  return;
@@ -2090,7 +2053,7 @@ const pn = (r) => encodeURIComponent(r).replace(
2090
2053
  await e.cancel();
2091
2054
  }
2092
2055
  }, xt = (r, e, t, s) => {
2093
- const n = bn(r, e);
2056
+ const n = _n(r, e);
2094
2057
  let i = 0, o, a = (l) => {
2095
2058
  o || (o = !0, s && s(l));
2096
2059
  };
@@ -2122,7 +2085,7 @@ const pn = (r) => encodeURIComponent(r).replace(
2122
2085
  }
2123
2086
  );
2124
2087
  };
2125
- function wn(r) {
2088
+ function vn(r) {
2126
2089
  if (!r || typeof r != "string" || !r.startsWith("data:")) return 0;
2127
2090
  const e = r.indexOf(",");
2128
2091
  if (e < 0) return 0;
@@ -2160,13 +2123,13 @@ function wn(r) {
2160
2123
  }
2161
2124
  return i;
2162
2125
  }
2163
- const dt = "1.16.1", Et = 64 * 1024, { isFunction: Ae } = c, kt = (r, ...e) => {
2126
+ const dt = "1.16.1", Et = 64 * 1024, { isFunction: Pe } = c, kt = (r, ...e) => {
2164
2127
  try {
2165
2128
  return !!r(...e);
2166
2129
  } catch {
2167
2130
  return !1;
2168
2131
  }
2169
- }, vn = (r) => {
2132
+ }, Sn = (r) => {
2170
2133
  const e = c.global !== void 0 && c.global !== null ? c.global : globalThis, { ReadableStream: t, TextEncoder: s } = e;
2171
2134
  r = c.merge.call(
2172
2135
  {
@@ -2178,10 +2141,10 @@ const dt = "1.16.1", Et = 64 * 1024, { isFunction: Ae } = c, kt = (r, ...e) => {
2178
2141
  },
2179
2142
  r
2180
2143
  );
2181
- const { fetch: n, Request: i, Response: o } = r, a = n ? Ae(n) : typeof fetch == "function", l = Ae(i), d = Ae(o);
2144
+ const { fetch: n, Request: i, Response: o } = r, a = n ? Pe(n) : typeof fetch == "function", l = Pe(i), d = Pe(o);
2182
2145
  if (!a)
2183
2146
  return !1;
2184
- const u = a && Ae(t), f = a && (typeof s == "function" ? /* @__PURE__ */ ((b) => (v) => b.encode(v))(new s()) : async (b) => new Uint8Array(await new i(b).arrayBuffer())), _ = l && u && kt(() => {
2147
+ const u = a && Pe(t), f = a && (typeof s == "function" ? /* @__PURE__ */ ((b) => (v) => b.encode(v))(new s()) : async (b) => new Uint8Array(await new i(b).arrayBuffer())), _ = l && u && kt(() => {
2185
2148
  let b = !1;
2186
2149
  const v = new i(N.origin, {
2187
2150
  body: new t(),
@@ -2229,31 +2192,31 @@ const dt = "1.16.1", Et = 64 * 1024, { isFunction: Ae } = c, kt = (r, ...e) => {
2229
2192
  url: v,
2230
2193
  method: x,
2231
2194
  data: S,
2232
- signal: A,
2195
+ signal: P,
2233
2196
  cancelToken: z,
2234
2197
  timeout: B,
2235
- onDownloadProgress: oe,
2198
+ onDownloadProgress: ie,
2236
2199
  onUploadProgress: H,
2237
2200
  responseType: L,
2238
2201
  headers: X,
2239
- withCredentials: ae = "same-origin",
2202
+ withCredentials: oe = "same-origin",
2240
2203
  fetchOptions: U,
2241
2204
  maxContentLength: R,
2242
- maxBodyLength: le
2205
+ maxBodyLength: ae
2243
2206
  } = mr(b);
2244
- const j = c.isNumber(R) && R > -1, K = c.isNumber(le) && le > -1;
2207
+ const j = c.isNumber(R) && R > -1, K = c.isNumber(ae) && ae > -1;
2245
2208
  let ee = n || fetch;
2246
2209
  L = L ? (L + "").toLowerCase() : "text";
2247
- let $ = mn(
2248
- [A, z && z.toAbortSignal()],
2210
+ let $ = yn(
2211
+ [P, z && z.toAbortSignal()],
2249
2212
  B
2250
2213
  ), D = null;
2251
- const P = $ && $.unsubscribe && (() => {
2214
+ const A = $ && $.unsubscribe && (() => {
2252
2215
  $.unsubscribe();
2253
2216
  });
2254
2217
  let G;
2255
2218
  try {
2256
- if (j && typeof v == "string" && v.startsWith("data:") && wn(v) > R)
2219
+ if (j && typeof v == "string" && v.startsWith("data:") && vn(v) > R)
2257
2220
  throw new w(
2258
2221
  "maxContentLength size of " + R + " exceeded",
2259
2222
  w.ERR_BAD_RESPONSE,
@@ -2262,7 +2225,7 @@ const dt = "1.16.1", Et = 64 * 1024, { isFunction: Ae } = c, kt = (r, ...e) => {
2262
2225
  );
2263
2226
  if (K && x !== "get" && x !== "head") {
2264
2227
  const k = await h(X, S);
2265
- if (typeof k == "number" && isFinite(k) && k > le)
2228
+ if (typeof k == "number" && isFinite(k) && k > ae)
2266
2229
  throw new w(
2267
2230
  "Request body larger than maxBodyLength limit",
2268
2231
  w.ERR_BAD_REQUEST,
@@ -2275,8 +2238,8 @@ const dt = "1.16.1", Et = 64 * 1024, { isFunction: Ae } = c, kt = (r, ...e) => {
2275
2238
  method: "POST",
2276
2239
  body: S,
2277
2240
  duplex: "half"
2278
- }), de;
2279
- if (c.isFormData(S) && (de = k.headers.get("content-type")) && X.setContentType(de), k.body) {
2241
+ }), le;
2242
+ if (c.isFormData(S) && (le = k.headers.get("content-type")) && X.setContentType(le), k.body) {
2280
2243
  const [Re, Ce] = wt(
2281
2244
  G,
2282
2245
  Ne(vt(H))
@@ -2284,7 +2247,7 @@ const dt = "1.16.1", Et = 64 * 1024, { isFunction: Ae } = c, kt = (r, ...e) => {
2284
2247
  S = xt(k.body, Et, Re, Ce);
2285
2248
  }
2286
2249
  }
2287
- c.isString(ae) || (ae = ae ? "include" : "omit");
2250
+ c.isString(oe) || (oe = oe ? "include" : "omit");
2288
2251
  const C = l && "credentials" in i.prototype;
2289
2252
  if (c.isFormData(S)) {
2290
2253
  const k = X.getContentType();
@@ -2298,7 +2261,7 @@ const dt = "1.16.1", Et = 64 * 1024, { isFunction: Ae } = c, kt = (r, ...e) => {
2298
2261
  headers: ar(X.normalize()),
2299
2262
  body: S,
2300
2263
  duplex: "half",
2301
- credentials: C ? ae : void 0
2264
+ credentials: C ? oe : void 0
2302
2265
  };
2303
2266
  D = l && new i(v, W);
2304
2267
  let Z = await (l ? ee(D, U) : ee(v, W));
@@ -2313,29 +2276,29 @@ const dt = "1.16.1", Et = 64 * 1024, { isFunction: Ae } = c, kt = (r, ...e) => {
2313
2276
  );
2314
2277
  }
2315
2278
  const He = g && (L === "stream" || L === "response");
2316
- if (g && Z.body && (oe || j || He && P)) {
2279
+ if (g && Z.body && (ie || j || He && A)) {
2317
2280
  const k = {};
2318
- ["status", "statusText", "headers"].forEach((ge) => {
2319
- k[ge] = Z[ge];
2281
+ ["status", "statusText", "headers"].forEach((he) => {
2282
+ k[he] = Z[he];
2320
2283
  });
2321
- const de = c.toFiniteNumber(Z.headers.get("content-length")), [Re, Ce] = oe && wt(
2322
- de,
2323
- Ne(vt(oe), !0)
2284
+ const le = c.toFiniteNumber(Z.headers.get("content-length")), [Re, Ce] = ie && wt(
2285
+ le,
2286
+ Ne(vt(ie), !0)
2324
2287
  ) || [];
2325
2288
  let ft = 0;
2326
- const kr = (ge) => {
2327
- if (j && (ft = ge, ft > R))
2289
+ const kr = (he) => {
2290
+ if (j && (ft = he, ft > R))
2328
2291
  throw new w(
2329
2292
  "maxContentLength size of " + R + " exceeded",
2330
2293
  w.ERR_BAD_RESPONSE,
2331
2294
  b,
2332
2295
  D
2333
2296
  );
2334
- Re && Re(ge);
2297
+ Re && Re(he);
2335
2298
  };
2336
2299
  Z = new o(
2337
2300
  xt(Z.body, Et, kr, () => {
2338
- Ce && Ce(), P && P();
2301
+ Ce && Ce(), A && A();
2339
2302
  }),
2340
2303
  k
2341
2304
  );
@@ -2355,8 +2318,8 @@ const dt = "1.16.1", Et = 64 * 1024, { isFunction: Ae } = c, kt = (r, ...e) => {
2355
2318
  D
2356
2319
  );
2357
2320
  }
2358
- return !He && P && P(), await new Promise((k, de) => {
2359
- hr(k, de, {
2321
+ return !He && A && A(), await new Promise((k, le) => {
2322
+ hr(k, le, {
2360
2323
  data: Q,
2361
2324
  headers: F.from(Z.headers),
2362
2325
  status: Z.status,
@@ -2366,7 +2329,7 @@ const dt = "1.16.1", Et = 64 * 1024, { isFunction: Ae } = c, kt = (r, ...e) => {
2366
2329
  });
2367
2330
  });
2368
2331
  } catch (C) {
2369
- if (P && P(), $ && $.aborted && $.reason instanceof w) {
2332
+ if (A && A(), $ && $.aborted && $.reason instanceof w) {
2370
2333
  const W = $.reason;
2371
2334
  throw W.config = b, D && (W.request = D), C !== W && (W.cause = C), W;
2372
2335
  }
@@ -2384,18 +2347,18 @@ const dt = "1.16.1", Et = 64 * 1024, { isFunction: Ae } = c, kt = (r, ...e) => {
2384
2347
  ) : w.from(C, C && C.code, b, D, C && C.response);
2385
2348
  }
2386
2349
  };
2387
- }, Sn = /* @__PURE__ */ new Map(), yr = (r) => {
2350
+ }, xn = /* @__PURE__ */ new Map(), yr = (r) => {
2388
2351
  let e = r && r.env || {};
2389
2352
  const { fetch: t, Request: s, Response: n } = e, i = [s, n, t];
2390
- let o = i.length, a = o, l, d, u = Sn;
2353
+ let o = i.length, a = o, l, d, u = xn;
2391
2354
  for (; a--; )
2392
- l = i[a], d = u.get(l), d === void 0 && u.set(l, d = a ? /* @__PURE__ */ new Map() : vn(e)), u = d;
2355
+ l = i[a], d = u.get(l), d === void 0 && u.set(l, d = a ? /* @__PURE__ */ new Map() : Sn(e)), u = d;
2393
2356
  return d;
2394
2357
  };
2395
2358
  yr();
2396
2359
  const ut = {
2397
- http: Bs,
2398
- xhr: gn,
2360
+ http: Ms,
2361
+ xhr: mn,
2399
2362
  fetch: {
2400
2363
  get: yr
2401
2364
  }
@@ -2409,8 +2372,8 @@ c.forEach(ut, (r, e) => {
2409
2372
  Object.defineProperty(r, "adapterName", { __proto__: null, value: e });
2410
2373
  }
2411
2374
  });
2412
- const Ot = (r) => `- ${r}`, xn = (r) => c.isFunction(r) || r === null || r === !1;
2413
- function En(r, e) {
2375
+ const Ot = (r) => `- ${r}`, En = (r) => c.isFunction(r) || r === null || r === !1;
2376
+ function kn(r, e) {
2414
2377
  r = c.isArray(r) ? r : [r];
2415
2378
  const { length: t } = r;
2416
2379
  let s, n;
@@ -2418,7 +2381,7 @@ function En(r, e) {
2418
2381
  for (let o = 0; o < t; o++) {
2419
2382
  s = r[o];
2420
2383
  let a;
2421
- if (n = s, !xn(s) && (n = ut[(a = String(s)).toLowerCase()], n === void 0))
2384
+ if (n = s, !En(s) && (n = ut[(a = String(s)).toLowerCase()], n === void 0))
2422
2385
  throw new w(`Unknown adapter '${a}'`);
2423
2386
  if (n && (c.isFunction(n) || (n = n.get(e))))
2424
2387
  break;
@@ -2443,7 +2406,7 @@ const br = {
2443
2406
  * Resolve an adapter from a list of adapter names or functions.
2444
2407
  * @type {Function}
2445
2408
  */
2446
- getAdapter: En,
2409
+ getAdapter: kn,
2447
2410
  /**
2448
2411
  * Exposes all known adapters
2449
2412
  * @type {Object<string, Function|Object>}
@@ -2511,7 +2474,7 @@ Ve.transitional = function(e, t, s) {
2511
2474
  Ve.spelling = function(e) {
2512
2475
  return (t, s) => (console.warn(`${s} is likely a misspelling of ${e}`), !0);
2513
2476
  };
2514
- function kn(r, e, t) {
2477
+ function On(r, e, t) {
2515
2478
  if (typeof r != "object")
2516
2479
  throw new w("options must be an object", w.ERR_BAD_OPTION_VALUE);
2517
2480
  const s = Object.keys(r);
@@ -2532,10 +2495,10 @@ function kn(r, e, t) {
2532
2495
  }
2533
2496
  }
2534
2497
  const je = {
2535
- assertOptions: kn,
2498
+ assertOptions: On,
2536
2499
  validators: Ve
2537
2500
  }, M = je.validators;
2538
- let ne = class {
2501
+ let se = class {
2539
2502
  constructor(e) {
2540
2503
  this.defaults = e || {}, this.interceptors = {
2541
2504
  request: new _t(),
@@ -2581,7 +2544,7 @@ let ne = class {
2581
2544
  }
2582
2545
  }
2583
2546
  _request(e, t) {
2584
- typeof e == "string" ? (t = t || {}, t.url = e) : t = e || {}, t = ie(this.defaults, t);
2547
+ typeof e == "string" ? (t = t || {}, t.url = e) : t = e || {}, t = ne(this.defaults, t);
2585
2548
  const { transitional: s, paramsSerializer: n, headers: i } = t;
2586
2549
  s !== void 0 && je.assertOptions(
2587
2550
  s,
@@ -2654,15 +2617,15 @@ let ne = class {
2654
2617
  return u;
2655
2618
  }
2656
2619
  getUri(e) {
2657
- e = ie(this.defaults, e);
2620
+ e = ne(this.defaults, e);
2658
2621
  const t = gr(e.baseURL, e.url, e.allowAbsoluteUrls);
2659
2622
  return cr(t, e.params, e.paramsSerializer);
2660
2623
  }
2661
2624
  };
2662
2625
  c.forEach(["delete", "get", "head", "options"], function(e) {
2663
- ne.prototype[e] = function(t, s) {
2626
+ se.prototype[e] = function(t, s) {
2664
2627
  return this.request(
2665
- ie(s || {}, {
2628
+ ne(s || {}, {
2666
2629
  method: e,
2667
2630
  url: t,
2668
2631
  data: (s || {}).data
@@ -2674,7 +2637,7 @@ c.forEach(["post", "put", "patch", "query"], function(e) {
2674
2637
  function t(s) {
2675
2638
  return function(i, o, a) {
2676
2639
  return this.request(
2677
- ie(a || {}, {
2640
+ ne(a || {}, {
2678
2641
  method: e,
2679
2642
  headers: s ? {
2680
2643
  "Content-Type": "multipart/form-data"
@@ -2685,9 +2648,9 @@ c.forEach(["post", "put", "patch", "query"], function(e) {
2685
2648
  );
2686
2649
  };
2687
2650
  }
2688
- ne.prototype[e] = t(), e !== "query" && (ne.prototype[e + "Form"] = t(!0));
2651
+ se.prototype[e] = t(), e !== "query" && (se.prototype[e + "Form"] = t(!0));
2689
2652
  });
2690
- let On = class _r {
2653
+ let Rn = class _r {
2691
2654
  constructor(e) {
2692
2655
  if (typeof e != "function")
2693
2656
  throw new TypeError("executor must be a function.");
@@ -2760,12 +2723,12 @@ let On = class _r {
2760
2723
  };
2761
2724
  }
2762
2725
  };
2763
- function Rn(r) {
2726
+ function Cn(r) {
2764
2727
  return function(t) {
2765
2728
  return r.apply(null, t);
2766
2729
  };
2767
2730
  }
2768
- function Cn(r) {
2731
+ function Pn(r) {
2769
2732
  return c.isObject(r) && r.isAxiosError === !0;
2770
2733
  }
2771
2734
  const rt = {
@@ -2843,15 +2806,15 @@ Object.entries(rt).forEach(([r, e]) => {
2843
2806
  rt[e] = r;
2844
2807
  });
2845
2808
  function wr(r) {
2846
- const e = new ne(r), t = Qt(ne.prototype.request, e);
2847
- return c.extend(t, ne.prototype, e, { allOwnKeys: !0 }), c.extend(t, e, null, { allOwnKeys: !0 }), t.create = function(n) {
2848
- return wr(ie(r, n));
2809
+ const e = new se(r), t = Qt(se.prototype.request, e);
2810
+ return c.extend(t, se.prototype, e, { allOwnKeys: !0 }), c.extend(t, e, null, { allOwnKeys: !0 }), t.create = function(n) {
2811
+ return wr(ne(r, n));
2849
2812
  }, t;
2850
2813
  }
2851
2814
  const O = wr(ke);
2852
- O.Axios = ne;
2815
+ O.Axios = se;
2853
2816
  O.CanceledError = Oe;
2854
- O.CancelToken = On;
2817
+ O.CancelToken = Rn;
2855
2818
  O.isCancel = pr;
2856
2819
  O.VERSION = dt;
2857
2820
  O.toFormData = Me;
@@ -2860,53 +2823,53 @@ O.Cancel = O.CanceledError;
2860
2823
  O.all = function(e) {
2861
2824
  return Promise.all(e);
2862
2825
  };
2863
- O.spread = Rn;
2864
- O.isAxiosError = Cn;
2865
- O.mergeConfig = ie;
2826
+ O.spread = Cn;
2827
+ O.isAxiosError = Pn;
2828
+ O.mergeConfig = ne;
2866
2829
  O.AxiosHeaders = F;
2867
2830
  O.formToJSON = (r) => fr(c.isHTMLForm(r) ? new FormData(r) : r);
2868
2831
  O.getAdapter = br.getAdapter;
2869
2832
  O.HttpStatusCode = rt;
2870
2833
  O.default = O;
2871
2834
  const {
2872
- Axios: Ri,
2873
- AxiosError: Ci,
2874
- CanceledError: Ai,
2875
- isCancel: Pi,
2876
- CancelToken: Li,
2877
- VERSION: Ti,
2878
- all: ji,
2879
- Cancel: Ni,
2880
- isAxiosError: Di,
2881
- spread: Fi,
2882
- toFormData: zi,
2883
- AxiosHeaders: Ii,
2884
- HttpStatusCode: Ui,
2885
- formToJSON: $i,
2886
- getAdapter: Bi,
2887
- mergeConfig: Mi,
2888
- create: Vi
2889
- } = O, E = (r) => typeof r == "string", ye = () => {
2835
+ Axios: ki,
2836
+ AxiosError: Oi,
2837
+ CanceledError: Ri,
2838
+ isCancel: Ci,
2839
+ CancelToken: Pi,
2840
+ VERSION: Ai,
2841
+ all: Li,
2842
+ Cancel: Ti,
2843
+ isAxiosError: ji,
2844
+ spread: Ni,
2845
+ toFormData: Di,
2846
+ AxiosHeaders: Fi,
2847
+ HttpStatusCode: zi,
2848
+ formToJSON: Ii,
2849
+ getAdapter: Ui,
2850
+ mergeConfig: $i,
2851
+ create: Bi
2852
+ } = O, E = (r) => typeof r == "string", me = () => {
2890
2853
  let r, e;
2891
2854
  const t = new Promise((s, n) => {
2892
2855
  r = s, e = n;
2893
2856
  });
2894
2857
  return t.resolve = r, t.reject = e, t;
2895
- }, At = (r) => r == null ? "" : "" + r, An = (r, e, t) => {
2858
+ }, Pt = (r) => r == null ? "" : "" + r, An = (r, e, t) => {
2896
2859
  r.forEach((s) => {
2897
2860
  e[s] && (t[s] = e[s]);
2898
2861
  });
2899
- }, Pn = /###/g, Pt = (r) => r && r.indexOf("###") > -1 ? r.replace(Pn, ".") : r, Lt = (r) => !r || E(r), _e = (r, e, t) => {
2862
+ }, Ln = /###/g, At = (r) => r && r.indexOf("###") > -1 ? r.replace(Ln, ".") : r, Lt = (r) => !r || E(r), _e = (r, e, t) => {
2900
2863
  const s = E(e) ? e.split(".") : e;
2901
2864
  let n = 0;
2902
2865
  for (; n < s.length - 1; ) {
2903
2866
  if (Lt(r)) return {};
2904
- const i = Pt(s[n]);
2867
+ const i = At(s[n]);
2905
2868
  !r[i] && t && (r[i] = new t()), Object.prototype.hasOwnProperty.call(r, i) ? r = r[i] : r = {}, ++n;
2906
2869
  }
2907
2870
  return Lt(r) ? {} : {
2908
2871
  obj: r,
2909
- k: Pt(s[n])
2872
+ k: At(s[n])
2910
2873
  };
2911
2874
  }, Tt = (r, e, t) => {
2912
2875
  const {
@@ -2921,7 +2884,7 @@ const {
2921
2884
  for (; a.obj === void 0 && o.length; )
2922
2885
  i = `${o[o.length - 1]}.${i}`, o = o.slice(0, o.length - 1), a = _e(r, o, Object), a?.obj && typeof a.obj[`${a.k}.${i}`] < "u" && (a.obj = void 0);
2923
2886
  a.obj[`${a.k}.${i}`] = t;
2924
- }, Ln = (r, e, t, s) => {
2887
+ }, Tn = (r, e, t, s) => {
2925
2888
  const {
2926
2889
  obj: n,
2927
2890
  k: i
@@ -2934,15 +2897,15 @@ const {
2934
2897
  } = _e(r, e);
2935
2898
  if (t && Object.prototype.hasOwnProperty.call(t, s))
2936
2899
  return t[s];
2937
- }, Tn = (r, e, t) => {
2900
+ }, jn = (r, e, t) => {
2938
2901
  const s = De(r, t);
2939
2902
  return s !== void 0 ? s : De(e, t);
2940
2903
  }, vr = (r, e, t) => {
2941
2904
  for (const s in e)
2942
2905
  s !== "__proto__" && s !== "constructor" && (s in r ? E(r[s]) || r[s] instanceof String || E(e[s]) || e[s] instanceof String ? t && (r[s] = e[s]) : vr(r[s], e[s], t) : r[s] = e[s]);
2943
2906
  return r;
2944
- }, ce = (r) => r.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g, "\\$&");
2945
- var jn = {
2907
+ }, ue = (r) => r.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g, "\\$&");
2908
+ var Nn = {
2946
2909
  "&": "&amp;",
2947
2910
  "<": "&lt;",
2948
2911
  ">": "&gt;",
@@ -2950,8 +2913,8 @@ var jn = {
2950
2913
  "'": "&#39;",
2951
2914
  "/": "&#x2F;"
2952
2915
  };
2953
- const Nn = (r) => E(r) ? r.replace(/[&<>"'\/]/g, (e) => jn[e]) : r;
2954
- class Dn {
2916
+ const Dn = (r) => E(r) ? r.replace(/[&<>"'\/]/g, (e) => Nn[e]) : r;
2917
+ class Fn {
2955
2918
  constructor(e) {
2956
2919
  this.capacity = e, this.regExpMap = /* @__PURE__ */ new Map(), this.regExpQueue = [];
2957
2920
  }
@@ -2963,11 +2926,11 @@ class Dn {
2963
2926
  return this.regExpQueue.length === this.capacity && this.regExpMap.delete(this.regExpQueue.shift()), this.regExpMap.set(e, s), this.regExpQueue.push(e), s;
2964
2927
  }
2965
2928
  }
2966
- const Fn = [" ", ",", "?", "!", ";"], zn = new Dn(20), In = (r, e, t) => {
2929
+ const zn = [" ", ",", "?", "!", ";"], In = new Fn(20), Un = (r, e, t) => {
2967
2930
  e = e || "", t = t || "";
2968
- const s = Fn.filter((o) => e.indexOf(o) < 0 && t.indexOf(o) < 0);
2931
+ const s = zn.filter((o) => e.indexOf(o) < 0 && t.indexOf(o) < 0);
2969
2932
  if (s.length === 0) return !0;
2970
- const n = zn.getRegExp(`(${s.map((o) => o === "?" ? "\\?" : o).join("|")})`);
2933
+ const n = In.getRegExp(`(${s.map((o) => o === "?" ? "\\?" : o).join("|")})`);
2971
2934
  let i = !n.test(r);
2972
2935
  if (!i) {
2973
2936
  const o = r.indexOf(t);
@@ -2994,7 +2957,7 @@ const Fn = [" ", ",", "?", "!", ";"], zn = new Dn(20), In = (r, e, t) => {
2994
2957
  n = o;
2995
2958
  }
2996
2959
  return n;
2997
- }, we = (r) => r?.replace("_", "-"), Un = {
2960
+ }, we = (r) => r?.replace("_", "-"), $n = {
2998
2961
  type: "logger",
2999
2962
  log(r) {
3000
2963
  this.output("log", r);
@@ -3014,7 +2977,7 @@ class Fe {
3014
2977
  this.init(e, t);
3015
2978
  }
3016
2979
  init(e, t = {}) {
3017
- this.prefix = t.prefix || "i18next:", this.logger = e || Un, this.options = t, this.debug = t.debug;
2980
+ this.prefix = t.prefix || "i18next:", this.logger = e || $n, this.options = t, this.debug = t.debug;
3018
2981
  }
3019
2982
  log(...e) {
3020
2983
  return this.forward(e, "log", "", !0);
@@ -3153,7 +3116,7 @@ var Sr = {
3153
3116
  }
3154
3117
  };
3155
3118
  const xr = /* @__PURE__ */ Symbol("i18next/PATH_KEY");
3156
- function $n() {
3119
+ function Bn() {
3157
3120
  const r = [], e = /* @__PURE__ */ Object.create(null);
3158
3121
  let t;
3159
3122
  return e.get = (s, n) => (t?.revoke?.(), n === xr ? r : (r.push(n), t = Proxy.revocable(s, e), t.proxy)), Proxy.revocable(/* @__PURE__ */ Object.create(null), e).proxy;
@@ -3161,7 +3124,7 @@ function $n() {
3161
3124
  function nt(r, e) {
3162
3125
  const {
3163
3126
  [xr]: t
3164
- } = r($n());
3127
+ } = r(Bn());
3165
3128
  return t.join(e?.keySeparator ?? ".");
3166
3129
  }
3167
3130
  const Nt = {}, Dt = (r) => !E(r) && typeof r != "boolean" && typeof r != "number";
@@ -3185,7 +3148,7 @@ class ze extends qe {
3185
3148
  s === void 0 && (s = ":");
3186
3149
  const n = t.keySeparator !== void 0 ? t.keySeparator : this.options.keySeparator;
3187
3150
  let i = t.ns || this.options.defaultNS || [];
3188
- const o = s && e.indexOf(s) > -1, a = !this.options.userDefinedKeySeparator && !t.keySeparator && !this.options.userDefinedNsSeparator && !t.nsSeparator && !In(e, s, n);
3151
+ const o = s && e.indexOf(s) > -1, a = !this.options.userDefinedKeySeparator && !t.keySeparator && !this.options.userDefinedNsSeparator && !t.nsSeparator && !Un(e, s, n);
3189
3152
  if (o && !a) {
3190
3153
  const l = e.match(this.interpolator.nestingRegexp);
3191
3154
  if (l && l.length > 0)
@@ -3237,13 +3200,13 @@ class ze extends qe {
3237
3200
  } : a;
3238
3201
  const g = this.resolve(e, n);
3239
3202
  let m = g?.res;
3240
- const y = g?.usedKey || a, h = g?.exactUsedKey || a, b = ["[object Number]", "[object Function]", "[object RegExp]"], v = n.joinArrays !== void 0 ? n.joinArrays : this.options.joinArrays, x = !this.i18nFormat || this.i18nFormat.handleAsObject, S = n.count !== void 0 && !E(n.count), A = ze.hasDefaultValue(n), z = S ? this.pluralResolver.getSuffix(f, n.count, n) : "", B = n.ordinal && S ? this.pluralResolver.getSuffix(f, n.count, {
3203
+ const y = g?.usedKey || a, h = g?.exactUsedKey || a, b = ["[object Number]", "[object Function]", "[object RegExp]"], v = n.joinArrays !== void 0 ? n.joinArrays : this.options.joinArrays, x = !this.i18nFormat || this.i18nFormat.handleAsObject, S = n.count !== void 0 && !E(n.count), P = ze.hasDefaultValue(n), z = S ? this.pluralResolver.getSuffix(f, n.count, n) : "", B = n.ordinal && S ? this.pluralResolver.getSuffix(f, n.count, {
3241
3204
  ordinal: !1
3242
- }) : "", oe = S && !n.ordinal && n.count === 0, H = oe && n[`defaultValue${this.options.pluralSeparator}zero`] || n[`defaultValue${z}`] || n[`defaultValue${B}`] || n.defaultValue;
3205
+ }) : "", ie = S && !n.ordinal && n.count === 0, H = ie && n[`defaultValue${this.options.pluralSeparator}zero`] || n[`defaultValue${z}`] || n[`defaultValue${B}`] || n.defaultValue;
3243
3206
  let L = m;
3244
- x && !m && A && (L = H);
3245
- const X = Dt(L), ae = Object.prototype.toString.apply(L);
3246
- if (x && L && X && b.indexOf(ae) < 0 && !(E(v) && Array.isArray(L))) {
3207
+ x && !m && P && (L = H);
3208
+ const X = Dt(L), oe = Object.prototype.toString.apply(L);
3209
+ if (x && L && X && b.indexOf(oe) < 0 && !(E(v) && Array.isArray(L))) {
3247
3210
  if (!n.returnObjects && !this.options.returnObjects) {
3248
3211
  this.options.returnedObjectHandler || this.logger.warn("accessing an object - but returnObjects options is not enabled!");
3249
3212
  const U = this.options.returnedObjectHandler ? this.options.returnedObjectHandler(y, L, {
@@ -3253,11 +3216,11 @@ class ze extends qe {
3253
3216
  return i ? (g.res = U, g.usedParams = this.getUsedParamsDetails(n), g) : U;
3254
3217
  }
3255
3218
  if (o) {
3256
- const U = Array.isArray(L), R = U ? [] : {}, le = U ? h : y;
3219
+ const U = Array.isArray(L), R = U ? [] : {}, ae = U ? h : y;
3257
3220
  for (const j in L)
3258
3221
  if (Object.prototype.hasOwnProperty.call(L, j)) {
3259
- const K = `${le}${o}${j}`;
3260
- A && !m ? R[j] = this.translate(K, {
3222
+ const K = `${ae}${o}${j}`;
3223
+ P && !m ? R[j] = this.translate(K, {
3261
3224
  ...n,
3262
3225
  defaultValue: Dt(H) ? H[j] : void 0,
3263
3226
  joinArrays: !1,
@@ -3274,30 +3237,30 @@ class ze extends qe {
3274
3237
  m = m.join(v), m && (m = this.extendTranslation(m, e, n, s));
3275
3238
  else {
3276
3239
  let U = !1, R = !1;
3277
- !this.isValidLookup(m) && A && (U = !0, m = H), this.isValidLookup(m) || (R = !0, m = a);
3278
- const j = (n.missingKeyNoValueFallbackToKey || this.options.missingKeyNoValueFallbackToKey) && R ? void 0 : m, K = A && H !== m && this.options.updateMissing;
3240
+ !this.isValidLookup(m) && P && (U = !0, m = H), this.isValidLookup(m) || (R = !0, m = a);
3241
+ const j = (n.missingKeyNoValueFallbackToKey || this.options.missingKeyNoValueFallbackToKey) && R ? void 0 : m, K = P && H !== m && this.options.updateMissing;
3279
3242
  if (R || U || K) {
3280
3243
  if (this.logger.log(K ? "updateKey" : "missingKey", f, d, a, K ? H : m), o) {
3281
- const P = this.resolve(a, {
3244
+ const A = this.resolve(a, {
3282
3245
  ...n,
3283
3246
  keySeparator: !1
3284
3247
  });
3285
- P && P.res && this.logger.warn("Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.");
3248
+ A && A.res && this.logger.warn("Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.");
3286
3249
  }
3287
3250
  let ee = [];
3288
3251
  const $ = this.languageUtils.getFallbackCodes(this.options.fallbackLng, n.lng || this.language);
3289
3252
  if (this.options.saveMissingTo === "fallback" && $ && $[0])
3290
- for (let P = 0; P < $.length; P++)
3291
- ee.push($[P]);
3253
+ for (let A = 0; A < $.length; A++)
3254
+ ee.push($[A]);
3292
3255
  else this.options.saveMissingTo === "all" ? ee = this.languageUtils.toResolveHierarchy(n.lng || this.language) : ee.push(n.lng || this.language);
3293
- const D = (P, G, C) => {
3294
- const W = A && C !== m ? C : j;
3295
- this.options.missingKeyHandler ? this.options.missingKeyHandler(P, d, G, W, K, n) : this.backendConnector?.saveMissing && this.backendConnector.saveMissing(P, d, G, W, K, n), this.emit("missingKey", P, d, G, m);
3256
+ const D = (A, G, C) => {
3257
+ const W = P && C !== m ? C : j;
3258
+ this.options.missingKeyHandler ? this.options.missingKeyHandler(A, d, G, W, K, n) : this.backendConnector?.saveMissing && this.backendConnector.saveMissing(A, d, G, W, K, n), this.emit("missingKey", A, d, G, m);
3296
3259
  };
3297
- this.options.saveMissing && (this.options.saveMissingPlurals && S ? ee.forEach((P) => {
3298
- const G = this.pluralResolver.getSuffixes(P, n);
3299
- oe && n[`defaultValue${this.options.pluralSeparator}zero`] && G.indexOf(`${this.options.pluralSeparator}zero`) < 0 && G.push(`${this.options.pluralSeparator}zero`), G.forEach((C) => {
3300
- D([P], a + C, n[`defaultValue${C}`] || H);
3260
+ this.options.saveMissing && (this.options.saveMissingPlurals && S ? ee.forEach((A) => {
3261
+ const G = this.pluralResolver.getSuffixes(A, n);
3262
+ ie && n[`defaultValue${this.options.pluralSeparator}zero`] && G.indexOf(`${this.options.pluralSeparator}zero`) < 0 && G.push(`${this.options.pluralSeparator}zero`), G.forEach((C) => {
3263
+ D([A], a + C, n[`defaultValue${C}`] || H);
3301
3264
  });
3302
3265
  }) : D(ee, a, H));
3303
3266
  }
@@ -3365,10 +3328,10 @@ class ze extends qe {
3365
3328
  else {
3366
3329
  let S;
3367
3330
  _ && (S = this.pluralResolver.getSuffix(b, t.count, t));
3368
- const A = `${this.options.pluralSeparator}zero`, z = `${this.options.pluralSeparator}ordinal${this.options.pluralSeparator}`;
3369
- if (_ && (t.ordinal && S.indexOf(z) === 0 && v.push(u + S.replace(z, this.options.pluralSeparator)), v.push(u + S), g && v.push(u + A)), m) {
3331
+ const P = `${this.options.pluralSeparator}zero`, z = `${this.options.pluralSeparator}ordinal${this.options.pluralSeparator}`;
3332
+ if (_ && (t.ordinal && S.indexOf(z) === 0 && v.push(u + S.replace(z, this.options.pluralSeparator)), v.push(u + S), g && v.push(u + P)), m) {
3370
3333
  const B = `${u}${this.options.contextSeparator || "_"}${t.context}`;
3371
- v.push(B), _ && (t.ordinal && S.indexOf(z) === 0 && v.push(B + S.replace(z, this.options.pluralSeparator)), v.push(B + S), g && v.push(B + A));
3334
+ v.push(B), _ && (t.ordinal && S.indexOf(z) === 0 && v.push(B + S.replace(z, this.options.pluralSeparator)), v.push(B + S), g && v.push(B + P));
3372
3335
  }
3373
3336
  }
3374
3337
  let x;
@@ -3490,7 +3453,7 @@ const zt = {
3490
3453
  pluralCategories: ["one", "other"]
3491
3454
  })
3492
3455
  };
3493
- class Bn {
3456
+ class Mn {
3494
3457
  constructor(e, t = {}) {
3495
3458
  this.languageUtils = e, this.options = t, this.logger = Y.create("pluralResolver"), this.pluralRulesCache = {};
3496
3459
  }
@@ -3538,10 +3501,10 @@ class Bn {
3538
3501
  }
3539
3502
  }
3540
3503
  const Ut = (r, e, t, s = ".", n = !0) => {
3541
- let i = Tn(r, e, t);
3504
+ let i = jn(r, e, t);
3542
3505
  return !i && n && E(t) && (i = st(r, t, s), i === void 0 && (i = st(e, t, s))), i;
3543
3506
  }, Ze = (r) => r.replace(/\$/g, "$$$$");
3544
- class Mn {
3507
+ class Vn {
3545
3508
  constructor(e = {}) {
3546
3509
  this.logger = Y.create("interpolator"), this.options = e, this.format = e?.interpolation?.format || ((t) => t), this.init(e);
3547
3510
  }
@@ -3568,7 +3531,7 @@ class Mn {
3568
3531
  maxReplaces: b,
3569
3532
  alwaysFormat: v
3570
3533
  } = e.interpolation;
3571
- this.escape = t !== void 0 ? t : Nn, this.escapeValue = s !== void 0 ? s : !0, this.useRawValueToEscape = n !== void 0 ? n : !1, this.prefix = i ? ce(i) : o || "{{", this.suffix = a ? ce(a) : l || "}}", this.formatSeparator = d || ",", this.unescapePrefix = u ? "" : f || "-", this.unescapeSuffix = this.unescapePrefix ? "" : u || "", this.nestingPrefix = _ ? ce(_) : g || ce("$t("), this.nestingSuffix = m ? ce(m) : y || ce(")"), this.nestingOptionsSeparator = h || ",", this.maxReplaces = b || 1e3, this.alwaysFormat = v !== void 0 ? v : !1, this.resetRegExp();
3534
+ this.escape = t !== void 0 ? t : Dn, this.escapeValue = s !== void 0 ? s : !0, this.useRawValueToEscape = n !== void 0 ? n : !1, this.prefix = i ? ue(i) : o || "{{", this.suffix = a ? ue(a) : l || "}}", this.formatSeparator = d || ",", this.unescapePrefix = u ? "" : f || "-", this.unescapeSuffix = this.unescapePrefix ? "" : u || "", this.nestingPrefix = _ ? ue(_) : g || ue("$t("), this.nestingSuffix = m ? ue(m) : y || ue(")"), this.nestingOptionsSeparator = h || ",", this.maxReplaces = b || 1e3, this.alwaysFormat = v !== void 0 ? v : !1, this.resetRegExp();
3572
3535
  }
3573
3536
  reset() {
3574
3537
  this.options && this.init(this.options);
@@ -3617,7 +3580,7 @@ class Mn {
3617
3580
  continue;
3618
3581
  } else
3619
3582
  this.logger.warn(`missed to pass in variable ${m} for interpolating ${e}`), o = "";
3620
- else !E(o) && !this.useRawValueToEscape && (o = At(o));
3583
+ else !E(o) && !this.useRawValueToEscape && (o = Pt(o));
3621
3584
  const y = g.safeValue(o);
3622
3585
  if (e = e.replace(i[0], y), f ? (g.regex.lastIndex += o.length, g.regex.lastIndex -= i[0].length) : g.regex.lastIndex = 0, a++, a >= this.maxReplaces)
3623
3586
  break;
@@ -3651,7 +3614,7 @@ class Mn {
3651
3614
  }, o = o.replace && !E(o.replace) ? o.replace : o, o.applyPostProcessor = !1, delete o.defaultValue;
3652
3615
  const d = /{.*}/.test(n[1]) ? n[1].lastIndexOf("}") + 1 : n[1].indexOf(this.formatSeparator);
3653
3616
  if (d !== -1 && (l = n[1].slice(d).split(this.formatSeparator).map((u) => u.trim()).filter(Boolean), n[1] = n[1].slice(0, d)), i = t(a.call(this, n[1].trim(), o), o), i && n[0] === e && !E(i)) return i;
3654
- E(i) || (i = At(i)), i || (this.logger.warn(`missed to resolve ${n[1]} for nesting ${e}`), i = ""), l.length && (i = l.reduce((u, f) => this.format(u, f, s.lng, {
3617
+ E(i) || (i = Pt(i)), i || (this.logger.warn(`missed to resolve ${n[1]} for nesting ${e}`), i = ""), l.length && (i = l.reduce((u, f) => this.format(u, f, s.lng, {
3655
3618
  ...s,
3656
3619
  interpolationkey: n[1].trim()
3657
3620
  }), i.trim())), e = e.replace(n[0], i), this.regexp.lastIndex = 0;
@@ -3659,7 +3622,7 @@ class Mn {
3659
3622
  return e;
3660
3623
  }
3661
3624
  }
3662
- const Vn = (r) => {
3625
+ const qn = (r) => {
3663
3626
  let e = r.toLowerCase().trim();
3664
3627
  const t = {};
3665
3628
  if (r.indexOf("(") > -1) {
@@ -3689,8 +3652,8 @@ const Vn = (r) => {
3689
3652
  let a = e[o];
3690
3653
  return a || (a = r(we(s), n), e[o] = a), a(t);
3691
3654
  };
3692
- }, qn = (r) => (e, t, s) => r(we(t), s)(e);
3693
- class Hn {
3655
+ }, Hn = (r) => (e, t, s) => r(we(t), s)(e);
3656
+ class Kn {
3694
3657
  constructor(e = {}) {
3695
3658
  this.logger = Y.create("formatter"), this.options = e, this.init(e);
3696
3659
  }
@@ -3698,7 +3661,7 @@ class Hn {
3698
3661
  interpolation: {}
3699
3662
  }) {
3700
3663
  this.formatSeparator = t.interpolation.formatSeparator || ",";
3701
- const s = t.cacheInBuiltFormats ? $t : qn;
3664
+ const s = t.cacheInBuiltFormats ? $t : Hn;
3702
3665
  this.formats = {
3703
3666
  number: s((n, i) => {
3704
3667
  const o = new Intl.NumberFormat(n, {
@@ -3749,7 +3712,7 @@ class Hn {
3749
3712
  const {
3750
3713
  formatName: d,
3751
3714
  formatOptions: u
3752
- } = Vn(l);
3715
+ } = qn(l);
3753
3716
  if (this.formats[d]) {
3754
3717
  let f = a;
3755
3718
  try {
@@ -3769,10 +3732,10 @@ class Hn {
3769
3732
  }, e);
3770
3733
  }
3771
3734
  }
3772
- const Kn = (r, e) => {
3735
+ const Wn = (r, e) => {
3773
3736
  r.pending[e] !== void 0 && (delete r.pending[e], r.pendingCount--);
3774
3737
  };
3775
- class Wn extends qe {
3738
+ class Jn extends qe {
3776
3739
  constructor(e, t, s, n = {}) {
3777
3740
  super(), this.backend = e, this.store = t, this.services = s, this.languageUtils = s.languageUtils, this.options = n, this.logger = Y.create("backendConnector"), this.waitingReads = [], this.maxParallelReads = n.maxParallelReads || 10, this.readingCalls = 0, this.maxRetries = n.maxRetries >= 0 ? n.maxRetries : 5, this.retryTimeout = n.retryTimeout >= 1 ? n.retryTimeout : 350, this.state = {}, this.queue = [], this.backend?.init?.(s, n.backend, n);
3778
3741
  }
@@ -3804,7 +3767,7 @@ class Wn extends qe {
3804
3767
  }), this.state[e] = t ? -1 : 2, t && s && (this.state[e] = 0);
3805
3768
  const a = {};
3806
3769
  this.queue.forEach((l) => {
3807
- Ln(l.loaded, [i], o), Kn(l, e), t && l.errors.push(t), l.pendingCount === 0 && !l.done && (Object.keys(l.loaded).forEach((d) => {
3770
+ Tn(l.loaded, [i], o), Wn(l, e), t && l.errors.push(t), l.pendingCount === 0 && !l.done && (Object.keys(l.loaded).forEach((d) => {
3808
3771
  a[d] || (a[d] = {});
3809
3772
  const u = l.loaded[d];
3810
3773
  u.length && u.forEach((f) => {
@@ -3959,8 +3922,8 @@ const Bt = () => ({
3959
3922
  skipOnVariables: !0
3960
3923
  },
3961
3924
  cacheInBuiltFormats: !0
3962
- }), Mt = (r) => (E(r.ns) && (r.ns = [r.ns]), E(r.fallbackLng) && (r.fallbackLng = [r.fallbackLng]), E(r.fallbackNS) && (r.fallbackNS = [r.fallbackNS]), r.supportedLngs?.indexOf?.("cimode") < 0 && (r.supportedLngs = r.supportedLngs.concat(["cimode"])), typeof r.initImmediate == "boolean" && (r.initAsync = r.initImmediate), r), Pe = () => {
3963
- }, Jn = (r) => {
3925
+ }), Mt = (r) => (E(r.ns) && (r.ns = [r.ns]), E(r.fallbackLng) && (r.fallbackLng = [r.fallbackLng]), E(r.fallbackNS) && (r.fallbackNS = [r.fallbackNS]), r.supportedLngs?.indexOf?.("cimode") < 0 && (r.supportedLngs = r.supportedLngs.concat(["cimode"])), typeof r.initImmediate == "boolean" && (r.initAsync = r.initImmediate), r), Ae = () => {
3926
+ }, Gn = (r) => {
3964
3927
  Object.getOwnPropertyNames(Object.getPrototypeOf(r)).forEach((t) => {
3965
3928
  typeof r[t] == "function" && (r[t] = r[t].bind(r));
3966
3929
  });
@@ -3969,7 +3932,7 @@ class ve extends qe {
3969
3932
  constructor(e = {}, t) {
3970
3933
  if (super(), this.options = Mt(e), this.services = {}, this.logger = Y, this.modules = {
3971
3934
  external: []
3972
- }, Jn(this), t && !this.isInitialized && !e.isClone) {
3935
+ }, Gn(this), t && !this.isInitialized && !e.isClone) {
3973
3936
  if (!this.options.initAsync)
3974
3937
  return this.init(e, t), this;
3975
3938
  setTimeout(() => {
@@ -3992,16 +3955,16 @@ class ve extends qe {
3992
3955
  if (!this.options.isClone) {
3993
3956
  this.modules.logger ? Y.init(n(this.modules.logger), this.options) : Y.init(null, this.options);
3994
3957
  let d;
3995
- this.modules.formatter ? d = this.modules.formatter : d = Hn;
3958
+ this.modules.formatter ? d = this.modules.formatter : d = Kn;
3996
3959
  const u = new Ft(this.options);
3997
3960
  this.store = new jt(this.options.resources, this.options);
3998
3961
  const f = this.services;
3999
- f.logger = Y, f.resourceStore = this.store, f.languageUtils = u, f.pluralResolver = new Bn(u, {
3962
+ f.logger = Y, f.resourceStore = this.store, f.languageUtils = u, f.pluralResolver = new Mn(u, {
4000
3963
  prepend: this.options.pluralSeparator,
4001
3964
  simplifyPluralSuffix: this.options.simplifyPluralSuffix
4002
- }), this.options.interpolation.format && this.options.interpolation.format !== s.interpolation.format && this.logger.deprecate("init: you are still using the legacy format function, please use the new approach: https://www.i18next.com/translation-function/formatting"), d && (!this.options.interpolation.format || this.options.interpolation.format === s.interpolation.format) && (f.formatter = n(d), f.formatter.init && f.formatter.init(f, this.options), this.options.interpolation.format = f.formatter.format.bind(f.formatter)), f.interpolator = new Mn(this.options), f.utils = {
3965
+ }), this.options.interpolation.format && this.options.interpolation.format !== s.interpolation.format && this.logger.deprecate("init: you are still using the legacy format function, please use the new approach: https://www.i18next.com/translation-function/formatting"), d && (!this.options.interpolation.format || this.options.interpolation.format === s.interpolation.format) && (f.formatter = n(d), f.formatter.init && f.formatter.init(f, this.options), this.options.interpolation.format = f.formatter.format.bind(f.formatter)), f.interpolator = new Vn(this.options), f.utils = {
4003
3966
  hasLoadedNamespace: this.hasLoadedNamespace.bind(this)
4004
- }, f.backendConnector = new Wn(n(this.modules.backend), f.resourceStore, f, this.options), f.backendConnector.on("*", (g, ...m) => {
3967
+ }, f.backendConnector = new Jn(n(this.modules.backend), f.resourceStore, f, this.options), f.backendConnector.on("*", (g, ...m) => {
4005
3968
  this.emit(g, ...m);
4006
3969
  }), this.modules.languageDetector && (f.languageDetector = n(this.modules.languageDetector), f.languageDetector.init && f.languageDetector.init(f, this.options.detection, this.options)), this.modules.i18nFormat && (f.i18nFormat = n(this.modules.i18nFormat), f.i18nFormat.init && f.i18nFormat.init(this)), this.translator = new ze(this.services, this.options), this.translator.on("*", (g, ...m) => {
4007
3970
  this.emit(g, ...m);
@@ -4009,7 +3972,7 @@ class ve extends qe {
4009
3972
  g.init && g.init(this);
4010
3973
  });
4011
3974
  }
4012
- if (this.format = this.options.interpolation.format, t || (t = Pe), this.options.fallbackLng && !this.services.languageDetector && !this.options.lng) {
3975
+ if (this.format = this.options.interpolation.format, t || (t = Ae), this.options.fallbackLng && !this.services.languageDetector && !this.options.lng) {
4013
3976
  const d = this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);
4014
3977
  d.length > 0 && d[0] !== "dev" && (this.options.lng = d[0]);
4015
3978
  }
@@ -4018,7 +3981,7 @@ class ve extends qe {
4018
3981
  }), ["addResource", "addResources", "addResourceBundle", "removeResourceBundle"].forEach((d) => {
4019
3982
  this[d] = (...u) => (this.store[d](...u), this);
4020
3983
  });
4021
- const a = ye(), l = () => {
3984
+ const a = me(), l = () => {
4022
3985
  const d = (u, f) => {
4023
3986
  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), a.resolve(f), t(u, f);
4024
3987
  };
@@ -4027,7 +3990,7 @@ class ve extends qe {
4027
3990
  };
4028
3991
  return this.options.resources || !this.options.initAsync ? l() : setTimeout(l, 0), a;
4029
3992
  }
4030
- loadResources(e, t = Pe) {
3993
+ loadResources(e, t = Ae) {
4031
3994
  let s = t;
4032
3995
  const n = E(e) ? e : this.language;
4033
3996
  if (typeof e == "function" && (s = e), !this.options.resources || this.options.partialBundledLanguages) {
@@ -4045,8 +4008,8 @@ class ve extends qe {
4045
4008
  s(null);
4046
4009
  }
4047
4010
  reloadResources(e, t, s) {
4048
- const n = ye();
4049
- return typeof e == "function" && (s = e, e = void 0), typeof t == "function" && (s = t, t = void 0), e || (e = this.languages), t || (t = this.options.ns), s || (s = Pe), this.services.backendConnector.reload(e, t, (i) => {
4011
+ const n = me();
4012
+ return typeof e == "function" && (s = e, e = void 0), typeof t == "function" && (s = t, t = void 0), e || (e = this.languages), t || (t = this.options.ns), s || (s = Ae), this.services.backendConnector.reload(e, t, (i) => {
4050
4013
  n.resolve(), s(i);
4051
4014
  }), n;
4052
4015
  }
@@ -4069,7 +4032,7 @@ class ve extends qe {
4069
4032
  }
4070
4033
  changeLanguage(e, t) {
4071
4034
  this.isLanguageChangingTo = e;
4072
- const s = ye();
4035
+ const s = me();
4073
4036
  this.emit("languageChanging", e);
4074
4037
  const n = (a) => {
4075
4038
  this.language = a, this.languages = this.services.languageUtils.toResolveHierarchy(a), this.resolvedLanguage = void 0, this.setResolvedLanguage(a);
@@ -4129,7 +4092,7 @@ class ve extends qe {
4129
4092
  return !!(this.hasResourceBundle(s, e) || !this.services.backendConnector.backend || this.options.resources && !this.options.partialBundledLanguages || o(s, e) && (!n || o(i, e)));
4130
4093
  }
4131
4094
  loadNamespaces(e, t) {
4132
- const s = ye();
4095
+ const s = me();
4133
4096
  return this.options.ns ? (E(e) && (e = [e]), e.forEach((n) => {
4134
4097
  this.options.ns.indexOf(n) < 0 && this.options.ns.push(n);
4135
4098
  }), this.loadResources((n) => {
@@ -4137,7 +4100,7 @@ class ve extends qe {
4137
4100
  }), s) : (t && t(), Promise.resolve());
4138
4101
  }
4139
4102
  loadLanguages(e, t) {
4140
- const s = ye();
4103
+ const s = me();
4141
4104
  E(e) && (e = [e]);
4142
4105
  const n = this.options.preload || [], i = e.filter((o) => n.indexOf(o) < 0 && this.services.languageUtils.isSupportedCode(o));
4143
4106
  return i.length ? (this.options.preload = n.concat(i), this.loadResources((o) => {
@@ -4160,7 +4123,7 @@ class ve extends qe {
4160
4123
  static createInstance(e = {}, t) {
4161
4124
  return new ve(e, t);
4162
4125
  }
4163
- cloneInstance(e = {}, t = Pe) {
4126
+ cloneInstance(e = {}, t = Ae) {
4164
4127
  const s = e.forkResourceStore;
4165
4128
  s && delete e.forkResourceStore;
4166
4129
  const n = {
@@ -4223,13 +4186,13 @@ await T.init({
4223
4186
  escapeValue: !1
4224
4187
  }
4225
4188
  });
4226
- const Gn = () => ({
4189
+ const Zn = () => ({
4227
4190
  formatMessage: (r, e, t) => T.t(e, { lng: r, ...t }),
4228
4191
  registerTranslations: (r, e, t) => {
4229
4192
  T.addResourceBundle(r, e, t, !0, !0);
4230
4193
  }
4231
4194
  });
4232
- let Zn = class {
4195
+ let Yn = class {
4233
4196
  instance;
4234
4197
  securityData = null;
4235
4198
  securityWorker;
@@ -4300,7 +4263,7 @@ let Zn = class {
4300
4263
  url: t
4301
4264
  });
4302
4265
  };
4303
- }, Yn = class extends Zn {
4266
+ }, Xn = class extends Yn {
4304
4267
  sessions = {
4305
4268
  /**
4306
4269
  * No description
@@ -4399,8 +4362,8 @@ let Zn = class {
4399
4362
  })
4400
4363
  };
4401
4364
  };
4402
- const Xn = ({ baseUrl: r }) => {
4403
- const e = new Yn({
4365
+ const Qn = ({ baseUrl: r }) => {
4366
+ const e = new Xn({
4404
4367
  baseURL: r ? `${r}/delivery/v1` : void 0
4405
4368
  });
4406
4369
  return async (t) => {
@@ -4410,7 +4373,7 @@ const Xn = ({ baseUrl: r }) => {
4410
4373
  return s;
4411
4374
  };
4412
4375
  };
4413
- class Qn {
4376
+ class ei {
4414
4377
  instance;
4415
4378
  securityData = null;
4416
4379
  securityWorker;
@@ -4482,7 +4445,7 @@ class Qn {
4482
4445
  });
4483
4446
  };
4484
4447
  }
4485
- class ct extends Qn {
4448
+ class ct extends ei {
4486
4449
  v1 = {
4487
4450
  /**
4488
4451
  * @description Get the full address details for a prediction. Exchanges a prediction ID (where `action` was `resolve`) for a full, formatted address object that can be used to populate the address form fields. This is the second step of the autocomplete flow — called after the user selects a final address prediction from the autocomplete results.
@@ -4555,7 +4518,7 @@ class ct extends Qn {
4555
4518
  })
4556
4519
  };
4557
4520
  }
4558
- const ei = ({
4521
+ const ti = ({
4559
4522
  baseUrl: r,
4560
4523
  logger: e
4561
4524
  }) => {
@@ -4571,7 +4534,7 @@ const ei = ({
4571
4534
  return e.debug("Validated address successfully", { data: i }), i;
4572
4535
  }
4573
4536
  };
4574
- }, ti = ({
4537
+ }, ri = ({
4575
4538
  baseUrl: r,
4576
4539
  logger: e
4577
4540
  }) => {
@@ -4598,7 +4561,7 @@ const ei = ({
4598
4561
  return e.debug("Converted address suggestion successfully", { data: o }), o;
4599
4562
  }
4600
4563
  };
4601
- }, ri = ({
4564
+ }, si = ({
4602
4565
  baseUrl: r,
4603
4566
  logger: e
4604
4567
  }) => {
@@ -4614,38 +4577,36 @@ const ei = ({
4614
4577
  return e.debug("Got address form config successfully", { data: i }), i;
4615
4578
  }
4616
4579
  };
4617
- }, Ki = (r) => ({ __tag: "withDefaultProvider", factory: r });
4580
+ }, qi = (r) => ({ __tag: "withDefaultProvider", factory: r });
4618
4581
  function V(r, e) {
4619
4582
  return e === void 0 ? r : typeof e == "function" ? e : e.factory(r);
4620
4583
  }
4621
- const si = () => {
4622
- const r = () => {
4623
- throw new Error(
4624
- "Not implemented. Provide custom address book provider to support the address book features."
4625
- );
4626
- };
4584
+ const ni = (r) => {
4585
+ const e = (t) => r.warn(
4586
+ `ContactsService.${t} has no implementation. Provide a custom contacts service to support address book features.`
4587
+ );
4627
4588
  return {
4628
- listContactBookEntries: r,
4629
- getContactBookEntry: r,
4630
- upsertContactBookEntry: r,
4631
- deleteContactBookEntry: r
4589
+ listContactBookEntries: () => (e("listContactBookEntries"), Promise.resolve({ entries: [] })),
4590
+ getContactBookEntry: () => (e("getContactBookEntry"), Promise.resolve({})),
4591
+ upsertContactBookEntry: () => (e("upsertContactBookEntry"), Promise.resolve({})),
4592
+ deleteContactBookEntry: () => (e("deleteContactBookEntry"), Promise.resolve({}))
4632
4593
  };
4633
- }, ni = ({ baseUrl: r }) => async (e) => (await O.get(
4594
+ }, ii = ({ baseUrl: r }) => async (e) => (await O.get(
4634
4595
  `${r}/v1/delivery_tracking/tracking_data.get`,
4635
4596
  {
4636
4597
  params: e
4637
4598
  }
4638
- )).data, ii = (r, e) => {
4639
- const t = si(), s = ti({
4599
+ )).data, oi = (r, e) => {
4600
+ const t = ni(e), s = ri({
4640
4601
  baseUrl: r,
4641
4602
  logger: e
4642
- }), n = ei({ baseUrl: r, logger: e }), i = ri({ baseUrl: r, logger: e }), o = Gn();
4603
+ }), n = ti({ baseUrl: r, logger: e }), i = si({ baseUrl: r, logger: e }), o = Zn();
4643
4604
  return {
4644
4605
  delivery: {
4645
- getSession: Xn({ baseUrl: r })
4606
+ getSession: Qn({ baseUrl: r })
4646
4607
  },
4647
4608
  tracking: {
4648
- getTrackingData: ni({ baseUrl: r })
4609
+ getTrackingData: ii({ baseUrl: r })
4649
4610
  },
4650
4611
  translations: {
4651
4612
  formatMessage: o.formatMessage,
@@ -4662,7 +4623,7 @@ const si = () => {
4662
4623
  getAddressFormConfig: i.getAddressFormConfig
4663
4624
  }
4664
4625
  };
4665
- }, q = (r) => (Object.assign(r, { __type: "internal" }), r), oi = (r, e) => ({
4626
+ }, q = (r) => (Object.assign(r, { __type: "internal" }), r), ai = (r, e) => ({
4666
4627
  delivery: {
4667
4628
  getSession: V(
4668
4629
  q(r.delivery.getSession),
@@ -4725,11 +4686,11 @@ const si = () => {
4725
4686
  return;
4726
4687
  }
4727
4688
  r(...n);
4728
- }, ai = (r = "production") => r === "stage" ? "https://api-stage.ingrid.com" : "https://api.ingrid.com", Ht = (r, e) => {
4689
+ }, li = (r = "production") => r === "stage" ? "https://api-stage.ingrid.com" : "https://api.ingrid.com", Ht = (r, e) => {
4729
4690
  Object.entries(r).forEach(([t, s]) => {
4730
4691
  e.style.setProperty(t, s);
4731
4692
  });
4732
- }, li = () => {
4693
+ }, di = () => {
4733
4694
  const r = document.createElement("link");
4734
4695
  r.rel = "preload", r.href = void 0, r.as = "font", r.type = "font/woff2", r.crossOrigin = "anonymous";
4735
4696
  const e = document.createElement("style");
@@ -4741,7 +4702,7 @@ const si = () => {
4741
4702
  }
4742
4703
  `)
4743
4704
  ), document.head.appendChild(r), document.head.appendChild(e);
4744
- }, di = (r) => r instanceof HTMLElement, ui = ({ logger: r, eventChannel: e, ...t }, s, n, i) => {
4705
+ }, ui = (r) => r instanceof HTMLElement, ci = ({ logger: r, eventChannel: e, ...t }, s, n, i) => {
4745
4706
  if (!n)
4746
4707
  throw r.error("Instance creation failed: compoundInitUrl is empty"), new Error("compoundInitUrl cannot be empty");
4747
4708
  let o = null;
@@ -4783,7 +4744,7 @@ const si = () => {
4783
4744
  const v = document.querySelector(g);
4784
4745
  if (!v)
4785
4746
  throw r.error("Mount failed: container not found", { containerSelector: g }), new Error("Container couldn't be found!");
4786
- if (!di(v))
4747
+ if (!ui(v))
4787
4748
  throw r.error("Mount failed: container is not valid HTMLElement", {
4788
4749
  containerSelector: g
4789
4750
  }), new Error("Container is not valid HTMLElement");
@@ -4826,7 +4787,7 @@ const si = () => {
4826
4787
  update: qt(f, a, r),
4827
4788
  on: e.on
4828
4789
  };
4829
- }, ci = () => {
4790
+ }, fi = () => {
4830
4791
  const r = {};
4831
4792
  return {
4832
4793
  emit: (e, ...t) => {
@@ -4838,7 +4799,7 @@ const si = () => {
4838
4799
  r[e].clear();
4839
4800
  }
4840
4801
  };
4841
- }, he = {
4802
+ }, pe = {
4842
4803
  address: {
4843
4804
  status: "inactive",
4844
4805
  mode: "addressForm",
@@ -4863,12 +4824,12 @@ const si = () => {
4863
4824
  tracking: {
4864
4825
  status: "inactive"
4865
4826
  }
4866
- }, Kt = te(he.address), Wt = te(
4867
- he.countrySelector
4827
+ }, Kt = te(pe.address), Wt = te(
4828
+ pe.countrySelector
4868
4829
  ), Jt = te(
4869
- he.freeShippingIndicator
4870
- ), Gt = te(he.delivery), Zt = te(he.tracking), be = (r) => {
4871
- const e = r.type, t = he[e], s = { status: "active" };
4830
+ pe.freeShippingIndicator
4831
+ ), Gt = te(pe.delivery), Zt = te(pe.tracking), ye = (r) => {
4832
+ const e = r.type, t = pe[e], s = { status: "active" };
4872
4833
  switch (r.type) {
4873
4834
  case "address":
4874
4835
  return {
@@ -4891,23 +4852,23 @@ const si = () => {
4891
4852
  default:
4892
4853
  throw new Error("Unrecognized molecule");
4893
4854
  }
4894
- }, fi = (r, e) => {
4855
+ }, pi = (r, e) => {
4895
4856
  for (const t of r)
4896
4857
  switch (t.type) {
4897
4858
  case "address":
4898
- e.set(Kt, be(t));
4859
+ e.set(Kt, ye(t));
4899
4860
  break;
4900
4861
  case "countrySelector":
4901
- e.set(Wt, be(t));
4862
+ e.set(Wt, ye(t));
4902
4863
  break;
4903
4864
  case "delivery":
4904
- e.set(Gt, be(t));
4865
+ e.set(Gt, ye(t));
4905
4866
  break;
4906
4867
  case "freeShippingIndicator":
4907
- e.set(Jt, be(t));
4868
+ e.set(Jt, ye(t));
4908
4869
  break;
4909
4870
  case "tracking":
4910
- e.set(Zt, be(t));
4871
+ e.set(Zt, ye(t));
4911
4872
  break;
4912
4873
  default:
4913
4874
  throw new Error("Unrecognized molecule");
@@ -4919,7 +4880,7 @@ const si = () => {
4919
4880
  freeShippingIndicator: Jt,
4920
4881
  tracking: Zt
4921
4882
  };
4922
- }, pi = {
4883
+ }, hi = {
4923
4884
  lastTime: null,
4924
4885
  log(r) {
4925
4886
  const e = this.lastTime ? r.timestamp - this.lastTime : 0, s = `${r.namespace ? `[${r.namespace}]` : ""} [${r.level}]`, n = r.messageArgs ?? [];
@@ -4929,7 +4890,7 @@ const si = () => {
4929
4890
  "color: #888"
4930
4891
  ), this.lastTime = r.timestamp;
4931
4892
  }
4932
- }, hi = (r) => r instanceof Error ? {
4893
+ }, gi = (r) => r instanceof Error ? {
4933
4894
  message: r.stack ?? r.message ?? String(r),
4934
4895
  error: r
4935
4896
  } : { message: String(r) }, Er = (r) => {
@@ -4940,7 +4901,7 @@ const si = () => {
4940
4901
  level: s,
4941
4902
  namespace: r.namespace,
4942
4903
  timestamp: Date.now(),
4943
- ...hi(n),
4904
+ ...gi(n),
4944
4905
  messageArgs: i
4945
4906
  };
4946
4907
  for (const [a, l] of r.transports.entries())
@@ -4960,17 +4921,17 @@ const si = () => {
4960
4921
  namespace: r.namespace ? `${r.namespace}:${s}` : s
4961
4922
  })
4962
4923
  };
4963
- }, gi = new Xt({
4924
+ }, mi = new Xt({
4964
4925
  defaultOptions: {
4965
4926
  queries: {
4966
4927
  refetchOnWindowFocus: !1
4967
4928
  }
4968
4929
  }
4969
- }), Yt = "en-US", re = Er({
4930
+ }), Yt = "en-US", be = Er({
4970
4931
  level: "debug",
4971
4932
  namespace: "experience-kit",
4972
- transports: [pi]
4973
- }), Wi = {
4933
+ transports: [hi]
4934
+ }), Hi = {
4974
4935
  /**
4975
4936
  * Initializes the Ingrid Experience Kit.
4976
4937
  *
@@ -4982,25 +4943,26 @@ const si = () => {
4982
4943
  *
4983
4944
  * @public
4984
4945
  */
4985
- init: mi
4946
+ init: yi
4986
4947
  };
4987
- async function mi(r) {
4988
- r.token || re.error("Token is not provided"), r.siteId || re.error("SiteId is not provided");
4989
- const e = Fr(r.env ?? "production"), t = await Ir({
4948
+ async function yi(r) {
4949
+ if (!r.siteId)
4950
+ throw new Error("[Experience Kit] siteId is required");
4951
+ const e = zr(r.env ?? "production"), t = await Ur({
4990
4952
  moleculesUrl: e,
4991
- logger: re
4953
+ logger: be
4992
4954
  });
4993
4955
  if (!t)
4994
- throw re.error("Failed to fetch release index, aborting initialization"), new Error("[Experience Kit][FATAL] Failed to fetch release index");
4956
+ throw be.error("Failed to fetch release index, aborting initialization"), new Error("[Experience Kit][FATAL] Failed to fetch release index");
4995
4957
  const s = await jr({
4996
4958
  token: r.token,
4997
- initUrl: `${e}/${t.versions.latest}/init.js`,
4959
+ initUrl: `${e}/${Dr(t)}/init.js`,
4998
4960
  siteId: r.siteId
4999
4961
  });
5000
- li();
5001
- const n = ai(r.env), i = Or(), o = ci(), a = fi(r.molecules, i), l = te(r.locale), d = te(r.countryCode), u = te(r.currency), f = ii(n, re), _ = i.get(l), g = await Nr(_), m = {
5002
- queryClient: { ref: gi }
5003
- }, y = oi(f, r.dataProviders?.services ?? {});
4962
+ di();
4963
+ const n = li(r.env), i = Or(), o = fi(), a = pi(r.molecules, i), l = te(r.locale), d = te(r.countryCode), u = te(r.currency), f = oi(n, be), _ = i.get(l), g = await Nr(_), m = {
4964
+ queryClient: { ref: mi }
4965
+ }, y = ai(f, r.dataProviders?.services ?? {});
5004
4966
  y.translations.registerTranslations(_, "default", g);
5005
4967
  const h = {
5006
4968
  token: r.token,
@@ -5008,7 +4970,7 @@ async function mi(r) {
5008
4970
  queryClient: m.queryClient,
5009
4971
  providers: y,
5010
4972
  refreshToken: r.refreshToken,
5011
- logger: re,
4973
+ logger: be,
5012
4974
  state: {
5013
4975
  store: i,
5014
4976
  atoms: {
@@ -5021,9 +4983,9 @@ async function mi(r) {
5021
4983
  eventChannel: o
5022
4984
  };
5023
4985
  return {
5024
- compound: ui(h, r.molecules, s.initUrl, r.styles),
4986
+ compound: ci(h, r.molecules, s.initUrl, r.styles),
5025
4987
  setLocale: (b) => {
5026
- Ye.includes(b) || (re.warn(`Locale ${b} is not supported. Fallbacks to ${Yt}`), b = Yt), i.set(l, b);
4988
+ Ye.includes(b) || (be.warn(`Locale ${b} is not supported. Fallbacks to ${Yt}`), b = Yt), i.set(l, b);
5027
4989
  },
5028
4990
  setPurchaseCountry: (b) => {
5029
4991
  i.set(d, b);
@@ -5035,10 +4997,7 @@ async function mi(r) {
5035
4997
  };
5036
4998
  }
5037
4999
  export {
5038
- wi as createAddressMolecule,
5039
- vi as createCountrySelectorMolecule,
5040
- Si as createDeliveryMolecule,
5041
- xi as createFreeShippingIndicatorMolecule,
5042
- Wi as default,
5043
- Ki as withDefaultProvider
5000
+ vi as createAddressMolecule,
5001
+ Hi as default,
5002
+ qi as withDefaultProvider
5044
5003
  };