markdown-flow-ui 0.1.116 → 0.1.117-beta.0

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 (74) hide show
  1. package/dist/_virtual/index.cjs10.js +1 -1
  2. package/dist/_virtual/index.cjs4.js +1 -1
  3. package/dist/_virtual/index.cjs6.js +1 -1
  4. package/dist/_virtual/index.cjs8.js +1 -1
  5. package/dist/_virtual/index.cjs9.js +1 -1
  6. package/dist/_virtual/index.es10.js +2 -2
  7. package/dist/_virtual/index.es4.js +4 -4
  8. package/dist/_virtual/index.es6.js +4 -4
  9. package/dist/_virtual/index.es8.js +3 -2
  10. package/dist/_virtual/index.es8.js.map +1 -1
  11. package/dist/_virtual/index.es9.js +2 -3
  12. package/dist/_virtual/index.es9.js.map +1 -1
  13. package/dist/assets/markdown-flow-ui.css +1 -1
  14. package/dist/components/ContentRender/ContentRender.cjs.js +2 -2
  15. package/dist/components/ContentRender/ContentRender.cjs.js.map +1 -1
  16. package/dist/components/ContentRender/ContentRender.d.ts +1 -1
  17. package/dist/components/ContentRender/ContentRender.es.js +209 -180
  18. package/dist/components/ContentRender/ContentRender.es.js.map +1 -1
  19. package/dist/components/ContentRender/ContentRender.stories.d.ts +1 -3
  20. package/dist/components/ContentRender/index.d.ts +1 -2
  21. package/dist/components/MarkdownFlow/MarkdownFlow.cjs.js +1 -1
  22. package/dist/components/MarkdownFlow/MarkdownFlow.cjs.js.map +1 -1
  23. package/dist/components/MarkdownFlow/MarkdownFlow.d.ts +0 -3
  24. package/dist/components/MarkdownFlow/MarkdownFlow.es.js +21 -29
  25. package/dist/components/MarkdownFlow/MarkdownFlow.es.js.map +1 -1
  26. package/dist/components/Slide/Player.cjs.js +1 -1
  27. package/dist/components/Slide/Player.cjs.js.map +1 -1
  28. package/dist/components/Slide/Player.es.js +330 -326
  29. package/dist/components/Slide/Player.es.js.map +1 -1
  30. package/dist/components/Slide/Slide.cjs.js +1 -1
  31. package/dist/components/Slide/Slide.cjs.js.map +1 -1
  32. package/dist/components/Slide/Slide.es.js +50 -51
  33. package/dist/components/Slide/Slide.es.js.map +1 -1
  34. package/dist/components/Slide/utils/playbackSource.cjs.js +2 -0
  35. package/dist/components/Slide/utils/playbackSource.cjs.js.map +1 -0
  36. package/dist/components/Slide/utils/playbackSource.d.ts +9 -0
  37. package/dist/components/Slide/utils/playbackSource.es.js +14 -0
  38. package/dist/components/Slide/utils/playbackSource.es.js.map +1 -0
  39. package/dist/components/Slide/utils/playbackSource.test.d.ts +1 -0
  40. package/dist/components/ui/inputGroup/textarea.cjs.js +1 -1
  41. package/dist/components/ui/inputGroup/textarea.es.js +1 -1
  42. package/dist/markdown-flow-ui/node_modules/.pnpm/@braintree_sanitize-url@7.1.1/node_modules/@braintree/sanitize-url/dist/index.cjs.js +1 -1
  43. package/dist/markdown-flow-ui/node_modules/.pnpm/@braintree_sanitize-url@7.1.1/node_modules/@braintree/sanitize-url/dist/index.cjs.js.map +1 -1
  44. package/dist/markdown-flow-ui/node_modules/.pnpm/@braintree_sanitize-url@7.1.1/node_modules/@braintree/sanitize-url/dist/index.es.js +1 -1
  45. package/dist/markdown-flow-ui/node_modules/.pnpm/classnames@2.5.1/node_modules/classnames/index.cjs.js +1 -1
  46. package/dist/markdown-flow-ui/node_modules/.pnpm/classnames@2.5.1/node_modules/classnames/index.es.js +1 -1
  47. package/dist/markdown-flow-ui/node_modules/.pnpm/hast-util-to-jsx-runtime@2.3.6/node_modules/hast-util-to-jsx-runtime/lib/index.cjs.js +1 -1
  48. package/dist/markdown-flow-ui/node_modules/.pnpm/hast-util-to-jsx-runtime@2.3.6/node_modules/hast-util-to-jsx-runtime/lib/index.es.js +1 -1
  49. package/dist/markdown-flow-ui/node_modules/.pnpm/mermaid@11.12.1/node_modules/mermaid/dist/chunks/mermaid.core/c4Diagram-YG6GDRKO.cjs.js +1 -1
  50. package/dist/markdown-flow-ui/node_modules/.pnpm/mermaid@11.12.1/node_modules/mermaid/dist/chunks/mermaid.core/c4Diagram-YG6GDRKO.es.js +1 -1
  51. package/dist/markdown-flow-ui/node_modules/.pnpm/mermaid@11.12.1/node_modules/mermaid/dist/chunks/mermaid.core/chunk-S3R3BYOJ.cjs.js +1 -1
  52. package/dist/markdown-flow-ui/node_modules/.pnpm/mermaid@11.12.1/node_modules/mermaid/dist/chunks/mermaid.core/chunk-S3R3BYOJ.es.js +1 -1
  53. package/dist/markdown-flow-ui/node_modules/.pnpm/mermaid@11.12.1/node_modules/mermaid/dist/chunks/mermaid.core/chunk-TZMSLE5B.cjs.js +1 -1
  54. package/dist/markdown-flow-ui/node_modules/.pnpm/mermaid@11.12.1/node_modules/mermaid/dist/chunks/mermaid.core/chunk-TZMSLE5B.es.js +1 -1
  55. package/dist/markdown-flow-ui/node_modules/.pnpm/mermaid@11.12.1/node_modules/mermaid/dist/chunks/mermaid.core/ganttDiagram-LVOFAZNH.cjs.js +1 -1
  56. package/dist/markdown-flow-ui/node_modules/.pnpm/mermaid@11.12.1/node_modules/mermaid/dist/chunks/mermaid.core/ganttDiagram-LVOFAZNH.es.js +1 -1
  57. package/dist/markdown-flow-ui/node_modules/.pnpm/mermaid@11.12.1/node_modules/mermaid/dist/chunks/mermaid.core/sequenceDiagram-WL72ISMW.cjs.js +1 -1
  58. package/dist/markdown-flow-ui/node_modules/.pnpm/mermaid@11.12.1/node_modules/mermaid/dist/chunks/mermaid.core/sequenceDiagram-WL72ISMW.es.js +1 -1
  59. package/dist/markdown-flow-ui/node_modules/.pnpm/rc-input@1.8.0_react-dom@19.0.1_react@19.0.1__react@19.0.1/node_modules/rc-input/es/BaseInput.cjs.js +1 -1
  60. package/dist/markdown-flow-ui/node_modules/.pnpm/rc-input@1.8.0_react-dom@19.0.1_react@19.0.1__react@19.0.1/node_modules/rc-input/es/BaseInput.es.js +1 -1
  61. package/dist/markdown-flow-ui/node_modules/.pnpm/rc-textarea@1.10.2_react-dom@19.0.1_react@19.0.1__react@19.0.1/node_modules/rc-textarea/es/ResizableTextArea.cjs.js +1 -1
  62. package/dist/markdown-flow-ui/node_modules/.pnpm/rc-textarea@1.10.2_react-dom@19.0.1_react@19.0.1__react@19.0.1/node_modules/rc-textarea/es/ResizableTextArea.es.js +1 -1
  63. package/dist/markdown-flow-ui/node_modules/.pnpm/rc-textarea@1.10.2_react-dom@19.0.1_react@19.0.1__react@19.0.1/node_modules/rc-textarea/es/TextArea.cjs.js +1 -1
  64. package/dist/markdown-flow-ui/node_modules/.pnpm/rc-textarea@1.10.2_react-dom@19.0.1_react@19.0.1__react@19.0.1/node_modules/rc-textarea/es/TextArea.es.js +1 -1
  65. package/dist/markdown-flow-ui/node_modules/.pnpm/rc-textarea@1.10.2_react-dom@19.0.1_react@19.0.1__react@19.0.1/node_modules/rc-textarea/es/index.cjs.js +1 -1
  66. package/dist/markdown-flow-ui/node_modules/.pnpm/rc-textarea@1.10.2_react-dom@19.0.1_react@19.0.1__react@19.0.1/node_modules/rc-textarea/es/index.es.js +1 -1
  67. package/dist/markdown-flow-ui-lib.css +1 -1
  68. package/package.json +2 -3
  69. package/dist/components/ContentRender/useTypewriter.d.ts +0 -19
  70. package/dist/components/ContentRender/useTypewriterStateMachine.cjs.js +0 -2
  71. package/dist/components/ContentRender/useTypewriterStateMachine.cjs.js.map +0 -1
  72. package/dist/components/ContentRender/useTypewriterStateMachine.d.ts +0 -19
  73. package/dist/components/ContentRender/useTypewriterStateMachine.es.js +0 -180
  74. package/dist/components/ContentRender/useTypewriterStateMachine.es.js.map +0 -1
