@pie-element/mc-populated-blank 0.3.0-next.5 → 0.3.0-next.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/browser/controller/index.js +2 -2
- package/dist/browser/controller/index.js.map +1 -1
- package/dist/browser/delivery/index.js +211 -211
- package/dist/browser/delivery/index.js.map +1 -1
- package/dist/browser/{layoutLimits-ATKOwLHb.js → layoutLimits-Bp17YP2V.js} +3 -3
- package/dist/browser/layoutLimits-Bp17YP2V.js.map +1 -0
- package/dist/controller/defaults.d.ts +1 -1
- package/dist/controller/index.d.ts +2 -2
- package/dist/controller/index.js +3 -3
- package/dist/controller/index.js.map +1 -1
- package/dist/delivery/index.js +18 -17
- package/dist/delivery/index.js.map +1 -1
- package/dist/index.iife.d.ts +2 -2
- package/dist/index.iife.js +78 -6
- package/dist/index.js +18 -17
- package/dist/index.js.map +1 -1
- package/dist/shared/layoutLimits.d.ts +1 -1
- package/package.json +7 -2
- package/print.js +2 -0
- package/dist/browser/layoutLimits-ATKOwLHb.js.map +0 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { A as e, C as t, D as n, E as r, F as i, M as a, N as o, O as s, P as c, S as l, T as u, _ as d, a as f, c as p, d as m, f as h, g, h as _, i as v, j as y, k as b, l as x, m as S, n as C, o as w, r as T, s as E, t as D, u as
|
|
2
|
-
import { t as
|
|
1
|
+
import { A as e, C as t, D as n, E as r, F as i, M as a, N as o, O as s, P as c, S as l, T as u, _ as d, a as f, c as p, d as m, f as h, g, h as _, i as v, j as y, k as b, l as x, m as S, n as C, o as w, r as T, s as E, t as D, u as ee, v as O, w as k, x as A, y as j } from "../client-BmZWrsT3.js";
|
|
2
|
+
import { t as M } from "../layoutLimits-Bp17YP2V.js";
|
|
3
3
|
//#region ../../lib-svelte/delivery-events/dist/index2.js
|
|
4
|
-
var
|
|
4
|
+
var N = class e extends CustomEvent {
|
|
5
5
|
static {
|
|
6
6
|
this.TYPE = "model-set";
|
|
7
7
|
}
|
|
@@ -16,7 +16,7 @@ var P = class e extends CustomEvent {
|
|
|
16
16
|
}
|
|
17
17
|
}), this.component = t, this.complete = n;
|
|
18
18
|
}
|
|
19
|
-
},
|
|
19
|
+
}, P = class e extends CustomEvent {
|
|
20
20
|
static {
|
|
21
21
|
this.TYPE = "session-changed";
|
|
22
22
|
}
|
|
@@ -30,12 +30,12 @@ var P = class e extends CustomEvent {
|
|
|
30
30
|
}
|
|
31
31
|
}), this.component = t, this.complete = n;
|
|
32
32
|
}
|
|
33
|
-
},
|
|
33
|
+
}, F = (e) => {
|
|
34
34
|
let t = e;
|
|
35
35
|
return t ? typeof t.onSessionChange == "function" || typeof t.onAudioStarted == "function" || typeof t.onAudioEnded == "function" : !1;
|
|
36
36
|
};
|
|
37
|
-
function
|
|
38
|
-
let n = t.hostPredicate ??
|
|
37
|
+
function I(e, t = {}) {
|
|
38
|
+
let n = t.hostPredicate ?? F, r = e;
|
|
39
39
|
for (; r;) {
|
|
40
40
|
if (n(r)) return r;
|
|
41
41
|
r = r.parentElement;
|
|
@@ -46,9 +46,9 @@ function L(e, t = {}) {
|
|
|
46
46
|
}
|
|
47
47
|
return null;
|
|
48
48
|
}
|
|
49
|
-
function
|
|
50
|
-
let a =
|
|
51
|
-
return a ? typeof a.onSessionChange == "function" ? (a.onSessionChange(i), a) : (a.dispatchEvent(new
|
|
49
|
+
function L({ sourceEl: e, fallbackSelector: t, component: n, complete: r, session: i }) {
|
|
50
|
+
let a = I(e, { fallbackSelector: t });
|
|
51
|
+
return a ? typeof a.onSessionChange == "function" ? (a.onSessionChange(i), a) : (a.dispatchEvent(new P(n, r)), a) : null;
|
|
52
52
|
}
|
|
53
53
|
//#endregion
|
|
54
54
|
//#region src/delivery/computeAudioMode.ts
|
|
@@ -57,58 +57,58 @@ function te(e) {
|
|
|
57
57
|
}
|
|
58
58
|
//#endregion
|
|
59
59
|
//#region src/delivery/AudioPlayer.svelte
|
|
60
|
-
var ne =
|
|
60
|
+
var ne = O("<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), re = O("<button class=\"mt-2 text-sm underline pie-audio-autoplay-enable\" type=\"button\"> </button>"), R = O("<audio controls=\"\" class=\"w-full max-w-md pie-audio-player\" preload=\"metadata\"><track kind=\"captions\"/></audio> <!>", 1), ie = O("<p class=\"text-sm text-red-700 pie-audio-error\" role=\"alert\"> </p>"), z = O("<div class=\"mb-4 audio-container pie-audio-container\"><!></div>"), B = {
|
|
61
61
|
hash: "svelte-ypdwb3",
|
|
62
62
|
code: ".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;}"
|
|
63
63
|
};
|
|
64
64
|
function V(p, m) {
|
|
65
|
-
c(m, !0),
|
|
65
|
+
c(m, !0), ee(p, B);
|
|
66
66
|
let h = {
|
|
67
67
|
IDLE: "idle",
|
|
68
68
|
PLAYING: "playing",
|
|
69
69
|
BLOCKED: "blocked",
|
|
70
70
|
PAUSED: "paused"
|
|
71
|
-
}, v = C(m, "hasAudio", 7, !1), w = C(m, "audioUrl", 7), E = C(m, "useFeatureButtonAudio", 7, !1), D = C(m, "autoplayEnabled", 7, !1),
|
|
71
|
+
}, v = C(m, "hasAudio", 7, !1), w = C(m, "audioUrl", 7), E = C(m, "useFeatureButtonAudio", 7, !1), D = C(m, "autoplayEnabled", 7, !1), O = C(m, "featureAudioSkin", 7), j = C(m, "uiText", 7), M = C(m, "locale", 7, ""), N = C(m, "onaudiostarted", 7), P = C(m, "onaudioended", 7), F = e(null), I = e(null), L = e(null), V = e(s(h.IDLE)), H = a(() => te({
|
|
72
72
|
hasAudio: v(),
|
|
73
73
|
audioUrl: w(),
|
|
74
74
|
useFeatureButtonAudio: E()
|
|
75
|
-
})), U = a(() =>
|
|
75
|
+
})), U = a(() => A(V) === h.PLAYING), W = a(() => A(V) === h.BLOCKED), ae = a(() => A(H) === "error" ? j().audioResourceUnavailable : "");
|
|
76
76
|
t(() => {
|
|
77
77
|
w(), b(V, h.IDLE, !0);
|
|
78
78
|
});
|
|
79
|
-
function
|
|
80
|
-
|
|
79
|
+
function oe() {
|
|
80
|
+
A(H) !== "none" && A(H) !== "error" && A(F) && A(F).play().catch(() => {});
|
|
81
81
|
}
|
|
82
|
-
function
|
|
83
|
-
|
|
84
|
-
|
|
82
|
+
function se() {
|
|
83
|
+
A(H) !== "none" && A(H) !== "error" && A(F) && A(F).play().finally(() => {
|
|
84
|
+
A(V) === h.BLOCKED && b(V, h.PAUSED, !0);
|
|
85
85
|
});
|
|
86
86
|
}
|
|
87
|
-
function
|
|
87
|
+
function G(e, n, r) {
|
|
88
88
|
t(() => {
|
|
89
89
|
let t = e();
|
|
90
90
|
if (t) return t.addEventListener(n, r), () => t.removeEventListener(n, r);
|
|
91
91
|
});
|
|
92
92
|
}
|
|
93
|
-
|
|
94
|
-
b(V, h.PLAYING, !0),
|
|
95
|
-
}),
|
|
96
|
-
b(V, h.PAUSED, !0),
|
|
97
|
-
}),
|
|
98
|
-
!D() ||
|
|
93
|
+
G(() => A(F), "playing", () => {
|
|
94
|
+
b(V, h.PLAYING, !0), N()?.();
|
|
95
|
+
}), G(() => A(F), "ended", () => {
|
|
96
|
+
b(V, h.PAUSED, !0), P()?.();
|
|
97
|
+
}), G(() => A(I), "click", () => oe()), G(() => A(L), "click", () => se()), t(() => {
|
|
98
|
+
!D() || A(H) === "none" || A(H) === "error" || A(V) === h.IDLE && A(F) && w() && (b(V, h.PAUSED, !0), A(F).play().catch(() => {
|
|
99
99
|
b(V, h.BLOCKED, !0);
|
|
100
100
|
}));
|
|
101
101
|
});
|
|
102
|
-
function
|
|
102
|
+
function K(e = "") {
|
|
103
103
|
return e.toLowerCase().startsWith("es") ? "Escuchar" : "Listen";
|
|
104
104
|
}
|
|
105
|
-
function
|
|
106
|
-
return e.toLowerCase().startsWith("es") ?
|
|
105
|
+
function q(e = "") {
|
|
106
|
+
return e.toLowerCase().startsWith("es") ? j().listenSilentAltEs ?? "Escuchar. Repetir las instrucciones." : j().listenSilentAlt ?? "Repeat instructions";
|
|
107
107
|
}
|
|
108
|
-
function
|
|
109
|
-
return e.toLowerCase().startsWith("es") ?
|
|
108
|
+
function J(e = "") {
|
|
109
|
+
return e.toLowerCase().startsWith("es") ? j().listenPlayingAltEs ?? "Escuchar. Estas son las instrucciones." : j().listenPlayingAlt ?? "Instructions are playing";
|
|
110
110
|
}
|
|
111
|
-
var
|
|
111
|
+
var ce = {
|
|
112
112
|
get hasAudio() {
|
|
113
113
|
return v();
|
|
114
114
|
},
|
|
@@ -134,68 +134,68 @@ function V(p, m) {
|
|
|
134
134
|
D(e), y();
|
|
135
135
|
},
|
|
136
136
|
get featureAudioSkin() {
|
|
137
|
-
return
|
|
137
|
+
return O();
|
|
138
138
|
},
|
|
139
139
|
set featureAudioSkin(e) {
|
|
140
|
-
|
|
140
|
+
O(e), y();
|
|
141
141
|
},
|
|
142
142
|
get uiText() {
|
|
143
|
-
return
|
|
143
|
+
return j();
|
|
144
144
|
},
|
|
145
145
|
set uiText(e) {
|
|
146
|
-
|
|
146
|
+
j(e), y();
|
|
147
147
|
},
|
|
148
148
|
get locale() {
|
|
149
|
-
return
|
|
149
|
+
return M();
|
|
150
150
|
},
|
|
151
151
|
set locale(e = "") {
|
|
152
|
-
|
|
152
|
+
M(e), y();
|
|
153
153
|
},
|
|
154
154
|
get onaudiostarted() {
|
|
155
|
-
return
|
|
155
|
+
return N();
|
|
156
156
|
},
|
|
157
157
|
set onaudiostarted(e) {
|
|
158
|
-
|
|
158
|
+
N(e), y();
|
|
159
159
|
},
|
|
160
160
|
get onaudioended() {
|
|
161
|
-
return
|
|
161
|
+
return P();
|
|
162
162
|
},
|
|
163
163
|
set onaudioended(e) {
|
|
164
|
-
|
|
164
|
+
P(e), y();
|
|
165
165
|
}
|
|
166
|
-
},
|
|
167
|
-
var t = z(), a =
|
|
166
|
+
}, Y = d(), X = u(Y), le = (e) => {
|
|
167
|
+
var t = z(), a = k(t), o = (e) => {
|
|
168
168
|
var t = ne(), r = u(t);
|
|
169
|
-
T(r, (e) => b(
|
|
170
|
-
var a = n(r, 2), o =
|
|
171
|
-
i(a), T(a, (e) => b(
|
|
172
|
-
f(r, "src", w()), f(a, "aria-label", e), x(o, 1, `listen-feature-icon pie-listen-icon rli-feature-listen ${
|
|
169
|
+
T(r, (e) => b(F, e), () => A(F));
|
|
170
|
+
var a = n(r, 2), o = k(a), s = n(o, 2);
|
|
171
|
+
i(a), T(a, (e) => b(I, e), () => A(I)), l((e, t, n) => {
|
|
172
|
+
f(r, "src", w()), f(a, "aria-label", e), x(o, 1, `listen-feature-icon pie-listen-icon rli-feature-listen ${A(U) ? "" : "listen-active"}`, "svelte-ypdwb3"), f(o, "src", O().silentUrl), f(o, "alt", t), x(s, 1, `listen-feature-icon pie-listen-icon rli-feature-listen ${A(U) ? "listen-active" : ""}`, "svelte-ypdwb3"), f(s, "src", O().playingUrl), f(s, "alt", n);
|
|
173
173
|
}, [
|
|
174
|
-
() =>
|
|
175
|
-
() =>
|
|
176
|
-
() =>
|
|
174
|
+
() => K(M()),
|
|
175
|
+
() => q(M()),
|
|
176
|
+
() => J(M())
|
|
177
177
|
]), g(e, t);
|
|
178
178
|
}, s = (e) => {
|
|
179
179
|
var t = R(), i = u(t);
|
|
180
|
-
T(i, (e) => b(
|
|
180
|
+
T(i, (e) => b(F, e), () => A(F));
|
|
181
181
|
var a = n(i, 2), o = (e) => {
|
|
182
182
|
var t = re(), n = r(t, !0);
|
|
183
|
-
T(t, (e) => b(
|
|
183
|
+
T(t, (e) => b(L, e), () => A(L)), l(() => _(n, j().clickToEnableAutoplay)), g(e, t);
|
|
184
184
|
};
|
|
185
185
|
S(a, (e) => {
|
|
186
|
-
|
|
186
|
+
A(W) && e(o);
|
|
187
187
|
}), l(() => f(i, "src", w())), g(e, t);
|
|
188
188
|
}, c = (e) => {
|
|
189
189
|
var t = ie(), n = r(t, !0);
|
|
190
|
-
l(() => _(n,
|
|
190
|
+
l(() => _(n, A(ae))), g(e, t);
|
|
191
191
|
};
|
|
192
192
|
S(a, (e) => {
|
|
193
|
-
|
|
193
|
+
A(H) === "feature-button" ? e(o) : A(H) === "controls" ? e(s, 1) : A(H) === "error" && e(c, 2);
|
|
194
194
|
}), i(t), g(e, t);
|
|
195
195
|
};
|
|
196
|
-
return S(
|
|
197
|
-
|
|
198
|
-
}), g(p,
|
|
196
|
+
return S(X, (e) => {
|
|
197
|
+
A(H) !== "none" && e(le);
|
|
198
|
+
}), g(p, Y), o(ce);
|
|
199
199
|
}
|
|
200
200
|
D(V, {
|
|
201
201
|
hasAudio: {},
|
|
@@ -210,12 +210,12 @@ D(V, {
|
|
|
210
210
|
}, [], [], { mode: "open" });
|
|
211
211
|
//#endregion
|
|
212
212
|
//#region src/delivery/ClozeMarker.svelte
|
|
213
|
-
var H =
|
|
213
|
+
var H = O("<img class=\"w-auto object-contain pie-blank-image\" style=\"max-width:var(--mpb-choice-image-max-width, 9.375rem);max-height:var(--mpb-choice-image-max-height, 9.375rem);\"/>"), U = O("<span class=\"cloze-marker-value pie-blank-value svelte-d9l5tb\"></span>"), W = O("<span class=\"cloze-marker-empty svelte-d9l5tb\"><span aria-hidden=\"true\"> </span> <span class=\"sr-only svelte-d9l5tb\">(blank)</span></span>"), ae = O("<span role=\"status\" aria-live=\"polite\" aria-atomic=\"true\"><!></span>"), oe = {
|
|
214
214
|
hash: "svelte-d9l5tb",
|
|
215
|
-
code: ".cloze-marker.svelte-d9l5tb {display:inline-flex;align-items:center;justify-content:center;text-align:center;vertical-align:baseline;}.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-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;}.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;}"
|
|
215
|
+
code: ".cloze-marker.svelte-d9l5tb {display:inline-flex;align-items:center;justify-content:center;text-align:center;vertical-align:baseline;}.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-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;}"
|
|
216
216
|
};
|
|
217
|
-
function
|
|
218
|
-
c(t, !0),
|
|
217
|
+
function se(e, t) {
|
|
218
|
+
c(t, !0), ee(e, oe);
|
|
219
219
|
let n = C(t, "choiceMode", 7, "text"), r = C(t, "displayChoice", 7, void 0), a = C(t, "displayChoiceLabelHtml", 7, ""), s = C(t, "isStandalone", 7, !1), u = C(t, "blankWidth", 7), d = C(t, "blankBorderWidth", 7), h = C(t, "ariaLabel", 7);
|
|
220
220
|
var _ = {
|
|
221
221
|
get choiceMode() {
|
|
@@ -260,7 +260,7 @@ function ce(e, t) {
|
|
|
260
260
|
set ariaLabel(e) {
|
|
261
261
|
h(e), y();
|
|
262
262
|
}
|
|
263
|
-
}, v =
|
|
263
|
+
}, v = ae(), b = k(v), w = (e) => {
|
|
264
264
|
var t = H();
|
|
265
265
|
l(() => {
|
|
266
266
|
f(t, "src", r().imageUrl), f(t, "alt", r().imageAlt || "Selected answer image");
|
|
@@ -269,7 +269,7 @@ function ce(e, t) {
|
|
|
269
269
|
var t = U();
|
|
270
270
|
m(t, a, !0), i(t), g(e, t);
|
|
271
271
|
}, E = (e) => {
|
|
272
|
-
g(e,
|
|
272
|
+
g(e, W());
|
|
273
273
|
};
|
|
274
274
|
return S(b, (e) => {
|
|
275
275
|
n() === "image" && r()?.imageUrl ? e(w) : a() ? e(T, 1) : e(E, -1);
|
|
@@ -277,7 +277,7 @@ function ce(e, t) {
|
|
|
277
277
|
x(v, 1, `inline-flex items-center min-h-[1.5em] px-2 mx-1 border-b-2 border-gray-500 align-baseline cloze-marker pie-blank-slot ${s() ? "cloze-marker-standalone pie-blank-slot-standalone" : ""}`, "svelte-d9l5tb"), p(v, `width:${u()};border-bottom-width:${d()};`), f(v, "aria-label", h());
|
|
278
278
|
}), g(e, v), o(_);
|
|
279
279
|
}
|
|
280
|
-
D(
|
|
280
|
+
D(se, {
|
|
281
281
|
choiceMode: {},
|
|
282
282
|
displayChoice: {},
|
|
283
283
|
displayChoiceLabelHtml: {},
|
|
@@ -288,14 +288,14 @@ D(ce, {
|
|
|
288
288
|
}, [], [], { mode: "open" });
|
|
289
289
|
//#endregion
|
|
290
290
|
//#region src/delivery/ChoiceRow.svelte
|
|
291
|
-
var
|
|
291
|
+
var G = O("<img class=\"object-contain pie-choice-image\" style=\"max-width:var(--mpb-choice-image-max-width, 9.375rem);max-height:var(--mpb-choice-image-max-height, 9.375rem);\"/>"), K = O("<span class=\"choice-html pie-choice-label svelte-8xu1pt\"></span>"), q = O("<label class=\"cursor-pointer choice-tile text-center 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>"), J = O("<img class=\"object-contain pie-choice-image\" style=\"max-height:var(--mpb-choice-image-max-height, 5rem);\"/>"), ce = O("<input type=\"radio\" class=\"choice-radio-inline pie-choice-radio pie-choice-radio-inline svelte-8xu1pt\"/> <label class=\"cursor-pointer flex-1 pie-choice-label-wrap svelte-8xu1pt\"><!></label>", 1), Y = O("<span aria-hidden=\"true\"> </span>"), X = O("<div style=\"gap:var(--mpb-choice-row-gap, 0.5rem);\"><!> <!></div>"), le = {
|
|
292
292
|
hash: "svelte-8xu1pt",
|
|
293
|
-
code: ".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;}.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-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;}.choice-radio-bottom.svelte-8xu1pt {margin-top:var(--mpb-horizontal-choice-radio-top-margin, 0.5rem);padding:var(--mpb-choice-radio-padding, 0px);}.choice-radio-inline.svelte-8xu1pt {margin-top:var(--mpb-horizontal-choice-radio-top-margin, 0.5rem);}"
|
|
293
|
+
code: ".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;}.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-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;}.choice-radio-bottom.svelte-8xu1pt {margin-top:var(--mpb-horizontal-choice-radio-top-margin, 0.5rem);padding:var(--mpb-choice-radio-padding, 0px);}.choice-radio-inline.svelte-8xu1pt {margin-top:var(--mpb-horizontal-choice-radio-top-margin, 0.5rem);}"
|
|
294
294
|
};
|
|
295
|
-
function
|
|
296
|
-
c(t, !0),
|
|
297
|
-
let a = C(t, "choice", 7), s = C(t, "choiceMode", 7, "text"), d = C(t, "isHorizontal", 7, !1), p = C(t, "isSelected", 7, !1), h = C(t, "isDisabled", 7, !1), b = C(t, "correctness", 7, void 0), T = C(t, "isEvaluateMode", 7, !1), D = C(t, "instanceId", 7),
|
|
298
|
-
var
|
|
295
|
+
function ue(e, t) {
|
|
296
|
+
c(t, !0), ee(e, le);
|
|
297
|
+
let a = C(t, "choice", 7), s = C(t, "choiceMode", 7, "text"), d = C(t, "isHorizontal", 7, !1), p = C(t, "isSelected", 7, !1), h = C(t, "isDisabled", 7, !1), b = C(t, "correctness", 7, void 0), T = C(t, "isEvaluateMode", 7, !1), D = C(t, "instanceId", 7), O = C(t, "radioGroupName", 7);
|
|
298
|
+
var A = {
|
|
299
299
|
get choice() {
|
|
300
300
|
return a();
|
|
301
301
|
},
|
|
@@ -345,19 +345,19 @@ function de(e, t) {
|
|
|
345
345
|
D(e), y();
|
|
346
346
|
},
|
|
347
347
|
get radioGroupName() {
|
|
348
|
-
return
|
|
348
|
+
return O();
|
|
349
349
|
},
|
|
350
350
|
set radioGroupName(e) {
|
|
351
|
-
|
|
351
|
+
O(e), y();
|
|
352
352
|
}
|
|
353
|
-
},
|
|
354
|
-
var t =
|
|
355
|
-
var t =
|
|
353
|
+
}, j = X(), M = k(j), N = (e) => {
|
|
354
|
+
var t = q(), r = k(t), o = k(r), c = (e) => {
|
|
355
|
+
var t = G();
|
|
356
356
|
l(() => {
|
|
357
357
|
f(t, "src", a().imageUrl), f(t, "alt", a().imageAlt || `Choice ${a().id}`);
|
|
358
358
|
}), g(e, t);
|
|
359
359
|
}, u = (e) => {
|
|
360
|
-
var t =
|
|
360
|
+
var t = K();
|
|
361
361
|
m(t, () => a().labelHtml || "", !0), i(t), g(e, t);
|
|
362
362
|
};
|
|
363
363
|
S(o, (e) => {
|
|
@@ -365,40 +365,40 @@ function de(e, t) {
|
|
|
365
365
|
}), i(r);
|
|
366
366
|
var d = n(r, 2);
|
|
367
367
|
v(d), i(t), l(() => {
|
|
368
|
-
f(t, "for", `${D()}-opt-${a().id}`), f(d, "name",
|
|
368
|
+
f(t, "for", `${D()}-opt-${a().id}`), f(d, "name", O()), f(d, "id", `${D()}-opt-${a().id}`), E(d, a().id), w(d, p()), d.disabled = h();
|
|
369
369
|
}), g(e, t);
|
|
370
|
-
},
|
|
371
|
-
var t =
|
|
370
|
+
}, P = (e) => {
|
|
371
|
+
var t = ce(), r = u(t);
|
|
372
372
|
v(r);
|
|
373
|
-
var o = n(r, 2), c =
|
|
374
|
-
var t =
|
|
373
|
+
var o = n(r, 2), c = k(o), d = (e) => {
|
|
374
|
+
var t = J();
|
|
375
375
|
l(() => {
|
|
376
376
|
f(t, "src", a().imageUrl), f(t, "alt", a().imageAlt || `Choice ${a().id}`);
|
|
377
377
|
}), g(e, t);
|
|
378
378
|
}, _ = (e) => {
|
|
379
|
-
var t =
|
|
379
|
+
var t = K();
|
|
380
380
|
m(t, () => a().labelHtml || "", !0), i(t), g(e, t);
|
|
381
381
|
};
|
|
382
382
|
S(c, (e) => {
|
|
383
383
|
s() === "image" && a().imageUrl ? e(d) : e(_, -1);
|
|
384
384
|
}), i(o), l(() => {
|
|
385
|
-
f(r, "name",
|
|
385
|
+
f(r, "name", O()), f(r, "id", `${D()}-opt-${a().id}`), E(r, a().id), w(r, p()), r.disabled = h(), f(o, "for", `${D()}-opt-${a().id}`);
|
|
386
386
|
}), g(e, t);
|
|
387
387
|
};
|
|
388
|
-
S(
|
|
389
|
-
d() ? e(
|
|
388
|
+
S(M, (e) => {
|
|
389
|
+
d() ? e(N) : e(P, -1);
|
|
390
390
|
});
|
|
391
|
-
var
|
|
392
|
-
var t =
|
|
391
|
+
var F = n(M, 2), I = (e) => {
|
|
392
|
+
var t = Y(), n = r(t, !0);
|
|
393
393
|
l(() => {
|
|
394
394
|
x(t, 1, `pie-choice-feedback-badge ${b() === "correct" ? "pie-choice-feedback-correct" : "pie-choice-feedback-incorrect"}`, "svelte-8xu1pt"), _(n, b() === "correct" ? "✓" : "✕");
|
|
395
395
|
}), g(e, t);
|
|
396
396
|
};
|
|
397
|
-
return S(
|
|
398
|
-
T() && b() && e(
|
|
399
|
-
}), i(
|
|
397
|
+
return S(F, (e) => {
|
|
398
|
+
T() && b() && e(I);
|
|
399
|
+
}), i(j), l(() => x(j, 1, `flex items-start choice-row pie-choice ${d() ? "choice-row-horizontal pie-choice-horizontal" : ""} ${p() ? "is-selected pie-choice-selected" : ""} ${b() ? `choice-${b()} pie-choice-${b()}` : ""}`, "svelte-8xu1pt")), g(e, j), o(A);
|
|
400
400
|
}
|
|
401
|
-
D(
|
|
401
|
+
D(ue, {
|
|
402
402
|
choice: {},
|
|
403
403
|
choiceMode: {},
|
|
404
404
|
isHorizontal: {},
|
|
@@ -411,31 +411,31 @@ D(de, {
|
|
|
411
411
|
}, [], [], { mode: "open" });
|
|
412
412
|
//#endregion
|
|
413
413
|
//#region src/delivery/computeChoiceCorrectness.ts
|
|
414
|
-
function
|
|
414
|
+
function de(e) {
|
|
415
415
|
let t = /* @__PURE__ */ new Map(), { isEvaluateMode: n, correctChoiceId: r, selectedId: i, showCorrectAnswer: a } = e;
|
|
416
416
|
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);
|
|
417
417
|
}
|
|
418
418
|
//#endregion
|
|
419
419
|
//#region src/delivery/computeLayoutProfile.ts
|
|
420
|
-
var
|
|
420
|
+
var fe = "{{blank}}", pe = /* @__PURE__ */ new Set([
|
|
421
421
|
"audio_blank_only",
|
|
422
422
|
"stimulus_image_blank",
|
|
423
423
|
"token_sequence"
|
|
424
424
|
]);
|
|
425
425
|
function me(e) {
|
|
426
|
-
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(/ /g, " ").trim() ===
|
|
426
|
+
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(/ /g, " ").trim() === fe : !1, l = r === "horizontal" || r === "vertical" ? r : s || c ? "horizontal" : "vertical";
|
|
427
427
|
return {
|
|
428
428
|
isAudioOnlyMode: s,
|
|
429
429
|
isBlankOnlyTemplate: c,
|
|
430
430
|
choiceLayout: l,
|
|
431
431
|
isHorizontalChoices: l === "horizontal",
|
|
432
432
|
hasInlineSentenceAudioLayout: i === "inline_sentence" && a,
|
|
433
|
-
useFeatureButtonAudio: typeof o == "boolean" ? o : a &&
|
|
433
|
+
useFeatureButtonAudio: typeof o == "boolean" ? o : a && pe.has(i)
|
|
434
434
|
};
|
|
435
435
|
}
|
|
436
436
|
//#endregion
|
|
437
437
|
//#region src/delivery/computeLayoutStyle.ts
|
|
438
|
-
var
|
|
438
|
+
var Z = {
|
|
439
439
|
blankStandaloneWidthRem: {
|
|
440
440
|
varName: "--mpb-blank-standalone-width",
|
|
441
441
|
unit: "rem"
|
|
@@ -472,8 +472,8 @@ var he = {
|
|
|
472
472
|
varName: "--mpb-choice-image-max-height",
|
|
473
473
|
unit: "rem"
|
|
474
474
|
},
|
|
475
|
-
|
|
476
|
-
varName: "--mpb-
|
|
475
|
+
choiceImageMaxWidthRem: {
|
|
476
|
+
varName: "--mpb-choice-image-max-width",
|
|
477
477
|
unit: "rem"
|
|
478
478
|
},
|
|
479
479
|
choiceGroupGapRem: {
|
|
@@ -572,7 +572,7 @@ var he = {
|
|
|
572
572
|
varName: "--mpb-inline-choices-margin-top",
|
|
573
573
|
unit: "rem"
|
|
574
574
|
}
|
|
575
|
-
},
|
|
575
|
+
}, he = {
|
|
576
576
|
audio_blank_only: {
|
|
577
577
|
blankWideWidthRem: 10,
|
|
578
578
|
blankUnderlineWideWidthPx: 6,
|
|
@@ -592,10 +592,10 @@ var he = {
|
|
|
592
592
|
};
|
|
593
593
|
function ge(e) {
|
|
594
594
|
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 = {
|
|
595
|
-
...
|
|
595
|
+
...he[t] ?? {},
|
|
596
596
|
...a
|
|
597
597
|
}, s = {
|
|
598
|
-
...
|
|
598
|
+
...M,
|
|
599
599
|
...r,
|
|
600
600
|
...o
|
|
601
601
|
}, c = ["audio_blank_only", "stimulus_image_blank"], l = [
|
|
@@ -604,7 +604,7 @@ function ge(e) {
|
|
|
604
604
|
"token_sequence"
|
|
605
605
|
], u = c.includes(t) ? `${s.blankWideWidthRem}rem` : n ? `${s.blankStandaloneWidthRem}rem` : "auto", d = l.includes(t) ? `${s.blankUnderlineWideWidthPx}px` : `${s.blankUnderlineWidthPx}px`;
|
|
606
606
|
return {
|
|
607
|
-
rootStyle: Object.keys(
|
|
607
|
+
rootStyle: Object.keys(Z).map((e) => `${Z[e].varName}:${s[e]}${Z[e].unit}`).join(";"),
|
|
608
608
|
blankWidth: u,
|
|
609
609
|
blankBorderWidth: d,
|
|
610
610
|
legendMaxChars: s.legendMaxChars
|
|
@@ -612,7 +612,7 @@ function ge(e) {
|
|
|
612
612
|
}
|
|
613
613
|
//#endregion
|
|
614
614
|
//#region src/delivery/computeDisplayState.ts
|
|
615
|
-
var
|
|
615
|
+
var _e = {
|
|
616
616
|
default: {
|
|
617
617
|
silentUrl: "https://assets.learnosity.com/organisations/844/0c9f2aa3-3cd5-4de7-93ef-541c24ca35da.svg",
|
|
618
618
|
playingUrl: "https://assets.learnosity.com/organisations/844/231dfdc2-c113-4be5-91fb-e75a0ca5994b.svg"
|
|
@@ -622,25 +622,25 @@ var Z = {
|
|
|
622
622
|
playingUrl: "https://assets.learnosity.com/organisations/844/120f216d-96b7-4560-94b8-1d90710216b7.svg"
|
|
623
623
|
}
|
|
624
624
|
};
|
|
625
|
-
function
|
|
626
|
-
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") ?
|
|
625
|
+
function ve(e) {
|
|
626
|
+
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") ? _e.es : _e.default;
|
|
627
627
|
return r[t] || r[n] || r.default || i || a;
|
|
628
628
|
}
|
|
629
|
-
function
|
|
629
|
+
function ye(e) {
|
|
630
630
|
let { selectedId: t, isEvaluateMode: n, showCorrectAnswer: r, alwaysShowCorrect: i, correctChoiceId: a } = e;
|
|
631
631
|
return i && a || n && r && a ? a : t;
|
|
632
632
|
}
|
|
633
|
-
function
|
|
633
|
+
function be(e) {
|
|
634
634
|
let { isEvaluateMode: t, showCorrectAnswer: n, isCorrect: r, isIncorrect: i, selectedId: a } = e;
|
|
635
635
|
return !t || n ? "" : r ? "Correct answer selected" : i && a ? "Incorrect answer selected" : "";
|
|
636
636
|
}
|
|
637
|
-
function
|
|
637
|
+
function xe(e) {
|
|
638
638
|
let { prompt: t, legendMaxChars: n, answerChoicesLabel: r } = e, i = t.replace(/<[^>]+>/g, " ").replace(/\s+/g, " ").trim(), a = Math.max(8, n);
|
|
639
639
|
return i ? i.length > a ? `${i.slice(0, Math.max(1, a - 1))}…` : i : r;
|
|
640
640
|
}
|
|
641
641
|
//#endregion
|
|
642
642
|
//#region src/delivery/cqt-css/sel-r1-base.css?raw
|
|
643
|
-
var
|
|
643
|
+
var Se = "/* Shared base styles for all sel_r1-*_plusggg variants.\n Applied via the data-mpb-variant=\"sel-r1-base\" style element.\n Uses [class*=\"variant-sel-r1-\"] so it covers every r1 variant class.\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[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[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[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-side mx-1 and the implicit\n whitespace, producing a wider gap than LSY shows. See CONTOOL-2569. */\n[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[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[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[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 (overriding the default Tailwind mx-1).\n .pie-blank-slot is box-sizing:border-box with a permanent 6px border-bottom\n (the underline) — 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[class*=\"variant-sel-r1-\"].layout-token_sequence .pie-template-line .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. Without this, Tailwind's mx-1 (4px)\n would dominate and the cloze→token gap diverges from LSY. See CONTOOL-2569. */\n[class*=\"variant-sel-r1-\"].layout-audio_blank_only .pie-template-line .pie-blank-slot,\n[class*=\"variant-sel-r1-\"].layout-stimulus_image_blank .pie-template-line .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[class*=\"variant-sel-r1-\"].layout-audio_blank_only .pie-blank-value span:not([class]),\n[class*=\"variant-sel-r1-\"].layout-stimulus_image_blank .pie-blank-value 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[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[class*=\"variant-sel-r1-\"] .pie-template-line img,\n[class*=\"variant-sel-r1-\"] .pie-choice-label img {\n width: 150px;\n height: 150px;\n}\n", Ce = {
|
|
644
644
|
"sel_r1-_plusggg": {
|
|
645
645
|
variantId: "sel-r1-plusggg",
|
|
646
646
|
variantClass: "variant-sel-r1-plusggg",
|
|
@@ -687,16 +687,16 @@ var xe = "/* Shared base styles for all sel_r1-*_plusggg variants.\n Applied v
|
|
|
687
687
|
variantId: "sel-r1-s3",
|
|
688
688
|
variantClass: "variant-sel-r1-s3",
|
|
689
689
|
sourceUrl: "https://global-pr-ibvcustomfiles.renaissance-go.com/learnosity/sel_r1-s3_plusggg/0.0.1/question.css",
|
|
690
|
-
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}\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.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"
|
|
690
|
+
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"
|
|
691
691
|
}
|
|
692
|
-
},
|
|
692
|
+
}, we = (e) => String(e || "").trim().toLowerCase().replace(/v\d+\.\d+\.\d+$/i, ""), Te = (e) => Ce[we(e)], Ee = (e) => Te(e)?.variantClass || "", De = /* @__PURE__ */ new Set([
|
|
693
693
|
"sel-r1-plusggg",
|
|
694
694
|
"sel-r1-gplusggg",
|
|
695
695
|
"sel-r1-g-stem",
|
|
696
696
|
"sel-r1-gg-plus",
|
|
697
697
|
"sel-r1-ggplus",
|
|
698
698
|
"sel-r1-s3"
|
|
699
|
-
]),
|
|
699
|
+
]), Oe = (e, t, n) => {
|
|
700
700
|
let r = document.getElementById(e);
|
|
701
701
|
if (r) {
|
|
702
702
|
r.textContent !== n && (r.textContent = n);
|
|
@@ -704,14 +704,14 @@ var xe = "/* Shared base styles for all sel_r1-*_plusggg variants.\n Applied v
|
|
|
704
704
|
}
|
|
705
705
|
let i = document.createElement("style");
|
|
706
706
|
i.id = e, i.setAttribute("data-mpb-variant", t), i.textContent = n, document.head.appendChild(i);
|
|
707
|
-
},
|
|
708
|
-
!e?.cssText || typeof document > "u" || (
|
|
709
|
-
},
|
|
707
|
+
}, ke = (e) => {
|
|
708
|
+
!e?.cssText || typeof document > "u" || (De.has(e.variantId) && Oe("mc-populated-blank-css-sel-r1-base", "sel-r1-base", Se), Oe(`mc-populated-blank-css-${e.variantId}`, e.variantId, e.cssText));
|
|
709
|
+
}, Ae = O("<div class=\"mb-4 prose pie-prompt\"></div>"), je = j("<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>"), Me = j("<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>"), Ne = O("<div class=\"pie-correct-answer-toggle-row svelte-6wlbb4\"><button type=\"button\" class=\"mb-3 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>"), Pe = O("<div class=\"mb-3 prose prose-p:my-1 sentence-line pie-sentence-line svelte-6wlbb4\"></div>"), Fe = O("<div class=\"mb-4 template-line pie-template-line svelte-6wlbb4\"><!><!><!></div>"), Ie = O("<p class=\"sr-only pie-result-feedback svelte-6wlbb4\" role=\"status\" aria-live=\"polite\"> </p>"), Le = O("<div><!> <!> <!> <!> <!> <!> <p class=\"sr-only pie-blank-hint svelte-6wlbb4\"> </p> <fieldset class=\"border-0 p-0 m-0 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>"), Re = {
|
|
710
710
|
hash: "svelte-6wlbb4",
|
|
711
711
|
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;}.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 );}.mc-populated-blank-root.svelte-6wlbb4 .prose {max-width:none;}.pie-toggle-correct-answer.svelte-6wlbb4 {width:100%;cursor:pointer;border:0;background:transparent;padding:0;display:flex;justify-content:center;text-align:center;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;}.template-line.svelte-6wlbb4 p {margin:0;display:inline;}.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 }"
|
|
712
712
|
};
|
|
713
|
-
function
|
|
714
|
-
c(u, !0),
|
|
713
|
+
function ze(s, u) {
|
|
714
|
+
c(u, !0), ee(s, Re);
|
|
715
715
|
let d = {
|
|
716
716
|
answerChoices: "Answer choices",
|
|
717
717
|
selectedAnswerInSentence: "Selected answer in sentence",
|
|
@@ -720,59 +720,59 @@ function Re(s, u) {
|
|
|
720
720
|
hideCorrectAnswer: "Hide correct answer",
|
|
721
721
|
clickToEnableAutoplay: "Click to enable audio autoplay",
|
|
722
722
|
audioResourceUnavailable: "Audio is enabled but no playable audio URL is configured."
|
|
723
|
-
}, v = C(u, "model", 7), w = C(u, "session", 7), E = e(""), D = e(null),
|
|
723
|
+
}, v = C(u, "model", 7), w = C(u, "session", 7), E = e(""), D = e(null), O = e(null), j = e(null), M = `mc-populated-blank-${Math.random().toString(36).slice(2, 10)}`, N = a(() => (v()?.mode || v()?.env?.mode || "").toString()), P = a(() => A(N) === "evaluate"), F = a(() => v()?.correctness), te = a(() => typeof v()?.responseCorrect == "boolean" ? v().responseCorrect : A(F) === "correct"), ne = a(() => A(F) === "correct"), re = a(() => A(F) === "incorrect"), R = e(!1), ie = a(() => A(P) && !A(te) && !!v()?.correctChoiceId), z = a(() => v()?.layoutProfile || ""), B = a(() => me({
|
|
724
724
|
interactionMode: v()?.interactionMode,
|
|
725
725
|
template: v()?.template,
|
|
726
726
|
choiceLayout: v()?.choiceLayout,
|
|
727
|
-
layoutProfile:
|
|
727
|
+
layoutProfile: A(z),
|
|
728
728
|
hasAudio: v()?.hasAudio,
|
|
729
729
|
useFeatureButtonAudio: v()?.useFeatureButtonAudio
|
|
730
|
-
})), H = a(() =>
|
|
731
|
-
layoutProfile:
|
|
732
|
-
isBlankOnlyTemplate:
|
|
730
|
+
})), H = a(() => A(B).isAudioOnlyMode), U = a(() => A(B).isBlankOnlyTemplate), W = a(() => A(B).isHorizontalChoices), ae = a(() => A(B).hasInlineSentenceAudioLayout), oe = a(() => A(B).useFeatureButtonAudio), G = a(() => ge({
|
|
731
|
+
layoutProfile: A(z),
|
|
732
|
+
isBlankOnlyTemplate: A(U),
|
|
733
733
|
configuredLimits: v()?.layoutLimits,
|
|
734
734
|
customProfilePresets: v()?.layoutProfilePresets
|
|
735
|
-
})),
|
|
736
|
-
selectedId:
|
|
737
|
-
isEvaluateMode:
|
|
738
|
-
showCorrectAnswer:
|
|
735
|
+
})), K = a(() => Array.isArray(v()?.choices) ? v().choices : []), q = a(() => v()?.choiceMode || "text"), J = a(() => w()?.choiceId || A(E) || ""), ce = a(() => `${M}-choice-group-${v()?.id || "1"}`), Y = a(() => ye({
|
|
736
|
+
selectedId: A(J),
|
|
737
|
+
isEvaluateMode: A(P),
|
|
738
|
+
showCorrectAnswer: A(R),
|
|
739
739
|
alwaysShowCorrect: !!v()?.alwaysShowCorrect,
|
|
740
740
|
correctChoiceId: String(v()?.correctChoiceId || "")
|
|
741
|
-
})),
|
|
742
|
-
isEvaluateMode:
|
|
743
|
-
showCorrectAnswer:
|
|
744
|
-
isCorrect:
|
|
745
|
-
isIncorrect:
|
|
746
|
-
selectedId:
|
|
747
|
-
})),
|
|
748
|
-
isEvaluateMode:
|
|
741
|
+
})), X = a(() => A(K).find((e) => e.id === A(Y))), le = a(() => String(A(X)?.labelHtml || "")), fe = a(() => be({
|
|
742
|
+
isEvaluateMode: A(P),
|
|
743
|
+
showCorrectAnswer: A(R),
|
|
744
|
+
isCorrect: A(ne),
|
|
745
|
+
isIncorrect: A(re),
|
|
746
|
+
selectedId: A(J)
|
|
747
|
+
})), pe = a(() => de({
|
|
748
|
+
isEvaluateMode: A(P),
|
|
749
749
|
correctChoiceId: String(v()?.correctChoiceId || ""),
|
|
750
|
-
selectedId: String(
|
|
751
|
-
showCorrectAnswer:
|
|
752
|
-
})),
|
|
750
|
+
selectedId: String(A(J) || ""),
|
|
751
|
+
showCorrectAnswer: A(R)
|
|
752
|
+
})), Z = a(() => ({
|
|
753
753
|
...d,
|
|
754
754
|
...v()?.uiText || {}
|
|
755
|
-
})),
|
|
755
|
+
})), he = a(() => `${M}-prompt`), _e = a(() => `${M}-choices-legend`), Se = a(() => `${M}-result`), Ce = a(() => `${M}-blank-hint`), we = a(() => xe({
|
|
756
756
|
prompt: v()?.prompt || "",
|
|
757
|
-
legendMaxChars:
|
|
758
|
-
answerChoicesLabel:
|
|
759
|
-
})), De = a(() => v()?.prompt ?
|
|
757
|
+
legendMaxChars: A(G).legendMaxChars,
|
|
758
|
+
answerChoicesLabel: A(Z).answerChoices
|
|
759
|
+
})), De = a(() => v()?.prompt ? A(he) : void 0), Oe = a(() => v()?.prompt ? void 0 : String(v()?.choiceGroupLabel || "").trim() || A(we)), ze = a(() => v()?.prompt ? A(he) : void 0), Be = a(() => {
|
|
760
760
|
let e = v()?.locale || "";
|
|
761
761
|
return e ? e.slice(0, 2) : "en";
|
|
762
|
-
}), Ve = a(() =>
|
|
762
|
+
}), Ve = a(() => Te(v()?.customType)), He = a(() => Ee(v()?.customType)), Ue = a(() => {
|
|
763
763
|
let e = v()?.template || "", t = e.indexOf("{{blank}}");
|
|
764
764
|
if (t < 0) return {
|
|
765
765
|
before: e,
|
|
766
766
|
after: ""
|
|
767
767
|
};
|
|
768
768
|
let n = e.slice(0, t), r = e.slice(t + 9);
|
|
769
|
-
return
|
|
769
|
+
return A(z) === "inline_sentence" && (n = `${n.replace(/\s+$/, "")} `, r = ` ${r.replace(/^\s+/, "")}`), {
|
|
770
770
|
before: n,
|
|
771
771
|
after: r
|
|
772
772
|
};
|
|
773
773
|
});
|
|
774
774
|
function We(e, t) {
|
|
775
|
-
|
|
775
|
+
L({
|
|
776
776
|
sourceEl: t,
|
|
777
777
|
fallbackSelector: "mc-populated-blank",
|
|
778
778
|
component: "mc-populated-blank",
|
|
@@ -792,10 +792,10 @@ function Re(s, u) {
|
|
|
792
792
|
}, t);
|
|
793
793
|
}
|
|
794
794
|
function Ke() {
|
|
795
|
-
|
|
795
|
+
A(ie) && b(R, !A(R));
|
|
796
796
|
}
|
|
797
797
|
t(() => {
|
|
798
|
-
(!
|
|
798
|
+
(!A(P) || A(te)) && b(R, !1);
|
|
799
799
|
});
|
|
800
800
|
function qe(e) {
|
|
801
801
|
if (v()?.disabled) return;
|
|
@@ -814,24 +814,24 @@ function Re(s, u) {
|
|
|
814
814
|
let a = r[i];
|
|
815
815
|
a.checked = !0, a.dispatchEvent(new Event("change", { bubbles: !0 })), a.focus();
|
|
816
816
|
}
|
|
817
|
-
let Je = a(() =>
|
|
817
|
+
let Je = a(() => ve({
|
|
818
818
|
locale: v()?.locale,
|
|
819
819
|
audioButtonSkin: v()?.audioButtonSkin,
|
|
820
820
|
audioButtonSkinsByLocale: v()?.audioButtonSkinsByLocale
|
|
821
821
|
}));
|
|
822
822
|
function Ye() {
|
|
823
|
-
|
|
823
|
+
I(A(j), { fallbackSelector: "mc-populated-blank" })?.onAudioStarted?.();
|
|
824
824
|
}
|
|
825
825
|
function Xe() {
|
|
826
|
-
|
|
826
|
+
I(A(j), { fallbackSelector: "mc-populated-blank" })?.onAudioEnded?.();
|
|
827
827
|
}
|
|
828
828
|
t(() => {
|
|
829
829
|
w()?.choiceId && b(E, w().choiceId, !0);
|
|
830
830
|
}), t(() => {
|
|
831
|
-
let e =
|
|
831
|
+
let e = A(D);
|
|
832
832
|
if (e) return e.addEventListener("click", Ke), () => e.removeEventListener("click", Ke);
|
|
833
833
|
}), t(() => {
|
|
834
|
-
let e =
|
|
834
|
+
let e = A(O);
|
|
835
835
|
if (!e) return;
|
|
836
836
|
let t = (e) => {
|
|
837
837
|
e.target?.type === "radio" && Ge(e);
|
|
@@ -840,7 +840,7 @@ function Re(s, u) {
|
|
|
840
840
|
e.removeEventListener("change", t), e.removeEventListener("keydown", n);
|
|
841
841
|
};
|
|
842
842
|
}), t(() => {
|
|
843
|
-
|
|
843
|
+
ke(A(Ve));
|
|
844
844
|
});
|
|
845
845
|
var Ze = {
|
|
846
846
|
get model() {
|
|
@@ -855,164 +855,164 @@ function Re(s, u) {
|
|
|
855
855
|
set session(e) {
|
|
856
856
|
w(e), y();
|
|
857
857
|
}
|
|
858
|
-
}, Q =
|
|
859
|
-
var t =
|
|
860
|
-
m(t, () => v().prompt, !0), i(t), l(() => f(t, "id",
|
|
858
|
+
}, Q = Le(), Qe = k(Q), $e = (e) => {
|
|
859
|
+
var t = Ae();
|
|
860
|
+
m(t, () => v().prompt, !0), i(t), l(() => f(t, "id", A(he))), g(e, t);
|
|
861
861
|
};
|
|
862
862
|
S(Qe, (e) => {
|
|
863
863
|
v()?.prompt && e($e);
|
|
864
864
|
});
|
|
865
865
|
var et = n(Qe, 2), tt = (e) => {
|
|
866
|
-
var t =
|
|
867
|
-
g(e, Ae());
|
|
868
|
-
}, d = (e) => {
|
|
866
|
+
var t = Ne(), a = k(t), o = k(a), s = k(o), c = k(s), u = (e) => {
|
|
869
867
|
g(e, je());
|
|
868
|
+
}, d = (e) => {
|
|
869
|
+
g(e, Me());
|
|
870
870
|
};
|
|
871
871
|
S(c, (e) => {
|
|
872
|
-
|
|
872
|
+
A(R) ? e(u) : e(d, -1);
|
|
873
873
|
}), i(s);
|
|
874
874
|
var p = r(n(s, 2), !0);
|
|
875
|
-
i(o), i(a), T(a, (e) => b(D, e), () =>
|
|
876
|
-
f(a, "aria-pressed",
|
|
875
|
+
i(o), i(a), T(a, (e) => b(D, e), () => A(D)), i(t), l(() => {
|
|
876
|
+
f(a, "aria-pressed", A(R)), _(p, A(R) ? A(Z).hideCorrectAnswer : A(Z).showCorrectAnswer);
|
|
877
877
|
}), g(e, t);
|
|
878
878
|
};
|
|
879
879
|
S(et, (e) => {
|
|
880
|
-
|
|
880
|
+
A(ie) && e(tt);
|
|
881
881
|
});
|
|
882
882
|
var nt = n(et, 2);
|
|
883
883
|
{
|
|
884
884
|
let e = a(() => !!v()?.hasAudio), t = a(() => v()?.audioUrl), n = a(() => !!v()?.autoplayAudioEnabled), r = a(() => v()?.locale);
|
|
885
885
|
V(nt, {
|
|
886
886
|
get hasAudio() {
|
|
887
|
-
return
|
|
887
|
+
return A(e);
|
|
888
888
|
},
|
|
889
889
|
get audioUrl() {
|
|
890
|
-
return
|
|
890
|
+
return A(t);
|
|
891
891
|
},
|
|
892
892
|
get useFeatureButtonAudio() {
|
|
893
|
-
return
|
|
893
|
+
return A(oe);
|
|
894
894
|
},
|
|
895
895
|
get autoplayEnabled() {
|
|
896
|
-
return
|
|
896
|
+
return A(n);
|
|
897
897
|
},
|
|
898
898
|
get featureAudioSkin() {
|
|
899
|
-
return
|
|
899
|
+
return A(Je);
|
|
900
900
|
},
|
|
901
901
|
get uiText() {
|
|
902
|
-
return
|
|
902
|
+
return A(Z);
|
|
903
903
|
},
|
|
904
904
|
get locale() {
|
|
905
|
-
return
|
|
905
|
+
return A(r);
|
|
906
906
|
},
|
|
907
907
|
onaudiostarted: Ye,
|
|
908
908
|
onaudioended: Xe
|
|
909
909
|
});
|
|
910
910
|
}
|
|
911
911
|
var rt = n(nt, 2), it = (e) => {
|
|
912
|
-
var t =
|
|
913
|
-
m(t, () => v().sentenceHtml, !0), i(t), l(() => f(t, "aria-describedby",
|
|
912
|
+
var t = Pe();
|
|
913
|
+
m(t, () => v().sentenceHtml, !0), i(t), l(() => f(t, "aria-describedby", A(ze))), g(e, t);
|
|
914
914
|
};
|
|
915
915
|
S(rt, (e) => {
|
|
916
916
|
v()?.sentenceHtml && e(it);
|
|
917
917
|
});
|
|
918
918
|
var at = n(rt, 2), ot = (e) => {
|
|
919
|
-
var t =
|
|
920
|
-
m(r, () =>
|
|
919
|
+
var t = Fe(), r = k(t);
|
|
920
|
+
m(r, () => A(Ue).before);
|
|
921
921
|
var a = n(r);
|
|
922
|
-
|
|
922
|
+
se(a, {
|
|
923
923
|
get choiceMode() {
|
|
924
|
-
return
|
|
924
|
+
return A(q);
|
|
925
925
|
},
|
|
926
926
|
get displayChoice() {
|
|
927
|
-
return
|
|
927
|
+
return A(X);
|
|
928
928
|
},
|
|
929
929
|
get displayChoiceLabelHtml() {
|
|
930
|
-
return
|
|
930
|
+
return A(le);
|
|
931
931
|
},
|
|
932
932
|
get isStandalone() {
|
|
933
|
-
return
|
|
933
|
+
return A(U);
|
|
934
934
|
},
|
|
935
935
|
get blankWidth() {
|
|
936
|
-
return
|
|
936
|
+
return A(G).blankWidth;
|
|
937
937
|
},
|
|
938
938
|
get blankBorderWidth() {
|
|
939
|
-
return
|
|
939
|
+
return A(G).blankBorderWidth;
|
|
940
940
|
},
|
|
941
941
|
get ariaLabel() {
|
|
942
|
-
return
|
|
942
|
+
return A(Z).selectedAnswerInSentence;
|
|
943
943
|
}
|
|
944
|
-
}), m(n(a), () =>
|
|
944
|
+
}), m(n(a), () => A(Ue).after), i(t), l(() => f(t, "aria-describedby", A(ze))), g(e, t);
|
|
945
945
|
};
|
|
946
946
|
S(at, (e) => {
|
|
947
|
-
|
|
947
|
+
A(H) || e(ot);
|
|
948
948
|
});
|
|
949
949
|
var st = n(at, 2), ct = (e) => {
|
|
950
|
-
var t =
|
|
950
|
+
var t = Ie(), n = r(t, !0);
|
|
951
951
|
l(() => {
|
|
952
|
-
f(t, "id",
|
|
952
|
+
f(t, "id", A(Se)), _(n, A(fe));
|
|
953
953
|
}), g(e, t);
|
|
954
954
|
};
|
|
955
955
|
S(st, (e) => {
|
|
956
|
-
|
|
956
|
+
A(fe) && e(ct);
|
|
957
957
|
});
|
|
958
|
-
var lt = n(st, 2), ut = r(lt, !0), dt = n(lt, 2), ft =
|
|
959
|
-
return h($, 21, () =>
|
|
958
|
+
var lt = n(st, 2), ut = r(lt, !0), dt = n(lt, 2), ft = k(dt), pt = r(ft, !0), $ = n(ft, 2);
|
|
959
|
+
return h($, 21, () => A(K), (e) => e.id, (e, t) => {
|
|
960
960
|
{
|
|
961
|
-
let n = a(() =>
|
|
962
|
-
|
|
961
|
+
let n = a(() => A(Y) === A(t).id), r = a(() => !!v()?.disabled), i = a(() => A(pe).get(A(t).id));
|
|
962
|
+
ue(e, {
|
|
963
963
|
get choice() {
|
|
964
|
-
return
|
|
964
|
+
return A(t);
|
|
965
965
|
},
|
|
966
966
|
get choiceMode() {
|
|
967
|
-
return
|
|
967
|
+
return A(q);
|
|
968
968
|
},
|
|
969
969
|
get isHorizontal() {
|
|
970
|
-
return
|
|
970
|
+
return A(W);
|
|
971
971
|
},
|
|
972
972
|
get isSelected() {
|
|
973
|
-
return
|
|
973
|
+
return A(n);
|
|
974
974
|
},
|
|
975
975
|
get isDisabled() {
|
|
976
|
-
return
|
|
976
|
+
return A(r);
|
|
977
977
|
},
|
|
978
978
|
get correctness() {
|
|
979
|
-
return
|
|
979
|
+
return A(i);
|
|
980
980
|
},
|
|
981
981
|
get isEvaluateMode() {
|
|
982
|
-
return
|
|
982
|
+
return A(P);
|
|
983
983
|
},
|
|
984
984
|
get instanceId() {
|
|
985
|
-
return
|
|
985
|
+
return M;
|
|
986
986
|
},
|
|
987
987
|
get radioGroupName() {
|
|
988
|
-
return
|
|
988
|
+
return A(ce);
|
|
989
989
|
}
|
|
990
990
|
});
|
|
991
991
|
}
|
|
992
|
-
}), i($), T($, (e) => b(
|
|
993
|
-
x(Q, 1, `p-4 mc-populated-blank-root pie-element pie-element-mc-populated-blank pie-delivery-root layout-${
|
|
994
|
-
}, [() => [
|
|
992
|
+
}), i($), T($, (e) => b(O, e), () => A(O)), i(dt), i(Q), T(Q, (e) => b(j, e), () => A(j)), l((e) => {
|
|
993
|
+
x(Q, 1, `p-4 mc-populated-blank-root pie-element pie-element-mc-populated-blank pie-delivery-root layout-${A(z)} ${A(He)} ${A(ae) ? "has-inline-audio" : ""}`, "svelte-6wlbb4"), f(Q, "lang", A(Be)), p(Q, A(G).rootStyle), f(lt, "id", A(Ce)), _(ut, A(Z).blankPreSelectionHint), dt.disabled = v()?.disabled, f(ft, "id", A(_e)), _(pt, A(we)), x($, 1, `pie-choices ${A(W) ? "flex flex-row flex-wrap items-start justify-center" : "flex flex-col"}`, "svelte-6wlbb4"), f($, "aria-labelledby", A(De)), f($, "aria-label", A(Oe)), f($, "aria-describedby", e);
|
|
994
|
+
}, [() => [A(Ce), A(fe) ? A(Se) : void 0].filter(Boolean).join(" ")]), g(s, Q), o(Ze);
|
|
995
995
|
}
|
|
996
|
-
D(
|
|
996
|
+
D(ze, {
|
|
997
997
|
model: { type: "Object" },
|
|
998
998
|
session: { type: "Object" },
|
|
999
999
|
options: { type: "Object" }
|
|
1000
1000
|
}, [], []);
|
|
1001
1001
|
//#endregion
|
|
1002
1002
|
//#region src/delivery/index.ts
|
|
1003
|
-
function
|
|
1003
|
+
function Be(e, t, n = !1) {
|
|
1004
1004
|
return !(!t?.choiceId || e?.autoplayAudioEnabled && e?.completeAudioEnabled && e?.hasAudio && !n);
|
|
1005
1005
|
}
|
|
1006
|
-
var
|
|
1006
|
+
var Ve = ze.element, He = class extends Ve {
|
|
1007
1007
|
_internalSession = null;
|
|
1008
1008
|
_model = null;
|
|
1009
1009
|
_options = null;
|
|
1010
1010
|
audioComplete = !1;
|
|
1011
1011
|
_dispatchModelSet = () => {
|
|
1012
|
-
this.dispatchEvent(new
|
|
1012
|
+
this.dispatchEvent(new N(this.tagName.toLowerCase(), this._isComplete(), this._model !== void 0));
|
|
1013
1013
|
};
|
|
1014
1014
|
_dispatchSessionChanged = () => {
|
|
1015
|
-
this.dispatchEvent(new
|
|
1015
|
+
this.dispatchEvent(new P(this.tagName.toLowerCase(), this._isComplete()));
|
|
1016
1016
|
};
|
|
1017
1017
|
set model(e) {
|
|
1018
1018
|
this._model = e, this.audioComplete = !1, super.model = e, this._dispatchModelSet();
|
|
@@ -1047,12 +1047,12 @@ var Be = Re.element, Ve = class extends Be {
|
|
|
1047
1047
|
audioEndTime: Date.now()
|
|
1048
1048
|
}, this._dispatchSessionChanged();
|
|
1049
1049
|
};
|
|
1050
|
-
_isComplete = () =>
|
|
1050
|
+
_isComplete = () => Be(this._model, this._internalSession, this.audioComplete);
|
|
1051
1051
|
connectedCallback() {
|
|
1052
1052
|
super.connectedCallback(), this.onSessionChange = this.onSessionChange, this.onAudioStarted = this.onAudioStarted, this.onAudioEnded = this.onAudioEnded;
|
|
1053
1053
|
}
|
|
1054
1054
|
};
|
|
1055
1055
|
//#endregion
|
|
1056
|
-
export {
|
|
1056
|
+
export { He as default };
|
|
1057
1057
|
|
|
1058
1058
|
//# sourceMappingURL=index.js.map
|