hyperbook 0.113.1 → 0.113.3

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 (55) hide show
  1. package/dist/asset-manifest.json +9 -9
  2. package/dist/assets/directive-bitflow/{EditorElement-zyz99U6n.js → EditorElement-BNwEKIvk.js} +258 -258
  3. package/dist/assets/directive-bitflow/{ReportElements-BnX14NtV.js → ReportElements-CAvHx5xm.js} +2 -2
  4. package/dist/assets/directive-bitflow/{bitLoaders-DIGwTcpd.js → bitLoaders-7qanePQL.js} +1138 -1073
  5. package/dist/assets/directive-bitflow/{dom-uYx_3K1r.js → dom-B6NPWBb1.js} +1558 -1551
  6. package/dist/assets/directive-bitflow/editor.js +3 -3
  7. package/dist/assets/directive-bitflow/flow.js +4 -4
  8. package/dist/assets/directive-bitflow/{index-BseSaQlX.js → index-4JaKZ7WT.js} +2 -2
  9. package/dist/assets/directive-bitflow/{index-e_8twLaN.js → index-6CQr_atd.js} +120 -120
  10. package/dist/assets/directive-bitflow/{index-COndsSPW.js → index-B9iG-a48.js} +9 -9
  11. package/dist/assets/directive-bitflow/{index-C5czXkRd.js → index-BFYoOtcY.js} +36 -36
  12. package/dist/assets/directive-bitflow/{index-YPMWh-1B.js → index-BI6aFdIS.js} +21 -21
  13. package/dist/assets/directive-bitflow/{index-D7m-hJZ9.js → index-Bf078mfo.js} +69 -69
  14. package/dist/assets/directive-bitflow/{index-Bf_FQRbK.js → index-BinE5Wvd.js} +19 -19
  15. package/dist/assets/directive-bitflow/{index-CFcRAa3F.js → index-BoX5-jkC.js} +31 -31
  16. package/dist/assets/directive-bitflow/{index-NyNuXp4C.js → index-BqRsXShM.js} +34 -34
  17. package/dist/assets/directive-bitflow/{index-Fr7yl4Vn.js → index-BxihQ8Oo.js} +21 -21
  18. package/dist/assets/directive-bitflow/{index-B3jMTk1o.js → index-C5YguHZU.js} +101 -101
  19. package/dist/assets/directive-bitflow/{index-XxGfBwJe.js → index-C8zwSmE6.js} +27 -27
  20. package/dist/assets/directive-bitflow/{index-BLcJNyog.js → index-C9JSBTNc.js} +91 -91
  21. package/dist/assets/directive-bitflow/{index-CjscG0z6.js → index-CCMI6UK4.js} +75 -75
  22. package/dist/assets/directive-bitflow/{index-CK1UMcfT.js → index-CGDt8H6s.js} +24 -24
  23. package/dist/assets/directive-bitflow/{index-xapm2BQE.js → index-Ca1v0pjV.js} +102 -92
  24. package/dist/assets/directive-bitflow/{index-IQHOi2fr.js → index-CaYn3Gmh.js} +31 -31
  25. package/dist/assets/directive-bitflow/{index-BpG316Ls.js → index-CbQue0If.js} +67 -67
  26. package/dist/assets/directive-bitflow/{index-CzdZQibq.js → index-CjH3h0OO.js} +79 -79
  27. package/dist/assets/directive-bitflow/{index-B7Z6Q-PQ.js → index-CkO3QfOS.js} +8 -8
  28. package/dist/assets/directive-bitflow/{index-BIJ7VfD2.js → index-Cz4i5rfe.js} +39 -39
  29. package/dist/assets/directive-bitflow/{index-8jTO-NJA.js → index-D0NtgeiX.js} +85 -85
  30. package/dist/assets/directive-bitflow/{index-DtsDy2By.js → index-D1C_1SPY.js} +14 -14
  31. package/dist/assets/directive-bitflow/{index-BdBBCZSy.js → index-D45u7EVR.js} +227 -194
  32. package/dist/assets/directive-bitflow/{index-cnRM_JDB.js → index-D9Ox4YpM.js} +33 -33
  33. package/dist/assets/directive-bitflow/{index-Bqf-kixT.js → index-DJ1w2Xcm.js} +46 -46
  34. package/dist/assets/directive-bitflow/{index-BQ5h4nDN.js → index-DUqW2fmV.js} +94 -94
  35. package/dist/assets/directive-bitflow/{index-ChgzyMHe.js → index-Deedj9EF.js} +25 -25
  36. package/dist/assets/directive-bitflow/{index-CZyaFdD2.js → index-Dg6nnY_v.js} +68 -68
  37. package/dist/assets/directive-bitflow/{index-kRpwcprB.js → index-DgxEzomz.js} +2 -2
  38. package/dist/assets/directive-bitflow/{index-D5yZNeIg.js → index-Dl0-ZAT5.js} +52 -52
  39. package/dist/assets/directive-bitflow/{index-DnVYIuen.js → index-Do6dmZyj.js} +42 -42
  40. package/dist/assets/directive-bitflow/{index-DjWNEPDL.js → index-DqnGC-DU.js} +31 -31
  41. package/dist/assets/directive-bitflow/{index-ivI25bnR.js → index-DwXXeSwk.js} +73 -73
  42. package/dist/assets/directive-bitflow/{index-Bf_NXJjq.js → index-b6qwcTj9.js} +15 -15
  43. package/dist/assets/directive-bitflow/{index-Fq7njn6_.js → index-d105UFQI.js} +58 -58
  44. package/dist/assets/directive-bitflow/{index-CW9iev-_.js → index-jijMWQB6.js} +8 -8
  45. package/dist/assets/directive-bitflow/{index-C_ZTSeqv.js → index-kxO5_U9Y.js} +24 -24
  46. package/dist/assets/directive-bitflow/{index-DoKlIgCD.js → index-p5AOgOal.js} +35 -35
  47. package/dist/assets/directive-bitflow/{index-CvCZVgKv.js → index-q2APknM6.js} +46 -46
  48. package/dist/assets/directive-bitflow/{index-eN2S_MLj.js → index-zVkWgm5I.js} +70 -70
  49. package/dist/assets/directive-bitflow/index.js +6 -6
  50. package/dist/assets/directive-bitflow/katex-DSLAjWZH-CHGN3Pr6.js +11314 -0
  51. package/dist/assets/directive-bitflow/katex-Dv-tcU2S-Dv-tcU2S.js +4 -0
  52. package/dist/assets/directive-bitflow/report.js +1 -1
  53. package/dist/assets/directive-bitflow/{shareableReport-ArQU1XjG.js → shareableReport-mdyEMdsJ.js} +6 -6
  54. package/dist/index.js +1 -1
  55. package/package.json +2 -2
