@pie-element/mc-populated-blank 0.2.13 → 0.3.0-next.10

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 (67) hide show
  1. package/README.md +8 -5
  2. package/author.js +2 -0
  3. package/configure.js +2 -0
  4. package/dist/author/defaults.d.ts +74 -0
  5. package/dist/author/index.d.ts +0 -1
  6. package/dist/author/index.js +1732 -1553
  7. package/dist/author/index.js.map +1 -1
  8. package/dist/browser/author/index.js +41 -0
  9. package/dist/browser/author/index.js.map +1 -0
  10. package/dist/browser/client-6I83eQqA.js +2396 -0
  11. package/dist/browser/client-6I83eQqA.js.map +1 -0
  12. package/dist/browser/controller/index.js +209 -0
  13. package/dist/browser/controller/index.js.map +1 -0
  14. package/dist/browser/delivery/index.js +1131 -0
  15. package/dist/browser/delivery/index.js.map +1 -0
  16. package/dist/browser/i18n-CQZqUmjk.js +1542 -0
  17. package/dist/browser/i18n-CQZqUmjk.js.map +1 -0
  18. package/dist/browser/layoutLimits-Bp17YP2V.js +42 -0
  19. package/dist/browser/layoutLimits-Bp17YP2V.js.map +1 -0
  20. package/dist/browser/print/index.js +151 -0
  21. package/dist/browser/print/index.js.map +1 -0
  22. package/dist/controller/defaults.d.ts +8 -30
  23. package/dist/controller/index.d.ts +79 -63
  24. package/dist/controller/index.js +108 -85
  25. package/dist/controller/index.js.map +1 -1
  26. package/dist/delivery/computeAudioMode.d.ts +0 -1
  27. package/dist/delivery/computeChoiceCorrectness.d.ts +0 -1
  28. package/dist/delivery/computeDisplayState.d.ts +7 -8
  29. package/dist/delivery/computeLayoutProfile.d.ts +0 -1
  30. package/dist/delivery/computeLayoutStyle.d.ts +0 -2
  31. package/dist/delivery/i18n.d.ts +8 -0
  32. package/dist/delivery/index.d.ts +22 -1
  33. package/dist/delivery/index.js +5742 -3222
  34. package/dist/delivery/index.js.map +1 -1
  35. package/dist/delivery/variant-css-map.d.ts +15 -2
  36. package/dist/index.d.ts +0 -1
  37. package/dist/index.iife.d.ts +0 -156
  38. package/dist/index.iife.js +139 -38
  39. package/dist/index.js +5742 -3222
  40. package/dist/index.js.map +1 -1
  41. package/dist/print/index.d.ts +4 -1
  42. package/dist/print/index.js +5418 -2879
  43. package/dist/print/index.js.map +1 -1
  44. package/dist/runtime-support.d.ts +12 -0
  45. package/dist/runtime-support.js +14 -0
  46. package/dist/runtime-support.js.map +1 -0
  47. package/dist/shared/layoutLimits.d.ts +1 -2
  48. package/dist/shared/types.d.ts +20 -19
  49. package/module/print.js +3883 -0
  50. package/module/print.js.map +1 -0
  51. package/package.json +42 -13
  52. package/print.js +2 -0
  53. package/dist/author/index.d.ts.map +0 -1
  54. package/dist/controller/defaults.d.ts.map +0 -1
  55. package/dist/controller/index.d.ts.map +0 -1
  56. package/dist/delivery/computeAudioMode.d.ts.map +0 -1
  57. package/dist/delivery/computeChoiceCorrectness.d.ts.map +0 -1
  58. package/dist/delivery/computeDisplayState.d.ts.map +0 -1
  59. package/dist/delivery/computeLayoutProfile.d.ts.map +0 -1
  60. package/dist/delivery/computeLayoutStyle.d.ts.map +0 -1
  61. package/dist/delivery/index.d.ts.map +0 -1
  62. package/dist/delivery/variant-css-map.d.ts.map +0 -1
  63. package/dist/index.d.ts.map +0 -1
  64. package/dist/index.iife.d.ts.map +0 -1
  65. package/dist/print/index.d.ts.map +0 -1
  66. package/dist/shared/layoutLimits.d.ts.map +0 -1
  67. package/dist/shared/types.d.ts.map +0 -1