@@ -1,27 +1,28 @@
1
1
  import { j as t } from "../../_virtual/jsx-runtime.es.js";
2
- import er, { memo as rr, useRef as c, useState as ke, useMemo as q, useEffect as S, useCallback as u } from "react";
3
- import { cn as Ee } from "../../lib/utils.es.js";
4
- import tr from "./MobilePlayerSettingsSheet.es.js";
5
- import { DEFAULT_SLIDE_PLAYER_TEXTS as nr } from "./constants.es.js";
6
- import { DEFAULT_MOBILE_VIEW_MODE as ur } from "./utils/mobileScreenMode.es.js";
2
+ import rr, { memo as tr, useRef as a, useState as Ee, useMemo as z, useEffect as b, useCallback as u } from "react";
3
+ import { cn as Te } from "../../lib/utils.es.js";
4
+ import nr from "./MobilePlayerSettingsSheet.es.js";
5
+ import { DEFAULT_SLIDE_PLAYER_TEXTS as ur } from "./constants.es.js";
6
+ import { DEFAULT_MOBILE_VIEW_MODE as lr } from "./utils/mobileScreenMode.es.js";
7
7
  import { hasReachedAudioEnd as sr } from "./utils/audioCompletion.es.js";
8
- import { toPlayerCustomActionList as lr } from "./utils/playerCustomActions.es.js";
8
+ import { resolveAudioPlaybackSourceType as ar } from "./utils/playbackSource.es.js";
9
+ import { toPlayerCustomActionList as cr } from "./utils/playerCustomActions.es.js";
9
10
  /* empty css */
