hyperbook 0.113.1 → 0.113.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (54) hide show
  1. package/dist/asset-manifest.json +9 -9
  2. package/dist/assets/directive-bitflow/{EditorElement-zyz99U6n.js → EditorElement-CE3Yr86b.js} +155 -155
  3. package/dist/assets/directive-bitflow/{ReportElements-BnX14NtV.js → ReportElements-eYGRtw6N.js} +1 -1
  4. package/dist/assets/directive-bitflow/{bitLoaders-DIGwTcpd.js → bitLoaders-CxvZkGrY.js} +1138 -1073
  5. package/dist/assets/directive-bitflow/editor.js +3 -3
  6. package/dist/assets/directive-bitflow/flow.js +3 -3
  7. package/dist/assets/directive-bitflow/{index-IQHOi2fr.js → index-88c3K20U.js} +31 -31
  8. package/dist/assets/directive-bitflow/{index-Bqf-kixT.js → index-B61LKxr1.js} +45 -45
  9. package/dist/assets/directive-bitflow/{index-CFcRAa3F.js → index-BG0PL-Z6.js} +30 -30
  10. package/dist/assets/directive-bitflow/{index-B3jMTk1o.js → index-BNdpL6Ss.js} +78 -78
  11. package/dist/assets/directive-bitflow/{index-Fq7njn6_.js → index-BO-d4HVC.js} +48 -48
  12. package/dist/assets/directive-bitflow/{index-Bf_NXJjq.js → index-BZhNY0lo.js} +12 -12
  13. package/dist/assets/directive-bitflow/{index-COndsSPW.js → index-BadyFTU5.js} +8 -8
  14. package/dist/assets/directive-bitflow/{index-CvCZVgKv.js → index-BlT1EcFH.js} +34 -34
  15. package/dist/assets/directive-bitflow/{index-CW9iev-_.js → index-BuQ-K_tR.js} +7 -7
  16. package/dist/assets/directive-bitflow/{index-DjWNEPDL.js → index-Bw0pL0hW.js} +28 -28
  17. package/dist/assets/directive-bitflow/{index-BQ5h4nDN.js → index-BwBVUdJ9.js} +94 -94
  18. package/dist/assets/directive-bitflow/{index-CjscG0z6.js → index-BydYlLy4.js} +73 -73
  19. package/dist/assets/directive-bitflow/{index-BpG316Ls.js → index-C7RJxxAx.js} +63 -63
  20. package/dist/assets/directive-bitflow/{index-eN2S_MLj.js → index-CERSJ9uS.js} +70 -70
  21. package/dist/assets/directive-bitflow/{index-DtsDy2By.js → index-CLHtOGrW.js} +11 -11
  22. package/dist/assets/directive-bitflow/{index-Bf_FQRbK.js → index-CWe2GjBK.js} +14 -14
  23. package/dist/assets/directive-bitflow/{index-CzdZQibq.js → index-CfKpkSVC.js} +72 -72
  24. package/dist/assets/directive-bitflow/{index-Fr7yl4Vn.js → index-CjKhq7gY.js} +23 -23
  25. package/dist/assets/directive-bitflow/{index-DoKlIgCD.js → index-Cm4w1Zyc.js} +38 -38
  26. package/dist/assets/directive-bitflow/{index-D5yZNeIg.js → index-D0U3nepG.js} +52 -52
  27. package/dist/assets/directive-bitflow/{index-C5czXkRd.js → index-D4PdXMcj.js} +33 -33
  28. package/dist/assets/directive-bitflow/{index-BLcJNyog.js → index-D9LOuqr2.js} +99 -99
  29. package/dist/assets/directive-bitflow/{index-BIJ7VfD2.js → index-DIb3CXwC.js} +42 -42
  30. package/dist/assets/directive-bitflow/{index-CZyaFdD2.js → index-DQP0cUsP.js} +70 -70
  31. package/dist/assets/directive-bitflow/{index-ChgzyMHe.js → index-DUOrQfVe.js} +27 -27
  32. package/dist/assets/directive-bitflow/{index-kRpwcprB.js → index-DW3cUBvZ.js} +1 -1
  33. package/dist/assets/directive-bitflow/{index-C_ZTSeqv.js → index-DYWo0PUv.js} +24 -24
  34. package/dist/assets/directive-bitflow/{index-xapm2BQE.js → index-D_QhyFcx.js} +101 -91
  35. package/dist/assets/directive-bitflow/{index-BdBBCZSy.js → index-Dn5hHVuT.js} +226 -193
  36. package/dist/assets/directive-bitflow/{index-D7m-hJZ9.js → index-DruC5d43.js} +69 -69
  37. package/dist/assets/directive-bitflow/{index-e_8twLaN.js → index-EKIgFddO.js} +105 -105
  38. package/dist/assets/directive-bitflow/{index-8jTO-NJA.js → index-HXNGIC7K.js} +70 -70
  39. package/dist/assets/directive-bitflow/{index-DnVYIuen.js → index-ISbOe239.js} +42 -42
  40. package/dist/assets/directive-bitflow/{index-cnRM_JDB.js → index-IsMJtrUT.js} +31 -31
  41. package/dist/assets/directive-bitflow/{index-B7Z6Q-PQ.js → index-TUXuIR22.js} +6 -6
  42. package/dist/assets/directive-bitflow/{index-CK1UMcfT.js → index-WbE9UOFa.js} +24 -24
  43. package/dist/assets/directive-bitflow/{index-YPMWh-1B.js → index-d5ebPDeY.js} +13 -13
  44. package/dist/assets/directive-bitflow/{index-NyNuXp4C.js → index-ledofrbo.js} +33 -33
  45. package/dist/assets/directive-bitflow/{index-BseSaQlX.js → index-oNmOArKu.js} +1 -1
  46. package/dist/assets/directive-bitflow/{index-ivI25bnR.js → index-rp4UTV85.js} +84 -84
  47. package/dist/assets/directive-bitflow/{index-XxGfBwJe.js → index-xTX3CXJW.js} +23 -23
  48. package/dist/assets/directive-bitflow/index.js +6 -6
  49. package/dist/assets/directive-bitflow/katex-DSLAjWZH-CHGN3Pr6.js +11314 -0
  50. package/dist/assets/directive-bitflow/katex-Dv-tcU2S-Dv-tcU2S.js +4 -0
  51. package/dist/assets/directive-bitflow/report.js +1 -1
  52. package/dist/assets/directive-bitflow/{shareableReport-ArQU1XjG.js → shareableReport-vjEU4OvA.js} +2 -2
  53. package/dist/index.js +1 -1
  54. package/package.json +4 -4