@@ -1,6 +1,6 @@
1
- import { L as S, ak as Z, a2 as f, P as q, j as t, a5 as V, ac as F, ad as K, a9 as T, a4 as E, b as N, aa as _, s as G } from "./dom-uYx_3K1r.js";
2
- import { v as $, y as U, A as C, _ as y, e as B, M as A, E as Y, L as J, R as Q } from "./bitLoaders-DIGwTcpd.js";
3
- const X = ["value", "output", "line"], ee = V(X), te = S({
1
+ import { P as S, ak as Z, a2 as f, Y as F, j as t, a5 as q, ac as U, ad as R, a9 as T, a4 as $, b as N, aa as V, s as B } from "./dom-B6NPWBb1.js";
2
+ import { e as E, C as G, g as C, i as y, P as Y, F as A, B as _, U as J, H as Q } from "./bitLoaders-7qanePQL.js";
3
+ const X = ["value", "output", "line"], ee = q(X), te = S({
4
4
  /** Stable across edits, so an answer keeps pointing at the same column. */
5
5
  id: f().min(1),
6
6
  /** The heading. A variable name for a `value` column. */
@@ -14,7 +14,7 @@ const X = ["value", "output", "line"], ee = V(X), te = S({
14
14
  * The line the checkpoint sits at, 1-based, or omitted. Only a signpost —
15
15
  * it marks the row in the listing so the learner can see where they are.
16
16
  */
17
- line: q().int().positive().optional(),
17
+ line: F().int().positive().optional(),
18
18
  /** Column id → the value expected there. An empty string means "blank". */
19
19
  expected: Z(f(), f()).default({})
20
20
  }), O = (e) => e.replace(/\n$/, "").split(`
@@ -30,8 +30,8 @@ const X = ["value", "output", "line"], ee = V(X), te = S({
30
30
  /** Shown as text, always. */
31
31
  code: f().default(""),
32
32
  showLineNumbers: T().default(!0),
33
- columns: E(te).default([]),
34
- checkpoints: E(ne).default([]),
33
+ columns: $(te).default([]),
34
+ checkpoints: $(ne).default([]),
35
35
  /**
36
36
  * Whether capital letters decide a mark. Off by default: `True` and `true`
37
37
  * are the same prediction about what the program does, and which spelling
@@ -44,7 +44,7 @@ const X = ["value", "output", "line"], ee = V(X), te = S({
44
44
  * and that is the thing worth knowing.
45
45
  */
46
46
  partialCredit: T().default(!0),
47
- evaluation: F.default(K)
47
+ evaluation: U.default(R)
48
48
  }).check((e) => {
49
49
  const { columns: i, checkpoints: s, code: o } = e.value, n = i.map((d) => d.id);
50
50
  new Set(n).size !== n.length && e.issues.push({
@@ -115,7 +115,7 @@ const X = ["value", "output", "line"], ee = V(X), te = S({
115
115
  }), ke = S({
116
116
  /** Checkpoint id → column id → what the learner wrote. */
117
117
  cells: Z(f(), Z(f(), f())).default({})
118
- }), M = (e, i, s) => e?.cells?.[i]?.[s] ?? "", le = (e) => ({
118
+ }), W = (e, i, s) => e?.cells?.[i]?.[s] ?? "", le = (e) => ({
119
119
  cells: Object.fromEntries(
120
120
  e.checkpoints.map((i) => [i.id, i.expected])
121
121
  )
@@ -127,11 +127,11 @@ const X = ["value", "output", "line"], ee = V(X), te = S({
127
127
  ...e?.cells,
128
128
  [i]: { ...e?.cells?.[i], [s]: o }
129
129
  }
130
- }), se = /^[+-]?(?:\d+\.?\d*|\.\d+)(?:[eE][+-]?\d+)?$/, P = (e) => se.test(e) ? Number(e) : void 0, R = (e, i) => {
130
+ }), se = /^[+-]?(?:\d+\.?\d*|\.\d+)(?:[eE][+-]?\d+)?$/, P = (e) => se.test(e) ? Number(e) : void 0, D = (e, i) => {
131
131
  const s = e.trim().replace(/\s+/g, " ").replace(/\s*([,;:[\]{}()])\s*/g, "$1").trim();
132
132
  return i ? s : s.toLowerCase();
133
133
  }, re = (e, i, s) => {
134
- const o = R(e, s), n = R(i, s), r = P(o), h = P(r === void 0 ? n : n.replace(/^([+-]?\d+),(\d+)$/, "$1.$2"));
134
+ const o = D(e, s), n = D(i, s), r = P(o), h = P(r === void 0 ? n : n.replace(/^([+-]?\d+),(\d+)$/, "$1.$2"));
135
135
  if (r !== void 0 && h !== void 0) return r === h;
136
136
  if (!s) {
137
137
  const u = (d) => d === "true" || d === "wahr" ? "true" : d === "false" || d === "falsch" ? "false" : d;
@@ -145,7 +145,7 @@ const X = ["value", "output", "line"], ee = V(X), te = S({
145
145
  for (const n of e.columns) {
146
146
  const r = re(
147
147
  o.expected[n.id] ?? "",
148
- M(i, o.id, n.id),
148
+ W(i, o.id, n.id),
149
149
  e.caseSensitive
150
150
  );
151
151
  s[o.id][n.id] = r ? "correct" : "wrong";
@@ -220,7 +220,7 @@ const X = ["value", "output", "line"], ee = V(X), te = S({
220
220
  correct: "richtig",
221
221
  wrong: "falsch"
222
222
  }
223
- }, he = ".bitflow-trace-code{margin:0;display:flex;flex-direction:column;gap:var(--bitflow-space-xxsmall)}.bitflow-trace-lines{margin:0;padding:var(--bitflow-space-xsmall);list-style:none;background:var(--bitflow-color-surface);border:1px solid var(--bitflow-color-border);border-radius:var(--bitflow-radius-standard);overflow-x:auto}.bitflow-trace-line{display:flex;align-items:baseline;gap:var(--bitflow-space-xsmall)}.bitflow-trace-line code{font-family:var(--bitflow-font-family-mono);font-size:var(--bitflow-font-size-small);white-space:pre}.bitflow-trace-number{flex:none;width:1.75rem;font-family:var(--bitflow-font-family-mono);font-size:var(--bitflow-font-size-small);font-variant-numeric:tabular-nums;color:var(--bitflow-color-text-muted);text-align:right;-webkit-user-select:none;user-select:none}.bitflow-trace-mark{flex:none;padding:0 var(--bitflow-space-xsmall);font-size:var(--bitflow-font-size-small);color:var(--bitflow-color-info);background:var(--bitflow-color-info-surface);border-radius:var(--bitflow-radius-full)}.bitflow-trace-scroll{overflow-x:auto}.bitflow-trace-table{border-collapse:collapse;width:auto;min-width:100%}.bitflow-trace-table caption{text-align:left;padding-bottom:var(--bitflow-space-xxsmall)}.bitflow-trace-table th,.bitflow-trace-table td{padding:var(--bitflow-space-xxsmall);border:1px solid var(--bitflow-color-border);text-align:left;vertical-align:middle}.bitflow-trace-table thead th{background:var(--bitflow-color-neutral-100);font-weight:var(--bitflow-font-weight-medium);white-space:nowrap}.bitflow-trace-table tbody th{font-weight:var(--bitflow-font-weight-standard);background:var(--bitflow-color-neutral-100)}.bitflow-trace-note{display:block;font-size:var(--bitflow-font-size-small);font-weight:var(--bitflow-font-weight-standard);color:var(--bitflow-color-text-muted)}.bitflow-trace-cell{padding:var(--bitflow-space-xxsmall)}.bitflow-trace-input,.bitflow-trace-select{min-height:2.25rem;min-width:var(--bitflow-trace-cell-width, 7rem)}.bitflow-trace-input{font-family:var(--bitflow-font-family-mono)}.bitflow-trace-cell-correct .bitflow-input,.bitflow-trace-cell-correct .bitflow-select{border-color:var(--bitflow-color-correct);background:var(--bitflow-color-correct-surface)}.bitflow-trace-cell-wrong .bitflow-input,.bitflow-trace-cell-wrong .bitflow-select{border-color:var(--bitflow-color-wrong);background:var(--bitflow-color-wrong-surface)}.bitflow-trace-editor-row{display:flex;flex-wrap:wrap;align-items:center;gap:var(--bitflow-space-xsmall)}.bitflow-trace-editor-row>.bitflow-input,.bitflow-trace-editor-row>.bitflow-select{flex:1 1 var(--bitflow-trace-editor-min, 7rem);min-width:0}", me = {
223
+ }, he = ".bitflow-trace-code{margin:0;display:flex;flex-direction:column;gap:var(--bitflow-space-xxsmall)}.bitflow-trace-lines{margin:0;padding:var(--bitflow-space-xsmall);list-style:none;background:var(--bitflow-color-surface);border:1px solid var(--bitflow-color-border);border-radius:var(--bitflow-radius-standard);overflow-x:auto}.bitflow-trace-line{display:flex;align-items:baseline;gap:var(--bitflow-space-xsmall)}.bitflow-trace-line code{font-family:var(--bitflow-font-family-mono);font-size:var(--bitflow-font-size-small);white-space:pre}.bitflow-trace-number{flex:none;width:1.75rem;font-family:var(--bitflow-font-family-mono);font-size:var(--bitflow-font-size-small);font-variant-numeric:tabular-nums;color:var(--bitflow-color-text-muted);text-align:right;-webkit-user-select:none;user-select:none}.bitflow-trace-mark{flex:none;padding:0 var(--bitflow-space-xsmall);font-size:var(--bitflow-font-size-small);color:var(--bitflow-color-info);background:var(--bitflow-color-info-surface);border-radius:var(--bitflow-radius-full)}.bitflow-trace-scroll{overflow-x:auto}.bitflow-trace-table{border-collapse:collapse;width:auto;min-width:100%}.bitflow-trace-table caption{text-align:left;padding-bottom:var(--bitflow-space-xxsmall)}.bitflow-trace-table th,.bitflow-trace-table td{padding:var(--bitflow-space-xxsmall);border:1px solid var(--bitflow-color-border);text-align:left;vertical-align:middle}.bitflow-trace-table thead th{background:var(--bitflow-color-neutral-100);font-weight:var(--bitflow-font-weight-medium);white-space:nowrap;vertical-align:top;padding:var(--bitflow-space-xsmall)}.bitflow-trace-table tbody th{font-weight:var(--bitflow-font-weight-standard);background:var(--bitflow-color-neutral-100);min-width:var(--bitflow-trace-moment-width, 10rem);padding-inline:var(--bitflow-space-xsmall)}.bitflow-trace-note{display:block;font-size:var(--bitflow-font-size-small);font-weight:var(--bitflow-font-weight-standard);color:var(--bitflow-color-text-muted)}.bitflow-trace-cell{padding:var(--bitflow-space-xxsmall)}.bitflow-trace-input,.bitflow-trace-select{min-height:2.25rem;min-width:var(--bitflow-trace-cell-width, 7rem)}.bitflow-trace-input{font-family:var(--bitflow-font-family-mono)}.bitflow-trace-cell-correct .bitflow-input,.bitflow-trace-cell-correct .bitflow-select{border-color:var(--bitflow-color-correct);background:var(--bitflow-color-correct-surface)}.bitflow-trace-cell-wrong .bitflow-input,.bitflow-trace-cell-wrong .bitflow-select{border-color:var(--bitflow-color-wrong);background:var(--bitflow-color-wrong-surface)}.bitflow-trace-editor-row{display:flex;flex-wrap:wrap;align-items:center;gap:var(--bitflow-space-xsmall)}.bitflow-trace-editor-row>.bitflow-input,.bitflow-trace-editor-row>.bitflow-select{flex:1 1 var(--bitflow-trace-editor-min, 7rem);min-width:0}", me = {
224
224
  en: {
225
225
  instructionLabel: "Instruction",
226
226
  instructionHint: "Shown above the program. Markdown is allowed.",
@@ -327,7 +327,7 @@ const X = ["value", "output", "line"], ee = V(X), te = S({
327
327
  (r.get(u + 1) ?? []).map((d) => /* @__PURE__ */ t.jsx("span", { className: "bitflow-trace-mark", children: d }, d))
328
328
  ] }, u)) })
329
329
  ] });
330
- }, W = ({
330
+ }, I = ({
331
331
  data: e,
332
332
  answer: i,
333
333
  states: s,
@@ -354,7 +354,7 @@ const X = ["value", "output", "line"], ee = V(X), te = S({
354
354
  m.line !== void 0 && /* @__PURE__ */ t.jsx("span", { className: "bitflow-trace-note", children: u("atLine", { line: m.line }) })
355
355
  ] }),
356
356
  e.columns.map((v, a) => {
357
- const l = s?.[m.id]?.[v.id], c = M(i, m.id, v.id), w = u("cellLabel", {
357
+ const l = s?.[m.id]?.[v.id], c = W(i, m.id, v.id), w = u("cellLabel", {
358
358
  column: p(v, a),
359
359
  step: j
360
360
  }), x = (k) => h(oe(i, m.id, v.id, k));
@@ -416,7 +416,7 @@ const X = ["value", "output", "line"], ee = V(X), te = S({
416
416
  /* @__PURE__ */ t.jsx("p", { className: "bitflow-text-muted", children: h(o ? "howToReadonly" : "howTo") }),
417
417
  /* @__PURE__ */ t.jsx(be, { data: e, locale: n, showNumbers: pe(e) }),
418
418
  /* @__PURE__ */ t.jsx(
419
- W,
419
+ I,
420
420
  {
421
421
  data: e,
422
422
  answer: i,
@@ -427,7 +427,7 @@ const X = ["value", "output", "line"], ee = V(X), te = S({
427
427
  }
428
428
  )
429
429
  ] });
430
- }, D = (e, i) => {
430
+ }, K = (e, i) => {
431
431
  for (let s = i.length + 1; ; s++) {
432
432
  const o = `${e}-${s}`;
433
433
  if (!i.includes(o)) return o;
@@ -466,7 +466,7 @@ const X = ["value", "output", "line"], ee = V(X), te = S({
466
466
  });
467
467
  return /* @__PURE__ */ t.jsxs("div", { className: "bitflow-stack", children: [
468
468
  /* @__PURE__ */ t.jsx(
469
- $,
469
+ E,
470
470
  {
471
471
  label: n("instructionLabel"),
472
472
  hint: n("instructionHint"),
@@ -476,7 +476,7 @@ const X = ["value", "output", "line"], ee = V(X), te = S({
476
476
  }
477
477
  ),
478
478
  /* @__PURE__ */ t.jsx(
479
- U,
479
+ G,
480
480
  {
481
481
  label: n("languageLabel"),
482
482
  hint: n("languageHint"),
@@ -485,7 +485,7 @@ const X = ["value", "output", "line"], ee = V(X), te = S({
485
485
  }
486
486
  ),
487
487
  /* @__PURE__ */ t.jsx(
488
- $,
488
+ E,
489
489
  {
490
490
  label: n("codeLabel"),
491
491
  hint: n("codeHint"),
@@ -583,7 +583,7 @@ const X = ["value", "output", "line"], ee = V(X), te = S({
583
583
  columns: [
584
584
  ...e.columns,
585
585
  {
586
- id: D("column", e.columns.map((a) => a.id)),
586
+ id: K("column", e.columns.map((a) => a.id)),
587
587
  name: "",
588
588
  kind: "value"
589
589
  }
@@ -688,7 +688,7 @@ const X = ["value", "output", "line"], ee = V(X), te = S({
688
688
  checkpoints: [
689
689
  ...e.checkpoints,
690
690
  {
691
- id: D(
691
+ id: K(
692
692
  "checkpoint",
693
693
  e.checkpoints.map((a) => a.id)
694
694
  ),
@@ -705,7 +705,7 @@ const X = ["value", "output", "line"], ee = V(X), te = S({
705
705
  /* @__PURE__ */ t.jsx("span", { className: "bitflow-hint", children: n("answerKeyHint") }),
706
706
  e.columns.length === 0 || e.checkpoints.length === 0 ? /* @__PURE__ */ t.jsx("p", { className: "bitflow-text-muted", children: n("answerKeyEmpty") }) : /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
707
707
  /* @__PURE__ */ t.jsx(
708
- W,
708
+ I,
709
709
  {
710
710
  data: e,
711
711
  answer: le(e),
@@ -725,7 +725,7 @@ const X = ["value", "output", "line"], ee = V(X), te = S({
725
725
  ))
726
726
  ] })
727
727
  ] }),
728
- /* @__PURE__ */ t.jsxs(B, { summary: n("advanced"), children: [
728
+ /* @__PURE__ */ t.jsxs(Y, { summary: n("advanced"), children: [
729
729
  /* @__PURE__ */ t.jsx(
730
730
  A,
731
731
  {
@@ -754,7 +754,7 @@ const X = ["value", "output", "line"], ee = V(X), te = S({
754
754
  }
755
755
  ),
756
756
  /* @__PURE__ */ t.jsx(
757
- Y,
757
+ _,
758
758
  {
759
759
  evaluation: e.evaluation,
760
760
  locale: i,
@@ -765,9 +765,9 @@ const X = ["value", "output", "line"], ee = V(X), te = S({
765
765
  ] });
766
766
  }, ge = (e) => (e ?? []).filter(
767
767
  (i) => /^checkpoints\.\d+\.expected\./.test(i.path)
768
- ), I = "task-code-trace";
769
- _({
770
- type: I,
768
+ ), M = "task-code-trace";
769
+ V({
770
+ type: M,
771
771
  kind: "task",
772
772
  schema: ae,
773
773
  evaluate: ue,
@@ -786,11 +786,11 @@ _({
786
786
  checkpoints: [],
787
787
  caseSensitive: !1,
788
788
  partialCredit: !0,
789
- evaluation: K()
789
+ evaluation: R()
790
790
  })
791
791
  });
792
- Q(I);
793
- G("bitflow-styles-task-code-trace", he);
792
+ Q(M);
793
+ B("bitflow-styles-task-code-trace", he);
794
794
  export {
795
795
  ke as AnswerSchema,
796
796
  X as COLUMN_KINDS,
@@ -800,18 +800,18 @@ export {
800
800
  te as ColumnSchema,
801
801
  ae as DataSchema,
802
802
  we as Form,
803
- I as TYPE,
803
+ M as TYPE,
804
804
  fe as Task,
805
- W as TraceTable,
805
+ I as TraceTable,
806
806
  de as allCorrect,
807
807
  re as cellCorrect,
808
808
  z as cellStates,
809
- M as cellValue,
809
+ W as cellValue,
810
810
  ue as evaluate,
811
811
  me as formMessages,
812
812
  O as linesOf,
813
813
  L as messages,
814
- R as normalise,
814
+ D as normalise,
815
815
  ce as scoreOf,
816
816
  oe as withCell
817
817
  };
@@ -1,6 +1,6 @@
1
- import { L as j, a9 as g, P as b, a2 as f, ac as z, ad as O, j as t, a5 as D, a as p, b as h, aa as E, s as W } from "./dom-uYx_3K1r.js";
2
- import { v as k, A as m, e as R, M as T, P, t as A, E as F, L as q, R as G } from "./bitLoaders-DIGwTcpd.js";
3
- const K = ".bitflow-typing{display:flex;flex-direction:column;gap:var(--bitflow-space-xsmall)}.bitflow-typing-passage{margin:0;padding:var(--bitflow-space-xsmall);font-family:var(--bitflow-font-family-mono);font-size:var(--bitflow-font-size-standard);line-height:var(--bitflow-line-height-standard);white-space:pre-wrap;overflow-wrap:anywhere;background:var(--bitflow-color-neutral-100);border-radius:var(--bitflow-radius-standard)}.bitflow-typing-character-pending{color:var(--bitflow-color-text-muted)}.bitflow-typing-character-right{color:var(--bitflow-color-correct)}.bitflow-typing-character-wrong{color:var(--bitflow-color-wrong);background:var(--bitflow-color-wrong-surface);text-decoration:underline}.bitflow-typing-input{width:100%;padding:var(--bitflow-space-xsmall);font-family:var(--bitflow-font-family-mono);font-size:var(--bitflow-font-size-standard);line-height:var(--bitflow-line-height-standard);color:var(--bitflow-color-text);background:var(--bitflow-color-surface);border:var(--bitflow-border-width) solid var(--bitflow-color-border);border-radius:var(--bitflow-radius-standard);resize:vertical}.bitflow-typing-input:focus-visible{outline:none;box-shadow:var(--bitflow-shadow-outline)}.bitflow-typing-input:disabled{-webkit-text-fill-color:var(--bitflow-color-text);opacity:1}.bitflow-typing-touch-notice.bitflow-alert-warning{display:none}@media(pointer:coarse){.bitflow-typing-touch-notice.bitflow-alert-warning{display:flex}}.bitflow-typing-meters{display:flex;flex-wrap:wrap;gap:var(--bitflow-space-small);margin:0;font-size:var(--bitflow-font-size-small);color:var(--bitflow-color-text-muted);font-variant-numeric:tabular-nums}", Z = D(["accuracy", "accuracyAndSpeed"]), $ = j({
1
+ import { P as j, a9 as g, Y as b, a2 as f, ac as z, ad as O, j as t, a5 as D, a as p, b as h, aa as W, s as E } from "./dom-B6NPWBb1.js";
2
+ import { e as k, g as m, P, F as T, M as R, r as A, B as F, U as q, H as G } from "./bitLoaders-7qanePQL.js";
3
+ const K = ".bitflow-typing{display:flex;flex-direction:column;gap:var(--bitflow-space-small)}.bitflow-typing-passage{margin:0;padding:var(--bitflow-space-xsmall);font-family:var(--bitflow-font-family-mono);font-size:var(--bitflow-font-size-standard);line-height:var(--bitflow-line-height-standard);white-space:pre-wrap;overflow-wrap:anywhere;background:var(--bitflow-color-neutral-100);border-radius:var(--bitflow-radius-standard)}.bitflow-typing-character-pending{color:var(--bitflow-color-text-muted)}.bitflow-typing-character-right{color:var(--bitflow-color-correct)}.bitflow-typing-character-wrong{color:var(--bitflow-color-wrong);background:var(--bitflow-color-wrong-surface);text-decoration:underline}.bitflow-typing-input{width:100%;padding:var(--bitflow-space-xsmall);font-family:var(--bitflow-font-family-mono);font-size:var(--bitflow-font-size-standard);line-height:var(--bitflow-line-height-standard);color:var(--bitflow-color-text);background:var(--bitflow-color-surface);border:var(--bitflow-border-width) solid var(--bitflow-color-border);border-radius:var(--bitflow-radius-standard);resize:vertical}.bitflow-typing-input:focus-visible{outline:none;box-shadow:var(--bitflow-shadow-outline)}.bitflow-typing-input:disabled{-webkit-text-fill-color:var(--bitflow-color-text);opacity:1}.bitflow-typing-touch-notice.bitflow-alert-warning{display:none}@media(pointer:coarse){.bitflow-typing-touch-notice.bitflow-alert-warning{display:flex}}.bitflow-typing-meters{display:flex;flex-wrap:wrap;gap:var(--bitflow-space-small);margin:0;font-size:var(--bitflow-font-size-small);color:var(--bitflow-color-text-muted);font-variant-numeric:tabular-nums}", Z = D(["accuracy", "accuracyAndSpeed"]), U = j({
4
4
  instruction: f().default(""),
5
5
  /** The text to type back. */
6
6
  text: f().default(""),
@@ -52,8 +52,8 @@ const K = ".bitflow-typing{display:flex;flex-direction:column;gap:var(--bitflow-
52
52
  }, Y = (e, n) => {
53
53
  const i = Math.max(e.length, n.length);
54
54
  return i === 0 ? 1 : y(e, n) / i;
55
- }, I = (e, n, i) => i <= 0 ? 0 : y(e, n) / 5 / (i / 6e4), M = (e, n) => {
56
- const i = n?.typed ?? "", o = e.timed ? n?.elapsedMs ?? 0 : 0, r = Y(e.text, i), s = e.timed ? I(e.text, i, o) : 0;
55
+ }, $ = (e, n, i) => i <= 0 ? 0 : y(e, n) / 5 / (i / 6e4), M = (e, n) => {
56
+ const i = n?.typed ?? "", o = e.timed ? n?.elapsedMs ?? 0 : 0, r = Y(e.text, i), s = e.timed ? $(e.text, i, o) : 0;
57
57
  return {
58
58
  correct: y(e.text, i),
59
59
  accuracy: r,
@@ -62,10 +62,10 @@ const K = ".bitflow-typing{display:flex;flex-direction:column;gap:var(--bitflow-
62
62
  accurateEnough: i.length > 0 && r >= e.requiredAccuracy,
63
63
  fastEnough: e.timed && s >= e.targetWpm
64
64
  };
65
- }, U = (e, n) => {
65
+ }, B = (e, n) => {
66
66
  const i = M(e, n), o = e.scoring === "accuracyAndSpeed" ? 2 : 1;
67
67
  return { earned: (i.accurateEnough ? 1 : 0) + (e.scoring === "accuracyAndSpeed" && i.fastEnough ? 1 : 0), possible: o };
68
- }, V = ({
68
+ }, I = ({
69
69
  data: e,
70
70
  answer: n
71
71
  }) => {
@@ -78,7 +78,7 @@ const K = ".bitflow-typing{display:flex;flex-direction:column;gap:var(--bitflow-
78
78
  allowRetry: !1,
79
79
  detail: { optedOut: !0 }
80
80
  };
81
- const i = M(e, n), o = U(e, n);
81
+ const i = M(e, n), o = B(e, n);
82
82
  return {
83
83
  state: o.earned === o.possible ? "correct" : "wrong",
84
84
  score: o,
@@ -129,7 +129,7 @@ const K = ".bitflow-typing{display:flex;flex-direction:column;gap:var(--bitflow-
129
129
  stoodDown: "Abgemeldet. Diese Aufgabe wird nicht bewertet.",
130
130
  stoodDownNotice: "Du hast dich von dieser Aufgabe abgemeldet, sie wird nicht bewertet."
131
131
  }
132
- }, B = {
132
+ }, V = {
133
133
  en: {
134
134
  instructionLabel: "Instruction",
135
135
  instructionHint: "Shown above the passage. Markdown is allowed.",
@@ -275,7 +275,7 @@ const K = ".bitflow-typing{display:flex;flex-direction:column;gap:var(--bitflow-
275
275
  onChange: i,
276
276
  errors: o
277
277
  }) => {
278
- const r = (a, l) => h(B, a, n, l), s = (a) => i({ ...e, ...a });
278
+ const r = (a, l) => h(V, a, n, l), s = (a) => i({ ...e, ...a });
279
279
  return /* @__PURE__ */ t.jsxs("div", { className: "bitflow-stack", children: [
280
280
  /* @__PURE__ */ t.jsx(
281
281
  k,
@@ -298,7 +298,7 @@ const K = ".bitflow-typing{display:flex;flex-direction:column;gap:var(--bitflow-
298
298
  onChange: (a) => s({ text: a })
299
299
  }
300
300
  ),
301
- /* @__PURE__ */ t.jsxs(R, { summary: r("advanced"), children: [
301
+ /* @__PURE__ */ t.jsxs(P, { summary: r("advanced"), children: [
302
302
  /* @__PURE__ */ t.jsx(
303
303
  T,
304
304
  {
@@ -317,7 +317,7 @@ const K = ".bitflow-typing{display:flex;flex-direction:column;gap:var(--bitflow-
317
317
  }
318
318
  ),
319
319
  /* @__PURE__ */ t.jsx(
320
- P,
320
+ R,
321
321
  {
322
322
  label: r("scoringLabel"),
323
323
  hint: r("scoringHint"),
@@ -388,11 +388,11 @@ const K = ".bitflow-typing{display:flex;flex-direction:column;gap:var(--bitflow-
388
388
  ] })
389
389
  ] });
390
390
  }, N = "task-keyboard-speed";
391
- E({
391
+ W({
392
392
  type: N,
393
393
  kind: "task",
394
- schema: $,
395
- evaluate: V,
394
+ schema: U,
395
+ evaluate: I,
396
396
  Task: Q,
397
397
  Form: X,
398
398
  info: (e) => ({
@@ -411,10 +411,10 @@ E({
411
411
  })
412
412
  });
413
413
  G(N);
414
- W("bitflow-styles-task-keyboard-speed", K);
414
+ E("bitflow-styles-task-keyboard-speed", K);
415
415
  export {
416
416
  te as AnswerSchema,
417
- $ as DataSchema,
417
+ U as DataSchema,
418
418
  X as Form,
419
419
  Z as ScoringSchema,
420
420
  N as TYPE,
@@ -422,10 +422,10 @@ export {
422
422
  J as Typist,
423
423
  Y as accuracyOf,
424
424
  y as correctCharacters,
425
- V as evaluate,
426
- B as formMessages,
425
+ I as evaluate,
426
+ V as formMessages,
427
427
  M as measure,
428
428
  w as messages,
429
- U as scoreOf,
430
- I as wordsPerMinute
429
+ B as scoreOf,
430
+ $ as wordsPerMinute
431
431
  };