10
- import ar from "../../markdown-flow-ui/node_modules/.pnpm/lucide-react@0.525.0_react@19.0.1/node_modules/lucide-react/dist/esm/icons/ellipsis-vertical.es.js";
11
- import cr from "../../markdown-flow-ui/node_modules/.pnpm/lucide-react@0.525.0_react@19.0.1/node_modules/lucide-react/dist/esm/icons/volume-2.es.js";
12
- import ir from "../../markdown-flow-ui/node_modules/.pnpm/lucide-react@0.525.0_react@19.0.1/node_modules/lucide-react/dist/esm/icons/captions.es.js";
13
- import or from "../../markdown-flow-ui/node_modules/.pnpm/lucide-react@0.525.0_react@19.0.1/node_modules/lucide-react/dist/esm/icons/captions-off.es.js";
14
- import fr from "../../markdown-flow-ui/node_modules/.pnpm/lucide-react@0.525.0_react@19.0.1/node_modules/lucide-react/dist/esm/icons/rotate-ccw.es.js";
15
- import dr from "../../markdown-flow-ui/node_modules/.pnpm/lucide-react@0.525.0_react@19.0.1/node_modules/lucide-react/dist/esm/icons/rotate-cw.es.js";
16
- import mr from "../../markdown-flow-ui/node_modules/.pnpm/lucide-react@0.525.0_react@19.0.1/node_modules/lucide-react/dist/esm/icons/scan-line.es.js";
17
- import pr from "../../markdown-flow-ui/node_modules/.pnpm/lucide-react@0.525.0_react@19.0.1/node_modules/lucide-react/dist/esm/icons/maximize.es.js";
18
- import hr from "../../markdown-flow-ui/node_modules/.pnpm/lucide-react@0.525.0_react@19.0.1/node_modules/lucide-react/dist/esm/icons/file-pen-line.es.js";
19
- const Ne = /* @__PURE__ */ new Map(), Re = (R) => {
20
- if (typeof window > "u" || !R || Ne.has(R))
11
+ import ir from "../../markdown-flow-ui/node_modules/.pnpm/lucide-react@0.525.0_react@19.0.1/node_modules/lucide-react/dist/esm/icons/ellipsis-vertical.es.js";
12
+ import or from "../../markdown-flow-ui/node_modules/.pnpm/lucide-react@0.525.0_react@19.0.1/node_modules/lucide-react/dist/esm/icons/volume-2.es.js";
13
+ import fr from "../../markdown-flow-ui/node_modules/.pnpm/lucide-react@0.525.0_react@19.0.1/node_modules/lucide-react/dist/esm/icons/captions.es.js";
14
+ import dr from "../../markdown-flow-ui/node_modules/.pnpm/lucide-react@0.525.0_react@19.0.1/node_modules/lucide-react/dist/esm/icons/captions-off.es.js";
15
+ import mr from "../../markdown-flow-ui/node_modules/.pnpm/lucide-react@0.525.0_react@19.0.1/node_modules/lucide-react/dist/esm/icons/rotate-ccw.es.js";
16
+ import pr from "../../markdown-flow-ui/node_modules/.pnpm/lucide-react@0.525.0_react@19.0.1/node_modules/lucide-react/dist/esm/icons/rotate-cw.es.js";
17
+ import hr from "../../markdown-flow-ui/node_modules/.pnpm/lucide-react@0.525.0_react@19.0.1/node_modules/lucide-react/dist/esm/icons/scan-line.es.js";
18
+ import yr from "../../markdown-flow-ui/node_modules/.pnpm/lucide-react@0.525.0_react@19.0.1/node_modules/lucide-react/dist/esm/icons/maximize.es.js";
19
+ import gr from "../../markdown-flow-ui/node_modules/.pnpm/lucide-react@0.525.0_react@19.0.1/node_modules/lucide-react/dist/esm/icons/file-pen-line.es.js";
20
+ const Ne = /* @__PURE__ */ new Map(), Re = (N) => {
21
+ if (typeof window > "u" || !N || Ne.has(N))
21
22
  return;
22
- const v = window.document.createElement("audio");
23
- v.preload = "auto", v.setAttribute("playsinline", "true"), v.src = R, v.load(), Ne.set(R, v);
24
- }, gr = () => /* @__PURE__ */ t.jsxs(
23
+ const F = window.document.createElement("audio");
24
+ F.preload = "auto", F.setAttribute("playsinline", "true"), F.src = N, F.load(), Ne.set(N, F);
25
+ }, _r = () => /* @__PURE__ */ t.jsxs(
25
26
  "svg",
26
27
  {
27
28
  xmlns: "http://www.w3.org/2000/svg",
@@ -40,7 +41,7 @@ const Ne = /* @__PURE__ */ new Map(), Re = (R) => {
40
41
  /* @__PURE__ */ t.jsx("path", { d: "M12 10H16V24H12V10ZM18 10H22V24H18V10Z", fill: "white" })
41
42
  ]
42
43
  }
43
- ), yr = () => /* @__PURE__ */ t.jsxs(
44
+ ), br = () => /* @__PURE__ */ t.jsxs(
44
45
  "svg",
45
46
  {
46
47
  xmlns: "http://www.w3.org/2000/svg",
@@ -59,414 +60,417 @@ const Ne = /* @__PURE__ */ new Map(), Re = (R) => {
59
60
  /* @__PURE__ */ t.jsx("path", { d: "M13.3333 10L23.3333 16.6667L13.3333 23.3333V10Z", fill: "white" })
60
61
  ]
61
62
  }
62
- ), _r = ({
63
- audioList: R = [],
64
- className: v,
63
+ ), Sr = ({
64
+ audioList: N = [],
65
+ className: F,
65
66
  currentAudioIndex: m = -1,
66
- defaultPlaying: A = !0,
67
- isPlaybackPaused: F = !1,
68
- isAutoAdvanceEnabled: G = !0,
69
- useAutoAdvanceToggle: J = !1,
70
- onLoadingChange: ne,
71
- onPlaybackStarted: ue,
72
- onPlaybackTimeChange: z,
67
+ defaultPlaying: M = !0,
68
+ isPlaybackPaused: U = !1,
69
+ isAutoAdvanceEnabled: J = !0,
70
+ useAutoAdvanceToggle: Q = !1,
71
+ onLoadingChange: ue,
72
+ onPlaybackStarted: le,
73
+ onPlaybackTimeChange: D,
73
74
  onSubtitleToggle: se,
74
- onPrev: Te,
75
+ onPrev: ve,
75
76
  onNext: Ce,
76
- onFullscreen: le,
77
- isFullscreen: ae = !1,
78
- mobileViewMode: Le = ur,
79
- settingsPortalContainer: ve,
80
- onMobileViewModeChange: ce,
81
- onEnded: ie,
82
- onAutoAdvanceToggle: Fe,
83
- onInteractionToggle: Ue,
84
- hasInteraction: We = !1,
85
- isInteractionOpen: $ = !1,
86
- isSubtitleEnabled: Q = !0,
87
- prevDisabled: Pe = !1,
88
- nextDisabled: Ve = !1,
89
- showControls: I = !0,
90
- customActions: oe,
91
- customActionContext: fe,
92
- texts: de,
93
- ...Be
77
+ onFullscreen: ae,
78
+ isFullscreen: ce = !1,
79
+ mobileViewMode: Le = lr,
80
+ settingsPortalContainer: Fe,
81
+ onMobileViewModeChange: ie,
82
+ onEnded: oe,
83
+ onAutoAdvanceToggle: Ue,
84
+ onInteractionToggle: We,
85
+ hasInteraction: Pe = !1,
86
+ isInteractionOpen: q = !1,
87
+ isSubtitleEnabled: I = !0,
88
+ prevDisabled: Ve = !1,
89
+ nextDisabled: Be = !1,
90
+ showControls: ee = !0,
91
+ customActions: fe,
92
+ customActionContext: de,
93
+ texts: me,
94
+ ...Ze
94
95
  }) => {
95
- const p = c(null), me = c($), M = c(null), pe = c(null), x = c(0), a = c(null), D = c(void 0), j = c([]), H = c(!1), he = c(!1), g = c(!1), T = c(null), y = c(!1), s = c(!1), h = c(null), w = c(!1), U = c(null), ee = c(0), C = c("unknown"), [re, i] = ke(A), [ge, B] = ke(!1), f = m >= 0 ? R[m] : void 0, K = f?.audioUrl, k = q(
96
+ const p = a(null), pe = a(q), R = a(null), he = a(null), S = a(0), c = a(null), X = a(void 0), j = a([]), K = a(!1), ye = a(!1), y = a(!1), v = a(null), Z = a(null), g = a(!1), l = a(!1), h = a(null), x = a(!1), W = a(null), re = a(0), C = a("unknown"), [te, o] = Ee(M), [ge, $] = Ee(!1), f = m >= 0 ? N[m] : void 0, P = f?.audioUrl, w = z(
96
97
  () => [...f?.audioSegments ?? []].sort(
97
98
  (e, r) => e.segment_index - r.segment_index
98
99
  ),
99
100
  [f?.audioSegments]
100
- ), ye = q(
101
- () => lr(oe, fe),
102
- [fe, oe]
103
- ), _e = ye.length + 5, Ke = q(
101
+ ), _e = z(
102
+ () => cr(fe, de),
103
+ [de, fe]
104
+ ), be = _e.length + 5, $e = z(
104
105
  () => ({
105
- "--slide-player-mobile-control-count": String(_e)
106
+ "--slide-player-mobile-control-count": String(be)
106
107
  }),
107
- [_e]
108
- ), W = q(
108
+ [be]
109
+ ), V = z(
109
110
  () => ({
110
- ...nr,
111
- ...de
111
+ ...ur,
112
+ ...me
112
113
  }),
113
- [de]
114
- ), te = q(() => f ? f.audioKey ?? `${String(f.sequenceNumber ?? "none")}:${String(f.audioUrl ?? "")}` : "none", [f]), Ze = J ? G : re, $e = J ? G ? "Pause autoplay" : "Play autoplay" : re ? "Pause" : "Play";
115
- S(() => {
116
- D.current = f;
117
- }, [f]), S(() => {
118
- I || B(!1);
119
- }, [I]), S(() => {
120
- !me.current && $ && B(!1), me.current = $;
121
- }, [$]), S(() => {
122
- j.current = k;
123
- }, [k]), S(() => {
124
- const e = f?.audioUrl, r = m >= 0 ? R[m + 1]?.audioUrl : void 0;
114
+ [me]
115
+ ), ne = z(() => f ? f.audioKey ?? `${String(f.sequenceNumber ?? "none")}:${String(f.audioUrl ?? "")}` : "none", [f]), He = Q ? J : te, Oe = Q ? J ? "Pause autoplay" : "Play autoplay" : te ? "Pause" : "Play";
116
+ b(() => {
117
+ X.current = f;
118
+ }, [f]), b(() => {
119
+ ee || $(!1);
120
+ }, [ee]), b(() => {
121
+ !pe.current && q && $(!1), pe.current = q;
122
+ }, [q]), b(() => {
123
+ j.current = w;
124
+ }, [w]), b(() => {
125
+ const e = f?.audioUrl, r = m >= 0 ? N[m + 1]?.audioUrl : void 0;
125
126
  Re(e), Re(r);
126
- }, [R, f?.audioUrl, m]);
127
+ }, [N, f?.audioUrl, m]);
127
128
  const n = u(
128
129
  (e, r = null) => {
129
- he.current === e && (!e || r === null) || (he.current = e, ne?.({
130
+ ye.current === e && (!e || r === null) || (ye.current = e, ue?.({
130
131
  loading: e,
131
132
  reason: e ? r : null
132
133
  }));
133
134
  },
134
- [ne]
135
- ), be = u((e) => e instanceof DOMException ? e.name === "NotAllowedError" || e.name === "SecurityError" : !1, []), L = u(() => A && !F && !g.current && C.current !== "blocked", [A, F]), Se = u((e) => e ? e.startsWith("data:") ? e : `data:audio/mpeg;base64,${e}` : "", []), xe = u(() => {
136
- const e = a.current;
135
+ [ue]
136
+ ), Se = u((e) => e instanceof DOMException ? e.name === "NotAllowedError" || e.name === "SecurityError" : !1, []), L = u(() => M && !U && !y.current && C.current !== "blocked", [M, U]), xe = u((e) => e ? e.startsWith("data:") ? e : `data:audio/mpeg;base64,${e}` : "", []), we = u(() => {
137
+ const e = c.current;
137
138
  return e == null || e <= 0 ? 0 : j.current.slice(0, e).reduce(
138
- (r, l) => r + Math.max(Number(l.duration_ms ?? 0), 0),
139
+ (r, s) => r + Math.max(Number(s.duration_ms ?? 0), 0),
139
140
  0
140
141
  ) / 1e3;
141
- }, []), P = u((e) => e <= 0 ? 0 : j.current.slice(0, e).reduce(
142
- (r, l) => r + Math.max(Number(l.duration_ms ?? 0), 0),
142
+ }, []), B = u((e) => e <= 0 ? 0 : j.current.slice(0, e).reduce(
143
+ (r, s) => r + Math.max(Number(s.duration_ms ?? 0), 0),
143
144
  0
144
- ), []), we = u(() => {
145
+ ), []), Ae = u(() => {
145
146
  const e = p.current;
146
- return e ? T.current === "segment" ? P(x.current) + Math.max(e.currentTime, 0) * 1e3 : h.current !== null && e.readyState === 0 ? h.current * 1e3 : Math.max(e.currentTime, 0) * 1e3 : a.current != null ? P(a.current) : 0;
147
- }, [P]), _ = u(
147
+ return e ? v.current === "segment" ? B(S.current) + Math.max(e.currentTime, 0) * 1e3 : h.current !== null && e.readyState === 0 ? h.current * 1e3 : Math.max(e.currentTime, 0) * 1e3 : c.current != null ? B(c.current) : 0;
148
+ }, [B]), _ = u(
148
149
  (e) => {
149
150
  const r = Math.max(e, 0);
150
- ee.current !== r && (ee.current = r, z?.(r));
151
+ re.current !== r && (re.current = r, D?.(r));
151
152
  },
152
- [z]
153
- ), o = u(() => {
154
- _(we());
155
- }, [we, _]), d = u(() => {
156
- typeof window > "u" || U.current === null || (window.cancelAnimationFrame(U.current), U.current = null);
157
- }, []), Ae = u(() => {
158
- if (typeof window > "u" || U.current !== null)
153
+ [D]
154
+ ), i = u(() => {
155
+ _(Ae());
156
+ }, [Ae, _]), d = u(() => {
157
+ typeof window > "u" || W.current === null || (window.cancelAnimationFrame(W.current), W.current = null);
158
+ }, []), Me = u(() => {
159
+ if (typeof window > "u" || W.current !== null)
159
160
  return;
160
161
  const e = () => {
161
- o();
162
+ i();
162
163
  const r = p.current;
163
164
  if (!r || r.paused || r.ended) {
164
- U.current = null;
165
+ W.current = null;
165
166
  return;
166
167
  }
167
- U.current = window.requestAnimationFrame(e);
168
+ W.current = window.requestAnimationFrame(e);
168
169
  };
169
- U.current = window.requestAnimationFrame(e);
170
- }, [o]), O = u(() => {
170
+ W.current = window.requestAnimationFrame(e);
171
+ }, [i]), H = u(() => {
171
172
  const e = p.current;
172
- e && (d(), s.current = !1, g.current = !1, H.current = !1, T.current = null, h.current = null, y.current = !1, w.current = !1, e.pause(), e.removeAttribute("src"), e.load(), M.current = null, x.current = 0, a.current = null, _(0), i(!1), n(!1));
173
- }, [_, d, n]), b = u(
173
+ e && (d(), l.current = !1, y.current = !1, K.current = !1, v.current = null, h.current = null, g.current = !1, x.current = !1, Z.current = null, e.pause(), e.removeAttribute("src"), e.load(), R.current = null, S.current = 0, c.current = null, _(0), o(!1), n(!1));
174
+ }, [_, d, n]), A = u(
174
175
  (e) => {
175
176
  const r = p.current;
176
177
  if (!r)
177
178
  return !1;
178
- const l = r.play();
179
- return l && typeof l.then == "function" && l.then(() => {
180
- C.current === "unknown" && (C.current = "auto"), s.current = !1, w.current = !1;
181
- }).catch((V) => {
182
- C.current === "unknown" && be(V) && (C.current = "blocked", s.current = !1, n(!1)), w.current = !1, i(!1);
179
+ const s = r.play();
180
+ return s && typeof s.then == "function" && s.then(() => {
181
+ C.current === "unknown" && (C.current = "auto"), l.current = !1, x.current = !1;
182
+ }).catch((E) => {
183
+ C.current === "unknown" && Se(E) && (C.current = "blocked", l.current = !1, n(!1)), x.current = !1, o(!1);
183
184
  }), !0;
184
185
  },
185
- [be, n]
186
- ), E = u(
186
+ [Se, n]
187
+ ), k = u(
187
188
  (e, r) => {
188
- const l = p.current, V = j.current[e];
189
- if (!l || !V)
189
+ const s = p.current, E = j.current[e];
190
+ if (!s || !E)
190
191
  return !1;
191
- const N = Se(V.audio_data);
192
- x.current = e, a.current = null, y.current = !1, w.current = !0, _(P(e));
193
- const Y = L();
194
- s.current = Y, n(!1);
195
- const Ie = M.current !== N;
196
- return T.current = "segment", Ie && (l.pause(), l.removeAttribute("src"), l.load(), M.current = N, l.src = N, l.load()), h.current = 0, l.readyState > 0 && (l.currentTime = 0, h.current = null), Y ? b(`start-segment:${r}`) : (s.current = !1, w.current = !1, l.pause(), i(!1), !0);
192
+ const T = xe(E.audio_data);
193
+ S.current = e, c.current = null, g.current = !1, x.current = !0, Z.current = "segment", _(B(e));
194
+ const G = L();
195
+ l.current = G, n(!1);
196
+ const er = R.current !== T;
197
+ return v.current = "segment", er && (s.pause(), s.removeAttribute("src"), s.load(), R.current = T, s.src = T, s.load()), h.current = 0, s.readyState > 0 && (s.currentTime = 0, h.current = null), G ? A(`start-segment:${r}`) : (l.current = !1, x.current = !1, s.pause(), o(!1), !0);
197
198
  },
198
199
  [
199
200
  L,
200
- Se,
201
- P,
201
+ xe,
202
+ B,
202
203
  _,
203
- b,
204
+ A,
204
205
  n
205
206
  ]
206
- ), Z = u(
207
+ ), O = u(
207
208
  (e) => {
208
- d(), s.current = !1, y.current = !1, w.current = !1, o(), i(!1), n(!1), m >= 0 && ie?.(m);
209
+ d(), l.current = !1, g.current = !1, x.current = !1, i(), o(!1), n(!1), m >= 0 && oe?.(m);
209
210
  },
210
211
  [
211
212
  m,
212
- ie,
213
+ oe,
213
214
  d,
214
- o,
215
+ i,
215
216
  n
216
217
  ]
217
- ), X = u(
218
+ ), Y = u(
218
219
  (e) => {
219
220
  const r = p.current;
220
- return !r || T.current !== "url" || !sr({
221
+ return !r || v.current !== "url" || !sr({
221
222
  currentTimeSeconds: Math.max(r.currentTime, 0),
222
223
  durationSeconds: r.duration
223
- }) ? !1 : (s.current = !1, r.pause(), Z(e), !0);
224
+ }) ? !1 : (l.current = !1, r.pause(), O(e), !0);
224
225
  },
225
- [Z]
226
- ), Me = u(() => {
227
- const e = x.current + 1, r = j.current, l = r[e], V = D.current, N = r.some((Y) => Y.is_final);
228
- if (l) {
229
- E(e, "ended");
226
+ [O]
227
+ ), je = u(() => {
228
+ const e = S.current + 1, r = j.current, s = r[e], E = X.current, T = r.some((G) => G.is_final);
229
+ if (s) {
230
+ k(e, "ended");
230
231
  return;
231
232
  }
232
- if (V?.isAudioStreaming || !N) {
233
- x.current = e, a.current = e, y.current = !0, s.current = A, _(P(e)), i(!1), n(!0, "waitingForMoreAudio");
233
+ if (E?.isAudioStreaming || !T) {
234
+ S.current = e, c.current = e, g.current = !0, l.current = M, _(B(e)), o(!1), n(!0, "waitingForMoreAudio");
234
235
  return;
235
236
  }
236
- Z("segments-completed");
237
+ O("segments-completed");
237
238
  }, [
238
- A,
239
- Z,
240
- P,
239
+ M,
240
+ O,
241
+ B,
241
242
  _,
242
- E,
243
+ k,
243
244
  n
244
245
  ]);
245
- S(() => {
246
- if (pe.current === te)
246
+ b(() => {
247
+ if (he.current === ne)
247
248
  return;
248
- pe.current = te, x.current = 0, a.current = null, y.current = !1, g.current = !1, H.current = !1, s.current = !1, w.current = !1, T.current = null, M.current = null, d(), _(0), n(!1);
249
+ he.current = ne, S.current = 0, c.current = null, g.current = !1, y.current = !1, K.current = !1, l.current = !1, x.current = !1, v.current = null, Z.current = null, R.current = null, d(), _(0), n(!1);
249
250
  const e = p.current;
250
- e && (e.pause(), e.removeAttribute("src"), e.load(), i(!1));
251
+ e && (e.pause(), e.removeAttribute("src"), e.load(), o(!1));
251
252
  }, [
252
253
  m,
253
- te,
254
- k.length,
255
- K,
254
+ ne,
255
+ w.length,
256
+ P,
256
257
  _,
257
258
  d,
258
259
  n
259
- ]), S(() => {
260
+ ]), b(() => {
260
261
  const e = p.current;
261
262
  if (e) {
262
- if (F) {
263
- H.current = !!(D.current && !g.current && (!e.paused || s.current || a.current !== null)), s.current = !1, n(!1), e.pause(), i(!1);
263
+ if (U) {
264
+ K.current = !!(X.current && !y.current && (!e.paused || l.current || c.current !== null)), l.current = !1, n(!1), e.pause(), o(!1);
264
265
  return;
265
266
  }
266
- if (!(!H.current || !D.current || g.current)) {
267
- if (H.current = !1, a.current !== null) {
268
- if (a.current < j.current.length) {
269
- E(a.current, "external-resume");
267
+ if (!(!K.current || !X.current || y.current)) {
268
+ if (K.current = !1, c.current !== null) {
269
+ if (c.current < j.current.length) {
270
+ k(c.current, "external-resume");
270
271
  return;
271
272
  }
272
- s.current = !0, n(!0, "waitingForMoreAudio");
273
+ l.current = !0, n(!0, "waitingForMoreAudio");
273
274
  return;
274
275
  }
275
- if (!M.current && j.current.length > 0) {
276
- E(
276
+ if (!R.current && j.current.length > 0) {
277
+ k(
277
278
  Math.min(
278
- x.current,
279
+ S.current,
279
280
  j.current.length - 1
280
281
  ),
281
282
  "external-resume-init"
282
283
  );
283
284
  return;
284
285
  }
285
- e.paused && (s.current = !0, b("external-resume"));
286
+ e.paused && (l.current = !0, A("external-resume"));
286
287
  }
287
288
  }
288
289
  }, [
289
- F,
290
- E,
291
- b,
290
+ U,
291
+ k,
292
+ A,
292
293
  n
293
- ]), S(() => {
294
+ ]), b(() => {
294
295
  const e = p.current;
295
- if (e) {
296
- if (!f) {
297
- O();
298
- return;
299
- }
300
- if (F) {
301
- s.current = !1, n(!1), e.pause(), i(!1);
302
- return;
303
- }
304
- if (K) {
305
- const r = M.current !== K, l = L();
306
- if (T.current === "segment" && !!M.current && a.current === null) {
307
- if (!l) {
308
- s.current = !1, e.pause(), i(!1);
309
- return;
310
- }
311
- e.paused && (s.current = !0, b("keep-segment-source"));
312
- return;
313
- }
314
- if (r) {
315
- const N = a.current !== null ? xe() : 0;
316
- e.pause(), e.removeAttribute("src"), e.load(), M.current = K, T.current = "url", e.src = K, e.load(), h.current = N, _(N * 1e3), e.readyState > 0 && (e.currentTime = N, h.current = null);
317
- }
318
- if (s.current = l, y.current = !1, w.current = !1, n(!1), !l) {
319
- s.current = !1, e.pause(), i(!1);
320
- return;
321
- }
322
- b(r ? "sync-url-init" : "sync-url");
323
- return;
296
+ if (!e)
297
+ return;
298
+ if (!f) {
299
+ H();
300
+ return;
301
+ }
302
+ if (U) {
303
+ l.current = !1, n(!1), e.pause(), o(!1);
304
+ return;
305
+ }
306
+ const r = ar({
307
+ activeSourceType: v.current,
308
+ hasAudioUrl: !!P,
309
+ segmentCount: w.length,
310
+ preferredSourceType: Z.current,
311
+ waitingSegmentIndex: c.current
312
+ });
313
+ if (r && Z.current !== r && (Z.current = r), r === "url" && P) {
314
+ const s = R.current !== P, E = L();
315
+ if (s) {
316
+ const T = c.current !== null ? we() : 0;
317
+ e.pause(), e.removeAttribute("src"), e.load(), R.current = P, v.current = "url", e.src = P, e.load(), h.current = T, _(T * 1e3), e.readyState > 0 && (e.currentTime = T, h.current = null);
324
318
  }
325
- if (a.current !== null) {
326
- if (a.current < k.length) {
327
- if (g.current) {
328
- i(!1), n(!1);
329
- return;
330
- }
331
- E(a.current, "wait-resume");
332
- return;
333
- }
334
- y.current = !0, s.current = L(), i(!1), n(L());
319
+ if (l.current = E, g.current = !1, x.current = !1, n(!1), !E) {
320
+ l.current = !1, e.pause(), o(!1);
335
321
  return;
336
322
  }
337
- if (!k.length) {
338
- if (f.isAudioStreaming) {
339
- a.current = x.current, y.current = !0, s.current = L(), i(!1), n(L());
323
+ A(s ? "sync-url-init" : "sync-url");
324
+ return;
325
+ }
326
+ if (r === "segment" && c.current !== null) {
327
+ if (c.current < w.length) {
328
+ if (y.current) {
329
+ o(!1), n(!1);
340
330
  return;
341
331
  }
342
- O();
343
- return;
344
- }
345
- if (!M.current) {
346
- E(
347
- Math.min(
348
- x.current,
349
- k.length - 1
350
- ),
351
- "effect-init"
352
- );
332
+ k(c.current, "wait-resume");
353
333
  return;
354
334
  }
355
- if (!A || g.current) {
356
- s.current = !1, e.pause(), i(!1);
335
+ g.current = !0, l.current = L(), o(!1), n(L());
336
+ return;
337
+ }
338
+ if (r === "segment" && !w.length) {
339
+ if (f.isAudioStreaming) {
340
+ c.current = S.current, g.current = !0, l.current = L(), o(!1), n(L());
357
341
  return;
358
342
  }
359
- e.paused && (s.current = !0, b("sync-paused-retry"));
343
+ H();
344
+ return;
345
+ }
346
+ if (r === "segment" && !R.current) {
347
+ k(
348
+ Math.min(
349
+ S.current,
350
+ w.length - 1
351
+ ),
352
+ "effect-init"
353
+ );
354
+ return;
355
+ }
356
+ if (r !== "segment") {
357
+ H();
358
+ return;
360
359
  }
360
+ if (!M || y.current) {
361
+ l.current = !1, e.pause(), o(!1);
362
+ return;
363
+ }
364
+ e.paused && (l.current = !0, A("sync-paused-retry"));
361
365
  }, [
362
366
  f,
363
367
  m,
364
- k,
365
- K,
366
- A,
367
- F,
368
+ w,
369
+ P,
370
+ M,
371
+ U,
368
372
  L,
369
373
  _,
370
- O,
371
- E,
372
- b,
373
- xe,
374
+ H,
375
+ k,
376
+ A,
377
+ we,
374
378
  n
375
- ]), S(() => O, [O]), S(() => d, [d]);
376
- const He = u(() => {
377
- o(), Ae(), i(!0), n(!1), ue?.();
379
+ ]), b(() => H, [H]), b(() => d, [d]);
380
+ const qe = u(() => {
381
+ i(), Me(), o(!0), n(!1), le?.();
378
382
  }, [
379
- ue,
380
- Ae,
381
- o,
383
+ le,
384
+ Me,
385
+ i,
382
386
  n
383
- ]), Oe = u(() => {
384
- y.current || w.current || (d(), o(), i(!1));
385
- }, [m, d, o]), qe = u(() => {
387
+ ]), Ke = u(() => {
388
+ g.current || x.current || (d(), i(), o(!1));
389
+ }, [m, d, i]), ze = u(() => {
386
390
  const e = p.current;
387
- e && h.current !== null && (e.currentTime = h.current, h.current = null), o(), !X("canplay-seek-finished") && (!s.current || !A || b("canplay"));
391
+ e && h.current !== null && (e.currentTime = h.current, h.current = null), i(), !Y("canplay-seek-finished") && (!l.current || !M || A("canplay"));
388
392
  }, [
389
393
  m,
390
- A,
391
- X,
392
- o,
393
- b
394
- ]), ze = u(() => {
394
+ M,
395
+ Y,
396
+ i,
397
+ A
398
+ ]), De = u(() => {
395
399
  const e = p.current;
396
- e && h.current !== null && (e.currentTime = h.current, h.current = null), o(), X("metadata-seek-finished");
397
- }, [m, X, o]), De = u(() => {
398
- o();
399
- }, [o]), Xe = u(() => {
400
- y.current || n(!0, "loadingAudio");
401
- }, [n]), Ye = u(() => {
402
- if (y.current) {
400
+ e && h.current !== null && (e.currentTime = h.current, h.current = null), i(), Y("metadata-seek-finished");
401
+ }, [m, Y, i]), Xe = u(() => {
402
+ i();
403
+ }, [i]), Ye = u(() => {
404
+ g.current || n(!0, "loadingAudio");
405
+ }, [n]), Ge = u(() => {
406
+ if (g.current) {
403
407
  n(!0, "waitingForMoreAudio");
404
408
  return;
405
409
  }
406
410
  n(!0, "loadingAudio");
407
- }, [n]), je = u(() => {
408
- o();
409
- }, [o]), Ge = u(() => {
410
- const e = T.current === "url" || j.current.length === 0;
411
- if (d(), w.current = !1, e) {
412
- Z("url-ended");
411
+ }, [n]), ke = u(() => {
412
+ i();
413
+ }, [i]), Je = u(() => {
414
+ const e = v.current === "url" || j.current.length === 0;
415
+ if (d(), x.current = !1, e) {
416
+ O("url-ended");
413
417
  return;
414
418
  }
415
- Me();
416
- }, [Z, Me, d]), Je = u(() => {
417
- d(), o(), i(!1), n(!1);
418
- }, [d, o, n]), Qe = u(
419
+ je();
420
+ }, [O, je, d]), Qe = u(() => {
421
+ d(), i(), o(!1), n(!1);
422
+ }, [d, i, n]), Ie = u(
419
423
  (e) => {
420
- ce?.(e), B(!1);
424
+ ie?.(e), $(!1);
421
425
  },
422
- [ce]
426
+ [ie]
423
427
  );
424
- return S(() => {
425
- z?.(ee.current);
426
- }, [z]), /* @__PURE__ */ t.jsxs("div", { className: Ee("slide-player", v), ...Be, children: [
428
+ return b(() => {
429
+ D?.(re.current);
430
+ }, [D]), /* @__PURE__ */ t.jsxs("div", { className: Te("slide-player", F), ...Ze, children: [
427
431
  /* @__PURE__ */ t.jsx(
428
432
  "audio",
429
433
  {
430
434
  ref: p,
431
435
  preload: "auto",
432
436
  playsInline: !0,
433
- onLoadStart: Xe,
434
- onLoadedMetadata: ze,
435
- onCanPlay: qe,
436
- onPlay: He,
437
- onPause: Oe,
438
- onWaiting: Ye,
439
- onSeeking: je,
440
- onSeeked: je,
441
- onTimeUpdate: De,
442
- onEnded: Ge,
443
- onError: Je
437
+ onLoadStart: Ye,
438
+ onLoadedMetadata: De,
439
+ onCanPlay: ze,
440
+ onPlay: qe,
441
+ onPause: Ke,
442
+ onWaiting: Ge,
443
+ onSeeking: ke,
444
+ onSeeked: ke,
445
+ onTimeUpdate: Xe,
446
+ onEnded: Je,
447
+ onError: Qe
444
448
  }
445
449
  ),
446
- I ? /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
450
+ ee ? /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
447
451
  /* @__PURE__ */ t.jsx(
448
- tr,
452
+ nr,
449
453
  {
450
- container: ve,
454
+ container: Fe,
451
455
  labels: {
452
- fullscreen: W.fullscreenLabel,
453
- nonFullscreen: W.nonFullscreenLabel,
454
- screen: W.screenLabel,
455
- subtitle: W.subtitleLabel,
456
- subtitleToggle: W.subtitleToggleAriaLabel,
457
- title: W.settingsTitle
456
+ fullscreen: V.fullscreenLabel,
457
+ nonFullscreen: V.nonFullscreenLabel,
458
+ screen: V.screenLabel,
459
+ subtitle: V.subtitleLabel,
460
+ subtitleToggle: V.subtitleToggleAriaLabel,
461
+ title: V.settingsTitle
458
462
  },
459
- isSubtitleEnabled: Q,
460
- onClose: () => B(!1),
461
- onOpenChange: B,
463
+ isSubtitleEnabled: I,
464
+ onClose: () => $(!1),
465
+ onOpenChange: $,
462
466
  onSubtitleToggle: se ?? (() => {
463
467
  }),
464
- onViewModeChange: Qe,
468
+ onViewModeChange: Ie,
465
469
  open: ge,
466
470
  viewMode: Le
467
471
  }
468
472
  ),
469
- /* @__PURE__ */ t.jsxs("div", { className: "slide-player__controls", style: Ke, children: [
473
+ /* @__PURE__ */ t.jsxs("div", { className: "slide-player__controls", style: $e, children: [
470
474
  /* @__PURE__ */ t.jsxs("div", { className: "slide-player__group", children: [
471
475
  /* @__PURE__ */ t.jsx(
472
476
  "button",
@@ -476,11 +480,11 @@ const Ne = /* @__PURE__ */ new Map(), Re = (R) => {
476
480
  "aria-label": "More options",
477
481
  className: "slide-player__action slide-player__action--mobile-more",
478
482
  onClick: () => {
479
- B((e) => !e);
483
+ $((e) => !e);
480
484
  },
481
485
  type: "button",
482
486
  children: /* @__PURE__ */ t.jsx(
483
- ar,
487
+ ir,
484
488
  {
485
489
  className: "slide-player__icon",
486
490
  strokeWidth: 2.25
@@ -488,17 +492,17 @@ const Ne = /* @__PURE__ */ new Map(), Re = (R) => {
488
492
  )
489
493
  }
490
494
  ),
491
- /* @__PURE__ */ t.jsx("button", { "aria-label": "Volume", className: "hidden", type: "button", children: /* @__PURE__ */ t.jsx(cr, { className: "slide-player__icon", strokeWidth: 2.25 }) }),
495
+ /* @__PURE__ */ t.jsx("button", { "aria-label": "Volume", className: "hidden", type: "button", children: /* @__PURE__ */ t.jsx(or, { className: "slide-player__icon", strokeWidth: 2.25 }) }),
492
496
  /* @__PURE__ */ t.jsx(
493
497
  "button",
494
498
  {
495
- "aria-label": W.subtitleToggleAriaLabel,
496
- "aria-pressed": Q,
499
+ "aria-label": V.subtitleToggleAriaLabel,
500
+ "aria-pressed": I,
497
501
  className: "slide-player__action slide-player__action--subtitle",
498
502
  onClick: se,
499
503
  type: "button",
500
- children: Q ? /* @__PURE__ */ t.jsx(ir, { className: "slide-player__icon", strokeWidth: 2.25 }) : /* @__PURE__ */ t.jsx(
501
- or,
504
+ children: I ? /* @__PURE__ */ t.jsx(fr, { className: "slide-player__icon", strokeWidth: 2.25 }) : /* @__PURE__ */ t.jsx(
505
+ dr,
502
506
  {
503
507
  className: "slide-player__icon",
504
508
  strokeWidth: 2.25
@@ -511,51 +515,51 @@ const Ne = /* @__PURE__ */ new Map(), Re = (R) => {
511
515
  {
512
516
  "aria-label": "Rewind",
513
517
  className: "slide-player__action slide-player__action--prev",
514
- disabled: Pe,
515
- onClick: Te,
518
+ disabled: Ve,
519
+ onClick: ve,
516
520
  type: "button",
517
- children: /* @__PURE__ */ t.jsx(fr, { className: "slide-player__icon", strokeWidth: 2.25 })
521
+ children: /* @__PURE__ */ t.jsx(mr, { className: "slide-player__icon", strokeWidth: 2.25 })
518
522
  }
519
523
  ),
520
524
  /* @__PURE__ */ t.jsx(
521
525
  "button",
522
526
  {
523
- "aria-label": $e,
527
+ "aria-label": Oe,
524
528
  className: "slide-player__toggle slide-player__toggle--playback",
525
529
  onClick: () => {
526
- if (J) {
527
- Fe?.(!G);
530
+ if (Q) {
531
+ Ue?.(!J);
528
532
  return;
529
533
  }
530
534
  const e = p.current;
531
- if (!(F || !e || !f)) {
532
- if (a.current !== null) {
533
- if (re) {
534
- s.current = !1, g.current = !0, a.current = null, y.current = !1, i(!1), n(!1), e.pause();
535
+ if (!(U || !e || !f)) {
536
+ if (c.current !== null) {
537
+ if (te) {
538
+ l.current = !1, y.current = !0, c.current = null, g.current = !1, o(!1), n(!1), e.pause();
535
539
  return;
536
540
  }
537
- C.current = "manual", g.current = !1, s.current = !0, n(!0, "waitingForMoreAudio");
541
+ C.current = "manual", y.current = !1, l.current = !0, n(!0, "waitingForMoreAudio");
538
542
  return;
539
543
  }
540
- if (!e.src && k.length > 0) {
541
- C.current = "manual", g.current = !1, E(
544
+ if (!e.src && w.length > 0) {
545
+ C.current = "manual", y.current = !1, k(
542
546
  Math.min(
543
- x.current,
544
- k.length - 1
547
+ S.current,
548
+ w.length - 1
545
549
  ),
546
550
  "toggle"
547
551
  );
548
552
  return;
549
553
  }
550
554
  if (e.paused) {
551
- C.current = "manual", g.current = !1, s.current = !0, b("toggle-resume");
555
+ C.current = "manual", y.current = !1, l.current = !0, A("toggle-resume");
552
556
  return;
553
557
  }
554
- s.current = !1, g.current = !0, e.pause();
558
+ l.current = !1, y.current = !0, e.pause();
555
559
  }
556
560
  },
557
561
  type: "button",
558
- children: Ze ? /* @__PURE__ */ t.jsx(gr, {}) : /* @__PURE__ */ t.jsx(yr, {})
562
+ children: He ? /* @__PURE__ */ t.jsx(_r, {}) : /* @__PURE__ */ t.jsx(br, {})
559
563
  }
560
564
  ),
561
565
  /* @__PURE__ */ t.jsx(
@@ -563,27 +567,27 @@ const Ne = /* @__PURE__ */ new Map(), Re = (R) => {
563
567
  {
564
568
  "aria-label": "Forward",
565
569
  className: "slide-player__action slide-player__action--next",
566
- disabled: Ve,
570
+ disabled: Be,
567
571
  onClick: Ce,
568
572
  type: "button",
569
- children: /* @__PURE__ */ t.jsx(dr, { className: "slide-player__icon", strokeWidth: 2.25 })
573
+ children: /* @__PURE__ */ t.jsx(pr, { className: "slide-player__icon", strokeWidth: 2.25 })
570
574
  }
571
575
  ),
572
- le ? /* @__PURE__ */ t.jsx(
576
+ ae ? /* @__PURE__ */ t.jsx(
573
577
  "button",
574
578
  {
575
- "aria-label": ae ? "Exit fullscreen" : "Enter fullscreen",
579
+ "aria-label": ce ? "Exit fullscreen" : "Enter fullscreen",
576
580
  className: "slide-player__action slide-player__action--fullscreen",
577
- onClick: le,
581
+ onClick: ae,
578
582
  type: "button",
579
- children: ae ? /* @__PURE__ */ t.jsx(
580
- mr,
583
+ children: ce ? /* @__PURE__ */ t.jsx(
584
+ hr,
581
585
  {
582
586
  className: "slide-player__icon",
583
587
  strokeWidth: 2.25
584
588
  }
585
589
  ) : /* @__PURE__ */ t.jsx(
586
- pr,
590
+ yr,
587
591
  {
588
592
  className: "slide-player__icon",
589
593
  strokeWidth: 2.25
@@ -594,20 +598,20 @@ const Ne = /* @__PURE__ */ new Map(), Re = (R) => {
594
598
  ] }),
595
599
  /* @__PURE__ */ t.jsx("div", { className: "slide-player__separator" }),
596
600
  /* @__PURE__ */ t.jsxs("div", { className: "slide-player__group", children: [
597
- ye.map((e, r) => /* @__PURE__ */ t.jsx(er.Fragment, { children: e }, `custom-action-${r}`)),
601
+ _e.map((e, r) => /* @__PURE__ */ t.jsx(rr.Fragment, { children: e }, `custom-action-${r}`)),
598
602
  /* @__PURE__ */ t.jsx(
599
603
  "button",
600
604
  {
601
605
  "aria-label": "Notes",
602
- className: Ee(
606
+ className: Te(
603
607
  "slide-player__action slide-player__action--notes",
604
- $ && "slide-player__action--active"
608
+ q && "slide-player__action--active"
605
609
  ),
606
- disabled: !We,
607
- onClick: Ue,
610
+ disabled: !Pe,
611
+ onClick: We,
608
612
  type: "button",
609
613
  children: /* @__PURE__ */ t.jsx(
610
- hr,
614
+ gr,
611
615
  {
612
616
  className: "slide-player__icon",
613
617
  strokeWidth: 2.25
@@ -619,9 +623,9 @@ const Ne = /* @__PURE__ */ new Map(), Re = (R) => {
619
623
  ] })
620
624
  ] }) : null
621
625
  ] });
622
- }, br = rr(_r);
623
- br.displayName = "Player";
626
+ }, xr = tr(Sr);
627
+ xr.displayName = "Player";
624
628
  export {
625
- br as default
629
+ xr as default
626
630
  };
627
631
  //# sourceMappingURL=Player.es.js.map