markdown-flow-ui 0.2.9-dev.2 → 0.2.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/_virtual/index.cjs3.js +1 -1
- package/dist/_virtual/index.cjs4.js +1 -1
- package/dist/_virtual/index.cjs8.js +1 -1
- package/dist/_virtual/index.cjs9.js +1 -1
- package/dist/_virtual/index.es3.js +5 -4
- package/dist/_virtual/index.es3.js.map +1 -1
- package/dist/_virtual/index.es4.js +4 -5
- package/dist/_virtual/index.es4.js.map +1 -1
- package/dist/_virtual/index.es8.js +2 -2
- package/dist/_virtual/index.es9.js +2 -2
- 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 +412 -402
- package/dist/components/Slide/Slide.es.js.map +1 -1
- package/dist/components/Slide/utils/stepAudioProgress.cjs.js +2 -0
- package/dist/components/Slide/utils/stepAudioProgress.cjs.js.map +1 -0
- package/dist/components/Slide/utils/stepAudioProgress.d.ts +22 -0
- package/dist/components/Slide/utils/stepAudioProgress.es.js +6 -0
- package/dist/components/Slide/utils/stepAudioProgress.es.js.map +1 -0
- package/dist/components/Slide/utils/stepAudioProgress.test.d.ts +1 -0
- package/dist/components/ui/inputGroup/textarea.cjs.js +1 -1
- package/dist/components/ui/inputGroup/textarea.es.js +1 -1
- package/dist/node_modules/@braintree/sanitize-url/dist/index.cjs.js +1 -1
- package/dist/node_modules/@braintree/sanitize-url/dist/index.es.js +1 -1
- package/dist/node_modules/classnames/index.cjs.js +1 -1
- package/dist/node_modules/classnames/index.es.js +1 -1
- package/dist/node_modules/rc-input/es/BaseInput.cjs.js +1 -1
- package/dist/node_modules/rc-input/es/BaseInput.es.js +1 -1
- package/dist/node_modules/rc-textarea/es/ResizableTextArea.cjs.js +1 -1
- package/dist/node_modules/rc-textarea/es/ResizableTextArea.es.js +1 -1
- package/dist/node_modules/rc-textarea/es/TextArea.cjs.js +1 -1
- package/dist/node_modules/rc-textarea/es/TextArea.es.js +1 -1
- package/dist/node_modules/rc-textarea/es/index.cjs.js +1 -1
- package/dist/node_modules/rc-textarea/es/index.es.js +1 -1
- package/dist/node_modules/remark-flow/dist/interaction-plugin-core.cjs.js +1 -1
- package/dist/node_modules/remark-flow/dist/interaction-plugin-core.es.js +1 -1
- package/package.json +1 -1
|
@@ -1,58 +1,59 @@
|
|
|
1
1
|
import { j as a } from "../../_virtual/jsx-runtime.es.js";
|
|
2
|
-
import { memo as
|
|
3
|
-
import { isSandboxInteractionMessage as
|
|
2
|
+
import { memo as Cr, useMemo as d, useId as Pr, useRef as m, useCallback as r, useState as p, useEffect as c, useLayoutEffect as Rr } from "react";
|
|
3
|
+
import { isSandboxInteractionMessage as _r } from "../../lib/sandboxInteraction.es.js";
|
|
4
4
|
import { cn as ve } from "../../lib/utils.es.js";
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import
|
|
5
|
+
import Or from "../ui/loading-overlay-card.es.js";
|
|
6
|
+
import Mr from "../ContentRender/ContentRender.es.js";
|
|
7
|
+
import bn from "../ContentRender/IframeSandbox.es.js";
|
|
8
8
|
import "../ui/inputGroup/input-group.es.js";
|
|
9
9
|
import "../ContentRender/contentRenderI18n.es.js";
|
|
10
|
-
import { isMobileDevice as
|
|
11
|
-
import
|
|
12
|
-
import
|
|
13
|
-
import
|
|
14
|
-
import
|
|
15
|
-
import
|
|
16
|
-
import { PlayerKeyboardShortcutContext as
|
|
17
|
-
import { activatePlayerKeyboardShortcutOwner as
|
|
18
|
-
import { DEFAULT_MOBILE_VIEW_MODE as
|
|
19
|
-
import { shouldRenderInteractionOverlay as
|
|
20
|
-
import { resolveMarkdownScalingMode as
|
|
21
|
-
import { shouldWakePlayerControlsAfterNavigation as
|
|
22
|
-
import { shouldAutoAdvanceIntoAppendedMarker as
|
|
23
|
-
import {
|
|
24
|
-
import {
|
|
25
|
-
import {
|
|
26
|
-
import {
|
|
27
|
-
import {
|
|
28
|
-
import {
|
|
29
|
-
import {
|
|
30
|
-
import {
|
|
31
|
-
import {
|
|
32
|
-
import {
|
|
10
|
+
import { isMobileDevice as kr, isLandscapeViewport as xn, subscribeMobileDeviceChange as Fr } from "../../lib/mobileDevice.es.js";
|
|
11
|
+
import Lr from "./Player.es.js";
|
|
12
|
+
import Nr from "./MarkdownSlideScaling.es.js";
|
|
13
|
+
import Br from "./SubtitleOverlay.es.js";
|
|
14
|
+
import Dr from "./useSlide.es.js";
|
|
15
|
+
import Vr from "./useWakePlayerFromIframe.es.js";
|
|
16
|
+
import { PlayerKeyboardShortcutContext as jr } from "./utils/playerKeyboardShortcutContext.es.js";
|
|
17
|
+
import { activatePlayerKeyboardShortcutOwner as qr } from "./utils/playerKeyboardShortcuts.es.js";
|
|
18
|
+
import { DEFAULT_MOBILE_VIEW_MODE as ot, resolveMobileViewModeState as Kr } from "./utils/mobileScreenMode.es.js";
|
|
19
|
+
import { shouldRenderInteractionOverlay as Ur, clampInteractionOverlayDragOffset as An, shouldPresentInteractionOverlay as Hr } from "./utils/interactionPlayback.es.js";
|
|
20
|
+
import { resolveMarkdownScalingMode as Yr } from "./utils/markdownScaling.es.js";
|
|
21
|
+
import { shouldWakePlayerControlsAfterNavigation as Rt } from "./utils/playerNavigationContext.es.js";
|
|
22
|
+
import { shouldAutoAdvanceIntoAppendedMarker as Gr } from "./utils/appendedMarkerAdvance.es.js";
|
|
23
|
+
import { resolvePendingStepAudioKey as $r, hasUnplayedStepAudio as zr } from "./utils/stepAudioProgress.es.js";
|
|
24
|
+
import { getPlaybackSequenceTransition as Xr, shouldStartDefaultAudioSequence as Jr } from "./utils/playbackSequence.es.js";
|
|
25
|
+
import { hasResolvedInteractionElement as Wr, canReachSubtitleJumpTarget as wn } from "./utils/subtitleJumpNavigation.es.js";
|
|
26
|
+
import { resolvePlayerCustomActionElement as Qr, getPlayerCustomActionCount as Zr } from "./utils/playerCustomActions.es.js";
|
|
27
|
+
import { createPlaybackTimeStore as eo } from "./utils/playbackTimeStore.es.js";
|
|
28
|
+
import { resolveSlideInteractionState as to } from "./utils/interactionResolution.es.js";
|
|
29
|
+
import { shouldUseAutoAdvanceToggle as no } from "./utils/playerToggleMode.es.js";
|
|
30
|
+
import { DEFAULT_IMAGE_ONLY_VISUAL_READY_TIMEOUT_MS as ro, areImageOnlyStepIframeVisualsReady as oo } from "./utils/imageOnlyStepVisualReady.es.js";
|
|
31
|
+
import { resolveSilentStepAutoAdvanceBehavior as io } from "./utils/silentStepAutoAdvance.es.js";
|
|
32
|
+
import { resolveSlidePlayerVisibility as lo } from "./utils/playerVisibility.es.js";
|
|
33
|
+
import { getSlideLocaleTexts as ao, DEFAULT_SLIDE_BUFFERING_TEXTS as so } from "./slideI18n.es.js";
|
|
33
34
|
/* empty css */
|
|
34
|
-
import
|
|
35
|
-
import
|
|
36
|
-
const
|
|
35
|
+
import _t from "../../node_modules/lucide-react/dist/esm/icons/grip-horizontal.es.js";
|
|
36
|
+
import co from "../../node_modules/lucide-react/dist/esm/icons/chevron-left.es.js";
|
|
37
|
+
const uo = 2e3, fo = 300, mo = 160, po = 16, En = 3e3, it = {
|
|
37
38
|
x: 0,
|
|
38
39
|
y: 0
|
|
39
|
-
},
|
|
40
|
+
}, Mt = 0.5, yo = typeof window > "u" ? c : Rr, ho = [
|
|
40
41
|
"button",
|
|
41
42
|
"input",
|
|
42
43
|
"textarea",
|
|
43
44
|
'[contenteditable=""]',
|
|
44
45
|
'[contenteditable="true"]',
|
|
45
46
|
'[contenteditable="plaintext-only"]'
|
|
46
|
-
].join(", "),
|
|
47
|
+
].join(", "), kt = "waitingForAudio", go = ({
|
|
47
48
|
x: u,
|
|
48
49
|
y: f
|
|
49
50
|
}) => ({
|
|
50
51
|
x: Number(u.toFixed(2)),
|
|
51
52
|
y: Number(f.toFixed(2))
|
|
52
|
-
}),
|
|
53
|
+
}), Tn = (u) => Math.abs(u) >= Mt, Cn = (u, f) => Math.abs(u.x - f.x) < Mt && Math.abs(u.y - f.y) < Mt, vo = (u, f) => typeof u == "string" ? u : u[f] ?? u[kt] ?? so[f], So = (u, f) => typeof u == "string" ? u : {
|
|
53
54
|
...f,
|
|
54
55
|
...u
|
|
55
|
-
},
|
|
56
|
+
}, Io = (u, f) => f ? u !== "loadingAudio" : !1, Pn = Cr(
|
|
56
57
|
({
|
|
57
58
|
content: u,
|
|
58
59
|
title: f,
|
|
@@ -63,9 +64,9 @@ const ao = 2e3, so = 300, co = 160, uo = 16, wn = 3e3, rt = {
|
|
|
63
64
|
confirmButtonText: ne,
|
|
64
65
|
copyButtonText: re,
|
|
65
66
|
copiedButtonText: Ve,
|
|
66
|
-
onSend:
|
|
67
|
+
onSend: lt,
|
|
67
68
|
onDragHandlePointerCancel: oe,
|
|
68
|
-
onDragHandlePointerDown:
|
|
69
|
+
onDragHandlePointerDown: at,
|
|
69
70
|
onDragHandlePointerMove: Ie,
|
|
70
71
|
onDragHandlePointerUp: je,
|
|
71
72
|
readonly: qe = !1
|
|
@@ -77,19 +78,19 @@ const ao = 2e3, so = 300, co = 160, uo = 16, wn = 3e3, rt = {
|
|
|
77
78
|
className: "slide-player__interaction-drag-handle",
|
|
78
79
|
"aria-label": "Move interaction",
|
|
79
80
|
onPointerCancel: oe,
|
|
80
|
-
onPointerDown:
|
|
81
|
+
onPointerDown: at,
|
|
81
82
|
onPointerMove: Ie,
|
|
82
83
|
onPointerUp: je,
|
|
83
84
|
children: /* @__PURE__ */ a.jsxs("span", { className: "slide-player__interaction-drag-handle-icon", children: [
|
|
84
|
-
/* @__PURE__ */ a.jsx(
|
|
85
|
-
/* @__PURE__ */ a.jsx(
|
|
86
|
-
/* @__PURE__ */ a.jsx(
|
|
85
|
+
/* @__PURE__ */ a.jsx(_t, { "aria-hidden": "true" }),
|
|
86
|
+
/* @__PURE__ */ a.jsx(_t, { "aria-hidden": "true" }),
|
|
87
|
+
/* @__PURE__ */ a.jsx(_t, { "aria-hidden": "true" })
|
|
87
88
|
] })
|
|
88
89
|
}
|
|
89
90
|
),
|
|
90
91
|
/* @__PURE__ */ a.jsx("div", { className: "slide-player__interaction-header", children: /* @__PURE__ */ a.jsx("p", { className: "slide-player__interaction-title", children: f }) }),
|
|
91
92
|
/* @__PURE__ */ a.jsx("div", { className: "slide-player__interaction-body", children: /* @__PURE__ */ a.jsx(
|
|
92
|
-
|
|
93
|
+
Mr,
|
|
93
94
|
{
|
|
94
95
|
content: u,
|
|
95
96
|
locale: H,
|
|
@@ -99,18 +100,18 @@ const ao = 2e3, so = 300, co = 160, uo = 16, wn = 3e3, rt = {
|
|
|
99
100
|
confirmButtonText: ne,
|
|
100
101
|
copyButtonText: re,
|
|
101
102
|
copiedButtonText: Ve,
|
|
102
|
-
onSend:
|
|
103
|
+
onSend: lt,
|
|
103
104
|
readonly: qe,
|
|
104
105
|
sandboxMode: "content"
|
|
105
106
|
}
|
|
106
107
|
) })
|
|
107
108
|
] })
|
|
108
109
|
);
|
|
109
|
-
|
|
110
|
-
const
|
|
110
|
+
Pn.displayName = "InteractionOverlayCard";
|
|
111
|
+
const bo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
111
112
|
const Y = f[Se];
|
|
112
113
|
return H.sequence_number === Y?.sequence_number && H.type === Y?.type && H.content === Y?.content;
|
|
113
|
-
}),
|
|
114
|
+
}), Ot = (u) => u instanceof HTMLElement && !!u.closest(ho), li = ({
|
|
114
115
|
elementList: u = [],
|
|
115
116
|
locale: f,
|
|
116
117
|
playerEnabled: H,
|
|
@@ -120,44 +121,44 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
120
121
|
playerCustomActions: ne,
|
|
121
122
|
playerCustomActionPauseOnActive: re = !0,
|
|
122
123
|
bufferingText: Ve,
|
|
123
|
-
interactionTitle:
|
|
124
|
+
interactionTitle: lt,
|
|
124
125
|
interactionTexts: oe,
|
|
125
|
-
playerTexts:
|
|
126
|
+
playerTexts: at,
|
|
126
127
|
playerAutoHideDelay: Ie = 3e3,
|
|
127
|
-
markerAutoAdvanceDelay: je =
|
|
128
|
+
markerAutoAdvanceDelay: je = uo,
|
|
128
129
|
interactionDefaultValueOptions: qe,
|
|
129
|
-
onSend:
|
|
130
|
-
onPlayerVisibilityChange:
|
|
131
|
-
onMobileViewModeChange:
|
|
132
|
-
onStepChange:
|
|
130
|
+
onSend: Ft,
|
|
131
|
+
onPlayerVisibilityChange: st,
|
|
132
|
+
onMobileViewModeChange: Lt,
|
|
133
|
+
onStepChange: Nt,
|
|
133
134
|
enableKeyboardShortcuts: ie = !0,
|
|
134
|
-
enableIframeScaling:
|
|
135
|
-
enableMarkdownScaling:
|
|
136
|
-
disableLoadingOverlay:
|
|
137
|
-
className:
|
|
138
|
-
onPointerDown:
|
|
139
|
-
onFocusCapture:
|
|
140
|
-
...
|
|
135
|
+
enableIframeScaling: Rn = !0,
|
|
136
|
+
enableMarkdownScaling: _n = !0,
|
|
137
|
+
disableLoadingOverlay: k = !1,
|
|
138
|
+
className: On,
|
|
139
|
+
onPointerDown: Bt,
|
|
140
|
+
onFocusCapture: Dt,
|
|
141
|
+
...Mn
|
|
141
142
|
}) => {
|
|
142
|
-
const $ = d(() =>
|
|
143
|
-
() =>
|
|
143
|
+
const $ = d(() => ao(f), [f]), kn = d(
|
|
144
|
+
() => So(
|
|
144
145
|
Ve,
|
|
145
146
|
$.bufferingText
|
|
146
147
|
),
|
|
147
148
|
[Ve, $.bufferingText]
|
|
148
149
|
), {
|
|
149
|
-
playerEnabled:
|
|
150
|
+
playerEnabled: Fn,
|
|
150
151
|
playerControlsVisibility: j
|
|
151
|
-
} =
|
|
152
|
+
} = lo({
|
|
152
153
|
playerEnabled: H,
|
|
153
154
|
playerControlsVisibility: Se
|
|
154
|
-
}), Ke =
|
|
155
|
+
}), Ke = Pr(), be = m(null), ct = m(null), Ue = m(null), Vt = m(null), le = m(null), He = m(!1), xe = m(null), Ye = m(null), z = m(null), Ae = m(null), we = m(null), ae = m(null), Ee = m(null), jt = m([]), Te = m(!1), X = m(null), Ce = m(null), qt = m(0), Kt = m(null), Ut = m({
|
|
155
156
|
markerCount: 0,
|
|
156
157
|
currentIndex: -1,
|
|
157
158
|
canGoNext: !1
|
|
158
|
-
}),
|
|
159
|
+
}), ut = m(!1), {
|
|
159
160
|
currentElementList: R,
|
|
160
|
-
stepElementLists:
|
|
161
|
+
stepElementLists: Ht,
|
|
161
162
|
slideElementList: P,
|
|
162
163
|
currentIndex: s,
|
|
163
164
|
audioList: I,
|
|
@@ -165,12 +166,12 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
165
166
|
currentAudioSequenceIndexes: $e,
|
|
166
167
|
currentStepHasSpeakableElement: x,
|
|
167
168
|
currentInteractionElement: y,
|
|
168
|
-
canGoPrev:
|
|
169
|
+
canGoPrev: Ln,
|
|
169
170
|
canGoNext: _,
|
|
170
|
-
handlePrev:
|
|
171
|
-
handleNext:
|
|
172
|
-
handleGoTo:
|
|
173
|
-
} =
|
|
171
|
+
handlePrev: Yt,
|
|
172
|
+
handleNext: F,
|
|
173
|
+
handleGoTo: Gt
|
|
174
|
+
} = Dr(u), Pe = d(() => {
|
|
174
175
|
if (!(s < 0))
|
|
175
176
|
return P[s];
|
|
176
177
|
}, [s, P]), se = d(
|
|
@@ -178,67 +179,67 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
178
179
|
(e, t) => `${e.sequence_number ?? `${e.type}-${t}`}:${String(e.is_new ?? "")}`
|
|
179
180
|
),
|
|
180
181
|
[R]
|
|
181
|
-
),
|
|
182
|
+
), Nn = P.filter(
|
|
182
183
|
(e) => e.is_renderable !== !1
|
|
183
|
-
).length === 1, g =
|
|
184
|
+
).length === 1, g = Fn && (P.length > 0 || I.length > 0 || !!y), Bn = d(
|
|
184
185
|
() => ({
|
|
185
186
|
enabled: ie,
|
|
186
187
|
ownerId: Ke
|
|
187
188
|
}),
|
|
188
189
|
[ie, Ke]
|
|
189
190
|
), q = r(() => {
|
|
190
|
-
!ie || !g ||
|
|
191
|
-
}, [ie, Ke, g]),
|
|
191
|
+
!ie || !g || qr(Ke);
|
|
192
|
+
}, [ie, Ke, g]), O = d(
|
|
192
193
|
() => $e.map((e) => I[e]?.audioKey).filter((e) => !!e),
|
|
193
194
|
[I, $e]
|
|
194
|
-
), [
|
|
195
|
-
|
|
196
|
-
), [
|
|
197
|
-
|
|
195
|
+
), [Dn, Re] = p(!0), [ze, ce] = p(!1), [dt, $t] = p(!0), [_e, zt] = p(!0), [w, K] = p(null), [Vn, Xt] = p(null), [jn, A] = p(!1), [qn, ft] = p(kt), [M, Xe] = p(!1), Je = m(/* @__PURE__ */ new Set()), [Kn, We] = p(!1), [Jt, Un] = p(!0), [mt, pt] = p(!1), [h, yt] = p(), [ue, Qe] = p(!1), [Wt, Ze] = p(!1), [E, ht] = p(
|
|
196
|
+
it
|
|
197
|
+
), [gt, vt] = p(!1), [
|
|
198
|
+
Hn,
|
|
198
199
|
Oe
|
|
199
|
-
] =
|
|
200
|
-
|
|
201
|
-
), [
|
|
202
|
-
() => D ?
|
|
203
|
-
), de = d(() =>
|
|
200
|
+
] = p(0), [Qt, Yn] = p(!1), D = d(() => kr(), []), [et, St] = p(
|
|
201
|
+
ot
|
|
202
|
+
), [Zt, It] = p(!1), [Gn, en] = p(
|
|
203
|
+
() => D ? xn() : !1
|
|
204
|
+
), de = d(() => eo(), []), {
|
|
204
205
|
effectiveMobileViewMode: J,
|
|
205
206
|
isImmersiveMobileFullscreen: fe,
|
|
206
|
-
isNativeMobileFullscreen:
|
|
207
|
-
shouldRotateFullscreenViewport:
|
|
207
|
+
isNativeMobileFullscreen: tn,
|
|
208
|
+
shouldRotateFullscreenViewport: $n
|
|
208
209
|
} = d(
|
|
209
|
-
() =>
|
|
210
|
-
hasManualMobileViewMode:
|
|
210
|
+
() => Kr({
|
|
211
|
+
hasManualMobileViewMode: Zt,
|
|
211
212
|
isMobileDevice: D,
|
|
212
|
-
mobileViewMode:
|
|
213
|
+
mobileViewMode: et
|
|
213
214
|
}),
|
|
214
215
|
[
|
|
215
|
-
|
|
216
|
+
Zt,
|
|
216
217
|
D,
|
|
217
|
-
|
|
218
|
-
|
|
218
|
+
Gn,
|
|
219
|
+
et
|
|
219
220
|
]
|
|
220
|
-
),
|
|
221
|
+
), nn = m(J), T = g && j !== "hidden" && (j === "visible" || Dn), zn = fe && T, Xn = fe && T, Jn = fe || tn, rn = Qt && !D, Wn = r(
|
|
221
222
|
(e) => {
|
|
222
|
-
|
|
223
|
+
It(!0), St(e);
|
|
223
224
|
},
|
|
224
225
|
[]
|
|
225
|
-
),
|
|
226
|
-
|
|
227
|
-
}, []),
|
|
228
|
-
|
|
229
|
-
}, [G,
|
|
230
|
-
|
|
231
|
-
}, []),
|
|
232
|
-
|
|
226
|
+
), on = r(() => {
|
|
227
|
+
It(!1), St(ot);
|
|
228
|
+
}, []), Qn = r(() => {
|
|
229
|
+
on(), G?.onBack?.();
|
|
230
|
+
}, [G, on]), ln = r((e) => {
|
|
231
|
+
pt(e);
|
|
232
|
+
}, []), an = r(() => {
|
|
233
|
+
pt((e) => !e);
|
|
233
234
|
}, []), W = r(() => {
|
|
234
|
-
|
|
235
|
-
(e) => e.x ===
|
|
236
|
-
),
|
|
237
|
-
}, []), { mountedStepStates:
|
|
235
|
+
ht(
|
|
236
|
+
(e) => e.x === it.x && e.y === it.y ? e : it
|
|
237
|
+
), vt(!1), Ee.current = null, ae.current = null;
|
|
238
|
+
}, []), { mountedStepStates: Zn, currentMountedStateIndex: er } = d(() => {
|
|
238
239
|
const e = [], t = /* @__PURE__ */ new Map();
|
|
239
|
-
return
|
|
240
|
+
return Ht.forEach((n, i) => {
|
|
240
241
|
const l = e.findIndex(
|
|
241
|
-
(o) =>
|
|
242
|
+
(o) => bo(
|
|
242
243
|
o.elementList,
|
|
243
244
|
n
|
|
244
245
|
)
|
|
@@ -255,17 +256,17 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
255
256
|
mountedStepStates: e,
|
|
256
257
|
currentMountedStateIndex: s >= 0 ? t.get(s) ?? -1 : -1
|
|
257
258
|
};
|
|
258
|
-
}, [s,
|
|
259
|
+
}, [s, Ht]), sn = d(() => String(s), [s]), C = d(() => w ? I.findIndex(
|
|
259
260
|
(e) => (e.audioKey ?? "") === w
|
|
260
|
-
) : -1, [I, w]),
|
|
261
|
+
) : -1, [I, w]), bt = d(
|
|
261
262
|
() => C >= 0 ? I[C] : void 0,
|
|
262
263
|
[I, C]
|
|
263
|
-
),
|
|
264
|
-
() =>
|
|
265
|
-
[
|
|
266
|
-
),
|
|
264
|
+
), tr = bt?.element?.subtitle_cues ?? [], tt = d(
|
|
265
|
+
() => O[0] ?? "none",
|
|
266
|
+
[O]
|
|
267
|
+
), xt = d(
|
|
267
268
|
() => ({
|
|
268
|
-
currentElement:
|
|
269
|
+
currentElement: Qr({
|
|
269
270
|
currentAudioIndex: C,
|
|
270
271
|
currentAudioSequenceIndexes: $e,
|
|
271
272
|
audioList: I,
|
|
@@ -274,9 +275,9 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
274
275
|
}),
|
|
275
276
|
currentIndex: s,
|
|
276
277
|
currentStepElement: Pe,
|
|
277
|
-
isActive:
|
|
278
|
-
setActive:
|
|
279
|
-
toggleActive:
|
|
278
|
+
isActive: mt,
|
|
279
|
+
setActive: ln,
|
|
280
|
+
toggleActive: an
|
|
280
281
|
}),
|
|
281
282
|
[
|
|
282
283
|
h,
|
|
@@ -285,21 +286,21 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
285
286
|
$e,
|
|
286
287
|
s,
|
|
287
288
|
Pe,
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
289
|
+
mt,
|
|
290
|
+
ln,
|
|
291
|
+
an
|
|
291
292
|
]
|
|
292
|
-
),
|
|
293
|
-
() =>
|
|
293
|
+
), At = d(
|
|
294
|
+
() => Zr(
|
|
294
295
|
ne,
|
|
295
|
-
|
|
296
|
+
xt
|
|
296
297
|
),
|
|
297
|
-
[
|
|
298
|
-
),
|
|
298
|
+
[xt, ne]
|
|
299
|
+
), nr = d(
|
|
299
300
|
() => ({
|
|
300
|
-
"--slide-player-custom-action-count": String(
|
|
301
|
+
"--slide-player-custom-action-count": String(At),
|
|
301
302
|
"--slide-player-mobile-control-count": String(
|
|
302
|
-
|
|
303
|
+
At + 4
|
|
303
304
|
),
|
|
304
305
|
"--slide-interaction-drag-x": `${E.x}px`,
|
|
305
306
|
"--slide-interaction-drag-y": `${E.y}px`
|
|
@@ -307,24 +308,24 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
307
308
|
[
|
|
308
309
|
E.x,
|
|
309
310
|
E.y,
|
|
310
|
-
|
|
311
|
+
At
|
|
311
312
|
]
|
|
312
|
-
),
|
|
313
|
+
), cn = O.length > 0, un = d(() => y ? `${y.sequence_number ?? "none"}:${String(
|
|
313
314
|
y.content ?? ""
|
|
314
315
|
)}` : "none", [y]), Me = d(
|
|
315
|
-
() => [
|
|
316
|
-
[
|
|
317
|
-
),
|
|
316
|
+
() => [sn, un].join("|"),
|
|
317
|
+
[un, sn]
|
|
318
|
+
), rr = d(
|
|
318
319
|
() => [
|
|
319
320
|
Me,
|
|
320
|
-
|
|
321
|
+
bt?.audioKey ?? "none",
|
|
321
322
|
String(C)
|
|
322
323
|
].join("|"),
|
|
323
|
-
[C,
|
|
324
|
-
),
|
|
325
|
-
(t) => t.audioKey ===
|
|
326
|
-
)?.audioUrl?.trim() ?? "", [I,
|
|
327
|
-
() =>
|
|
324
|
+
[C, bt?.audioKey, Me]
|
|
325
|
+
), dn = !!d(() => !tt || tt === "none" ? "" : I.find(
|
|
326
|
+
(t) => t.audioKey === tt
|
|
327
|
+
)?.audioUrl?.trim() ?? "", [I, tt]), Q = re && !!ne && mt, ke = d(
|
|
328
|
+
() => no({
|
|
328
329
|
canGoNext: _,
|
|
329
330
|
currentAudioIndex: C,
|
|
330
331
|
currentStepHasSpeakableElement: x,
|
|
@@ -336,8 +337,8 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
336
337
|
y,
|
|
337
338
|
x
|
|
338
339
|
]
|
|
339
|
-
),
|
|
340
|
-
() =>
|
|
340
|
+
), fn = d(
|
|
341
|
+
() => io({
|
|
341
342
|
currentElementList: R,
|
|
342
343
|
currentStepHasSpeakableElement: x,
|
|
343
344
|
currentInteractionElement: y,
|
|
@@ -349,10 +350,10 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
349
350
|
x,
|
|
350
351
|
je
|
|
351
352
|
]
|
|
352
|
-
),
|
|
353
|
+
), mn = fn.delayMs, Fe = fn.usesImageOnlyDelay, wt = d(
|
|
353
354
|
() => `${s}:${se.join("|")}`,
|
|
354
355
|
[s, se]
|
|
355
|
-
), [
|
|
356
|
+
), [or, ir] = p(null), pn = !Fe || or === wt, V = r(() => {
|
|
356
357
|
le.current !== null && (window.clearTimeout(le.current), le.current = null);
|
|
357
358
|
}, []), L = r(() => {
|
|
358
359
|
z.current !== null && (window.clearTimeout(z.current), z.current = null);
|
|
@@ -364,7 +365,7 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
364
365
|
Ye.current !== null && (window.clearTimeout(Ye.current), Ye.current = null);
|
|
365
366
|
}, []), B = r(
|
|
366
367
|
(e = {}) => {
|
|
367
|
-
me(), L(), N(), U(), K(null), de.reset(), A(!1),
|
|
368
|
+
me(), L(), N(), U(), K(null), de.reset(), A(!1), ft(kt), Xe(!1), Je.current = /* @__PURE__ */ new Set(), We(!1), Xt(null), e.preservePendingSubtitleJump || (Ce.current = null), yt(void 0), Qe(!1), Oe(0);
|
|
368
369
|
},
|
|
369
370
|
[
|
|
370
371
|
me,
|
|
@@ -373,47 +374,50 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
373
374
|
N,
|
|
374
375
|
de
|
|
375
376
|
]
|
|
376
|
-
),
|
|
377
|
+
), nt = r(
|
|
377
378
|
(e) => {
|
|
378
|
-
|
|
379
|
+
qt.current += 1, Xt({
|
|
379
380
|
...e,
|
|
380
|
-
id:
|
|
381
|
+
id: qt.current
|
|
381
382
|
});
|
|
382
383
|
},
|
|
383
384
|
[]
|
|
384
385
|
), pe = r(() => {
|
|
385
|
-
const e =
|
|
386
|
+
const e = $r(
|
|
387
|
+
O,
|
|
388
|
+
Je.current
|
|
389
|
+
);
|
|
386
390
|
return e ? (K(e), !0) : !1;
|
|
387
|
-
}, [
|
|
388
|
-
L(), N(),
|
|
391
|
+
}, [O]), Le = r(() => {
|
|
392
|
+
L(), N(), Qe(!1), Oe(0), !pe() && _ && F();
|
|
389
393
|
}, [
|
|
390
394
|
_,
|
|
391
395
|
L,
|
|
392
396
|
N,
|
|
393
|
-
|
|
397
|
+
F,
|
|
394
398
|
pe
|
|
395
|
-
]),
|
|
399
|
+
]), yn = r(
|
|
396
400
|
(e) => {
|
|
397
401
|
if (N(), !e)
|
|
398
402
|
return;
|
|
399
403
|
const t = () => {
|
|
400
404
|
Ae.current = null, Oe(
|
|
401
|
-
|
|
402
|
-
),
|
|
405
|
+
mo
|
|
406
|
+
), Qe(!0), X.current = null;
|
|
403
407
|
};
|
|
404
408
|
Ae.current = window.setTimeout(
|
|
405
409
|
t,
|
|
406
|
-
|
|
410
|
+
fo
|
|
407
411
|
);
|
|
408
412
|
},
|
|
409
413
|
[N]
|
|
410
|
-
),
|
|
414
|
+
), Et = r(
|
|
411
415
|
() => He.current || !!be.current?.querySelector(".slide-player__controls:hover"),
|
|
412
416
|
[]
|
|
413
417
|
), v = r(
|
|
414
418
|
(e = ze) => {
|
|
415
|
-
!g || j === "hidden" || (Re(!0), V(), !(j === "visible" || !e || Ie <= 0 ||
|
|
416
|
-
if (
|
|
419
|
+
!g || j === "hidden" || (Re(!0), V(), !(j === "visible" || !e || Ie <= 0 || Et()) && (le.current = window.setTimeout(() => {
|
|
420
|
+
if (Et()) {
|
|
417
421
|
le.current = null;
|
|
418
422
|
return;
|
|
419
423
|
}
|
|
@@ -423,23 +427,23 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
423
427
|
[
|
|
424
428
|
V,
|
|
425
429
|
ze,
|
|
426
|
-
|
|
430
|
+
Et,
|
|
427
431
|
Ie,
|
|
428
432
|
j,
|
|
429
433
|
g
|
|
430
434
|
]
|
|
431
|
-
), Ne = !!
|
|
432
|
-
|
|
435
|
+
), Ne = !!Wr(y), ye = !!y && !Ne, lr = r((e) => {
|
|
436
|
+
$t(e);
|
|
433
437
|
}, []), he = r(
|
|
434
438
|
(e) => {
|
|
435
|
-
e &&
|
|
439
|
+
e && $t(e.shouldContinuePlayback);
|
|
436
440
|
},
|
|
437
441
|
[]
|
|
438
442
|
);
|
|
439
443
|
c(() => {
|
|
440
|
-
|
|
441
|
-
}, [s,
|
|
442
|
-
re &&
|
|
444
|
+
zt(dt);
|
|
445
|
+
}, [s, dt, re]), c(() => {
|
|
446
|
+
re && pt(!1);
|
|
443
447
|
}, [s, re]), c(() => () => {
|
|
444
448
|
me(), U(), V(), L(), N();
|
|
445
449
|
}, [
|
|
@@ -457,7 +461,7 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
457
461
|
const i = () => {
|
|
458
462
|
n?.(), n = null;
|
|
459
463
|
}, l = () => {
|
|
460
|
-
e || (i(), U(),
|
|
464
|
+
e || (i(), U(), ir(wt));
|
|
461
465
|
}, o = () => {
|
|
462
466
|
if (e)
|
|
463
467
|
return;
|
|
@@ -470,7 +474,7 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
470
474
|
const b = Array.from(
|
|
471
475
|
S.querySelectorAll("iframe")
|
|
472
476
|
);
|
|
473
|
-
if (b.length === 0 ||
|
|
477
|
+
if (b.length === 0 || oo(b)) {
|
|
474
478
|
l();
|
|
475
479
|
return;
|
|
476
480
|
}
|
|
@@ -478,7 +482,7 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
478
482
|
e || (t !== null && window.cancelAnimationFrame(t), t = window.requestAnimationFrame(() => {
|
|
479
483
|
t = null, o();
|
|
480
484
|
}));
|
|
481
|
-
},
|
|
485
|
+
}, Pt = (ee, ge, te) => {
|
|
482
486
|
ee.addEventListener(ge, te, { once: !0 }), Z.push(
|
|
483
487
|
() => ee.removeEventListener(ge, te)
|
|
484
488
|
);
|
|
@@ -486,11 +490,11 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
486
490
|
b.forEach((ee) => {
|
|
487
491
|
const ge = ee.contentDocument;
|
|
488
492
|
if (!ge || ge.readyState !== "complete") {
|
|
489
|
-
|
|
493
|
+
Pt(ee, "load", De);
|
|
490
494
|
return;
|
|
491
495
|
}
|
|
492
496
|
Array.from(ge.images).filter((te) => !te.complete).forEach((te) => {
|
|
493
|
-
|
|
497
|
+
Pt(te, "load", De), Pt(te, "error", De);
|
|
494
498
|
});
|
|
495
499
|
}), n = () => {
|
|
496
500
|
Z.forEach((ee) => ee());
|
|
@@ -500,28 +504,28 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
500
504
|
t = null, o();
|
|
501
505
|
}), Ye.current = window.setTimeout(() => {
|
|
502
506
|
l();
|
|
503
|
-
},
|
|
507
|
+
}, ro), () => {
|
|
504
508
|
e = !0, i(), U(), t !== null && window.cancelAnimationFrame(t);
|
|
505
509
|
};
|
|
506
510
|
}, [
|
|
507
511
|
U,
|
|
508
512
|
R,
|
|
509
513
|
s,
|
|
510
|
-
|
|
514
|
+
wt,
|
|
511
515
|
Fe
|
|
512
|
-
]), c(() => (
|
|
513
|
-
|
|
514
|
-
}), [
|
|
516
|
+
]), c(() => (st?.(T), () => {
|
|
517
|
+
st?.(!1);
|
|
518
|
+
}), [st, T]), c(() => {
|
|
515
519
|
T || (He.current = !1);
|
|
516
520
|
}, [T]), c(() => {
|
|
517
|
-
D ||
|
|
518
|
-
}, [D,
|
|
521
|
+
D || et === ot || (It(!1), St(ot));
|
|
522
|
+
}, [D, et]), c(() => {
|
|
519
523
|
if (!D) {
|
|
520
|
-
|
|
524
|
+
en(!1);
|
|
521
525
|
return;
|
|
522
526
|
}
|
|
523
527
|
const e = () => {
|
|
524
|
-
|
|
528
|
+
en(xn()), W();
|
|
525
529
|
}, t = () => {
|
|
526
530
|
W();
|
|
527
531
|
};
|
|
@@ -529,7 +533,7 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
529
533
|
"change",
|
|
530
534
|
t
|
|
531
535
|
);
|
|
532
|
-
const n =
|
|
536
|
+
const n = Fr(
|
|
533
537
|
e
|
|
534
538
|
);
|
|
535
539
|
return () => {
|
|
@@ -539,13 +543,13 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
539
543
|
);
|
|
540
544
|
};
|
|
541
545
|
}, [D, W]), c(() => {
|
|
542
|
-
|
|
543
|
-
}, [J,
|
|
544
|
-
|
|
546
|
+
Lt?.(J);
|
|
547
|
+
}, [J, Lt]), c(() => {
|
|
548
|
+
nn.current !== J && W(), nn.current = J;
|
|
545
549
|
}, [J, W]), c(() => {
|
|
546
|
-
|
|
547
|
-
}, [s, Pe,
|
|
548
|
-
const e =
|
|
550
|
+
Nt?.(Pe, s);
|
|
551
|
+
}, [s, Pe, Nt]), c(() => {
|
|
552
|
+
const e = Ut.current, t = Gr(
|
|
549
553
|
{
|
|
550
554
|
previousMarkerCount: e.markerCount,
|
|
551
555
|
nextMarkerCount: P.length,
|
|
@@ -553,7 +557,7 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
553
557
|
previousCanGoNext: e.canGoNext,
|
|
554
558
|
nextCanGoNext: _,
|
|
555
559
|
currentAudioKey: w,
|
|
556
|
-
hasCompletedCurrentStepAudio:
|
|
560
|
+
hasCompletedCurrentStepAudio: M,
|
|
557
561
|
hasResolvedCurrentInteraction: Ne,
|
|
558
562
|
currentStepHasSpeakableElement: x,
|
|
559
563
|
currentInteractionElement: y,
|
|
@@ -561,19 +565,19 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
561
565
|
shouldUseSilentStepAutoAdvanceToggle: ke
|
|
562
566
|
}
|
|
563
567
|
);
|
|
564
|
-
|
|
568
|
+
Ut.current = {
|
|
565
569
|
markerCount: P.length,
|
|
566
570
|
currentIndex: s,
|
|
567
571
|
canGoNext: _
|
|
568
|
-
}, t &&
|
|
572
|
+
}, t && F();
|
|
569
573
|
}, [
|
|
570
574
|
_,
|
|
571
575
|
w,
|
|
572
576
|
s,
|
|
573
577
|
y,
|
|
574
578
|
x,
|
|
575
|
-
M,
|
|
576
579
|
F,
|
|
580
|
+
M,
|
|
577
581
|
Ne,
|
|
578
582
|
_e,
|
|
579
583
|
ke,
|
|
@@ -598,12 +602,12 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
598
602
|
if (typeof window > "u")
|
|
599
603
|
return;
|
|
600
604
|
const e = (t) => {
|
|
601
|
-
t.origin === window.location.origin &&
|
|
605
|
+
t.origin === window.location.origin && _r(t.data) && t.data.eventType === "click" && g && (q(), ce(!0), v(!0));
|
|
602
606
|
};
|
|
603
607
|
return window.addEventListener("message", e), () => {
|
|
604
608
|
window.removeEventListener("message", e);
|
|
605
609
|
};
|
|
606
|
-
}, [q, g, v]),
|
|
610
|
+
}, [q, g, v]), Vr({
|
|
607
611
|
sectionRef: be,
|
|
608
612
|
enabled: g,
|
|
609
613
|
keyboardShortcutsEnabled: ie,
|
|
@@ -616,14 +620,14 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
616
620
|
B();
|
|
617
621
|
return;
|
|
618
622
|
}
|
|
619
|
-
const { hasPlaybackContextChanged: e, shouldInitializeAudioSequence: t } =
|
|
620
|
-
previousResetKey:
|
|
623
|
+
const { hasPlaybackContextChanged: e, shouldInitializeAudioSequence: t } = Xr({
|
|
624
|
+
previousResetKey: Kt.current,
|
|
621
625
|
nextResetKey: Me,
|
|
622
626
|
currentAudioKey: w,
|
|
623
|
-
hasCompletedCurrentStepAudio:
|
|
627
|
+
hasCompletedCurrentStepAudio: M
|
|
624
628
|
});
|
|
625
|
-
|
|
626
|
-
const n = X.current === s && !!y, i =
|
|
629
|
+
Kt.current = Me;
|
|
630
|
+
const n = X.current === s && !!y, i = Hr({
|
|
627
631
|
hasInteraction: !!y,
|
|
628
632
|
shouldBlockPlaybackForInteraction: ye,
|
|
629
633
|
shouldOpenInteractionOverlayAfterAudio: n,
|
|
@@ -634,35 +638,35 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
634
638
|
if (e && B({
|
|
635
639
|
preservePendingSubtitleJump: o
|
|
636
640
|
}), !(R.length === 0 && !y) && !Q) {
|
|
637
|
-
if (l?.slideIndex === s &&
|
|
641
|
+
if (l?.slideIndex === s && wn({
|
|
638
642
|
currentIndex: s,
|
|
639
643
|
resolvedCurrentInteractionElement: h,
|
|
640
644
|
slideElementList: P,
|
|
641
645
|
targetSlideIndex: l.slideIndex
|
|
642
646
|
})) {
|
|
643
|
-
Ce.current = null,
|
|
647
|
+
Ce.current = null, ut.current = !0, K(l.audioKey), nt({
|
|
644
648
|
audioIndex: l.audioIndex,
|
|
645
649
|
timeMs: l.timeMs
|
|
646
650
|
});
|
|
647
651
|
return;
|
|
648
652
|
}
|
|
649
|
-
if (y &&
|
|
650
|
-
|
|
653
|
+
if (y && yt(y), i) {
|
|
654
|
+
yn(y);
|
|
651
655
|
return;
|
|
652
656
|
}
|
|
653
657
|
if (N(), X.current = null, !!t && !pe()) {
|
|
654
658
|
if (x) {
|
|
655
|
-
if (
|
|
659
|
+
if (k) {
|
|
656
660
|
A(!1);
|
|
657
661
|
return;
|
|
658
662
|
}
|
|
659
663
|
A(!0);
|
|
660
664
|
return;
|
|
661
665
|
}
|
|
662
|
-
if (_ && !(ke && !_e) && !(Fe && !
|
|
666
|
+
if (_ && !(ke && !_e) && !(Fe && !pn))
|
|
663
667
|
return xe.current = window.setTimeout(() => {
|
|
664
|
-
xe.current = null,
|
|
665
|
-
},
|
|
668
|
+
xe.current = null, F();
|
|
669
|
+
}, mn), () => {
|
|
666
670
|
me();
|
|
667
671
|
};
|
|
668
672
|
}
|
|
@@ -678,60 +682,65 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
678
682
|
Me,
|
|
679
683
|
x,
|
|
680
684
|
Fe,
|
|
685
|
+
pn,
|
|
681
686
|
mn,
|
|
682
|
-
fn,
|
|
683
|
-
M,
|
|
684
687
|
F,
|
|
685
|
-
|
|
688
|
+
M,
|
|
689
|
+
k,
|
|
686
690
|
_e,
|
|
687
691
|
Ne,
|
|
688
692
|
ye,
|
|
689
693
|
N,
|
|
690
694
|
B,
|
|
691
|
-
|
|
692
|
-
|
|
695
|
+
nt,
|
|
696
|
+
yn,
|
|
693
697
|
g,
|
|
694
698
|
P,
|
|
695
699
|
pe,
|
|
696
700
|
Q,
|
|
697
701
|
ke
|
|
698
702
|
]), c(() => {
|
|
699
|
-
if (
|
|
703
|
+
if (k || Q || !x || ye) {
|
|
700
704
|
A(!1);
|
|
701
705
|
return;
|
|
702
706
|
}
|
|
703
|
-
if (
|
|
707
|
+
if (M) {
|
|
704
708
|
A(!1);
|
|
705
709
|
return;
|
|
706
710
|
}
|
|
707
|
-
if (
|
|
711
|
+
if (cn) {
|
|
708
712
|
A(!1);
|
|
709
713
|
return;
|
|
710
714
|
}
|
|
711
|
-
|
|
715
|
+
ft("waitingForAudio"), A(!0);
|
|
712
716
|
}, [
|
|
713
|
-
|
|
717
|
+
cn,
|
|
714
718
|
x,
|
|
715
|
-
|
|
716
|
-
|
|
719
|
+
M,
|
|
720
|
+
k,
|
|
717
721
|
Q,
|
|
718
722
|
ye
|
|
719
723
|
]), c(() => {
|
|
720
|
-
|
|
721
|
-
|
|
724
|
+
M && zr(
|
|
725
|
+
O,
|
|
726
|
+
Je.current
|
|
727
|
+
) && Xe(!1);
|
|
728
|
+
}, [O, M]), c(() => {
|
|
729
|
+
const e = ut.current;
|
|
730
|
+
ut.current = !1, Jr({
|
|
722
731
|
currentAudioKey: w,
|
|
723
|
-
currentAudioSequenceLength:
|
|
732
|
+
currentAudioSequenceLength: O.length,
|
|
724
733
|
currentStepHasSpeakableElement: x,
|
|
725
|
-
hasCompletedCurrentStepAudio:
|
|
734
|
+
hasCompletedCurrentStepAudio: M,
|
|
726
735
|
shouldBlockPlaybackForInteraction: ye,
|
|
727
736
|
shouldPausePlaybackForCustomAction: Q,
|
|
728
737
|
shouldSkipDefaultAudioStart: e
|
|
729
738
|
}) && pe();
|
|
730
739
|
}, [
|
|
731
740
|
w,
|
|
732
|
-
|
|
741
|
+
O,
|
|
733
742
|
x,
|
|
734
|
-
|
|
743
|
+
M,
|
|
735
744
|
Q,
|
|
736
745
|
ye,
|
|
737
746
|
pe
|
|
@@ -740,45 +749,45 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
740
749
|
}, [C, w]), c(() => {
|
|
741
750
|
C >= 0 || de.reset();
|
|
742
751
|
}, [C, de]), c(() => {
|
|
743
|
-
|
|
744
|
-
}, [
|
|
752
|
+
We(!1);
|
|
753
|
+
}, [rr]);
|
|
745
754
|
const {
|
|
746
|
-
interactionDefaults:
|
|
747
|
-
interactionDefaultSelectedValues:
|
|
748
|
-
hasResolvedInteractionInput:
|
|
749
|
-
isInteractionReadonly:
|
|
750
|
-
shouldAutoContinueInteraction:
|
|
755
|
+
interactionDefaults: hn,
|
|
756
|
+
interactionDefaultSelectedValues: ar,
|
|
757
|
+
hasResolvedInteractionInput: gn,
|
|
758
|
+
isInteractionReadonly: sr,
|
|
759
|
+
shouldAutoContinueInteraction: vn
|
|
751
760
|
} = d(
|
|
752
|
-
() =>
|
|
761
|
+
() => to(h, {
|
|
753
762
|
interactionDefaultValueOptions: qe
|
|
754
763
|
}),
|
|
755
764
|
[h, qe]
|
|
756
|
-
),
|
|
765
|
+
), cr = !!h?.readonly || sr, Be = Ur({
|
|
757
766
|
hasActiveInteraction: !!h,
|
|
758
767
|
isInteractionOverlayOpen: ue
|
|
759
|
-
}),
|
|
768
|
+
}), ur = r(
|
|
760
769
|
(e) => {
|
|
761
770
|
const n = [
|
|
762
771
|
...e.selectedValues ?? [],
|
|
763
772
|
e.inputText?.trim() ?? "",
|
|
764
773
|
e.buttonText?.trim() ?? ""
|
|
765
774
|
].filter(Boolean).join(", ");
|
|
766
|
-
|
|
775
|
+
yt((i) => !i || !n ? i : {
|
|
767
776
|
...i,
|
|
768
777
|
user_input: n
|
|
769
|
-
}),
|
|
778
|
+
}), Ft?.(e, h), Le();
|
|
770
779
|
},
|
|
771
|
-
[h, Le,
|
|
780
|
+
[h, Le, Ft]
|
|
772
781
|
);
|
|
773
782
|
c(() => {
|
|
774
783
|
const e = () => {
|
|
775
|
-
|
|
784
|
+
Yn(document.fullscreenElement === be.current);
|
|
776
785
|
};
|
|
777
786
|
return e(), document.addEventListener("fullscreenchange", e), () => {
|
|
778
787
|
document.removeEventListener("fullscreenchange", e);
|
|
779
788
|
};
|
|
780
789
|
}, []), c(() => {
|
|
781
|
-
h && ue ||
|
|
790
|
+
h && ue || Ze(!1);
|
|
782
791
|
}, [h, ue]), c(() => {
|
|
783
792
|
W();
|
|
784
793
|
}, [h, W]), c(() => {
|
|
@@ -794,7 +803,7 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
794
803
|
e.getBoundingClientRect().height
|
|
795
804
|
);
|
|
796
805
|
Oe(
|
|
797
|
-
i +
|
|
806
|
+
i + po
|
|
798
807
|
);
|
|
799
808
|
};
|
|
800
809
|
if (t(), typeof ResizeObserver > "u")
|
|
@@ -807,62 +816,62 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
807
816
|
};
|
|
808
817
|
}, [Be]), c(() => {
|
|
809
818
|
if (L(), !!ue) {
|
|
810
|
-
if (
|
|
819
|
+
if (vn)
|
|
811
820
|
return z.current = window.setTimeout(() => {
|
|
812
821
|
z.current = null, Le();
|
|
813
|
-
},
|
|
822
|
+
}, En), () => {
|
|
814
823
|
L();
|
|
815
824
|
};
|
|
816
|
-
if (!(
|
|
825
|
+
if (!(Wt || !gn))
|
|
817
826
|
return z.current = window.setTimeout(() => {
|
|
818
827
|
z.current = null, Le();
|
|
819
|
-
},
|
|
828
|
+
}, En), () => {
|
|
820
829
|
L();
|
|
821
830
|
};
|
|
822
831
|
}
|
|
823
832
|
}, [
|
|
824
833
|
L,
|
|
825
834
|
Le,
|
|
826
|
-
|
|
827
|
-
|
|
835
|
+
Wt,
|
|
836
|
+
gn,
|
|
828
837
|
ue,
|
|
829
|
-
|
|
838
|
+
vn
|
|
830
839
|
]);
|
|
831
|
-
const
|
|
832
|
-
|
|
840
|
+
const dr = (e, t = {}) => e ? e.type === "slot" ? /* @__PURE__ */ a.jsx(a.Fragment, { children: e.content }) : e.type === "html" ? /* @__PURE__ */ a.jsx(
|
|
841
|
+
bn,
|
|
833
842
|
{
|
|
834
843
|
className: "content-render-iframe",
|
|
835
|
-
disableLoadingOverlay:
|
|
844
|
+
disableLoadingOverlay: k,
|
|
836
845
|
hideFullScreen: !0,
|
|
837
846
|
locale: f,
|
|
838
847
|
mode: "blackboard",
|
|
839
848
|
replaceRootScreenHeightWithFull: t.replaceRootScreenHeightWithFull,
|
|
840
849
|
type: "sandbox",
|
|
841
850
|
content: e.content,
|
|
842
|
-
enableScaling:
|
|
851
|
+
enableScaling: Rn
|
|
843
852
|
}
|
|
844
853
|
) : /* @__PURE__ */ a.jsx(
|
|
845
|
-
|
|
854
|
+
bn,
|
|
846
855
|
{
|
|
847
856
|
className: "content-render-iframe",
|
|
848
|
-
disableLoadingOverlay:
|
|
857
|
+
disableLoadingOverlay: k,
|
|
849
858
|
hideFullScreen: !0,
|
|
850
859
|
locale: f,
|
|
851
860
|
mode: "blackboard",
|
|
852
861
|
type: "markdown",
|
|
853
862
|
content: e.content
|
|
854
863
|
}
|
|
855
|
-
) : null,
|
|
864
|
+
) : null, fr = (e = [], t = !1) => {
|
|
856
865
|
if (e.length === 0)
|
|
857
866
|
return null;
|
|
858
867
|
const n = e.filter(
|
|
859
868
|
(o) => o.is_renderable !== !1
|
|
860
|
-
).length, i = t &&
|
|
869
|
+
).length, i = t && _n ? Yr(e) : "disabled", l = e.reduce(
|
|
861
870
|
(o, S, b) => S.is_renderable !== !1 ? b : o,
|
|
862
871
|
-1
|
|
863
872
|
);
|
|
864
873
|
return /* @__PURE__ */ a.jsx(
|
|
865
|
-
|
|
874
|
+
Nr,
|
|
866
875
|
{
|
|
867
876
|
className: "slide-stage__content flex w-full flex-col gap-4",
|
|
868
877
|
mode: i,
|
|
@@ -871,14 +880,14 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
871
880
|
return /* @__PURE__ */ a.jsx(
|
|
872
881
|
"div",
|
|
873
882
|
{
|
|
874
|
-
ref: t && S === l ?
|
|
883
|
+
ref: t && S === l ? Vt : null,
|
|
875
884
|
"aria-hidden": b || void 0,
|
|
876
885
|
className: ve(
|
|
877
886
|
"w-full shrink-0",
|
|
878
887
|
n === 1 && o.is_renderable !== !1 && "slide-element--single",
|
|
879
888
|
b ? "pointer-events-none fixed left-[-200vw] top-0 -z-10 h-[100dvh] w-[100vw] overflow-hidden opacity-0" : o.is_renderable === !1 && "hidden"
|
|
880
889
|
),
|
|
881
|
-
children:
|
|
890
|
+
children: dr(o, {
|
|
882
891
|
replaceRootScreenHeightWithFull: n === 1 && o.type === "html" && o.is_renderable !== !1
|
|
883
892
|
})
|
|
884
893
|
},
|
|
@@ -887,7 +896,7 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
887
896
|
})
|
|
888
897
|
}
|
|
889
898
|
);
|
|
890
|
-
},
|
|
899
|
+
}, mr = r(() => {
|
|
891
900
|
const e = be.current;
|
|
892
901
|
if (e) {
|
|
893
902
|
if (document.fullscreenElement === e) {
|
|
@@ -898,14 +907,14 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
898
907
|
e.requestFullscreen?.().catch(() => {
|
|
899
908
|
});
|
|
900
909
|
}
|
|
901
|
-
}, []),
|
|
910
|
+
}, []), Sn = r(() => {
|
|
902
911
|
const e = Ue.current;
|
|
903
912
|
e && e.scrollTo({
|
|
904
913
|
top: e.scrollHeight,
|
|
905
914
|
behavior: "smooth"
|
|
906
915
|
});
|
|
907
|
-
}, []),
|
|
908
|
-
(e) =>
|
|
916
|
+
}, []), Tt = r(
|
|
917
|
+
(e) => wn({
|
|
909
918
|
currentIndex: s,
|
|
910
919
|
resolvedCurrentInteractionElement: h,
|
|
911
920
|
slideElementList: P,
|
|
@@ -917,91 +926,92 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
917
926
|
s,
|
|
918
927
|
P
|
|
919
928
|
]
|
|
920
|
-
),
|
|
929
|
+
), pr = r(
|
|
921
930
|
(e, t) => {
|
|
922
931
|
const i = I[e.audioIndex]?.audioKey, l = Ge[e.audioIndex];
|
|
923
|
-
return !i || l == null || !
|
|
932
|
+
return !i || l == null || !Tt(e) ? !1 : (he(t), X.current = null, A(!1), Xe(!1), We(!1), Rt(t) && (ce(!0), v(!0)), l === s ? (Ce.current = null, B(), K(i), nt(e), !0) : (Te.current = !0, B(), Ce.current = {
|
|
924
933
|
audioIndex: e.audioIndex,
|
|
925
934
|
audioKey: i,
|
|
926
935
|
slideIndex: l,
|
|
927
936
|
timeMs: e.timeMs
|
|
928
|
-
},
|
|
937
|
+
}, Gt(l), !0));
|
|
929
938
|
},
|
|
930
939
|
[
|
|
931
940
|
I,
|
|
932
941
|
Ge,
|
|
933
|
-
|
|
942
|
+
Tt,
|
|
934
943
|
s,
|
|
935
|
-
|
|
936
|
-
|
|
944
|
+
Gt,
|
|
945
|
+
nt,
|
|
937
946
|
B,
|
|
938
947
|
v,
|
|
939
948
|
he
|
|
940
949
|
]
|
|
941
|
-
),
|
|
950
|
+
), yr = r(
|
|
942
951
|
(e) => {
|
|
943
|
-
he(e), Te.current = !0, X.current = null, A(!1),
|
|
952
|
+
he(e), Te.current = !0, X.current = null, A(!1), Rt(e) && (ce(!0), v(!0)), B(), Yt();
|
|
944
953
|
},
|
|
945
954
|
[
|
|
946
|
-
|
|
955
|
+
Yt,
|
|
947
956
|
B,
|
|
948
957
|
v,
|
|
949
958
|
he
|
|
950
959
|
]
|
|
951
|
-
),
|
|
960
|
+
), hr = r(
|
|
952
961
|
(e) => {
|
|
953
|
-
he(e), Te.current = !0, X.current = null, A(!1),
|
|
962
|
+
he(e), Te.current = !0, X.current = null, A(!1), Rt(e) && (ce(!0), v(!0)), B(), F();
|
|
954
963
|
},
|
|
955
964
|
[
|
|
956
|
-
|
|
965
|
+
F,
|
|
957
966
|
B,
|
|
958
967
|
v,
|
|
959
968
|
he
|
|
960
969
|
]
|
|
961
|
-
),
|
|
970
|
+
), gr = r(
|
|
962
971
|
({
|
|
963
972
|
loading: e,
|
|
964
973
|
reason: t
|
|
965
974
|
}) => {
|
|
966
|
-
if (
|
|
975
|
+
if (k) {
|
|
967
976
|
A(!1);
|
|
968
977
|
return;
|
|
969
978
|
}
|
|
970
|
-
if (!x ||
|
|
979
|
+
if (!x || M) {
|
|
971
980
|
A(!1);
|
|
972
981
|
return;
|
|
973
982
|
}
|
|
974
|
-
e && t &&
|
|
983
|
+
e && t && ft(t), A(Io(t, e));
|
|
975
984
|
},
|
|
976
985
|
[
|
|
977
986
|
x,
|
|
978
|
-
|
|
979
|
-
|
|
987
|
+
M,
|
|
988
|
+
k
|
|
980
989
|
]
|
|
981
990
|
);
|
|
982
991
|
c(() => {
|
|
983
|
-
|
|
984
|
-
}, [
|
|
985
|
-
const
|
|
992
|
+
k && A(!1);
|
|
993
|
+
}, [k]);
|
|
994
|
+
const vr = r(
|
|
986
995
|
(e) => {
|
|
987
996
|
const t = I[e]?.audioKey;
|
|
988
997
|
if (!t || !w || t !== w)
|
|
989
998
|
return;
|
|
990
|
-
|
|
999
|
+
Je.current.add(t);
|
|
1000
|
+
const n = O.findIndex(
|
|
991
1001
|
(o) => o === t
|
|
992
1002
|
);
|
|
993
1003
|
if (n < 0) {
|
|
994
1004
|
K(null);
|
|
995
1005
|
return;
|
|
996
1006
|
}
|
|
997
|
-
const i = n + 1, l =
|
|
1007
|
+
const i = n + 1, l = O[i];
|
|
998
1008
|
if (l) {
|
|
999
1009
|
K(l);
|
|
1000
1010
|
return;
|
|
1001
1011
|
}
|
|
1002
|
-
if (K(null),
|
|
1012
|
+
if (K(null), Xe(!0), A(!1), _) {
|
|
1003
1013
|
const o = s + 1, S = P[o];
|
|
1004
|
-
|
|
1014
|
+
dn && S?.type === "interaction" && (X.current = o), F();
|
|
1005
1015
|
return;
|
|
1006
1016
|
}
|
|
1007
1017
|
},
|
|
@@ -1010,25 +1020,25 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
1010
1020
|
_,
|
|
1011
1021
|
s,
|
|
1012
1022
|
w,
|
|
1013
|
-
|
|
1014
|
-
|
|
1015
|
-
|
|
1023
|
+
O,
|
|
1024
|
+
F,
|
|
1025
|
+
dn,
|
|
1016
1026
|
P
|
|
1017
1027
|
]
|
|
1018
|
-
),
|
|
1019
|
-
h &&
|
|
1020
|
-
}, [h]),
|
|
1028
|
+
), Sr = r(() => {
|
|
1029
|
+
h && Qe((e) => !e);
|
|
1030
|
+
}, [h]), Ir = r(() => {
|
|
1021
1031
|
He.current = !0, V(), g && Re(!0);
|
|
1022
|
-
}, [V, g]),
|
|
1032
|
+
}, [V, g]), br = r(() => {
|
|
1023
1033
|
He.current = !1, v(!0);
|
|
1024
|
-
}, [v]),
|
|
1034
|
+
}, [v]), Ct = r(
|
|
1025
1035
|
(e) => {
|
|
1026
1036
|
e.stopPropagation(), T && v(!0);
|
|
1027
1037
|
},
|
|
1028
1038
|
[T, v]
|
|
1029
|
-
),
|
|
1039
|
+
), rt = r(
|
|
1030
1040
|
(e, t) => {
|
|
1031
|
-
const n =
|
|
1041
|
+
const n = ct.current;
|
|
1032
1042
|
if (!n)
|
|
1033
1043
|
return null;
|
|
1034
1044
|
const i = e.getBoundingClientRect(), l = n.getBoundingClientRect();
|
|
@@ -1041,14 +1051,14 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
1041
1051
|
},
|
|
1042
1052
|
[]
|
|
1043
1053
|
);
|
|
1044
|
-
|
|
1054
|
+
yo(() => {
|
|
1045
1055
|
const e = we.current;
|
|
1046
1056
|
if (!Be || !e) {
|
|
1047
1057
|
ae.current = null;
|
|
1048
1058
|
return;
|
|
1049
1059
|
}
|
|
1050
1060
|
const t = ae.current, n = e.getBoundingClientRect();
|
|
1051
|
-
if (!t ||
|
|
1061
|
+
if (!t || gt) {
|
|
1052
1062
|
ae.current = {
|
|
1053
1063
|
left: n.left,
|
|
1054
1064
|
top: n.top
|
|
@@ -1056,7 +1066,7 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
1056
1066
|
return;
|
|
1057
1067
|
}
|
|
1058
1068
|
const i = t.left - n.left, l = t.top - n.top;
|
|
1059
|
-
if (!
|
|
1069
|
+
if (!Tn(i) && !Tn(l)) {
|
|
1060
1070
|
ae.current = {
|
|
1061
1071
|
left: n.left,
|
|
1062
1072
|
top: n.top
|
|
@@ -1066,34 +1076,34 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
1066
1076
|
const o = {
|
|
1067
1077
|
x: E.x + i,
|
|
1068
1078
|
y: E.y + l
|
|
1069
|
-
}, S =
|
|
1079
|
+
}, S = rt(
|
|
1070
1080
|
e,
|
|
1071
1081
|
E
|
|
1072
|
-
), b =
|
|
1073
|
-
S ?
|
|
1082
|
+
), b = go(
|
|
1083
|
+
S ? An(o, S) : o
|
|
1074
1084
|
);
|
|
1075
1085
|
ae.current = {
|
|
1076
1086
|
left: n.left + b.x - E.x,
|
|
1077
1087
|
top: n.top + b.y - E.y
|
|
1078
|
-
},
|
|
1088
|
+
}, Cn(
|
|
1079
1089
|
b,
|
|
1080
1090
|
E
|
|
1081
|
-
) ||
|
|
1082
|
-
(Z) =>
|
|
1091
|
+
) || ht(
|
|
1092
|
+
(Z) => Cn(Z, b) ? Z : b
|
|
1083
1093
|
);
|
|
1084
1094
|
}, [
|
|
1085
|
-
|
|
1095
|
+
rt,
|
|
1086
1096
|
E,
|
|
1087
|
-
|
|
1097
|
+
gt,
|
|
1088
1098
|
T,
|
|
1089
1099
|
g,
|
|
1090
1100
|
Be
|
|
1091
1101
|
]);
|
|
1092
|
-
const
|
|
1102
|
+
const xr = r(
|
|
1093
1103
|
(e) => {
|
|
1094
|
-
if (
|
|
1104
|
+
if (Ct(e), e.button !== 0 || !e.currentTarget.isConnected || !we.current)
|
|
1095
1105
|
return;
|
|
1096
|
-
const t =
|
|
1106
|
+
const t = rt(
|
|
1097
1107
|
we.current,
|
|
1098
1108
|
E
|
|
1099
1109
|
);
|
|
@@ -1103,18 +1113,18 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
1103
1113
|
startClientY: e.clientY,
|
|
1104
1114
|
startOffset: E,
|
|
1105
1115
|
bounds: t
|
|
1106
|
-
},
|
|
1116
|
+
}, vt(!0));
|
|
1107
1117
|
},
|
|
1108
1118
|
[
|
|
1109
|
-
|
|
1119
|
+
rt,
|
|
1110
1120
|
E,
|
|
1111
|
-
|
|
1121
|
+
Ct
|
|
1112
1122
|
]
|
|
1113
|
-
),
|
|
1123
|
+
), Ar = r(
|
|
1114
1124
|
(e) => {
|
|
1115
1125
|
const t = Ee.current;
|
|
1116
|
-
!t || t.pointerId !== e.pointerId || (e.preventDefault(), e.stopPropagation(),
|
|
1117
|
-
|
|
1126
|
+
!t || t.pointerId !== e.pointerId || (e.preventDefault(), e.stopPropagation(), ht(
|
|
1127
|
+
An(
|
|
1118
1128
|
{
|
|
1119
1129
|
x: t.startOffset.x + e.clientX - t.startClientX,
|
|
1120
1130
|
y: t.startOffset.y + e.clientY - t.startClientY
|
|
@@ -1124,33 +1134,33 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
1124
1134
|
));
|
|
1125
1135
|
},
|
|
1126
1136
|
[]
|
|
1127
|
-
),
|
|
1137
|
+
), In = r(
|
|
1128
1138
|
(e) => {
|
|
1129
1139
|
const t = Ee.current;
|
|
1130
|
-
!t || t.pointerId !== e.pointerId || (e.stopPropagation(), e.currentTarget.hasPointerCapture(e.pointerId) && e.currentTarget.releasePointerCapture(e.pointerId), Ee.current = null,
|
|
1140
|
+
!t || t.pointerId !== e.pointerId || (e.stopPropagation(), e.currentTarget.hasPointerCapture(e.pointerId) && e.currentTarget.releasePointerCapture(e.pointerId), Ee.current = null, vt(!1));
|
|
1131
1141
|
},
|
|
1132
1142
|
[]
|
|
1133
|
-
), Ar = r(
|
|
1134
|
-
(e) => {
|
|
1135
|
-
q(), Nt?.(e);
|
|
1136
|
-
},
|
|
1137
|
-
[q, Nt]
|
|
1138
1143
|
), wr = r(
|
|
1139
1144
|
(e) => {
|
|
1140
1145
|
q(), Bt?.(e);
|
|
1141
1146
|
},
|
|
1142
1147
|
[q, Bt]
|
|
1143
|
-
), Er = r(
|
|
1148
|
+
), Er = r(
|
|
1149
|
+
(e) => {
|
|
1150
|
+
q(), Dt?.(e);
|
|
1151
|
+
},
|
|
1152
|
+
[q, Dt]
|
|
1153
|
+
), Tr = r(() => {
|
|
1144
1154
|
ce(!0), v(!0);
|
|
1145
1155
|
}, [v]);
|
|
1146
1156
|
return c(() => {
|
|
1147
|
-
const e =
|
|
1157
|
+
const e = jt.current, i = (e.length > 0 && e.length < se.length && e.every((o, S) => o === se[S]) ? R.slice(e.length) : []).some(
|
|
1148
1158
|
(o) => o.is_new === !1
|
|
1149
1159
|
);
|
|
1150
|
-
if (
|
|
1160
|
+
if (jt.current = se, !i)
|
|
1151
1161
|
return;
|
|
1152
1162
|
const l = window.requestAnimationFrame(() => {
|
|
1153
|
-
const o = Ue.current, S =
|
|
1163
|
+
const o = Ue.current, S = Vt.current;
|
|
1154
1164
|
if (!o || !S)
|
|
1155
1165
|
return;
|
|
1156
1166
|
const b = o.getBoundingClientRect(), Z = S.getBoundingClientRect(), De = o.scrollTop + (Z.top - b.top);
|
|
@@ -1166,29 +1176,29 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
1166
1176
|
if (!Te.current || (Te.current = !1, R.length === 0))
|
|
1167
1177
|
return;
|
|
1168
1178
|
const e = window.requestAnimationFrame(() => {
|
|
1169
|
-
|
|
1179
|
+
Sn();
|
|
1170
1180
|
});
|
|
1171
1181
|
return () => {
|
|
1172
1182
|
window.cancelAnimationFrame(e);
|
|
1173
1183
|
};
|
|
1174
|
-
}, [R,
|
|
1184
|
+
}, [R, Sn]), /* @__PURE__ */ a.jsxs(
|
|
1175
1185
|
"section",
|
|
1176
1186
|
{
|
|
1177
1187
|
ref: be,
|
|
1178
1188
|
className: ve(
|
|
1179
1189
|
"relative h-full w-full",
|
|
1180
1190
|
D && "slide--mobile-device",
|
|
1181
|
-
|
|
1191
|
+
rn && "slide--browser-fullscreen",
|
|
1182
1192
|
fe && "slide--mobile-landscape",
|
|
1183
|
-
|
|
1184
|
-
|
|
1193
|
+
tn && "slide--mobile-landscape-native",
|
|
1194
|
+
On
|
|
1185
1195
|
),
|
|
1186
|
-
onClick:
|
|
1187
|
-
onFocusCapture:
|
|
1188
|
-
onPointerDown:
|
|
1189
|
-
...
|
|
1196
|
+
onClick: Tr,
|
|
1197
|
+
onFocusCapture: Er,
|
|
1198
|
+
onPointerDown: wr,
|
|
1199
|
+
...Mn,
|
|
1190
1200
|
children: [
|
|
1191
|
-
|
|
1201
|
+
Jn ? /* @__PURE__ */ a.jsx(
|
|
1192
1202
|
"div",
|
|
1193
1203
|
{
|
|
1194
1204
|
"aria-hidden": "true",
|
|
@@ -1198,23 +1208,23 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
1198
1208
|
/* @__PURE__ */ a.jsxs(
|
|
1199
1209
|
"div",
|
|
1200
1210
|
{
|
|
1201
|
-
ref:
|
|
1211
|
+
ref: ct,
|
|
1202
1212
|
className: ve(
|
|
1203
1213
|
"slide__viewport relative h-full min-h-0 w-full",
|
|
1204
1214
|
fe && "slide__viewport--mobile-landscape",
|
|
1205
|
-
fe &&
|
|
1215
|
+
fe && !$n && "slide__viewport--mobile-landscape-native"
|
|
1206
1216
|
),
|
|
1207
1217
|
children: [
|
|
1208
|
-
|
|
1218
|
+
zn ? /* @__PURE__ */ a.jsxs("div", { className: "slide-landscape-header", children: [
|
|
1209
1219
|
/* @__PURE__ */ a.jsx(
|
|
1210
1220
|
"button",
|
|
1211
1221
|
{
|
|
1212
1222
|
"aria-label": G?.backAriaLabel ?? $.fullscreenBackAriaLabel,
|
|
1213
1223
|
className: "slide-landscape-header__back",
|
|
1214
|
-
onClick:
|
|
1224
|
+
onClick: Qn,
|
|
1215
1225
|
type: "button",
|
|
1216
1226
|
children: /* @__PURE__ */ a.jsx(
|
|
1217
|
-
|
|
1227
|
+
co,
|
|
1218
1228
|
{
|
|
1219
1229
|
className: "slide-landscape-header__icon h-6 w-6",
|
|
1220
1230
|
strokeWidth: 2.25
|
|
@@ -1229,12 +1239,12 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
1229
1239
|
{
|
|
1230
1240
|
className: ve(
|
|
1231
1241
|
"h-full min-h-0 w-full",
|
|
1232
|
-
|
|
1233
|
-
|
|
1242
|
+
Xn && "slide__viewport-content--with-header",
|
|
1243
|
+
Nn ? "slide-content--single" : "grid gap-4"
|
|
1234
1244
|
),
|
|
1235
|
-
children: R.length > 0 ? /* @__PURE__ */ a.jsx("div", { className: "slide-stage", children: /* @__PURE__ */ a.jsx("div", { ref: Ue, className: "slide-stage__layer w-full", children:
|
|
1245
|
+
children: R.length > 0 ? /* @__PURE__ */ a.jsx("div", { className: "slide-stage", children: /* @__PURE__ */ a.jsx("div", { ref: Ue, className: "slide-stage__layer w-full", children: Zn.map(
|
|
1236
1246
|
(e, t) => {
|
|
1237
|
-
const n = t ===
|
|
1247
|
+
const n = t === er;
|
|
1238
1248
|
return /* @__PURE__ */ a.jsx(
|
|
1239
1249
|
"div",
|
|
1240
1250
|
{
|
|
@@ -1242,7 +1252,7 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
1242
1252
|
"aria-hidden": !n || void 0,
|
|
1243
1253
|
className: "w-full h-full",
|
|
1244
1254
|
style: { display: n ? void 0 : "none" },
|
|
1245
|
-
children:
|
|
1255
|
+
children: fr(
|
|
1246
1256
|
e.elementList,
|
|
1247
1257
|
n
|
|
1248
1258
|
)
|
|
@@ -1253,25 +1263,25 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
1253
1263
|
) }) }) : null
|
|
1254
1264
|
}
|
|
1255
1265
|
),
|
|
1256
|
-
|
|
1257
|
-
|
|
1266
|
+
jn ? /* @__PURE__ */ a.jsx(
|
|
1267
|
+
Or,
|
|
1258
1268
|
{
|
|
1259
|
-
message:
|
|
1260
|
-
|
|
1261
|
-
|
|
1269
|
+
message: vo(
|
|
1270
|
+
kn,
|
|
1271
|
+
qn
|
|
1262
1272
|
),
|
|
1263
1273
|
className: "absolute left-1/2 top-1/2 z-[3] -translate-x-1/2 -translate-y-1/2"
|
|
1264
1274
|
}
|
|
1265
1275
|
) : null,
|
|
1266
1276
|
/* @__PURE__ */ a.jsx(
|
|
1267
|
-
|
|
1277
|
+
Br,
|
|
1268
1278
|
{
|
|
1269
|
-
extraBottomOffset:
|
|
1279
|
+
extraBottomOffset: Hn,
|
|
1270
1280
|
hasPlayerGap: T,
|
|
1271
|
-
isEnabled:
|
|
1281
|
+
isEnabled: Jt && Kn,
|
|
1272
1282
|
isPlayerHidden: g && !T,
|
|
1273
1283
|
playbackTimeStore: de,
|
|
1274
|
-
subtitleCues:
|
|
1284
|
+
subtitleCues: tr
|
|
1275
1285
|
}
|
|
1276
1286
|
),
|
|
1277
1287
|
Be ? /* @__PURE__ */ a.jsx(
|
|
@@ -1282,93 +1292,93 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
1282
1292
|
className: ve(
|
|
1283
1293
|
"slide-interaction-overlay",
|
|
1284
1294
|
T && g ? "slide-interaction-overlay--with-player" : "slide-interaction-overlay--standalone",
|
|
1285
|
-
|
|
1295
|
+
gt && "slide-interaction-overlay--dragging"
|
|
1286
1296
|
),
|
|
1287
|
-
onClick:
|
|
1297
|
+
onClick: Ct,
|
|
1288
1298
|
onPointerDownCapture: (e) => {
|
|
1289
|
-
|
|
1299
|
+
Ot(e.target) && Ze(!0);
|
|
1290
1300
|
},
|
|
1291
1301
|
onFocusCapture: (e) => {
|
|
1292
|
-
|
|
1302
|
+
Ot(e.target) && Ze(!0);
|
|
1293
1303
|
},
|
|
1294
1304
|
onInputCapture: (e) => {
|
|
1295
|
-
|
|
1305
|
+
Ot(e.target) && Ze(!0);
|
|
1296
1306
|
},
|
|
1297
|
-
style:
|
|
1307
|
+
style: nr,
|
|
1298
1308
|
children: /* @__PURE__ */ a.jsx(
|
|
1299
|
-
|
|
1309
|
+
Pn,
|
|
1300
1310
|
{
|
|
1301
1311
|
content: String(h?.content ?? ""),
|
|
1302
1312
|
locale: f,
|
|
1303
|
-
defaultButtonText:
|
|
1304
|
-
defaultInputText:
|
|
1305
|
-
defaultSelectedValues:
|
|
1313
|
+
defaultButtonText: hn.buttonText ?? "",
|
|
1314
|
+
defaultInputText: hn.inputText ?? "",
|
|
1315
|
+
defaultSelectedValues: ar,
|
|
1306
1316
|
confirmButtonText: oe?.confirmButtonText ?? $.interactionTexts.confirmButtonText,
|
|
1307
1317
|
copyButtonText: oe?.copyButtonText ?? $.interactionTexts.copyButtonText,
|
|
1308
1318
|
copiedButtonText: oe?.copiedButtonText ?? $.interactionTexts.copiedButtonText,
|
|
1309
|
-
onSend:
|
|
1310
|
-
onDragHandlePointerCancel:
|
|
1311
|
-
onDragHandlePointerDown:
|
|
1312
|
-
onDragHandlePointerMove:
|
|
1313
|
-
onDragHandlePointerUp:
|
|
1314
|
-
readonly:
|
|
1315
|
-
title: oe?.title ??
|
|
1319
|
+
onSend: ur,
|
|
1320
|
+
onDragHandlePointerCancel: In,
|
|
1321
|
+
onDragHandlePointerDown: xr,
|
|
1322
|
+
onDragHandlePointerMove: Ar,
|
|
1323
|
+
onDragHandlePointerUp: In,
|
|
1324
|
+
readonly: cr,
|
|
1325
|
+
title: oe?.title ?? lt ?? $.interactionTexts.title
|
|
1316
1326
|
}
|
|
1317
1327
|
)
|
|
1318
1328
|
}
|
|
1319
1329
|
) : null,
|
|
1320
1330
|
g ? /* @__PURE__ */ a.jsx(
|
|
1321
|
-
|
|
1331
|
+
jr.Provider,
|
|
1322
1332
|
{
|
|
1323
|
-
value:
|
|
1333
|
+
value: Bn,
|
|
1324
1334
|
children: /* @__PURE__ */ a.jsx(
|
|
1325
|
-
|
|
1335
|
+
Lr,
|
|
1326
1336
|
{
|
|
1327
1337
|
audioList: I,
|
|
1328
1338
|
className: ve(
|
|
1329
1339
|
"absolute left-1/2 z-[2] -translate-x-1/2",
|
|
1330
|
-
|
|
1340
|
+
rn ? "bottom-3" : "-bottom-3",
|
|
1331
1341
|
Y,
|
|
1332
1342
|
!T && "pointer-events-none opacity-0"
|
|
1333
1343
|
),
|
|
1334
1344
|
currentAudioIndex: C,
|
|
1335
|
-
defaultPlaying:
|
|
1345
|
+
defaultPlaying: dt,
|
|
1336
1346
|
enableKeyboardShortcuts: ie,
|
|
1337
1347
|
isPlaybackPaused: Q,
|
|
1338
1348
|
isAutoAdvanceEnabled: _e,
|
|
1339
1349
|
locale: f,
|
|
1340
1350
|
hasInteraction: !!h,
|
|
1341
1351
|
isInteractionOpen: ue,
|
|
1342
|
-
isSubtitleEnabled:
|
|
1343
|
-
onAutoAdvanceToggle:
|
|
1344
|
-
onLoadingChange:
|
|
1352
|
+
isSubtitleEnabled: Jt,
|
|
1353
|
+
onAutoAdvanceToggle: zt,
|
|
1354
|
+
onLoadingChange: gr,
|
|
1345
1355
|
onPlaybackStarted: () => {
|
|
1346
|
-
|
|
1356
|
+
We(!0);
|
|
1347
1357
|
},
|
|
1348
|
-
onPlaybackPreferenceChange:
|
|
1358
|
+
onPlaybackPreferenceChange: lr,
|
|
1349
1359
|
onPlaybackTimeChange: de.setTime,
|
|
1350
1360
|
onSubtitleToggle: () => {
|
|
1351
|
-
|
|
1361
|
+
Un((e) => !e);
|
|
1352
1362
|
},
|
|
1353
1363
|
nextDisabled: !_,
|
|
1354
|
-
onEnded:
|
|
1355
|
-
onFullscreen:
|
|
1356
|
-
isFullscreen:
|
|
1364
|
+
onEnded: vr,
|
|
1365
|
+
onFullscreen: mr,
|
|
1366
|
+
isFullscreen: Qt,
|
|
1357
1367
|
mobileViewMode: J,
|
|
1358
|
-
settingsPortalContainer:
|
|
1359
|
-
onMobileViewModeChange:
|
|
1360
|
-
onControlsPointerEnter:
|
|
1361
|
-
onControlsPointerLeave:
|
|
1362
|
-
onInteractionToggle:
|
|
1363
|
-
onNext:
|
|
1364
|
-
onPrev:
|
|
1365
|
-
onSubtitleJump:
|
|
1366
|
-
canJumpToSubtitleTarget:
|
|
1367
|
-
prevDisabled: !
|
|
1368
|
+
settingsPortalContainer: ct.current,
|
|
1369
|
+
onMobileViewModeChange: Wn,
|
|
1370
|
+
onControlsPointerEnter: Ir,
|
|
1371
|
+
onControlsPointerLeave: br,
|
|
1372
|
+
onInteractionToggle: Sr,
|
|
1373
|
+
onNext: hr,
|
|
1374
|
+
onPrev: yr,
|
|
1375
|
+
onSubtitleJump: pr,
|
|
1376
|
+
canJumpToSubtitleTarget: Tt,
|
|
1377
|
+
prevDisabled: !Ln,
|
|
1368
1378
|
showControls: T,
|
|
1369
|
-
subtitleSeekRequest:
|
|
1370
|
-
texts:
|
|
1371
|
-
customActionContext:
|
|
1379
|
+
subtitleSeekRequest: Vn,
|
|
1380
|
+
texts: at,
|
|
1381
|
+
customActionContext: xt,
|
|
1372
1382
|
customActions: ne,
|
|
1373
1383
|
useAutoAdvanceToggle: ke
|
|
1374
1384
|
}
|
|
@@ -1383,6 +1393,6 @@ const vo = (u, f) => u.length === f.length && u.every((H, Se) => {
|
|
|
1383
1393
|
);
|
|
1384
1394
|
};
|
|
1385
1395
|
export {
|
|
1386
|
-
|
|
1396
|
+
li as default
|
|
1387
1397
|
};
|
|
1388
1398
|
//# sourceMappingURL=Slide.es.js.map
|