zerocodejs 1.0.1-beta.12 → 1.0.1-beta.13

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.
@@ -504,7 +504,7 @@ function Og(n) {
504
504
  const e = n;
505
505
  let t = 0, o = 1, r = 1, i = 0;
506
506
  const s = (x) => e[x] === Ig && e[x + 1] === Ft, a = (x) => e[x] === Ft, l = (x) => e[x] === _g, c = (x) => e[x] === Ng, d = (x) => s(x) || a(x) || l(x) || c(x), u = () => t, f = () => o, p = () => r, h = () => i, g = (x) => s(x) || l(x) || c(x) ? Ft : e[x], b = () => g(t), v = () => g(t + i);
507
- function E() {
507
+ function C() {
508
508
  return i = 0, d(t) && (o++, r = 0), s(t) && t++, t++, r++, e[t];
509
509
  }
510
510
  function k() {
@@ -519,7 +519,7 @@ function Og(n) {
519
519
  function I() {
520
520
  const x = t + i;
521
521
  for (; x !== t; )
522
- E();
522
+ C();
523
523
  i = 0;
524
524
  }
525
525
  return {
@@ -530,7 +530,7 @@ function Og(n) {
530
530
  charAt: g,
531
531
  currentChar: b,
532
532
  currentPeek: v,
533
- next: E,
533
+ next: C,
534
534
  peek: k,
535
535
  reset: T,
536
536
  resetPeek: N,
@@ -593,7 +593,7 @@ function Dg(n, e = {}) {
593
593
  _ >= 65 && _ <= 90 || // A-Z
594
594
  _ === 95;
595
595
  }
596
- function E(z) {
596
+ function C(z) {
597
597
  if (z === Qn)
598
598
  return !1;
599
599
  const _ = z.charCodeAt(0);
@@ -612,7 +612,7 @@ function Dg(n, e = {}) {
612
612
  if (ne !== 2)
613
613
  return !1;
614
614
  g(z);
615
- const Se = z.currentPeek() === "-" ? z.peek() : z.currentPeek(), De = E(Se);
615
+ const Se = z.currentPeek() === "-" ? z.peek() : z.currentPeek(), De = C(Se);
616
616
  return z.resetPeek(), De;
617
617
  }
618
618
  function N(z, _) {
@@ -784,14 +784,14 @@ function Dg(n, e = {}) {
784
784
  case "'":
785
785
  return z.next(), `\\${_}`;
786
786
  case "u":
787
- return C(z, _, 4);
787
+ return E(z, _, 4);
788
788
  case "U":
789
- return C(z, _, 6);
789
+ return E(z, _, 6);
790
790
  default:
791
791
  return u(Oe.UNKNOWN_ESCAPE_SEQUENCE, i(), 0, _), "";
792
792
  }
793
793
  }
794
- function C(z, _, ne) {
794
+ function E(z, _, ne) {
795
795
  h(z, _);
796
796
  let Se = "";
797
797
  for (let De = 0; De < ne; De++) {
@@ -1102,11 +1102,11 @@ function Vg(n = {}) {
1102
1102
  const T = k.context(), { offset: N, startLoc: I } = T, x = g(k);
1103
1103
  return T.currentType === 14 ? x : b(k, N, I, x);
1104
1104
  }
1105
- function E(k) {
1105
+ function C(k) {
1106
1106
  const T = Dg(k, kf({}, n)), N = T.context(), I = s(0, N.offset, N.startLoc);
1107
1107
  return e && I.loc && (I.loc.source = k), I.body = v(T), n.onCacheKey && (I.cacheKey = n.onCacheKey(k)), N.currentType !== 14 && r(T, Oe.UNEXPECTED_LEXICAL_ANALYSIS, N.lastStartLoc, 0, k[N.offset] || ""), a(I, T.currentOffset(), T.currentPosition()), I;
1108
1108
  }
1109
- return { parse: E };
1109
+ return { parse: C };
1110
1110
  }
1111
1111
  function gn(n) {
1112
1112
  if (n.type === 14)
@@ -1777,17 +1777,17 @@ function kb(n = {}) {
1777
1777
  Ct(n.pluralIndex) && xb(t, l);
1778
1778
  const c = (v) => l[v];
1779
1779
  function d(v) {
1780
- const E = dt(n.messages) ? n.messages(v) : Ye(n.messages) ? n.messages[v] : !1;
1781
- return E || (n.parent ? n.parent.message(v) : mb);
1780
+ const C = dt(n.messages) ? n.messages(v) : Ye(n.messages) ? n.messages[v] : !1;
1781
+ return C || (n.parent ? n.parent.message(v) : mb);
1782
1782
  }
1783
1783
  const u = (v) => n.modifiers ? n.modifiers[v] : hb, f = Xe(n.processor) && dt(n.processor.normalize) ? n.processor.normalize : bb, p = Xe(n.processor) && dt(n.processor.interpolate) ? n.processor.interpolate : yb, h = Xe(n.processor) && ze(n.processor.type) ? n.processor.type : gb, b = {
1784
1784
  list: a,
1785
1785
  named: c,
1786
1786
  plural: i,
1787
- linked: (v, ...E) => {
1788
- const [k, T] = E;
1787
+ linked: (v, ...C) => {
1788
+ const [k, T] = C;
1789
1789
  let N = "text", I = "";
1790
- E.length === 1 ? Ye(k) ? (I = k.modifier || I, N = k.type || N) : ze(k) && (I = k || I) : E.length === 2 && (ze(k) && (I = k || I), ze(T) && (N = T || N));
1790
+ C.length === 1 ? Ye(k) ? (I = k.modifier || I, N = k.type || N) : ze(k) && (I = k || I) : C.length === 2 && (ze(k) && (I = k || I), ze(T) && (N = T || N));
1791
1791
  const x = d(v)(b), w = (
1792
1792
  // The message in vnode resolved with linked are returned as an array by processor.nomalize
1793
1793
  N === "vnode" && kt(x) && I ? x[0] : x
@@ -1931,7 +1931,7 @@ const cd = (n) => {
1931
1931
  }, Nb = () => $f;
1932
1932
  let dd = 0;
1933
1933
  function _b(n = {}) {
1934
- const e = dt(n.onWarn) ? n.onWarn : pg, t = ze(n.version) ? n.version : zb, o = ze(n.locale) || dt(n.locale) ? n.locale : ns, r = dt(o) ? ns : o, i = kt(n.fallbackLocale) || Xe(n.fallbackLocale) || ze(n.fallbackLocale) || n.fallbackLocale === !1 ? n.fallbackLocale : r, s = Xe(n.messages) ? n.messages : ka(r), a = Xe(n.datetimeFormats) ? n.datetimeFormats : ka(r), l = Xe(n.numberFormats) ? n.numberFormats : ka(r), c = Vt(Ze(), n.modifiers, Ab()), d = n.pluralRules || Ze(), u = dt(n.missing) ? n.missing : null, f = lt(n.missingWarn) || Zi(n.missingWarn) ? n.missingWarn : !0, p = lt(n.fallbackWarn) || Zi(n.fallbackWarn) ? n.fallbackWarn : !0, h = !!n.fallbackFormat, g = !!n.unresolving, b = dt(n.postTranslation) ? n.postTranslation : null, v = Xe(n.processor) ? n.processor : null, E = lt(n.warnHtmlMessage) ? n.warnHtmlMessage : !0, k = !!n.escapeParameter, T = dt(n.messageCompiler) ? n.messageCompiler : Pf, N = dt(n.messageResolver) ? n.messageResolver : Rf || fb, I = dt(n.localeFallbacker) ? n.localeFallbacker : Df || Eb, x = Ye(n.fallbackContext) ? n.fallbackContext : void 0, w = n, y = Ye(w.__datetimeFormatters) ? w.__datetimeFormatters : /* @__PURE__ */ new Map(), L = Ye(w.__numberFormatters) ? w.__numberFormatters : /* @__PURE__ */ new Map(), H = Ye(w.__meta) ? w.__meta : {};
1934
+ const e = dt(n.onWarn) ? n.onWarn : pg, t = ze(n.version) ? n.version : zb, o = ze(n.locale) || dt(n.locale) ? n.locale : ns, r = dt(o) ? ns : o, i = kt(n.fallbackLocale) || Xe(n.fallbackLocale) || ze(n.fallbackLocale) || n.fallbackLocale === !1 ? n.fallbackLocale : r, s = Xe(n.messages) ? n.messages : ka(r), a = Xe(n.datetimeFormats) ? n.datetimeFormats : ka(r), l = Xe(n.numberFormats) ? n.numberFormats : ka(r), c = Vt(Ze(), n.modifiers, Ab()), d = n.pluralRules || Ze(), u = dt(n.missing) ? n.missing : null, f = lt(n.missingWarn) || Zi(n.missingWarn) ? n.missingWarn : !0, p = lt(n.fallbackWarn) || Zi(n.fallbackWarn) ? n.fallbackWarn : !0, h = !!n.fallbackFormat, g = !!n.unresolving, b = dt(n.postTranslation) ? n.postTranslation : null, v = Xe(n.processor) ? n.processor : null, C = lt(n.warnHtmlMessage) ? n.warnHtmlMessage : !0, k = !!n.escapeParameter, T = dt(n.messageCompiler) ? n.messageCompiler : Pf, N = dt(n.messageResolver) ? n.messageResolver : Rf || fb, I = dt(n.localeFallbacker) ? n.localeFallbacker : Df || Eb, x = Ye(n.fallbackContext) ? n.fallbackContext : void 0, w = n, y = Ye(w.__datetimeFormatters) ? w.__datetimeFormatters : /* @__PURE__ */ new Map(), L = Ye(w.__numberFormatters) ? w.__numberFormatters : /* @__PURE__ */ new Map(), H = Ye(w.__meta) ? w.__meta : {};
1935
1935
  dd++;
1936
1936
  const P = {
1937
1937
  version: t,
@@ -1948,7 +1948,7 @@ function _b(n = {}) {
1948
1948
  unresolving: g,
1949
1949
  postTranslation: b,
1950
1950
  processor: v,
1951
- warnHtmlMessage: E,
1951
+ warnHtmlMessage: C,
1952
1952
  escapeParameter: k,
1953
1953
  messageCompiler: T,
1954
1954
  messageResolver: N,
@@ -2093,20 +2093,20 @@ const fd = () => "", Wn = (n) => dt(n);
2093
2093
  function pd(n, ...e) {
2094
2094
  const { fallbackFormat: t, postTranslation: o, unresolving: r, messageCompiler: i, fallbackLocale: s, messages: a } = n, [l, c] = rl(...e), d = lt(c.missingWarn) ? c.missingWarn : n.missingWarn, u = lt(c.fallbackWarn) ? c.fallbackWarn : n.fallbackWarn, f = lt(c.escapeParameter) ? c.escapeParameter : n.escapeParameter, p = !!c.resolvedMessage, h = ze(c.default) || lt(c.default) ? lt(c.default) ? i ? l : () => l : c.default : t ? i ? l : () => l : "", g = t || h !== "", b = Yl(n, c);
2095
2095
  f && Lb(c);
2096
- let [v, E, k] = p ? [
2096
+ let [v, C, k] = p ? [
2097
2097
  l,
2098
2098
  b,
2099
2099
  a[b] || Ze()
2100
2100
  ] : Vf(n, l, b, s, u, d), T = v, N = l;
2101
- if (!p && !(ze(T) || Nn(T) || Wn(T)) && g && (T = h, N = T), !p && (!(ze(T) || Nn(T) || Wn(T)) || !ze(E)))
2101
+ if (!p && !(ze(T) || Nn(T) || Wn(T)) && g && (T = h, N = T), !p && (!(ze(T) || Nn(T) || Wn(T)) || !ze(C)))
2102
2102
  return r ? Zs : l;
2103
2103
  let I = !1;
2104
2104
  const x = () => {
2105
2105
  I = !0;
2106
- }, w = Wn(T) ? T : Bf(n, l, E, T, N, x);
2106
+ }, w = Wn(T) ? T : Bf(n, l, C, T, N, x);
2107
2107
  if (I)
2108
2108
  return T;
2109
- const y = Bb(n, E, k, c), L = kb(y), H = Fb(n, w, L);
2109
+ const y = Bb(n, C, k, c), L = kb(y), H = Fb(n, w, L);
2110
2110
  let P = o ? o(H, l) : H;
2111
2111
  return f && ze(P) && (P = yg(P)), P;
2112
2112
  }
@@ -2200,16 +2200,16 @@ function hd(n, ...e) {
2200
2200
  );
2201
2201
  if (!ze(l) || l === "")
2202
2202
  return new Intl.DateTimeFormat(h, u).format(c);
2203
- let b = {}, v, E = null;
2203
+ let b = {}, v, C = null;
2204
2204
  const k = "datetime format";
2205
- for (let I = 0; I < g.length && (v = g[I], b = t[v] || {}, E = b[l], !Xe(E)); I++)
2205
+ for (let I = 0; I < g.length && (v = g[I], b = t[v] || {}, C = b[l], !Xe(C)); I++)
2206
2206
  Ql(n, l, v, f, k);
2207
- if (!Xe(E) || !ze(v))
2207
+ if (!Xe(C) || !ze(v))
2208
2208
  return o ? Zs : l;
2209
2209
  let T = `${v}__${l}`;
2210
2210
  Ys(u) || (T = `${T}__${JSON.stringify(u)}`);
2211
2211
  let N = a.get(T);
2212
- return N || (N = new Intl.DateTimeFormat(v, Vt({}, E, u)), a.set(T, N)), p ? N.formatToParts(c) : N.format(c);
2212
+ return N || (N = new Intl.DateTimeFormat(v, Vt({}, C, u)), a.set(T, N)), p ? N.formatToParts(c) : N.format(c);
2213
2213
  }
2214
2214
  const jf = [
2215
2215
  "localeMatcher",
@@ -2277,16 +2277,16 @@ function gd(n, ...e) {
2277
2277
  );
2278
2278
  if (!ze(l) || l === "")
2279
2279
  return new Intl.NumberFormat(h, u).format(c);
2280
- let b = {}, v, E = null;
2280
+ let b = {}, v, C = null;
2281
2281
  const k = "number format";
2282
- for (let I = 0; I < g.length && (v = g[I], b = t[v] || {}, E = b[l], !Xe(E)); I++)
2282
+ for (let I = 0; I < g.length && (v = g[I], b = t[v] || {}, C = b[l], !Xe(C)); I++)
2283
2283
  Ql(n, l, v, f, k);
2284
- if (!Xe(E) || !ze(v))
2284
+ if (!Xe(C) || !ze(v))
2285
2285
  return o ? Zs : l;
2286
2286
  let T = `${v}__${l}`;
2287
2287
  Ys(u) || (T = `${T}__${JSON.stringify(u)}`);
2288
2288
  let N = a.get(T);
2289
- return N || (N = new Intl.NumberFormat(v, Vt({}, E, u)), a.set(T, N)), p ? N.formatToParts(c) : N.format(c);
2289
+ return N || (N = new Intl.NumberFormat(v, Vt({}, C, u)), a.set(T, N)), p ? N.formatToParts(c) : N.format(c);
2290
2290
  }
2291
2291
  const Hf = [
2292
2292
  "localeMatcher",
@@ -2466,7 +2466,7 @@ function qf(n = {}, e) {
2466
2466
  // prettier-ignore
2467
2467
  t && l ? t.fallbackLocale.value : ze(n.fallbackLocale) || kt(n.fallbackLocale) || Xe(n.fallbackLocale) || n.fallbackLocale === !1 ? n.fallbackLocale : c.value
2468
2468
  ), u = s(Wf(c.value, n)), f = s(Xe(n.datetimeFormats) ? n.datetimeFormats : { [c.value]: {} }), p = s(Xe(n.numberFormats) ? n.numberFormats : { [c.value]: {} });
2469
- let h = t ? t.missingWarn : lt(n.missingWarn) || Zi(n.missingWarn) ? n.missingWarn : !0, g = t ? t.fallbackWarn : lt(n.fallbackWarn) || Zi(n.fallbackWarn) ? n.fallbackWarn : !0, b = t ? t.fallbackRoot : lt(n.fallbackRoot) ? n.fallbackRoot : !0, v = !!n.fallbackFormat, E = dt(n.missing) ? n.missing : null, k = dt(n.missing) ? kd(n.missing) : null, T = dt(n.postTranslation) ? n.postTranslation : null, N = t ? t.warnHtmlMessage : lt(n.warnHtmlMessage) ? n.warnHtmlMessage : !0, I = !!n.escapeParameter;
2469
+ let h = t ? t.missingWarn : lt(n.missingWarn) || Zi(n.missingWarn) ? n.missingWarn : !0, g = t ? t.fallbackWarn : lt(n.fallbackWarn) || Zi(n.fallbackWarn) ? n.fallbackWarn : !0, b = t ? t.fallbackRoot : lt(n.fallbackRoot) ? n.fallbackRoot : !0, v = !!n.fallbackFormat, C = dt(n.missing) ? n.missing : null, k = dt(n.missing) ? kd(n.missing) : null, T = dt(n.postTranslation) ? n.postTranslation : null, N = t ? t.warnHtmlMessage : lt(n.warnHtmlMessage) ? n.warnHtmlMessage : !0, I = !!n.escapeParameter;
2470
2470
  const x = t ? t.modifiers : Xe(n.modifiers) ? n.modifiers : {};
2471
2471
  let w = n.pluralRules || t && t.pluralRules, y;
2472
2472
  y = (() => {
@@ -2521,10 +2521,10 @@ function qf(n = {}, e) {
2521
2521
  T = G, y.postTranslation = G;
2522
2522
  }
2523
2523
  function Z() {
2524
- return E;
2524
+ return C;
2525
2525
  }
2526
2526
  function ae(G) {
2527
- G !== null && (k = kd(G)), E = G, y.missing = k;
2527
+ G !== null && (k = kd(G)), C = G, y.missing = k;
2528
2528
  }
2529
2529
  const se = (G, re, $e, qe, wt, nn) => {
2530
2530
  H();
@@ -2587,7 +2587,7 @@ function qf(n = {}, e) {
2587
2587
  (re) => kt(re)
2588
2588
  );
2589
2589
  }
2590
- function C(...G) {
2590
+ function E(...G) {
2591
2591
  return se(
2592
2592
  (re) => Reflect.apply(gd, null, [re, ...G]),
2593
2593
  () => sl(...G),
@@ -2748,7 +2748,7 @@ function qf(n = {}, e) {
2748
2748
  setMissingHandler: ae,
2749
2749
  [Wb]: B
2750
2750
  };
2751
- return Ee.datetimeFormats = X, Ee.numberFormats = J, Ee.rt = oe, Ee.te = S, Ee.tm = A, Ee.d = te, Ee.n = ie, Ee.getDateTimeFormat = Re, Ee.setDateTimeFormat = z, Ee.mergeDateTimeFormat = _, Ee.getNumberFormat = ne, Ee.setNumberFormat = Se, Ee.mergeNumberFormat = De, Ee[qb] = o, Ee[al] = Ke, Ee[ll] = F, Ee[cl] = C, Ee;
2751
+ return Ee.datetimeFormats = X, Ee.numberFormats = J, Ee.rt = oe, Ee.te = S, Ee.tm = A, Ee.d = te, Ee.n = ie, Ee.getDateTimeFormat = Re, Ee.setDateTimeFormat = z, Ee.mergeDateTimeFormat = _, Ee.getNumberFormat = ne, Ee.setNumberFormat = Se, Ee.mergeNumberFormat = De, Ee[qb] = o, Ee[al] = Ke, Ee[ll] = F, Ee[cl] = E, Ee;
2752
2752
  }
2753
2753
  const Zl = {
2754
2754
  tag: {
@@ -3575,7 +3575,7 @@ function Qf() {
3575
3575
  HTMLFormElement: u,
3576
3576
  DOMParser: f,
3577
3577
  trustedTypes: p
3578
- } = n, h = l.prototype, g = Nr(h, "cloneNode"), b = Nr(h, "remove"), v = Nr(h, "nextSibling"), E = Nr(h, "childNodes"), k = Nr(h, "parentNode");
3578
+ } = n, h = l.prototype, g = Nr(h, "cloneNode"), b = Nr(h, "remove"), v = Nr(h, "nextSibling"), C = Nr(h, "childNodes"), k = Nr(h, "parentNode");
3579
3579
  if (typeof s == "function") {
3580
3580
  const Te = t.createElement("template");
3581
3581
  Te.content && Te.content.ownerDocument && (t = Te.content.ownerDocument);
@@ -3641,7 +3641,7 @@ function Qf() {
3641
3641
  value: null
3642
3642
  }
3643
3643
  }));
3644
- let Ke = !0, C = !0, F = !1, B = !0, S = !1, Q = !0, A = !1, K = !1, ce = !1, Ne = !1, Re = !1, z = !1, _ = !0, ne = !1;
3644
+ let Ke = !0, E = !0, F = !1, B = !0, S = !1, Q = !0, A = !1, K = !1, ce = !1, Ne = !1, Re = !1, z = !1, _ = !0, ne = !1;
3645
3645
  const Se = "user-content-";
3646
3646
  let De = !0, Ee = !1, G = {}, re = null;
3647
3647
  const $e = Ue({}, ["annotation-xml", "audio", "colgroup", "desc", "foreignobject", "head", "iframe", "math", "mi", "mn", "mo", "ms", "mtext", "noembed", "noframes", "noscript", "plaintext", "script", "style", "svg", "template", "thead", "title", "video", "xmp"]);
@@ -3662,7 +3662,7 @@ function Qf() {
3662
3662
  let O = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
3663
3663
  if (!(qt && qt === O)) {
3664
3664
  if ((!O || typeof O != "object") && (O = {}), O = Cn(O), zo = // eslint-disable-next-line unicorn/prefer-includes
3665
- ga.indexOf(O.PARSER_MEDIA_TYPE) === -1 ? kr : O.PARSER_MEDIA_TYPE, at = zo === "application/xhtml+xml" ? Sa : qi, se = bn(O, "ALLOWED_TAGS") ? Ue({}, O.ALLOWED_TAGS, at) : ee, oe = bn(O, "ALLOWED_ATTR") ? Ue({}, O.ALLOWED_ATTR, at) : te, ve = bn(O, "ALLOWED_NAMESPACES") ? Ue({}, O.ALLOWED_NAMESPACES, Sa) : Be, nn = bn(O, "ADD_URI_SAFE_ATTR") ? Ue(Cn(Wt), O.ADD_URI_SAFE_ATTR, at) : Wt, qe = bn(O, "ADD_DATA_URI_TAGS") ? Ue(Cn(wt), O.ADD_DATA_URI_TAGS, at) : wt, re = bn(O, "FORBID_CONTENTS") ? Ue({}, O.FORBID_CONTENTS, at) : $e, ge = bn(O, "FORBID_TAGS") ? Ue({}, O.FORBID_TAGS, at) : Cn({}), ke = bn(O, "FORBID_ATTR") ? Ue({}, O.FORBID_ATTR, at) : Cn({}), G = bn(O, "USE_PROFILES") ? O.USE_PROFILES : !1, Ke = O.ALLOW_ARIA_ATTR !== !1, C = O.ALLOW_DATA_ATTR !== !1, F = O.ALLOW_UNKNOWN_PROTOCOLS || !1, B = O.ALLOW_SELF_CLOSE_IN_ATTR !== !1, S = O.SAFE_FOR_TEMPLATES || !1, Q = O.SAFE_FOR_XML !== !1, A = O.WHOLE_DOCUMENT || !1, Ne = O.RETURN_DOM || !1, Re = O.RETURN_DOM_FRAGMENT || !1, z = O.RETURN_TRUSTED_TYPE || !1, ce = O.FORCE_BODY || !1, _ = O.SANITIZE_DOM !== !1, ne = O.SANITIZE_NAMED_PROPS || !1, De = O.KEEP_CONTENT !== !1, Ee = O.IN_PLACE || !1, ae = O.ALLOWED_URI_REGEXP || Xf, W = O.NAMESPACE || U, ft = O.MATHML_TEXT_INTEGRATION_POINTS || ft, Sn = O.HTML_INTEGRATION_POINTS || Sn, ie = O.CUSTOM_ELEMENT_HANDLING || {}, O.CUSTOM_ELEMENT_HANDLING && Ko(O.CUSTOM_ELEMENT_HANDLING.tagNameCheck) && (ie.tagNameCheck = O.CUSTOM_ELEMENT_HANDLING.tagNameCheck), O.CUSTOM_ELEMENT_HANDLING && Ko(O.CUSTOM_ELEMENT_HANDLING.attributeNameCheck) && (ie.attributeNameCheck = O.CUSTOM_ELEMENT_HANDLING.attributeNameCheck), O.CUSTOM_ELEMENT_HANDLING && typeof O.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements == "boolean" && (ie.allowCustomizedBuiltInElements = O.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements), S && (C = !1), Re && (Ne = !0), G && (se = Ue({}, Td), oe = [], G.html === !0 && (Ue(se, Cd), Ue(oe, zd)), G.svg === !0 && (Ue(se, Ca), Ue(oe, Aa), Ue(oe, Ai)), G.svgFilters === !0 && (Ue(se, Ta), Ue(oe, Aa), Ue(oe, Ai)), G.mathMl === !0 && (Ue(se, za), Ue(oe, Ad), Ue(oe, Ai))), O.ADD_TAGS && (typeof O.ADD_TAGS == "function" ? Le.tagCheck = O.ADD_TAGS : (se === ee && (se = Cn(se)), Ue(se, O.ADD_TAGS, at))), O.ADD_ATTR && (typeof O.ADD_ATTR == "function" ? Le.attributeCheck = O.ADD_ATTR : (oe === te && (oe = Cn(oe)), Ue(oe, O.ADD_ATTR, at))), O.ADD_URI_SAFE_ATTR && Ue(nn, O.ADD_URI_SAFE_ATTR, at), O.FORBID_CONTENTS && (re === $e && (re = Cn(re)), Ue(re, O.FORBID_CONTENTS, at)), O.ADD_FORBID_CONTENTS && (re === $e && (re = Cn(re)), Ue(re, O.ADD_FORBID_CONTENTS, at)), De && (se["#text"] = !0), A && Ue(se, ["html", "head", "body"]), se.table && (Ue(se, ["tbody"]), delete ge.tbody), O.TRUSTED_TYPES_POLICY) {
3665
+ ga.indexOf(O.PARSER_MEDIA_TYPE) === -1 ? kr : O.PARSER_MEDIA_TYPE, at = zo === "application/xhtml+xml" ? Sa : qi, se = bn(O, "ALLOWED_TAGS") ? Ue({}, O.ALLOWED_TAGS, at) : ee, oe = bn(O, "ALLOWED_ATTR") ? Ue({}, O.ALLOWED_ATTR, at) : te, ve = bn(O, "ALLOWED_NAMESPACES") ? Ue({}, O.ALLOWED_NAMESPACES, Sa) : Be, nn = bn(O, "ADD_URI_SAFE_ATTR") ? Ue(Cn(Wt), O.ADD_URI_SAFE_ATTR, at) : Wt, qe = bn(O, "ADD_DATA_URI_TAGS") ? Ue(Cn(wt), O.ADD_DATA_URI_TAGS, at) : wt, re = bn(O, "FORBID_CONTENTS") ? Ue({}, O.FORBID_CONTENTS, at) : $e, ge = bn(O, "FORBID_TAGS") ? Ue({}, O.FORBID_TAGS, at) : Cn({}), ke = bn(O, "FORBID_ATTR") ? Ue({}, O.FORBID_ATTR, at) : Cn({}), G = bn(O, "USE_PROFILES") ? O.USE_PROFILES : !1, Ke = O.ALLOW_ARIA_ATTR !== !1, E = O.ALLOW_DATA_ATTR !== !1, F = O.ALLOW_UNKNOWN_PROTOCOLS || !1, B = O.ALLOW_SELF_CLOSE_IN_ATTR !== !1, S = O.SAFE_FOR_TEMPLATES || !1, Q = O.SAFE_FOR_XML !== !1, A = O.WHOLE_DOCUMENT || !1, Ne = O.RETURN_DOM || !1, Re = O.RETURN_DOM_FRAGMENT || !1, z = O.RETURN_TRUSTED_TYPE || !1, ce = O.FORCE_BODY || !1, _ = O.SANITIZE_DOM !== !1, ne = O.SANITIZE_NAMED_PROPS || !1, De = O.KEEP_CONTENT !== !1, Ee = O.IN_PLACE || !1, ae = O.ALLOWED_URI_REGEXP || Xf, W = O.NAMESPACE || U, ft = O.MATHML_TEXT_INTEGRATION_POINTS || ft, Sn = O.HTML_INTEGRATION_POINTS || Sn, ie = O.CUSTOM_ELEMENT_HANDLING || {}, O.CUSTOM_ELEMENT_HANDLING && Ko(O.CUSTOM_ELEMENT_HANDLING.tagNameCheck) && (ie.tagNameCheck = O.CUSTOM_ELEMENT_HANDLING.tagNameCheck), O.CUSTOM_ELEMENT_HANDLING && Ko(O.CUSTOM_ELEMENT_HANDLING.attributeNameCheck) && (ie.attributeNameCheck = O.CUSTOM_ELEMENT_HANDLING.attributeNameCheck), O.CUSTOM_ELEMENT_HANDLING && typeof O.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements == "boolean" && (ie.allowCustomizedBuiltInElements = O.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements), S && (E = !1), Re && (Ne = !0), G && (se = Ue({}, Td), oe = [], G.html === !0 && (Ue(se, Cd), Ue(oe, zd)), G.svg === !0 && (Ue(se, Ca), Ue(oe, Aa), Ue(oe, Ai)), G.svgFilters === !0 && (Ue(se, Ta), Ue(oe, Aa), Ue(oe, Ai)), G.mathMl === !0 && (Ue(se, za), Ue(oe, Ad), Ue(oe, Ai))), O.ADD_TAGS && (typeof O.ADD_TAGS == "function" ? Le.tagCheck = O.ADD_TAGS : (se === ee && (se = Cn(se)), Ue(se, O.ADD_TAGS, at))), O.ADD_ATTR && (typeof O.ADD_ATTR == "function" ? Le.attributeCheck = O.ADD_ATTR : (oe === te && (oe = Cn(oe)), Ue(oe, O.ADD_ATTR, at))), O.ADD_URI_SAFE_ATTR && Ue(nn, O.ADD_URI_SAFE_ATTR, at), O.FORBID_CONTENTS && (re === $e && (re = Cn(re)), Ue(re, O.FORBID_CONTENTS, at)), O.ADD_FORBID_CONTENTS && (re === $e && (re = Cn(re)), Ue(re, O.ADD_FORBID_CONTENTS, at)), De && (se["#text"] = !0), A && Ue(se, ["html", "head", "body"]), se.table && (Ue(se, ["tbody"]), delete ge.tbody), O.TRUSTED_TYPES_POLICY) {
3666
3666
  if (typeof O.TRUSTED_TYPES_POLICY.createHTML != "function")
3667
3667
  throw Ir('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');
3668
3668
  if (typeof O.TRUSTED_TYPES_POLICY.createScriptURL != "function")
@@ -3768,7 +3768,7 @@ function Qf() {
3768
3768
  if (!ge[Ce] && nt(Ce) && (ie.tagNameCheck instanceof RegExp && $t(ie.tagNameCheck, Ce) || ie.tagNameCheck instanceof Function && ie.tagNameCheck(Ce)))
3769
3769
  return !1;
3770
3770
  if (De && !re[Ce]) {
3771
- const it = k(O) || O.parentNode, Pt = E(O) || O.childNodes;
3771
+ const it = k(O) || O.parentNode, Pt = C(O) || O.childNodes;
3772
3772
  if (Pt && it) {
3773
3773
  const gt = Pt.length;
3774
3774
  for (let Gt = gt - 1; Gt >= 0; --Gt) {
@@ -3787,7 +3787,7 @@ function Qf() {
3787
3787
  }, Ie = function(O, me, Ce) {
3788
3788
  if (_ && (me === "id" || me === "name") && (Ce in t || Ce in ba))
3789
3789
  return !1;
3790
- if (!(C && !ke[me] && $t(X, me))) {
3790
+ if (!(E && !ke[me] && $t(X, me))) {
3791
3791
  if (!(Ke && $t(J, me))) {
3792
3792
  if (!(Le.attributeCheck instanceof Function && Le.attributeCheck(me, O))) {
3793
3793
  if (!oe[me] || ke[me]) {
@@ -4321,11 +4321,11 @@ function po(n) {
4321
4321
  }), t.add(A);
4322
4322
  }
4323
4323
  });
4324
- const C = new RegExp(
4324
+ const E = new RegExp(
4325
4325
  we.RADIO_CHECKBOX_FIELD_WITH_GROUP.source,
4326
4326
  we.RADIO_CHECKBOX_FIELD_WITH_GROUP.flags
4327
4327
  );
4328
- Array.from(d.matchAll(C)).forEach((S) => {
4328
+ Array.from(d.matchAll(E)).forEach((S) => {
4329
4329
  if (S && S[1] && S[2] && S[3] && !t.has(S[1])) {
4330
4330
  const Q = S[1], A = S[2], K = S[3];
4331
4331
  K.includes("|") ? e.push({
@@ -4369,9 +4369,9 @@ function po(n) {
4369
4369
  if (h) {
4370
4370
  const g = h[1], b = h[2];
4371
4371
  if (!t.has(g)) {
4372
- const v = b ? b.split("|").map((T) => T.trim()) : void 0, E = d.tagName.toLowerCase();
4373
- let k = E;
4374
- v && !v.includes(E) && (k = v[0]), e.push({
4372
+ const v = b ? b.split("|").map((T) => T.trim()) : void 0, C = d.tagName.toLowerCase();
4373
+ let k = C;
4374
+ v && !v.includes(C) && (k = v[0]), e.push({
4375
4375
  fieldName: g,
4376
4376
  type: "tag",
4377
4377
  defaultValue: k,
@@ -4385,188 +4385,188 @@ function po(n) {
4385
4385
  const g = h.value, b = /\{\$(\w+)\.(\w+)\?:(.+?):rich(?::[^}]+)?\}/g;
4386
4386
  Array.from(
4387
4387
  g.matchAll(b)
4388
- ).forEach((C) => {
4389
- if (C && C[1] && C[2] && C[3] && !t.has(C[1])) {
4390
- const { defaultValue: F, validation: B } = Fe(C[3]);
4388
+ ).forEach((E) => {
4389
+ if (E && E[1] && E[2] && E[3] && !t.has(E[1])) {
4390
+ const { defaultValue: F, validation: B } = Fe(E[3]);
4391
4391
  e.push({
4392
- fieldName: C[1],
4393
- groupName: C[2],
4392
+ fieldName: E[1],
4393
+ groupName: E[2],
4394
4394
  type: "rich",
4395
4395
  defaultValue: F,
4396
4396
  optional: !0,
4397
4397
  ...B
4398
- }), t.add(C[1]);
4398
+ }), t.add(E[1]);
4399
4399
  }
4400
4400
  });
4401
- const E = /\{\$(\w+)\?:(.+?):rich(?::[^}]+)?\}/g;
4402
- Array.from(g.matchAll(E)).forEach((C) => {
4403
- if (C && C[1] && C[2] && !t.has(C[1])) {
4404
- const { defaultValue: F, validation: B } = Fe(C[2]);
4401
+ const C = /\{\$(\w+)\?:(.+?):rich(?::[^}]+)?\}/g;
4402
+ Array.from(g.matchAll(C)).forEach((E) => {
4403
+ if (E && E[1] && E[2] && !t.has(E[1])) {
4404
+ const { defaultValue: F, validation: B } = Fe(E[2]);
4405
4405
  e.push({
4406
- fieldName: C[1],
4406
+ fieldName: E[1],
4407
4407
  type: "rich",
4408
4408
  defaultValue: F,
4409
4409
  optional: !0,
4410
4410
  ...B
4411
- }), t.add(C[1]);
4411
+ }), t.add(E[1]);
4412
4412
  }
4413
4413
  });
4414
4414
  const T = new RegExp(
4415
4415
  we.RICH_TEXT_FIELD_WITH_GROUP.source,
4416
4416
  we.RICH_TEXT_FIELD_WITH_GROUP.flags
4417
4417
  );
4418
- Array.from(g.matchAll(T)).forEach((C) => {
4419
- if (C && C[1] && C[2] && C[3] && !t.has(C[1])) {
4420
- const { defaultValue: F, validation: B } = Fe(C[3]);
4418
+ Array.from(g.matchAll(T)).forEach((E) => {
4419
+ if (E && E[1] && E[2] && E[3] && !t.has(E[1])) {
4420
+ const { defaultValue: F, validation: B } = Fe(E[3]);
4421
4421
  e.push({
4422
- fieldName: C[1],
4423
- groupName: C[2],
4422
+ fieldName: E[1],
4423
+ groupName: E[2],
4424
4424
  type: "rich",
4425
4425
  defaultValue: F,
4426
4426
  ...B
4427
- }), t.add(C[1]);
4427
+ }), t.add(E[1]);
4428
4428
  }
4429
4429
  });
4430
4430
  const I = new RegExp(
4431
4431
  we.RICH_TEXT_FIELD.source,
4432
4432
  we.RICH_TEXT_FIELD.flags
4433
4433
  );
4434
- Array.from(g.matchAll(I)).forEach((C) => {
4435
- if (C && C[1] && C[2] && !t.has(C[1])) {
4436
- const { defaultValue: F, validation: B } = Fe(C[2]);
4434
+ Array.from(g.matchAll(I)).forEach((E) => {
4435
+ if (E && E[1] && E[2] && !t.has(E[1])) {
4436
+ const { defaultValue: F, validation: B } = Fe(E[2]);
4437
4437
  e.push({
4438
- fieldName: C[1],
4438
+ fieldName: E[1],
4439
4439
  type: "rich",
4440
4440
  defaultValue: F,
4441
4441
  ...B
4442
- }), t.add(C[1]);
4442
+ }), t.add(E[1]);
4443
4443
  }
4444
4444
  });
4445
4445
  const w = /\{\$(\w+)\.(\w+)\?:(.+?):image(?::[^}]+)?\}/g;
4446
4446
  Array.from(
4447
4447
  g.matchAll(w)
4448
- ).forEach((C) => {
4449
- if (C && C[1] && C[2] && C[3] && !t.has(C[1])) {
4450
- const { defaultValue: F, validation: B } = Fe(C[3]);
4448
+ ).forEach((E) => {
4449
+ if (E && E[1] && E[2] && E[3] && !t.has(E[1])) {
4450
+ const { defaultValue: F, validation: B } = Fe(E[3]);
4451
4451
  e.push({
4452
- fieldName: C[1],
4453
- groupName: C[2],
4452
+ fieldName: E[1],
4453
+ groupName: E[2],
4454
4454
  type: "image",
4455
4455
  defaultValue: F,
4456
4456
  optional: !0,
4457
4457
  ...B
4458
- }), t.add(C[1]);
4458
+ }), t.add(E[1]);
4459
4459
  }
4460
4460
  });
4461
4461
  const L = /\{\$(\w+)\?:(.+?):image(?::[^}]+)?\}/g;
4462
- Array.from(g.matchAll(L)).forEach((C) => {
4463
- if (C && C[1] && C[2] && !t.has(C[1])) {
4464
- const { defaultValue: F, validation: B } = Fe(C[2]);
4462
+ Array.from(g.matchAll(L)).forEach((E) => {
4463
+ if (E && E[1] && E[2] && !t.has(E[1])) {
4464
+ const { defaultValue: F, validation: B } = Fe(E[2]);
4465
4465
  e.push({
4466
- fieldName: C[1],
4466
+ fieldName: E[1],
4467
4467
  type: "image",
4468
4468
  defaultValue: F,
4469
4469
  optional: !0,
4470
4470
  ...B
4471
- }), t.add(C[1]);
4471
+ }), t.add(E[1]);
4472
4472
  }
4473
4473
  });
4474
4474
  const P = new RegExp(
4475
4475
  we.IMAGE_FIELD_WITH_GROUP.source,
4476
4476
  we.IMAGE_FIELD_WITH_GROUP.flags
4477
4477
  );
4478
- Array.from(g.matchAll(P)).forEach((C) => {
4479
- if (C && C[1] && C[2] && C[3] && !t.has(C[1])) {
4480
- const { defaultValue: F, validation: B } = Fe(C[3]);
4478
+ Array.from(g.matchAll(P)).forEach((E) => {
4479
+ if (E && E[1] && E[2] && E[3] && !t.has(E[1])) {
4480
+ const { defaultValue: F, validation: B } = Fe(E[3]);
4481
4481
  e.push({
4482
- fieldName: C[1],
4483
- groupName: C[2],
4482
+ fieldName: E[1],
4483
+ groupName: E[2],
4484
4484
  type: "image",
4485
4485
  defaultValue: F,
4486
4486
  ...B
4487
- }), t.add(C[1]);
4487
+ }), t.add(E[1]);
4488
4488
  }
4489
4489
  });
4490
4490
  const $ = new RegExp(
4491
4491
  we.IMAGE_FIELD.source,
4492
4492
  we.IMAGE_FIELD.flags
4493
4493
  );
4494
- Array.from(g.matchAll($)).forEach((C) => {
4495
- if (C && C[1] && C[2] && !t.has(C[1])) {
4496
- const { defaultValue: F, validation: B } = Fe(C[2]);
4494
+ Array.from(g.matchAll($)).forEach((E) => {
4495
+ if (E && E[1] && E[2] && !t.has(E[1])) {
4496
+ const { defaultValue: F, validation: B } = Fe(E[2]);
4497
4497
  e.push({
4498
- fieldName: C[1],
4498
+ fieldName: E[1],
4499
4499
  type: "image",
4500
4500
  defaultValue: F,
4501
4501
  ...B
4502
- }), t.add(C[1]);
4502
+ }), t.add(E[1]);
4503
4503
  }
4504
4504
  });
4505
4505
  const J = /\{\$(\w+)\.(\w+)\?:([^}]+)\}/g;
4506
- Array.from(g.matchAll(J)).forEach((C) => {
4507
- if (C && C[1] && C[2] && C[3] && !t.has(C[1])) {
4508
- const { defaultValue: F, validation: B } = Fe(C[3]);
4506
+ Array.from(g.matchAll(J)).forEach((E) => {
4507
+ if (E && E[1] && E[2] && E[3] && !t.has(E[1])) {
4508
+ const { defaultValue: F, validation: B } = Fe(E[3]);
4509
4509
  e.push({
4510
- fieldName: C[1],
4511
- groupName: C[2],
4510
+ fieldName: E[1],
4511
+ groupName: E[2],
4512
4512
  type: "text",
4513
4513
  defaultValue: F,
4514
4514
  optional: !0,
4515
4515
  ...B
4516
- }), t.add(C[1]);
4516
+ }), t.add(E[1]);
4517
4517
  }
4518
4518
  });
4519
4519
  const Y = /\{\$(\w+)\?:([^}]+)\}/g;
4520
- Array.from(g.matchAll(Y)).forEach((C) => {
4521
- if (C && C[0] && !/:rich(?::[^}]*)?\}$/.test(C[0]) && !/:image(?::[^}]*)?\}$/.test(C[0]) && !/:textarea(?::[^}]*)?\}$/.test(C[0]) && !C[0].includes(".") && C[1] && C[2] && !t.has(C[1])) {
4522
- const { defaultValue: F, validation: B } = Fe(C[2]);
4520
+ Array.from(g.matchAll(Y)).forEach((E) => {
4521
+ if (E && E[0] && !/:rich(?::[^}]*)?\}$/.test(E[0]) && !/:image(?::[^}]*)?\}$/.test(E[0]) && !/:textarea(?::[^}]*)?\}$/.test(E[0]) && !E[0].includes(".") && E[1] && E[2] && !t.has(E[1])) {
4522
+ const { defaultValue: F, validation: B } = Fe(E[2]);
4523
4523
  e.push({
4524
- fieldName: C[1],
4524
+ fieldName: E[1],
4525
4525
  type: "text",
4526
4526
  defaultValue: F,
4527
4527
  optional: !0,
4528
4528
  ...B
4529
- }), t.add(C[1]);
4529
+ }), t.add(E[1]);
4530
4530
  }
4531
4531
  });
4532
4532
  const ae = new RegExp(
4533
4533
  we.TEXT_FIELD_WITH_GROUP.source,
4534
4534
  we.TEXT_FIELD_WITH_GROUP.flags
4535
4535
  );
4536
- Array.from(g.matchAll(ae)).forEach((C) => {
4537
- if (C && C[1] && C[2] && C[3] && !t.has(C[1])) {
4538
- const { defaultValue: F, validation: B } = Fe(C[3]);
4536
+ Array.from(g.matchAll(ae)).forEach((E) => {
4537
+ if (E && E[1] && E[2] && E[3] && !t.has(E[1])) {
4538
+ const { defaultValue: F, validation: B } = Fe(E[3]);
4539
4539
  e.push({
4540
- fieldName: C[1],
4541
- groupName: C[2],
4540
+ fieldName: E[1],
4541
+ groupName: E[2],
4542
4542
  type: "text",
4543
4543
  defaultValue: F,
4544
4544
  ...B
4545
- }), t.add(C[1]);
4545
+ }), t.add(E[1]);
4546
4546
  }
4547
4547
  });
4548
4548
  const ee = new RegExp(
4549
4549
  we.TEXT_FIELD.source,
4550
4550
  we.TEXT_FIELD.flags
4551
4551
  );
4552
- Array.from(g.matchAll(ee)).forEach((C) => {
4553
- if (C && C[0] && !/:rich(?::[^}]*)?\}$/.test(C[0]) && !/:image(?::[^}]*)?\}$/.test(C[0]) && !/:textarea(?::[^}]*)?\}$/.test(C[0]) && !C[0].includes(".") && C[1] && C[2] && !t.has(C[1])) {
4554
- const { defaultValue: F, validation: B } = Fe(C[2]);
4552
+ Array.from(g.matchAll(ee)).forEach((E) => {
4553
+ if (E && E[0] && !/:rich(?::[^}]*)?\}$/.test(E[0]) && !/:image(?::[^}]*)?\}$/.test(E[0]) && !/:textarea(?::[^}]*)?\}$/.test(E[0]) && !E[0].includes(".") && E[1] && E[2] && !t.has(E[1])) {
4554
+ const { defaultValue: F, validation: B } = Fe(E[2]);
4555
4555
  e.push({
4556
- fieldName: C[1],
4556
+ fieldName: E[1],
4557
4557
  type: "text",
4558
4558
  defaultValue: F,
4559
4559
  ...B
4560
- }), t.add(C[1]);
4560
+ }), t.add(E[1]);
4561
4561
  }
4562
4562
  });
4563
4563
  const te = new RegExp(
4564
4564
  we.SELECT_FIELD_WITH_GROUP.source,
4565
4565
  we.SELECT_FIELD_WITH_GROUP.flags
4566
4566
  );
4567
- Array.from(g.matchAll(te)).forEach((C) => {
4568
- if (C && C[1] && C[2] && C[3] && !t.has(C[1])) {
4569
- const F = C[1], B = C[2], S = C[3];
4567
+ Array.from(g.matchAll(te)).forEach((E) => {
4568
+ if (E && E[1] && E[2] && E[3] && !t.has(E[1])) {
4569
+ const F = E[1], B = E[2], S = E[3];
4570
4570
  S.includes("|") ? e.push({
4571
4571
  fieldName: F,
4572
4572
  groupName: B,
@@ -4579,8 +4579,8 @@ function po(n) {
4579
4579
  options: S.split(",")
4580
4580
  }), t.add(F);
4581
4581
  }
4582
- }), (g.match(we.SELECT_FIELD) || []).forEach((C) => {
4583
- const F = C.match(/\(\$(\w+)@:([^)]+)\)/);
4582
+ }), (g.match(we.SELECT_FIELD) || []).forEach((E) => {
4583
+ const F = E.match(/\(\$(\w+)@:([^)]+)\)/);
4584
4584
  if (F && !t.has(F[1])) {
4585
4585
  const B = F[1], S = F[2];
4586
4586
  S.includes("|") ? e.push({
@@ -4600,9 +4600,9 @@ function po(n) {
4600
4600
  );
4601
4601
  Array.from(
4602
4602
  g.matchAll(ke)
4603
- ).forEach((C) => {
4604
- if (C && C[1] && C[2] && C[3] && !t.has(C[1])) {
4605
- const F = C[1], B = C[2], S = C[3];
4603
+ ).forEach((E) => {
4604
+ if (E && E[1] && E[2] && E[3] && !t.has(E[1])) {
4605
+ const F = E[1], B = E[2], S = E[3];
4606
4606
  S.includes("|") ? e.push({
4607
4607
  fieldName: F,
4608
4608
  groupName: B,
@@ -4615,8 +4615,8 @@ function po(n) {
4615
4615
  options: S.split(",")
4616
4616
  }), t.add(F);
4617
4617
  }
4618
- }), (g.match(we.RADIO_FIELD) || []).forEach((C) => {
4619
- const F = C.match(/\(\$(\w+):([^)]+)\)/);
4618
+ }), (g.match(we.RADIO_FIELD) || []).forEach((E) => {
4619
+ const F = E.match(/\(\$(\w+):([^)]+)\)/);
4620
4620
  if (F && !t.has(F[1])) {
4621
4621
  const B = F[1], S = F[2];
4622
4622
  S.includes("|") ? e.push({
@@ -4718,12 +4718,12 @@ function ea(n, e, t, o, r, i = !0, s = [], a = [], l = [], c, d) {
4718
4718
  }
4719
4719
  let ge = ie === void 0 ? "" : typeof ie == "string" ? ie : String(ie || te);
4720
4720
  i || (ge = Nd(ge));
4721
- const ke = w.parentNode, Le = H.index || 0, Ke = y.substring(0, Le), C = y.substring(Le + H[0].length);
4721
+ const ke = w.parentNode, Le = H.index || 0, Ke = y.substring(0, Le), E = y.substring(Le + H[0].length);
4722
4722
  ge ? ge.trim().startsWith("<p") || (ge = `<p>${ge}</p>`) : ge = "";
4723
4723
  const F = p.createElement("div");
4724
4724
  F.innerHTML = ge, Ke && ke.insertBefore(p.createTextNode(Ke), w), Array.from(F.childNodes).forEach((B) => {
4725
4725
  ke.insertBefore(B.cloneNode(!0), w);
4726
- }), C && ke.insertBefore(p.createTextNode(C), w), w.parentNode && w.parentNode.removeChild(w);
4726
+ }), E && ke.insertBefore(p.createTextNode(E), w), w.parentNode && w.parentNode.removeChild(w);
4727
4727
  return;
4728
4728
  }
4729
4729
  let $ = new RegExp(
@@ -4739,22 +4739,22 @@ function ea(n, e, t, o, r, i = !0, s = [], a = [], l = [], c, d) {
4739
4739
  i || (ie = Nd(ie));
4740
4740
  const ge = w.parentNode, ke = $.index || 0, Le = y.substring(0, ke), Ke = y.substring(ke + $[0].length);
4741
4741
  ie ? ie.trim().startsWith("<p") || (ie = `<p>${ie}</p>`) : ie = "<p></p>";
4742
- const C = p.createElement("div");
4743
- C.innerHTML = ie, Le && ge.insertBefore(p.createTextNode(Le), w), Array.from(C.childNodes).forEach((F) => {
4742
+ const E = p.createElement("div");
4743
+ E.innerHTML = ie, Le && ge.insertBefore(p.createTextNode(Le), w), Array.from(E.childNodes).forEach((F) => {
4744
4744
  ge.insertBefore(F.cloneNode(!0), w);
4745
4745
  }), Ke && ge.insertBefore(p.createTextNode(Ke), w), w.parentNode && w.parentNode.removeChild(w);
4746
4746
  return;
4747
4747
  }
4748
4748
  let j = /\{\$(\w+)\.(\w+)\?:(.+?):textarea(?::[^}]+)?\}/.exec(y), Y = !1;
4749
4749
  if (j && w.parentNode ? Y = !0 : j = /\{\$(\w+)\?:(.+?):textarea(?::[^}]+)?\}/.exec(y), j && w.parentNode) {
4750
- const ee = j[1], oe = Y ? j[3] : j[2], { defaultValue: te } = Fe(oe), ie = e[ee], ge = ie === void 0 ? "" : String(ie || te), ke = w.parentNode, Le = j.index || 0, Ke = y.substring(0, Le), C = y.substring(Le + j[0].length);
4750
+ const ee = j[1], oe = Y ? j[3] : j[2], { defaultValue: te } = Fe(oe), ie = e[ee], ge = ie === void 0 ? "" : String(ie || te), ke = w.parentNode, Le = j.index || 0, Ke = y.substring(0, Le), E = y.substring(Le + j[0].length);
4751
4751
  Ke && ke.insertBefore(p.createTextNode(Ke), w);
4752
4752
  const F = ge.split(`
4753
4753
  `);
4754
4754
  if (F.forEach((B, S) => {
4755
4755
  B && ke.insertBefore(p.createTextNode(B), w), S < F.length - 1 && ke.insertBefore(p.createElement("br"), w);
4756
- }), C) {
4757
- const B = p.createTextNode(C);
4756
+ }), E) {
4757
+ const B = p.createTextNode(E);
4758
4758
  ke.insertBefore(B, w), g(B);
4759
4759
  }
4760
4760
  w.parentNode && w.parentNode.removeChild(w);
@@ -4770,10 +4770,10 @@ function ea(n, e, t, o, r, i = !0, s = [], a = [], l = [], c, d) {
4770
4770
  ).exec(y), ae && w.parentNode) {
4771
4771
  const ee = ae[1], oe = se ? ae[3] : ae[2], te = e[ee] ?? oe ?? "", ie = String(te), ge = w.parentNode, ke = ae.index || 0, Le = y.substring(0, ke), Ke = y.substring(ke + ae[0].length);
4772
4772
  Le && ge.insertBefore(p.createTextNode(Le), w);
4773
- const C = ie.split(`
4773
+ const E = ie.split(`
4774
4774
  `);
4775
- if (C.forEach((F, B) => {
4776
- F && ge.insertBefore(p.createTextNode(F), w), B < C.length - 1 && ge.insertBefore(p.createElement("br"), w);
4775
+ if (E.forEach((F, B) => {
4776
+ F && ge.insertBefore(p.createTextNode(F), w), B < E.length - 1 && ge.insertBefore(p.createElement("br"), w);
4777
4777
  }), Ke) {
4778
4778
  const F = p.createTextNode(Ke);
4779
4779
  ge.insertBefore(F, w), g(F);
@@ -9644,8 +9644,8 @@ function d1(n, e, t, o) {
9644
9644
  for (let g = 0; g < s.length; g++) {
9645
9645
  let b = s[(g + l) % s.length], v = !0;
9646
9646
  b < 0 && (v = !1, b = -b);
9647
- let E = r.node(b - 1), k = r.index(b - 1);
9648
- if (E.canReplaceWith(k, k, h.type, h.marks))
9647
+ let C = r.node(b - 1), k = r.index(b - 1);
9648
+ if (C.canReplaceWith(k, k, h.type, h.marks))
9649
9649
  return n.replace(r.before(b), v ? i.after(b) : t, new xe(Dp(o.content, 0, o.openStart, p), p, o.openEnd));
9650
9650
  }
9651
9651
  }
@@ -11105,8 +11105,8 @@ function Yp(n, e, t, o) {
11105
11105
  let v = de.empty;
11106
11106
  for (let k = h.length - 1; k >= 0; k--)
11107
11107
  v = de.from(h[k].copy(v));
11108
- let E = n.tr.step(new zt(e.pos - h.length, e.pos + i.nodeSize, e.pos + b, e.pos + i.nodeSize - b, new xe(v, h.length, 0), 0, !0));
11109
- t(E.scrollIntoView());
11108
+ let C = n.tr.step(new zt(e.pos - h.length, e.pos + i.nodeSize, e.pos + b, e.pos + i.nodeSize - b, new xe(v, h.length, 0), 0, !0));
11109
+ t(C.scrollIntoView());
11110
11110
  }
11111
11111
  return !0;
11112
11112
  }
@@ -14115,8 +14115,8 @@ function ex(n, e, t, o, r, i, s) {
14115
14115
  t.maps[c].forEach((f, p, h, g) => {
14116
14116
  let b = g - h - (p - f);
14117
14117
  for (let v = 0; v < a.length; v += 3) {
14118
- let E = a[v + 1];
14119
- if (E < 0 || f > E + d - u)
14118
+ let C = a[v + 1];
14119
+ if (C < 0 || f > C + d - u)
14120
14120
  continue;
14121
14121
  let k = a[v] + d - u;
14122
14122
  p >= k ? a[v + 1] = f <= k ? -2 : -1 : f >= d && b && (a[v] += b, a[v + 1] += b);
@@ -14469,12 +14469,12 @@ function dx(n, e, t) {
14469
14469
  let { node: o, fromOffset: r, toOffset: i, from: s, to: a } = n.docView.parseRange(e, t), l = n.domSelectionRange(), c, d = l.anchorNode;
14470
14470
  if (d && n.dom.contains(d.nodeType == 1 ? d : d.parentNode) && (c = [{ node: d, offset: l.anchorOffset }], sa(l) || c.push({ node: l.focusNode, offset: l.focusOffset })), Tt && n.input.lastKeyCode === 8)
14471
14471
  for (let b = i; b > r; b--) {
14472
- let v = o.childNodes[b - 1], E = v.pmViewDesc;
14473
- if (v.nodeName == "BR" && !E) {
14472
+ let v = o.childNodes[b - 1], C = v.pmViewDesc;
14473
+ if (v.nodeName == "BR" && !C) {
14474
14474
  i = b;
14475
14475
  break;
14476
14476
  }
14477
- if (!E || E.size)
14477
+ if (!C || C.size)
14478
14478
  break;
14479
14479
  }
14480
14480
  let u = n.state.doc, f = n.someProp("domParser") || jr.fromSchema(n.state.schema), p = u.resolve(s), h = null, g = f.parse(o, {
@@ -14544,8 +14544,8 @@ function px(n, e, t, o, r) {
14544
14544
  return;
14545
14545
  }
14546
14546
  n.state.selection.from < n.state.selection.to && h.start == h.endB && n.state.selection instanceof He && (h.start > n.state.selection.from && h.start <= n.state.selection.from + 2 && n.state.selection.from >= c.from ? h.start = n.state.selection.from : h.endA < n.state.selection.to && h.endA >= n.state.selection.to - 2 && n.state.selection.to <= c.to && (h.endB += n.state.selection.to - h.endA, h.endA = n.state.selection.to)), Xt && mo <= 11 && h.endB == h.start + 1 && h.endA == h.start && h.start > c.from && c.doc.textBetween(h.start - c.from - 1, h.start - c.from + 1) == "  " && (h.start--, h.endA--, h.endB--);
14547
- let g = c.doc.resolveNoCache(h.start - c.from), b = c.doc.resolveNoCache(h.endB - c.from), v = d.resolve(h.start), E = g.sameParent(b) && g.parent.inlineContent && v.end() >= h.endA;
14548
- if ((pr && n.input.lastIOSEnter > Date.now() - 225 && (!E || r.some((x) => x.nodeName == "DIV" || x.nodeName == "P")) || !E && g.pos < c.doc.content.size && (!g.sameParent(b) || !g.parent.inlineContent) && g.pos < b.pos && !/\S/.test(c.doc.textBetween(g.pos, b.pos, "", ""))) && n.someProp("handleKeyDown", (x) => x(n, Oo(13, "Enter")))) {
14547
+ let g = c.doc.resolveNoCache(h.start - c.from), b = c.doc.resolveNoCache(h.endB - c.from), v = d.resolve(h.start), C = g.sameParent(b) && g.parent.inlineContent && v.end() >= h.endA;
14548
+ if ((pr && n.input.lastIOSEnter > Date.now() - 225 && (!C || r.some((x) => x.nodeName == "DIV" || x.nodeName == "P")) || !C && g.pos < c.doc.content.size && (!g.sameParent(b) || !g.parent.inlineContent) && g.pos < b.pos && !/\S/.test(c.doc.textBetween(g.pos, b.pos, "", ""))) && n.someProp("handleKeyDown", (x) => x(n, Oo(13, "Enter")))) {
14549
14549
  n.input.lastIOSEnter = 0;
14550
14550
  return;
14551
14551
  }
@@ -14553,7 +14553,7 @@ function px(n, e, t, o, r) {
14553
14553
  Un && Tt && n.domObserver.suppressSelectionUpdates();
14554
14554
  return;
14555
14555
  }
14556
- Tt && h.endB == h.start && (n.input.lastChromeDelete = Date.now()), Un && !E && g.start() != b.start() && b.parentOffset == 0 && g.depth == b.depth && c.sel && c.sel.anchor == c.sel.head && c.sel.head == h.endA && (h.endB -= 2, b = c.doc.resolveNoCache(h.endB - c.from), setTimeout(() => {
14556
+ Tt && h.endB == h.start && (n.input.lastChromeDelete = Date.now()), Un && !C && g.start() != b.start() && b.parentOffset == 0 && g.depth == b.depth && c.sel && c.sel.anchor == c.sel.head && c.sel.head == h.endA && (h.endB -= 2, b = c.doc.resolveNoCache(h.endB - c.from), setTimeout(() => {
14557
14557
  n.someProp("handleKeyDown", function(x) {
14558
14558
  return x(n, Oo(13, "Enter"));
14559
14559
  });
@@ -14566,7 +14566,7 @@ function px(n, e, t, o, r) {
14566
14566
  }
14567
14567
  return i && w.setMeta("composition", i), w.scrollIntoView();
14568
14568
  }, I;
14569
- if (E)
14569
+ if (C)
14570
14570
  if (g.pos == b.pos) {
14571
14571
  Xt && mo <= 11 && g.parentOffset == 0 && (n.domObserver.suppressSelectionUpdates(), setTimeout(() => Gn(n), 20));
14572
14572
  let x = N(n.state.tr.delete(k, T)), w = d.resolve(h.start).marksAcross(d.resolve(h.endA));
@@ -15645,8 +15645,8 @@ var Kx = (n) => !("type" in n), Jx = (n, e, t) => ({ tr: o, dispatch: r, editor:
15645
15645
  o.insertText(g, d, u);
15646
15646
  } else {
15647
15647
  g = a;
15648
- const b = o.doc.resolve(d), v = b.node(), E = b.parentOffset === 0, k = v.isText || v.isTextblock, T = v.content.size > 0;
15649
- E && k && T && (d = Math.max(0, d - 1)), o.replaceWith(d, u, g);
15648
+ const b = o.doc.resolve(d), v = b.node(), C = b.parentOffset === 0, k = v.isText || v.isTextblock, T = v.content.size > 0;
15649
+ C && k && T && (d = Math.max(0, d - 1)), o.replaceWith(d, u, g);
15650
15650
  }
15651
15651
  t.updateSelection && Gx(o, o.steps.length - 1, -1), t.applyInputRules && o.setMeta("applyInputRules", { from: d, text: g }), t.applyPasteRules && o.setMeta("applyPasteRules", { from: d, text: g });
15652
15652
  }
@@ -16000,8 +16000,8 @@ function Ek(n, e) {
16000
16000
  options: c.options,
16001
16001
  storage: c.storage,
16002
16002
  editor: e
16003
- }, f = n.reduce((v, E) => {
16004
- const k = Ae(E, "extendNodeSchema", u);
16003
+ }, f = n.reduce((v, C) => {
16004
+ const k = Ae(C, "extendNodeSchema", u);
16005
16005
  return {
16006
16006
  ...v,
16007
16007
  ...k ? k(c) : {}
@@ -16043,10 +16043,10 @@ function Ek(n, e) {
16043
16043
  storage: c.storage,
16044
16044
  editor: e
16045
16045
  }, f = n.reduce((b, v) => {
16046
- const E = Ae(v, "extendMarkSchema", u);
16046
+ const C = Ae(v, "extendMarkSchema", u);
16047
16047
  return {
16048
16048
  ...b,
16049
- ...E ? E(c) : {}
16049
+ ...C ? C(c) : {}
16050
16050
  };
16051
16051
  }, {}), p = Du({
16052
16052
  ...f,
@@ -16239,12 +16239,12 @@ function Ol(n, e, t = {}) {
16239
16239
  n.doc.nodesBetween(p, h, (g, b) => {
16240
16240
  if (!g.isText && !g.marks.length)
16241
16241
  return;
16242
- const v = Math.max(p, b), E = Math.min(h, b + g.nodeSize), k = E - v;
16242
+ const v = Math.max(p, b), C = Math.min(h, b + g.nodeSize), k = C - v;
16243
16243
  s += k, a.push(
16244
16244
  ...g.marks.map((T) => ({
16245
16245
  mark: T,
16246
16246
  from: v,
16247
- to: E
16247
+ to: C
16248
16248
  }))
16249
16249
  );
16250
16250
  });
@@ -16468,8 +16468,8 @@ var Wk = ({ keepMarks: n = !0 } = {}) => ({ tr: e, state: t, dispatch: o, editor
16468
16468
  return !1;
16469
16469
  if (r) {
16470
16470
  let v = de.empty;
16471
- const E = l.index(-1) ? 1 : l.index(-2) ? 2 : 3;
16472
- for (let w = l.depth - E; w >= l.depth - 3; w -= 1)
16471
+ const C = l.index(-1) ? 1 : l.index(-2) ? 2 : 3;
16472
+ for (let w = l.depth - C; w >= l.depth - 3; w -= 1)
16473
16473
  v = de.from(l.node(w).copy(v));
16474
16474
  const k = (
16475
16475
  // eslint-disable-next-line no-nested-ternary
@@ -16479,8 +16479,8 @@ var Wk = ({ keepMarks: n = !0 } = {}) => ({ tr: e, state: t, dispatch: o, editor
16479
16479
  ...e
16480
16480
  }, N = ((s = a.contentMatch.defaultType) == null ? void 0 : s.createAndFill(T)) || void 0;
16481
16481
  v = v.append(de.from(a.createAndFill(null, N) || void 0));
16482
- const I = l.before(l.depth - (E - 1));
16483
- t.replace(I, l.after(-k), new xe(v, 4 - E, 0));
16482
+ const I = l.before(l.depth - (C - 1));
16483
+ t.replace(I, l.after(-k), new xe(v, 4 - C, 0));
16484
16484
  let x = -1;
16485
16485
  t.doc.nodesBetween(I, t.doc.content.size, (w, y) => {
16486
16486
  if (x > -1)
@@ -16505,7 +16505,7 @@ var Wk = ({ keepMarks: n = !0 } = {}) => ({ tr: e, state: t, dispatch: o, editor
16505
16505
  if (!qn(t.doc, l.pos, 2))
16506
16506
  return !1;
16507
16507
  if (r) {
16508
- const { selection: v, storedMarks: E } = o, { splittableMarks: k } = i.extensionManager, T = E || v.$to.parentOffset && v.$from.marks();
16508
+ const { selection: v, storedMarks: C } = o, { splittableMarks: k } = i.extensionManager, T = C || v.$to.parentOffset && v.$from.marks();
16509
16509
  if (t.split(l.pos, 2, b).scrollIntoView(), !T || !r)
16510
16510
  return !0;
16511
16511
  const N = T.filter((I) => k.includes(I.type.name));
@@ -16531,7 +16531,7 @@ var Wk = ({ keepMarks: n = !0 } = {}) => ({ tr: e, state: t, dispatch: o, editor
16531
16531
  const r = n.doc.nodeAt(o);
16532
16532
  return t.node.type === r?.type && Co(n.doc, o) && n.join(o), !0;
16533
16533
  }, Gk = (n, e, t, o = {}) => ({ editor: r, tr: i, state: s, dispatch: a, chain: l, commands: c, can: d }) => {
16534
- const { extensions: u, splittableMarks: f } = r.extensionManager, p = vt(n, s.schema), h = vt(e, s.schema), { selection: g, storedMarks: b } = s, { $from: v, $to: E } = g, k = v.blockRange(E), T = b || g.$to.parentOffset && g.$from.marks();
16534
+ const { extensions: u, splittableMarks: f } = r.extensionManager, p = vt(n, s.schema), h = vt(e, s.schema), { selection: g, storedMarks: b } = s, { $from: v, $to: C } = g, k = v.blockRange(C), T = b || g.$to.parentOffset && g.$from.marks();
16535
16535
  if (!k)
16536
16536
  return !1;
16537
16537
  const N = fa((I) => Fu(I.type.name, u))(g);
@@ -16622,14 +16622,14 @@ var Wk = ({ keepMarks: n = !0 } = {}) => ({ tr: e, state: t, dispatch: o, editor
16622
16622
  v < d && i && i === b.type && (l = !0, h = Math.max(v, d), g = Math.min(v + b.nodeSize, u), f = v, p = b), v >= d && v <= u && (i && i === b.type && (l = !0, r && t.setNodeMarkup(v, void 0, {
16623
16623
  ...b.attrs,
16624
16624
  ...e
16625
- })), s && b.marks.length && b.marks.forEach((E) => {
16626
- if (s === E.type && (l = !0, r)) {
16625
+ })), s && b.marks.length && b.marks.forEach((C) => {
16626
+ if (s === C.type && (l = !0, r)) {
16627
16627
  const k = Math.max(v, d), T = Math.min(v + b.nodeSize, u);
16628
16628
  t.addMark(
16629
16629
  k,
16630
16630
  T,
16631
16631
  s.create({
16632
- ...E.attrs,
16632
+ ...C.attrs,
16633
16633
  ...e
16634
16634
  })
16635
16635
  );
@@ -16718,7 +16718,7 @@ function Di(n) {
16718
16718
  }), b = {
16719
16719
  from: o - (p[0].length - i.length),
16720
16720
  to: r
16721
- }, { commands: v, chain: E, can: k } = new da({
16721
+ }, { commands: v, chain: C, can: k } = new da({
16722
16722
  editor: t,
16723
16723
  state: g
16724
16724
  });
@@ -16727,7 +16727,7 @@ function Di(n) {
16727
16727
  range: b,
16728
16728
  match: p,
16729
16729
  commands: v,
16730
- chain: E,
16730
+ chain: C,
16731
16731
  can: k
16732
16732
  }) === null || !h.steps.length || (f.undoable && h.setMeta(a, {
16733
16733
  transform: h,
@@ -16913,10 +16913,10 @@ function uw(n) {
16913
16913
  state: t
16914
16914
  }), u = [];
16915
16915
  return t.doc.nodesBetween(o, r, (p, h) => {
16916
- var g, b, v, E, k;
16916
+ var g, b, v, C, k;
16917
16917
  if ((b = (g = p.type) == null ? void 0 : g.spec) != null && b.code || !(p.isText || p.isTextblock || p.isInline))
16918
16918
  return;
16919
- const T = (k = (E = (v = p.content) == null ? void 0 : v.size) != null ? E : p.nodeSize) != null ? k : 0, N = Math.max(o, h), I = Math.min(r, h + T);
16919
+ const T = (k = (C = (v = p.content) == null ? void 0 : v.size) != null ? C : p.nodeSize) != null ? k : 0, N = Math.max(o, h), I = Math.min(r, h + T);
16920
16920
  if (N >= I)
16921
16921
  return;
16922
16922
  const x = p.isText ? p.text || "" : p.textBetween(N - h, I - h, void 0, "");
@@ -17018,10 +17018,10 @@ function pw(n) {
17018
17018
  }
17019
17019
  },
17020
17020
  appendTransaction: (u, f, p) => {
17021
- const h = u[0], g = h.getMeta("uiEvent") === "paste" && !r, b = h.getMeta("uiEvent") === "drop" && !i, v = h.getMeta("applyPasteRules"), E = !!v;
17022
- if (!g && !b && !E)
17021
+ const h = u[0], g = h.getMeta("uiEvent") === "paste" && !r, b = h.getMeta("uiEvent") === "drop" && !i, v = h.getMeta("applyPasteRules"), C = !!v;
17022
+ if (!g && !b && !C)
17023
17023
  return;
17024
- if (E) {
17024
+ if (C) {
17025
17025
  let { text: N } = v;
17026
17026
  typeof N == "string" ? N = N : N = Cc(de.from(N), p.schema);
17027
17027
  const { from: I } = v, x = I + N.length, w = fw(N);
@@ -17354,7 +17354,7 @@ var mn = class em extends Ac {
17354
17354
  d.steps.forEach((p, h) => {
17355
17355
  var g, b;
17356
17356
  if (p instanceof xn) {
17357
- const v = f.slice(h).map(p.from, -1), E = f.slice(h).map(p.to), k = f.invert().map(v, -1), T = f.invert().map(E), N = (g = d.doc.nodeAt(v - 1)) == null ? void 0 : g.marks.some((x) => x.eq(p.mark)), I = (b = d.doc.nodeAt(E)) == null ? void 0 : b.marks.some((x) => x.eq(p.mark));
17357
+ const v = f.slice(h).map(p.from, -1), C = f.slice(h).map(p.to), k = f.invert().map(v, -1), T = f.invert().map(C), N = (g = d.doc.nodeAt(v - 1)) == null ? void 0 : g.marks.some((x) => x.eq(p.mark)), I = (b = d.doc.nodeAt(C)) == null ? void 0 : b.marks.some((x) => x.eq(p.mark));
17358
17358
  this.editor.emit("delete", {
17359
17359
  type: "mark",
17360
17360
  mark: p.mark,
@@ -17366,7 +17366,7 @@ var mn = class em extends Ac {
17366
17366
  },
17367
17367
  newRange: {
17368
17368
  from: v,
17369
- to: E
17369
+ to: C
17370
17370
  },
17371
17371
  partial: !!(I || N),
17372
17372
  editor: this.editor,
@@ -18334,7 +18334,7 @@ function xw(n) {
18334
18334
  if (!h)
18335
18335
  return;
18336
18336
  const g = h[1] || "", b = o(g);
18337
- if (!s.find((E) => !(E in b)))
18337
+ if (!s.find((C) => !(C in b)))
18338
18338
  return {
18339
18339
  type: e,
18340
18340
  raw: h[0],
@@ -18389,7 +18389,7 @@ function kw(n) {
18389
18389
  const g = new RegExp(`^:::${c}(?:\\s+\\{([^}]*)\\})?\\s*\\n`), b = u.match(g);
18390
18390
  if (!b)
18391
18391
  return;
18392
- const [v, E = ""] = b, k = r(E);
18392
+ const [v, C = ""] = b, k = r(C);
18393
18393
  let T = 1;
18394
18394
  const N = v.length;
18395
18395
  let I = "";
@@ -18501,15 +18501,15 @@ function Ew(n) {
18501
18501
  const g = a ? new RegExp(`^\\[${u}\\s*([^\\]]*)\\]`) : new RegExp(`^\\[${u}\\s*([^\\]]*)\\]([\\s\\S]*?)\\[\\/${u}\\]`), b = f.match(g);
18502
18502
  if (!b)
18503
18503
  return;
18504
- let v = "", E = "";
18504
+ let v = "", C = "";
18505
18505
  if (a) {
18506
18506
  const [, T] = b;
18507
- E = T;
18507
+ C = T;
18508
18508
  } else {
18509
18509
  const [, T, N] = b;
18510
- E = T, v = N || "";
18510
+ C = T, v = N || "";
18511
18511
  }
18512
- const k = r(E.trim());
18512
+ const k = r(C.trim());
18513
18513
  return {
18514
18514
  type: e,
18515
18515
  raw: b[0],
@@ -18567,14 +18567,14 @@ function Pl(n, e, t) {
18567
18567
  else
18568
18568
  break;
18569
18569
  }
18570
- let E;
18570
+ let C;
18571
18571
  const k = v.slice(1);
18572
18572
  if (k.length > 0) {
18573
18573
  const N = k.map((I) => I.slice(g + u)).join(`
18574
18574
  `);
18575
- N.trim() && (e.customNestedParser ? E = e.customNestedParser(N) : E = t.blockTokens(N));
18575
+ N.trim() && (e.customNestedParser ? C = e.customNestedParser(N) : C = t.blockTokens(N));
18576
18576
  }
18577
- const T = e.createToken(h, E);
18577
+ const T = e.createToken(h, C);
18578
18578
  l.push(T);
18579
18579
  }
18580
18580
  if (l.length !== 0)
@@ -20090,12 +20090,12 @@ function SS(n = []) {
20090
20090
  ascii: !0
20091
20091
  }, e), n = n.sort((g, b) => g[0] > b[0] ? 1 : -1);
20092
20092
  for (let g = 0; g < n.length; g++) {
20093
- const b = n[g][0], E = n[g][1] ? {
20093
+ const b = n[g][0], C = n[g][1] ? {
20094
20094
  [bS]: !0
20095
20095
  } : {
20096
20096
  [yS]: !0
20097
20097
  };
20098
- b.indexOf("-") >= 0 ? E[Vl] = !0 : Fn.test(b) ? Vn.test(b) ? E[qr] = !0 : E[Ll] = !0 : E[$l] = !0, Ku(t, b, b, E);
20098
+ b.indexOf("-") >= 0 ? C[Vl] = !0 : Fn.test(b) ? Vn.test(b) ? C[qr] = !0 : C[Ll] = !0 : C[$l] = !0, Ku(t, b, b, C);
20099
20099
  }
20100
20100
  return Ku(t, "localhost", pi, {
20101
20101
  ascii: !0
@@ -20416,12 +20416,12 @@ function TS({
20416
20416
  je(g, n.numeric, Qu);
20417
20417
  const b = pe(s, sn), v = pe(s, Tn);
20418
20418
  pe(b, sn, b), je(b, n.domain, s), je(v, o, i), je(v, n.domain, s);
20419
- const E = rn(Bi);
20420
- je(v, n.tld, E), je(v, n.utld, E), je(E, n.domain, s), je(E, o, i), pe(E, Tn, v), pe(E, sn, b), pe(E, oo, c);
20421
- const k = pe(E, io), T = rn(Bi);
20419
+ const C = rn(Bi);
20420
+ je(v, n.tld, C), je(v, n.utld, C), je(C, n.domain, s), je(C, o, i), pe(C, Tn, v), pe(C, sn, b), pe(C, oo, c);
20421
+ const k = pe(C, io), T = rn(Bi);
20422
20422
  je(k, n.numeric, T);
20423
20423
  const N = rn(Bi), I = rn();
20424
- je(N, e, N), je(N, t, I), je(I, e, N), je(I, t, I), pe(E, zn, N), pe(T, zn, N);
20424
+ je(N, e, N), je(N, t, I), je(I, e, N), je(I, t, I), pe(C, zn, N), pe(T, zn, N);
20425
20425
  const x = pe(a, io), w = pe(l, io), y = pe(w, zn), L = pe(y, zn);
20426
20426
  je(a, n.domain, s), pe(a, Tn, v), pe(a, sn, b), je(l, n.domain, s), pe(l, Tn, v), pe(l, sn, b), je(x, n.domain, N), pe(x, zn, N), pe(x, Xr, N), je(L, n.domain, N), je(L, e, N), pe(L, zn, N);
20427
20427
  const H = [
@@ -20450,7 +20450,7 @@ function TS({
20450
20450
  const j = rn();
20451
20451
  je(X, t), je(J, e, J), je(J, t, j), je(j, e, J), je(j, t, j), pe(J, $, N), pe(j, $, N);
20452
20452
  }
20453
- return pe(r, pi, E), pe(r, Pc, CS), {
20453
+ return pe(r, pi, C), pe(r, Pc, CS), {
20454
20454
  start: r,
20455
20455
  tokens: zm
20456
20456
  };
@@ -20571,7 +20571,7 @@ function DS(n) {
20571
20571
  from: g + v.start + 1,
20572
20572
  to: g + v.end + 1
20573
20573
  })).filter((v) => o.schema.marks.code ? !o.doc.rangeHasMark(v.from, v.to, o.schema.marks.code) : !0).filter((v) => n.validate(v.value)).filter((v) => n.shouldAutoLink(v.value)).forEach((v) => {
20574
- Tc(v.from, v.to, o.doc).some((E) => E.mark.type === n.type) || s.addMark(
20574
+ Tc(v.from, v.to, o.doc).some((C) => C.mark.type === n.type) || s.addMark(
20575
20575
  v.from,
20576
20576
  v.to,
20577
20577
  n.type.create({
@@ -20979,16 +20979,16 @@ const BS = { class: "zcode-rich-text-editor" }, jS = {
20979
20979
  emits: ["update:model-value", "add-image", "delete-image", "close"],
20980
20980
  setup(n, { emit: e }) {
20981
20981
  const { t } = pn(), o = n, r = e, i = fe("common"), s = fe(null), a = fe(o.currentValue || null), l = _e(() => i.value === "common" ? o.imagesCommon : i.value === "individual" ? o.imagesIndividual : o.imagesSpecial), c = _e(() => {
20982
- const E = { add: !1, delete: !1 }, k = o.imageModalActions;
20983
- return k ? i.value === "common" ? { ...E, ...k.common } : i.value === "individual" ? { ...E, ...k.individual } : { ...E, ...k.special } : E;
20984
- }), d = _e(() => c.value.add), u = _e(() => c.value.delete), f = () => o.currentValue && [...o.imagesCommon, ...o.imagesIndividual, ...o.imagesSpecial].find((k) => k.id === o.currentValue) || null, p = (E) => {
20985
- a.value = E.id;
20982
+ const C = { add: !1, delete: !1 }, k = o.imageModalActions;
20983
+ return k ? i.value === "common" ? { ...C, ...k.common } : i.value === "individual" ? { ...C, ...k.individual } : { ...C, ...k.special } : C;
20984
+ }), d = _e(() => c.value.add), u = _e(() => c.value.delete), f = () => o.currentValue && [...o.imagesCommon, ...o.imagesIndividual, ...o.imagesSpecial].find((k) => k.id === o.currentValue) || null, p = (C) => {
20985
+ a.value = C.id;
20986
20986
  }, h = () => {
20987
20987
  a.value && (r("update:model-value", a.value), v());
20988
20988
  }, g = () => {
20989
20989
  a.value && confirm(t("imagesManager.deleteImageFromModalConfirm")) && (r("delete-image", a.value), a.value = null);
20990
- }, b = (E) => {
20991
- const T = E.target.files?.[0];
20990
+ }, b = (C) => {
20991
+ const T = C.target.files?.[0];
20992
20992
  if (!T) return;
20993
20993
  const N = new FileReader();
20994
20994
  N.onload = (I) => {
@@ -21004,7 +21004,7 @@ const BS = { class: "zcode-rich-text-editor" }, jS = {
21004
21004
  }, v = () => {
21005
21005
  r("close");
21006
21006
  };
21007
- return (E, k) => n.isOpen ? (V(), q("div", {
21007
+ return (C, k) => n.isOpen ? (V(), q("div", {
21008
21008
  key: 0,
21009
21009
  class: "zcode-image-modal",
21010
21010
  onClick: Ve(v, ["self"])
@@ -21015,17 +21015,17 @@ const BS = { class: "zcode-rich-text-editor" }, jS = {
21015
21015
  }, ["stop"]))
21016
21016
  }, [
21017
21017
  m("div", US, [
21018
- m("div", WS, R(E.$t("imagesManager.selectImage")), 1),
21018
+ m("div", WS, R(C.$t("imagesManager.selectImage")), 1),
21019
21019
  m("button", {
21020
21020
  class: "zcode-close-btn",
21021
- "aria-label": E.$t("common.close"),
21021
+ "aria-label": C.$t("common.close"),
21022
21022
  onClick: v
21023
21023
  }, [
21024
21024
  le(M(ht), { size: 18 })
21025
21025
  ], 8, qS)
21026
21026
  ]),
21027
21027
  n.currentValue && f() ? (V(), q("div", GS, [
21028
- m("div", KS, R(E.$t("imagesManager.currentlySelected")), 1),
21028
+ m("div", KS, R(C.$t("imagesManager.currentlySelected")), 1),
21029
21029
  m("div", JS, [
21030
21030
  m("img", {
21031
21031
  src: f()?.url,
@@ -21039,16 +21039,16 @@ const BS = { class: "zcode-rich-text-editor" }, jS = {
21039
21039
  m("button", {
21040
21040
  class: Me([{ active: i.value === "common" }, "zcode-image-tab"]),
21041
21041
  onClick: k[0] || (k[0] = (T) => i.value = "common")
21042
- }, R(E.$t("dataViewer.common")), 3),
21042
+ }, R(C.$t("dataViewer.common")), 3),
21043
21043
  m("button", {
21044
21044
  class: Me([{ active: i.value === "individual" }, "zcode-image-tab"]),
21045
21045
  onClick: k[1] || (k[1] = (T) => i.value = "individual")
21046
- }, R(E.$t("dataViewer.individual")), 3),
21046
+ }, R(C.$t("dataViewer.individual")), 3),
21047
21047
  n.imagesSpecial.length > 0 ? (V(), q("button", {
21048
21048
  key: 0,
21049
21049
  class: Me([{ active: i.value === "special" }, "zcode-image-tab"]),
21050
21050
  onClick: k[2] || (k[2] = (T) => i.value = "special")
21051
- }, R(E.$t("dataViewer.special")), 3)) : be("", !0)
21051
+ }, R(C.$t("dataViewer.special")), 3)) : be("", !0)
21052
21052
  ]),
21053
21053
  m("div", ZS, [
21054
21054
  (V(!0), q(Qe, null, ut(l.value, (T) => (V(), q("div", {
@@ -21078,7 +21078,7 @@ const BS = { class: "zcode-rich-text-editor" }, jS = {
21078
21078
  onClick: k[3] || (k[3] = (T) => s.value?.click())
21079
21079
  }, [
21080
21080
  le(M(Lo), { size: 16 }),
21081
- m("span", null, R(E.$t("imagesManager.addImage")), 1)
21081
+ m("span", null, R(C.$t("imagesManager.addImage")), 1)
21082
21082
  ])
21083
21083
  ])) : be("", !0),
21084
21084
  m("div", rE, [
@@ -21088,7 +21088,7 @@ const BS = { class: "zcode-rich-text-editor" }, jS = {
21088
21088
  onClick: h
21089
21089
  }, [
21090
21090
  le(M(Zr), { size: 16 }),
21091
- m("span", null, R(E.$t("imagesManager.select")), 1)
21091
+ m("span", null, R(C.$t("imagesManager.select")), 1)
21092
21092
  ])) : be("", !0),
21093
21093
  a.value && u.value ? (V(), q("button", {
21094
21094
  key: 1,
@@ -21096,7 +21096,7 @@ const BS = { class: "zcode-rich-text-editor" }, jS = {
21096
21096
  onClick: g
21097
21097
  }, [
21098
21098
  le(M(fo), { size: 16 }),
21099
- m("span", null, R(E.$t("common.delete")), 1)
21099
+ m("span", null, R(C.$t("common.delete")), 1)
21100
21100
  ])) : be("", !0)
21101
21101
  ])
21102
21102
  ])
@@ -21235,7 +21235,7 @@ const BS = { class: "zcode-rich-text-editor" }, jS = {
21235
21235
  x.currentValue = "", a("save-field", x);
21236
21236
  }, v = (x) => {
21237
21237
  p.value && (p.value.currentValue = x || "", a("save-field", p.value));
21238
- }, E = (x, w) => {
21238
+ }, C = (x, w) => {
21239
21239
  a("add-image", x, w);
21240
21240
  }, k = (x) => {
21241
21241
  a("delete-image", x), p.value?.currentValue === x && (p.value.currentValue = "", a("save-field", p.value));
@@ -21460,7 +21460,7 @@ const BS = { class: "zcode-rich-text-editor" }, jS = {
21460
21460
  "current-value": p.value?.currentValue || void 0,
21461
21461
  "image-modal-actions": n.imageModalActions,
21462
21462
  "onUpdate:modelValue": v,
21463
- onAddImage: E,
21463
+ onAddImage: C,
21464
21464
  onDeleteImage: k,
21465
21465
  onClose: g
21466
21466
  }, null, 8, ["is-open", "images-common", "images-individual", "images-special", "current-value", "image-modal-actions"])
@@ -21642,7 +21642,7 @@ const BS = { class: "zcode-rich-text-editor" }, jS = {
21642
21642
  () => e.config?.categoryOrder || "common"
21643
21643
  ), o = _e(() => {
21644
21644
  const c = [];
21645
- return t.value === "individual" ? (c.push("individual", "common"), e.hasSpecialParts && c.push("special")) : t.value === "special" ? (e.hasSpecialParts && c.push("special"), c.push("common", "individual")) : (c.push("common", "individual"), e.hasSpecialParts && c.push("special")), c;
21645
+ return t.value === "individual" ? c.push("individual", "common", "special") : t.value === "special" ? c.push("special", "common", "individual") : c.push("common", "individual", "special"), c;
21646
21646
  }), r = fe(!1), i = fe(null);
21647
21647
  function s(c, d) {
21648
21648
  i.value = { type: c, part: d, isActiveParts: !1 }, r.value = !0;
@@ -22406,7 +22406,7 @@ function cT(n, e, t, o) {
22406
22406
  function v(P) {
22407
22407
  a.value = P, l.value = "all", i.value = null, s.value = null, d.value = !1;
22408
22408
  }
22409
- function E(P) {
22409
+ function C(P) {
22410
22410
  if (l.value = P, P === "selected" && c.value && c.value.part_id) {
22411
22411
  const D = n.parts, $ = [...D.common, ...D.individual, ...D.special];
22412
22412
  for (const X of $) {
@@ -22468,20 +22468,20 @@ function cT(n, e, t, o) {
22468
22468
  const ie = te.allowedParts;
22469
22469
  if (ie && ie.length === 1) {
22470
22470
  const ge = ie[0], ke = n.parts, Le = [...ke.common, ...ke.individual, ...ke.special];
22471
- let Ke = null, C = null;
22471
+ let Ke = null, E = null;
22472
22472
  for (const F of Le) {
22473
22473
  const B = F.parts.find((S) => S.id === ge);
22474
22474
  if (B) {
22475
- Ke = F, C = B;
22475
+ Ke = F, E = B;
22476
22476
  break;
22477
22477
  }
22478
22478
  }
22479
- if (Ke && C) {
22479
+ if (Ke && E) {
22480
22480
  const F = x(
22481
22481
  Ke,
22482
22482
  !1,
22483
22483
  $,
22484
- C.id
22484
+ E.id
22485
22485
  );
22486
22486
  ee[oe] = [F];
22487
22487
  } else
@@ -22604,7 +22604,7 @@ function cT(n, e, t, o) {
22604
22604
  hasSpecialParts: H,
22605
22605
  handleAddClick: b,
22606
22606
  handleCategoryTabClick: v,
22607
- handleTypeTabClick: E,
22607
+ handleTypeTabClick: C,
22608
22608
  selectPart: I,
22609
22609
  getPartPreviewHtml: k,
22610
22610
  getClickedComponentPreviewHtml: T,
@@ -22659,12 +22659,12 @@ function dT(n, e, t, o) {
22659
22659
  }
22660
22660
  b = b[v[k]];
22661
22661
  }
22662
- const E = v[v.length - 1];
22662
+ const C = v[v.length - 1];
22663
22663
  if (b && typeof b == "object")
22664
22664
  if (Array.isArray(b)) {
22665
- const k = parseInt(E);
22666
- !isNaN(k) && k >= 0 && k < b.length ? b.splice(k, 1) : console.error("Invalid array index:", E);
22667
- } else E in b ? delete b[E] : console.error("Field not found:", u);
22665
+ const k = parseInt(C);
22666
+ !isNaN(k) && k >= 0 && k < b.length ? b.splice(k, 1) : console.error("Invalid array index:", C);
22667
+ } else C in b ? delete b[C] : console.error("Field not found:", u);
22668
22668
  else
22669
22669
  console.error("Invalid current object:", u);
22670
22670
  }
@@ -22679,9 +22679,9 @@ function dT(n, e, t, o) {
22679
22679
  if (!h || !Array.isArray(h[f])) return;
22680
22680
  const g = h[f];
22681
22681
  if (g.length === 0) {
22682
- const b = p.part_id, v = n.parts, E = [...v.common, ...v.individual];
22682
+ const b = p.part_id, v = n.parts, C = [...v.common, ...v.individual];
22683
22683
  let k = null, T = null;
22684
- for (const I of E) {
22684
+ for (const I of C) {
22685
22685
  const x = I.parts.find((w) => w.id === b);
22686
22686
  if (x) {
22687
22687
  k = I, T = x;
@@ -22695,7 +22695,7 @@ function dT(n, e, t, o) {
22695
22695
  if (I && I.length === 1) {
22696
22696
  const x = I[0];
22697
22697
  let w = null, y = null;
22698
- for (const L of E) {
22698
+ for (const L of C) {
22699
22699
  const H = L.parts.find((P) => P.id === x);
22700
22700
  if (H) {
22701
22701
  w = L, y = H;
@@ -22711,12 +22711,12 @@ function dT(n, e, t, o) {
22711
22711
  }
22712
22712
  }
22713
22713
  function c(u, f) {
22714
- const p = f && u.parts.find((E) => E.id === f) || u.parts[0];
22714
+ const p = f && u.parts.find((C) => C.id === f) || u.parts[0];
22715
22715
  if (!p)
22716
22716
  throw new Error(`Part not found for type: ${u.type}`);
22717
22717
  const h = po(p.body), g = {};
22718
- h.forEach((E) => {
22719
- E.optional ? g[E.fieldName] = void 0 : E.type === "text" ? g[E.fieldName] = E.defaultValue : E.type === "radio" ? g[E.fieldName] = E.options?.[0] : E.type === "checkbox" ? g[E.fieldName] = [] : E.type === "boolean" ? g[E.fieldName] = !0 : E.type === "rich" ? g[E.fieldName] = E.defaultValue ? `<p>${E.defaultValue}</p>` : "<p></p>" : E.type === "image" && (g[E.fieldName] = E.defaultValue || "");
22718
+ h.forEach((C) => {
22719
+ C.optional ? g[C.fieldName] = void 0 : C.type === "text" ? g[C.fieldName] = C.defaultValue : C.type === "radio" ? g[C.fieldName] = C.options?.[0] : C.type === "checkbox" ? g[C.fieldName] = [] : C.type === "boolean" ? g[C.fieldName] = !0 : C.type === "rich" ? g[C.fieldName] = C.defaultValue ? `<p>${C.defaultValue}</p>` : "<p></p>" : C.type === "image" && (g[C.fieldName] = C.defaultValue || "");
22720
22720
  });
22721
22721
  const b = {
22722
22722
  id: ao(),
@@ -22724,7 +22724,7 @@ function dT(n, e, t, o) {
22724
22724
  ...g
22725
22725
  }, v = p.slots;
22726
22726
  if (v) {
22727
- const E = {};
22727
+ const C = {};
22728
22728
  Object.entries(v).forEach(([k, T]) => {
22729
22729
  const N = T.allowedParts;
22730
22730
  if (N && N.length === 1) {
@@ -22739,12 +22739,12 @@ function dT(n, e, t, o) {
22739
22739
  }
22740
22740
  if (y && L) {
22741
22741
  const H = c(y, L.id);
22742
- E[k] = [H];
22742
+ C[k] = [H];
22743
22743
  } else
22744
- E[k] = [];
22744
+ C[k] = [];
22745
22745
  } else
22746
- E[k] = [];
22747
- }), Object.keys(E).length > 0 && (b.slots = E);
22746
+ C[k] = [];
22747
+ }), Object.keys(C).length > 0 && (b.slots = C);
22748
22748
  }
22749
22749
  return b;
22750
22750
  }
@@ -22868,8 +22868,8 @@ function uT(n, e) {
22868
22868
  const g = c[u + 1], b = d[f + 1];
22869
22869
  if (g !== b)
22870
22870
  return !1;
22871
- const v = parseInt(c[c.length - 1]), E = parseInt(d[d.length - 1]);
22872
- if (isNaN(v) || isNaN(E) || v === E)
22871
+ const v = parseInt(c[c.length - 1]), C = parseInt(d[d.length - 1]);
22872
+ if (isNaN(v) || isNaN(C) || v === C)
22873
22873
  return !1;
22874
22874
  const k = In(p, n);
22875
22875
  if (!k || !k.slots || !k.slots[g])
@@ -22883,7 +22883,7 @@ function uT(n, e) {
22883
22883
  else
22884
22884
  return !1;
22885
22885
  const [I] = N.splice(v, 1);
22886
- return N.splice(E, 0, I), !Array.isArray(T) && typeof T == "object" && T.children && (T.children = N), !0;
22886
+ return N.splice(C, 0, I), !Array.isArray(T) && typeof T == "object" && T.children && (T.children = N), !0;
22887
22887
  } else if (c.length > 2 && d.length > 2) {
22888
22888
  const u = c.slice(0, -1).join("."), f = d.slice(0, -1).join(".");
22889
22889
  if (u === f) {
@@ -22964,7 +22964,7 @@ function pT(n, e, t, o, r, i, s, a, l, c, d, u, f, p) {
22964
22964
  function g() {
22965
22965
  if (!e.value) return;
22966
22966
  b();
22967
- const v = e.value.querySelectorAll("[data-zcode-id]"), E = (x) => {
22967
+ const v = e.value.querySelectorAll("[data-zcode-id]"), C = (x) => {
22968
22968
  const w = x.target;
22969
22969
  if (!w) return;
22970
22970
  const y = w.closest("[data-zcode-add-slot]");
@@ -23020,8 +23020,8 @@ function pT(n, e, t, o, r, i, s, a, l, c, d, u, f, p) {
23020
23020
  const P = H.getAttribute("data-zcode-slot-path") || "";
23021
23021
  (!P || !T(P)) && An(H), k === H && (k = null);
23022
23022
  };
23023
- e.value.addEventListener("click", E, !0), e.value.addEventListener("mouseover", N, !0), e.value.addEventListener("mouseout", I, !0), h.set(e.value, [
23024
- { type: "click", listener: E, options: !0 },
23023
+ e.value.addEventListener("click", C, !0), e.value.addEventListener("mouseover", N, !0), e.value.addEventListener("mouseout", I, !0), h.set(e.value, [
23024
+ { type: "click", listener: C, options: !0 },
23025
23025
  { type: "mouseover", listener: N, options: !0 },
23026
23026
  { type: "mouseout", listener: I, options: !0 }
23027
23027
  ]), v.forEach((x) => {
@@ -23133,9 +23133,9 @@ function pT(n, e, t, o, r, i, s, a, l, c, d, u, f, p) {
23133
23133
  });
23134
23134
  }
23135
23135
  function b() {
23136
- h.forEach((v, E) => {
23136
+ h.forEach((v, C) => {
23137
23137
  v.forEach(({ type: k, listener: T, options: N }) => {
23138
- E.removeEventListener(k, T, N);
23138
+ C.removeEventListener(k, T, N);
23139
23139
  });
23140
23140
  }), h.clear();
23141
23141
  }
@@ -23269,10 +23269,10 @@ const bT = {
23269
23269
  d("enableContextMenu", !1, a.cms?.enableContextMenu)
23270
23270
  ), p = fe(
23271
23271
  d("showSaveConfirm", !0, a.cms?.showSaveConfirm)
23272
- ), h = _e(() => u.value), g = fe(!1), { cmsData: b, loadDataFromProps: v, getData: E, setData: k } = _m(o), { fullPageHtml: T, renderComponentToHtml: N } = ta(b, !0);
23272
+ ), h = _e(() => u.value), g = fe(!1), { cmsData: b, loadDataFromProps: v, getData: C, setData: k } = _m(o), { fullPageHtml: T, renderComponentToHtml: N } = ta(b, !0);
23273
23273
  function I(ue) {
23274
23274
  if (ue !== "css")
23275
- return ue ? E(ue) : E();
23275
+ return ue ? C(ue) : C();
23276
23276
  }
23277
23277
  const x = fe(null), w = fe(null), y = _e(() => w.value?.previewArea || null), {
23278
23278
  currentMode: L,
@@ -23318,7 +23318,7 @@ const bT = {
23318
23318
  addSelectedType: ke,
23319
23319
  addSelectedPart: Le,
23320
23320
  clickedComponent: Ke,
23321
- addPartCategory: C,
23321
+ addPartCategory: E,
23322
23322
  addTypeTab: F,
23323
23323
  keepAdding: B,
23324
23324
  availablePartTypes: S,
@@ -23352,7 +23352,7 @@ const bT = {
23352
23352
  J,
23353
23353
  ke,
23354
23354
  Le,
23355
- C,
23355
+ E,
23356
23356
  F,
23357
23357
  Wt
23358
23358
  ), Pn = _e(() => L.value === "edit" && j.value ? j.value : L.value === "add" && ge.value ? ge.value : L.value === "reorder" && De.value ? De.value : L.value === "delete" && qe.value ? qe.value : null), { canSelectParent: U, selectParentElement: W } = fT(
@@ -23678,7 +23678,7 @@ const bT = {
23678
23678
  }, null, 8, ["reorder-source-path", "current-mode", "can-select-parent", "onCancel", "onSelectParent"]),
23679
23679
  le(nT, {
23680
23680
  "add-target-path": M(ge),
23681
- "add-part-category": M(C),
23681
+ "add-part-category": M(E),
23682
23682
  "add-type-tab": M(F),
23683
23683
  "add-selected-part": M(Le),
23684
23684
  "add-selected-type": M(ke),
@@ -24529,11 +24529,11 @@ class IT extends HTMLElement {
24529
24529
  customElements.get("zcode-cms") || customElements.define("zcode-cms", IT);
24530
24530
  function NT(n) {
24531
24531
  const { t: e } = pn(), t = fe("common"), o = fe(null), r = fe(null), i = fe(null), s = fe(null), a = fe(!1), l = fe(null), c = fe(null), { renderComponentToHtml: d } = ta(n, !1), u = _e(() => {
24532
- const C = n.parts;
24533
- return t.value === "common" ? C.common : t.value === "individual" ? C.individual : C.special;
24532
+ const E = n.parts;
24533
+ return t.value === "common" ? E.common : t.value === "individual" ? E.individual : E.special;
24534
24534
  }), f = _e(() => {
24535
- const C = u.value, F = /* @__PURE__ */ new Map();
24536
- return C.forEach((B) => {
24535
+ const E = u.value, F = /* @__PURE__ */ new Map();
24536
+ return E.forEach((B) => {
24537
24537
  F.has(B.type) || F.set(B.type, []), B.parts.forEach((S, Q) => {
24538
24538
  F.get(B.type).push({ type: B, partIndex: Q });
24539
24539
  });
@@ -24547,25 +24547,25 @@ function NT(n) {
24547
24547
  }));
24548
24548
  });
24549
24549
  function p() {
24550
- const C = n.parts;
24551
- return t.value === "common" ? C.common : t.value === "individual" ? C.individual : C.special;
24550
+ const E = n.parts;
24551
+ return t.value === "common" ? E.common : t.value === "individual" ? E.individual : E.special;
24552
24552
  }
24553
- function h(C) {
24554
- return u.value.find((F) => F.type === C) || null;
24553
+ function h(E) {
24554
+ return u.value.find((F) => F.type === E) || null;
24555
24555
  }
24556
- function g(C) {
24557
- return i.value && i.value.partIndex === C && i.value.part.slots || null;
24556
+ function g(E) {
24557
+ return i.value && i.value.partIndex === E && i.value.part.slots || null;
24558
24558
  }
24559
- function b(C, F, B) {
24560
- if (i.value && i.value.partIndex === C) {
24559
+ function b(E, F, B) {
24560
+ if (i.value && i.value.partIndex === E) {
24561
24561
  const S = i.value.part;
24562
24562
  return S.slots || (S.slots = {}), B(S.slots), !0;
24563
24563
  }
24564
24564
  return !1;
24565
24565
  }
24566
- function v(C) {
24566
+ function v(E) {
24567
24567
  const F = {};
24568
- return C.forEach((B) => {
24568
+ return E.forEach((B) => {
24569
24569
  if (B.optional)
24570
24570
  F[B.fieldName] = void 0;
24571
24571
  else
@@ -24591,8 +24591,8 @@ function NT(n) {
24591
24591
  }
24592
24592
  }), F;
24593
24593
  }
24594
- function E(C) {
24595
- o.value = C, r.value = null, a.value = !1;
24594
+ function C(E) {
24595
+ o.value = E, r.value = null, a.value = !1;
24596
24596
  }
24597
24597
  function k() {
24598
24598
  r.value = to({
@@ -24609,21 +24609,21 @@ function NT(n) {
24609
24609
  ]
24610
24610
  }), s.value = "type", a.value = !0, o.value = null;
24611
24611
  }
24612
- function T(C) {
24613
- r.value = to(JSON.parse(JSON.stringify(C))), s.value = "type", a.value = !1, o.value = C;
24612
+ function T(E) {
24613
+ r.value = to(JSON.parse(JSON.stringify(E))), s.value = "type", a.value = !1, o.value = E;
24614
24614
  }
24615
- function N(C, F) {
24616
- const B = C.parts[F];
24615
+ function N(E, F) {
24616
+ const B = E.parts[F];
24617
24617
  if (!B) return;
24618
24618
  const S = JSON.parse(JSON.stringify(B));
24619
24619
  S.slots || (S.slots = {}), i.value = {
24620
- type: to(JSON.parse(JSON.stringify(C))),
24620
+ type: to(JSON.parse(JSON.stringify(E))),
24621
24621
  partIndex: F,
24622
24622
  part: to(S)
24623
24623
  }, s.value = "part";
24624
24624
  }
24625
- async function I(C) {
24626
- const F = h(C.type);
24625
+ async function I(E) {
24626
+ const F = h(E.type);
24627
24627
  if (!F) return;
24628
24628
  const B = to(JSON.parse(JSON.stringify(F))), S = {
24629
24629
  id: ao(),
@@ -24642,10 +24642,10 @@ function NT(n) {
24642
24642
  }
24643
24643
  async function x() {
24644
24644
  if (!r.value) return;
24645
- const C = Ke(r.value);
24646
- if (!C.valid) {
24645
+ const E = Ke(r.value);
24646
+ if (!E.valid) {
24647
24647
  alert(e("partsManager.validationError") + `
24648
- ` + C.errors.join(`
24648
+ ` + E.errors.join(`
24649
24649
  `));
24650
24650
  return;
24651
24651
  }
@@ -24658,8 +24658,8 @@ function NT(n) {
24658
24658
  }
24659
24659
  await Je(), u.value, f.value, r.value = null, s.value = null, a.value = !1;
24660
24660
  }
24661
- function w(C) {
24662
- const F = [], B = C.toLowerCase(), S = ["script", "iframe", "object", "embed"], Q = ["onclick", "onerror", "onload", "onmouseover", "onfocus", "onblur"];
24661
+ function w(E) {
24662
+ const F = [], B = E.toLowerCase(), S = ["script", "iframe", "object", "embed"], Q = ["onclick", "onerror", "onload", "onmouseover", "onfocus", "onblur"];
24663
24663
  return S.forEach((A) => {
24664
24664
  B.includes(`<${A}`) && F.push(e("partsManager.dangerousTagWarning", { tag: A }));
24665
24665
  }), Q.forEach((A) => {
@@ -24671,7 +24671,7 @@ function NT(n) {
24671
24671
  }
24672
24672
  async function y() {
24673
24673
  if (!i.value) return;
24674
- const C = i.value.part.body || "", F = w(C);
24674
+ const E = i.value.part.body || "", F = w(E);
24675
24675
  if (F.hasWarning && !confirm(
24676
24676
  `テンプレートにセキュリティ上注意が必要な記述が含まれています。
24677
24677
 
@@ -24688,28 +24688,28 @@ ${F.messages.join(
24688
24688
  const Q = B[S], A = JSON.parse(JSON.stringify(Uc(i.value.part)));
24689
24689
  i.value.isNewPart ? Q.parts.push(A) : Q.parts[i.value.partIndex] = A, await Je(), u.value, f.value, i.value = null, s.value = null;
24690
24690
  }
24691
- function L(C) {
24692
- const F = u.value.find((B) => B.id === C.id);
24691
+ function L(E) {
24692
+ const F = u.value.find((B) => B.id === E.id);
24693
24693
  if (F) {
24694
- if (C._partIndex !== void 0 && C._partIndex !== null)
24694
+ if (E._partIndex !== void 0 && E._partIndex !== null)
24695
24695
  if (F.parts.length > 1)
24696
- F.parts.splice(C._partIndex, 1);
24696
+ F.parts.splice(E._partIndex, 1);
24697
24697
  else {
24698
- const B = u.value.findIndex((S) => S.id === C.id);
24698
+ const B = u.value.findIndex((S) => S.id === E.id);
24699
24699
  B !== -1 && u.value.splice(B, 1);
24700
24700
  }
24701
24701
  else {
24702
- const B = u.value.findIndex((S) => S.id === C.id);
24702
+ const B = u.value.findIndex((S) => S.id === E.id);
24703
24703
  B !== -1 && u.value.splice(B, 1);
24704
24704
  }
24705
24705
  o.value = null, r.value = null;
24706
24706
  }
24707
24707
  }
24708
- function H(C) {
24708
+ function H(E) {
24709
24709
  const F = [], B = (S, Q) => {
24710
24710
  const A = S.part_id, K = n.parts, ce = [...K.common, ...K.individual];
24711
24711
  for (const Ne of ce)
24712
- if (Ne.parts.find((z) => z.id === A) && Ne.type === C) {
24712
+ if (Ne.parts.find((z) => z.id === A) && Ne.type === E) {
24713
24713
  F.push({ path: Q, component: S });
24714
24714
  break;
24715
24715
  }
@@ -24723,13 +24723,13 @@ ${F.messages.join(
24723
24723
  B(S, `page.${Q}`);
24724
24724
  }), F;
24725
24725
  }
24726
- function P(C, F) {
24726
+ function P(E, F) {
24727
24727
  const B = po(F.body), S = v(B), Q = {
24728
24728
  id: "preview",
24729
24729
  part_id: F.id,
24730
24730
  ...S
24731
24731
  }, A = /* @__PURE__ */ new Set();
24732
- A.add(`${C.id}:${F.id}`);
24732
+ A.add(`${E.id}:${F.id}`);
24733
24733
  const K = F.slots;
24734
24734
  if (K) {
24735
24735
  const ce = {};
@@ -24760,11 +24760,11 @@ ${F.messages.join(
24760
24760
  }
24761
24761
  return Q;
24762
24762
  }
24763
- function D(C, F, B = /* @__PURE__ */ new Set()) {
24764
- const S = F && C.parts.find((Re) => Re.id === F) || C.parts[0];
24763
+ function D(E, F, B = /* @__PURE__ */ new Set()) {
24764
+ const S = F && E.parts.find((Re) => Re.id === F) || E.parts[0];
24765
24765
  if (!S)
24766
- throw new Error(`Part not found for type: ${C.type}`);
24767
- const Q = `${C.id}:${S.id}`;
24766
+ throw new Error(`Part not found for type: ${E.type}`);
24767
+ const Q = `${E.id}:${S.id}`;
24768
24768
  if (B.has(Q)) {
24769
24769
  const Re = po(S.body), z = v(Re);
24770
24770
  return {
@@ -24808,9 +24808,9 @@ ${F.messages.join(
24808
24808
  }
24809
24809
  return ce;
24810
24810
  }
24811
- function $(C, F) {
24811
+ function $(E, F) {
24812
24812
  if (!F) return "";
24813
- const B = P(C, F);
24813
+ const B = P(E, F);
24814
24814
  return ea(
24815
24815
  F.body,
24816
24816
  B,
@@ -24831,10 +24831,10 @@ ${F.messages.join(
24831
24831
  n.images.special
24832
24832
  );
24833
24833
  }
24834
- function X(C) {
24834
+ function X(E) {
24835
24835
  const F = [];
24836
24836
  try {
24837
- const Q = new DOMParser().parseFromString(`<template>${C}</template>`, "text/html").querySelector("template");
24837
+ const Q = new DOMParser().parseFromString(`<template>${E}</template>`, "text/html").querySelector("template");
24838
24838
  if (!Q) return F;
24839
24839
  Q.content.querySelectorAll("[z-slot]").forEach((K) => {
24840
24840
  const ce = K.getAttribute("z-slot") || "default";
@@ -24845,18 +24845,18 @@ ${F.messages.join(
24845
24845
  }
24846
24846
  return F;
24847
24847
  }
24848
- function J(C) {
24849
- if (i.value && i.value.partIndex === C) {
24848
+ function J(E) {
24849
+ if (i.value && i.value.partIndex === E) {
24850
24850
  const F = i.value.part.body, B = X(F), S = Object.keys(i.value.part.slots || {});
24851
24851
  return B.filter((Q) => !S.includes(Q));
24852
24852
  }
24853
24853
  return [];
24854
24854
  }
24855
- function j(C, F) {
24855
+ function j(E, F) {
24856
24856
  let B = F || null;
24857
24857
  if (!B && (B = prompt("スロット名を入力してください:"), !B?.trim()))
24858
24858
  return;
24859
- b(C, B.trim(), (Q) => {
24859
+ b(E, B.trim(), (Q) => {
24860
24860
  if (Q[B.trim()]) {
24861
24861
  alert("このスロット名は既に存在します");
24862
24862
  return;
@@ -24864,56 +24864,56 @@ ${F.messages.join(
24864
24864
  Q[B.trim()] = {};
24865
24865
  }) || alert("パーツが見つかりません");
24866
24866
  }
24867
- function Y(C, F) {
24868
- g(C)?.[F] && confirm(`スロット「${F}」を削除しますか?`) && b(C, F, (S) => {
24867
+ function Y(E, F) {
24868
+ g(E)?.[F] && confirm(`スロット「${F}」を削除しますか?`) && b(E, F, (S) => {
24869
24869
  delete S[F];
24870
24870
  });
24871
24871
  }
24872
- function Z(C, F, B) {
24873
- b(C, F, (Q) => {
24872
+ function Z(E, F, B) {
24873
+ b(E, F, (Q) => {
24874
24874
  Q[F] && (Q[F].allowedParts = B);
24875
24875
  }) || console.warn(`Failed to update allowed parts for slot ${F}`);
24876
24876
  }
24877
- function ae(C, F) {
24877
+ function ae(E, F) {
24878
24878
  if (!l.value) {
24879
- l.value = { type: C.type, partIndex: F };
24879
+ l.value = { type: E.type, partIndex: F };
24880
24880
  return;
24881
24881
  }
24882
- if (l.value.type === C.type && l.value.partIndex === F) {
24882
+ if (l.value.type === E.type && l.value.partIndex === F) {
24883
24883
  oe();
24884
24884
  return;
24885
24885
  }
24886
- const B = l.value, S = { type: C.type, partIndex: F };
24886
+ const B = l.value, S = { type: E.type, partIndex: F };
24887
24887
  if (!se(B, S)) {
24888
24888
  alert("同じタイプ内のパーツのみ並べ替えできます"), oe();
24889
24889
  return;
24890
24890
  }
24891
24891
  ee(B, S), oe();
24892
24892
  }
24893
- function se(C, F) {
24894
- return !(C.type !== F.type || C.partIndex === F.partIndex);
24893
+ function se(E, F) {
24894
+ return !(E.type !== F.type || E.partIndex === F.partIndex);
24895
24895
  }
24896
- function ee(C, F) {
24897
- const B = p(), S = B.findIndex((ce) => ce.type === C.type);
24896
+ function ee(E, F) {
24897
+ const B = p(), S = B.findIndex((ce) => ce.type === E.type);
24898
24898
  if (S === -1) return;
24899
- const A = B[S].parts, [K] = A.splice(C.partIndex, 1);
24899
+ const A = B[S].parts, [K] = A.splice(E.partIndex, 1);
24900
24900
  A.splice(F.partIndex, 0, K);
24901
24901
  }
24902
24902
  function oe() {
24903
24903
  l.value = null;
24904
24904
  }
24905
- function te(C) {
24906
- const F = p(), B = H(C);
24905
+ function te(E) {
24906
+ const F = p(), B = H(E);
24907
24907
  if (B.length > 0) {
24908
- if (!confirm(`タイプ「${C}」は${B.length}箇所で使用されています。削除しますか?`))
24908
+ if (!confirm(`タイプ「${E}」は${B.length}箇所で使用されています。削除しますか?`))
24909
24909
  return;
24910
- } else if (!confirm(`タイプ「${C}」を削除しますか?`))
24910
+ } else if (!confirm(`タイプ「${E}」を削除しますか?`))
24911
24911
  return;
24912
24912
  for (let S = F.length - 1; S >= 0; S--)
24913
- F[S].type === C && F.splice(S, 1);
24913
+ F[S].type === E && F.splice(S, 1);
24914
24914
  }
24915
- function ie(C, F) {
24916
- if (C === F) return;
24915
+ function ie(E, F) {
24916
+ if (E === F) return;
24917
24917
  const B = p(), S = /* @__PURE__ */ new Map(), Q = [];
24918
24918
  B.forEach((Re) => {
24919
24919
  S.has(Re.type) || (S.set(Re.type, []), Q.push(Re.type)), S.get(Re.type).push(Re);
@@ -24921,23 +24921,23 @@ ${F.messages.join(
24921
24921
  const A = Q.map((Re) => ({
24922
24922
  type: Re,
24923
24923
  types: S.get(Re)
24924
- })), K = A.findIndex((Re) => Re.type === C), ce = A.findIndex((Re) => Re.type === F);
24924
+ })), K = A.findIndex((Re) => Re.type === E), ce = A.findIndex((Re) => Re.type === F);
24925
24925
  if (K === -1 || ce === -1) return;
24926
24926
  const [Ne] = A.splice(K, 1);
24927
24927
  A.splice(ce, 0, Ne), B.splice(0, B.length), A.forEach((Re) => {
24928
24928
  Re.types.forEach((z) => B.push(z));
24929
24929
  });
24930
24930
  }
24931
- function ge(C) {
24931
+ function ge(E) {
24932
24932
  if (!c.value) {
24933
- c.value = C;
24933
+ c.value = E;
24934
24934
  return;
24935
24935
  }
24936
- if (c.value === C) {
24936
+ if (c.value === E) {
24937
24937
  c.value = null;
24938
24938
  return;
24939
24939
  }
24940
- ie(c.value, C), c.value = null;
24940
+ ie(c.value, E), c.value = null;
24941
24941
  }
24942
24942
  function ke() {
24943
24943
  r.value = null, s.value = null, a.value = !1;
@@ -24945,15 +24945,15 @@ ${F.messages.join(
24945
24945
  function Le() {
24946
24946
  i.value = null, s.value = null;
24947
24947
  }
24948
- function Ke(C) {
24948
+ function Ke(E) {
24949
24949
  const F = [];
24950
- if (!C.type || C.type.trim() === "")
24950
+ if (!E.type || E.type.trim() === "")
24951
24951
  F.push("タイプ名は必須です");
24952
24952
  else if (a.value) {
24953
24953
  const B = n.parts;
24954
- [...B.common, ...B.individual].some((A) => A.type === C.type.trim()) && F.push(`タイプ「${C.type}」は既に存在します`);
24954
+ [...B.common, ...B.individual].some((A) => A.type === E.type.trim()) && F.push(`タイプ「${E.type}」は既に存在します`);
24955
24955
  }
24956
- return !C.parts || C.parts.length === 0 ? F.push("最低1つのパーツが必要です") : C.parts.forEach((B, S) => {
24956
+ return !E.parts || E.parts.length === 0 ? F.push("最低1つのパーツが必要です") : E.parts.forEach((B, S) => {
24957
24957
  (!B.title || B.title.trim() === "") && F.push(`パーツ ${S + 1} のタイトルは必須です`), (!B.body || B.body.trim() === "") && F.push(`パーツ ${S + 1} のテンプレートは必須です`);
24958
24958
  }), {
24959
24959
  valid: F.length === 0,
@@ -24975,7 +24975,7 @@ ${F.messages.join(
24975
24975
  isCreatingNew: a,
24976
24976
  currentTypes: u,
24977
24977
  groupedPartsByType: f,
24978
- selectType: E,
24978
+ selectType: C,
24979
24979
  startCreating: k,
24980
24980
  startEditingType: T,
24981
24981
  startEditingPart: N,
@@ -25424,23 +25424,23 @@ const wz = { class: "monaco-editor-wrapper" }, Sz = {
25424
25424
  const g = h;
25425
25425
  Array.from(
25426
25426
  document.head.querySelectorAll('style, link[rel="stylesheet"]')
25427
- ).filter((E) => {
25428
- if (E.tagName === "LINK") {
25429
- const T = E.href || "";
25427
+ ).filter((C) => {
25428
+ if (C.tagName === "LINK") {
25429
+ const T = C.href || "";
25430
25430
  return T.includes("monaco") || T.includes("/vs/") || T.includes("vs/");
25431
25431
  }
25432
- const k = E.textContent || "";
25432
+ const k = C.textContent || "";
25433
25433
  return k.includes(".monaco-editor") || k.includes(".monaco-editor-background");
25434
- }).forEach((E) => {
25435
- if (E.tagName === "LINK") {
25436
- const T = E.href;
25434
+ }).forEach((C) => {
25435
+ if (C.tagName === "LINK") {
25436
+ const T = C.href;
25437
25437
  if (!!g.querySelector(`link[rel="stylesheet"][href="${T}"]`)) return;
25438
25438
  } else {
25439
- const T = E.getAttribute("data-name") || "";
25439
+ const T = C.getAttribute("data-name") || "";
25440
25440
  if (T && !!g.querySelector(`style[data-name="${T}"]`))
25441
25441
  return;
25442
25442
  }
25443
- const k = E.cloneNode(!0);
25443
+ const k = C.cloneNode(!0);
25444
25444
  k.setAttribute("data-zcode-monaco-style", "true"), g.appendChild(k), d.push(k);
25445
25445
  });
25446
25446
  }
@@ -25464,13 +25464,13 @@ const wz = { class: "monaco-editor-wrapper" }, Sz = {
25464
25464
  endLineNumber: g.lineNumber,
25465
25465
  startColumn: b.startColumn,
25466
25466
  endColumn: b.endColumn
25467
- }, E = h.getValueInRange({
25467
+ }, C = h.getValueInRange({
25468
25468
  startLineNumber: g.lineNumber,
25469
25469
  startColumn: Math.max(1, g.column - 10),
25470
25470
  endLineNumber: g.lineNumber,
25471
25471
  endColumn: g.column
25472
25472
  }), k = [];
25473
- return (E.endsWith("$") || E.endsWith("{$")) && k.push(
25473
+ return (C.endsWith("$") || C.endsWith("{$")) && k.push(
25474
25474
  // テキストフィールド記法
25475
25475
  {
25476
25476
  label: "{$field:default}",
@@ -25482,7 +25482,7 @@ const wz = { class: "monaco-editor-wrapper" }, Sz = {
25482
25482
  range: {
25483
25483
  startLineNumber: g.lineNumber,
25484
25484
  endLineNumber: g.lineNumber,
25485
- startColumn: g.column - (E.endsWith("{$") ? 2 : 1),
25485
+ startColumn: g.column - (C.endsWith("{$") ? 2 : 1),
25486
25486
  endColumn: g.column
25487
25487
  }
25488
25488
  },
@@ -25497,7 +25497,7 @@ const wz = { class: "monaco-editor-wrapper" }, Sz = {
25497
25497
  range: {
25498
25498
  startLineNumber: g.lineNumber,
25499
25499
  endLineNumber: g.lineNumber,
25500
- startColumn: g.column - (E.endsWith("{$") ? 2 : 1),
25500
+ startColumn: g.column - (C.endsWith("{$") ? 2 : 1),
25501
25501
  endColumn: g.column
25502
25502
  }
25503
25503
  },
@@ -25512,7 +25512,7 @@ const wz = { class: "monaco-editor-wrapper" }, Sz = {
25512
25512
  range: {
25513
25513
  startLineNumber: g.lineNumber,
25514
25514
  endLineNumber: g.lineNumber,
25515
- startColumn: g.column - (E.endsWith("{$") ? 2 : 1),
25515
+ startColumn: g.column - (C.endsWith("{$") ? 2 : 1),
25516
25516
  endColumn: g.column
25517
25517
  }
25518
25518
  },
@@ -25527,11 +25527,11 @@ const wz = { class: "monaco-editor-wrapper" }, Sz = {
25527
25527
  range: {
25528
25528
  startLineNumber: g.lineNumber,
25529
25529
  endLineNumber: g.lineNumber,
25530
- startColumn: g.column - (E.endsWith("{$") ? 2 : 1),
25530
+ startColumn: g.column - (C.endsWith("{$") ? 2 : 1),
25531
25531
  endColumn: g.column
25532
25532
  }
25533
25533
  }
25534
- ), (E.endsWith("(") || E.endsWith("$(")) && k.push(
25534
+ ), (C.endsWith("(") || C.endsWith("$(")) && k.push(
25535
25535
  // ラジオボタン記法
25536
25536
  {
25537
25537
  label: "($field:option1|option2)",
@@ -25543,7 +25543,7 @@ const wz = { class: "monaco-editor-wrapper" }, Sz = {
25543
25543
  range: {
25544
25544
  startLineNumber: g.lineNumber,
25545
25545
  endLineNumber: g.lineNumber,
25546
- startColumn: g.column - (E.endsWith("$(") ? 2 : 1),
25546
+ startColumn: g.column - (C.endsWith("$(") ? 2 : 1),
25547
25547
  endColumn: g.column
25548
25548
  }
25549
25549
  },
@@ -25558,7 +25558,7 @@ const wz = { class: "monaco-editor-wrapper" }, Sz = {
25558
25558
  range: {
25559
25559
  startLineNumber: g.lineNumber,
25560
25560
  endLineNumber: g.lineNumber,
25561
- startColumn: g.column - (E.endsWith("$(") ? 2 : 1),
25561
+ startColumn: g.column - (C.endsWith("$(") ? 2 : 1),
25562
25562
  endColumn: g.column
25563
25563
  }
25564
25564
  },
@@ -25573,7 +25573,7 @@ const wz = { class: "monaco-editor-wrapper" }, Sz = {
25573
25573
  range: {
25574
25574
  startLineNumber: g.lineNumber,
25575
25575
  endLineNumber: g.lineNumber,
25576
- startColumn: g.column - (E.endsWith("$(") ? 2 : 1),
25576
+ startColumn: g.column - (C.endsWith("$(") ? 2 : 1),
25577
25577
  endColumn: g.column
25578
25578
  }
25579
25579
  },
@@ -25588,11 +25588,11 @@ const wz = { class: "monaco-editor-wrapper" }, Sz = {
25588
25588
  range: {
25589
25589
  startLineNumber: g.lineNumber,
25590
25590
  endLineNumber: g.lineNumber,
25591
- startColumn: g.column - (E.endsWith("$(") ? 2 : 1),
25591
+ startColumn: g.column - (C.endsWith("$(") ? 2 : 1),
25592
25592
  endColumn: g.column
25593
25593
  }
25594
25594
  }
25595
- ), (E.endsWith("z-") || E.endsWith(" z-")) && k.push(
25595
+ ), (C.endsWith("z-") || C.endsWith(" z-")) && k.push(
25596
25596
  // z-if属性
25597
25597
  {
25598
25598
  label: 'z-if="show_xxx"',
@@ -25905,7 +25905,7 @@ const wz = { class: "monaco-editor-wrapper" }, Sz = {
25905
25905
  Be || (Be = document.createElement("style"), Be.id = h[he], Be.setAttribute("data-zcode-css", "true"), Be.setAttribute("data-zcode-css-parts-preview", "true"), Be.setAttribute("data-zcode-css-category", he), Be.parentNode || document.head.appendChild(Be), g.set(he, Be)), Be.textContent = ve;
25906
25906
  });
25907
25907
  }
25908
- function E() {
25908
+ function C() {
25909
25909
  g.forEach((U) => {
25910
25910
  U.remove();
25911
25911
  }), g.clear();
@@ -25926,8 +25926,8 @@ const wz = { class: "monaco-editor-wrapper" }, Sz = {
25926
25926
  hl({ enableTemplateSuggestions: U });
25927
25927
  });
25928
25928
  const x = _e(() => o.config?.categoryOrder || "common"), w = _e(() => {
25929
- const U = [], W = o.cmsData.parts.special.length > 0;
25930
- return x.value === "individual" ? (U.push("individual", "common"), W && U.push("special")) : x.value === "special" ? (W && U.push("special"), U.push("common", "individual")) : (U.push("common", "individual"), W && U.push("special")), U;
25929
+ const U = [];
25930
+ return x.value === "individual" ? U.push("individual", "common", "special") : x.value === "special" ? U.push("special", "common", "individual") : U.push("common", "individual", "special"), U;
25931
25931
  }), {
25932
25932
  // 並べ替え
25933
25933
  reorderSourcePart: y,
@@ -25952,7 +25952,7 @@ const wz = { class: "monaco-editor-wrapper" }, Sz = {
25952
25952
  getPartPreviewHtml: ke,
25953
25953
  createTempComponentFromType: Le,
25954
25954
  addPartSlot: Ke,
25955
- removePartSlot: C,
25955
+ removePartSlot: E,
25956
25956
  updatePartSlotAllowedParts: F,
25957
25957
  getAvailableSlotsForPart: B,
25958
25958
  extractSlotsFromTemplate: S,
@@ -25989,7 +25989,7 @@ const wz = { class: "monaco-editor-wrapper" }, Sz = {
25989
25989
  () => z.value,
25990
25990
  (U) => {
25991
25991
  if (!U) {
25992
- E();
25992
+ C();
25993
25993
  return;
25994
25994
  }
25995
25995
  Je(() => {
@@ -26027,10 +26027,10 @@ const wz = { class: "monaco-editor-wrapper" }, Sz = {
26027
26027
  await ee(), !D.value && o.cmsData.css && (H.value === "common" ? o.cmsData.css.common = f.value : H.value === "individual" ? o.cmsData.css.individual = f.value : o.cmsData.css.special = f.value, p.value = f.value);
26028
26028
  }
26029
26029
  function ne() {
26030
- f.value = p.value, E(), r.value = !1, ge();
26030
+ f.value = p.value, C(), r.value = !1, ge();
26031
26031
  }
26032
26032
  Gl(() => {
26033
- E();
26033
+ C();
26034
26034
  }), We(
26035
26035
  () => D.value,
26036
26036
  (U) => {
@@ -26448,7 +26448,7 @@ const wz = { class: "monaco-editor-wrapper" }, Sz = {
26448
26448
  m("div", RA, R(U.$t("partsManager.slot")) + ": " + R(ve), 1),
26449
26449
  m("button", {
26450
26450
  class: "zcode-btn-small",
26451
- onClick: (Be) => M(C)(M(D).partIndex, ve)
26451
+ onClick: (Be) => M(E)(M(D).partIndex, ve)
26452
26452
  }, [
26453
26453
  le(M(fo), { size: 12 })
26454
26454
  ], 8, DA)
@@ -26887,7 +26887,7 @@ function BM(n) {
26887
26887
  t.value = v, o.value = null, r.value = !1;
26888
26888
  }
26889
26889
  function l(v) {
26890
- return new Promise((E, k) => {
26890
+ return new Promise((C, k) => {
26891
26891
  const T = new FileReader();
26892
26892
  T.onload = (N) => {
26893
26893
  const I = N.target?.result, x = {
@@ -26897,7 +26897,7 @@ function BM(n) {
26897
26897
  mimeType: v.type,
26898
26898
  needsUpload: !0
26899
26899
  };
26900
- e.value === "common" ? n.images.common.push(x) : e.value === "individual" ? n.images.individual.push(x) : n.images.special.push(x), E(x);
26900
+ e.value === "common" ? n.images.common.push(x) : e.value === "individual" ? n.images.individual.push(x) : n.images.special.push(x), C(x);
26901
26901
  }, T.onerror = k, T.readAsDataURL(v);
26902
26902
  });
26903
26903
  }
@@ -26921,8 +26921,8 @@ function BM(n) {
26921
26921
  if (!o.value) return;
26922
26922
  let v;
26923
26923
  e.value === "common" ? v = n.images.common : e.value === "individual" ? v = n.images.individual : v = n.images.special;
26924
- const E = v.findIndex((k) => k.id === o.value.id);
26925
- E !== -1 && (v[E] = o.value), o.value = null, r.value = !1;
26924
+ const C = v.findIndex((k) => k.id === o.value.id);
26925
+ C !== -1 && (v[C] = o.value), o.value = null, r.value = !1;
26926
26926
  }
26927
26927
  function f() {
26928
26928
  o.value = null, r.value = !1;
@@ -26941,10 +26941,10 @@ function BM(n) {
26941
26941
  }
26942
26942
  g(i.value, v), b();
26943
26943
  }
26944
- function g(v, E) {
26944
+ function g(v, C) {
26945
26945
  let k;
26946
26946
  e.value === "common" ? k = n.images.common : e.value === "individual" ? k = n.images.individual : k = n.images.special;
26947
- const T = k.findIndex((x) => x.id === v), N = k.findIndex((x) => x.id === E);
26947
+ const T = k.findIndex((x) => x.id === v), N = k.findIndex((x) => x.id === C);
26948
26948
  if (T === -1 || N === -1) return;
26949
26949
  const [I] = k.splice(T, 1);
26950
26950
  k.splice(N, 0, I);
@@ -27005,8 +27005,8 @@ const jM = { class: "zcode-images-manager" }, HM = { class: "zcode-images-catego
27005
27005
  const { t } = pn(), o = n, r = fe(null), i = fe(!1), s = _e(
27006
27006
  () => o.config?.categoryOrder || "common"
27007
27007
  ), a = _e(() => {
27008
- const I = [], x = o.cmsData.images.special.length > 0;
27009
- return s.value === "individual" ? (I.push("individual", "common"), x && I.push("special")) : s.value === "special" ? (x && I.push("special"), I.push("common", "individual")) : (I.push("common", "individual"), x && I.push("special")), I;
27008
+ const I = [];
27009
+ return s.value === "individual" ? I.push("individual", "common", "special") : s.value === "special" ? I.push("special", "common", "individual") : I.push("common", "individual", "special"), I;
27010
27010
  }), {
27011
27011
  // 並べ替え
27012
27012
  reorderSourceImage: l,
@@ -27020,7 +27020,7 @@ const jM = { class: "zcode-images-manager" }, HM = { class: "zcode-images-catego
27020
27020
  startEditing: g,
27021
27021
  saveImage: b,
27022
27022
  cancelEditing: v,
27023
- checkImageUsage: E
27023
+ checkImageUsage: C
27024
27024
  } = BM(o.cmsData);
27025
27025
  o.config?.categoryOrder === "individual" ? d.value = "individual" : o.config?.categoryOrder === "special" && (d.value = "special"), e({
27026
27026
  activeCategory: d
@@ -27039,7 +27039,7 @@ const jM = { class: "zcode-images-manager" }, HM = { class: "zcode-images-catego
27039
27039
  return l.value === I.id && x.push("zcode-reorder-source"), x.join(" ");
27040
27040
  }
27041
27041
  function N(I) {
27042
- const x = E(I.id);
27042
+ const x = C(I.id);
27043
27043
  if (x.length > 0) {
27044
27044
  if (!confirm(t("imagesManager.deleteImageWithUsagesConfirm", { count: x.length })))
27045
27045
  return;
@@ -27249,8 +27249,8 @@ const jM = { class: "zcode-images-manager" }, HM = { class: "zcode-images-catego
27249
27249
  const t = n, o = fe("page"), r = fe("json"), i = fe(!1), s = _e(
27250
27250
  () => t.config?.categoryOrder || "common"
27251
27251
  ), a = _e(() => {
27252
- const E = [], k = o.value === "parts" ? t.cmsData.parts.special.length > 0 : t.cmsData.images.special.length > 0;
27253
- return s.value === "individual" ? (E.push("individual", "common"), k && E.push("special")) : s.value === "special" ? (k && E.push("special"), E.push("common", "individual")) : (E.push("common", "individual"), k && E.push("special")), E;
27252
+ const C = [];
27253
+ return s.value === "individual" ? C.push("individual", "common", "special") : s.value === "special" ? C.push("special", "common", "individual") : C.push("common", "individual", "special"), C;
27254
27254
  }), l = fe(
27255
27255
  t.config?.categoryOrder === "individual" ? "individual" : t.config?.categoryOrder === "special" ? "special" : "common"
27256
27256
  ), { fullPageHtml: c } = ta(t.cmsData, !1), d = _e(() => {
@@ -27268,7 +27268,7 @@ const jM = { class: "zcode-images-manager" }, HM = { class: "zcode-images-catego
27268
27268
  let f = "";
27269
27269
  function p() {
27270
27270
  try {
27271
- const E = d.value, k = JSON.stringify(E, null, 2);
27271
+ const C = d.value, k = JSON.stringify(C, null, 2);
27272
27272
  if (k === f)
27273
27273
  return;
27274
27274
  u.value = k, f = k;
@@ -27276,14 +27276,14 @@ const jM = { class: "zcode-images-manager" }, HM = { class: "zcode-images-catego
27276
27276
  u.value = String(d.value), f = u.value;
27277
27277
  }
27278
27278
  }
27279
- function h(E) {
27280
- let k = E.replace(/\\\\/g, "\0").replace(/\\u([0-9a-fA-F]{4})/g, (T, N) => String.fromCharCode(parseInt(N, 16))).replace(/\\n/g, `
27279
+ function h(C) {
27280
+ let k = C.replace(/\\\\/g, "\0").replace(/\\u([0-9a-fA-F]{4})/g, (T, N) => String.fromCharCode(parseInt(N, 16))).replace(/\\n/g, `
27281
27281
  `).replace(/\\t/g, " ").replace(/\\r/g, "\r").replace(/\\"/g, '"').replace(/\\b/g, "\b").replace(/\\f/g, "\f").replace(/\\\//g, "/").replace(/\u0000/g, "\\");
27282
27282
  return k = k.replace(/&lt;/g, "<").replace(/&gt;/g, ">").replace(/&amp;/g, "&"), k;
27283
27283
  }
27284
- function g(E) {
27285
- if (!E) return "";
27286
- const T = E.replace(/>\s+</g, "><").replace(/></g, `>
27284
+ function g(C) {
27285
+ if (!C) return "";
27286
+ const T = C.replace(/>\s+</g, "><").replace(/></g, `>
27287
27287
  <`).split(`
27288
27288
  `), N = [];
27289
27289
  let I = 0;
@@ -27332,15 +27332,15 @@ const jM = { class: "zcode-images-manager" }, HM = { class: "zcode-images-catego
27332
27332
  l.value = t.config?.categoryOrder === "individual" ? "individual" : "common", p();
27333
27333
  });
27334
27334
  const v = async () => {
27335
- const E = b.value;
27335
+ const C = b.value;
27336
27336
  try {
27337
- await navigator.clipboard.writeText(E), i.value = !0, setTimeout(() => {
27337
+ await navigator.clipboard.writeText(C), i.value = !0, setTimeout(() => {
27338
27338
  i.value = !1;
27339
27339
  }, 2e3);
27340
27340
  } catch (k) {
27341
27341
  console.error("コピーに失敗しました:", k);
27342
27342
  const T = document.createElement("textarea");
27343
- T.value = E, T.style.position = "fixed", T.style.opacity = "0", document.body.appendChild(T), T.select();
27343
+ T.value = C, T.style.position = "fixed", T.style.opacity = "0", document.body.appendChild(T), T.select();
27344
27344
  try {
27345
27345
  document.execCommand("copy"), i.value = !0, setTimeout(() => {
27346
27346
  i.value = !1;
@@ -27354,37 +27354,37 @@ const jM = { class: "zcode-images-manager" }, HM = { class: "zcode-images-catego
27354
27354
  return p(), e({
27355
27355
  internalActiveTab: o,
27356
27356
  activeCategory: l
27357
- }), (E, k) => (V(), q("div", zI, [
27357
+ }), (C, k) => (V(), q("div", zI, [
27358
27358
  m("div", AI, [
27359
27359
  m("div", MI, [
27360
27360
  m("button", {
27361
27361
  class: Me([{ active: o.value === "page" }, "zcode-data-viewer-content-tab"]),
27362
27362
  onClick: k[0] || (k[0] = (T) => o.value = "page")
27363
- }, R(E.$t("dataViewer.page")), 3),
27363
+ }, R(C.$t("dataViewer.page")), 3),
27364
27364
  m("button", {
27365
27365
  class: Me([{ active: o.value === "parts" }, "zcode-data-viewer-content-tab"]),
27366
27366
  onClick: k[1] || (k[1] = (T) => o.value = "parts")
27367
- }, R(E.$t("dataViewer.parts")), 3),
27367
+ }, R(C.$t("dataViewer.parts")), 3),
27368
27368
  m("button", {
27369
27369
  class: Me([{ active: o.value === "images" }, "zcode-data-viewer-content-tab"]),
27370
27370
  onClick: k[2] || (k[2] = (T) => o.value = "images")
27371
- }, R(E.$t("dataViewer.images")), 3)
27371
+ }, R(C.$t("dataViewer.images")), 3)
27372
27372
  ]),
27373
27373
  m("div", II, [
27374
27374
  o.value === "page" ? (V(), q(Qe, { key: 0 }, [
27375
27375
  m("button", {
27376
27376
  class: Me([{ active: r.value === "json" }, "zcode-data-viewer-tab"]),
27377
27377
  onClick: k[3] || (k[3] = (T) => r.value = "json")
27378
- }, R(E.$t("dataViewer.json")), 3),
27378
+ }, R(C.$t("dataViewer.json")), 3),
27379
27379
  m("button", {
27380
27380
  class: Me([{ active: r.value === "html" }, "zcode-data-viewer-tab"]),
27381
27381
  onClick: k[4] || (k[4] = (T) => r.value = "html")
27382
- }, R(E.$t("dataViewer.html")), 3)
27382
+ }, R(C.$t("dataViewer.html")), 3)
27383
27383
  ], 64)) : (V(!0), q(Qe, { key: 1 }, ut(a.value, (T) => (V(), q("button", {
27384
27384
  key: T,
27385
27385
  class: Me([{ active: l.value === T }, "zcode-data-viewer-tab"]),
27386
27386
  onClick: (N) => l.value = T
27387
- }, R(T === "common" ? E.$t("dataViewer.common") : T === "individual" ? E.$t("dataViewer.individual") : E.$t("dataViewer.special")), 11, NI))), 128))
27387
+ }, R(T === "common" ? C.$t("dataViewer.common") : T === "individual" ? C.$t("dataViewer.individual") : C.$t("dataViewer.special")), 11, NI))), 128))
27388
27388
  ])
27389
27389
  ]),
27390
27390
  m("div", _I, [
@@ -27392,7 +27392,7 @@ const jM = { class: "zcode-images-manager" }, HM = { class: "zcode-images-catego
27392
27392
  m("pre", PI, R(b.value), 1),
27393
27393
  m("button", {
27394
27394
  class: "zcode-data-viewer-copy-btn",
27395
- title: i.value ? E.$t("common.copied") : E.$t("common.copy"),
27395
+ title: i.value ? C.$t("common.copied") : C.$t("common.copy"),
27396
27396
  onClick: v
27397
27397
  }, [
27398
27398
  i.value ? (V(), bt(M(Zr), {
@@ -27457,7 +27457,7 @@ const jM = { class: "zcode-images-manager" }, HM = { class: "zcode-images-catego
27457
27457
  special: { ...A.special, ...K.special }
27458
27458
  } : A;
27459
27459
  }
27460
- function E(A) {
27460
+ function C(A) {
27461
27461
  return typeof A == "object" && A !== null;
27462
27462
  }
27463
27463
  function k(A) {
@@ -27467,7 +27467,7 @@ const jM = { class: "zcode-images-manager" }, HM = { class: "zcode-images-catego
27467
27467
  return A === "page" || A === "parts" || A === "images";
27468
27468
  }
27469
27469
  function N(A) {
27470
- if (E(A) && "value" in A)
27470
+ if (C(A) && "value" in A)
27471
27471
  return A.value;
27472
27472
  }
27473
27473
  function I(A) {
@@ -27481,10 +27481,10 @@ const jM = { class: "zcode-images-manager" }, HM = { class: "zcode-images-catego
27481
27481
  if (typeof A == "string") return A;
27482
27482
  }
27483
27483
  function w(A, K) {
27484
- return E(A) && "value" in A ? (A.value = K, !0) : !1;
27484
+ return C(A) && "value" in A ? (A.value = K, !0) : !1;
27485
27485
  }
27486
27486
  function y(A, K) {
27487
- if (E(A))
27487
+ if (C(A))
27488
27488
  return A[K];
27489
27489
  }
27490
27490
  function L(A) {
@@ -27501,7 +27501,7 @@ const jM = { class: "zcode-images-manager" }, HM = { class: "zcode-images-catego
27501
27501
  }
27502
27502
  function P() {
27503
27503
  const A = l.value;
27504
- return !E(A) || !("cmsData" in A) || !("currentMode" in A) || !("switchMode" in A) || !("allowDynamicContentInteraction" in A) || !("settingsPanelOpen" in A) || !("setData" in A) ? null : A;
27504
+ return !C(A) || !("cmsData" in A) || !("currentMode" in A) || !("switchMode" in A) || !("allowDynamicContentInteraction" in A) || !("settingsPanelOpen" in A) || !("setData" in A) ? null : A;
27505
27505
  }
27506
27506
  const D = (A, K, ce) => {
27507
27507
  const Ne = ip();
@@ -27541,7 +27541,7 @@ const jM = { class: "zcode-images-manager" }, HM = { class: "zcode-images-catego
27541
27541
  const ce = A.split(".");
27542
27542
  let Ne = K;
27543
27543
  for (const Re of ce)
27544
- if (!E(Ne) || (Ne = Ne[Re], Ne === void 0)) return;
27544
+ if (!C(Ne) || (Ne = Ne[Re], Ne === void 0)) return;
27545
27545
  return Ne;
27546
27546
  }
27547
27547
  function ie(A, K) {
@@ -27661,7 +27661,7 @@ const jM = { class: "zcode-images-manager" }, HM = { class: "zcode-images-catego
27661
27661
  } else A === "parts-common" ? K = [A, "parts-common-css"] : A === "parts-individual" ? K = [A, "parts-individual-css"] : A === "parts-special" ? K = [A, "parts-special-css"] : K = [A];
27662
27662
  return K;
27663
27663
  }
27664
- function C() {
27664
+ function E() {
27665
27665
  if (!X.value) {
27666
27666
  F();
27667
27667
  return;
@@ -27828,7 +27828,7 @@ const jM = { class: "zcode-images-manager" }, HM = { class: "zcode-images-catego
27828
27828
  s.value === "manage" ? (V(), q("div", WI, [
27829
27829
  m("button", {
27830
27830
  class: "zcode-save-btn",
27831
- onClick: C
27831
+ onClick: E
27832
27832
  }, [
27833
27833
  le(M(hf), { size: 16 }),
27834
27834
  m("span", null, R(A.$t("common.save")), 1)