@pie-element/math-inline 12.1.1-next.17 → 12.1.1-next.18

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.
@@ -32586,8 +32586,8 @@ X.create({
32586
32586
  })) ?? null };
32587
32587
  }
32588
32588
  });
32589
- var Mz = "placeholder", Nz = new q("tiptap__placeholder"), Pz = 200;
32590
- function Fz(e) {
32589
+ var Mz = "placeholder", Nz = new q("tiptap__placeholder");
32590
+ function Pz(e) {
32591
32591
  let { editor: t, placeholder: n, dataAttribute: r, pos: i, node: a, isEmptyDoc: o, hasAnchor: s, classes: { emptyNode: c, emptyEditor: l } } = e, u = [c];
32592
32592
  return o && u.push(l), tm.node(i, i + a.nodeSize, {
32593
32593
  class: u.join(" "),
@@ -32599,156 +32599,198 @@ function Fz(e) {
32599
32599
  }) : n
32600
32600
  });
32601
32601
  }
32602
- function Iz({ editor: e, options: t, dataAttribute: n, doc: r, selection: i }) {
32602
+ function Fz(e, t) {
32603
+ return typeof e == "function" ? e(t) : e;
32604
+ }
32605
+ function Iz({ editor: e, options: t, dataAttribute: n, doc: r, selection: i, from: a, to: o }) {
32606
+ let { anchor: s } = i, c = [], l = e.isEmpty;
32607
+ return r.nodesBetween(a, o, (r, i) => {
32608
+ let a = s >= i && s <= i + r.nodeSize, o = !r.isLeaf && o_(r);
32609
+ return r.type.isTextblock && (a || !t.showOnlyCurrent) && o && c.push(Pz({
32610
+ editor: e,
32611
+ isEmptyDoc: l,
32612
+ dataAttribute: n,
32613
+ hasAnchor: a,
32614
+ placeholder: t.placeholder,
32615
+ classes: {
32616
+ emptyEditor: t.emptyEditorClass,
32617
+ emptyNode: Fz(t.emptyNodeClass, {
32618
+ editor: e,
32619
+ node: r,
32620
+ pos: i,
32621
+ hasAnchor: a
32622
+ })
32623
+ },
32624
+ node: r,
32625
+ pos: i
32626
+ })), t.includeChildren;
32627
+ }), c;
32628
+ }
32629
+ function Lz({ editor: e, options: t, dataAttribute: n, doc: r, selection: i }) {
32603
32630
  if (!(e.isEditable || !t.showOnlyWhenEditable)) return null;
32604
- let { anchor: a } = i, o = [], s = e.isEmpty, c = {
32605
- emptyEditor: t.emptyEditorClass,
32606
- emptyNode: t.emptyNodeClass
32607
- };
32631
+ let { anchor: a } = i, o = [], s = e.isEmpty;
32608
32632
  if (t.showOnlyCurrent && !t.includeChildren) {
32609
- let i = r.resolve(a), l = i.depth > 0 ? i.node(1) : i.nodeAfter, u = i.depth > 0 ? i.before(1) : a;
32610
- if (l && l.type.isTextblock && o_(l)) {
32611
- let r = a >= u && a <= u + l.nodeSize;
32612
- o.push(Fz({
32633
+ let i = r.resolve(a), c = i.depth > 0 ? i.node(1) : i.nodeAfter, l = i.depth > 0 ? i.before(1) : a;
32634
+ if (c && c.type.isTextblock && o_(c)) {
32635
+ let r = a >= l && a <= l + c.nodeSize;
32636
+ o.push(Pz({
32613
32637
  editor: e,
32614
32638
  isEmptyDoc: s,
32615
32639
  dataAttribute: n,
32616
32640
  hasAnchor: r,
32617
32641
  placeholder: t.placeholder,
32618
- classes: c,
32619
- node: l,
32620
- pos: u
32642
+ classes: {
32643
+ emptyEditor: t.emptyEditorClass,
32644
+ emptyNode: Fz(t.emptyNodeClass, {
32645
+ editor: e,
32646
+ node: c,
32647
+ pos: l,
32648
+ hasAnchor: r
32649
+ })
32650
+ },
32651
+ node: c,
32652
+ pos: l
32621
32653
  }));
32622
32654
  }
32623
- } else {
32624
- let i = Nz.getState(e.state), l = i?.topPos ?? 0, u = i?.bottomPos ?? r.content.size;
32625
- r.nodesBetween(l, u, (r, i) => {
32626
- let l = a >= i && a <= i + r.nodeSize, u = !r.isLeaf && o_(r);
32627
- return r.type.isTextblock && (l || !t.showOnlyCurrent) && u && o.push(Fz({
32628
- editor: e,
32629
- isEmptyDoc: s,
32630
- dataAttribute: n,
32631
- hasAnchor: l,
32632
- placeholder: t.placeholder,
32633
- classes: c,
32634
- node: r,
32635
- pos: i
32636
- })), t.includeChildren;
32637
- });
32638
- }
32655
+ } else o.push(...Iz({
32656
+ editor: e,
32657
+ options: t,
32658
+ dataAttribute: n,
32659
+ doc: r,
32660
+ selection: i,
32661
+ from: 0,
32662
+ to: r.content.size
32663
+ }));
32639
32664
  return im.create(r, o);
32640
32665
  }
32641
- function Lz(e) {
32642
- return e.replace(/\s+/g, "-").replace(/[^a-zA-Z0-9-]/g, "").replace(/^[0-9-]+/, "").replace(/^-+/, "").toLowerCase();
32666
+ function Rz(e, t) {
32667
+ let n = e.resolve(t);
32668
+ if (n.depth === 0) {
32669
+ let e = n.nodeAfter ?? n.nodeBefore;
32670
+ if (!e) return {
32671
+ from: t,
32672
+ to: t
32673
+ };
32674
+ let r = n.nodeAfter ? t : t - e.nodeSize;
32675
+ return {
32676
+ from: r,
32677
+ to: r + e.nodeSize
32678
+ };
32679
+ }
32680
+ let r = n.before(1);
32681
+ return {
32682
+ from: r,
32683
+ to: r + n.node(1).nodeSize
32684
+ };
32643
32685
  }
32644
- function Rz(e) {
32645
- let t = getComputedStyle(e), n = `${t.overflow} ${t.overflowY} ${t.overflowX}`;
32646
- return /auto|scroll|overlay/.test(n);
32686
+ function zz(e, t) {
32687
+ return {
32688
+ from: Math.max(0, t.from - 1),
32689
+ to: Math.min(e.content.size, t.to - 1)
32690
+ };
32647
32691
  }
32648
- function zz(e) {
32649
- let t = e;
32650
- for (; t;) {
32651
- if (Rz(t)) return t;
32652
- let e = t.parentElement;
32653
- if (!e) {
32654
- let e = t.getRootNode();
32655
- if (e instanceof ShadowRoot) {
32656
- t = e.host;
32657
- continue;
32658
- }
32659
- return window;
32660
- }
32661
- t = e;
32692
+ function Bz(e, t, n) {
32693
+ let r = [];
32694
+ return e.forEach((e, i) => {
32695
+ let a = i, o = a + e.nodeSize, s = a + 1, c = o + 1;
32696
+ s < n && c > t && r.push({
32697
+ from: a,
32698
+ to: o
32699
+ });
32700
+ }), r;
32701
+ }
32702
+ function Vz(e) {
32703
+ if (e.length === 0) return [];
32704
+ let t = [...e].sort((e, t) => e.from - t.from), n = [{ ...t[0] }];
32705
+ for (let e = 1; e < t.length; e += 1) {
32706
+ let r = n[n.length - 1], i = t[e];
32707
+ i.from <= r.to ? r.to = Math.max(r.to, i.to) : n.push({ ...i });
32662
32708
  }
32663
- return window;
32709
+ return n;
32664
32710
  }
32665
- function Bz(e) {
32666
- return e === window ? {
32667
- top: 0,
32668
- bottom: window.innerHeight
32669
- } : e.getBoundingClientRect();
32711
+ function Hz(e, t) {
32712
+ let n = Bz(e, t.from, t.to);
32713
+ return n.push(zz(e, Rz(e, t.from))), t.to > t.from ? n.push(zz(e, Rz(e, Math.min(t.to, e.content.size + 1) - 1))) : t.from < e.content.size + 1 && n.push(zz(e, Rz(e, Math.min(t.from + 1, e.content.size)))), n;
32670
32714
  }
32671
- function Vz({ doc: e, view: t, scrollContainer: n }) {
32672
- let r = t.dom.getBoundingClientRect(), i = n ? Bz(n) : {
32673
- top: 0,
32674
- bottom: window.innerHeight
32675
- }, a = Math.max(r.top, i.top) - Pz, o = Math.min(r.bottom, i.bottom) + Pz;
32676
- if (a >= o) return {
32677
- top: 0,
32678
- bottom: e.content.size
32679
- };
32680
- let s = getComputedStyle(t.dom).direction === "rtl" ? Math.max(r.right - 2, r.left + 2) : r.left + 2, c = t.posAtCoords({
32681
- left: s,
32682
- top: a + 2
32683
- }), l = t.posAtCoords({
32684
- left: s,
32685
- top: o - 2
32686
- });
32715
+ function Uz(e, t, n) {
32716
+ let r = [];
32717
+ if (e.docChanged) {
32718
+ let t = Yg(e);
32719
+ for (let e of t) r.push(...Hz(n.doc, e.newRange));
32720
+ }
32721
+ return e.selectionSet && (r.push(zz(n.doc, Rz(n.doc, e.mapping.map(t.selection.anchor)))), r.push(zz(n.doc, Rz(n.doc, n.selection.anchor)))), Vz(r);
32722
+ }
32723
+ function Wz(e, t, n) {
32724
+ let r = Math.max(0, Math.min(e, n.content.size));
32687
32725
  return {
32688
- top: c ? c.pos : 0,
32689
- bottom: l ? l.pos : e.content.size
32726
+ from: r,
32727
+ to: Math.max(r, Math.min(t, n.content.size))
32690
32728
  };
32691
32729
  }
32692
- var Hz = {
32693
- init() {
32694
- return {
32695
- topPos: null,
32696
- bottomPos: null
32697
- };
32698
- },
32699
- apply(e, t) {
32700
- let n = e.getMeta(Nz);
32701
- return n?.positions ? {
32702
- topPos: n.positions.top,
32703
- bottomPos: n.positions.bottom
32704
- } : e.docChanged ? {
32705
- topPos: t.topPos === null ? null : e.mapping.map(t.topPos),
32706
- bottomPos: t.bottomPos === null ? null : e.mapping.map(t.bottomPos)
32707
- } : t;
32730
+ function Gz({ decorations: e, ranges: t, editor: n, options: r, dataAttribute: i, doc: a, selection: o }) {
32731
+ let s = e;
32732
+ for (let e of t) {
32733
+ let { from: t, to: c } = Wz(e.from, e.to, a), l = s.find(t, c).filter((e) => e.from >= t && e.to <= c);
32734
+ l.length && (s = s.remove(l));
32735
+ let u = Iz({
32736
+ editor: n,
32737
+ options: r,
32738
+ dataAttribute: i,
32739
+ doc: a,
32740
+ selection: o,
32741
+ from: t,
32742
+ to: c
32743
+ });
32744
+ u.length && (s = s.add(a, u));
32708
32745
  }
32709
- };
32710
- function Uz(e) {
32711
- let t = zz(e.dom), n = () => {
32712
- let n = Vz({
32713
- view: e,
32714
- doc: e.state.doc,
32715
- scrollContainer: t
32716
- }), r = Nz.getState(e.state);
32717
- if (r?.topPos === n.top && r?.bottomPos === n.bottom) return;
32718
- let i = e.state.tr.setMeta(Nz, { positions: n });
32719
- e.dispatch(i);
32720
- }, r = null, i = 0, a = () => {
32721
- r === null && (r = requestAnimationFrame(() => {
32722
- r = null;
32723
- let e = performance.now();
32724
- e - i >= 150 ? (i = e, n()) : a();
32725
- }));
32726
- };
32727
- return t.addEventListener("scroll", a, { passive: !0 }), n(), {
32728
- update(t, n) {
32729
- e.state.doc.content.size !== n.doc.content.size && a();
32746
+ return s;
32747
+ }
32748
+ function Kz({ editor: e, options: t, dataAttribute: n }) {
32749
+ return {
32750
+ init(r, i) {
32751
+ return Lz({
32752
+ editor: e,
32753
+ options: t,
32754
+ dataAttribute: n,
32755
+ doc: i.doc,
32756
+ selection: i.selection
32757
+ }) ?? im.empty;
32730
32758
  },
32731
- destroy: () => {
32732
- r !== null && cancelAnimationFrame(r), t.removeEventListener("scroll", a);
32759
+ apply(r, i, a, o) {
32760
+ return !r.docChanged && !r.selectionSet ? i : Gz({
32761
+ decorations: i.map(r.mapping, r.doc),
32762
+ ranges: Uz(r, a, o),
32763
+ editor: e,
32764
+ options: t,
32765
+ dataAttribute: n,
32766
+ doc: o.doc,
32767
+ selection: o.selection
32768
+ });
32733
32769
  }
32734
32770
  };
32735
32771
  }
32736
- function Wz({ editor: e, options: t }) {
32737
- let n = t.dataAttribute ? `data-${Lz(t.dataAttribute)}` : `data-${Mz}`;
32772
+ function qz(e) {
32773
+ return e.replace(/\s+/g, "-").replace(/[^a-zA-Z0-9-]/g, "").replace(/^[0-9-]+/, "").replace(/^-+/, "").toLowerCase();
32774
+ }
32775
+ function Jz({ editor: e, options: t }) {
32776
+ let n = t.dataAttribute ? `data-${qz(t.dataAttribute)}` : `data-${Mz}`, r = t.showOnlyCurrent && !t.includeChildren;
32738
32777
  return new K({
32739
32778
  key: Nz,
32740
- state: Hz,
32741
- view: Uz,
32742
- props: { decorations: ({ doc: r, selection: i }) => Iz({
32779
+ ...r ? {} : { state: Kz({
32780
+ editor: e,
32781
+ options: t,
32782
+ dataAttribute: n
32783
+ }) },
32784
+ props: { decorations: r ? ({ doc: r, selection: i }) => Lz({
32743
32785
  editor: e,
32744
32786
  options: t,
32745
32787
  dataAttribute: n,
32746
32788
  doc: r,
32747
32789
  selection: i
32748
- }) }
32790
+ }) : (n) => t.showOnlyWhenEditable && !e.isEditable ? im.empty : Nz.getState(n) ?? im.empty }
32749
32791
  });
32750
32792
  }
32751
- var Gz = X.create({
32793
+ var Yz = X.create({
32752
32794
  name: "placeholder",
32753
32795
  addOptions() {
32754
32796
  return {
@@ -32762,12 +32804,25 @@ var Gz = X.create({
32762
32804
  };
32763
32805
  },
32764
32806
  addProseMirrorPlugins() {
32765
- return [Wz({
32807
+ return [Jz({
32766
32808
  editor: this.editor,
32767
32809
  options: this.options
32768
32810
  })];
32769
32811
  }
32770
32812
  });
32813
+ function Xz(e, t) {
32814
+ return !e.selection.empty && !s_(e.selection) && t.isEditable;
32815
+ }
32816
+ function Zz(e, t) {
32817
+ return Xz(e, t) && !t.isFocused && !t.view.dragging;
32818
+ }
32819
+ function Qz() {
32820
+ var e;
32821
+ (e = window.getSelection()) == null || e.removeAllRanges();
32822
+ }
32823
+ function $z(e) {
32824
+ e.focus();
32825
+ }
32771
32826
  X.create({
32772
32827
  name: "selection",
32773
32828
  addOptions() {
@@ -32777,13 +32832,25 @@ X.create({
32777
32832
  let { editor: e, options: t } = this;
32778
32833
  return [new K({
32779
32834
  key: new q("selection"),
32780
- props: { decorations(n) {
32781
- return n.selection.empty || e.isFocused || !e.isEditable || s_(n.selection) || e.view.dragging ? null : im.create(n.doc, [tm.inline(n.selection.from, n.selection.to, { class: t.className })]);
32782
- } }
32835
+ props: {
32836
+ decorations(n) {
32837
+ return Zz(n, e) ? im.create(n.doc, [tm.inline(n.selection.from, n.selection.to, { class: t.className })]) : null;
32838
+ },
32839
+ handleDOMEvents: {
32840
+ blur(t) {
32841
+ return Xz(t.state, e) && Qz(), !1;
32842
+ },
32843
+ focus(t) {
32844
+ return Xz(t.state, e) && requestAnimationFrame(() => {
32845
+ !e.isDestroyed && t.hasFocus() && $z(t);
32846
+ }), !1;
32847
+ }
32848
+ }
32849
+ }
32783
32850
  })];
32784
32851
  }
32785
32852
  });
32786
- function Kz({ types: e, node: t }) {
32853
+ function eB({ types: e, node: t }) {
32787
32854
  return t && Array.isArray(e) && e.includes(t.type) || t?.type === e;
32788
32855
  }
32789
32856
  X.create({
@@ -32805,7 +32872,7 @@ X.create({
32805
32872
  state: {
32806
32873
  init: (e, t) => {
32807
32874
  let r = t.tr.doc.lastChild;
32808
- return !Kz({
32875
+ return !eB({
32809
32876
  node: r,
32810
32877
  types: n
32811
32878
  });
@@ -32813,7 +32880,7 @@ X.create({
32813
32880
  apply: (e, t) => {
32814
32881
  if (!e.docChanged || e.getMeta("__uniqueIDTransaction")) return t;
32815
32882
  let r = e.doc.lastChild;
32816
- return !Kz({
32883
+ return !eB({
32817
32884
  node: r,
32818
32885
  types: n
32819
32886
  });
@@ -32848,7 +32915,7 @@ X.create({
32848
32915
  };
32849
32916
  }
32850
32917
  });
32851
- var qz = W_.create({
32918
+ var tB = W_.create({
32852
32919
  name: "superscript",
32853
32920
  addOptions() {
32854
32921
  return { HTMLAttributes: {} };
@@ -32878,7 +32945,7 @@ var qz = W_.create({
32878
32945
  addKeyboardShortcuts() {
32879
32946
  return { "Mod-.": () => this.editor.commands.toggleSuperscript() };
32880
32947
  }
32881
- }), Jz = W_.create({
32948
+ }), nB = W_.create({
32882
32949
  name: "subscript",
32883
32950
  addOptions() {
32884
32951
  return { HTMLAttributes: {} };
@@ -32908,7 +32975,7 @@ var qz = W_.create({
32908
32975
  addKeyboardShortcuts() {
32909
32976
  return { "Mod-,": () => this.editor.commands.toggleSubscript() };
32910
32977
  }
32911
- }), Yz = X.create({
32978
+ }), rB = X.create({
32912
32979
  name: "textAlign",
32913
32980
  addOptions() {
32914
32981
  return {
@@ -32950,7 +33017,7 @@ var qz = W_.create({
32950
33017
  "Mod-Shift-j": () => this.editor.commands.setTextAlign("justify")
32951
33018
  };
32952
33019
  }
32953
- }), Xz = /(?:^|\s)(!\[(.+|:?)]\((\S+)(?:(?:\s+)["'](\S+)["'])?\))$/, Zz = Dv.create({
33020
+ }), iB = /(?:^|\s)(!\[(.+|:?)]\((\S+)(?:(?:\s+)["'](\S+)["'])?\))$/, aB = Dv.create({
32954
33021
  name: "image",
32955
33022
  addOptions() {
32956
33023
  return {
@@ -33043,7 +33110,7 @@ var qz = W_.create({
33043
33110
  },
33044
33111
  addInputRules() {
33045
33112
  return [pv({
33046
- find: Xz,
33113
+ find: iB,
33047
33114
  type: this.type,
33048
33115
  getAttributes: (e) => {
33049
33116
  let [, , t, n, r] = e;
@@ -33055,17 +33122,17 @@ var qz = W_.create({
33055
33122
  }
33056
33123
  })];
33057
33124
  }
33058
- }), Qz = Gz, $z = {
33125
+ }), oB = Yz, sB = {
33059
33126
  position: "bottom",
33060
33127
  alignment: "left",
33061
33128
  alwaysVisible: !1,
33062
33129
  showDone: !0,
33063
33130
  doneOn: "blur"
33064
- }, eB = {
33131
+ }, cB = {
33065
33132
  options: {},
33066
33133
  respAreaToolbar: () => {},
33067
33134
  onHandleAreaChange: () => {}
33068
- }, tB = [
33135
+ }, lB = [
33069
33136
  "bold",
33070
33137
  "italic",
33071
33138
  "underline",
@@ -33087,7 +33154,7 @@ var qz = W_.create({
33087
33154
  "h3",
33088
33155
  "undo",
33089
33156
  "redo"
33090
- ], nB = {
33157
+ ], uB = {
33091
33158
  "--white": "#fff",
33092
33159
  "--black": "#2e2b29",
33093
33160
  "--black-contrast": "#110f0e",
@@ -33106,14 +33173,18 @@ var qz = W_.create({
33106
33173
  "--red": "#ff5c33",
33107
33174
  "--red-light": "#ffebe5",
33108
33175
  "--shadow": "0px 12px 33px 0px rgba(0, 0, 0, .06),\n 0px 3.618px 9.949px 0px rgba(0, 0, 0, .04)"
33109
- }, rB = (e) => {
33176
+ }, dB = (e) => ({
33177
+ spellcheck: e ? "true" : "false",
33178
+ autocorrect: e ? "on" : "off",
33179
+ autocapitalize: e ? "on" : "off"
33180
+ }), fB = (e) => {
33110
33181
  let { showParagraphs: t, separateParagraphs: n } = e.pluginProps || {}, [r, i] = ct([]), [a, o] = ct(!1), { toolbarOpts: s } = e, c = nt((e) => {
33111
33182
  i((t) => {
33112
33183
  let n = t.filter((t) => t.pos !== e);
33113
33184
  return n.length === 0 && o(!1), n;
33114
33185
  });
33115
33186
  }, [i]), u = {
33116
- ...$z,
33187
+ ...sB,
33117
33188
  ...s
33118
33189
  }, d = nt((t) => {
33119
33190
  let n = t.getHTML();
@@ -33124,13 +33195,13 @@ var qz = W_.create({
33124
33195
  e.onDone,
33125
33196
  u.doneOn
33126
33197
  ]), f = ot(() => ({
33127
- ...eB,
33198
+ ...cB,
33128
33199
  ...e.responseAreaProps,
33129
33200
  onInlineDropdownToolbarClose: d
33130
33201
  }), [e.responseAreaProps, d]), p = ot(() => {
33131
33202
  let { customPlugins: t, ...n } = e.pluginProps || {};
33132
33203
  t ||= [];
33133
- let r = (e.activePlugins || tB)?.filter((e) => {
33204
+ let r = (e.activePlugins || lB)?.filter((e) => {
33134
33205
  let t = Xi[e] || e, r = n[t] || {};
33135
33206
  return !r || !r.disabled;
33136
33207
  });
@@ -33148,103 +33219,112 @@ var qz = W_.create({
33148
33219
  setKeypadInteraction: {},
33149
33220
  media: {}
33150
33221
  });
33151
- }, [e, f.type]), m = ME({
33152
- extensions: [
33153
- Yz.configure({
33154
- types: [
33155
- "heading",
33156
- "paragraph",
33157
- "div",
33158
- "headingParagraph",
33159
- "h1",
33160
- "h2",
33161
- "h3",
33162
- "h4",
33163
- "h5",
33164
- "h6",
33165
- "td",
33166
- "th"
33167
- ],
33168
- alignments: [
33169
- "left",
33170
- "right",
33171
- "center",
33172
- "justify"
33173
- ]
33174
- }),
33175
- Az,
33176
- jz.configure({ limit: e.charactersLimit || 1e6 }),
33177
- bz.configure({ trailingNode: {
33222
+ }, [e, f.type]), m = [
33223
+ rB.configure({
33224
+ types: [
33225
+ "heading",
33226
+ "paragraph",
33227
+ "div",
33228
+ "headingParagraph",
33229
+ "h1",
33230
+ "h2",
33231
+ "h3",
33232
+ "h4",
33233
+ "h5",
33234
+ "h6",
33235
+ "td",
33236
+ "th"
33237
+ ],
33238
+ alignments: [
33239
+ "left",
33240
+ "right",
33241
+ "center",
33242
+ "justify"
33243
+ ]
33244
+ }),
33245
+ Az,
33246
+ jz.configure({ limit: e.charactersLimit || 1e6 }),
33247
+ bz.configure({
33248
+ trailingNode: {
33178
33249
  node: "paragraph",
33179
33250
  notAfter: ["paragraph", "div"]
33180
- } }),
33181
- TA,
33182
- aT,
33183
- EA,
33184
- oT,
33185
- sT,
33186
- Qz.configure({
33187
- placeholder: e.placeholder,
33188
- showOnlyWhenEditable: !0,
33189
- showOnlyCurrent: !1,
33190
- includeChildren: !0
33191
- }),
33192
- tT,
33193
- zw,
33194
- iT,
33195
- rT,
33196
- BO.configure(f),
33197
- VO.configure(f),
33198
- UO.configure(f),
33199
- WO.configure(f),
33200
- HO.configure(f),
33201
- XO.configure({
33202
- toolbarOpts: u,
33203
- math: e.pluginProps?.math || {}
33204
- }),
33205
- Jz,
33206
- qz,
33207
- Zz,
33208
- _k.configure({
33209
- toolbarOpts: u,
33210
- imageHandling: {
33211
- disableImageAlignmentButtons: e.disableImageAlignmentButtons,
33212
- onDone: (t) => e.onDone?.(t.getHTML()),
33213
- onDelete: e.imageSupport && e.imageSupport.delete && ((t) => {
33214
- let { src: n } = t.attrs;
33215
- e.imageSupport.delete(n, (e) => {
33216
- c(t.pos);
33217
- });
33218
- }),
33219
- insertImageRequested: e.imageSupport && ((t, n, r) => {
33220
- let [o, s] = n, u = (n) => {
33221
- let r;
33222
- a && n && (r = e.onChange), c(s), r?.(t.getHTML());
33223
- };
33224
- t._insertingImage = !0, i((e) => [...e, o]), (() => {
33225
- let n = r(u), i = l(() => {
33226
- let e = () => window.removeEventListener("focus", i);
33227
- if (!t._insertingImage) {
33228
- e();
33229
- return;
33230
- }
33231
- c(s), t._insertingImage = !1, e();
33232
- }, 500);
33233
- window.addEventListener("focus", i), e.imageSupport.add(n);
33234
- })();
33235
- }),
33236
- maxImageWidth: e.maxImageWidth,
33237
- maxImageHeight: e.maxImageHeight
33238
- },
33239
- limit: 3
33240
- }),
33241
- Rk.configure({ uploadSoundSupport: e.uploadSoundSupport }),
33242
- Wk.configure({ extraCSSRules: e.extraCSSRules })
33243
- ],
33251
+ },
33252
+ link: {
33253
+ autolink: !1,
33254
+ linkOnPaste: !1
33255
+ }
33256
+ }),
33257
+ TA,
33258
+ aT,
33259
+ EA,
33260
+ oT,
33261
+ sT,
33262
+ oB.configure({
33263
+ placeholder: e.placeholder,
33264
+ showOnlyWhenEditable: !0,
33265
+ showOnlyCurrent: !1,
33266
+ includeChildren: !0
33267
+ }),
33268
+ tT,
33269
+ zw,
33270
+ iT,
33271
+ rT,
33272
+ BO.configure(f),
33273
+ VO.configure(f),
33274
+ UO.configure(f),
33275
+ WO.configure(f),
33276
+ HO.configure(f),
33277
+ XO.configure({
33278
+ toolbarOpts: u,
33279
+ math: e.pluginProps?.math || {}
33280
+ }),
33281
+ nB,
33282
+ tB,
33283
+ aB,
33284
+ _k.configure({
33285
+ toolbarOpts: u,
33286
+ imageHandling: {
33287
+ disableImageAlignmentButtons: e.disableImageAlignmentButtons,
33288
+ onDone: (t) => e.onDone?.(t.getHTML()),
33289
+ onDelete: e.imageSupport && e.imageSupport.delete && ((t) => {
33290
+ let { src: n } = t.attrs;
33291
+ e.imageSupport.delete(n, (e) => {
33292
+ c(t.pos);
33293
+ });
33294
+ }),
33295
+ insertImageRequested: e.imageSupport && ((t, n, r) => {
33296
+ let [o, s] = n, u = (n) => {
33297
+ let r;
33298
+ a && n && (r = e.onChange), c(s), r?.(t.getHTML());
33299
+ };
33300
+ t._insertingImage = !0, i((e) => [...e, o]), (() => {
33301
+ let n = r(u), i = l(() => {
33302
+ let e = () => window.removeEventListener("focus", i);
33303
+ if (!t._insertingImage) {
33304
+ e();
33305
+ return;
33306
+ }
33307
+ c(s), t._insertingImage = !1, e();
33308
+ }, 500);
33309
+ window.addEventListener("focus", i), e.imageSupport.add(n);
33310
+ })();
33311
+ }),
33312
+ maxImageWidth: e.maxImageWidth,
33313
+ maxImageHeight: e.maxImageHeight
33314
+ },
33315
+ limit: 3
33316
+ }),
33317
+ Rk.configure({ uploadSoundSupport: e.uploadSoundSupport }),
33318
+ Wk.configure({ extraCSSRules: e.extraCSSRules })
33319
+ ], h = e.spellCheck !== !1, g = ME({
33320
+ extensions: m,
33244
33321
  immediatelyRender: !1,
33245
- editorProps: { handleKeyDown(t, n) {
33246
- return e.onKeyDown ? e.onKeyDown(n) : !1;
33247
- } },
33322
+ editorProps: {
33323
+ attributes: dB(h),
33324
+ handleKeyDown(t, n) {
33325
+ return e.onKeyDown ? e.onKeyDown(n) : !1;
33326
+ }
33327
+ },
33248
33328
  editable: !e.disabled,
33249
33329
  content: ta(e.markup),
33250
33330
  onUpdate: ({ editor: t, transaction: n }) => {
@@ -33255,22 +33335,29 @@ var qz = W_.create({
33255
33335
  }
33256
33336
  }, [e.charactersLimit]);
33257
33337
  L(() => {
33258
- e.editorRef && e.editorRef(m);
33259
- }, [e.editorRef, m]), L(() => {
33260
- m?.setEditable(!e.disabled);
33261
- }, [e.disabled, m]), L(() => {
33262
- if (!m) return;
33338
+ e.editorRef && e.editorRef(g);
33339
+ }, [e.editorRef, g]), L(() => {
33340
+ g?.setEditable(!e.disabled);
33341
+ }, [e.disabled, g]), L(() => {
33342
+ if (!g) return;
33343
+ let e = g.options?.editorProps, t = dB(h);
33344
+ e?.attributes?.spellcheck !== t.spellcheck && g.setOptions({ editorProps: {
33345
+ ...e,
33346
+ attributes: t
33347
+ } });
33348
+ }, [h, g]), L(() => {
33349
+ if (!g) return;
33263
33350
  let t = ta(e.markup);
33264
- t !== m.getHTML() && m.commands.setContent(t, { emitUpdate: !1 });
33265
- }, [e.markup, m]), L(() => {
33266
- Object.entries(nB).forEach(([e, t]) => {
33351
+ t !== g.getHTML() && g.commands.setContent(t, { emitUpdate: !1 });
33352
+ }, [e.markup, g]), L(() => {
33353
+ Object.entries(uB).forEach(([e, t]) => {
33267
33354
  document.documentElement.style.setProperty(e, t);
33268
33355
  });
33269
33356
  }, []);
33270
- let h = OE({
33271
- editor: m,
33357
+ let _ = OE({
33358
+ editor: g,
33272
33359
  selector: (e) => ({ isFocused: e.editor?.isFocused })
33273
- }), g = ot(() => {
33360
+ }), v = ot(() => {
33274
33361
  let { minWidth: t, width: n, maxWidth: r, minHeight: i, height: a, maxHeight: o } = e;
33275
33362
  return {
33276
33363
  width: DA(n),
@@ -33285,20 +33372,20 @@ var qz = W_.create({
33285
33372
  ...e,
33286
33373
  activePlugins: p,
33287
33374
  toolbarOpts: u,
33288
- editorState: h,
33289
- editor: m,
33290
- children: m && /* @__PURE__ */ R(iB, {
33375
+ editorState: _,
33376
+ editor: g,
33377
+ children: g && /* @__PURE__ */ R(pB, {
33291
33378
  style: {
33292
- minHeight: g.minHeight,
33293
- height: g.height,
33294
- maxHeight: g.maxHeight
33379
+ minHeight: v.minHeight,
33380
+ height: v.height,
33381
+ maxHeight: v.maxHeight
33295
33382
  },
33296
33383
  showParagraph: t && !t.disabled,
33297
33384
  separateParagraph: n && !n.disabled,
33298
- editor: m
33385
+ editor: g
33299
33386
  })
33300
33387
  });
33301
- }, iB = M(TE, { shouldForwardProp: (e) => !["showParagraph", "separateParagraph"].includes(e) })(({ showParagraph: e, separateParagraph: t }) => ({
33388
+ }, pB = M(TE, { shouldForwardProp: (e) => !["showParagraph", "separateParagraph"].includes(e) })(({ showParagraph: e, separateParagraph: t }) => ({
33302
33389
  display: "flex",
33303
33390
  outline: "none !important",
33304
33391
  "& .ProseMirror": {
@@ -33326,26 +33413,26 @@ var qz = W_.create({
33326
33413
  } },
33327
33414
  ...t && { "& > p:has(+ p)": { marginBottom: "1em" } }
33328
33415
  }
33329
- })), aB = rB;
33416
+ })), mB = fB;
33330
33417
  //#endregion
33331
33418
  //#region ../../lib-react/config-ui/dist/feedback-config/feedback-selector.js
33332
- function oB(e) {
33419
+ function hB(e) {
33333
33420
  return typeof e == "function" || typeof e == "object" && !!e && typeof e.$$typeof == "symbol";
33334
33421
  }
33335
- function sB(e, t) {
33336
- return !e || oB(e) ? e : oB(e.default) ? e.default : t && oB(e[t]) ? e[t] : t && oB(e[t]?.default) ? e[t].default : e;
33422
+ function gB(e, t) {
33423
+ return !e || hB(e) ? e : hB(e.default) ? e.default : t && hB(e[t]) ? e[t] : t && hB(e[t]?.default) ? e[t].default : e;
33337
33424
  }
33338
- var cB = sB(y, "InputContainer") || sB(dB.InputContainer, "InputContainer"), lB = Ue, uB = lB.default, dB = uB && typeof uB == "object" ? uB : lB, fB = M(aB)(({ theme: e }) => ({ fontFamily: e.typography.fontFamily })), pB = {
33425
+ var _B = gB(y, "InputContainer") || gB(bB.InputContainer, "InputContainer"), vB = Ue, yB = vB.default, bB = yB && typeof yB == "object" ? yB : vB, xB = M(mB)(({ theme: e }) => ({ fontFamily: e.typography.fontFamily })), SB = {
33339
33426
  default: "Simple Feedback",
33340
33427
  none: "No Feedback",
33341
33428
  custom: "Customized Feedback"
33342
- }, mB = M("div")(({ theme: e }) => ({ marginBottom: e.spacing(1) })), hB = M(cB)(() => ({ paddingBottom: 0 })), gB = M("div")(({ theme: e }) => ({
33429
+ }, CB = M("div")(({ theme: e }) => ({ marginBottom: e.spacing(1) })), wB = M(_B)(() => ({ paddingBottom: 0 })), TB = M("div")(({ theme: e }) => ({
33343
33430
  marginTop: "0px",
33344
33431
  background: A.backgroundDark(),
33345
33432
  padding: 0,
33346
33433
  marginBottom: e.spacing(2),
33347
33434
  borderRadius: "4px"
33348
- })), _B = M("div")(({ theme: e }) => ({
33435
+ })), EB = M("div")(({ theme: e }) => ({
33349
33436
  marginTop: "0px",
33350
33437
  background: A.backgroundDark(),
33351
33438
  padding: e.spacing(2),
@@ -33353,7 +33440,7 @@ var cB = sB(y, "InputContainer") || sB(dB.InputContainer, "InputContainer"), lB
33353
33440
  borderRadius: "4px",
33354
33441
  fontFamily: e.typography.fontFamily,
33355
33442
  cursor: "default"
33356
- })), vB = M(qi)(({ theme: e }) => ({ paddingTop: e.spacing(1) })), yB = {
33443
+ })), DB = M(qi)(({ theme: e }) => ({ paddingTop: e.spacing(1) })), OB = {
33357
33444
  type: B.default.oneOf([
33358
33445
  "default",
33359
33446
  "custom",
@@ -33361,11 +33448,11 @@ var cB = sB(y, "InputContainer") || sB(dB.InputContainer, "InputContainer"), lB
33361
33448
  ]),
33362
33449
  default: B.default.string,
33363
33450
  custom: B.default.string
33364
- }, bB = class extends I.Component {
33451
+ }, kB = class extends I.Component {
33365
33452
  static propTypes = {
33366
33453
  keys: B.default.arrayOf(B.default.string),
33367
33454
  label: B.default.string.isRequired,
33368
- feedback: B.default.shape(yB).isRequired,
33455
+ feedback: B.default.shape(OB).isRequired,
33369
33456
  onChange: B.default.func.isRequired,
33370
33457
  toolbarOpts: B.default.object,
33371
33458
  mathMlOptions: B.default.object
@@ -33387,36 +33474,36 @@ var cB = sB(y, "InputContainer") || sB(dB.InputContainer, "InputContainer"), lB
33387
33474
  };
33388
33475
  render() {
33389
33476
  let { keys: e, label: t, feedback: n, toolbarOpts: r, mathMlOptions: i = {} } = this.props;
33390
- return /* @__PURE__ */ z(mB, { children: [
33391
- /* @__PURE__ */ R(hB, {
33477
+ return /* @__PURE__ */ z(CB, { children: [
33478
+ /* @__PURE__ */ R(wB, {
33392
33479
  label: t,
33393
33480
  extraClasses: { label: { transform: "translateY(-20%)" } },
33394
- children: /* @__PURE__ */ R(vB, {
33395
- keys: e || Object.keys(pB),
33481
+ children: /* @__PURE__ */ R(DB, {
33482
+ keys: e || Object.keys(SB),
33396
33483
  label: t,
33397
33484
  value: n.type,
33398
33485
  onChange: this.changeType,
33399
- feedbackLabels: pB
33486
+ feedbackLabels: SB
33400
33487
  })
33401
33488
  }),
33402
- n.type === "custom" && /* @__PURE__ */ R(gB, { children: /* @__PURE__ */ R(fB, {
33489
+ n.type === "custom" && /* @__PURE__ */ R(TB, { children: /* @__PURE__ */ R(xB, {
33403
33490
  onChange: this.changeCustom,
33404
33491
  markup: n.custom || "",
33405
33492
  toolbarOpts: r,
33406
33493
  languageCharactersProps: [{ language: "spanish" }, { language: "special" }],
33407
33494
  mathMlOptions: i
33408
33495
  }) }),
33409
- n.type === "default" && /* @__PURE__ */ z(_B, { children: [" ", n.default] })
33496
+ n.type === "default" && /* @__PURE__ */ z(EB, { children: [" ", n.default] })
33410
33497
  ] });
33411
33498
  }
33412
- }, xB = E(/*#__PURE__*/ R("path", { d: "M16.59 8.59 12 13.17 7.41 8.59 6 10l6 6 6-6z" }), "ExpandMore"), SB = M("div")(() => ({
33499
+ }, AB = E(/*#__PURE__*/ R("path", { d: "M16.59 8.59 12 13.17 7.41 8.59 6 10l6 6 6-6z" }), "ExpandMore"), jB = M("div")(() => ({
33413
33500
  display: "flex",
33414
33501
  flex: 1,
33415
33502
  flexDirection: "column"
33416
- })), CB = M(Vt)(() => ({
33503
+ })), MB = M(Vt)(() => ({
33417
33504
  paddingTop: 0,
33418
33505
  paddingBottom: 0
33419
- })), wB = (e) => a({}, {
33506
+ })), NB = (e) => a({}, {
33420
33507
  correct: {
33421
33508
  type: "default",
33422
33509
  default: "Correct"
@@ -33429,21 +33516,21 @@ var cB = sB(y, "InputContainer") || sB(dB.InputContainer, "InputContainer"), lB
33429
33516
  type: "default",
33430
33517
  default: "Nearly"
33431
33518
  }
33432
- }, e), TB = class extends I.Component {
33519
+ }, e), PB = class extends I.Component {
33433
33520
  static propTypes = {
33434
33521
  allowPartial: B.default.bool,
33435
33522
  className: B.default.string,
33436
33523
  feedback: B.default.shape({
33437
- correct: B.default.shape(yB),
33438
- incorrect: B.default.shape(yB),
33439
- partial: B.default.shape(yB)
33524
+ correct: B.default.shape(OB),
33525
+ incorrect: B.default.shape(OB),
33526
+ partial: B.default.shape(OB)
33440
33527
  }),
33441
33528
  onChange: B.default.func.isRequired,
33442
33529
  toolbarOpts: B.default.object
33443
33530
  };
33444
33531
  static defaultProps = {
33445
33532
  allowPartial: !0,
33446
- feedback: wB()
33533
+ feedback: NB()
33447
33534
  };
33448
33535
  onChange(e, t) {
33449
33536
  let { feedback: n, onChange: r } = this.props;
@@ -33465,22 +33552,22 @@ var cB = sB(y, "InputContainer") || sB(dB.InputContainer, "InputContainer"), lB
33465
33552
  exit: 195
33466
33553
  } } },
33467
33554
  children: [/* @__PURE__ */ R(Jt, {
33468
- expandIcon: /* @__PURE__ */ R(xB, {}),
33555
+ expandIcon: /* @__PURE__ */ R(AB, {}),
33469
33556
  children: /* @__PURE__ */ R(xt, { children: "Feedback" })
33470
- }), /* @__PURE__ */ R(CB, { children: /* @__PURE__ */ z(SB, { children: [
33471
- /* @__PURE__ */ R(bB, {
33557
+ }), /* @__PURE__ */ R(MB, { children: /* @__PURE__ */ z(jB, { children: [
33558
+ /* @__PURE__ */ R(kB, {
33472
33559
  label: "If correct, show",
33473
33560
  feedback: n.correct,
33474
33561
  onChange: this.onCorrectChange,
33475
33562
  toolbarOpts: r
33476
33563
  }),
33477
- t && /* @__PURE__ */ R(bB, {
33564
+ t && /* @__PURE__ */ R(kB, {
33478
33565
  label: "If partially correct, show",
33479
33566
  feedback: n.partial,
33480
33567
  onChange: this.onPartialChange,
33481
33568
  toolbarOpts: r
33482
33569
  }),
33483
- /* @__PURE__ */ R(bB, {
33570
+ /* @__PURE__ */ R(kB, {
33484
33571
  label: "If incorrect, show",
33485
33572
  feedback: n.incorrect,
33486
33573
  onChange: this.onIncorrectChange,
@@ -33490,7 +33577,7 @@ var cB = sB(y, "InputContainer") || sB(dB.InputContainer, "InputContainer"), lB
33490
33577
  })
33491
33578
  });
33492
33579
  }
33493
- }, EB = M(di)(() => ({})), DB = class extends I.Component {
33580
+ }, FB = M(di)(() => ({})), IB = class extends I.Component {
33494
33581
  static propTypes = {
33495
33582
  className: B.default.string,
33496
33583
  contentClassName: B.default.string,
@@ -33511,7 +33598,7 @@ var cB = sB(y, "InputContainer") || sB(dB.InputContainer, "InputContainer"), lB
33511
33598
  indicatorColor: "primary",
33512
33599
  value: e,
33513
33600
  onChange: this.handleChange,
33514
- children: I.Children.map(t, (e, t) => e && e.props.title ? /* @__PURE__ */ R(EB, { label: e.props.title }, t) : null)
33601
+ children: I.Children.map(t, (e, t) => e && e.props.title ? /* @__PURE__ */ R(FB, { label: e.props.title }, t) : null)
33515
33602
  }), /* @__PURE__ */ R("div", {
33516
33603
  className: r,
33517
33604
  style: i,
@@ -33519,7 +33606,7 @@ var cB = sB(y, "InputContainer") || sB(dB.InputContainer, "InputContainer"), lB
33519
33606
  })]
33520
33607
  });
33521
33608
  }
33522
- }, OB = M(Zn)(({ theme: e, mini: t }) => ({
33609
+ }, LB = M(Zn)(({ theme: e, mini: t }) => ({
33523
33610
  margin: 0,
33524
33611
  marginLeft: 0,
33525
33612
  padding: 0,
@@ -33533,7 +33620,7 @@ var cB = sB(y, "InputContainer") || sB(dB.InputContainer, "InputContainer"), lB
33533
33620
  fontSize: e.typography.fontSize - 3
33534
33621
  }
33535
33622
  }
33536
- })), kB = M(yn)(({ theme: e, mini: t, error: n }) => ({
33623
+ })), RB = M(yn)(({ theme: e, mini: t, error: n }) => ({
33537
33624
  color: `${A.tertiary()} !important`,
33538
33625
  ...t && {
33539
33626
  margin: 0,
@@ -33542,9 +33629,9 @@ var cB = sB(y, "InputContainer") || sB(dB.InputContainer, "InputContainer"), lB
33542
33629
  height: e.spacing(3)
33543
33630
  },
33544
33631
  ...n && { color: `${e.palette.error.main} !important` }
33545
- })), AB = ({ mini: e, checked: t, onChange: n, value: r, label: i, error: a }) => /* @__PURE__ */ R(OB, {
33632
+ })), zB = ({ mini: e, checked: t, onChange: n, value: r, label: i, error: a }) => /* @__PURE__ */ R(LB, {
33546
33633
  mini: e,
33547
- control: /* @__PURE__ */ R(kB, {
33634
+ control: /* @__PURE__ */ R(RB, {
33548
33635
  checked: t,
33549
33636
  onChange: n,
33550
33637
  value: r,
@@ -33553,21 +33640,21 @@ var cB = sB(y, "InputContainer") || sB(dB.InputContainer, "InputContainer"), lB
33553
33640
  }),
33554
33641
  label: i
33555
33642
  });
33556
- AB.propTypes = {
33643
+ zB.propTypes = {
33557
33644
  mini: B.default.bool,
33558
33645
  checked: B.default.bool.isRequired,
33559
33646
  onChange: B.default.func.isRequired,
33560
33647
  value: B.default.string,
33561
33648
  label: B.default.string.isRequired,
33562
33649
  error: B.default.bool
33563
- }, AB.defaultProps = {
33650
+ }, zB.defaultProps = {
33564
33651
  value: "",
33565
33652
  mini: !1,
33566
33653
  error: !1
33567
33654
  };
33568
33655
  //#endregion
33569
33656
  //#region ../../lib-react/config-ui/dist/number-text-field.js
33570
- var jB = (0, St.default)("@pie-lib:config-ui:number-text-field"), MB = M(Bi)(({ theme: e }) => ({
33657
+ var BB = (0, St.default)("@pie-lib:config-ui:number-text-field"), VB = M(Bi)(({ theme: e }) => ({
33571
33658
  marginRight: e.spacing(1),
33572
33659
  "& .MuiInputLabel-root": {
33573
33660
  width: "auto",
@@ -33589,11 +33676,11 @@ var jB = (0, St.default)("@pie-lib:config-ui:number-text-field"), MB = M(Bi)(({
33589
33676
  minHeight: "auto",
33590
33677
  padding: "6px 0 7px"
33591
33678
  }
33592
- })), NB = (e, t) => {
33679
+ })), HB = (e, t) => {
33593
33680
  if (!r(e) && !r(t)) return 0;
33594
33681
  if (!r(e) && r(t)) return t;
33595
33682
  if (r(e)) return e;
33596
- }, PB = class extends I.Component {
33683
+ }, UB = class extends I.Component {
33597
33684
  static propTypes = {
33598
33685
  disabled: B.default.bool,
33599
33686
  className: B.default.string,
@@ -33619,13 +33706,13 @@ var jB = (0, St.default)("@pie-lib:config-ui:number-text-field"), MB = M(Bi)(({
33619
33706
  this.setState({ value: t });
33620
33707
  }
33621
33708
  clamp(e, t = this.props.min, n = this.props.max) {
33622
- return r(e) ? (r(n) && (e = Math.min(e, n)), r(t) && (e = Math.max(e, t)), e) : NB(t, n);
33709
+ return r(e) ? (r(n) && (e = Math.min(e, n)), r(t) && (e = Math.max(e, t)), e) : HB(t, n);
33623
33710
  }
33624
33711
  onBlur = (e) => {
33625
33712
  let t = e.target.value, n = parseFloat(t);
33626
- jB("rawNumber: ", n);
33713
+ BB("rawNumber: ", n);
33627
33714
  let r = this.clamp(n);
33628
- jB("number: ", r), r !== this.state.value && (jB("trigger update..."), this.setState({ value: r.toString() }, () => {
33715
+ BB("number: ", r), r !== this.state.value && (BB("trigger update..."), this.setState({ value: r.toString() }, () => {
33629
33716
  this.props.onChange(e, r);
33630
33717
  }));
33631
33718
  };
@@ -33645,7 +33732,7 @@ var jB = (0, St.default)("@pie-lib:config-ui:number-text-field"), MB = M(Bi)(({
33645
33732
  };
33646
33733
  render() {
33647
33734
  let { className: e, label: t, disabled: n, suffix: r, min: i, max: a, inputClassName: o, disableUnderline: s, showErrorWhenOutsideRange: c, variant: l } = this.props, u = c && this.getError();
33648
- return /* @__PURE__ */ R(MB, {
33735
+ return /* @__PURE__ */ R(VB, {
33649
33736
  variant: s ? "filled" : l || "standard",
33650
33737
  inputRef: (e) => {
33651
33738
  this.inputRef = e;
@@ -33680,19 +33767,19 @@ var jB = (0, St.default)("@pie-lib:config-ui:number-text-field"), MB = M(Bi)(({
33680
33767
  };
33681
33768
  //#endregion
33682
33769
  //#region ../../lib-react/config-ui/dist/two-choice.js
33683
- function FB(e) {
33770
+ function WB(e) {
33684
33771
  return typeof e == "function" || typeof e == "object" && !!e && typeof e.$$typeof == "symbol";
33685
33772
  }
33686
- function IB(e, t) {
33687
- return !e || FB(e) ? e : FB(e.default) ? e.default : t && FB(e[t]) ? e[t] : t && FB(e[t]?.default) ? e[t].default : e;
33773
+ function GB(e, t) {
33774
+ return !e || WB(e) ? e : WB(e.default) ? e.default : t && WB(e[t]) ? e[t] : t && WB(e[t]?.default) ? e[t].default : e;
33688
33775
  }
33689
- var LB = IB(y, "InputContainer") || IB(BB.InputContainer, "InputContainer"), RB = Ue, zB = RB.default, BB = zB && typeof zB == "object" ? zB : RB, VB = M("div")(({ theme: e, direction: t }) => ({
33776
+ var KB = GB(y, "InputContainer") || GB(YB.InputContainer, "InputContainer"), qB = Ue, JB = qB.default, YB = JB && typeof JB == "object" ? JB : qB, XB = M("div")(({ theme: e, direction: t }) => ({
33690
33777
  display: "flex",
33691
33778
  flexWrap: "wrap",
33692
33779
  paddingLeft: 0,
33693
33780
  marginTop: e.spacing(1),
33694
33781
  ...t === "vertical" && { flexDirection: "column" }
33695
- })), HB = class extends I.Component {
33782
+ })), ZB = class extends I.Component {
33696
33783
  static propTypes = {
33697
33784
  header: B.default.string.isRequired,
33698
33785
  className: B.default.string,
@@ -33710,10 +33797,10 @@ var LB = IB(y, "InputContainer") || IB(BB.InputContainer, "InputContainer"), RB
33710
33797
  label: e,
33711
33798
  value: e
33712
33799
  } : e), s = n || Ui;
33713
- return /* @__PURE__ */ R(LB, {
33800
+ return /* @__PURE__ */ R(KB, {
33714
33801
  label: e,
33715
33802
  className: t,
33716
- children: /* @__PURE__ */ R(VB, {
33803
+ children: /* @__PURE__ */ R(XB, {
33717
33804
  direction: a,
33718
33805
  children: o.map((e, t) => /* @__PURE__ */ R(s, {
33719
33806
  value: e.value,
@@ -33724,7 +33811,7 @@ var LB = IB(y, "InputContainer") || IB(BB.InputContainer, "InputContainer"), RB
33724
33811
  })
33725
33812
  });
33726
33813
  }
33727
- }, UB = B.default.shape({
33814
+ }, QB = B.default.shape({
33728
33815
  label: B.default.string,
33729
33816
  value: B.default.string
33730
33817
  });
@@ -33733,14 +33820,14 @@ var LB = IB(y, "InputContainer") || IB(BB.InputContainer, "InputContainer"), RB
33733
33820
  header: B.default.string.isRequired,
33734
33821
  value: B.default.string.isRequired,
33735
33822
  onChange: B.default.func.isRequired,
33736
- one: B.default.oneOfType([UB, B.default.string]),
33737
- two: B.default.oneOfType([UB, B.default.string]),
33823
+ one: B.default.oneOfType([QB, B.default.string]),
33824
+ two: B.default.oneOfType([QB, B.default.string]),
33738
33825
  className: B.default.string,
33739
33826
  customLabel: B.default.func
33740
33827
  };
33741
33828
  render() {
33742
33829
  let { one: e, two: t, header: n, className: r, customLabel: i, value: a, onChange: o } = this.props;
33743
- return /* @__PURE__ */ R(HB, {
33830
+ return /* @__PURE__ */ R(ZB, {
33744
33831
  customLabel: i,
33745
33832
  header: n,
33746
33833
  className: r,
@@ -33752,21 +33839,21 @@ var LB = IB(y, "InputContainer") || IB(BB.InputContainer, "InputContainer"), RB
33752
33839
  });
33753
33840
  //#endregion
33754
33841
  //#region ../../lib-react/config-ui/dist/_virtual/_rolldown/runtime.js
33755
- var WB = Object.defineProperty, GB = (e, t) => {
33842
+ var $B = Object.defineProperty, eV = (e, t) => {
33756
33843
  let n = {};
33757
- for (var r in e) WB(n, r, {
33844
+ for (var r in e) $B(n, r, {
33758
33845
  get: e[r],
33759
33846
  enumerable: !0
33760
33847
  });
33761
- return t || WB(n, Symbol.toStringTag, { value: "Module" }), n;
33762
- }, KB = M("div")(() => ({
33848
+ return t || $B(n, Symbol.toStringTag, { value: "Module" }), n;
33849
+ }, tV = M("div")(() => ({
33763
33850
  display: "flex",
33764
33851
  flexDirection: "column",
33765
33852
  position: "relative"
33766
- })), qB = M("div")(() => ({
33853
+ })), nV = M("div")(() => ({
33767
33854
  display: "flex",
33768
33855
  justifyContent: "space-between"
33769
- })), JB = M("div")(({ theme: e }) => ({ padding: `${e.spacing(2)} 0` })), YB = M("div")(() => ({ flex: "1" })), XB = M("div")(({ theme: e }) => ({ marginLeft: e.spacing(2) })), ZB = class extends I.Component {
33856
+ })), rV = M("div")(({ theme: e }) => ({ padding: `${e.spacing(2)} 0` })), iV = M("div")(() => ({ flex: "1" })), aV = M("div")(({ theme: e }) => ({ marginLeft: e.spacing(2) })), oV = class extends I.Component {
33770
33857
  static propTypes = {
33771
33858
  mode: B.default.oneOf(["tabbed", "inline"]),
33772
33859
  secondary: B.default.oneOfType([B.default.arrayOf(B.default.node), B.default.node]),
@@ -33784,7 +33871,7 @@ var WB = Object.defineProperty, GB = (e, t) => {
33784
33871
  } catch (e) {
33785
33872
  console.log(e.toString());
33786
33873
  }
33787
- return /* @__PURE__ */ z(KB, {
33874
+ return /* @__PURE__ */ z(tV, {
33788
33875
  style: {
33789
33876
  minHeight: i,
33790
33877
  minWidth: a,
@@ -33792,28 +33879,28 @@ var WB = Object.defineProperty, GB = (e, t) => {
33792
33879
  maxWidth: s
33793
33880
  },
33794
33881
  children: [
33795
- e === "inline" && /* @__PURE__ */ z(qB, { children: [/* @__PURE__ */ R(YB, {
33882
+ e === "inline" && /* @__PURE__ */ z(nV, { children: [/* @__PURE__ */ R(iV, {
33796
33883
  className: "design-container",
33797
33884
  children: n
33798
- }), l && /* @__PURE__ */ R(XB, {
33885
+ }), l && /* @__PURE__ */ R(aV, {
33799
33886
  className: "settings-container",
33800
33887
  children: t
33801
33888
  })] }),
33802
- e === "tabbed" && l && /* @__PURE__ */ z(DB, {
33889
+ e === "tabbed" && l && /* @__PURE__ */ z(IB, {
33803
33890
  onChange: this.onTabsChange,
33804
33891
  contentClassName: "content-container",
33805
33892
  indicatorColor: "primary",
33806
- children: [/* @__PURE__ */ R(JB, {
33893
+ children: [/* @__PURE__ */ R(rV, {
33807
33894
  title: "Design",
33808
33895
  className: "design-container",
33809
33896
  children: n
33810
- }), /* @__PURE__ */ R(JB, {
33897
+ }), /* @__PURE__ */ R(rV, {
33811
33898
  title: "Settings",
33812
33899
  className: "settings-container",
33813
33900
  children: t
33814
33901
  })]
33815
33902
  }),
33816
- e === "tabbed" && !l && /* @__PURE__ */ R(JB, {
33903
+ e === "tabbed" && !l && /* @__PURE__ */ R(rV, {
33817
33904
  className: "design-container",
33818
33905
  children: n
33819
33906
  })
@@ -33823,18 +33910,18 @@ var WB = Object.defineProperty, GB = (e, t) => {
33823
33910
  };
33824
33911
  //#endregion
33825
33912
  //#region ../../lib-react/config-ui/dist/node_modules/.bun/@babel_runtime@7.29.7/node_modules/@babel/runtime/helpers/esm/extends.js
33826
- function QB() {
33827
- return QB = Object.assign ? Object.assign.bind() : function(e) {
33913
+ function sV() {
33914
+ return sV = Object.assign ? Object.assign.bind() : function(e) {
33828
33915
  for (var t = 1; t < arguments.length; t++) {
33829
33916
  var n = arguments[t];
33830
33917
  for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
33831
33918
  }
33832
33919
  return e;
33833
- }, QB.apply(null, arguments);
33920
+ }, sV.apply(null, arguments);
33834
33921
  }
33835
33922
  //#endregion
33836
33923
  //#region ../../lib-react/config-ui/dist/node_modules/.bun/@babel_runtime@7.29.7/node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js
33837
- function $B(e, t) {
33924
+ function cV(e, t) {
33838
33925
  if (e == null) return {};
33839
33926
  var n = {};
33840
33927
  for (var r in e) if ({}.hasOwnProperty.call(e, r)) {
@@ -33845,19 +33932,19 @@ function $B(e, t) {
33845
33932
  }
33846
33933
  //#endregion
33847
33934
  //#region ../../lib-react/config-ui/dist/node_modules/.bun/@babel_runtime@7.29.7/node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js
33848
- function eV(e, t) {
33849
- return eV = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(e, t) {
33935
+ function lV(e, t) {
33936
+ return lV = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(e, t) {
33850
33937
  return e.__proto__ = t, e;
33851
- }, eV(e, t);
33938
+ }, lV(e, t);
33852
33939
  }
33853
33940
  //#endregion
33854
33941
  //#region ../../lib-react/config-ui/dist/node_modules/.bun/@babel_runtime@7.29.7/node_modules/@babel/runtime/helpers/esm/inheritsLoose.js
33855
- function tV(e, t) {
33856
- e.prototype = Object.create(t.prototype), e.prototype.constructor = e, eV(e, t);
33942
+ function uV(e, t) {
33943
+ e.prototype = Object.create(t.prototype), e.prototype.constructor = e, lV(e, t);
33857
33944
  }
33858
33945
  //#endregion
33859
33946
  //#region ../../lib-react/config-ui/dist/node_modules/.bun/resize-observer-polyfill@1.5.1/node_modules/resize-observer-polyfill/dist/ResizeObserver.es.js
33860
- var nV = (function() {
33947
+ var dV = (function() {
33861
33948
  if (typeof Map < "u") return Map;
33862
33949
  function e(e, t) {
33863
33950
  var n = -1;
@@ -33896,34 +33983,34 @@ var nV = (function() {
33896
33983
  }
33897
33984
  }, t;
33898
33985
  }();
33899
- })(), rV = typeof window < "u" && typeof document < "u" && window.document === document, iV = (function() {
33986
+ })(), fV = typeof window < "u" && typeof document < "u" && window.document === document, pV = (function() {
33900
33987
  return typeof global < "u" && global.Math === Math ? global : typeof self < "u" && self.Math === Math ? self : typeof window < "u" && window.Math === Math ? window : Function("return this")();
33901
- })(), aV = (function() {
33902
- return typeof requestAnimationFrame == "function" ? requestAnimationFrame.bind(iV) : function(e) {
33988
+ })(), mV = (function() {
33989
+ return typeof requestAnimationFrame == "function" ? requestAnimationFrame.bind(pV) : function(e) {
33903
33990
  return setTimeout(function() {
33904
33991
  return e(Date.now());
33905
33992
  }, 1e3 / 60);
33906
33993
  };
33907
- })(), oV = 2;
33908
- function sV(e, t) {
33994
+ })(), hV = 2;
33995
+ function gV(e, t) {
33909
33996
  var n = !1, r = !1, i = 0;
33910
33997
  function a() {
33911
33998
  n && (n = !1, e()), r && s();
33912
33999
  }
33913
34000
  function o() {
33914
- aV(a);
34001
+ mV(a);
33915
34002
  }
33916
34003
  function s() {
33917
34004
  var e = Date.now();
33918
34005
  if (n) {
33919
- if (e - i < oV) return;
34006
+ if (e - i < hV) return;
33920
34007
  r = !0;
33921
34008
  } else n = !0, r = !1, setTimeout(o, t);
33922
34009
  i = e;
33923
34010
  }
33924
34011
  return s;
33925
34012
  }
33926
- var cV = 20, lV = [
34013
+ var _V = 20, vV = [
33927
34014
  "top",
33928
34015
  "right",
33929
34016
  "bottom",
@@ -33932,9 +34019,9 @@ var cV = 20, lV = [
33932
34019
  "height",
33933
34020
  "size",
33934
34021
  "weight"
33935
- ], uV = typeof MutationObserver < "u", dV = function() {
34022
+ ], yV = typeof MutationObserver < "u", bV = function() {
33936
34023
  function e() {
33937
- this.connected_ = !1, this.mutationEventsAdded_ = !1, this.mutationsObserver_ = null, this.observers_ = [], this.onTransitionEnd_ = this.onTransitionEnd_.bind(this), this.refresh = sV(this.refresh.bind(this), cV);
34024
+ this.connected_ = !1, this.mutationEventsAdded_ = !1, this.mutationsObserver_ = null, this.observers_ = [], this.onTransitionEnd_ = this.onTransitionEnd_.bind(this), this.refresh = gV(this.refresh.bind(this), _V);
33938
34025
  }
33939
34026
  return e.prototype.addObserver = function(e) {
33940
34027
  ~this.observers_.indexOf(e) || this.observers_.push(e), this.connected_ || this.connect_();
@@ -33951,23 +34038,23 @@ var cV = 20, lV = [
33951
34038
  return e.broadcastActive();
33952
34039
  }), e.length > 0;
33953
34040
  }, e.prototype.connect_ = function() {
33954
- !rV || this.connected_ || (document.addEventListener("transitionend", this.onTransitionEnd_), window.addEventListener("resize", this.refresh), uV ? (this.mutationsObserver_ = new MutationObserver(this.refresh), this.mutationsObserver_.observe(document, {
34041
+ !fV || this.connected_ || (document.addEventListener("transitionend", this.onTransitionEnd_), window.addEventListener("resize", this.refresh), yV ? (this.mutationsObserver_ = new MutationObserver(this.refresh), this.mutationsObserver_.observe(document, {
33955
34042
  attributes: !0,
33956
34043
  childList: !0,
33957
34044
  characterData: !0,
33958
34045
  subtree: !0
33959
34046
  })) : (document.addEventListener("DOMSubtreeModified", this.refresh), this.mutationEventsAdded_ = !0), this.connected_ = !0);
33960
34047
  }, e.prototype.disconnect_ = function() {
33961
- !rV || !this.connected_ || (document.removeEventListener("transitionend", this.onTransitionEnd_), window.removeEventListener("resize", this.refresh), this.mutationsObserver_ && this.mutationsObserver_.disconnect(), this.mutationEventsAdded_ && document.removeEventListener("DOMSubtreeModified", this.refresh), this.mutationsObserver_ = null, this.mutationEventsAdded_ = !1, this.connected_ = !1);
34048
+ !fV || !this.connected_ || (document.removeEventListener("transitionend", this.onTransitionEnd_), window.removeEventListener("resize", this.refresh), this.mutationsObserver_ && this.mutationsObserver_.disconnect(), this.mutationEventsAdded_ && document.removeEventListener("DOMSubtreeModified", this.refresh), this.mutationsObserver_ = null, this.mutationEventsAdded_ = !1, this.connected_ = !1);
33962
34049
  }, e.prototype.onTransitionEnd_ = function(e) {
33963
34050
  var t = e.propertyName, n = t === void 0 ? "" : t;
33964
- lV.some(function(e) {
34051
+ vV.some(function(e) {
33965
34052
  return !!~n.indexOf(e);
33966
34053
  }) && this.refresh();
33967
34054
  }, e.getInstance = function() {
33968
34055
  return this.instance_ ||= new e(), this.instance_;
33969
34056
  }, e.instance_ = null, e;
33970
- }(), fV = (function(e, t) {
34057
+ }(), xV = (function(e, t) {
33971
34058
  for (var n = 0, r = Object.keys(t); n < r.length; n++) {
33972
34059
  var i = r[n];
33973
34060
  Object.defineProperty(e, i, {
@@ -33978,19 +34065,19 @@ var cV = 20, lV = [
33978
34065
  });
33979
34066
  }
33980
34067
  return e;
33981
- }), pV = (function(e) {
33982
- return e && e.ownerDocument && e.ownerDocument.defaultView || iV;
33983
- }), mV = wV(0, 0, 0, 0);
33984
- function hV(e) {
34068
+ }), SV = (function(e) {
34069
+ return e && e.ownerDocument && e.ownerDocument.defaultView || pV;
34070
+ }), CV = NV(0, 0, 0, 0);
34071
+ function wV(e) {
33985
34072
  return parseFloat(e) || 0;
33986
34073
  }
33987
- function gV(e) {
34074
+ function TV(e) {
33988
34075
  return [...arguments].slice(1).reduce(function(t, n) {
33989
34076
  var r = e["border-" + n + "-width"];
33990
- return t + hV(r);
34077
+ return t + wV(r);
33991
34078
  }, 0);
33992
34079
  }
33993
- function _V(e) {
34080
+ function EV(e) {
33994
34081
  for (var t = [
33995
34082
  "top",
33996
34083
  "right",
@@ -33998,40 +34085,40 @@ function _V(e) {
33998
34085
  "left"
33999
34086
  ], n = {}, r = 0, i = t; r < i.length; r++) {
34000
34087
  var a = i[r], o = e["padding-" + a];
34001
- n[a] = hV(o);
34088
+ n[a] = wV(o);
34002
34089
  }
34003
34090
  return n;
34004
34091
  }
34005
- function vV(e) {
34092
+ function DV(e) {
34006
34093
  var t = e.getBBox();
34007
- return wV(0, 0, t.width, t.height);
34094
+ return NV(0, 0, t.width, t.height);
34008
34095
  }
34009
- function yV(e) {
34096
+ function OV(e) {
34010
34097
  var t = e.clientWidth, n = e.clientHeight;
34011
- if (!t && !n) return mV;
34012
- var r = pV(e).getComputedStyle(e), i = _V(r), a = i.left + i.right, o = i.top + i.bottom, s = hV(r.width), c = hV(r.height);
34013
- if (r.boxSizing === "border-box" && (Math.round(s + a) !== t && (s -= gV(r, "left", "right") + a), Math.round(c + o) !== n && (c -= gV(r, "top", "bottom") + o)), !xV(e)) {
34098
+ if (!t && !n) return CV;
34099
+ var r = SV(e).getComputedStyle(e), i = EV(r), a = i.left + i.right, o = i.top + i.bottom, s = wV(r.width), c = wV(r.height);
34100
+ if (r.boxSizing === "border-box" && (Math.round(s + a) !== t && (s -= TV(r, "left", "right") + a), Math.round(c + o) !== n && (c -= TV(r, "top", "bottom") + o)), !AV(e)) {
34014
34101
  var l = Math.round(s + a) - t, u = Math.round(c + o) - n;
34015
34102
  Math.abs(l) !== 1 && (s -= l), Math.abs(u) !== 1 && (c -= u);
34016
34103
  }
34017
- return wV(i.left, i.top, s, c);
34104
+ return NV(i.left, i.top, s, c);
34018
34105
  }
34019
- var bV = (function() {
34106
+ var kV = (function() {
34020
34107
  return typeof SVGGraphicsElement < "u" ? function(e) {
34021
- return e instanceof pV(e).SVGGraphicsElement;
34108
+ return e instanceof SV(e).SVGGraphicsElement;
34022
34109
  } : function(e) {
34023
- return e instanceof pV(e).SVGElement && typeof e.getBBox == "function";
34110
+ return e instanceof SV(e).SVGElement && typeof e.getBBox == "function";
34024
34111
  };
34025
34112
  })();
34026
- function xV(e) {
34027
- return e === pV(e).document.documentElement;
34113
+ function AV(e) {
34114
+ return e === SV(e).document.documentElement;
34028
34115
  }
34029
- function SV(e) {
34030
- return rV ? bV(e) ? vV(e) : yV(e) : mV;
34116
+ function jV(e) {
34117
+ return fV ? kV(e) ? DV(e) : OV(e) : CV;
34031
34118
  }
34032
- function CV(e) {
34119
+ function MV(e) {
34033
34120
  var t = e.x, n = e.y, r = e.width, i = e.height, a = Object.create((typeof DOMRectReadOnly < "u" ? DOMRectReadOnly : Object).prototype);
34034
- return fV(a, {
34121
+ return xV(a, {
34035
34122
  x: t,
34036
34123
  y: n,
34037
34124
  width: r,
@@ -34042,7 +34129,7 @@ function CV(e) {
34042
34129
  left: t
34043
34130
  }), a;
34044
34131
  }
34045
- function wV(e, t, n, r) {
34132
+ function NV(e, t, n, r) {
34046
34133
  return {
34047
34134
  x: e,
34048
34135
  y: t,
@@ -34050,42 +34137,42 @@ function wV(e, t, n, r) {
34050
34137
  height: r
34051
34138
  };
34052
34139
  }
34053
- var TV = function() {
34140
+ var PV = function() {
34054
34141
  function e(e) {
34055
- this.broadcastWidth = 0, this.broadcastHeight = 0, this.contentRect_ = wV(0, 0, 0, 0), this.target = e;
34142
+ this.broadcastWidth = 0, this.broadcastHeight = 0, this.contentRect_ = NV(0, 0, 0, 0), this.target = e;
34056
34143
  }
34057
34144
  return e.prototype.isActive = function() {
34058
- var e = SV(this.target);
34145
+ var e = jV(this.target);
34059
34146
  return this.contentRect_ = e, e.width !== this.broadcastWidth || e.height !== this.broadcastHeight;
34060
34147
  }, e.prototype.broadcastRect = function() {
34061
34148
  var e = this.contentRect_;
34062
34149
  return this.broadcastWidth = e.width, this.broadcastHeight = e.height, e;
34063
34150
  }, e;
34064
- }(), EV = function() {
34151
+ }(), FV = function() {
34065
34152
  function e(e, t) {
34066
- var n = CV(t);
34067
- fV(this, {
34153
+ var n = MV(t);
34154
+ xV(this, {
34068
34155
  target: e,
34069
34156
  contentRect: n
34070
34157
  });
34071
34158
  }
34072
34159
  return e;
34073
- }(), DV = function() {
34160
+ }(), IV = function() {
34074
34161
  function e(e, t, n) {
34075
- if (this.activeObservations_ = [], this.observations_ = new nV(), typeof e != "function") throw TypeError("The callback provided as parameter 1 is not a function.");
34162
+ if (this.activeObservations_ = [], this.observations_ = new dV(), typeof e != "function") throw TypeError("The callback provided as parameter 1 is not a function.");
34076
34163
  this.callback_ = e, this.controller_ = t, this.callbackCtx_ = n;
34077
34164
  }
34078
34165
  return e.prototype.observe = function(e) {
34079
34166
  if (!arguments.length) throw TypeError("1 argument required, but only 0 present.");
34080
34167
  if (!(typeof Element > "u" || !(Element instanceof Object))) {
34081
- if (!(e instanceof pV(e).Element)) throw TypeError("parameter 1 is not of type \"Element\".");
34168
+ if (!(e instanceof SV(e).Element)) throw TypeError("parameter 1 is not of type \"Element\".");
34082
34169
  var t = this.observations_;
34083
- t.has(e) || (t.set(e, new TV(e)), this.controller_.addObserver(this), this.controller_.refresh());
34170
+ t.has(e) || (t.set(e, new PV(e)), this.controller_.addObserver(this), this.controller_.refresh());
34084
34171
  }
34085
34172
  }, e.prototype.unobserve = function(e) {
34086
34173
  if (!arguments.length) throw TypeError("1 argument required, but only 0 present.");
34087
34174
  if (!(typeof Element > "u" || !(Element instanceof Object))) {
34088
- if (!(e instanceof pV(e).Element)) throw TypeError("parameter 1 is not of type \"Element\".");
34175
+ if (!(e instanceof SV(e).Element)) throw TypeError("parameter 1 is not of type \"Element\".");
34089
34176
  var t = this.observations_;
34090
34177
  t.has(e) && (t.delete(e), t.size || this.controller_.removeObserver(this));
34091
34178
  }
@@ -34099,7 +34186,7 @@ var TV = function() {
34099
34186
  }, e.prototype.broadcastActive = function() {
34100
34187
  if (this.hasActive()) {
34101
34188
  var e = this.callbackCtx_, t = this.activeObservations_.map(function(e) {
34102
- return new EV(e.target, e.broadcastRect());
34189
+ return new FV(e.target, e.broadcastRect());
34103
34190
  });
34104
34191
  this.callback_.call(e, t, e), this.clearActive();
34105
34192
  }
@@ -34108,12 +34195,12 @@ var TV = function() {
34108
34195
  }, e.prototype.hasActive = function() {
34109
34196
  return this.activeObservations_.length > 0;
34110
34197
  }, e;
34111
- }(), OV = typeof WeakMap < "u" ? /* @__PURE__ */ new WeakMap() : new nV(), kV = function() {
34198
+ }(), LV = typeof WeakMap < "u" ? /* @__PURE__ */ new WeakMap() : new dV(), RV = function() {
34112
34199
  function e(t) {
34113
34200
  if (!(this instanceof e)) throw TypeError("Cannot call a class as a function.");
34114
34201
  if (!arguments.length) throw TypeError("1 argument required, but only 0 present.");
34115
- var n = new DV(t, dV.getInstance(), this);
34116
- OV.set(this, n);
34202
+ var n = new IV(t, bV.getInstance(), this);
34203
+ LV.set(this, n);
34117
34204
  }
34118
34205
  return e;
34119
34206
  }();
@@ -34122,27 +34209,27 @@ var TV = function() {
34122
34209
  "unobserve",
34123
34210
  "disconnect"
34124
34211
  ].forEach(function(e) {
34125
- kV.prototype[e] = function() {
34212
+ RV.prototype[e] = function() {
34126
34213
  var t;
34127
- return (t = OV.get(this))[e].apply(t, arguments);
34214
+ return (t = LV.get(this))[e].apply(t, arguments);
34128
34215
  };
34129
34216
  });
34130
- var AV = (function() {
34131
- return iV.ResizeObserver === void 0 ? kV : iV.ResizeObserver;
34132
- })(), jV = [
34217
+ var zV = (function() {
34218
+ return pV.ResizeObserver === void 0 ? RV : pV.ResizeObserver;
34219
+ })(), BV = [
34133
34220
  "client",
34134
34221
  "offset",
34135
34222
  "scroll",
34136
34223
  "bounds",
34137
34224
  "margin"
34138
34225
  ];
34139
- function MV(e) {
34226
+ function VV(e) {
34140
34227
  var t = [];
34141
- return jV.forEach(function(n) {
34228
+ return BV.forEach(function(n) {
34142
34229
  e[n] && t.push(n);
34143
34230
  }), t;
34144
34231
  }
34145
- function NV(e, t) {
34232
+ function HV(e, t) {
34146
34233
  var n = {};
34147
34234
  if (t.indexOf("client") > -1 && (n.client = {
34148
34235
  top: e.clientTop,
@@ -34181,14 +34268,14 @@ function NV(e, t) {
34181
34268
  }
34182
34269
  return n;
34183
34270
  }
34184
- function PV(e) {
34271
+ function UV(e) {
34185
34272
  return e && e.ownerDocument && e.ownerDocument.defaultView || window;
34186
34273
  }
34187
- function FV(e) {
34274
+ function WV(e) {
34188
34275
  return function(t) {
34189
34276
  var n, r;
34190
34277
  return r = n = /*#__PURE__*/ function(n) {
34191
- tV(r, n);
34278
+ uV(r, n);
34192
34279
  function r() {
34193
34280
  var t, r = [...arguments];
34194
34281
  return t = n.call.apply(n, [this].concat(r)) || this, t.state = { contentRect: {
@@ -34199,24 +34286,24 @@ function FV(e) {
34199
34286
  bounds: {},
34200
34287
  margin: {}
34201
34288
  } }, t._animationFrameID = null, t._resizeObserver = null, t._node = null, t._window = null, t.measure = function(n) {
34202
- var r = NV(t._node, e || MV(t.props));
34289
+ var r = HV(t._node, e || VV(t.props));
34203
34290
  n && (r.entry = n[0].contentRect), t._animationFrameID = t._window.requestAnimationFrame(function() {
34204
34291
  t._resizeObserver !== null && (t.setState({ contentRect: r }), typeof t.props.onResize == "function" && t.props.onResize(r));
34205
34292
  });
34206
34293
  }, t._handleRef = function(e) {
34207
- t._resizeObserver !== null && t._node !== null && t._resizeObserver.unobserve(t._node), t._node = e, t._window = PV(t._node);
34294
+ t._resizeObserver !== null && t._node !== null && t._resizeObserver.unobserve(t._node), t._node = e, t._window = UV(t._node);
34208
34295
  var n = t.props.innerRef;
34209
34296
  n && (typeof n == "function" ? n(t._node) : n.current = t._node), t._resizeObserver !== null && t._node !== null && t._resizeObserver.observe(t._node);
34210
34297
  }, t;
34211
34298
  }
34212
34299
  var i = r.prototype;
34213
34300
  return i.componentDidMount = function() {
34214
- this._resizeObserver = this._window !== null && this._window.ResizeObserver ? new this._window.ResizeObserver(this.measure) : new AV(this.measure), this._node !== null && (this._resizeObserver.observe(this._node), typeof this.props.onResize == "function" && this.props.onResize(NV(this._node, e || MV(this.props))));
34301
+ this._resizeObserver = this._window !== null && this._window.ResizeObserver ? new this._window.ResizeObserver(this.measure) : new zV(this.measure), this._node !== null && (this._resizeObserver.observe(this._node), typeof this.props.onResize == "function" && this.props.onResize(HV(this._node, e || VV(this.props))));
34215
34302
  }, i.componentWillUnmount = function() {
34216
34303
  this._window !== null && this._window.cancelAnimationFrame(this._animationFrameID), this._resizeObserver !== null && (this._resizeObserver.disconnect(), this._resizeObserver = null);
34217
34304
  }, i.render = function() {
34218
34305
  var e = this.props;
34219
- return e.innerRef, e.onResize, Qe(t, QB({}, $B(e, ["innerRef", "onResize"]), {
34306
+ return e.innerRef, e.onResize, Qe(t, sV({}, cV(e, ["innerRef", "onResize"]), {
34220
34307
  measureRef: this._handleRef,
34221
34308
  measure: this.measure,
34222
34309
  contentRect: this.state.contentRect
@@ -34233,7 +34320,7 @@ function FV(e) {
34233
34320
  }, r;
34234
34321
  };
34235
34322
  }
34236
- var IV = FV()(function(e) {
34323
+ var GV = WV()(function(e) {
34237
34324
  var t = e.measure, n = e.measureRef, r = e.contentRect, i = e.children;
34238
34325
  return i({
34239
34326
  measure: t,
@@ -34241,10 +34328,10 @@ var IV = FV()(function(e) {
34241
34328
  contentRect: r
34242
34329
  });
34243
34330
  });
34244
- IV.displayName = "Measure", IV.propTypes.children = B.default.func;
34331
+ GV.displayName = "Measure", GV.propTypes.children = B.default.func;
34245
34332
  //#endregion
34246
34333
  //#region ../../lib-react/config-ui/dist/layout/settings-box.js
34247
- var LV = M("div")(() => ({
34334
+ var KV = M("div")(() => ({
34248
34335
  backgroundColor: A.white(),
34249
34336
  border: `2px solid ${A.border()}`,
34250
34337
  display: "flex",
@@ -34254,7 +34341,7 @@ var LV = M("div")(() => ({
34254
34341
  maxWidth: "300px",
34255
34342
  padding: "20px 4px 4px 20px",
34256
34343
  zIndex: 99
34257
- })), RV = class extends I.Component {
34344
+ })), qV = class extends I.Component {
34258
34345
  static propTypes = {
34259
34346
  className: B.default.string,
34260
34347
  children: B.default.oneOfType([B.default.arrayOf(B.default.node), B.default.node]).isRequired
@@ -34262,19 +34349,19 @@ var LV = M("div")(() => ({
34262
34349
  static defaultProps = {};
34263
34350
  render() {
34264
34351
  let { className: e, children: t } = this.props;
34265
- return /* @__PURE__ */ R(LV, {
34352
+ return /* @__PURE__ */ R(KV, {
34266
34353
  className: e,
34267
34354
  children: t
34268
34355
  });
34269
34356
  }
34270
- }, zV = de({
34357
+ }, JV = de({
34271
34358
  typography: { fontFamily: "inherit" },
34272
34359
  components: { MuiButton: { styleOverrides: { contained: {
34273
34360
  backgroundColor: "#e0e0e0",
34274
34361
  color: "#000000",
34275
34362
  "&:hover": { backgroundColor: "#bdbdbd" }
34276
34363
  } } } }
34277
- }), BV = class extends I.Component {
34364
+ }), YV = class extends I.Component {
34278
34365
  static propTypes = {
34279
34366
  children: B.default.oneOfType([
34280
34367
  B.default.string,
@@ -34307,19 +34394,19 @@ var LV = M("div")(() => ({
34307
34394
  return /* @__PURE__ */ R(ie, {
34308
34395
  injectFirst: !0,
34309
34396
  children: /* @__PURE__ */ R(Fe, {
34310
- theme: zV,
34311
- children: /* @__PURE__ */ R(IV, {
34397
+ theme: JV,
34398
+ children: /* @__PURE__ */ R(GV, {
34312
34399
  bounds: !0,
34313
34400
  onResize: this.onResize,
34314
34401
  children: ({ measureRef: e }) => {
34315
- let { children: t, settings: n, hideSettings: r, dimensions: i, extraCSSRules: a } = this.props, { layoutMode: o } = this.state, s = r ? null : o === "inline" ? /* @__PURE__ */ R(RV, {
34402
+ let { children: t, settings: n, hideSettings: r, dimensions: i, extraCSSRules: a } = this.props, { layoutMode: o } = this.state, s = r ? null : o === "inline" ? /* @__PURE__ */ R(qV, {
34316
34403
  className: "settings-box",
34317
34404
  children: n
34318
34405
  }) : n;
34319
34406
  return /* @__PURE__ */ z("div", {
34320
34407
  ref: e,
34321
34408
  className: "main-container extraCSSRules",
34322
- children: [a?.rules ? /* @__PURE__ */ R("style", { dangerouslySetInnerHTML: { __html: `.extraCSSRules { ${a.rules} }` } }) : null, /* @__PURE__ */ R(ZB, {
34409
+ children: [a?.rules ? /* @__PURE__ */ R("style", { dangerouslySetInnerHTML: { __html: `.extraCSSRules { ${a.rules} }` } }) : null, /* @__PURE__ */ R(oV, {
34323
34410
  mode: o,
34324
34411
  secondary: s,
34325
34412
  dimensions: i,
@@ -34331,27 +34418,27 @@ var LV = M("div")(() => ({
34331
34418
  })
34332
34419
  });
34333
34420
  }
34334
- }, VV = FV("bounds")(BV), HV = /* @__PURE__ */ GB({
34335
- ConfigLayout: () => VV,
34336
- LayoutContents: () => ZB
34337
- }), UV = M("div")(() => ({
34421
+ }, XV = WV("bounds")(YV), ZV = /* @__PURE__ */ eV({
34422
+ ConfigLayout: () => XV,
34423
+ LayoutContents: () => oV
34424
+ }), QV = M("div")(() => ({
34338
34425
  display: "flex",
34339
34426
  width: "100%",
34340
34427
  justifyContent: "space-between"
34341
- })), WV = M(D)(({ theme: e }) => ({
34428
+ })), $V = M(D)(({ theme: e }) => ({
34342
34429
  color: "rgba(0, 0, 0, 0.89)",
34343
34430
  fontSize: e.typography.fontSize,
34344
34431
  paddingTop: e.spacing(2)
34345
- })), GV = M(oi)(({ checked: e }) => ({
34432
+ })), eH = M(oi)(({ checked: e }) => ({
34346
34433
  "&.Mui-checked .MuiSwitch-thumb": { color: `${A.tertiary()} !important` },
34347
34434
  "&.Mui-checked .MuiSwitch-track": { backgroundColor: `${A.tertiaryLight()} !important` },
34348
34435
  "& .MuiSwitch-track": { backgroundColor: e ? `${A.tertiaryLight()} !important` : void 0 }
34349
- })), KV = ({ checked: e, disabled: t, label: n, toggle: r }) => /* @__PURE__ */ z(UV, { children: [/* @__PURE__ */ R(WV, { children: n }), /* @__PURE__ */ R(GV, {
34436
+ })), tH = ({ checked: e, disabled: t, label: n, toggle: r }) => /* @__PURE__ */ z(QV, { children: [/* @__PURE__ */ R($V, { children: n }), /* @__PURE__ */ R(eH, {
34350
34437
  checked: e,
34351
34438
  disabled: t,
34352
34439
  onChange: (e) => r(e.target.checked)
34353
34440
  })] });
34354
- KV.propTypes = {
34441
+ tH.propTypes = {
34355
34442
  checked: B.default.bool,
34356
34443
  disabled: B.default.bool,
34357
34444
  label: B.default.string.isRequired,
@@ -34359,20 +34446,20 @@ KV.propTypes = {
34359
34446
  };
34360
34447
  //#endregion
34361
34448
  //#region ../../lib-react/config-ui/dist/settings/settings-radio-label.js
34362
- var qV = M(Zn)(({ theme: e }) => ({ "& .MuiFormControlLabel-label": {
34449
+ var nH = M(Zn)(({ theme: e }) => ({ "& .MuiFormControlLabel-label": {
34363
34450
  color: "rgba(0, 0, 0, 0.89)",
34364
34451
  fontSize: e.typography.fontSize - 2,
34365
34452
  left: "-5px",
34366
34453
  position: "relative"
34367
- } })), JV = M(Qr)(() => ({ color: `${A.tertiary()} !important` })), YV = ({ label: e, value: t, checked: n, onChange: r }) => /* @__PURE__ */ R(qV, {
34454
+ } })), rH = M(Qr)(() => ({ color: `${A.tertiary()} !important` })), iH = ({ label: e, value: t, checked: n, onChange: r }) => /* @__PURE__ */ R(nH, {
34368
34455
  value: t,
34369
- control: /* @__PURE__ */ R(JV, {
34456
+ control: /* @__PURE__ */ R(rH, {
34370
34457
  checked: n,
34371
34458
  onChange: r
34372
34459
  }),
34373
34460
  label: e
34374
34461
  });
34375
- YV.propTypes = {
34462
+ iH.propTypes = {
34376
34463
  label: B.default.string,
34377
34464
  value: B.default.string,
34378
34465
  checked: B.default.bool,
@@ -34380,26 +34467,26 @@ YV.propTypes = {
34380
34467
  };
34381
34468
  //#endregion
34382
34469
  //#region ../../lib-react/config-ui/dist/settings/panel.js
34383
- var XV = (0, St.default)("pie-lib:config-ui:settings:panel"), ZV = {
34470
+ var aH = (0, St.default)("pie-lib:config-ui:settings:panel"), oH = {
34384
34471
  label: B.default.string,
34385
34472
  value: B.default.string
34386
- }, QV = {
34473
+ }, sH = {
34387
34474
  label: B.default.string,
34388
34475
  value: B.default.string,
34389
34476
  onChange: B.default.func
34390
- }, $V = ({ label: e, value: t, onChange: n }) => /* @__PURE__ */ R(AB, {
34477
+ }, cH = ({ label: e, value: t, onChange: n }) => /* @__PURE__ */ R(zB, {
34391
34478
  checked: t,
34392
34479
  label: e,
34393
34480
  onChange: (e) => {
34394
34481
  n(e.target.checked);
34395
34482
  }
34396
34483
  });
34397
- $V.propTypes = {
34484
+ cH.propTypes = {
34398
34485
  label: B.default.string,
34399
34486
  value: B.default.bool,
34400
34487
  onChange: B.default.func
34401
34488
  };
34402
- var eH = M(HB)(({ theme: e }) => ({
34489
+ var lH = M(ZB)(({ theme: e }) => ({
34403
34490
  marginTop: e.spacing(.5),
34404
34491
  paddingBottom: e.spacing(.5),
34405
34492
  width: "100%",
@@ -34410,29 +34497,29 @@ var eH = M(HB)(({ theme: e }) => ({
34410
34497
  marginTop: e.spacing(2.5)
34411
34498
  },
34412
34499
  "& > div": { marginTop: e.spacing(2.5) }
34413
- })), tH = ({ label: e, value: t, onChange: n, choices: r }) => /* @__PURE__ */ R(eH, {
34500
+ })), uH = ({ label: e, value: t, onChange: n, choices: r }) => /* @__PURE__ */ R(lH, {
34414
34501
  direction: "horizontal",
34415
- customLabel: YV,
34502
+ customLabel: iH,
34416
34503
  value: t,
34417
34504
  header: e,
34418
34505
  opts: r,
34419
34506
  onChange: n
34420
34507
  });
34421
- tH.propTypes = {
34422
- ...QV,
34423
- choices: B.default.arrayOf(B.default.shape(ZV))
34508
+ uH.propTypes = {
34509
+ ...sH,
34510
+ choices: B.default.arrayOf(B.default.shape(oH))
34424
34511
  };
34425
- var nH = tH, rH = M("p")(({ theme: e }) => ({
34512
+ var dH = uH, fH = M("p")(({ theme: e }) => ({
34426
34513
  margin: 0,
34427
34514
  fontSize: e.typography.fontSize
34428
- })), iH = M(fe)(({ theme: e }) => ({
34515
+ })), pH = M(fe)(({ theme: e }) => ({
34429
34516
  marginTop: e.spacing(.5),
34430
34517
  border: "2px solid lightgrey",
34431
34518
  padding: `0 ${e.spacing(1)}`,
34432
34519
  borderRadius: "4px"
34433
- })), aH = ({ label: e, value: t, onChange: n, choices: r = [] }) => {
34520
+ })), mH = ({ label: e, value: t, onChange: n, choices: r = [] }) => {
34434
34521
  let i = (e) => typeof e == "string" ? e : e.label, a = (e) => typeof e == "string" ? e : e.value;
34435
- return /* @__PURE__ */ z("div", { children: [e && /* @__PURE__ */ R(rH, { children: e }), /* @__PURE__ */ R(iH, {
34522
+ return /* @__PURE__ */ z("div", { children: [e && /* @__PURE__ */ R(fH, { children: e }), /* @__PURE__ */ R(pH, {
34436
34523
  value: t || r && r[0],
34437
34524
  onChange: ({ target: e }) => n(e.value),
34438
34525
  input: /* @__PURE__ */ R(ge, { id: `dropdown-${e}` }),
@@ -34447,14 +34534,14 @@ var nH = tH, rH = M("p")(({ theme: e }) => ({
34447
34534
  }, t))
34448
34535
  })] });
34449
34536
  };
34450
- aH.propTypes = {
34451
- ...QV,
34537
+ mH.propTypes = {
34538
+ ...sH,
34452
34539
  choices: B.default.arrayOf(B.default.string)
34453
34540
  };
34454
- var oH = M(xt)(({ theme: e }) => ({
34541
+ var hH = M(xt)(({ theme: e }) => ({
34455
34542
  marginRight: e.spacing(3),
34456
34543
  marginTop: e.spacing(1)
34457
- })), sH = ({ label: e }) => /* @__PURE__ */ R(oH, { children: e }), cH = M(PB)(({ theme: e }) => ({
34544
+ })), gH = ({ label: e }) => /* @__PURE__ */ R(hH, { children: e }), _H = M(UB)(({ theme: e }) => ({
34458
34545
  width: "35%",
34459
34546
  marginRight: e.spacing(3),
34460
34547
  marginTop: e.spacing(1),
@@ -34465,7 +34552,7 @@ var oH = M(xt)(({ theme: e }) => ({
34465
34552
  padding: `0 ${e.spacing(1)}`,
34466
34553
  backgroundColor: "transparent"
34467
34554
  }
34468
- })), lH = ({ label: e, value: t, onChange: n = () => {}, suffix: r, min: i, max: a }) => /* @__PURE__ */ R(cH, {
34555
+ })), vH = ({ label: e, value: t, onChange: n = () => {}, suffix: r, min: i, max: a }) => /* @__PURE__ */ R(_H, {
34469
34556
  variant: "standard",
34470
34557
  label: e || "Label",
34471
34558
  value: t,
@@ -34476,45 +34563,45 @@ var oH = M(xt)(({ theme: e }) => ({
34476
34563
  showErrorWhenOutsideRange: !0,
34477
34564
  disableUnderline: !0
34478
34565
  });
34479
- lH.propTypes = {
34480
- ...QV,
34566
+ vH.propTypes = {
34567
+ ...sH,
34481
34568
  suffix: B.default.string,
34482
34569
  min: B.default.number,
34483
34570
  max: B.default.number,
34484
34571
  value: B.default.number
34485
- }, sH.propTypes = { ...QV };
34486
- var uH = ({ disabled: e, label: t, value: n, onChange: r }) => /* @__PURE__ */ R(KV, {
34572
+ }, gH.propTypes = { ...sH };
34573
+ var yH = ({ disabled: e, label: t, value: n, onChange: r }) => /* @__PURE__ */ R(tH, {
34487
34574
  label: t,
34488
34575
  checked: !!n,
34489
34576
  disabled: !!e,
34490
34577
  toggle: r
34491
34578
  });
34492
- uH.propTypes = {
34493
- ...QV,
34579
+ yH.propTypes = {
34580
+ ...sH,
34494
34581
  value: B.default.bool
34495
34582
  };
34496
- var dH = {
34497
- toggle: uH,
34498
- radio: nH,
34499
- dropdown: aH,
34500
- numberField: lH,
34501
- checkbox: $V,
34502
- textField: sH
34503
- }, fH = M("div")(({ theme: e }) => ({ margin: `0 0 ${e.spacing(2)} 0` })), pH = M("div")(({ theme: e }) => ({
34583
+ var bH = {
34584
+ toggle: yH,
34585
+ radio: dH,
34586
+ dropdown: mH,
34587
+ numberField: vH,
34588
+ checkbox: cH,
34589
+ textField: gH
34590
+ }, xH = M("div")(({ theme: e }) => ({ margin: `0 0 ${e.spacing(2)} 0` })), SH = M("div")(({ theme: e }) => ({
34504
34591
  color: "#495B8F",
34505
34592
  fontSize: e.typography.fontSize + 2,
34506
34593
  fontWeight: 600,
34507
34594
  marginBottom: e.spacing(1)
34508
- })), mH = M("p")(({ theme: e }) => ({
34595
+ })), CH = M("p")(({ theme: e }) => ({
34509
34596
  fontSize: e.typography.fontSize,
34510
34597
  marginBottom: 0
34511
- })), hH = (e) => {
34598
+ })), wH = (e) => {
34512
34599
  let { model: t, label: r, group: i, configuration: a, onChange: o } = e, s = (e, r, i) => {
34513
34600
  let { isConfigProperty: s, ...c } = n(e, i || r), l = n(s ? a : t, r), u = {
34514
34601
  ...c,
34515
34602
  key: r,
34516
34603
  value: l
34517
- }, d = dH[u.type];
34604
+ }, d = bH[u.type];
34518
34605
  return /* @__PURE__ */ R(d, {
34519
34606
  ...u,
34520
34607
  onChange: (e) => o(r, e, s)
@@ -34523,18 +34610,18 @@ var dH = {
34523
34610
  let n = e[t];
34524
34611
  if (!n) return null;
34525
34612
  let { type: r, label: i, fields: a, choices: o } = n;
34526
- return r === "numberFields" ? /* @__PURE__ */ z("div", { children: [/* @__PURE__ */ R(mH, { children: i }), Object.keys(a).map((n) => s(e, `${t}.${n}`, `${t}.fields.${n}`))] }, `numberField-${i}`) : r === "checkboxes" ? /* @__PURE__ */ z("div", { children: [/* @__PURE__ */ R("p", { children: i }), Object.keys(o).map((n) => s(e, `${t}.${n}`, `${t}.choices.${n}`))] }, `checkbox-${i}`) : s(e, t);
34613
+ return r === "numberFields" ? /* @__PURE__ */ z("div", { children: [/* @__PURE__ */ R(CH, { children: i }), Object.keys(a).map((n) => s(e, `${t}.${n}`, `${t}.fields.${n}`))] }, `numberField-${i}`) : r === "checkboxes" ? /* @__PURE__ */ z("div", { children: [/* @__PURE__ */ R("p", { children: i }), Object.keys(o).map((n) => s(e, `${t}.${n}`, `${t}.choices.${n}`))] }, `checkbox-${i}`) : s(e, t);
34527
34614
  };
34528
- return /* @__PURE__ */ z(fH, { children: [/* @__PURE__ */ R(pH, { children: r }), Object.keys(i).map((e) => c(i, e))] });
34615
+ return /* @__PURE__ */ z(xH, { children: [/* @__PURE__ */ R(SH, { children: r }), Object.keys(i).map((e) => c(i, e))] });
34529
34616
  };
34530
- hH.propTypes = {
34617
+ wH.propTypes = {
34531
34618
  model: B.default.object,
34532
34619
  label: B.default.string,
34533
34620
  group: B.default.object,
34534
34621
  configuration: B.default.object,
34535
34622
  onChange: B.default.func
34536
34623
  };
34537
- var gH = class extends I.Component {
34624
+ var TH = class extends I.Component {
34538
34625
  static propTypes = {
34539
34626
  model: B.default.object,
34540
34627
  configuration: B.default.object,
@@ -34548,13 +34635,13 @@ var gH = class extends I.Component {
34548
34635
  onChangeConfiguration: () => {}
34549
34636
  };
34550
34637
  change = (e, t, n = !1) => {
34551
- XV("[changeModel]", e, t);
34638
+ aH("[changeModel]", e, t);
34552
34639
  let { onChangeModel: r, onChangeConfiguration: i } = this.props, a = { ...this.props.model }, o = { ...this.props.configuration };
34553
34640
  n ? (c(o, e, t), i(o, e)) : (c(a, e, t), r(a, e));
34554
34641
  };
34555
34642
  render() {
34556
34643
  let { groups: e, model: t, configuration: n, modal: r } = this.props;
34557
- return XV("render:", t), /* @__PURE__ */ z("div", { children: [Object.keys(e || {}).map((r) => Object.entries(e[r]).some(([, e]) => !!e) ? /* @__PURE__ */ R(hH, {
34644
+ return aH("render:", t), /* @__PURE__ */ z("div", { children: [Object.keys(e || {}).map((r) => Object.entries(e[r]).some(([, e]) => !!e) ? /* @__PURE__ */ R(wH, {
34558
34645
  label: r,
34559
34646
  model: t,
34560
34647
  configuration: n,
@@ -34562,59 +34649,59 @@ var gH = class extends I.Component {
34562
34649
  onChange: this.change
34563
34650
  }, r) : null), r] });
34564
34651
  }
34565
- }, _H = /* @__PURE__ */ GB({
34566
- Panel: () => gH,
34567
- checkbox: () => TH,
34568
- checkboxes: () => EH,
34569
- dropdown: () => SH,
34570
- numberField: () => CH,
34571
- numberFields: () => wH,
34572
- radio: () => xH,
34573
- textField: () => vH,
34574
- toggle: () => yH
34575
- }), vH = (e, t = !0) => ({
34652
+ }, EH = /* @__PURE__ */ eV({
34653
+ Panel: () => TH,
34654
+ checkbox: () => PH,
34655
+ checkboxes: () => FH,
34656
+ dropdown: () => jH,
34657
+ numberField: () => MH,
34658
+ numberFields: () => NH,
34659
+ radio: () => AH,
34660
+ textField: () => DH,
34661
+ toggle: () => OH
34662
+ }), DH = (e, t = !0) => ({
34576
34663
  label: e,
34577
34664
  type: "textField",
34578
34665
  isConfigProperty: t
34579
- }), yH = (e, t = !1, n = !1) => ({
34666
+ }), OH = (e, t = !1, n = !1) => ({
34580
34667
  type: "toggle",
34581
34668
  label: e,
34582
34669
  isConfigProperty: t,
34583
34670
  disabled: n
34584
- }), bH = (e) => typeof e == "string" ? {
34671
+ }), kH = (e) => typeof e == "string" ? {
34585
34672
  label: e,
34586
34673
  value: e
34587
- } : e, xH = function() {
34674
+ } : e, AH = function() {
34588
34675
  let [e, t, n = !1] = Array.prototype.slice.call(arguments);
34589
34676
  return {
34590
34677
  type: "radio",
34591
34678
  label: e,
34592
- choices: t && t.map((e) => bH(e)),
34679
+ choices: t && t.map((e) => kH(e)),
34593
34680
  isConfigProperty: n
34594
34681
  };
34595
- }, SH = (e, t, n = !1) => ({
34682
+ }, jH = (e, t, n = !1) => ({
34596
34683
  type: "dropdown",
34597
34684
  label: e,
34598
34685
  choices: t,
34599
34686
  isConfigProperty: n
34600
- }), CH = (e, t, n = !1) => ({
34687
+ }), MH = (e, t, n = !1) => ({
34601
34688
  ...t,
34602
34689
  label: e,
34603
34690
  type: "numberField",
34604
34691
  isConfigProperty: n
34605
- }), wH = (e, t, n = !1) => (Object.keys(t).map((e) => {
34606
- t[e] = CH(t[e].label, t[e], n);
34692
+ }), NH = (e, t, n = !1) => (Object.keys(t).map((e) => {
34693
+ t[e] = MH(t[e].label, t[e], n);
34607
34694
  }), {
34608
34695
  type: "numberFields",
34609
34696
  label: e,
34610
34697
  fields: t
34611
- }), TH = (e, t, n = !1) => ({
34698
+ }), PH = (e, t, n = !1) => ({
34612
34699
  ...t,
34613
34700
  label: e,
34614
34701
  type: "checkbox",
34615
34702
  isConfigProperty: n
34616
- }), EH = (e, t, n = !1) => (Object.keys(t).map((e) => {
34617
- t[e] = TH(t[e].label, t[e], n);
34703
+ }), FH = (e, t, n = !1) => (Object.keys(t).map((e) => {
34704
+ t[e] = PH(t[e].label, t[e], n);
34618
34705
  }), {
34619
34706
  type: "checkboxes",
34620
34707
  label: e,
@@ -34622,13 +34709,13 @@ var gH = class extends I.Component {
34622
34709
  });
34623
34710
  //#endregion
34624
34711
  //#region ../../lib-react/config-ui/dist/index.js
34625
- function DH(e) {
34712
+ function IH(e) {
34626
34713
  return typeof e == "function" || typeof e == "object" && !!e && typeof e.$$typeof == "symbol";
34627
34714
  }
34628
- function OH(e, t) {
34629
- return !e || DH(e) ? e : DH(e.default) ? e.default : t && DH(e[t]) ? e[t] : t && DH(e[t]?.default) ? e[t].default : e;
34715
+ function LH(e, t) {
34716
+ return !e || IH(e) ? e : IH(e.default) ? e.default : t && IH(e[t]) ? e[t] : t && IH(e[t]?.default) ? e[t].default : e;
34630
34717
  }
34631
- var kH = OH(y, "InputContainer") || OH(MH.InputContainer, "InputContainer"), AH = Ue, jH = AH.default, MH = jH && typeof jH == "object" ? jH : AH, NH = M(Qt)(({ theme: e }) => ({
34718
+ var RH = LH(y, "InputContainer") || LH(VH.InputContainer, "InputContainer"), zH = Ue, BH = zH.default, VH = BH && typeof BH == "object" ? BH : zH, HH = M(Qt)(({ theme: e }) => ({
34632
34719
  marginBottom: e.spacing(2.5),
34633
34720
  width: "100%",
34634
34721
  minWidth: "548px",
@@ -34650,34 +34737,34 @@ var kH = OH(y, "InputContainer") || OH(MH.InputContainer, "InputContainer"), AH
34650
34737
  width: "100%",
34651
34738
  maxWidth: "900px"
34652
34739
  }
34653
- })), PH = M(nn)(({ theme: e }) => ({ paddingBottom: `${e.spacing(2)} !important` })), FH = M(xt)({
34740
+ })), UH = M(nn)(({ theme: e }) => ({ paddingBottom: `${e.spacing(2)} !important` })), WH = M(xt)({
34654
34741
  fontWeight: 700,
34655
34742
  fontSize: "1.2rem",
34656
34743
  flex: 3
34657
- }), IH = M(kH)(({ theme: e }) => ({
34744
+ }), GH = M(RH)(({ theme: e }) => ({
34658
34745
  flex: 2,
34659
34746
  "& > *:not(label)": { marginTop: e.spacing(1) }
34660
- })), LH = M("div")(({ theme: e }) => ({ marginBottom: e.spacing(2) })), RH = M("div")({
34747
+ })), KH = M("div")(({ theme: e }) => ({ marginBottom: e.spacing(2) })), qH = M("div")({
34661
34748
  display: "flex",
34662
34749
  alignItems: "center",
34663
34750
  justifyContent: "space-between"
34664
- }), zH = M("div")({ display: "flex" }), BH = M("div")({
34751
+ }), JH = M("div")({ display: "flex" }), YH = M("div")({
34665
34752
  display: "flex",
34666
34753
  alignItems: "center",
34667
34754
  justifyContent: "flex-start"
34668
- }), VH = M("div")(({ theme: e }) => ({
34755
+ }), XH = M("div")(({ theme: e }) => ({
34669
34756
  fontSize: e.typography.fontSize - 2,
34670
34757
  color: e.palette.error.main,
34671
34758
  paddingTop: e.spacing(1)
34672
- })), HH = M(yn)({ color: `${A.tertiary()} !important` }), UH = M(ne)(() => ({
34759
+ })), ZH = M(yn)({ color: `${A.tertiary()} !important` }), QH = M(ne)(() => ({
34673
34760
  border: `1px solid ${A.border()}`,
34674
34761
  color: A.text()
34675
- })), WH = M(ne)(({ theme: e }) => ({
34762
+ })), $H = M(ne)(({ theme: e }) => ({
34676
34763
  marginLeft: e.spacing(2),
34677
34764
  border: `1px solid ${A.border()}`,
34678
34765
  color: A.disabled(),
34679
34766
  fontSize: "0.8rem"
34680
- })), GH = class extends F.Component {
34767
+ })), eU = class extends F.Component {
34681
34768
  static propTypes = {
34682
34769
  defaultResponse: B.default.bool,
34683
34770
  error: B.default.object,
@@ -34767,13 +34854,13 @@ var kH = OH(y, "InputContainer") || OH(MH.InputContainer, "InputContainer"), AH
34767
34854
  editor: "response-editor",
34768
34855
  mathToolbar: "math-toolbar"
34769
34856
  };
34770
- return /* @__PURE__ */ R(NH, {
34857
+ return /* @__PURE__ */ R(HH, {
34771
34858
  style: { minHeight: `${s.openCount > 0 ? 430 : 230}px` },
34772
- children: /* @__PURE__ */ z(PH, { children: [
34773
- /* @__PURE__ */ z(RH, { children: [/* @__PURE__ */ z(FH, {
34859
+ children: /* @__PURE__ */ z(UH, { children: [
34860
+ /* @__PURE__ */ z(qH, { children: [/* @__PURE__ */ z(WH, {
34774
34861
  component: "div",
34775
34862
  children: ["Response ", ""]
34776
- }), /* @__PURE__ */ R(IH, {
34863
+ }), /* @__PURE__ */ R(GH, {
34777
34864
  label: "Validation",
34778
34865
  children: /* @__PURE__ */ z(fe, {
34779
34866
  onChange: this.onChange("validation"),
@@ -34791,20 +34878,20 @@ var kH = OH(y, "InputContainer") || OH(MH.InputContainer, "InputContainer"), AH
34791
34878
  })]
34792
34879
  })
34793
34880
  })] }),
34794
- c === "literal" && /* @__PURE__ */ z(zH, { children: [i.enabled && /* @__PURE__ */ R(Zn, {
34881
+ c === "literal" && /* @__PURE__ */ z(JH, { children: [i.enabled && /* @__PURE__ */ R(Zn, {
34795
34882
  label: i.label,
34796
- control: /* @__PURE__ */ R(HH, {
34883
+ control: /* @__PURE__ */ R(ZH, {
34797
34884
  checked: f,
34798
34885
  onChange: this.onLiteralOptionsChange("allowTrailingZeros")
34799
34886
  })
34800
34887
  }), a.enabled && /* @__PURE__ */ R(Zn, {
34801
34888
  label: a.label,
34802
- control: /* @__PURE__ */ R(HH, {
34889
+ control: /* @__PURE__ */ R(ZH, {
34803
34890
  checked: d,
34804
34891
  onChange: this.onLiteralOptionsChange("ignoreOrder")
34805
34892
  })
34806
34893
  })] }),
34807
- /* @__PURE__ */ z(LH, { children: [
34894
+ /* @__PURE__ */ z(KH, { children: [
34808
34895
  /* @__PURE__ */ R(D, { children: "Correct Answer" }),
34809
34896
  /* @__PURE__ */ R(Ae, {
34810
34897
  keypadMode: e,
@@ -34817,10 +34904,10 @@ var kH = OH(y, "InputContainer") || OH(MH.InputContainer, "InputContainer"), AH
34817
34904
  onDone: this.onDone,
34818
34905
  error: o && o.answer
34819
34906
  }),
34820
- o && o.answer ? /* @__PURE__ */ R(VH, { children: o.answer }) : null
34907
+ o && o.answer ? /* @__PURE__ */ R(XH, { children: o.answer }) : null
34821
34908
  ] }),
34822
- p && Object.keys(u).map((t, n) => /* @__PURE__ */ z(LH, { children: [
34823
- /* @__PURE__ */ z(BH, { children: [/* @__PURE__ */ z(D, { children: ["Alternate", Object.keys(u).length > 1 ? ` ${n + 1}` : ""] }), /* @__PURE__ */ R(WH, {
34909
+ p && Object.keys(u).map((t, n) => /* @__PURE__ */ z(KH, { children: [
34910
+ /* @__PURE__ */ z(YH, { children: [/* @__PURE__ */ z(D, { children: ["Alternate", Object.keys(u).length > 1 ? ` ${n + 1}` : ""] }), /* @__PURE__ */ R($H, {
34824
34911
  type: "secondary",
34825
34912
  onClick: this.onRemoveAlternate(t),
34826
34913
  children: "Remove"
@@ -34836,9 +34923,9 @@ var kH = OH(y, "InputContainer") || OH(MH.InputContainer, "InputContainer"), AH
34836
34923
  onDone: this.onAlternateDone(t),
34837
34924
  error: o && o[t]
34838
34925
  }),
34839
- o && o[t] ? /* @__PURE__ */ R(VH, { children: o[t] }) : null
34926
+ o && o[t] ? /* @__PURE__ */ R(XH, { children: o[t] }) : null
34840
34927
  ] }, t)),
34841
- /* @__PURE__ */ R(UH, {
34928
+ /* @__PURE__ */ R(QH, {
34842
34929
  type: "primary",
34843
34930
  onClick: this.onAddAlternate,
34844
34931
  children: "ADD ALTERNATE"
@@ -34846,29 +34933,29 @@ var kH = OH(y, "InputContainer") || OH(MH.InputContainer, "InputContainer"), AH
34846
34933
  ] })
34847
34934
  });
34848
34935
  }
34849
- }, KH = {
34936
+ }, tU = {
34850
34937
  advanced: "Advanced Multi",
34851
34938
  simple: "Simple"
34852
- }, qH = (e = {}, t = {}) => {
34939
+ }, nU = (e = {}, t = {}) => {
34853
34940
  let { maxResponseAreas: n } = t, { responseType: r } = e, i = "";
34854
34941
  return r === "Advanced Multi" && (i = "\nThere should be at least 1 " + (n ? `and at most ${n} ` : "") + "response area" + (n ? "s" : "") + " defined."), "Validation requirements:\nAll correct answers (the primary and any alternates) should not be empty and should be unique." + i;
34855
- }, JH = (e = {}, t = {}) => ({
34942
+ }, rU = (e = {}, t = {}) => ({
34856
34943
  ...t,
34857
34944
  ...e
34858
- }), YH = E(/*#__PURE__*/ R("path", { d: "M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2m1 15h-2v-6h2zm0-8h-2V7h2z" }), "Info"), XH = !1, ZH = M("div")({
34945
+ }), iU = E(/*#__PURE__*/ R("path", { d: "M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2m1 15h-2v-6h2zm0-8h-2V7h2z" }), "Info"), aU = !1, oU = M("div")({
34859
34946
  display: "flex",
34860
34947
  flexDirection: "column"
34861
- }), QH = M(D)({ fontSize: "0.85rem" }), $H = M("div")({ fontSize: "1.1rem" }), eU = M("div")({
34948
+ }), sU = M(D)({ fontSize: "0.85rem" }), cU = M("div")({ fontSize: "1.1rem" }), lU = M("div")({
34862
34949
  display: "flex",
34863
34950
  alignItems: "center",
34864
34951
  justifyContent: "space-between"
34865
- }), tU = M(kH)(({ theme: e }) => ({
34952
+ }), uU = M(RH)(({ theme: e }) => ({
34866
34953
  flex: "initial",
34867
34954
  width: "40%",
34868
34955
  marginTop: e.spacing(2),
34869
34956
  marginBottom: e.spacing(2),
34870
34957
  "& > *:not(label)": { marginTop: e.spacing(1) }
34871
- })), nU = M("div")({
34958
+ })), dU = M("div")({
34872
34959
  display: "flex",
34873
34960
  flexDirection: "column",
34874
34961
  ".block-container": {
@@ -34902,28 +34989,28 @@ var kH = OH(y, "InputContainer") || OH(MH.InputContainer, "InputContainer"), AH
34902
34989
  padding: "8px"
34903
34990
  },
34904
34991
  ".math-toolbar": { maxWidth: "900px" }
34905
- }), rU = M(He)(({ theme: e }) => ({ "& .MuiTooltip-tooltip": {
34992
+ }), fU = M(He)(({ theme: e }) => ({ "& .MuiTooltip-tooltip": {
34906
34993
  fontSize: e.typography.fontSize - 2,
34907
34994
  whiteSpace: "pre-wrap"
34908
- } })), iU = M("div")(({ theme: e }) => ({
34995
+ } })), pU = M("div")(({ theme: e }) => ({
34909
34996
  fontSize: e.typography.fontSize - 2,
34910
34997
  color: e.palette.error.main,
34911
34998
  paddingTop: e.spacing(1)
34912
- })), aU = M(kH)(({ theme: e }) => ({
34999
+ })), mU = M(RH)(({ theme: e }) => ({
34913
35000
  width: "100%",
34914
35001
  paddingTop: e.spacing(2),
34915
35002
  marginBottom: e.spacing(2)
34916
- })), oU = M("div")(({ theme: e }) => ({ marginBottom: e.spacing(2.5) })), sU = /{{response}}/gm, cU = /\\%response\\%/gm, lU = /\\embed\{answerBlock\}\[r\d*\]/g, uU = /\\embed\{newLine\}\[\]/g, dU = /\\newline/g;
34917
- function fU(e) {
35003
+ })), hU = M("div")(({ theme: e }) => ({ marginBottom: e.spacing(2.5) })), gU = /{{response}}/gm, _U = /\\%response\\%/gm, vU = /\\embed\{answerBlock\}\[r\d*\]/g, yU = /\\embed\{newLine\}\[\]/g, bU = /\\newline/g;
35004
+ function xU(e) {
34918
35005
  if (e) {
34919
35006
  let t = 1;
34920
- return e.replace(sU, () => `\\embed{answerBlock}[r${t++}]`).replace(dU, "\\embed{newLine}[]");
35007
+ return e.replace(gU, () => `\\embed{answerBlock}[r${t++}]`).replace(bU, "\\embed{newLine}[]");
34921
35008
  }
34922
35009
  }
34923
- function pU(e) {
34924
- if (e) return e.replace(lU, () => "{{response}}").replace(cU, () => "{{response}}").replace(uU, () => "\\newline");
35010
+ function SU(e) {
35011
+ if (e) return e.replace(vU, () => "{{response}}").replace(_U, () => "{{response}}").replace(yU, () => "\\newline");
34925
35012
  }
34926
- var mU = class extends F.Component {
35013
+ var CU = class extends F.Component {
34927
35014
  static propTypes = {
34928
35015
  model: B.default.object.isRequired,
34929
35016
  imageSupport: B.default.object,
@@ -34939,7 +35026,7 @@ var mU = class extends F.Component {
34939
35026
  let t = {};
34940
35027
  if (e.model && e.model.expression) {
34941
35028
  let n = 1;
34942
- e.model.expression.replace(sU, () => {
35029
+ e.model.expression.replace(gU, () => {
34943
35030
  t[`r${n++}`] = { value: "" };
34944
35031
  });
34945
35032
  }
@@ -34951,7 +35038,7 @@ var mU = class extends F.Component {
34951
35038
  }
34952
35039
  onChange = (e) => (t) => {
34953
35040
  let { model: n, onChange: r } = this.props, i = { ...n };
34954
- typeof t == "object" ? i[e] = t.target.value : i[e] = t, e === "expression" && (i[e] = pU(t)), r(i);
35041
+ typeof t == "object" ? i[e] = t.target.value : i[e] = t, e === "expression" && (i[e] = SU(t)), r(i);
34955
35042
  };
34956
35043
  onDone = () => {
34957
35044
  this.setState({ showKeypad: !1 });
@@ -34963,7 +35050,7 @@ var mU = class extends F.Component {
34963
35050
  this.setState({ showKeypad: !1 });
34964
35051
  };
34965
35052
  UNSAFE_componentWillMount() {
34966
- typeof window < "u" && (XH ||= (ye("answerBlock", (e) => ({
35053
+ typeof window < "u" && (aU ||= (ye("answerBlock", (e) => ({
34967
35054
  htmlString: `
34968
35055
  <div class="block-container block-container-generic">
34969
35056
  <div class="block-response block-response-generic" id="${e}Index">Response</div>
@@ -34982,7 +35069,7 @@ var mU = class extends F.Component {
34982
35069
  let { model: e } = this.props, t = {};
34983
35070
  if (e && e.expression) {
34984
35071
  let n = 1;
34985
- e.expression.replace(sU, () => {
35072
+ e.expression.replace(gU, () => {
34986
35073
  t[`r${n++}`] = { value: "" };
34987
35074
  });
34988
35075
  }
@@ -35009,26 +35096,26 @@ var mU = class extends F.Component {
35009
35096
  i.responses[t] = e, r(i);
35010
35097
  };
35011
35098
  render() {
35012
- let { model: e, imageSupport: t, uploadSoundSupport: n, configuration: r, promptEnabled: i, rationaleEnabled: a, toolbarOpts: o } = this.props, { showKeypad: s } = this.state, { prompt: c, expression: l, equationEditor: u, promptEquationEditor: d = "8", responses: f, responseType: p, rationale: m, spellCheckEnabled: h, errors: g = {} } = e, { baseInputConfiguration: _ = {}, rationale: v = {}, prompt: y = {}, ignoreOrder: b = {}, allowTrailingZeros: x = {}, maxResponseAreas: S, maxImageWidth: C = {}, maxImageHeight: w = {}, mathMlOptions: T = {} } = r || {}, E = qH(r, e), { prompt: ee, rationale: D, responsesErrors: te, responseAreasError: ne } = g, re = C && C.prompt, O = w && w.prompt, k = {
35099
+ let { model: e, imageSupport: t, uploadSoundSupport: n, configuration: r, promptEnabled: i, rationaleEnabled: a, toolbarOpts: o } = this.props, { showKeypad: s } = this.state, { prompt: c, expression: l, equationEditor: u, promptEquationEditor: d = "8", responses: f, responseType: p, rationale: m, spellCheckEnabled: h, errors: g = {} } = e, { baseInputConfiguration: _ = {}, rationale: v = {}, prompt: y = {}, ignoreOrder: b = {}, allowTrailingZeros: x = {}, maxResponseAreas: S, maxImageWidth: C = {}, maxImageHeight: w = {}, mathMlOptions: T = {} } = r || {}, E = nU(r, e), { prompt: ee, rationale: D, responsesErrors: te, responseAreasError: ne } = g, re = C && C.prompt, O = w && w.prompt, k = {
35013
35100
  editor: "response-editor",
35014
35101
  mathToolbar: "math-toolbar"
35015
- }, ie = p === KH.advanced ? f : f.slice(0, 1), ae = /* @__PURE__ */ R(rU, {
35102
+ }, ie = p === tU.advanced ? f : f.slice(0, 1), ae = /* @__PURE__ */ R(fU, {
35016
35103
  disableFocusListener: !0,
35017
35104
  disableTouchListener: !0,
35018
35105
  placement: "right",
35019
35106
  title: E,
35020
- children: /* @__PURE__ */ R(YH, {
35107
+ children: /* @__PURE__ */ R(iU, {
35021
35108
  fontSize: "small",
35022
35109
  color: "primary",
35023
35110
  style: { marginLeft: "5px" }
35024
35111
  })
35025
35112
  });
35026
- return /* @__PURE__ */ z(ZH, {
35113
+ return /* @__PURE__ */ z(oU, {
35027
35114
  ref: (e) => this.root = e || this.root,
35028
35115
  children: [
35029
- i && /* @__PURE__ */ z(aU, {
35116
+ i && /* @__PURE__ */ z(mU, {
35030
35117
  label: y.label,
35031
- children: [/* @__PURE__ */ R(aB, {
35118
+ children: [/* @__PURE__ */ R(mB, {
35032
35119
  onFocus: this.onPromptFocus,
35033
35120
  markup: c || "",
35034
35121
  onChange: this.onChange("prompt"),
@@ -35036,21 +35123,21 @@ var mU = class extends F.Component {
35036
35123
  nonEmpty: !1,
35037
35124
  error: ee,
35038
35125
  toolbarOpts: o,
35039
- pluginProps: JH(y?.inputConfiguration, _),
35126
+ pluginProps: rU(y?.inputConfiguration, _),
35040
35127
  spellCheck: h,
35041
35128
  maxImageWidth: re,
35042
35129
  maxImageHeight: O,
35043
35130
  uploadSoundSupport: n,
35044
35131
  languageCharactersProps: [{ language: "spanish" }, { language: "special" }],
35045
35132
  mathMlOptions: T
35046
- }), ee && /* @__PURE__ */ R(iU, { children: ee })]
35133
+ }), ee && /* @__PURE__ */ R(pU, { children: ee })]
35047
35134
  }),
35048
- p === KH.advanced && /* @__PURE__ */ z(oU, { children: [
35049
- /* @__PURE__ */ z(eU, {
35135
+ p === tU.advanced && /* @__PURE__ */ z(hU, { children: [
35136
+ /* @__PURE__ */ z(lU, {
35050
35137
  style: { justifyContent: "flex-start" },
35051
- children: [/* @__PURE__ */ R($H, { children: "Define Response" }), ae]
35138
+ children: [/* @__PURE__ */ R(cU, { children: "Define Response" }), ae]
35052
35139
  }),
35053
- /* @__PURE__ */ R(tU, {
35140
+ /* @__PURE__ */ R(uU, {
35054
35141
  label: "Response Template Equation Editor",
35055
35142
  children: /* @__PURE__ */ z(fe, {
35056
35143
  onChange: this.onChange("promptEquationEditor"),
@@ -35111,26 +35198,26 @@ var mU = class extends F.Component {
35111
35198
  ]
35112
35199
  })
35113
35200
  }, "templateEditorType"),
35114
- /* @__PURE__ */ z(nU, { children: [/* @__PURE__ */ R(QH, { children: "RESPONSE TEMPLATE" }), /* @__PURE__ */ R(Ae, {
35201
+ /* @__PURE__ */ z(dU, { children: [/* @__PURE__ */ R(sU, { children: "RESPONSE TEMPLATE" }), /* @__PURE__ */ R(Ae, {
35115
35202
  classNames: k,
35116
35203
  allowAnswerBlock: !0,
35117
35204
  keypadMode: d,
35118
35205
  controlledKeypad: !0,
35119
35206
  showKeypad: s,
35120
- latex: fU(l) || "",
35207
+ latex: xU(l) || "",
35121
35208
  onChange: this.onChange("expression"),
35122
35209
  onFocus: this.onFocus,
35123
35210
  onDone: this.onDone,
35124
35211
  maxResponseAreas: S,
35125
35212
  error: ne
35126
35213
  })] }, "templateHolder"),
35127
- ne && /* @__PURE__ */ R(iU, { children: ne })
35214
+ ne && /* @__PURE__ */ R(pU, { children: ne })
35128
35215
  ] }),
35129
- /* @__PURE__ */ z(eU, {
35216
+ /* @__PURE__ */ z(lU, {
35130
35217
  style: { justifyContent: "flex-start" },
35131
- children: [/* @__PURE__ */ R($H, { children: "Define Correct Response" }), p === KH.simple ? ae : null]
35218
+ children: [/* @__PURE__ */ R(cU, { children: "Define Correct Response" }), p === tU.simple ? ae : null]
35132
35219
  }),
35133
- /* @__PURE__ */ R(tU, {
35220
+ /* @__PURE__ */ R(uU, {
35134
35221
  label: "Equation Editor",
35135
35222
  children: /* @__PURE__ */ z(fe, {
35136
35223
  onChange: this.onChange("equationEditor"),
@@ -35191,26 +35278,26 @@ var mU = class extends F.Component {
35191
35278
  ]
35192
35279
  })
35193
35280
  }),
35194
- ie.map((e, t) => /* @__PURE__ */ R(GH, {
35281
+ ie.map((e, t) => /* @__PURE__ */ R(eU, {
35195
35282
  mode: u,
35196
35283
  response: e,
35197
- defaultResponse: p === KH.simple,
35284
+ defaultResponse: p === tU.simple,
35198
35285
  onResponseChange: this.onResponseChange,
35199
35286
  index: t,
35200
35287
  cIgnoreOrder: b,
35201
35288
  cAllowTrailingZeros: x,
35202
35289
  error: te && te[t]
35203
35290
  }, e.id)),
35204
- a && /* @__PURE__ */ z(aU, {
35291
+ a && /* @__PURE__ */ z(mU, {
35205
35292
  label: v.label,
35206
- children: [/* @__PURE__ */ R(aB, {
35293
+ children: [/* @__PURE__ */ R(mB, {
35207
35294
  markup: m || "",
35208
35295
  onChange: this.onChange("rationale"),
35209
35296
  imageSupport: t,
35210
35297
  nonEmpty: !1,
35211
35298
  error: D,
35212
35299
  toolbarOpts: o,
35213
- pluginProps: JH(v?.inputConfiguration, {
35300
+ pluginProps: rU(v?.inputConfiguration, {
35214
35301
  ..._,
35215
35302
  math: { controlledKeypadMode: !1 }
35216
35303
  }),
@@ -35220,20 +35307,20 @@ var mU = class extends F.Component {
35220
35307
  uploadSoundSupport: n,
35221
35308
  languageCharactersProps: [{ language: "spanish" }, { language: "special" }],
35222
35309
  mathMlOptions: T
35223
- }), D && /* @__PURE__ */ R(iU, { children: D })]
35310
+ }), D && /* @__PURE__ */ R(pU, { children: D })]
35224
35311
  })
35225
35312
  ]
35226
35313
  });
35227
35314
  }
35228
- }, hU = (0, St.default)("@pie-element:math-inline:configure"), { Panel: gU, toggle: _U, radio: vU, dropdown: yU } = _H, bU = M(kH)(({ theme: e }) => ({
35315
+ }, wU = (0, St.default)("@pie-element:math-inline:configure"), { Panel: TU, toggle: EU, radio: DU, dropdown: OU } = EH, kU = M(RH)(({ theme: e }) => ({
35229
35316
  width: "100%",
35230
35317
  paddingTop: e.spacing(2),
35231
35318
  marginBottom: e.spacing(2)
35232
- })), xU = M("div")(({ theme: e }) => ({
35319
+ })), AU = M("div")(({ theme: e }) => ({
35233
35320
  fontSize: e.typography.fontSize - 2,
35234
35321
  color: e.palette.error.main,
35235
35322
  paddingTop: e.spacing(1)
35236
- })), SU = class extends I.Component {
35323
+ })), jU = class extends I.Component {
35237
35324
  static propTypes = {
35238
35325
  onModelChanged: B.default.func,
35239
35326
  onConfigurationChanged: B.default.func,
@@ -35257,28 +35344,28 @@ var mU = class extends F.Component {
35257
35344
  };
35258
35345
  render() {
35259
35346
  let { model: e, imageSupport: t, onModelChanged: n, configuration: r, onConfigurationChanged: i, uploadSoundSupport: a } = this.props, { allowTrailingZeros: o = {}, baseInputConfiguration: s = {}, contentDimensions: c = {}, feedback: l = {}, ignoreOrder: u = {}, maxImageWidth: d = {}, maxImageHeight: f = {}, prompt: p = {}, rationale: m = {}, responseType: h = {}, scoringType: g = {}, settingsPanelDisabled: _, spellCheck: v = {}, studentInstructions: y = {}, teacherInstructions: b = {}, withRubric: x = {}, mathMlOptions: S = {}, language: C = {}, languageChoices: w = {} } = r || {}, { errors: T = {}, extraCSSRules: E, feedbackEnabled: ee, promptEnabled: D, rationaleEnabled: te, spellCheckEnabled: ne, teacherInstructionsEnabled: re, toolbarEditorPosition: O } = e || {}, { teacherInstructions: k } = T;
35260
- hU("[render] model", e);
35347
+ wU("[render] model", e);
35261
35348
  let ie = { position: O === "top" ? "top" : "bottom" }, ae = d && d.prompt, oe = f && f.prompt, se = {
35262
- responseType: h.settings && vU(h.label, [KH.simple, KH.advanced]),
35263
- feedbackEnabled: l.settings && _U(l.label),
35264
- promptEnabled: p.settings && _U(p.label),
35265
- "language.enabled": C.settings && _U(C.label, !0),
35266
- language: C.settings && C.enabled && yU(w.label, w.options)
35349
+ responseType: h.settings && DU(h.label, [tU.simple, tU.advanced]),
35350
+ feedbackEnabled: l.settings && EU(l.label),
35351
+ promptEnabled: p.settings && EU(p.label),
35352
+ "language.enabled": C.settings && EU(C.label, !0),
35353
+ language: C.settings && C.enabled && OU(w.label, w.options)
35267
35354
  }, ce = {
35268
- teacherInstructionsEnabled: b.settings && _U(b.label),
35269
- studentInstructionsEnabled: y.settings && _U(y.label),
35270
- rationaleEnabled: m.settings && _U(m.label),
35271
- spellCheckEnabled: v.settings && _U(v.label),
35272
- scoringType: g.settings && vU(g.label, ["auto", "rubric"]),
35273
- "ignoreOrder.enabled": u.settings && _U(u.label),
35274
- "allowTrailingZeros.enabled": o.settings && _U(o.label),
35275
- rubricEnabled: x?.settings && _U(x?.label)
35355
+ teacherInstructionsEnabled: b.settings && EU(b.label),
35356
+ studentInstructionsEnabled: y.settings && EU(y.label),
35357
+ rationaleEnabled: m.settings && EU(m.label),
35358
+ spellCheckEnabled: v.settings && EU(v.label),
35359
+ scoringType: g.settings && DU(g.label, ["auto", "rubric"]),
35360
+ "ignoreOrder.enabled": u.settings && EU(u.label),
35361
+ "allowTrailingZeros.enabled": o.settings && EU(o.label),
35362
+ rubricEnabled: x?.settings && EU(x?.label)
35276
35363
  };
35277
- return /* @__PURE__ */ z(HV.ConfigLayout, {
35364
+ return /* @__PURE__ */ z(ZV.ConfigLayout, {
35278
35365
  extraCSSRules: E,
35279
35366
  dimensions: c,
35280
35367
  hideSettings: _,
35281
- settings: /* @__PURE__ */ R(gU, {
35368
+ settings: /* @__PURE__ */ R(TU, {
35282
35369
  model: e,
35283
35370
  configuration: r,
35284
35371
  onChangeModel: (e) => n(e),
@@ -35289,25 +35376,25 @@ var mU = class extends F.Component {
35289
35376
  }
35290
35377
  }),
35291
35378
  children: [
35292
- re && /* @__PURE__ */ z(bU, {
35379
+ re && /* @__PURE__ */ z(kU, {
35293
35380
  label: b.label,
35294
- children: [/* @__PURE__ */ R(aB, {
35381
+ children: [/* @__PURE__ */ R(mB, {
35295
35382
  markup: e.teacherInstructions || "",
35296
35383
  onChange: this.changeTeacherInstructions,
35297
35384
  imageSupport: t,
35298
35385
  nonEmpty: !1,
35299
35386
  error: k,
35300
35387
  toolbarOpts: ie,
35301
- pluginProps: JH(b?.inputConfiguration, s),
35388
+ pluginProps: rU(b?.inputConfiguration, s),
35302
35389
  spellCheck: ne,
35303
35390
  maxImageWidth: d && d.teacherInstructions || ae,
35304
35391
  maxImageHeight: f && f.teacherInstructions || oe,
35305
35392
  uploadSoundSupport: a,
35306
35393
  languageCharactersProps: [{ language: "spanish" }, { language: "special" }],
35307
35394
  mathMlOptions: S
35308
- }), k && /* @__PURE__ */ R(xU, { children: k })]
35395
+ }), k && /* @__PURE__ */ R(AU, { children: k })]
35309
35396
  }),
35310
- /* @__PURE__ */ R(mU, {
35397
+ /* @__PURE__ */ R(CU, {
35311
35398
  imageSupport: t,
35312
35399
  uploadSoundSupport: a,
35313
35400
  model: e,
@@ -35318,7 +35405,7 @@ var mU = class extends F.Component {
35318
35405
  toolbarOpts: ie,
35319
35406
  spellCheck: ne
35320
35407
  }),
35321
- ee && /* @__PURE__ */ R(TB, {
35408
+ ee && /* @__PURE__ */ R(PB, {
35322
35409
  feedback: e.feedback,
35323
35410
  onChange: this.onFeedbackChange,
35324
35411
  toolbarOpts: ie
@@ -35326,7 +35413,7 @@ var mU = class extends F.Component {
35326
35413
  ]
35327
35414
  });
35328
35415
  }
35329
- }, CU = class e extends CustomEvent {
35416
+ }, MU = class e extends CustomEvent {
35330
35417
  static {
35331
35418
  this.TYPE = "model.updated";
35332
35419
  }
@@ -35339,7 +35426,7 @@ var mU = class extends F.Component {
35339
35426
  }
35340
35427
  }), this.update = t, this.reset = n;
35341
35428
  }
35342
- }, wU = class e extends CustomEvent {
35429
+ }, NU = class e extends CustomEvent {
35343
35430
  static {
35344
35431
  this.TYPE = "delete.image";
35345
35432
  }
@@ -35352,7 +35439,7 @@ var mU = class extends F.Component {
35352
35439
  }
35353
35440
  }), this.src = t, this.done = n;
35354
35441
  }
35355
- }, TU = class e extends CustomEvent {
35442
+ }, PU = class e extends CustomEvent {
35356
35443
  static {
35357
35444
  this.TYPE = "insert.image";
35358
35445
  }
@@ -35362,7 +35449,7 @@ var mU = class extends F.Component {
35362
35449
  detail: t
35363
35450
  }), this.handler = t;
35364
35451
  }
35365
- }, EU = class e extends CustomEvent {
35452
+ }, FU = class e extends CustomEvent {
35366
35453
  static {
35367
35454
  this.TYPE = "delete.sound";
35368
35455
  }
@@ -35375,7 +35462,7 @@ var mU = class extends F.Component {
35375
35462
  }
35376
35463
  }), this.src = t, this.done = n;
35377
35464
  }
35378
- }, DU = class e extends CustomEvent {
35465
+ }, IU = class e extends CustomEvent {
35379
35466
  static {
35380
35467
  this.TYPE = "insert.sound";
35381
35468
  }
@@ -35385,7 +35472,7 @@ var mU = class extends F.Component {
35385
35472
  detail: t
35386
35473
  }), this.handler = t;
35387
35474
  }
35388
- }, OU = {
35475
+ }, LU = {
35389
35476
  model: {
35390
35477
  allowTrailingZerosDefault: !1,
35391
35478
  customKeys: [],
@@ -35412,7 +35499,7 @@ var mU = class extends F.Component {
35412
35499
  promptEnabled: !0,
35413
35500
  rationale: "",
35414
35501
  rationaleEnabled: !0,
35415
- responseType: KH.advanced,
35502
+ responseType: tU.advanced,
35416
35503
  responses: [],
35417
35504
  scoringType: "auto",
35418
35505
  studentInstructionsEnabled: !0,
@@ -35525,25 +35612,25 @@ var mU = class extends F.Component {
35525
35612
  options: []
35526
35613
  }
35527
35614
  }
35528
- }, kU = (0, St.default)("pie-elements:math-inline:configure"), AU = class e extends HTMLElement {
35615
+ }, RU = (0, St.default)("pie-elements:math-inline:configure"), zU = class e extends HTMLElement {
35529
35616
  static createDefaultModel = (e = {}) => (t(e.responses) || (e.responses = e.responses.map((e) => ({
35530
35617
  ...e,
35531
- validation: e.validation || OU.model.validationDefault,
35532
- allowTrailingZeros: e.allowTrailingZeros || OU.model.allowTrailingZerosDefault,
35533
- ignoreOrder: e.ignoreOrder || OU.model.ignoreOrderDefault || !1
35618
+ validation: e.validation || LU.model.validationDefault,
35619
+ allowTrailingZeros: e.allowTrailingZeros || LU.model.allowTrailingZerosDefault,
35620
+ ignoreOrder: e.ignoreOrder || LU.model.ignoreOrderDefault || !1
35534
35621
  }))), {
35535
- ...OU.model,
35622
+ ...LU.model,
35536
35623
  ...e
35537
35624
  });
35538
35625
  constructor() {
35539
- super(), this._root = null, this._model = e.createDefaultModel(), this._configuration = OU.configuration;
35626
+ super(), this._root = null, this._model = e.createDefaultModel(), this._configuration = LU.configuration;
35540
35627
  }
35541
35628
  set model(t) {
35542
35629
  this._model = e.createDefaultModel(t), this._render();
35543
35630
  }
35544
35631
  set configuration(e) {
35545
35632
  let t = {
35546
- ...OU.configuration,
35633
+ ...LU.configuration,
35547
35634
  ...e
35548
35635
  };
35549
35636
  this._configuration = t, t?.language?.enabled ? t?.languageChoices?.options?.length && (this._model.language = t?.languageChoices.options[0].value) : t.language.settings && this._model.language ? (this._configuration.language.enabled = !0, (!this._configuration.languageChoices.options || !this._configuration.languageChoices.options.length) && (this._configuration.languageChoices.options = []), this._configuration.languageChoices.options.find((e) => e.value === this._model.language) || this._configuration.languageChoices.options.push({
@@ -35552,26 +35639,26 @@ var mU = class extends F.Component {
35552
35639
  })) : delete this._model.language, this._render();
35553
35640
  }
35554
35641
  onModelChanged(e) {
35555
- this._model = e, kU("[onModelChanged]: ", this._model), this._render(), this.dispatchEvent(new CU(this._model));
35642
+ this._model = e, RU("[onModelChanged]: ", this._model), this._render(), this.dispatchEvent(new MU(this._model));
35556
35643
  }
35557
35644
  onConfigurationChanged(e) {
35558
35645
  this._configuration = e, this._model && this.onModelChanged(this._model), this._render();
35559
35646
  }
35560
35647
  insertImage(e) {
35561
- this.dispatchEvent(new TU(e));
35648
+ this.dispatchEvent(new PU(e));
35562
35649
  }
35563
35650
  onDeleteImage(e, t) {
35564
- this.dispatchEvent(new wU(e, t));
35651
+ this.dispatchEvent(new NU(e, t));
35565
35652
  }
35566
35653
  insertSound(e) {
35567
- this.dispatchEvent(new DU(e));
35654
+ this.dispatchEvent(new IU(e));
35568
35655
  }
35569
35656
  onDeleteSound(e, t) {
35570
- this.dispatchEvent(new EU(e, t));
35657
+ this.dispatchEvent(new FU(e, t));
35571
35658
  }
35572
35659
  _render() {
35573
35660
  if (this._model) {
35574
- let e = I.createElement(SU, {
35661
+ let e = I.createElement(jU, {
35575
35662
  onModelChanged: this.onModelChanged.bind(this),
35576
35663
  onConfigurationChanged: this.onConfigurationChanged.bind(this),
35577
35664
  model: this._model,
@@ -35596,6 +35683,6 @@ var mU = class extends F.Component {
35596
35683
  }
35597
35684
  };
35598
35685
  //#endregion
35599
- export { AU as default };
35686
+ export { zU as default };
35600
35687
 
35601
35688
  //# sourceMappingURL=index.js.map