@instructure/studio-player 0.2.5 → 0.2.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/studio-player.es.js
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import './index-aLp7_0kW.css';var
|
|
2
|
-
var
|
|
3
|
-
var
|
|
4
|
-
import { jsx as t, jsxs as s, Fragment as
|
|
5
|
-
import { createContext as
|
|
6
|
-
import { useMediaPlayer as q, Spinner as
|
|
7
|
-
import { initReactI18next as
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import { useFloating as
|
|
11
|
-
const
|
|
1
|
+
import './index-aLp7_0kW.css';var ze = Object.defineProperty;
|
|
2
|
+
var Ke = (e, n, o) => n in e ? ze(e, n, { enumerable: !0, configurable: !0, writable: !0, value: o }) : e[n] = o;
|
|
3
|
+
var x = (e, n, o) => Ke(e, typeof n != "symbol" ? n + "" : n, o);
|
|
4
|
+
import { jsx as t, jsxs as s, Fragment as ee } from "react/jsx-runtime";
|
|
5
|
+
import { createContext as te, useContext as P, useState as M, useCallback as p, useEffect as E, useMemo as Z, useRef as ve } from "react";
|
|
6
|
+
import { useMediaPlayer as q, Spinner as Y, useMediaRemote as W, useMediaState as _, isTrackCaptionKind as De, Track as je, Captions as Ue, usePlaybackRateOptions as qe, useCaptionOptions as We, useVideoQualityOptions as Ge, useMediaStore as be, FullscreenButton as Ce, PlayButton as Qe, Poster as Ye, Time as re, TimeSlider as A, MuteButton as Je, VolumeSlider as D, MediaPlayer as Xe, MediaProvider as et } from "@vidstack/react";
|
|
7
|
+
import { initReactI18next as tt, useTranslation as g } from "react-i18next";
|
|
8
|
+
import nt from "i18next";
|
|
9
|
+
import ot from "i18next-resources-to-backend";
|
|
10
|
+
import { useFloating as ge, autoUpdate as ke, flip as ye, arrow as we, useDismiss as Le, useInteractions as Pe, FloatingFocusManager as it, FloatingArrow as Ne, shift as at, offset as st } from "@floating-ui/react";
|
|
11
|
+
const ct = (e, n, o) => {
|
|
12
12
|
const i = e[n];
|
|
13
13
|
return i ? typeof i == "function" ? i() : Promise.resolve(i) : new Promise((a, c) => {
|
|
14
14
|
(typeof queueMicrotask == "function" ? queueMicrotask : setTimeout)(
|
|
@@ -21,9 +21,9 @@ const ot = (e, n, o) => {
|
|
|
21
21
|
);
|
|
22
22
|
});
|
|
23
23
|
};
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
(e) =>
|
|
24
|
+
nt.use(tt).use(
|
|
25
|
+
ot(
|
|
26
|
+
(e) => ct(/* @__PURE__ */ Object.assign({ "./locales/en.json": () => import("./en-DRnzP2ly.js"), "./locales/kl.json": () => import("./kl-DAr1HilW.js") }), `./locales/${e}.json`, 3)
|
|
27
27
|
)
|
|
28
28
|
).init({
|
|
29
29
|
fallbackLng: "en",
|
|
@@ -34,23 +34,23 @@ Je.use(Ye).use(
|
|
|
34
34
|
escapeValue: !1
|
|
35
35
|
}
|
|
36
36
|
});
|
|
37
|
-
const
|
|
38
|
-
function
|
|
37
|
+
const xe = te(null);
|
|
38
|
+
function lt({
|
|
39
39
|
children: e,
|
|
40
40
|
contextValue: n
|
|
41
41
|
}) {
|
|
42
|
-
return /* @__PURE__ */ t(
|
|
42
|
+
return /* @__PURE__ */ t(xe.Provider, { value: n, children: e });
|
|
43
43
|
}
|
|
44
|
-
function
|
|
45
|
-
const e =
|
|
44
|
+
function v() {
|
|
45
|
+
const e = P(xe);
|
|
46
46
|
if (!e)
|
|
47
47
|
throw new Error(
|
|
48
48
|
"useStudioPlayerContext must be used within a StudioPlayerContextProvider"
|
|
49
49
|
);
|
|
50
50
|
return e;
|
|
51
51
|
}
|
|
52
|
-
const
|
|
53
|
-
function
|
|
52
|
+
const Me = te(null);
|
|
53
|
+
function rt({
|
|
54
54
|
hideFullScreen: e,
|
|
55
55
|
comments: n,
|
|
56
56
|
annotations: o,
|
|
@@ -59,11 +59,13 @@ function at({
|
|
|
59
59
|
onAnnotationClick: c,
|
|
60
60
|
onQuizMarkerClick: l,
|
|
61
61
|
onInteractivePinClick: u,
|
|
62
|
-
interactiveMenuElements:
|
|
63
|
-
darkMode:
|
|
64
|
-
children: b
|
|
62
|
+
interactiveMenuElements: m,
|
|
63
|
+
darkMode: h,
|
|
64
|
+
children: b,
|
|
65
|
+
forceComments: w,
|
|
66
|
+
disableCaptionSettings: y
|
|
65
67
|
}) {
|
|
66
|
-
const
|
|
68
|
+
const C = {
|
|
67
69
|
hideFullScreen: e,
|
|
68
70
|
comments: n,
|
|
69
71
|
annotations: o,
|
|
@@ -72,80 +74,82 @@ function at({
|
|
|
72
74
|
onAnnotationClick: c,
|
|
73
75
|
onQuizMarkerClick: l,
|
|
74
76
|
onInteractivePinClick: u,
|
|
75
|
-
interactiveMenuElements:
|
|
76
|
-
darkMode:
|
|
77
|
+
interactiveMenuElements: m,
|
|
78
|
+
darkMode: h,
|
|
77
79
|
hasComments: n.length > 0,
|
|
78
80
|
hasAnnotations: o.length > 0,
|
|
79
|
-
hasQuizmarkers: i.length > 0
|
|
81
|
+
hasQuizmarkers: i.length > 0,
|
|
82
|
+
forceComments: w,
|
|
83
|
+
disableCaptionSettings: y
|
|
80
84
|
};
|
|
81
|
-
return /* @__PURE__ */ t(
|
|
85
|
+
return /* @__PURE__ */ t(Me.Provider, { value: C, children: b });
|
|
82
86
|
}
|
|
83
|
-
function
|
|
84
|
-
const e =
|
|
87
|
+
function S() {
|
|
88
|
+
const e = P(Me);
|
|
85
89
|
if (!e)
|
|
86
90
|
throw new Error(
|
|
87
91
|
"useStudioPlayerPropsContext must be used within a StudioPlayerPropsContextProvider"
|
|
88
92
|
);
|
|
89
93
|
return e;
|
|
90
94
|
}
|
|
91
|
-
const
|
|
95
|
+
const ut = "_annotation-overlay_1kxzn_1", dt = {
|
|
92
96
|
"annotation-overlay": "_annotation-overlay_1kxzn_1",
|
|
93
|
-
annotationOverlay:
|
|
94
|
-
},
|
|
97
|
+
annotationOverlay: ut
|
|
98
|
+
}, ue = 0.25, mt = (e, n) => {
|
|
95
99
|
let o = !1;
|
|
96
100
|
return (i) => {
|
|
97
101
|
const a = i.detail.currentTime;
|
|
98
|
-
a >= e.time && a < e.time +
|
|
102
|
+
a >= e.time && a < e.time + ue && !o && (o = !0, n(e)), (a < e.time || a >= e.time + ue) && o && (o = !1);
|
|
99
103
|
};
|
|
100
104
|
};
|
|
101
|
-
function
|
|
102
|
-
const n = q(), o =
|
|
105
|
+
function ht({ annotations: e }) {
|
|
106
|
+
const n = q(), o = v(), i = S(), [a, c] = M(
|
|
103
107
|
null
|
|
104
|
-
), l =
|
|
105
|
-
(
|
|
106
|
-
n == null || n.pause(), i.interactive || o.disableInteractions(), c(
|
|
108
|
+
), l = p(
|
|
109
|
+
(m) => {
|
|
110
|
+
n == null || n.pause(), i.interactive || o.disableInteractions(), c(m);
|
|
107
111
|
},
|
|
108
112
|
[n, o]
|
|
109
113
|
), u = () => {
|
|
110
114
|
i.interactive || (n == null || n.play(), o.enableInteractions()), c(null);
|
|
111
115
|
};
|
|
112
|
-
return
|
|
116
|
+
return E(() => {
|
|
113
117
|
if (!n)
|
|
114
118
|
return;
|
|
115
|
-
const
|
|
116
|
-
for (const
|
|
117
|
-
const b =
|
|
118
|
-
n.addEventListener("time-update", b),
|
|
119
|
+
const m = [];
|
|
120
|
+
for (const h of e) {
|
|
121
|
+
const b = mt(h, l);
|
|
122
|
+
n.addEventListener("time-update", b), m.push(b);
|
|
119
123
|
}
|
|
120
124
|
if (a) {
|
|
121
|
-
const
|
|
125
|
+
const h = e.find(
|
|
122
126
|
(b) => b.id === a.id
|
|
123
127
|
);
|
|
124
|
-
|
|
128
|
+
h ? c(h) : (c(null), o.enableInteractions());
|
|
125
129
|
}
|
|
126
130
|
return () => {
|
|
127
|
-
for (const
|
|
128
|
-
n.removeEventListener("time-update",
|
|
131
|
+
for (const h of m)
|
|
132
|
+
n.removeEventListener("time-update", h);
|
|
129
133
|
};
|
|
130
|
-
}, [n, e]), a ? /* @__PURE__ */ t("div", { className:
|
|
134
|
+
}, [n, e]), a ? /* @__PURE__ */ t("div", { className: dt.annotationOverlay, children: a.render(u) }) : null;
|
|
131
135
|
}
|
|
132
|
-
const
|
|
136
|
+
const pt = "_media-buffering-indicator_1fwjr_1", _t = "_media-buffering-spinner_1fwjr_17", ft = "_media-buffering-spin_1fwjr_17", vt = "_media-buffering-track_1fwjr_22", bt = "_media-buffering-track-fill_1fwjr_27", j = {
|
|
133
137
|
"media-buffering-indicator": "_media-buffering-indicator_1fwjr_1",
|
|
134
|
-
mediaBufferingIndicator:
|
|
138
|
+
mediaBufferingIndicator: pt,
|
|
135
139
|
"media-buffering-spinner": "_media-buffering-spinner_1fwjr_17",
|
|
136
|
-
mediaBufferingSpinner:
|
|
140
|
+
mediaBufferingSpinner: _t,
|
|
137
141
|
"media-buffering-spin": "_media-buffering-spin_1fwjr_17",
|
|
138
|
-
mediaBufferingSpin:
|
|
142
|
+
mediaBufferingSpin: ft,
|
|
139
143
|
"media-buffering-track": "_media-buffering-track_1fwjr_22",
|
|
140
|
-
mediaBufferingTrack:
|
|
144
|
+
mediaBufferingTrack: vt,
|
|
141
145
|
"media-buffering-track-fill": "_media-buffering-track-fill_1fwjr_27",
|
|
142
|
-
mediaBufferingTrackFill:
|
|
146
|
+
mediaBufferingTrackFill: bt
|
|
143
147
|
};
|
|
144
|
-
function
|
|
145
|
-
return /* @__PURE__ */ t("div", { className: j.mediaBufferingIndicator, children: /* @__PURE__ */ s(
|
|
146
|
-
/* @__PURE__ */ t(
|
|
148
|
+
function Ct() {
|
|
149
|
+
return /* @__PURE__ */ t("div", { className: j.mediaBufferingIndicator, children: /* @__PURE__ */ s(Y.Root, { className: j.mediaBufferingSpinner, size: 96, children: [
|
|
150
|
+
/* @__PURE__ */ t(Y.Track, { className: j.mediaBufferingTrack, width: 8 }),
|
|
147
151
|
/* @__PURE__ */ t(
|
|
148
|
-
|
|
152
|
+
Y.TrackFill,
|
|
149
153
|
{
|
|
150
154
|
className: j.mediaBufferingTrackFill,
|
|
151
155
|
width: 8
|
|
@@ -153,15 +157,15 @@ function _t() {
|
|
|
153
157
|
)
|
|
154
158
|
] }) });
|
|
155
159
|
}
|
|
156
|
-
const
|
|
160
|
+
const Te = (e) => /* @__PURE__ */ s("svg", { width: 24, height: 24, viewBox: "0 0 24 24", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e, children: [
|
|
157
161
|
/* @__PURE__ */ t("defs", { children: /* @__PURE__ */ t("clipPath", { id: "clip0_149_104418", children: /* @__PURE__ */ t("rect", { width: 24, height: 24, fill: "white" }) }) }),
|
|
158
162
|
/* @__PURE__ */ t("g", { clipPath: "url(#clip0_149_104418)", children: /* @__PURE__ */ t("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M22.5 21.8125V2.3125C22.5 1.9 22.1625 1.5625 21.75 1.5625H2.25C1.8375 1.5625 1.5 1.9 1.5 2.3125V21.8125C1.5 22.225 1.8375 22.5625 2.25 22.5625H21.75C22.1625 22.5625 22.5 22.225 22.5 21.8125ZM21.75 0.0625C22.9905 0.0625 24 1.072 24 2.3125V21.8125C24 23.053 22.9905 24.0625 21.75 24.0625H2.25C1.0095 24.0625 0 23.053 0 21.8125V2.3125C0 1.072 1.0095 0.0625 2.25 0.0625H21.75ZM10.744 10.6709H8.74403V10.0042H6.07736V14.0042H8.74403V13.3375H10.744V14.6709C10.744 15.4042 10.144 16.0042 9.41069 16.0042H5.41069C4.67736 16.0042 4.07736 15.4042 4.07736 14.6709V9.33753C4.07736 8.6042 4.67736 8.0042 5.41069 8.0042H9.41069C10.144 8.0042 10.744 8.6042 10.744 9.33753V10.6709ZM19.8065 10.6709H17.8065V10.0042H15.1399V14.0042H17.8065V13.3375H19.8065V14.6709C19.8065 15.4042 19.2065 16.0042 18.4732 16.0042H14.4732C13.7399 16.0042 13.1399 15.4042 13.1399 14.6709V9.33753C13.1399 8.6042 13.7399 8.0042 14.4732 8.0042H18.4732C19.2065 8.0042 19.8065 8.6042 19.8065 9.33753V10.6709Z", fill: "currentColor" }) })
|
|
159
|
-
] }),
|
|
163
|
+
] }), Ie = (e) => /* @__PURE__ */ s("svg", { width: 24, height: 24, viewBox: "0 0 24 24", xmlns: "http://www.w3.org/2000/svg", ...e, children: [
|
|
160
164
|
/* @__PURE__ */ t("defs", { children: /* @__PURE__ */ t("clipPath", { id: "clip0_149_104406", children: /* @__PURE__ */ t("rect", { width: 24, height: 24, fill: "white" }) }) }),
|
|
161
165
|
/* @__PURE__ */ t("g", { clipPath: "url(#clip0_149_104406)", children: /* @__PURE__ */ t("path", { d: "M21.3333 0H2.66666C1.18666 0 0 1.35 0 3V21C0 22.65 1.18666 24 2.66666 24H21.3333C22.8 24 24 22.65 24 21V3C24 1.35 22.8 0 21.3333 0ZM10.6667 10.6667H8.66666V10H6V14H8.66666V13.3333H10.6667V14.6667C10.6667 15.4 10.0667 16 9.33334 16H5.33334C4.6 16 4 15.4 4 14.6667V9.33334C4 8.6 4.6 8 5.33334 8H9.33334C10.0667 8 10.6667 8.6 10.6667 9.33334V10.6667ZM20.0042 10.6667H18.0042V10H15.3375V14H18.0042V13.3333H20.0042V14.6667C20.0042 15.4 19.4042 16 18.6708 16H14.6708C13.9375 16 13.3375 15.4 13.3375 14.6667V9.33334C13.3375 8.6 13.9375 8 14.6708 8H18.6708C19.4042 8 20.0042 8.6 20.0042 9.33334V10.6667Z", fill: "currentColor" }) })
|
|
162
166
|
] });
|
|
163
|
-
function
|
|
164
|
-
const e = W(), n =
|
|
167
|
+
function gt() {
|
|
168
|
+
const e = W(), n = _("textTrack"), o = _("hasCaptions"), i = n && De(n), a = v(), c = p(
|
|
165
169
|
(l) => {
|
|
166
170
|
e.toggleCaptions(l.nativeEvent);
|
|
167
171
|
},
|
|
@@ -175,18 +179,18 @@ function ft() {
|
|
|
175
179
|
onClick: c,
|
|
176
180
|
"aria-label": "Captions",
|
|
177
181
|
tabIndex: a.state.interactionsDisabled ? -1 : 0,
|
|
178
|
-
children: i ? /* @__PURE__ */ t(
|
|
182
|
+
children: i ? /* @__PURE__ */ t(Ie, { className: "controls-button-icon" }) : /* @__PURE__ */ t(Te, { className: "controls-button-icon" })
|
|
179
183
|
}
|
|
180
184
|
) : null;
|
|
181
185
|
}
|
|
182
|
-
const
|
|
183
|
-
captions:
|
|
186
|
+
const kt = "_captions_13epz_1", yt = {
|
|
187
|
+
captions: kt
|
|
184
188
|
};
|
|
185
|
-
function
|
|
186
|
-
const n =
|
|
187
|
-
return /* @__PURE__ */ s(
|
|
189
|
+
function wt({ captions: e }) {
|
|
190
|
+
const n = _("hasCaptions"), o = v();
|
|
191
|
+
return /* @__PURE__ */ s(ee, { children: [
|
|
188
192
|
e.map((i) => /* @__PURE__ */ t(
|
|
189
|
-
|
|
193
|
+
je,
|
|
190
194
|
{
|
|
191
195
|
kind: "subtitles",
|
|
192
196
|
type: i.type,
|
|
@@ -206,13 +210,13 @@ function Ct({ captions: e }) {
|
|
|
206
210
|
"--captions-color": o.state.captionsInvertColors ? "rgba(22, 22, 22)" : "white",
|
|
207
211
|
"--captions-background-color": o.state.captionsInvertColors ? "rgba(255, 255, 255, 0.75)" : "rgba(22, 22, 22, 0.75)"
|
|
208
212
|
},
|
|
209
|
-
children: /* @__PURE__ */ t(
|
|
213
|
+
children: /* @__PURE__ */ t(Ue, { className: yt.captions })
|
|
210
214
|
}
|
|
211
215
|
) : null
|
|
212
216
|
] });
|
|
213
217
|
}
|
|
214
|
-
const
|
|
215
|
-
const [, n] =
|
|
218
|
+
const B = [0.5, 0.75, 1, 1.25, 1.5, 2], Lt = [0.5, 1, 2, 3, 4], Se = 5, Pt = (e) => {
|
|
219
|
+
const [, n] = M({});
|
|
216
220
|
return Z(() => {
|
|
217
221
|
let o = [];
|
|
218
222
|
return {
|
|
@@ -222,125 +226,137 @@ const V = [0.5, 0.75, 1, 1.25, 1.5, 2], gt = [0.5, 1, 2, 3, 4], Me = 5, kt = (e)
|
|
|
222
226
|
remove(i) {
|
|
223
227
|
o = o.filter((a) => a !== i), n({});
|
|
224
228
|
},
|
|
229
|
+
clear() {
|
|
230
|
+
o = [], n({});
|
|
231
|
+
},
|
|
225
232
|
map(i) {
|
|
226
233
|
return o.map(i);
|
|
227
234
|
}
|
|
228
235
|
};
|
|
229
236
|
}, []);
|
|
230
|
-
},
|
|
237
|
+
}, Nt = (e, n, o) => {
|
|
231
238
|
let i = !1;
|
|
232
239
|
return (a) => {
|
|
233
240
|
const c = a.detail.currentTime;
|
|
234
241
|
c >= e.timestamp && c < e.timestamp + n && !i && (o.add(e), i = !0), (c < e.timestamp || c >= e.timestamp + n) && i && (o.remove(e), i = !1);
|
|
235
242
|
};
|
|
236
|
-
},
|
|
237
|
-
const o = q(), i =
|
|
238
|
-
return
|
|
243
|
+
}, xt = (e, n = 5) => {
|
|
244
|
+
const o = q(), i = Pt(n);
|
|
245
|
+
return E(() => {
|
|
239
246
|
if (!o)
|
|
240
247
|
return;
|
|
241
248
|
const a = [];
|
|
242
249
|
for (const c of e) {
|
|
243
|
-
const l =
|
|
250
|
+
const l = Nt(c, Se, i);
|
|
244
251
|
a.push(l), o.addEventListener("time-update", l);
|
|
245
252
|
}
|
|
246
|
-
return (
|
|
253
|
+
return o.dispatchEvent(
|
|
254
|
+
new CustomEvent("time-update", {
|
|
255
|
+
detail: { currentTime: o.currentTime }
|
|
256
|
+
})
|
|
257
|
+
), () => {
|
|
247
258
|
for (const c of a)
|
|
248
259
|
o.removeEventListener("time-update", c);
|
|
260
|
+
i.clear();
|
|
249
261
|
};
|
|
250
262
|
}, [o, i, e]), i;
|
|
251
|
-
},
|
|
263
|
+
}, Mt = "_comments-overlay_agbjl_1", Tt = "_comments-container_agbjl_9", It = "_comment_agbjl_1", St = "_comment-text_agbjl_44", Ht = "_comment-author-avatar_agbjl_67", Vt = "_comment-author-name_agbjl_86", R = {
|
|
252
264
|
"comments-overlay": "_comments-overlay_agbjl_1",
|
|
253
|
-
commentsOverlay:
|
|
265
|
+
commentsOverlay: Mt,
|
|
254
266
|
"comments-container": "_comments-container_agbjl_9",
|
|
255
|
-
commentsContainer:
|
|
256
|
-
comment:
|
|
267
|
+
commentsContainer: Tt,
|
|
268
|
+
comment: It,
|
|
257
269
|
"comment-text": "_comment-text_agbjl_44",
|
|
258
|
-
commentText:
|
|
270
|
+
commentText: St,
|
|
259
271
|
"comment-author-avatar": "_comment-author-avatar_agbjl_67",
|
|
260
|
-
commentAuthorAvatar:
|
|
272
|
+
commentAuthorAvatar: Ht,
|
|
261
273
|
"comment-author-name": "_comment-author-name_agbjl_86",
|
|
262
|
-
commentAuthorName:
|
|
274
|
+
commentAuthorName: Vt
|
|
263
275
|
};
|
|
264
|
-
function
|
|
265
|
-
return /* @__PURE__ */ s("div", { className:
|
|
276
|
+
function Bt({ comment: e }) {
|
|
277
|
+
return /* @__PURE__ */ s("div", { className: R.comment, onClick: e.onClick, children: [
|
|
266
278
|
/* @__PURE__ */ t(
|
|
267
279
|
"img",
|
|
268
280
|
{
|
|
269
|
-
className:
|
|
281
|
+
className: R.commentAuthorAvatar,
|
|
270
282
|
src: e.user.avatar,
|
|
271
283
|
alt: e.user.name
|
|
272
284
|
}
|
|
273
285
|
),
|
|
274
|
-
/* @__PURE__ */ t("span", { className:
|
|
275
|
-
/* @__PURE__ */ t("span", { className:
|
|
286
|
+
/* @__PURE__ */ t("span", { className: R.commentText, children: e.text }),
|
|
287
|
+
/* @__PURE__ */ t("span", { className: R.commentAuthorName, children: e.user.name })
|
|
276
288
|
] });
|
|
277
289
|
}
|
|
278
|
-
const
|
|
279
|
-
function
|
|
280
|
-
const n =
|
|
290
|
+
const Rt = 5;
|
|
291
|
+
function Et({ comments: e }) {
|
|
292
|
+
const n = v(), o = xt(e, Rt), i = !!_("textTrack"), a = o.map((c) => /* @__PURE__ */ t(Bt, { comment: c }, c.id));
|
|
281
293
|
return e.length > 0 && n.state.commentsEnabled ? /* @__PURE__ */ t(
|
|
282
294
|
"div",
|
|
283
295
|
{
|
|
284
|
-
className:
|
|
296
|
+
className: R.commentsOverlay,
|
|
285
297
|
style: {
|
|
286
298
|
flexDirection: n.state.captionPositionOnTop && i ? "column-reverse" : "column"
|
|
287
299
|
},
|
|
288
|
-
children: /* @__PURE__ */ t("div", { className:
|
|
300
|
+
children: /* @__PURE__ */ t("div", { className: R.commentsContainer, children: i ? a.slice(-4) : a })
|
|
289
301
|
}
|
|
290
302
|
) : null;
|
|
291
303
|
}
|
|
292
|
-
const
|
|
293
|
-
root:
|
|
304
|
+
const At = "_root_fph0z_1", Ot = "_left-controls_fph0z_28", Ft = "_right-controls_fph0z_34", Zt = "_indicators_fph0z_40", $t = "_normal-timeline_fph0z_49", zt = "_compact-timeline_fph0z_55", V = {
|
|
305
|
+
root: At,
|
|
294
306
|
"left-controls": "_left-controls_fph0z_28",
|
|
295
|
-
leftControls:
|
|
307
|
+
leftControls: Ot,
|
|
296
308
|
"right-controls": "_right-controls_fph0z_34",
|
|
297
|
-
rightControls:
|
|
298
|
-
indicators:
|
|
309
|
+
rightControls: Ft,
|
|
310
|
+
indicators: Zt,
|
|
299
311
|
"normal-timeline": "_normal-timeline_fph0z_49",
|
|
300
|
-
normalTimeline:
|
|
312
|
+
normalTimeline: $t,
|
|
301
313
|
"compact-timeline": "_compact-timeline_fph0z_55",
|
|
302
|
-
compactTimeline:
|
|
314
|
+
compactTimeline: zt
|
|
303
315
|
};
|
|
304
|
-
function
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
316
|
+
function Kt({
|
|
317
|
+
darkMode: e,
|
|
318
|
+
playerRef: n,
|
|
319
|
+
showCaptionsButton: o = !0
|
|
320
|
+
}) {
|
|
321
|
+
const i = q();
|
|
322
|
+
return E(() => {
|
|
323
|
+
i && (i.remoteControl.pauseControls(), n && (n.current = i));
|
|
324
|
+
}, [i, n]), /* @__PURE__ */ s("div", { "data-darkmode": e, className: V.root, children: [
|
|
325
|
+
/* @__PURE__ */ t(he, { className: V.normalTimeline }),
|
|
326
|
+
/* @__PURE__ */ s("div", { className: V.leftControls, children: [
|
|
327
|
+
/* @__PURE__ */ t(ro, {}),
|
|
328
|
+
/* @__PURE__ */ t(hi, {})
|
|
313
329
|
] }),
|
|
314
|
-
/* @__PURE__ */ t("div", { className:
|
|
315
|
-
/* @__PURE__ */ t(
|
|
316
|
-
/* @__PURE__ */ s("div", { className:
|
|
317
|
-
/* @__PURE__ */ t(
|
|
318
|
-
/* @__PURE__ */ t(
|
|
319
|
-
/* @__PURE__ */ t(
|
|
330
|
+
/* @__PURE__ */ t("div", { className: V.indicators, children: /* @__PURE__ */ t(wo, {}) }),
|
|
331
|
+
/* @__PURE__ */ t(he, { className: V.compactTimeline }),
|
|
332
|
+
/* @__PURE__ */ s("div", { className: V.rightControls, children: [
|
|
333
|
+
o && /* @__PURE__ */ t(gt, {}),
|
|
334
|
+
/* @__PURE__ */ t(Rn, {}),
|
|
335
|
+
/* @__PURE__ */ t(Yn, {})
|
|
320
336
|
] })
|
|
321
337
|
] });
|
|
322
338
|
}
|
|
323
|
-
const
|
|
339
|
+
const N = te(null), Dt = (e) => /* @__PURE__ */ t("svg", { width: 18, height: 18, viewBox: "0 0 18 18", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e, children: /* @__PURE__ */ t("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M6 3.03704L7.03704 2L14.037 9L7.03704 16L6 14.963L11.963 9L6 3.03704Z", fill: "currentColor" }) }), jt = "_menu-hint_k49ve_1", Ut = "_menu-button_k49ve_5", qt = "_menu-label_k49ve_37", Wt = "_menu-icon_k49ve_42", U = {
|
|
324
340
|
"menu-hint": "_menu-hint_k49ve_1",
|
|
325
|
-
menuHint:
|
|
341
|
+
menuHint: jt,
|
|
326
342
|
"menu-button": "_menu-button_k49ve_5",
|
|
327
|
-
menuButton:
|
|
343
|
+
menuButton: Ut,
|
|
328
344
|
"menu-label": "_menu-label_k49ve_37",
|
|
329
|
-
menuLabel:
|
|
345
|
+
menuLabel: qt,
|
|
330
346
|
"menu-icon": "_menu-icon_k49ve_42",
|
|
331
|
-
menuIcon:
|
|
347
|
+
menuIcon: Wt
|
|
332
348
|
};
|
|
333
349
|
function $({ label: e, hint: n, onClick: o, Icon: i }) {
|
|
334
350
|
return /* @__PURE__ */ s("button", { type: "button", className: U.menuButton, onClick: o, children: [
|
|
335
351
|
i && /* @__PURE__ */ t(i, { className: U.menuIcon }),
|
|
336
352
|
/* @__PURE__ */ t("span", { className: U.menuLabel, children: e }),
|
|
337
353
|
/* @__PURE__ */ t("span", { className: U.menuHint, children: n }),
|
|
338
|
-
/* @__PURE__ */ t(
|
|
354
|
+
/* @__PURE__ */ t(Dt, {})
|
|
339
355
|
] });
|
|
340
356
|
}
|
|
341
|
-
const
|
|
342
|
-
function
|
|
343
|
-
const e =
|
|
357
|
+
const Gt = (e) => /* @__PURE__ */ t("svg", { width: 18, height: 18, viewBox: "0 0 18 18", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e, children: /* @__PURE__ */ t("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M3.42229 2.82911C4.71149 1.83006 6.23876 1.19768 7.8383 1L7.96797 2.05432C6.55867 2.22862 5.21101 2.7866 4.07273 3.66874L3.42229 2.82911ZM5.44493 6.71393L9.49745 10.7665L17.0924 3.1705L17.8438 3.92297L9.49745 12.2693L4.69352 7.46534L5.44493 6.71393ZM17.932 8.83829C17.8618 8.27074 17.7364 7.70745 17.5589 7.16222L16.5482 7.49276C16.7055 7.97209 16.816 8.46843 16.8766 8.96689C16.917 9.29742 16.9372 9.6269 16.9372 9.96594C16.9372 10.305 16.917 10.6344 16.8777 10.9639C16.7033 12.3732 16.1454 13.7209 15.2632 14.8592L16.1029 15.5096C17.1019 14.2204 17.7343 12.6931 17.932 11.0925C17.9766 10.7205 18 10.3486 18 9.96594C18 9.58332 17.9766 9.21134 17.932 8.83829ZM1.05432 8.96795L0 8.83829C0.197684 7.23874 0.830061 5.71147 1.82911 4.42228L2.66874 5.07272C1.7866 6.211 1.22862 7.55865 1.05432 8.96795ZM0 11.0936C0.197684 12.6931 0.830061 14.2204 1.82911 15.5096L2.66874 14.8591C1.7866 13.7209 1.22862 12.3732 1.05432 10.9639L0 11.0936ZM10.0939 1.00011C11.6935 1.19673 13.2207 1.83017 14.5099 2.82922L13.8595 3.66884C12.7202 2.7867 11.3736 2.22872 9.96426 2.05442L10.0939 1.00011Z", fill: "currentColor" }) });
|
|
358
|
+
function Qt() {
|
|
359
|
+
const e = P(N), n = _("playbackRate"), { t: o } = g(), i = p(() => {
|
|
344
360
|
e && e.setPage("speed");
|
|
345
361
|
}, [e]);
|
|
346
362
|
return e ? /* @__PURE__ */ t(
|
|
@@ -349,12 +365,12 @@ function Ut() {
|
|
|
349
365
|
label: o("PLAYBACK_SPEED"),
|
|
350
366
|
hint: `${n}x`,
|
|
351
367
|
onClick: i,
|
|
352
|
-
Icon:
|
|
368
|
+
Icon: Gt
|
|
353
369
|
}
|
|
354
370
|
) : null;
|
|
355
371
|
}
|
|
356
|
-
function
|
|
357
|
-
const e =
|
|
372
|
+
function Yt() {
|
|
373
|
+
const e = P(N), n = _("hasCaptions"), o = _("textTrack"), { t: i } = g(), a = p(() => {
|
|
358
374
|
e && e.setPage("captions");
|
|
359
375
|
}, [e]);
|
|
360
376
|
return e && n ? /* @__PURE__ */ t(
|
|
@@ -363,11 +379,11 @@ function qt() {
|
|
|
363
379
|
label: i("CAPTIONS"),
|
|
364
380
|
hint: (o == null ? void 0 : o.label) ?? i("OFF"),
|
|
365
381
|
onClick: a,
|
|
366
|
-
Icon:
|
|
382
|
+
Icon: Te
|
|
367
383
|
}
|
|
368
384
|
) : null;
|
|
369
385
|
}
|
|
370
|
-
const
|
|
386
|
+
const Jt = (e) => /* @__PURE__ */ s("svg", { width: 18, height: 18, viewBox: "0 0 18 18", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e, children: [
|
|
371
387
|
/* @__PURE__ */ t("defs", { children: /* @__PURE__ */ t("clipPath", { id: "clip0_412_23039", children: /* @__PURE__ */ t("rect", { width: 18, height: 18, fill: "white" }) }) }),
|
|
372
388
|
/* @__PURE__ */ s("g", { clipPath: "url(#clip0_412_23039)", children: [
|
|
373
389
|
/* @__PURE__ */ t("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M2.46326 3.85039H0V2.65039H2.46326C2.7388 1.36449 3.88181 0.400391 5.24999 0.400391C6.61818 0.400391 7.76119 1.36449 8.03673 2.65039H18V3.85039H8.03673C7.76119 5.13629 6.61818 6.10039 5.24999 6.10039C3.88181 6.10039 2.7388 5.13629 2.46326 3.85039ZM3.59999 3.25039C3.59999 2.33912 4.33872 1.60039 5.24999 1.60039C6.16126 1.60039 6.89999 2.33912 6.89999 3.25039C6.89999 4.16166 6.16126 4.90039 5.24999 4.90039C4.33872 4.90039 3.59999 4.16166 3.59999 3.25039Z", fill: "currentColor" }),
|
|
@@ -375,8 +391,8 @@ const Wt = (e) => /* @__PURE__ */ s("svg", { width: 18, height: 18, viewBox: "0
|
|
|
375
391
|
/* @__PURE__ */ t("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M5.24999 17.6004C6.61818 17.6004 7.76119 16.6363 8.03673 15.3504H18V14.1504H8.03673C7.76119 12.8645 6.61818 11.9004 5.24999 11.9004C3.88181 11.9004 2.7388 12.8645 2.46326 14.1504H0V15.3504H2.46326C2.7388 16.6363 3.88181 17.6004 5.24999 17.6004ZM5.24999 13.1004C4.33872 13.1004 3.59999 13.8391 3.59999 14.7504C3.59999 15.6617 4.33872 16.4004 5.24999 16.4004C6.16126 16.4004 6.89999 15.6617 6.89999 14.7504C6.89999 13.8391 6.16126 13.1004 5.24999 13.1004Z", fill: "currentColor" })
|
|
376
392
|
] })
|
|
377
393
|
] });
|
|
378
|
-
function
|
|
379
|
-
const e =
|
|
394
|
+
function Xt() {
|
|
395
|
+
const e = P(N), n = _("autoQuality"), o = _("quality"), { t: i } = g(), a = p(() => {
|
|
380
396
|
e && e.setPage("quality");
|
|
381
397
|
}, [e]);
|
|
382
398
|
return e && o ? /* @__PURE__ */ t(
|
|
@@ -385,31 +401,31 @@ function Gt() {
|
|
|
385
401
|
label: i("QUALITY"),
|
|
386
402
|
hint: n ? i("AUTO", { quality: o.height }) : `${o.height}p`,
|
|
387
403
|
onClick: a,
|
|
388
|
-
Icon:
|
|
404
|
+
Icon: Jt
|
|
389
405
|
}
|
|
390
406
|
) : null;
|
|
391
407
|
}
|
|
392
|
-
const
|
|
408
|
+
const en = (e) => /* @__PURE__ */ t("svg", { width: 24, height: 24, viewBox: "0 0 24 24", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e, children: /* @__PURE__ */ t("path", { d: "M 21.798373,3.342155 8.8843977,16.256145 2.2000774,9.571825 0,11.771895 8.8843977,20.657845 24,5.543795 Z", fill: "currentColor" }) }), tn = (e) => /* @__PURE__ */ t("svg", { width: 24, height: 24, viewBox: "0 0 24 24", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e, children: /* @__PURE__ */ t("path", { d: "M 9.64706,12 4,17.64706 6.35293,20 12,14.35293 17.64706,20 20,17.64706 14.35293,12 20,6.35293 17.64706,4 12,9.64706 6.35293,4 4,6.35293 Z", fill: "currentColor" }) }), nn = "_switch-track_vptv3_1", on = "_switch-thumb_vptv3_11", an = "_switch-icon_vptv3_25", sn = "_switch-body_vptv3_31", cn = "_switch-label_vptv3_68", ln = "_menu-icon_vptv3_72", I = {
|
|
393
409
|
"switch-track": "_switch-track_vptv3_1",
|
|
394
|
-
switchTrack:
|
|
410
|
+
switchTrack: nn,
|
|
395
411
|
"switch-thumb": "_switch-thumb_vptv3_11",
|
|
396
|
-
switchThumb:
|
|
412
|
+
switchThumb: on,
|
|
397
413
|
"switch-icon": "_switch-icon_vptv3_25",
|
|
398
|
-
switchIcon:
|
|
414
|
+
switchIcon: an,
|
|
399
415
|
"switch-body": "_switch-body_vptv3_31",
|
|
400
|
-
switchBody:
|
|
416
|
+
switchBody: sn,
|
|
401
417
|
"switch-label": "_switch-label_vptv3_68",
|
|
402
|
-
switchLabel:
|
|
418
|
+
switchLabel: cn,
|
|
403
419
|
"menu-icon": "_menu-icon_vptv3_72",
|
|
404
|
-
menuIcon:
|
|
420
|
+
menuIcon: ln
|
|
405
421
|
};
|
|
406
|
-
function
|
|
422
|
+
function ne({
|
|
407
423
|
label: e,
|
|
408
424
|
checked: n = !1,
|
|
409
425
|
onClick: o,
|
|
410
426
|
Icon: i
|
|
411
427
|
}) {
|
|
412
|
-
const a =
|
|
428
|
+
const a = p(
|
|
413
429
|
(c) => {
|
|
414
430
|
(c.key === "Enter" || c.key === " ") && (o == null || o());
|
|
415
431
|
},
|
|
@@ -418,35 +434,35 @@ function te({
|
|
|
418
434
|
return /* @__PURE__ */ s(
|
|
419
435
|
"div",
|
|
420
436
|
{
|
|
421
|
-
className:
|
|
437
|
+
className: I.switchBody,
|
|
422
438
|
role: "menuitemcheckbox",
|
|
423
439
|
"aria-checked": n,
|
|
424
440
|
onClick: o,
|
|
425
441
|
onKeyDown: a,
|
|
426
442
|
tabIndex: 0,
|
|
427
443
|
children: [
|
|
428
|
-
i && /* @__PURE__ */ t(i, { className:
|
|
429
|
-
/* @__PURE__ */ t("span", { className:
|
|
430
|
-
/* @__PURE__ */ t("div", { className:
|
|
444
|
+
i && /* @__PURE__ */ t(i, { className: I.menuIcon }),
|
|
445
|
+
/* @__PURE__ */ t("span", { className: I.switchLabel, children: e }),
|
|
446
|
+
/* @__PURE__ */ t("div", { className: I.switchTrack, children: /* @__PURE__ */ t("div", { className: I.switchThumb, children: n ? /* @__PURE__ */ t(en, { className: I.switchIcon }) : /* @__PURE__ */ t(tn, { className: I.switchIcon }) }) })
|
|
431
447
|
]
|
|
432
448
|
}
|
|
433
449
|
);
|
|
434
450
|
}
|
|
435
|
-
const
|
|
436
|
-
function
|
|
437
|
-
const { t: e } =
|
|
438
|
-
return n.hasComments ? /* @__PURE__ */ t(
|
|
439
|
-
|
|
451
|
+
const rn = (e) => /* @__PURE__ */ t("svg", { width: 18, height: 18, viewBox: "0 0 18 18", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e, children: /* @__PURE__ */ t("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M1 0V12.7489H5.44V18L10.5007 12.7489H16.582V0H1ZM2 1H15.58V11.7339H9.98655L6.52667 15.25V11.7339H2V1ZM5.24963 5.35011H12.3323V4.24835H5.24963V5.35011ZM5.24963 8.18462H9.50067V7.08285H5.24963V8.18462Z", fill: "currentColor" }) });
|
|
452
|
+
function un() {
|
|
453
|
+
const { t: e } = g(), n = S(), o = v();
|
|
454
|
+
return !n.forceComments && n.hasComments ? /* @__PURE__ */ t(
|
|
455
|
+
ne,
|
|
440
456
|
{
|
|
441
|
-
Icon:
|
|
457
|
+
Icon: rn,
|
|
442
458
|
label: e("COMMENTS"),
|
|
443
459
|
onClick: o.toggleComments,
|
|
444
460
|
checked: o.state.commentsEnabled
|
|
445
461
|
}
|
|
446
462
|
) : null;
|
|
447
463
|
}
|
|
448
|
-
function
|
|
449
|
-
|
|
464
|
+
function H(e) {
|
|
465
|
+
E(() => {
|
|
450
466
|
const n = (o) => {
|
|
451
467
|
o.key === "Escape" && (e == null || e());
|
|
452
468
|
};
|
|
@@ -455,41 +471,41 @@ function T(e) {
|
|
|
455
471
|
};
|
|
456
472
|
}, []);
|
|
457
473
|
}
|
|
458
|
-
const
|
|
474
|
+
const dn = "_main-menu_7h96l_1", mn = {
|
|
459
475
|
"main-menu": "_main-menu_7h96l_1",
|
|
460
|
-
mainMenu:
|
|
476
|
+
mainMenu: dn
|
|
461
477
|
};
|
|
462
|
-
function
|
|
463
|
-
const e =
|
|
464
|
-
return
|
|
465
|
-
/* @__PURE__ */ t(
|
|
466
|
-
/* @__PURE__ */ t(
|
|
467
|
-
/* @__PURE__ */ t(
|
|
468
|
-
/* @__PURE__ */ t(
|
|
478
|
+
function hn() {
|
|
479
|
+
const e = P(N);
|
|
480
|
+
return H(e == null ? void 0 : e.toggle), /* @__PURE__ */ s("div", { className: mn.mainMenu, children: [
|
|
481
|
+
/* @__PURE__ */ t(Qt, {}),
|
|
482
|
+
/* @__PURE__ */ t(Yt, {}),
|
|
483
|
+
/* @__PURE__ */ t(un, {}),
|
|
484
|
+
/* @__PURE__ */ t(Xt, {})
|
|
469
485
|
] });
|
|
470
486
|
}
|
|
471
|
-
const G = (e) => /* @__PURE__ */ t("svg", { width: 18, height: 18, viewBox: "0 0 18 18", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e, children: /* @__PURE__ */ t("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M17.1347 3.00061L6.55157 13.5825L0.865302 7.89624L0 8.76154L6.55157 15.3131L17.9988 3.86469L17.1347 3.00061Z", fill: "currentColor" }) }), z = (e) => /* @__PURE__ */ t("svg", { width: 18, height: 18, viewBox: "0 0 18 18", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e, children: /* @__PURE__ */ t("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M12.037 3.03704L6.07407 9L12.037 14.963L11 16L4 9L11 2L12.037 3.03704Z", fill: "currentColor" }) }),
|
|
487
|
+
const G = (e) => /* @__PURE__ */ t("svg", { width: 18, height: 18, viewBox: "0 0 18 18", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e, children: /* @__PURE__ */ t("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M17.1347 3.00061L6.55157 13.5825L0.865302 7.89624L0 8.76154L6.55157 15.3131L17.9988 3.86469L17.1347 3.00061Z", fill: "currentColor" }) }), z = (e) => /* @__PURE__ */ t("svg", { width: 18, height: 18, viewBox: "0 0 18 18", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e, children: /* @__PURE__ */ t("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M12.037 3.03704L6.07407 9L12.037 14.963L11 16L4 9L11 2L12.037 3.03704Z", fill: "currentColor" }) }), pn = "_menu-container_1bjr3_1", _n = "_menu-options_1bjr3_6", fn = "_menu-heading_1bjr3_11", vn = "_check-icon_1bjr3_27", bn = "_menu-item-label_1bjr3_33", Cn = "_menu-item_1bjr3_33", gn = "_menu-back-button_1bjr3_66", r = {
|
|
472
488
|
"menu-container": "_menu-container_1bjr3_1",
|
|
473
|
-
menuContainer:
|
|
489
|
+
menuContainer: pn,
|
|
474
490
|
"menu-options": "_menu-options_1bjr3_6",
|
|
475
|
-
menuOptions:
|
|
491
|
+
menuOptions: _n,
|
|
476
492
|
"menu-heading": "_menu-heading_1bjr3_11",
|
|
477
|
-
menuHeading:
|
|
493
|
+
menuHeading: fn,
|
|
478
494
|
"check-icon": "_check-icon_1bjr3_27",
|
|
479
|
-
checkIcon:
|
|
495
|
+
checkIcon: vn,
|
|
480
496
|
"menu-item-label": "_menu-item-label_1bjr3_33",
|
|
481
|
-
menuItemLabel:
|
|
497
|
+
menuItemLabel: bn,
|
|
482
498
|
"menu-item": "_menu-item_1bjr3_33",
|
|
483
|
-
menuItem:
|
|
499
|
+
menuItem: Cn,
|
|
484
500
|
"menu-back-button": "_menu-back-button_1bjr3_66",
|
|
485
|
-
menuBackButton:
|
|
501
|
+
menuBackButton: gn
|
|
486
502
|
};
|
|
487
|
-
function
|
|
488
|
-
const e =
|
|
489
|
-
rates:
|
|
503
|
+
function kn() {
|
|
504
|
+
const e = P(N), n = qe({
|
|
505
|
+
rates: B,
|
|
490
506
|
normalLabel: "1x"
|
|
491
|
-
}), { t: o } =
|
|
492
|
-
return
|
|
507
|
+
}), { t: o } = g();
|
|
508
|
+
return H(e == null ? void 0 : e.backToMain), e ? /* @__PURE__ */ s("div", { className: r.menuContainer, children: [
|
|
493
509
|
/* @__PURE__ */ s(
|
|
494
510
|
"button",
|
|
495
511
|
{
|
|
@@ -522,8 +538,8 @@ function vn() {
|
|
|
522
538
|
)) })
|
|
523
539
|
] }) : null;
|
|
524
540
|
}
|
|
525
|
-
function
|
|
526
|
-
const e =
|
|
541
|
+
function yn() {
|
|
542
|
+
const e = P(N), n = _("textTrack"), { t: o } = g(), i = p(() => {
|
|
527
543
|
e && e.setPage("captionLanguage");
|
|
528
544
|
}, [e]);
|
|
529
545
|
return e ? /* @__PURE__ */ t(
|
|
@@ -535,8 +551,8 @@ function bn() {
|
|
|
535
551
|
}
|
|
536
552
|
) : null;
|
|
537
553
|
}
|
|
538
|
-
function
|
|
539
|
-
const { t: e } =
|
|
554
|
+
function wn() {
|
|
555
|
+
const { t: e } = g(), n = v(), o = P(N), i = p(() => {
|
|
540
556
|
o && o.setPage("captionFontSize");
|
|
541
557
|
}, [o]);
|
|
542
558
|
return o ? /* @__PURE__ */ t(
|
|
@@ -548,10 +564,10 @@ function Cn() {
|
|
|
548
564
|
}
|
|
549
565
|
) : null;
|
|
550
566
|
}
|
|
551
|
-
function
|
|
552
|
-
const { t: e } =
|
|
567
|
+
function Ln() {
|
|
568
|
+
const { t: e } = g(), n = v();
|
|
553
569
|
return /* @__PURE__ */ t(
|
|
554
|
-
|
|
570
|
+
ne,
|
|
555
571
|
{
|
|
556
572
|
label: e("ON_TOP"),
|
|
557
573
|
onClick: n.toggleCaptionPositionOnTop,
|
|
@@ -559,10 +575,10 @@ function gn() {
|
|
|
559
575
|
}
|
|
560
576
|
);
|
|
561
577
|
}
|
|
562
|
-
function
|
|
563
|
-
const { t: e } =
|
|
578
|
+
function Pn() {
|
|
579
|
+
const { t: e } = g(), n = v();
|
|
564
580
|
return /* @__PURE__ */ t(
|
|
565
|
-
|
|
581
|
+
ne,
|
|
566
582
|
{
|
|
567
583
|
label: e("INVERT_COLORS"),
|
|
568
584
|
onClick: n.toggleCaptionsInvertColors,
|
|
@@ -570,9 +586,9 @@ function kn() {
|
|
|
570
586
|
}
|
|
571
587
|
);
|
|
572
588
|
}
|
|
573
|
-
function
|
|
574
|
-
const e =
|
|
575
|
-
return
|
|
589
|
+
function Nn() {
|
|
590
|
+
const e = P(N), { t: n } = g(), { disableCaptionSettings: o } = v();
|
|
591
|
+
return H(e == null ? void 0 : e.backToMain), e ? /* @__PURE__ */ s("div", { className: r.menuContainer, children: [
|
|
576
592
|
/* @__PURE__ */ s(
|
|
577
593
|
"button",
|
|
578
594
|
{
|
|
@@ -586,15 +602,15 @@ function yn() {
|
|
|
586
602
|
}
|
|
587
603
|
),
|
|
588
604
|
/* @__PURE__ */ t("strong", { className: r.menuHeading, children: n("CAPTIONS") }),
|
|
589
|
-
/* @__PURE__ */ t(
|
|
590
|
-
/* @__PURE__ */ t(
|
|
591
|
-
/* @__PURE__ */ t(
|
|
592
|
-
/* @__PURE__ */ t(
|
|
605
|
+
!o && /* @__PURE__ */ t(yn, {}),
|
|
606
|
+
/* @__PURE__ */ t(wn, {}),
|
|
607
|
+
/* @__PURE__ */ t(Ln, {}),
|
|
608
|
+
/* @__PURE__ */ t(Pn, {})
|
|
593
609
|
] }) : null;
|
|
594
610
|
}
|
|
595
|
-
function
|
|
596
|
-
const e =
|
|
597
|
-
return
|
|
611
|
+
function xn() {
|
|
612
|
+
const e = P(N), n = We(), { t: o } = g();
|
|
613
|
+
return H(e == null ? void 0 : e.backToCaptions), e ? /* @__PURE__ */ s("div", { className: r.menuContainer, children: [
|
|
598
614
|
/* @__PURE__ */ s(
|
|
599
615
|
"button",
|
|
600
616
|
{
|
|
@@ -627,9 +643,9 @@ function wn() {
|
|
|
627
643
|
)) })
|
|
628
644
|
] }) : null;
|
|
629
645
|
}
|
|
630
|
-
function
|
|
631
|
-
const e =
|
|
632
|
-
return
|
|
646
|
+
function Mn() {
|
|
647
|
+
const e = v(), n = P(N), { t: o } = g();
|
|
648
|
+
return H(n == null ? void 0 : n.backToCaptions), n ? /* @__PURE__ */ s("div", { className: r.menuContainer, children: [
|
|
633
649
|
/* @__PURE__ */ s(
|
|
634
650
|
"button",
|
|
635
651
|
{
|
|
@@ -643,7 +659,7 @@ function Ln() {
|
|
|
643
659
|
}
|
|
644
660
|
),
|
|
645
661
|
/* @__PURE__ */ t("strong", { className: r.menuHeading, children: o("CAPTIONS") }),
|
|
646
|
-
/* @__PURE__ */ t("div", { role: "menu", className: r.menuOptions, children:
|
|
662
|
+
/* @__PURE__ */ t("div", { role: "menu", className: r.menuOptions, children: Lt.map((i) => /* @__PURE__ */ s(
|
|
647
663
|
"button",
|
|
648
664
|
{
|
|
649
665
|
type: "button",
|
|
@@ -665,9 +681,9 @@ function Ln() {
|
|
|
665
681
|
)) })
|
|
666
682
|
] }) : null;
|
|
667
683
|
}
|
|
668
|
-
function
|
|
669
|
-
const e =
|
|
670
|
-
return
|
|
684
|
+
function Tn() {
|
|
685
|
+
const e = P(N), n = Ge({ sort: "descending" }), o = _("autoQuality"), { t: i } = g();
|
|
686
|
+
return H(e == null ? void 0 : e.backToMain), e ? /* @__PURE__ */ s("div", { className: r.menuContainer, children: [
|
|
671
687
|
/* @__PURE__ */ s(
|
|
672
688
|
"button",
|
|
673
689
|
{
|
|
@@ -700,58 +716,58 @@ function Pn() {
|
|
|
700
716
|
)) })
|
|
701
717
|
] }) : null;
|
|
702
718
|
}
|
|
703
|
-
const
|
|
704
|
-
main:
|
|
705
|
-
speed:
|
|
706
|
-
captions:
|
|
707
|
-
captionLanguage:
|
|
708
|
-
captionFontSize:
|
|
709
|
-
quality:
|
|
719
|
+
const In = {
|
|
720
|
+
main: hn,
|
|
721
|
+
speed: kn,
|
|
722
|
+
captions: Nn,
|
|
723
|
+
captionLanguage: xn,
|
|
724
|
+
captionFontSize: Mn,
|
|
725
|
+
quality: Tn
|
|
710
726
|
};
|
|
711
|
-
function
|
|
712
|
-
const [e, n] =
|
|
713
|
-
i((
|
|
714
|
-
}, []), c =
|
|
715
|
-
n(
|
|
716
|
-
}, []), l =
|
|
727
|
+
function Sn() {
|
|
728
|
+
const [e, n] = M("main"), [o, i] = M(!1), a = p(() => {
|
|
729
|
+
i((T) => !T);
|
|
730
|
+
}, []), c = p((T) => {
|
|
731
|
+
n(T);
|
|
732
|
+
}, []), l = p(() => {
|
|
717
733
|
n("captions");
|
|
718
|
-
}, []), u =
|
|
734
|
+
}, []), u = p(() => {
|
|
719
735
|
n("main");
|
|
720
|
-
}, []),
|
|
736
|
+
}, []), m = Z(() => In[e], [e]), h = ve(null), { refs: b, floatingStyles: w, context: y } = ge({
|
|
721
737
|
open: o,
|
|
722
|
-
onOpenChange: (
|
|
723
|
-
i(
|
|
738
|
+
onOpenChange: (T) => {
|
|
739
|
+
i(T), u();
|
|
724
740
|
},
|
|
725
741
|
placement: "top-end",
|
|
726
|
-
whileElementsMounted:
|
|
742
|
+
whileElementsMounted: ke,
|
|
727
743
|
middleware: [
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
element:
|
|
744
|
+
ye(),
|
|
745
|
+
we({
|
|
746
|
+
element: h
|
|
731
747
|
})
|
|
732
748
|
]
|
|
733
|
-
}),
|
|
749
|
+
}), C = Le(y, { escapeKey: !1 }), { getReferenceProps: f, getFloatingProps: k } = Pe([C]);
|
|
734
750
|
return {
|
|
735
|
-
Page:
|
|
751
|
+
Page: m,
|
|
736
752
|
open: o,
|
|
737
753
|
toggle: a,
|
|
738
754
|
setPage: c,
|
|
739
755
|
backToCaptions: l,
|
|
740
756
|
backToMain: u,
|
|
741
|
-
arrowRef:
|
|
757
|
+
arrowRef: h,
|
|
742
758
|
refs: b,
|
|
743
|
-
floatingStyles:
|
|
744
|
-
context:
|
|
745
|
-
getReferenceProps:
|
|
746
|
-
getFloatingProps:
|
|
759
|
+
floatingStyles: w,
|
|
760
|
+
context: y,
|
|
761
|
+
getReferenceProps: f,
|
|
762
|
+
getFloatingProps: k
|
|
747
763
|
};
|
|
748
764
|
}
|
|
749
|
-
const
|
|
765
|
+
const Hn = (e) => /* @__PURE__ */ t("svg", { width: 24, height: 24, viewBox: "0 0 24 24", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e, children: /* @__PURE__ */ t("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M21.0692 12C21.0692 11.4776 21.0212 10.944 20.9238 10.4104L23.5511 8.13318L21.0579 3.87247L17.7431 4.97788C16.9059 4.28329 15.9515 3.73553 14.9449 3.37271L14.2616 0H9.28941L8.60612 3.37129C7.58823 3.73553 6.65082 4.27482 5.80659 4.97647L2.49318 3.87247L0 8.13318L2.62729 10.4104C2.52988 10.944 2.48188 11.4776 2.48188 12C2.48188 12.5224 2.52988 13.056 2.62729 13.5896L0 15.8668L2.49318 20.1275L5.808 19.0221C6.64518 19.7167 7.59953 20.2645 8.60612 20.6273L9.28941 24H14.2616L14.9449 20.6287C15.9614 20.2645 16.9002 19.7252 17.7445 19.0235L21.0579 20.1289L23.5511 15.8682L20.9238 13.5911C21.0212 13.056 21.0692 12.5224 21.0692 12ZM11.7755 16.9412C9.05082 16.9412 6.83435 14.7247 6.83435 12C6.83435 9.2753 9.05082 7.05883 11.7755 7.05883C14.5002 7.05883 16.7167 9.2753 16.7167 12C16.7167 14.7247 14.5002 16.9412 11.7755 16.9412Z", fill: "currentColor" }) }), Vn = "_settings-menu_hxlsv_1", Bn = "_arrow_hxlsv_15", de = {
|
|
750
766
|
"settings-menu": "_settings-menu_hxlsv_1",
|
|
751
|
-
settingsMenu:
|
|
752
|
-
arrow:
|
|
767
|
+
settingsMenu: Vn,
|
|
768
|
+
arrow: Bn
|
|
753
769
|
};
|
|
754
|
-
function
|
|
770
|
+
function Rn() {
|
|
755
771
|
const {
|
|
756
772
|
Page: e,
|
|
757
773
|
arrowRef: n,
|
|
@@ -761,47 +777,47 @@ function Sn() {
|
|
|
761
777
|
floatingStyles: c,
|
|
762
778
|
getFloatingProps: l,
|
|
763
779
|
getReferenceProps: u,
|
|
764
|
-
open:
|
|
765
|
-
refs:
|
|
780
|
+
open: m,
|
|
781
|
+
refs: h,
|
|
766
782
|
setPage: b,
|
|
767
|
-
toggle:
|
|
768
|
-
} =
|
|
769
|
-
return /* @__PURE__ */ s(
|
|
783
|
+
toggle: w
|
|
784
|
+
} = Sn(), y = v(), { t: C } = g();
|
|
785
|
+
return /* @__PURE__ */ s(ee, { children: [
|
|
770
786
|
/* @__PURE__ */ t(
|
|
771
787
|
"button",
|
|
772
788
|
{
|
|
773
|
-
ref:
|
|
789
|
+
ref: h.setReference,
|
|
774
790
|
type: "button",
|
|
775
791
|
className: "controls-button",
|
|
776
|
-
"aria-label":
|
|
777
|
-
onClick:
|
|
778
|
-
"aria-expanded":
|
|
779
|
-
tabIndex:
|
|
792
|
+
"aria-label": C("SETTINGS"),
|
|
793
|
+
onClick: w,
|
|
794
|
+
"aria-expanded": m,
|
|
795
|
+
tabIndex: y != null && y.state.interactionsDisabled ? -1 : 0,
|
|
780
796
|
...u(),
|
|
781
|
-
children: /* @__PURE__ */ t(
|
|
797
|
+
children: /* @__PURE__ */ t(Hn, { className: "controls-button-icon icon-rotate" })
|
|
782
798
|
}
|
|
783
799
|
),
|
|
784
|
-
|
|
800
|
+
m && /* @__PURE__ */ t(it, { context: a, initialFocus: -1, modal: !1, children: /* @__PURE__ */ s(
|
|
785
801
|
"div",
|
|
786
802
|
{
|
|
787
|
-
className:
|
|
788
|
-
ref:
|
|
803
|
+
className: de.settingsMenu,
|
|
804
|
+
ref: h.setFloating,
|
|
789
805
|
style: c,
|
|
790
806
|
...l(),
|
|
791
807
|
children: [
|
|
792
808
|
/* @__PURE__ */ t(
|
|
793
|
-
|
|
809
|
+
N.Provider,
|
|
794
810
|
{
|
|
795
|
-
value: { setPage: b, backToMain: i, backToCaptions: o, toggle:
|
|
811
|
+
value: { setPage: b, backToMain: i, backToCaptions: o, toggle: w },
|
|
796
812
|
children: /* @__PURE__ */ t(e, {})
|
|
797
813
|
}
|
|
798
814
|
),
|
|
799
815
|
/* @__PURE__ */ t(
|
|
800
|
-
|
|
816
|
+
Ne,
|
|
801
817
|
{
|
|
802
818
|
ref: n,
|
|
803
819
|
context: a,
|
|
804
|
-
className:
|
|
820
|
+
className: de.arrow
|
|
805
821
|
}
|
|
806
822
|
)
|
|
807
823
|
]
|
|
@@ -809,129 +825,129 @@ function Sn() {
|
|
|
809
825
|
) })
|
|
810
826
|
] });
|
|
811
827
|
}
|
|
812
|
-
function
|
|
828
|
+
function He(e, n = 1e3) {
|
|
813
829
|
return function() {
|
|
814
|
-
const i =
|
|
815
|
-
return
|
|
830
|
+
const i = _("lastKeyboardAction"), [a, c] = M(!1), l = p(() => c(!1), []);
|
|
831
|
+
return E(() => {
|
|
816
832
|
c(!!i);
|
|
817
833
|
const u = setTimeout(l, n);
|
|
818
834
|
return () => clearTimeout(u);
|
|
819
835
|
}, [i, n]), a ? /* @__PURE__ */ t(e, {}) : null;
|
|
820
836
|
};
|
|
821
837
|
}
|
|
822
|
-
const
|
|
838
|
+
const oe = (e) => /* @__PURE__ */ t("svg", { width: 24, height: 24, viewBox: "0 0 24 24", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e, children: /* @__PURE__ */ t("path", { d: "M 11,21 H 5 V 3 h 6 z m 8,0 H 13 V 3 h 6 z", fill: "currentColor" }) }), ie = (e) => /* @__PURE__ */ t("svg", { width: 24, height: 24, viewBox: "0 0 24 24", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e, children: /* @__PURE__ */ t("path", { d: "M 5,2 V 22 L 21,12.000665 Z", fill: "currentColor" }) }), Ve = (e) => /* @__PURE__ */ t("svg", { width: 24, height: 24, viewBox: "0 0 24 24", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e, children: /* @__PURE__ */ t("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M14.1179 1.41211V22.589H11.2943L5.64717 16.9418V7.05928L11.2943 1.41211H14.1179ZM4.23537 7.05928V16.9418H2.11769C0.957618 16.9418 0.0189406 16.0147 0.00028305 14.8592L0 14.8241V9.17696C0 8.01689 0.927077 7.07822 2.0826 7.05956L2.11769 7.05928H4.23537ZM22.3744 7.93711L24 9.56119L21.5623 11.9988L24 14.4365L22.3744 16.0621L19.9383 13.6245L17.5006 16.0621L15.875 14.4365L18.3127 11.9988L15.875 9.56119L17.5006 7.93711L19.9383 10.3748L22.3744 7.93711Z", fill: "currentColor" }) }), Be = (e) => /* @__PURE__ */ t("svg", { width: 24, height: 24, viewBox: "0 0 24 24", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e, children: /* @__PURE__ */ t("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M5.64714 6.98017V16.8627L11.2943 22.5099H14.1179V1.33301H11.2943L5.64714 6.98017ZM0 9.09785V14.745C0 15.9168 0.945899 16.8627 2.11768 16.8627H4.23537V6.98017H2.11768C0.945899 6.98017 0 7.92607 0 9.09785ZM18.3527 11.9207C18.3527 10.6134 17.8388 9.36962 16.9056 8.4209L17.9094 7.43123C19.1066 8.64396 19.7645 10.2393 19.7645 11.9207C19.7645 13.6036 19.1066 15.1989 17.9094 16.4116L16.9056 15.422C17.8388 14.4732 18.3527 13.2295 18.3527 11.9207Z", fill: "currentColor" }) }), Re = (e) => /* @__PURE__ */ t("svg", { width: 24, height: 24, viewBox: "0 0 24 24", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e, children: /* @__PURE__ */ t("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M5.64714 16.8627V6.98017L11.2943 1.33301H14.1179V22.5099H11.2943L5.64714 16.8627ZM0 14.745V9.09785C0 7.92607 0.945899 6.98017 2.11768 6.98017H4.23537V16.8627H2.11768C0.945899 16.8627 0 15.9168 0 14.745ZM16.9056 8.4209C17.8388 9.36962 18.3527 10.6134 18.3527 11.9207C18.3527 13.2295 17.8388 14.4732 16.9056 15.422L17.9094 16.4116C19.1066 15.1989 19.7645 13.6036 19.7645 11.9207C19.7645 10.2393 19.1066 8.64396 17.9094 7.43123L16.9056 8.4209ZM19.9016 5.43185L20.8997 4.43372C22.9002 6.43422 24 9.09403 24 11.9219C24 14.7497 22.9002 17.4081 20.8997 19.4086L19.9016 18.4104C21.6353 16.6782 22.5882 14.3727 22.5882 11.9219C22.5882 9.46957 21.6353 7.16553 19.9016 5.43185Z", fill: "currentColor" }) }), En = (e) => /* @__PURE__ */ t("svg", { width: 24, height: 24, viewBox: "0 0 24 24", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e, children: /* @__PURE__ */ t("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M10.691 3.99987V10.5281L0 4.00655V20.2596L10.691 13.7367V20.2663L23.9987 12.1331L10.691 3.99987Z", fill: "currentColor" }) }), An = (e) => /* @__PURE__ */ t("svg", { width: 24, height: 24, viewBox: "0 0 24 24", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e, children: /* @__PURE__ */ t("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M13.309 3.99987L0 12.1331L13.309 20.2663V13.7367L23.9987 20.2596V4.00655L13.309 10.5281V3.99987Z", fill: "currentColor" }) }), On = "_feedback-overlay_v4lbu_1", Fn = "_feedback-message_v4lbu_14", Zn = "_feedback-icon_v4lbu_30", $n = "_feedback-icon-animation_v4lbu_1", L = {
|
|
823
839
|
"feedback-overlay": "_feedback-overlay_v4lbu_1",
|
|
824
|
-
feedbackOverlay:
|
|
840
|
+
feedbackOverlay: On,
|
|
825
841
|
"feedback-message": "_feedback-message_v4lbu_14",
|
|
826
|
-
feedbackMessage:
|
|
842
|
+
feedbackMessage: Fn,
|
|
827
843
|
"feedback-icon": "_feedback-icon_v4lbu_30",
|
|
828
|
-
feedbackIcon:
|
|
844
|
+
feedbackIcon: Zn,
|
|
829
845
|
"feedback-icon-animation": "_feedback-icon-animation_v4lbu_1",
|
|
830
|
-
feedbackIconAnimation:
|
|
846
|
+
feedbackIconAnimation: $n
|
|
831
847
|
};
|
|
832
|
-
function
|
|
848
|
+
function zn() {
|
|
833
849
|
var o;
|
|
834
|
-
const e =
|
|
850
|
+
const e = be();
|
|
835
851
|
switch ((o = e.lastKeyboardAction) == null ? void 0 : o.action) {
|
|
836
852
|
case "togglePaused":
|
|
837
|
-
return /* @__PURE__ */ t("i", { className:
|
|
853
|
+
return /* @__PURE__ */ t("i", { className: L.feedbackIcon, children: e.paused ? /* @__PURE__ */ t(oe, {}) : /* @__PURE__ */ t(ie, {}) });
|
|
838
854
|
case "toggleCaptions":
|
|
839
855
|
case "nextCaptionLanguage":
|
|
840
856
|
case "previousCaptionLanguage":
|
|
841
|
-
return e.hasCaptions ? /* @__PURE__ */ t("i", { className:
|
|
857
|
+
return e.hasCaptions ? /* @__PURE__ */ t("i", { className: L.feedbackIcon, children: /* @__PURE__ */ t(Ie, {}) }) : null;
|
|
842
858
|
case "volumeUp":
|
|
843
859
|
case "volumeDown":
|
|
844
860
|
case "toggleMuted":
|
|
845
|
-
return /* @__PURE__ */ t("i", { className:
|
|
861
|
+
return /* @__PURE__ */ t("i", { className: L.feedbackIcon, children: e.muted || e.volume === 0 ? /* @__PURE__ */ t(Ve, {}) : e.volume >= 0.5 ? /* @__PURE__ */ t(Re, {}) : /* @__PURE__ */ t(Be, {}) });
|
|
846
862
|
case "seekForward":
|
|
847
863
|
case "seekForward10":
|
|
848
|
-
return /* @__PURE__ */ t("i", { className:
|
|
864
|
+
return /* @__PURE__ */ t("i", { className: L.feedbackIcon, children: /* @__PURE__ */ t(En, { className: "right" }) });
|
|
849
865
|
case "seekBackward":
|
|
850
866
|
case "seekBackward10":
|
|
851
|
-
return /* @__PURE__ */ t("i", { className:
|
|
867
|
+
return /* @__PURE__ */ t("i", { className: L.feedbackIcon, children: /* @__PURE__ */ t(An, { className: "left" }) });
|
|
852
868
|
default:
|
|
853
869
|
return null;
|
|
854
870
|
}
|
|
855
871
|
}
|
|
856
|
-
function
|
|
872
|
+
function Kn() {
|
|
857
873
|
var i;
|
|
858
|
-
const { t: e } =
|
|
874
|
+
const { t: e } = g(), n = be();
|
|
859
875
|
switch ((i = n.lastKeyboardAction) == null ? void 0 : i.action) {
|
|
860
876
|
case "toggleCaptions":
|
|
861
877
|
case "nextCaptionLanguage":
|
|
862
878
|
case "previousCaptionLanguage":
|
|
863
|
-
return /* @__PURE__ */ t("div", { className:
|
|
879
|
+
return /* @__PURE__ */ t("div", { className: L.feedbackMessage, children: n.textTrack ? e("CAPTION_LANGUAGE", { language: n.textTrack.label }) : `${e("CAPTIONS")}: ${e("OFF")}` });
|
|
864
880
|
case "volumeUp":
|
|
865
881
|
case "volumeDown":
|
|
866
882
|
case "toggleMuted":
|
|
867
|
-
return /* @__PURE__ */ t("div", { className:
|
|
883
|
+
return /* @__PURE__ */ t("div", { className: L.feedbackMessage, children: n.muted || n.volume === 0 ? e("MUTED") : e("VOLUME", { volume: (n.volume * 100).toFixed(0) }) });
|
|
868
884
|
case "increasePlaybackRate":
|
|
869
885
|
case "decreasePlaybackRate":
|
|
870
886
|
case "resetPlaybackRate":
|
|
871
|
-
return /* @__PURE__ */ t("div", { className:
|
|
887
|
+
return /* @__PURE__ */ t("div", { className: L.feedbackMessage, children: e("PLAYBACK_SPEED_MESSAGE", { speed: n.playbackRate }) });
|
|
872
888
|
case "seekForward":
|
|
873
|
-
return /* @__PURE__ */ t("div", { className:
|
|
889
|
+
return /* @__PURE__ */ t("div", { className: L.feedbackMessage, children: e("SEEK_FORWARD", { seconds: 5 }) });
|
|
874
890
|
case "seekForward10":
|
|
875
|
-
return /* @__PURE__ */ t("div", { className:
|
|
891
|
+
return /* @__PURE__ */ t("div", { className: L.feedbackMessage, children: e("SEEK_FORWARD", { seconds: 10 }) });
|
|
876
892
|
case "seekBackward":
|
|
877
|
-
return /* @__PURE__ */ t("div", { className:
|
|
893
|
+
return /* @__PURE__ */ t("div", { className: L.feedbackMessage, children: e("SEEK_BACKWARD", { seconds: 5 }) });
|
|
878
894
|
case "seekBackward10":
|
|
879
|
-
return /* @__PURE__ */ t("div", { className:
|
|
895
|
+
return /* @__PURE__ */ t("div", { className: L.feedbackMessage, children: e("SEEK_BACKWARD", { seconds: 10 }) });
|
|
880
896
|
default:
|
|
881
897
|
return null;
|
|
882
898
|
}
|
|
883
899
|
}
|
|
884
|
-
const
|
|
885
|
-
function
|
|
886
|
-
return /* @__PURE__ */ s("div", { className:
|
|
887
|
-
/* @__PURE__ */ t(
|
|
888
|
-
/* @__PURE__ */ t(
|
|
900
|
+
const Dn = He(zn, 500), jn = He(Kn, 1e3);
|
|
901
|
+
function Un() {
|
|
902
|
+
return /* @__PURE__ */ s("div", { className: L.feedbackOverlay, children: [
|
|
903
|
+
/* @__PURE__ */ t(Dn, {}),
|
|
904
|
+
/* @__PURE__ */ t(jn, {})
|
|
889
905
|
] });
|
|
890
906
|
}
|
|
891
|
-
const
|
|
907
|
+
const qn = (e) => /* @__PURE__ */ t("svg", { width: 24, height: 24, viewBox: "0 0 24 24", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e, children: /* @__PURE__ */ t("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M14.1383 0.999867V3.66268H18.4561L3.66281 18.4546V14.1382H1V23H9.86449V20.3372H5.54542L20.3387 5.54528V9.86303H23.0001V0.999867H14.1383Z", fill: "currentColor" }) }), Wn = (e) => /* @__PURE__ */ t("svg", { width: 24, height: 24, viewBox: "0 0 24 24", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e, children: /* @__PURE__ */ t("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M15.562 6.58944L22.1514 0L24.0005 1.84907L17.4111 8.43851H21.6506V11.0552H12.9453V2.34861H15.562V6.58944ZM2.34861 15.5615V12.9461H11.0539V21.6501H8.43982V17.4106L1.84907 24L0 22.1509L6.59075 15.5615H2.34861Z", fill: "currentColor" }) }), Gn = "_full-screen-button_1xm32_2", Qn = {
|
|
892
908
|
"full-screen-button": "_full-screen-button_1xm32_2",
|
|
893
|
-
fullScreenButton:
|
|
909
|
+
fullScreenButton: Gn
|
|
894
910
|
};
|
|
895
|
-
function
|
|
896
|
-
const e =
|
|
897
|
-
return
|
|
898
|
-
|
|
911
|
+
function Yn() {
|
|
912
|
+
const e = _("fullscreen"), n = v();
|
|
913
|
+
return S().hideFullScreen ? null : /* @__PURE__ */ t(
|
|
914
|
+
Ce,
|
|
899
915
|
{
|
|
900
916
|
tabIndex: n.state.interactionsDisabled ? -1 : 0,
|
|
901
|
-
className: `controls-button ${
|
|
902
|
-
children: e ? /* @__PURE__ */ t(
|
|
917
|
+
className: `controls-button ${Qn.fullScreenButton}`,
|
|
918
|
+
children: e ? /* @__PURE__ */ t(Wn, { className: "controls-button-icon" }) : /* @__PURE__ */ t(qn, { className: "controls-button-icon" })
|
|
903
919
|
}
|
|
904
920
|
);
|
|
905
921
|
}
|
|
906
|
-
const
|
|
922
|
+
const Jn = "_gestures-container_1fn3b_1", Xn = "_gesture_1fn3b_1", me = {
|
|
907
923
|
"gestures-container": "_gestures-container_1fn3b_1",
|
|
908
|
-
gesturesContainer:
|
|
909
|
-
gesture:
|
|
924
|
+
gesturesContainer: Jn,
|
|
925
|
+
gesture: Xn
|
|
910
926
|
};
|
|
911
|
-
function
|
|
927
|
+
function eo() {
|
|
912
928
|
const e = W(), n = () => {
|
|
913
929
|
e.togglePaused();
|
|
914
930
|
};
|
|
915
|
-
return /* @__PURE__ */ t("div", { className:
|
|
931
|
+
return /* @__PURE__ */ t("div", { className: me.gesturesContainer, children: /* @__PURE__ */ t("div", { "aria-hidden": !0, className: me.gesture, onClick: n }) });
|
|
916
932
|
}
|
|
917
|
-
const
|
|
933
|
+
const to = (e) => /* @__PURE__ */ t("svg", { width: 18, height: 18, viewBox: "0 0 18 18", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e, children: /* @__PURE__ */ t("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M4.76472 10.5294C5.05696 10.5294 5.29413 10.2922 5.29413 9.99999V8.94117C5.29413 8.64893 5.05696 8.41175 4.76472 8.41175H3.7059C3.41366 8.41175 3.17649 8.64893 3.17649 8.94117V9.99999C3.17649 10.2922 3.41366 10.5294 3.7059 10.5294H4.76472ZM11.1177 10.5294C11.4099 10.5294 11.6471 10.2922 11.6471 9.99999V8.94117C11.6471 8.64893 11.4099 8.41175 11.1177 8.41175H10.0588C9.76661 8.41175 9.52944 8.64893 9.52944 8.94117V9.99999C9.52944 10.2922 9.76661 10.5294 10.0588 10.5294H11.1177ZM14.8235 9.99999C14.8235 10.2922 14.5864 10.5294 14.2941 10.5294H13.2353C12.9431 10.5294 12.7059 10.2922 12.7059 9.99999V8.94117C12.7059 8.64893 12.9431 8.41175 13.2353 8.41175H14.2941C14.5864 8.41175 14.8235 8.64893 14.8235 8.94117V9.99999ZM14.8235 13.1765C14.8235 13.4687 14.5864 13.7059 14.2941 13.7059H13.2353C12.9431 13.7059 12.7059 13.4687 12.7059 13.1765V12.1176C12.7059 11.8254 12.9431 11.5882 13.2353 11.5882H14.2941C14.5864 11.5882 14.8235 11.8254 14.8235 12.1176V13.1765ZM11.6471 13.1765C11.6471 13.4687 11.4099 13.7059 11.1177 13.7059H6.88239C6.59015 13.7059 6.35297 13.4687 6.35297 13.1765V12.1176C6.35297 11.8254 6.59015 11.5882 6.88239 11.5882H11.1177C11.4099 11.5882 11.6471 11.8254 11.6471 12.1176V13.1765ZM5.29413 13.1765C5.29413 13.4687 5.05696 13.7059 4.76472 13.7059H3.7059C3.41366 13.7059 3.17649 13.4687 3.17649 13.1765V12.1176C3.17649 11.8254 3.41366 11.5882 3.7059 11.5882H4.76472C5.05696 11.5882 5.29413 11.8254 5.29413 12.1176V13.1765ZM6.88238 8.41175C6.59015 8.41175 6.35297 8.64893 6.35297 8.94117V9.99999C6.35297 10.2922 6.59015 10.5294 6.88238 10.5294H7.94121C8.23344 10.5294 8.47062 10.2922 8.47062 9.99999V8.94117C8.47062 8.64893 8.23344 8.41175 7.94121 8.41175H6.88238ZM16.4118 5.23529H9.57494C9.71471 4.42 10.1933 4.17118 10.8254 3.85565C11.6629 3.43741 12.7059 2.91541 12.7059 1H11.6471C11.6471 2.26106 11.1039 2.53212 10.3511 2.90906C9.59824 3.28494 8.68659 3.75506 8.50871 5.23529H1.58824C0.712588 5.23529 0 5.94788 0 6.82353V15.2941C0 16.1698 0.712588 16.8824 1.58824 16.8824H16.4118C17.2874 16.8824 18 16.1698 18 15.2941V6.82353C18 5.94788 17.2874 5.23529 16.4118 5.23529Z", fill: "currentColor" }) }), Ee = (e) => /* @__PURE__ */ t("svg", { width: 18, height: 18, viewBox: "0 0 18 18", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e, children: /* @__PURE__ */ t("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M8.94968 7.74766L3.99993 2.79791L2.79785 3.99999L7.7476 8.94974L2.79785 13.8995L3.99993 15.1016L8.94968 10.1518L13.8994 15.1016L15.1015 13.8995L10.1518 8.94974L15.1015 3.99999L13.8994 2.79791L8.94968 7.74766Z", fill: "currentColor" }) }), no = "_keyboard-shortcuts-overlay_y5kv6_1", oo = "_keyboard-shortcuts-button_y5kv6_67", io = "_close-button_y5kv6_93", X = {
|
|
918
934
|
"keyboard-shortcuts-overlay": "_keyboard-shortcuts-overlay_y5kv6_1",
|
|
919
|
-
keyboardShortcutsOverlay:
|
|
935
|
+
keyboardShortcutsOverlay: no,
|
|
920
936
|
"keyboard-shortcuts-button": "_keyboard-shortcuts-button_y5kv6_67",
|
|
921
|
-
keyboardShortcutsButton:
|
|
937
|
+
keyboardShortcutsButton: oo,
|
|
922
938
|
"close-button": "_close-button_y5kv6_93",
|
|
923
|
-
closeButton:
|
|
939
|
+
closeButton: io
|
|
924
940
|
};
|
|
925
|
-
function
|
|
926
|
-
const { t: n } =
|
|
927
|
-
|
|
941
|
+
function ao({ onClose: e }) {
|
|
942
|
+
const { t: n } = g();
|
|
943
|
+
H(e);
|
|
928
944
|
const o = (i) => {
|
|
929
945
|
i && i.focus();
|
|
930
946
|
};
|
|
931
947
|
return /* @__PURE__ */ s(
|
|
932
948
|
"div",
|
|
933
949
|
{
|
|
934
|
-
className:
|
|
950
|
+
className: X.keyboardShortcutsOverlay,
|
|
935
951
|
tabIndex: 0,
|
|
936
952
|
ref: o,
|
|
937
953
|
children: [
|
|
@@ -941,10 +957,10 @@ function to({ onClose: e }) {
|
|
|
941
957
|
"button",
|
|
942
958
|
{
|
|
943
959
|
type: "button",
|
|
944
|
-
className:
|
|
960
|
+
className: X.closeButton,
|
|
945
961
|
onClick: e,
|
|
946
962
|
"aria-label": n("CLOSE"),
|
|
947
|
-
children: /* @__PURE__ */ t(
|
|
963
|
+
children: /* @__PURE__ */ t(Ee, {})
|
|
948
964
|
}
|
|
949
965
|
)
|
|
950
966
|
] }),
|
|
@@ -1035,156 +1051,156 @@ function to({ onClose: e }) {
|
|
|
1035
1051
|
}
|
|
1036
1052
|
);
|
|
1037
1053
|
}
|
|
1038
|
-
function
|
|
1039
|
-
const [e, n] =
|
|
1040
|
-
n(!0), l.disableInteractions(), u && (c(!0),
|
|
1041
|
-
}, [u,
|
|
1042
|
-
n(!1), i(!0), l.enableInteractions(), a && (c(!1),
|
|
1043
|
-
}, [a,
|
|
1044
|
-
(
|
|
1054
|
+
function so() {
|
|
1055
|
+
const [e, n] = M(!1), [o, i] = M(!1), [a, c] = M(!1), l = v(), u = _("playing"), m = W(), { t: h } = g(), b = p(() => {
|
|
1056
|
+
n(!0), l.disableInteractions(), u && (c(!0), m.pause());
|
|
1057
|
+
}, [u, m, l]), w = p(() => {
|
|
1058
|
+
n(!1), i(!0), l.enableInteractions(), a && (c(!1), m.play());
|
|
1059
|
+
}, [a, m, l]), y = p(
|
|
1060
|
+
(C) => o && (C == null ? void 0 : C.focus()),
|
|
1045
1061
|
[o]
|
|
1046
1062
|
);
|
|
1047
|
-
return e ? /* @__PURE__ */ t(
|
|
1063
|
+
return e ? /* @__PURE__ */ t(ao, { onClose: w }) : /* @__PURE__ */ t(
|
|
1048
1064
|
"button",
|
|
1049
1065
|
{
|
|
1050
|
-
ref:
|
|
1051
|
-
"aria-label":
|
|
1066
|
+
ref: y,
|
|
1067
|
+
"aria-label": h("KEYBOARD_SHORTCUTS"),
|
|
1052
1068
|
type: "button",
|
|
1053
|
-
className:
|
|
1069
|
+
className: X.keyboardShortcutsButton,
|
|
1054
1070
|
onClick: b,
|
|
1055
1071
|
tabIndex: l.state.interactionsDisabled ? -1 : 0,
|
|
1056
|
-
children: /* @__PURE__ */ t(
|
|
1072
|
+
children: /* @__PURE__ */ t(to, {})
|
|
1057
1073
|
}
|
|
1058
1074
|
);
|
|
1059
1075
|
}
|
|
1060
|
-
const
|
|
1076
|
+
const co = "_play-pause-button_kyuc5_1", lo = {
|
|
1061
1077
|
"play-pause-button": "_play-pause-button_kyuc5_1",
|
|
1062
|
-
playPauseButton:
|
|
1078
|
+
playPauseButton: co
|
|
1063
1079
|
};
|
|
1064
|
-
function
|
|
1065
|
-
const e = q(), n =
|
|
1080
|
+
function ro() {
|
|
1081
|
+
const e = q(), n = v(), o = _("paused");
|
|
1066
1082
|
return e ? /* @__PURE__ */ t(
|
|
1067
|
-
|
|
1083
|
+
Qe,
|
|
1068
1084
|
{
|
|
1069
1085
|
tabIndex: n.state.interactionsDisabled ? -1 : 0,
|
|
1070
|
-
className: `${
|
|
1086
|
+
className: `${lo.playPauseButton} controls-button`,
|
|
1071
1087
|
onKeyDown: (i) => {
|
|
1072
1088
|
i.key === " " && (e == null || e.$state.lastKeyboardAction.set({
|
|
1073
1089
|
action: "togglePaused",
|
|
1074
1090
|
event: i.nativeEvent
|
|
1075
1091
|
}));
|
|
1076
1092
|
},
|
|
1077
|
-
children: o ? /* @__PURE__ */ t(
|
|
1093
|
+
children: o ? /* @__PURE__ */ t(ie, { className: "controls-button-icon" }) : /* @__PURE__ */ t(oe, { className: "controls-button-icon" })
|
|
1078
1094
|
}
|
|
1079
1095
|
) : null;
|
|
1080
1096
|
}
|
|
1081
|
-
const
|
|
1082
|
-
poster:
|
|
1097
|
+
const uo = "_poster_195hi_1", mo = {
|
|
1098
|
+
poster: uo
|
|
1083
1099
|
};
|
|
1084
|
-
function
|
|
1085
|
-
const n =
|
|
1086
|
-
return n.type === "video/youtube" || n.type === "video/vimeo" ? null : /* @__PURE__ */ t(
|
|
1100
|
+
function ho({ src: e }) {
|
|
1101
|
+
const n = _("source");
|
|
1102
|
+
return n.type === "video/youtube" || n.type === "video/vimeo" ? null : /* @__PURE__ */ t(Ye, { src: e, className: mo.poster });
|
|
1087
1103
|
}
|
|
1088
|
-
const
|
|
1104
|
+
const po = "_small-layout-overlay_1vli4_1", _o = "_small-layout-button_1vli4_14", fo = "_small-layout-icon-play_1vli4_24", vo = "_small-layout-icon-pause_1vli4_30", bo = "_full-screen-close-icon_1vli4_36", Co = "_fade-out_1vli4_1", O = {
|
|
1089
1105
|
"small-layout-overlay": "_small-layout-overlay_1vli4_1",
|
|
1090
|
-
smallLayoutOverlay:
|
|
1106
|
+
smallLayoutOverlay: po,
|
|
1091
1107
|
"small-layout-button": "_small-layout-button_1vli4_14",
|
|
1092
|
-
smallLayoutButton:
|
|
1108
|
+
smallLayoutButton: _o,
|
|
1093
1109
|
"small-layout-icon-play": "_small-layout-icon-play_1vli4_24",
|
|
1094
|
-
smallLayoutIconPlay:
|
|
1110
|
+
smallLayoutIconPlay: fo,
|
|
1095
1111
|
"small-layout-icon-pause": "_small-layout-icon-pause_1vli4_30",
|
|
1096
|
-
smallLayoutIconPause:
|
|
1112
|
+
smallLayoutIconPause: vo,
|
|
1097
1113
|
"full-screen-close-icon": "_full-screen-close-icon_1vli4_36",
|
|
1098
|
-
fullScreenCloseIcon:
|
|
1114
|
+
fullScreenCloseIcon: bo,
|
|
1099
1115
|
"fade-out": "_fade-out_1vli4_1",
|
|
1100
|
-
fadeOut:
|
|
1116
|
+
fadeOut: Co
|
|
1101
1117
|
};
|
|
1102
|
-
function
|
|
1118
|
+
function go() {
|
|
1103
1119
|
return /* @__PURE__ */ s("div", { className: O.smallLayoutOverlay, children: [
|
|
1104
|
-
/* @__PURE__ */ t(
|
|
1120
|
+
/* @__PURE__ */ t(Ce, { className: O.fullScreenCloseIcon, children: /* @__PURE__ */ t(Ee, {}) }),
|
|
1105
1121
|
/* @__PURE__ */ s("i", { className: O.smallLayoutButton, children: [
|
|
1106
|
-
/* @__PURE__ */ t(
|
|
1107
|
-
/* @__PURE__ */ t(
|
|
1122
|
+
/* @__PURE__ */ t(ie, { className: O.smallLayoutIconPlay }),
|
|
1123
|
+
/* @__PURE__ */ t(oe, { className: O.smallLayoutIconPause })
|
|
1108
1124
|
] })
|
|
1109
1125
|
] });
|
|
1110
1126
|
}
|
|
1111
|
-
const
|
|
1127
|
+
const ko = "_time-indicator_1rlpb_1", yo = {
|
|
1112
1128
|
"time-indicator": "_time-indicator_1rlpb_1",
|
|
1113
|
-
timeIndicator:
|
|
1129
|
+
timeIndicator: ko
|
|
1114
1130
|
};
|
|
1115
|
-
function
|
|
1116
|
-
return /* @__PURE__ */ s("div", { className:
|
|
1117
|
-
/* @__PURE__ */ t(
|
|
1131
|
+
function wo() {
|
|
1132
|
+
return /* @__PURE__ */ s("div", { className: yo.timeIndicator, children: [
|
|
1133
|
+
/* @__PURE__ */ t(re, { type: "current" }),
|
|
1118
1134
|
"/",
|
|
1119
|
-
/* @__PURE__ */ t(
|
|
1135
|
+
/* @__PURE__ */ t(re, { type: "duration" })
|
|
1120
1136
|
] });
|
|
1121
1137
|
}
|
|
1122
|
-
const
|
|
1138
|
+
const Lo = "_comment-markers_19b45_1", Po = "_comment-marker_19b45_1", No = "_timeline-wrapper_19b45_21", xo = "_track_19b45_35", Mo = "_thumb_19b45_48", To = "_root_19b45_62", Io = "_track-inner_19b45_92", So = "_progress_19b45_98", Ho = "_track-fill_19b45_104", Vo = "_pins_19b45_121", Bo = "_pin-button_19b45_134", Ro = "_annotation-pin_19b45_154", Eo = "_quiz-pin_19b45_159", Ao = "_annotation-pin-child_19b45_164", Oo = "_quiz-pin-child_19b45_168", Fo = "_interactive-pin-container_19b45_173", Zo = "_interactive-pin-wrapper_19b45_183", $o = "_interactive-pin-icon_19b45_189", zo = "_interactive-pin_19b45_173", Ko = "_bg_19b45_203", Do = "_symbol_19b45_207", jo = "_interactive-pin-button_19b45_212", Uo = "_interactive-pin-menu_19b45_232", qo = "_interactive-pin-menu-item_19b45_246", Wo = "_arrow_19b45_267", d = {
|
|
1123
1139
|
"comment-markers": "_comment-markers_19b45_1",
|
|
1124
|
-
commentMarkers:
|
|
1140
|
+
commentMarkers: Lo,
|
|
1125
1141
|
"comment-marker": "_comment-marker_19b45_1",
|
|
1126
|
-
commentMarker:
|
|
1142
|
+
commentMarker: Po,
|
|
1127
1143
|
"timeline-wrapper": "_timeline-wrapper_19b45_21",
|
|
1128
|
-
timelineWrapper:
|
|
1129
|
-
track:
|
|
1130
|
-
thumb:
|
|
1131
|
-
root:
|
|
1144
|
+
timelineWrapper: No,
|
|
1145
|
+
track: xo,
|
|
1146
|
+
thumb: Mo,
|
|
1147
|
+
root: To,
|
|
1132
1148
|
"track-inner": "_track-inner_19b45_92",
|
|
1133
|
-
trackInner:
|
|
1134
|
-
progress:
|
|
1149
|
+
trackInner: Io,
|
|
1150
|
+
progress: So,
|
|
1135
1151
|
"track-fill": "_track-fill_19b45_104",
|
|
1136
|
-
trackFill:
|
|
1137
|
-
pins:
|
|
1152
|
+
trackFill: Ho,
|
|
1153
|
+
pins: Vo,
|
|
1138
1154
|
"pin-button": "_pin-button_19b45_134",
|
|
1139
|
-
pinButton:
|
|
1155
|
+
pinButton: Bo,
|
|
1140
1156
|
"annotation-pin": "_annotation-pin_19b45_154",
|
|
1141
|
-
annotationPin:
|
|
1157
|
+
annotationPin: Ro,
|
|
1142
1158
|
"quiz-pin": "_quiz-pin_19b45_159",
|
|
1143
|
-
quizPin:
|
|
1159
|
+
quizPin: Eo,
|
|
1144
1160
|
"annotation-pin-child": "_annotation-pin-child_19b45_164",
|
|
1145
|
-
annotationPinChild:
|
|
1161
|
+
annotationPinChild: Ao,
|
|
1146
1162
|
"quiz-pin-child": "_quiz-pin-child_19b45_168",
|
|
1147
|
-
quizPinChild:
|
|
1163
|
+
quizPinChild: Oo,
|
|
1148
1164
|
"interactive-pin-container": "_interactive-pin-container_19b45_173",
|
|
1149
|
-
interactivePinContainer:
|
|
1165
|
+
interactivePinContainer: Fo,
|
|
1150
1166
|
"interactive-pin-wrapper": "_interactive-pin-wrapper_19b45_183",
|
|
1151
|
-
interactivePinWrapper:
|
|
1167
|
+
interactivePinWrapper: Zo,
|
|
1152
1168
|
"interactive-pin-icon": "_interactive-pin-icon_19b45_189",
|
|
1153
|
-
interactivePinIcon:
|
|
1169
|
+
interactivePinIcon: $o,
|
|
1154
1170
|
"interactive-pin": "_interactive-pin_19b45_173",
|
|
1155
|
-
interactivePin:
|
|
1156
|
-
bg:
|
|
1157
|
-
symbol:
|
|
1171
|
+
interactivePin: zo,
|
|
1172
|
+
bg: Ko,
|
|
1173
|
+
symbol: Do,
|
|
1158
1174
|
"interactive-pin-button": "_interactive-pin-button_19b45_212",
|
|
1159
|
-
interactivePinButton:
|
|
1175
|
+
interactivePinButton: jo,
|
|
1160
1176
|
"interactive-pin-menu": "_interactive-pin-menu_19b45_232",
|
|
1161
|
-
interactivePinMenu:
|
|
1177
|
+
interactivePinMenu: Uo,
|
|
1162
1178
|
"interactive-pin-menu-item": "_interactive-pin-menu-item_19b45_246",
|
|
1163
|
-
interactivePinMenuItem:
|
|
1164
|
-
arrow:
|
|
1165
|
-
},
|
|
1166
|
-
annotation:
|
|
1167
|
-
quiz:
|
|
1179
|
+
interactivePinMenuItem: qo,
|
|
1180
|
+
arrow: Wo
|
|
1181
|
+
}, Go = {
|
|
1182
|
+
annotation: d.annotationPin,
|
|
1183
|
+
quiz: d.quizPin
|
|
1168
1184
|
};
|
|
1169
|
-
function
|
|
1185
|
+
function Ae({
|
|
1170
1186
|
type: e,
|
|
1171
1187
|
position: n,
|
|
1172
1188
|
children: o,
|
|
1173
1189
|
onClick: i
|
|
1174
1190
|
}) {
|
|
1175
|
-
const a =
|
|
1191
|
+
const a = v();
|
|
1176
1192
|
return /* @__PURE__ */ t(
|
|
1177
1193
|
"button",
|
|
1178
1194
|
{
|
|
1179
1195
|
type: "button",
|
|
1180
1196
|
tabIndex: a.state.interactionsDisabled ? -1 : 0,
|
|
1181
|
-
className:
|
|
1197
|
+
className: d.pinButton,
|
|
1182
1198
|
style: { left: `${n}%` },
|
|
1183
1199
|
onClick: i,
|
|
1184
1200
|
children: /* @__PURE__ */ s(
|
|
1185
1201
|
"svg",
|
|
1186
1202
|
{
|
|
1187
|
-
className:
|
|
1203
|
+
className: Go[e],
|
|
1188
1204
|
width: "26",
|
|
1189
1205
|
height: "32",
|
|
1190
1206
|
viewBox: "0 0 26 32",
|
|
@@ -1198,11 +1214,11 @@ function Be({
|
|
|
1198
1214
|
}
|
|
1199
1215
|
);
|
|
1200
1216
|
}
|
|
1201
|
-
function
|
|
1202
|
-
return /* @__PURE__ */ t(
|
|
1217
|
+
function Qo(e) {
|
|
1218
|
+
return /* @__PURE__ */ t(Ae, { type: "annotation", ...e, children: /* @__PURE__ */ t(
|
|
1203
1219
|
"path",
|
|
1204
1220
|
{
|
|
1205
|
-
className:
|
|
1221
|
+
className: d.annotationPinChild,
|
|
1206
1222
|
fillRule: "evenodd",
|
|
1207
1223
|
clipRule: "evenodd",
|
|
1208
1224
|
d: "M7 8V19.25H8.875V18.875C8.875 17.8415 9.7165 17 10.75 17H19V8H7ZM10 11.75H16V11H10V11.75ZM14.5 14H10V13.25H14.5V14Z",
|
|
@@ -1211,11 +1227,11 @@ function Uo(e) {
|
|
|
1211
1227
|
}
|
|
1212
1228
|
) });
|
|
1213
1229
|
}
|
|
1214
|
-
function
|
|
1215
|
-
return /* @__PURE__ */ t(
|
|
1230
|
+
function Yo(e) {
|
|
1231
|
+
return /* @__PURE__ */ t(Ae, { type: "quiz", ...e, children: e.multiple ? /* @__PURE__ */ t("circle", { className: d.quizPinChild, cx: "13", cy: "13", r: "6" }) : /* @__PURE__ */ t(
|
|
1216
1232
|
"text",
|
|
1217
1233
|
{
|
|
1218
|
-
className:
|
|
1234
|
+
className: d.quizPinChild,
|
|
1219
1235
|
x: "50%",
|
|
1220
1236
|
y: "56%",
|
|
1221
1237
|
textAnchor: "middle",
|
|
@@ -1225,7 +1241,7 @@ function qo(e) {
|
|
|
1225
1241
|
}
|
|
1226
1242
|
) });
|
|
1227
1243
|
}
|
|
1228
|
-
function
|
|
1244
|
+
function Jo(e, n) {
|
|
1229
1245
|
return e.map((o, i) => ({
|
|
1230
1246
|
id: o.id,
|
|
1231
1247
|
time: o.time,
|
|
@@ -1234,7 +1250,7 @@ function Wo(e, n) {
|
|
|
1234
1250
|
onClick: () => n(o)
|
|
1235
1251
|
}));
|
|
1236
1252
|
}
|
|
1237
|
-
function
|
|
1253
|
+
function Xo(e, n) {
|
|
1238
1254
|
const o = /* @__PURE__ */ new Map();
|
|
1239
1255
|
e.forEach((c) => {
|
|
1240
1256
|
var u;
|
|
@@ -1254,12 +1270,12 @@ function Go(e, n) {
|
|
|
1254
1270
|
}), a++;
|
|
1255
1271
|
}), i;
|
|
1256
1272
|
}
|
|
1257
|
-
function
|
|
1273
|
+
function ei(e, n, o, i) {
|
|
1258
1274
|
switch (e.type) {
|
|
1259
1275
|
case "annotation": {
|
|
1260
1276
|
const a = () => i ? e.onClick() : o.seek(e.time);
|
|
1261
1277
|
return /* @__PURE__ */ t(
|
|
1262
|
-
|
|
1278
|
+
Qo,
|
|
1263
1279
|
{
|
|
1264
1280
|
position: e.time / n * 100,
|
|
1265
1281
|
onClick: a
|
|
@@ -1269,7 +1285,7 @@ function Qo(e, n, o, i) {
|
|
|
1269
1285
|
}
|
|
1270
1286
|
case "quiz":
|
|
1271
1287
|
return /* @__PURE__ */ t(
|
|
1272
|
-
|
|
1288
|
+
Yo,
|
|
1273
1289
|
{
|
|
1274
1290
|
position: e.time / n * 100,
|
|
1275
1291
|
ordinal: e.ordinal,
|
|
@@ -1282,63 +1298,63 @@ function Qo(e, n, o, i) {
|
|
|
1282
1298
|
return null;
|
|
1283
1299
|
}
|
|
1284
1300
|
}
|
|
1285
|
-
function
|
|
1286
|
-
const e = W(), n =
|
|
1287
|
-
...
|
|
1301
|
+
function ti() {
|
|
1302
|
+
const e = W(), n = _("duration"), o = S(), i = Z(() => [
|
|
1303
|
+
...Jo(
|
|
1288
1304
|
o.annotations,
|
|
1289
1305
|
o.onAnnotationClick
|
|
1290
1306
|
),
|
|
1291
|
-
...
|
|
1292
|
-
].sort((c, l) => c.time - l.time).map((c) =>
|
|
1293
|
-
return /* @__PURE__ */ t("div", { className:
|
|
1307
|
+
...Xo(o.quizMarkers, o.onQuizMarkerClick)
|
|
1308
|
+
].sort((c, l) => c.time - l.time).map((c) => ei(c, n, e, o.interactive)), [o.annotations, o.quizMarkers, n, e]);
|
|
1309
|
+
return /* @__PURE__ */ t("div", { className: d.pins, children: i });
|
|
1294
1310
|
}
|
|
1295
|
-
function
|
|
1296
|
-
const e =
|
|
1297
|
-
return n.hasComments && o.state.commentsEnabled ? /* @__PURE__ */ t("div", { className:
|
|
1311
|
+
function ni() {
|
|
1312
|
+
const e = _("duration"), n = S(), o = v();
|
|
1313
|
+
return n.hasComments && o.state.commentsEnabled ? /* @__PURE__ */ t("div", { className: d.commentMarkers, children: n.comments.map((i) => /* @__PURE__ */ t(
|
|
1298
1314
|
"span",
|
|
1299
1315
|
{
|
|
1300
|
-
className:
|
|
1316
|
+
className: d.commentMarker,
|
|
1301
1317
|
style: {
|
|
1302
1318
|
left: `${i.timestamp / e * 100}%`,
|
|
1303
|
-
width: `${
|
|
1319
|
+
width: `${Se / e * 100}%`
|
|
1304
1320
|
}
|
|
1305
1321
|
},
|
|
1306
1322
|
i.id
|
|
1307
1323
|
)) }) : null;
|
|
1308
1324
|
}
|
|
1309
|
-
function
|
|
1310
|
-
const [o, i] =
|
|
1325
|
+
function oi({ currentTime: e, position: n }) {
|
|
1326
|
+
const [o, i] = M(!1), a = S(), c = p(() => a.interactiveMenuElements.length > 0 ? i((C) => !C) : a.onInteractivePinClick(e), [
|
|
1311
1327
|
a.interactiveMenuElements,
|
|
1312
1328
|
a.onInteractivePinClick,
|
|
1313
1329
|
e
|
|
1314
|
-
]), l =
|
|
1330
|
+
]), l = ve(null), { refs: u, floatingStyles: m, context: h } = ge({
|
|
1315
1331
|
open: o,
|
|
1316
1332
|
onOpenChange: i,
|
|
1317
|
-
whileElementsMounted:
|
|
1333
|
+
whileElementsMounted: ke,
|
|
1318
1334
|
placement: "top",
|
|
1319
1335
|
middleware: [
|
|
1320
|
-
|
|
1321
|
-
|
|
1322
|
-
|
|
1323
|
-
|
|
1336
|
+
at(),
|
|
1337
|
+
st(6),
|
|
1338
|
+
ye(),
|
|
1339
|
+
we({
|
|
1324
1340
|
element: l
|
|
1325
1341
|
})
|
|
1326
1342
|
]
|
|
1327
|
-
}), b =
|
|
1328
|
-
return /* @__PURE__ */ s(
|
|
1343
|
+
}), b = Le(h), { getReferenceProps: w, getFloatingProps: y } = Pe([b]);
|
|
1344
|
+
return /* @__PURE__ */ s(ee, { children: [
|
|
1329
1345
|
/* @__PURE__ */ t(
|
|
1330
1346
|
"button",
|
|
1331
1347
|
{
|
|
1332
1348
|
type: "button",
|
|
1333
1349
|
onClick: c,
|
|
1334
|
-
className:
|
|
1350
|
+
className: d.interactivePinButton,
|
|
1335
1351
|
ref: u.setReference,
|
|
1336
1352
|
style: { left: `${n}%` },
|
|
1337
|
-
...
|
|
1353
|
+
...w(),
|
|
1338
1354
|
children: /* @__PURE__ */ s(
|
|
1339
1355
|
"svg",
|
|
1340
1356
|
{
|
|
1341
|
-
className:
|
|
1357
|
+
className: d.interactivePin,
|
|
1342
1358
|
width: "36",
|
|
1343
1359
|
height: "44",
|
|
1344
1360
|
fill: "none",
|
|
@@ -1348,21 +1364,21 @@ function Xo({ currentTime: e, position: n }) {
|
|
|
1348
1364
|
/* @__PURE__ */ t(
|
|
1349
1365
|
"path",
|
|
1350
1366
|
{
|
|
1351
|
-
className:
|
|
1367
|
+
className: d.bg,
|
|
1352
1368
|
d: "M 33.1703,27.499961 C 34.9615,24.721661 36,21.418761 36,17.874961 36,8.0028612 27.9411,-3.8819277e-5 18,-3.8819277e-5 8.0588999,-3.8819277e-5 -1.5e-7,8.0028612 -1.5e-7,17.874961 c 0,3.5438 1.03844995,6.8467 2.82964995,9.625 4.5447501,6.8094 10.1600502,10.1014 15.2487502,16.5 5.0364,-6.3985 10.5573,-9.7259 15.0919,-16.5 z"
|
|
1353
1369
|
}
|
|
1354
1370
|
),
|
|
1355
1371
|
/* @__PURE__ */ t(
|
|
1356
1372
|
"path",
|
|
1357
1373
|
{
|
|
1358
|
-
className:
|
|
1374
|
+
className: d.symbol,
|
|
1359
1375
|
d: "m 35.499961,17.877772 c 0,3.443549 -1.008198,6.652061 -2.747494,9.351891 -2.235095,3.338633 -4.71529,5.832631 -7.286584,8.306425 -0.277599,0.267143 -0.556499,0.534085 -0.836198,0.801928 -2.174595,2.082232 -4.40389,4.216673 -6.553385,6.870196 -2.158995,-2.636621 -4.40379,-4.754859 -6.591985,-6.819788 -0.2979,-0.281145 -0.594699,-0.561289 -0.890198,-0.841534 C 7.9918219,33.077896 5.4869279,30.584698 3.2477829,27.230063 1.5082968,24.530133 0.50003905,21.321521 0.50003905,17.877772 0.50003905,8.2835422 8.3317219,0.50000048 18,0.50000048 c 9.668278,0 17.499961,7.78354172 17.499961,17.37777152 z"
|
|
1360
1376
|
}
|
|
1361
1377
|
),
|
|
1362
1378
|
/* @__PURE__ */ t(
|
|
1363
1379
|
"path",
|
|
1364
1380
|
{
|
|
1365
|
-
className:
|
|
1381
|
+
className: d.interactivePinIcon,
|
|
1366
1382
|
"data-open": o,
|
|
1367
1383
|
fillRule: "evenodd",
|
|
1368
1384
|
clipRule: "evenodd",
|
|
@@ -1379,17 +1395,17 @@ function Xo({ currentTime: e, position: n }) {
|
|
|
1379
1395
|
"div",
|
|
1380
1396
|
{
|
|
1381
1397
|
ref: u.setFloating,
|
|
1382
|
-
style:
|
|
1383
|
-
className:
|
|
1384
|
-
...
|
|
1398
|
+
style: m,
|
|
1399
|
+
className: d.interactivePinMenu,
|
|
1400
|
+
...y(),
|
|
1385
1401
|
children: [
|
|
1386
|
-
a.interactiveMenuElements.map(({ id:
|
|
1402
|
+
a.interactiveMenuElements.map(({ id: C, text: f, onClick: k }) => /* @__PURE__ */ s(
|
|
1387
1403
|
"button",
|
|
1388
1404
|
{
|
|
1389
1405
|
type: "button",
|
|
1390
|
-
className:
|
|
1406
|
+
className: d.interactivePinMenuItem,
|
|
1391
1407
|
onClick: () => {
|
|
1392
|
-
|
|
1408
|
+
k(C, e), i(!1);
|
|
1393
1409
|
},
|
|
1394
1410
|
children: [
|
|
1395
1411
|
/* @__PURE__ */ t(
|
|
@@ -1411,17 +1427,17 @@ function Xo({ currentTime: e, position: n }) {
|
|
|
1411
1427
|
)
|
|
1412
1428
|
}
|
|
1413
1429
|
),
|
|
1414
|
-
|
|
1430
|
+
f
|
|
1415
1431
|
]
|
|
1416
1432
|
},
|
|
1417
|
-
|
|
1433
|
+
C
|
|
1418
1434
|
)),
|
|
1419
1435
|
/* @__PURE__ */ t(
|
|
1420
|
-
|
|
1436
|
+
Ne,
|
|
1421
1437
|
{
|
|
1422
1438
|
ref: l,
|
|
1423
|
-
context:
|
|
1424
|
-
className:
|
|
1439
|
+
context: h,
|
|
1440
|
+
className: d.arrow
|
|
1425
1441
|
}
|
|
1426
1442
|
)
|
|
1427
1443
|
]
|
|
@@ -1429,54 +1445,54 @@ function Xo({ currentTime: e, position: n }) {
|
|
|
1429
1445
|
)
|
|
1430
1446
|
] });
|
|
1431
1447
|
}
|
|
1432
|
-
function
|
|
1433
|
-
const e =
|
|
1434
|
-
return /* @__PURE__ */ t("div", { className:
|
|
1448
|
+
function ii() {
|
|
1449
|
+
const e = _("duration"), n = _("currentTime"), o = n / e * 100;
|
|
1450
|
+
return /* @__PURE__ */ t("div", { className: d.interactivePinContainer, children: /* @__PURE__ */ t("div", { className: d.interactivePinWrapper, children: /* @__PURE__ */ t(oi, { currentTime: n, position: o }) }) });
|
|
1435
1451
|
}
|
|
1436
|
-
function
|
|
1437
|
-
const e =
|
|
1438
|
-
return e && !n.state.interactionsDisabled ? /* @__PURE__ */ t(
|
|
1452
|
+
function ai() {
|
|
1453
|
+
const e = _("paused"), n = v();
|
|
1454
|
+
return e && !n.state.interactionsDisabled ? /* @__PURE__ */ t(ii, {}) : null;
|
|
1439
1455
|
}
|
|
1440
|
-
const
|
|
1441
|
-
function
|
|
1442
|
-
const n =
|
|
1456
|
+
const si = `${d.progress} ${d.trackInner}`, ci = `${d.trackFill} ${d.trackInner}`;
|
|
1457
|
+
function he({ className: e }) {
|
|
1458
|
+
const n = v(), { hasAnnotations: o, hasQuizmarkers: i, interactive: a } = S(), c = e ? `${d.timelineWrapper} ${e}` : d.timelineWrapper;
|
|
1443
1459
|
return /* @__PURE__ */ s("div", { className: c, children: [
|
|
1444
|
-
a ? /* @__PURE__ */ t(
|
|
1445
|
-
a || o || i ? /* @__PURE__ */ t(
|
|
1460
|
+
a ? /* @__PURE__ */ t(ai, {}) : null,
|
|
1461
|
+
a || o || i ? /* @__PURE__ */ t(ti, {}) : null,
|
|
1446
1462
|
/* @__PURE__ */ s(
|
|
1447
|
-
|
|
1463
|
+
A.Root,
|
|
1448
1464
|
{
|
|
1449
|
-
className:
|
|
1465
|
+
className: d.root,
|
|
1450
1466
|
tabIndex: n.state.interactionsDisabled ? -1 : 0,
|
|
1451
1467
|
children: [
|
|
1452
|
-
/* @__PURE__ */ s(
|
|
1453
|
-
/* @__PURE__ */ t(
|
|
1454
|
-
/* @__PURE__ */ t(
|
|
1468
|
+
/* @__PURE__ */ s(A.Track, { className: d.track, children: [
|
|
1469
|
+
/* @__PURE__ */ t(A.Progress, { className: si }),
|
|
1470
|
+
/* @__PURE__ */ t(A.TrackFill, { className: ci })
|
|
1455
1471
|
] }),
|
|
1456
|
-
/* @__PURE__ */ t(
|
|
1472
|
+
/* @__PURE__ */ t(A.Thumb, { className: d.thumb })
|
|
1457
1473
|
]
|
|
1458
1474
|
}
|
|
1459
1475
|
),
|
|
1460
|
-
/* @__PURE__ */ t(
|
|
1476
|
+
/* @__PURE__ */ t(ni, {})
|
|
1461
1477
|
] });
|
|
1462
1478
|
}
|
|
1463
|
-
const
|
|
1464
|
-
wrapper:
|
|
1465
|
-
track:
|
|
1466
|
-
thumb:
|
|
1479
|
+
const li = "_wrapper_12cb0_1", ri = "_track_12cb0_6", ui = "_thumb_12cb0_18", di = "_track-fill_12cb0_32", mi = "_root_12cb0_51", F = {
|
|
1480
|
+
wrapper: li,
|
|
1481
|
+
track: ri,
|
|
1482
|
+
thumb: ui,
|
|
1467
1483
|
"track-fill": "_track-fill_12cb0_32",
|
|
1468
|
-
trackFill:
|
|
1469
|
-
root:
|
|
1484
|
+
trackFill: di,
|
|
1485
|
+
root: mi
|
|
1470
1486
|
};
|
|
1471
|
-
function
|
|
1472
|
-
const e =
|
|
1487
|
+
function hi() {
|
|
1488
|
+
const e = _("volume"), n = _("muted"), o = v();
|
|
1473
1489
|
return /* @__PURE__ */ s("div", { className: F.wrapper, children: [
|
|
1474
1490
|
/* @__PURE__ */ t(
|
|
1475
|
-
|
|
1491
|
+
Je,
|
|
1476
1492
|
{
|
|
1477
1493
|
tabIndex: o.state.interactionsDisabled ? -1 : 0,
|
|
1478
1494
|
className: "controls-button",
|
|
1479
|
-
children: n || e == 0 ? /* @__PURE__ */ t(
|
|
1495
|
+
children: n || e == 0 ? /* @__PURE__ */ t(Ve, { className: "controls-button-icon" }) : e < 0.5 ? /* @__PURE__ */ t(Be, { className: "controls-button-icon" }) : /* @__PURE__ */ t(Re, { className: "controls-button-icon" })
|
|
1480
1496
|
}
|
|
1481
1497
|
),
|
|
1482
1498
|
/* @__PURE__ */ s(
|
|
@@ -1492,7 +1508,7 @@ function ri() {
|
|
|
1492
1508
|
)
|
|
1493
1509
|
] });
|
|
1494
1510
|
}
|
|
1495
|
-
const
|
|
1511
|
+
const pe = {
|
|
1496
1512
|
togglePaused: ["Space", "Enter", "k"],
|
|
1497
1513
|
seekForward: ["ArrowRight"],
|
|
1498
1514
|
seekBackward: ["ArrowLeft"],
|
|
@@ -1530,8 +1546,8 @@ const me = {
|
|
|
1530
1546
|
decreasePlaybackRate: {
|
|
1531
1547
|
keys: ["a"],
|
|
1532
1548
|
onKeyUp({ event: e, player: n, remote: o }) {
|
|
1533
|
-
const a =
|
|
1534
|
-
a >= 0 && (o.changePlaybackRate(
|
|
1549
|
+
const a = B.indexOf(n.playbackRate) - 1;
|
|
1550
|
+
a >= 0 && (o.changePlaybackRate(B[a]), n.$state.lastKeyboardAction.set({
|
|
1535
1551
|
action: "decreasePlaybackRate",
|
|
1536
1552
|
event: e
|
|
1537
1553
|
}));
|
|
@@ -1540,8 +1556,8 @@ const me = {
|
|
|
1540
1556
|
increasePlaybackRate: {
|
|
1541
1557
|
keys: ["d"],
|
|
1542
1558
|
onKeyUp({ event: e, player: n, remote: o }) {
|
|
1543
|
-
const a =
|
|
1544
|
-
a <
|
|
1559
|
+
const a = B.indexOf(n.playbackRate) + 1;
|
|
1560
|
+
a < B.length && (o.changePlaybackRate(B[a]), n.$state.lastKeyboardAction.set({
|
|
1545
1561
|
action: "increasePlaybackRate",
|
|
1546
1562
|
event: e
|
|
1547
1563
|
}));
|
|
@@ -1575,7 +1591,10 @@ const me = {
|
|
|
1575
1591
|
}
|
|
1576
1592
|
}
|
|
1577
1593
|
};
|
|
1578
|
-
function
|
|
1594
|
+
function _e(e) {
|
|
1595
|
+
return typeof e == "number" && !isNaN(e);
|
|
1596
|
+
}
|
|
1597
|
+
function pi(e, n = 1e3) {
|
|
1579
1598
|
let o = !1;
|
|
1580
1599
|
return () => {
|
|
1581
1600
|
o || (e(), o = !0, setTimeout(() => {
|
|
@@ -1583,7 +1602,7 @@ function ui(e, n = 1e3) {
|
|
|
1583
1602
|
}, n));
|
|
1584
1603
|
};
|
|
1585
1604
|
}
|
|
1586
|
-
const
|
|
1605
|
+
const fe = {
|
|
1587
1606
|
volume: 1,
|
|
1588
1607
|
muted: !1,
|
|
1589
1608
|
lang: null,
|
|
@@ -1594,24 +1613,25 @@ const he = {
|
|
|
1594
1613
|
invert: !1,
|
|
1595
1614
|
comments: !1
|
|
1596
1615
|
};
|
|
1597
|
-
class
|
|
1616
|
+
class _i {
|
|
1598
1617
|
constructor() {
|
|
1599
|
-
|
|
1600
|
-
|
|
1601
|
-
|
|
1602
|
-
|
|
1603
|
-
|
|
1618
|
+
x(this, "playerId", "studio-player");
|
|
1619
|
+
x(this, "mediaId", null);
|
|
1620
|
+
x(this, "data", fe);
|
|
1621
|
+
x(this, "time", null);
|
|
1622
|
+
x(this, "overrideTime", null);
|
|
1623
|
+
x(this, "saveTime", () => {
|
|
1604
1624
|
if (!this.mediaId) return;
|
|
1605
1625
|
const n = (this.time ?? 0).toString();
|
|
1606
1626
|
localStorage.setItem(this.mediaId, n);
|
|
1607
1627
|
});
|
|
1608
|
-
|
|
1628
|
+
x(this, "saveTimeThrottled", pi(this.saveTime, 1e3));
|
|
1609
1629
|
// only used for useStudioPlayer hook's state initialization
|
|
1610
|
-
|
|
1611
|
-
const
|
|
1612
|
-
if (n)
|
|
1630
|
+
x(this, "initializeState", (n) => {
|
|
1631
|
+
const o = localStorage.getItem(this.playerId);
|
|
1632
|
+
if (_e(n) && n >= 0 && (this.overrideTime = n), o)
|
|
1613
1633
|
try {
|
|
1614
|
-
this.data = JSON.parse(
|
|
1634
|
+
this.data = JSON.parse(o);
|
|
1615
1635
|
} catch {
|
|
1616
1636
|
}
|
|
1617
1637
|
return {
|
|
@@ -1619,10 +1639,11 @@ class di {
|
|
|
1619
1639
|
captionPositionOnTop: this.data.ontop,
|
|
1620
1640
|
captionsInvertColors: this.data.invert,
|
|
1621
1641
|
commentsEnabled: this.data.comments,
|
|
1622
|
-
interactionsDisabled: !1
|
|
1642
|
+
interactionsDisabled: !1,
|
|
1643
|
+
disableCaptionSettings: !1
|
|
1623
1644
|
};
|
|
1624
1645
|
});
|
|
1625
|
-
|
|
1646
|
+
x(this, "saveData", (n, o) => {
|
|
1626
1647
|
this.data = {
|
|
1627
1648
|
...this.data,
|
|
1628
1649
|
[n]: o
|
|
@@ -1682,9 +1703,9 @@ class di {
|
|
|
1682
1703
|
} catch {
|
|
1683
1704
|
}
|
|
1684
1705
|
this.data = {
|
|
1685
|
-
...
|
|
1706
|
+
...fe,
|
|
1686
1707
|
...l
|
|
1687
|
-
}, this.time = c ? +c : null;
|
|
1708
|
+
}, _e(this.overrideTime) && this.overrideTime >= 0 ? this.time = this.overrideTime : this.time = c ? +c : null;
|
|
1688
1709
|
}
|
|
1689
1710
|
save() {
|
|
1690
1711
|
if (!this.playerId) return;
|
|
@@ -1692,72 +1713,76 @@ class di {
|
|
|
1692
1713
|
localStorage.setItem(this.playerId, n);
|
|
1693
1714
|
}
|
|
1694
1715
|
}
|
|
1695
|
-
function
|
|
1696
|
-
const
|
|
1697
|
-
|
|
1698
|
-
),
|
|
1699
|
-
(
|
|
1700
|
-
|
|
1701
|
-
...
|
|
1702
|
-
captionsFontSizeMultiplier:
|
|
1716
|
+
function fi(e, n, o, i) {
|
|
1717
|
+
const a = Z(() => new _i(), []), [c, l] = M(
|
|
1718
|
+
a.initializeState(i)
|
|
1719
|
+
), u = p(
|
|
1720
|
+
(f) => {
|
|
1721
|
+
l((k) => (a.saveData("multiplier", f), {
|
|
1722
|
+
...k,
|
|
1723
|
+
captionsFontSizeMultiplier: f
|
|
1703
1724
|
}));
|
|
1704
1725
|
},
|
|
1705
|
-
[
|
|
1706
|
-
),
|
|
1707
|
-
|
|
1708
|
-
const
|
|
1709
|
-
return
|
|
1710
|
-
...
|
|
1711
|
-
captionPositionOnTop:
|
|
1726
|
+
[a]
|
|
1727
|
+
), m = p(() => {
|
|
1728
|
+
l((f) => {
|
|
1729
|
+
const k = !f.captionPositionOnTop;
|
|
1730
|
+
return a.saveData("ontop", k), {
|
|
1731
|
+
...f,
|
|
1732
|
+
captionPositionOnTop: k
|
|
1712
1733
|
};
|
|
1713
1734
|
});
|
|
1714
|
-
}, [
|
|
1715
|
-
|
|
1716
|
-
const
|
|
1717
|
-
return
|
|
1718
|
-
...
|
|
1719
|
-
captionsInvertColors:
|
|
1735
|
+
}, [a]), h = p(() => {
|
|
1736
|
+
l((f) => {
|
|
1737
|
+
const k = !f.captionsInvertColors;
|
|
1738
|
+
return a.saveData("invert", k), {
|
|
1739
|
+
...f,
|
|
1740
|
+
captionsInvertColors: k
|
|
1720
1741
|
};
|
|
1721
1742
|
});
|
|
1722
|
-
}, [
|
|
1723
|
-
|
|
1724
|
-
const
|
|
1725
|
-
return
|
|
1726
|
-
...
|
|
1727
|
-
commentsEnabled:
|
|
1743
|
+
}, [a]), b = p(() => {
|
|
1744
|
+
l((f) => {
|
|
1745
|
+
const k = !f.commentsEnabled;
|
|
1746
|
+
return a.saveData("comments", k), {
|
|
1747
|
+
...f,
|
|
1748
|
+
commentsEnabled: k
|
|
1728
1749
|
};
|
|
1729
1750
|
});
|
|
1730
|
-
}, [
|
|
1731
|
-
|
|
1732
|
-
...
|
|
1751
|
+
}, [a]), w = p(() => {
|
|
1752
|
+
l((f) => ({
|
|
1753
|
+
...f,
|
|
1733
1754
|
interactionsDisabled: !1
|
|
1734
1755
|
}));
|
|
1735
|
-
}, []),
|
|
1736
|
-
|
|
1737
|
-
...
|
|
1756
|
+
}, []), y = p(() => {
|
|
1757
|
+
l((f) => ({
|
|
1758
|
+
...f,
|
|
1738
1759
|
interactionsDisabled: !0
|
|
1739
1760
|
}));
|
|
1740
|
-
}, []),
|
|
1741
|
-
...
|
|
1761
|
+
}, []), C = Z(() => e ? {
|
|
1762
|
+
...pe,
|
|
1742
1763
|
toggleFullscreen: []
|
|
1743
|
-
} :
|
|
1764
|
+
} : pe, [e]);
|
|
1744
1765
|
return {
|
|
1745
1766
|
contextValue: {
|
|
1746
|
-
state:
|
|
1747
|
-
|
|
1748
|
-
|
|
1749
|
-
|
|
1750
|
-
|
|
1751
|
-
|
|
1752
|
-
|
|
1767
|
+
state: {
|
|
1768
|
+
...c,
|
|
1769
|
+
commentsEnabled: n || c.commentsEnabled
|
|
1770
|
+
},
|
|
1771
|
+
setCaptionsFontSizeMultiplier: u,
|
|
1772
|
+
toggleCaptionPositionOnTop: m,
|
|
1773
|
+
toggleCaptionsInvertColors: h,
|
|
1774
|
+
enableInteractions: w,
|
|
1775
|
+
disableInteractions: y,
|
|
1776
|
+
toggleComments: b,
|
|
1777
|
+
disableCaptionSettings: o
|
|
1753
1778
|
},
|
|
1754
|
-
shortcuts:
|
|
1755
|
-
storage:
|
|
1779
|
+
shortcuts: C,
|
|
1780
|
+
storage: a
|
|
1756
1781
|
};
|
|
1757
1782
|
}
|
|
1758
|
-
const
|
|
1783
|
+
const vi = {}, J = () => {
|
|
1759
1784
|
};
|
|
1760
|
-
function
|
|
1785
|
+
function Ni({
|
|
1761
1786
|
title: e,
|
|
1762
1787
|
playerRef: n,
|
|
1763
1788
|
src: o,
|
|
@@ -1766,60 +1791,77 @@ function yi({
|
|
|
1766
1791
|
hideFullScreen: c = !1,
|
|
1767
1792
|
comments: l = [],
|
|
1768
1793
|
locale: u = "en",
|
|
1769
|
-
annotations:
|
|
1770
|
-
quizMarkers:
|
|
1794
|
+
annotations: m = [],
|
|
1795
|
+
quizMarkers: h = [],
|
|
1771
1796
|
interactive: b = !1,
|
|
1772
|
-
onAnnotationClick:
|
|
1773
|
-
onQuizMarkerClick:
|
|
1774
|
-
onInteractivePinClick:
|
|
1775
|
-
interactiveMenuElements:
|
|
1776
|
-
darkMode:
|
|
1777
|
-
autoLoadCaptionSrc:
|
|
1797
|
+
onAnnotationClick: w = J,
|
|
1798
|
+
onQuizMarkerClick: y = J,
|
|
1799
|
+
onInteractivePinClick: C = J,
|
|
1800
|
+
interactiveMenuElements: f = [],
|
|
1801
|
+
darkMode: k = !1,
|
|
1802
|
+
autoLoadCaptionSrc: T = "",
|
|
1803
|
+
forceComments: ae,
|
|
1804
|
+
disableCaptionSettings: Q,
|
|
1805
|
+
startAt: Oe
|
|
1778
1806
|
}) {
|
|
1779
|
-
const { contextValue:
|
|
1780
|
-
|
|
1781
|
-
ae
|
|
1782
|
-
|
|
1783
|
-
|
|
1807
|
+
const { contextValue: se, shortcuts: Fe, storage: Ze } = fi(
|
|
1808
|
+
c,
|
|
1809
|
+
ae ?? !1,
|
|
1810
|
+
Q ?? !1,
|
|
1811
|
+
Oe
|
|
1812
|
+
), { i18n: ce } = g();
|
|
1813
|
+
return E(() => {
|
|
1814
|
+
ce.changeLanguage(u);
|
|
1815
|
+
}, [ce, u]), /* @__PURE__ */ t(
|
|
1816
|
+
rt,
|
|
1784
1817
|
{
|
|
1785
1818
|
hideFullScreen: c,
|
|
1786
1819
|
comments: l,
|
|
1787
|
-
annotations:
|
|
1788
|
-
quizMarkers:
|
|
1820
|
+
annotations: m,
|
|
1821
|
+
quizMarkers: h,
|
|
1789
1822
|
interactive: b,
|
|
1790
|
-
onAnnotationClick:
|
|
1791
|
-
onQuizMarkerClick:
|
|
1792
|
-
onInteractivePinClick:
|
|
1793
|
-
interactiveMenuElements:
|
|
1794
|
-
darkMode:
|
|
1795
|
-
|
|
1796
|
-
|
|
1823
|
+
onAnnotationClick: w,
|
|
1824
|
+
onQuizMarkerClick: y,
|
|
1825
|
+
onInteractivePinClick: C,
|
|
1826
|
+
interactiveMenuElements: f,
|
|
1827
|
+
darkMode: k,
|
|
1828
|
+
forceComments: ae ?? !1,
|
|
1829
|
+
disableCaptionSettings: Q ?? !1,
|
|
1830
|
+
children: /* @__PURE__ */ t(lt, { contextValue: se, children: /* @__PURE__ */ s(
|
|
1831
|
+
Xe,
|
|
1797
1832
|
{
|
|
1798
|
-
storage:
|
|
1833
|
+
storage: Ze,
|
|
1799
1834
|
title: e,
|
|
1800
1835
|
src: o,
|
|
1801
|
-
keyShortcuts:
|
|
1836
|
+
keyShortcuts: Fe,
|
|
1802
1837
|
playsInline: !0,
|
|
1803
|
-
keyDisabled:
|
|
1838
|
+
keyDisabled: se.state.interactionsDisabled,
|
|
1804
1839
|
onTextTracksChange: (K) => {
|
|
1805
|
-
const
|
|
1806
|
-
(
|
|
1840
|
+
const le = K == null ? void 0 : K.findIndex(
|
|
1841
|
+
($e) => $e.src === T
|
|
1807
1842
|
);
|
|
1808
|
-
|
|
1843
|
+
le > -1 && (K[le].mode = "showing");
|
|
1809
1844
|
},
|
|
1810
1845
|
children: [
|
|
1811
|
-
/* @__PURE__ */ t(
|
|
1812
|
-
/* @__PURE__ */ s(
|
|
1813
|
-
/* @__PURE__ */ t(
|
|
1814
|
-
/* @__PURE__ */ t(
|
|
1815
|
-
/* @__PURE__ */ t(
|
|
1816
|
-
/* @__PURE__ */ t(
|
|
1817
|
-
/* @__PURE__ */ t(
|
|
1818
|
-
/* @__PURE__ */ t(
|
|
1819
|
-
/* @__PURE__ */ t(
|
|
1846
|
+
/* @__PURE__ */ t(so, {}),
|
|
1847
|
+
/* @__PURE__ */ s(et, { className: vi.mediaProvider, children: [
|
|
1848
|
+
/* @__PURE__ */ t(ho, { src: a }),
|
|
1849
|
+
/* @__PURE__ */ t(Un, {}),
|
|
1850
|
+
/* @__PURE__ */ t(Ct, {}),
|
|
1851
|
+
/* @__PURE__ */ t(wt, { captions: i }),
|
|
1852
|
+
/* @__PURE__ */ t(Et, { comments: l }),
|
|
1853
|
+
/* @__PURE__ */ t(go, {}),
|
|
1854
|
+
/* @__PURE__ */ t(eo, {})
|
|
1820
1855
|
] }),
|
|
1821
|
-
/* @__PURE__ */ t(
|
|
1822
|
-
|
|
1856
|
+
/* @__PURE__ */ t(
|
|
1857
|
+
Kt,
|
|
1858
|
+
{
|
|
1859
|
+
darkMode: k,
|
|
1860
|
+
playerRef: n,
|
|
1861
|
+
showCaptionsButton: !Q
|
|
1862
|
+
}
|
|
1863
|
+
),
|
|
1864
|
+
/* @__PURE__ */ t(ht, { annotations: m })
|
|
1823
1865
|
]
|
|
1824
1866
|
}
|
|
1825
1867
|
) })
|
|
@@ -1827,8 +1869,8 @@ function yi({
|
|
|
1827
1869
|
);
|
|
1828
1870
|
}
|
|
1829
1871
|
export {
|
|
1830
|
-
|
|
1831
|
-
|
|
1832
|
-
|
|
1833
|
-
|
|
1872
|
+
Lt as CAPTION_FONT_SIZE_MULTIPLIERS,
|
|
1873
|
+
Se as COMMENT_DURATION,
|
|
1874
|
+
B as PLAYBACK_RATES,
|
|
1875
|
+
Ni as StudioPlayer
|
|
1834
1876
|
};
|