@pie-element/fraction-model 6.1.2-next.7 → 6.1.2-next.8

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.
@@ -37398,8 +37398,8 @@ Iv.create({
37398
37398
  })) ?? null };
37399
37399
  }
37400
37400
  });
37401
- var IG = "placeholder", LG = new L("tiptap__placeholder"), RG = 200;
37402
- function zG(e) {
37401
+ var IG = "placeholder", LG = new L("tiptap__placeholder");
37402
+ function RG(e) {
37403
37403
  let { editor: t, placeholder: n, dataAttribute: r, pos: i, node: a, isEmptyDoc: o, hasAnchor: s, classes: { emptyNode: c, emptyEditor: l } } = e, u = [c];
37404
37404
  return o && u.push(l), zm.node(i, i + a.nodeSize, {
37405
37405
  class: u.join(" "),
@@ -37411,156 +37411,198 @@ function zG(e) {
37411
37411
  }) : n
37412
37412
  });
37413
37413
  }
37414
- function BG({ editor: e, options: t, dataAttribute: n, doc: r, selection: i }) {
37414
+ function zG(e, t) {
37415
+ return typeof e == "function" ? e(t) : e;
37416
+ }
37417
+ function BG({ editor: e, options: t, dataAttribute: n, doc: r, selection: i, from: a, to: o }) {
37418
+ let { anchor: s } = i, c = [], l = e.isEmpty;
37419
+ return r.nodesBetween(a, o, (r, i) => {
37420
+ let a = s >= i && s <= i + r.nodeSize, o = !r.isLeaf && W_(r);
37421
+ return r.type.isTextblock && (a || !t.showOnlyCurrent) && o && c.push(RG({
37422
+ editor: e,
37423
+ isEmptyDoc: l,
37424
+ dataAttribute: n,
37425
+ hasAnchor: a,
37426
+ placeholder: t.placeholder,
37427
+ classes: {
37428
+ emptyEditor: t.emptyEditorClass,
37429
+ emptyNode: zG(t.emptyNodeClass, {
37430
+ editor: e,
37431
+ node: r,
37432
+ pos: i,
37433
+ hasAnchor: a
37434
+ })
37435
+ },
37436
+ node: r,
37437
+ pos: i
37438
+ })), t.includeChildren;
37439
+ }), c;
37440
+ }
37441
+ function VG({ editor: e, options: t, dataAttribute: n, doc: r, selection: i }) {
37415
37442
  if (!(e.isEditable || !t.showOnlyWhenEditable)) return null;
37416
- let { anchor: a } = i, o = [], s = e.isEmpty, c = {
37417
- emptyEditor: t.emptyEditorClass,
37418
- emptyNode: t.emptyNodeClass
37419
- };
37443
+ let { anchor: a } = i, o = [], s = e.isEmpty;
37420
37444
  if (t.showOnlyCurrent && !t.includeChildren) {
37421
- let i = r.resolve(a), l = i.depth > 0 ? i.node(1) : i.nodeAfter, u = i.depth > 0 ? i.before(1) : a;
37422
- if (l && l.type.isTextblock && W_(l)) {
37423
- let r = a >= u && a <= u + l.nodeSize;
37424
- o.push(zG({
37445
+ let i = r.resolve(a), c = i.depth > 0 ? i.node(1) : i.nodeAfter, l = i.depth > 0 ? i.before(1) : a;
37446
+ if (c && c.type.isTextblock && W_(c)) {
37447
+ let r = a >= l && a <= l + c.nodeSize;
37448
+ o.push(RG({
37425
37449
  editor: e,
37426
37450
  isEmptyDoc: s,
37427
37451
  dataAttribute: n,
37428
37452
  hasAnchor: r,
37429
37453
  placeholder: t.placeholder,
37430
- classes: c,
37431
- node: l,
37432
- pos: u
37454
+ classes: {
37455
+ emptyEditor: t.emptyEditorClass,
37456
+ emptyNode: zG(t.emptyNodeClass, {
37457
+ editor: e,
37458
+ node: c,
37459
+ pos: l,
37460
+ hasAnchor: r
37461
+ })
37462
+ },
37463
+ node: c,
37464
+ pos: l
37433
37465
  }));
37434
37466
  }
37435
- } else {
37436
- let i = LG.getState(e.state), l = i?.topPos ?? 0, u = i?.bottomPos ?? r.content.size;
37437
- r.nodesBetween(l, u, (r, i) => {
37438
- let l = a >= i && a <= i + r.nodeSize, u = !r.isLeaf && W_(r);
37439
- return r.type.isTextblock && (l || !t.showOnlyCurrent) && u && o.push(zG({
37440
- editor: e,
37441
- isEmptyDoc: s,
37442
- dataAttribute: n,
37443
- hasAnchor: l,
37444
- placeholder: t.placeholder,
37445
- classes: c,
37446
- node: r,
37447
- pos: i
37448
- })), t.includeChildren;
37449
- });
37450
- }
37467
+ } else o.push(...BG({
37468
+ editor: e,
37469
+ options: t,
37470
+ dataAttribute: n,
37471
+ doc: r,
37472
+ selection: i,
37473
+ from: 0,
37474
+ to: r.content.size
37475
+ }));
37451
37476
  return Hm.create(r, o);
37452
37477
  }
37453
- function VG(e) {
37454
- return e.replace(/\s+/g, "-").replace(/[^a-zA-Z0-9-]/g, "").replace(/^[0-9-]+/, "").replace(/^-+/, "").toLowerCase();
37478
+ function HG(e, t) {
37479
+ let n = e.resolve(t);
37480
+ if (n.depth === 0) {
37481
+ let e = n.nodeAfter ?? n.nodeBefore;
37482
+ if (!e) return {
37483
+ from: t,
37484
+ to: t
37485
+ };
37486
+ let r = n.nodeAfter ? t : t - e.nodeSize;
37487
+ return {
37488
+ from: r,
37489
+ to: r + e.nodeSize
37490
+ };
37491
+ }
37492
+ let r = n.before(1);
37493
+ return {
37494
+ from: r,
37495
+ to: r + n.node(1).nodeSize
37496
+ };
37455
37497
  }
37456
- function HG(e) {
37457
- let t = getComputedStyle(e), n = `${t.overflow} ${t.overflowY} ${t.overflowX}`;
37458
- return /auto|scroll|overlay/.test(n);
37498
+ function UG(e, t) {
37499
+ return {
37500
+ from: Math.max(0, t.from - 1),
37501
+ to: Math.min(e.content.size, t.to - 1)
37502
+ };
37459
37503
  }
37460
- function UG(e) {
37461
- let t = e;
37462
- for (; t;) {
37463
- if (HG(t)) return t;
37464
- let e = t.parentElement;
37465
- if (!e) {
37466
- let e = t.getRootNode();
37467
- if (e instanceof ShadowRoot) {
37468
- t = e.host;
37469
- continue;
37470
- }
37471
- return window;
37472
- }
37473
- t = e;
37504
+ function WG(e, t, n) {
37505
+ let r = [];
37506
+ return e.forEach((e, i) => {
37507
+ let a = i, o = a + e.nodeSize, s = a + 1, c = o + 1;
37508
+ s < n && c > t && r.push({
37509
+ from: a,
37510
+ to: o
37511
+ });
37512
+ }), r;
37513
+ }
37514
+ function GG(e) {
37515
+ if (e.length === 0) return [];
37516
+ let t = [...e].sort((e, t) => e.from - t.from), n = [{ ...t[0] }];
37517
+ for (let e = 1; e < t.length; e += 1) {
37518
+ let r = n[n.length - 1], i = t[e];
37519
+ i.from <= r.to ? r.to = Math.max(r.to, i.to) : n.push({ ...i });
37474
37520
  }
37475
- return window;
37521
+ return n;
37476
37522
  }
37477
- function WG(e) {
37478
- return e === window ? {
37479
- top: 0,
37480
- bottom: window.innerHeight
37481
- } : e.getBoundingClientRect();
37523
+ function KG(e, t) {
37524
+ let n = WG(e, t.from, t.to);
37525
+ return n.push(UG(e, HG(e, t.from))), t.to > t.from ? n.push(UG(e, HG(e, Math.min(t.to, e.content.size + 1) - 1))) : t.from < e.content.size + 1 && n.push(UG(e, HG(e, Math.min(t.from + 1, e.content.size)))), n;
37482
37526
  }
37483
- function GG({ doc: e, view: t, scrollContainer: n }) {
37484
- let r = t.dom.getBoundingClientRect(), i = n ? WG(n) : {
37485
- top: 0,
37486
- bottom: window.innerHeight
37487
- }, a = Math.max(r.top, i.top) - RG, o = Math.min(r.bottom, i.bottom) + RG;
37488
- if (a >= o) return {
37489
- top: 0,
37490
- bottom: e.content.size
37491
- };
37492
- let s = getComputedStyle(t.dom).direction === "rtl" ? Math.max(r.right - 2, r.left + 2) : r.left + 2, c = t.posAtCoords({
37493
- left: s,
37494
- top: a + 2
37495
- }), l = t.posAtCoords({
37496
- left: s,
37497
- top: o - 2
37498
- });
37499
- return {
37500
- top: c ? c.pos : 0,
37501
- bottom: l ? l.pos : e.content.size
37502
- };
37527
+ function qG(e, t, n) {
37528
+ let r = [];
37529
+ if (e.docChanged) {
37530
+ let t = N_(e);
37531
+ for (let e of t) r.push(...KG(n.doc, e.newRange));
37532
+ }
37533
+ return e.selectionSet && (r.push(UG(n.doc, HG(n.doc, e.mapping.map(t.selection.anchor)))), r.push(UG(n.doc, HG(n.doc, n.selection.anchor)))), GG(r);
37503
37534
  }
37504
- var KG = {
37505
- init() {
37506
- return {
37507
- topPos: null,
37508
- bottomPos: null
37509
- };
37510
- },
37511
- apply(e, t) {
37512
- let n = e.getMeta(LG);
37513
- return n?.positions ? {
37514
- topPos: n.positions.top,
37515
- bottomPos: n.positions.bottom
37516
- } : e.docChanged ? {
37517
- topPos: t.topPos === null ? null : e.mapping.map(t.topPos),
37518
- bottomPos: t.bottomPos === null ? null : e.mapping.map(t.bottomPos)
37519
- } : t;
37535
+ function JG(e, t, n) {
37536
+ let r = Math.max(0, Math.min(e, n.content.size));
37537
+ return {
37538
+ from: r,
37539
+ to: Math.max(r, Math.min(t, n.content.size))
37540
+ };
37541
+ }
37542
+ function YG({ decorations: e, ranges: t, editor: n, options: r, dataAttribute: i, doc: a, selection: o }) {
37543
+ let s = e;
37544
+ for (let e of t) {
37545
+ let { from: t, to: c } = JG(e.from, e.to, a), l = s.find(t, c).filter((e) => e.from >= t && e.to <= c);
37546
+ l.length && (s = s.remove(l));
37547
+ let u = BG({
37548
+ editor: n,
37549
+ options: r,
37550
+ dataAttribute: i,
37551
+ doc: a,
37552
+ selection: o,
37553
+ from: t,
37554
+ to: c
37555
+ });
37556
+ u.length && (s = s.add(a, u));
37520
37557
  }
37521
- };
37522
- function qG(e) {
37523
- let t = UG(e.dom), n = () => {
37524
- let n = GG({
37525
- view: e,
37526
- doc: e.state.doc,
37527
- scrollContainer: t
37528
- }), r = LG.getState(e.state);
37529
- if (r?.topPos === n.top && r?.bottomPos === n.bottom) return;
37530
- let i = e.state.tr.setMeta(LG, { positions: n });
37531
- e.dispatch(i);
37532
- }, r = null, i = 0, a = () => {
37533
- r === null && (r = requestAnimationFrame(() => {
37534
- r = null;
37535
- let e = performance.now();
37536
- e - i >= 150 ? (i = e, n()) : a();
37537
- }));
37538
- };
37539
- return t.addEventListener("scroll", a, { passive: !0 }), n(), {
37540
- update(t, n) {
37541
- e.state.doc.content.size !== n.doc.content.size && a();
37558
+ return s;
37559
+ }
37560
+ function XG({ editor: e, options: t, dataAttribute: n }) {
37561
+ return {
37562
+ init(r, i) {
37563
+ return VG({
37564
+ editor: e,
37565
+ options: t,
37566
+ dataAttribute: n,
37567
+ doc: i.doc,
37568
+ selection: i.selection
37569
+ }) ?? Hm.empty;
37542
37570
  },
37543
- destroy: () => {
37544
- r !== null && cancelAnimationFrame(r), t.removeEventListener("scroll", a);
37571
+ apply(r, i, a, o) {
37572
+ return !r.docChanged && !r.selectionSet ? i : YG({
37573
+ decorations: i.map(r.mapping, r.doc),
37574
+ ranges: qG(r, a, o),
37575
+ editor: e,
37576
+ options: t,
37577
+ dataAttribute: n,
37578
+ doc: o.doc,
37579
+ selection: o.selection
37580
+ });
37545
37581
  }
37546
37582
  };
37547
37583
  }
37548
- function JG({ editor: e, options: t }) {
37549
- let n = t.dataAttribute ? `data-${VG(t.dataAttribute)}` : `data-${IG}`;
37584
+ function ZG(e) {
37585
+ return e.replace(/\s+/g, "-").replace(/[^a-zA-Z0-9-]/g, "").replace(/^[0-9-]+/, "").replace(/^-+/, "").toLowerCase();
37586
+ }
37587
+ function QG({ editor: e, options: t }) {
37588
+ let n = t.dataAttribute ? `data-${ZG(t.dataAttribute)}` : `data-${IG}`, r = t.showOnlyCurrent && !t.includeChildren;
37550
37589
  return new I({
37551
37590
  key: LG,
37552
- state: KG,
37553
- view: qG,
37554
- props: { decorations: ({ doc: r, selection: i }) => BG({
37591
+ ...r ? {} : { state: XG({
37592
+ editor: e,
37593
+ options: t,
37594
+ dataAttribute: n
37595
+ }) },
37596
+ props: { decorations: r ? ({ doc: r, selection: i }) => VG({
37555
37597
  editor: e,
37556
37598
  options: t,
37557
37599
  dataAttribute: n,
37558
37600
  doc: r,
37559
37601
  selection: i
37560
- }) }
37602
+ }) : (n) => t.showOnlyWhenEditable && !e.isEditable ? Hm.empty : LG.getState(n) ?? Hm.empty }
37561
37603
  });
37562
37604
  }
37563
- var YG = Iv.create({
37605
+ var $G = Iv.create({
37564
37606
  name: "placeholder",
37565
37607
  addOptions() {
37566
37608
  return {
@@ -37574,12 +37616,25 @@ var YG = Iv.create({
37574
37616
  };
37575
37617
  },
37576
37618
  addProseMirrorPlugins() {
37577
- return [JG({
37619
+ return [QG({
37578
37620
  editor: this.editor,
37579
37621
  options: this.options
37580
37622
  })];
37581
37623
  }
37582
37624
  });
37625
+ function eK(e, t) {
37626
+ return !e.selection.empty && !G_(e.selection) && t.isEditable;
37627
+ }
37628
+ function tK(e, t) {
37629
+ return eK(e, t) && !t.isFocused && !t.view.dragging;
37630
+ }
37631
+ function nK() {
37632
+ var e;
37633
+ (e = window.getSelection()) == null || e.removeAllRanges();
37634
+ }
37635
+ function rK(e) {
37636
+ e.focus();
37637
+ }
37583
37638
  Iv.create({
37584
37639
  name: "selection",
37585
37640
  addOptions() {
@@ -37589,13 +37644,25 @@ Iv.create({
37589
37644
  let { editor: e, options: t } = this;
37590
37645
  return [new I({
37591
37646
  key: new L("selection"),
37592
- props: { decorations(n) {
37593
- return n.selection.empty || e.isFocused || !e.isEditable || G_(n.selection) || e.view.dragging ? null : Hm.create(n.doc, [zm.inline(n.selection.from, n.selection.to, { class: t.className })]);
37594
- } }
37647
+ props: {
37648
+ decorations(n) {
37649
+ return tK(n, e) ? Hm.create(n.doc, [zm.inline(n.selection.from, n.selection.to, { class: t.className })]) : null;
37650
+ },
37651
+ handleDOMEvents: {
37652
+ blur(t) {
37653
+ return eK(t.state, e) && nK(), !1;
37654
+ },
37655
+ focus(t) {
37656
+ return eK(t.state, e) && requestAnimationFrame(() => {
37657
+ !e.isDestroyed && t.hasFocus() && rK(t);
37658
+ }), !1;
37659
+ }
37660
+ }
37661
+ }
37595
37662
  })];
37596
37663
  }
37597
37664
  });
37598
- function XG({ types: e, node: t }) {
37665
+ function iK({ types: e, node: t }) {
37599
37666
  return t && Array.isArray(e) && e.includes(t.type) || t?.type === e;
37600
37667
  }
37601
37668
  Iv.create({
@@ -37617,7 +37684,7 @@ Iv.create({
37617
37684
  state: {
37618
37685
  init: (e, t) => {
37619
37686
  let r = t.tr.doc.lastChild;
37620
- return !XG({
37687
+ return !iK({
37621
37688
  node: r,
37622
37689
  types: n
37623
37690
  });
@@ -37625,7 +37692,7 @@ Iv.create({
37625
37692
  apply: (e, t) => {
37626
37693
  if (!e.docChanged || e.getMeta("__uniqueIDTransaction")) return t;
37627
37694
  let r = e.doc.lastChild;
37628
- return !XG({
37695
+ return !iK({
37629
37696
  node: r,
37630
37697
  types: n
37631
37698
  });
@@ -37660,7 +37727,7 @@ Iv.create({
37660
37727
  };
37661
37728
  }
37662
37729
  });
37663
- var ZG = Ov.create({
37730
+ var aK = Ov.create({
37664
37731
  name: "superscript",
37665
37732
  addOptions() {
37666
37733
  return { HTMLAttributes: {} };
@@ -37690,7 +37757,7 @@ var ZG = Ov.create({
37690
37757
  addKeyboardShortcuts() {
37691
37758
  return { "Mod-.": () => this.editor.commands.toggleSuperscript() };
37692
37759
  }
37693
- }), QG = Ov.create({
37760
+ }), oK = Ov.create({
37694
37761
  name: "subscript",
37695
37762
  addOptions() {
37696
37763
  return { HTMLAttributes: {} };
@@ -37720,7 +37787,7 @@ var ZG = Ov.create({
37720
37787
  addKeyboardShortcuts() {
37721
37788
  return { "Mod-,": () => this.editor.commands.toggleSubscript() };
37722
37789
  }
37723
- }), $G = Iv.create({
37790
+ }), sK = Iv.create({
37724
37791
  name: "textAlign",
37725
37792
  addOptions() {
37726
37793
  return {
@@ -37762,7 +37829,7 @@ var ZG = Ov.create({
37762
37829
  "Mod-Shift-j": () => this.editor.commands.setTextAlign("justify")
37763
37830
  };
37764
37831
  }
37765
- }), eK = /(?:^|\s)(!\[(.+|:?)]\((\S+)(?:(?:\s+)["'](\S+)["'])?\))$/, tK = fy.create({
37832
+ }), cK = /(?:^|\s)(!\[(.+|:?)]\((\S+)(?:(?:\s+)["'](\S+)["'])?\))$/, lK = fy.create({
37766
37833
  name: "image",
37767
37834
  addOptions() {
37768
37835
  return {
@@ -37855,7 +37922,7 @@ var ZG = Ov.create({
37855
37922
  },
37856
37923
  addInputRules() {
37857
37924
  return [Qv({
37858
- find: eK,
37925
+ find: cK,
37859
37926
  type: this.type,
37860
37927
  getAttributes: (e) => {
37861
37928
  let [, , t, n, r] = e;
@@ -37867,17 +37934,17 @@ var ZG = Ov.create({
37867
37934
  }
37868
37935
  })];
37869
37936
  }
37870
- }), nK = YG, rK = {
37937
+ }), uK = $G, dK = {
37871
37938
  position: "bottom",
37872
37939
  alignment: "left",
37873
37940
  alwaysVisible: !1,
37874
37941
  showDone: !0,
37875
37942
  doneOn: "blur"
37876
- }, iK = {
37943
+ }, fK = {
37877
37944
  options: {},
37878
37945
  respAreaToolbar: () => {},
37879
37946
  onHandleAreaChange: () => {}
37880
- }, aK = [
37947
+ }, pK = [
37881
37948
  "bold",
37882
37949
  "italic",
37883
37950
  "underline",
@@ -37899,7 +37966,7 @@ var ZG = Ov.create({
37899
37966
  "h3",
37900
37967
  "undo",
37901
37968
  "redo"
37902
- ], oK = {
37969
+ ], mK = {
37903
37970
  "--white": "#fff",
37904
37971
  "--black": "#2e2b29",
37905
37972
  "--black-contrast": "#110f0e",
@@ -37918,14 +37985,18 @@ var ZG = Ov.create({
37918
37985
  "--red": "#ff5c33",
37919
37986
  "--red-light": "#ffebe5",
37920
37987
  "--shadow": "0px 12px 33px 0px rgba(0, 0, 0, .06),\n 0px 3.618px 9.949px 0px rgba(0, 0, 0, .04)"
37921
- }, sK = (e) => {
37988
+ }, hK = (e) => ({
37989
+ spellcheck: e ? "true" : "false",
37990
+ autocorrect: e ? "on" : "off",
37991
+ autocapitalize: e ? "on" : "off"
37992
+ }), gK = (e) => {
37922
37993
  let { showParagraphs: t, separateParagraphs: n } = e.pluginProps || {}, [r, i] = gt([]), [a, o] = gt(!1), { toolbarOpts: s } = e, c = lt((e) => {
37923
37994
  i((t) => {
37924
37995
  let n = t.filter((t) => t.pos !== e);
37925
37996
  return n.length === 0 && o(!1), n;
37926
37997
  });
37927
37998
  }, [i]), l = {
37928
- ...rK,
37999
+ ...dK,
37929
38000
  ...s
37930
38001
  }, u = lt((t) => {
37931
38002
  let n = t.getHTML();
@@ -37936,13 +38007,13 @@ var ZG = Ov.create({
37936
38007
  e.onDone,
37937
38008
  l.doneOn
37938
38009
  ]), d = mt(() => ({
37939
- ...iK,
38010
+ ...fK,
37940
38011
  ...e.responseAreaProps,
37941
38012
  onInlineDropdownToolbarClose: u
37942
38013
  }), [e.responseAreaProps, u]), f = mt(() => {
37943
38014
  let { customPlugins: t, ...n } = e.pluginProps || {};
37944
38015
  t ||= [];
37945
- let r = (e.activePlugins || aK)?.filter((e) => {
38016
+ let r = (e.activePlugins || pK)?.filter((e) => {
37946
38017
  let t = Na[e] || e, r = n[t] || {};
37947
38018
  return !r || !r.disabled;
37948
38019
  });
@@ -37960,103 +38031,112 @@ var ZG = Ov.create({
37960
38031
  setKeypadInteraction: {},
37961
38032
  media: {}
37962
38033
  });
37963
- }, [e, d.type]), p = hD({
37964
- extensions: [
37965
- $G.configure({
37966
- types: [
37967
- "heading",
37968
- "paragraph",
37969
- "div",
37970
- "headingParagraph",
37971
- "h1",
37972
- "h2",
37973
- "h3",
37974
- "h4",
37975
- "h5",
37976
- "h6",
37977
- "td",
37978
- "th"
37979
- ],
37980
- alignments: [
37981
- "left",
37982
- "right",
37983
- "center",
37984
- "justify"
37985
- ]
37986
- }),
37987
- PG,
37988
- FG.configure({ limit: e.charactersLimit || 1e6 }),
37989
- wG.configure({ trailingNode: {
38034
+ }, [e, d.type]), p = [
38035
+ sK.configure({
38036
+ types: [
38037
+ "heading",
38038
+ "paragraph",
38039
+ "div",
38040
+ "headingParagraph",
38041
+ "h1",
38042
+ "h2",
38043
+ "h3",
38044
+ "h4",
38045
+ "h5",
38046
+ "h6",
38047
+ "td",
38048
+ "th"
38049
+ ],
38050
+ alignments: [
38051
+ "left",
38052
+ "right",
38053
+ "center",
38054
+ "justify"
38055
+ ]
38056
+ }),
38057
+ PG,
38058
+ FG.configure({ limit: e.charactersLimit || 1e6 }),
38059
+ wG.configure({
38060
+ trailingNode: {
37990
38061
  node: "paragraph",
37991
38062
  notAfter: ["paragraph", "div"]
37992
- } }),
37993
- OI,
37994
- WT,
37995
- kI,
37996
- GT,
37997
- KT,
37998
- nK.configure({
37999
- placeholder: e.placeholder,
38000
- showOnlyWhenEditable: !0,
38001
- showOnlyCurrent: !1,
38002
- includeChildren: !0
38003
- }),
38004
- BT,
38005
- wT,
38006
- UT,
38007
- HT,
38008
- fP.configure(d),
38009
- pP.configure(d),
38010
- hP.configure(d),
38011
- gP.configure(d),
38012
- mP.configure(d),
38013
- $P.configure({
38014
- toolbarOpts: l,
38015
- math: e.pluginProps?.math || {}
38016
- }),
38017
- QG,
38018
- ZG,
38019
- tK,
38020
- bF.configure({
38021
- toolbarOpts: l,
38022
- imageHandling: {
38023
- disableImageAlignmentButtons: e.disableImageAlignmentButtons,
38024
- onDone: (t) => e.onDone?.(t.getHTML()),
38025
- onDelete: e.imageSupport && e.imageSupport.delete && ((t) => {
38026
- let { src: n } = t.attrs;
38027
- e.imageSupport.delete(n, (e) => {
38028
- c(t.pos);
38029
- });
38030
- }),
38031
- insertImageRequested: e.imageSupport && ((t, n, r) => {
38032
- let [o, s] = n, l = (n) => {
38033
- let r;
38034
- a && n && (r = e.onChange), c(s), r?.(t.getHTML());
38035
- };
38036
- t._insertingImage = !0, i((e) => [...e, o]), (() => {
38037
- let n = r(l), i = Ke(() => {
38038
- let e = () => window.removeEventListener("focus", i);
38039
- if (!t._insertingImage) {
38040
- e();
38041
- return;
38042
- }
38043
- c(s), t._insertingImage = !1, e();
38044
- }, 500);
38045
- window.addEventListener("focus", i), e.imageSupport.add(n);
38046
- })();
38047
- }),
38048
- maxImageWidth: e.maxImageWidth,
38049
- maxImageHeight: e.maxImageHeight
38050
- },
38051
- limit: 3
38052
- }),
38053
- VF.configure({ uploadSoundSupport: e.uploadSoundSupport }),
38054
- qF.configure({ extraCSSRules: e.extraCSSRules })
38055
- ],
38063
+ },
38064
+ link: {
38065
+ autolink: !1,
38066
+ linkOnPaste: !1
38067
+ }
38068
+ }),
38069
+ OI,
38070
+ WT,
38071
+ kI,
38072
+ GT,
38073
+ KT,
38074
+ uK.configure({
38075
+ placeholder: e.placeholder,
38076
+ showOnlyWhenEditable: !0,
38077
+ showOnlyCurrent: !1,
38078
+ includeChildren: !0
38079
+ }),
38080
+ BT,
38081
+ wT,
38082
+ UT,
38083
+ HT,
38084
+ fP.configure(d),
38085
+ pP.configure(d),
38086
+ hP.configure(d),
38087
+ gP.configure(d),
38088
+ mP.configure(d),
38089
+ $P.configure({
38090
+ toolbarOpts: l,
38091
+ math: e.pluginProps?.math || {}
38092
+ }),
38093
+ oK,
38094
+ aK,
38095
+ lK,
38096
+ bF.configure({
38097
+ toolbarOpts: l,
38098
+ imageHandling: {
38099
+ disableImageAlignmentButtons: e.disableImageAlignmentButtons,
38100
+ onDone: (t) => e.onDone?.(t.getHTML()),
38101
+ onDelete: e.imageSupport && e.imageSupport.delete && ((t) => {
38102
+ let { src: n } = t.attrs;
38103
+ e.imageSupport.delete(n, (e) => {
38104
+ c(t.pos);
38105
+ });
38106
+ }),
38107
+ insertImageRequested: e.imageSupport && ((t, n, r) => {
38108
+ let [o, s] = n, l = (n) => {
38109
+ let r;
38110
+ a && n && (r = e.onChange), c(s), r?.(t.getHTML());
38111
+ };
38112
+ t._insertingImage = !0, i((e) => [...e, o]), (() => {
38113
+ let n = r(l), i = Ke(() => {
38114
+ let e = () => window.removeEventListener("focus", i);
38115
+ if (!t._insertingImage) {
38116
+ e();
38117
+ return;
38118
+ }
38119
+ c(s), t._insertingImage = !1, e();
38120
+ }, 500);
38121
+ window.addEventListener("focus", i), e.imageSupport.add(n);
38122
+ })();
38123
+ }),
38124
+ maxImageWidth: e.maxImageWidth,
38125
+ maxImageHeight: e.maxImageHeight
38126
+ },
38127
+ limit: 3
38128
+ }),
38129
+ VF.configure({ uploadSoundSupport: e.uploadSoundSupport }),
38130
+ qF.configure({ extraCSSRules: e.extraCSSRules })
38131
+ ], m = e.spellCheck !== !1, h = hD({
38132
+ extensions: p,
38056
38133
  immediatelyRender: !1,
38057
- editorProps: { handleKeyDown(t, n) {
38058
- return e.onKeyDown ? e.onKeyDown(n) : !1;
38059
- } },
38134
+ editorProps: {
38135
+ attributes: hK(m),
38136
+ handleKeyDown(t, n) {
38137
+ return e.onKeyDown ? e.onKeyDown(n) : !1;
38138
+ }
38139
+ },
38060
38140
  editable: !e.disabled,
38061
38141
  content: Ra(e.markup),
38062
38142
  onUpdate: ({ editor: t, transaction: n }) => {
@@ -38067,22 +38147,29 @@ var ZG = Ov.create({
38067
38147
  }
38068
38148
  }, [e.charactersLimit]);
38069
38149
  ft(() => {
38070
- e.editorRef && e.editorRef(p);
38071
- }, [e.editorRef, p]), ft(() => {
38072
- p?.setEditable(!e.disabled);
38073
- }, [e.disabled, p]), ft(() => {
38074
- if (!p) return;
38150
+ e.editorRef && e.editorRef(h);
38151
+ }, [e.editorRef, h]), ft(() => {
38152
+ h?.setEditable(!e.disabled);
38153
+ }, [e.disabled, h]), ft(() => {
38154
+ if (!h) return;
38155
+ let e = h.options?.editorProps, t = hK(m);
38156
+ e?.attributes?.spellcheck !== t.spellcheck && h.setOptions({ editorProps: {
38157
+ ...e,
38158
+ attributes: t
38159
+ } });
38160
+ }, [m, h]), ft(() => {
38161
+ if (!h) return;
38075
38162
  let t = Ra(e.markup);
38076
- t !== p.getHTML() && p.commands.setContent(t, { emitUpdate: !1 });
38077
- }, [e.markup, p]), ft(() => {
38078
- Object.entries(oK).forEach(([e, t]) => {
38163
+ t !== h.getHTML() && h.commands.setContent(t, { emitUpdate: !1 });
38164
+ }, [e.markup, h]), ft(() => {
38165
+ Object.entries(mK).forEach(([e, t]) => {
38079
38166
  document.documentElement.style.setProperty(e, t);
38080
38167
  });
38081
38168
  }, []);
38082
- let m = dD({
38083
- editor: p,
38169
+ let g = dD({
38170
+ editor: h,
38084
38171
  selector: (e) => ({ isFocused: e.editor?.isFocused })
38085
- }), h = mt(() => {
38172
+ }), _ = mt(() => {
38086
38173
  let { minWidth: t, width: n, maxWidth: r, minHeight: i, height: a, maxHeight: o } = e;
38087
38174
  return {
38088
38175
  width: AI(n),
@@ -38097,20 +38184,20 @@ var ZG = Ov.create({
38097
38184
  ...e,
38098
38185
  activePlugins: f,
38099
38186
  toolbarOpts: l,
38100
- editorState: m,
38101
- editor: p,
38102
- children: p && /* @__PURE__ */ k(cK, {
38187
+ editorState: g,
38188
+ editor: h,
38189
+ children: h && /* @__PURE__ */ k(_K, {
38103
38190
  style: {
38104
- minHeight: h.minHeight,
38105
- height: h.height,
38106
- maxHeight: h.maxHeight
38191
+ minHeight: _.minHeight,
38192
+ height: _.height,
38193
+ maxHeight: _.maxHeight
38107
38194
  },
38108
38195
  showParagraph: t && !t.disabled,
38109
38196
  separateParagraph: n && !n.disabled,
38110
- editor: p
38197
+ editor: h
38111
38198
  })
38112
38199
  });
38113
- }, cK = w(cD, { shouldForwardProp: (e) => !["showParagraph", "separateParagraph"].includes(e) })(({ showParagraph: e, separateParagraph: t }) => ({
38200
+ }, _K = w(cD, { shouldForwardProp: (e) => !["showParagraph", "separateParagraph"].includes(e) })(({ showParagraph: e, separateParagraph: t }) => ({
38114
38201
  display: "flex",
38115
38202
  outline: "none !important",
38116
38203
  "& .ProseMirror": {
@@ -38138,7 +38225,7 @@ var ZG = Ov.create({
38138
38225
  } },
38139
38226
  ...t && { "& > p:has(+ p)": { marginBottom: "1em" } }
38140
38227
  }
38141
- })), lK = sK, uK = w(aa)(() => ({})), dK = class extends O.Component {
38228
+ })), vK = gK, yK = w(aa)(() => ({})), bK = class extends O.Component {
38142
38229
  static propTypes = {
38143
38230
  className: z.default.string,
38144
38231
  contentClassName: z.default.string,
@@ -38159,7 +38246,7 @@ var ZG = Ov.create({
38159
38246
  indicatorColor: "primary",
38160
38247
  value: e,
38161
38248
  onChange: this.handleChange,
38162
- children: O.Children.map(t, (e, t) => e && e.props.title ? /* @__PURE__ */ k(uK, { label: e.props.title }, t) : null)
38249
+ children: O.Children.map(t, (e, t) => e && e.props.title ? /* @__PURE__ */ k(yK, { label: e.props.title }, t) : null)
38163
38250
  }), /* @__PURE__ */ k("div", {
38164
38251
  className: r,
38165
38252
  style: i,
@@ -38167,7 +38254,7 @@ var ZG = Ov.create({
38167
38254
  })]
38168
38255
  });
38169
38256
  }
38170
- }, fK = w(ei)(({ theme: e, mini: t }) => ({
38257
+ }, xK = w(ei)(({ theme: e, mini: t }) => ({
38171
38258
  margin: 0,
38172
38259
  marginLeft: 0,
38173
38260
  padding: 0,
@@ -38181,7 +38268,7 @@ var ZG = Ov.create({
38181
38268
  fontSize: e.typography.fontSize - 3
38182
38269
  }
38183
38270
  }
38184
- })), pK = w(qr)(({ theme: e, mini: t, error: n }) => ({
38271
+ })), SK = w(qr)(({ theme: e, mini: t, error: n }) => ({
38185
38272
  color: `${E.tertiary()} !important`,
38186
38273
  ...t && {
38187
38274
  margin: 0,
@@ -38190,9 +38277,9 @@ var ZG = Ov.create({
38190
38277
  height: e.spacing(3)
38191
38278
  },
38192
38279
  ...n && { color: `${e.palette.error.main} !important` }
38193
- })), mK = ({ mini: e, checked: t, onChange: n, value: r, label: i, error: a }) => /* @__PURE__ */ k(fK, {
38280
+ })), CK = ({ mini: e, checked: t, onChange: n, value: r, label: i, error: a }) => /* @__PURE__ */ k(xK, {
38194
38281
  mini: e,
38195
- control: /* @__PURE__ */ k(pK, {
38282
+ control: /* @__PURE__ */ k(SK, {
38196
38283
  checked: t,
38197
38284
  onChange: n,
38198
38285
  value: r,
@@ -38201,32 +38288,32 @@ var ZG = Ov.create({
38201
38288
  }),
38202
38289
  label: i
38203
38290
  });
38204
- mK.propTypes = {
38291
+ CK.propTypes = {
38205
38292
  mini: z.default.bool,
38206
38293
  checked: z.default.bool.isRequired,
38207
38294
  onChange: z.default.func.isRequired,
38208
38295
  value: z.default.string,
38209
38296
  label: z.default.string.isRequired,
38210
38297
  error: z.default.bool
38211
- }, mK.defaultProps = {
38298
+ }, CK.defaultProps = {
38212
38299
  value: "",
38213
38300
  mini: !1,
38214
38301
  error: !1
38215
38302
  };
38216
38303
  //#endregion
38217
38304
  //#region ../../lib-react/config-ui/dist/form-section.js
38218
- var hK = w("div")(({ theme: e }) => ({
38305
+ var wK = w("div")(({ theme: e }) => ({
38219
38306
  marginTop: e.spacing(2),
38220
38307
  marginBottom: e.spacing(2)
38221
- })), gK = w(p)(({ theme: e }) => ({ marginBottom: e.spacing(1) })), _K = ({ className: e, label: t, children: n, labelExtraStyle: r }) => /* @__PURE__ */ A(hK, {
38308
+ })), TK = w(p)(({ theme: e }) => ({ marginBottom: e.spacing(1) })), EK = ({ className: e, label: t, children: n, labelExtraStyle: r }) => /* @__PURE__ */ A(wK, {
38222
38309
  className: e,
38223
- children: [/* @__PURE__ */ k(gK, {
38310
+ children: [/* @__PURE__ */ k(TK, {
38224
38311
  variant: "subtitle1",
38225
38312
  style: r,
38226
38313
  children: t
38227
38314
  }), n]
38228
38315
  });
38229
- _K.propTypes = {
38316
+ EK.propTypes = {
38230
38317
  className: z.default.string,
38231
38318
  label: z.default.string,
38232
38319
  children: z.default.node,
@@ -38234,7 +38321,7 @@ _K.propTypes = {
38234
38321
  };
38235
38322
  //#endregion
38236
38323
  //#region ../../lib-react/config-ui/dist/number-text-field.js
38237
- var vK = (0, Aa.default)("@pie-lib:config-ui:number-text-field"), yK = w(ue)(({ theme: e }) => ({
38324
+ var DK = (0, Aa.default)("@pie-lib:config-ui:number-text-field"), OK = w(ue)(({ theme: e }) => ({
38238
38325
  marginRight: e.spacing(1),
38239
38326
  "& .MuiInputLabel-root": {
38240
38327
  width: "auto",
@@ -38256,11 +38343,11 @@ var vK = (0, Aa.default)("@pie-lib:config-ui:number-text-field"), yK = w(ue)(({
38256
38343
  minHeight: "auto",
38257
38344
  padding: "6px 0 7px"
38258
38345
  }
38259
- })), bK = (e, t) => {
38346
+ })), kK = (e, t) => {
38260
38347
  if (!Ze(e) && !Ze(t)) return 0;
38261
38348
  if (!Ze(e) && Ze(t)) return t;
38262
38349
  if (Ze(e)) return e;
38263
- }, xK = class extends O.Component {
38350
+ }, AK = class extends O.Component {
38264
38351
  static propTypes = {
38265
38352
  disabled: z.default.bool,
38266
38353
  className: z.default.string,
@@ -38286,13 +38373,13 @@ var vK = (0, Aa.default)("@pie-lib:config-ui:number-text-field"), yK = w(ue)(({
38286
38373
  this.setState({ value: t });
38287
38374
  }
38288
38375
  clamp(e, t = this.props.min, n = this.props.max) {
38289
- return Ze(e) ? (Ze(n) && (e = Math.min(e, n)), Ze(t) && (e = Math.max(e, t)), e) : bK(t, n);
38376
+ return Ze(e) ? (Ze(n) && (e = Math.min(e, n)), Ze(t) && (e = Math.max(e, t)), e) : kK(t, n);
38290
38377
  }
38291
38378
  onBlur = (e) => {
38292
38379
  let t = e.target.value, n = parseFloat(t);
38293
- vK("rawNumber: ", n);
38380
+ DK("rawNumber: ", n);
38294
38381
  let r = this.clamp(n);
38295
- vK("number: ", r), r !== this.state.value && (vK("trigger update..."), this.setState({ value: r.toString() }, () => {
38382
+ DK("number: ", r), r !== this.state.value && (DK("trigger update..."), this.setState({ value: r.toString() }, () => {
38296
38383
  this.props.onChange(e, r);
38297
38384
  }));
38298
38385
  };
@@ -38312,7 +38399,7 @@ var vK = (0, Aa.default)("@pie-lib:config-ui:number-text-field"), yK = w(ue)(({
38312
38399
  };
38313
38400
  render() {
38314
38401
  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();
38315
- return /* @__PURE__ */ k(yK, {
38402
+ return /* @__PURE__ */ k(OK, {
38316
38403
  variant: s ? "filled" : l || "standard",
38317
38404
  inputRef: (e) => {
38318
38405
  this.inputRef = e;
@@ -38344,21 +38431,21 @@ var vK = (0, Aa.default)("@pie-lib:config-ui:number-text-field"), yK = w(ue)(({
38344
38431
  margin: "normal"
38345
38432
  });
38346
38433
  }
38347
- }, SK = Object.defineProperty, CK = (e, t) => {
38434
+ }, jK = Object.defineProperty, MK = (e, t) => {
38348
38435
  let n = {};
38349
- for (var r in e) SK(n, r, {
38436
+ for (var r in e) jK(n, r, {
38350
38437
  get: e[r],
38351
38438
  enumerable: !0
38352
38439
  });
38353
- return t || SK(n, Symbol.toStringTag, { value: "Module" }), n;
38354
- }, wK = w("div")(() => ({
38440
+ return t || jK(n, Symbol.toStringTag, { value: "Module" }), n;
38441
+ }, NK = w("div")(() => ({
38355
38442
  display: "flex",
38356
38443
  flexDirection: "column",
38357
38444
  position: "relative"
38358
- })), TK = w("div")(() => ({
38445
+ })), PK = w("div")(() => ({
38359
38446
  display: "flex",
38360
38447
  justifyContent: "space-between"
38361
- })), EK = w("div")(({ theme: e }) => ({ padding: `${e.spacing(2)} 0` })), DK = w("div")(() => ({ flex: "1" })), OK = w("div")(({ theme: e }) => ({ marginLeft: e.spacing(2) })), kK = class extends O.Component {
38448
+ })), FK = w("div")(({ theme: e }) => ({ padding: `${e.spacing(2)} 0` })), IK = w("div")(() => ({ flex: "1" })), LK = w("div")(({ theme: e }) => ({ marginLeft: e.spacing(2) })), RK = class extends O.Component {
38362
38449
  static propTypes = {
38363
38450
  mode: z.default.oneOf(["tabbed", "inline"]),
38364
38451
  secondary: z.default.oneOfType([z.default.arrayOf(z.default.node), z.default.node]),
@@ -38376,7 +38463,7 @@ var vK = (0, Aa.default)("@pie-lib:config-ui:number-text-field"), yK = w(ue)(({
38376
38463
  } catch (e) {
38377
38464
  console.log(e.toString());
38378
38465
  }
38379
- return /* @__PURE__ */ A(wK, {
38466
+ return /* @__PURE__ */ A(NK, {
38380
38467
  style: {
38381
38468
  minHeight: i,
38382
38469
  minWidth: a,
@@ -38384,28 +38471,28 @@ var vK = (0, Aa.default)("@pie-lib:config-ui:number-text-field"), yK = w(ue)(({
38384
38471
  maxWidth: s
38385
38472
  },
38386
38473
  children: [
38387
- e === "inline" && /* @__PURE__ */ A(TK, { children: [/* @__PURE__ */ k(DK, {
38474
+ e === "inline" && /* @__PURE__ */ A(PK, { children: [/* @__PURE__ */ k(IK, {
38388
38475
  className: "design-container",
38389
38476
  children: n
38390
- }), l && /* @__PURE__ */ k(OK, {
38477
+ }), l && /* @__PURE__ */ k(LK, {
38391
38478
  className: "settings-container",
38392
38479
  children: t
38393
38480
  })] }),
38394
- e === "tabbed" && l && /* @__PURE__ */ A(dK, {
38481
+ e === "tabbed" && l && /* @__PURE__ */ A(bK, {
38395
38482
  onChange: this.onTabsChange,
38396
38483
  contentClassName: "content-container",
38397
38484
  indicatorColor: "primary",
38398
- children: [/* @__PURE__ */ k(EK, {
38485
+ children: [/* @__PURE__ */ k(FK, {
38399
38486
  title: "Design",
38400
38487
  className: "design-container",
38401
38488
  children: n
38402
- }), /* @__PURE__ */ k(EK, {
38489
+ }), /* @__PURE__ */ k(FK, {
38403
38490
  title: "Settings",
38404
38491
  className: "settings-container",
38405
38492
  children: t
38406
38493
  })]
38407
38494
  }),
38408
- e === "tabbed" && !l && /* @__PURE__ */ k(EK, {
38495
+ e === "tabbed" && !l && /* @__PURE__ */ k(FK, {
38409
38496
  className: "design-container",
38410
38497
  children: n
38411
38498
  })
@@ -38415,18 +38502,18 @@ var vK = (0, Aa.default)("@pie-lib:config-ui:number-text-field"), yK = w(ue)(({
38415
38502
  };
38416
38503
  //#endregion
38417
38504
  //#region ../../lib-react/config-ui/dist/node_modules/.bun/@babel_runtime@7.29.7/node_modules/@babel/runtime/helpers/esm/extends.js
38418
- function AK() {
38419
- return AK = Object.assign ? Object.assign.bind() : function(e) {
38505
+ function zK() {
38506
+ return zK = Object.assign ? Object.assign.bind() : function(e) {
38420
38507
  for (var t = 1; t < arguments.length; t++) {
38421
38508
  var n = arguments[t];
38422
38509
  for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
38423
38510
  }
38424
38511
  return e;
38425
- }, AK.apply(null, arguments);
38512
+ }, zK.apply(null, arguments);
38426
38513
  }
38427
38514
  //#endregion
38428
38515
  //#region ../../lib-react/config-ui/dist/node_modules/.bun/@babel_runtime@7.29.7/node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js
38429
- function jK(e, t) {
38516
+ function BK(e, t) {
38430
38517
  if (e == null) return {};
38431
38518
  var n = {};
38432
38519
  for (var r in e) if ({}.hasOwnProperty.call(e, r)) {
@@ -38437,19 +38524,19 @@ function jK(e, t) {
38437
38524
  }
38438
38525
  //#endregion
38439
38526
  //#region ../../lib-react/config-ui/dist/node_modules/.bun/@babel_runtime@7.29.7/node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js
38440
- function MK(e, t) {
38441
- return MK = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(e, t) {
38527
+ function VK(e, t) {
38528
+ return VK = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(e, t) {
38442
38529
  return e.__proto__ = t, e;
38443
- }, MK(e, t);
38530
+ }, VK(e, t);
38444
38531
  }
38445
38532
  //#endregion
38446
38533
  //#region ../../lib-react/config-ui/dist/node_modules/.bun/@babel_runtime@7.29.7/node_modules/@babel/runtime/helpers/esm/inheritsLoose.js
38447
- function NK(e, t) {
38448
- e.prototype = Object.create(t.prototype), e.prototype.constructor = e, MK(e, t);
38534
+ function HK(e, t) {
38535
+ e.prototype = Object.create(t.prototype), e.prototype.constructor = e, VK(e, t);
38449
38536
  }
38450
38537
  //#endregion
38451
38538
  //#region ../../lib-react/config-ui/dist/node_modules/.bun/resize-observer-polyfill@1.5.1/node_modules/resize-observer-polyfill/dist/ResizeObserver.es.js
38452
- var PK = (function() {
38539
+ var UK = (function() {
38453
38540
  if (typeof Map < "u") return Map;
38454
38541
  function e(e, t) {
38455
38542
  var n = -1;
@@ -38488,34 +38575,34 @@ var PK = (function() {
38488
38575
  }
38489
38576
  }, t;
38490
38577
  }();
38491
- })(), FK = typeof window < "u" && typeof document < "u" && window.document === document, IK = (function() {
38578
+ })(), WK = typeof window < "u" && typeof document < "u" && window.document === document, GK = (function() {
38492
38579
  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")();
38493
- })(), LK = (function() {
38494
- return typeof requestAnimationFrame == "function" ? requestAnimationFrame.bind(IK) : function(e) {
38580
+ })(), KK = (function() {
38581
+ return typeof requestAnimationFrame == "function" ? requestAnimationFrame.bind(GK) : function(e) {
38495
38582
  return setTimeout(function() {
38496
38583
  return e(Date.now());
38497
38584
  }, 1e3 / 60);
38498
38585
  };
38499
- })(), RK = 2;
38500
- function zK(e, t) {
38586
+ })(), qK = 2;
38587
+ function JK(e, t) {
38501
38588
  var n = !1, r = !1, i = 0;
38502
38589
  function a() {
38503
38590
  n && (n = !1, e()), r && s();
38504
38591
  }
38505
38592
  function o() {
38506
- LK(a);
38593
+ KK(a);
38507
38594
  }
38508
38595
  function s() {
38509
38596
  var e = Date.now();
38510
38597
  if (n) {
38511
- if (e - i < RK) return;
38598
+ if (e - i < qK) return;
38512
38599
  r = !0;
38513
38600
  } else n = !0, r = !1, setTimeout(o, t);
38514
38601
  i = e;
38515
38602
  }
38516
38603
  return s;
38517
38604
  }
38518
- var BK = 20, VK = [
38605
+ var YK = 20, XK = [
38519
38606
  "top",
38520
38607
  "right",
38521
38608
  "bottom",
@@ -38524,9 +38611,9 @@ var BK = 20, VK = [
38524
38611
  "height",
38525
38612
  "size",
38526
38613
  "weight"
38527
- ], HK = typeof MutationObserver < "u", UK = function() {
38614
+ ], ZK = typeof MutationObserver < "u", QK = function() {
38528
38615
  function e() {
38529
- this.connected_ = !1, this.mutationEventsAdded_ = !1, this.mutationsObserver_ = null, this.observers_ = [], this.onTransitionEnd_ = this.onTransitionEnd_.bind(this), this.refresh = zK(this.refresh.bind(this), BK);
38616
+ this.connected_ = !1, this.mutationEventsAdded_ = !1, this.mutationsObserver_ = null, this.observers_ = [], this.onTransitionEnd_ = this.onTransitionEnd_.bind(this), this.refresh = JK(this.refresh.bind(this), YK);
38530
38617
  }
38531
38618
  return e.prototype.addObserver = function(e) {
38532
38619
  ~this.observers_.indexOf(e) || this.observers_.push(e), this.connected_ || this.connect_();
@@ -38543,23 +38630,23 @@ var BK = 20, VK = [
38543
38630
  return e.broadcastActive();
38544
38631
  }), e.length > 0;
38545
38632
  }, e.prototype.connect_ = function() {
38546
- !FK || this.connected_ || (document.addEventListener("transitionend", this.onTransitionEnd_), window.addEventListener("resize", this.refresh), HK ? (this.mutationsObserver_ = new MutationObserver(this.refresh), this.mutationsObserver_.observe(document, {
38633
+ !WK || this.connected_ || (document.addEventListener("transitionend", this.onTransitionEnd_), window.addEventListener("resize", this.refresh), ZK ? (this.mutationsObserver_ = new MutationObserver(this.refresh), this.mutationsObserver_.observe(document, {
38547
38634
  attributes: !0,
38548
38635
  childList: !0,
38549
38636
  characterData: !0,
38550
38637
  subtree: !0
38551
38638
  })) : (document.addEventListener("DOMSubtreeModified", this.refresh), this.mutationEventsAdded_ = !0), this.connected_ = !0);
38552
38639
  }, e.prototype.disconnect_ = function() {
38553
- !FK || !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);
38640
+ !WK || !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);
38554
38641
  }, e.prototype.onTransitionEnd_ = function(e) {
38555
38642
  var t = e.propertyName, n = t === void 0 ? "" : t;
38556
- VK.some(function(e) {
38643
+ XK.some(function(e) {
38557
38644
  return !!~n.indexOf(e);
38558
38645
  }) && this.refresh();
38559
38646
  }, e.getInstance = function() {
38560
38647
  return this.instance_ ||= new e(), this.instance_;
38561
38648
  }, e.instance_ = null, e;
38562
- }(), WK = (function(e, t) {
38649
+ }(), $K = (function(e, t) {
38563
38650
  for (var n = 0, r = Object.keys(t); n < r.length; n++) {
38564
38651
  var i = r[n];
38565
38652
  Object.defineProperty(e, i, {
@@ -38570,19 +38657,19 @@ var BK = 20, VK = [
38570
38657
  });
38571
38658
  }
38572
38659
  return e;
38573
- }), GK = (function(e) {
38574
- return e && e.ownerDocument && e.ownerDocument.defaultView || IK;
38575
- }), KK = nq(0, 0, 0, 0);
38576
- function qK(e) {
38660
+ }), eq = (function(e) {
38661
+ return e && e.ownerDocument && e.ownerDocument.defaultView || GK;
38662
+ }), tq = dq(0, 0, 0, 0);
38663
+ function nq(e) {
38577
38664
  return parseFloat(e) || 0;
38578
38665
  }
38579
- function JK(e) {
38666
+ function rq(e) {
38580
38667
  return [...arguments].slice(1).reduce(function(t, n) {
38581
38668
  var r = e["border-" + n + "-width"];
38582
- return t + qK(r);
38669
+ return t + nq(r);
38583
38670
  }, 0);
38584
38671
  }
38585
- function YK(e) {
38672
+ function iq(e) {
38586
38673
  for (var t = [
38587
38674
  "top",
38588
38675
  "right",
@@ -38590,40 +38677,40 @@ function YK(e) {
38590
38677
  "left"
38591
38678
  ], n = {}, r = 0, i = t; r < i.length; r++) {
38592
38679
  var a = i[r], o = e["padding-" + a];
38593
- n[a] = qK(o);
38680
+ n[a] = nq(o);
38594
38681
  }
38595
38682
  return n;
38596
38683
  }
38597
- function XK(e) {
38684
+ function aq(e) {
38598
38685
  var t = e.getBBox();
38599
- return nq(0, 0, t.width, t.height);
38686
+ return dq(0, 0, t.width, t.height);
38600
38687
  }
38601
- function ZK(e) {
38688
+ function oq(e) {
38602
38689
  var t = e.clientWidth, n = e.clientHeight;
38603
- if (!t && !n) return KK;
38604
- var r = GK(e).getComputedStyle(e), i = YK(r), a = i.left + i.right, o = i.top + i.bottom, s = qK(r.width), c = qK(r.height);
38605
- if (r.boxSizing === "border-box" && (Math.round(s + a) !== t && (s -= JK(r, "left", "right") + a), Math.round(c + o) !== n && (c -= JK(r, "top", "bottom") + o)), !$K(e)) {
38690
+ if (!t && !n) return tq;
38691
+ var r = eq(e).getComputedStyle(e), i = iq(r), a = i.left + i.right, o = i.top + i.bottom, s = nq(r.width), c = nq(r.height);
38692
+ if (r.boxSizing === "border-box" && (Math.round(s + a) !== t && (s -= rq(r, "left", "right") + a), Math.round(c + o) !== n && (c -= rq(r, "top", "bottom") + o)), !cq(e)) {
38606
38693
  var l = Math.round(s + a) - t, u = Math.round(c + o) - n;
38607
38694
  Math.abs(l) !== 1 && (s -= l), Math.abs(u) !== 1 && (c -= u);
38608
38695
  }
38609
- return nq(i.left, i.top, s, c);
38696
+ return dq(i.left, i.top, s, c);
38610
38697
  }
38611
- var QK = (function() {
38698
+ var sq = (function() {
38612
38699
  return typeof SVGGraphicsElement < "u" ? function(e) {
38613
- return e instanceof GK(e).SVGGraphicsElement;
38700
+ return e instanceof eq(e).SVGGraphicsElement;
38614
38701
  } : function(e) {
38615
- return e instanceof GK(e).SVGElement && typeof e.getBBox == "function";
38702
+ return e instanceof eq(e).SVGElement && typeof e.getBBox == "function";
38616
38703
  };
38617
38704
  })();
38618
- function $K(e) {
38619
- return e === GK(e).document.documentElement;
38705
+ function cq(e) {
38706
+ return e === eq(e).document.documentElement;
38620
38707
  }
38621
- function eq(e) {
38622
- return FK ? QK(e) ? XK(e) : ZK(e) : KK;
38708
+ function lq(e) {
38709
+ return WK ? sq(e) ? aq(e) : oq(e) : tq;
38623
38710
  }
38624
- function tq(e) {
38711
+ function uq(e) {
38625
38712
  var t = e.x, n = e.y, r = e.width, i = e.height, a = Object.create((typeof DOMRectReadOnly < "u" ? DOMRectReadOnly : Object).prototype);
38626
- return WK(a, {
38713
+ return $K(a, {
38627
38714
  x: t,
38628
38715
  y: n,
38629
38716
  width: r,
@@ -38634,7 +38721,7 @@ function tq(e) {
38634
38721
  left: t
38635
38722
  }), a;
38636
38723
  }
38637
- function nq(e, t, n, r) {
38724
+ function dq(e, t, n, r) {
38638
38725
  return {
38639
38726
  x: e,
38640
38727
  y: t,
@@ -38642,42 +38729,42 @@ function nq(e, t, n, r) {
38642
38729
  height: r
38643
38730
  };
38644
38731
  }
38645
- var rq = function() {
38732
+ var fq = function() {
38646
38733
  function e(e) {
38647
- this.broadcastWidth = 0, this.broadcastHeight = 0, this.contentRect_ = nq(0, 0, 0, 0), this.target = e;
38734
+ this.broadcastWidth = 0, this.broadcastHeight = 0, this.contentRect_ = dq(0, 0, 0, 0), this.target = e;
38648
38735
  }
38649
38736
  return e.prototype.isActive = function() {
38650
- var e = eq(this.target);
38737
+ var e = lq(this.target);
38651
38738
  return this.contentRect_ = e, e.width !== this.broadcastWidth || e.height !== this.broadcastHeight;
38652
38739
  }, e.prototype.broadcastRect = function() {
38653
38740
  var e = this.contentRect_;
38654
38741
  return this.broadcastWidth = e.width, this.broadcastHeight = e.height, e;
38655
38742
  }, e;
38656
- }(), iq = function() {
38743
+ }(), pq = function() {
38657
38744
  function e(e, t) {
38658
- var n = tq(t);
38659
- WK(this, {
38745
+ var n = uq(t);
38746
+ $K(this, {
38660
38747
  target: e,
38661
38748
  contentRect: n
38662
38749
  });
38663
38750
  }
38664
38751
  return e;
38665
- }(), aq = function() {
38752
+ }(), mq = function() {
38666
38753
  function e(e, t, n) {
38667
- if (this.activeObservations_ = [], this.observations_ = new PK(), typeof e != "function") throw TypeError("The callback provided as parameter 1 is not a function.");
38754
+ if (this.activeObservations_ = [], this.observations_ = new UK(), typeof e != "function") throw TypeError("The callback provided as parameter 1 is not a function.");
38668
38755
  this.callback_ = e, this.controller_ = t, this.callbackCtx_ = n;
38669
38756
  }
38670
38757
  return e.prototype.observe = function(e) {
38671
38758
  if (!arguments.length) throw TypeError("1 argument required, but only 0 present.");
38672
38759
  if (!(typeof Element > "u" || !(Element instanceof Object))) {
38673
- if (!(e instanceof GK(e).Element)) throw TypeError("parameter 1 is not of type \"Element\".");
38760
+ if (!(e instanceof eq(e).Element)) throw TypeError("parameter 1 is not of type \"Element\".");
38674
38761
  var t = this.observations_;
38675
- t.has(e) || (t.set(e, new rq(e)), this.controller_.addObserver(this), this.controller_.refresh());
38762
+ t.has(e) || (t.set(e, new fq(e)), this.controller_.addObserver(this), this.controller_.refresh());
38676
38763
  }
38677
38764
  }, e.prototype.unobserve = function(e) {
38678
38765
  if (!arguments.length) throw TypeError("1 argument required, but only 0 present.");
38679
38766
  if (!(typeof Element > "u" || !(Element instanceof Object))) {
38680
- if (!(e instanceof GK(e).Element)) throw TypeError("parameter 1 is not of type \"Element\".");
38767
+ if (!(e instanceof eq(e).Element)) throw TypeError("parameter 1 is not of type \"Element\".");
38681
38768
  var t = this.observations_;
38682
38769
  t.has(e) && (t.delete(e), t.size || this.controller_.removeObserver(this));
38683
38770
  }
@@ -38691,7 +38778,7 @@ var rq = function() {
38691
38778
  }, e.prototype.broadcastActive = function() {
38692
38779
  if (this.hasActive()) {
38693
38780
  var e = this.callbackCtx_, t = this.activeObservations_.map(function(e) {
38694
- return new iq(e.target, e.broadcastRect());
38781
+ return new pq(e.target, e.broadcastRect());
38695
38782
  });
38696
38783
  this.callback_.call(e, t, e), this.clearActive();
38697
38784
  }
@@ -38700,12 +38787,12 @@ var rq = function() {
38700
38787
  }, e.prototype.hasActive = function() {
38701
38788
  return this.activeObservations_.length > 0;
38702
38789
  }, e;
38703
- }(), oq = typeof WeakMap < "u" ? /* @__PURE__ */ new WeakMap() : new PK(), sq = function() {
38790
+ }(), hq = typeof WeakMap < "u" ? /* @__PURE__ */ new WeakMap() : new UK(), gq = function() {
38704
38791
  function e(t) {
38705
38792
  if (!(this instanceof e)) throw TypeError("Cannot call a class as a function.");
38706
38793
  if (!arguments.length) throw TypeError("1 argument required, but only 0 present.");
38707
- var n = new aq(t, UK.getInstance(), this);
38708
- oq.set(this, n);
38794
+ var n = new mq(t, QK.getInstance(), this);
38795
+ hq.set(this, n);
38709
38796
  }
38710
38797
  return e;
38711
38798
  }();
@@ -38714,27 +38801,27 @@ var rq = function() {
38714
38801
  "unobserve",
38715
38802
  "disconnect"
38716
38803
  ].forEach(function(e) {
38717
- sq.prototype[e] = function() {
38804
+ gq.prototype[e] = function() {
38718
38805
  var t;
38719
- return (t = oq.get(this))[e].apply(t, arguments);
38806
+ return (t = hq.get(this))[e].apply(t, arguments);
38720
38807
  };
38721
38808
  });
38722
- var cq = (function() {
38723
- return IK.ResizeObserver === void 0 ? sq : IK.ResizeObserver;
38724
- })(), lq = [
38809
+ var _q = (function() {
38810
+ return GK.ResizeObserver === void 0 ? gq : GK.ResizeObserver;
38811
+ })(), vq = [
38725
38812
  "client",
38726
38813
  "offset",
38727
38814
  "scroll",
38728
38815
  "bounds",
38729
38816
  "margin"
38730
38817
  ];
38731
- function uq(e) {
38818
+ function yq(e) {
38732
38819
  var t = [];
38733
- return lq.forEach(function(n) {
38820
+ return vq.forEach(function(n) {
38734
38821
  e[n] && t.push(n);
38735
38822
  }), t;
38736
38823
  }
38737
- function dq(e, t) {
38824
+ function bq(e, t) {
38738
38825
  var n = {};
38739
38826
  if (t.indexOf("client") > -1 && (n.client = {
38740
38827
  top: e.clientTop,
@@ -38773,14 +38860,14 @@ function dq(e, t) {
38773
38860
  }
38774
38861
  return n;
38775
38862
  }
38776
- function fq(e) {
38863
+ function xq(e) {
38777
38864
  return e && e.ownerDocument && e.ownerDocument.defaultView || window;
38778
38865
  }
38779
- function pq(e) {
38866
+ function Sq(e) {
38780
38867
  return function(t) {
38781
38868
  var n, r;
38782
38869
  return r = n = /*#__PURE__*/ function(n) {
38783
- NK(r, n);
38870
+ HK(r, n);
38784
38871
  function r() {
38785
38872
  var t, r = [...arguments];
38786
38873
  return t = n.call.apply(n, [this].concat(r)) || this, t.state = { contentRect: {
@@ -38791,24 +38878,24 @@ function pq(e) {
38791
38878
  bounds: {},
38792
38879
  margin: {}
38793
38880
  } }, t._animationFrameID = null, t._resizeObserver = null, t._node = null, t._window = null, t.measure = function(n) {
38794
- var r = dq(t._node, e || uq(t.props));
38881
+ var r = bq(t._node, e || yq(t.props));
38795
38882
  n && (r.entry = n[0].contentRect), t._animationFrameID = t._window.requestAnimationFrame(function() {
38796
38883
  t._resizeObserver !== null && (t.setState({ contentRect: r }), typeof t.props.onResize == "function" && t.props.onResize(r));
38797
38884
  });
38798
38885
  }, t._handleRef = function(e) {
38799
- t._resizeObserver !== null && t._node !== null && t._resizeObserver.unobserve(t._node), t._node = e, t._window = fq(t._node);
38886
+ t._resizeObserver !== null && t._node !== null && t._resizeObserver.unobserve(t._node), t._node = e, t._window = xq(t._node);
38800
38887
  var n = t.props.innerRef;
38801
38888
  n && (typeof n == "function" ? n(t._node) : n.current = t._node), t._resizeObserver !== null && t._node !== null && t._resizeObserver.observe(t._node);
38802
38889
  }, t;
38803
38890
  }
38804
38891
  var i = r.prototype;
38805
38892
  return i.componentDidMount = function() {
38806
- this._resizeObserver = this._window !== null && this._window.ResizeObserver ? new this._window.ResizeObserver(this.measure) : new cq(this.measure), this._node !== null && (this._resizeObserver.observe(this._node), typeof this.props.onResize == "function" && this.props.onResize(dq(this._node, e || uq(this.props))));
38893
+ this._resizeObserver = this._window !== null && this._window.ResizeObserver ? new this._window.ResizeObserver(this.measure) : new _q(this.measure), this._node !== null && (this._resizeObserver.observe(this._node), typeof this.props.onResize == "function" && this.props.onResize(bq(this._node, e || yq(this.props))));
38807
38894
  }, i.componentWillUnmount = function() {
38808
38895
  this._window !== null && this._window.cancelAnimationFrame(this._animationFrameID), this._resizeObserver !== null && (this._resizeObserver.disconnect(), this._resizeObserver = null);
38809
38896
  }, i.render = function() {
38810
38897
  var e = this.props;
38811
- return e.innerRef, e.onResize, at(t, AK({}, jK(e, ["innerRef", "onResize"]), {
38898
+ return e.innerRef, e.onResize, at(t, zK({}, BK(e, ["innerRef", "onResize"]), {
38812
38899
  measureRef: this._handleRef,
38813
38900
  measure: this.measure,
38814
38901
  contentRect: this.state.contentRect
@@ -38825,7 +38912,7 @@ function pq(e) {
38825
38912
  }, r;
38826
38913
  };
38827
38914
  }
38828
- var mq = pq()(function(e) {
38915
+ var Cq = Sq()(function(e) {
38829
38916
  var t = e.measure, n = e.measureRef, r = e.contentRect, i = e.children;
38830
38917
  return i({
38831
38918
  measure: t,
@@ -38833,10 +38920,10 @@ var mq = pq()(function(e) {
38833
38920
  contentRect: r
38834
38921
  });
38835
38922
  });
38836
- mq.displayName = "Measure", mq.propTypes.children = z.default.func;
38923
+ Cq.displayName = "Measure", Cq.propTypes.children = z.default.func;
38837
38924
  //#endregion
38838
38925
  //#region ../../lib-react/config-ui/dist/layout/settings-box.js
38839
- var hq = w("div")(() => ({
38926
+ var wq = w("div")(() => ({
38840
38927
  backgroundColor: E.white(),
38841
38928
  border: `2px solid ${E.border()}`,
38842
38929
  display: "flex",
@@ -38846,7 +38933,7 @@ var hq = w("div")(() => ({
38846
38933
  maxWidth: "300px",
38847
38934
  padding: "20px 4px 4px 20px",
38848
38935
  zIndex: 99
38849
- })), gq = class extends O.Component {
38936
+ })), Tq = class extends O.Component {
38850
38937
  static propTypes = {
38851
38938
  className: z.default.string,
38852
38939
  children: z.default.oneOfType([z.default.arrayOf(z.default.node), z.default.node]).isRequired
@@ -38854,19 +38941,19 @@ var hq = w("div")(() => ({
38854
38941
  static defaultProps = {};
38855
38942
  render() {
38856
38943
  let { className: e, children: t } = this.props;
38857
- return /* @__PURE__ */ k(hq, {
38944
+ return /* @__PURE__ */ k(wq, {
38858
38945
  className: e,
38859
38946
  children: t
38860
38947
  });
38861
38948
  }
38862
- }, _q = le({
38949
+ }, Eq = le({
38863
38950
  typography: { fontFamily: "inherit" },
38864
38951
  components: { MuiButton: { styleOverrides: { contained: {
38865
38952
  backgroundColor: "#e0e0e0",
38866
38953
  color: "#000000",
38867
38954
  "&:hover": { backgroundColor: "#bdbdbd" }
38868
38955
  } } } }
38869
- }), vq = class extends O.Component {
38956
+ }), Dq = class extends O.Component {
38870
38957
  static propTypes = {
38871
38958
  children: z.default.oneOfType([
38872
38959
  z.default.string,
@@ -38899,19 +38986,19 @@ var hq = w("div")(() => ({
38899
38986
  return /* @__PURE__ */ k(he, {
38900
38987
  injectFirst: !0,
38901
38988
  children: /* @__PURE__ */ k(ye, {
38902
- theme: _q,
38903
- children: /* @__PURE__ */ k(mq, {
38989
+ theme: Eq,
38990
+ children: /* @__PURE__ */ k(Cq, {
38904
38991
  bounds: !0,
38905
38992
  onResize: this.onResize,
38906
38993
  children: ({ measureRef: e }) => {
38907
- let { children: t, settings: n, hideSettings: r, dimensions: i, extraCSSRules: a } = this.props, { layoutMode: o } = this.state, s = r ? null : o === "inline" ? /* @__PURE__ */ k(gq, {
38994
+ let { children: t, settings: n, hideSettings: r, dimensions: i, extraCSSRules: a } = this.props, { layoutMode: o } = this.state, s = r ? null : o === "inline" ? /* @__PURE__ */ k(Tq, {
38908
38995
  className: "settings-box",
38909
38996
  children: n
38910
38997
  }) : n;
38911
38998
  return /* @__PURE__ */ A("div", {
38912
38999
  ref: e,
38913
39000
  className: "main-container extraCSSRules",
38914
- children: [a?.rules ? /* @__PURE__ */ k("style", { dangerouslySetInnerHTML: { __html: `.extraCSSRules { ${a.rules} }` } }) : null, /* @__PURE__ */ k(kK, {
39001
+ children: [a?.rules ? /* @__PURE__ */ k("style", { dangerouslySetInnerHTML: { __html: `.extraCSSRules { ${a.rules} }` } }) : null, /* @__PURE__ */ k(RK, {
38915
39002
  mode: o,
38916
39003
  secondary: s,
38917
39004
  dimensions: i,
@@ -38923,41 +39010,41 @@ var hq = w("div")(() => ({
38923
39010
  })
38924
39011
  });
38925
39012
  }
38926
- }, yq = pq("bounds")(vq), bq = /* @__PURE__ */ CK({
38927
- ConfigLayout: () => yq,
38928
- LayoutContents: () => kK
38929
- }), xq = T(/*#__PURE__*/ k("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"), Sq = T(/*#__PURE__*/ k("path", { d: "M11 18h2v-2h-2zm1-16C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2m0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8m0-14c-2.21 0-4 1.79-4 4h2c0-1.1.9-2 2-2s2 .9 2 2c0 2-3 1.75-3 5h2c0-2.25 3-2.5 3-5 0-2.21-1.79-4-4-4" }), "HelpOutline"), Cq = w("div")({
39013
+ }, Oq = Sq("bounds")(Dq), kq = /* @__PURE__ */ MK({
39014
+ ConfigLayout: () => Oq,
39015
+ LayoutContents: () => RK
39016
+ }), Aq = T(/*#__PURE__*/ k("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"), jq = T(/*#__PURE__*/ k("path", { d: "M11 18h2v-2h-2zm1-16C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2m0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8m0-14c-2.21 0-4 1.79-4 4h2c0-1.1.9-2 2-2s2 .9 2 2c0 2-3 1.75-3 5h2c0-2.25 3-2.5 3-5 0-2.21-1.79-4-4-4" }), "HelpOutline"), Mq = w("div")({
38930
39017
  display: "flex",
38931
39018
  justifyContent: "space-between"
38932
- }), wq = w("div")({
39019
+ }), Nq = w("div")({
38933
39020
  display: "flex",
38934
39021
  alignItems: "center"
38935
- }), Tq = w(Dt)({
39022
+ }), Pq = w(Dt)({
38936
39023
  margin: 0,
38937
39024
  padding: 0
38938
- }), Eq = w(ea)(({ theme: e }) => ({ "& .MuiTooltip-tooltip": { fontSize: e.typography.fontSize - 2 } })), Dq = (e) => {
39025
+ }), Fq = w(ea)(({ theme: e }) => ({ "& .MuiTooltip-tooltip": { fontSize: e.typography.fontSize - 2 } })), Iq = (e) => {
38939
39026
  let { header: t, children: n, mini: r, info: i } = e;
38940
- return /* @__PURE__ */ A(Cq, { children: [/* @__PURE__ */ A(wq, { children: [/* @__PURE__ */ k(p, {
39027
+ return /* @__PURE__ */ A(Mq, { children: [/* @__PURE__ */ A(Nq, { children: [/* @__PURE__ */ k(p, {
38941
39028
  variant: r ? "h6" : "h5",
38942
39029
  children: t
38943
- }), i] }), n && /* @__PURE__ */ k(Eq, {
39030
+ }), i] }), n && /* @__PURE__ */ k(Fq, {
38944
39031
  title: n,
38945
- children: /* @__PURE__ */ k(Tq, {
39032
+ children: /* @__PURE__ */ k(Pq, {
38946
39033
  "aria-label": "Delete",
38947
39034
  size: "large",
38948
- children: /* @__PURE__ */ k(Sq, {})
39035
+ children: /* @__PURE__ */ k(jq, {})
38949
39036
  })
38950
39037
  })] });
38951
39038
  };
38952
- Dq.propTypes = {
39039
+ Iq.propTypes = {
38953
39040
  mini: z.default.bool,
38954
39041
  header: z.default.string,
38955
39042
  children: z.default.node,
38956
39043
  info: z.default.any
38957
- }, w(xK)(({ theme: e }) => ({ marginLeft: e.spacing(1) }));
39044
+ }, w(AK)(({ theme: e }) => ({ marginLeft: e.spacing(1) }));
38958
39045
  //#endregion
38959
39046
  //#region src/author/number-text-field.tsx
38960
- var Oq = w(xK)({
39047
+ var Lq = w(AK)({
38961
39048
  maxWidth: "120px",
38962
39049
  width: "120px",
38963
39050
  marginTop: "0",
@@ -38968,25 +39055,25 @@ var Oq = w(xK)({
38968
39055
  "& [class^=\"MuiInputBase-input\"]": { padding: "18.5px 14px" }
38969
39056
  });
38970
39057
  O.Component;
38971
- var kq = O.forwardRef((e, t) => /* @__PURE__ */ k(Oq, {
39058
+ var Rq = O.forwardRef((e, t) => /* @__PURE__ */ k(Lq, {
38972
39059
  ...e,
38973
39060
  ref: t,
38974
39061
  variant: "outlined"
38975
- })), Aq = w("div")({
39062
+ })), zq = w("div")({
38976
39063
  alignItems: "center",
38977
39064
  display: "flex",
38978
39065
  gap: "20px"
38979
- }), jq = w("div")({ margin: "12px 0" }), Mq = w("label")({
39066
+ }), Bq = w("div")({ margin: "12px 0" }), Vq = w("label")({
38980
39067
  display: "block",
38981
39068
  marginBottom: "4px"
38982
- }), Nq = w(fe)({
39069
+ }), Hq = w(fe)({
38983
39070
  width: "80px",
38984
39071
  alignItems: "center",
38985
39072
  height: "40px",
38986
39073
  verticalAlign: "top",
38987
39074
  marginBottom: "8px",
38988
39075
  "& .MuiSelect-select": { paddingLeft: "10px" }
38989
- }), Pq = w("div")({ marginLeft: "-15px" }), Fq = w("span")({ verticalAlign: "middle" }), Iq = class extends O.Component {
39076
+ }), Uq = w("div")({ marginLeft: "-15px" }), Wq = w("span")({ verticalAlign: "middle" }), Gq = class extends O.Component {
38990
39077
  static propTypes = {
38991
39078
  model: z.default.object.isRequired,
38992
39079
  onChange: z.default.func,
@@ -39006,10 +39093,10 @@ var kq = O.forwardRef((e, t) => /* @__PURE__ */ k(Oq, {
39006
39093
  render() {
39007
39094
  let { model: e, modelOptions: t } = this.props, { maxOfModel: n, partsPerModel: r, modelTypeChoices: i } = t;
39008
39095
  return /* @__PURE__ */ A("div", { children: [
39009
- /* @__PURE__ */ k(Dq, { header: "Configure Fraction Model" }),
39096
+ /* @__PURE__ */ k(Iq, { header: "Configure Fraction Model" }),
39010
39097
  /* @__PURE__ */ k("br", {}),
39011
- /* @__PURE__ */ A(Aq, { children: [
39012
- /* @__PURE__ */ A(jq, { children: [/* @__PURE__ */ k(Mq, { children: "Model Type" }), /* @__PURE__ */ k(Nq, {
39098
+ /* @__PURE__ */ A(zq, { children: [
39099
+ /* @__PURE__ */ A(Bq, { children: [/* @__PURE__ */ k(Vq, { children: "Model Type" }), /* @__PURE__ */ k(Hq, {
39013
39100
  onChange: this.handleSelect,
39014
39101
  value: e.modelTypeSelected,
39015
39102
  MenuProps: { transitionDuration: {
@@ -39021,14 +39108,14 @@ var kq = O.forwardRef((e, t) => /* @__PURE__ */ k(Oq, {
39021
39108
  children: e.label
39022
39109
  }, "item_" + t))
39023
39110
  })] }),
39024
- /* @__PURE__ */ A(jq, { children: [/* @__PURE__ */ k(Mq, { children: "Max # of Models" }), /* @__PURE__ */ k(kq, {
39111
+ /* @__PURE__ */ A(Bq, { children: [/* @__PURE__ */ k(Vq, { children: "Max # of Models" }), /* @__PURE__ */ k(Rq, {
39025
39112
  min: n.min,
39026
39113
  max: n.max,
39027
39114
  value: e.maxModelSelected,
39028
39115
  name: "max-model",
39029
39116
  onChange: this.changeMaxModel
39030
39117
  })] }),
39031
- /* @__PURE__ */ A(jq, { children: [/* @__PURE__ */ k(Mq, { children: "Parts per Model" }), /* @__PURE__ */ k(kq, {
39118
+ /* @__PURE__ */ A(Bq, { children: [/* @__PURE__ */ k(Vq, { children: "Parts per Model" }), /* @__PURE__ */ k(Rq, {
39032
39119
  min: r.min,
39033
39120
  max: r.max,
39034
39121
  value: e.partsPerModel,
@@ -39036,22 +39123,22 @@ var kq = O.forwardRef((e, t) => /* @__PURE__ */ k(Oq, {
39036
39123
  onChange: this.changePartModel
39037
39124
  })] })
39038
39125
  ] }),
39039
- /* @__PURE__ */ A(Pq, { children: [/* @__PURE__ */ k(mK, {
39126
+ /* @__PURE__ */ A(Uq, { children: [/* @__PURE__ */ k(CK, {
39040
39127
  onChange: this.studentConfig,
39041
39128
  checked: e.allowedStudentConfig,
39042
39129
  label: ""
39043
- }), /* @__PURE__ */ k(Fq, { children: "Allow student to configure number of models and parts per model" })] })
39130
+ }), /* @__PURE__ */ k(Wq, { children: "Allow student to configure number of models and parts per model" })] })
39044
39131
  ] });
39045
39132
  }
39046
- }, Lq = w(_K)(({ theme: e }) => ({ marginBottom: e.spacing(4) })), Rq = w(ea)(({ theme: e }) => ({ "& .MuiTooltip-tooltip": {
39133
+ }, Kq = w(EK)(({ theme: e }) => ({ marginBottom: e.spacing(4) })), qq = w(ea)(({ theme: e }) => ({ "& .MuiTooltip-tooltip": {
39047
39134
  fontSize: e.typography.fontSize - 2,
39048
39135
  whiteSpace: "pre",
39049
39136
  maxWidth: "500px"
39050
- } })), zq = w("div")(({ theme: e }) => ({
39137
+ } })), Jq = w("div")(({ theme: e }) => ({
39051
39138
  fontSize: e.typography.fontSize - 2,
39052
39139
  color: e.palette.error.main,
39053
39140
  marginTop: e.spacing(1)
39054
- })), Bq = w("div")(({ theme: e, hasError: t }) => ({ ...t && { border: `2px solid ${e.palette.error.main}` } })), Vq = w("label")(({ theme: e }) => ({ marginBottom: e.spacing(4) })), Hq = class extends O.Component {
39141
+ })), Yq = w("div")(({ theme: e, hasError: t }) => ({ ...t && { border: `2px solid ${e.palette.error.main}` } })), Xq = w("label")(({ theme: e }) => ({ marginBottom: e.spacing(4) })), Zq = class extends O.Component {
39055
39142
  static propTypes = {
39056
39143
  model: z.default.object.isRequired,
39057
39144
  configuration: z.default.object.isRequired,
@@ -39084,15 +39171,15 @@ var kq = O.forwardRef((e, t) => /* @__PURE__ */ k(Oq, {
39084
39171
  ...a,
39085
39172
  ...e
39086
39173
  }), v = this.generateRandomKey();
39087
- return /* @__PURE__ */ A(bq.ConfigLayout, {
39174
+ return /* @__PURE__ */ A(kq.ConfigLayout, {
39088
39175
  extraCSSRules: f,
39089
39176
  dimensions: o,
39090
39177
  hideSettings: !0,
39091
39178
  children: [
39092
- /* @__PURE__ */ k(Dq, { header: "Set Up" }),
39093
- /* @__PURE__ */ k(Lq, {
39179
+ /* @__PURE__ */ k(Iq, { header: "Set Up" }),
39180
+ /* @__PURE__ */ k(Kq, {
39094
39181
  label: s?.label || "Title",
39095
- children: /* @__PURE__ */ k(lK, {
39182
+ children: /* @__PURE__ */ k(vK, {
39096
39183
  markup: e.title || "",
39097
39184
  onChange: (e) => t({ title: e }),
39098
39185
  toolbarOpts: g,
@@ -39114,9 +39201,9 @@ var kq = O.forwardRef((e, t) => /* @__PURE__ */ k(Oq, {
39114
39201
  mathMlOptions: u
39115
39202
  })
39116
39203
  }),
39117
- /* @__PURE__ */ k(Lq, {
39204
+ /* @__PURE__ */ k(Kq, {
39118
39205
  label: c?.label || "Question",
39119
- children: /* @__PURE__ */ k(lK, {
39206
+ children: /* @__PURE__ */ k(vK, {
39120
39207
  markup: e.prompt || "",
39121
39208
  minHeight: 60,
39122
39209
  onChange: (e) => t({ prompt: e }),
@@ -39129,21 +39216,21 @@ var kq = O.forwardRef((e, t) => /* @__PURE__ */ k(Oq, {
39129
39216
  mathMlOptions: u
39130
39217
  })
39131
39218
  }),
39132
- /* @__PURE__ */ k(_K, { children: /* @__PURE__ */ k(Iq, {
39219
+ /* @__PURE__ */ k(EK, { children: /* @__PURE__ */ k(Gq, {
39133
39220
  model: e,
39134
39221
  onChange: this.onModelOptionsChange,
39135
39222
  modelOptions: l
39136
39223
  }) }),
39137
- /* @__PURE__ */ A(_K, { children: [
39224
+ /* @__PURE__ */ A(EK, { children: [
39138
39225
  " ",
39139
- /* @__PURE__ */ k(Dq, {
39226
+ /* @__PURE__ */ k(Iq, {
39140
39227
  header: "Correct Answer",
39141
- info: /* @__PURE__ */ k(Rq, {
39228
+ info: /* @__PURE__ */ k(qq, {
39142
39229
  disableFocusListener: !0,
39143
39230
  disableTouchListener: !0,
39144
39231
  placement: "right",
39145
39232
  title: "The correct answer should include no more than one partially-filled model",
39146
- children: /* @__PURE__ */ k(xq, {
39233
+ children: /* @__PURE__ */ k(Aq, {
39147
39234
  fontSize: "small",
39148
39235
  color: "primary",
39149
39236
  style: { marginLeft: "8px" }
@@ -39151,9 +39238,9 @@ var kq = O.forwardRef((e, t) => /* @__PURE__ */ k(Oq, {
39151
39238
  })
39152
39239
  }),
39153
39240
  /* @__PURE__ */ k("br", {}),
39154
- /* @__PURE__ */ k(Vq, { children: "Click/touch the number of parts to represent the correct fraction model" }),
39241
+ /* @__PURE__ */ k(Xq, { children: "Click/touch the number of parts to represent the correct fraction model" }),
39155
39242
  /* @__PURE__ */ k("br", {}),
39156
- /* @__PURE__ */ k(Bq, {
39243
+ /* @__PURE__ */ k(Yq, {
39157
39244
  hasError: !!d.correctResponse,
39158
39245
  children: /* @__PURE__ */ k(Ne, {
39159
39246
  value: e.correctResponse,
@@ -39164,7 +39251,7 @@ var kq = O.forwardRef((e, t) => /* @__PURE__ */ k(Oq, {
39164
39251
  onChange: this.onCorrectAnswerChange
39165
39252
  }, v)
39166
39253
  }),
39167
- d.correctResponse && /* @__PURE__ */ k(zq, { children: d.correctResponse })
39254
+ d.correctResponse && /* @__PURE__ */ k(Jq, { children: d.correctResponse })
39168
39255
  ] }),
39169
39256
  /* @__PURE__ */ k(Ee, {
39170
39257
  open: h.open,
@@ -39184,7 +39271,7 @@ var kq = O.forwardRef((e, t) => /* @__PURE__ */ k(Oq, {
39184
39271
  ]
39185
39272
  });
39186
39273
  }
39187
- }, Uq = class e extends CustomEvent {
39274
+ }, Qq = class e extends CustomEvent {
39188
39275
  static {
39189
39276
  this.TYPE = "model.updated";
39190
39277
  }
@@ -39197,7 +39284,7 @@ var kq = O.forwardRef((e, t) => /* @__PURE__ */ k(Oq, {
39197
39284
  }
39198
39285
  }), this.update = t, this.reset = n;
39199
39286
  }
39200
- }, Wq = class e extends CustomEvent {
39287
+ }, $q = class e extends CustomEvent {
39201
39288
  static {
39202
39289
  this.TYPE = "delete.image";
39203
39290
  }
@@ -39210,7 +39297,7 @@ var kq = O.forwardRef((e, t) => /* @__PURE__ */ k(Oq, {
39210
39297
  }
39211
39298
  }), this.src = t, this.done = n;
39212
39299
  }
39213
- }, Gq = class e extends CustomEvent {
39300
+ }, eJ = class e extends CustomEvent {
39214
39301
  static {
39215
39302
  this.TYPE = "insert.image";
39216
39303
  }
@@ -39220,7 +39307,7 @@ var kq = O.forwardRef((e, t) => /* @__PURE__ */ k(Oq, {
39220
39307
  detail: t
39221
39308
  }), this.handler = t;
39222
39309
  }
39223
- }, Kq = class e extends CustomEvent {
39310
+ }, tJ = class e extends CustomEvent {
39224
39311
  static {
39225
39312
  this.TYPE = "delete.sound";
39226
39313
  }
@@ -39233,7 +39320,7 @@ var kq = O.forwardRef((e, t) => /* @__PURE__ */ k(Oq, {
39233
39320
  }
39234
39321
  }), this.src = t, this.done = n;
39235
39322
  }
39236
- }, qq = class e extends CustomEvent {
39323
+ }, nJ = class e extends CustomEvent {
39237
39324
  static {
39238
39325
  this.TYPE = "insert.sound";
39239
39326
  }
@@ -39243,7 +39330,7 @@ var kq = O.forwardRef((e, t) => /* @__PURE__ */ k(Oq, {
39243
39330
  detail: t
39244
39331
  }), this.handler = t;
39245
39332
  }
39246
- }, Jq = {
39333
+ }, rJ = {
39247
39334
  model: {
39248
39335
  correctResponse: [],
39249
39336
  title: "",
@@ -39323,24 +39410,24 @@ var kq = O.forwardRef((e, t) => /* @__PURE__ */ k(Oq, {
39323
39410
  },
39324
39411
  settingsPanelDisabled: !0
39325
39412
  }
39326
- }, Yq = class e extends HTMLElement {
39413
+ }, iJ = class e extends HTMLElement {
39327
39414
  static createDefaultModel = (e = {}) => {
39328
- let t = Jq.configuration, n = e.language || "";
39415
+ let t = rJ.configuration, n = e.language || "";
39329
39416
  return !n && t.language && t.language.enabled && t.languageChoices?.options?.length && (n = t.languageChoices.options[0].value), {
39330
- ...Jq.model,
39417
+ ...rJ.model,
39331
39418
  ...e,
39332
39419
  language: n
39333
39420
  };
39334
39421
  };
39335
39422
  constructor() {
39336
- super(), this._root = null, this._model = e.createDefaultModel(), this._configuration = Jq.configuration;
39423
+ super(), this._root = null, this._model = e.createDefaultModel(), this._configuration = rJ.configuration;
39337
39424
  }
39338
39425
  set model(t) {
39339
39426
  this._model = e.createDefaultModel(t), this.render();
39340
39427
  }
39341
39428
  set configuration(e) {
39342
39429
  let t = {
39343
- ...Jq.configuration,
39430
+ ...rJ.configuration,
39344
39431
  ...e
39345
39432
  };
39346
39433
  this._configuration = t, this.resetModelAfterConfigurationIsSet(), 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({
@@ -39356,32 +39443,32 @@ var kq = O.forwardRef((e, t) => /* @__PURE__ */ k(Oq, {
39356
39443
  this.render();
39357
39444
  }
39358
39445
  modelChanged(e) {
39359
- this._model = e, this.dispatchEvent(new Uq(this._model), !0), this.render();
39446
+ this._model = e, this.dispatchEvent(new Qq(this._model), !0), this.render();
39360
39447
  }
39361
39448
  onChange = (e) => {
39362
39449
  this._model = {
39363
39450
  ...this._model,
39364
39451
  ...e
39365
- }, this.dispatchEvent(new Uq(this._model)), this.render();
39452
+ }, this.dispatchEvent(new Qq(this._model)), this.render();
39366
39453
  };
39367
39454
  onConfigurationChanged(e) {
39368
39455
  this._configuration = e, this.render();
39369
39456
  }
39370
39457
  insertImage(e) {
39371
- this.dispatchEvent(new Gq(e));
39458
+ this.dispatchEvent(new eJ(e));
39372
39459
  }
39373
39460
  onDeleteImage(e, t) {
39374
- this.dispatchEvent(new Wq(e, t));
39461
+ this.dispatchEvent(new $q(e, t));
39375
39462
  }
39376
39463
  insertSound(e) {
39377
- this.dispatchEvent(new qq(e));
39464
+ this.dispatchEvent(new nJ(e));
39378
39465
  }
39379
39466
  onDeleteSound(e, t) {
39380
- this.dispatchEvent(new Kq(e, t));
39467
+ this.dispatchEvent(new tJ(e, t));
39381
39468
  }
39382
39469
  render() {
39383
39470
  if (this._model) {
39384
- let e = O.createElement(Hq, {
39471
+ let e = O.createElement(Zq, {
39385
39472
  classes: {},
39386
39473
  model: this._model,
39387
39474
  configuration: this._configuration,
@@ -39404,6 +39491,6 @@ var kq = O.forwardRef((e, t) => /* @__PURE__ */ k(Oq, {
39404
39491
  }
39405
39492
  };
39406
39493
  //#endregion
39407
- export { Yq as default };
39494
+ export { iJ as default };
39408
39495
 
39409
39496
  //# sourceMappingURL=index.js.map