@yungu-fed/question-editor 0.1.6 → 0.1.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs CHANGED
@@ -800,8 +800,8 @@ var Qt = ["true", "false"], $t = {
800
800
  createDataElement: (e) => bn(e),
801
801
  createTypeElement: (e, t) => ({
802
802
  config: {
803
- candidateMode: "none",
804
- selectionType: "single"
803
+ allowCandidateReuse: !1,
804
+ candidateMode: "none"
805
805
  },
806
806
  id: e,
807
807
  name: "\u9898\u5e72\u5185\u586b\u7a7a",
@@ -830,7 +830,7 @@ var Qt = ["true", "false"], $t = {
830
830
  judgement: {
831
831
  createDataElement: (e) => Hn(e),
832
832
  createTypeElement: (e, t) => ({
833
- config: { judgementMode: "correctWrong" },
833
+ config: { judgeAnswerMode: "correctWrong" },
834
834
  id: e,
835
835
  name: "\u5224\u65ad",
836
836
  type: "judgement",
@@ -1076,7 +1076,7 @@ function xn(e, t) {
1076
1076
  if ((t == null ? void 0 : t.type) !== "inlineFill") return bn(e);
1077
1077
  let n = wn(t.blanks, "inline-blank"), r = jn(e.config.candidateMode);
1078
1078
  return {
1079
- answers: Mn(t.answers, n, r, e.config.selectionType),
1079
+ answers: Mn(t.answers, n, r, e.config.allowCandidateReuse),
1080
1080
  blanks: n,
1081
1081
  content: b(t.content, n),
1082
1082
  elementId: e.id,
@@ -1166,8 +1166,8 @@ function Nn(e, t, n, r) {
1166
1166
  var i;
1167
1167
  let a = e.filter((e) => e.blankIds.some((e) => t.includes(e))), o = n === "none" ? [] : In((i = a.find((e) => e.options.length > 0)) == null ? void 0 : i.options), s = new Set(o.map((e) => e.id));
1168
1168
  return {
1169
- allowReuse: a.some((e) => e.allowReuse),
1170
- answers: Ln(t, (e) => Rn(Pn(a, e), n, s, r)),
1169
+ allowReuse: n === "sharedPool" && r,
1170
+ answers: Ln(t, (e) => Rn(Pn(a, e), n, s)),
1171
1171
  blankIds: t,
1172
1172
  options: o
1173
1173
  };
@@ -1200,14 +1200,14 @@ function In(e) {
1200
1200
  function Ln(e, t) {
1201
1201
  return e.reduce((e, n) => k(k({}, e), {}, { [n]: t(n) }), {});
1202
1202
  }
1203
- function Rn(e, t, n, r) {
1204
- var i;
1203
+ function Rn(e, t, n) {
1204
+ var r;
1205
1205
  if (t === "none") {
1206
1206
  let t = (e == null ? [] : e).filter(zn).map((e) => y(e));
1207
1207
  return t.length > 0 ? t : [v("")];
1208
1208
  }
1209
- let a = (e == null ? [] : e).filter((e) => typeof e == "string").filter((e, t, r) => n.has(e) && r.indexOf(e) === t), o = r === "single" ? a.slice(0, 1) : a;
1210
- return o.length > 0 ? o : [(i = n.values().next().value) == null ? "" : i].filter(Boolean);
1209
+ let i = (e == null ? [] : e).filter((e) => typeof e == "string").filter((e, t, r) => n.has(e) && r.indexOf(e) === t), a = t === "perBlankOptions" ? i.slice(0, 1) : i;
1210
+ return a.length > 0 ? a : [(r = n.values().next().value) == null ? "" : r].filter(Boolean);
1211
1211
  }
1212
1212
  function zn(e) {
1213
1213
  return !!(e && typeof e == "object");
@@ -1263,19 +1263,19 @@ function Kn(e, t, n) {
1263
1263
  function qn(e, t, n) {
1264
1264
  let r = (t == null ? void 0 : t.type) === "inlineFill" ? t : bn(e);
1265
1265
  return {
1266
- answers: Jn((n == null ? void 0 : n.type) === "inlineFill" ? n.answers : void 0, r, jn(e.config.candidateMode), e.config.selectionType),
1266
+ answers: Jn((n == null ? void 0 : n.type) === "inlineFill" ? n.answers : void 0, r, jn(e.config.candidateMode)),
1267
1267
  elementId: e.id,
1268
1268
  type: "inlineFill"
1269
1269
  };
1270
1270
  }
1271
- function Jn(e, t, n, r) {
1272
- let i = new Set(t.blanks.map((e) => e.id));
1273
- return (e == null ? [] : e).filter((e) => i.has(e.blankId)).map((e) => {
1274
- var i;
1275
- let a = t.answers.find((t) => t.blankIds.includes(e.blankId)), o = new Set((i = a == null ? void 0 : a.options.map((e) => e.id)) == null ? [] : i);
1271
+ function Jn(e, t, n) {
1272
+ let r = new Set(t.blanks.map((e) => e.id));
1273
+ return (e == null ? [] : e).filter((e) => r.has(e.blankId)).map((e) => {
1274
+ var r;
1275
+ let i = t.answers.find((t) => t.blankIds.includes(e.blankId)), a = new Set((r = i == null ? void 0 : i.options.map((e) => e.id)) == null ? [] : r);
1276
1276
  return {
1277
1277
  blankId: e.blankId,
1278
- values: Rn(e.values, n, o, r)
1278
+ values: Rn(e.values, n, a)
1279
1279
  };
1280
1280
  });
1281
1281
  }
@@ -1327,7 +1327,7 @@ function tr(e, t) {
1327
1327
  }
1328
1328
  var nr = [
1329
1329
  "none",
1330
- "optionGroups",
1330
+ "perBlankOptions",
1331
1331
  "sharedPool"
1332
1332
  ];
1333
1333
  //#endregion
@@ -1579,13 +1579,14 @@ function Lr(e, t = []) {
1579
1579
  return {
1580
1580
  clientId: Zr(),
1581
1581
  enName: Yr(e),
1582
+ extraKey: Qr(e),
1582
1583
  name: Jr(e),
1583
1584
  type: e
1584
1585
  };
1585
1586
  }
1586
1587
  function Rr(e, t = []) {
1587
1588
  let n = Zr();
1588
- return e === "classification" || e === "fill" || e === "richText" || e === "textMarker" || e === "ordering" ? Qr(e, n) : zr(e, n);
1589
+ return e === "classification" || e === "fill" || e === "richText" || e === "textMarker" || e === "ordering" ? $r(e, n) : zr(e, n);
1589
1590
  }
1590
1591
  function zr(e, t) {
1591
1592
  switch (e) {
@@ -1595,6 +1596,7 @@ function zr(e, t) {
1595
1596
  allowCandidateReuse: !1,
1596
1597
  candidateMode: "none"
1597
1598
  },
1599
+ elementKey: t,
1598
1600
  enName: j(e),
1599
1601
  name: A(e),
1600
1602
  type: e
@@ -1602,6 +1604,7 @@ function zr(e, t) {
1602
1604
  case "wordBuilder": return {
1603
1605
  clientId: t,
1604
1606
  config: { builderMode: "spelling" },
1607
+ elementKey: t,
1605
1608
  enName: j(e),
1606
1609
  name: A(e),
1607
1610
  type: e
@@ -1609,6 +1612,7 @@ function zr(e, t) {
1609
1612
  case "judgement": return {
1610
1613
  clientId: t,
1611
1614
  config: { judgeAnswerMode: "correctWrong" },
1615
+ elementKey: t,
1612
1616
  enName: j(e),
1613
1617
  name: A(e),
1614
1618
  type: e
@@ -1620,6 +1624,7 @@ function zr(e, t) {
1620
1624
  renderer: "standard",
1621
1625
  selectionType: "single"
1622
1626
  },
1627
+ elementKey: t,
1623
1628
  enName: j(e),
1624
1629
  name: A(e),
1625
1630
  type: e
@@ -1632,6 +1637,7 @@ function Br(e, t) {
1632
1637
  return {
1633
1638
  clientId: t,
1634
1639
  config: { columns: [{ labelStyle: "number" }, { labelStyle: "upperAlpha" }] },
1640
+ elementKey: t,
1635
1641
  enName: j(e),
1636
1642
  name: A(e),
1637
1643
  type: e
@@ -1646,7 +1652,7 @@ function Hr(e, t) {
1646
1652
  function Ur(e, t, n) {
1647
1653
  let r = e.elements.findIndex((e) => e.clientId === t), i = r + n;
1648
1654
  if (r < 0 || i < 0 || i >= e.elements.length) return e;
1649
- let a = $r(e.elements, r), o = $r(e.elements, i);
1655
+ let a = ei(e.elements, r), o = ei(e.elements, i);
1650
1656
  return !a || !o ? e : k(k({}, e), {}, { elements: e.elements.map((e, t) => t === r ? o : t === i ? a : e) });
1651
1657
  }
1652
1658
  function Wr(e, t, n) {
@@ -1680,21 +1686,25 @@ function Xr(e, t) {
1680
1686
  function Zr() {
1681
1687
  return kr();
1682
1688
  }
1683
- function Qr(e, t) {
1689
+ function Qr(e) {
1690
+ return `extra-${e}`;
1691
+ }
1692
+ function $r(e, t) {
1684
1693
  return {
1685
1694
  clientId: t,
1686
1695
  config: {},
1696
+ elementKey: t,
1687
1697
  enName: j(e),
1688
1698
  name: A(e),
1689
1699
  type: e
1690
1700
  };
1691
1701
  }
1692
- function $r(e, t) {
1702
+ function ei(e, t) {
1693
1703
  return e.find((e, n) => n === t);
1694
1704
  }
1695
1705
  //#endregion
1696
1706
  //#region src/question/elements/fill/inline-fill-plugin.module.css
1697
- var ei = { "blank-underline": "_blank-underline_1wnlx_1" }, ti = { nodes: [{
1707
+ var ti = { "blank-underline": "_blank-underline_1wnlx_1" }, ni = { nodes: [{
1698
1708
  codecs: {
1699
1709
  html: {
1700
1710
  deserialize: ({ element: e }) => {
@@ -1706,111 +1716,111 @@ var ei = { "blank-underline": "_blank-underline_1wnlx_1" }, ti = { nodes: [{
1706
1716
  type: "blank"
1707
1717
  } : null;
1708
1718
  },
1709
- serialize: ({ node: e }) => e.type === "blank" ? `<span data-rte-node="blank" data-blank-id="${ai(e.blankId)}" data-label="${ai(e.label)}"></span>` : null
1719
+ serialize: ({ node: e }) => e.type === "blank" ? `<span data-rte-node="blank" data-blank-id="${oi(e.blankId)}" data-label="${oi(e.label)}"></span>` : null
1710
1720
  },
1711
1721
  json: {
1712
- deserialize: ({ input: e }) => ni(e) ? {
1713
- blankId: ai(e.blankId),
1714
- label: ai(e.label),
1722
+ deserialize: ({ input: e }) => ri(e) ? {
1723
+ blankId: oi(e.blankId),
1724
+ label: oi(e.label),
1715
1725
  children: [{ text: "" }],
1716
1726
  type: "blank"
1717
1727
  } : null,
1718
1728
  serialize: ({ node: e }) => e.type === "blank" ? {
1719
- blankId: ai(e.blankId),
1720
- label: ai(e.label),
1729
+ blankId: oi(e.blankId),
1730
+ label: oi(e.label),
1721
1731
  type: "blank"
1722
1732
  } : null
1723
1733
  }
1724
1734
  },
1725
1735
  commands: { insert: ({ payload: e }) => ({
1726
- blankId: ri(e),
1727
- label: ii(e),
1736
+ blankId: ii(e),
1737
+ label: ai(e),
1728
1738
  type: "blank"
1729
1739
  }) },
1730
1740
  object: {
1731
1741
  inline: !0,
1732
1742
  markable: !0,
1733
1743
  render: ({ element: e, selected: t }) => /* @__PURE__ */ a("span", {
1734
- className: ei["blank-underline"],
1744
+ className: ti["blank-underline"],
1735
1745
  "data-selected": t ? "true" : void 0,
1736
- children: ai(e.label) || ai(e.blankId) || "Blank"
1746
+ children: oi(e.label) || oi(e.blankId) || "Blank"
1737
1747
  })
1738
1748
  },
1739
1749
  type: "blank"
1740
1750
  }] };
1741
- function ni(e) {
1742
- return !!(e && typeof e == "object" && "type" in e && e.type === "blank");
1743
- }
1744
1751
  function ri(e) {
1745
- return e && typeof e == "object" && "blankId" in e ? ai(e.blankId) : "";
1752
+ return !!(e && typeof e == "object" && "type" in e && e.type === "blank");
1746
1753
  }
1747
1754
  function ii(e) {
1748
- return e && typeof e == "object" && "label" in e ? ai(e.label) : "";
1755
+ return e && typeof e == "object" && "blankId" in e ? oi(e.blankId) : "";
1749
1756
  }
1750
1757
  function ai(e) {
1758
+ return e && typeof e == "object" && "label" in e ? oi(e.label) : "";
1759
+ }
1760
+ function oi(e) {
1751
1761
  return typeof e == "string" ? e : "";
1752
1762
  }
1753
1763
  //#endregion
1754
1764
  //#region src/question/content-editor/helpers.ts
1755
- var oi = 1, si = 4, ci = "composite", li = 2, ui = 4, di = 2, fi = {
1765
+ var si = 1, ci = 4, li = "composite", ui = 2, di = 4, fi = 2, pi = {
1756
1766
  lowerAlpha: (e) => String.fromCharCode(97 + e),
1757
1767
  number: (e) => String(e + 1),
1758
1768
  upperAlpha: (e) => String.fromCharCode(65 + e)
1759
1769
  };
1760
- function pi(e) {
1761
- return e.systemQuestionType === ci;
1770
+ function mi(e) {
1771
+ return e.systemQuestionType === li;
1762
1772
  }
1763
- function mi(e, t = null) {
1773
+ function hi(e, t = null) {
1764
1774
  return {
1765
1775
  questionTypeKey: t,
1766
1776
  children: [],
1767
- elements: e.elements.map((t) => Xa(t, e.hasAnswer)),
1768
- extras: e.extras.map($a),
1777
+ elements: e.elements.map((t) => Za(t, e.hasAnswer)),
1778
+ extras: e.extras.map(eo),
1769
1779
  id: null,
1770
1780
  version: ""
1771
1781
  };
1772
1782
  }
1773
1783
  function M(e = "", t) {
1774
- return hi(t == null ? Ro(e) : t);
1784
+ return gi(t == null ? zo(e) : t);
1775
1785
  }
1776
- function hi(e, t = [ti]) {
1777
- let n = Ko(e, t);
1786
+ function gi(e, t = [ni]) {
1787
+ let n = qo(e, t);
1778
1788
  return {
1779
1789
  html: r(n, { plugins: t }),
1780
1790
  json: n,
1781
- text: zo(n)
1791
+ text: Bo(n)
1782
1792
  };
1783
1793
  }
1784
- function gi(e = "", t, n = "") {
1785
- return hi(_i(e, t, n), [It]);
1794
+ function _i(e = "", t, n = "") {
1795
+ return gi(vi(e, t, n), [It]);
1786
1796
  }
1787
- function _i(e, n, r) {
1788
- return n && Go(n) ? n : r ? t(r, { plugins: [It] }) : Ro(e);
1797
+ function vi(e, n, r) {
1798
+ return n && Ko(n) ? n : r ? t(r, { plugins: [It] }) : zo(e);
1789
1799
  }
1790
- function vi(e) {
1800
+ function yi(e) {
1791
1801
  return Vt(e.content.json).filter((t) => e.answers.includes(t.markerId)).map((e) => e.text.trim()).filter(Boolean).join(" / ");
1792
1802
  }
1793
- function yi(e) {
1794
- return Go(e.json) ? e.json : Ro(e.text);
1803
+ function bi(e) {
1804
+ return Ko(e.json) ? e.json : zo(e.text);
1795
1805
  }
1796
- function bi(e, t, n) {
1806
+ function xi(e, t, n) {
1797
1807
  var r;
1798
- return (r = e.elements.find((e) => e.elementKey === t.elementKey)) == null ? Xa(t, n) : r;
1799
- }
1800
- function xi(e, t) {
1801
- var n;
1802
- return (n = e.extras.find((e) => e.extraKey === t.extraKey)) == null ? $a(t) : n;
1808
+ return (r = e.elements.find((e) => e.elementKey === t.elementKey)) == null ? Za(t, n) : r;
1803
1809
  }
1804
1810
  function Si(e, t) {
1805
- return fi[e](t);
1811
+ var n;
1812
+ return (n = e.extras.find((e) => e.extraKey === t.extraKey)) == null ? eo(t) : n;
1806
1813
  }
1807
1814
  function Ci(e, t) {
1808
- return $e(e, t);
1815
+ return pi[e](t);
1809
1816
  }
1810
1817
  function wi(e, t) {
1818
+ return $e(e, t);
1819
+ }
1820
+ function Ti(e, t) {
1811
1821
  return Ct(e, t);
1812
1822
  }
1813
- function Ti(e) {
1823
+ function Ei(e) {
1814
1824
  switch (e) {
1815
1825
  case "checkCross": return ["\u2713", "\u2715"];
1816
1826
  case "correctWrong": return ["\u6b63\u786e", "\u9519\u8bef"];
@@ -1820,139 +1830,139 @@ function Ti(e) {
1820
1830
  case "yesNo": return ["\u662f", "\u5426"];
1821
1831
  }
1822
1832
  }
1823
- function Ei(e, t) {
1824
- return e.options.map((e, n) => _a(e, n, t));
1825
- }
1826
1833
  function Di(e, t) {
1827
- let n = Ei(e, t);
1834
+ return e.options.map((e, n) => va(e, n, t));
1835
+ }
1836
+ function Oi(e, t) {
1837
+ let n = Di(e, t);
1828
1838
  return e.answers.optionIds.reduce((e, t) => {
1829
1839
  let r = n.find((e) => e.optionId === t);
1830
1840
  return r ? [...e, r] : e;
1831
1841
  }, []);
1832
1842
  }
1833
- function Oi(e) {
1834
- return e.elements.every(qo) && e.extras.every((e) => N(e.content)) && e.children.every(Oi);
1835
- }
1836
1843
  function ki(e) {
1844
+ return e.elements.every(Jo) && e.extras.every((e) => N(e.content)) && e.children.every(ki);
1845
+ }
1846
+ function Ai(e) {
1837
1847
  return {
1838
1848
  questionTypeKey: e.questionTypeKey,
1839
- children: e.children.map(ki),
1840
- elements: e.elements.map(os),
1849
+ children: e.children.map(Ai),
1850
+ elements: e.elements.map(ss),
1841
1851
  extras: e.extras.map(hs),
1842
1852
  id: e.id,
1843
1853
  version: e.version
1844
1854
  };
1845
1855
  }
1846
- function Ai(e, t) {
1856
+ function ji(e, t) {
1847
1857
  var n, r, i;
1848
1858
  let a = /* @__PURE__ */ new Set(), o = /* @__PURE__ */ new Set();
1849
1859
  return {
1850
1860
  questionTypeKey: (n = t.questionTypeKey) == null ? null : n,
1851
1861
  children: (r = t.children) == null ? [] : r,
1852
1862
  elements: e.elements.map((n) => {
1853
- let r = t.elements.findIndex((e, t) => !a.has(t) && e.type === n.type);
1854
- return r < 0 ? Xa(n, e.hasAnswer) : (a.add(r), cs(t.elements.slice(r, r + 1)[0], n, e.hasAnswer));
1863
+ let r = t.elements.findIndex((e, t) => !a.has(t) && e.elementKey === n.elementKey);
1864
+ return r < 0 ? Za(n, e.hasAnswer) : (a.add(r), ls(t.elements.slice(r, r + 1)[0], n, e.hasAnswer));
1855
1865
  }),
1856
1866
  extras: e.extras.map((e) => {
1857
1867
  var n, r;
1858
- let i = (n = (r = t.extras) == null ? void 0 : r.findIndex((t, n) => !o.has(n) && t.type === e.type)) == null ? -1 : n;
1859
- return i < 0 || !t.extras ? $a(e) : (o.add(i), ms(t.extras.slice(i, i + 1)[0], e.extraKey));
1868
+ let i = (n = (r = t.extras) == null ? void 0 : r.findIndex((t, n) => !o.has(n) && t.extraKey === e.extraKey)) == null ? -1 : n;
1869
+ return i < 0 || !t.extras ? eo(e) : (o.add(i), t.extras.slice(i, i + 1)[0]);
1860
1870
  }),
1861
1871
  id: (i = t.id) == null ? null : i,
1862
1872
  version: t.version
1863
1873
  };
1864
1874
  }
1865
- function ji(e, t) {
1875
+ function Mi(e, t) {
1866
1876
  let n = e.elements.some((e) => e.elementKey === t.elementKey);
1867
1877
  return k(k({}, e), {}, { elements: n ? e.elements.map((e) => e.elementKey === t.elementKey ? t : e) : [...e.elements, t] });
1868
1878
  }
1869
- function Mi(e, t) {
1879
+ function Ni(e, t) {
1870
1880
  let n = e.extras.some((e) => e.extraKey === t.extraKey);
1871
1881
  return k(k({}, e), {}, { extras: n ? e.extras.map((e) => e.extraKey === t.extraKey ? t : e) : [...e.extras, t] });
1872
1882
  }
1873
- function Ni(e) {
1883
+ function Pi(e) {
1874
1884
  let t = [];
1875
- return Vo(e, (e) => {
1876
- if (!Uo(e) || e.type !== "blank") return;
1877
- let n = Ho(e, "blankId");
1885
+ return Ho(e, (e) => {
1886
+ if (!Wo(e) || e.type !== "blank") return;
1887
+ let n = Uo(e, "blankId");
1878
1888
  n && !t.includes(n) && t.push(n);
1879
1889
  }), t;
1880
1890
  }
1881
- function Pi(e) {
1882
- return Lo(e);
1891
+ function Fi(e) {
1892
+ return Ro(e);
1883
1893
  }
1884
- function Fi(e, t, n, r) {
1885
- let i = Ni(t.json);
1886
- return zi(k(k({}, e), {}, {
1894
+ function Ii(e, t, n, r) {
1895
+ let i = Pi(t.json);
1896
+ return Bi(k(k({}, e), {}, {
1887
1897
  blanks: i,
1888
1898
  content: t
1889
1899
  }), r, n);
1890
1900
  }
1891
- function Ii(e, t, n, r) {
1892
- let i = Ni(t.json);
1893
- return Ri(k(k({}, e), {}, {
1901
+ function Li(e, t, n, r) {
1902
+ let i = Pi(t.json);
1903
+ return zi(k(k({}, e), {}, {
1894
1904
  blanks: i,
1895
1905
  content: t
1896
1906
  }), n, r);
1897
1907
  }
1898
- function Li(e, t, n) {
1899
- let r = gi(t.text, t.json, t.html), i = Bt(r.json);
1908
+ function Ri(e, t, n) {
1909
+ let r = _i(t.text, t.json, t.html), i = Bt(r.json);
1900
1910
  return k(k({}, e), {}, {
1901
- answers: n ? xo(e.answers, i) : [],
1911
+ answers: n ? So(e.answers, i) : [],
1902
1912
  content: r,
1903
1913
  markers: i
1904
1914
  });
1905
1915
  }
1906
- function Ri(e, t, n) {
1907
- let r = Wi(e.blanks);
1916
+ function zi(e, t, n) {
1917
+ let r = Gi(e.blanks);
1908
1918
  return k(k({}, e), {}, {
1909
- answers: t ? Gi(e.answers, r) : {},
1919
+ answers: t ? Ki(e.answers, r) : {},
1910
1920
  blanks: r,
1911
- candidateOptions: Hi(e.candidateOptions, n.config.builderMode)
1921
+ candidateOptions: Ui(e.candidateOptions, n.config.builderMode)
1912
1922
  });
1913
1923
  }
1914
- function zi(e, t, n) {
1924
+ function Bi(e, t, n) {
1915
1925
  if (t.config.candidateMode === "sharedPool") {
1916
- let r = Vi(e.candidateOptions, "option_");
1926
+ let r = Hi(e.candidateOptions, "option_");
1917
1927
  return k(k({}, e), {}, {
1918
- answers: n ? Xi(e.answers, e.blanks, r.map((e) => e.optionId), t.config.allowCandidateReuse) : [],
1928
+ answers: n ? Zi(e.answers, e.blanks, r.map((e) => e.optionId), t.config.allowCandidateReuse) : [],
1919
1929
  blankOptionGroups: void 0,
1920
1930
  candidateOptions: r
1921
1931
  });
1922
1932
  }
1923
1933
  if (t.config.candidateMode === "perBlankOptions") {
1924
- let t = Ji(e.blankOptionGroups, e.blanks), r = new Map(t.map((e) => [e.blankId, e.options.map((e) => e.optionId)]));
1934
+ let t = Yi(e.blankOptionGroups, e.blanks), r = new Map(t.map((e) => [e.blankId, e.options.map((e) => e.optionId)]));
1925
1935
  return k(k({}, e), {}, {
1926
- answers: n ? Zi(e.answers, e.blanks, r) : [],
1936
+ answers: n ? Qi(e.answers, e.blanks, r) : [],
1927
1937
  blankOptionGroups: t,
1928
1938
  candidateOptions: void 0
1929
1939
  });
1930
1940
  }
1931
1941
  return k(k({}, e), {}, {
1932
- answers: n ? ea(e.answers, e.blanks) : [],
1942
+ answers: n ? ta(e.answers, e.blanks) : [],
1933
1943
  blankOptionGroups: void 0,
1934
1944
  candidateOptions: void 0
1935
1945
  });
1936
1946
  }
1937
- function Bi(e, t = M()) {
1947
+ function Vi(e, t = M()) {
1938
1948
  return {
1939
1949
  content: t,
1940
1950
  optionId: e
1941
1951
  };
1942
1952
  }
1943
- function Vi(e, t = "option_", n = 1) {
1953
+ function Hi(e, t = "option_", n = 1) {
1944
1954
  var r;
1945
1955
  let i = /* @__PURE__ */ new Set(), a = (r = e == null ? void 0 : e.map((e, n) => {
1946
- let r = e.optionId || Io(n, t);
1947
- return i.has(r) ? Bi(Io(n, t), e.content) : (i.add(r), Bi(r, e.content));
1956
+ let r = e.optionId || Lo(n, t);
1957
+ return i.has(r) ? Vi(Lo(n, t), e.content) : (i.add(r), Vi(r, e.content));
1948
1958
  }).filter((e) => e.optionId.length > 0)) == null ? [] : r;
1949
- return a.length ? a : Array.from({ length: n }, (e, r) => Bi(Io(r, t), n === si ? M(`\u9009\u9879 ${Si("upperAlpha", r)}`) : M()));
1959
+ return a.length ? a : Array.from({ length: n }, (e, r) => Vi(Lo(r, t), n === ci ? M(`\u9009\u9879 ${Ci("upperAlpha", r)}`) : M()));
1950
1960
  }
1951
- function Hi(e, t) {
1961
+ function Ui(e, t) {
1952
1962
  let n = (e == null ? [] : e).map((e) => e.trim()).filter((e) => e.length > 0);
1953
- return n.length > 0 ? n : Ui(t);
1963
+ return n.length > 0 ? n : Wi(t);
1954
1964
  }
1955
- function Ui(e) {
1965
+ function Wi(e) {
1956
1966
  return e === "sentence" ? ["This helped them save time."] : [
1957
1967
  "c",
1958
1968
  "l",
@@ -1961,17 +1971,17 @@ function Ui(e) {
1961
1971
  "n"
1962
1972
  ];
1963
1973
  }
1964
- function Wi(e) {
1965
- return e.map((e, t) => e.trim() || Fo(t)).filter((e, t, n) => e.length > 0 && n.indexOf(e) === t);
1974
+ function Gi(e) {
1975
+ return e.map((e, t) => e.trim() || Io(t)).filter((e, t, n) => e.length > 0 && n.indexOf(e) === t);
1966
1976
  }
1967
- function Gi(e, t) {
1977
+ function Ki(e, t) {
1968
1978
  return t.reduce((t, n) => {
1969
1979
  var r;
1970
1980
  return k(k({}, t), {}, { [n]: (r = e[n]) == null ? "" : r });
1971
1981
  }, {});
1972
1982
  }
1973
- function Ki() {
1974
- return hi([{
1983
+ function qi() {
1984
+ return gi([{
1975
1985
  children: [{ text: "Complete: " }, {
1976
1986
  blankId: "blank_0",
1977
1987
  children: [{ text: "" }],
@@ -1981,25 +1991,25 @@ function Ki() {
1981
1991
  type: "paragraph"
1982
1992
  }]);
1983
1993
  }
1984
- function qi(e, t) {
1994
+ function Ji(e, t) {
1985
1995
  return {
1986
1996
  blankId: t,
1987
- options: Vi(e == null ? void 0 : e.options, `${t}_option_`, si)
1997
+ options: Hi(e == null ? void 0 : e.options, `${t}_option_`, ci)
1988
1998
  };
1989
1999
  }
1990
- function Ji(e, t) {
2000
+ function Yi(e, t) {
1991
2001
  let n = new Map((e == null ? [] : e).map((e) => [e.blankId, e]));
1992
- return t.map((e) => k({}, qi(n.get(e), e)));
2002
+ return t.map((e) => k({}, Ji(n.get(e), e)));
1993
2003
  }
1994
- function Yi(e) {
2004
+ function Xi(e) {
1995
2005
  return e && "answerOptionIds" in e ? e.answerOptionIds : [];
1996
2006
  }
1997
- function Xi(e, t, n, r) {
2007
+ function Zi(e, t, n, r) {
1998
2008
  let i = /* @__PURE__ */ new Set(), a = /* @__PURE__ */ new Set(), o = new Set(n);
1999
2009
  return [...e.filter((e) => "answerOptionIds" in e).map((e) => {
2000
2010
  let n = e.blankIds.filter((e) => !t.includes(e) || i.has(e) ? !1 : (i.add(e), !0));
2001
2011
  return {
2002
- answerOptionIds: Yi(e).filter((e) => !o.has(e) || !r && a.has(e) ? !1 : (a.add(e), !0)),
2012
+ answerOptionIds: Xi(e).filter((e) => !o.has(e) || !r && a.has(e) ? !1 : (a.add(e), !0)),
2003
2013
  blankIds: n
2004
2014
  };
2005
2015
  }).filter((e) => e.blankIds.length > 0), ...t.filter((e) => !i.has(e)).map((e) => ({
@@ -2007,7 +2017,7 @@ function Xi(e, t, n, r) {
2007
2017
  blankIds: [e]
2008
2018
  }))];
2009
2019
  }
2010
- function Zi(e, t, n) {
2020
+ function Qi(e, t, n) {
2011
2021
  let r = new Map(e.filter((e) => "answerOptionId" in e).map((e) => [e.blankId, e.answerOptionId]));
2012
2022
  return t.map((e) => {
2013
2023
  var t, i;
@@ -2018,30 +2028,30 @@ function Zi(e, t, n) {
2018
2028
  };
2019
2029
  });
2020
2030
  }
2021
- function Qi(e) {
2022
- let t = Lo(e.blanks), n = [...e.blanks, t];
2031
+ function $i(e) {
2032
+ let t = Ro(e.blanks), n = [...e.blanks, t];
2023
2033
  return k(k({}, e), {}, {
2024
- answers: ea([...e.answers, {
2034
+ answers: ta([...e.answers, {
2025
2035
  answerPools: [M()],
2026
2036
  blankIds: [t]
2027
2037
  }], n),
2028
2038
  blanks: n
2029
2039
  });
2030
2040
  }
2031
- function $i(e, t) {
2041
+ function ea(e, t) {
2032
2042
  if (e.blanks.length <= 1) return e;
2033
- let n = e.blanks.filter((e) => e !== t), r = ea(e.answers.map((e) => k(k({}, e), {}, { blankIds: e.blankIds.filter((e) => e !== t) })).filter((e) => e.blankIds.length > 0), n);
2043
+ let n = e.blanks.filter((e) => e !== t), r = ta(e.answers.map((e) => k(k({}, e), {}, { blankIds: e.blankIds.filter((e) => e !== t) })).filter((e) => e.blankIds.length > 0), n);
2034
2044
  return k(k({}, e), {}, {
2035
2045
  answers: r,
2036
2046
  blanks: n.length ? n : e.blanks
2037
2047
  });
2038
2048
  }
2039
- function ea(e, t) {
2049
+ function ta(e, t) {
2040
2050
  let n = /* @__PURE__ */ new Set();
2041
2051
  return [...e.filter((e) => "answerPools" in e).map((e) => {
2042
2052
  let r = e.blankIds.filter((e) => !t.includes(e) || n.has(e) ? !1 : (n.add(e), !0));
2043
2053
  return {
2044
- answerPools: as("answerPools" in e ? e.answerPools : []),
2054
+ answerPools: os("answerPools" in e ? e.answerPools : []),
2045
2055
  blankIds: r
2046
2056
  };
2047
2057
  }).filter((e) => e.blankIds.length > 0), ...t.filter((e) => !n.has(e)).map((e) => ({
@@ -2049,52 +2059,52 @@ function ea(e, t) {
2049
2059
  blankIds: [e]
2050
2060
  }))];
2051
2061
  }
2052
- function ta(e) {
2062
+ function na(e) {
2053
2063
  return e.reduce((e, t, n) => (t.blankIds.length >= 2 && e.push({
2054
2064
  group: t,
2055
2065
  groupIndex: n
2056
2066
  }), e), []);
2057
2067
  }
2058
- function na(e, t, n) {
2068
+ function ra(e, t, n) {
2059
2069
  let r = e.answers.find((e) => e.blankIds.includes(t)), i = e.answers.slice(n, n + 1)[0];
2060
- return !i || i.blankIds.length < 2 || i.blankIds.includes(t) ? e : k(k({}, e), {}, { answers: ea(e.answers.map((e, r) => r === n ? k(k({}, e), {}, {
2061
- answerPools: as(e.answerPools),
2070
+ return !i || i.blankIds.length < 2 || i.blankIds.includes(t) ? e : k(k({}, e), {}, { answers: ta(e.answers.map((e, r) => r === n ? k(k({}, e), {}, {
2071
+ answerPools: os(e.answerPools),
2062
2072
  blankIds: [...e.blankIds, t]
2063
2073
  }) : k(k({}, e), {}, {
2064
- answerPools: as(e.answerPools),
2074
+ answerPools: os(e.answerPools),
2065
2075
  blankIds: e.blankIds.filter((e) => e !== t)
2066
2076
  })), e.blanks).map((e) => {
2067
2077
  var n;
2068
- return e.blankIds.includes(t) && e.blankIds.length > 1 ? k(k({}, e), {}, { answerPools: i.answerPools.length > 0 ? as(i.answerPools) : as((n = r == null ? void 0 : r.answerPools) == null ? [] : n) }) : e;
2078
+ return e.blankIds.includes(t) && e.blankIds.length > 1 ? k(k({}, e), {}, { answerPools: i.answerPools.length > 0 ? os(i.answerPools) : os((n = r == null ? void 0 : r.answerPools) == null ? [] : n) }) : e;
2069
2079
  }) });
2070
2080
  }
2071
- function ra(e, t, n) {
2081
+ function ia(e, t, n) {
2072
2082
  var r;
2073
2083
  if (t === n || !e.blanks.includes(t) || !e.blanks.includes(n)) return e;
2074
2084
  let i = e.answers.find((e) => e.blankIds.includes(t));
2075
- return k(k({}, e), {}, { answers: ea([...e.answers.map((e) => k(k({}, e), {}, { blankIds: e.blankIds.filter((e) => e !== t && e !== n) })), {
2076
- answerPools: as((r = i == null ? void 0 : i.answerPools) == null ? [] : r),
2085
+ return k(k({}, e), {}, { answers: ta([...e.answers.map((e) => k(k({}, e), {}, { blankIds: e.blankIds.filter((e) => e !== t && e !== n) })), {
2086
+ answerPools: os((r = i == null ? void 0 : i.answerPools) == null ? [] : r),
2077
2087
  blankIds: [t, n]
2078
2088
  }], e.blanks) });
2079
2089
  }
2080
- function ia(e, t) {
2090
+ function aa(e, t) {
2081
2091
  var n;
2082
2092
  let r = e.answers.find((e) => e.blankIds.includes(t));
2083
- return k(k({}, e), {}, { answers: ea([...e.answers.map((e) => k(k({}, e), {}, { blankIds: e.blankIds.filter((e) => e !== t) })), {
2084
- answerPools: as((n = r == null ? void 0 : r.answerPools) == null ? [] : n),
2093
+ return k(k({}, e), {}, { answers: ta([...e.answers.map((e) => k(k({}, e), {}, { blankIds: e.blankIds.filter((e) => e !== t) })), {
2094
+ answerPools: os((n = r == null ? void 0 : r.answerPools) == null ? [] : n),
2085
2095
  blankIds: [t]
2086
2096
  }], e.blanks) });
2087
2097
  }
2088
- function aa(e, t, n) {
2089
- return k(k({}, e), {}, { answers: ea(e.answers.map((e, r) => r === t ? k(k({}, e), {}, { answerPools: as(n) }) : e), e.blanks) });
2098
+ function oa(e, t, n) {
2099
+ return k(k({}, e), {}, { answers: ta(e.answers.map((e, r) => r === t ? k(k({}, e), {}, { answerPools: os(n) }) : e), e.blanks) });
2090
2100
  }
2091
- function oa(e) {
2092
- return ya(e);
2101
+ function sa(e) {
2102
+ return ba(e);
2093
2103
  }
2094
- function sa(e, t, n) {
2104
+ function ca(e, t, n) {
2095
2105
  return k(k({}, e), {}, { options: e.options.map((e, r) => r === t ? k(k({}, e), {}, { cells: e.cells.map((e, t) => t === 0 ? n : e) }) : e) });
2096
2106
  }
2097
- function ca(e, t) {
2107
+ function la(e, t) {
2098
2108
  if (!e.options[t] || e.options.length <= 1) return e;
2099
2109
  let n = e.options.filter((e, n) => n !== t);
2100
2110
  return k(k({}, e), {}, {
@@ -2102,23 +2112,23 @@ function ca(e, t) {
2102
2112
  options: n
2103
2113
  });
2104
2114
  }
2105
- function la(e, t, n) {
2115
+ function ua(e, t, n) {
2106
2116
  return ue(e, t, n);
2107
2117
  }
2108
- function ua(e) {
2118
+ function da(e) {
2109
2119
  let t = [...e.columns, _e(e.columns)];
2110
2120
  return k(k({}, e), {}, {
2111
2121
  columns: t,
2112
2122
  options: e.options.map((e) => k(k({}, e), {}, { cells: [...e.cells, M()] }))
2113
2123
  });
2114
2124
  }
2115
- function da(e, t) {
2125
+ function fa(e, t) {
2116
2126
  return le(e, t);
2117
2127
  }
2118
- function fa(e) {
2119
- return ya(e);
2128
+ function pa(e) {
2129
+ return ba(e);
2120
2130
  }
2121
- function pa(e, t) {
2131
+ function ma(e, t) {
2122
2132
  if (!e.options[t] || e.options.length <= 1) return e;
2123
2133
  let n = e.options.filter((e, n) => n !== t);
2124
2134
  return k(k({}, e), {}, {
@@ -2126,14 +2136,14 @@ function pa(e, t) {
2126
2136
  options: n
2127
2137
  });
2128
2138
  }
2129
- function ma(e, t, n, r) {
2139
+ function ha(e, t, n, r) {
2130
2140
  return k(k({}, e), {}, { options: e.options.map((e, i) => i === t ? k(k({}, e), {}, { cells: e.cells.map((e, t) => t === n ? r : e) }) : e) });
2131
2141
  }
2132
- function ha(e, t, n) {
2142
+ function ga(e, t, n) {
2133
2143
  return k(k({}, e), {}, { columns: e.columns.map((e, r) => r === t ? k(k({}, e), {}, { content: n }) : e) });
2134
2144
  }
2135
- function ga(e, t, n) {
2136
- va(e);
2145
+ function _a(e, t, n) {
2146
+ ya(e);
2137
2147
  let r = fe(e.columns, t.config.renderer), i = he(e.options, r);
2138
2148
  return k(k({}, e), {}, {
2139
2149
  answers: n ? ge(e.answers, i, t.config.selectionType) : { optionIds: [] },
@@ -2141,113 +2151,113 @@ function ga(e, t, n) {
2141
2151
  options: i
2142
2152
  });
2143
2153
  }
2144
- function _a(e, t, n) {
2154
+ function va(e, t, n) {
2145
2155
  var r;
2146
2156
  return {
2147
2157
  cells: e.cells,
2148
- marker: Si(n, t),
2158
+ marker: Ci(n, t),
2149
2159
  option: e,
2150
2160
  optionId: e.id,
2151
2161
  optionIndex: t,
2152
2162
  standardContent: (r = e.cells[0]) == null ? M() : r
2153
2163
  };
2154
2164
  }
2155
- function va(e) {
2165
+ function ya(e) {
2156
2166
  let t = e, n = t.answers;
2157
2167
  if (!n || !Array.isArray(n.optionIds) || !Array.isArray(t.columns) || !Array.isArray(t.options)) throw Error("Invalid choice content shape. Expected columns, options, and answer.optionIds.");
2158
2168
  }
2159
- function ya(e) {
2169
+ function ba(e) {
2160
2170
  return k(k({}, e), {}, { options: [...e.options, me(e.options, e.columns)] });
2161
2171
  }
2162
- function ba(e, t, n) {
2163
- let r = co(e.columns, t);
2172
+ function xa(e, t, n) {
2173
+ let r = lo(e.columns, t);
2164
2174
  return k(k({}, e), {}, {
2165
- answers: n ? go(e.answers, r) : {},
2175
+ answers: n ? _o(e.answers, r) : {},
2166
2176
  columns: r
2167
2177
  });
2168
2178
  }
2169
- function xa(e) {
2179
+ function Sa(e) {
2170
2180
  if (e.columns.length >= Re.max) return e;
2171
2181
  let t = e.columns.length;
2172
- return k(k({}, e), {}, { columns: [...e.columns, mo(t, fo(t))] });
2182
+ return k(k({}, e), {}, { columns: [...e.columns, ho(t, po(t))] });
2173
2183
  }
2174
- function Sa(e, t) {
2184
+ function Ca(e, t) {
2175
2185
  if (e.columns.length <= Re.min) return e;
2176
2186
  let n = e.columns.filter((e) => e.columnId !== t);
2177
2187
  return k(k({}, e), {}, {
2178
- answers: go(e.answers, n),
2188
+ answers: _o(e.answers, n),
2179
2189
  columns: n
2180
2190
  });
2181
2191
  }
2182
- function Ca(e, t, n) {
2183
- return Pa(e, t, n);
2192
+ function wa(e, t, n) {
2193
+ return Fa(e, t, n);
2184
2194
  }
2185
- function wa(e, t) {
2195
+ function Ta(e, t) {
2186
2196
  return k(k({}, e), {}, { columns: e.columns.map((n, r) => n.columnId === t ? k(k({}, n), {}, { items: [...n.items, {
2187
2197
  content: M(),
2188
- itemId: ko(Mo(r, n.items.length), new Set(Ao(e.columns)))
2198
+ itemId: Ao(No(r, n.items.length), new Set(jo(e.columns)))
2189
2199
  }] }) : n) });
2190
2200
  }
2191
- function Ta(e, t) {
2201
+ function Ea(e, t) {
2192
2202
  let n = e.columns.map((e) => e.items.length <= 1 ? e : k(k({}, e), {}, { items: e.items.filter((e) => e.itemId !== t) }));
2193
2203
  return k(k({}, e), {}, {
2194
- answers: go(e.answers, n),
2204
+ answers: _o(e.answers, n),
2195
2205
  columns: n
2196
2206
  });
2197
2207
  }
2198
- function Ea(e, t, n) {
2199
- return Fa(e, t, n);
2200
- }
2201
2208
  function Da(e, t, n) {
2202
- return Xe(e, t, n);
2209
+ return Ia(e, t, n);
2203
2210
  }
2204
2211
  function Oa(e, t, n) {
2205
- let r = _o(e.columns, t);
2212
+ return Xe(e, t, n);
2213
+ }
2214
+ function ka(e, t, n) {
2215
+ let r = vo(e.columns, t);
2206
2216
  return k(k({}, e), {}, {
2207
- answers: n ? bo(e.answers, r) : {},
2217
+ answers: n ? xo(e.answers, r) : {},
2208
2218
  columns: r
2209
2219
  });
2210
2220
  }
2211
- function ka(e, t, n) {
2212
- return Pa(e, t, n);
2221
+ function Aa(e, t, n) {
2222
+ return Fa(e, t, n);
2213
2223
  }
2214
- function Aa(e, t) {
2224
+ function ja(e, t) {
2215
2225
  return k(k({}, e), {}, { columns: e.columns.map((n, r) => n.columnId === t ? k(k({}, n), {}, { items: [...n.items, {
2216
2226
  content: M(),
2217
- itemId: ko(Po(r, n.items.length), new Set(Ao(e.columns)))
2227
+ itemId: Ao(Fo(r, n.items.length), new Set(jo(e.columns)))
2218
2228
  }] }) : n) });
2219
2229
  }
2220
- function ja(e, t) {
2230
+ function Ma(e, t) {
2221
2231
  let n = e.columns.map((e) => e.items.length <= 1 ? e : k(k({}, e), {}, { items: e.items.filter((e) => e.itemId !== t) }));
2222
2232
  return k(k({}, e), {}, {
2223
- answers: bo(e.answers, n),
2233
+ answers: xo(e.answers, n),
2224
2234
  columns: n
2225
2235
  });
2226
2236
  }
2227
- function Ma(e, t, n) {
2228
- return Fa(e, t, n);
2229
- }
2230
2237
  function Na(e, t, n) {
2231
- return bt(e, t, n);
2238
+ return Ia(e, t, n);
2232
2239
  }
2233
2240
  function Pa(e, t, n) {
2234
- return k(k({}, e), {}, { columns: e.columns.map((e) => e.columnId === t ? k(k({}, e), {}, { labelStyle: n }) : e) });
2241
+ return bt(e, t, n);
2235
2242
  }
2236
2243
  function Fa(e, t, n) {
2244
+ return k(k({}, e), {}, { columns: e.columns.map((e) => e.columnId === t ? k(k({}, e), {}, { labelStyle: n }) : e) });
2245
+ }
2246
+ function Ia(e, t, n) {
2237
2247
  return k(k({}, e), {}, { columns: e.columns.map((e) => k(k({}, e), {}, { items: e.items.map((e) => e.itemId === t ? k(k({}, e), {}, { content: n }) : e) })) });
2238
2248
  }
2239
- function Ia(e, t) {
2240
- let n = to(e.categories), r = no(e.items);
2249
+ function La(e, t) {
2250
+ let n = no(e.categories), r = ro(e.items);
2241
2251
  return k(k({}, e), {}, {
2242
2252
  answers: t ? Oe(e.answers, n, r) : {},
2243
2253
  categories: n,
2244
2254
  items: r
2245
2255
  });
2246
2256
  }
2247
- function La(e) {
2248
- return k(k({}, e), {}, { categories: [...e.categories, ro(e.categories.length, new Set(e.categories.map((e) => e.id)))] });
2257
+ function Ra(e) {
2258
+ return k(k({}, e), {}, { categories: [...e.categories, io(e.categories.length, new Set(e.categories.map((e) => e.id)))] });
2249
2259
  }
2250
- function Ra(e, t) {
2260
+ function za(e, t) {
2251
2261
  if (e.categories.length <= 1) return e;
2252
2262
  let n = e.categories.filter((e) => e.id !== t);
2253
2263
  return k(k({}, e), {}, {
@@ -2255,13 +2265,13 @@ function Ra(e, t) {
2255
2265
  categories: n
2256
2266
  });
2257
2267
  }
2258
- function za(e, t, n) {
2268
+ function Ba(e, t, n) {
2259
2269
  return k(k({}, e), {}, { categories: e.categories.map((e) => e.id === t ? k(k({}, e), {}, { content: n }) : e) });
2260
2270
  }
2261
- function Ba(e) {
2262
- return k(k({}, e), {}, { items: [...e.items, io(e.items.length, new Set(e.items.map((e) => e.id)))] });
2271
+ function Va(e) {
2272
+ return k(k({}, e), {}, { items: [...e.items, ao(e.items.length, new Set(e.items.map((e) => e.id)))] });
2263
2273
  }
2264
- function Va(e, t) {
2274
+ function Ha(e, t) {
2265
2275
  if (e.items.length <= 1) return e;
2266
2276
  let n = e.items.filter((e) => e.id !== t);
2267
2277
  return k(k({}, e), {}, {
@@ -2269,101 +2279,101 @@ function Va(e, t) {
2269
2279
  items: n
2270
2280
  });
2271
2281
  }
2272
- function Ha(e, t, n) {
2282
+ function Ua(e, t, n) {
2273
2283
  return k(k({}, e), {}, { items: e.items.map((e) => e.id === t ? k(k({}, e), {}, { content: n }) : e) });
2274
2284
  }
2275
- function Ua(e, t, n) {
2285
+ function Wa(e, t, n) {
2276
2286
  return ke(e, t, n);
2277
2287
  }
2278
- function Wa(e, t) {
2279
- let n = So(e.sortOptions);
2288
+ function Ga(e, t) {
2289
+ let n = Co(e.sortOptions);
2280
2290
  return k(k({}, e), {}, {
2281
- answers: t ? Co(e.answers, n) : [],
2291
+ answers: t ? wo(e.answers, n) : [],
2282
2292
  sortOptions: n
2283
2293
  });
2284
2294
  }
2285
- function Ga(e, t) {
2286
- let n = new Set(e.sortOptions.map((e) => e.id)), r = wo(Do(Eo(e.sortOptions.length), n));
2287
- return Wa(k(k({}, e), {}, {
2295
+ function Ka(e, t) {
2296
+ let n = new Set(e.sortOptions.map((e) => e.id)), r = To(Oo(Do(e.sortOptions.length), n));
2297
+ return Ga(k(k({}, e), {}, {
2288
2298
  answers: [...e.answers, r.id],
2289
2299
  sortOptions: [...e.sortOptions, r]
2290
2300
  }), t);
2291
2301
  }
2292
- function Ka(e, t, n) {
2293
- return e.sortOptions.length <= 1 ? e : Wa(k(k({}, e), {}, {
2302
+ function qa(e, t, n) {
2303
+ return e.sortOptions.length <= 1 ? e : Ga(k(k({}, e), {}, {
2294
2304
  answers: e.answers.filter((e) => e !== t),
2295
2305
  sortOptions: e.sortOptions.filter((e) => e.id !== t)
2296
2306
  }), n);
2297
2307
  }
2298
- function qa(e, t, n, r) {
2299
- return Wa(k(k({}, e), {}, { sortOptions: e.sortOptions.map((e) => e.id === t ? k(k({}, e), {}, { content: n }) : e) }), r);
2300
- }
2301
2308
  function Ja(e, t, n, r) {
2302
- let i = Co(e.answers, e.sortOptions), a = i.indexOf(t), o = a + n;
2309
+ return Ga(k(k({}, e), {}, { sortOptions: e.sortOptions.map((e) => e.id === t ? k(k({}, e), {}, { content: n }) : e) }), r);
2310
+ }
2311
+ function Ya(e, t, n, r) {
2312
+ let i = wo(e.answers, e.sortOptions), a = i.indexOf(t), o = a + n;
2303
2313
  if (a < 0 || o < 0 || o >= i.length) return e;
2304
2314
  let s = [...i], [c] = s.splice(a, 1);
2305
- return s.splice(o, 0, c), Wa(k(k({}, e), {}, { answers: s }), r);
2315
+ return s.splice(o, 0, c), Ga(k(k({}, e), {}, { answers: s }), r);
2306
2316
  }
2307
- function Ya(e, t, n, r) {
2308
- let i = Co(e, t), a = i.indexOf(n), o = a + r;
2317
+ function Xa(e, t, n, r) {
2318
+ let i = wo(e, t), a = i.indexOf(n), o = a + r;
2309
2319
  if (a < 0 || o < 0 || o >= i.length) return i;
2310
2320
  let s = [...i], [c] = s.splice(a, 1);
2311
2321
  return s.splice(o, 0, c), s;
2312
2322
  }
2313
- function Xa(e, t) {
2323
+ function Za(e, t) {
2314
2324
  return e.type === "richText" ? {
2315
2325
  content: M(),
2316
2326
  elementKey: e.elementKey,
2317
2327
  type: "richText"
2318
2328
  } : e.type === "textMarker" ? {
2319
2329
  answers: [],
2320
- content: gi(),
2330
+ content: _i(),
2321
2331
  elementKey: e.elementKey,
2322
2332
  markers: [],
2323
2333
  type: "textMarker"
2324
- } : e.type === "ordering" ? Wa({
2334
+ } : e.type === "ordering" ? Ga({
2325
2335
  answers: [],
2326
2336
  elementKey: e.elementKey,
2327
2337
  sortOptions: [],
2328
2338
  type: "ordering"
2329
- }, t) : e.type === "classification" ? Ia({
2339
+ }, t) : e.type === "classification" ? La({
2330
2340
  answers: {},
2331
2341
  categories: [],
2332
2342
  elementKey: e.elementKey,
2333
2343
  items: [],
2334
2344
  type: "classification"
2335
- }, t) : e.type === "fill" ? Qa(e.elementKey, t) : Za(e, t);
2345
+ }, t) : e.type === "fill" ? $a(e.elementKey, t) : Qa(e, t);
2336
2346
  }
2337
- function Za(e, t) {
2347
+ function Qa(e, t) {
2338
2348
  switch (e.type) {
2339
- case "inlineFill": return zi({
2349
+ case "inlineFill": return Bi({
2340
2350
  answers: [],
2341
2351
  blanks: [],
2342
2352
  content: M(),
2343
2353
  elementKey: e.elementKey,
2344
2354
  type: "inlineFill"
2345
2355
  }, e, t);
2346
- case "wordBuilder": return Ri({
2356
+ case "wordBuilder": return zi({
2347
2357
  answers: {},
2348
2358
  blanks: ["blank_0"],
2349
- candidateOptions: Ui(e.config.builderMode),
2350
- content: Ki(),
2359
+ candidateOptions: Wi(e.config.builderMode),
2360
+ content: qi(),
2351
2361
  elementKey: e.elementKey,
2352
2362
  type: "wordBuilder"
2353
2363
  }, t, e);
2354
- case "choice": return eo(e);
2364
+ case "choice": return to(e);
2355
2365
  case "judgement": return {
2356
2366
  answers: [],
2357
2367
  elementKey: e.elementKey,
2358
2368
  type: "judgement"
2359
2369
  };
2360
- case "lineConnect": return ba({
2370
+ case "lineConnect": return xa({
2361
2371
  answers: {},
2362
2372
  columns: [],
2363
2373
  elementKey: e.elementKey,
2364
2374
  type: "lineConnect"
2365
2375
  }, e, t);
2366
- case "matching": return Oa({
2376
+ case "matching": return ka({
2367
2377
  answers: {},
2368
2378
  columns: [],
2369
2379
  elementKey: e.elementKey,
@@ -2371,8 +2381,8 @@ function Za(e, t) {
2371
2381
  }, e, t);
2372
2382
  }
2373
2383
  }
2374
- function Qa(e, t) {
2375
- let n = Array.from({ length: oi }, (e, t) => Fo(t));
2384
+ function $a(e, t) {
2385
+ let n = Array.from({ length: si }, (e, t) => Io(t));
2376
2386
  return {
2377
2387
  answers: t ? [{
2378
2388
  answerPools: [M()],
@@ -2383,14 +2393,14 @@ function Qa(e, t) {
2383
2393
  type: "fill"
2384
2394
  };
2385
2395
  }
2386
- function $a(e) {
2396
+ function eo(e) {
2387
2397
  return {
2388
2398
  content: M(),
2389
2399
  extraKey: e.extraKey,
2390
2400
  type: e.type
2391
2401
  };
2392
2402
  }
2393
- function eo(e) {
2403
+ function to(e) {
2394
2404
  let t = de(e.config.renderer), n = pe(t);
2395
2405
  return {
2396
2406
  answers: { optionIds: [] },
@@ -2400,180 +2410,180 @@ function eo(e) {
2400
2410
  type: "choice"
2401
2411
  };
2402
2412
  }
2403
- function to(e) {
2413
+ function no(e) {
2404
2414
  let t = /* @__PURE__ */ new Set(), n = e.map((e, n) => ({
2405
2415
  content: e.content,
2406
- id: ao(e.id, oo(n), t)
2416
+ id: oo(e.id, so(n), t)
2407
2417
  }));
2408
- return n.length > 0 ? n : Array.from({ length: li }, (e, n) => ro(n, t));
2418
+ return n.length > 0 ? n : Array.from({ length: ui }, (e, n) => io(n, t));
2409
2419
  }
2410
- function no(e) {
2420
+ function ro(e) {
2411
2421
  let t = /* @__PURE__ */ new Set(), n = e.map((e, n) => ({
2412
2422
  content: e.content,
2413
- id: ao(e.id, so(n), t)
2423
+ id: oo(e.id, co(n), t)
2414
2424
  }));
2415
- return n.length > 0 ? n : Array.from({ length: ui }, (e, n) => io(n, t));
2425
+ return n.length > 0 ? n : Array.from({ length: di }, (e, n) => ao(n, t));
2416
2426
  }
2417
- function ro(e, t) {
2427
+ function io(e, t) {
2418
2428
  return {
2419
2429
  content: M(`\u5206\u7c7b ${e + 1}`),
2420
- id: ao("", oo(e), t)
2430
+ id: oo("", so(e), t)
2421
2431
  };
2422
2432
  }
2423
- function io(e, t) {
2433
+ function ao(e, t) {
2424
2434
  return {
2425
2435
  content: M(`\u5361\u7247 ${e + 1}`),
2426
- id: ao("", so(e), t)
2436
+ id: oo("", co(e), t)
2427
2437
  };
2428
2438
  }
2429
- function ao(e, t, n) {
2439
+ function oo(e, t, n) {
2430
2440
  let r = e || t, i = r, a = 2;
2431
2441
  for (; n.has(i);) i = `${r}_${a}`, a += 1;
2432
2442
  return n.add(i), i;
2433
2443
  }
2434
- function oo(e) {
2444
+ function so(e) {
2435
2445
  return `category_${e + 1}`;
2436
2446
  }
2437
- function so(e) {
2447
+ function co(e) {
2438
2448
  return `item_${e + 1}`;
2439
2449
  }
2440
- function co(e, t) {
2441
- let n = e.length > 0 ? e : lo(t), r = /* @__PURE__ */ new Set(), i = /* @__PURE__ */ new Set(), a = uo(t);
2450
+ function lo(e, t) {
2451
+ let n = e.length > 0 ? e : uo(t), r = /* @__PURE__ */ new Set(), i = /* @__PURE__ */ new Set(), a = fo(t);
2442
2452
  return n.slice(0, Re.max).map((e, t) => {
2443
2453
  var n, o;
2444
2454
  return {
2445
- columnId: ko(e.columnId, r),
2446
- items: po(e.items, t, i),
2455
+ columnId: Ao(e.columnId, r),
2456
+ items: mo(e.items, t, i),
2447
2457
  labelStyle: st(e.labelStyle, (n = (o = a[t]) == null ? void 0 : o.labelStyle) == null ? "number" : n)
2448
2458
  };
2449
2459
  });
2450
2460
  }
2451
- function lo(e) {
2452
- return uo(e).map((e, t) => mo(t, e.labelStyle));
2453
- }
2454
2461
  function uo(e) {
2455
- return Ze(e.config.columns);
2462
+ return fo(e).map((e, t) => ho(t, e.labelStyle));
2456
2463
  }
2457
2464
  function fo(e) {
2465
+ return Ze(e.config.columns);
2466
+ }
2467
+ function po(e) {
2458
2468
  var t, n;
2459
2469
  return (t = (n = Ze([])[e]) == null ? void 0 : n.labelStyle) == null ? "number" : t;
2460
2470
  }
2461
- function po(e, t, n) {
2471
+ function mo(e, t, n) {
2462
2472
  let r = e.map((e, r) => ({
2463
2473
  content: e.content,
2464
- itemId: ko(e.itemId || Mo(t, r), n)
2474
+ itemId: Ao(e.itemId || No(t, r), n)
2465
2475
  }));
2466
- return r.length > 0 ? r : ho(t, n);
2476
+ return r.length > 0 ? r : go(t, n);
2467
2477
  }
2468
- function mo(e, t) {
2478
+ function ho(e, t) {
2469
2479
  let n = /* @__PURE__ */ new Set();
2470
2480
  return {
2471
- columnId: jo(e),
2472
- items: ho(e, n),
2481
+ columnId: Mo(e),
2482
+ items: go(e, n),
2473
2483
  labelStyle: t
2474
2484
  };
2475
2485
  }
2476
- function ho(e, t) {
2477
- return Array.from({ length: di }, (n, r) => ({
2486
+ function go(e, t) {
2487
+ return Array.from({ length: fi }, (n, r) => ({
2478
2488
  content: M(`\u8fde\u7ebf\u9879 ${r + 1}`),
2479
- itemId: ko(Mo(e, r), t)
2489
+ itemId: Ao(No(e, r), t)
2480
2490
  }));
2481
2491
  }
2482
- function go(e, t) {
2483
- return Ye(e, Oo(t));
2484
- }
2485
2492
  function _o(e, t) {
2486
- let n = e.length > 0 ? e : vo(t), r = /* @__PURE__ */ new Set(), i = /* @__PURE__ */ new Set(), a = xt(t.config.columns);
2493
+ return Ye(e, ko(t));
2494
+ }
2495
+ function vo(e, t) {
2496
+ let n = e.length > 0 ? e : yo(t), r = /* @__PURE__ */ new Set(), i = /* @__PURE__ */ new Set(), a = xt(t.config.columns);
2487
2497
  return n.slice(0, dt.max).map((e, t) => {
2488
2498
  var n, o;
2489
2499
  return {
2490
- columnId: ko(e.columnId || No(t), r),
2491
- items: po(e.items, t, i),
2500
+ columnId: Ao(e.columnId || Po(t), r),
2501
+ items: mo(e.items, t, i),
2492
2502
  labelStyle: st(e.labelStyle, (n = (o = a[t]) == null ? void 0 : o.labelStyle) == null ? "number" : n)
2493
2503
  };
2494
2504
  });
2495
2505
  }
2496
- function vo(e) {
2497
- return xt(e.config.columns).map((e, t) => yo(t, e.labelStyle));
2506
+ function yo(e) {
2507
+ return xt(e.config.columns).map((e, t) => bo(t, e.labelStyle));
2498
2508
  }
2499
- function yo(e, t) {
2509
+ function bo(e, t) {
2500
2510
  let n = /* @__PURE__ */ new Set();
2501
2511
  return {
2502
- columnId: No(e),
2503
- items: Array.from({ length: di }, (t, r) => ({
2512
+ columnId: Po(e),
2513
+ items: Array.from({ length: fi }, (t, r) => ({
2504
2514
  content: M(`\u5339\u914d\u9879 ${r + 1}`),
2505
- itemId: ko(Po(e, r), n)
2515
+ itemId: Ao(Fo(e, r), n)
2506
2516
  })),
2507
2517
  labelStyle: t
2508
2518
  };
2509
2519
  }
2510
- function bo(e, t) {
2511
- return yt(e, Oo(t));
2512
- }
2513
2520
  function xo(e, t) {
2521
+ return yt(e, ko(t));
2522
+ }
2523
+ function So(e, t) {
2514
2524
  let n = new Set(t);
2515
2525
  return e.filter((e, t, r) => n.has(e) && r.indexOf(e) === t);
2516
2526
  }
2517
- function So(e) {
2518
- let t = /* @__PURE__ */ new Set(), n = (e == null ? [] : e).map((e, n) => wo(Do(e.id || Eo(n), t), e.content)).filter((e) => e.id.length > 0);
2519
- return n.length > 0 ? n : To();
2527
+ function Co(e) {
2528
+ let t = /* @__PURE__ */ new Set(), n = (e == null ? [] : e).map((e, n) => To(Oo(e.id || Do(n), t), e.content)).filter((e) => e.id.length > 0);
2529
+ return n.length > 0 ? n : Eo();
2520
2530
  }
2521
- function Co(e, t) {
2531
+ function wo(e, t) {
2522
2532
  let n = t.map((e) => e.id), r = new Set(n), i = e.filter((e, t, n) => r.has(e) && n.indexOf(e) === t);
2523
2533
  return [...i, ...n.filter((e) => !i.includes(e))];
2524
2534
  }
2525
- function wo(e, t = M()) {
2535
+ function To(e, t = M()) {
2526
2536
  return {
2527
2537
  content: t,
2528
2538
  id: e
2529
2539
  };
2530
2540
  }
2531
- function To() {
2541
+ function Eo() {
2532
2542
  return [
2533
2543
  "\u6b65\u9aa4\u4e00",
2534
2544
  "\u6b65\u9aa4\u4e8c",
2535
2545
  "\u6b65\u9aa4\u4e09"
2536
- ].map((e, t) => wo(Eo(t), M(e)));
2546
+ ].map((e, t) => To(Do(t), M(e)));
2537
2547
  }
2538
- function Eo(e) {
2548
+ function Do(e) {
2539
2549
  return `option_${e + 1}`;
2540
2550
  }
2541
- function Do(e, t) {
2551
+ function Oo(e, t) {
2542
2552
  let n = e, r = 2;
2543
2553
  for (; t.has(n);) n = `${e}_${r}`, r += 1;
2544
2554
  return t.add(n), n;
2545
2555
  }
2546
- function Oo(e) {
2556
+ function ko(e) {
2547
2557
  return e.reduce((e, t, n) => (t.items.forEach((t) => e.set(t.itemId, n)), e), /* @__PURE__ */ new Map());
2548
2558
  }
2549
- function ko(e, t) {
2559
+ function Ao(e, t) {
2550
2560
  let n = e || "line_connect_item", r = n, i = 2;
2551
2561
  for (; t.has(r);) r = `${n}_${i}`, i += 1;
2552
2562
  return t.add(r), r;
2553
2563
  }
2554
- function Ao(e) {
2564
+ function jo(e) {
2555
2565
  return e.reduce((e, t) => [...e, ...t.items.map((e) => e.itemId)], []);
2556
2566
  }
2557
- function jo(e) {
2567
+ function Mo(e) {
2558
2568
  return `column_${e + 1}`;
2559
2569
  }
2560
- function Mo(e, t) {
2570
+ function No(e, t) {
2561
2571
  return `column_${e + 1}_item_${t + 1}`;
2562
2572
  }
2563
- function No(e) {
2573
+ function Po(e) {
2564
2574
  return e === 0 ? "left" : "right";
2565
2575
  }
2566
- function Po(e, t) {
2567
- return `${No(e)}_${t + 1}`;
2576
+ function Fo(e, t) {
2577
+ return `${Po(e)}_${t + 1}`;
2568
2578
  }
2569
- function Fo(e) {
2579
+ function Io(e) {
2570
2580
  return `blank_${e}`;
2571
2581
  }
2572
- function Io(e, t) {
2582
+ function Lo(e, t) {
2573
2583
  return `${t}${e + 1}`;
2574
2584
  }
2575
- function Lo(e) {
2576
- return Fo(e.reduce((e, t) => {
2585
+ function Ro(e) {
2586
+ return Io(e.reduce((e, t) => {
2577
2587
  let n = (/* @__PURE__ */ RegExp("^blank_(\\d+)$", "u")).exec(t), r = n != null && n[1] ? Number(n[1]) : -1;
2578
2588
  return Math.max(e, r);
2579
2589
  }, -1) + 1);
@@ -2581,108 +2591,112 @@ function Lo(e) {
2581
2591
  function N(e) {
2582
2592
  return e.text.trim() === "";
2583
2593
  }
2584
- function Ro(e) {
2594
+ function zo(e) {
2585
2595
  return [{
2586
2596
  children: [{ text: e }],
2587
2597
  type: "paragraph"
2588
2598
  }];
2589
2599
  }
2590
- function zo(e) {
2591
- return e.map((e) => Bo(e)).filter((e) => e.length > 0).join("\n");
2592
- }
2593
2600
  function Bo(e) {
2594
- return Wo(e) ? e.text : Uo(e) ? e.type === "blank" ? `[${Ho(e, "label") || Ho(e, "blankId") || "Blank"}]` : e.children.map((e) => Bo(e)).join("") : "";
2601
+ return e.map((e) => Vo(e)).filter((e) => e.length > 0).join("\n");
2595
2602
  }
2596
- function Vo(e, t) {
2603
+ function Vo(e) {
2604
+ return Go(e) ? e.text : Wo(e) ? e.type === "blank" ? `[${Uo(e, "label") || Uo(e, "blankId") || "Blank"}]` : e.children.map((e) => Vo(e)).join("") : "";
2605
+ }
2606
+ function Ho(e, t) {
2597
2607
  e.forEach((e) => {
2598
- t(e), Uo(e) && Vo(e.children, t);
2608
+ t(e), Wo(e) && Ho(e.children, t);
2599
2609
  });
2600
2610
  }
2601
- function Ho(e, t) {
2611
+ function Uo(e, t) {
2602
2612
  let n = t === "blankId" ? e.blankId : e.label;
2603
2613
  return typeof n == "string" ? n : "";
2604
2614
  }
2605
- function Uo(e) {
2615
+ function Wo(e) {
2606
2616
  return typeof e == "object" && !!e && "type" in e && typeof e.type == "string" && "children" in e && Array.isArray(e.children);
2607
2617
  }
2608
- function Wo(e) {
2618
+ function Go(e) {
2609
2619
  return typeof e == "object" && !!e && "text" in e && typeof e.text == "string";
2610
2620
  }
2611
- function Go(e) {
2621
+ function Ko(e) {
2612
2622
  return Array.isArray(e) && e.length > 0;
2613
2623
  }
2614
- function Ko(e, t = [ti]) {
2615
- return Go(e) ? n(e, { plugins: t }) : Ro("");
2616
- }
2617
- function qo(e) {
2618
- return e.type === "richText" ? N(e.content) : e.type === "textMarker" ? N(e.content) && e.markers.length === 0 : e.type === "classification" ? es(e) : e.type === "fill" ? e.answers.every(Zo) : Jo(e);
2624
+ function qo(e, t = [ni]) {
2625
+ return Ko(e) ? n(e, { plugins: t }) : zo("");
2619
2626
  }
2620
2627
  function Jo(e) {
2628
+ return e.type === "richText" ? N(e.content) : e.type === "textMarker" ? N(e.content) && e.markers.length === 0 : e.type === "classification" ? ts(e) : e.type === "fill" ? e.answers.every(Qo) : Yo(e);
2629
+ }
2630
+ function Yo(e) {
2621
2631
  switch (e.type) {
2622
- case "inlineFill": return Yo(e);
2623
- case "wordBuilder": return Xo(e);
2624
- case "choice": return $o(e);
2632
+ case "inlineFill": return Xo(e);
2633
+ case "wordBuilder": return Zo(e);
2634
+ case "choice": return es(e);
2625
2635
  case "judgement": return e.answers.length === 0;
2626
- case "lineConnect": return ts(e);
2627
- case "matching": return rs(e);
2628
- case "ordering": return is(e);
2636
+ case "lineConnect": return ns(e);
2637
+ case "matching": return is(e);
2638
+ case "ordering": return as(e);
2629
2639
  }
2630
2640
  }
2631
- function Yo(e) {
2641
+ function Xo(e) {
2632
2642
  var t, n, r, i;
2633
- return N(e.content) && e.answers.every(Zo) && ((t = (n = e.candidateOptions) == null ? void 0 : n.every((e) => N(e.content))) == null ? !0 : t) && ((r = (i = e.blankOptionGroups) == null ? void 0 : i.every(Qo)) == null ? !0 : r);
2643
+ return N(e.content) && e.answers.every(Qo) && ((t = (n = e.candidateOptions) == null ? void 0 : n.every((e) => N(e.content))) == null ? !0 : t) && ((r = (i = e.blankOptionGroups) == null ? void 0 : i.every($o)) == null ? !0 : r);
2634
2644
  }
2635
- function Xo(e) {
2645
+ function Zo(e) {
2636
2646
  return N(e.content) && e.candidateOptions.every((e) => e.trim() === "") && Object.values(e.answers).every((e) => e.trim() === "");
2637
2647
  }
2638
- function Zo(e) {
2648
+ function Qo(e) {
2639
2649
  return "answerOptionIds" in e ? e.answerOptionIds.length === 0 : "answerOptionId" in e ? e.answerOptionId.length === 0 : e.answerPools.every(N);
2640
2650
  }
2641
- function Qo(e) {
2651
+ function $o(e) {
2642
2652
  var t;
2643
2653
  return (t = e == null ? void 0 : e.options.every((e) => N(e.content))) == null ? !0 : t;
2644
2654
  }
2645
- function $o(e) {
2646
- return e.answers.optionIds.length === 0 && e.options.every((e) => e.cells.every(N));
2647
- }
2648
2655
  function es(e) {
2649
- return Object.keys(e.answers).length === 0 && e.categories.every((e) => N(e.content)) && e.items.every((e) => N(e.content));
2656
+ return e.answers.optionIds.length === 0 && e.options.every((e) => e.cells.every(N));
2650
2657
  }
2651
2658
  function ts(e) {
2652
- return ns(e);
2659
+ return Object.keys(e.answers).length === 0 && e.categories.every((e) => N(e.content)) && e.items.every((e) => N(e.content));
2653
2660
  }
2654
2661
  function ns(e) {
2655
- return Object.keys(e.answers).length === 0 && e.columns.every((e) => e.items.every((e) => N(e.content)));
2662
+ return rs(e);
2656
2663
  }
2657
2664
  function rs(e) {
2658
- return ns(e);
2665
+ return Object.keys(e.answers).length === 0 && e.columns.every((e) => e.items.every((e) => N(e.content)));
2659
2666
  }
2660
2667
  function is(e) {
2661
- return e.answers.length === 0 && e.sortOptions.every((e) => N(e.content));
2668
+ return rs(e);
2662
2669
  }
2663
2670
  function as(e) {
2664
- return e.length ? e : [M()];
2671
+ return e.answers.length === 0 && e.sortOptions.every((e) => N(e.content));
2665
2672
  }
2666
2673
  function os(e) {
2674
+ return e.length ? e : [M()];
2675
+ }
2676
+ function ss(e) {
2667
2677
  return e.type === "richText" ? {
2668
2678
  content: e.content,
2679
+ elementKey: e.elementKey,
2669
2680
  type: "richText"
2670
2681
  } : e.type === "ordering" ? {
2671
- answers: Co(e.answers, e.sortOptions),
2672
- sortOptions: So(e.sortOptions),
2682
+ answers: wo(e.answers, e.sortOptions),
2683
+ elementKey: e.elementKey,
2684
+ sortOptions: Co(e.sortOptions),
2673
2685
  type: "ordering"
2674
2686
  } : e.type === "classification" ? {
2675
2687
  answers: e.answers,
2676
2688
  categories: e.categories,
2689
+ elementKey: e.elementKey,
2677
2690
  items: e.items,
2678
2691
  type: "classification"
2679
2692
  } : e.type === "fill" ? {
2680
2693
  answers: e.answers,
2681
2694
  blanks: e.blanks,
2695
+ elementKey: e.elementKey,
2682
2696
  type: "fill"
2683
- } : ss(e);
2697
+ } : cs(e);
2684
2698
  }
2685
- function ss(e) {
2699
+ function cs(e) {
2686
2700
  switch (e.type) {
2687
2701
  case "inlineFill": return gs(e);
2688
2702
  case "wordBuilder": return {
@@ -2690,69 +2704,72 @@ function ss(e) {
2690
2704
  blanks: e.blanks,
2691
2705
  candidateOptions: e.candidateOptions,
2692
2706
  content: e.content,
2707
+ elementKey: e.elementKey,
2693
2708
  type: "wordBuilder"
2694
2709
  };
2695
2710
  case "choice": return _s(e);
2696
2711
  case "judgement": return {
2697
2712
  answers: e.answers,
2713
+ elementKey: e.elementKey,
2698
2714
  type: "judgement"
2699
2715
  };
2700
2716
  case "lineConnect": return {
2701
2717
  answers: e.answers,
2702
2718
  columns: e.columns,
2719
+ elementKey: e.elementKey,
2703
2720
  type: "lineConnect"
2704
2721
  };
2705
2722
  case "matching": return {
2706
2723
  answers: e.answers,
2707
2724
  columns: e.columns,
2725
+ elementKey: e.elementKey,
2708
2726
  type: "matching"
2709
2727
  };
2710
2728
  case "textMarker": return {
2711
- answers: xo(e.answers, e.markers),
2712
- content: gi(e.content.text, e.content.json, e.content.html),
2729
+ answers: So(e.answers, e.markers),
2730
+ content: _i(e.content.text, e.content.json, e.content.html),
2731
+ elementKey: e.elementKey,
2713
2732
  markers: e.markers,
2714
2733
  type: "textMarker"
2715
2734
  };
2716
2735
  }
2717
2736
  }
2718
- function cs(e, t, n) {
2719
- let r = k(k({}, e), {}, { elementKey: t.elementKey });
2720
- switch (r.type) {
2721
- case "choice": return ls(r, t, n);
2722
- case "wordBuilder": return us(r, t, n);
2723
- case "textMarker": return ds(r, t, n);
2724
- case "ordering": return fs(r, t, n);
2725
- case "classification": return ps(r, t, n);
2726
- default: return r;
2727
- }
2728
- }
2729
2737
  function ls(e, t, n) {
2730
- return t.type === "choice" ? ga(e, t, n) : e;
2738
+ switch (e.type) {
2739
+ case "choice": return us(e, t, n);
2740
+ case "wordBuilder": return ds(e, t, n);
2741
+ case "textMarker": return fs(e, t, n);
2742
+ case "ordering": return ps(e, t, n);
2743
+ case "classification": return ms(e, t, n);
2744
+ default: return e;
2745
+ }
2731
2746
  }
2732
2747
  function us(e, t, n) {
2733
- return t.type === "wordBuilder" ? Ri(e, n, t) : e;
2748
+ return t.type === "choice" ? _a(e, t, n) : e;
2734
2749
  }
2735
2750
  function ds(e, t, n) {
2736
- return t.type === "textMarker" ? Li(e, e.content, n) : e;
2751
+ return t.type === "wordBuilder" ? zi(e, n, t) : e;
2737
2752
  }
2738
2753
  function fs(e, t, n) {
2739
- return t.type === "ordering" ? Wa(e, n) : e;
2754
+ return t.type === "textMarker" ? Ri(e, e.content, n) : e;
2740
2755
  }
2741
2756
  function ps(e, t, n) {
2742
- return t.type === "classification" ? Ia(e, n) : e;
2757
+ return t.type === "ordering" ? Ga(e, n) : e;
2743
2758
  }
2744
- function ms(e, t) {
2745
- return k(k({}, e), {}, { extraKey: t });
2759
+ function ms(e, t, n) {
2760
+ return t.type === "classification" ? La(e, n) : e;
2746
2761
  }
2747
2762
  function hs(e) {
2748
2763
  return {
2749
2764
  content: e.content,
2765
+ extraKey: e.extraKey,
2750
2766
  type: e.type
2751
2767
  };
2752
2768
  }
2753
2769
  function gs(e) {
2754
2770
  return k(k(k({ answers: e.answers }, e.blankOptionGroups ? { blankOptionGroups: e.blankOptionGroups } : {}), {}, { blanks: e.blanks }, e.candidateOptions ? { candidateOptions: e.candidateOptions } : {}), {}, {
2755
2771
  content: e.content,
2772
+ elementKey: e.elementKey,
2756
2773
  type: "inlineFill"
2757
2774
  });
2758
2775
  }
@@ -2760,6 +2777,7 @@ function _s(e) {
2760
2777
  return {
2761
2778
  answers: e.answers,
2762
2779
  columns: e.columns,
2780
+ elementKey: e.elementKey,
2763
2781
  options: e.options,
2764
2782
  type: "choice"
2765
2783
  };
@@ -2819,7 +2837,7 @@ var Cs = {
2819
2837
  label: "Blank {{index}}",
2820
2838
  memberDetach: "Blank {{index}} Detach",
2821
2839
  newAnswerGroup: "New Answer Group",
2822
- optionGroupsTitle: "Option Groups",
2840
+ perBlankOptionsTitle: "Option Groups",
2823
2841
  sharedAnswer: "Shared Answer",
2824
2842
  shortLabel: "Blank {{index}}",
2825
2843
  singleAnswer: "Single Answer"
@@ -3004,7 +3022,7 @@ var Cs = {
3004
3022
  label: "\u7b2c {{index}} \u7a7a",
3005
3023
  memberDetach: "\u7b2c {{index}} \u7a7a \u62c6\u51fa",
3006
3024
  newAnswerGroup: "\u65b0\u5efa\u7b54\u6848\u7ec4",
3007
- optionGroupsTitle: "\u9009\u9879\u7ec4",
3025
+ perBlankOptionsTitle: "\u9009\u9879\u7ec4",
3008
3026
  sharedAnswer: "\u5171\u7528\u7b54\u6848",
3009
3027
  shortLabel: "\u7a7a {{index}}",
3010
3028
  singleAnswer: "\u5355\u72ec\u7b54\u6848"
@@ -3511,25 +3529,25 @@ function R({ controls: e, disabled: t, editorRef: n, label: r, onChange: i, plac
3511
3529
  //#endregion
3512
3530
  //#region src/question/content-editor/QuestionContentBlankGroupEditor.tsx
3513
3531
  function Js({ disabled: e, hasAnswer: t, item: n, onChange: r, richTextControls: s, translator: c }) {
3514
- let { t: l } = c, [u, d] = m(null), [f, p] = m(null), h = t ? ea(n.answers, n.blanks) : [], g = ta(h);
3532
+ let { t: l } = c, [u, d] = m(null), [f, p] = m(null), h = t ? ta(n.answers, n.blanks) : [], g = na(h);
3515
3533
  function _(e) {
3516
- r(k(k({}, e), {}, { answers: t ? ea(e.answers, e.blanks) : [] }));
3534
+ r(k(k({}, e), {}, { answers: t ? ta(e.answers, e.blanks) : [] }));
3517
3535
  }
3518
3536
  function v(e, t, r) {
3519
3537
  let i = Ys(h, e);
3520
- i && _(aa(k(k({}, n), {}, { answers: h }), e, i.answerPools.map((e, n) => n === t ? r : e)));
3538
+ i && _(oa(k(k({}, n), {}, { answers: h }), e, i.answerPools.map((e, n) => n === t ? r : e)));
3521
3539
  }
3522
3540
  function y(e) {
3523
3541
  let t = Ys(h, e);
3524
- t && _(aa(k(k({}, n), {}, { answers: h }), e, [...t.answerPools, M()]));
3542
+ t && _(oa(k(k({}, n), {}, { answers: h }), e, [...t.answerPools, M()]));
3525
3543
  }
3526
3544
  function b(e, t) {
3527
3545
  let r = Ys(h, e);
3528
- r && _(aa(k(k({}, n), {}, { answers: h }), e, r.answerPools.filter((e, n) => n !== t)));
3546
+ r && _(oa(k(k({}, n), {}, { answers: h }), e, r.answerPools.filter((e, n) => n !== t)));
3529
3547
  }
3530
3548
  function x(e, t) {
3531
3549
  if (t === "__single__") {
3532
- _(ia(k(k({}, n), {}, { answers: h }), e));
3550
+ _(aa(k(k({}, n), {}, { answers: h }), e));
3533
3551
  return;
3534
3552
  }
3535
3553
  if (t === "__new__") {
@@ -3537,7 +3555,7 @@ function Js({ disabled: e, hasAnswer: t, item: n, onChange: r, richTextControls:
3537
3555
  return;
3538
3556
  }
3539
3557
  let r = Number(t.replace("group:", ""));
3540
- Number.isNaN(r) || _(na(k(k({}, n), {}, { answers: h }), e, r));
3558
+ Number.isNaN(r) || _(ra(k(k({}, n), {}, { answers: h }), e, r));
3541
3559
  }
3542
3560
  function S(e) {
3543
3561
  return h.filter((e) => e.blankIds.length === 1).map((e) => e.blankIds[0]).filter((t) => !!t && t !== e);
@@ -3550,7 +3568,7 @@ function Js({ disabled: e, hasAnswer: t, item: n, onChange: r, richTextControls:
3550
3568
  d(null), p(null);
3551
3569
  }
3552
3570
  function T() {
3553
- !u || !f || (_(ra(k(k({}, n), {}, { answers: h }), u, f)), w());
3571
+ !u || !f || (_(ia(k(k({}, n), {}, { answers: h }), u, f)), w());
3554
3572
  }
3555
3573
  function ee(t, n) {
3556
3574
  return /* @__PURE__ */ o("div", {
@@ -3630,7 +3648,7 @@ function Js({ disabled: e, hasAnswer: t, item: n, onChange: r, richTextControls:
3630
3648
  "aria-label": l("questionContentEditor.actions.deleteBlank", { index: r + 1 }),
3631
3649
  danger: !0,
3632
3650
  disabled: e || n.blanks.length <= 1,
3633
- onClick: () => _($i(k(k({}, n), {}, { answers: h }), t)),
3651
+ onClick: () => _(ea(k(k({}, n), {}, { answers: h }), t)),
3634
3652
  children: l("questionContentEditor.actions.deleteBlank", { index: r + 1 })
3635
3653
  })
3636
3654
  ]
@@ -3648,7 +3666,7 @@ function Js({ disabled: e, hasAnswer: t, item: n, onChange: r, richTextControls:
3648
3666
  children: l("questionContentEditor.blank.answerGroup", { index: i + 1 })
3649
3667
  }), t.blankIds.map((t) => /* @__PURE__ */ a(F, {
3650
3668
  disabled: e,
3651
- onClick: () => _(ia(k(k({}, n), {}, { answers: h }), t)),
3669
+ onClick: () => _(aa(k(k({}, n), {}, { answers: h }), t)),
3652
3670
  size: "small",
3653
3671
  children: l("questionContentEditor.blank.memberDetach", { index: n.blanks.indexOf(t) + 1 })
3654
3672
  }, t))]
@@ -3736,18 +3754,18 @@ var z = {
3736
3754
  //#endregion
3737
3755
  //#region src/question/content-editor/QuestionContentClassificationEditor.tsx
3738
3756
  function Xs({ disabled: e, hasAnswer: t, item: n, onChange: r, richTextControls: i, translator: s }) {
3739
- let { t: c } = s, l = Ia(n, t);
3757
+ let { t: c } = s, l = La(n, t);
3740
3758
  function u(e) {
3741
- r(Ia(e, t));
3759
+ r(La(e, t));
3742
3760
  }
3743
3761
  function d(e, t) {
3744
- u(za(l, e, t));
3762
+ u(Ba(l, e, t));
3745
3763
  }
3746
3764
  function f(e, t) {
3747
- u(Ha(l, e, t));
3765
+ u(Ua(l, e, t));
3748
3766
  }
3749
3767
  function p(e, t) {
3750
- u(k(k({}, l), {}, { answers: Ua(l.answers, e, t == null ? "" : t) }));
3768
+ u(k(k({}, l), {}, { answers: Wa(l.answers, e, t == null ? "" : t) }));
3751
3769
  }
3752
3770
  return /* @__PURE__ */ o("div", {
3753
3771
  className: z.board,
@@ -3769,7 +3787,7 @@ function Xs({ disabled: e, hasAnswer: t, item: n, onChange: r, richTextControls:
3769
3787
  className: z["primary-action"],
3770
3788
  disabled: e,
3771
3789
  icon: "+",
3772
- onClick: () => u(La(l)),
3790
+ onClick: () => u(Ra(l)),
3773
3791
  children: c("questionContentEditor.classification.addCategory")
3774
3792
  })]
3775
3793
  }), /* @__PURE__ */ a("div", {
@@ -3797,7 +3815,7 @@ function Xs({ disabled: e, hasAnswer: t, item: n, onChange: r, richTextControls:
3797
3815
  Zs({
3798
3816
  ariaLabel: c("questionContentEditor.classification.deleteCategory", { index: n + 1 }),
3799
3817
  disabled: e || l.categories.length <= 1,
3800
- onClick: () => u(Ra(l, t.id))
3818
+ onClick: () => u(za(l, t.id))
3801
3819
  })
3802
3820
  ]
3803
3821
  })
@@ -3821,7 +3839,7 @@ function Xs({ disabled: e, hasAnswer: t, item: n, onChange: r, richTextControls:
3821
3839
  className: z["primary-action"],
3822
3840
  disabled: e,
3823
3841
  icon: "+",
3824
- onClick: () => u(Ba(l)),
3842
+ onClick: () => u(Va(l)),
3825
3843
  children: c("questionContentEditor.classification.addCard")
3826
3844
  })]
3827
3845
  }), /* @__PURE__ */ a("div", {
@@ -3846,7 +3864,7 @@ function Xs({ disabled: e, hasAnswer: t, item: n, onChange: r, richTextControls:
3846
3864
  }), Zs({
3847
3865
  ariaLabel: c("questionContentEditor.classification.deleteCard", { index: r + 1 }),
3848
3866
  disabled: e || l.items.length <= 1,
3849
- onClick: () => u(Va(l, n.id))
3867
+ onClick: () => u(Ha(l, n.id))
3850
3868
  })]
3851
3869
  }), t ? /* @__PURE__ */ o("label", {
3852
3870
  className: z["field-stack"],
@@ -3891,7 +3909,7 @@ function Zs({ ariaLabel: e, disabled: t, onClick: n }) {
3891
3909
  //#endregion
3892
3910
  //#region src/question/content-editor/QuestionContentFillTextEditor.tsx
3893
3911
  function Qs({ disabled: e, element: t, hasAnswer: n, item: r, onChange: s, richTextControls: c, title: l, translator: u }) {
3894
- let { t: d } = u, f = p(null), [h, g] = m({}), [_, v] = m(null), [y, b] = m(null), x = zi(r, t, n), S = {
3912
+ let { t: d } = u, f = p(null), [h, g] = m({}), [_, v] = m(null), [y, b] = m(null), x = Bi(r, t, n), S = {
3895
3913
  answers: x.answers.filter((e) => "answerPools" in e),
3896
3914
  blanks: x.blanks,
3897
3915
  elementKey: x.elementKey,
@@ -3899,14 +3917,14 @@ function Qs({ disabled: e, element: t, hasAnswer: n, item: r, onChange: s, richT
3899
3917
  };
3900
3918
  function C() {
3901
3919
  var e;
3902
- let t = Pi(r.blanks);
3920
+ let t = Fi(r.blanks);
3903
3921
  (e = f.current) == null || e.insertNode("blank", {
3904
3922
  blankId: t,
3905
3923
  label: d("questionContentEditor.blank.shortLabel", { index: r.blanks.length + 1 })
3906
3924
  });
3907
3925
  }
3908
3926
  function w(e) {
3909
- s(zi(e, t, n));
3927
+ s(Bi(e, t, n));
3910
3928
  }
3911
3929
  function T(e) {
3912
3930
  e.type === "fill" && w(k(k({}, x), {}, {
@@ -3915,10 +3933,10 @@ function Qs({ disabled: e, element: t, hasAnswer: n, item: r, onChange: s, richT
3915
3933
  }));
3916
3934
  }
3917
3935
  function ee(e) {
3918
- w(k(k({}, x), {}, { candidateOptions: Vi(e, "option_") }));
3936
+ w(k(k({}, x), {}, { candidateOptions: Hi(e, "option_") }));
3919
3937
  }
3920
3938
  function E(e, t) {
3921
- let n = Ji(x.blankOptionGroups, x.blanks).map((n) => n.blankId === e ? k(k({}, t), {}, { blankId: e }) : n);
3939
+ let n = Yi(x.blankOptionGroups, x.blanks).map((n) => n.blankId === e ? k(k({}, t), {}, { blankId: e }) : n);
3922
3940
  w(k(k({}, x), {}, { blankOptionGroups: n }));
3923
3941
  }
3924
3942
  function D() {
@@ -3937,7 +3955,7 @@ function Qs({ disabled: e, element: t, hasAnswer: n, item: r, onChange: s, richT
3937
3955
  t >= i.answerOptionIds.length && n && g((e) => k(k({}, e), {}, { [a]: Math.max(0, $s(e, a) - 1) })), O(r.map((t, n) => n === e ? k(k({}, t), {}, { answerOptionIds: o }) : t));
3938
3956
  }
3939
3957
  function re(e) {
3940
- let t = Ji(x.blankOptionGroups, x.blanks).find((t) => t.blankId === e);
3958
+ let t = Yi(x.blankOptionGroups, x.blanks).find((t) => t.blankId === e);
3941
3959
  if (!t) throw Error(`Missing option group for blank ${e}.`);
3942
3960
  return t;
3943
3961
  }
@@ -4034,7 +4052,7 @@ function Qs({ disabled: e, element: t, hasAnswer: n, item: r, onChange: s, richT
4034
4052
  return /* @__PURE__ */ a("div", {
4035
4053
  className: "flex min-w-0 flex-col gap-2",
4036
4054
  children: t.map((r, i) => {
4037
- let s = Si("upperAlpha", i);
4055
+ let s = Ci("upperAlpha", i);
4038
4056
  return /* @__PURE__ */ o("div", {
4039
4057
  className: "grid min-w-0 grid-cols-[2rem_minmax(0,1fr)_auto] items-center gap-2",
4040
4058
  children: [
@@ -4076,7 +4094,7 @@ function Qs({ disabled: e, element: t, hasAnswer: n, item: r, onChange: s, richT
4076
4094
  }), /* @__PURE__ */ a(F, {
4077
4095
  disabled: e,
4078
4096
  icon: "+",
4079
- onClick: () => n([...t, Bi(ve(t, i))]),
4097
+ onClick: () => n([...t, Vi(ve(t, i))]),
4080
4098
  size: "small",
4081
4099
  children: d("questionContentEditor.actions.addCandidateOption")
4082
4100
  })]
@@ -4093,8 +4111,8 @@ function Qs({ disabled: e, element: t, hasAnswer: n, item: r, onChange: s, richT
4093
4111
  return new Set(D().filter((e) => e.blankIds.every((e) => !n.has(e))).reduce((e, t) => [...e, ...t.answerOptionIds], []));
4094
4112
  }
4095
4113
  function Ce(t, n) {
4096
- let r = te(t), i = Yi(t), s = i.length ? [...i, ...Array.from({ length: $s(h, r) }, () => "")] : Array.from({ length: $s(h, r) + 1 }, () => ""), c = Se(t), l = xe().map((e, t) => {
4097
- let n = Si("upperAlpha", t), r = i.includes(e.optionId);
4114
+ let r = te(t), i = Xi(t), s = i.length ? [...i, ...Array.from({ length: $s(h, r) }, () => "")] : Array.from({ length: $s(h, r) + 1 }, () => ""), c = Se(t), l = xe().map((e, t) => {
4115
+ let n = Ci("upperAlpha", t), r = i.includes(e.optionId);
4098
4116
  return {
4099
4117
  disabled: c.has(e.optionId) && !r,
4100
4118
  label: `${n}. ${e.content.text || d("questionContentEditor.fields.candidateOption", { index: t + 1 })}`,
@@ -4215,7 +4233,7 @@ function Qs({ disabled: e, element: t, hasAnswer: n, item: r, onChange: s, richT
4215
4233
  }
4216
4234
  function Me(t, r) {
4217
4235
  let i = ke(t.blankId), s = t.options.map((e, t) => ({
4218
- label: `${Si("upperAlpha", t)}. ${e.content.text || d("questionContentEditor.fields.candidateOption", { index: t + 1 })}`,
4236
+ label: `${Ci("upperAlpha", t)}. ${e.content.text || d("questionContentEditor.fields.candidateOption", { index: t + 1 })}`,
4219
4237
  value: e.optionId
4220
4238
  }));
4221
4239
  return /* @__PURE__ */ o("section", {
@@ -4242,7 +4260,7 @@ function Qs({ disabled: e, element: t, hasAnswer: n, item: r, onChange: s, richT
4242
4260
  })]
4243
4261
  }) : null, /* @__PURE__ */ a(F, {
4244
4262
  disabled: e,
4245
- onClick: () => je(t.blankId, [...t.options, Bi(ve(t.options, `${t.blankId}_option_`))]),
4263
+ onClick: () => je(t.blankId, [...t.options, Vi(ve(t.options, `${t.blankId}_option_`))]),
4246
4264
  size: "small",
4247
4265
  children: d("questionContentEditor.actions.addBlankOption")
4248
4266
  })]
@@ -4255,12 +4273,12 @@ function Qs({ disabled: e, element: t, hasAnswer: n, item: r, onChange: s, richT
4255
4273
  var e;
4256
4274
  return /* @__PURE__ */ o(i, { children: [be((e = x.candidateOptions) == null ? [] : e, ee, d("questionContentEditor.fields.candidateOptions"), "option_"), n ? Oe() : null] });
4257
4275
  }
4258
- let r = Ji(x.blankOptionGroups, x.blanks);
4276
+ let r = Yi(x.blankOptionGroups, x.blanks);
4259
4277
  return /* @__PURE__ */ o("div", {
4260
4278
  className: "flex min-w-0 flex-col gap-3",
4261
4279
  children: [/* @__PURE__ */ a(I.Text, {
4262
4280
  strong: !0,
4263
- children: d("questionContentEditor.blank.optionGroupsTitle")
4281
+ children: d("questionContentEditor.blank.perBlankOptionsTitle")
4264
4282
  }), r.map(Me)]
4265
4283
  });
4266
4284
  }
@@ -4287,7 +4305,7 @@ function Qs({ disabled: e, element: t, hasAnswer: n, item: r, onChange: s, richT
4287
4305
  editorRef: f,
4288
4306
  label: d("questionContentEditor.fields.fillTextContent"),
4289
4307
  onChange: (e) => {
4290
- s(Fi(x, e, n, t));
4308
+ s(Ii(x, e, n, t));
4291
4309
  },
4292
4310
  placeholder: d("questionContentEditor.placeholders.fillTextContent"),
4293
4311
  value: x.content
@@ -4331,7 +4349,7 @@ function $s(e, t) {
4331
4349
  //#endregion
4332
4350
  //#region src/question/content-editor/QuestionContentJudgementGroupEditor.tsx
4333
4351
  function ec({ disabled: e, element: t, hasAnswer: n, item: r, onChange: i, translator: o }) {
4334
- let { t: s } = o, c = Ti(t.config.judgeAnswerMode), l = n ? r.answers.filter((e) => c.includes(e)).slice(0, 1) : [];
4352
+ let { t: s } = o, c = Ei(t.config.judgeAnswerMode), l = n ? r.answers.filter((e) => c.includes(e)).slice(0, 1) : [];
4335
4353
  function u(e) {
4336
4354
  i(k(k({}, r), {}, { answers: l.includes(e) ? [] : [e] }));
4337
4355
  }
@@ -4437,7 +4455,7 @@ var B = {
4437
4455
  "none"
4438
4456
  ];
4439
4457
  function pc({ disabled: e, element: t, hasAnswer: n, item: r, onChange: i, richTextControls: s, translator: c }) {
4440
- let { t: u } = c, [h, g] = m(null), [_, v] = m(null), y = p(null), b = p(/* @__PURE__ */ new Map()), x = ba(r, t, n), S = { gridTemplateColumns: `repeat(${x.columns.length}, minmax(16rem, 1fr))` }, C = f(() => JSON.stringify({
4458
+ let { t: u } = c, [h, g] = m(null), [_, v] = m(null), y = p(null), b = p(/* @__PURE__ */ new Map()), x = xa(r, t, n), S = { gridTemplateColumns: `repeat(${x.columns.length}, minmax(16rem, 1fr))` }, C = f(() => JSON.stringify({
4441
4459
  answers: x.answers,
4442
4460
  columns: x.columns.map((e) => e.items.map((e) => e.itemId))
4443
4461
  }), [x.answers, x.columns]), w = f(() => n ? ic(x, x.answers) : [], [n, x]), T = l(() => {
@@ -4487,13 +4505,13 @@ function pc({ disabled: e, element: t, hasAnswer: n, item: r, onChange: i, richT
4487
4505
  };
4488
4506
  }
4489
4507
  function E(e) {
4490
- i(ba(e, t, n));
4508
+ i(xa(e, t, n));
4491
4509
  }
4492
4510
  function D(e, t) {
4493
- E(Ea(x, e, t));
4511
+ E(Da(x, e, t));
4494
4512
  }
4495
4513
  function te(e, t) {
4496
- E(k(k({}, x), {}, { answers: Da(x.answers, e, t) }));
4514
+ E(k(k({}, x), {}, { answers: Oa(x.answers, e, t) }));
4497
4515
  }
4498
4516
  function O(t, r, i) {
4499
4517
  if (e || !n) return;
@@ -4529,7 +4547,7 @@ function pc({ disabled: e, element: t, hasAnswer: n, item: r, onChange: i, richT
4529
4547
  children: [/* @__PURE__ */ a(Ms, {
4530
4548
  "aria-label": u("questionContentEditor.lineConnect.labelStyle", { index: n + 1 }),
4531
4549
  disabled: e,
4532
- onChange: (e) => e ? E(Ca(x, t.columnId, e)) : void 0,
4550
+ onChange: (e) => e ? E(wa(x, t.columnId, e)) : void 0,
4533
4551
  options: fc.map((e) => ({
4534
4552
  label: u(`questionContentEditor.lineConnect.labels.${e}`),
4535
4553
  value: e
@@ -4540,7 +4558,7 @@ function pc({ disabled: e, element: t, hasAnswer: n, item: r, onChange: i, richT
4540
4558
  danger: !0,
4541
4559
  disabled: e || x.columns.length <= 2,
4542
4560
  icon: "\u00d7",
4543
- onClick: () => E(Sa(x, t.columnId)),
4561
+ onClick: () => E(Ca(x, t.columnId)),
4544
4562
  size: "small"
4545
4563
  })]
4546
4564
  })]
@@ -4553,7 +4571,7 @@ function pc({ disabled: e, element: t, hasAnswer: n, item: r, onChange: i, richT
4553
4571
  "aria-label": u("questionContentEditor.lineConnect.addItem", { index: n + 1 }),
4554
4572
  disabled: e,
4555
4573
  icon: "+",
4556
- onClick: () => E(wa(x, t.columnId)),
4574
+ onClick: () => E(Ta(x, t.columnId)),
4557
4575
  size: "small",
4558
4576
  children: u("questionContentEditor.lineConnect.addItem", { index: n + 1 })
4559
4577
  })
@@ -4561,7 +4579,7 @@ function pc({ disabled: e, element: t, hasAnswer: n, item: r, onChange: i, richT
4561
4579
  }, t.columnId);
4562
4580
  }
4563
4581
  function ie(t, r, i, c) {
4564
- let l = Ci(t.labelStyle, c), d = l ? `${l}. ${i.content.text}` : i.content.text, f = (h == null ? void 0 : h.itemId) === i.itemId, p = mc(x, i.itemId), m = hc(x, i.itemId), g = gc(p, m), _ = _c(n);
4582
+ let l = wi(t.labelStyle, c), d = l ? `${l}. ${i.content.text}` : i.content.text, f = (h == null ? void 0 : h.itemId) === i.itemId, p = mc(x, i.itemId), m = hc(x, i.itemId), g = gc(p, m), _ = _c(n);
4565
4583
  return /* @__PURE__ */ o("div", {
4566
4584
  className: vc(f, g),
4567
4585
  "data-testid": `line-connect-item-${i.itemId}`,
@@ -4588,7 +4606,7 @@ function pc({ disabled: e, element: t, hasAnswer: n, item: r, onChange: i, richT
4588
4606
  danger: !0,
4589
4607
  disabled: e || t.items.length <= 1,
4590
4608
  icon: "\u00d7",
4591
- onClick: () => E(Ta(x, i.itemId)),
4609
+ onClick: () => E(Ea(x, i.itemId)),
4592
4610
  size: "small"
4593
4611
  }),
4594
4612
  oe(r, i, c, d, f, m)
@@ -4673,7 +4691,7 @@ function pc({ disabled: e, element: t, hasAnswer: n, item: r, onChange: i, richT
4673
4691
  "aria-label": u("questionContentEditor.lineConnect.addColumn"),
4674
4692
  disabled: e || x.columns.length >= 5,
4675
4693
  icon: "+",
4676
- onClick: () => E(xa(x)),
4694
+ onClick: () => E(Sa(x)),
4677
4695
  children: u("questionContentEditor.lineConnect.addColumn")
4678
4696
  })
4679
4697
  ]
@@ -4717,7 +4735,7 @@ var bc = {
4717
4735
  "none"
4718
4736
  ];
4719
4737
  function Sc({ disabled: e, element: t, hasAnswer: n, item: r, onChange: i, richTextControls: s, translator: c }) {
4720
- let { t: u } = c, [h, g] = m(null), [_, v] = m(null), y = p(null), b = p(/* @__PURE__ */ new Map()), x = Oa(r, t, n), S = { gridTemplateColumns: `repeat(${x.columns.length}, minmax(16rem, 1fr))` }, C = f(() => n ? ic(x, x.answers, ft) : [], [n, x]), w = f(() => JSON.stringify({
4738
+ let { t: u } = c, [h, g] = m(null), [_, v] = m(null), y = p(null), b = p(/* @__PURE__ */ new Map()), x = ka(r, t, n), S = { gridTemplateColumns: `repeat(${x.columns.length}, minmax(16rem, 1fr))` }, C = f(() => n ? ic(x, x.answers, ft) : [], [n, x]), w = f(() => JSON.stringify({
4721
4739
  answers: x.answers,
4722
4740
  columns: x.columns.map((e) => e.items.map((e) => e.itemId))
4723
4741
  }), [x.answers, x.columns]), T = l(() => {
@@ -4767,10 +4785,10 @@ function Sc({ disabled: e, element: t, hasAnswer: n, item: r, onChange: i, richT
4767
4785
  };
4768
4786
  }
4769
4787
  function E(e) {
4770
- i(Oa(e, t, n));
4788
+ i(ka(e, t, n));
4771
4789
  }
4772
4790
  function D(e, t) {
4773
- E(Ma(x, e, t));
4791
+ E(Na(x, e, t));
4774
4792
  }
4775
4793
  function te(t, r, i) {
4776
4794
  if (e || !n) return;
@@ -4780,7 +4798,7 @@ function Sc({ disabled: e, element: t, hasAnswer: n, item: r, onChange: i, richT
4780
4798
  label: i
4781
4799
  }, o = h ? pt(h, a) : null;
4782
4800
  if (o) {
4783
- E(k(k({}, x), {}, { answers: Na(x.answers, o.fromItemId, o.toItemId) })), g(null);
4801
+ E(k(k({}, x), {}, { answers: Pa(x.answers, o.fromItemId, o.toItemId) })), g(null);
4784
4802
  return;
4785
4803
  }
4786
4804
  g(a);
@@ -4794,7 +4812,7 @@ function Sc({ disabled: e, element: t, hasAnswer: n, item: r, onChange: i, richT
4794
4812
  children: /* @__PURE__ */ a(Ms, {
4795
4813
  "aria-label": u("questionContentEditor.matching.labelStyle", { index: n + 1 }),
4796
4814
  disabled: e,
4797
- onChange: (e) => e ? E(ka(x, t.columnId, e)) : void 0,
4815
+ onChange: (e) => e ? E(Aa(x, t.columnId, e)) : void 0,
4798
4816
  options: xc.map((e) => ({
4799
4817
  label: u(`questionContentEditor.matching.labels.${e}`),
4800
4818
  value: e
@@ -4810,7 +4828,7 @@ function Sc({ disabled: e, element: t, hasAnswer: n, item: r, onChange: i, richT
4810
4828
  "aria-label": u("questionContentEditor.matching.addItem", { index: n + 1 }),
4811
4829
  disabled: e,
4812
4830
  icon: "+",
4813
- onClick: () => E(Aa(x, t.columnId)),
4831
+ onClick: () => E(ja(x, t.columnId)),
4814
4832
  size: "small",
4815
4833
  children: u("questionContentEditor.matching.addItemButton")
4816
4834
  })
@@ -4818,7 +4836,7 @@ function Sc({ disabled: e, element: t, hasAnswer: n, item: r, onChange: i, richT
4818
4836
  }, t.columnId);
4819
4837
  }
4820
4838
  function ne(t, r, i, c) {
4821
- let l = wi(t.labelStyle, c), d = (h == null ? void 0 : h.itemId) === i.itemId, f = Cc(x, i.itemId), p = wc(x, i.itemId), m = f || p, g = l ? `${l}. ${i.content.text}` : i.content.text, _ = Tc(n);
4839
+ let l = Ti(t.labelStyle, c), d = (h == null ? void 0 : h.itemId) === i.itemId, f = Cc(x, i.itemId), p = wc(x, i.itemId), m = f || p, g = l ? `${l}. ${i.content.text}` : i.content.text, _ = Tc(n);
4822
4840
  return /* @__PURE__ */ o("div", {
4823
4841
  className: tc(bc.item, d ? bc.selected : "", m ? bc.matched : ""),
4824
4842
  "data-testid": `matching-editor-item-${i.itemId}`,
@@ -4845,7 +4863,7 @@ function Sc({ disabled: e, element: t, hasAnswer: n, item: r, onChange: i, richT
4845
4863
  danger: !0,
4846
4864
  disabled: e || t.items.length <= 1,
4847
4865
  icon: "\u00d7",
4848
- onClick: () => E(ja(x, i.itemId)),
4866
+ onClick: () => E(Ma(x, i.itemId)),
4849
4867
  size: "small"
4850
4868
  }),
4851
4869
  ie(r, i, c, g, d, p)
@@ -4945,21 +4963,21 @@ function Ec(e, t) {
4945
4963
  //#endregion
4946
4964
  //#region src/question/content-editor/QuestionContentOptionGroupEditor.tsx
4947
4965
  function Dc({ disabled: e, element: t, hasAnswer: n, item: r, onChange: i, richTextControls: s, translator: c }) {
4948
- let { t: l } = c, u = n ? r.answers.optionIds : [], d = t.config.renderer === "table", f = Ei(r, t.config.optionLabelStyle);
4966
+ let { t: l } = c, u = n ? r.answers.optionIds : [], d = t.config.renderer === "table", f = Di(r, t.config.optionLabelStyle);
4949
4967
  function p(e) {
4950
4968
  i(k(k({}, e), {}, { answers: n ? e.answers : { optionIds: [] } }));
4951
4969
  }
4952
4970
  function m(e, t) {
4953
- p(sa(r, e, t));
4971
+ p(ca(r, e, t));
4954
4972
  }
4955
4973
  function h(e, t, n) {
4956
- p(ma(r, e, t, n));
4974
+ p(ha(r, e, t, n));
4957
4975
  }
4958
4976
  function g(e, t) {
4959
- p(ha(r, e, t));
4977
+ p(ga(r, e, t));
4960
4978
  }
4961
4979
  function _(e) {
4962
- p(k(k({}, r), {}, { answers: { optionIds: la(u, e, t.config.selectionType) } }));
4980
+ p(k(k({}, r), {}, { answers: { optionIds: ua(u, e, t.config.selectionType) } }));
4963
4981
  }
4964
4982
  function v(t, n, r, i) {
4965
4983
  let a = u.includes(t);
@@ -5007,7 +5025,7 @@ function Dc({ disabled: e, element: t, hasAnswer: n, item: r, onChange: i, richT
5007
5025
  danger: !0,
5008
5026
  disabled: e || r.options.length <= 1,
5009
5027
  icon: "\u00d7",
5010
- onClick: () => p(ca(r, n)),
5028
+ onClick: () => p(la(r, n)),
5011
5029
  size: "small"
5012
5030
  })
5013
5031
  ]
@@ -5017,7 +5035,7 @@ function Dc({ disabled: e, element: t, hasAnswer: n, item: r, onChange: i, richT
5017
5035
  "aria-label": l("questionContentEditor.actions.addOption"),
5018
5036
  disabled: e,
5019
5037
  icon: "+",
5020
- onClick: () => p(oa(r)),
5038
+ onClick: () => p(sa(r)),
5021
5039
  children: l("questionContentEditor.actions.addOption")
5022
5040
  })]
5023
5041
  });
@@ -5046,14 +5064,14 @@ function Dc({ disabled: e, element: t, hasAnswer: n, item: r, onChange: i, richT
5046
5064
  "aria-label": l("questionContentEditor.actions.addTableColumn"),
5047
5065
  disabled: e,
5048
5066
  icon: "+",
5049
- onClick: () => p(ua(r)),
5067
+ onClick: () => p(da(r)),
5050
5068
  size: "small",
5051
5069
  children: l("questionContentEditor.actions.addTableColumn")
5052
5070
  }), /* @__PURE__ */ a(F, {
5053
5071
  "aria-label": l("questionContentEditor.actions.addTableRow"),
5054
5072
  disabled: e,
5055
5073
  icon: "+",
5056
- onClick: () => p(fa(r)),
5074
+ onClick: () => p(pa(r)),
5057
5075
  size: "small",
5058
5076
  children: l("questionContentEditor.actions.addTableRow")
5059
5077
  })]
@@ -5092,7 +5110,7 @@ function Dc({ disabled: e, element: t, hasAnswer: n, item: r, onChange: i, richT
5092
5110
  "aria-label": l("questionContentEditor.actions.deleteTableColumn"),
5093
5111
  danger: !0,
5094
5112
  disabled: e || r.columns.length <= 1,
5095
- onClick: () => p(da(r, n)),
5113
+ onClick: () => p(fa(r, n)),
5096
5114
  children: l("questionContentEditor.actions.deleteTableColumn")
5097
5115
  })]
5098
5116
  }),
@@ -5105,7 +5123,7 @@ function Dc({ disabled: e, element: t, hasAnswer: n, item: r, onChange: i, richT
5105
5123
  "aria-label": l("questionContentEditor.actions.deleteTableRow"),
5106
5124
  danger: !0,
5107
5125
  disabled: e || r.options.length <= 1,
5108
- onClick: () => p(pa(r, n.view.optionIndex)),
5126
+ onClick: () => p(ma(r, n.view.optionIndex)),
5109
5127
  size: "small",
5110
5128
  children: l("questionContentEditor.actions.deleteTableRow")
5111
5129
  }),
@@ -5162,12 +5180,12 @@ function Dc({ disabled: e, element: t, hasAnswer: n, item: r, onChange: i, richT
5162
5180
  //#endregion
5163
5181
  //#region src/question/content-editor/QuestionContentOrderingEditor.tsx
5164
5182
  function Oc({ disabled: e, hasAnswer: t, item: n, onChange: r, richTextControls: i, translator: s }) {
5165
- let { t: c } = s, l = Wa(n, t), u = new Map(l.sortOptions.map((e) => [e.id, e]));
5183
+ let { t: c } = s, l = Ga(n, t), u = new Map(l.sortOptions.map((e) => [e.id, e]));
5166
5184
  function d(e) {
5167
- r(Wa(e, t));
5185
+ r(Ga(e, t));
5168
5186
  }
5169
5187
  function f(e, n) {
5170
- d(qa(l, e, n, t));
5188
+ d(Ja(l, e, n, t));
5171
5189
  }
5172
5190
  return /* @__PURE__ */ o("div", {
5173
5191
  className: "flex min-w-0 flex-col gap-3",
@@ -5196,7 +5214,7 @@ function Oc({ disabled: e, hasAnswer: t, item: n, onChange: r, richTextControls:
5196
5214
  danger: !0,
5197
5215
  disabled: e || l.sortOptions.length <= 1,
5198
5216
  icon: "\u00d7",
5199
- onClick: () => d(Ka(l, n.id, t)),
5217
+ onClick: () => d(qa(l, n.id, t)),
5200
5218
  size: "small"
5201
5219
  })
5202
5220
  ]
@@ -5206,7 +5224,7 @@ function Oc({ disabled: e, hasAnswer: t, item: n, onChange: r, richTextControls:
5206
5224
  "aria-label": c("questionContentEditor.ordering.addOption"),
5207
5225
  disabled: e,
5208
5226
  icon: "+",
5209
- onClick: () => d(Ga(l, t)),
5227
+ onClick: () => d(Ka(l, t)),
5210
5228
  children: c("questionContentEditor.ordering.addOption")
5211
5229
  }),
5212
5230
  t ? /* @__PURE__ */ o("section", {
@@ -5231,13 +5249,13 @@ function Oc({ disabled: e, hasAnswer: t, item: n, onChange: r, richTextControls:
5231
5249
  "aria-label": c("questionContentEditor.ordering.moveUp", { index: r + 1 }),
5232
5250
  disabled: e || r === 0,
5233
5251
  icon: "\u2191",
5234
- onClick: () => d(Ja(l, n, -1, t)),
5252
+ onClick: () => d(Ya(l, n, -1, t)),
5235
5253
  size: "small"
5236
5254
  }), /* @__PURE__ */ a(F, {
5237
5255
  "aria-label": c("questionContentEditor.ordering.moveDown", { index: r + 1 }),
5238
5256
  disabled: e || r === l.answers.length - 1,
5239
5257
  icon: "\u2193",
5240
- onClick: () => d(Ja(l, n, 1, t)),
5258
+ onClick: () => d(Ya(l, n, 1, t)),
5241
5259
  size: "small"
5242
5260
  })]
5243
5261
  })
@@ -5275,7 +5293,7 @@ var Ac = {
5275
5293
  function jc({ disabled: e, hasAnswer: t, item: n, onChange: r, richTextControls: i, translator: s }) {
5276
5294
  let c = p(null), { t: l } = s, u = Vt(n.content.json);
5277
5295
  function d(e) {
5278
- r(Li(e, e.content, t));
5296
+ r(Ri(e, e.content, t));
5279
5297
  }
5280
5298
  function f() {
5281
5299
  var e;
@@ -5310,7 +5328,7 @@ function jc({ disabled: e, hasAnswer: t, item: n, onChange: r, richTextControls:
5310
5328
  disabled: e,
5311
5329
  editorRef: c,
5312
5330
  label: l("questionContentEditor.fields.textMarkerContent"),
5313
- onChange: (e) => d(k(k({}, n), {}, { content: gi(e.text, e.json) })),
5331
+ onChange: (e) => d(k(k({}, n), {}, { content: _i(e.text, e.json) })),
5314
5332
  placeholder: l("questionContentEditor.placeholders.textMarkerContent"),
5315
5333
  value: n.content
5316
5334
  }),
@@ -5354,13 +5372,13 @@ var H = {
5354
5372
  //#endregion
5355
5373
  //#region src/question/content-editor/QuestionContentWordBuilderEditor.tsx
5356
5374
  function Mc({ disabled: e, element: t, hasAnswer: n, item: r, onChange: i, richTextControls: s, title: c, translator: l }) {
5357
- let { t: u } = l, d = p(null), f = Ri(r, n, t);
5375
+ let { t: u } = l, d = p(null), f = zi(r, n, t);
5358
5376
  function m(e) {
5359
- i(Ri(e, n, t));
5377
+ i(zi(e, n, t));
5360
5378
  }
5361
5379
  function h() {
5362
5380
  var e;
5363
- let t = Pi(f.blanks);
5381
+ let t = Fi(f.blanks);
5364
5382
  (e = d.current) == null || e.insertNode("blank", {
5365
5383
  blankId: t,
5366
5384
  label: u("questionContentEditor.blank.shortLabel", { index: f.blanks.length + 1 })
@@ -5400,7 +5418,7 @@ function Mc({ disabled: e, element: t, hasAnswer: n, item: r, onChange: i, richT
5400
5418
  disabled: e,
5401
5419
  editorRef: d,
5402
5420
  label: u("questionContentEditor.fields.wordBuilderContent"),
5403
- onChange: (e) => i(Ii(f, e, n, t)),
5421
+ onChange: (e) => i(Li(f, e, n, t)),
5404
5422
  placeholder: u("questionContentEditor.placeholders.wordBuilderContent"),
5405
5423
  value: f.content
5406
5424
  }),
@@ -5594,13 +5612,13 @@ function Fc(e, t, n) {
5594
5612
  });
5595
5613
  }
5596
5614
  function Ic(e, t) {
5597
- let n = Qi(e);
5615
+ let n = $i(e);
5598
5616
  return t ? n : k(k({}, n), {}, { answers: [] });
5599
5617
  }
5600
5618
  //#endregion
5601
5619
  //#region src/question/content-editor/subquestion-group-editor-helpers.ts
5602
5620
  function Lc(e, t) {
5603
- return mi(zc(e.structure, t), e.questionTypeKey);
5621
+ return hi(zc(e.structure, t), e.questionTypeKey);
5604
5622
  }
5605
5623
  function Rc(e) {
5606
5624
  return e;
@@ -5661,10 +5679,10 @@ function Hc(e) {
5661
5679
  function Uc({ child: e, disabled: t, onChange: n, richTextControls: r, structure: i, translator: s }) {
5662
5680
  let { t: c } = s;
5663
5681
  function l(t) {
5664
- n(k(k({}, e), ji(e, t)));
5682
+ n(k(k({}, e), Mi(e, t)));
5665
5683
  }
5666
5684
  function u(t) {
5667
- n(k(k({}, e), Mi(e, t)));
5685
+ n(k(k({}, e), Ni(e, t)));
5668
5686
  }
5669
5687
  return i.elements.length === 0 && i.extras.length === 0 ? /* @__PURE__ */ a(Is, { description: c("questionContentEditor.subquestion.emptyTemplate") }) : /* @__PURE__ */ o("div", {
5670
5688
  className: "flex min-w-0 flex-col",
@@ -5674,14 +5692,14 @@ function Uc({ child: e, disabled: t, onChange: n, richTextControls: r, structure
5674
5692
  disabled: t,
5675
5693
  element: n,
5676
5694
  hasAnswer: i.hasAnswer,
5677
- item: bi(e, n, i.hasAnswer),
5695
+ item: xi(e, n, i.hasAnswer),
5678
5696
  onChange: l,
5679
5697
  richTextControls: r,
5680
5698
  title: n.name || c(`questionContentEditor.elementType.${n.type}`),
5681
5699
  translator: s
5682
5700
  })
5683
5701
  }, n.elementKey)), i.extras.map((n) => {
5684
- let o = xi(e, n);
5702
+ let o = Si(e, n);
5685
5703
  return /* @__PURE__ */ a("section", {
5686
5704
  className: "flex min-w-0 flex-col gap-3 border-t border-slate-100 py-3 first:border-t-0 first:pt-0 last:pb-0",
5687
5705
  children: /* @__PURE__ */ a(Nc, {
@@ -5728,7 +5746,7 @@ function qc(e, t) {
5728
5746
  //#endregion
5729
5747
  //#region src/question/content-editor/QuestionContentSubquestionChildEditor.tsx
5730
5748
  function Jc({ child: e, childIndex: t, disabled: n, hasAnswer: r, numberPath: i, onChange: s, onDelete: c, onMove: l, richTextControls: u, siblingCount: d, subquestionTemplates: f, translator: p }) {
5731
- let { t: m } = p, h = i == null ? [t] : i, g = Hc(h), _ = Yc(e, f), v = Xc(_, r), y = pi(v), b = k(k(k({}, e), Ai(v, e)), {}, { children: e.children });
5749
+ let { t: m } = p, h = i == null ? [t] : i, g = Hc(h), _ = Yc(e, f), v = Xc(_, r), y = mi(v), b = k(k(k({}, e), ji(v, e)), {}, { children: e.children });
5732
5750
  function x(e) {
5733
5751
  s(k(k({}, b), {}, { children: [...b.children, e] }));
5734
5752
  }
@@ -5918,17 +5936,17 @@ function el({ disabled: e, hasAnswer: t, item: n, onChange: r, richTextControls:
5918
5936
  //#region src/question/content-editor/QuestionContentEditor.tsx
5919
5937
  function tl({ disabled: t = !1, locale: n = "zh-CN", onChange: r, structure: i, subquestionTemplates: s = [], uploadImage: c, value: l }) {
5920
5938
  let u = ws(n), { t: d } = u, p = f(() => ({
5921
- plugins: [ti, ys],
5939
+ plugins: [ni, ys],
5922
5940
  uploadImage: c
5923
5941
  }), [c]);
5924
5942
  function m(e) {
5925
- r(ji(l, e));
5943
+ r(Mi(l, e));
5926
5944
  }
5927
5945
  function h(e) {
5928
- r(Mi(l, e));
5946
+ r(Ni(l, e));
5929
5947
  }
5930
5948
  function g(e) {
5931
- let n = bi(l, e, i.hasAnswer);
5949
+ let n = xi(l, e, i.hasAnswer);
5932
5950
  return /* @__PURE__ */ a(Nc, {
5933
5951
  disabled: t,
5934
5952
  element: e,
@@ -5941,7 +5959,7 @@ function tl({ disabled: t = !1, locale: n = "zh-CN", onChange: r, structure: i,
5941
5959
  });
5942
5960
  }
5943
5961
  function _(e) {
5944
- let n = xi(l, e);
5962
+ let n = Si(l, e);
5945
5963
  return /* @__PURE__ */ a(Nc, {
5946
5964
  disabled: t,
5947
5965
  element: nl(e),
@@ -5957,7 +5975,7 @@ function tl({ disabled: t = !1, locale: n = "zh-CN", onChange: r, structure: i,
5957
5975
  translator: u
5958
5976
  });
5959
5977
  }
5960
- let v = pi(i) ? /* @__PURE__ */ a(el, {
5978
+ let v = mi(i) ? /* @__PURE__ */ a(el, {
5961
5979
  disabled: t,
5962
5980
  hasAnswer: i.hasAnswer,
5963
5981
  item: k(k({}, l), {}, { elements: [] }),
@@ -6013,7 +6031,7 @@ function il(e, t) {
6013
6031
  return {
6014
6032
  elements: e.elements.map((e) => hl(e, t)),
6015
6033
  extras: e.extras.map((e) => ({
6016
- extraKey: e.clientId,
6034
+ extraKey: e.extraKey,
6017
6035
  name: _l(e, Jr(e.type), Yr(e.type), t),
6018
6036
  type: e.type
6019
6037
  })),
@@ -6022,7 +6040,7 @@ function il(e, t) {
6022
6040
  };
6023
6041
  }
6024
6042
  function al(e, t, n) {
6025
- return !e || !t ? null : k(k({}, Ai(t, cl(e))), {}, { children: e.children.map((e) => {
6043
+ return !e || !t ? null : k(k({}, ji(t, cl(e))), {}, { children: e.children.map((e) => {
6026
6044
  let t = qc(n, e.questionTypeKey);
6027
6045
  return t ? al(e, t.structure, n) : null;
6028
6046
  }).filter((e) => !!e) });
@@ -6053,13 +6071,13 @@ function cl(e) {
6053
6071
  function ll(e, t) {
6054
6072
  return e.some((e, n) => {
6055
6073
  let r = t.slice(n, n + 1)[0];
6056
- return !r || e.clientId !== r.clientId || e.type !== r.type || JSON.stringify(e.config) !== JSON.stringify(r.config);
6074
+ return !r || e.clientId !== r.clientId || e.elementKey !== r.elementKey || e.type !== r.type || JSON.stringify(e.config) !== JSON.stringify(r.config);
6057
6075
  });
6058
6076
  }
6059
6077
  function ul(e, t) {
6060
6078
  return e.some((e, n) => {
6061
6079
  let r = t.slice(n, n + 1)[0];
6062
- return !r || e.clientId !== r.clientId || e.type !== r.type;
6080
+ return !r || e.clientId !== r.clientId || e.extraKey !== r.extraKey || e.type !== r.type;
6063
6081
  });
6064
6082
  }
6065
6083
  function dl(e) {
@@ -6069,36 +6087,42 @@ function fl(e) {
6069
6087
  switch (e.type) {
6070
6088
  case "inlineFill": return {
6071
6089
  config: k({}, e.config),
6090
+ elementKey: e.elementKey,
6072
6091
  enName: e.enName,
6073
6092
  name: e.name,
6074
6093
  type: "inlineFill"
6075
6094
  };
6076
6095
  case "wordBuilder": return {
6077
6096
  config: k({}, e.config),
6097
+ elementKey: e.elementKey,
6078
6098
  enName: e.enName,
6079
6099
  name: e.name,
6080
6100
  type: "wordBuilder"
6081
6101
  };
6082
6102
  case "judgement": return {
6083
6103
  config: k({}, e.config),
6104
+ elementKey: e.elementKey,
6084
6105
  enName: e.enName,
6085
6106
  name: e.name,
6086
6107
  type: "judgement"
6087
6108
  };
6088
6109
  case "choice": return {
6089
6110
  config: k({}, e.config),
6111
+ elementKey: e.elementKey,
6090
6112
  enName: e.enName,
6091
6113
  name: e.name,
6092
6114
  type: "choice"
6093
6115
  };
6094
6116
  case "lineConnect": return {
6095
6117
  config: k({}, e.config),
6118
+ elementKey: e.elementKey,
6096
6119
  enName: e.enName,
6097
6120
  name: e.name,
6098
6121
  type: "lineConnect"
6099
6122
  };
6100
6123
  case "matching": return {
6101
6124
  config: k({}, e.config),
6125
+ elementKey: e.elementKey,
6102
6126
  enName: e.enName,
6103
6127
  name: e.name,
6104
6128
  type: "matching"
@@ -6108,6 +6132,7 @@ function fl(e) {
6108
6132
  function pl(e) {
6109
6133
  return {
6110
6134
  config: {},
6135
+ elementKey: e.elementKey,
6111
6136
  enName: e.enName,
6112
6137
  name: e.name,
6113
6138
  type: e.type
@@ -6116,6 +6141,7 @@ function pl(e) {
6116
6141
  function ml(e) {
6117
6142
  return {
6118
6143
  enName: e.enName,
6144
+ extraKey: e.extraKey,
6119
6145
  name: e.name,
6120
6146
  type: e.type
6121
6147
  };
@@ -6123,7 +6149,7 @@ function ml(e) {
6123
6149
  function hl(e, t) {
6124
6150
  return e.type === "fill" || e.type === "classification" || e.type === "ordering" || e.type === "richText" || e.type === "textMarker" ? {
6125
6151
  config: {},
6126
- elementKey: e.clientId,
6152
+ elementKey: e.elementKey,
6127
6153
  name: _l(e, A(e.type), j(e.type), t),
6128
6154
  type: e.type
6129
6155
  } : gl(e, t);
@@ -6135,19 +6161,19 @@ function gl(e, t) {
6135
6161
  allowCandidateReuse: !!e.config.allowCandidateReuse,
6136
6162
  candidateMode: e.config.candidateMode
6137
6163
  },
6138
- elementKey: e.clientId,
6164
+ elementKey: e.elementKey,
6139
6165
  name: _l(e, A("inlineFill"), j("inlineFill"), t),
6140
6166
  type: "inlineFill"
6141
6167
  };
6142
6168
  case "wordBuilder": return {
6143
6169
  config: { builderMode: e.config.builderMode },
6144
- elementKey: e.clientId,
6170
+ elementKey: e.elementKey,
6145
6171
  name: _l(e, A("wordBuilder"), j("wordBuilder"), t),
6146
6172
  type: "wordBuilder"
6147
6173
  };
6148
6174
  case "judgement": return {
6149
6175
  config: { judgeAnswerMode: e.config.judgeAnswerMode },
6150
- elementKey: e.clientId,
6176
+ elementKey: e.elementKey,
6151
6177
  name: _l(e, A("judgement"), j("judgement"), t),
6152
6178
  type: "judgement"
6153
6179
  };
@@ -6157,19 +6183,19 @@ function gl(e, t) {
6157
6183
  renderer: e.config.renderer,
6158
6184
  selectionType: e.config.selectionType
6159
6185
  },
6160
- elementKey: e.clientId,
6186
+ elementKey: e.elementKey,
6161
6187
  name: _l(e, A("choice"), j("choice"), t),
6162
6188
  type: "choice"
6163
6189
  };
6164
6190
  case "lineConnect": return {
6165
6191
  config: { columns: e.config.columns.map((e) => k({}, e)) },
6166
- elementKey: e.clientId,
6192
+ elementKey: e.elementKey,
6167
6193
  name: _l(e, A("lineConnect"), j("lineConnect"), t),
6168
6194
  type: "lineConnect"
6169
6195
  };
6170
6196
  case "matching": return {
6171
6197
  config: { columns: e.config.columns.map((e) => k({}, e)) },
6172
- elementKey: e.clientId,
6198
+ elementKey: e.elementKey,
6173
6199
  name: _l(e, A("matching"), j("matching"), t),
6174
6200
  type: "matching"
6175
6201
  };
@@ -6186,13 +6212,13 @@ function _l(e, t, n, r) {
6186
6212
  //#endregion
6187
6213
  //#region src/question/player/helpers.ts
6188
6214
  function vl(e, t, n = []) {
6189
- let r = pi(t);
6215
+ let r = mi(t);
6190
6216
  return {
6191
6217
  questionTypeKey: e.questionTypeKey,
6192
6218
  children: e.children.map((e) => Rl(e, n)),
6193
6219
  id: e.id,
6194
6220
  items: r ? [] : t.elements.reduce((n, r) => {
6195
- let i = zl(r, bi(e, r, t.hasAnswer));
6221
+ let i = zl(r, xi(e, r, t.hasAnswer));
6196
6222
  return i ? [...n, i] : n;
6197
6223
  }, []),
6198
6224
  version: e.version
@@ -6304,7 +6330,7 @@ function Fl(e, t, n) {
6304
6330
  return ke(e, t, n);
6305
6331
  }
6306
6332
  function Il(e, t, n, r) {
6307
- return Ya(e, t.sortOptions, n, r);
6333
+ return Xa(e, t.sortOptions, n, r);
6308
6334
  }
6309
6335
  function Ll(e, t) {
6310
6336
  return e.includes(t) ? e.filter((e) => e !== t) : [...e, t];
@@ -6455,11 +6481,11 @@ var tu = {
6455
6481
  explanation: "Explanation",
6456
6482
  falseLabel: "False",
6457
6483
  inspector: "Inspector",
6458
- judgementMode: "Judgement mode",
6484
+ judgeAnswerMode: "Judgement mode",
6459
6485
  multipleChoice: "Multiple choice",
6460
6486
  noCandidates: "None",
6461
6487
  option: "Option",
6462
- optionGroups: "Option groups",
6488
+ perBlankOptions: "Option groups",
6463
6489
  optionLabelStyle: "Labels",
6464
6490
  questionArrangement: "Type arrangement",
6465
6491
  questionContent: "Question content",
@@ -6519,11 +6545,11 @@ var tu = {
6519
6545
  explanation: "\u89e3\u6790",
6520
6546
  falseLabel: "\u9519\u8bef",
6521
6547
  inspector: "\u7ed3\u6784\u8bbe\u7f6e",
6522
- judgementMode: "\u5224\u65ad\u6a21\u5f0f",
6548
+ judgeAnswerMode: "\u5224\u65ad\u6a21\u5f0f",
6523
6549
  multipleChoice: "\u591a\u9009",
6524
6550
  noCandidates: "\u4e0d\u4f7f\u7528",
6525
6551
  option: "\u9009\u9879",
6526
- optionGroups: "\u9009\u9879\u7ec4",
6552
+ perBlankOptions: "\u9009\u9879\u7ec4",
6527
6553
  optionLabelStyle: "\u9009\u9879\u6807\u53f7",
6528
6554
  questionArrangement: "\u9898\u578b\u7f16\u6392",
6529
6555
  questionContent: "\u9898\u76ee\u5185\u5bb9",
@@ -6561,45 +6587,45 @@ function nu(e = "zh-CN") {
6561
6587
  }
6562
6588
  //#endregion
6563
6589
  //#region src/question/renderers/helpers.ts
6564
- function U(...e) {
6590
+ function ru(...e) {
6565
6591
  return e.filter(Boolean).join(" ");
6566
6592
  }
6567
- function ru(e, t, n) {
6593
+ function iu(e, t, n) {
6568
6594
  return e.map((e) => t.indexOf(e) + 1).filter((e) => e > 0).map((e) => `${n}${e}`).join(" ");
6569
6595
  }
6570
- function iu(e) {
6596
+ function au(e) {
6571
6597
  return "answerPools" in e;
6572
6598
  }
6573
- function au(e) {
6599
+ function ou(e) {
6574
6600
  return "answerOptionId" in e;
6575
6601
  }
6576
- function ou(e) {
6602
+ function su(e) {
6577
6603
  return "answerOptionIds" in e;
6578
6604
  }
6579
- function su(e, t) {
6605
+ function cu(e, t) {
6580
6606
  var n, r;
6581
6607
  return (n = e == null || (r = e.find((e) => e.optionId === t)) == null ? void 0 : r.content) == null ? null : n;
6582
6608
  }
6583
- function cu(e, t, n) {
6609
+ function lu(e, t, n) {
6584
6610
  var r, i;
6585
6611
  return (r = e == null || (i = e.find((e) => e.blankId === t)) == null || (i = i.options.find((e) => e.optionId === n)) == null ? void 0 : i.content) == null ? null : r;
6586
6612
  }
6587
- function lu(e) {
6613
+ function uu(e) {
6588
6614
  return e.answers.reduce((t, n) => {
6589
- if (iu(n)) return uu(t, {
6615
+ if (au(n)) return du(t, {
6590
6616
  blankIds: n.blankIds,
6591
6617
  contents: n.answerPools
6592
6618
  });
6593
- if (au(n)) {
6594
- let r = cu(e.blankOptionGroups, n.blankId, n.answerOptionId);
6595
- return uu(t, {
6619
+ if (ou(n)) {
6620
+ let r = lu(e.blankOptionGroups, n.blankId, n.answerOptionId);
6621
+ return du(t, {
6596
6622
  blankIds: [n.blankId],
6597
6623
  contents: r ? [r] : []
6598
6624
  });
6599
6625
  }
6600
- if (ou(n)) {
6601
- let r = n.answerOptionIds.map((t) => su(e.candidateOptions, t)).filter((e) => !!e);
6602
- return uu(t, {
6626
+ if (su(n)) {
6627
+ let r = n.answerOptionIds.map((t) => cu(e.candidateOptions, t)).filter((e) => !!e);
6628
+ return du(t, {
6603
6629
  blankIds: n.blankIds,
6604
6630
  contents: r
6605
6631
  });
@@ -6607,14 +6633,14 @@ function lu(e) {
6607
6633
  return t;
6608
6634
  }, []);
6609
6635
  }
6610
- function uu(e, t) {
6636
+ function du(e, t) {
6611
6637
  let n = t.contents.filter((e) => e.text.trim() !== "");
6612
6638
  return n.length > 0 ? [...e, {
6613
6639
  blankIds: t.blankIds,
6614
6640
  contents: n
6615
6641
  }] : e;
6616
6642
  }
6617
- var W = {
6643
+ var U = {
6618
6644
  root: "_root_16zbu_1",
6619
6645
  "element-list": "_element-list_16zbu_20",
6620
6646
  children: "_children_16zbu_21",
@@ -6631,32 +6657,32 @@ var W = {
6631
6657
  };
6632
6658
  //#endregion
6633
6659
  //#region src/question/player/QuestionPlayerComposite.tsx
6634
- function du({ messages: e, numberPath: t = [], onChildResponseChange: n, renderChild: r, response: i, subquestionTemplates: s, value: c }) {
6660
+ function fu({ messages: e, numberPath: t = [], onChildResponseChange: n, renderChild: r, response: i, subquestionTemplates: s, value: c }) {
6635
6661
  return c.children.length === 0 ? /* @__PURE__ */ a("div", {
6636
- className: W.empty,
6662
+ className: U.empty,
6637
6663
  children: e.previewEmpty
6638
6664
  }) : /* @__PURE__ */ a("div", {
6639
- className: W.children,
6665
+ className: U.children,
6640
6666
  children: c.children.map((c, l) => {
6641
6667
  let u = [...t, l], d = qc(s, c.questionTypeKey), f = i.children.slice(l, l + 1)[0];
6642
6668
  return /* @__PURE__ */ o("section", {
6643
- className: W.child,
6669
+ className: U.child,
6644
6670
  children: [/* @__PURE__ */ o("div", {
6645
- className: W["child-title"],
6671
+ className: U["child-title"],
6646
6672
  children: [
6647
6673
  e.subquestion,
6648
6674
  " ",
6649
6675
  Hc(u)
6650
6676
  ]
6651
6677
  }), d && f ? r(c, f, d.structure, (e) => n(l, e), u) : /* @__PURE__ */ a("div", {
6652
- className: W.empty,
6678
+ className: U.empty,
6653
6679
  children: e.missingSubquestionTemplate
6654
6680
  })]
6655
6681
  }, c.id || l);
6656
6682
  })
6657
6683
  });
6658
6684
  }
6659
- var G = {
6685
+ var W = {
6660
6686
  "rich-content": "_rich-content_aqc4q_1",
6661
6687
  element: "_element_aqc4q_52",
6662
6688
  "option-list": "_option-list_aqc4q_54",
@@ -6673,16 +6699,16 @@ var G = {
6673
6699
  };
6674
6700
  //#endregion
6675
6701
  //#region src/question/renderers/QuestionRichContentView.tsx
6676
- function K({ className: e, content: t }) {
6677
- let n = t.html || r(yi(t), { plugins: [ti] });
6702
+ function G({ className: e, content: t }) {
6703
+ let n = t.html || r(bi(t), { plugins: [ni] });
6678
6704
  return /* @__PURE__ */ a("div", {
6679
- className: e ? `${G["rich-content"]} ${e}` : G["rich-content"],
6705
+ className: e ? `${W["rich-content"]} ${e}` : W["rich-content"],
6680
6706
  dangerouslySetInnerHTML: { __html: n }
6681
6707
  });
6682
6708
  }
6683
6709
  //#endregion
6684
6710
  //#region src/question/renderers/QuestionStandardAnswerPanel.module.css
6685
- var fu = {
6711
+ var pu = {
6686
6712
  "answer-panel": "_answer-panel_1a0m0_1",
6687
6713
  "answer-title": "_answer-title_1a0m0_12",
6688
6714
  "answer-list": "_answer-list_1a0m0_30",
@@ -6693,25 +6719,25 @@ var fu = {
6693
6719
  };
6694
6720
  //#endregion
6695
6721
  //#region src/question/renderers/QuestionStandardAnswerPanel.tsx
6696
- function q({ groups: e, title: t }) {
6722
+ function K({ groups: e, title: t }) {
6697
6723
  let n = e.filter((e) => e.contents.length > 0);
6698
6724
  return n.length === 0 ? null : /* @__PURE__ */ o("section", {
6699
6725
  "aria-label": t,
6700
- className: fu["answer-panel"],
6726
+ className: pu["answer-panel"],
6701
6727
  children: [/* @__PURE__ */ a("span", {
6702
- className: fu["answer-title"],
6728
+ className: pu["answer-title"],
6703
6729
  children: t
6704
6730
  }), /* @__PURE__ */ a("ol", {
6705
- className: fu["answer-list"],
6731
+ className: pu["answer-list"],
6706
6732
  children: n.map((e, t) => /* @__PURE__ */ o("li", {
6707
- className: fu["answer-row"],
6733
+ className: pu["answer-row"],
6708
6734
  children: [e.marker ? /* @__PURE__ */ a("span", {
6709
- className: fu["answer-marker"],
6735
+ className: pu["answer-marker"],
6710
6736
  children: e.marker
6711
6737
  }) : null, /* @__PURE__ */ a("div", {
6712
- className: fu["answer-content-list"],
6738
+ className: pu["answer-content-list"],
6713
6739
  children: e.contents.map((e, t) => /* @__PURE__ */ a("div", {
6714
- className: fu["answer-value"],
6740
+ className: pu["answer-value"],
6715
6741
  children: e
6716
6742
  }, `answer-${t}`))
6717
6743
  })]
@@ -6721,53 +6747,53 @@ function q({ groups: e, title: t }) {
6721
6747
  }
6722
6748
  //#endregion
6723
6749
  //#region src/question/player/QuestionBlankGroupPlayer.tsx
6724
- function pu({ disabled: e, item: t, messages: n, onChange: r, response: i, showAnswer: s }) {
6725
- let c = bl(i, t.elementKey, t.blanks), l = ea(t.answers, t.blanks).map((e, r) => ({
6726
- contents: e.answerPools.map((e, t) => /* @__PURE__ */ a(K, { content: e }, `group-${r}-answer-${t}`)),
6727
- marker: ru(e.blankIds, t.blanks, n.blankLabel)
6750
+ function mu({ disabled: e, item: t, messages: n, onChange: r, response: i, showAnswer: s }) {
6751
+ let c = bl(i, t.elementKey, t.blanks), l = ta(t.answers, t.blanks).map((e, r) => ({
6752
+ contents: e.answerPools.map((e, t) => /* @__PURE__ */ a(G, { content: e }, `group-${r}-answer-${t}`)),
6753
+ marker: iu(e.blankIds, t.blanks, n.blankLabel)
6728
6754
  }));
6729
6755
  function u(e, t) {
6730
6756
  r(k(k({}, c), {}, { answers: k(k({}, c.answers), {}, { [e]: t }) }));
6731
6757
  }
6732
6758
  return /* @__PURE__ */ o("div", {
6733
- className: W["control-list"],
6759
+ className: U["control-list"],
6734
6760
  children: [t.blanks.map((t, r) => /* @__PURE__ */ o("label", {
6735
- className: W.field,
6761
+ className: U.field,
6736
6762
  children: [/* @__PURE__ */ o("span", {
6737
- className: W["field-label"],
6763
+ className: U["field-label"],
6738
6764
  children: [
6739
6765
  n.blankLabel,
6740
6766
  " ",
6741
6767
  r + 1
6742
6768
  ]
6743
6769
  }), /* @__PURE__ */ a("input", {
6744
- className: W.input,
6770
+ className: U.input,
6745
6771
  disabled: e,
6746
6772
  onChange: (e) => u(t, e.target.value),
6747
- value: hu(c.answers, t)
6773
+ value: gu(c.answers, t)
6748
6774
  })]
6749
- }, mu(t, r))), s ? /* @__PURE__ */ a(q, {
6775
+ }, hu(t, r))), s ? /* @__PURE__ */ a(K, {
6750
6776
  groups: l,
6751
6777
  title: n.standardAnswer
6752
6778
  }) : null]
6753
6779
  });
6754
6780
  }
6755
- function mu(e, t) {
6781
+ function hu(e, t) {
6756
6782
  return e || `blank-${t + 1}`;
6757
6783
  }
6758
- function hu(e, t) {
6784
+ function gu(e, t) {
6759
6785
  var n, r;
6760
6786
  return (n = (r = Object.entries(e).find(([e]) => e === t)) == null ? void 0 : r[1]) == null ? "" : n;
6761
6787
  }
6762
6788
  //#endregion
6763
6789
  //#region src/question/renderers/classificationAnswers.tsx
6764
- function gu(e) {
6790
+ function _u(e) {
6765
6791
  return e.categories.map((t) => ({
6766
- contents: e.items.filter((n) => e.answers[n.id] === t.id).map((e) => /* @__PURE__ */ a(K, { content: e.content }, `${t.id}-${e.id}`)),
6792
+ contents: e.items.filter((n) => e.answers[n.id] === t.id).map((e) => /* @__PURE__ */ a(G, { content: e.content }, `${t.id}-${e.id}`)),
6767
6793
  marker: t.content.text || t.id
6768
6794
  }));
6769
6795
  }
6770
- var J = {
6796
+ var q = {
6771
6797
  board: "_board_1f76b_1",
6772
6798
  pool: "_pool_1f76b_6",
6773
6799
  zones: "_zones_1f76b_13",
@@ -6782,10 +6808,10 @@ var J = {
6782
6808
  };
6783
6809
  //#endregion
6784
6810
  //#region src/question/player/QuestionClassificationPlayer.tsx
6785
- function _u({ disabled: e, item: t, messages: n, onChange: r, response: i, showAnswer: s }) {
6786
- let [c, l] = m(""), u = wl(i, t.elementKey), d = yu(u.placements, t), f = t.items.find((e) => e.id === c);
6811
+ function vu({ disabled: e, item: t, messages: n, onChange: r, response: i, showAnswer: s }) {
6812
+ let [c, l] = m(""), u = wl(i, t.elementKey), d = bu(u.placements, t), f = t.items.find((e) => e.id === c);
6787
6813
  function p(e, n) {
6788
- r(k(k({}, u), {}, { placements: yu(Fl(d, e, n), t) })), l("");
6814
+ r(k(k({}, u), {}, { placements: bu(Fl(d, e, n), t) })), l("");
6789
6815
  }
6790
6816
  function h(t, n) {
6791
6817
  t.preventDefault();
@@ -6793,10 +6819,10 @@ function _u({ disabled: e, item: t, messages: n, onChange: r, response: i, showA
6793
6819
  !e && r && p(r, n);
6794
6820
  }
6795
6821
  function g(n) {
6796
- let r = c === n.id, i = vu(n.id, d, t, s);
6822
+ let r = c === n.id, i = yu(n.id, d, t, s);
6797
6823
  return /* @__PURE__ */ a("button", {
6798
6824
  "aria-pressed": r,
6799
- className: U(J.item, r && J.selected, i === "correct" && J.correct, i === "incorrect" && J.incorrect, i === "unanswered" && J.unanswered),
6825
+ className: ru(q.item, r && q.selected, i === "correct" && q.correct, i === "incorrect" && q.incorrect, i === "unanswered" && q.unanswered),
6800
6826
  "data-status": i,
6801
6827
  "data-testid": `classification-player-item-${n.id}`,
6802
6828
  disabled: e,
@@ -6808,97 +6834,97 @@ function _u({ disabled: e, item: t, messages: n, onChange: r, response: i, showA
6808
6834
  e.dataTransfer.effectAllowed = "move", e.dataTransfer.setData("question/classification-item", n.id);
6809
6835
  },
6810
6836
  type: "button",
6811
- children: /* @__PURE__ */ a(K, { content: n.content })
6837
+ children: /* @__PURE__ */ a(G, { content: n.content })
6812
6838
  }, n.id);
6813
6839
  }
6814
6840
  return /* @__PURE__ */ o("div", {
6815
- className: G.element,
6841
+ className: W.element,
6816
6842
  children: [/* @__PURE__ */ o("div", {
6817
- className: J.board,
6843
+ className: q.board,
6818
6844
  children: [/* @__PURE__ */ a("div", {
6819
- className: J.zones,
6845
+ className: q.zones,
6820
6846
  "data-testid": "classification-zones",
6821
6847
  children: t.categories.map((e) => {
6822
6848
  let r = t.items.filter((t) => d[t.id] === e.id);
6823
6849
  return /* @__PURE__ */ o("section", {
6824
- className: J.zone,
6850
+ className: q.zone,
6825
6851
  onClick: () => f ? p(f.id, e.id) : void 0,
6826
6852
  onDragOver: (e) => e.preventDefault(),
6827
6853
  onDrop: (t) => h(t, e.id),
6828
6854
  children: [/* @__PURE__ */ a("div", {
6829
- className: J["zone-title"],
6830
- children: /* @__PURE__ */ a(K, { content: e.content })
6855
+ className: q["zone-title"],
6856
+ children: /* @__PURE__ */ a(G, { content: e.content })
6831
6857
  }), r.length > 0 ? r.map((e) => g(e)) : /* @__PURE__ */ a("span", {
6832
- className: J.empty,
6858
+ className: q.empty,
6833
6859
  children: n.unassigned
6834
6860
  })]
6835
6861
  }, e.id);
6836
6862
  })
6837
6863
  }), /* @__PURE__ */ a("section", {
6838
- className: J.pool,
6864
+ className: q.pool,
6839
6865
  "data-testid": "classification-pool",
6840
6866
  onClick: () => f ? p(f.id, "") : void 0,
6841
6867
  onDragOver: (e) => e.preventDefault(),
6842
6868
  onDrop: (e) => h(e, ""),
6843
6869
  children: t.items.filter((e) => !d[e.id]).map((e) => g(e))
6844
6870
  })]
6845
- }), s ? /* @__PURE__ */ a(q, {
6846
- groups: gu(t),
6871
+ }), s ? /* @__PURE__ */ a(K, {
6872
+ groups: _u(t),
6847
6873
  title: n.standardAnswer
6848
6874
  }) : null]
6849
6875
  });
6850
6876
  }
6851
- function vu(e, t, n, r) {
6877
+ function yu(e, t, n, r) {
6852
6878
  var i, a;
6853
6879
  let o = (i = t[e]) == null ? "" : i, s = (a = n.answers[e]) == null ? "" : a;
6854
6880
  if (!(!r || !s)) return o ? s === o ? "correct" : "incorrect" : "unanswered";
6855
6881
  }
6856
- function yu(e, t) {
6882
+ function bu(e, t) {
6857
6883
  return Oe(e, t.categories, t.items);
6858
6884
  }
6859
6885
  //#endregion
6860
6886
  //#region src/question/renderers/QuestionRichContentWithBlankView.tsx
6861
- function bu({ className: e, content: t, renderBlank: n }) {
6887
+ function xu({ className: e, content: t, renderBlank: n }) {
6862
6888
  let r = /* @__PURE__ */ new Map();
6863
6889
  return /* @__PURE__ */ a("div", {
6864
- className: [G["rich-content"], e == null ? "" : e].filter(Boolean).join(" "),
6865
- children: t.json.map((e, t) => xu(e, {
6890
+ className: [W["rich-content"], e == null ? "" : e].filter(Boolean).join(" "),
6891
+ children: t.json.map((e, t) => Su(e, {
6866
6892
  blankIndexes: r,
6867
6893
  key: `node-${t}`,
6868
6894
  renderBlank: n
6869
6895
  }))
6870
6896
  });
6871
6897
  }
6872
- function xu(e, t) {
6898
+ function Su(e, t) {
6873
6899
  if (typeof e.text == "string") return /* @__PURE__ */ a(s, { children: e.text }, t.key);
6874
- if (e.type === "blank") return /* @__PURE__ */ a(s, { children: Su(e, t) }, t.key);
6875
- let n = wu(e.children, t);
6900
+ if (e.type === "blank") return /* @__PURE__ */ a(s, { children: Cu(e, t) }, t.key);
6901
+ let n = Tu(e.children, t);
6876
6902
  switch (e.type) {
6877
- case "heading": return Tu(e, n, t.key);
6903
+ case "heading": return Eu(e, n, t.key);
6878
6904
  case "table": return /* @__PURE__ */ a("table", { children: n }, t.key);
6879
6905
  case "table-row": return /* @__PURE__ */ a("tr", { children: n }, t.key);
6880
6906
  case "table-cell": return /* @__PURE__ */ a("td", { children: n }, t.key);
6881
6907
  default: return /* @__PURE__ */ a("p", { children: n }, t.key);
6882
6908
  }
6883
6909
  }
6884
- function Su(e, t) {
6885
- let n = Eu(e.blankId), r = Cu(t.blankIndexes, n);
6910
+ function Cu(e, t) {
6911
+ let n = Du(e.blankId), r = wu(t.blankIndexes, n);
6886
6912
  return t.renderBlank({
6887
6913
  blankId: n,
6888
6914
  index: r,
6889
- label: Eu(e.label)
6915
+ label: Du(e.label)
6890
6916
  });
6891
6917
  }
6892
- function Cu(e, t) {
6918
+ function wu(e, t) {
6893
6919
  let n = e.get(t);
6894
6920
  if (n !== void 0) return n;
6895
6921
  let r = e.size;
6896
6922
  return e.set(t, r), r;
6897
6923
  }
6898
- function wu(e, t) {
6899
- return (e == null ? [] : e).map((e, n) => xu(e, k(k({}, t), {}, { key: `${t.key}-${n}` })));
6924
+ function Tu(e, t) {
6925
+ return (e == null ? [] : e).map((e, n) => Su(e, k(k({}, t), {}, { key: `${t.key}-${n}` })));
6900
6926
  }
6901
- function Tu(e, t, n) {
6927
+ function Eu(e, t, n) {
6902
6928
  switch (e.level) {
6903
6929
  case 1: return /* @__PURE__ */ a("h1", { children: t }, n);
6904
6930
  case 2: return /* @__PURE__ */ a("h2", { children: t }, n);
@@ -6906,10 +6932,10 @@ function Tu(e, t, n) {
6906
6932
  default: return /* @__PURE__ */ a("p", { children: t }, n);
6907
6933
  }
6908
6934
  }
6909
- function Eu(e) {
6935
+ function Du(e) {
6910
6936
  return typeof e == "string" ? e : "";
6911
6937
  }
6912
- var Y = {
6938
+ var J = {
6913
6939
  "inline-input": "_inline-input_2je8q_1",
6914
6940
  "inline-select": "_inline-select_2je8q_19",
6915
6941
  "inline-blank-underline": "_inline-blank-underline_2je8q_43",
@@ -6927,10 +6953,10 @@ var Y = {
6927
6953
  };
6928
6954
  //#endregion
6929
6955
  //#region src/question/player/QuestionFillTextContentPlayer.tsx
6930
- function Du({ answers: e, disabled: t, item: n, messages: r, onAnswerChange: i, structure: o }) {
6931
- return /* @__PURE__ */ a(bu, {
6956
+ function Ou({ answers: e, disabled: t, item: n, messages: r, onAnswerChange: i, structure: o }) {
6957
+ return /* @__PURE__ */ a(xu, {
6932
6958
  content: n.content,
6933
- renderBlank: (a) => Ou(a, {
6959
+ renderBlank: (a) => ku(a, {
6934
6960
  answers: e,
6935
6961
  blankLabel: r.blankLabel,
6936
6962
  disabled: t,
@@ -6940,13 +6966,13 @@ function Du({ answers: e, disabled: t, item: n, messages: r, onAnswerChange: i,
6940
6966
  })
6941
6967
  });
6942
6968
  }
6943
- function Ou(e, t) {
6944
- let { blankId: n } = e, r = t.item.blanks.indexOf(n), i = Pu(e.label, t.blankLabel, r);
6969
+ function ku(e, t) {
6970
+ let { blankId: n } = e, r = t.item.blanks.indexOf(n), i = Fu(e.label, t.blankLabel, r);
6945
6971
  if (t.structure.config.candidateMode === "none") {
6946
- let e = Au(t.answers, n);
6972
+ let e = ju(t.answers, n);
6947
6973
  return /* @__PURE__ */ a("input", {
6948
6974
  "aria-label": i,
6949
- className: Y["inline-input"],
6975
+ className: J["inline-input"],
6950
6976
  disabled: t.disabled,
6951
6977
  onChange: (e) => t.onAnswerChange(n, {
6952
6978
  kind: "text",
@@ -6955,23 +6981,23 @@ function Ou(e, t) {
6955
6981
  value: (e == null ? void 0 : e.kind) === "text" ? e.value : ""
6956
6982
  });
6957
6983
  }
6958
- if (t.structure.config.candidateMode === "sharedPool") return ku(n, i, t);
6959
- let o = Au(t.answers, n), s = Mu(t.item, n, t.structure.config.candidateMode, o);
6984
+ if (t.structure.config.candidateMode === "sharedPool") return Au(n, i, t);
6985
+ let o = ju(t.answers, n), s = Nu(t.item, n, t.structure.config.candidateMode, o);
6960
6986
  return /* @__PURE__ */ a("span", {
6961
6987
  "aria-label": i,
6962
- className: Y["inline-blank-underline"],
6963
- children: s ? /* @__PURE__ */ a(K, {
6964
- className: Y["inline-blank-content"],
6988
+ className: J["inline-blank-underline"],
6989
+ children: s ? /* @__PURE__ */ a(G, {
6990
+ className: J["inline-blank-content"],
6965
6991
  content: s.content
6966
6992
  }) : i
6967
6993
  });
6968
6994
  }
6969
- function ku(e, t, n) {
6995
+ function Au(e, t, n) {
6970
6996
  var r, i;
6971
- let s = Au(n.answers, e), c = (r = ((s == null ? void 0 : s.kind) === "option" ? s.optionIds : []).slice(0, 1)[0]) == null ? "" : r, l = Nu(n.answers, e);
6997
+ let s = ju(n.answers, e), c = (r = ((s == null ? void 0 : s.kind) === "option" ? s.optionIds : []).slice(0, 1)[0]) == null ? "" : r, l = Pu(n.answers, e);
6972
6998
  return /* @__PURE__ */ o("select", {
6973
6999
  "aria-label": t,
6974
- className: Y["inline-select"],
7000
+ className: J["inline-select"],
6975
7001
  disabled: n.disabled,
6976
7002
  onChange: (t) => n.onAnswerChange(e, {
6977
7003
  kind: "option",
@@ -6988,11 +7014,11 @@ function ku(e, t, n) {
6988
7014
  }, e.optionId))]
6989
7015
  });
6990
7016
  }
6991
- function Au(e, t) {
7017
+ function ju(e, t) {
6992
7018
  var n;
6993
7019
  return (n = Object.entries(e).find(([e]) => e === t)) == null ? void 0 : n[1];
6994
7020
  }
6995
- function ju(e, t, n) {
7021
+ function Mu(e, t, n) {
6996
7022
  var r, i;
6997
7023
  if (n === "sharedPool") {
6998
7024
  var a;
@@ -7000,32 +7026,32 @@ function ju(e, t, n) {
7000
7026
  }
7001
7027
  return (r = (i = e.blankOptionGroups) == null || (i = i.find((e) => e.blankId === t)) == null ? void 0 : i.options) == null ? [] : r;
7002
7028
  }
7003
- function Mu(e, t, n, r) {
7029
+ function Nu(e, t, n, r) {
7004
7030
  let i = (r == null ? void 0 : r.kind) === "option" ? r.optionIds[0] : void 0;
7005
- if (i) return ju(e, t, n).find((e) => e.optionId === i);
7031
+ if (i) return Mu(e, t, n).find((e) => e.optionId === i);
7006
7032
  }
7007
- function Nu(e, t) {
7033
+ function Pu(e, t) {
7008
7034
  let n = /* @__PURE__ */ new Set(), r = Object.entries(e);
7009
7035
  for (let [e, i] of r) if (e !== t && i.kind === "option") for (let e of i.optionIds) n.add(e);
7010
7036
  return n;
7011
7037
  }
7012
- function Pu(e, t, n) {
7038
+ function Fu(e, t, n) {
7013
7039
  return e || `${t} ${n + 1}`;
7014
7040
  }
7015
7041
  //#endregion
7016
7042
  //#region src/question/player/QuestionFillTextPlayer.tsx
7017
- function Fu({ disabled: e, element: t, item: n, messages: r, onChange: i, response: s, showAnswer: c }) {
7018
- let l = zi(n, t, !0), u = lu(l), d = xl(s, t, l.blanks), f = u.map((e, t) => ({
7019
- contents: e.contents.map((e, n) => /* @__PURE__ */ a(K, { content: e }, `group-${t}-answer-${n}`)),
7020
- marker: ru(e.blankIds, l.blanks, r.blankLabel)
7043
+ function Iu({ disabled: e, element: t, item: n, messages: r, onChange: i, response: s, showAnswer: c }) {
7044
+ let l = Bi(n, t, !0), u = uu(l), d = xl(s, t, l.blanks), f = u.map((e, t) => ({
7045
+ contents: e.contents.map((e, n) => /* @__PURE__ */ a(G, { content: e }, `group-${t}-answer-${n}`)),
7046
+ marker: iu(e.blankIds, l.blanks, r.blankLabel)
7021
7047
  }));
7022
7048
  function p(e, t) {
7023
7049
  i(k(k({}, d), {}, { answers: k(k({}, d.answers), {}, { [e]: t }) }));
7024
7050
  }
7025
7051
  return /* @__PURE__ */ o("div", {
7026
- className: W["fill-text"],
7052
+ className: U["fill-text"],
7027
7053
  children: [
7028
- /* @__PURE__ */ a(Du, {
7054
+ /* @__PURE__ */ a(Ou, {
7029
7055
  answers: d.answers,
7030
7056
  disabled: e,
7031
7057
  item: l,
@@ -7033,41 +7059,41 @@ function Fu({ disabled: e, element: t, item: n, messages: r, onChange: i, respon
7033
7059
  onAnswerChange: p,
7034
7060
  structure: t
7035
7061
  }),
7036
- Iu(l, t.config.candidateMode, r.candidateOptions),
7037
- Lu({
7062
+ Lu(l, t.config.candidateMode, r.candidateOptions),
7063
+ Ru({
7038
7064
  disabled: e,
7039
7065
  item: l,
7040
7066
  onAnswerChange: p,
7041
7067
  responseItem: d
7042
7068
  }),
7043
- c ? /* @__PURE__ */ a(q, {
7069
+ c ? /* @__PURE__ */ a(K, {
7044
7070
  groups: f,
7045
7071
  title: r.standardAnswer
7046
7072
  }) : null
7047
7073
  ]
7048
7074
  });
7049
7075
  }
7050
- function Iu(e, t, n) {
7076
+ function Lu(e, t, n) {
7051
7077
  var r;
7052
7078
  let i = (r = e.candidateOptions) == null ? [] : r;
7053
7079
  return t !== "sharedPool" || i.length === 0 ? null : /* @__PURE__ */ o("div", {
7054
- className: Y["shared-candidate-section"],
7080
+ className: J["shared-candidate-section"],
7055
7081
  children: [/* @__PURE__ */ a("span", {
7056
- className: Y["shared-candidate-title"],
7082
+ className: J["shared-candidate-title"],
7057
7083
  children: n
7058
7084
  }), /* @__PURE__ */ a("ol", {
7059
- className: Y["shared-candidate-list"],
7085
+ className: J["shared-candidate-list"],
7060
7086
  children: i.map((e) => /* @__PURE__ */ a("li", {
7061
- className: Y["shared-candidate-item"],
7062
- children: /* @__PURE__ */ a(K, {
7063
- className: Y["shared-candidate-content"],
7087
+ className: J["shared-candidate-item"],
7088
+ children: /* @__PURE__ */ a(G, {
7089
+ className: J["shared-candidate-content"],
7064
7090
  content: e.content
7065
7091
  })
7066
7092
  }, e.optionId))
7067
7093
  })]
7068
7094
  });
7069
7095
  }
7070
- function Lu({ disabled: e, item: t, onAnswerChange: n, responseItem: r }) {
7096
+ function Ru({ disabled: e, item: t, onAnswerChange: n, responseItem: r }) {
7071
7097
  let i = t.blanks.reduce((e, n, r) => {
7072
7098
  var i;
7073
7099
  let a = (i = t.blankOptionGroups) == null ? void 0 : i.find((e) => e.blankId === n);
@@ -7077,8 +7103,8 @@ function Lu({ disabled: e, item: t, onAnswerChange: n, responseItem: r }) {
7077
7103
  }] : e;
7078
7104
  }, []);
7079
7105
  return i.length === 0 ? null : /* @__PURE__ */ a("div", {
7080
- className: Y["per-blank-candidate-options"],
7081
- children: i.map(({ group: t, marker: i }) => Ru({
7106
+ className: J["per-blank-candidate-options"],
7107
+ children: i.map(({ group: t, marker: i }) => zu({
7082
7108
  disabled: e,
7083
7109
  group: t,
7084
7110
  marker: i,
@@ -7087,17 +7113,17 @@ function Lu({ disabled: e, item: t, onAnswerChange: n, responseItem: r }) {
7087
7113
  }))
7088
7114
  });
7089
7115
  }
7090
- function Ru({ disabled: e, group: t, marker: n, onAnswerChange: r, responseItem: i }) {
7116
+ function zu({ disabled: e, group: t, marker: n, onAnswerChange: r, responseItem: i }) {
7091
7117
  let s = i.answers[t.blankId];
7092
7118
  return /* @__PURE__ */ o("section", {
7093
7119
  "aria-label": n,
7094
- className: Y["per-blank-candidate-group"],
7120
+ className: J["per-blank-candidate-group"],
7095
7121
  children: [/* @__PURE__ */ a("span", {
7096
- className: Y["per-blank-candidate-title"],
7122
+ className: J["per-blank-candidate-title"],
7097
7123
  children: n
7098
7124
  }), /* @__PURE__ */ a("div", {
7099
- className: Y["per-blank-candidate-list"],
7100
- children: t.options.map((n) => zu({
7125
+ className: J["per-blank-candidate-list"],
7126
+ children: t.options.map((n) => Bu({
7101
7127
  activeAnswer: s,
7102
7128
  blankId: t.blankId,
7103
7129
  disabled: e,
@@ -7107,19 +7133,19 @@ function Ru({ disabled: e, group: t, marker: n, onAnswerChange: r, responseItem:
7107
7133
  })]
7108
7134
  }, t.blankId);
7109
7135
  }
7110
- function zu({ activeAnswer: e, blankId: t, disabled: n, onAnswerChange: r, option: i }) {
7136
+ function Bu({ activeAnswer: e, blankId: t, disabled: n, onAnswerChange: r, option: i }) {
7111
7137
  let o = (e == null ? void 0 : e.kind) === "option" && e.optionIds.includes(i.optionId);
7112
7138
  return /* @__PURE__ */ a("button", {
7113
7139
  "aria-pressed": o,
7114
- className: o ? Y.selected : void 0,
7140
+ className: o ? J.selected : void 0,
7115
7141
  "data-selected": o ? "true" : void 0,
7116
7142
  disabled: n,
7117
7143
  onClick: () => r(t, Ml(e, i.optionId, "single")),
7118
7144
  type: "button",
7119
- children: /* @__PURE__ */ a(K, { content: i.content })
7145
+ children: /* @__PURE__ */ a(G, { content: i.content })
7120
7146
  }, i.optionId);
7121
7147
  }
7122
- var X = {
7148
+ var Y = {
7123
7149
  "choice-button": "_choice-button_zwndo_1",
7124
7150
  "table-row-button": "_table-row-button_zwndo_2",
7125
7151
  "judgement-button": "_judgement-button_zwndo_26",
@@ -7135,8 +7161,8 @@ var X = {
7135
7161
  };
7136
7162
  //#endregion
7137
7163
  //#region src/question/player/QuestionJudgementGroupPlayer.tsx
7138
- function Bu({ disabled: e, element: t, item: n, messages: r, onChange: i, response: s, showAnswer: c }) {
7139
- let l = Cl(s, t.elementKey), u = Ti(t.config.judgeAnswerMode), d = [{
7164
+ function Vu({ disabled: e, element: t, item: n, messages: r, onChange: i, response: s, showAnswer: c }) {
7165
+ let l = Cl(s, t.elementKey), u = Ei(t.config.judgeAnswerMode), d = [{
7140
7166
  contents: n.answers.filter((e) => e.trim() !== ""),
7141
7167
  marker: ""
7142
7168
  }];
@@ -7144,17 +7170,17 @@ function Bu({ disabled: e, element: t, item: n, messages: r, onChange: i, respon
7144
7170
  i(k(k({}, l), {}, { selectedValues: l.selectedValues.includes(e) ? [] : [e] }));
7145
7171
  }
7146
7172
  return /* @__PURE__ */ o("div", {
7147
- className: G.element,
7173
+ className: W.element,
7148
7174
  children: [/* @__PURE__ */ a("ol", {
7149
- className: U(G["judgement-list"], X["judgement-list"]),
7175
+ className: ru(W["judgement-list"], Y["judgement-list"]),
7150
7176
  children: u.map((t) => {
7151
7177
  let n = l.selectedValues.includes(t);
7152
7178
  return /* @__PURE__ */ a("li", {
7153
- className: U(G["judgement-item"], X["judgement-option"], n && X.selected),
7179
+ className: ru(W["judgement-item"], Y["judgement-option"], n && Y.selected),
7154
7180
  "data-selected": n ? "true" : void 0,
7155
7181
  children: /* @__PURE__ */ a("button", {
7156
7182
  "aria-pressed": n,
7157
- className: X["judgement-button"],
7183
+ className: Y["judgement-button"],
7158
7184
  disabled: e,
7159
7185
  onClick: () => f(t),
7160
7186
  type: "button",
@@ -7162,7 +7188,7 @@ function Bu({ disabled: e, element: t, item: n, messages: r, onChange: i, respon
7162
7188
  })
7163
7189
  }, t);
7164
7190
  })
7165
- }), c ? /* @__PURE__ */ a(q, {
7191
+ }), c ? /* @__PURE__ */ a(K, {
7166
7192
  groups: d,
7167
7193
  title: r.standardAnswer
7168
7194
  }) : null]
@@ -7170,8 +7196,8 @@ function Bu({ disabled: e, element: t, item: n, messages: r, onChange: i, respon
7170
7196
  }
7171
7197
  //#endregion
7172
7198
  //#region src/question/renderers/lineConnectAnswers.tsx
7173
- function Vu(e) {
7174
- let t = Hu(e);
7199
+ function Hu(e) {
7200
+ let t = Uu(e);
7175
7201
  return e.columns.reduce((n, r, i) => {
7176
7202
  let o = r.items.map((n, o) => {
7177
7203
  var s;
@@ -7179,14 +7205,14 @@ function Vu(e) {
7179
7205
  contents: ((s = e.answers[n.itemId]) == null ? [] : s).map((e) => {
7180
7206
  let n = t.get(e);
7181
7207
  return n && ze(i, n.columnIndex) ? n.item : void 0;
7182
- }).filter((e) => !!e).map((e, t) => /* @__PURE__ */ a(K, { content: e.content }, `${n.itemId}-${e.itemId}-${t}`)),
7183
- marker: Ci(r.labelStyle, o)
7208
+ }).filter((e) => !!e).map((e, t) => /* @__PURE__ */ a(G, { content: e.content }, `${n.itemId}-${e.itemId}-${t}`)),
7209
+ marker: wi(r.labelStyle, o)
7184
7210
  };
7185
7211
  });
7186
7212
  return [...n, ...o];
7187
7213
  }, []);
7188
7214
  }
7189
- function Hu(e) {
7215
+ function Uu(e) {
7190
7216
  return e.columns.reduce((e, t, n) => (t.items.forEach((t) => e.set(t.itemId, {
7191
7217
  columnIndex: n,
7192
7218
  item: t
@@ -7194,7 +7220,7 @@ function Hu(e) {
7194
7220
  }
7195
7221
  //#endregion
7196
7222
  //#region src/question/player/QuestionLineConnectPlayer.tsx
7197
- function Uu({ disabled: e, item: t, messages: n, onChange: r, response: i, showAnswer: s }) {
7223
+ function Wu({ disabled: e, item: t, messages: n, onChange: r, response: i, showAnswer: s }) {
7198
7224
  let [c, u] = m(null), [h, g] = m(null), _ = p(null), v = p(/* @__PURE__ */ new Map()), y = Tl(i, t.elementKey), b = { gridTemplateColumns: `repeat(${t.columns.length}, minmax(12rem, 1fr))` }, x = f(() => ic(t, y.connections), [t, y.connections]), S = f(() => JSON.stringify({
7199
7225
  columns: t.columns.map((e) => e.items.map((e) => e.itemId)),
7200
7226
  connections: y.connections
@@ -7255,7 +7281,7 @@ function Uu({ disabled: e, item: t, messages: n, onChange: r, response: i, showA
7255
7281
  });
7256
7282
  }
7257
7283
  return /* @__PURE__ */ o("div", {
7258
- className: G.element,
7284
+ className: W.element,
7259
7285
  children: [/* @__PURE__ */ o("div", {
7260
7286
  className: B.board,
7261
7287
  "data-testid": "line-connect-player-board",
@@ -7289,9 +7315,9 @@ function Uu({ disabled: e, item: t, messages: n, onChange: r, response: i, showA
7289
7315
  r + 1
7290
7316
  ]
7291
7317
  }), t.items.map((n, i) => {
7292
- let s = Ci(t.labelStyle, i), l = (c == null ? void 0 : c.itemId) === n.itemId;
7318
+ let s = wi(t.labelStyle, i), l = (c == null ? void 0 : c.itemId) === n.itemId;
7293
7319
  return /* @__PURE__ */ a("div", {
7294
- className: U(B.item, l && B.selected),
7320
+ className: ru(B.item, l && B.selected),
7295
7321
  "data-selected": l ? "true" : void 0,
7296
7322
  "data-testid": `line-connect-player-item-${n.itemId}`,
7297
7323
  ref: w(n.itemId),
@@ -7304,21 +7330,21 @@ function Uu({ disabled: e, item: t, messages: n, onChange: r, response: i, showA
7304
7330
  children: [s ? /* @__PURE__ */ a("span", {
7305
7331
  className: B.marker,
7306
7332
  children: s
7307
- }) : null, /* @__PURE__ */ a(K, { content: n.content })]
7333
+ }) : null, /* @__PURE__ */ a(G, { content: n.content })]
7308
7334
  })
7309
7335
  }, n.itemId);
7310
7336
  })]
7311
7337
  }, t.columnId))
7312
7338
  })]
7313
- }), s ? /* @__PURE__ */ a(q, {
7314
- groups: Vu(t),
7339
+ }), s ? /* @__PURE__ */ a(K, {
7340
+ groups: Hu(t),
7315
7341
  title: n.standardAnswer
7316
7342
  }) : null]
7317
7343
  });
7318
7344
  }
7319
7345
  //#endregion
7320
7346
  //#region src/question/renderers/matchingAnswers.tsx
7321
- function Wu(e) {
7347
+ function Gu(e) {
7322
7348
  var t, n;
7323
7349
  let r = e.columns[0], i = e.columns[1], o = new Map((t = i == null ? void 0 : i.items.map((e) => [e.itemId, e])) == null ? [] : t);
7324
7350
  return ((n = r == null ? void 0 : r.items) == null ? [] : n).map((t, n) => {
@@ -7327,12 +7353,12 @@ function Wu(e) {
7327
7353
  contents: ((i = e.answers[t.itemId]) == null ? [] : i).reduce((e, t) => {
7328
7354
  let n = o.get(t);
7329
7355
  return n ? [...e, n] : e;
7330
- }, []).map((e, n) => /* @__PURE__ */ a(K, { content: e.content }, `${t.itemId}-${e.itemId}-${n}`)),
7331
- marker: wi((s = r == null ? void 0 : r.labelStyle) == null ? "number" : s, n)
7356
+ }, []).map((e, n) => /* @__PURE__ */ a(G, { content: e.content }, `${t.itemId}-${e.itemId}-${n}`)),
7357
+ marker: Ti((s = r == null ? void 0 : r.labelStyle) == null ? "number" : s, n)
7332
7358
  };
7333
7359
  });
7334
7360
  }
7335
- var Gu = {
7361
+ var Ku = {
7336
7362
  board: "_board_1q6ar_1",
7337
7363
  "matched-rows": "_matched-rows_1q6ar_6",
7338
7364
  "matched-row": "_matched-row_1q6ar_6",
@@ -7345,8 +7371,8 @@ var Gu = {
7345
7371
  };
7346
7372
  //#endregion
7347
7373
  //#region src/question/player/QuestionMatchingPlayer.tsx
7348
- function Ku({ disabled: e, item: t, messages: n, onChange: r, response: i, showAnswer: s }) {
7349
- let [c, l] = m(null), u = El(i, t.elementKey), d = qu(t, u.connections);
7374
+ function qu({ disabled: e, item: t, messages: n, onChange: r, response: i, showAnswer: s }) {
7375
+ let [c, l] = m(null), u = El(i, t.elementKey), d = Ju(t, u.connections);
7350
7376
  function f(t, n) {
7351
7377
  if (e) return;
7352
7378
  let i = c ? pt(c, {
@@ -7366,50 +7392,50 @@ function Ku({ disabled: e, item: t, messages: n, onChange: r, response: i, showA
7366
7392
  let r = (c == null ? void 0 : c.itemId) === t.item.itemId;
7367
7393
  return /* @__PURE__ */ o("button", {
7368
7394
  "aria-pressed": r,
7369
- className: U(Gu.item, r && Gu.selected, n && Gu.matched),
7395
+ className: ru(Ku.item, r && Ku.selected, n && Ku.matched),
7370
7396
  "data-testid": `matching-player-item-${t.item.itemId}`,
7371
7397
  disabled: e,
7372
7398
  onClick: () => f(t.columnIndex, t.item.itemId),
7373
7399
  type: "button",
7374
7400
  children: [t.marker ? /* @__PURE__ */ a("span", {
7375
- className: Gu.marker,
7401
+ className: Ku.marker,
7376
7402
  children: t.marker
7377
- }) : null, /* @__PURE__ */ a(K, { content: t.item.content })]
7403
+ }) : null, /* @__PURE__ */ a(G, { content: t.item.content })]
7378
7404
  }, t.item.itemId);
7379
7405
  }
7380
7406
  return /* @__PURE__ */ o("div", {
7381
- className: G.element,
7407
+ className: W.element,
7382
7408
  children: [/* @__PURE__ */ o("div", {
7383
- className: Gu.board,
7409
+ className: Ku.board,
7384
7410
  children: [d.rows.length > 0 ? /* @__PURE__ */ a("div", {
7385
- className: Gu["matched-rows"],
7411
+ className: Ku["matched-rows"],
7386
7412
  children: d.rows.map((e) => /* @__PURE__ */ o("div", {
7387
- className: Gu["matched-row"],
7413
+ className: Ku["matched-row"],
7388
7414
  "data-testid": `matching-player-row-${e.from.item.itemId}-${e.to.item.itemId}`,
7389
7415
  children: [p(e.from, !0), p(e.to, !0)]
7390
7416
  }, `${e.from.item.itemId}-${e.to.item.itemId}`))
7391
7417
  }) : null, d.unmatchedColumns.some((e) => e.length > 0) ? /* @__PURE__ */ a("div", {
7392
- className: Gu.columns,
7418
+ className: Ku.columns,
7393
7419
  children: d.unmatchedColumns.map((e, n) => {
7394
7420
  var r, i;
7395
7421
  return /* @__PURE__ */ a("section", {
7396
- className: Gu.column,
7422
+ className: Ku.column,
7397
7423
  children: e.map((e) => p(e, !1))
7398
7424
  }, (r = (i = t.columns[n]) == null ? void 0 : i.columnId) == null ? n : r);
7399
7425
  })
7400
7426
  }) : null]
7401
- }), s ? /* @__PURE__ */ a(q, {
7402
- groups: Wu(t),
7427
+ }), s ? /* @__PURE__ */ a(K, {
7428
+ groups: Gu(t),
7403
7429
  title: n.standardAnswer
7404
7430
  }) : null]
7405
7431
  });
7406
7432
  }
7407
- function qu(e, t) {
7433
+ function Ju(e, t) {
7408
7434
  var n;
7409
7435
  let r = e.columns.map((e, t) => e.items.map((n, r) => ({
7410
7436
  columnIndex: t,
7411
7437
  item: n,
7412
- marker: wi(e.labelStyle, r)
7438
+ marker: Ti(e.labelStyle, r)
7413
7439
  }))), i = r.reduce((e, t) => (t.forEach((t) => e.set(t.item.itemId, t)), e), /* @__PURE__ */ new Map()), a = /* @__PURE__ */ new Set(), o = ((n = r[0]) == null ? [] : n).reduce((e, n) => {
7414
7440
  var r;
7415
7441
  let o = (r = t[n.item.itemId]) == null ? void 0 : r[0], s = o ? i.get(o) : void 0;
@@ -7425,17 +7451,17 @@ function qu(e, t) {
7425
7451
  }
7426
7452
  //#endregion
7427
7453
  //#region src/question/renderers/optionGroupAnswers.tsx
7428
- function Ju(e, t) {
7429
- let n = Di(t, e.config.optionLabelStyle);
7454
+ function Yu(e, t) {
7455
+ let n = Oi(t, e.config.optionLabelStyle);
7430
7456
  return e.config.renderer === "table" ? n.map((e) => ({
7431
- contents: e.cells.map((t, n) => /* @__PURE__ */ a(K, { content: t }, `${e.optionId}-cell-${n}`)),
7457
+ contents: e.cells.map((t, n) => /* @__PURE__ */ a(G, { content: t }, `${e.optionId}-cell-${n}`)),
7432
7458
  marker: e.marker
7433
7459
  })) : n.map((e) => ({
7434
- contents: [/* @__PURE__ */ a(K, { content: e.standardContent }, `answer-${e.optionId}`)],
7460
+ contents: [/* @__PURE__ */ a(G, { content: e.standardContent }, `answer-${e.optionId}`)],
7435
7461
  marker: e.marker
7436
7462
  }));
7437
7463
  }
7438
- var Yu = {
7464
+ var Xu = {
7439
7465
  "table-wrap": "_table-wrap_n67ah_1",
7440
7466
  table: "_table_n67ah_1",
7441
7467
  "table-option-column": "_table-option-column_n67ah_17",
@@ -7443,81 +7469,81 @@ var Yu = {
7443
7469
  };
7444
7470
  //#endregion
7445
7471
  //#region src/question/player/QuestionOptionGroupPlayer.tsx
7446
- function Xu({ disabled: e, element: t, item: n, messages: r, onChange: i, response: s, showAnswer: c }) {
7447
- let l = yl(s, t.elementKey), u = Ei(n, t.config.optionLabelStyle);
7472
+ function Zu({ disabled: e, element: t, item: n, messages: r, onChange: i, response: s, showAnswer: c }) {
7473
+ let l = yl(s, t.elementKey), u = Di(n, t.config.optionLabelStyle);
7448
7474
  function d(e) {
7449
7475
  i(k(k({}, l), {}, { selectedOptionIds: jl(l.selectedOptionIds, e, t.config.selectionType) }));
7450
7476
  }
7451
7477
  if (t.config.renderer === "table") {
7452
- let i = Ju(t, n);
7478
+ let i = Yu(t, n);
7453
7479
  return /* @__PURE__ */ o("div", {
7454
- className: G.element,
7480
+ className: W.element,
7455
7481
  children: [/* @__PURE__ */ a("div", {
7456
- className: Yu["table-wrap"],
7482
+ className: Xu["table-wrap"],
7457
7483
  children: /* @__PURE__ */ o("table", {
7458
- className: Yu.table,
7484
+ className: Xu.table,
7459
7485
  children: [
7460
- /* @__PURE__ */ o("colgroup", { children: [/* @__PURE__ */ a("col", { className: Yu["table-option-column"] }), n.columns.map((e) => /* @__PURE__ */ a("col", {}, e.id))] }),
7461
- /* @__PURE__ */ a("thead", { children: /* @__PURE__ */ o("tr", { children: [/* @__PURE__ */ a("th", { children: r.option }), n.columns.map((e) => /* @__PURE__ */ a("th", { children: /* @__PURE__ */ a(K, { content: e.content }) }, e.id))] }) }),
7486
+ /* @__PURE__ */ o("colgroup", { children: [/* @__PURE__ */ a("col", { className: Xu["table-option-column"] }), n.columns.map((e) => /* @__PURE__ */ a("col", {}, e.id))] }),
7487
+ /* @__PURE__ */ a("thead", { children: /* @__PURE__ */ o("tr", { children: [/* @__PURE__ */ a("th", { children: r.option }), n.columns.map((e) => /* @__PURE__ */ a("th", { children: /* @__PURE__ */ a(G, { content: e.content }) }, e.id))] }) }),
7462
7488
  /* @__PURE__ */ a("tbody", { children: u.map((t) => {
7463
7489
  let n = l.selectedOptionIds.includes(t.optionId);
7464
7490
  return /* @__PURE__ */ o("tr", {
7465
- className: X["table-choice-row"],
7491
+ className: Y["table-choice-row"],
7466
7492
  "data-selected": n ? "true" : void 0,
7467
7493
  children: [/* @__PURE__ */ a("td", { children: /* @__PURE__ */ a("button", {
7468
- className: X["table-row-button"],
7494
+ className: Y["table-row-button"],
7469
7495
  disabled: e,
7470
7496
  "aria-pressed": n,
7471
7497
  onClick: () => d(t.optionId),
7472
7498
  type: "button",
7473
7499
  children: /* @__PURE__ */ a("span", {
7474
- className: U(G.marker, X["table-option-marker"]),
7500
+ className: ru(W.marker, Y["table-option-marker"]),
7475
7501
  "data-selected": n ? "true" : void 0,
7476
7502
  children: t.marker
7477
7503
  })
7478
7504
  }) }), t.cells.map((r, i) => /* @__PURE__ */ a("td", { children: /* @__PURE__ */ a("button", {
7479
- className: X["table-row-button"],
7505
+ className: Y["table-row-button"],
7480
7506
  disabled: e,
7481
7507
  "aria-pressed": n,
7482
7508
  onClick: () => d(t.optionId),
7483
7509
  type: "button",
7484
- children: /* @__PURE__ */ a(K, { content: r })
7510
+ children: /* @__PURE__ */ a(G, { content: r })
7485
7511
  }) }, `${t.optionId}-cell-${i}`))]
7486
7512
  }, t.optionId);
7487
7513
  }) })
7488
7514
  ]
7489
7515
  })
7490
- }), c ? /* @__PURE__ */ a(q, {
7516
+ }), c ? /* @__PURE__ */ a(K, {
7491
7517
  groups: i,
7492
7518
  title: r.standardAnswer
7493
7519
  }) : null]
7494
7520
  });
7495
7521
  }
7496
- let f = Ju(t, n);
7522
+ let f = Yu(t, n);
7497
7523
  return /* @__PURE__ */ o("div", {
7498
- className: G.element,
7524
+ className: W.element,
7499
7525
  children: [/* @__PURE__ */ a("ol", {
7500
- className: G["option-list"],
7526
+ className: W["option-list"],
7501
7527
  children: u.map((t) => {
7502
7528
  let n = l.selectedOptionIds.includes(t.optionId);
7503
7529
  return /* @__PURE__ */ a("li", {
7504
- className: U(G["option-item"], X["choice-option"], n && X.selected),
7530
+ className: ru(W["option-item"], Y["choice-option"], n && Y.selected),
7505
7531
  "data-selected": n ? "true" : void 0,
7506
7532
  children: /* @__PURE__ */ o("button", {
7507
- className: X["choice-button"],
7533
+ className: Y["choice-button"],
7508
7534
  disabled: e,
7509
7535
  "aria-pressed": n,
7510
7536
  onClick: () => d(t.optionId),
7511
7537
  type: "button",
7512
7538
  children: [/* @__PURE__ */ a("span", {
7513
- className: U(G.marker, X["option-marker"]),
7539
+ className: ru(W.marker, Y["option-marker"]),
7514
7540
  "data-selected": n ? "true" : void 0,
7515
7541
  children: t.marker
7516
- }), /* @__PURE__ */ a(K, { content: t.standardContent })]
7542
+ }), /* @__PURE__ */ a(G, { content: t.standardContent })]
7517
7543
  })
7518
7544
  }, t.optionId);
7519
7545
  })
7520
- }), c ? /* @__PURE__ */ a(q, {
7546
+ }), c ? /* @__PURE__ */ a(K, {
7521
7547
  groups: f,
7522
7548
  title: r.standardAnswer
7523
7549
  }) : null]
@@ -7525,47 +7551,47 @@ function Xu({ disabled: e, element: t, item: n, messages: r, onChange: i, respon
7525
7551
  }
7526
7552
  //#endregion
7527
7553
  //#region src/question/renderers/orderingAnswerGroups.tsx
7528
- function Zu(e) {
7554
+ function Qu(e) {
7529
7555
  let t = new Map(e.sortOptions.map((e) => [e.id, e]));
7530
7556
  return e.answers.map((e, n) => {
7531
7557
  let r = t.get(e);
7532
7558
  return {
7533
- contents: r ? [/* @__PURE__ */ a(K, { content: r.content }, e)] : [],
7559
+ contents: r ? [/* @__PURE__ */ a(G, { content: r.content }, e)] : [],
7534
7560
  marker: String(n + 1)
7535
7561
  };
7536
7562
  });
7537
7563
  }
7538
7564
  //#endregion
7539
7565
  //#region src/question/player/QuestionOrderingPlayer.tsx
7540
- function Qu({ disabled: e, item: t, messages: n, onChange: r, response: i, showAnswer: s }) {
7566
+ function $u({ disabled: e, item: t, messages: n, onChange: r, response: i, showAnswer: s }) {
7541
7567
  let c = Dl(i, t), l = new Map(t.sortOptions.map((e) => [e.id, e])), u = c.orderedOptionIds.map((e) => l.get(e)).filter((e) => !!e);
7542
7568
  function d(e, n) {
7543
7569
  r(k(k({}, c), {}, { orderedOptionIds: Il(c.orderedOptionIds, t, e, n) }));
7544
7570
  }
7545
7571
  return /* @__PURE__ */ o("div", {
7546
- className: G.element,
7572
+ className: W.element,
7547
7573
  children: [/* @__PURE__ */ a("ol", {
7548
- className: G["option-list"],
7574
+ className: W["option-list"],
7549
7575
  children: u.map((t, r) => /* @__PURE__ */ o("li", {
7550
- className: U(G["option-item"], X["choice-option"]),
7576
+ className: ru(W["option-item"], Y["choice-option"]),
7551
7577
  children: [
7552
7578
  /* @__PURE__ */ a("span", {
7553
- className: G.marker,
7579
+ className: W.marker,
7554
7580
  children: r + 1
7555
7581
  }),
7556
- /* @__PURE__ */ a(K, { content: t.content }),
7582
+ /* @__PURE__ */ a(G, { content: t.content }),
7557
7583
  /* @__PURE__ */ o("span", {
7558
- className: X["ordering-controls"],
7584
+ className: Y["ordering-controls"],
7559
7585
  children: [/* @__PURE__ */ a("button", {
7560
7586
  "aria-label": `${n.moveUp} ${r + 1}`,
7561
- className: X["ordering-button"],
7587
+ className: Y["ordering-button"],
7562
7588
  disabled: e || r === 0,
7563
7589
  onClick: () => d(t.id, -1),
7564
7590
  type: "button",
7565
7591
  children: "\u2191"
7566
7592
  }), /* @__PURE__ */ a("button", {
7567
7593
  "aria-label": `${n.moveDown} ${r + 1}`,
7568
- className: X["ordering-button"],
7594
+ className: Y["ordering-button"],
7569
7595
  disabled: e || r === u.length - 1,
7570
7596
  onClick: () => d(t.id, 1),
7571
7597
  type: "button",
@@ -7574,13 +7600,13 @@ function Qu({ disabled: e, item: t, messages: n, onChange: r, response: i, showA
7574
7600
  })
7575
7601
  ]
7576
7602
  }, t.id))
7577
- }), s ? /* @__PURE__ */ a(q, {
7578
- groups: Zu(t),
7603
+ }), s ? /* @__PURE__ */ a(K, {
7604
+ groups: Qu(t),
7579
7605
  title: n.standardAnswer
7580
7606
  }) : null]
7581
7607
  });
7582
7608
  }
7583
- var $u = {
7609
+ var ed = {
7584
7610
  content: "_content_63948_1",
7585
7611
  paragraph: "_paragraph_63948_10",
7586
7612
  marker: "_marker_63948_14",
@@ -7590,21 +7616,21 @@ var $u = {
7590
7616
  };
7591
7617
  //#endregion
7592
7618
  //#region src/question/renderers/QuestionTextMarkerContent.tsx
7593
- function ed({ answerMarkers: e = [], content: t, disabled: n = !1, onMarkerClick: r, selectedMarkers: i = [], showAnswer: o = !1 }) {
7619
+ function td({ answerMarkers: e = [], content: t, disabled: n = !1, onMarkerClick: r, selectedMarkers: i = [], showAnswer: o = !1 }) {
7594
7620
  let c = t.json.length ? t.json : [{
7595
7621
  children: [{ text: t.text }],
7596
7622
  type: "paragraph"
7597
7623
  }];
7598
7624
  return /* @__PURE__ */ a("div", {
7599
- className: $u.content,
7625
+ className: ed.content,
7600
7626
  children: c.map((e, t) => l(e, `node-${t}`))
7601
7627
  });
7602
7628
  function l(e, t) {
7603
- if (nd(e)) return u(e, t);
7604
- if (!td(e)) return null;
7629
+ if (rd(e)) return u(e, t);
7630
+ if (!nd(e)) return null;
7605
7631
  let n = e.children.map((e, n) => l(e, `${t}-${n}`));
7606
7632
  return e.type === "paragraph" ? /* @__PURE__ */ a("p", {
7607
- className: $u.paragraph,
7633
+ className: ed.paragraph,
7608
7634
  children: n
7609
7635
  }, t) : /* @__PURE__ */ a("span", { children: n }, t);
7610
7636
  }
@@ -7618,7 +7644,7 @@ function ed({ answerMarkers: e = [], content: t, disabled: n = !1, onMarkerClick
7618
7644
  let n = i.includes(t), a = o && e.includes(t);
7619
7645
  return {
7620
7646
  answer: a,
7621
- className: tc($u.marker, r ? $u["marker-button"] : "", n ? $u["marker-selected"] : "", a ? $u["marker-answer"] : ""),
7647
+ className: tc(ed.marker, r ? ed["marker-button"] : "", n ? ed["marker-selected"] : "", a ? ed["marker-answer"] : ""),
7622
7648
  selected: n
7623
7649
  };
7624
7650
  }
@@ -7644,21 +7670,21 @@ function ed({ answerMarkers: e = [], content: t, disabled: n = !1, onMarkerClick
7644
7670
  }, n);
7645
7671
  }
7646
7672
  }
7647
- function td(e) {
7673
+ function nd(e) {
7648
7674
  return !!(e && typeof e == "object" && "children" in e && Array.isArray(e.children));
7649
7675
  }
7650
- function nd(e) {
7676
+ function rd(e) {
7651
7677
  return !!(e && typeof e == "object" && "text" in e && typeof e.text == "string");
7652
7678
  }
7653
7679
  //#endregion
7654
7680
  //#region src/question/renderers/QuestionTextMarkerView.tsx
7655
- function rd({ item: e, messages: t, showAnswer: n }) {
7681
+ function id({ item: e, messages: t, showAnswer: n }) {
7656
7682
  let r = Vt(e.content.json).filter((t) => e.answers.includes(t.markerId)).map((e) => e.text);
7657
- return /* @__PURE__ */ o(i, { children: [/* @__PURE__ */ a(ed, {
7683
+ return /* @__PURE__ */ o(i, { children: [/* @__PURE__ */ a(td, {
7658
7684
  answerMarkers: e.answers,
7659
7685
  content: e.content,
7660
7686
  showAnswer: n
7661
- }), n ? /* @__PURE__ */ a(q, {
7687
+ }), n ? /* @__PURE__ */ a(K, {
7662
7688
  groups: [{
7663
7689
  contents: r,
7664
7690
  marker: t.standardAnswer
@@ -7668,13 +7694,13 @@ function rd({ item: e, messages: t, showAnswer: n }) {
7668
7694
  }
7669
7695
  //#endregion
7670
7696
  //#region src/question/player/QuestionTextMarkerPlayer.tsx
7671
- function id({ disabled: e, item: t, messages: n, onChange: r, response: i, showAnswer: o }) {
7697
+ function ad({ disabled: e, item: t, messages: n, onChange: r, response: i, showAnswer: o }) {
7672
7698
  let s = Ol(i, t.elementKey);
7673
- return o ? /* @__PURE__ */ a(rd, {
7699
+ return o ? /* @__PURE__ */ a(id, {
7674
7700
  item: t,
7675
7701
  messages: n,
7676
7702
  showAnswer: o
7677
- }) : /* @__PURE__ */ a(ed, {
7703
+ }) : /* @__PURE__ */ a(td, {
7678
7704
  answerMarkers: t.answers,
7679
7705
  content: t.content,
7680
7706
  disabled: e,
@@ -7684,26 +7710,26 @@ function id({ disabled: e, item: t, messages: n, onChange: r, response: i, showA
7684
7710
  }
7685
7711
  //#endregion
7686
7712
  //#region src/question/renderers/wordBuilderAnswers.tsx
7687
- function ad(e, t) {
7713
+ function od(e, t) {
7688
7714
  return e.blanks.reduce((n, r) => {
7689
7715
  var i;
7690
7716
  let o = (i = e.answers[r]) == null ? void 0 : i.trim();
7691
7717
  return o ? [...n, {
7692
- contents: [/* @__PURE__ */ a(K, { content: M(o) }, `${r}-answer`)],
7693
- marker: ru([r], e.blanks, t)
7718
+ contents: [/* @__PURE__ */ a(G, { content: M(o) }, `${r}-answer`)],
7719
+ marker: iu([r], e.blanks, t)
7694
7720
  }] : n;
7695
7721
  }, []);
7696
7722
  }
7697
7723
  //#endregion
7698
7724
  //#region src/question/player/QuestionPlayerWordBuilder.module.css
7699
- var od = {
7725
+ var sd = {
7700
7726
  "word-builder-blank": "_word-builder-blank_ftw6q_1",
7701
7727
  "word-builder-candidate-list": "_word-builder-candidate-list_ftw6q_30"
7702
7728
  };
7703
7729
  //#endregion
7704
7730
  //#region src/question/player/QuestionWordBuilderPlayer.tsx
7705
- function sd({ disabled: e, element: t, item: n, messages: r, onChange: i, response: s, showAnswer: c }) {
7706
- let l = Ri(n, !0, t), u = Sl(s, t.elementKey, l.blanks), d = ad(l, r.blankLabel);
7731
+ function cd({ disabled: e, element: t, item: n, messages: r, onChange: i, response: s, showAnswer: c }) {
7732
+ let l = zi(n, !0, t), u = Sl(s, t.elementKey, l.blanks), d = od(l, r.blankLabel);
7707
7733
  function f(e, t) {
7708
7734
  i(k(k({}, u), {}, { answers: k(k({}, u.answers), {}, { [e]: t }) }));
7709
7735
  }
@@ -7729,13 +7755,13 @@ function sd({ disabled: e, element: t, item: n, messages: r, onChange: i, respon
7729
7755
  r && m(n, r);
7730
7756
  }
7731
7757
  return /* @__PURE__ */ o("div", {
7732
- className: W["fill-text"],
7758
+ className: U["fill-text"],
7733
7759
  children: [
7734
- /* @__PURE__ */ a(bu, {
7760
+ /* @__PURE__ */ a(xu, {
7735
7761
  content: l.content,
7736
7762
  renderBlank: ({ blankId: t, index: n, label: i }) => {
7737
7763
  var o, s;
7738
- let c = (o = u.answers[t]) == null ? "" : o, l = cd({
7764
+ let c = (o = u.answers[t]) == null ? "" : o, l = ld({
7739
7765
  answers: c,
7740
7766
  blankLabel: r.blankLabel,
7741
7767
  canClear: !e && !!c.trim(),
@@ -7744,7 +7770,7 @@ function sd({ disabled: e, element: t, item: n, messages: r, onChange: i, respon
7744
7770
  });
7745
7771
  return /* @__PURE__ */ a("button", {
7746
7772
  "aria-label": l,
7747
- className: od["word-builder-blank"],
7773
+ className: sd["word-builder-blank"],
7748
7774
  disabled: e,
7749
7775
  onClick: () => p(t),
7750
7776
  onDragOver: (e) => e.preventDefault(),
@@ -7756,7 +7782,7 @@ function sd({ disabled: e, element: t, item: n, messages: r, onChange: i, respon
7756
7782
  }
7757
7783
  }),
7758
7784
  /* @__PURE__ */ a("div", {
7759
- className: od["word-builder-candidate-list"],
7785
+ className: sd["word-builder-candidate-list"],
7760
7786
  children: l.candidateOptions.map((t, n) => /* @__PURE__ */ a("button", {
7761
7787
  disabled: e,
7762
7788
  draggable: !e,
@@ -7768,42 +7794,42 @@ function sd({ disabled: e, element: t, item: n, messages: r, onChange: i, respon
7768
7794
  children: t
7769
7795
  }, `${t}-${n}`))
7770
7796
  }),
7771
- c ? /* @__PURE__ */ a(q, {
7797
+ c ? /* @__PURE__ */ a(K, {
7772
7798
  groups: d,
7773
7799
  title: r.standardAnswer
7774
7800
  }) : null
7775
7801
  ]
7776
7802
  });
7777
7803
  }
7778
- function cd({ answers: e, blankLabel: t, canClear: n, index: r, label: i }) {
7804
+ function ld({ answers: e, blankLabel: t, canClear: n, index: r, label: i }) {
7779
7805
  let a = i || `${t}${r + 1}`;
7780
7806
  return !n || !e.trim() ? a : t === "\u7a7a" ? `${a}\uff0c\u70b9\u51fb\u6e05\u7a7a` : `${a}, click to clear`;
7781
7807
  }
7782
7808
  //#endregion
7783
7809
  //#region src/question/player/QuestionPlayerElement.tsx
7784
- function ld({ disabled: e, element: t, item: n, messages: r, onResponseItemChange: i, response: o, showAnswer: s }) {
7785
- return t.type === n.type ? t.type === "richText" ? /* @__PURE__ */ a(K, { content: n.content }) : t.type === "ordering" ? /* @__PURE__ */ a(Qu, {
7810
+ function ud({ disabled: e, element: t, item: n, messages: r, onResponseItemChange: i, response: o, showAnswer: s }) {
7811
+ return t.type === n.type ? t.type === "richText" ? /* @__PURE__ */ a(G, { content: n.content }) : t.type === "ordering" ? /* @__PURE__ */ a($u, {
7786
7812
  disabled: e,
7787
7813
  item: n,
7788
7814
  messages: r,
7789
7815
  onChange: i,
7790
7816
  response: o,
7791
7817
  showAnswer: s
7792
- }) : t.type === "classification" ? /* @__PURE__ */ a(_u, {
7818
+ }) : t.type === "classification" ? /* @__PURE__ */ a(vu, {
7793
7819
  disabled: e,
7794
7820
  item: n,
7795
7821
  messages: r,
7796
7822
  onChange: i,
7797
7823
  response: o,
7798
7824
  showAnswer: s
7799
- }) : t.type === "textMarker" ? /* @__PURE__ */ a(id, {
7825
+ }) : t.type === "textMarker" ? /* @__PURE__ */ a(ad, {
7800
7826
  disabled: e,
7801
7827
  item: n,
7802
7828
  messages: r,
7803
7829
  onChange: i,
7804
7830
  response: o,
7805
7831
  showAnswer: s
7806
- }) : ud({
7832
+ }) : dd({
7807
7833
  disabled: e,
7808
7834
  element: t,
7809
7835
  item: n,
@@ -7813,9 +7839,9 @@ function ld({ disabled: e, element: t, item: n, messages: r, onResponseItemChang
7813
7839
  showAnswer: s
7814
7840
  }) : null;
7815
7841
  }
7816
- function ud({ disabled: e, element: t, item: n, messages: r, onResponseItemChange: i, response: o, showAnswer: s }) {
7842
+ function dd({ disabled: e, element: t, item: n, messages: r, onResponseItemChange: i, response: o, showAnswer: s }) {
7817
7843
  switch (t.type) {
7818
- case "choice": return /* @__PURE__ */ a(Xu, {
7844
+ case "choice": return /* @__PURE__ */ a(Zu, {
7819
7845
  disabled: e,
7820
7846
  element: t,
7821
7847
  item: n,
@@ -7824,7 +7850,7 @@ function ud({ disabled: e, element: t, item: n, messages: r, onResponseItemChang
7824
7850
  response: o,
7825
7851
  showAnswer: s
7826
7852
  });
7827
- case "fill": return /* @__PURE__ */ a(pu, {
7853
+ case "fill": return /* @__PURE__ */ a(mu, {
7828
7854
  disabled: e,
7829
7855
  item: n,
7830
7856
  messages: r,
@@ -7832,7 +7858,7 @@ function ud({ disabled: e, element: t, item: n, messages: r, onResponseItemChang
7832
7858
  response: o,
7833
7859
  showAnswer: s
7834
7860
  });
7835
- case "inlineFill": return /* @__PURE__ */ a(Fu, {
7861
+ case "inlineFill": return /* @__PURE__ */ a(Iu, {
7836
7862
  disabled: e,
7837
7863
  element: t,
7838
7864
  item: n,
@@ -7841,7 +7867,7 @@ function ud({ disabled: e, element: t, item: n, messages: r, onResponseItemChang
7841
7867
  response: o,
7842
7868
  showAnswer: s
7843
7869
  });
7844
- case "wordBuilder": return /* @__PURE__ */ a(sd, {
7870
+ case "wordBuilder": return /* @__PURE__ */ a(cd, {
7845
7871
  disabled: e,
7846
7872
  element: t,
7847
7873
  item: n,
@@ -7850,7 +7876,7 @@ function ud({ disabled: e, element: t, item: n, messages: r, onResponseItemChang
7850
7876
  response: o,
7851
7877
  showAnswer: s
7852
7878
  });
7853
- case "judgement": return /* @__PURE__ */ a(Bu, {
7879
+ case "judgement": return /* @__PURE__ */ a(Vu, {
7854
7880
  disabled: e,
7855
7881
  element: t,
7856
7882
  item: n,
@@ -7859,7 +7885,7 @@ function ud({ disabled: e, element: t, item: n, messages: r, onResponseItemChang
7859
7885
  response: o,
7860
7886
  showAnswer: s
7861
7887
  });
7862
- case "lineConnect": return /* @__PURE__ */ a(Uu, {
7888
+ case "lineConnect": return /* @__PURE__ */ a(Wu, {
7863
7889
  disabled: e,
7864
7890
  item: n,
7865
7891
  messages: r,
@@ -7867,7 +7893,7 @@ function ud({ disabled: e, element: t, item: n, messages: r, onResponseItemChang
7867
7893
  response: o,
7868
7894
  showAnswer: s
7869
7895
  });
7870
- case "matching": return /* @__PURE__ */ a(Ku, {
7896
+ case "matching": return /* @__PURE__ */ a(qu, {
7871
7897
  disabled: e,
7872
7898
  item: n,
7873
7899
  messages: r,
@@ -7879,16 +7905,16 @@ function ud({ disabled: e, element: t, item: n, messages: r, onResponseItemChang
7879
7905
  }
7880
7906
  //#endregion
7881
7907
  //#region src/question/player/QuestionPlayer.tsx
7882
- var dd = ["locale"];
7883
- function fd(e) {
7908
+ var fd = ["locale"];
7909
+ function pd(e) {
7884
7910
  let { locale: t = "zh-CN" } = e;
7885
- return /* @__PURE__ */ a(pd, k(k({}, As(e, dd)), {}, {
7911
+ return /* @__PURE__ */ a(md, k(k({}, As(e, fd)), {}, {
7886
7912
  messages: nu(t),
7887
7913
  numberPath: []
7888
7914
  }));
7889
7915
  }
7890
- function pd({ className: e, disabled: t = !1, messages: n, numberPath: r, onResponseChange: i, response: o, showAnswer: s = !1, showExtraAttributes: c = !1, structure: l, subquestionTemplates: u = [], value: d }) {
7891
- let f = md({
7916
+ function md({ className: e, disabled: t = !1, messages: n, numberPath: r, onResponseChange: i, response: o, showAnswer: s = !1, showExtraAttributes: c = !1, structure: l, subquestionTemplates: u = [], value: d }) {
7917
+ let f = hd({
7892
7918
  disabled: t,
7893
7919
  messages: n,
7894
7920
  numberPath: r,
@@ -7901,24 +7927,24 @@ function pd({ className: e, disabled: t = !1, messages: n, numberPath: r, onResp
7901
7927
  value: d
7902
7928
  });
7903
7929
  return /* @__PURE__ */ a("div", {
7904
- className: U(W.root, e),
7905
- children: _d(l, d) ? /* @__PURE__ */ a("div", {
7906
- className: W.empty,
7930
+ className: ru(U.root, e),
7931
+ children: vd(l, d) ? /* @__PURE__ */ a("div", {
7932
+ className: U.empty,
7907
7933
  children: n.previewEmpty
7908
7934
  }) : f
7909
7935
  });
7910
7936
  }
7911
- function md(e) {
7912
- return /* @__PURE__ */ o(i, { children: [hd(e), gd(e)] });
7937
+ function hd(e) {
7938
+ return /* @__PURE__ */ o(i, { children: [gd(e), _d(e)] });
7913
7939
  }
7914
- function hd({ disabled: e, messages: t, onResponseChange: n, response: r, showAnswer: i, showExtraAttributes: s, structure: c, value: l }) {
7915
- return pi(c) ? null : /* @__PURE__ */ o("div", {
7916
- className: W["element-list"],
7940
+ function gd({ disabled: e, messages: t, onResponseChange: n, response: r, showAnswer: i, showExtraAttributes: s, structure: c, value: l }) {
7941
+ return mi(c) ? null : /* @__PURE__ */ o("div", {
7942
+ className: U["element-list"],
7917
7943
  children: [c.elements.map((o) => {
7918
- let s = bi(l, o, c.hasAnswer);
7944
+ let s = xi(l, o, c.hasAnswer);
7919
7945
  return /* @__PURE__ */ a("section", {
7920
- className: W.element,
7921
- children: /* @__PURE__ */ a(ld, {
7946
+ className: U.element,
7947
+ children: /* @__PURE__ */ a(ud, {
7922
7948
  disabled: e,
7923
7949
  element: o,
7924
7950
  item: s,
@@ -7929,16 +7955,16 @@ function hd({ disabled: e, messages: t, onResponseChange: n, response: r, showAn
7929
7955
  })
7930
7956
  }, o.elementKey);
7931
7957
  }), s ? c.extras.map((n) => {
7932
- let i = xi(l, n);
7958
+ let i = Si(l, n);
7933
7959
  return /* @__PURE__ */ o("section", {
7934
- className: W.element,
7960
+ className: U.element,
7935
7961
  children: [/* @__PURE__ */ a("h3", {
7936
- className: W["section-title"],
7962
+ className: U["section-title"],
7937
7963
  children: n.name
7938
- }), /* @__PURE__ */ a(ld, {
7964
+ }), /* @__PURE__ */ a(ud, {
7939
7965
  disabled: e,
7940
- element: vd(n),
7941
- item: yd(i),
7966
+ element: yd(n),
7967
+ item: bd(i),
7942
7968
  messages: t,
7943
7969
  onResponseItemChange: () => void 0,
7944
7970
  response: r,
@@ -7948,14 +7974,14 @@ function hd({ disabled: e, messages: t, onResponseChange: n, response: r, showAn
7948
7974
  }) : null]
7949
7975
  });
7950
7976
  }
7951
- function gd({ disabled: e, messages: t, numberPath: n, onResponseChange: r, response: i, showAnswer: o, showExtraAttributes: s, subquestionTemplates: c = [], value: l }) {
7952
- return l.children.length === 0 ? null : /* @__PURE__ */ a(du, {
7977
+ function _d({ disabled: e, messages: t, numberPath: n, onResponseChange: r, response: i, showAnswer: o, showExtraAttributes: s, subquestionTemplates: c = [], value: l }) {
7978
+ return l.children.length === 0 ? null : /* @__PURE__ */ a(fu, {
7953
7979
  disabled: e,
7954
7980
  messages: t,
7955
7981
  numberPath: n,
7956
7982
  onChildResponseChange: (e, t) => r(Al(i, e, t)),
7957
7983
  response: i,
7958
- renderChild: (n, r, i, l, u) => /* @__PURE__ */ a(pd, {
7984
+ renderChild: (n, r, i, l, u) => /* @__PURE__ */ a(md, {
7959
7985
  disabled: e,
7960
7986
  messages: t,
7961
7987
  numberPath: u,
@@ -7971,10 +7997,10 @@ function gd({ disabled: e, messages: t, numberPath: n, onResponseChange: r, resp
7971
7997
  value: l
7972
7998
  });
7973
7999
  }
7974
- function _d(e, t) {
7975
- return pi(e) && t.children.length === 0;
8000
+ function vd(e, t) {
8001
+ return mi(e) && t.children.length === 0;
7976
8002
  }
7977
- function vd(e) {
8003
+ function yd(e) {
7978
8004
  return {
7979
8005
  config: {},
7980
8006
  elementKey: e.extraKey,
@@ -7982,7 +8008,7 @@ function vd(e) {
7982
8008
  type: "richText"
7983
8009
  };
7984
8010
  }
7985
- function yd(e) {
8011
+ function bd(e) {
7986
8012
  return {
7987
8013
  content: e.content,
7988
8014
  elementKey: e.extraKey,
@@ -7991,129 +8017,129 @@ function yd(e) {
7991
8017
  }
7992
8018
  //#endregion
7993
8019
  //#region src/question/renderers/QuestionBlankGroupView.module.css
7994
- var bd = {
8020
+ var xd = {
7995
8021
  "blank-list": "_blank-list_12ccp_1",
7996
8022
  "blank-item": "_blank-item_12ccp_11",
7997
8023
  "blank-field": "_blank-field_12ccp_17"
7998
8024
  };
7999
8025
  //#endregion
8000
8026
  //#region src/question/renderers/QuestionBlankGroupView.tsx
8001
- function xd({ item: e, messages: t, showAnswer: n }) {
8002
- let r = ea(e.answers, e.blanks).map((n, r) => ({
8003
- contents: n.answerPools.map((e, t) => /* @__PURE__ */ a(K, { content: e }, `group-${r}-answer-${t}`)),
8004
- marker: ru(n.blankIds, e.blanks, t.blankLabel)
8027
+ function Sd({ item: e, messages: t, showAnswer: n }) {
8028
+ let r = ta(e.answers, e.blanks).map((n, r) => ({
8029
+ contents: n.answerPools.map((e, t) => /* @__PURE__ */ a(G, { content: e }, `group-${r}-answer-${t}`)),
8030
+ marker: iu(n.blankIds, e.blanks, t.blankLabel)
8005
8031
  }));
8006
8032
  return /* @__PURE__ */ o("div", {
8007
- className: G.element,
8033
+ className: W.element,
8008
8034
  children: [/* @__PURE__ */ a("ol", {
8009
- className: bd["blank-list"],
8035
+ className: xd["blank-list"],
8010
8036
  children: e.blanks.map((e, n) => /* @__PURE__ */ a("li", {
8011
- className: bd["blank-item"],
8037
+ className: xd["blank-item"],
8012
8038
  children: /* @__PURE__ */ o("span", {
8013
- className: bd["blank-field"],
8039
+ className: xd["blank-field"],
8014
8040
  children: [
8015
8041
  t.blankLabel,
8016
8042
  " ",
8017
8043
  n + 1
8018
8044
  ]
8019
8045
  })
8020
- }, Sd(e, n)))
8021
- }), n ? /* @__PURE__ */ a(q, {
8046
+ }, Cd(e, n)))
8047
+ }), n ? /* @__PURE__ */ a(K, {
8022
8048
  groups: r,
8023
8049
  title: t.standardAnswer
8024
8050
  }) : null]
8025
8051
  });
8026
8052
  }
8027
- function Sd(e, t) {
8053
+ function Cd(e, t) {
8028
8054
  return e || `blank-${t + 1}`;
8029
8055
  }
8030
8056
  //#endregion
8031
8057
  //#region src/question/renderers/QuestionClassificationView.tsx
8032
- function Cd({ item: e, messages: t, showAnswer: n }) {
8058
+ function wd({ item: e, messages: t, showAnswer: n }) {
8033
8059
  return /* @__PURE__ */ o("div", {
8034
- className: G.element,
8060
+ className: W.element,
8035
8061
  children: [/* @__PURE__ */ o("div", {
8036
- className: J.board,
8062
+ className: q.board,
8037
8063
  children: [/* @__PURE__ */ a("div", {
8038
- className: J.zones,
8064
+ className: q.zones,
8039
8065
  children: e.categories.map((e) => /* @__PURE__ */ o("section", {
8040
- className: J.zone,
8066
+ className: q.zone,
8041
8067
  children: [/* @__PURE__ */ a("div", {
8042
- className: J["zone-title"],
8043
- children: /* @__PURE__ */ a(K, { content: e.content })
8068
+ className: q["zone-title"],
8069
+ children: /* @__PURE__ */ a(G, { content: e.content })
8044
8070
  }), /* @__PURE__ */ a("span", {
8045
- className: J.empty,
8071
+ className: q.empty,
8046
8072
  children: t.unassigned
8047
8073
  })]
8048
8074
  }, e.id))
8049
8075
  }), /* @__PURE__ */ a("section", {
8050
- className: J.pool,
8076
+ className: q.pool,
8051
8077
  children: e.items.map((e) => /* @__PURE__ */ a("div", {
8052
- className: J.item,
8053
- children: /* @__PURE__ */ a(K, { content: e.content })
8078
+ className: q.item,
8079
+ children: /* @__PURE__ */ a(G, { content: e.content })
8054
8080
  }, e.id))
8055
8081
  })]
8056
- }), n ? /* @__PURE__ */ a(q, {
8057
- groups: gu(e),
8082
+ }), n ? /* @__PURE__ */ a(K, {
8083
+ groups: _u(e),
8058
8084
  title: t.standardAnswer
8059
8085
  }) : null]
8060
8086
  });
8061
8087
  }
8062
8088
  //#endregion
8063
8089
  //#region src/question/renderers/QuestionFillTextView.tsx
8064
- function wd({ element: e, item: t, messages: n, showAnswer: r }) {
8065
- let i = zi(t, e, !0), s = lu(i).map((e, t) => ({
8066
- contents: e.contents.map((e, n) => /* @__PURE__ */ a(K, { content: e }, `group-${t}-answer-${n}`)),
8067
- marker: ru(e.blankIds, i.blanks, n.blankLabel)
8090
+ function Td({ element: e, item: t, messages: n, showAnswer: r }) {
8091
+ let i = Bi(t, e, !0), s = uu(i).map((e, t) => ({
8092
+ contents: e.contents.map((e, n) => /* @__PURE__ */ a(G, { content: e }, `group-${t}-answer-${n}`)),
8093
+ marker: iu(e.blankIds, i.blanks, n.blankLabel)
8068
8094
  }));
8069
8095
  return /* @__PURE__ */ o("div", {
8070
- className: G.element,
8096
+ className: W.element,
8071
8097
  children: [
8072
- /* @__PURE__ */ a(K, { content: i.content }),
8073
- Td(i, n.candidateOptions),
8074
- r ? /* @__PURE__ */ a(q, {
8098
+ /* @__PURE__ */ a(G, { content: i.content }),
8099
+ Ed(i, n.candidateOptions),
8100
+ r ? /* @__PURE__ */ a(K, {
8075
8101
  groups: s,
8076
8102
  title: n.standardAnswer
8077
8103
  }) : null
8078
8104
  ]
8079
8105
  });
8080
8106
  }
8081
- function Td(e, t) {
8107
+ function Ed(e, t) {
8082
8108
  var n, r;
8083
8109
  let i = (n = e.candidateOptions) == null ? [] : n, s = (r = e.blankOptionGroups) == null ? [] : r;
8084
8110
  return !i.length && !s.length ? null : /* @__PURE__ */ o("div", {
8085
- className: G["candidate-section"],
8111
+ className: W["candidate-section"],
8086
8112
  children: [/* @__PURE__ */ a("span", {
8087
- className: G["section-title"],
8113
+ className: W["section-title"],
8088
8114
  children: t
8089
8115
  }), /* @__PURE__ */ o("ol", {
8090
- className: G["candidate-list"],
8116
+ className: W["candidate-list"],
8091
8117
  children: [i.map((e) => /* @__PURE__ */ a("li", {
8092
- className: G["candidate-item"],
8093
- children: /* @__PURE__ */ a(K, { content: e.content })
8118
+ className: W["candidate-item"],
8119
+ children: /* @__PURE__ */ a(G, { content: e.content })
8094
8120
  }, e.optionId)), s.reduce((e, t) => [...e, ...t.options.map((e) => /* @__PURE__ */ a("li", {
8095
- className: G["candidate-item"],
8096
- children: /* @__PURE__ */ a(K, { content: e.content })
8121
+ className: W["candidate-item"],
8122
+ children: /* @__PURE__ */ a(G, { content: e.content })
8097
8123
  }, `${t.blankId}-${e.optionId}`))], [])]
8098
8124
  })]
8099
8125
  });
8100
8126
  }
8101
8127
  //#endregion
8102
8128
  //#region src/question/renderers/QuestionJudgementGroupView.tsx
8103
- function Ed({ element: e, item: t, messages: n, showAnswer: r }) {
8104
- let i = Ti(e.config.judgeAnswerMode), s = [{
8129
+ function Dd({ element: e, item: t, messages: n, showAnswer: r }) {
8130
+ let i = Ei(e.config.judgeAnswerMode), s = [{
8105
8131
  contents: t.answers.filter((e) => e.trim() !== ""),
8106
8132
  marker: ""
8107
8133
  }];
8108
8134
  return /* @__PURE__ */ o("div", {
8109
- className: G.element,
8135
+ className: W.element,
8110
8136
  children: [/* @__PURE__ */ a("ol", {
8111
- className: G["judgement-list"],
8137
+ className: W["judgement-list"],
8112
8138
  children: i.map((e) => /* @__PURE__ */ a("li", {
8113
- className: G["judgement-item"],
8139
+ className: W["judgement-item"],
8114
8140
  children: e
8115
8141
  }, e))
8116
- }), r ? /* @__PURE__ */ a(q, {
8142
+ }), r ? /* @__PURE__ */ a(K, {
8117
8143
  groups: s,
8118
8144
  title: n.standardAnswer
8119
8145
  }) : null]
@@ -8121,10 +8147,10 @@ function Ed({ element: e, item: t, messages: n, showAnswer: r }) {
8121
8147
  }
8122
8148
  //#endregion
8123
8149
  //#region src/question/renderers/QuestionLineConnectView.tsx
8124
- function Dd({ item: e, messages: t, showAnswer: n }) {
8150
+ function Od({ item: e, messages: t, showAnswer: n }) {
8125
8151
  let r = { gridTemplateColumns: `repeat(${e.columns.length}, minmax(12rem, 1fr))` };
8126
8152
  return /* @__PURE__ */ o("div", {
8127
- className: G.element,
8153
+ className: W.element,
8128
8154
  children: [/* @__PURE__ */ a("div", {
8129
8155
  className: B.board,
8130
8156
  children: /* @__PURE__ */ a("div", {
@@ -8140,24 +8166,24 @@ function Dd({ item: e, messages: t, showAnswer: n }) {
8140
8166
  n + 1
8141
8167
  ]
8142
8168
  }), e.items.map((t, n) => {
8143
- let r = Ci(e.labelStyle, n);
8169
+ let r = wi(e.labelStyle, n);
8144
8170
  return /* @__PURE__ */ o("div", {
8145
8171
  className: B.item,
8146
8172
  children: [r ? /* @__PURE__ */ a("span", {
8147
8173
  className: B.marker,
8148
8174
  children: r
8149
- }) : null, /* @__PURE__ */ a(K, { content: t.content })]
8175
+ }) : null, /* @__PURE__ */ a(G, { content: t.content })]
8150
8176
  }, t.itemId);
8151
8177
  })]
8152
8178
  }, e.columnId))
8153
8179
  })
8154
- }), n ? /* @__PURE__ */ a(q, {
8155
- groups: Vu(e),
8180
+ }), n ? /* @__PURE__ */ a(K, {
8181
+ groups: Hu(e),
8156
8182
  title: t.standardAnswer
8157
8183
  }) : null]
8158
8184
  });
8159
8185
  }
8160
- var Od = {
8186
+ var kd = {
8161
8187
  board: "_board_5xarh_1",
8162
8188
  columns: "_columns_5xarh_6",
8163
8189
  column: "_column_5xarh_6",
@@ -8166,73 +8192,73 @@ var Od = {
8166
8192
  };
8167
8193
  //#endregion
8168
8194
  //#region src/question/renderers/QuestionMatchingView.tsx
8169
- function kd({ item: e, messages: t, showAnswer: n }) {
8195
+ function Ad({ item: e, messages: t, showAnswer: n }) {
8170
8196
  return /* @__PURE__ */ o("div", {
8171
- className: G.element,
8197
+ className: W.element,
8172
8198
  children: [/* @__PURE__ */ a("div", {
8173
- className: Od.board,
8199
+ className: kd.board,
8174
8200
  children: /* @__PURE__ */ a("div", {
8175
- className: Od.columns,
8201
+ className: kd.columns,
8176
8202
  children: e.columns.map((e) => /* @__PURE__ */ a("section", {
8177
- className: Od.column,
8203
+ className: kd.column,
8178
8204
  children: e.items.map((t, n) => {
8179
- let r = wi(e.labelStyle, n);
8205
+ let r = Ti(e.labelStyle, n);
8180
8206
  return /* @__PURE__ */ o("div", {
8181
- className: Od.item,
8207
+ className: kd.item,
8182
8208
  children: [r ? /* @__PURE__ */ a("span", {
8183
- className: Od.marker,
8209
+ className: kd.marker,
8184
8210
  children: r
8185
- }) : null, /* @__PURE__ */ a(K, { content: t.content })]
8211
+ }) : null, /* @__PURE__ */ a(G, { content: t.content })]
8186
8212
  }, t.itemId);
8187
8213
  })
8188
8214
  }, e.columnId))
8189
8215
  })
8190
- }), n ? /* @__PURE__ */ a(q, {
8191
- groups: Wu(e),
8216
+ }), n ? /* @__PURE__ */ a(K, {
8217
+ groups: Gu(e),
8192
8218
  title: t.standardAnswer
8193
8219
  }) : null]
8194
8220
  });
8195
8221
  }
8196
8222
  //#endregion
8197
8223
  //#region src/question/renderers/QuestionOptionGroupView.tsx
8198
- function Ad({ element: e, item: t, messages: n, showAnswer: r }) {
8199
- let i = Ei(t, e.config.optionLabelStyle);
8224
+ function jd({ element: e, item: t, messages: n, showAnswer: r }) {
8225
+ let i = Di(t, e.config.optionLabelStyle);
8200
8226
  if (e.config.renderer === "table") {
8201
- let s = Ju(e, t);
8227
+ let s = Yu(e, t);
8202
8228
  return /* @__PURE__ */ o("div", {
8203
- className: G.element,
8229
+ className: W.element,
8204
8230
  children: [/* @__PURE__ */ a("div", {
8205
- className: Yu["table-wrap"],
8231
+ className: Xu["table-wrap"],
8206
8232
  children: /* @__PURE__ */ o("table", {
8207
- className: Yu.table,
8233
+ className: Xu.table,
8208
8234
  children: [
8209
- /* @__PURE__ */ o("colgroup", { children: [/* @__PURE__ */ a("col", { className: Yu["table-option-column"] }), t.columns.map((e) => /* @__PURE__ */ a("col", {}, e.id))] }),
8210
- /* @__PURE__ */ a("thead", { children: /* @__PURE__ */ o("tr", { children: [/* @__PURE__ */ a("th", { children: n.option }), t.columns.map((e) => /* @__PURE__ */ a("th", { children: /* @__PURE__ */ a(K, { content: e.content }) }, e.id))] }) }),
8235
+ /* @__PURE__ */ o("colgroup", { children: [/* @__PURE__ */ a("col", { className: Xu["table-option-column"] }), t.columns.map((e) => /* @__PURE__ */ a("col", {}, e.id))] }),
8236
+ /* @__PURE__ */ a("thead", { children: /* @__PURE__ */ o("tr", { children: [/* @__PURE__ */ a("th", { children: n.option }), t.columns.map((e) => /* @__PURE__ */ a("th", { children: /* @__PURE__ */ a(G, { content: e.content }) }, e.id))] }) }),
8211
8237
  /* @__PURE__ */ a("tbody", { children: i.map((e) => /* @__PURE__ */ o("tr", { children: [/* @__PURE__ */ a("td", { children: /* @__PURE__ */ a("span", {
8212
- className: Yu["table-option-marker"],
8238
+ className: Xu["table-option-marker"],
8213
8239
  children: e.marker
8214
- }) }), e.cells.map((t, n) => /* @__PURE__ */ a("td", { children: /* @__PURE__ */ a(K, { content: t }) }, `${e.optionId}-cell-${n}`))] }, e.optionId)) })
8240
+ }) }), e.cells.map((t, n) => /* @__PURE__ */ a("td", { children: /* @__PURE__ */ a(G, { content: t }) }, `${e.optionId}-cell-${n}`))] }, e.optionId)) })
8215
8241
  ]
8216
8242
  })
8217
- }), r ? /* @__PURE__ */ a(q, {
8243
+ }), r ? /* @__PURE__ */ a(K, {
8218
8244
  groups: s,
8219
8245
  title: n.standardAnswer
8220
8246
  }) : null]
8221
8247
  });
8222
8248
  }
8223
- let s = Ju(e, t);
8249
+ let s = Yu(e, t);
8224
8250
  return /* @__PURE__ */ o("div", {
8225
- className: G.element,
8251
+ className: W.element,
8226
8252
  children: [/* @__PURE__ */ a("ol", {
8227
- className: G["option-list"],
8253
+ className: W["option-list"],
8228
8254
  children: i.map((e) => /* @__PURE__ */ o("li", {
8229
- className: G["option-item"],
8255
+ className: W["option-item"],
8230
8256
  children: [/* @__PURE__ */ a("span", {
8231
- className: G.marker,
8257
+ className: W.marker,
8232
8258
  children: e.marker
8233
- }), /* @__PURE__ */ a(K, { content: e.standardContent })]
8259
+ }), /* @__PURE__ */ a(G, { content: e.standardContent })]
8234
8260
  }, e.optionId))
8235
- }), r ? /* @__PURE__ */ a(q, {
8261
+ }), r ? /* @__PURE__ */ a(K, {
8236
8262
  groups: s,
8237
8263
  title: n.standardAnswer
8238
8264
  }) : null]
@@ -8240,53 +8266,53 @@ function Ad({ element: e, item: t, messages: n, showAnswer: r }) {
8240
8266
  }
8241
8267
  //#endregion
8242
8268
  //#region src/question/renderers/QuestionOrderingView.tsx
8243
- function jd({ item: e, messages: t, showAnswer: n }) {
8269
+ function Md({ item: e, messages: t, showAnswer: n }) {
8244
8270
  return /* @__PURE__ */ o("div", {
8245
- className: G.element,
8271
+ className: W.element,
8246
8272
  children: [/* @__PURE__ */ a("ol", {
8247
- className: G["option-list"],
8273
+ className: W["option-list"],
8248
8274
  children: e.sortOptions.map((e, t) => /* @__PURE__ */ o("li", {
8249
- className: G["option-item"],
8275
+ className: W["option-item"],
8250
8276
  children: [/* @__PURE__ */ a("span", {
8251
- className: G.marker,
8277
+ className: W.marker,
8252
8278
  children: t + 1
8253
- }), /* @__PURE__ */ a(K, { content: e.content })]
8279
+ }), /* @__PURE__ */ a(G, { content: e.content })]
8254
8280
  }, e.id))
8255
- }), n ? /* @__PURE__ */ a(q, {
8256
- groups: Zu(e),
8281
+ }), n ? /* @__PURE__ */ a(K, {
8282
+ groups: Qu(e),
8257
8283
  title: t.standardAnswer
8258
8284
  }) : null]
8259
8285
  });
8260
8286
  }
8261
8287
  //#endregion
8262
8288
  //#region src/question/renderers/QuestionWordBuilderView.tsx
8263
- function Md({ element: e, item: t, messages: n, showAnswer: r }) {
8264
- let i = Ri(t, !0, e), s = ad(i, n.blankLabel);
8289
+ function Nd({ element: e, item: t, messages: n, showAnswer: r }) {
8290
+ let i = zi(t, !0, e), s = od(i, n.blankLabel);
8265
8291
  return /* @__PURE__ */ o("div", {
8266
- className: G.element,
8292
+ className: W.element,
8267
8293
  children: [
8268
- /* @__PURE__ */ a(bu, {
8294
+ /* @__PURE__ */ a(xu, {
8269
8295
  content: i.content,
8270
8296
  renderBlank: ({ blankId: e, index: t, label: r }) => /* @__PURE__ */ a("span", {
8271
8297
  "aria-label": r || `${n.blankLabel}${t + 1}`,
8272
- className: G["word-builder-blank"],
8298
+ className: W["word-builder-blank"],
8273
8299
  "data-blank-id": e
8274
8300
  })
8275
8301
  }),
8276
8302
  /* @__PURE__ */ o("div", {
8277
- className: G["candidate-section"],
8303
+ className: W["candidate-section"],
8278
8304
  children: [/* @__PURE__ */ a("span", {
8279
- className: G["section-title"],
8305
+ className: W["section-title"],
8280
8306
  children: n.candidateOptions
8281
8307
  }), /* @__PURE__ */ a("ol", {
8282
- className: G["word-builder-candidate-list"],
8308
+ className: W["word-builder-candidate-list"],
8283
8309
  children: i.candidateOptions.map((e, t) => /* @__PURE__ */ a("li", {
8284
- className: G["candidate-item"],
8310
+ className: W["candidate-item"],
8285
8311
  children: e
8286
8312
  }, `${e}-${t}`))
8287
8313
  })]
8288
8314
  }),
8289
- r ? /* @__PURE__ */ a(q, {
8315
+ r ? /* @__PURE__ */ a(K, {
8290
8316
  groups: s,
8291
8317
  title: n.standardAnswer
8292
8318
  }) : null
@@ -8295,70 +8321,70 @@ function Md({ element: e, item: t, messages: n, showAnswer: r }) {
8295
8321
  }
8296
8322
  //#endregion
8297
8323
  //#region src/question/renderers/QuestionContentElementView.tsx
8298
- function Nd({ element: e, item: t, messages: n, showAnswer: r }) {
8299
- return e.type === t.type ? e.type === "richText" ? /* @__PURE__ */ a(K, { content: t.content }) : e.type === "ordering" ? /* @__PURE__ */ a(jd, {
8324
+ function Pd({ element: e, item: t, messages: n, showAnswer: r }) {
8325
+ return e.type === t.type ? e.type === "richText" ? /* @__PURE__ */ a(G, { content: t.content }) : e.type === "ordering" ? /* @__PURE__ */ a(Md, {
8300
8326
  item: t,
8301
8327
  messages: n,
8302
8328
  showAnswer: r
8303
- }) : e.type === "classification" ? /* @__PURE__ */ a(Cd, {
8329
+ }) : e.type === "classification" ? /* @__PURE__ */ a(wd, {
8304
8330
  item: t,
8305
8331
  messages: n,
8306
8332
  showAnswer: r
8307
- }) : e.type === "textMarker" ? /* @__PURE__ */ a(rd, {
8333
+ }) : e.type === "textMarker" ? /* @__PURE__ */ a(id, {
8308
8334
  item: t,
8309
8335
  messages: n,
8310
8336
  showAnswer: r
8311
- }) : Pd({
8337
+ }) : Fd({
8312
8338
  element: e,
8313
8339
  item: t,
8314
8340
  messages: n,
8315
8341
  showAnswer: r
8316
8342
  }) : null;
8317
8343
  }
8318
- function Pd({ element: e, item: t, messages: n, showAnswer: r }) {
8344
+ function Fd({ element: e, item: t, messages: n, showAnswer: r }) {
8319
8345
  switch (e.type) {
8320
- case "choice": return /* @__PURE__ */ a(Ad, {
8346
+ case "choice": return /* @__PURE__ */ a(jd, {
8321
8347
  element: e,
8322
8348
  item: t,
8323
8349
  messages: n,
8324
8350
  showAnswer: r
8325
8351
  });
8326
- case "fill": return /* @__PURE__ */ a(xd, {
8352
+ case "fill": return /* @__PURE__ */ a(Sd, {
8327
8353
  item: t,
8328
8354
  messages: n,
8329
8355
  showAnswer: r
8330
8356
  });
8331
- case "inlineFill": return /* @__PURE__ */ a(wd, {
8357
+ case "inlineFill": return /* @__PURE__ */ a(Td, {
8332
8358
  element: e,
8333
8359
  item: t,
8334
8360
  messages: n,
8335
8361
  showAnswer: r
8336
8362
  });
8337
- case "wordBuilder": return /* @__PURE__ */ a(Md, {
8363
+ case "wordBuilder": return /* @__PURE__ */ a(Nd, {
8338
8364
  element: e,
8339
8365
  item: t,
8340
8366
  messages: n,
8341
8367
  showAnswer: r
8342
8368
  });
8343
- case "judgement": return /* @__PURE__ */ a(Ed, {
8369
+ case "judgement": return /* @__PURE__ */ a(Dd, {
8344
8370
  element: e,
8345
8371
  item: t,
8346
8372
  messages: n,
8347
8373
  showAnswer: r
8348
8374
  });
8349
- case "lineConnect": return /* @__PURE__ */ a(Dd, {
8375
+ case "lineConnect": return /* @__PURE__ */ a(Od, {
8350
8376
  item: t,
8351
8377
  messages: n,
8352
8378
  showAnswer: r
8353
8379
  });
8354
- case "matching": return /* @__PURE__ */ a(kd, {
8380
+ case "matching": return /* @__PURE__ */ a(Ad, {
8355
8381
  item: t,
8356
8382
  messages: n,
8357
8383
  showAnswer: r
8358
8384
  });
8359
8385
  }
8360
8386
  }
8361
- var Fd = {
8387
+ var X = {
8362
8388
  root: "_root_oqlnl_1",
8363
8389
  empty: "_empty_oqlnl_19",
8364
8390
  "element-list": "_element-list_oqlnl_31",
@@ -8372,23 +8398,23 @@ var Fd = {
8372
8398
  //#region src/question/preview/QuestionCompositePreview.tsx
8373
8399
  function Id({ messages: e, numberPath: t = [], renderChild: n, subquestionTemplates: r, value: i }) {
8374
8400
  return i.children.length === 0 ? /* @__PURE__ */ a("div", {
8375
- className: Fd.empty,
8401
+ className: X.empty,
8376
8402
  children: e.previewEmpty
8377
8403
  }) : /* @__PURE__ */ a("div", {
8378
- className: Fd.children,
8404
+ className: X.children,
8379
8405
  children: i.children.map((i, s) => {
8380
8406
  let c = [...t, s], l = qc(r, i.questionTypeKey);
8381
8407
  return /* @__PURE__ */ o("section", {
8382
- className: Fd.child,
8408
+ className: X.child,
8383
8409
  children: [/* @__PURE__ */ o("div", {
8384
- className: Fd["child-title"],
8410
+ className: X["child-title"],
8385
8411
  children: [
8386
8412
  e.subquestion,
8387
8413
  " ",
8388
8414
  Hc(c)
8389
8415
  ]
8390
8416
  }), l ? n(i, l.structure, c) : /* @__PURE__ */ a("div", {
8391
- className: Fd.empty,
8417
+ className: X.empty,
8392
8418
  children: e.missingSubquestionTemplate
8393
8419
  })]
8394
8420
  }, i.id || s);
@@ -8406,13 +8432,13 @@ function Rd(e) {
8406
8432
  }));
8407
8433
  }
8408
8434
  function zd({ className: e, messages: t, numberPath: n, showAnswer: r = !1, showExtraAttributes: s = !1, structure: c, subquestionTemplates: l = [], value: u }) {
8409
- let d = /* @__PURE__ */ o(i, { children: [pi(c) ? null : /* @__PURE__ */ o("div", {
8410
- className: Fd["element-list"],
8435
+ let d = /* @__PURE__ */ o(i, { children: [mi(c) ? null : /* @__PURE__ */ o("div", {
8436
+ className: X["element-list"],
8411
8437
  children: [c.elements.map((e) => {
8412
- let n = bi(u, e, c.hasAnswer);
8438
+ let n = xi(u, e, c.hasAnswer);
8413
8439
  return /* @__PURE__ */ a("section", {
8414
- className: Fd.element,
8415
- children: /* @__PURE__ */ a(Nd, {
8440
+ className: X.element,
8441
+ children: /* @__PURE__ */ a(Pd, {
8416
8442
  element: e,
8417
8443
  item: n,
8418
8444
  messages: t,
@@ -8420,13 +8446,13 @@ function zd({ className: e, messages: t, numberPath: n, showAnswer: r = !1, show
8420
8446
  })
8421
8447
  }, e.elementKey);
8422
8448
  }), s ? c.extras.map((e) => {
8423
- let n = xi(u, e);
8449
+ let n = Si(u, e);
8424
8450
  return /* @__PURE__ */ o("section", {
8425
- className: Fd.element,
8451
+ className: X.element,
8426
8452
  children: [/* @__PURE__ */ a("h3", {
8427
- className: Fd["section-title"],
8453
+ className: X["section-title"],
8428
8454
  children: e.name
8429
- }), /* @__PURE__ */ a(Nd, {
8455
+ }), /* @__PURE__ */ a(Pd, {
8430
8456
  element: Vd(e),
8431
8457
  item: Hd(n),
8432
8458
  messages: t,
@@ -8450,15 +8476,15 @@ function zd({ className: e, messages: t, numberPath: n, showAnswer: r = !1, show
8450
8476
  value: u
8451
8477
  })] });
8452
8478
  return /* @__PURE__ */ a("div", {
8453
- className: U(Fd.root, e),
8479
+ className: ru(X.root, e),
8454
8480
  children: Bd(c, u) ? /* @__PURE__ */ a("div", {
8455
- className: Fd.empty,
8481
+ className: X.empty,
8456
8482
  children: t.previewEmpty
8457
8483
  }) : d
8458
8484
  });
8459
8485
  }
8460
8486
  function Bd(e, t) {
8461
- return pi(e) && t.children.length === 0;
8487
+ return mi(e) && t.children.length === 0;
8462
8488
  }
8463
8489
  function Vd(e) {
8464
8490
  return {
@@ -9386,4 +9412,4 @@ function Ef(e) {
9386
9412
  return (t = (n = (r = e.elements[0]) == null ? void 0 : r.clientId) == null ? (i = e.extras[0]) == null ? void 0 : i.clientId : n) == null ? null : t;
9387
9413
  }
9388
9414
  //#endregion
9389
- export { tl as QuestionContentEditor, fd as QuestionPlayer, Rd as QuestionPreview, K as QuestionRichContentView, wf as QuestionStructureEditor, Qi as addBlankToGroup, na as assignBlankToAnswerGroup, tc as cn, ra as createBlankAnswerGroupWithBlank, mi as createEmptyQuestionContentDraft, rr as createEmptyQuestionData, vl as createEmptyQuestionPlayerResponse, ar as createEmptyQuestionResponse, Ir as createEmptyQuestionStructureDraft, Ai as createQuestionContentDraftFromSerialized, il as createQuestionContentStructureFromDraft, al as createQuestionPreviewDraft, Rr as createQuestionStructureElement, Lr as createQuestionStructureExtra, M as createRichContentValue, hi as createRichContentValueFromDocument, v as createRichTextContent, $i as deleteBlankFromGroup, Hr as deleteQuestionStructureElement, Vr as deleteQuestionStructureExtra, ia as detachBlankFromAnswerGroup, qc as findQuestionContentSubquestionTemplate, xi as getQuestionContentExtraItem, bi as getQuestionContentItem, Ti as getQuestionContentJudgementOptions, Si as getQuestionContentOptionMarker, vi as getQuestionContentTextMarkerAnswerText, sl as getQuestionStructureDraftChangeKind, j as getQuestionStructureElementDefaultEnName, A as getQuestionStructureElementDefaultName, Yr as getQuestionStructureExtraDefaultEnName, Jr as getQuestionStructureExtraDefaultName, yi as getRichContentDocument, ta as getSharedBlankAnswerGroups, pi as isCompositeQuestionContentStructure, sr as isCompositeQuestionType, Oi as isQuestionContentDraftEmpty, Kc as isQuestionContentSubquestionTemplateMatch, Ur as moveQuestionStructureElement, zi as normalizeFillTextCandidateState, ir as normalizeQuestionData, or as normalizeQuestionResponse, y as normalizeRichTextContent, Ar as questionStructureElementTypes, jr as questionStructureExtraKeys, ki as serializeQuestionContentDraft, ol as serializeQuestionStructureDraft, Mi as updateQuestionContentExtraItem, ji as updateQuestionContentItem, Gr as updateQuestionStructureElement, Wr as updateQuestionStructureExtra, Kr as updateQuestionStructureGlobalConfig, qr as updateQuestionStructureMetadata, ur as validateQuestionDataElementAlignment };
9415
+ export { tl as QuestionContentEditor, pd as QuestionPlayer, Rd as QuestionPreview, G as QuestionRichContentView, wf as QuestionStructureEditor, $i as addBlankToGroup, ra as assignBlankToAnswerGroup, tc as cn, ia as createBlankAnswerGroupWithBlank, hi as createEmptyQuestionContentDraft, rr as createEmptyQuestionData, vl as createEmptyQuestionPlayerResponse, ar as createEmptyQuestionResponse, Ir as createEmptyQuestionStructureDraft, ji as createQuestionContentDraftFromSerialized, il as createQuestionContentStructureFromDraft, al as createQuestionPreviewDraft, Rr as createQuestionStructureElement, Lr as createQuestionStructureExtra, M as createRichContentValue, gi as createRichContentValueFromDocument, v as createRichTextContent, ea as deleteBlankFromGroup, Hr as deleteQuestionStructureElement, Vr as deleteQuestionStructureExtra, aa as detachBlankFromAnswerGroup, qc as findQuestionContentSubquestionTemplate, Si as getQuestionContentExtraItem, xi as getQuestionContentItem, Ei as getQuestionContentJudgementOptions, Ci as getQuestionContentOptionMarker, yi as getQuestionContentTextMarkerAnswerText, sl as getQuestionStructureDraftChangeKind, j as getQuestionStructureElementDefaultEnName, A as getQuestionStructureElementDefaultName, Yr as getQuestionStructureExtraDefaultEnName, Jr as getQuestionStructureExtraDefaultName, bi as getRichContentDocument, na as getSharedBlankAnswerGroups, mi as isCompositeQuestionContentStructure, sr as isCompositeQuestionType, ki as isQuestionContentDraftEmpty, Kc as isQuestionContentSubquestionTemplateMatch, Ur as moveQuestionStructureElement, Bi as normalizeFillTextCandidateState, ir as normalizeQuestionData, or as normalizeQuestionResponse, y as normalizeRichTextContent, Ar as questionStructureElementTypes, jr as questionStructureExtraKeys, Ai as serializeQuestionContentDraft, ol as serializeQuestionStructureDraft, Ni as updateQuestionContentExtraItem, Mi as updateQuestionContentItem, Gr as updateQuestionStructureElement, Wr as updateQuestionStructureExtra, Kr as updateQuestionStructureGlobalConfig, qr as updateQuestionStructureMetadata, ur as validateQuestionDataElementAlignment };