@ogcio/design-system-react 1.26.0 → 1.28.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.
Files changed (34) hide show
  1. package/README.md +27 -11
  2. package/dist/autocomplete/use-autocomplete-controller.js +1 -1
  3. package/dist/browser-support/browser-support.js +1 -1
  4. package/dist/character-count/character-count.d.ts +6 -0
  5. package/dist/character-count/character-count.js +23 -0
  6. package/dist/character-count/types.d.ts +10 -0
  7. package/dist/character-count/types.js +1 -0
  8. package/dist/data-table/editable-table-cell.js +1 -1
  9. package/dist/forms/form-field/form-field.js +1 -1
  10. package/dist/forms/form-field-with-tag/form-field-with-tag.js +1 -1
  11. package/dist/header/header-next/components/menu/components/header-menu-item-button.js +1 -1
  12. package/dist/header/header-next/components/menu/components/header-menu-item-link.js +1 -1
  13. package/dist/hooks/use-focus-trap.js +574 -416
  14. package/dist/i18n/config.js +2 -2
  15. package/dist/i18n/utility.js +1 -1
  16. package/dist/{i18nInstance-D_96ADqd.js → i18nInstance-AYICsHJu.js} +8 -6
  17. package/dist/{i18next-B_GQfCrJ.js → i18next-Bfi2-LyH.js} +125 -117
  18. package/dist/index-D_wwt4P0.js +87 -0
  19. package/dist/index.d.ts +7 -1
  20. package/dist/index.js +232 -229
  21. package/dist/link/link.js +33 -33
  22. package/dist/load-symbols/load-symbols.d.ts +7 -0
  23. package/dist/{load-fonts/load-fonts.js → load-symbols/load-symbols.js} +7 -13
  24. package/dist/{lodash-LsP9-6SV.js → lodash-82PmXrjJ.js} +16 -16
  25. package/dist/pagination/pagination.js +249 -221
  26. package/dist/primitives/anchor.js +1 -1
  27. package/dist/styles.css +1 -1
  28. package/dist/textarea/textarea.d.ts +6 -0
  29. package/dist/textarea/textarea.js +33 -33
  30. package/dist/useTranslation-DiBQuy8S.js +268 -0
  31. package/package.json +2 -2
  32. package/dist/index-2sRBqKFV.js +0 -78
  33. package/dist/load-fonts/load-fonts.d.ts +0 -40
  34. package/dist/useTranslation-BmIU4GBA.js +0 -272
@@ -4,23 +4,23 @@ const g = (o) => typeof o == "string", K = () => {
4
4
  o = i, e = s;
5
5
  });
6
6
  return t.resolve = o, t.reject = e, t;
7
- }, ie = (o) => o == null ? "" : "" + o, be = (o, e, t) => {
7
+ }, ne = (o) => o == null ? "" : "" + o, Le = (o, e, t) => {
8
8
  o.forEach((i) => {
9
9
  e[i] && (t[i] = e[i]);
10
10
  });
11
- }, Le = /###/g, ne = (o) => o && o.indexOf("###") > -1 ? o.replace(Le, ".") : o, re = (o) => !o || g(o), A = (o, e, t) => {
11
+ }, we = /###/g, re = (o) => o && o.indexOf("###") > -1 ? o.replace(we, ".") : o, ae = (o) => !o || g(o), A = (o, e, t) => {
12
12
  const i = g(e) ? e.split(".") : e;
13
13
  let s = 0;
14
14
  for (; s < i.length - 1; ) {
15
- if (re(o)) return {};
16
- const n = ne(i[s]);
15
+ if (ae(o)) return {};
16
+ const n = re(i[s]);
17
17
  !o[n] && t && (o[n] = new t()), Object.prototype.hasOwnProperty.call(o, n) ? o = o[n] : o = {}, ++s;
18
18
  }
