markdown-flow-ui 0.1.123 → 0.1.124
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/Slide/Player.cjs.js +1 -1
- package/dist/components/Slide/Player.cjs.js.map +1 -1
- package/dist/components/Slide/Player.es.js +191 -201
- package/dist/components/Slide/Player.es.js.map +1 -1
- package/dist/components/Slide/Slide.cjs.js +1 -1
- package/dist/components/Slide/Slide.cjs.js.map +1 -1
- package/dist/components/Slide/Slide.es.js +116 -116
- package/dist/components/Slide/Slide.es.js.map +1 -1
- package/dist/components/Slide/utils/playbackPreference.cjs.js +1 -1
- package/dist/components/Slide/utils/playbackPreference.cjs.js.map +1 -1
- package/dist/components/Slide/utils/playbackPreference.d.ts +1 -6
- package/dist/components/Slide/utils/playbackPreference.es.js +4 -9
- package/dist/components/Slide/utils/playbackPreference.es.js.map +1 -1
- package/dist/node_modules/cose-base/cose-base.cjs.js +1 -1
- package/dist/node_modules/cose-base/cose-base.cjs.js.map +1 -1
- package/dist/node_modules/cose-base/cose-base.es.js +1 -1
- package/dist/node_modules/cytoscape-fcose/node_modules/cose-base/cose-base.cjs.js +1 -1
- package/dist/node_modules/cytoscape-fcose/node_modules/cose-base/cose-base.cjs.js.map +1 -1
- package/dist/node_modules/cytoscape-fcose/node_modules/cose-base/cose-base.es.js +1 -1
- package/dist/node_modules/cytoscape-fcose/node_modules/layout-base/layout-base.cjs.js +1 -1
- package/dist/node_modules/cytoscape-fcose/node_modules/layout-base/layout-base.cjs.js.map +1 -1
- package/dist/node_modules/cytoscape-fcose/node_modules/layout-base/layout-base.es.js +1 -1
- package/dist/node_modules/layout-base/layout-base.cjs.js +1 -1
- package/dist/node_modules/layout-base/layout-base.cjs.js.map +1 -1
- package/dist/node_modules/layout-base/layout-base.es.js +1 -1
- package/package.json +1 -1
|
@@ -12,7 +12,7 @@ import En from "./Player.es.js";
|
|
|
12
12
|
import Pn from "./SubtitleOverlay.es.js";
|
|
13
13
|
import Tn from "./useSlide.es.js";
|
|
14
14
|
import Cn from "./useWakePlayerFromIframe.es.js";
|
|
15
|
-
import { DEFAULT_MOBILE_VIEW_MODE as
|
|
15
|
+
import { DEFAULT_MOBILE_VIEW_MODE as _e, resolveMobileViewModeState as Rn } from "./utils/mobileScreenMode.es.js";
|
|
16
16
|
import { shouldPresentInteractionOverlay as Mn } from "./utils/interactionPlayback.es.js";
|
|
17
17
|
import { shouldAutoAdvanceIntoAppendedMarker as kn } from "./utils/appendedMarkerAdvance.es.js";
|
|
18
18
|
import { getPlaybackSequenceTransition as Fn } from "./utils/playbackSequence.es.js";
|
|
@@ -21,11 +21,11 @@ import { createPlaybackTimeStore as On } from "./utils/playbackTimeStore.es.js";
|
|
|
21
21
|
import { shouldUseAutoAdvanceToggle as jn } from "./utils/playerToggleMode.es.js";
|
|
22
22
|
/* empty css */
|
|
23
23
|
import Ln from "../../node_modules/lucide-react/dist/esm/icons/chevron-left.es.js";
|
|
24
|
-
const Kn = 2e3, Vn = 300, qn = 160, Dn = 16,
|
|
24
|
+
const Kn = 2e3, Vn = 300, qn = 160, Dn = 16, De = "waitingForAudio", Tt = {
|
|
25
25
|
waitingForAudio: "Waiting for current slide audio...",
|
|
26
26
|
loadingAudio: "Loading current slide audio...",
|
|
27
27
|
waitingForMoreAudio: "Waiting for more current slide audio..."
|
|
28
|
-
}, Un = (b, I) => typeof b == "string" ? b : b[I] ?? b[
|
|
28
|
+
}, Un = (b, I) => typeof b == "string" ? b : b[I] ?? b[De] ?? Tt[I], zn = (b, I) => I ? b !== "loadingAudio" : !1, Ct = gn(
|
|
29
29
|
({
|
|
30
30
|
content: b,
|
|
31
31
|
title: I,
|
|
@@ -34,8 +34,8 @@ const Kn = 2e3, Vn = 300, qn = 160, Dn = 16, Ue = "waitingForAudio", Tt = {
|
|
|
34
34
|
defaultSelectedValues: _,
|
|
35
35
|
confirmButtonText: V,
|
|
36
36
|
copyButtonText: Z,
|
|
37
|
-
copiedButtonText:
|
|
38
|
-
onSend:
|
|
37
|
+
copiedButtonText: Ee,
|
|
38
|
+
onSend: Pe,
|
|
39
39
|
readonly: q = !1
|
|
40
40
|
}) => /* @__PURE__ */ r.jsxs("div", { className: "slide-player__interaction-card", children: [
|
|
41
41
|
/* @__PURE__ */ r.jsx("div", { className: "slide-player__interaction-header", children: /* @__PURE__ */ r.jsx("p", { className: "slide-player__interaction-title", children: I }) }),
|
|
@@ -48,8 +48,8 @@ const Kn = 2e3, Vn = 300, qn = 160, Dn = 16, Ue = "waitingForAudio", Tt = {
|
|
|
48
48
|
defaultSelectedValues: _,
|
|
49
49
|
confirmButtonText: V,
|
|
50
50
|
copyButtonText: Z,
|
|
51
|
-
copiedButtonText:
|
|
52
|
-
onSend:
|
|
51
|
+
copiedButtonText: Ee,
|
|
52
|
+
onSend: Pe,
|
|
53
53
|
readonly: q,
|
|
54
54
|
sandboxMode: "content"
|
|
55
55
|
}
|
|
@@ -68,30 +68,30 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
68
68
|
fullscreenHeader: _,
|
|
69
69
|
playerCustomActions: V,
|
|
70
70
|
playerCustomActionPauseOnActive: Z = !0,
|
|
71
|
-
bufferingText:
|
|
72
|
-
interactionTitle:
|
|
71
|
+
bufferingText: Ee = Tt,
|
|
72
|
+
interactionTitle: Pe,
|
|
73
73
|
interactionTexts: q,
|
|
74
74
|
playerTexts: Rt,
|
|
75
|
-
playerAutoHideDelay:
|
|
76
|
-
markerAutoAdvanceDelay:
|
|
75
|
+
playerAutoHideDelay: Te = 3e3,
|
|
76
|
+
markerAutoAdvanceDelay: Ue = Kn,
|
|
77
77
|
interactionDefaultValueOptions: fe,
|
|
78
|
-
onSend:
|
|
79
|
-
onPlayerVisibilityChange:
|
|
80
|
-
onMobileViewModeChange:
|
|
81
|
-
onStepChange:
|
|
78
|
+
onSend: ze,
|
|
79
|
+
onPlayerVisibilityChange: Ce,
|
|
80
|
+
onMobileViewModeChange: Ge,
|
|
81
|
+
onStepChange: He,
|
|
82
82
|
enableIframeScaling: Mt = !0,
|
|
83
83
|
disableLoadingOverlay: T = !1,
|
|
84
84
|
className: kt,
|
|
85
|
-
onPointerDown:
|
|
85
|
+
onPointerDown: We,
|
|
86
86
|
...Ft
|
|
87
87
|
}) => {
|
|
88
|
-
const me = p(null),
|
|
88
|
+
const me = p(null), $e = p(null), Re = p(null), Ye = p(null), ee = p(null), te = p(null), ne = p(null), re = p(null), Xe = p(null), Je = p([]), pe = p(!1), D = p(null), Qe = p(null), Ze = p({
|
|
89
89
|
markerCount: 0,
|
|
90
90
|
currentIndex: -1,
|
|
91
91
|
canGoNext: !1
|
|
92
92
|
}), {
|
|
93
93
|
currentElementList: B,
|
|
94
|
-
stepElementLists:
|
|
94
|
+
stepElementLists: et,
|
|
95
95
|
slideElementList: N,
|
|
96
96
|
currentIndex: d,
|
|
97
97
|
audioList: h,
|
|
@@ -100,7 +100,7 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
100
100
|
currentInteractionElement: u,
|
|
101
101
|
canGoPrev: Bt,
|
|
102
102
|
canGoNext: x,
|
|
103
|
-
handlePrev:
|
|
103
|
+
handlePrev: tt,
|
|
104
104
|
handleNext: C
|
|
105
105
|
} = Tn(b), oe = c(() => {
|
|
106
106
|
if (!(d < 0))
|
|
@@ -110,12 +110,12 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
110
110
|
).length === 1, E = I && (N.length > 0 || h.length > 0 || !!u), R = c(
|
|
111
111
|
() => he.map((e) => h[e]?.audioKey).filter((e) => !!e),
|
|
112
112
|
[h, he]
|
|
113
|
-
), [
|
|
113
|
+
), [nt, ve] = m(!0), [ye, se] = m(!1), [ie, rt] = m(!0), [le, ot] = m(!0), [v, U] = m(null), [Ot, y] = m(!1), [jt, Me] = m(De), [M, st] = m(!1), [Lt, ke] = m(!1), [it, Kt] = m(!0), [Fe, Be] = m(!1), [o, Ne] = m(), [ge, be] = m(!1), [
|
|
114
114
|
Vt,
|
|
115
115
|
ce
|
|
116
|
-
] = m(0), [lt, qt] = m(!1), O = c(() => wn(), []), [
|
|
117
|
-
|
|
118
|
-
), [ct,
|
|
116
|
+
] = m(0), [lt, qt] = m(!1), O = c(() => wn(), []), [Se, Oe] = m(
|
|
117
|
+
_e
|
|
118
|
+
), [ct, je] = m(!1), [Dt, at] = m(
|
|
119
119
|
() => O ? Pt() : !1
|
|
120
120
|
), z = c(() => On(), []), {
|
|
121
121
|
effectiveMobileViewMode: G,
|
|
@@ -126,30 +126,30 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
126
126
|
() => Rn({
|
|
127
127
|
hasManualMobileViewMode: ct,
|
|
128
128
|
isMobileDevice: O,
|
|
129
|
-
mobileViewMode:
|
|
129
|
+
mobileViewMode: Se
|
|
130
130
|
}),
|
|
131
131
|
[
|
|
132
132
|
ct,
|
|
133
133
|
O,
|
|
134
134
|
Dt,
|
|
135
|
-
|
|
135
|
+
Se
|
|
136
136
|
]
|
|
137
|
-
), zt = p(G), k = E && (w ||
|
|
137
|
+
), zt = p(G), k = E && (w || nt), Gt = H && k, Ht = H && k, Wt = H || ut, dt = lt && !O, $t = n(
|
|
138
138
|
(e) => {
|
|
139
|
-
|
|
139
|
+
je(!0), Oe(e);
|
|
140
140
|
},
|
|
141
141
|
[]
|
|
142
142
|
), ft = n(() => {
|
|
143
|
-
|
|
143
|
+
je(!1), Oe(_e);
|
|
144
144
|
}, []), Yt = n(() => {
|
|
145
145
|
ft(), _?.onBack?.();
|
|
146
146
|
}, [_, ft]), mt = n((e) => {
|
|
147
|
-
|
|
147
|
+
Be(e);
|
|
148
148
|
}, []), pt = n(() => {
|
|
149
|
-
|
|
149
|
+
Be((e) => !e);
|
|
150
150
|
}, []), { mountedStepStates: Xt, currentMountedStateIndex: Jt } = c(() => {
|
|
151
151
|
const e = [], t = /* @__PURE__ */ new Map();
|
|
152
|
-
return
|
|
152
|
+
return et.forEach((l, f) => {
|
|
153
153
|
const i = e.findIndex(
|
|
154
154
|
(a) => Gn(
|
|
155
155
|
a.elementList,
|
|
@@ -168,15 +168,15 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
168
168
|
mountedStepStates: e,
|
|
169
169
|
currentMountedStateIndex: d >= 0 ? t.get(d) ?? -1 : -1
|
|
170
170
|
};
|
|
171
|
-
}, [d,
|
|
171
|
+
}, [d, et]), ht = c(() => String(d), [d]), g = c(() => v ? h.findIndex(
|
|
172
172
|
(e) => (e.audioKey ?? "") === v
|
|
173
|
-
) : -1, [h, v]),
|
|
173
|
+
) : -1, [h, v]), Le = c(
|
|
174
174
|
() => g >= 0 ? h[g] : void 0,
|
|
175
175
|
[h, g]
|
|
176
|
-
), Qt =
|
|
176
|
+
), Qt = Le?.element?.subtitle_cues ?? [], Ae = c(
|
|
177
177
|
() => R[0] ?? "none",
|
|
178
178
|
[R]
|
|
179
|
-
),
|
|
179
|
+
), Ke = c(
|
|
180
180
|
() => ({
|
|
181
181
|
currentElement: Bn({
|
|
182
182
|
currentAudioIndex: g,
|
|
@@ -187,7 +187,7 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
187
187
|
}),
|
|
188
188
|
currentIndex: d,
|
|
189
189
|
currentStepElement: oe,
|
|
190
|
-
isActive:
|
|
190
|
+
isActive: Fe,
|
|
191
191
|
setActive: mt,
|
|
192
192
|
toggleActive: pt
|
|
193
193
|
}),
|
|
@@ -198,24 +198,24 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
198
198
|
he,
|
|
199
199
|
d,
|
|
200
200
|
oe,
|
|
201
|
-
|
|
201
|
+
Fe,
|
|
202
202
|
mt,
|
|
203
203
|
pt
|
|
204
204
|
]
|
|
205
|
-
),
|
|
205
|
+
), Ve = c(
|
|
206
206
|
() => Nn(
|
|
207
207
|
V,
|
|
208
|
-
|
|
208
|
+
Ke
|
|
209
209
|
),
|
|
210
|
-
[
|
|
210
|
+
[Ke, V]
|
|
211
211
|
), Zt = c(
|
|
212
212
|
() => ({
|
|
213
|
-
"--slide-player-custom-action-count": String(
|
|
213
|
+
"--slide-player-custom-action-count": String(Ve),
|
|
214
214
|
"--slide-player-mobile-control-count": String(
|
|
215
|
-
|
|
215
|
+
Ve + 4
|
|
216
216
|
)
|
|
217
217
|
}),
|
|
218
|
-
[
|
|
218
|
+
[Ve]
|
|
219
219
|
), vt = R.length > 0, yt = c(() => u ? `${u.sequence_number ?? "none"}:${String(
|
|
220
220
|
u.content ?? ""
|
|
221
221
|
)}` : "none", [u]), ae = c(
|
|
@@ -224,13 +224,13 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
224
224
|
), en = c(
|
|
225
225
|
() => [
|
|
226
226
|
ae,
|
|
227
|
-
|
|
227
|
+
Le?.audioKey ?? "none",
|
|
228
228
|
String(g)
|
|
229
229
|
].join("|"),
|
|
230
|
-
[g,
|
|
231
|
-
), gt = !!c(() => !
|
|
232
|
-
(t) => t.audioKey ===
|
|
233
|
-
)?.audioUrl?.trim() ?? "", [h,
|
|
230
|
+
[g, Le?.audioKey, ae]
|
|
231
|
+
), gt = !!c(() => !Ae || Ae === "none" ? "" : h.find(
|
|
232
|
+
(t) => t.audioKey === Ae
|
|
233
|
+
)?.audioUrl?.trim() ?? "", [h, Ae]), L = Z && !!V && Fe, ue = c(
|
|
234
234
|
() => jn({
|
|
235
235
|
canGoNext: x,
|
|
236
236
|
currentAudioIndex: g,
|
|
@@ -252,7 +252,7 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
252
252
|
}, []), W = n(() => {
|
|
253
253
|
te.current !== null && (window.clearTimeout(te.current), te.current = null);
|
|
254
254
|
}, []), $ = n(() => {
|
|
255
|
-
W(), j(), F(), U(null), z.reset(), y(!1),
|
|
255
|
+
W(), j(), F(), U(null), z.reset(), y(!1), Me(De), st(!1), ke(!1), Ne(void 0), be(!1), ce(0);
|
|
256
256
|
}, [
|
|
257
257
|
W,
|
|
258
258
|
j,
|
|
@@ -261,8 +261,8 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
261
261
|
]), Y = n(() => {
|
|
262
262
|
const e = R[0];
|
|
263
263
|
return e ? (U(e), !0) : !1;
|
|
264
|
-
}, [R]),
|
|
265
|
-
j(), F(),
|
|
264
|
+
}, [R]), xe = n(() => {
|
|
265
|
+
j(), F(), be(!1), ce(0), !Y() && x && C();
|
|
266
266
|
}, [
|
|
267
267
|
x,
|
|
268
268
|
j,
|
|
@@ -276,7 +276,7 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
276
276
|
const t = () => {
|
|
277
277
|
re.current = null, ce(
|
|
278
278
|
qn
|
|
279
|
-
),
|
|
279
|
+
), be(!0), D.current = null;
|
|
280
280
|
};
|
|
281
281
|
re.current = window.setTimeout(
|
|
282
282
|
t,
|
|
@@ -286,28 +286,28 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
286
286
|
[F]
|
|
287
287
|
), A = n(
|
|
288
288
|
(e = ye) => {
|
|
289
|
-
E && (ve(!0), K(), !(w || !e ||
|
|
289
|
+
E && (ve(!0), K(), !(w || !e || Te <= 0) && (ee.current = window.setTimeout(() => {
|
|
290
290
|
ve(!1), ee.current = null;
|
|
291
|
-
},
|
|
291
|
+
}, Te)));
|
|
292
292
|
},
|
|
293
293
|
[
|
|
294
294
|
K,
|
|
295
295
|
ye,
|
|
296
296
|
w,
|
|
297
|
-
|
|
297
|
+
Te,
|
|
298
298
|
E
|
|
299
299
|
]
|
|
300
300
|
), de = !!(u?.readonly || u?.user_input?.trim()), X = !!u && !de, tn = n((e) => {
|
|
301
|
-
|
|
302
|
-
}, []),
|
|
301
|
+
rt(e);
|
|
302
|
+
}, []), Ie = n(
|
|
303
303
|
(e) => {
|
|
304
304
|
const t = e?.shouldContinuePlayback ?? ie;
|
|
305
|
-
|
|
305
|
+
rt(t);
|
|
306
306
|
},
|
|
307
307
|
[ie]
|
|
308
308
|
);
|
|
309
309
|
s(() => {
|
|
310
|
-
|
|
310
|
+
ot(ie), Z && Be(!1);
|
|
311
311
|
}, [d, ie, Z]), s(() => () => {
|
|
312
312
|
W(), K(), j(), F();
|
|
313
313
|
}, [
|
|
@@ -315,11 +315,11 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
315
315
|
j,
|
|
316
316
|
F,
|
|
317
317
|
K
|
|
318
|
-
]), s(() => (
|
|
319
|
-
|
|
320
|
-
}), [
|
|
321
|
-
O ||
|
|
322
|
-
}, [O,
|
|
318
|
+
]), s(() => (Ce?.(k), () => {
|
|
319
|
+
Ce?.(!1);
|
|
320
|
+
}), [Ce, k]), s(() => {
|
|
321
|
+
O || Se === _e || (je(!1), Oe(_e));
|
|
322
|
+
}, [O, Se]), s(() => {
|
|
323
323
|
if (!O) {
|
|
324
324
|
at(!1);
|
|
325
325
|
return;
|
|
@@ -329,13 +329,13 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
329
329
|
};
|
|
330
330
|
return e(), _n(e);
|
|
331
331
|
}, [O]), s(() => {
|
|
332
|
-
|
|
333
|
-
}, [G,
|
|
332
|
+
Ge?.(G);
|
|
333
|
+
}, [G, Ge]), s(() => {
|
|
334
334
|
zt.current = G;
|
|
335
335
|
}, [G]), s(() => {
|
|
336
|
-
|
|
337
|
-
}, [d, oe,
|
|
338
|
-
const e =
|
|
336
|
+
He?.(oe, d);
|
|
337
|
+
}, [d, oe, He]), s(() => {
|
|
338
|
+
const e = Ze.current, t = kn(
|
|
339
339
|
{
|
|
340
340
|
previousMarkerCount: e.markerCount,
|
|
341
341
|
nextMarkerCount: N.length,
|
|
@@ -351,7 +351,7 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
351
351
|
shouldUseSilentStepAutoAdvanceToggle: ue
|
|
352
352
|
}
|
|
353
353
|
);
|
|
354
|
-
|
|
354
|
+
Ze.current = {
|
|
355
355
|
markerCount: N.length,
|
|
356
356
|
currentIndex: d,
|
|
357
357
|
canGoNext: x
|
|
@@ -401,12 +401,12 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
401
401
|
}
|
|
402
402
|
}), s(() => {
|
|
403
403
|
const { hasPlaybackContextChanged: e, shouldInitializeAudioSequence: t } = Fn({
|
|
404
|
-
previousResetKey:
|
|
404
|
+
previousResetKey: Qe.current,
|
|
405
405
|
nextResetKey: ae,
|
|
406
406
|
currentAudioKey: v,
|
|
407
407
|
hasCompletedCurrentStepAudio: M
|
|
408
408
|
});
|
|
409
|
-
|
|
409
|
+
Qe.current = ae;
|
|
410
410
|
const l = D.current === d && !!u, f = Mn({
|
|
411
411
|
hasInteraction: !!u,
|
|
412
412
|
shouldBlockPlaybackForInteraction: X,
|
|
@@ -416,7 +416,7 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
416
416
|
currentStepHasSpeakableElement: S
|
|
417
417
|
});
|
|
418
418
|
if (e && $(), !(B.length === 0 && !u) && !L) {
|
|
419
|
-
if (u &&
|
|
419
|
+
if (u && Ne(u), f) {
|
|
420
420
|
bt(u);
|
|
421
421
|
return;
|
|
422
422
|
}
|
|
@@ -432,7 +432,7 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
432
432
|
if (x && !(ue && !le))
|
|
433
433
|
return te.current = window.setTimeout(() => {
|
|
434
434
|
te.current = null, C();
|
|
435
|
-
},
|
|
435
|
+
}, Ue), () => {
|
|
436
436
|
W();
|
|
437
437
|
};
|
|
438
438
|
}
|
|
@@ -445,7 +445,7 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
445
445
|
v,
|
|
446
446
|
ae,
|
|
447
447
|
S,
|
|
448
|
-
|
|
448
|
+
Ue,
|
|
449
449
|
C,
|
|
450
450
|
M,
|
|
451
451
|
T,
|
|
@@ -471,7 +471,7 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
471
471
|
y(!1);
|
|
472
472
|
return;
|
|
473
473
|
}
|
|
474
|
-
|
|
474
|
+
Me("waitingForAudio"), y(!0);
|
|
475
475
|
}, [
|
|
476
476
|
vt,
|
|
477
477
|
S,
|
|
@@ -494,7 +494,7 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
494
494
|
}, [g, v]), s(() => {
|
|
495
495
|
g >= 0 || z.reset();
|
|
496
496
|
}, [g, z]), s(() => {
|
|
497
|
-
|
|
497
|
+
ke(!1);
|
|
498
498
|
}, [en]);
|
|
499
499
|
const St = c(() => {
|
|
500
500
|
if (!o)
|
|
@@ -514,19 +514,19 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
514
514
|
o.user_input,
|
|
515
515
|
e ? void 0 : fe
|
|
516
516
|
);
|
|
517
|
-
}, [o, fe]), At = !!o?.user_input?.trim(), xt = !!o?.readonly || At, It = xt || At,
|
|
517
|
+
}, [o, fe]), At = !!o?.user_input?.trim(), xt = !!o?.readonly || At, It = xt || At, qe = !!o && ge, rn = n(
|
|
518
518
|
(e) => {
|
|
519
519
|
const l = [
|
|
520
520
|
...e.selectedValues ?? [],
|
|
521
521
|
e.inputText?.trim() ?? "",
|
|
522
522
|
e.buttonText?.trim() ?? ""
|
|
523
523
|
].filter(Boolean).join(", ");
|
|
524
|
-
|
|
524
|
+
Ne((f) => !f || !l ? f : {
|
|
525
525
|
...f,
|
|
526
526
|
user_input: l
|
|
527
|
-
}),
|
|
527
|
+
}), ze?.(e, o), xe();
|
|
528
528
|
},
|
|
529
|
-
[o,
|
|
529
|
+
[o, xe, ze]
|
|
530
530
|
);
|
|
531
531
|
s(() => {
|
|
532
532
|
const e = () => {
|
|
@@ -536,11 +536,11 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
536
536
|
document.removeEventListener("fullscreenchange", e);
|
|
537
537
|
};
|
|
538
538
|
}, []), s(() => {
|
|
539
|
-
if (!
|
|
539
|
+
if (!qe) {
|
|
540
540
|
ce(0);
|
|
541
541
|
return;
|
|
542
542
|
}
|
|
543
|
-
const e =
|
|
543
|
+
const e = Xe.current;
|
|
544
544
|
if (!e)
|
|
545
545
|
return;
|
|
546
546
|
const t = () => {
|
|
@@ -559,17 +559,17 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
559
559
|
return l.observe(e), () => {
|
|
560
560
|
l.disconnect();
|
|
561
561
|
};
|
|
562
|
-
}, [
|
|
563
|
-
if (j(), !(!
|
|
562
|
+
}, [qe]), s(() => {
|
|
563
|
+
if (j(), !(!ge || !It))
|
|
564
564
|
return ne.current = window.setTimeout(() => {
|
|
565
|
-
ne.current = null,
|
|
565
|
+
ne.current = null, xe();
|
|
566
566
|
}, 2e3), () => {
|
|
567
567
|
j();
|
|
568
568
|
};
|
|
569
569
|
}, [
|
|
570
570
|
j,
|
|
571
|
-
|
|
572
|
-
|
|
571
|
+
xe,
|
|
572
|
+
ge,
|
|
573
573
|
It
|
|
574
574
|
]);
|
|
575
575
|
const on = (e, t = {}) => e ? e.type === "slot" ? /* @__PURE__ */ r.jsx(r.Fragment, { children: e.content }) : e.type === "html" ? /* @__PURE__ */ r.jsx(
|
|
@@ -608,7 +608,7 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
608
608
|
return /* @__PURE__ */ r.jsx(
|
|
609
609
|
"div",
|
|
610
610
|
{
|
|
611
|
-
ref: t && a === f ?
|
|
611
|
+
ref: t && a === f ? Ye : null,
|
|
612
612
|
"aria-hidden": P || void 0,
|
|
613
613
|
className: J(
|
|
614
614
|
"w-full shrink-0",
|
|
@@ -634,30 +634,30 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
634
634
|
});
|
|
635
635
|
}
|
|
636
636
|
}, []), wt = n(() => {
|
|
637
|
-
const e =
|
|
637
|
+
const e = Re.current;
|
|
638
638
|
e && e.scrollTo({
|
|
639
639
|
top: e.scrollHeight,
|
|
640
640
|
behavior: "smooth"
|
|
641
641
|
});
|
|
642
642
|
}, []), cn = n(
|
|
643
643
|
(e) => {
|
|
644
|
-
|
|
644
|
+
Ie(e), pe.current = !0, D.current = null, se(!0), y(!1), A(!0), $(), tt();
|
|
645
645
|
},
|
|
646
646
|
[
|
|
647
|
-
|
|
647
|
+
tt,
|
|
648
648
|
$,
|
|
649
649
|
A,
|
|
650
|
-
|
|
650
|
+
Ie
|
|
651
651
|
]
|
|
652
652
|
), an = n(
|
|
653
653
|
(e) => {
|
|
654
|
-
|
|
654
|
+
Ie(e), pe.current = !0, D.current = null, se(!0), y(!1), A(!0), $(), C();
|
|
655
655
|
},
|
|
656
656
|
[
|
|
657
657
|
C,
|
|
658
658
|
$,
|
|
659
659
|
A,
|
|
660
|
-
|
|
660
|
+
Ie
|
|
661
661
|
]
|
|
662
662
|
), un = n(
|
|
663
663
|
({
|
|
@@ -672,7 +672,7 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
672
672
|
y(!1);
|
|
673
673
|
return;
|
|
674
674
|
}
|
|
675
|
-
e && t &&
|
|
675
|
+
e && t && Me(t), y(zn(t, e));
|
|
676
676
|
},
|
|
677
677
|
[
|
|
678
678
|
S,
|
|
@@ -717,33 +717,33 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
717
717
|
N
|
|
718
718
|
]
|
|
719
719
|
), fn = n(() => {
|
|
720
|
-
o &&
|
|
720
|
+
o && be((e) => !e);
|
|
721
721
|
}, [o]), _t = n(
|
|
722
722
|
(e) => {
|
|
723
723
|
e.stopPropagation(), k && A(!0);
|
|
724
724
|
},
|
|
725
|
-
[
|
|
725
|
+
[nt, A]
|
|
726
726
|
), mn = n(
|
|
727
727
|
(e) => {
|
|
728
|
-
|
|
728
|
+
We?.(e);
|
|
729
729
|
},
|
|
730
|
-
[
|
|
730
|
+
[We]
|
|
731
731
|
), pn = n(() => {
|
|
732
732
|
se(!0), A(!0);
|
|
733
|
-
}, [A]),
|
|
733
|
+
}, [A]), we = c(
|
|
734
734
|
() => B.map(
|
|
735
735
|
(e, t) => `${e.sequence_number ?? `${e.type}-${t}`}:${String(e.is_new ?? "")}`
|
|
736
736
|
),
|
|
737
737
|
[B]
|
|
738
738
|
);
|
|
739
739
|
return s(() => {
|
|
740
|
-
const e =
|
|
740
|
+
const e = Je.current, f = (e.length > 0 && e.length < we.length && e.every((a, P) => a === we[P]) ? B.slice(e.length) : []).some(
|
|
741
741
|
(a) => a.is_new === !1
|
|
742
742
|
);
|
|
743
|
-
if (
|
|
743
|
+
if (Je.current = we, !f)
|
|
744
744
|
return;
|
|
745
745
|
const i = window.requestAnimationFrame(() => {
|
|
746
|
-
const a =
|
|
746
|
+
const a = Re.current, P = Ye.current;
|
|
747
747
|
if (!a || !P)
|
|
748
748
|
return;
|
|
749
749
|
const hn = a.getBoundingClientRect(), vn = P.getBoundingClientRect(), yn = a.scrollTop + (vn.top - hn.top);
|
|
@@ -755,7 +755,7 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
755
755
|
return () => {
|
|
756
756
|
window.cancelAnimationFrame(i);
|
|
757
757
|
};
|
|
758
|
-
}, [B,
|
|
758
|
+
}, [B, we]), s(() => {
|
|
759
759
|
if (!pe.current || (pe.current = !1, B.length === 0))
|
|
760
760
|
return;
|
|
761
761
|
const e = window.requestAnimationFrame(() => {
|
|
@@ -790,7 +790,7 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
790
790
|
/* @__PURE__ */ r.jsxs(
|
|
791
791
|
"div",
|
|
792
792
|
{
|
|
793
|
-
ref:
|
|
793
|
+
ref: $e,
|
|
794
794
|
className: J(
|
|
795
795
|
"slide__viewport relative h-full min-h-0 w-full",
|
|
796
796
|
H && "slide__viewport--mobile-landscape",
|
|
@@ -824,7 +824,7 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
824
824
|
Ht && "slide__viewport-content--with-header",
|
|
825
825
|
Nt ? "slide-content--single" : "grid gap-4"
|
|
826
826
|
),
|
|
827
|
-
children: B.length > 0 ? /* @__PURE__ */ r.jsx("div", { className: "slide-stage", children: /* @__PURE__ */ r.jsx("div", { ref:
|
|
827
|
+
children: B.length > 0 ? /* @__PURE__ */ r.jsx("div", { className: "slide-stage", children: /* @__PURE__ */ r.jsx("div", { ref: Re, className: "slide-stage__layer w-full", children: Xt.map(
|
|
828
828
|
(e, t) => {
|
|
829
829
|
const l = t === Jt;
|
|
830
830
|
return /* @__PURE__ */ r.jsx(
|
|
@@ -848,7 +848,7 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
848
848
|
Sn,
|
|
849
849
|
{
|
|
850
850
|
message: Un(
|
|
851
|
-
|
|
851
|
+
Ee,
|
|
852
852
|
jt
|
|
853
853
|
),
|
|
854
854
|
className: "absolute left-1/2 top-1/2 z-[3] -translate-x-1/2 -translate-y-1/2"
|
|
@@ -865,10 +865,10 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
865
865
|
subtitleCues: Qt
|
|
866
866
|
}
|
|
867
867
|
),
|
|
868
|
-
|
|
868
|
+
qe ? /* @__PURE__ */ r.jsx(
|
|
869
869
|
"div",
|
|
870
870
|
{
|
|
871
|
-
ref:
|
|
871
|
+
ref: Xe,
|
|
872
872
|
className: J(
|
|
873
873
|
"slide-interaction-overlay",
|
|
874
874
|
k && E ? "slide-interaction-overlay--with-player" : "slide-interaction-overlay--standalone"
|
|
@@ -888,7 +888,7 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
888
888
|
copiedButtonText: q?.copiedButtonText,
|
|
889
889
|
onSend: rn,
|
|
890
890
|
readonly: xt,
|
|
891
|
-
title: q?.title ??
|
|
891
|
+
title: q?.title ?? Pe ?? "Submit the content below to continue."
|
|
892
892
|
}
|
|
893
893
|
)
|
|
894
894
|
}
|
|
@@ -908,13 +908,13 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
908
908
|
isPlaybackPaused: L,
|
|
909
909
|
isAutoAdvanceEnabled: le,
|
|
910
910
|
hasInteraction: !!o,
|
|
911
|
-
isInteractionOpen:
|
|
911
|
+
isInteractionOpen: ge,
|
|
912
912
|
isSubtitleEnabled: it,
|
|
913
|
-
onAutoAdvanceToggle:
|
|
913
|
+
onAutoAdvanceToggle: ot,
|
|
914
914
|
onLoadingChange: un,
|
|
915
915
|
onPlaybackPreferenceChange: tn,
|
|
916
916
|
onPlaybackStarted: () => {
|
|
917
|
-
|
|
917
|
+
ke(!0);
|
|
918
918
|
},
|
|
919
919
|
onPlaybackTimeChange: z.setTime,
|
|
920
920
|
onSubtitleToggle: () => {
|
|
@@ -925,7 +925,7 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
925
925
|
onFullscreen: ln,
|
|
926
926
|
isFullscreen: lt,
|
|
927
927
|
mobileViewMode: G,
|
|
928
|
-
settingsPortalContainer:
|
|
928
|
+
settingsPortalContainer: $e.current,
|
|
929
929
|
onMobileViewModeChange: $t,
|
|
930
930
|
onInteractionToggle: fn,
|
|
931
931
|
onNext: an,
|
|
@@ -933,7 +933,7 @@ const Gn = (b, I) => b.length === I.length && b.every((w, Q) => {
|
|
|
933
933
|
prevDisabled: !Bt,
|
|
934
934
|
showControls: k,
|
|
935
935
|
texts: Rt,
|
|
936
|
-
customActionContext:
|
|
936
|
+
customActionContext: Ke,
|
|
937
937
|
customActions: V,
|
|
938
938
|
useAutoAdvanceToggle: ue
|
|
939
939
|
}
|