markdown-flow-ui 0.2.21 → 0.2.22

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