@@ -1,5 +1,5 @@
1
- import { L as T, a4 as D, ac as re, ad as J, a9 as K, am as se, a2 as E, a as P, j as a, a5 as Q, P as $, b as A, aa as de, s as ce } from "./dom-uYx_3K1r.js";
2
- import { s as he, N as me, S as G, v as ue, D as q, A as z, e as O, y as M, P as V, M as W, t as U, E as pe, L as be, R as ge } from "./bitLoaders-DIGwTcpd.js";
1
+ import { L as I, a4 as $, ac as re, ad as J, a9 as U, am as se, a2 as E, a as P, j as a, a5 as Q, P as B, b as A, aa as de, s as ce } from "./dom-uYx_3K1r.js";
2
+ import { y as he, j as me, $ as Y, e as ue, h as q, g as z, P as F, C as L, M as V, F as O, r as K, B as pe, U as be, H as ge } from "./bitLoaders-CxvZkGrY.js";
3
3
  const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitflow-space-small)}.bitflow-dragdrop-area{position:relative;width:100%;overflow:hidden;border-radius:var(--bitflow-radius-standard);container-type:inline-size}.bitflow-dragdrop-background{position:absolute;inset:0;width:100%;height:100%;object-fit:contain}.bitflow-dragdrop-noimage{background:var(--bitflow-color-neutral-100)}.bitflow-dragdrop-element{display:flex;align-items:center;justify-content:center;padding:var(--bitflow-space-xxsmall);font:inherit;font-size:clamp(11px,3.5cqw,var(--bitflow-font-size-small));line-height:var(--bitflow-line-height-tight);overflow-wrap:anywhere;color:var(--bitflow-color-text);text-align:center;cursor:grab;background:var(--bitflow-color-surface);border:var(--bitflow-border-width) solid var(--bitflow-color-border);border-radius:var(--bitflow-radius-standard)}.bitflow-dragdrop-element{position:absolute;opacity:var(--bitflow-dragdrop-opacity, 1);touch-action:none}.bitflow-dragdrop-element.bitflow-dragdrop-element-placed{z-index:2}.bitflow-dragdrop-element.bitflow-dragdrop-element-dragging{z-index:3;cursor:grabbing;box-shadow:var(--bitflow-shadow-medium);transition:none}.bitflow-dragdrop-element:disabled{cursor:default}@media(pointer:coarse){.bitflow-dragdrop-element:before{content:"";position:absolute;inset:-10px}}.bitflow-dragdrop-element>img{max-width:100%;max-height:100%}.bitflow-dragdrop-element.bitflow-dragdrop-element-correct{background:color-mix(in srgb,var(--bitflow-color-correct) 18%,var(--bitflow-color-surface));border-color:var(--bitflow-color-correct)}.bitflow-dragdrop-element.bitflow-dragdrop-element-wrong{background:color-mix(in srgb,var(--bitflow-color-wrong) 18%,var(--bitflow-color-surface));border-color:var(--bitflow-color-wrong)}.bitflow-dragdrop-element.bitflow-dragdrop-element-adrift{border-style:dashed;border-color:var(--bitflow-color-neutral-400)}.bitflow-dragdrop-points{position:absolute;top:-8px;right:-8px;min-width:20px;padding:0 4px;font-size:var(--bitflow-font-size-small);font-weight:var(--bitflow-font-weight-bold);line-height:18px;color:var(--bitflow-color-surface);text-align:center;border-radius:10px}.bitflow-dragdrop-points-correct{background:var(--bitflow-color-correct)}.bitflow-dragdrop-points-wrong{background:var(--bitflow-color-wrong)}.bitflow-boxeditor-box.bitflow-dragdrop-handle-zone{border-style:dashed}.bitflow-boxeditor-box.bitflow-dragdrop-handle-element{background:color-mix(in srgb,var(--bitflow-color-surface) 85%,transparent);border-style:solid}.bitflow-rule.bitflow-rule-selected{border-color:var(--bitflow-color-primary);box-shadow:0 0 0 2px var(--bitflow-color-primary)}', ee = (e, i) => {
4
4
  const s = Math.min(e.x + e.width, i.x + i.width) - Math.max(e.x, i.x), r = Math.min(e.y + e.height, i.y + i.height) - Math.max(e.y, i.y);