19
- return re(o) ? {} : {
19
+ return ae(o) ? {} : {
20
20
  obj: o,
21
- k: ne(i[s])
21
+ k: re(i[s])
22
22
  };
23
- }, ae = (o, e, t) => {
23
+ }, oe = (o, e, t) => {
24
24
  const {
25
25
  obj: i,
26
26
  k: s
@@ -33,7 +33,7 @@ const g = (o) => typeof o == "string", K = () => {
33
33
  for (; a.obj === void 0 && r.length; )
34
34
  n = `${r[r.length - 1]}.${n}`, r = r.slice(0, r.length - 1), a = A(o, r, Object), a != null && a.obj && typeof a.obj[`${a.k}.${n}`] < "u" && (a.obj = void 0);
35
35
  a.obj[`${a.k}.${n}`] = t;
36
- }, we = (o, e, t, i) => {
36
+ }, ve = (o, e, t, i) => {
37
37
  const {
38
38
  obj: s,
39
39
  k: n
@@ -49,12 +49,12 @@ const g = (o) => typeof o == "string", K = () => {
49
49
  }, Ce = (o, e, t) => {
50
50
  const i = J(o, t);
51
51
  return i !== void 0 ? i : J(e, t);
52
- }, me = (o, e, t) => {
52
+ }, xe = (o, e, t) => {
53
53
  for (const i in e)
54
- i !== "__proto__" && i !== "constructor" && (i in o ? g(o[i]) || o[i] instanceof String || g(e[i]) || e[i] instanceof String ? t && (o[i] = e[i]) : me(o[i], e[i], t) : o[i] = e[i]);
54
+ i !== "__proto__" && i !== "constructor" && (i in o ? g(o[i]) || o[i] instanceof String || g(e[i]) || e[i] instanceof String ? t && (o[i] = e[i]) : xe(o[i], e[i], t) : o[i] = e[i]);
55
55
  return o;
56
56
  }, I = (o) => o.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g, "\\$&");
57
- var ve = {
57
+ var Pe = {
58
58
  "&": "&amp;",
59
59
  "<": "&lt;",
60
60
  ">": "&gt;",
@@ -62,8 +62,8 @@ var ve = {
62
62
  "'": "&#39;",
63
63
  "/": "&#x2F;"
64
64
  };
65
- const Re = (o) => g(o) ? o.replace(/[&<>"'\/]/g, (e) => ve[e]) : o;
66
- class Pe {
65
+ const Re = (o) => g(o) ? o.replace(/[&<>"'\/]/g, (e) => Pe[e]) : o;
66
+ class $e {
67
67
  constructor(e) {
68
68
  this.capacity = e, this.regExpMap = /* @__PURE__ */ new Map(), this.regExpQueue = [];
69
69
  }
@@ -75,18 +75,18 @@ class Pe {
75
75
  return this.regExpQueue.length === this.capacity && this.regExpMap.delete(this.regExpQueue.shift()), this.regExpMap.set(e, i), this.regExpQueue.push(e), i;
76
76
  }
77
77
  }
78
- const $e = [" ", ",", "?", "!", ";"], Ne = new Pe(20), ke = (o, e, t) => {
78
+ const Ne = [" ", ",", "?", "!", ";"], ke = new $e(20), Fe = (o, e, t) => {
79
79
  e = e || "", t = t || "";
80
- const i = $e.filter((r) => e.indexOf(r) < 0 && t.indexOf(r) < 0);
80
+ const i = Ne.filter((r) => e.indexOf(r) < 0 && t.indexOf(r) < 0);
81
81
  if (i.length === 0) return !0;
82
- const s = Ne.getRegExp(`(${i.map((r) => r === "?" ? "\\?" : r).join("|")})`);
82
+ const s = ke.getRegExp(`(${i.map((r) => r === "?" ? "\\?" : r).join("|")})`);
83
83
  let n = !s.test(o);
84
84
  if (!n) {
85
85
  const r = o.indexOf(t);
86
86
  r > 0 && !s.test(o.substring(0, r)) && (n = !0);
87
87
  }
88
88
  return n;
89
- }, Z = (o, e, t = ".") => {
89
+ }, X = (o, e, t = ".") => {
90
90
  if (!o) return;
91
91
  if (o[e])
92
92
  return Object.prototype.hasOwnProperty.call(o, e) ? o[e] : void 0;
@@ -106,7 +106,7 @@ const $e = [" ", ",", "?", "!", ";"], Ne = new Pe(20), ke = (o, e, t) => {
106
106
  s = r;
107
107
  }
108
108
  return s;
109
- }, M = (o) => o == null ? void 0 : o.replace("_", "-"), Fe = {
109
+ }, H = (o) => o == null ? void 0 : o.replace("_", "-"), je = {
110
110
  type: "logger",
111
111
  log(o) {
112
112
  this.output("log", o);
@@ -127,7 +127,7 @@ class W {
127
127
  this.init(e, t);
128
128
  }
129
129
  init(e, t = {}) {
130
- this.prefix = t.prefix || "i18next:", this.logger = e || Fe, this.options = t, this.debug = t.debug;
130
+ this.prefix = t.prefix || "i18next:", this.logger = e || je, this.options = t, this.debug = t.debug;
131
131
  }
132
132
  log(...e) {
133
133
  return this.forward(e, "log", "", !0);
@@ -185,7 +185,7 @@ class _ {
185
185
  });
186
186
  }
187
187
  }
188
- class oe extends _ {
188
+ class le extends _ {
189
189
  constructor(e, t = {
190
190
  ns: ["translation"],
191
191
  defaultNS: "translation"
@@ -205,14 +205,14 @@ class oe extends _ {
205
205
  let a;
206
206
  e.indexOf(".") > -1 ? a = e.split(".") : (a = [e, t], i && (Array.isArray(i) ? a.push(...i) : g(i) && n ? a.push(...i.split(n)) : a.push(i)));
207
207
  const u = J(this.data, a);
208
- return !u && !t && !i && e.indexOf(".") > -1 && (e = a[0], t = a[1], i = a.slice(2).join(".")), u || !r || !g(i) ? u : Z((h = (l = this.data) == null ? void 0 : l[e]) == null ? void 0 : h[t], i, n);
208
+ return !u && !t && !i && e.indexOf(".") > -1 && (e = a[0], t = a[1], i = a.slice(2).join(".")), u || !r || !g(i) ? u : X((h = (l = this.data) == null ? void 0 : l[e]) == null ? void 0 : h[t], i, n);
209
209
  }
210
210
  addResource(e, t, i, s, n = {
211
211
  silent: !1
212
212
  }) {
213
213
  const r = n.keySeparator !== void 0 ? n.keySeparator : this.options.keySeparator;
214
214
  let a = [e, t];
215
- i && (a = a.concat(r ? i.split(r) : i)), e.indexOf(".") > -1 && (a = e.split("."), s = t, t = a[1]), this.addNamespaces(t), ae(this.data, a, s), n.silent || this.emit("added", e, t, i, s);
215
+ i && (a = a.concat(r ? i.split(r) : i)), e.indexOf(".") > -1 && (a = e.split("."), s = t, t = a[1]), this.addNamespaces(t), oe(this.data, a, s), n.silent || this.emit("added", e, t, i, s);
216
216
  }
217
217
  addResources(e, t, i, s = {
218
218
  silent: !1
@@ -230,10 +230,10 @@ class oe extends _ {
230
230
  let a = [e, t];
231
231
  e.indexOf(".") > -1 && (a = e.split("."), s = i, i = t, t = a[1]), this.addNamespaces(t);
232
232
  let u = J(this.data, a) || {};
233
- r.skipCopy || (i = JSON.parse(JSON.stringify(i))), s ? me(u, i, n) : u = {
233
+ r.skipCopy || (i = JSON.parse(JSON.stringify(i))), s ? xe(u, i, n) : u = {
234
234
  ...u,
235
235
  ...i
236
- }, ae(this.data, a, u), r.silent || this.emit("added", e, t, i);
236
+ }, oe(this.data, a, u), r.silent || this.emit("added", e, t, i);
237
237
  }
238
238
  removeResourceBundle(e, t) {
239
239
  this.hasResourceBundle(e, t) && delete this.data[e][t], this.removeNamespaces(t), this.emit("removed", e, t);
@@ -255,7 +255,7 @@ class oe extends _ {
255
255
  return this.data;
256
256
  }
257
257
  }
258
- var xe = {
258
+ var ye = {
259
259
  processors: {},
260
260
  addPostProcessor(o) {
261
261
  this.processors[o.name] = o;
@@ -267,25 +267,25 @@ var xe = {
267
267
  }), e;
268
268
  }
269
269
  };
270
- const ye = Symbol("i18next/PATH_KEY");
271
- function je() {
270
+ const Se = Symbol("i18next/PATH_KEY");
271
+ function Ee() {
272
272
  const o = [], e = /* @__PURE__ */ Object.create(null);
273
273
  let t;
274
274
  return e.get = (i, s) => {
275
275
  var n;
276
- return (n = t == null ? void 0 : t.revoke) == null || n.call(t), s === ye ? o : (o.push(s), t = Proxy.revocable(i, e), t.proxy);
276
+ return (n = t == null ? void 0 : t.revoke) == null || n.call(t), s === Se ? o : (o.push(s), t = Proxy.revocable(i, e), t.proxy);
277
277
  }, Proxy.revocable(/* @__PURE__ */ Object.create(null), e).proxy;
278
278
  }
279
- function X(o, e) {
279
+ function q(o, e) {
280
280
  const {
281
- [ye]: t
282
- } = o(je());
281
+ [Se]: t
282
+ } = o(Ee());
283
283
  return t.join((e == null ? void 0 : e.keySeparator) ?? ".");
284
284
  }
285
- const le = {}, Q = (o) => !g(o) && typeof o != "boolean" && typeof o != "number";
285
+ const ue = {}, Q = (o) => !g(o) && typeof o != "boolean" && typeof o != "number";
286
286
  class Y extends _ {
287
287
  constructor(e, t = {}) {
288
- super(), be(["resourceStore", "languageUtils", "pluralResolver", "interpolator", "backendConnector", "i18nFormat", "utils"], e, this), this.options = t, this.options.keySeparator === void 0 && (this.options.keySeparator = "."), this.logger = $.create("translator");
288
+ super(), Le(["resourceStore", "languageUtils", "pluralResolver", "interpolator", "backendConnector", "i18nFormat", "utils"], e, this), this.options = t, this.options.keySeparator === void 0 && (this.options.keySeparator = "."), this.logger = $.create("translator");
289
289
  }
290
290
  changeLanguage(e) {
291
291
  e && (this.language = e);
@@ -307,7 +307,7 @@ class Y extends _ {
307
307
  i === void 0 && (i = ":");
308
308
  const s = t.keySeparator !== void 0 ? t.keySeparator : this.options.keySeparator;
309
309
  let n = t.ns || this.options.defaultNS || [];
310
- const r = i && e.indexOf(i) > -1, a = !this.options.userDefinedKeySeparator && !t.keySeparator && !this.options.userDefinedNsSeparator && !t.nsSeparator && !ke(e, i, s);
310
+ const r = i && e.indexOf(i) > -1, a = !this.options.userDefinedKeySeparator && !t.keySeparator && !this.options.userDefinedNsSeparator && !t.nsSeparator && !Fe(e, i, s);
311
311
  if (r && !a) {
312
312
  const u = e.match(this.interpolator.nestingRegexp);
313
313
  if (u && u.length > 0)
@@ -330,7 +330,7 @@ class Y extends _ {
330
330
  if (typeof s != "object" && this.options.overloadTranslationOptionHandler && (s = this.options.overloadTranslationOptionHandler(arguments)), typeof s == "object" && (s = {
331
331
  ...s
332
332
  }), s || (s = {}), e == null) return "";
333
- typeof e == "function" && (e = X(e, {
333
+ typeof e == "function" && (e = q(e, {
334
334
  ...this.options,
335
335
  ...s
336
336
  })), Array.isArray(e) || (e = [String(e)]);
@@ -359,46 +359,46 @@ class Y extends _ {
359
359
  } : a;
360
360
  const d = this.resolve(e, s);
361
361
  let c = d == null ? void 0 : d.res;
362
- const m = (d == null ? void 0 : d.usedKey) || a, x = (d == null ? void 0 : d.exactUsedKey) || a, C = ["[object Number]", "[object Function]", "[object RegExp]"], w = s.joinArrays !== void 0 ? s.joinArrays : this.options.joinArrays, j = !this.i18nFormat || this.i18nFormat.handleAsObject, S = s.count !== void 0 && !g(s.count), N = Y.hasDefaultValue(s), H = S ? this.pluralResolver.getSuffix(f, s.count, s) : "", k = s.ordinal && S ? this.pluralResolver.getSuffix(f, s.count, {
362
+ const m = (d == null ? void 0 : d.usedKey) || a, x = (d == null ? void 0 : d.exactUsedKey) || a, v = ["[object Number]", "[object Function]", "[object RegExp]"], w = s.joinArrays !== void 0 ? s.joinArrays : this.options.joinArrays, j = !this.i18nFormat || this.i18nFormat.handleAsObject, S = s.count !== void 0 && !g(s.count), N = Y.hasDefaultValue(s), M = S ? this.pluralResolver.getSuffix(f, s.count, s) : "", k = s.ordinal && S ? this.pluralResolver.getSuffix(f, s.count, {
363
363
  ordinal: !1
364
- }) : "", T = S && !s.ordinal && s.count === 0, b = T && s[`defaultValue${this.options.pluralSeparator}zero`] || s[`defaultValue${H}`] || s[`defaultValue${k}`] || s.defaultValue;
364
+ }) : "", T = S && !s.ordinal && s.count === 0, b = T && s[`defaultValue${this.options.pluralSeparator}zero`] || s[`defaultValue${M}`] || s[`defaultValue${k}`] || s.defaultValue;
365
365
  let y = c;
366
366
  j && !c && N && (y = b);
367
- const Se = Q(y), Oe = Object.prototype.toString.apply(y);
368
- if (j && y && Se && C.indexOf(Oe) < 0 && !(g(w) && Array.isArray(y))) {
367
+ const Oe = Q(y), be = Object.prototype.toString.apply(y);
368
+ if (j && y && Oe && v.indexOf(be) < 0 && !(g(w) && Array.isArray(y))) {
369
369
  if (!s.returnObjects && !this.options.returnObjects) {
370
370
  this.options.returnedObjectHandler || this.logger.warn("accessing an object - but returnObjects options is not enabled!");
371
- const R = this.options.returnedObjectHandler ? this.options.returnedObjectHandler(m, y, {
371
+ const P = this.options.returnedObjectHandler ? this.options.returnedObjectHandler(m, y, {
372
372
  ...s,
373
373
  ns: u
374
374
  }) : `key '${a} (${this.language})' returned an object instead of string.`;
375
- return n ? (d.res = R, d.usedParams = this.getUsedParamsDetails(s), d) : R;
375
+ return n ? (d.res = P, d.usedParams = this.getUsedParamsDetails(s), d) : P;
376
376
  }
377
377
  if (r) {
378
- const R = Array.isArray(y), v = R ? [] : {}, q = R ? x : m;
379
- for (const P in y)
380
- if (Object.prototype.hasOwnProperty.call(y, P)) {
381
- const F = `${q}${r}${P}`;
382
- N && !c ? v[P] = this.translate(F, {
378
+ const P = Array.isArray(y), C = P ? [] : {}, ee = P ? x : m;
379
+ for (const R in y)
380
+ if (Object.prototype.hasOwnProperty.call(y, R)) {
381
+ const F = `${ee}${r}${R}`;
382
+ N && !c ? C[R] = this.translate(F, {
383
383
  ...s,
384
- defaultValue: Q(b) ? b[P] : void 0,
384
+ defaultValue: Q(b) ? b[R] : void 0,
385
385
  joinArrays: !1,
386
386
  ns: u
387
- }) : v[P] = this.translate(F, {
387
+ }) : C[R] = this.translate(F, {
388
388
  ...s,
389
389
  joinArrays: !1,
390
390
  ns: u
391
- }), v[P] === F && (v[P] = y[P]);
391
+ }), C[R] === F && (C[R] = y[R]);
392
392
  }
393
- c = v;
393
+ c = C;
394
394
  }
395
395
  } else if (j && g(w) && Array.isArray(c))
396
396
  c = c.join(w), c && (c = this.extendTranslation(c, e, s, i));
397
397
  else {
398
- let R = !1, v = !1;
399
- !this.isValidLookup(c) && N && (R = !0, c = b), this.isValidLookup(c) || (v = !0, c = a);
400
- const P = (s.missingKeyNoValueFallbackToKey || this.options.missingKeyNoValueFallbackToKey) && v ? void 0 : c, F = N && b !== c && this.options.updateMissing;
401
- if (v || R || F) {
398
+ let P = !1, C = !1;
399
+ !this.isValidLookup(c) && N && (P = !0, c = b), this.isValidLookup(c) || (C = !0, c = a);
400
+ const R = (s.missingKeyNoValueFallbackToKey || this.options.missingKeyNoValueFallbackToKey) && C ? void 0 : c, F = N && b !== c && this.options.updateMissing;
401
+ if (C || P || F) {
402
402
  if (this.logger.log(F ? "updateKey" : "missingKey", f, l, a, F ? b : c), r) {
403
403
  const L = this.resolve(a, {
404
404
  ...s,
@@ -412,19 +412,19 @@ class Y extends _ {
412
412
  for (let L = 0; L < B.length; L++)
413
413
  D.push(B[L]);
414
414
  else this.options.saveMissingTo === "all" ? D = this.languageUtils.toResolveHierarchy(s.lng || this.language) : D.push(s.lng || this.language);
415
- const ee = (L, E, V) => {
416
- var se;
417
- const te = N && V !== c ? V : P;
418
- this.options.missingKeyHandler ? this.options.missingKeyHandler(L, l, E, te, F, s) : (se = this.backendConnector) != null && se.saveMissing && this.backendConnector.saveMissing(L, l, E, te, F, s), this.emit("missingKey", L, l, E, c);
415
+ const te = (L, E, V) => {
416
+ var ie;
417
+ const se = N && V !== c ? V : R;
418
+ this.options.missingKeyHandler ? this.options.missingKeyHandler(L, l, E, se, F, s) : (ie = this.backendConnector) != null && ie.saveMissing && this.backendConnector.saveMissing(L, l, E, se, F, s), this.emit("missingKey", L, l, E, c);
419
419
  };
420
420
  this.options.saveMissing && (this.options.saveMissingPlurals && S ? D.forEach((L) => {
421
421
  const E = this.pluralResolver.getSuffixes(L, s);
422
422
  T && s[`defaultValue${this.options.pluralSeparator}zero`] && E.indexOf(`${this.options.pluralSeparator}zero`) < 0 && E.push(`${this.options.pluralSeparator}zero`), E.forEach((V) => {
423
- ee([L], a + V, s[`defaultValue${V}`] || b);
423
+ te([L], a + V, s[`defaultValue${V}`] || b);
424
424
  });
425
- }) : ee(D, a, b));
425
+ }) : te(D, a, b));
426
426
  }
427
- c = this.extendTranslation(c, e, s, d, i), v && c === a && this.options.appendNamespaceToMissingKey && (c = `${l}${h}${a}`), (v || R) && this.options.parseMissingKeyHandler && (c = this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey ? `${l}${h}${a}` : a, R ? c : void 0, s));
427
+ c = this.extendTranslation(c, e, s, d, i), C && c === a && this.options.appendNamespaceToMissingKey && (c = `${l}${h}${a}`), (C || P) && this.options.parseMissingKeyHandler && (c = this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey ? `${l}${h}${a}` : a, P ? c : void 0, s));
428
428
  }
429
429
  return n ? (d.res = c, d.usedParams = this.getUsedParamsDetails(s), d) : c;
430
430
  }
@@ -462,7 +462,7 @@ class Y extends _ {
462
462
  !i.lng && s && s.res && (i.lng = this.language || s.usedLng), i.nest !== !1 && (e = this.interpolator.nest(e, (...d) => (n == null ? void 0 : n[0]) === d[0] && !i.context ? (this.logger.warn(`It seems you are nesting recursively key: ${d[0]} in key: ${t[0]}`), null) : this.translate(...d, t), i)), i.interpolation && this.interpolator.reset();
463
463
  }
464
464
  const r = i.postProcess || this.options.postProcess, a = g(r) ? [r] : r;
465
- return e != null && (a != null && a.length) && i.applyPostProcessor !== !1 && (e = xe.handle(a, e, t, this.options && this.options.postProcessPassResolved ? {
465
+ return e != null && (a != null && a.length) && i.applyPostProcessor !== !1 && (e = ye.handle(a, e, t, this.options && this.options.postProcessPassResolved ? {
466
466
  i18nResolved: {
467
467
  ...s,
468
468
  usedParams: this.getUsedParamsDetails(i)
@@ -480,13 +480,13 @@ class Y extends _ {
480
480
  this.options.fallbackNS && (f = f.concat(this.options.fallbackNS));
481
481
  const p = t.count !== void 0 && !g(t.count), d = p && !t.ordinal && t.count === 0, c = t.context !== void 0 && (g(t.context) || typeof t.context == "number") && t.context !== "", m = t.lngs ? t.lngs : this.languageUtils.toResolveHierarchy(t.lng || this.language, t.fallbackLng);
482
482
  f.forEach((x) => {
483
- var C, w;
484
- this.isValidLookup(i) || (a = x, !le[`${m[0]}-${x}`] && ((C = this.utils) != null && C.hasLoadedNamespace) && !((w = this.utils) != null && w.hasLoadedNamespace(a)) && (le[`${m[0]}-${x}`] = !0, this.logger.warn(`key "${s}" for languages "${m.join(", ")}" won't get resolved as namespace "${a}" was not yet loaded`, "This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")), m.forEach((j) => {
485
- var H;
483
+ var v, w;
484
+ this.isValidLookup(i) || (a = x, !ue[`${m[0]}-${x}`] && ((v = this.utils) != null && v.hasLoadedNamespace) && !((w = this.utils) != null && w.hasLoadedNamespace(a)) && (ue[`${m[0]}-${x}`] = !0, this.logger.warn(`key "${s}" for languages "${m.join(", ")}" won't get resolved as namespace "${a}" was not yet loaded`, "This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")), m.forEach((j) => {
485
+ var M;
486
486
  if (this.isValidLookup(i)) return;
487
487
  r = j;
488
488
  const S = [h];
489
- if ((H = this.i18nFormat) != null && H.addLookupKeys)
489
+ if ((M = this.i18nFormat) != null && M.addLookupKeys)
490
490
  this.i18nFormat.addLookupKeys(S, h, j, x, t);
491
491
  else {
492
492
  let k;
@@ -540,17 +540,17 @@ class Y extends _ {
540
540
  return !1;
541
541
  }
542
542
  }
543
- class ue {
543
+ class fe {
544
544
  constructor(e) {
545
545
  this.options = e, this.supportedLngs = this.options.supportedLngs || !1, this.logger = $.create("languageUtils");
546
546
  }
547
547
  getScriptPartFromCode(e) {
548
- if (e = M(e), !e || e.indexOf("-") < 0) return null;
548
+ if (e = H(e), !e || e.indexOf("-") < 0) return null;
549
549
  const t = e.split("-");
550
550
  return t.length === 2 || (t.pop(), t[t.length - 1].toLowerCase() === "x") ? null : this.formatLanguageCode(t.join("-"));
551
551
  }
552
552
  getLanguagePartFromCode(e) {
553
- if (e = M(e), !e || e.indexOf("-") < 0) return e;
553
+ if (e = H(e), !e || e.indexOf("-") < 0) return e;
554
554
  const t = e.split("-");
555
555
  return this.formatLanguageCode(t[0]);
556
556
  }
@@ -604,31 +604,28 @@ class ue {
604
604
  }), s;
605
605
  }
606
606
  }
607
- const fe = {
607
+ const he = {
608
608
  zero: 0,
609
609
  one: 1,
610
610
  two: 2,
611
611
  few: 3,
612
612
  many: 4,
613
613
  other: 5
614
- }, he = {
614
+ }, ce = {
615
615
  select: (o) => o === 1 ? "one" : "other",
616
616
  resolvedOptions: () => ({
617
617
  pluralCategories: ["one", "other"]
618
618
  })
619
619
  };
620
- class Ee {
620
+ class Ie {
621
621
  constructor(e, t = {}) {
622
622
  this.languageUtils = e, this.options = t, this.logger = $.create("pluralResolver"), this.pluralRulesCache = {};
623
623
  }
624
- addRule(e, t) {
625
- this.rules[e] = t;
626
- }
627
624
  clearCache() {
628
625
  this.pluralRulesCache = {};
629
626
  }
630
627
  getRule(e, t = {}) {
631
- const i = M(e === "dev" ? "en" : e), s = t.ordinal ? "ordinal" : "cardinal", n = JSON.stringify({
628
+ const i = H(e === "dev" ? "en" : e), s = t.ordinal ? "ordinal" : "cardinal", n = JSON.stringify({
632
629
  cleanedCode: i,
633
630
  type: s
634
631
  });
@@ -641,8 +638,8 @@ class Ee {
641
638
  });
642
639
  } catch {
643
640
  if (!Intl)
644
- return this.logger.error("No Intl support, please use an Intl polyfill!"), he;
645
- if (!e.match(/-|_/)) return he;
641
+ return this.logger.error("No Intl support, please use an Intl polyfill!"), ce;
642
+ if (!e.match(/-|_/)) return ce;
646
643
  const u = this.languageUtils.getLanguagePartFromCode(e);
647
644
  r = this.getRule(u, t);
648
645
  }
@@ -657,18 +654,18 @@ class Ee {
657
654
  }
658
655
  getSuffixes(e, t = {}) {
659
656
  let i = this.getRule(e, t);
660
- return i || (i = this.getRule("dev", t)), i ? i.resolvedOptions().pluralCategories.sort((s, n) => fe[s] - fe[n]).map((s) => `${this.options.prepend}${t.ordinal ? `ordinal${this.options.prepend}` : ""}${s}`) : [];
657
+ return i || (i = this.getRule("dev", t)), i ? i.resolvedOptions().pluralCategories.sort((s, n) => he[s] - he[n]).map((s) => `${this.options.prepend}${t.ordinal ? `ordinal${this.options.prepend}` : ""}${s}`) : [];
661
658
  }
662
659
  getSuffix(e, t, i = {}) {
663
660
  const s = this.getRule(e, i);
664
661
  return s ? `${this.options.prepend}${i.ordinal ? `ordinal${this.options.prepend}` : ""}${s.select(t)}` : (this.logger.warn(`no plural rule found for: ${e}`), this.getSuffix("dev", t, i));
665
662
  }
666
663
  }
667
- const ce = (o, e, t, i = ".", s = !0) => {
664
+ const de = (o, e, t, i = ".", s = !0) => {
668
665
  let n = Ce(o, e, t);
669
- return !n && s && g(t) && (n = Z(o, t, i), n === void 0 && (n = Z(e, t, i))), n;
666
+ return !n && s && g(t) && (n = X(o, t, i), n === void 0 && (n = X(e, t, i))), n;
670
667
  }, G = (o) => o.replace(/\$/g, "$$$$");
671
- class Ie {
668
+ class ge {
672
669
  constructor(e = {}) {
673
670
  var t;
674
671
  this.logger = $.create("interpolator"), this.options = e, this.format = ((t = e == null ? void 0 : e.interpolation) == null ? void 0 : t.format) || ((i) => i), this.init(e);
@@ -693,10 +690,10 @@ class Ie {
693
690
  nestingSuffix: c,
694
691
  nestingSuffixEscaped: m,
695
692
  nestingOptionsSeparator: x,
696
- maxReplaces: C,
693
+ maxReplaces: v,
697
694
  alwaysFormat: w
698
695
  } = e.interpolation;
699
- this.escape = t !== void 0 ? t : Re, this.escapeValue = i !== void 0 ? i : !0, this.useRawValueToEscape = s !== void 0 ? s : !1, this.prefix = n ? I(n) : r || "{{", this.suffix = a ? I(a) : u || "}}", this.formatSeparator = l || ",", this.unescapePrefix = h ? "" : f || "-", this.unescapeSuffix = this.unescapePrefix ? "" : h || "", this.nestingPrefix = p ? I(p) : d || I("$t("), this.nestingSuffix = c ? I(c) : m || I(")"), this.nestingOptionsSeparator = x || ",", this.maxReplaces = C || 1e3, this.alwaysFormat = w !== void 0 ? w : !1, this.resetRegExp();
696
+ this.escape = t !== void 0 ? t : Re, this.escapeValue = i !== void 0 ? i : !0, this.useRawValueToEscape = s !== void 0 ? s : !1, this.prefix = n ? I(n) : r || "{{", this.suffix = a ? I(a) : u || "}}", this.formatSeparator = l || ",", this.unescapePrefix = h ? "" : f || "-", this.unescapeSuffix = this.unescapePrefix ? "" : h || "", this.nestingPrefix = p ? I(p) : d || I("$t("), this.nestingSuffix = c ? I(c) : m || I(")"), this.nestingOptionsSeparator = x || ",", this.maxReplaces = v || 1e3, this.alwaysFormat = w !== void 0 ? w : !1, this.resetRegExp();
700
697
  }
701
698
  reset() {
702
699
  this.options && this.init(this.options);
@@ -710,15 +707,15 @@ class Ie {
710
707
  let n, r, a;
711
708
  const u = this.options && this.options.interpolation && this.options.interpolation.defaultVariables || {}, l = (c) => {
712
709
  if (c.indexOf(this.formatSeparator) < 0) {
713
- const w = ce(t, u, c, this.options.keySeparator, this.options.ignoreJSONStructure);
710
+ const w = de(t, u, c, this.options.keySeparator, this.options.ignoreJSONStructure);
714
711
  return this.alwaysFormat ? this.format(w, void 0, i, {
715
712
  ...s,
716
713
  ...t,
717
714
  interpolationkey: c
718
715
  }) : w;
719
716
  }
720
- const m = c.split(this.formatSeparator), x = m.shift().trim(), C = m.join(this.formatSeparator).trim();
721
- return this.format(ce(t, u, x, this.options.keySeparator, this.options.ignoreJSONStructure), C, i, {
717
+ const m = c.split(this.formatSeparator), x = m.shift().trim(), v = m.join(this.formatSeparator).trim();
718
+ return this.format(de(t, u, x, this.options.keySeparator, this.options.ignoreJSONStructure), v, i, {
722
719
  ...s,
723
720
  ...t,
724
721
  interpolationkey: x
@@ -737,8 +734,8 @@ class Ie {
737
734
  const m = n[1].trim();
738
735
  if (r = l(m), r === void 0)
739
736
  if (typeof h == "function") {
740
- const C = h(e, n, s);
741
- r = g(C) ? C : "";
737
+ const v = h(e, n, s);
738
+ r = g(v) ? v : "";
742
739
  } else if (s && Object.prototype.hasOwnProperty.call(s, m))
743
740
  r = "";
744
741
  else if (f) {
@@ -746,7 +743,7 @@ class Ie {
746
743
  continue;
747
744
  } else
748
745
  this.logger.warn(`missed to pass in variable ${m} for interpolating ${e}`), r = "";
749
- else !g(r) && !this.useRawValueToEscape && (r = ie(r));
746
+ else !g(r) && !this.useRawValueToEscape && (r = ne(r));
750
747
  const x = c.safeValue(r);
751
748
  if (e = e.replace(n[0], x), f ? (c.regex.lastIndex += r.length, c.regex.lastIndex -= n[0].length) : c.regex.lastIndex = 0, a++, a >= this.maxReplaces)
752
749
  break;
@@ -780,7 +777,7 @@ class Ie {
780
777
  }, r = r.replace && !g(r.replace) ? r.replace : r, r.applyPostProcessor = !1, delete r.defaultValue;
781
778
  const l = /{.*}/.test(s[1]) ? s[1].lastIndexOf("}") + 1 : s[1].indexOf(this.formatSeparator);
782
779
  if (l !== -1 && (u = s[1].slice(l).split(this.formatSeparator).map((h) => h.trim()).filter(Boolean), s[1] = s[1].slice(0, l)), n = t(a.call(this, s[1].trim(), r), r), n && s[0] === e && !g(n)) return n;
783
- g(n) || (n = ie(n)), n || (this.logger.warn(`missed to resolve ${s[1]} for nesting ${e}`), n = ""), u.length && (n = u.reduce((h, f) => this.format(h, f, i.lng, {
780
+ g(n) || (n = ne(n)), n || (this.logger.warn(`missed to resolve ${s[1]} for nesting ${e}`), n = ""), u.length && (n = u.reduce((h, f) => this.format(h, f, i.lng, {
784
781
  ...i,
785
782
  interpolationkey: s[1].trim()
786
783
  }), n.trim())), e = e.replace(s[0], n), this.regexp.lastIndex = 0;
@@ -806,7 +803,7 @@ const Te = (o) => {
806
803
  formatName: e,
807
804
  formatOptions: t
808
805
  };
809
- }, de = (o) => {
806
+ }, pe = (o) => {
810
807
  const e = {};
811
808
  return (t, i, s) => {
812
809
  let n = s;
@@ -816,9 +813,9 @@ const Te = (o) => {
816
813
  });
817
814
  const r = i + JSON.stringify(n);
818
815
  let a = e[r];
819
- return a || (a = o(M(i), s), e[r] = a), a(t);
816
+ return a || (a = o(H(i), s), e[r] = a), a(t);
820
817
  };
821
- }, De = (o) => (e, t, i) => o(M(t), i)(e);
818
+ }, De = (o) => (e, t, i) => o(H(t), i)(e);
822
819
  class Ve {
823
820
  constructor(e = {}) {
824
821
  this.logger = $.create("formatter"), this.options = e, this.init(e);
@@ -827,7 +824,7 @@ class Ve {
827
824
  interpolation: {}
828
825
  }) {
829
826
  this.formatSeparator = t.interpolation.formatSeparator || ",";
830
- const i = t.cacheInBuiltFormats ? de : De;
827
+ const i = t.cacheInBuiltFormats ? pe : De;
831
828
  this.formats = {
832
829
  number: i((s, n) => {
833
830
  const r = new Intl.NumberFormat(s, {
@@ -866,7 +863,7 @@ class Ve {
866
863
  this.formats[e.toLowerCase().trim()] = t;
867
864
  }
868
865
  addCached(e, t) {
869
- this.formats[e.toLowerCase().trim()] = de(t);
866
+ this.formats[e.toLowerCase().trim()] = pe(t);
870
867
  }
871
868
  format(e, t, i, s = {}) {
872
869
  const n = t.split(this.formatSeparator);
@@ -935,7 +932,7 @@ class Ae extends _ {
935
932
  }), this.state[e] = t ? -1 : 2, t && i && (this.state[e] = 0);
936
933
  const a = {};
937
934
  this.queue.forEach((u) => {
938
- we(u.loaded, [n], r), Ke(u, e), t && u.errors.push(t), u.pendingCount === 0 && !u.done && (Object.keys(u.loaded).forEach((l) => {
935
+ ve(u.loaded, [n], r), Ke(u, e), t && u.errors.push(t), u.pendingCount === 0 && !u.done && (Object.keys(u.loaded).forEach((l) => {
939
936
  a[l] || (a[l] = {});
940
937
  const h = u.loaded[l];
941
938
  h.length && h.forEach((f) => {
@@ -1034,7 +1031,7 @@ class Ae extends _ {
1034
1031
  }
1035
1032
  }
1036
1033
  }
1037
- const ge = () => ({
1034
+ const Z = () => ({
1038
1035
  debug: !1,
1039
1036
  initAsync: !0,
1040
1037
  ns: ["translation"],
@@ -1091,7 +1088,7 @@ const ge = () => ({
1091
1088
  skipOnVariables: !0
1092
1089
  },
1093
1090
  cacheInBuiltFormats: !0
1094
- }), pe = (o) => {
1091
+ }), me = (o) => {
1095
1092
  var e, t;
1096
1093
  return g(o.ns) && (o.ns = [o.ns]), g(o.fallbackLng) && (o.fallbackLng = [o.fallbackLng]), g(o.fallbackNS) && (o.fallbackNS = [o.fallbackNS]), ((t = (e = o.supportedLngs) == null ? void 0 : e.indexOf) == null ? void 0 : t.call(e, "cimode")) < 0 && (o.supportedLngs = o.supportedLngs.concat(["cimode"])), typeof o.initImmediate == "boolean" && (o.initAsync = o.initImmediate), o;
1097
1094
  }, z = () => {
@@ -1102,7 +1099,7 @@ const ge = () => ({
1102
1099
  };
1103
1100
  class U extends _ {
1104
1101
  constructor(e = {}, t) {
1105
- if (super(), this.options = pe(e), this.services = {}, this.logger = $, this.modules = {
1102
+ if (super(), this.options = me(e), this.services = {}, this.logger = $, this.modules = {
1106
1103
  external: []
1107
1104
  }, Ue(this), t && !this.isInitialized && !e.isClone) {
1108
1105
  if (!this.options.initAsync)
@@ -1114,27 +1111,27 @@ class U extends _ {
1114
1111
  }
1115
1112
  init(e = {}, t) {
1116
1113
  this.isInitializing = !0, typeof e == "function" && (t = e, e = {}), e.defaultNS == null && e.ns && (g(e.ns) ? e.defaultNS = e.ns : e.ns.indexOf("translation") < 0 && (e.defaultNS = e.ns[0]));
1117
- const i = ge();
1114
+ const i = Z();
1118
1115
  this.options = {
1119
1116
  ...i,
1120
1117
  ...this.options,
1121
- ...pe(e)
1118
+ ...me(e)
1122
1119
  }, this.options.interpolation = {
1123
1120
  ...i.interpolation,
1124
1121
  ...this.options.interpolation
1125
- }, e.keySeparator !== void 0 && (this.options.userDefinedKeySeparator = e.keySeparator), e.nsSeparator !== void 0 && (this.options.userDefinedNsSeparator = e.nsSeparator);
1122
+ }, e.keySeparator !== void 0 && (this.options.userDefinedKeySeparator = e.keySeparator), e.nsSeparator !== void 0 && (this.options.userDefinedNsSeparator = e.nsSeparator), typeof this.options.overloadTranslationOptionHandler != "function" && (this.options.overloadTranslationOptionHandler = i.overloadTranslationOptionHandler);
1126
1123
  const s = (l) => l ? typeof l == "function" ? new l() : l : null;
1127
1124
  if (!this.options.isClone) {
1128
1125
  this.modules.logger ? $.init(s(this.modules.logger), this.options) : $.init(null, this.options);
1129
1126
  let l;
1130
1127
  this.modules.formatter ? l = this.modules.formatter : l = Ve;
1131
- const h = new ue(this.options);
1132
- this.store = new oe(this.options.resources, this.options);
1128
+ const h = new fe(this.options);
1129
+ this.store = new le(this.options.resources, this.options);
1133
1130
  const f = this.services;
1134
- f.logger = $, f.resourceStore = this.store, f.languageUtils = h, f.pluralResolver = new Ee(h, {
1131
+ f.logger = $, f.resourceStore = this.store, f.languageUtils = h, f.pluralResolver = new Ie(h, {
1135
1132
  prepend: this.options.pluralSeparator,
1136
1133
  simplifyPluralSuffix: this.options.simplifyPluralSuffix
1137
- }), this.options.interpolation.format && this.options.interpolation.format !== i.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"), l && (!this.options.interpolation.format || this.options.interpolation.format === i.interpolation.format) && (f.formatter = s(l), f.formatter.init && f.formatter.init(f, this.options), this.options.interpolation.format = f.formatter.format.bind(f.formatter)), f.interpolator = new Ie(this.options), f.utils = {
1134
+ }), this.options.interpolation.format && this.options.interpolation.format !== i.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"), l && (!this.options.interpolation.format || this.options.interpolation.format === i.interpolation.format) && (f.formatter = s(l), f.formatter.init && f.formatter.init(f, this.options), this.options.interpolation.format = f.formatter.format.bind(f.formatter)), f.interpolator = new ge(this.options), f.utils = {
1138
1135
  hasLoadedNamespace: this.hasLoadedNamespace.bind(this)
1139
1136
  }, f.backendConnector = new Ae(s(this.modules.backend), f.resourceStore, f, this.options), f.backendConnector.on("*", (d, ...c) => {
1140
1137
  this.emit(d, ...c);
@@ -1189,7 +1186,7 @@ class U extends _ {
1189
1186
  use(e) {
1190
1187
  if (!e) throw new Error("You are passing an undefined module! Please check the object you are passing to i18next.use()");
1191
1188
  if (!e.type) throw new Error("You are passing a wrong module! Please check the object you are passing to i18next.use()");
1192
- return e.type === "backend" && (this.modules.backend = e), (e.type === "logger" || e.log && e.warn && e.error) && (this.modules.logger = e), e.type === "languageDetector" && (this.modules.languageDetector = e), e.type === "i18nFormat" && (this.modules.i18nFormat = e), e.type === "postProcessor" && xe.addPostProcessor(e), e.type === "formatter" && (this.modules.formatter = e), e.type === "3rdParty" && this.modules.external.push(e), this;
1189
+ return e.type === "backend" && (this.modules.backend = e), (e.type === "logger" || e.log && e.warn && e.error) && (this.modules.logger = e), e.type === "languageDetector" && (this.modules.languageDetector = e), e.type === "i18nFormat" && (this.modules.i18nFormat = e), e.type === "postProcessor" && ye.addPostProcessor(e), e.type === "formatter" && (this.modules.formatter = e), e.type === "3rdParty" && this.modules.external.push(e), this;
1193
1190
  }
1194
1191
  setResolvedLanguage(e) {
1195
1192
  if (!(!e || !this.languages) && !(["cimode", "dev"].indexOf(e) > -1)) {
@@ -1229,10 +1226,10 @@ class U extends _ {
1229
1226
  }, u.lng = u.lng || s.lng, u.lngs = u.lngs || s.lngs, u.ns = u.ns || s.ns, u.keyPrefix !== "" && (u.keyPrefix = u.keyPrefix || i || s.keyPrefix);
1230
1227
  const l = this.options.keySeparator || ".";
1231
1228
  let h;
1232
- return u.keyPrefix && Array.isArray(n) ? h = n.map((f) => (typeof f == "function" && (f = X(f, {
1229
+ return u.keyPrefix && Array.isArray(n) ? h = n.map((f) => (typeof f == "function" && (f = q(f, {
1233
1230
  ...this.options,
1234
1231
  ...r
1235
- })), `${u.keyPrefix}${l}${f}`)) : (typeof n == "function" && (n = X(n, {
1232
+ })), `${u.keyPrefix}${l}${f}`)) : (typeof n == "function" && (n = q(n, {
1236
1233
  ...this.options,
1237
1234
  ...r
1238
1235
  })), h = u.keyPrefix ? `${u.keyPrefix}${l}${n}` : n), this.t(h, u);
@@ -1294,7 +1291,7 @@ class U extends _ {
1294
1291
  }
1295
1292
  } catch {
1296
1293
  }
1297
- const t = ["ar", "shu", "sqr", "ssh", "xaa", "yhd", "yud", "aao", "abh", "abv", "acm", "acq", "acw", "acx", "acy", "adf", "ads", "aeb", "aec", "afb", "ajp", "apc", "apd", "arb", "arq", "ars", "ary", "arz", "auz", "avl", "ayh", "ayl", "ayn", "ayp", "bbz", "pga", "he", "iw", "ps", "pbt", "pbu", "pst", "prp", "prd", "ug", "ur", "ydd", "yds", "yih", "ji", "yi", "hbo", "men", "xmn", "fa", "jpr", "peo", "pes", "prs", "dv", "sam", "ckb"], i = ((n = this.services) == null ? void 0 : n.languageUtils) || new ue(ge());
1294
+ const t = ["ar", "shu", "sqr", "ssh", "xaa", "yhd", "yud", "aao", "abh", "abv", "acm", "acq", "acw", "acx", "acy", "adf", "ads", "aeb", "aec", "afb", "ajp", "apc", "apd", "arb", "arq", "ars", "ary", "arz", "auz", "avl", "ayh", "ayl", "ayn", "ayp", "bbz", "pga", "he", "iw", "ps", "pbt", "pbu", "pst", "prp", "prd", "ug", "ur", "ydd", "yds", "yih", "ji", "yi", "hbo", "men", "xmn", "fa", "jpr", "peo", "pes", "prs", "dv", "sam", "ckb"], i = ((n = this.services) == null ? void 0 : n.languageUtils) || new fe(Z());
1298
1295
  return e.toLowerCase().indexOf("-latn") > 1 ? "ltr" : t.indexOf(i.getLanguagePartFromCode(e)) > -1 || e.toLowerCase().indexOf("-arab") > 1 ? "rtl" : "ltr";
1299
1296
  }
1300
1297
  static createInstance(e = {}, t) {
@@ -1321,7 +1318,18 @@ class U extends _ {
1321
1318
  }, u[l] = Object.keys(u[l]).reduce((h, f) => (h[f] = {
1322
1319
  ...u[l][f]
1323
1320
  }, h), u[l]), u), {});
1324
- n.store = new oe(a, s), n.services.resourceStore = n.store;
1321
+ n.store = new le(a, s), n.services.resourceStore = n.store;
1322
+ }
1323
+ if (e.interpolation) {
1324
+ const u = {
1325
+ ...Z().interpolation,
1326
+ ...this.options.interpolation,
1327
+ ...e.interpolation
1328
+ }, l = {
1329
+ ...s,
1330
+ interpolation: u
1331
+ };
1332
+ n.services.interpolator = new ge(l);
1325
1333
  }
1326
1334
  return n.translator = new Y(n.services, s), n.translator.on("*", (a, ...u) => {
1327
1335
  n.emit(a, ...u);
@@ -1345,10 +1353,10 @@ O.dir;
1345
1353
  O.init;
1346
1354
  O.loadResources;
1347
1355
  O.reloadResources;
1348
- const Me = O.use;
1356
+ const He = O.use;
1349
1357
  O.changeLanguage;
1350
1358
  O.getFixedT;
1351
- const He = O.t;
1359
+ const Me = O.t;
1352
1360
  O.exists;
1353
1361
  O.setDefaultNamespace;
1354
1362
  O.hasLoadedNamespace;
@@ -1356,7 +1364,7 @@ O.loadNamespaces;
1356
1364
  O.loadLanguages;
1357
1365
  export {
1358
1366
  O as i,
1359
- X as k,
1360
- He as t,
1361
- Me as u
1367
+ q as k,
1368
+ Me as t,
1369
+ He as u
1362
1370
  };