@@ -0,0 +1,1131 @@
1
+ import { A as e, C as t, D as n, E as r, F as i, I as a, L as o, M as s, N as c, O as l, P as u, S as d, T as f, _ as p, a as m, c as h, d as g, f as _, g as v, h as y, i as b, j as x, k as S, l as C, m as w, n as T, o as E, r as D, s as O, t as k, u as A, v as j, w as M, x as N, y as P } from "../client-6I83eQqA.js";
2
+ import { n as F, t as I } from "../i18n-CQZqUmjk.js";
3
+ import { t as L } from "../layoutLimits-Bp17YP2V.js";
4
+ //#region ../../shared/player-events/dist/index.js
5
+ var R = class e extends CustomEvent {
6
+ static {
7
+ this.TYPE = "model-set";
8
+ }
9
+ constructor(t, n, r) {
10
+ super(e.TYPE, {
11
+ bubbles: !0,
12
+ composed: !0,
13
+ detail: {
14
+ complete: n,
15
+ component: t,
16
+ hasModel: r
17
+ }
18
+ }), this.component = t, this.complete = n;
19
+ }
20
+ }, z = class e extends CustomEvent {
21
+ static {
22
+ this.TYPE = "session-changed";
23
+ }
24
+ constructor(t, n) {
25
+ super(e.TYPE, {
26
+ bubbles: !0,
27
+ composed: !0,
28
+ detail: {
29
+ complete: n,
30
+ component: t
31
+ }
32
+ }), this.component = t, this.complete = n;
33
+ }
34
+ }, B = (e) => {
35
+ let t = e;
36
+ return t ? typeof t.onSessionChange == "function" || typeof t.onAudioStarted == "function" || typeof t.onAudioEnded == "function" : !1;
37
+ };
38
+ function V(e) {
39
+ if (e.parentElement) return e.parentElement;
40
+ let t = e.getRootNode();
41
+ return t instanceof ShadowRoot ? t.host : null;
42
+ }
43
+ function ee(e, t = {}) {
44
+ let n = t.hostPredicate ?? B, r = e;
45
+ for (; r;) {
46
+ if (n(r)) return r;
47
+ r = V(r);
48
+ }
49
+ return null;
50
+ }
51
+ function H(e) {
52
+ return !!e && typeof e == "object" && !Array.isArray(e);
53
+ }
54
+ function U(e, t) {
55
+ if (e === t) return e;
56
+ if (!H(e) || !H(t) || Object.isFrozen(e) || !Object.isExtensible(e)) return t;
57
+ try {
58
+ for (let n of Object.keys(e)) n in t || delete e[n];
59
+ Object.assign(e, t);
60
+ } catch {
61
+ return t;
62
+ }
63
+ return e;
64
+ }
65
+ var W = {}, G = /* @__PURE__ */ new WeakSet();
66
+ function te(e) {
67
+ let t = e ?? W;
68
+ if (G.has(t)) return;
69
+ G.add(t);
70
+ let n = e ? `above <${e.tagName.toLowerCase()}>` : "for an update with no source element";
71
+ console.warn(`[session-bridge] no delivery host ${n}; the session change was not forwarded to the player`);
72
+ }
73
+ function ne({ sourceEl: e, complete: t, session: n }) {
74
+ let r = ee(e);
75
+ if (!r) return te(e), null;
76
+ if (typeof r.onSessionChange == "function") return r.onSessionChange(n), r;
77
+ let i = U(r.session, n);
78
+ return i !== r.session && (r.session = i), r.dispatchEvent(new z(r.tagName.toLowerCase(), t)), r;
79
+ }
80
+ //#endregion
81
+ //#region src/delivery/computeAudioMode.ts
82
+ function re(e) {
83
+ return e.hasAudio ? e.audioUrl ? e.useFeatureButtonAudio ? "feature-button" : "controls" : "error" : "none";
84
+ }
85
+ //#endregion
86
+ //#region src/delivery/AudioPlayer.svelte
87
+ var ie = j("<audio class=\"sr-only pie-audio-player svelte-ypdwb3\" preload=\"metadata\" aria-hidden=\"true\" tabindex=\"-1\"></audio> <button class=\"listen-button pie-listen-button rli-feature-audio svelte-ypdwb3\" type=\"button\"><img/> <img/></button>", 1), ae = j("<button class=\"autoplay-enable pie-audio-autoplay-enable svelte-ypdwb3\" type=\"button\"> </button>"), oe = j("<audio controls=\"\" class=\"audio-controls pie-audio-player svelte-ypdwb3\" preload=\"metadata\"><track kind=\"captions\"/></audio> <!>", 1), K = j("<p class=\"audio-error pie-audio-error svelte-ypdwb3\" role=\"alert\"> </p>"), se = j("<div class=\"audio-container pie-audio-container svelte-ypdwb3\"><!></div>"), ce = {
88
+ hash: "svelte-ypdwb3",
89
+ code: ".audio-container.svelte-ypdwb3 {margin-bottom:1rem;}.audio-controls.svelte-ypdwb3 {display:block;width:100%;max-width:28rem;}.autoplay-enable.svelte-ypdwb3 {margin-top:0.5rem;padding:0;border:0;background:transparent;font:inherit;font-size:0.875rem;line-height:calc(1.25 / 0.875);color:inherit;text-decoration-line:underline;}.audio-error.svelte-ypdwb3 {margin:0;font-size:0.875rem;line-height:calc(1.25 / 0.875);color:var(--pie-incorrect-icon, #c10007);}.listen-button.svelte-ypdwb3 {width:var(--mpb-listen-button-size, 128px);height:var(--mpb-listen-button-size, 128px);border:0;padding:0;background-color:transparent;cursor:pointer;z-index:1;}.listen-button.svelte-ypdwb3:hover {background-color:#e2f1fe;}.listen-feature-icon.svelte-ypdwb3 {width:var(--mpb-listen-button-size, 128px);height:var(--mpb-listen-button-size, 128px);object-fit:contain;display:none;}.listen-feature-icon.listen-active.svelte-ypdwb3 {display:block;}.sr-only.svelte-ypdwb3 {position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0, 0, 0, 0);white-space:nowrap;border:0;}"
90
+ };
91
+ function le(d, h) {
92
+ a(h, !0), A(d, ce);
93
+ let g = {
94
+ IDLE: "idle",
95
+ PLAYING: "playing",
96
+ BLOCKED: "blocked",
97
+ PAUSED: "paused"
98
+ }, _ = T(h, "hasAudio", 7, !1), b = T(h, "audioUrl", 7), E = T(h, "useFeatureButtonAudio", 7, !1), O = T(h, "autoplayEnabled", 7, !1), k = T(h, "featureAudioSkin", 7), j = T(h, "language", 7), N = T(h, "onaudiostarted", 7), P = T(h, "onaudioended", 7), F = s(null), L = s(null), R = s(null), z = s(e(g.IDLE)), B = u(() => re({
99
+ hasAudio: _(),
100
+ audioUrl: b(),
101
+ useFeatureButtonAudio: E()
102
+ })), V = u(() => t(z) === g.PLAYING), ee = u(() => t(z) === g.BLOCKED), H = u(() => t(B) === "error" ? I("audioResourceUnavailable", j()) : "");
103
+ f(() => {
104
+ b(), x(z, g.IDLE, !0);
105
+ });
106
+ function U() {
107
+ t(B) !== "none" && t(B) !== "error" && t(F) && t(F).play().catch(() => {});
108
+ }
109
+ function W() {
110
+ t(B) !== "none" && t(B) !== "error" && t(F) && t(F).play().finally(() => {
111
+ t(z) === g.BLOCKED && x(z, g.PAUSED, !0);
112
+ });
113
+ }
114
+ function G(e, t, n) {
115
+ f(() => {
116
+ let r = e();
117
+ if (r) return r.addEventListener(t, n), () => r.removeEventListener(t, n);
118
+ });
119
+ }
120
+ G(() => t(F), "playing", () => {
121
+ x(z, g.PLAYING, !0), N()?.();
122
+ }), G(() => t(F), "ended", () => {
123
+ x(z, g.PAUSED, !0), P()?.();
124
+ }), G(() => t(L), "click", () => U()), G(() => t(R), "click", () => W()), f(() => {
125
+ !O() || t(B) === "none" || t(B) === "error" || t(z) === g.IDLE && t(F) && b() && (x(z, g.PAUSED, !0), t(F).play().catch(() => {
126
+ x(z, g.BLOCKED, !0);
127
+ }));
128
+ });
129
+ var te = {
130
+ get hasAudio() {
131
+ return _();
132
+ },
133
+ set hasAudio(e = !1) {
134
+ _(e), c();
135
+ },
136
+ get audioUrl() {
137
+ return b();
138
+ },
139
+ set audioUrl(e) {
140
+ b(e), c();
141
+ },
142
+ get useFeatureButtonAudio() {
143
+ return E();
144
+ },
145
+ set useFeatureButtonAudio(e = !1) {
146
+ E(e), c();
147
+ },
148
+ get autoplayEnabled() {
149
+ return O();
150
+ },
151
+ set autoplayEnabled(e = !1) {
152
+ O(e), c();
153
+ },
154
+ get featureAudioSkin() {
155
+ return k();
156
+ },
157
+ set featureAudioSkin(e) {
158
+ k(e), c();
159
+ },
160
+ get language() {
161
+ return j();
162
+ },
163
+ set language(e) {
164
+ j(e), c();
165
+ },
166
+ get onaudiostarted() {
167
+ return N();
168
+ },
169
+ set onaudiostarted(e) {
170
+ N(e), c();
171
+ },
172
+ get onaudioended() {
173
+ return P();
174
+ },
175
+ set onaudioended(e) {
176
+ P(e), c();
177
+ }
178
+ }, ne = p(), le = n(ne), q = (e) => {
179
+ var i = se(), a = r(i), s = (e) => {
180
+ var i = ie(), a = n(i);
181
+ D(a, (e) => x(F, e), () => t(F));
182
+ var s = S(a, 2), c = r(s), l = S(c, 2);
183
+ o(s), D(s, (e) => x(L, e), () => t(L)), M((e, n, r) => {
184
+ m(a, "src", b()), m(s, "aria-label", e), C(c, 1, `listen-feature-icon pie-listen-icon rli-feature-listen ${t(V) ? "" : "listen-active"}`, "svelte-ypdwb3"), m(c, "src", k().silentUrl), m(c, "alt", n), C(l, 1, `listen-feature-icon pie-listen-icon rli-feature-listen ${t(V) ? "listen-active" : ""}`, "svelte-ypdwb3"), m(l, "src", k().playingUrl), m(l, "alt", r);
185
+ }, [
186
+ () => I("listen", j()),
187
+ () => I("listenSilentAlt", j()),
188
+ () => I("listenPlayingAlt", j())
189
+ ]), v(e, i);
190
+ }, c = (e) => {
191
+ var r = oe(), i = n(r);
192
+ D(i, (e) => x(F, e), () => t(F));
193
+ var a = S(i, 2), o = (e) => {
194
+ var n = ae(), r = l(n, !0);
195
+ D(n, (e) => x(R, e), () => t(R)), M((e) => y(r, e), [() => I("clickToEnableAutoplay", j())]), v(e, n);
196
+ };
197
+ w(a, (e) => {
198
+ t(ee) && e(o);
199
+ }), M(() => m(i, "src", b())), v(e, r);
200
+ }, u = (e) => {
201
+ var n = K(), r = l(n, !0);
202
+ M(() => y(r, t(H))), v(e, n);
203
+ };
204
+ w(a, (e) => {
205
+ t(B) === "feature-button" ? e(s) : t(B) === "controls" ? e(c, 1) : t(B) === "error" && e(u, 2);
206
+ }), o(i), v(e, i);
207
+ };
208
+ return w(le, (e) => {
209
+ t(B) !== "none" && e(q);
210
+ }), v(d, ne), i(te);
211
+ }
212
+ k(le, {
213
+ hasAudio: {},
214
+ audioUrl: {},
215
+ useFeatureButtonAudio: {},
216
+ autoplayEnabled: {},
217
+ featureAudioSkin: {},
218
+ language: {},
219
+ onaudiostarted: {},
220
+ onaudioended: {}
221
+ }, [], [], { mode: "open" });
222
+ //#endregion
223
+ //#region src/delivery/ClozeMarker.svelte
224
+ var q = j("<img class=\"cloze-marker-image pie-blank-image svelte-d9l5tb\" style=\"max-width:var(--mpb-choice-image-max-width, 9.375rem);max-height:var(--mpb-choice-image-max-height, 9.375rem);\"/>"), ue = j("<span class=\"cloze-marker-value pie-blank-value svelte-d9l5tb\"></span>"), de = j("<span class=\"cloze-marker-empty svelte-d9l5tb\"><span aria-hidden=\"true\">&nbsp;</span> <span class=\"sr-only svelte-d9l5tb\"> </span></span>"), fe = j("<span role=\"status\" aria-live=\"polite\" aria-atomic=\"true\"><!></span>"), pe = {
225
+ hash: "svelte-d9l5tb",
226
+ code: "\n /* The underline width comes from the inline style (layoutLimits); the colour\n follows the text. */.cloze-marker.svelte-d9l5tb {display:inline-flex;align-items:center;justify-content:center;text-align:center;vertical-align:baseline;padding-inline:0.5rem;border-bottom:2px solid currentColor;}.cloze-marker.svelte-d9l5tb:focus-within {outline:2px solid var(--mpb-focus-ring, #1565c0);outline-offset:2px;}.cloze-marker-standalone.svelte-d9l5tb {width:var(--mpb-blank-standalone-width, 7rem);}.cloze-marker-image.svelte-d9l5tb {object-fit:contain;}.cloze-marker-empty.svelte-d9l5tb {display:inline-block;min-width:4ch;}.cloze-marker-value.svelte-d9l5tb {width:100%;display:inline-flex;align-items:center;justify-content:center;text-align:center;}.cloze-marker-value.svelte-d9l5tb p {margin:0;}\n\n /* Same 150x150 content-element constraint as ChoiceRow.svelte's .choice-html\n img — the selected choice's raw labelHtml can carry an embedded <img> here\n too, regardless of customType. See CONTOOL-3159. */.cloze-marker-value.svelte-d9l5tb img {width:150px;height:150px;}.sr-only.svelte-d9l5tb {position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0, 0, 0, 0);white-space:nowrap;border:0;}"
227
+ };
228
+ function me(e, t) {
229
+ a(t, !0), A(e, pe);
230
+ let n = T(t, "choiceMode", 7, "text"), s = T(t, "displayChoice", 7, void 0), u = T(t, "displayChoiceLabelHtml", 7, ""), d = T(t, "isStandalone", 7, !1), f = T(t, "blankWidth", 7), p = T(t, "blankBorderWidth", 7), _ = T(t, "ariaLabel", 7), b = T(t, "language", 7);
231
+ var x = {
232
+ get choiceMode() {
233
+ return n();
234
+ },
235
+ set choiceMode(e = "text") {
236
+ n(e), c();
237
+ },
238
+ get displayChoice() {
239
+ return s();
240
+ },
241
+ set displayChoice(e = void 0) {
242
+ s(e), c();
243
+ },
244
+ get displayChoiceLabelHtml() {
245
+ return u();
246
+ },
247
+ set displayChoiceLabelHtml(e = "") {
248
+ u(e), c();
249
+ },
250
+ get isStandalone() {
251
+ return d();
252
+ },
253
+ set isStandalone(e = !1) {
254
+ d(e), c();
255
+ },
256
+ get blankWidth() {
257
+ return f();
258
+ },
259
+ set blankWidth(e) {
260
+ f(e), c();
261
+ },
262
+ get blankBorderWidth() {
263
+ return p();
264
+ },
265
+ set blankBorderWidth(e) {
266
+ p(e), c();
267
+ },
268
+ get ariaLabel() {
269
+ return _();
270
+ },
271
+ set ariaLabel(e) {
272
+ _(e), c();
273
+ },
274
+ get language() {
275
+ return b();
276
+ },
277
+ set language(e) {
278
+ b(e), c();
279
+ }
280
+ }, E = fe(), D = r(E), O = (e) => {
281
+ var t = q();
282
+ M((e) => {
283
+ m(t, "src", s().imageUrl), m(t, "alt", e);
284
+ }, [() => s().imageAlt || I("selectedAnswerImage", b())]), v(e, t);
285
+ }, k = (e) => {
286
+ var t = ue();
287
+ g(t, u, !0), o(t), v(e, t);
288
+ }, j = (e) => {
289
+ var t = de(), n = l(S(r(t), 2), !0);
290
+ o(t), M((e) => y(n, e), [() => I("emptyBlank", b())]), v(e, t);
291
+ };
292
+ return w(D, (e) => {
293
+ n() === "image" && s()?.imageUrl ? e(O) : u() ? e(k, 1) : e(j, -1);
294
+ }), o(E), M(() => {
295
+ C(E, 1, `cloze-marker pie-blank-slot ${d() ? "cloze-marker-standalone pie-blank-slot-standalone" : ""}`, "svelte-d9l5tb"), h(E, `width:${f()};border-bottom-width:${p()};`), m(E, "aria-label", _());
296
+ }), v(e, E), i(x);
297
+ }
298
+ k(me, {
299
+ choiceMode: {},
300
+ displayChoice: {},
301
+ displayChoiceLabelHtml: {},
302
+ isStandalone: {},
303
+ blankWidth: {},
304
+ blankBorderWidth: {},
305
+ ariaLabel: {},
306
+ language: {}
307
+ }, [], [], { mode: "open" });
308
+ //#endregion
309
+ //#region src/delivery/ChoiceRow.svelte
310
+ var he = j("<img class=\"choice-image pie-choice-image svelte-8xu1pt\" style=\"max-width:var(--mpb-choice-image-max-width, 9.375rem);max-height:var(--mpb-choice-image-max-height, 9.375rem);\"/>"), J = j("<span class=\"choice-html pie-choice-label svelte-8xu1pt\"></span>"), ge = j("<label class=\"choice-tile pie-choice-tile svelte-8xu1pt\"><span class=\"choice-tile-content pie-choice-tile-content svelte-8xu1pt\"><!></span> <input type=\"radio\" class=\"choice-radio-bottom pie-choice-radio pie-choice-radio-bottom svelte-8xu1pt\"/></label>"), Y = j("<img class=\"choice-image pie-choice-image svelte-8xu1pt\" style=\"max-height:var(--mpb-choice-image-max-height, 5rem);\"/>"), _e = j("<input type=\"radio\" class=\"choice-radio-inline pie-choice-radio pie-choice-radio-inline svelte-8xu1pt\"/> <label class=\"choice-label-wrap pie-choice-label-wrap svelte-8xu1pt\"><!></label>", 1), ve = j("<span aria-hidden=\"true\"> </span>"), ye = j("<div style=\"gap:var(--mpb-choice-row-gap, 0.5rem);\"><!> <!></div>"), be = {
311
+ hash: "svelte-8xu1pt",
312
+ code: ".choice-row.svelte-8xu1pt {display:flex;align-items:flex-start;}.choice-row-horizontal.svelte-8xu1pt {flex-direction:column;align-items:center;width:min(var(--mpb-choice-width-px, 170px), var(--mpb-choice-width-vw, 30vw));min-height:var(--mpb-choice-tile-min-height, 11rem);gap:0;}.choice-tile.svelte-8xu1pt {display:flex;flex-direction:column;justify-content:space-between;align-items:center;width:100%;min-height:var(--mpb-choice-tile-min-height, 11rem);padding:0.8rem 0.65rem 0.5rem;border-radius:8px;background:transparent;transition:background-color 120ms ease-in-out;cursor:pointer;text-align:center;}.choice-tile-content.svelte-8xu1pt {width:100%;display:flex;align-items:center;justify-content:center;min-height:var(--mpb-choice-content-min-height, 7.5rem);}.choice-image.svelte-8xu1pt {display:block;object-fit:contain;}.choice-label-wrap.svelte-8xu1pt {flex:1 1 0%;cursor:pointer;}.choice-row-horizontal.svelte-8xu1pt:hover .choice-tile:where(.svelte-8xu1pt) {background:var(--mpb-choice-hover-bg, var(--pie-background-dark, #ecedf1));}.pie-choice-horizontal.svelte-8xu1pt:not(.is-selected):not(:hover) .pie-choice-tile:where(.svelte-8xu1pt) {background:transparent;}.choice-row-horizontal.is-selected.svelte-8xu1pt .choice-tile:where(.svelte-8xu1pt) {background:var(--mpb-choice-selected-bg, var(--pie-secondary-background, rgba(241, 241, 241, 1)));}.choice-row-horizontal.is-selected.svelte-8xu1pt:hover .choice-tile:where(.svelte-8xu1pt) {background:var(--mpb-choice-selected-bg, var(--pie-secondary-background, rgba(241, 241, 241, 1)));}.pie-choice.svelte-8xu1pt:not(.pie-choice-horizontal):hover .pie-choice-label-wrap:where(.svelte-8xu1pt) {background:var(--pie-background-dark, #ecedf1);}.pie-choice.svelte-8xu1pt:not(.pie-choice-horizontal):not(.is-selected):not(:hover) .pie-choice-label-wrap:where(.svelte-8xu1pt) {background:transparent;}.pie-choice:not(.pie-choice-horizontal).is-selected.svelte-8xu1pt .pie-choice-label-wrap:where(.svelte-8xu1pt) {background:var(--pie-secondary-background, rgba(241, 241, 241, 1));border-radius:6px;}.pie-choice:not(.pie-choice-horizontal).is-selected.svelte-8xu1pt:hover .pie-choice-label-wrap:where(.svelte-8xu1pt) {background:var(--pie-secondary-background, rgba(241, 241, 241, 1));}.pie-choice.choice-correct.svelte-8xu1pt {border-left:3px solid var(--pie-correct-tertiary, #0ea449);}.pie-choice.choice-incorrect.svelte-8xu1pt {border-left:3px solid var(--pie-incorrect-icon, #bf0d00);}.pie-choice-horizontal.choice-correct.svelte-8xu1pt .choice-tile:where(.svelte-8xu1pt) {background:var(--pie-correct-secondary, #e8f5e9);}.pie-choice-horizontal.choice-incorrect.svelte-8xu1pt .choice-tile:where(.svelte-8xu1pt) {background:var(--pie-incorrect-secondary, #ffebee);}.pie-choice-feedback-badge.svelte-8xu1pt {margin-left:auto;display:inline-flex;align-items:center;justify-content:center;width:1.1rem;height:1.1rem;border-radius:9999px;font-size:0.72rem;line-height:1;font-weight:700;color:var(--pie-white, #ffffff);}.pie-choice-feedback-correct.svelte-8xu1pt {background:var(--pie-correct-icon, #087d38);}.pie-choice-feedback-incorrect.svelte-8xu1pt {background:var(--pie-incorrect-icon, #bf0d00);}.choice-row-horizontal.svelte-8xu1pt p {margin:0;text-align:center;}.choice-html.svelte-8xu1pt p {margin:0;}.choice-html.svelte-8xu1pt {width:100%;display:inline-flex;align-items:center;justify-content:center;text-align:center;}\n\n /* Choices carrying raw <img> markup in labelHtml (rather than the dedicated\n imageUrl/imageAlt fields) render unconstrained at their authored size\n otherwise — 3rd-party/CQT-sourced content is typically authored well above\n the platform's 150x150 content-element spec. Applies regardless of\n customType, unlike the r1-CQT-specific cqt-css overlays. See CONTOOL-3159. */.choice-html.svelte-8xu1pt img {width:150px;height:150px;}\n\n /* Only the top margin is spaced; the browser's own radio side margins would\n otherwise offset the control from its label (the demo app's preflight zeroed them). */.choice-radio-bottom.svelte-8xu1pt {margin:var(--mpb-horizontal-choice-radio-top-margin, 0.5rem) 0 0;padding:var(--mpb-choice-radio-padding, 0px);}.choice-radio-inline.svelte-8xu1pt {margin:var(--mpb-horizontal-choice-radio-top-margin, 0.5rem) 0 0;}"
313
+ };
314
+ function xe(e, t) {
315
+ a(t, !0), A(e, be);
316
+ let s = T(t, "choice", 7), u = T(t, "choiceMode", 7, "text"), d = T(t, "isHorizontal", 7, !1), f = T(t, "isSelected", 7, !1), p = T(t, "isDisabled", 7, !1), h = T(t, "correctness", 7, void 0), _ = T(t, "isEvaluateMode", 7, !1), x = T(t, "instanceId", 7), D = T(t, "radioGroupName", 7), k = T(t, "language", 7);
317
+ var j = {
318
+ get choice() {
319
+ return s();
320
+ },
321
+ set choice(e) {
322
+ s(e), c();
323
+ },
324
+ get choiceMode() {
325
+ return u();
326
+ },
327
+ set choiceMode(e = "text") {
328
+ u(e), c();
329
+ },
330
+ get isHorizontal() {
331
+ return d();
332
+ },
333
+ set isHorizontal(e = !1) {
334
+ d(e), c();
335
+ },
336
+ get isSelected() {
337
+ return f();
338
+ },
339
+ set isSelected(e = !1) {
340
+ f(e), c();
341
+ },
342
+ get isDisabled() {
343
+ return p();
344
+ },
345
+ set isDisabled(e = !1) {
346
+ p(e), c();
347
+ },
348
+ get correctness() {
349
+ return h();
350
+ },
351
+ set correctness(e = void 0) {
352
+ h(e), c();
353
+ },
354
+ get isEvaluateMode() {
355
+ return _();
356
+ },
357
+ set isEvaluateMode(e = !1) {
358
+ _(e), c();
359
+ },
360
+ get instanceId() {
361
+ return x();
362
+ },
363
+ set instanceId(e) {
364
+ x(e), c();
365
+ },
366
+ get radioGroupName() {
367
+ return D();
368
+ },
369
+ set radioGroupName(e) {
370
+ D(e), c();
371
+ },
372
+ get language() {
373
+ return k();
374
+ },
375
+ set language(e) {
376
+ k(e), c();
377
+ }
378
+ }, N = ye(), P = r(N), F = (e) => {
379
+ var t = ge(), n = r(t), i = r(n), a = (e) => {
380
+ var t = he();
381
+ M((e) => {
382
+ m(t, "src", s().imageUrl), m(t, "alt", e);
383
+ }, [() => s().imageAlt || I("choiceImage", k(), { id: s().id })]), v(e, t);
384
+ }, c = (e) => {
385
+ var t = J();
386
+ g(t, () => s().labelHtml || "", !0), o(t), v(e, t);
387
+ };
388
+ w(i, (e) => {
389
+ u() === "image" && s().imageUrl ? e(a) : e(c, -1);
390
+ }), o(n);
391
+ var l = S(n, 2);
392
+ b(l), o(t), M(() => {
393
+ m(t, "for", `${x()}-opt-${s().id}`), m(l, "name", D()), m(l, "id", `${x()}-opt-${s().id}`), O(l, s().id), E(l, f()), l.disabled = p();
394
+ }), v(e, t);
395
+ }, L = (e) => {
396
+ var t = _e(), i = n(t);
397
+ b(i);
398
+ var a = S(i, 2), c = r(a), l = (e) => {
399
+ var t = Y();
400
+ M((e) => {
401
+ m(t, "src", s().imageUrl), m(t, "alt", e);
402
+ }, [() => s().imageAlt || I("choiceImage", k(), { id: s().id })]), v(e, t);
403
+ }, d = (e) => {
404
+ var t = J();
405
+ g(t, () => s().labelHtml || "", !0), o(t), v(e, t);
406
+ };
407
+ w(c, (e) => {
408
+ u() === "image" && s().imageUrl ? e(l) : e(d, -1);
409
+ }), o(a), M(() => {
410
+ m(i, "name", D()), m(i, "id", `${x()}-opt-${s().id}`), O(i, s().id), E(i, f()), i.disabled = p(), m(a, "for", `${x()}-opt-${s().id}`);
411
+ }), v(e, t);
412
+ };
413
+ w(P, (e) => {
414
+ d() ? e(F) : e(L, -1);
415
+ });
416
+ var R = S(P, 2), z = (e) => {
417
+ var t = ve(), n = l(t, !0);
418
+ M(() => {
419
+ C(t, 1, `pie-choice-feedback-badge ${h() === "correct" ? "pie-choice-feedback-correct" : "pie-choice-feedback-incorrect"}`, "svelte-8xu1pt"), y(n, h() === "correct" ? "✓" : "✕");
420
+ }), v(e, t);
421
+ };
422
+ return w(R, (e) => {
423
+ _() && h() && e(z);
424
+ }), o(N), M(() => C(N, 1, `choice-row pie-choice ${d() ? "choice-row-horizontal pie-choice-horizontal" : ""} ${f() ? "is-selected pie-choice-selected" : ""} ${h() ? `choice-${h()} pie-choice-${h()}` : ""}`, "svelte-8xu1pt")), v(e, N), i(j);
425
+ }
426
+ k(xe, {
427
+ choice: {},
428
+ choiceMode: {},
429
+ isHorizontal: {},
430
+ isSelected: {},
431
+ isDisabled: {},
432
+ correctness: {},
433
+ isEvaluateMode: {},
434
+ instanceId: {},
435
+ radioGroupName: {},
436
+ language: {}
437
+ }, [], [], { mode: "open" });
438
+ //#endregion
439
+ //#region src/delivery/TeacherInstructions.svelte
440
+ var Se = j("<div class=\"teacher-instructions pie-teacher-instructions svelte-1jhejbv\"><button type=\"button\" class=\"teacher-instructions-toggle pie-teacher-instructions-toggle svelte-1jhejbv\"> </button> <div class=\"teacher-instructions-content pie-teacher-instructions-content svelte-1jhejbv\"></div></div>"), Ce = {
441
+ hash: "svelte-1jhejbv",
442
+ code: ".teacher-instructions.svelte-1jhejbv {margin-bottom:1rem;}.teacher-instructions-toggle.svelte-1jhejbv {padding:0;border:0;border-bottom:1px dotted currentColor;background:transparent;font:inherit;color:var(--pie-primary, #3f51b5);cursor:pointer;}.teacher-instructions-toggle.svelte-1jhejbv:focus-visible {outline:2px solid var(--mpb-focus-ring, var(--pie-focus-outline, #1565c0));outline-offset:2px;}.teacher-instructions-content.svelte-1jhejbv {padding-top:1rem;}"
443
+ };
444
+ function we(e, n) {
445
+ a(n, !0), A(e, Ce);
446
+ let u = T(n, "html", 7), f = T(n, "language", 7), p = s(!1), h = `mpb-teacher-instructions-${Math.random().toString(36).slice(2, 10)}`;
447
+ var _ = {
448
+ get html() {
449
+ return u();
450
+ },
451
+ set html(e) {
452
+ u(e), c();
453
+ },
454
+ get language() {
455
+ return f();
456
+ },
457
+ set language(e) {
458
+ f(e), c();
459
+ }
460
+ }, b = Se(), C = r(b), w = l(C, !0), E = S(C, 2);
461
+ return g(E, u, !0), o(E), o(b), M((e) => {
462
+ m(C, "aria-expanded", t(p)), m(C, "aria-controls", h), y(w, e), m(E, "id", h), m(E, "hidden", !t(p));
463
+ }, [() => F(t(p) ? "hideTeacherInstructions" : "showTeacherInstructions", f())]), d("click", C, () => x(p, !t(p))), v(e, b), i(_);
464
+ }
465
+ N(["click"]), k(we, {
466
+ html: {},
467
+ language: {}
468
+ }, [], [], { mode: "open" });
469
+ //#endregion
470
+ //#region src/delivery/computeChoiceCorrectness.ts
471
+ function Te(e) {
472
+ let t = /* @__PURE__ */ new Map(), { isEvaluateMode: n, correctChoiceId: r, selectedId: i, showCorrectAnswer: a } = e;
473
+ return !n || !r ? t : a ? (t.set(r, "correct"), t) : i ? i === r ? (t.set(r, "correct"), t) : (t.set(i, "incorrect"), t.set(r, "incorrect"), t) : (t.set(r, "incorrect"), t);
474
+ }
475
+ //#endregion
476
+ //#region src/delivery/computeLayoutProfile.ts
477
+ var Ee = "{{blank}}", De = /* @__PURE__ */ new Set([
478
+ "audio_blank_only",
479
+ "stimulus_image_blank",
480
+ "token_sequence"
481
+ ]);
482
+ function Oe(e) {
483
+ let { interactionMode: t = "", template: n = "", choiceLayout: r, layoutProfile: i = "", hasAudio: a = !1, useFeatureButtonAudio: o } = e, s = t === "audio_mc_only", c = n ? n.replace(/<[^>]+>/g, "").replace(/&nbsp;/g, " ").trim() === Ee : !1, l = r === "horizontal" || r === "vertical" ? r : s || c ? "horizontal" : "vertical";
484
+ return {
485
+ isAudioOnlyMode: s,
486
+ isBlankOnlyTemplate: c,
487
+ choiceLayout: l,
488
+ isHorizontalChoices: l === "horizontal",
489
+ hasInlineSentenceAudioLayout: i === "inline_sentence" && a,
490
+ useFeatureButtonAudio: typeof o == "boolean" ? o : a && De.has(i)
491
+ };
492
+ }
493
+ //#endregion
494
+ //#region src/delivery/computeLayoutStyle.ts
495
+ var X = {
496
+ blankStandaloneWidthRem: {
497
+ varName: "--mpb-blank-standalone-width",
498
+ unit: "rem"
499
+ },
500
+ blankWideWidthRem: {
501
+ varName: "--mpb-blank-wide-width",
502
+ unit: "rem"
503
+ },
504
+ blankUnderlineWidthPx: {
505
+ varName: "--mpb-blank-underline-width",
506
+ unit: "px"
507
+ },
508
+ blankUnderlineWideWidthPx: {
509
+ varName: "--mpb-blank-underline-wide-width",
510
+ unit: "px"
511
+ },
512
+ horizontalChoiceWidthPx: {
513
+ varName: "--mpb-choice-width-px",
514
+ unit: "px"
515
+ },
516
+ horizontalChoiceWidthVw: {
517
+ varName: "--mpb-choice-width-vw",
518
+ unit: "vw"
519
+ },
520
+ horizontalChoiceTileMinHeightRem: {
521
+ varName: "--mpb-choice-tile-min-height",
522
+ unit: "rem"
523
+ },
524
+ horizontalChoiceContentMinHeightRem: {
525
+ varName: "--mpb-choice-content-min-height",
526
+ unit: "rem"
527
+ },
528
+ choiceImageMaxHeightRem: {
529
+ varName: "--mpb-choice-image-max-height",
530
+ unit: "rem"
531
+ },
532
+ choiceImageMaxWidthRem: {
533
+ varName: "--mpb-choice-image-max-width",
534
+ unit: "rem"
535
+ },
536
+ choiceGroupGapRem: {
537
+ varName: "--mpb-choice-group-gap",
538
+ unit: "rem"
539
+ },
540
+ choiceRowGapRem: {
541
+ varName: "--mpb-choice-row-gap",
542
+ unit: "rem"
543
+ },
544
+ horizontalChoiceRadioTopMarginRem: {
545
+ varName: "--mpb-horizontal-choice-radio-top-margin",
546
+ unit: "rem"
547
+ },
548
+ narrowHorizontalChoiceMaxWidthPx: {
549
+ varName: "--mpb-narrow-choice-max-width",
550
+ unit: "px"
551
+ },
552
+ toggleButtonGapRem: {
553
+ varName: "--mpb-toggle-button-gap",
554
+ unit: "rem"
555
+ },
556
+ listenButtonSizePx: {
557
+ varName: "--mpb-listen-button-size",
558
+ unit: "px"
559
+ },
560
+ audioBlankTemplateMarginTopRem: {
561
+ varName: "--mpb-audio-blank-template-margin-top",
562
+ unit: "rem"
563
+ },
564
+ audioBlankTemplateMarginBottomRem: {
565
+ varName: "--mpb-audio-blank-template-margin-bottom",
566
+ unit: "rem"
567
+ },
568
+ audioInstructionsMaxWidthPx: {
569
+ varName: "--mpb-audio-instructions-max-width",
570
+ unit: "px"
571
+ },
572
+ stimulusMinColumnPx: {
573
+ varName: "--mpb-stimulus-min-column",
574
+ unit: "px"
575
+ },
576
+ textMinColumnPx: {
577
+ varName: "--mpb-text-min-column",
578
+ unit: "px"
579
+ },
580
+ stimulusGridColumnGapRem: {
581
+ varName: "--mpb-stimulus-grid-column-gap",
582
+ unit: "rem"
583
+ },
584
+ stimulusGridRowGapRem: {
585
+ varName: "--mpb-stimulus-grid-row-gap",
586
+ unit: "rem"
587
+ },
588
+ stimulusSentenceMarginTopRem: {
589
+ varName: "--mpb-stimulus-sentence-margin-top",
590
+ unit: "rem"
591
+ },
592
+ stimulusChoicesMarginTopRem: {
593
+ varName: "--mpb-stimulus-choices-margin-top",
594
+ unit: "rem"
595
+ },
596
+ tokenGridColumnGapRem: {
597
+ varName: "--mpb-token-grid-column-gap",
598
+ unit: "rem"
599
+ },
600
+ tokenGridRowGapRem: {
601
+ varName: "--mpb-token-grid-row-gap",
602
+ unit: "rem"
603
+ },
604
+ tokenTemplateMarginTopRem: {
605
+ varName: "--mpb-token-template-margin-top",
606
+ unit: "rem"
607
+ },
608
+ tokenInlineTokenGapRem: {
609
+ varName: "--mpb-token-inline-token-gap",
610
+ unit: "rem"
611
+ },
612
+ tokenChoicesMarginTopRem: {
613
+ varName: "--mpb-token-choices-margin-top",
614
+ unit: "rem"
615
+ },
616
+ inlineGridColumnGapRem: {
617
+ varName: "--mpb-inline-grid-column-gap",
618
+ unit: "rem"
619
+ },
620
+ inlineGridRowGapRem: {
621
+ varName: "--mpb-inline-grid-row-gap",
622
+ unit: "rem"
623
+ },
624
+ inlineTemplateMarginTopRem: {
625
+ varName: "--mpb-inline-template-margin-top",
626
+ unit: "rem"
627
+ },
628
+ inlineChoicesMarginTopRem: {
629
+ varName: "--mpb-inline-choices-margin-top",
630
+ unit: "rem"
631
+ }
632
+ }, ke = {
633
+ audio_blank_only: {
634
+ blankWideWidthRem: 10,
635
+ blankUnderlineWideWidthPx: 6,
636
+ horizontalChoiceTileMinHeightRem: 11.25,
637
+ horizontalChoiceContentMinHeightRem: 9.375,
638
+ choiceGroupGapRem: 1,
639
+ audioBlankTemplateMarginBottomRem: 1.875
640
+ },
641
+ stimulus_image_blank: {
642
+ blankWideWidthRem: 10,
643
+ blankUnderlineWideWidthPx: 6
644
+ },
645
+ token_sequence: {
646
+ blankStandaloneWidthRem: 7,
647
+ blankUnderlineWideWidthPx: 6
648
+ }
649
+ };
650
+ function Ae(e) {
651
+ let { layoutProfile: t, isBlankOnlyTemplate: n } = e, r = e.configuredLimits && typeof e.configuredLimits == "object" ? e.configuredLimits : {}, i = e.customProfilePresets && typeof e.customProfilePresets == "object" ? e.customProfilePresets : {}, a = i[t] && typeof i[t] == "object" ? i[t] : {}, o = {
652
+ ...ke[t] ?? {},
653
+ ...a
654
+ }, s = {
655
+ ...L,
656
+ ...r,
657
+ ...o
658
+ }, c = ["audio_blank_only", "stimulus_image_blank"], l = [
659
+ "audio_blank_only",
660
+ "stimulus_image_blank",
661
+ "token_sequence"
662
+ ], u = c.includes(t) ? `${s.blankWideWidthRem}rem` : n ? `${s.blankStandaloneWidthRem}rem` : "auto", d = l.includes(t) ? `${s.blankUnderlineWideWidthPx}px` : `${s.blankUnderlineWidthPx}px`;
663
+ return {
664
+ rootStyle: Object.keys(X).map((e) => `${X[e].varName}:${s[e]}${X[e].unit}`).join(";"),
665
+ blankWidth: u,
666
+ blankBorderWidth: d,
667
+ legendMaxChars: s.legendMaxChars
668
+ };
669
+ }
670
+ //#endregion
671
+ //#region src/delivery/computeDisplayState.ts
672
+ var Z = {
673
+ default: {
674
+ silentUrl: "https://assets.learnosity.com/organisations/844/0c9f2aa3-3cd5-4de7-93ef-541c24ca35da.svg",
675
+ playingUrl: "https://assets.learnosity.com/organisations/844/231dfdc2-c113-4be5-91fb-e75a0ca5994b.svg"
676
+ },
677
+ es: {
678
+ silentUrl: "https://assets.learnosity.com/organisations/844/27a9d5b5-d873-4bd5-b9ba-22748782d8ba.svg",
679
+ playingUrl: "https://assets.learnosity.com/organisations/844/120f216d-96b7-4560-94b8-1d90710216b7.svg"
680
+ }
681
+ };
682
+ function je(e) {
683
+ let t = String(e.locale || "").toLowerCase(), n = t.slice(0, 2), r = e.audioButtonSkinsByLocale && typeof e.audioButtonSkinsByLocale == "object" ? e.audioButtonSkinsByLocale : {}, i = e.audioButtonSkin && typeof e.audioButtonSkin == "object" ? e.audioButtonSkin : null, a = t.startsWith("es") ? Z.es : Z.default;
684
+ return r[t] || r[n] || r.default || i || a;
685
+ }
686
+ function Me(e) {
687
+ let { selectedId: t, isEvaluateMode: n, showCorrectAnswer: r, correctChoiceId: i } = e;
688
+ return n && r && i ? i : t;
689
+ }
690
+ function Ne(e) {
691
+ let { isEvaluateMode: t, showCorrectAnswer: n, isCorrect: r, isIncorrect: i, selectedId: a } = e;
692
+ return !t || n ? "" : r ? "correct" : i && a ? "incorrect" : "";
693
+ }
694
+ function Pe(e) {
695
+ let { prompt: t, legendMaxChars: n, answerChoicesLabel: r } = e, i = t.replace(/<[^>]+>/g, " ").replace(/\s+/g, " ").trim(), a = Math.max(8, n);
696
+ return i ? i.length > a ? `${i.slice(0, Math.max(1, a - 1))}…` : i : r;
697
+ }
698
+ //#endregion
699
+ //#region src/delivery/cqt-css/sel-r1-base.css?raw
700
+ var Fe = "/* Shared base styles for all sel_r1-*_plusggg variants.\n Applied via the data-mpb-variant=\"sel-r1-base\" style element.\n Every selector starts at .mc-populated-blank-root carrying any r1 variant class,\n so it cannot match outside this element. :where() keeps the attribute match out\n of the specificity, so each per-variant file still overrides a base rule with\n the selector shapes it already uses.\n Source: web-ItemBankViewer/learnosity/templates/Renaissance/r1.scss */\n\n/* r1.scss: Starial font throughout.\n font-size 14px mirrors the Learnosity host root (.lrn_widget) which sets the\n base for all em-scaled rules in r1.scss (e.g. .rli-r1-content-element { 1.9em })\n and any em-based author content (e.g. <span style=\"font-size:1.8em\">). Without\n this base PIE inherits the 16px browser default and renders ~14% larger than\n the LSY reference. See CONTOOL-2567. */\n.mc-populated-blank-root:where([class*=\"variant-sel-r1-\"]) {\n font-family: Starial, Arial, sans-serif;\n font-size: 14px;\n}\n\n/* r1.scss: .rli-r1-audio-transcript { font-family:Roboto; font-size:16px } */\n.mc-populated-blank-root:where([class*=\"variant-sel-r1-\"]) .pie-audio-transcript {\n font-family: Roboto, Arial, sans-serif;\n font-size: 16px;\n font-style: normal;\n font-weight: 400;\n}\n\n/* r1.scss: .rli-r1-content-element { font-size: 1.9em } wraps all stem tokens.\n Makes inline font-size spans in the template multiply on top of this base. */\n.mc-populated-blank-root:where([class*=\"variant-sel-r1-\"]) .pie-template-line {\n font-size: 1.9em;\n}\n\n/* r1.scss: .rli-r1-stem { display:flex; flex-direction:row; justify-content:center }\n r1.scss: .rli-r1-content-element { margin-right:2px; margin-left:2px } — 4px total gap.\n Apply the per-element margin to both classless tokens and the blank slot\n (which is the cloze equivalent) so the gap stacks with whitespace text-nodes\n between flex items the same way LSY does. Earlier this used column-gap:4px,\n but flex column-gap accumulates with the cloze margin and the implicit\n whitespace, producing a wider gap than LSY shows. See CONTOOL-2569. */\n.mc-populated-blank-root:where([class*=\"variant-sel-r1-\"]) .pie-template-line {\n display: flex;\n flex-direction: row;\n align-items: baseline;\n justify-content: center;\n}\n\n.mc-populated-blank-root:where([class*=\"variant-sel-r1-\"]) .pie-template-line p {\n margin: 0;\n display: flex;\n flex-direction: row;\n align-items: baseline;\n}\n\n/* r1.scss: .rli-r1-content-element { min-width:150px; max-width:150px; min-height:150px;\n line-height:89px; margin-right:2px; margin-left:2px } — wraps every stem token\n (blank slot and adjacent inline spans) in LSY, giving each a 150px box with a\n 2px per-side margin. Apply to inline tokens in all r1 variants so trailing\n tokens in audio_blank_only (gplusggg) match the blank's height the way LSY does. */\n.mc-populated-blank-root:where([class*=\"variant-sel-r1-\"]) .pie-template-line span:not([class]) {\n min-width: 150px;\n max-width: 150px;\n min-height: 150px;\n line-height: 89px;\n margin-left: 2px;\n margin-right: 2px;\n}\n\n/* .pie-template-line's align-items:baseline (above) computes a shared baseline\n across all its flex items. .pie-blank-slot has no baseline-participating child\n of its own (.cloze-marker centers internally, align-items:center) — so it\n contributes a *synthesized* baseline back to the row, based on its own box\n geometry. That geometry swings wildly depending on the blank's content: an\n empty placeholder vs. a selected choice's image (up to 150x150). Every time a\n choice is selected the row's shared baseline is recomputed from that new\n geometry, visibly shifting sibling tokens like a leading/trailing stem word.\n align-self removes the blank from that shared computation entirely — its\n siblings' position no longer depends on what's currently displayed inside it.\n See CONTOOL-3159. */\n.mc-populated-blank-root:where([class*=\"variant-sel-r1-\"]) .pie-template-line .pie-blank-slot {\n align-self: flex-end;\n}\n\n/* In token_sequence layouts the blank itself is also a content-element box (no\n surrounding .rli-r1-cloze container at 160px). audio_blank_only / stimulus_image_blank\n keep their own 160px min-height set on the blank slot in McPopulatedBlank.svelte to\n mirror LSY's .rli-r1-cloze height. The 2px per-side margin matches LSY's\n .rli-r1-content-element pattern.\n .pie-blank-slot is box-sizing:border-box (McPopulatedBlank.svelte sets it for\n the whole element) with a permanent 6px border-bottom (the underline) —\n min-height:150px therefore only leaves 144px for content,\n so an empty blank (content ~0px, clamped to the 150px floor) and a blank\n showing a 150px choice image (150 + 6 border = 156px, exceeding the floor)\n render at two different total heights. Since .pie-blank-slot is bottom-anchored\n in its row (align-self:flex-end above), that 6px height difference shows up as\n a visible shift of the blank/image every time a choice is selected or cleared.\n min-height:156px keeps the total box height constant regardless of content, so\n the 150px is fully available to the image/text and the border no longer\n competes with it. See CONTOOL-3159. */\n.mc-populated-blank-root:where([class*=\"variant-sel-r1-\"]).layout-token_sequence\n .pie-template-line\n .pie-blank-slot {\n min-width: 150px;\n max-width: 150px;\n min-height: 156px;\n line-height: 89px;\n margin-left: 2px;\n margin-right: 2px;\n}\n\n/* audio_blank_only / stimulus_image_blank keep the 160px wide blank slot, but\n still need the 2px per-side margin so the gap to the trailing token mirrors\n LSY's .rli-r1-content-element rhythm. See CONTOOL-2569. */\n.mc-populated-blank-root:where([class*=\"variant-sel-r1-\"]).layout-audio_blank_only\n .pie-template-line\n .pie-blank-slot,\n.mc-populated-blank-root:where([class*=\"variant-sel-r1-\"]).layout-stimulus_image_blank\n .pie-template-line\n .pie-blank-slot {\n margin-left: 2px;\n margin-right: 2px;\n}\n\n/* The `.pie-template-line span:not([class])` rule above has no depth limit, so it\n also matches the unclassed answer <span> ClozeMarker.svelte renders inside\n .pie-blank-value once a choice is selected (e.g. author font-size overrides like\n <span style=\"font-size:3em\">). For token_sequence that coincides with the blank\n slot's own 150px/89px box above, so outer and inner agree. audio_blank_only /\n stimulus_image_blank instead keep .pie-blank-slot at LSY's separate, taller\n .rli-r1-cloze box (160px) — forcing the answer span into the stem token's\n 150px/89px box there is wrong: a plain (non-flex) span whose min-height exceeds\n its line-height renders that line top-anchored, pinning the answer text to the\n top of the blank with the rest of the box empty beneath it, instead of centered\n on the underline the way LSY renders it. See CONTOOL-3159. */\n.mc-populated-blank-root:where([class*=\"variant-sel-r1-\"]).layout-audio_blank_only\n .pie-blank-value\n span:not([class]),\n.mc-populated-blank-root:where([class*=\"variant-sel-r1-\"]).layout-stimulus_image_blank\n .pie-blank-value\n span:not([class]) {\n min-width: 0;\n max-width: none;\n min-height: 0;\n line-height: normal;\n margin-left: 0;\n margin-right: 0;\n}\n\n/* r1.scss: .rli-r1-content-element { font-size:1.9em; line-height:89px } on distractors */\n.mc-populated-blank-root:where([class*=\"variant-sel-r1-\"]) .pie-choice-label {\n font-size: 1.9em;\n line-height: 89px;\n}\n\n/* r1.scss: .rli-r1-content-element { min-width:150px; max-width:150px;\n min-height:150px } wraps every image (stem token + distractor) and forces\n the content box to 150×150. LSY's host also rewrites <img width/height>\n to 150 server-side. PIE keeps the authored attributes (typically 108×108),\n so without an explicit override images render ~28% smaller than LSY.\n See CONTOOL-2570. */\n.mc-populated-blank-root:where([class*=\"variant-sel-r1-\"]) .pie-template-line img,\n.mc-populated-blank-root:where([class*=\"variant-sel-r1-\"]) .pie-choice-label img {\n width: 150px;\n height: 150px;\n}\n", Ie = {
701
+ "sel_r1-_plusggg": {
702
+ variantId: "sel-r1-plusggg",
703
+ variantClass: "variant-sel-r1-plusggg",
704
+ sourceUrl: "https://global-pr-ibvcustomfiles.renaissance-go.com/learnosity/sel_r1-_plusggg/0.0.1/question.css",
705
+ cssText: "/* Source baseline: https://global-pr-ibvcustomfiles.renaissance-go.com/learnosity/sel_r1-_plusggg/0.0.1/question.css */\n/* Shared r1 base styles (font, template-line flex, choice-label) are in sel-r1-base.css */\n.mc-populated-blank-root.variant-sel-r1-plusggg {\n max-width: 875px;\n margin-inline: auto;\n --mpb-listen-button-size: 128px;\n --mpb-choice-width-px: 155px;\n --mpb-choice-tile-min-height: 11.25rem;\n --mpb-choice-content-min-height: 9.375rem;\n --mpb-choice-group-gap: 1rem;\n --mpb-choice-hover-bg: #f2f2f2;\n --mpb-choice-selected-bg: #fcfcd3;\n}\n\n.mc-populated-blank-root.variant-sel-r1-plusggg {\n --mpb-choice-radio-padding: 20px;\n}\n"
706
+ },
707
+ "sr-vic": {
708
+ variantId: "sr-vic",
709
+ variantClass: "variant-sr-vic",
710
+ sourceUrl: "https://global-pr-ibvcustomfiles.renaissance-go.com/learnosity/sr-vic/0.0.1/question.css",
711
+ cssText: "/* Source baseline: https://global-pr-ibvcustomfiles.renaissance-go.com/learnosity/sr-vic/0.0.1/question.css */\n/* Reference layout: web-ItemBankViewer/learnosity/templates/Renaissance/vic.scss */\n.mc-populated-blank-root.variant-sr-vic {\n font-family: Starial, Arial, sans-serif;\n --mpb-inline-grid-column-gap: 1rem;\n --mpb-inline-grid-row-gap: 0.5rem;\n --mpb-inline-template-margin-top: 0.2rem;\n --mpb-inline-choices-margin-top: 0.2rem;\n}\n\n.mc-populated-blank-root.variant-sr-vic .pie-template-line,\n.mc-populated-blank-root.variant-sr-vic .pie-blank-value,\n.mc-populated-blank-root.variant-sr-vic .pie-choice-label {\n line-height: 123%;\n}\n\n/* vic.scss: .rli-vic-answer uses display:flex so sentence and cloze stay on\n one line. The template HTML wraps text in <p>, which is block by default and\n breaks to a new line. Making <p> inline keeps the sentence and blank inline. */\n.mc-populated-blank-root.variant-sr-vic .pie-template-line p {\n display: inline;\n margin: 0;\n}\n\n/* LSY .rli-vic-answer has no text-align rule and inherits start; PIE's\n inline_sentence layout sets text-align:center on .template-line via a\n Svelte-scoped selector with specificity (0,4,0), so we need to match or\n exceed that. Pin sr-vic back to start so wrapped lines stay left-aligned.\n Same root cause as sel-vic. See CONTOOL-2573. */\n.mc-populated-blank-root.variant-sr-vic.layout-inline_sentence .pie-template-line.template-line {\n text-align: start;\n}\n\n/* vic.scss: .rli-vic-cloze > .rli-vic-content-element { color: #cc3333 } */\n.mc-populated-blank-root.variant-sr-vic .pie-blank-value {\n color: #cc3333;\n}\n\n/* vic.scss: .rli-vic-selected { background-color: #fcfcd3 } applied to the\n whole distractor row (radio + label), not just the label wrapper. */\n.mc-populated-blank-root.variant-sr-vic .pie-choice.is-selected {\n background-color: #fcfcd3;\n border-radius: 6px;\n}\n\n.mc-populated-blank-root.variant-sr-vic .pie-choice.is-selected .pie-choice-label-wrap {\n background-color: transparent;\n}\n\n/* vic.scss: distractor label text sits to the right of the radio — no centering. */\n.mc-populated-blank-root.variant-sr-vic .pie-choice-label {\n text-align: left;\n justify-content: flex-start;\n}\n\n/* vic.scss: .rli-vic-distractor:hover { background-color: #F2F2F2 } applied to\n the full row element, not only the inner label wrapper. */\n.mc-populated-blank-root.variant-sr-vic .pie-choice:not(.pie-choice-horizontal):hover {\n background-color: #f2f2f2;\n border-radius: 6px;\n}\n\n.mc-populated-blank-root.variant-sr-vic\n .pie-choice:not(.pie-choice-horizontal):hover\n .pie-choice-label-wrap {\n background-color: transparent;\n}\n\n/* Selected state must win over hover — yellow persists when hovering a chosen row. */\n.mc-populated-blank-root.variant-sr-vic .pie-choice:not(.pie-choice-horizontal).is-selected:hover {\n background-color: #fcfcd3;\n}\n"
712
+ },
713
+ sel_vic: {
714
+ variantId: "sel-vic",
715
+ variantClass: "variant-sel-vic",
716
+ sourceUrl: "https://global-pr-ibvcustomfiles.renaissance-go.com/learnosity/sel_vic/0.0.1/question.css",
717
+ cssText: "/* Source baseline: https://global-pr-ibvcustomfiles.renaissance-go.com/learnosity/sel_vic/0.0.1/question.css */\n/* Reference layout: web-ItemBankViewer/learnosity/templates/Renaissance/sel_vic/scss/main.scss + vic.scss */\n.mc-populated-blank-root.variant-sel-vic {\n font-family: Starial, Arial, sans-serif;\n /* LSY chain: .lrn_widget (14px host) → .sel-vic { 1.5em } = 21px.\n PIE collapses both LSY layers into this single variant-root selector, so\n the resolved value is set directly. See CONTOOL-2567. */\n font-size: 21px;\n max-width: 800px;\n margin-inline: auto;\n --mpb-inline-grid-column-gap: 1rem;\n --mpb-inline-grid-row-gap: 0.5rem;\n --mpb-inline-template-margin-top: 0.2rem;\n --mpb-inline-choices-margin-top: 0.2rem;\n}\n\n.mc-populated-blank-root.variant-sel-vic .pie-audio-transcript {\n font-family: Roboto, Arial, sans-serif;\n font-size: 16px;\n font-style: normal;\n font-weight: 400;\n}\n\n.mc-populated-blank-root.variant-sel-vic .pie-template-line,\n.mc-populated-blank-root.variant-sel-vic .pie-blank-value,\n.mc-populated-blank-root.variant-sel-vic .pie-choice-label {\n line-height: 123%;\n}\n\n/* sel_vic/main.scss: template left ~75%, audio right ~25% on the same row.\n Svelte scoping prevents the component-internal grid-area rule from reaching\n .audio-container inside AudioPlayer, so we override it here via the global\n .pie-audio-container class which is not subject to scope hashing. */\n.mc-populated-blank-root.variant-sel-vic .pie-audio-container {\n grid-area: audio;\n margin: 0;\n justify-self: end;\n align-self: start;\n min-height: 128px;\n}\n\n/* vic.scss: sentence and cloze sit inline — the <p> wrapper must not break to\n a new line before the blank slot. */\n.mc-populated-blank-root.variant-sel-vic .pie-template-line p {\n display: inline;\n margin: 0;\n}\n\n/* LSY .rli-vic-answer has no text-align rule and inherits start; PIE's\n inline_sentence layout sets text-align:center on .template-line via a\n Svelte-scoped selector with specificity (0,4,0), so we need to match or\n exceed that. Pin sel-vic back to start so wrapped lines stay left-aligned.\n See CONTOOL-2573. */\n.mc-populated-blank-root.variant-sel-vic.layout-inline_sentence .pie-template-line.template-line {\n text-align: start;\n}\n\n/* vic.scss: .rli-vic-cloze { margin-left: 6px; margin-right: 6px } gives the\n cloze breathing room from adjacent text or punctuation. The shared blank slot\n has no inline margin, so set it here so the cloze→trailing-punctuation gap\n matches LSY. See CONTOOL-2572. */\n.mc-populated-blank-root.variant-sel-vic .pie-template-line .pie-blank-slot {\n margin-left: 6px;\n margin-right: 6px;\n}\n\n/* vic.scss: .rli-vic-cloze > .rli-vic-content-element { color: #cc3333 } */\n.mc-populated-blank-root.variant-sel-vic .pie-blank-value {\n color: #cc3333;\n}\n\n/* sel_vic/main.scss: .sel-vic { max-width: 800px } — the fieldset/choices must\n also be constrained so rows don't span beyond 800px. */\n.mc-populated-blank-root.variant-sel-vic .pie-choices-fieldset {\n max-width: 800px;\n width: 100%;\n}\n\n/* vic.scss: distractor label text sits to the right of the radio — no centering. */\n.mc-populated-blank-root.variant-sel-vic .pie-choice-label {\n text-align: left;\n justify-content: flex-start;\n}\n\n/* vic.scss: .rli-vic-selected { background-color: #fcfcd3 } on the full row. */\n.mc-populated-blank-root.variant-sel-vic .pie-choice.is-selected {\n background-color: #fcfcd3;\n border-radius: 6px;\n}\n\n.mc-populated-blank-root.variant-sel-vic .pie-choice.is-selected .pie-choice-label-wrap {\n background-color: transparent;\n}\n\n/* Selected state must win over hover. */\n.mc-populated-blank-root.variant-sel-vic .pie-choice:not(.pie-choice-horizontal).is-selected:hover {\n background-color: #fcfcd3;\n}\n\n/* vic.scss: .rli-vic-distractor:hover { background-color: #F2F2F2 } on the full row. */\n.mc-populated-blank-root.variant-sel-vic .pie-choice:not(.pie-choice-horizontal):hover {\n background-color: #f2f2f2;\n border-radius: 6px;\n}\n\n.mc-populated-blank-root.variant-sel-vic\n .pie-choice:not(.pie-choice-horizontal):hover\n .pie-choice-label-wrap {\n background-color: transparent;\n}\n\n@media (min-width: 620px) {\n .mc-populated-blank-root.variant-sel-vic .pie-audio-transcript {\n min-width: 620px;\n max-width: 800px;\n transform: translateX(-55px);\n }\n}\n"
718
+ },
719
+ "sel_r1-_gplusggg": {
720
+ variantId: "sel-r1-gplusggg",
721
+ variantClass: "variant-sel-r1-gplusggg",
722
+ sourceUrl: "https://global-pr-ibvcustomfiles.renaissance-go.com/learnosity/sel_r1-_gplusggg/0.0.1/question.css",
723
+ cssText: "/* Source baseline: https://global-pr-ibvcustomfiles.renaissance-go.com/learnosity/sel_r1-_gplusggg/0.0.1/question.css */\n/* Shared r1 base styles (font, template-line flex, choice-label) are in sel-r1-base.css */\n.mc-populated-blank-root.variant-sel-r1-gplusggg {\n max-width: 875px;\n margin-inline: auto;\n --mpb-listen-button-size: 128px;\n --mpb-choice-width-px: 155px;\n --mpb-choice-tile-min-height: 11.25rem;\n --mpb-choice-content-min-height: 9.375rem;\n --mpb-choice-group-gap: 1rem;\n --mpb-choice-hover-bg: #f2f2f2;\n --mpb-choice-selected-bg: #fcfcd3;\n}\n\n/* r1.scss: .rli-r1-content-element boxes all have fixed line-height:89px, so every\n token in the stem row shares a stable baseline regardless of content. In PIE,\n the blank slot's baseline shifts when the empty placeholder (short &nbsp;) is\n replaced by the filled value span (full text height), dragging adjacent tokens\n down by ~9px. Switching to align-items:center is safe here because gplusggg has\n only one row of content (blank + \"four\"), so vertical centering and baseline\n alignment produce the same visual result. The :is() wrapper raises specificity\n above the base [class*=] rule without needing !important. */\n:is(.mc-populated-blank-root.variant-sel-r1-gplusggg) .pie-template-line {\n align-items: center;\n}\n"
724
+ },
725
+ "sel_r1-g_plusggg": {
726
+ variantId: "sel-r1-g-stem",
727
+ variantClass: "variant-sel-r1-g-stem",
728
+ sourceUrl: "https://global-pr-ibvcustomfiles.renaissance-go.com/learnosity/sel_r1-g_plusggg/0.0.1/question.css",
729
+ cssText: "/* Source baseline: https://global-pr-ibvcustomfiles.renaissance-go.com/learnosity/sel_r1-g_plusggg/0.0.1/question.css */\n/* Shared r1 base styles (font, template-line flex, choice-label) are in sel-r1-base.css */\n.mc-populated-blank-root.variant-sel-r1-g-stem {\n max-width: 875px;\n margin-inline: auto;\n --mpb-listen-button-size: 128px;\n --mpb-choice-width-px: 155px;\n --mpb-choice-tile-min-height: 11.25rem;\n --mpb-choice-content-min-height: 9.375rem;\n --mpb-choice-hover-bg: #f2f2f2;\n --mpb-choice-selected-bg: #fcfcd3;\n /* r1.scss: .rli-r1-cloze { border-bottom: 6px solid } */\n --mpb-blank-underline-wide-width: 6px;\n}\n"
730
+ },
731
+ "sel_r1-gg_plusggg": {
732
+ variantId: "sel-r1-gg-plus",
733
+ variantClass: "variant-sel-r1-gg-plus",
734
+ sourceUrl: "https://global-pr-ibvcustomfiles.renaissance-go.com/learnosity/sel_r1-gg_plusggg/0.0.1/question.css",
735
+ cssText: "/* Source baseline: https://global-pr-ibvcustomfiles.renaissance-go.com/learnosity/sel_r1-gg_plusggg/0.0.1/question.css */\n/* Shared r1 base styles (font, template-line flex, choice-label) are in sel-r1-base.css */\n.mc-populated-blank-root.variant-sel-r1-gg-plus {\n max-width: 875px;\n margin-inline: auto;\n --mpb-listen-button-size: 128px;\n --mpb-choice-width-px: 155px;\n --mpb-choice-tile-min-height: 11.25rem;\n --mpb-choice-content-min-height: 9.375rem;\n --mpb-choice-hover-bg: #f2f2f2;\n --mpb-choice-selected-bg: #fcfcd3;\n}\n"
736
+ },
737
+ "sel_r1-_ggplusggg": {
738
+ variantId: "sel-r1-ggplus",
739
+ variantClass: "variant-sel-r1-ggplus",
740
+ sourceUrl: "https://global-pr-ibvcustomfiles.renaissance-go.com/learnosity/sel_r1-_ggplusggg/0.0.1/question.css",
741
+ cssText: "/* Source baseline: https://global-pr-ibvcustomfiles.renaissance-go.com/learnosity/sel_r1-_ggplusggg/0.0.1/question.css */\n/* Shared r1 base styles (font, template-line flex, choice-label) are in sel-r1-base.css */\n.mc-populated-blank-root.variant-sel-r1-ggplus {\n max-width: 875px;\n margin-inline: auto;\n --mpb-listen-button-size: 128px;\n --mpb-choice-width-px: 155px;\n --mpb-choice-tile-min-height: 11.25rem;\n --mpb-choice-content-min-height: 9.375rem;\n --mpb-choice-hover-bg: #f2f2f2;\n --mpb-choice-selected-bg: #fcfcd3;\n}\n"
742
+ },
743
+ "sel_r1-s3_plusggg": {
744
+ variantId: "sel-r1-s3",
745
+ variantClass: "variant-sel-r1-s3",
746
+ sourceUrl: "https://global-pr-ibvcustomfiles.renaissance-go.com/learnosity/sel_r1-s3_plusggg/0.0.1/question.css",
747
+ cssText: "/* Source baseline: https://global-pr-ibvcustomfiles.renaissance-go.com/learnosity/sel_r1-s3_plusggg/0.0.1/question.css */\n/* Shared r1 base styles (font, template-line flex, choice-label) are in sel-r1-base.css */\n.mc-populated-blank-root.variant-sel-r1-s3 {\n max-width: 860px;\n margin-inline: auto;\n --mpb-listen-button-size: 128px;\n --mpb-choice-width-px: 155px;\n --mpb-choice-tile-min-height: 11.25rem;\n --mpb-choice-content-min-height: 9.375rem;\n --mpb-choice-group-gap: 0.35rem;\n --mpb-choice-row-gap: 0.35rem;\n --mpb-horizontal-choice-radio-top-margin: 0.25rem;\n --mpb-stimulus-min-column: 240px;\n --mpb-stimulus-grid-column-gap: 1.1rem;\n --mpb-stimulus-choices-margin-top: 0.85rem;\n --mpb-audio-blank-template-margin-bottom: 0.9rem;\n --mpb-blank-wide-width: 6.8rem;\n}\n\n/* sel_r1-s3_plusggg/question.css does not set font-weight on distractors or\n cloze content-element, so they inherit 400 from the host root. The earlier\n font-weight:500 override caused PIE to render visibly heavier than LSY for\n the same author content. See CONTOOL-2571. */\n.mc-populated-blank-root.variant-sel-r1-s3 .pie-choice-label,\n.mc-populated-blank-root.variant-sel-r1-s3 .pie-choice-label :is(span, p, div) {\n font-size: 1.9em;\n line-height: 89px;\n}\n\n.mc-populated-blank-root.variant-sel-r1-s3 .pie-blank-value,\n.mc-populated-blank-root.variant-sel-r1-s3 .pie-blank-value :is(span, p, div) {\n line-height: 1.1;\n white-space: nowrap;\n}\n\n.mc-populated-blank-root.variant-sel-r1-s3 .pie-choice-horizontal .pie-choice-tile {\n border-radius: 6px;\n background: #f1f1f1;\n}\n\n.mc-populated-blank-root.variant-sel-r1-s3.layout-stimulus_image_blank {\n grid-template-columns: minmax(220px, auto) auto auto;\n grid-template-areas:\n \"transcript transcript transcript\"\n \"sentence template audio\"\n \"choices choices choices\";\n justify-content: center;\n /* question.css: .rli-s3-cloze-container { justify-content:end } bottom-anchors\n the cloze against the shared sentence/audio row instead of top-aligning it —\n matches every item sitting on the same visual baseline. See CONTOOL-3159. */\n align-items: end;\n}\n\n.mc-populated-blank-root.variant-sel-r1-s3.layout-stimulus_image_blank .pie-template-line {\n grid-area: template;\n justify-self: center;\n}\n\n/* ClozeMarker.svelte's shared .cloze-marker rule vertically *centers* its content\n (align-items:center). question.css's .rli-s3-cloze-container uses\n justify-content:end instead, bottom-anchoring the answer text against the\n underline. Centering leaves it floating well above both the underline and the\n sentence image's own (bottom-anchored) baseline. The blank's own box height\n (160px, from McPopulatedBlank.svelte's shared audio_blank_only/stimulus_image_blank\n rule) is left as-is — it already matches the Learnosity reference (~161px)\n closely; only the internal alignment was wrong. See CONTOOL-3159. */\n.mc-populated-blank-root.variant-sel-r1-s3.layout-stimulus_image_blank .pie-blank-slot {\n align-items: flex-end;\n}\n\n.mc-populated-blank-root.variant-sel-r1-s3.layout-stimulus_image_blank .pie-sentence-line {\n justify-self: end;\n}\n\n.mc-populated-blank-root.variant-sel-r1-s3.layout-stimulus_image_blank .pie-audio-container {\n justify-self: start;\n align-self: start;\n}\n\n.mc-populated-blank-root.variant-sel-r1-s3.layout-stimulus_image_blank .pie-choices-fieldset {\n justify-self: center;\n width: fit-content;\n}\n\n.mc-populated-blank-root.variant-sel-r1-s3 .pie-sentence-line img {\n max-width: 100%;\n height: auto;\n}\n\n.mc-populated-blank-root.variant-sel-r1-s3 .pie-choice-horizontal:hover .pie-choice-tile {\n background: #e2e2e2;\n}\n\n.mc-populated-blank-root.variant-sel-r1-s3 .pie-choice-horizontal.is-selected .pie-choice-tile,\n.mc-populated-blank-root.variant-sel-r1-s3\n .pie-choice-horizontal.is-selected:hover\n .pie-choice-tile {\n background: #fcfcd3;\n}\n\n.mc-populated-blank-root.variant-sel-r1-s3 .pie-choice-horizontal .pie-choice-radio {\n transform: scale(0.85);\n}\n"
748
+ }
749
+ }, Le = (e) => String(e || "").trim().toLowerCase().replace(/v\d+\.\d+\.\d+$/i, ""), Re = (e) => Ie[Le(e)], ze = (e) => Re(e)?.variantClass || "", Be = /* @__PURE__ */ new Set([
750
+ "sel-r1-plusggg",
751
+ "sel-r1-gplusggg",
752
+ "sel-r1-g-stem",
753
+ "sel-r1-gg-plus",
754
+ "sel-r1-ggplus",
755
+ "sel-r1-s3"
756
+ ]), Ve = /\.mc-populated-blank-root(?![\w-])/g, He = ((e) => {
757
+ let t = 2166136261;
758
+ for (let n = 0; n < e.length; n++) t ^= e.charCodeAt(n), t = Math.imul(t, 16777619);
759
+ return (t >>> 0).toString(36);
760
+ })([Fe, ...Object.values(Ie).map((e) => e.cssText)].join("\n")), Ue = (e) => e.replace(Ve, `.mc-populated-blank-root:where([data-mpb-css="${He}"])`), We = (e, t, n) => {
761
+ let r = `mc-populated-blank-css-${t}-${He}`;
762
+ if (e.getElementById(r)) return;
763
+ let i = document.createElement("style");
764
+ i.id = r, i.setAttribute("data-mpb-variant", t), i.textContent = Ue(n), (e instanceof ShadowRoot ? e : e.head).appendChild(i);
765
+ }, Ge = (e, t) => {
766
+ if (!e?.cssText || typeof document > "u") return;
767
+ let n = t.getRootNode(), r = n instanceof ShadowRoot ? n : document;
768
+ Be.has(e.variantId) && We(r, "sel-r1-base", Fe), We(r, e.variantId, e.cssText);
769
+ }, Ke = j("<div class=\"pie-prompt svelte-6wlbb4\"></div>"), qe = P("<svg class=\"pie-correct-answer-toggle-svg svelte-6wlbb4\" preserveAspectRatio=\"xMinYMin meet\" version=\"1.1\" viewBox=\"-283 359 34 35\"><circle cx=\"-266\" cy=\"375.9\" r=\"14\" fill=\"var(--pie-tertiary-light, #d0e2f0)\"></circle><path d=\"M-280.5,375.9c0-8,6.5-14.5,14.5-14.5s14.5,6.5,14.5,14.5s-6.5,14.5-14.5,14.5S-280.5,383.9-280.5,375.9z M-279.5,375.9c0,7.4,6.1,13.5,13.5,13.5c7.4,0,13.5-6.1,13.5-13.5s-6.1-13.5-13.5-13.5C-273.4,362.4-279.5,368.5-279.5,375.9z\" fill=\"var(--pie-tertiary-light, #d0e2f0)\"></path><polygon points=\"-265.4,383.1 -258.6,377.2 -261.2,374.2 -264.3,376.9 -268.9,368.7 -272.4,370.6\" fill=\"var(--pie-tertiary, #146eb3)\"></polygon></svg>"), Je = P("<svg class=\"pie-correct-answer-toggle-svg svelte-6wlbb4\" preserveAspectRatio=\"xMinYMin meet\" version=\"1.1\" viewBox=\"-129.5 127 34 35\"><path d=\"M-112.9,160.4c-8.5,0-15.5-6.9-15.5-15.5c0-8.5,6.9-15.5,15.5-15.5s15.5,6.9,15.5,15.5 C-97.4,153.5-104.3,160.4-112.9,160.4z\" fill=\"#D0CAC5\" stroke=\"#E6E3E0\" stroke-width=\"0.75\"></path><path d=\"M-113.2,159c-8,0-14.5-6.5-14.5-14.5s6.5-14.5,14.5-14.5s14.5,6.5,14.5,14.5S-105.2,159-113.2,159z\" fill=\"#B3ABA4\" stroke=\"#CDC7C2\" stroke-width=\"0.5\"></path><circle cx=\"-114.2\" cy=\"143.5\" r=\"14\" fill=\"white\"></circle><path d=\"M-114.2,158c-8,0-14.5-6.5-14.5-14.5s6.5-14.5,14.5-14.5s14.5,6.5,14.5,14.5S-106.2,158-114.2,158z M-114.2,130c-7.4,0-13.5,6.1-13.5,13.5s6.1,13.5,13.5,13.5s13.5-6.1,13.5-13.5S-106.8,130-114.2,130z\" fill=\"var(--pie-background-dark, #ecedf1)\"></path><polygon points=\"-114.8,150.7 -121.6,144.8 -119,141.8 -115.9,144.5 -111.3,136.3 -107.8,138.2\" fill=\"var(--pie-tertiary, #146eb3)\"></polygon></svg>"), Ye = j("<div class=\"pie-correct-answer-toggle-row svelte-6wlbb4\"><button type=\"button\" class=\"pie-toggle-correct-answer svelte-6wlbb4\" style=\"gap:var(--mpb-toggle-button-gap, 0.5rem);\" data-testid=\"show-correct-answer\"><span class=\"pie-correct-answer-toggle-content svelte-6wlbb4\"><span class=\"pie-correct-answer-toggle-icon-holder svelte-6wlbb4\" aria-hidden=\"true\"><!></span> <span class=\"pie-correct-answer-toggle-label svelte-6wlbb4\"> </span></span></button></div>"), Xe = j("<div class=\"sentence-line pie-sentence-line svelte-6wlbb4\"></div>"), Ze = j("<div class=\"template-line pie-template-line svelte-6wlbb4\"><!><!><!></div>"), Qe = j("<p class=\"sr-only pie-result-feedback svelte-6wlbb4\" role=\"status\" aria-live=\"polite\"> </p>"), $e = j("<div><!> <!> <!> <!> <!> <!> <!> <p class=\"sr-only pie-blank-hint svelte-6wlbb4\"> </p> <fieldset class=\"pie-choices-fieldset svelte-6wlbb4\"><legend class=\"sr-only pie-choices-legend svelte-6wlbb4\"> </legend> <div style=\"gap:var(--mpb-choice-group-gap, 0.5rem);\" role=\"radiogroup\" tabindex=\"-1\"></div></fieldset></div>"), et = {
770
+ hash: "svelte-6wlbb4",
771
+ code: ".sr-only.svelte-6wlbb4 {position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0, 0, 0, 0);white-space:nowrap;border:0;}\n\n /* Layout is self-contained: PIE players ship no Tailwind, so no utility class or\n preflight reset can be assumed. The blank slot, choice tiles and variant\n max-widths are sized for border-box. */.mc-populated-blank-root.svelte-6wlbb4,\n .mc-populated-blank-root.svelte-6wlbb4 *,\n .mc-populated-blank-root.svelte-6wlbb4 *::before,\n .mc-populated-blank-root.svelte-6wlbb4 *::after {box-sizing:border-box;}\n\n /* An authored image on its own line (the sel_r1-s3 stimulus) would otherwise sit\n on the text baseline and add the descender gap below it. */.mc-populated-blank-root.svelte-6wlbb4 img {vertical-align:middle;}.mc-populated-blank-root.svelte-6wlbb4 {--mpb-focus-ring: var(\n --pie-focus-outline,\n var(--pie-button-focus-outline, var(--pie-focus-checked-border, #1565c0))\n );padding:1rem;}.pie-prompt.svelte-6wlbb4 {margin-bottom:1rem;}\n\n /* Flush paragraphs, as the demo app's preflight reset rendered them. */.pie-prompt.svelte-6wlbb4 p,\n .sentence-line.svelte-6wlbb4 p {margin:0;}.sentence-line.svelte-6wlbb4 {margin-bottom:0.75rem;}.pie-toggle-correct-answer.svelte-6wlbb4 {width:100%;cursor:pointer;border:0;background:transparent;padding:0;margin-bottom:0.75rem;display:flex;justify-content:center;text-align:center;font:inherit;color:var(--pie-text, black);}.pie-correct-answer-toggle-row.svelte-6wlbb4 {width:100%;display:flex;justify-content:flex-end;}.pie-correct-answer-toggle-content.svelte-6wlbb4 {display:flex;margin:0 auto;align-items:center;}.pie-correct-answer-toggle-icon-holder.svelte-6wlbb4 {width:25px;margin-right:5px;display:inline-flex;align-items:center;justify-content:center;}.pie-correct-answer-toggle-svg.svelte-6wlbb4 {width:25px;height:25px;}.pie-correct-answer-toggle-label.svelte-6wlbb4 {width:fit-content;min-width:140px;align-self:center;vertical-align:middle;font-weight:400;user-select:none;}.pie-toggle-correct-answer.svelte-6wlbb4:hover .pie-correct-answer-toggle-label:where(.svelte-6wlbb4),\n .pie-toggle-correct-answer.svelte-6wlbb4:focus-visible .pie-correct-answer-toggle-label:where(.svelte-6wlbb4) {text-decoration:underline;}.template-line.svelte-6wlbb4 {white-space:pre-wrap;margin-bottom:1rem;}.template-line.svelte-6wlbb4 p {margin:0;display:inline;}.pie-choices-fieldset.svelte-6wlbb4 {border:0;padding:0;margin:0;}.pie-choices.svelte-6wlbb4 {display:flex;}.choices-horizontal.svelte-6wlbb4 {flex-direction:row;flex-wrap:wrap;align-items:flex-start;justify-content:center;}.choices-vertical.svelte-6wlbb4 {flex-direction:column;}.layout-audio_blank_only.svelte-6wlbb4 .pie-audio-container,\n .layout-stimulus_image_blank.svelte-6wlbb4 .pie-audio-container {display:flex;width:min(100%, var(--mpb-audio-instructions-max-width, 875px));margin-left:auto;margin-right:auto;justify-content:flex-end;}.layout-audio_blank_only.svelte-6wlbb4 .template-line:where(.svelte-6wlbb4),\n .layout-stimulus_image_blank.svelte-6wlbb4 .template-line:where(.svelte-6wlbb4) {text-align:center;margin:var(--mpb-audio-blank-template-margin-top, 0.8rem) 0\n var(--mpb-audio-blank-template-margin-bottom, 1.8rem);}.layout-audio_blank_only.svelte-6wlbb4 fieldset:where(.svelte-6wlbb4) {display:flex;justify-content:center;}.layout-audio_blank_only.svelte-6wlbb4 .pie-blank-slot,\n .layout-stimulus_image_blank.svelte-6wlbb4 .pie-blank-slot {width:var(--mpb-blank-wide-width, 10rem);border-bottom-width:var(--mpb-blank-underline-wide-width, 6px);min-height:160px;padding-bottom:4px;}.layout-stimulus_image_blank.svelte-6wlbb4 {display:grid;grid-template-columns:minmax(var(--mpb-stimulus-min-column, 210px), 1fr) auto;grid-template-areas:'sentence audio'\n '. template'\n 'choices choices';column-gap:var(--mpb-stimulus-grid-column-gap, 2rem);row-gap:var(--mpb-stimulus-grid-row-gap, 0.7rem);align-items:start;}.layout-stimulus_image_blank.svelte-6wlbb4 .pie-audio-container {grid-area:audio;margin:0;}.layout-stimulus_image_blank.svelte-6wlbb4 .sentence-line:where(.svelte-6wlbb4) {grid-area:sentence;margin:var(--mpb-stimulus-sentence-margin-top, 0.2rem) 0 0;}.layout-stimulus_image_blank.svelte-6wlbb4 .template-line:where(.svelte-6wlbb4) {grid-area:template;margin:0;text-align:center;justify-self:center;}.layout-stimulus_image_blank.svelte-6wlbb4 fieldset:where(.svelte-6wlbb4) {grid-area:choices;margin-top:var(--mpb-stimulus-choices-margin-top, 0.9rem);}.layout-token_sequence.svelte-6wlbb4 {display:grid;grid-template-columns:1fr auto;grid-template-areas:'audio audio'\n 'template template'\n 'choices choices';column-gap:var(--mpb-token-grid-column-gap, 1.5rem);row-gap:var(--mpb-token-grid-row-gap, 0.8rem);align-items:start;}.layout-token_sequence.svelte-6wlbb4 .pie-audio-container {grid-area:audio;margin:0;justify-self:end;}.layout-token_sequence.svelte-6wlbb4 .template-line:where(.svelte-6wlbb4) {grid-area:template;margin:var(--mpb-token-template-margin-top, 0.6rem) 0 0;justify-self:center;text-align:center;}.layout-token_sequence.svelte-6wlbb4 .template-line:where(.svelte-6wlbb4) span + span {margin-left:var(--mpb-token-inline-token-gap, 0.35rem);}.layout-token_sequence.svelte-6wlbb4 .pie-blank-slot {width:var(--mpb-blank-standalone-width, 7rem);border-bottom-width:var(--mpb-blank-underline-wide-width, 4px);margin-left:var(--mpb-token-inline-token-gap, 0.35rem);}.layout-token_sequence.svelte-6wlbb4 fieldset:where(.svelte-6wlbb4) {grid-area:choices;margin-top:var(--mpb-token-choices-margin-top, 0.2rem);}.layout-inline_sentence.has-inline-audio.svelte-6wlbb4 {display:grid;grid-template-columns:minmax(var(--mpb-text-min-column, 260px), 1fr) auto;grid-template-areas:'template audio'\n 'choices choices';column-gap:var(--mpb-inline-grid-column-gap, 1.5rem);row-gap:var(--mpb-inline-grid-row-gap, 0.65rem);align-items:start;}.layout-inline_sentence.has-inline-audio.svelte-6wlbb4 .pie-audio-container {grid-area:audio;margin:0;justify-self:end;}.layout-inline_sentence.has-inline-audio.svelte-6wlbb4 .template-line:where(.svelte-6wlbb4) {grid-area:template;margin:var(--mpb-inline-template-margin-top, 0.45rem) 0 0;text-align:center;justify-self:center;}.layout-inline_sentence.has-inline-audio.svelte-6wlbb4 fieldset:where(.svelte-6wlbb4) {grid-area:choices;margin-top:var(--mpb-inline-choices-margin-top, 0.25rem);}\n\n /* Match Learnosity responsive behavior for CQT audio-blank layouts:\n at smaller widths, audio control shifts left and answer tiles stack. */\n @media (max-width: 760px) {.layout-audio_blank_only.svelte-6wlbb4 .pie-audio-container,\n .layout-stimulus_image_blank.svelte-6wlbb4 .pie-audio-container,\n .layout-token_sequence.svelte-6wlbb4 .pie-audio-container,\n .layout-inline_sentence.has-inline-audio.svelte-6wlbb4 .pie-audio-container {width:100%;margin-left:0;margin-right:0;justify-content:flex-start;justify-self:start;}.layout-audio_blank_only.svelte-6wlbb4 .pie-choices:where(.svelte-6wlbb4),\n .layout-token_sequence.svelte-6wlbb4 .pie-choices:where(.svelte-6wlbb4),\n .layout-stimulus_image_blank.svelte-6wlbb4 .pie-choices:where(.svelte-6wlbb4),\n .layout-inline_sentence.has-inline-audio.svelte-6wlbb4 .pie-choices:where(.svelte-6wlbb4) {flex-direction:column;align-items:flex-start;justify-content:flex-start;}.layout-audio_blank_only.svelte-6wlbb4 .choice-row-horizontal:where(.svelte-6wlbb4),\n .layout-token_sequence.svelte-6wlbb4 .choice-row-horizontal:where(.svelte-6wlbb4),\n .layout-stimulus_image_blank.svelte-6wlbb4 .choice-row-horizontal:where(.svelte-6wlbb4),\n .layout-inline_sentence.has-inline-audio.svelte-6wlbb4 .choice-row-horizontal:where(.svelte-6wlbb4) {width:min(100%, var(--mpb-narrow-choice-max-width, 230px));align-items:flex-start;}\n }"
772
+ };
773
+ function tt(e, n) {
774
+ a(n, !0), A(e, et);
775
+ let d = T(n, "model", 7), p = T(n, "session", 7), b = (e) => I(e, d()?.language), E = s(""), O = s(null), k = s(null), j = s(null), N = `mc-populated-blank-${Math.random().toString(36).slice(2, 10)}`, P = u(() => (d()?.mode || d()?.env?.mode || "").toString()), L = u(() => t(P) === "evaluate"), R = u(() => d()?.correctness), z = u(() => typeof d()?.responseCorrect == "boolean" ? d().responseCorrect : t(R) === "correct"), B = u(() => t(R) === "correct"), V = u(() => t(R) === "incorrect"), H = s(!1), U = u(() => t(L) && !t(z) && !!d()?.correctChoiceId), W = u(() => d()?.layoutProfile || ""), G = u(() => Oe({
776
+ interactionMode: d()?.interactionMode,
777
+ template: d()?.template,
778
+ choiceLayout: d()?.choiceLayout,
779
+ layoutProfile: t(W),
780
+ hasAudio: d()?.hasAudio,
781
+ useFeatureButtonAudio: d()?.useFeatureButtonAudio
782
+ })), te = u(() => t(G).isAudioOnlyMode), re = u(() => t(G).isBlankOnlyTemplate), ie = u(() => t(G).isHorizontalChoices), ae = u(() => t(G).hasInlineSentenceAudioLayout), oe = u(() => t(G).useFeatureButtonAudio), K = u(() => Ae({
783
+ layoutProfile: t(W),
784
+ isBlankOnlyTemplate: t(re),
785
+ configuredLimits: d()?.layoutLimits,
786
+ customProfilePresets: d()?.layoutProfilePresets
787
+ })), se = u(() => Array.isArray(d()?.choices) ? d().choices : []), ce = u(() => d()?.choiceMode || "text"), q = u(() => p()?.choiceId || t(E) || ""), ue = u(() => `${N}-choice-group-${d()?.id || "1"}`), de = u(() => Me({
788
+ selectedId: t(q),
789
+ isEvaluateMode: t(L),
790
+ showCorrectAnswer: t(H),
791
+ correctChoiceId: String(d()?.correctChoiceId || "")
792
+ })), fe = u(() => t(se).find((e) => e.id === t(de))), pe = u(() => String(t(fe)?.labelHtml || "")), he = u(() => Ne({
793
+ isEvaluateMode: t(L),
794
+ showCorrectAnswer: t(H),
795
+ isCorrect: t(B),
796
+ isIncorrect: t(V),
797
+ selectedId: t(q)
798
+ })), J = u(() => t(he) === "correct" ? b("correctAnswerSelected") : t(he) === "incorrect" ? b("incorrectAnswerSelected") : ""), ge = u(() => Te({
799
+ isEvaluateMode: t(L),
800
+ correctChoiceId: String(d()?.correctChoiceId || ""),
801
+ selectedId: String(t(q) || ""),
802
+ showCorrectAnswer: t(H)
803
+ })), Y = u(() => `${N}-prompt`), _e = u(() => `${N}-choices-legend`), ve = u(() => `${N}-result`), ye = u(() => `${N}-blank-hint`), be = u(() => Pe({
804
+ prompt: d()?.prompt || "",
805
+ legendMaxChars: t(K).legendMaxChars,
806
+ answerChoicesLabel: b("answerChoices")
807
+ })), Se = u(() => d()?.prompt ? t(Y) : void 0), Ce = u(() => d()?.prompt ? void 0 : String(d()?.choiceGroupLabel || "").trim() || t(be)), Ee = u(() => d()?.prompt ? t(Y) : void 0), De = u(() => {
808
+ let e = String(d()?.language || d()?.locale || "").trim();
809
+ return e ? e.replace(/_/g, "-") : void 0;
810
+ }), X = u(() => Re(d()?.customType)), ke = u(() => ze(d()?.customType)), Z = u(() => {
811
+ let e = d()?.template || "", n = e.indexOf("{{blank}}");
812
+ if (n < 0) return {
813
+ before: e,
814
+ after: ""
815
+ };
816
+ let r = e.slice(0, n), i = e.slice(n + 9);
817
+ return t(W) === "inline_sentence" && (r = `${r.replace(/\s+$/, "")} `, i = ` ${i.replace(/^\s+/, "")}`), {
818
+ before: r,
819
+ after: i
820
+ };
821
+ });
822
+ function Fe(e, t) {
823
+ ne({
824
+ sourceEl: t,
825
+ session: e,
826
+ complete: !!e?.choiceId
827
+ });
828
+ }
829
+ function Ie(e) {
830
+ let t = e.target;
831
+ if (!t.checked) return;
832
+ let n = t.value;
833
+ x(E, n, !0), Fe({
834
+ ...p(),
835
+ choiceId: n
836
+ }, t);
837
+ }
838
+ function Le() {
839
+ t(U) && x(H, !t(H));
840
+ }
841
+ f(() => {
842
+ (!t(L) || t(z)) && x(H, !1);
843
+ });
844
+ function Be(e) {
845
+ if (d()?.disabled) return;
846
+ let t = e.key;
847
+ if (![
848
+ "ArrowDown",
849
+ "ArrowRight",
850
+ "ArrowUp",
851
+ "ArrowLeft"
852
+ ].includes(t)) return;
853
+ e.preventDefault();
854
+ let n = e.currentTarget, r = Array.from(n.querySelectorAll("input[type=\"radio\"]:not([disabled])"));
855
+ if (r.length === 0) return;
856
+ let i = r.findIndex((e) => e.checked);
857
+ i = t === "ArrowDown" || t === "ArrowRight" ? i < 0 ? 0 : (i + 1) % r.length : i < 0 ? r.length - 1 : (i - 1 + r.length) % r.length;
858
+ let a = r[i];
859
+ a.checked = !0, a.dispatchEvent(new Event("change", { bubbles: !0 })), a.focus();
860
+ }
861
+ let Ve = u(() => je({
862
+ locale: d()?.locale,
863
+ audioButtonSkin: d()?.audioButtonSkin,
864
+ audioButtonSkinsByLocale: d()?.audioButtonSkinsByLocale
865
+ }));
866
+ function Ue() {
867
+ ee(t(j))?.onAudioStarted?.();
868
+ }
869
+ function We() {
870
+ ee(t(j))?.onAudioEnded?.();
871
+ }
872
+ f(() => {
873
+ x(E, p()?.choiceId || "", !0);
874
+ }), f(() => {
875
+ let e = t(O);
876
+ if (e) return e.addEventListener("click", Le), () => e.removeEventListener("click", Le);
877
+ }), f(() => {
878
+ let e = t(k);
879
+ if (!e) return;
880
+ let n = (e) => {
881
+ e.target?.type === "radio" && Ie(e);
882
+ }, r = (e) => Be(e);
883
+ return e.addEventListener("change", n), e.addEventListener("keydown", r), () => {
884
+ e.removeEventListener("change", n), e.removeEventListener("keydown", r);
885
+ };
886
+ }), f(() => {
887
+ t(j) && Ge(t(X), t(j));
888
+ });
889
+ var tt = {
890
+ get model() {
891
+ return d();
892
+ },
893
+ set model(e) {
894
+ d(e), c();
895
+ },
896
+ get session() {
897
+ return p();
898
+ },
899
+ set session(e) {
900
+ p(e), c();
901
+ }
902
+ }, Q = $e(), nt = r(Q), rt = (e) => {
903
+ {
904
+ let n = u(() => d()?.language);
905
+ we(e, {
906
+ get html() {
907
+ return d().teacherInstructions;
908
+ },
909
+ get language() {
910
+ return t(n);
911
+ }
912
+ });
913
+ }
914
+ };
915
+ w(nt, (e) => {
916
+ d()?.teacherInstructions && e(rt);
917
+ });
918
+ var it = S(nt, 2), at = (e) => {
919
+ var n = Ke();
920
+ g(n, () => d().prompt, !0), o(n), M(() => m(n, "id", t(Y))), v(e, n);
921
+ };
922
+ w(it, (e) => {
923
+ d()?.prompt && e(at);
924
+ });
925
+ var ot = S(it, 2), st = (e) => {
926
+ var n = Ye(), i = r(n), a = r(i), s = r(a), c = r(s), u = (e) => {
927
+ v(e, qe());
928
+ }, f = (e) => {
929
+ v(e, Je());
930
+ };
931
+ w(c, (e) => {
932
+ t(H) ? e(u) : e(f, -1);
933
+ }), o(s);
934
+ var p = l(S(s, 2), !0);
935
+ o(a), o(i), D(i, (e) => x(O, e), () => t(O)), o(n), M((e) => {
936
+ m(i, "aria-pressed", t(H)), y(p, e);
937
+ }, [() => F(t(H) ? "hideCorrectAnswer" : "showCorrectAnswer", d()?.language)]), v(e, n);
938
+ };
939
+ w(ot, (e) => {
940
+ t(U) && e(st);
941
+ });
942
+ var ct = S(ot, 2);
943
+ {
944
+ let e = u(() => !!d()?.hasAudio), n = u(() => d()?.audioUrl), r = u(() => !!d()?.autoplayAudioEnabled), i = u(() => d()?.language);
945
+ le(ct, {
946
+ get hasAudio() {
947
+ return t(e);
948
+ },
949
+ get audioUrl() {
950
+ return t(n);
951
+ },
952
+ get useFeatureButtonAudio() {
953
+ return t(oe);
954
+ },
955
+ get autoplayEnabled() {
956
+ return t(r);
957
+ },
958
+ get featureAudioSkin() {
959
+ return t(Ve);
960
+ },
961
+ get language() {
962
+ return t(i);
963
+ },
964
+ onaudiostarted: Ue,
965
+ onaudioended: We
966
+ });
967
+ }
968
+ var lt = S(ct, 2), ut = (e) => {
969
+ var n = Xe();
970
+ g(n, () => d().sentenceHtml, !0), o(n), M(() => m(n, "aria-describedby", t(Ee))), v(e, n);
971
+ };
972
+ w(lt, (e) => {
973
+ d()?.sentenceHtml && e(ut);
974
+ });
975
+ var dt = S(lt, 2), ft = (e) => {
976
+ var n = Ze(), i = r(n);
977
+ g(i, () => t(Z).before);
978
+ var a = S(i);
979
+ {
980
+ let e = u(() => b("blankLabel")), n = u(() => d()?.language);
981
+ me(a, {
982
+ get choiceMode() {
983
+ return t(ce);
984
+ },
985
+ get displayChoice() {
986
+ return t(fe);
987
+ },
988
+ get displayChoiceLabelHtml() {
989
+ return t(pe);
990
+ },
991
+ get isStandalone() {
992
+ return t(re);
993
+ },
994
+ get blankWidth() {
995
+ return t(K).blankWidth;
996
+ },
997
+ get blankBorderWidth() {
998
+ return t(K).blankBorderWidth;
999
+ },
1000
+ get ariaLabel() {
1001
+ return t(e);
1002
+ },
1003
+ get language() {
1004
+ return t(n);
1005
+ }
1006
+ });
1007
+ }
1008
+ g(S(a), () => t(Z).after), o(n), M(() => m(n, "aria-describedby", t(Ee))), v(e, n);
1009
+ };
1010
+ w(dt, (e) => {
1011
+ t(te) || e(ft);
1012
+ });
1013
+ var pt = S(dt, 2), mt = (e) => {
1014
+ var n = Qe(), r = l(n, !0);
1015
+ M(() => {
1016
+ m(n, "id", t(ve)), y(r, t(J));
1017
+ }), v(e, n);
1018
+ };
1019
+ w(pt, (e) => {
1020
+ t(J) && e(mt);
1021
+ });
1022
+ var ht = S(pt, 2), gt = l(ht, !0), _t = S(ht, 2), vt = r(_t), yt = l(vt, !0), $ = S(vt, 2);
1023
+ return _($, 21, () => t(se), (e) => e.id, (e, n) => {
1024
+ {
1025
+ let r = u(() => t(de) === t(n).id), i = u(() => !!d()?.disabled), a = u(() => t(ge).get(t(n).id)), o = u(() => d()?.language);
1026
+ xe(e, {
1027
+ get choice() {
1028
+ return t(n);
1029
+ },
1030
+ get choiceMode() {
1031
+ return t(ce);
1032
+ },
1033
+ get isHorizontal() {
1034
+ return t(ie);
1035
+ },
1036
+ get isSelected() {
1037
+ return t(r);
1038
+ },
1039
+ get isDisabled() {
1040
+ return t(i);
1041
+ },
1042
+ get correctness() {
1043
+ return t(a);
1044
+ },
1045
+ get isEvaluateMode() {
1046
+ return t(L);
1047
+ },
1048
+ get instanceId() {
1049
+ return N;
1050
+ },
1051
+ get radioGroupName() {
1052
+ return t(ue);
1053
+ },
1054
+ get language() {
1055
+ return t(o);
1056
+ }
1057
+ });
1058
+ }
1059
+ }), o($), D($, (e) => x(k, e), () => t(k)), o(_t), o(Q), D(Q, (e) => x(j, e), () => t(j)), M((e, n) => {
1060
+ C(Q, 1, `mc-populated-blank-root pie-element pie-element-mc-populated-blank pie-delivery-root layout-${t(W)} ${t(ke)} ${t(ae) ? "has-inline-audio" : ""}`, "svelte-6wlbb4"), m(Q, "lang", t(De)), h(Q, t(K).rootStyle), m(Q, "data-mpb-css", He), m(ht, "id", t(ye)), y(gt, e), _t.disabled = d()?.disabled, m(vt, "id", t(_e)), y(yt, t(be)), C($, 1, `pie-choices ${t(ie) ? "choices-horizontal" : "choices-vertical"}`, "svelte-6wlbb4"), m($, "aria-labelledby", t(Se)), m($, "aria-label", t(Ce)), m($, "aria-describedby", n);
1061
+ }, [() => b("blankPreSelectionHint"), () => [t(ye), t(J) ? t(ve) : void 0].filter(Boolean).join(" ")]), v(e, Q), i(tt);
1062
+ }
1063
+ k(tt, {
1064
+ model: { type: "Object" },
1065
+ session: { type: "Object" },
1066
+ options: { type: "Object" }
1067
+ }, [], []);
1068
+ //#endregion
1069
+ //#region src/delivery/index.ts
1070
+ function Q(e, t, n = !1) {
1071
+ return !(!t?.choiceId || e?.autoplayAudioEnabled && e?.completeAudioEnabled && e?.hasAudio && !n);
1072
+ }
1073
+ var nt = tt.element, rt = class extends nt {
1074
+ _internalSession = null;
1075
+ _playerSession = null;
1076
+ _model = null;
1077
+ _options = null;
1078
+ audioComplete = !1;
1079
+ _dispatchModelSet = () => {
1080
+ this.dispatchEvent(new R(this.tagName.toLowerCase(), this._isComplete(), this._model !== void 0));
1081
+ };
1082
+ _dispatchSessionChanged = () => {
1083
+ this.dispatchEvent(new z(this.tagName.toLowerCase(), this._isComplete()));
1084
+ };
1085
+ set model(e) {
1086
+ e?.audioUrl !== this._model?.audioUrl && (this.audioComplete = !1), this._model = e, super.model = e, this._dispatchModelSet();
1087
+ }
1088
+ get model() {
1089
+ return this._model;
1090
+ }
1091
+ set session(e) {
1092
+ this._playerSession = e, this._internalSession = e, super.session = e, this._dispatchSessionChanged();
1093
+ }
1094
+ get session() {
1095
+ return this._internalSession;
1096
+ }
1097
+ set options(e) {
1098
+ this._options = e, super.options = e;
1099
+ }
1100
+ get options() {
1101
+ return this._options;
1102
+ }
1103
+ onSessionChange = (e) => {
1104
+ this._writeSession(e), this._dispatchSessionChanged();
1105
+ };
1106
+ onAudioStarted = () => {
1107
+ this._writeAudioTiming({ audioStartTime: Date.now() });
1108
+ };
1109
+ onAudioEnded = () => {
1110
+ this.audioComplete = !0, this._writeAudioTiming({ audioEndTime: Date.now() }), this._dispatchSessionChanged();
1111
+ };
1112
+ _writeAudioTiming = (e) => {
1113
+ let t = this._internalSession || {}, n = t.audioStartTime || e.audioStartTime, r = t.audioEndTime || e.audioEndTime, i = {
1114
+ ...t,
1115
+ ...n ? { audioStartTime: n } : {},
1116
+ ...r ? { audioEndTime: r } : {}
1117
+ };
1118
+ !i.waitTime && n && r && (i.waitTime = r - n), this._writeSession(i);
1119
+ };
1120
+ _writeSession = (e) => {
1121
+ U(this._playerSession, e), this._internalSession = e, super.session = e;
1122
+ };
1123
+ _isComplete = () => Q(this._model, this._internalSession, this.audioComplete);
1124
+ connectedCallback() {
1125
+ super.connectedCallback(), this.onSessionChange = this.onSessionChange, this.onAudioStarted = this.onAudioStarted, this.onAudioEnded = this.onAudioEnded;
1126
+ }
1127
+ };
1128
+ //#endregion
1129
+ export { rt as default };
1130
+
1131
+ //# sourceMappingURL=index.js.map