5
5
  return s > 0 && r > 0 ? s * r : 0;
@@ -48,7 +48,7 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
48
48
  allowRetry: e.evaluation.enableRetry,
49
49
  detail: { placements: s }
50
50
  };
51
- }, X = {
51
+ }, G = {
52
52
  en: {
53
53
  "placement-adrift": "not on any target",
54
54
  pointGained: "one point",
@@ -79,15 +79,15 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
79
79
  "placement-correct": "richtig",
80
80
  "placement-wrong": "nicht richtig"
81
81
  }
82
- }, H = $().min(0).max(1), je = se, Ne = T({
83
- width: $().positive().default(620),
84
- height: $().positive().default(310)
82
+ }, H = B().min(0).max(1), je = se, Ne = I({
83
+ width: B().positive().default(620),
84
+ height: B().positive().default(310)
85
85
  }), te = {
86
86
  x: H,
87
87
  y: H,
88
88
  width: H,
89
89
  height: H
90
- }, ne = $().min(0).max(100).default(100), Ze = T({
90
+ }, ne = B().min(0).max(100).default(100), Ze = I({
91
91
  /** Stable across edits, so an answer keeps pointing at the same element. */
92
92
  id: E().min(1),
93
93
  kind: Q(["text", "image"]).default("text"),
@@ -103,9 +103,9 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
103
103
  * Clones the element on being dragged, so it can fill several zones. Its
104
104
  * maximum score rises accordingly: one point per zone it belongs in.
105
105
  */
106
- multiple: K().default(!1),
106
+ multiple: U().default(!1),
107
107
  backgroundOpacity: ne
108
- }), Pe = T({
108
+ }), Pe = I({
109
109
  id: E().min(1),
110
110
  /**
111
111
  * Names the region in words.
@@ -126,29 +126,29 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
126
126
  */
127
127
  tolerance: Q(["touch", "centre", "fit"]).default("touch"),
128
128
  /** The elements that are right here. */
129
- correctElementIds: D(E()).default([]),
129
+ correctElementIds: $(E()).default([]),
130
130
  /** A nudge available before answering. */
131
131
  tip: E().optional(),
132
132
  feedbackOnCorrect: E().optional(),
133
133
  feedbackOnIncorrect: E().optional(),
134
134
  backgroundOpacity: ne
135
- }), He = T({
135
+ }), He = I({
136
136
  instruction: E().default(""),
137
137
  background: je.default({ src: "", alt: "" }),
138
138
  size: Ne.default({ width: 620, height: 310 }),
139
- elements: D(Ze).default([]),
140
- dropZones: D(Pe).default([]),
139
+ elements: $(Ze).default([]),
140
+ dropZones: $(Pe).default([]),
141
141
  /**
142
142
  * The whole task is worth one point, all or nothing, instead of one point
143
143
  * per element in the right place.
144
144
  */
145
- singlePoint: K().default(!1),
145
+ singlePoint: U().default(!1),
146
146
  /**
147
147
  * An element in the wrong zone costs a point. On by default, as in H5P,
148
148
  * and effectively required once elements can be reused: without it,
149
149
  * dropping every element into every zone scores full marks.
150
150
  */
151
- applyPenalties: K().default(!0),
151
+ applyPenalties: U().default(!0),
152
152
  evaluation: re.default(J)
153
153
  }).check((e) => {
154
154
  const i = e.value.elements.map((t) => t.id);
@@ -226,7 +226,7 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
226
226
  path: ["applyPenalties"],
227
227
  message: "With cloning on and penalties off, dropping every element into every zone scores full marks. Switch penalties on."
228
228
  });
229
- }), Te = T({
229
+ }), Ie = I({
230
230
  elementId: E().min(1),
231
231
  /**
232
232
  * The element's top-left where the learner left it, as fractions of the play
@@ -239,10 +239,10 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
239
239
  */
240
240
  x: H,
241
241
  y: H
242
- }), Oe = T({
242
+ }), Fe = I({
243
243
  /** Where the learner left each element. A clone appears more than once. */
244
- placements: D(Te).default([])
245
- }), Ie = 0.01, Ce = 0.05, Le = ({
244
+ placements: $(Ie).default([])
245
+ }), Te = 0.01, Ce = 0.05, Me = ({
246
246
  data: e,
247
247
  placements: i,
248
248
  judged: s,
@@ -250,7 +250,7 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
250
250
  readonly: t,
251
251
  onChange: c
252
252
  }) => {
253
- const p = (l, o) => A(X, l, r, o), x = P.useRef(null), [, y] = P.useReducer((l) => l + 1, 0), [Z, u] = P.useState(""), v = P.useRef(null), f = (l) => e.elements.find((o) => o.id === l), j = (l) => l.label || l.id, B = (l) => s?.[l]?.state, I = P.useCallback((l, o) => {
253
+ const p = (l, o) => A(G, l, r, o), x = P.useRef(null), [, y] = P.useReducer((l) => l + 1, 0), [Z, u] = P.useState(""), v = P.useRef(null), f = (l) => e.elements.find((o) => o.id === l), j = (l) => l.label || l.id, D = (l) => s?.[l]?.state, T = P.useCallback((l, o) => {
254
254
  const h = v.current?.getBoundingClientRect();
255
255
  return !h || h.width === 0 || h.height === 0 ? null : {
256
256
  x: (l - h.left) / h.width,
@@ -267,7 +267,7 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
267
267
  c(k);
268
268
  }, m = (l, o, h) => {
269
269
  if (t || l.button !== 0) return;
270
- const b = I(l.clientX, l.clientY);
270
+ const b = T(l.clientX, l.clientY);
271
271
  if (!b) return;
272
272
  const g = h === null ? { x: o.x, y: o.y } : i[h];
273
273
  x.current = {
@@ -287,7 +287,7 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
287
287
  he((l) => {
288
288
  const o = x.current;
289
289
  if (!o) return;
290
- const h = I(l.clientX, l.clientY);
290
+ const h = T(l.clientX, l.clientY);
291
291
  if (!h) return;
292
292
  const b = h.x - o.grabX, g = h.y - o.grabY;
293
293
  x.current = {
@@ -302,12 +302,12 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
302
302
  if (!o) return;
303
303
  const h = f(o.elementId);
304
304
  if (x.current = null, y(), !h) return;
305
- const b = I(l.clientX, l.clientY), g = b ? b.x - o.grabX : o.x, k = b ? b.y - o.grabY : o.y, w = o.index === null ? { x: h.x, y: h.y } : i[o.index] ?? { x: h.x, y: h.y };
305
+ const b = T(l.clientX, l.clientY), g = b ? b.x - o.grabX : o.x, k = b ? b.y - o.grabY : o.y, w = o.index === null ? { x: h.x, y: h.y } : i[o.index] ?? { x: h.x, y: h.y };
306
306
  (o.moved || Math.abs(g - w.x) > 4e-3 || Math.abs(k - w.y) > 4e-3) && (n(h, o.index, g, k), u(p("moved", { element: j(h) })));
307
307
  });
308
308
  const d = (l, o, h) => {
309
309
  if (t) return;
310
- const b = l.shiftKey ? Ce : Ie, g = {
310
+ const b = l.shiftKey ? Ce : Te, g = {
311
311
  ArrowLeft: [-b, 0],
312
312
  ArrowRight: [b, 0],
313
313
  ArrowUp: [0, -b],
@@ -325,8 +325,8 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
325
325
  width: `${l.width * 100}%`,
326
326
  height: `${l.height * 100}%`,
327
327
  "--bitflow-dragdrop-opacity": String(o / 100)
328
- }), oe = (l) => l.kind === "image" && l.src ? /* @__PURE__ */ a.jsx("img", { src: l.src, alt: j(l), draggable: !1 }) : /* @__PURE__ */ a.jsx("span", { children: j(l) }), Y = (l, o, h) => {
329
- const b = x.current, g = b?.elementId === l.id && b.index === o && b.moved, k = g ? { x: b.x, y: b.y } : h ?? { x: l.x, y: l.y }, w = o === null ? void 0 : B(o), S = s !== void 0 && o !== null && w === void 0, C = ["bitflow-dragdrop-element"];
328
+ }), oe = (l) => l.kind === "image" && l.src ? /* @__PURE__ */ a.jsx("img", { src: l.src, alt: j(l), draggable: !1 }) : /* @__PURE__ */ a.jsx("span", { children: j(l) }), X = (l, o, h) => {
329
+ const b = x.current, g = b?.elementId === l.id && b.index === o && b.moved, k = g ? { x: b.x, y: b.y } : h ?? { x: l.x, y: l.y }, w = o === null ? void 0 : D(o), S = s !== void 0 && o !== null && w === void 0, C = ["bitflow-dragdrop-element"];
330
330
  return w && C.push(`bitflow-dragdrop-element-${w}`), S && C.push("bitflow-dragdrop-element-adrift"), g && C.push("bitflow-dragdrop-element-dragging"), h && C.push("bitflow-dragdrop-element-placed"), /* @__PURE__ */ a.jsxs(
331
331
  "button",
332
332
  {
@@ -342,13 +342,13 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
342
342
  x: Math.round(k.x * 100),
343
343
  y: Math.round(k.y * 100)
344
344
  }) : l.multiple ? p("cloneable", { element: j(l) }) : j(l),
345
- onPointerDown: (L) => m(L, l, o),
346
- onKeyDown: (L) => {
347
- if (h && o !== null && L.key === "Backspace") {
348
- L.preventDefault(), N(l, o);
345
+ onPointerDown: (M) => m(M, l, o),
346
+ onKeyDown: (M) => {
347
+ if (h && o !== null && M.key === "Backspace") {
348
+ M.preventDefault(), N(l, o);
349
349
  return;
350
350
  }
351
- d(L, l, o);
351
+ d(M, l, o);
352
352
  },
353
353
  children: [
354
354
  oe(l),
@@ -394,10 +394,10 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
394
394
  ) : /* @__PURE__ */ a.jsx("div", { className: "bitflow-dragdrop-background bitflow-dragdrop-noimage" }),
395
395
  e.elements.filter(
396
396
  (l) => l.multiple || !i.some((o) => o.elementId === l.id)
397
- ).map((l) => Y(l, null)),
397
+ ).map((l) => X(l, null)),
398
398
  i.map((l, o) => {
399
399
  const h = f(l.elementId);
400
- return h ? Y(h, o, l) : null;
400
+ return h ? X(h, o, l) : null;
401
401
  })
402
402
  ]
403
403
  }
@@ -522,7 +522,7 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
522
522
  noElements: "Noch keine Elemente.",
523
523
  noZones: "Noch keine Ablagebereiche."
524
524
  }
525
- }, Me = ({
525
+ }, Le = ({
526
526
  data: e,
527
527
  locale: i,
528
528
  selected: s,
@@ -579,7 +579,7 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
579
579
  }) => /* @__PURE__ */ a.jsxs("div", { className: "bitflow-stack", children: [
580
580
  /* @__PURE__ */ a.jsx(be, { markdown: e.instruction }),
581
581
  /* @__PURE__ */ a.jsx(
582
- Le,
582
+ Me,
583
583
  {
584
584
  data: e,
585
585
  placements: i?.placements ?? [],
@@ -593,10 +593,10 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
593
593
  if (e.correctElementIds.length === 0) return s("zoneExpectsNothing");
594
594
  const r = e.correctElementIds.map((t) => i.elements.find((c) => c.id === t)).map((t, c) => t?.label || e.correctElementIds[c]);
595
595
  return `${s("zoneExpectsShort")} ${r.join(", ")}`;
596
- }, De = (e, i, s) => {
596
+ }, $e = (e, i, s) => {
597
597
  const r = i.dropZones.filter((t) => t.correctElementIds.includes(e.id)).map((t) => t.label || t.id);
598
598
  return r.length === 0 ? s("elementBelongsNowhere") : `${s("elementBelongsIn")} ${r.join(", ")}`;
599
- }, F = (e, i) => {
599
+ }, W = (e, i) => {
600
600
  for (let s = i.length + 1; ; s++) {
601
601
  const r = `${e}-${s}`;
602
602
  if (!i.includes(r)) return r;
@@ -610,7 +610,7 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
610
610
  ["y", "top"],
611
611
  ["width", "width"],
612
612
  ["height", "height"]
613
- ].map(([r, t]) => /* @__PURE__ */ a.jsx(U, { label: i(t), children: (c) => /* @__PURE__ */ a.jsx(
613
+ ].map(([r, t]) => /* @__PURE__ */ a.jsx(K, { label: i(t), children: (c) => /* @__PURE__ */ a.jsx(
614
614
  "input",
615
615
  {
616
616
  ...c,
@@ -622,13 +622,13 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
622
622
  value: e[r],
623
623
  onChange: (p) => s(r, Math.min(1, Math.max(0, Number(p.target.value) || 0)))
624
624
  }
625
- ) }, r)) }), $e = ({
625
+ ) }, r)) }), Be = ({
626
626
  data: e,
627
627
  locale: i,
628
628
  onChange: s,
629
629
  errors: r
630
630
  }) => {
631
- const t = (n) => A(le, n, i), c = (n) => s({ ...e, ...n }), [p, x] = P.useState(), y = G(e.dropZones.map((n) => n.id)), Z = G(e.elements.map((n) => n.id)), u = (n) => {
631
+ const t = (n) => A(le, n, i), c = (n) => s({ ...e, ...n }), [p, x] = P.useState(), y = Y(e.dropZones.map((n) => n.id)), Z = Y(e.elements.map((n) => n.id)), u = (n) => {
632
632
  x(n), n && (n.type === "zone" ? y : Z).open(n.id);
633
633
  }, v = (n, m) => c({
634
634
  elements: e.elements.map(
@@ -646,8 +646,8 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
646
646
  ...m,
647
647
  correctElementIds: m.correctElementIds.filter((d) => d !== n)
648
648
  }))
649
- }), B = (n) => c({ dropZones: e.dropZones.filter((m) => m.id !== n) }), I = (n, m, d) => d ? [...n, m] : n.filter((N) => N !== m), R = (n) => {
650
- const m = F("zone", e.dropZones.map((d) => d.id));
649
+ }), D = (n) => c({ dropZones: e.dropZones.filter((m) => m.id !== n) }), T = (n, m, d) => d ? [...n, m] : n.filter((N) => N !== m), R = (n) => {
650
+ const m = W("zone", e.dropZones.map((d) => d.id));
651
651
  c({
652
652
  dropZones: [
653
653
  ...e.dropZones,
@@ -687,7 +687,7 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
687
687
  }
688
688
  ),
689
689
  /* @__PURE__ */ a.jsx(
690
- Me,
690
+ Le,
691
691
  {
692
692
  data: e,
693
693
  locale: i,
@@ -708,14 +708,14 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
708
708
  {
709
709
  className: p?.type === "zone" && p.id === n.id ? "bitflow-rule bitflow-rule-selected" : "bitflow-rule",
710
710
  children: /* @__PURE__ */ a.jsxs(
711
- O,
711
+ F,
712
712
  {
713
713
  summary: n.label || t("zoneUnnamed"),
714
714
  aside: Se(n, e, t),
715
715
  ...y.props(n.id),
716
716
  children: [
717
717
  /* @__PURE__ */ a.jsx(
718
- M,
718
+ L,
719
719
  {
720
720
  label: t("zoneName"),
721
721
  placeholder: t("zoneNamePlaceholder"),
@@ -757,7 +757,7 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
757
757
  type: "checkbox",
758
758
  checked: n.correctElementIds.includes(d.id),
759
759
  onChange: (N) => f(n.id, {
760
- correctElementIds: I(
760
+ correctElementIds: T(
761
761
  n.correctElementIds,
762
762
  d.id,
763
763
  N.target.checked
@@ -769,7 +769,7 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
769
769
  ] }, d.id))
770
770
  ] }),
771
771
  /* @__PURE__ */ a.jsx(
772
- M,
772
+ L,
773
773
  {
774
774
  label: t("zoneTip"),
775
775
  value: n.tip ?? "",
@@ -777,7 +777,7 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
777
777
  }
778
778
  ),
779
779
  /* @__PURE__ */ a.jsx(
780
- M,
780
+ L,
781
781
  {
782
782
  label: t("zoneFeedbackCorrect"),
783
783
  value: n.feedbackOnCorrect ?? "",
@@ -785,7 +785,7 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
785
785
  }
786
786
  ),
787
787
  /* @__PURE__ */ a.jsx(
788
- M,
788
+ L,
789
789
  {
790
790
  label: t("zoneFeedbackIncorrect"),
791
791
  value: n.feedbackOnIncorrect ?? "",
@@ -797,7 +797,7 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
797
797
  {
798
798
  type: "button",
799
799
  className: "bitflow-button bitflow-button-quiet",
800
- onClick: () => B(n.id),
800
+ onClick: () => D(n.id),
801
801
  children: t("remove")
802
802
  }
803
803
  )
@@ -813,7 +813,7 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
813
813
  type: "button",
814
814
  className: "bitflow-button bitflow-button-secondary",
815
815
  onClick: () => {
816
- const n = F("zone", e.dropZones.map((m) => m.id));
816
+ const n = W("zone", e.dropZones.map((m) => m.id));
817
817
  c({
818
818
  dropZones: [
819
819
  ...e.dropZones,
@@ -845,10 +845,10 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
845
845
  {
846
846
  className: p?.type === "element" && p.id === n.id ? "bitflow-rule bitflow-rule-selected" : "bitflow-rule",
847
847
  children: /* @__PURE__ */ a.jsxs(
848
- O,
848
+ F,
849
849
  {
850
850
  summary: n.label || t("elementUnnamed"),
851
- aside: De(n, e, t),
851
+ aside: $e(n, e, t),
852
852
  ...Z.props(n.id),
853
853
  children: [
854
854
  /* @__PURE__ */ a.jsx(
@@ -875,7 +875,7 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
875
875
  onChange: (d) => v(n.id, { src: d.src, label: d.alt })
876
876
  }
877
877
  ) : /* @__PURE__ */ a.jsx(
878
- M,
878
+ L,
879
879
  {
880
880
  label: t("elementText"),
881
881
  value: n.label,
@@ -893,7 +893,7 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
893
893
  ),
894
894
  z(r, `elements.${m}`) && /* @__PURE__ */ a.jsx("span", { className: "bitflow-field-error", role: "alert", children: z(r, `elements.${m}`) }),
895
895
  /* @__PURE__ */ a.jsx(
896
- W,
896
+ O,
897
897
  {
898
898
  label: t("elementMultiple"),
899
899
  hint: t("elementMultipleHint"),
@@ -922,7 +922,7 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
922
922
  type: "button",
923
923
  className: "bitflow-button bitflow-button-secondary",
924
924
  onClick: () => {
925
- const n = F(
925
+ const n = W(
926
926
  "element",
927
927
  e.elements.map((m) => m.id)
928
928
  );
@@ -947,9 +947,9 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
947
947
  }
948
948
  )
949
949
  ] }),
950
- /* @__PURE__ */ a.jsxs(O, { summary: t("advanced"), children: [
950
+ /* @__PURE__ */ a.jsxs(F, { summary: t("advanced"), children: [
951
951
  /* @__PURE__ */ a.jsxs("div", { className: "bitflow-row", children: [
952
- /* @__PURE__ */ a.jsx(U, { label: t("sizeWidth"), hint: t("sizeHint"), children: (n) => /* @__PURE__ */ a.jsx(
952
+ /* @__PURE__ */ a.jsx(K, { label: t("sizeWidth"), hint: t("sizeHint"), children: (n) => /* @__PURE__ */ a.jsx(
953
953
  "input",
954
954
  {
955
955
  ...n,
@@ -965,7 +965,7 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
965
965
  })
966
966
  }
967
967
  ) }),
968
- /* @__PURE__ */ a.jsx(U, { label: t("sizeHeight"), children: (n) => /* @__PURE__ */ a.jsx(
968
+ /* @__PURE__ */ a.jsx(K, { label: t("sizeHeight"), children: (n) => /* @__PURE__ */ a.jsx(
969
969
  "input",
970
970
  {
971
971
  ...n,
@@ -983,7 +983,7 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
983
983
  ) })
984
984
  ] }),
985
985
  /* @__PURE__ */ a.jsx(
986
- W,
986
+ O,
987
987
  {
988
988
  label: t("singlePointLabel"),
989
989
  hint: t("singlePointHint"),
@@ -992,7 +992,7 @@ const fe = '.bitflow-dragdrop{display:flex;flex-direction:column;gap:var(--bitfl
992
992
  }
993
993
  ),
994
994
  /* @__PURE__ */ a.jsx(
995
- W,
995
+ O,
996
996
  {
997
997
  label: t("applyPenaltiesLabel"),
998
998
  hint: t("applyPenaltiesHint"),
@@ -1018,10 +1018,10 @@ de({
1018
1018
  schema: He,
1019
1019
  evaluate: Ee,
1020
1020
  Task: Ae,
1021
- Form: $e,
1021
+ Form: Be,
1022
1022
  info: (e) => ({
1023
- name: A(X, "name", e),
1024
- description: A(X, "description", e)
1023
+ name: A(G, "name", e),
1024
+ description: A(G, "description", e)
1025
1025
  }),
1026
1026
  defaultData: () => ({
1027
1027
  instruction: "",
@@ -1037,14 +1037,14 @@ de({
1037
1037
  ge(ae);
1038
1038
  ce("bitflow-styles-task-drag-drop", fe);
1039
1039
  export {
1040
- Oe as AnswerSchema,
1040
+ Fe as AnswerSchema,
1041
1041
  He as DataSchema,
1042
- Le as DragCanvas,
1042
+ Me as DragCanvas,
1043
1043
  Pe as DropZoneSchema,
1044
- Me as EditorCanvas,
1044
+ Le as EditorCanvas,
1045
1045
  Ze as ElementSchema,
1046
- $e as Form,
1047
- Te as PlacementSchema,
1046
+ Be as Form,
1047
+ Ie as PlacementSchema,
1048
1048
  ae as TYPE,
1049
1049
  Ae as Task,
1050
1050
  Ee as evaluate,
@@ -1053,6 +1053,6 @@ export {
1053
1053
  we as inside,
1054
1054
  ke as judge,
1055
1055
  ze as maxScore,
1056
- X as messages,
1056
+ G as messages,
1057
1057
  ve as zoneUnder
1058
1058
  };
@@ -1,5 +1,5 @@
1
1
  import { L as w, a2 as l, a9 as k, j as i, a as c, b as u, s as y, aa as L } from "./dom-uYx_3K1r.js";
2
- import { y as h, v as j, M as x, t as q, L as S, R as z } from "./bitLoaders-DIGwTcpd.js";
2
+ import { C as h, e as j, F as x, r as q, U as S, H as z } from "./bitLoaders-CxvZkGrY.js";
3
3
  const T = ".bitflow-handoff-state{margin:0;min-height:var(--bitflow-space-small);font-size:var(--bitflow-font-size-small);color:var(--bitflow-color-text-muted)}.bitflow-handoff-sent{color:var(--bitflow-color-correct)}.bitflow-handoff-failed,.bitflow-handoff-misconfigured{color:var(--bitflow-color-wrong)}.bitflow-handoff-link{color:var(--bitflow-color-primary-dark);text-underline-offset:.2em}", g = {
4
4
  en: {
5
5
  name: "Finish and hand back",
@@ -89,7 +89,7 @@ const T = ".bitflow-handoff-state{margin:0;min-height:var(--bitflow-space-small)
89
89
  misconfigured: "Bu değerlendirme bir yere gönderecek şekilde ayarlanmamış. Hazırlayan kişiye söyle — çalışman sekmeyi kapatana kadar burada duruyor.",
90
90
  unframed: "Bu sayfa gönderilebilecek bir sayfanın içinde değil, bu yüzden çalışman hiçbir yere gitmedi. Hazırlayan kişiye söyle — çalışman sekmeyi kapatana kadar burada duruyor."
91
91
  }
92
- }, M = w({
92
+ }, U = w({
93
93
  title: l().default(""),
94
94
  markdown: l().default(""),
95
95
  /**
@@ -134,7 +134,7 @@ const T = ".bitflow-handoff-state{margin:0;min-height:var(--bitflow-space-small)
134
134
  } catch {
135
135
  return !1;
136
136
  }
137
- }, U = {
137
+ }, H = {
138
138
  en: {
139
139
  titleLabel: "Title",
140
140
  markdownLabel: "Closing message",
@@ -165,7 +165,7 @@ const T = ".bitflow-handoff-state{margin:0;min-height:var(--bitflow-space-small)
165
165
  continueLabelLabel: "Beschriftung des Links",
166
166
  continueLabelHint: "Leer lassen für „Weiter“."
167
167
  }
168
- }, H = () => typeof window < "u" && window.parent !== window.self, C = ({
168
+ }, M = () => typeof window < "u" && window.parent !== window.self, C = ({
169
169
  data: e,
170
170
  locale: r,
171
171
  readonly: t,
@@ -177,7 +177,7 @@ const T = ".bitflow-handoff-state{margin:0;min-height:var(--bitflow-space-small)
177
177
  n("misconfigured");
178
178
  return;
179
179
  }
180
- if (!H()) {
180
+ if (!M()) {
181
181
  n("unframed");
182
182
  return;
183
183
  }
@@ -216,12 +216,12 @@ const T = ".bitflow-handoff-state{margin:0;min-height:var(--bitflow-space-small)
216
216
  ] }),
217
217
  f(e.continueUrl) && /* @__PURE__ */ i.jsx("p", { children: /* @__PURE__ */ i.jsx("a", { className: "bitflow-handoff-link", href: e.continueUrl.trim(), children: e.continueLabel || s("continueFallback") }) })
218
218
  ] });
219
- }, E = ({
219
+ }, F = ({
220
220
  data: e,
221
221
  locale: r,
222
222
  onChange: t
223
223
  }) => {
224
- const a = (n) => u(U, n, r), s = e.postMessage && e.messageOrigin.trim() !== "" && !m(e.messageOrigin) ? a("originInvalid") : void 0, o = e.continueUrl.trim() !== "" && !f(e.continueUrl) ? a("continueUrlInvalid") : void 0;
224
+ const a = (n) => u(H, n, r), s = e.postMessage && e.messageOrigin.trim() !== "" && !m(e.messageOrigin) ? a("originInvalid") : void 0, o = e.continueUrl.trim() !== "" && !f(e.continueUrl) ? a("continueUrlInvalid") : void 0;
225
225
  return /* @__PURE__ */ i.jsxs("div", { className: "bitflow-stack", children: [
226
226
  /* @__PURE__ */ i.jsx(
227
227
  h,
@@ -294,9 +294,9 @@ const b = "end-handoff";
294
294
  L({
295
295
  type: b,
296
296
  kind: "end",
297
- schema: M,
297
+ schema: U,
298
298
  Task: C,
299
- Form: E,
299
+ Form: F,
300
300
  info: (e) => ({
301
301
  name: u(g, "name", e),
302
302
  description: u(g, "description", e)
@@ -314,8 +314,8 @@ L({
314
314
  });
315
315
  z(b);
316
316
  export {
317
- M as DataSchema,
318
- E as Form,
317
+ U as DataSchema,
318
+ F as Form,
319
319
  A as MESSAGE_TYPE,
320
320
  b as TYPE,
321
321
  C as Task,
@@ -1,5 +1,5 @@
1
- import { L as u, a9 as f, ac as y, ad as m, ab as c, a2 as g, j as n, b as r, s as p, aa as v } from "./dom-uYx_3K1r.js";
2
- import { v as k, P as w, y as b, e as N, E as j, L as x, R as L } from "./bitLoaders-DIGwTcpd.js";
1
+ import { L as u, a9 as f, ac as g, ad as m, ab as c, a2 as y, j as n, b as r, s as p, aa as k } from "./dom-uYx_3K1r.js";
2
+ import { e as v, M as w, C as b, P as N, B as j, U as x, H as L } from "./bitLoaders-CxvZkGrY.js";
3
3
  const W = ".bitflow-yes-no{border:0;margin:0;padding:0;display:flex;gap:var(--bitflow-space-xsmall)}.bitflow-yes-no .bitflow-option{flex:1;justify-content:center;align-items:center}", q = ({
4
4
  data: e,
5
5
  answer: o
@@ -48,17 +48,17 @@ const W = ".bitflow-yes-no{border:0;margin:0;padding:0;display:flex;gap:var(--bi
48
48
  it: { name: "Sì / No", description: "Una domanda con risposta sì o no.", yes: "Sì", no: "No", legend: "Scegli sì o no" },
49
49
  pt: { name: "Sim / Não", description: "Uma pergunta de sim ou não.", yes: "Sim", no: "Não", legend: "Escolhe sim ou não" },
50
50
  tr: { name: "Evet / Hayır", description: "Evet ya da hayır ile yanıtlanan bir soru.", yes: "Evet", no: "Hayır", legend: "Evet ya da hayır seçin" }
51
- }, E = u({
51
+ }, C = u({
52
52
  /** The statement or question, as Markdown. */
53
- question: g().default(""),
53
+ question: y().default(""),
54
54
  /** Which answer counts as right. */
55
55
  correctAnswer: f().default(!0),
56
56
  /** Shown when the learner answered yes and yes was wrong. */
57
57
  feedbackWhenYes: c.optional(),
58
58
  /** Shown when the learner answered no and no was wrong. */
59
59
  feedbackWhenNo: c.optional(),
60
- evaluation: y.default(m)
61
- }), F = u({ yes: f() }), A = ({
60
+ evaluation: g.default(m)
61
+ }), Y = u({ yes: f() }), A = ({
62
62
  data: e,
63
63
  answer: o,
64
64
  readonly: t,
@@ -85,7 +85,7 @@ const W = ".bitflow-yes-no{border:0;margin:0;padding:0;display:flex;gap:var(--bi
85
85
  ] }, String(l)))
86
86
  ] })
87
87
  ] });
88
- }, S = ({
88
+ }, E = ({
89
89
  data: e,
90
90
  locale: o,
91
91
  onChange: t
@@ -93,7 +93,7 @@ const W = ".bitflow-yes-no{border:0;margin:0;padding:0;display:flex;gap:var(--bi
93
93
  const s = (a) => r(d, a, o), i = (a) => t({ ...e, ...a });
94
94
  return /* @__PURE__ */ n.jsxs("div", { className: "bitflow-stack", children: [
95
95
  /* @__PURE__ */ n.jsx(
96
- k,
96
+ v,
97
97
  {
98
98
  label: s("questionLabel"),
99
99
  hint: s("questionHint"),
@@ -149,13 +149,13 @@ const W = ".bitflow-yes-no{border:0;margin:0;padding:0;display:flex;gap:var(--bi
149
149
  };
150
150
  p("bitflow-styles-task-yes-no", W);
151
151
  const h = "task-yes-no";
152
- v({
152
+ k({
153
153
  type: h,
154
154
  kind: "task",
155
- schema: E,
155
+ schema: C,
156
156
  evaluate: q,
157
157
  Task: A,
158
- Form: S,
158
+ Form: E,
159
159
  info: (e) => ({
160
160
  name: r(d, "name", e),
161
161
  description: r(d, "description", e)
@@ -168,9 +168,9 @@ v({
168
168
  });
169
169
  L(h);
170
170
  export {
171
- F as AnswerSchema,
172
- E as DataSchema,
173
- S as Form,
171
+ Y as AnswerSchema,
172
+ C as DataSchema,
173
+ E as Form,
174
174
  h as TYPE,
175
175
  A as Task,
176
176
  q as evaluate,