@vindral/web-sdk 4.7.0 → 4.7.1-2-g72bf274f
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/{Ctk0PAlI.js → BK-84KPi.js} +1 -1
- package/{DYgG1Gmb.js → D5NaiJmn.js} +774 -773
- package/{5u5UZABw.js → DBP00llQ.js} +3042 -2695
- package/{Bo-fEHbb.js → XEQIIc9P.js} +3 -3
- package/core.js +1 -1
- package/legacy.es.js +3764 -3417
- package/legacy.umd.js +16 -16
- package/package.json +1 -1
- package/player.js +3 -3
- package/vindral-player-component.js +2 -2
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { n as e, t } from "./BsfwXDui.js";
|
|
2
|
-
import { C as n, D as r, E as i, O as a, S as o, T as s, _ as c, b as l, g as u, h as ee, k as d, m as te, p as ne, t as re, v as ie, w as ae, x as oe, y as se } from "./
|
|
2
|
+
import { C as n, D as r, E as i, O as a, S as o, T as s, _ as c, b as l, g as u, h as ee, k as d, m as te, p as ne, t as re, v as ie, w as ae, x as oe, y as se } from "./DBP00llQ.js";
|
|
3
3
|
import { t as ce } from "./CuYn2z5X.js";
|
|
4
4
|
import { i as f, n as p, r as m, t as h } from "./DSw1XhvD.js";
|
|
5
5
|
import { c as le, n as ue, t as de } from "./D40eQS8l.js";
|
|
6
6
|
import { n as fe, r as pe } from "./BaDhuUsA.js";
|
|
7
|
-
import { C as me, S as he, _ as ge, a as _e, b as g, c as _, d as ve, f as ye, g as be, h as xe, i as v, l as Se, m as Ce, n as we, o as Te, p as Ee, r as y, s as De, t as Oe, u as b, v as ke, x as Ae, y as x } from "./
|
|
7
|
+
import { C as me, S as he, _ as ge, a as _e, b as g, c as _, d as ve, f as ye, g as be, h as xe, i as v, l as Se, m as Ce, n as we, o as Te, p as Ee, r as y, s as De, t as Oe, u as b, v as ke, x as Ae, y as x } from "./BK-84KPi.js";
|
|
8
8
|
import { t as S } from "./Tj9xPXja.js";
|
|
9
9
|
import { t as je } from "./DQ5kuB8C.js";
|
|
10
10
|
//#region ../../libs/utils/src/mediaMetadata.ts
|
|
@@ -1074,22 +1074,25 @@ function Gn(e) {
|
|
|
1074
1074
|
return [];
|
|
1075
1075
|
}
|
|
1076
1076
|
}
|
|
1077
|
-
var Kn = /* @__PURE__ */ new WeakMap(), qn = /* @__PURE__ */ new WeakMap(), Jn = /* @__PURE__ */ new WeakMap(), Yn = /* @__PURE__ */ new WeakMap(), Xn = /* @__PURE__ */ new WeakMap(), Zn = /* @__PURE__ */ new WeakMap(), Qn = class {
|
|
1077
|
+
var Kn = /* @__PURE__ */ new WeakMap(), qn = /* @__PURE__ */ new WeakMap(), Jn = /* @__PURE__ */ new WeakMap(), Yn = /* @__PURE__ */ new WeakMap(), Xn = /* @__PURE__ */ new WeakMap(), Zn = /* @__PURE__ */ new WeakMap(), Qn = /* @__PURE__ */ new WeakMap(), $n = /* @__PURE__ */ new WeakMap(), er = class {
|
|
1078
1078
|
constructor(t) {
|
|
1079
1079
|
f(this, Kn, void 0), f(this, qn, null), f(this, Jn, null), f(this, Yn, null), f(this, Xn, !0), e(this, "observe", (e) => {
|
|
1080
|
-
h(Yn, this) || (p(Yn, this, e), window.ResizeObserver && (p(qn, this, new ResizeObserver(() => h(
|
|
1081
|
-
}),
|
|
1080
|
+
h(Yn, this) || (p(Yn, this, e), e.addEventListener("webkitpresentationmodechanged", h(Zn, this), !0), window.ResizeObserver && (p(qn, this, new ResizeObserver(() => h($n, this).call(this))), h(qn, this).observe(e)));
|
|
1081
|
+
}), f(this, Zn, (e) => {
|
|
1082
|
+
var t;
|
|
1083
|
+
e.target instanceof HTMLMediaElement && h(Qn, this).call(this, ((t = ie(e.target)) == null ? "inline" : t) === "inline");
|
|
1084
|
+
}), f(this, Qn, (e) => {
|
|
1082
1085
|
if (h(Xn, this) !== e) {
|
|
1083
1086
|
if (p(Xn, this, e), p(Jn, this, null), e) {
|
|
1084
|
-
h(
|
|
1087
|
+
h($n, this).call(this);
|
|
1085
1088
|
return;
|
|
1086
1089
|
}
|
|
1087
1090
|
for (let e of h(Kn, this)) e.style.removeProperty("font-size");
|
|
1088
1091
|
}
|
|
1089
1092
|
}), e(this, "unload", () => {
|
|
1090
|
-
var e;
|
|
1091
|
-
(e = h(
|
|
1092
|
-
}), f(this,
|
|
1093
|
+
var e, t;
|
|
1094
|
+
(e = h(Yn, this)) == null || e.removeEventListener("webkitpresentationmodechanged", h(Zn, this), !0), (t = h(qn, this)) == null || t.disconnect(), p(qn, this, null), p(Yn, this, null), p(Xn, this, !0);
|
|
1095
|
+
}), f(this, $n, () => {
|
|
1093
1096
|
if (!h(Xn, this) || h(Kn, this).length === 0 || !h(Yn, this)) return;
|
|
1094
1097
|
let { clientWidth: e, clientHeight: t } = h(Yn, this);
|
|
1095
1098
|
if (e <= 0 || t <= 0) return;
|
|
@@ -1100,7 +1103,7 @@ var Kn = /* @__PURE__ */ new WeakMap(), qn = /* @__PURE__ */ new WeakMap(), Jn =
|
|
|
1100
1103
|
}
|
|
1101
1104
|
}), p(Kn, this, Gn(t));
|
|
1102
1105
|
}
|
|
1103
|
-
},
|
|
1106
|
+
}, tr = class n extends pe {
|
|
1104
1107
|
constructor(r) {
|
|
1105
1108
|
var i;
|
|
1106
1109
|
super(), i = this, e(this, "container", void 0), e(this, "unload", () => {
|
|
@@ -1131,35 +1134,35 @@ var Kn = /* @__PURE__ */ new WeakMap(), qn = /* @__PURE__ */ new WeakMap(), Jn =
|
|
|
1131
1134
|
return () => Promise.resolve();
|
|
1132
1135
|
}
|
|
1133
1136
|
};
|
|
1134
|
-
e(
|
|
1137
|
+
e(tr, "isFullscreenApiSupported", (e) => l(e));
|
|
1135
1138
|
//#endregion
|
|
1136
1139
|
//#region ../../libs/player-next/src/PictureInPicture.ts
|
|
1137
|
-
var
|
|
1140
|
+
var nr = /* @__PURE__ */ new WeakMap(), rr = /* @__PURE__ */ new WeakMap(), ir = /* @__PURE__ */ new WeakMap(), ar = /* @__PURE__ */ new WeakMap(), or = /* @__PURE__ */ new WeakMap(), sr = /* @__PURE__ */ new WeakMap(), cr = /* @__PURE__ */ new WeakMap(), lr = /* @__PURE__ */ new WeakMap(), ur = /* @__PURE__ */ new WeakMap(), dr = class extends pe {
|
|
1138
1141
|
constructor(r) {
|
|
1139
1142
|
var a;
|
|
1140
1143
|
super(), a = this, e(this, "unload", () => {
|
|
1141
1144
|
this.element.removeEventListener("enterpictureinpicture", this.onChange), this.element.removeEventListener("leavepictureinpicture", this.onChange), this.element.removeEventListener("webkitpresentationmodechanged", this.onChange), n(this.element, !1);
|
|
1142
1145
|
}), e(this, "request", t(function* () {
|
|
1143
1146
|
try {
|
|
1144
|
-
return yield h(
|
|
1147
|
+
return yield h(nr, a).call(a);
|
|
1145
1148
|
} catch (e) {
|
|
1146
1149
|
throw a.onChange(), e;
|
|
1147
1150
|
}
|
|
1148
1151
|
})), e(this, "exit", t(function* () {
|
|
1149
1152
|
try {
|
|
1150
|
-
return yield h(
|
|
1153
|
+
return yield h(rr, a).call(a);
|
|
1151
1154
|
} catch (e) {
|
|
1152
1155
|
throw a.onChange(), e;
|
|
1153
1156
|
}
|
|
1154
1157
|
})), e(this, "onChange", () => {
|
|
1155
1158
|
this.emit("on picture in picture change", this.isPictureInPictureActive());
|
|
1156
|
-
}), e(this, "isPictureInPictureActive", () => this.
|
|
1159
|
+
}), e(this, "isPictureInPictureActive", () => h(cr, this).call(this) || h(sr, this).call(this)), e(this, "isSupported", () => h(ur, this).call(this) || h(or, this).call(this)), f(this, nr, () => h(or, this).call(this) ? h(ir, this).call(this) : h(ur, this).call(this) ? h(lr, this).call(this, "picture-in-picture") : Promise.resolve()), f(this, rr, () => this.isPictureInPictureActive() ? h(or, this).call(this) ? h(ar, this).call(this) : h(ur, this).call(this) ? h(lr, this).call(this, "inline") : Promise.resolve() : Promise.resolve()), f(this, ir, t(function* () {
|
|
1157
1160
|
let e = c(a.element);
|
|
1158
1161
|
e && (yield e());
|
|
1159
|
-
})), f(this,
|
|
1162
|
+
})), f(this, ar, t(function* () {
|
|
1160
1163
|
let e = ee();
|
|
1161
1164
|
e && (yield e());
|
|
1162
|
-
})), f(this,
|
|
1165
|
+
})), f(this, or, () => s(this.element)), f(this, sr, () => oe()), f(this, cr, () => ie(this.element) === "picture-in-picture"), f(this, lr, (e) => (i(this.element) && ae(this.element, e), Promise.resolve())), f(this, ur, () => i(this.element)), this.element = r, this.element.addEventListener("enterpictureinpicture", this.onChange), this.element.addEventListener("leavepictureinpicture", this.onChange), this.element.addEventListener("webkitpresentationmodechanged", this.onChange), n(this.element, !0);
|
|
1163
1166
|
}
|
|
1164
1167
|
get videoElement() {
|
|
1165
1168
|
return this.element;
|
|
@@ -1167,7 +1170,7 @@ var er = /* @__PURE__ */ new WeakMap(), tr = /* @__PURE__ */ new WeakMap(), nr =
|
|
|
1167
1170
|
};
|
|
1168
1171
|
//#endregion
|
|
1169
1172
|
//#region ../../libs/player-next/src/timeshift/firstMediaPlaylistUrl.ts
|
|
1170
|
-
function
|
|
1173
|
+
function fr(e, t) {
|
|
1171
1174
|
let n = e.split("\n").map((e) => e.trim());
|
|
1172
1175
|
for (let e = 0; e < n.length; e++) {
|
|
1173
1176
|
var r;
|
|
@@ -1179,7 +1182,7 @@ function lr(e, t) {
|
|
|
1179
1182
|
}
|
|
1180
1183
|
//#endregion
|
|
1181
1184
|
//#region ../../libs/player-next/src/timeshift/parseMediaPlaylistDuration.ts
|
|
1182
|
-
function
|
|
1185
|
+
function pr(e) {
|
|
1183
1186
|
let t = 0;
|
|
1184
1187
|
for (let n of e.split("\n")) {
|
|
1185
1188
|
let e = n.trim().match(/^#EXTINF:([\d.]+)/), r = e != null && e[1] ? Number.parseFloat(e[1]) : NaN;
|
|
@@ -1189,90 +1192,90 @@ function ur(e) {
|
|
|
1189
1192
|
}
|
|
1190
1193
|
//#endregion
|
|
1191
1194
|
//#region ../../libs/player-next/src/timeshift/probeTimeshiftDuration.ts
|
|
1192
|
-
var
|
|
1193
|
-
function
|
|
1194
|
-
return
|
|
1195
|
+
var mr = 5e3;
|
|
1196
|
+
function hr(e, t) {
|
|
1197
|
+
return gr.apply(this, arguments);
|
|
1195
1198
|
}
|
|
1196
|
-
function
|
|
1197
|
-
return
|
|
1198
|
-
let { signal: r, timeoutMs: i =
|
|
1199
|
+
function gr() {
|
|
1200
|
+
return gr = t(function* (e, t, n = {}) {
|
|
1201
|
+
let { signal: r, timeoutMs: i = mr } = n, a = new AbortController(), o = () => a.abort();
|
|
1199
1202
|
r && (r.aborted ? a.abort() : r.addEventListener("abort", o, { once: !0 }));
|
|
1200
1203
|
let s = setTimeout(o, i);
|
|
1201
1204
|
try {
|
|
1202
1205
|
let n = yield fetch(e, { signal: a.signal });
|
|
1203
1206
|
if (!n.ok) return;
|
|
1204
|
-
let r =
|
|
1207
|
+
let r = fr(yield n.text(), e);
|
|
1205
1208
|
if (!r) return;
|
|
1206
1209
|
let i = new URL(r);
|
|
1207
1210
|
i.searchParams.set("channelId", t.channelId), i.searchParams.set("from", t.from), t.authToken && i.searchParams.set("authToken", t.authToken);
|
|
1208
1211
|
let o = yield fetch(i.toString(), { signal: a.signal });
|
|
1209
|
-
return o.ok ?
|
|
1212
|
+
return o.ok ? pr(yield o.text()) : void 0;
|
|
1210
1213
|
} catch (e) {
|
|
1211
1214
|
return;
|
|
1212
1215
|
} finally {
|
|
1213
1216
|
clearTimeout(s), r == null || r.removeEventListener("abort", o);
|
|
1214
1217
|
}
|
|
1215
|
-
}),
|
|
1218
|
+
}), gr.apply(this, arguments);
|
|
1216
1219
|
}
|
|
1217
1220
|
//#endregion
|
|
1218
1221
|
//#region ../../libs/player-next/src/timeshift/TimeshiftDurationSource.ts
|
|
1219
|
-
var
|
|
1220
|
-
constructor({ onChange: e, probe: t =
|
|
1221
|
-
S(this, A), f(this,
|
|
1222
|
+
var _r = /* @__PURE__ */ new WeakMap(), vr = /* @__PURE__ */ new WeakMap(), yr = /* @__PURE__ */ new WeakMap(), br = /* @__PURE__ */ new WeakMap(), xr = /* @__PURE__ */ new WeakMap(), Sr = /* @__PURE__ */ new WeakMap(), Cr = /* @__PURE__ */ new WeakMap(), wr = /* @__PURE__ */ new WeakMap(), Tr = /* @__PURE__ */ new WeakMap(), Er = /* @__PURE__ */ new WeakMap(), A = /* @__PURE__ */ new WeakSet(), Dr = class {
|
|
1223
|
+
constructor({ onChange: e, probe: t = hr, now: n = () => performance.now() }) {
|
|
1224
|
+
S(this, A), f(this, _r, void 0), f(this, vr, void 0), f(this, yr, void 0), f(this, br, void 0), f(this, xr, !0), f(this, Sr, !1), f(this, Cr, 0), f(this, wr, 0), f(this, Tr, 0), f(this, Er, null), p(_r, this, e), p(vr, this, t), p(yr, this, n);
|
|
1222
1225
|
}
|
|
1223
1226
|
start({ multivariantUrl: e, params: t, windowCapSeconds: n }) {
|
|
1224
|
-
if (m(A, this,
|
|
1225
|
-
h(
|
|
1227
|
+
if (m(A, this, Or).call(this), !(n > 0)) {
|
|
1228
|
+
h(_r, this).call(this, n);
|
|
1226
1229
|
return;
|
|
1227
1230
|
}
|
|
1228
1231
|
let r = new AbortController();
|
|
1229
|
-
p(
|
|
1232
|
+
p(br, this, r);
|
|
1230
1233
|
let { signal: i } = r;
|
|
1231
|
-
h(
|
|
1234
|
+
h(vr, this).call(this, e, t, { signal: i }).then((e) => {
|
|
1232
1235
|
if (!i.aborted) {
|
|
1233
1236
|
if (e === void 0) {
|
|
1234
|
-
h(
|
|
1237
|
+
h(_r, this).call(this, n);
|
|
1235
1238
|
return;
|
|
1236
1239
|
}
|
|
1237
|
-
p(
|
|
1240
|
+
p(wr, this, n), p(Cr, this, Math.min(Math.max(e, 0), n)), p(Tr, this, h(yr, this).call(this)), p(Sr, this, !0), m(A, this, kr).call(this), h(xr, this) && m(A, this, Ar).call(this);
|
|
1238
1241
|
}
|
|
1239
1242
|
});
|
|
1240
1243
|
}
|
|
1241
1244
|
setLive(e) {
|
|
1242
|
-
p(
|
|
1245
|
+
p(xr, this, e), !(!h(br, this) || e) && (m(A, this, jr).call(this), m(A, this, kr).call(this));
|
|
1243
1246
|
}
|
|
1244
1247
|
applyLoadedDuration(e) {
|
|
1245
|
-
m(A, this,
|
|
1248
|
+
m(A, this, Or).call(this), h(_r, this).call(this, Number.isNaN(e) ? 0 : e);
|
|
1246
1249
|
}
|
|
1247
1250
|
stop() {
|
|
1248
|
-
m(A, this,
|
|
1251
|
+
m(A, this, Or).call(this);
|
|
1249
1252
|
}
|
|
1250
1253
|
};
|
|
1251
|
-
function
|
|
1254
|
+
function Or() {
|
|
1252
1255
|
var e;
|
|
1253
|
-
(e = h(
|
|
1256
|
+
(e = h(br, this)) == null || e.abort(), p(br, this, void 0), m(A, this, jr).call(this), p(Sr, this, !1);
|
|
1254
1257
|
}
|
|
1255
|
-
function
|
|
1256
|
-
if (!h(
|
|
1257
|
-
let e = h(
|
|
1258
|
-
h(
|
|
1258
|
+
function kr() {
|
|
1259
|
+
if (!h(Sr, this)) return;
|
|
1260
|
+
let e = h(Cr, this) + Math.max(0, (h(yr, this).call(this) - h(Tr, this)) / 1e3), t = Math.min(h(wr, this), e);
|
|
1261
|
+
h(_r, this).call(this, t), t >= h(wr, this) && m(A, this, jr).call(this);
|
|
1259
1262
|
}
|
|
1260
|
-
function
|
|
1261
|
-
h(
|
|
1263
|
+
function Ar() {
|
|
1264
|
+
h(Er, this) === null && p(Er, this, window.setInterval(() => m(A, this, kr).call(this), 1e3));
|
|
1262
1265
|
}
|
|
1263
|
-
function
|
|
1264
|
-
h(
|
|
1266
|
+
function jr() {
|
|
1267
|
+
h(Er, this) !== null && (clearInterval(h(Er, this)), p(Er, this, null));
|
|
1265
1268
|
}
|
|
1266
1269
|
//#endregion
|
|
1267
1270
|
//#region ../../libs/player-next/src/utils/getVindralAttributes.ts
|
|
1268
|
-
var
|
|
1271
|
+
var Mr = (e) => {
|
|
1269
1272
|
var t;
|
|
1270
1273
|
let n = "observedAttributes" in e.constructor ? e.constructor.observedAttributes : void 0;
|
|
1271
1274
|
return !n && (t = e.nodeName) != null && t.includes("-") && (globalThis.customElements.upgrade(e), n = "observedAttributes" in e.constructor ? e.constructor.observedAttributes : void 0), Array.isArray(n) ? n.filter((e) => Ae.includes(e)) : [];
|
|
1272
1275
|
};
|
|
1273
1276
|
//#endregion
|
|
1274
1277
|
//#region ../../libs/player-next/src/utils/humanReadableTimeToSeconds.ts
|
|
1275
|
-
function
|
|
1278
|
+
function Nr(e) {
|
|
1276
1279
|
if (typeof e != "string") return NaN;
|
|
1277
1280
|
let t = [...e.matchAll(/(\d+(?:\.\d+)?)([hms])/gi)];
|
|
1278
1281
|
return t.length === 0 ? NaN : t.reduce((e, t) => {
|
|
@@ -1288,37 +1291,37 @@ function Ar(e) {
|
|
|
1288
1291
|
}
|
|
1289
1292
|
//#endregion
|
|
1290
1293
|
//#region ../../libs/player-next/src/utils/timelineMarkers.ts
|
|
1291
|
-
var
|
|
1292
|
-
|
|
1293
|
-
},
|
|
1294
|
+
var Pr = fe.get().createContext("TimelineMarkers"), Fr = /^\d{4}-\d{2}-\d{2}[T ]\d{2}:\d{2}(:\d{2})?(\.\d+)?$/, Ir = (e) => {
|
|
1295
|
+
Pr.warn(`Timeline marker time "${e}" has no timezone and is interpreted in the viewer's local timezone, so it can land at a different position for viewers in other timezones. Provide an ISO 8601 time with an offset (e.g. "${e}Z") or epoch milliseconds.`);
|
|
1296
|
+
}, Lr = (e) => {
|
|
1294
1297
|
if (typeof e == "number" && Number.isFinite(e)) return e;
|
|
1295
1298
|
if (typeof e == "string") {
|
|
1296
1299
|
let t = Date.parse(e);
|
|
1297
|
-
return Number.isNaN(t) ? null : (
|
|
1300
|
+
return Number.isNaN(t) ? null : (Fr.test(e) && Ir(e), t);
|
|
1298
1301
|
}
|
|
1299
1302
|
if (e instanceof Date) {
|
|
1300
1303
|
let t = e.getTime();
|
|
1301
1304
|
return Number.isNaN(t) ? null : t;
|
|
1302
1305
|
}
|
|
1303
1306
|
return null;
|
|
1304
|
-
},
|
|
1307
|
+
}, Rr = (e) => {
|
|
1305
1308
|
if (typeof e != "object" || !e) return null;
|
|
1306
|
-
let { time: t, label: n, type: r } = e, i =
|
|
1309
|
+
let { time: t, label: n, type: r } = e, i = Lr(t);
|
|
1307
1310
|
if (i === null || typeof n != "string" || n.length === 0) return null;
|
|
1308
1311
|
let a = {
|
|
1309
1312
|
time: i,
|
|
1310
1313
|
label: n
|
|
1311
1314
|
};
|
|
1312
1315
|
return typeof r == "string" && r.length > 0 && (a.type = r), a;
|
|
1313
|
-
},
|
|
1316
|
+
}, zr = (e) => {
|
|
1314
1317
|
if (!Array.isArray(e)) return [];
|
|
1315
|
-
let t = e.map(
|
|
1316
|
-
return n > 0 &&
|
|
1317
|
-
},
|
|
1318
|
+
let t = e.map(Rr).filter((e) => e !== null), n = e.length - t.length;
|
|
1319
|
+
return n > 0 && Pr.warn(`Dropped ${n} invalid timeline marker(s). Each marker needs a non-empty "label" and a valid "time" (epoch milliseconds, a Date, or an ISO 8601 string).`), t;
|
|
1320
|
+
}, Br = (e) => e ? zr(le(e)) : [], Vr = (e, t, n) => {
|
|
1318
1321
|
if (!Number.isFinite(n) || n <= 0) return null;
|
|
1319
1322
|
let r = 1 - (t - e) / (n * 1e3);
|
|
1320
1323
|
return r < 0 || r > 1 ? null : r;
|
|
1321
|
-
},
|
|
1324
|
+
}, Hr = class extends pe {
|
|
1322
1325
|
constructor(t) {
|
|
1323
1326
|
if (super(), e(this, "audioContext", void 0), e(this, "audioNode", void 0), e(this, "bufferLength", void 0), e(this, "animationFrameId", null), e(this, "canUseFloatTimeDomainData", void 0), e(this, "byteSampleBuffer", null), e(this, "floatSampleBuffer", null), e(this, "leftAnalyser", void 0), e(this, "rightAnalyser", void 0), e(this, "mediaElementSource", null), e(this, "update", () => {
|
|
1324
1327
|
let e = this.getDecibel(this.leftAnalyser, this.floatSampleBuffer || this.byteSampleBuffer), t = this.getDecibel(this.rightAnalyser, this.floatSampleBuffer || this.byteSampleBuffer);
|
|
@@ -1370,18 +1373,18 @@ var jr = fe.get().createContext("TimelineMarkers"), Mr = /^\d{4}-\d{2}-\d{2}[T ]
|
|
|
1370
1373
|
get isMediaElementSource() {
|
|
1371
1374
|
return this.source instanceof HTMLMediaElement;
|
|
1372
1375
|
}
|
|
1373
|
-
}, j = /* @__PURE__ */ new WeakMap(), M = /* @__PURE__ */ new WeakMap(), N = /* @__PURE__ */ new WeakMap(),
|
|
1376
|
+
}, j = /* @__PURE__ */ new WeakMap(), M = /* @__PURE__ */ new WeakMap(), N = /* @__PURE__ */ new WeakMap(), Ur = /* @__PURE__ */ new WeakMap(), Wr = /* @__PURE__ */ new WeakMap(), Gr = /* @__PURE__ */ new WeakMap(), Kr = /* @__PURE__ */ new WeakMap(), qr = /* @__PURE__ */ new WeakMap(), Jr = /* @__PURE__ */ new WeakMap(), Yr = /* @__PURE__ */ new WeakMap(), Xr = /* @__PURE__ */ new WeakMap(), Zr = /* @__PURE__ */ new WeakMap(), P = /* @__PURE__ */ new WeakMap(), F = /* @__PURE__ */ new WeakSet(), Qr = /* @__PURE__ */ new WeakMap(), $r = /* @__PURE__ */ new WeakMap(), ei = /* @__PURE__ */ new WeakMap(), ti = /* @__PURE__ */ new WeakMap(), ni = class {
|
|
1374
1377
|
constructor(t, n) {
|
|
1375
|
-
S(this, F), f(this, j, void 0), f(this, M, void 0), f(this, N, void 0), f(this,
|
|
1376
|
-
h(j, this).readyState >= HTMLMediaElement.HAVE_CURRENT_DATA && !h(j, this).paused && m(F, this,
|
|
1377
|
-
}), f(this,
|
|
1378
|
-
h(j, this).readyState >= HTMLMediaElement.HAVE_FUTURE_DATA && m(F, this,
|
|
1379
|
-
}), p(M, this, t), p(
|
|
1378
|
+
S(this, F), f(this, j, void 0), f(this, M, void 0), f(this, N, void 0), f(this, Ur, void 0), f(this, Wr, void 0), e(this, "userPaused", !0), f(this, Gr, void 0), f(this, Kr, void 0), f(this, qr, !1), f(this, Jr, !1), f(this, Yr, null), f(this, Xr, 0), f(this, Zr, !1), f(this, P, fe.get().createContext("HlsPlayer")), f(this, Qr, () => m(F, this, hi).call(this, !0)), f(this, $r, () => m(F, this, hi).call(this, !1)), f(this, ei, () => {
|
|
1379
|
+
h(j, this).readyState >= HTMLMediaElement.HAVE_CURRENT_DATA && !h(j, this).paused && m(F, this, hi).call(this, !1);
|
|
1380
|
+
}), f(this, ti, () => {
|
|
1381
|
+
h(j, this).readyState >= HTMLMediaElement.HAVE_FUTURE_DATA && m(F, this, hi).call(this, !1);
|
|
1382
|
+
}), p(M, this, t), p(Kr, this, n == null ? void 0 : n.maxVideoBitRate), h(M, this).style.position = "absolute", h(M, this).style.top = "0", h(M, this).style.left = "0", h(M, this).style.width = "100%", h(M, this).style.height = "100%", h(M, this).style.opacity = "0", h(M, this).style.pointerEvents = "none", h(M, this).style.transition = "opacity 0.12s linear";
|
|
1380
1383
|
let r = document.createElement("video");
|
|
1381
|
-
p(j, this, r), t.appendChild(h(j, this)), h(j, this).style.width = "100%", h(j, this).style.height = "100%", h(j, this).setAttribute("playsinline", ""), h(j, this).setAttribute("webkit-playsinline", ""), h(j, this).setAttribute("preload", "metadata"), m(F, this,
|
|
1384
|
+
p(j, this, r), t.appendChild(h(j, this)), h(j, this).style.width = "100%", h(j, this).style.height = "100%", h(j, this).setAttribute("playsinline", ""), h(j, this).setAttribute("webkit-playsinline", ""), h(j, this).setAttribute("preload", "metadata"), m(F, this, pi).call(this), p(Zr, this, h(j, this).muted), (n == null ? void 0 : n.volume) !== void 0 && (this.volume = n.volume), (n == null ? void 0 : n.muted) !== void 0 && (this.muted = n.muted);
|
|
1382
1385
|
}
|
|
1383
1386
|
hide() {
|
|
1384
|
-
p(
|
|
1387
|
+
p(qr, this, !0), p(Jr, this, !1), h(M, this).classList.remove("active"), h(M, this).style.opacity = "0", h(M, this).style.pointerEvents = "none", p(Yr, this, null);
|
|
1385
1388
|
}
|
|
1386
1389
|
play() {
|
|
1387
1390
|
var e = this;
|
|
@@ -1397,17 +1400,17 @@ var jr = fe.get().createContext("TimelineMarkers"), Mr = /^\d{4}-\d{2}-\d{2}[T ]
|
|
|
1397
1400
|
var n = this;
|
|
1398
1401
|
return t(function* () {
|
|
1399
1402
|
if (h(P, n).debug("HlsPlayer seek to", e.time), !Number.isFinite(e.time)) {
|
|
1400
|
-
p(
|
|
1403
|
+
p(Yr, n, null);
|
|
1401
1404
|
return;
|
|
1402
1405
|
}
|
|
1403
|
-
if (p(
|
|
1404
|
-
else return m(F, n,
|
|
1406
|
+
if (p(Yr, n, e.time > .1 ? e.time : null), n.isActive() && h(N, n)) m(F, n, si).call(n, e.time);
|
|
1407
|
+
else return m(F, n, ci).call(n, e);
|
|
1405
1408
|
})();
|
|
1406
1409
|
}
|
|
1407
1410
|
shouldIgnoreTimeupdate() {
|
|
1408
|
-
if (h(
|
|
1411
|
+
if (h(Yr, this) == null) return !1;
|
|
1409
1412
|
let e = h(j, this).currentTime;
|
|
1410
|
-
return !Number.isFinite(e) || e <= .1 ? !0 : (p(
|
|
1413
|
+
return !Number.isFinite(e) || e <= .1 ? !0 : (p(Yr, this, null), !1);
|
|
1411
1414
|
}
|
|
1412
1415
|
isPipSupported() {
|
|
1413
1416
|
return "pictureInPictureEnabled" in document && !h(j, this).disablePictureInPicture;
|
|
@@ -1422,7 +1425,7 @@ var jr = fe.get().createContext("TimelineMarkers"), Mr = /^\d{4}-\d{2}-\d{2}[T ]
|
|
|
1422
1425
|
return h(M, this).style.opacity === "1" || h(M, this).classList.contains("active");
|
|
1423
1426
|
}
|
|
1424
1427
|
cleanup() {
|
|
1425
|
-
m(F, this,
|
|
1428
|
+
m(F, this, mi).call(this), m(F, this, oi).call(this), h(Gr, this) && (cancelAnimationFrame(h(Gr, this)), p(Gr, this, void 0)), p(Yr, this, null), h(j, this).remove();
|
|
1426
1429
|
}
|
|
1427
1430
|
addEventListener(e, t) {
|
|
1428
1431
|
h(j, this).addEventListener(e, t);
|
|
@@ -1434,7 +1437,7 @@ var jr = fe.get().createContext("TimelineMarkers"), Mr = /^\d{4}-\d{2}-\d{2}[T ]
|
|
|
1434
1437
|
return h(j, this).dispatchEvent(e);
|
|
1435
1438
|
}
|
|
1436
1439
|
setTimeshiftUrl(e) {
|
|
1437
|
-
h(
|
|
1440
|
+
h(Wr, this) !== e && (h(P, this).debug("HLSPlayer Setting timeshift URL to", e), p(Wr, this, e));
|
|
1438
1441
|
}
|
|
1439
1442
|
get videoElement() {
|
|
1440
1443
|
return h(j, this);
|
|
@@ -1452,10 +1455,10 @@ var jr = fe.get().createContext("TimelineMarkers"), Mr = /^\d{4}-\d{2}-\d{2}[T ]
|
|
|
1452
1455
|
return h(j, this).volume;
|
|
1453
1456
|
}
|
|
1454
1457
|
set muted(e) {
|
|
1455
|
-
p(
|
|
1458
|
+
p(Zr, this, e), h(j, this).muted = e;
|
|
1456
1459
|
}
|
|
1457
1460
|
get muted() {
|
|
1458
|
-
return h(
|
|
1461
|
+
return h(Zr, this);
|
|
1459
1462
|
}
|
|
1460
1463
|
set currentTime(e) {
|
|
1461
1464
|
h(j, this).currentTime = e;
|
|
@@ -1470,17 +1473,17 @@ var jr = fe.get().createContext("TimelineMarkers"), Mr = /^\d{4}-\d{2}-\d{2}[T ]
|
|
|
1470
1473
|
return h(j, this).duration;
|
|
1471
1474
|
}
|
|
1472
1475
|
get maxVideoBitRate() {
|
|
1473
|
-
return h(
|
|
1476
|
+
return h(Kr, this);
|
|
1474
1477
|
}
|
|
1475
1478
|
set maxVideoBitRate(e) {
|
|
1476
|
-
p(
|
|
1479
|
+
p(Kr, this, e), e !== void 0 && h(N, this) && m(F, this, ii).call(this, e);
|
|
1477
1480
|
}
|
|
1478
1481
|
};
|
|
1479
|
-
function
|
|
1482
|
+
function ri() {
|
|
1480
1483
|
var e = this;
|
|
1481
1484
|
return t(function* () {
|
|
1482
1485
|
let { default: t } = yield import("./Ct8GqCxq.js");
|
|
1483
|
-
if (p(
|
|
1486
|
+
if (p(Ur, e, t), !t.isSupported()) {
|
|
1484
1487
|
h(P, e).warn("HLS not supported");
|
|
1485
1488
|
return;
|
|
1486
1489
|
}
|
|
@@ -1504,17 +1507,17 @@ function ei() {
|
|
|
1504
1507
|
testBandwidth: !1,
|
|
1505
1508
|
debug: !1
|
|
1506
1509
|
})), h(N, e).attachMedia(h(j, e)), h(N, e).on(t.Events.MEDIA_ATTACHED, () => h(P, e).debug("[HLS] media attached")), h(N, e).on(t.Events.MANIFEST_PARSED, () => h(P, e).debug("[HLS] manifest parsed")), h(N, e).on(t.Events.ERROR, (t, n) => {
|
|
1507
|
-
h(P, e).error("[HLS] error:", n), n.fatal && m(F, e,
|
|
1510
|
+
h(P, e).error("[HLS] error:", n), n.fatal && m(F, e, ai).call(e, n);
|
|
1508
1511
|
}), h(N, e).on(t.Events.MANIFEST_PARSED, () => {
|
|
1509
1512
|
var t;
|
|
1510
|
-
!h(
|
|
1513
|
+
!h(Kr, e) || ((t = h(N, e)) == null ? void 0 : t.levels.length) === 0 || m(F, e, ii).call(e, h(Kr, e));
|
|
1511
1514
|
}), h(N, e).on(t.Events.LEVEL_SWITCHED, () => {
|
|
1512
1515
|
var t, n;
|
|
1513
1516
|
h(P, e).debug("Level switched:", (t = h(N, e)) == null ? void 0 : t.currentLevel, "max:", e.maxVideoBitRate, "autoLevelCapping:", (n = h(N, e)) == null ? void 0 : n.autoLevelCapping);
|
|
1514
1517
|
});
|
|
1515
1518
|
})();
|
|
1516
1519
|
}
|
|
1517
|
-
function
|
|
1520
|
+
function ii(e) {
|
|
1518
1521
|
if (!h(N, this)) {
|
|
1519
1522
|
h(P, this).warn("HLS not initialized, cannot set bitrate cap");
|
|
1520
1523
|
return;
|
|
@@ -1530,12 +1533,12 @@ function ti(e) {
|
|
|
1530
1533
|
let r = h(N, this).currentLevel;
|
|
1531
1534
|
h(N, this).autoLevelCapping = t, r !== t && (h(P, this).debug(`Current level ${r} exceeds cap ${t}, forcing immediate switch`), h(N, this).currentLevel = t);
|
|
1532
1535
|
}
|
|
1533
|
-
function
|
|
1534
|
-
if (!h(
|
|
1536
|
+
function ai(e) {
|
|
1537
|
+
if (!h(Ur, this)) {
|
|
1535
1538
|
h(P, this).error("Hls class not available for error handling");
|
|
1536
1539
|
return;
|
|
1537
1540
|
}
|
|
1538
|
-
let t = h(
|
|
1541
|
+
let t = h(Ur, this);
|
|
1539
1542
|
switch (e.type) {
|
|
1540
1543
|
case t.ErrorTypes.NETWORK_ERROR:
|
|
1541
1544
|
var n;
|
|
@@ -1546,39 +1549,39 @@ function ni(e) {
|
|
|
1546
1549
|
h(P, this).warn("[HLS] media error -> recoverMediaError"), (r = h(N, this)) == null || r.recoverMediaError();
|
|
1547
1550
|
break;
|
|
1548
1551
|
default:
|
|
1549
|
-
h(P, this).error("[HLS] fatal -> destroy"), m(F, this,
|
|
1552
|
+
h(P, this).error("[HLS] fatal -> destroy"), m(F, this, oi).call(this);
|
|
1550
1553
|
break;
|
|
1551
1554
|
}
|
|
1552
1555
|
}
|
|
1553
|
-
function
|
|
1556
|
+
function oi() {
|
|
1554
1557
|
h(N, this) && (h(N, this).destroy(), p(N, this, void 0));
|
|
1555
1558
|
}
|
|
1556
|
-
function
|
|
1559
|
+
function si(e) {
|
|
1557
1560
|
if (!Number.isFinite(e)) {
|
|
1558
|
-
p(
|
|
1561
|
+
p(Yr, this, null);
|
|
1559
1562
|
return;
|
|
1560
1563
|
}
|
|
1561
|
-
let t = m(F, this,
|
|
1562
|
-
p(
|
|
1564
|
+
let t = m(F, this, fi).call(this, h(j, this), e);
|
|
1565
|
+
p(Yr, this, t > .1 ? t : null), h(Gr, this) && cancelAnimationFrame(h(Gr, this)), p(Gr, this, requestAnimationFrame(() => {
|
|
1563
1566
|
h(j, this).currentTime = t;
|
|
1564
1567
|
}));
|
|
1565
1568
|
}
|
|
1566
|
-
function
|
|
1569
|
+
function ci(e) {
|
|
1567
1570
|
var n = this;
|
|
1568
1571
|
return t(function* () {
|
|
1569
1572
|
var t;
|
|
1570
|
-
let { time: r, playWhenReady: i = !0 } = e || {}, a = p(
|
|
1571
|
-
if (!h(
|
|
1573
|
+
let { time: r, playWhenReady: i = !0 } = e || {}, a = p(Xr, n, (t = h(Xr, n), ++t));
|
|
1574
|
+
if (!h(Wr, n)) {
|
|
1572
1575
|
h(P, n).warn("No timeshift URL");
|
|
1573
1576
|
return;
|
|
1574
1577
|
}
|
|
1575
|
-
if (!h(N, n) && (yield m(F, n,
|
|
1576
|
-
p(
|
|
1578
|
+
if (!h(N, n) && (yield m(F, n, ri).call(n), !m(F, n, gi).call(n, a))) return;
|
|
1579
|
+
p(qr, n, !1), p(Jr, n, !1), h(N, n) && (!h(N, n).url || h(N, n).url !== h(Wr, n)) && (h(P, n).debug("Loading timeshift URL", h(Wr, n)), h(N, n).loadSource(h(Wr, n)));
|
|
1577
1580
|
let o = n.muted;
|
|
1578
|
-
h(j, n).muted = !0, yield m(F, n,
|
|
1581
|
+
h(j, n).muted = !0, yield m(F, n, li).call(n), m(F, n, gi).call(n, a) && (m(F, n, si).call(n, r), !(i && (yield n.play(), !m(F, n, gi).call(n, a))) && m(F, n, ui).call(n, o, a));
|
|
1579
1582
|
})();
|
|
1580
1583
|
}
|
|
1581
|
-
function
|
|
1584
|
+
function li() {
|
|
1582
1585
|
return h(j, this).duration && !Number.isNaN(h(j, this).duration) ? Promise.resolve() : new Promise((e) => {
|
|
1583
1586
|
h(P, this).debug("Waiting for duration...");
|
|
1584
1587
|
let t = () => {
|
|
@@ -1589,11 +1592,11 @@ function oi() {
|
|
|
1589
1592
|
h(j, this).addEventListener("loadedmetadata", t);
|
|
1590
1593
|
});
|
|
1591
1594
|
}
|
|
1592
|
-
function
|
|
1595
|
+
function ui(e, t) {
|
|
1593
1596
|
let n = HTMLMediaElement.HAVE_CURRENT_DATA, r = () => h(j, this).readyState >= n && h(j, this).videoWidth > 0 && h(j, this).videoHeight > 0, i = () => {
|
|
1594
|
-
h(
|
|
1597
|
+
h(qr, this) || h(Jr, this) || !m(F, this, gi).call(this, t) || (p(Jr, this, !0), h(P, this).debug("Revealing timeshift video"), h(M, this).classList.add("active"), h(M, this).style.opacity = "1", h(M, this).style.pointerEvents = "auto", h(j, this).dispatchEvent(new CustomEvent("timeshiftready", { detail: { activationId: t } })), e || m(F, this, di).call(this, t));
|
|
1595
1598
|
}, a = () => {
|
|
1596
|
-
h(
|
|
1599
|
+
h(qr, this) || h(Jr, this) || !m(F, this, gi).call(this, t) || r() && (s(), i());
|
|
1597
1600
|
}, o = !1, s = () => {
|
|
1598
1601
|
o || (o = !0, h(j, this).removeEventListener("canplay", a), h(j, this).removeEventListener("canplaythrough", a), h(j, this).removeEventListener("loadeddata", a), clearTimeout(c));
|
|
1599
1602
|
};
|
|
@@ -1606,9 +1609,9 @@ function si(e, t) {
|
|
|
1606
1609
|
h(P, this).debug("Timeout reached, forcing reveal"), s(), i();
|
|
1607
1610
|
}, 2e3);
|
|
1608
1611
|
}
|
|
1609
|
-
function
|
|
1612
|
+
function di(e) {
|
|
1610
1613
|
let t = () => {
|
|
1611
|
-
m(F, this,
|
|
1614
|
+
m(F, this, gi).call(this, e) && (h(j, this).muted = !1);
|
|
1612
1615
|
};
|
|
1613
1616
|
"requestVideoFrameCallback" in h(j, this) ? h(j, this).requestVideoFrameCallback(() => {
|
|
1614
1617
|
setTimeout(() => {
|
|
@@ -1618,43 +1621,43 @@ function ci(e) {
|
|
|
1618
1621
|
t();
|
|
1619
1622
|
}, 120);
|
|
1620
1623
|
}
|
|
1621
|
-
function
|
|
1624
|
+
function fi(e, t) {
|
|
1622
1625
|
let n = e.seekable;
|
|
1623
1626
|
if (!n || n.length === 0) return t;
|
|
1624
1627
|
let r = n.start(0), i = n.end(n.length - 1);
|
|
1625
1628
|
return h(P, this).debug("Clamped seekable:", Math.max(r, Math.min(t, i))), Math.max(r, Math.min(t, i));
|
|
1626
1629
|
}
|
|
1627
|
-
function
|
|
1628
|
-
for (let e of
|
|
1629
|
-
for (let e of
|
|
1630
|
-
h(j, this).addEventListener("timeupdate", h(
|
|
1630
|
+
function pi() {
|
|
1631
|
+
for (let e of _i._) h(j, this).addEventListener(e, h(Qr, this));
|
|
1632
|
+
for (let e of vi._) h(j, this).addEventListener(e, h($r, this));
|
|
1633
|
+
h(j, this).addEventListener("timeupdate", h(ei, this)), h(j, this).addEventListener("progress", h(ti, this));
|
|
1631
1634
|
}
|
|
1632
|
-
function
|
|
1633
|
-
for (let e of
|
|
1634
|
-
for (let e of
|
|
1635
|
-
h(j, this).removeEventListener("timeupdate", h(
|
|
1635
|
+
function mi() {
|
|
1636
|
+
for (let e of _i._) h(j, this).removeEventListener(e, h(Qr, this));
|
|
1637
|
+
for (let e of vi._) h(j, this).removeEventListener(e, h($r, this));
|
|
1638
|
+
h(j, this).removeEventListener("timeupdate", h(ei, this)), h(j, this).removeEventListener("progress", h(ti, this));
|
|
1636
1639
|
}
|
|
1637
|
-
function
|
|
1640
|
+
function hi(e) {
|
|
1638
1641
|
let t = e && (h(j, this).readyState < HTMLMediaElement.HAVE_FUTURE_DATA || h(j, this).seeking || h(j, this).paused && !this.userPaused);
|
|
1639
1642
|
h(j, this).dispatchEvent(new CustomEvent(t ? "hlsbuffering" : "hlsnotbuffering", {
|
|
1640
1643
|
bubbles: !0,
|
|
1641
1644
|
composed: !0
|
|
1642
1645
|
}));
|
|
1643
1646
|
}
|
|
1644
|
-
function
|
|
1645
|
-
return h(
|
|
1647
|
+
function gi(e) {
|
|
1648
|
+
return h(Xr, this) === e;
|
|
1646
1649
|
}
|
|
1647
|
-
var
|
|
1650
|
+
var _i = { _: [
|
|
1648
1651
|
"waiting",
|
|
1649
1652
|
"seeking",
|
|
1650
1653
|
"stalled",
|
|
1651
1654
|
"loadstart"
|
|
1652
|
-
] },
|
|
1655
|
+
] }, vi = { _: [
|
|
1653
1656
|
"canplay",
|
|
1654
1657
|
"canplaythrough",
|
|
1655
1658
|
"seeked",
|
|
1656
1659
|
"loadeddata"
|
|
1657
|
-
] },
|
|
1660
|
+
] }, yi = class {
|
|
1658
1661
|
constructor(e) {
|
|
1659
1662
|
this.vindral = e;
|
|
1660
1663
|
}
|
|
@@ -1674,19 +1677,19 @@ var mi = { _: [
|
|
|
1674
1677
|
pause() {
|
|
1675
1678
|
this.vindral.pause();
|
|
1676
1679
|
}
|
|
1677
|
-
},
|
|
1678
|
-
|
|
1679
|
-
var
|
|
1680
|
+
}, bi = document.createElement("template");
|
|
1681
|
+
bi.innerHTML = "\n <style>\n :host {\n --value: 0;\n --range-thickness: var(--vindral-range-thickness, 4px);\n --range-hover-thickness: var(--vindral-range-hover-thickness, var(--range-thickness));\n --range-thumb-size: var(--vindral-range-thumb-size, 12px);\n --range-thumb-hover-size: var(--vindral-range-thumb-hover-size, var(--range-thumb-size));\n --range-fill-color: var(--vindral-range-fill-color, var(--fg-strong));\n --range-thumb-color: var(--vindral-range-thumb-color, var(--fg-strong));\n --_focus-box-shadow: none;\n height: calc(var(--button-icon-size) + 2 * var(--button-padding));\n width: 100%;\n display: flex;\n align-items: center;\n justify-content: center;\n padding: 0 !important;\n margin: 0;\n position: relative;\n cursor: pointer;\n touch-action: none;\n box-shadow: var(--_focus-visible-box-shadow, none);\n outline: 0;\n background: transparent;\n }\n\n :host > * {\n transition-timing-function: cubic-bezier(0.4, 0, 1, 1);\n transition-duration: 0.1s;\n }\n\n #range {\n -webkit-appearance: none;\n appearance: none;\n\n position: absolute;\n top: 0;\n left: 0;\n height: 100%;\n width: 100%;\n margin: 0;\n padding: 0;\n\n background-color: #00000000;\n outline: none;\n z-index: 1;\n cursor: pointer;\n }\n\n #range-track {\n position: absolute;\n top: calc(50% - calc(var(--range-thickness) / 2));\n left: 1px;\n width: calc(100% - 2px);\n height: var(--range-thickness);\n background-color: rgb(255 255 255 / 0.2);\n overflow: hidden;\n cursor: pointer;\n transition-property: height, top;\n }\n\n @media (hover: hover) and (pointer: fine) {\n :host(:hover) #range-track {\n height: var(--range-hover-thickness);\n top: calc(50% - calc(var(--range-hover-thickness) / 2));\n }\n }\n\n #range-track::before {\n position: absolute;\n content: \"\";\n left: calc(-100%);\n top: 0;\n width: calc(100%);\n height: 100%;\n background: var(--range-fill-color);\n transition: background-color 300ms ease-out;\n transform-origin: 100% 0%;\n transform: translateX(calc(var(--value) * 100%)) scaleX(1.2);\n }\n\n #range::-webkit-slider-runnable-track {\n background: transparent;\n }\n\n #range::-moz-range-track {\n background: transparent;\n }\n\n #range::-webkit-slider-thumb {\n -webkit-appearance: none;\n appearance: none;\n width: var(--range-thumb-size);\n height: var(--range-thumb-size);\n border-radius: 50%;\n background: var(--range-thumb-color);\n cursor: pointer;\n z-index: 1;\n transition-property: width, height;\n transition-timing-function: cubic-bezier(0.4, 0, 1, 1);\n transition-duration: 0.1s;\n }\n\n #range::-moz-range-thumb {\n -moz-appearance: none;\n appearance: none;\n width: var(--range-thumb-size);\n height: var(--range-thumb-size);\n border-radius: 50%;\n background: var(--range-thumb-color);\n cursor: pointer;\n z-index: 1;\n border: none;\n transition-property: width, height;\n transition-timing-function: cubic-bezier(0.4, 0, 1, 1);\n transition-duration: 0.1s;\n }\n\n :host:has(#range:focus-visible) {\n box-shadow: inset 0 0 0 2px var(--fg-strong);\n }\n\n @media (hover: hover) and (pointer: fine) {\n :host(:hover) #range::-webkit-slider-thumb {\n width: var(--range-thumb-hover-size);\n height: var(--range-thumb-hover-size);\n }\n\n :host(:hover) #range::-moz-range-thumb {\n width: var(--range-thumb-hover-size);\n height: var(--range-thumb-hover-size);\n }\n }\n </style>\n\n <input type=\"range\" id=\"range\" min=\"0\" max=\"1\" step=\"any\" value=\"0\" />\n <div id=\"range-track\"></div>\n";
|
|
1682
|
+
var xi = /* @__PURE__ */ new WeakMap(), Si = /* @__PURE__ */ new WeakMap(), Ci = class extends HTMLElement {
|
|
1680
1683
|
constructor() {
|
|
1681
|
-
super(), f(this,
|
|
1684
|
+
super(), f(this, xi, null), f(this, Si, void 0), e(this, "range", void 0), p(Si, this, this.attachShadow({ mode: "open" })), h(Si, this).appendChild(bi.content.cloneNode(!0)), this.range = h(Si, this).getElementById("range");
|
|
1682
1685
|
}
|
|
1683
1686
|
connectedCallback() {
|
|
1684
1687
|
var e;
|
|
1685
|
-
p(
|
|
1688
|
+
p(xi, this, this.closest("vindral-controller")), (e = h(xi, this)) == null || e.connectListener(this), this.hasAttribute("disabled") || this.enable();
|
|
1686
1689
|
}
|
|
1687
1690
|
disconnectedCallback() {
|
|
1688
1691
|
var e;
|
|
1689
|
-
(e = h(
|
|
1692
|
+
(e = h(xi, this)) == null || e.disconnectListener(this);
|
|
1690
1693
|
}
|
|
1691
1694
|
attributeChangedCallback(e, t, n) {
|
|
1692
1695
|
t !== n && (e === "disabled" && n ? this.disable() : this.enable(), this.updateBar());
|
|
@@ -1712,11 +1715,11 @@ var vi = /* @__PURE__ */ new WeakMap(), yi = /* @__PURE__ */ new WeakMap(), bi =
|
|
|
1712
1715
|
];
|
|
1713
1716
|
}
|
|
1714
1717
|
};
|
|
1715
|
-
e(
|
|
1718
|
+
e(Ci, "observedAttributes", ["disabled"]);
|
|
1716
1719
|
//#endregion
|
|
1717
1720
|
//#region ../../libs/player-next/src/components/Controller.ts
|
|
1718
|
-
var
|
|
1719
|
-
|
|
1721
|
+
var wi = document.createElement("template");
|
|
1722
|
+
wi.innerHTML = `
|
|
1720
1723
|
<style>
|
|
1721
1724
|
:host {
|
|
1722
1725
|
--fg-strong: var(--vindral-fg-strong, #eeeeee);
|
|
@@ -1929,7 +1932,7 @@ xi.innerHTML = `
|
|
|
1929
1932
|
<slot id="overlay-interactive" name="overlay-interactive"></slot>
|
|
1930
1933
|
</div>
|
|
1931
1934
|
`;
|
|
1932
|
-
var
|
|
1935
|
+
var Ti = [
|
|
1933
1936
|
"ArrowDown",
|
|
1934
1937
|
"ArrowLeft",
|
|
1935
1938
|
"ArrowRight",
|
|
@@ -1938,27 +1941,27 @@ var Si = [
|
|
|
1938
1941
|
" ",
|
|
1939
1942
|
"f",
|
|
1940
1943
|
"m"
|
|
1941
|
-
],
|
|
1944
|
+
], Ei = /* @__PURE__ */ new WeakMap(), Di = /* @__PURE__ */ new WeakMap(), Oi = /* @__PURE__ */ new WeakMap(), ki = /* @__PURE__ */ new WeakMap(), Ai = /* @__PURE__ */ new WeakMap(), ji = /* @__PURE__ */ new WeakMap(), I = /* @__PURE__ */ new WeakMap(), L = /* @__PURE__ */ new WeakMap(), Mi = /* @__PURE__ */ new WeakMap(), R = /* @__PURE__ */ new WeakMap(), Ni = /* @__PURE__ */ new WeakMap(), Pi = /* @__PURE__ */ new WeakMap(), Fi = /* @__PURE__ */ new WeakMap(), Ii = /* @__PURE__ */ new WeakMap(), Li = /* @__PURE__ */ new WeakMap(), z = /* @__PURE__ */ new WeakMap(), Ri = /* @__PURE__ */ new WeakMap(), zi = /* @__PURE__ */ new WeakMap(), Bi = /* @__PURE__ */ new WeakMap(), B = /* @__PURE__ */ new WeakMap(), Vi = /* @__PURE__ */ new WeakMap(), Hi = /* @__PURE__ */ new WeakMap(), Ui = /* @__PURE__ */ new WeakMap(), V = /* @__PURE__ */ new WeakMap(), Wi = /* @__PURE__ */ new WeakMap(), Gi = /* @__PURE__ */ new WeakMap(), Ki = /* @__PURE__ */ new WeakMap(), qi = /* @__PURE__ */ new WeakMap(), H = /* @__PURE__ */ new WeakSet(), Ji = /* @__PURE__ */ new WeakMap(), Yi = /* @__PURE__ */ new WeakMap(), Xi = /* @__PURE__ */ new WeakMap(), Zi = /* @__PURE__ */ new WeakMap(), Qi = /* @__PURE__ */ new WeakMap(), $i = /* @__PURE__ */ new WeakMap(), ea = /* @__PURE__ */ new WeakMap(), ta = /* @__PURE__ */ new WeakMap(), na = /* @__PURE__ */ new WeakMap(), ra = /* @__PURE__ */ new WeakMap(), ia = /* @__PURE__ */ new WeakMap(), aa = /* @__PURE__ */ new WeakMap(), oa = /* @__PURE__ */ new WeakMap(), sa = /* @__PURE__ */ new WeakMap(), ca = /* @__PURE__ */ new WeakMap(), la = /* @__PURE__ */ new WeakMap(), ua = /* @__PURE__ */ new WeakMap(), da = /* @__PURE__ */ new WeakMap(), fa = /* @__PURE__ */ new WeakMap(), pa = /* @__PURE__ */ new WeakMap(), ma = /* @__PURE__ */ new WeakMap(), ha = /* @__PURE__ */ new WeakMap(), ga = /* @__PURE__ */ new WeakMap(), _a = /* @__PURE__ */ new WeakMap(), va = /* @__PURE__ */ new WeakMap(), ya = /* @__PURE__ */ new WeakMap(), ba = /* @__PURE__ */ new WeakMap(), xa = /* @__PURE__ */ new WeakMap(), Sa = /* @__PURE__ */ new WeakMap(), Ca = /* @__PURE__ */ new WeakMap(), wa = /* @__PURE__ */ new WeakMap(), Ta = /* @__PURE__ */ new WeakMap(), Ea = /* @__PURE__ */ new WeakMap(), Da = /* @__PURE__ */ new WeakMap(), Oa = class extends HTMLElement {
|
|
1942
1945
|
constructor() {
|
|
1943
1946
|
var t;
|
|
1944
|
-
super(), S(this, H), f(this,
|
|
1947
|
+
super(), S(this, H), f(this, Ei, /* @__PURE__ */ new Map()), f(this, Di, 2e3), f(this, Oi, null), f(this, ki, new Dr({ onChange: (e) => m(H, this, U).call(this, g.DURATION, e.toString()) })), f(this, Ai, null), f(this, ji, void 0), f(this, I, void 0), f(this, L, void 0), f(this, Mi, void 0), f(this, R, void 0), f(this, Ni, we), f(this, Pi, void 0), f(this, Fi, void 0), f(this, Ii, void 0), f(this, Li, void 0), f(this, z, void 0), f(this, Ri, void 0), f(this, zi, void 0), f(this, Bi, void 0), f(this, B, void 0), f(this, Vi, void 0), f(this, Hi, void 0), f(this, Ui, void 0), f(this, V, void 0), f(this, Wi, null), f(this, Gi, !1), f(this, Ki, null), f(this, qi, void 0), f(this, Ji, (e) => {
|
|
1945
1948
|
let t = e.filter((e) => {
|
|
1946
1949
|
var t;
|
|
1947
1950
|
return (t = e.video) == null ? void 0 : t.width;
|
|
1948
1951
|
});
|
|
1949
1952
|
m(H, this, U).call(this, g.RENDITION_LEVELS, JSON.stringify(t));
|
|
1950
|
-
}), f(this,
|
|
1953
|
+
}), f(this, Yi, (e) => {
|
|
1951
1954
|
m(H, this, U).call(this, g.RENDITION_LEVEL, JSON.stringify(e));
|
|
1952
|
-
}), f(this,
|
|
1953
|
-
let t = h(
|
|
1954
|
-
p(
|
|
1955
|
+
}), f(this, Xi, !1), f(this, Zi, (e) => {
|
|
1956
|
+
let t = h(Xi, this);
|
|
1957
|
+
p(Xi, this, !0);
|
|
1955
1958
|
try {
|
|
1956
1959
|
e();
|
|
1957
1960
|
} finally {
|
|
1958
|
-
p(
|
|
1961
|
+
p(Xi, this, t);
|
|
1959
1962
|
}
|
|
1960
|
-
}), f(this,
|
|
1961
|
-
h(
|
|
1963
|
+
}), f(this, Qi, (e) => {
|
|
1964
|
+
h(Zi, this).call(this, () => {
|
|
1962
1965
|
switch (e) {
|
|
1963
1966
|
case "playing":
|
|
1964
1967
|
m(H, this, W).call(this, g.PAUSED), m(H, this, W).call(this, g.BUFFERING);
|
|
@@ -1972,40 +1975,40 @@ var Si = [
|
|
|
1972
1975
|
default: break;
|
|
1973
1976
|
}
|
|
1974
1977
|
});
|
|
1975
|
-
}), f(this,
|
|
1976
|
-
h(
|
|
1978
|
+
}), f(this, $i, (e) => {
|
|
1979
|
+
h(Zi, this).call(this, () => {
|
|
1977
1980
|
m(H, this, U).call(this, g.VOLUME, e.volume.toString()), e.isMuted ? m(H, this, U).call(this, g.MUTED, "") : m(H, this, W).call(this, g.MUTED);
|
|
1978
1981
|
});
|
|
1979
|
-
}), f(this,
|
|
1982
|
+
}), f(this, ea, ({ channelId: e }) => {
|
|
1980
1983
|
var t;
|
|
1981
1984
|
this.setAttribute(g.CHANNEL_ID, e), ((t = h(I, this)) == null ? void 0 : t.playbackState) !== "buffering" && m(H, this, W).call(this, g.BUFFERING);
|
|
1982
|
-
}), f(this,
|
|
1985
|
+
}), f(this, ta, ({ channelId: e }) => {
|
|
1983
1986
|
var t;
|
|
1984
|
-
h(
|
|
1985
|
-
}), f(this,
|
|
1986
|
-
p(
|
|
1987
|
-
}), f(this,
|
|
1987
|
+
h(Pi, this) !== e && this.setAttribute(g.CHANNEL_ID, e), ((t = h(I, this)) == null ? void 0 : t.playbackState) !== "buffering" && m(H, this, W).call(this, g.BUFFERING);
|
|
1988
|
+
}), f(this, na, (e) => {
|
|
1989
|
+
p(wa, this, Date.now()), m(H, this, U).call(this, g.CHANNELS, JSON.stringify(e));
|
|
1990
|
+
}), f(this, ra, (e) => {
|
|
1988
1991
|
var t;
|
|
1989
1992
|
m(H, this, U).call(this, g.LANGUAGES, JSON.stringify(e)), (t = h(I, this)) != null && t.language && m(H, this, U).call(this, g.LANGUAGE, h(I, this).language);
|
|
1990
|
-
}), f(this,
|
|
1993
|
+
}), f(this, ia, (e) => {
|
|
1991
1994
|
var t;
|
|
1992
1995
|
if (m(H, this, U).call(this, g.TEXT_TRACKS, JSON.stringify(e)), (t = h(I, this)) != null && t.textTrack) {
|
|
1993
1996
|
var n, r;
|
|
1994
1997
|
m(H, this, U).call(this, g.TEXT_TRACK, (n = (r = h(I, this)) == null ? void 0 : r.textTrack) == null ? "" : n);
|
|
1995
1998
|
}
|
|
1996
|
-
}), f(this,
|
|
1999
|
+
}), f(this, aa, (e) => {
|
|
1997
2000
|
e != null && e.forVideo ? (m(H, this, U).call(this, g.NEEDS_USER_INPUT_VIDEO, ""), m(H, this, W).call(this, g.NEEDS_USER_INPUT_AUDIO)) : e != null && e.forAudio && (m(H, this, U).call(this, g.NEEDS_USER_INPUT_AUDIO, ""), m(H, this, W).call(this, g.NEEDS_USER_INPUT_VIDEO));
|
|
1998
|
-
}), f(this,
|
|
1999
|
-
e || m(H, this, W).call(this, g.BUFFERING), h(
|
|
2000
|
-
}), f(this,
|
|
2001
|
+
}), f(this, oa, (e) => {
|
|
2002
|
+
e || m(H, this, W).call(this, g.BUFFERING), h(ki, this).setLive(e);
|
|
2003
|
+
}), f(this, sa, (e) => {
|
|
2001
2004
|
var t, n;
|
|
2002
2005
|
let { urls: r, duration: i } = e;
|
|
2003
2006
|
if (!r[0] || !h(R, this)) return;
|
|
2004
2007
|
let a = new URL(r[0]);
|
|
2005
|
-
a.searchParams.set("channelId", (t = h(
|
|
2008
|
+
a.searchParams.set("channelId", (t = h(Pi, this)) == null ? "" : t);
|
|
2006
2009
|
let o = this.getAttribute("authentication-token");
|
|
2007
2010
|
o && a.searchParams.set("authToken", o);
|
|
2008
|
-
let s =
|
|
2011
|
+
let s = Nr(i);
|
|
2009
2012
|
if (Number.isNaN(s)) {
|
|
2010
2013
|
h(V, this).error(`Invalid duration format: ${i}`);
|
|
2011
2014
|
return;
|
|
@@ -2013,70 +2016,70 @@ var Si = [
|
|
|
2013
2016
|
let c = Math.floor(Date.now() / 1e3), l = (/* @__PURE__ */ new Date((c - s) * 1e3)).toISOString();
|
|
2014
2017
|
a.searchParams.set("from", l);
|
|
2015
2018
|
let u = a.toString();
|
|
2016
|
-
h(R, this).setTimeshiftUrl(u), h(
|
|
2019
|
+
h(R, this).setTimeshiftUrl(u), h(ki, this).start({
|
|
2017
2020
|
multivariantUrl: u,
|
|
2018
2021
|
params: {
|
|
2019
|
-
channelId: (n = h(
|
|
2022
|
+
channelId: (n = h(Pi, this)) == null ? "" : n,
|
|
2020
2023
|
authToken: o == null ? void 0 : o,
|
|
2021
2024
|
from: l
|
|
2022
2025
|
},
|
|
2023
2026
|
windowCapSeconds: s
|
|
2024
2027
|
});
|
|
2025
|
-
}), f(this, aa, () => {
|
|
2026
|
-
m(H, this, W).call(this, g.PAUSED), m(H, this, W).call(this, g.BUFFERING);
|
|
2027
|
-
}), f(this, oa, () => {
|
|
2028
|
-
m(H, this, U).call(this, g.PAUSED, ""), m(H, this, W).call(this, g.BUFFERING);
|
|
2029
|
-
}), f(this, sa, () => {
|
|
2030
|
-
h(va, this).call(this), m(H, this, W).call(this, g.BUFFERING);
|
|
2031
2028
|
}), f(this, ca, () => {
|
|
2032
|
-
|
|
2029
|
+
m(H, this, W).call(this, g.PAUSED), m(H, this, W).call(this, g.BUFFERING);
|
|
2033
2030
|
}), f(this, la, () => {
|
|
2031
|
+
m(H, this, U).call(this, g.PAUSED, ""), m(H, this, W).call(this, g.BUFFERING);
|
|
2032
|
+
}), f(this, ua, () => {
|
|
2033
|
+
h(xa, this).call(this), m(H, this, W).call(this, g.BUFFERING);
|
|
2034
|
+
}), f(this, da, () => {
|
|
2035
|
+
h(R, this) && h(ki, this).applyLoadedDuration(h(R, this).duration);
|
|
2036
|
+
}), f(this, fa, () => {
|
|
2034
2037
|
var e, t;
|
|
2035
2038
|
if (!h(R, this) || h(R, this).seeking || (e = (t = h(R, this)).shouldIgnoreTimeupdate) != null && e.call(t)) return;
|
|
2036
2039
|
let n = h(R, this).currentTime;
|
|
2037
2040
|
n !== void 0 && m(H, this, U).call(this, g.TIMESHIFT_POSITION, n.toString());
|
|
2038
|
-
}), f(this,
|
|
2041
|
+
}), f(this, pa, () => {
|
|
2039
2042
|
h(R, this) && (m(H, this, U).call(this, g.VOLUME, h(R, this).volume.toString()), h(R, this).muted ? m(H, this, U).call(this, g.MUTED, "") : m(H, this, W).call(this, g.MUTED));
|
|
2040
|
-
}), f(this,
|
|
2043
|
+
}), f(this, ma, () => {
|
|
2041
2044
|
m(H, this, U).call(this, g.BUFFERING, "");
|
|
2042
|
-
}), f(this,
|
|
2045
|
+
}), f(this, ha, () => {
|
|
2043
2046
|
m(H, this, W).call(this, g.BUFFERING);
|
|
2044
|
-
}), f(this,
|
|
2045
|
-
if (h(
|
|
2047
|
+
}), f(this, ga, () => {
|
|
2048
|
+
if (h(Gi, this)) {
|
|
2046
2049
|
if (h(L, this) !== h(R, this)) {
|
|
2047
|
-
p(
|
|
2050
|
+
p(Gi, this, !1);
|
|
2048
2051
|
return;
|
|
2049
2052
|
}
|
|
2050
|
-
p(
|
|
2053
|
+
p(Gi, this, !1), m(H, this, oo).call(this);
|
|
2051
2054
|
}
|
|
2052
|
-
}), f(this,
|
|
2055
|
+
}), f(this, _a, 0), e(this, "handleEvent", (e) => {
|
|
2053
2056
|
switch (e.type) {
|
|
2054
2057
|
case "pointerdown":
|
|
2055
|
-
p(
|
|
2058
|
+
p(_a, this, e.timeStamp);
|
|
2056
2059
|
break;
|
|
2057
2060
|
case "pointermove":
|
|
2058
|
-
m(H, this,
|
|
2061
|
+
m(H, this, Ya).call(this, e);
|
|
2059
2062
|
break;
|
|
2060
2063
|
case "pointerup":
|
|
2061
|
-
m(H, this,
|
|
2064
|
+
m(H, this, Xa).call(this, e);
|
|
2062
2065
|
break;
|
|
2063
2066
|
case "mouseleave":
|
|
2064
|
-
m(H, this,
|
|
2067
|
+
m(H, this, io).call(this);
|
|
2065
2068
|
break;
|
|
2066
2069
|
case "dblclick":
|
|
2067
|
-
m(H, this,
|
|
2070
|
+
m(H, this, Qa).call(this, e);
|
|
2068
2071
|
break;
|
|
2069
2072
|
case "mousemove":
|
|
2070
|
-
m(H, this,
|
|
2073
|
+
m(H, this, $a).call(this, e);
|
|
2071
2074
|
break;
|
|
2072
2075
|
case "keydown":
|
|
2073
|
-
h(
|
|
2076
|
+
h(ba, this).call(this, e);
|
|
2074
2077
|
break;
|
|
2075
2078
|
case "keyup":
|
|
2076
|
-
m(H, this,
|
|
2079
|
+
m(H, this, io).call(this), h(ya, this).call(this, e);
|
|
2077
2080
|
break;
|
|
2078
2081
|
}
|
|
2079
|
-
}), f(this,
|
|
2082
|
+
}), f(this, va, (e) => {
|
|
2080
2083
|
if (h(I, this) && (h(V, this).debug("Vindral event", { type: e.type }), e instanceof CustomEvent)) switch (e.type) {
|
|
2081
2084
|
case x.PLAY:
|
|
2082
2085
|
this.removeAttribute(g.PAUSED);
|
|
@@ -2121,10 +2124,10 @@ var Si = [
|
|
|
2121
2124
|
}
|
|
2122
2125
|
break;
|
|
2123
2126
|
case x.CHANNEL_GRID_OPENED:
|
|
2124
|
-
h(
|
|
2127
|
+
h(Wi, this) === null && m(H, this, to).call(this);
|
|
2125
2128
|
break;
|
|
2126
2129
|
case x.CHANNEL_GRID_CLOSED:
|
|
2127
|
-
h(
|
|
2130
|
+
h(Wi, this) !== null && (clearTimeout(h(Wi, this)), p(Wi, this, null));
|
|
2128
2131
|
break;
|
|
2129
2132
|
case x.ENTER_PIP:
|
|
2130
2133
|
this.setAttribute(g.IS_PIP, "");
|
|
@@ -2134,7 +2137,7 @@ var Si = [
|
|
|
2134
2137
|
break;
|
|
2135
2138
|
case x.REQUEST_AIRPLAY:
|
|
2136
2139
|
var t;
|
|
2137
|
-
(t = h(
|
|
2140
|
+
(t = h(Bi, this)) == null || t.showPlaybackTargetPicker();
|
|
2138
2141
|
break;
|
|
2139
2142
|
case x.SET_LANGUAGE:
|
|
2140
2143
|
_(e.detail) ? this.setAttribute(g.LANGUAGE, e.detail) : this.removeAttribute(g.LANGUAGE);
|
|
@@ -2155,7 +2158,7 @@ var Si = [
|
|
|
2155
2158
|
this.handleTimeShiftUpdate(String(e.detail));
|
|
2156
2159
|
break;
|
|
2157
2160
|
case x.GO_LIVE:
|
|
2158
|
-
h(
|
|
2161
|
+
h(xa, this).call(this);
|
|
2159
2162
|
break;
|
|
2160
2163
|
case x.TOGGLE_DEBUG_PANEL:
|
|
2161
2164
|
this.hasAttribute(g.DEBUG_PANEL_OPEN) ? this.removeAttribute(g.DEBUG_PANEL_OPEN) : this.setAttribute(g.DEBUG_PANEL_OPEN, "");
|
|
@@ -2167,64 +2170,64 @@ var Si = [
|
|
|
2167
2170
|
}
|
|
2168
2171
|
break;
|
|
2169
2172
|
}
|
|
2170
|
-
}), f(this,
|
|
2173
|
+
}), f(this, ya, (e) => {
|
|
2171
2174
|
let { key: t } = e;
|
|
2172
|
-
if (!
|
|
2175
|
+
if (!Ti.includes(t)) {
|
|
2173
2176
|
this.removeEventListener("keyup", this);
|
|
2174
2177
|
return;
|
|
2175
2178
|
}
|
|
2176
|
-
m(H, this,
|
|
2177
|
-
}), f(this,
|
|
2179
|
+
m(H, this, eo).call(this, e);
|
|
2180
|
+
}), f(this, ba, (e) => {
|
|
2178
2181
|
let { metaKey: t, altKey: n, key: r } = e;
|
|
2179
|
-
t || n || !
|
|
2180
|
-
}), f(this,
|
|
2182
|
+
t || n || !Ti.includes(r) || this.addEventListener("keyup", this, { once: !0 });
|
|
2183
|
+
}), f(this, xa, () => {
|
|
2181
2184
|
this.removeAttribute(g.TIMESHIFT_POSITION), this.handleTimeShiftUpdate(!1);
|
|
2182
|
-
}), f(this,
|
|
2185
|
+
}), f(this, Sa, (e) => {
|
|
2183
2186
|
var t;
|
|
2184
|
-
h(R, this) || m(H, this,
|
|
2185
|
-
}), f(this,
|
|
2187
|
+
h(R, this) || m(H, this, Na).call(this), h(L, this) !== h(R, this) && (e && m(H, this, so).call(this), p(L, this, h(R, this)), m(H, this, ja).call(this), m(H, this, Ma).call(this), m(H, this, La).call(this), (t = h(I, this)) == null || t.pause(), p(Gi, this, e));
|
|
2188
|
+
}), f(this, Ca, (e) => {
|
|
2186
2189
|
var t, n, r, i;
|
|
2187
|
-
e && m(H, this,
|
|
2188
|
-
m(H, this,
|
|
2190
|
+
e && m(H, this, so).call(this), (t = h(R, this)) == null || t.hide(), p(L, this, h(Mi, this)), m(H, this, La).call(this), this.hasAttribute(g.PAUSED) ? (n = h(L, this)) == null || n.pause() : (r = h(L, this)) == null || r.play(), m(H, this, Fa).call(this), m(H, this, Aa).call(this), (i = h(R, this)) == null || i.pause(), e && (p(Gi, this, !1), setTimeout(() => {
|
|
2191
|
+
m(H, this, oo).call(this);
|
|
2189
2192
|
}, 100));
|
|
2190
2193
|
}), e(this, "handleTimeShiftUpdate", (e) => {
|
|
2191
2194
|
let t = this.hasAttribute(g.IS_PIP);
|
|
2192
2195
|
if (e !== !1) {
|
|
2193
2196
|
var n;
|
|
2194
|
-
h(
|
|
2197
|
+
h(Sa, this).call(this, t), (n = h(R, this)) == null || n.seek({
|
|
2195
2198
|
time: parseFloat(e),
|
|
2196
2199
|
playWhenReady: !this.hasAttribute(g.PAUSED)
|
|
2197
2200
|
});
|
|
2198
2201
|
return;
|
|
2199
2202
|
}
|
|
2200
|
-
h(L, this) !== h(
|
|
2201
|
-
}), f(this,
|
|
2203
|
+
h(L, this) !== h(Mi, this) && h(Ca, this).call(this, t);
|
|
2204
|
+
}), f(this, wa, null), f(this, Ta, () => {
|
|
2202
2205
|
var e;
|
|
2203
2206
|
let t = (e = h(I, this)) == null ? void 0 : e.currentRenditionLevel;
|
|
2204
2207
|
if (!(t != null && t.video)) return;
|
|
2205
2208
|
let n = o(t.video.width > t.video.height ? "landscape-primary" : "portrait-primary");
|
|
2206
2209
|
n && n.catch(() => {});
|
|
2207
|
-
}), f(this,
|
|
2210
|
+
}), f(this, Ea, () => {
|
|
2208
2211
|
r();
|
|
2209
|
-
}), f(this,
|
|
2212
|
+
}), f(this, Da, null);
|
|
2210
2213
|
let n = this.attachShadow({ mode: "open" });
|
|
2211
|
-
n.appendChild(
|
|
2214
|
+
n.appendChild(wi.content.cloneNode(!0));
|
|
2212
2215
|
let i = ye(this.getAttribute("log-level"));
|
|
2213
|
-
p(V, this, fe.get().createContext("VindralController")), h(V, this).setLevel(i), p(
|
|
2216
|
+
p(V, this, fe.get().createContext("VindralController")), h(V, this).setLevel(i), p(ji, this, (t = this.shadowRoot) == null ? void 0 : t.querySelector("#time-shift-video")), p(qi, this, new er(n));
|
|
2214
2217
|
}
|
|
2215
2218
|
connectedCallback() {
|
|
2216
2219
|
var e = this;
|
|
2217
2220
|
return t(function* () {
|
|
2218
|
-
b(e.getAttribute("auto-instance-enabled"), !0) && (yield m(H, e,
|
|
2219
|
-
for (let t of Object.values(x)) e.addEventListener(t, h(
|
|
2220
|
-
window.PointerEvent ? (e.addEventListener("pointerdown", e), e.addEventListener("pointermove", e), e.addEventListener("pointerup", e)) : e.addEventListener("mousemove", e), e.addEventListener("mouseleave", e), e.addEventListener("keydown", e), e.addEventListener("resize", e), e.addEventListener("dblclick", e), h(
|
|
2221
|
+
b(e.getAttribute("auto-instance-enabled"), !0) && (yield m(H, e, ka).call(e));
|
|
2222
|
+
for (let t of Object.values(x)) e.addEventListener(t, h(va, e));
|
|
2223
|
+
window.PointerEvent ? (e.addEventListener("pointerdown", e), e.addEventListener("pointermove", e), e.addEventListener("pointerup", e)) : e.addEventListener("mousemove", e), e.addEventListener("mouseleave", e), e.addEventListener("keydown", e), e.addEventListener("resize", e), e.addEventListener("dblclick", e), h(Zi, e).call(e, () => e.connectListener(e)), m(H, e, qa).call(e), e.tabIndex = 0, e.focus({ preventScroll: !0 });
|
|
2221
2224
|
})();
|
|
2222
2225
|
}
|
|
2223
2226
|
disconnectedCallback() {
|
|
2224
2227
|
var e, t, n, r, i;
|
|
2225
|
-
m(H, this,
|
|
2226
|
-
for (let e of Object.values(x)) this.removeEventListener(e, h(
|
|
2227
|
-
m(H, this,
|
|
2228
|
+
m(H, this, Ja).call(this), m(H, this, ho).call(this), h(qi, this).unload(), (e = h(I, this)) == null || e.unload(), (t = h(z, this)) == null || t.unload(), (n = h(Ri, this)) == null || n.unload(), (r = h(zi, this)) == null || r.unload(), (i = h(B, this)) == null || i.unload(), m(H, this, Pa).call(this);
|
|
2229
|
+
for (let e of Object.values(x)) this.removeEventListener(e, h(va, this));
|
|
2230
|
+
m(H, this, ja).call(this), h(Oi, this) && (clearTimeout(h(Oi, this)), p(Oi, this, null)), h(ki, this).stop(), this.disconnectListener(this);
|
|
2228
2231
|
}
|
|
2229
2232
|
attributeChangedCallback(e, t, n) {
|
|
2230
2233
|
if (t !== n) {
|
|
@@ -2234,22 +2237,22 @@ var Si = [
|
|
|
2234
2237
|
newValue: n
|
|
2235
2238
|
}), e) {
|
|
2236
2239
|
case "channel-id":
|
|
2237
|
-
p(
|
|
2240
|
+
p(Pi, this, n), h(I, this) && n && (h(I, this).channelId = n, h(I, this).play(), m(H, this, U).call(this, g.BUFFERING, ""), m(H, this, U).call(this, g.CHANNEL_ID, n), m(H, this, U).call(this, g.POSTER_SRC, h(I, this).getThumbnailUrl()));
|
|
2238
2241
|
break;
|
|
2239
2242
|
case "channel-group-id":
|
|
2240
|
-
p(
|
|
2243
|
+
p(Fi, this, n);
|
|
2241
2244
|
break;
|
|
2242
2245
|
case "url":
|
|
2243
|
-
n && p(
|
|
2246
|
+
n && p(Ni, this, n);
|
|
2244
2247
|
break;
|
|
2245
2248
|
case "paused":
|
|
2246
2249
|
if (_(n)) {
|
|
2247
|
-
if (!h(
|
|
2250
|
+
if (!h(Xi, this)) {
|
|
2248
2251
|
var r;
|
|
2249
2252
|
(r = h(L, this)) == null || r.pause();
|
|
2250
2253
|
}
|
|
2251
2254
|
m(H, this, U).call(this, g.PAUSED, "");
|
|
2252
|
-
} else if (m(H, this, W).call(this, g.NEEDS_USER_INPUT_VIDEO), m(H, this, W).call(this, g.PAUSED), !h(
|
|
2255
|
+
} else if (m(H, this, W).call(this, g.NEEDS_USER_INPUT_VIDEO), m(H, this, W).call(this, g.PAUSED), !h(Xi, this)) {
|
|
2253
2256
|
var i;
|
|
2254
2257
|
(i = h(L, this)) == null || i.play();
|
|
2255
2258
|
}
|
|
@@ -2273,7 +2276,7 @@ var Si = [
|
|
|
2273
2276
|
}
|
|
2274
2277
|
break;
|
|
2275
2278
|
case g.DEBUG_PANEL_OPEN:
|
|
2276
|
-
_(n) ? m(H, this, U).call(this, g.DEBUG_PANEL_OPEN, "") : m(H, this, W).call(this, g.DEBUG_PANEL_OPEN), m(H, this,
|
|
2279
|
+
_(n) ? m(H, this, U).call(this, g.DEBUG_PANEL_OPEN, "") : m(H, this, W).call(this, g.DEBUG_PANEL_OPEN), m(H, this, po).call(this);
|
|
2277
2280
|
break;
|
|
2278
2281
|
case "user-interacting":
|
|
2279
2282
|
_(n) ? m(H, this, U).call(this, g.USER_INTERACTING, "") : m(H, this, W).call(this, g.USER_INTERACTING);
|
|
@@ -2281,7 +2284,7 @@ var Si = [
|
|
|
2281
2284
|
case "muted":
|
|
2282
2285
|
if (h(I, this)) if (_(n)) {
|
|
2283
2286
|
var a;
|
|
2284
|
-
if (h(
|
|
2287
|
+
if (h(Xi, this) || (h(I, this).muted = !0, h(R, this) && (h(R, this).muted = !0)), m(H, this, U).call(this, g.MUTED, ""), (a = h(B, this)) != null && a.isMediaElementSource) {
|
|
2285
2288
|
var o;
|
|
2286
2289
|
(o = h(B, this)) == null || o.stop(), m(H, this, U).call(this, g.VOLUME_LEVEL, JSON.stringify({
|
|
2287
2290
|
left: null,
|
|
@@ -2290,14 +2293,14 @@ var Si = [
|
|
|
2290
2293
|
}
|
|
2291
2294
|
} else {
|
|
2292
2295
|
var s;
|
|
2293
|
-
h(
|
|
2296
|
+
h(Xi, this) || (h(I, this).muted = !1, h(R, this) && (h(R, this).muted = !1), h(I, this).volume === 0 && (h(I, this).volume = .3)), m(H, this, W).call(this, g.MUTED), m(H, this, W).call(this, g.NEEDS_USER_INPUT_AUDIO), (s = h(B, this)) == null || s.start();
|
|
2294
2297
|
}
|
|
2295
2298
|
break;
|
|
2296
2299
|
case "ui-locked":
|
|
2297
|
-
_(n) ? m(H, this,
|
|
2300
|
+
_(n) ? m(H, this, ro).call(this) : m(H, this, io).call(this);
|
|
2298
2301
|
break;
|
|
2299
2302
|
case "is-fullscreen":
|
|
2300
|
-
_(n) ? m(H, this,
|
|
2303
|
+
_(n) ? m(H, this, co).call(this) : m(H, this, lo).call(this);
|
|
2301
2304
|
break;
|
|
2302
2305
|
case "abr-enabled":
|
|
2303
2306
|
{
|
|
@@ -2312,13 +2315,13 @@ var Si = [
|
|
|
2312
2315
|
}
|
|
2313
2316
|
break;
|
|
2314
2317
|
case "max-video-bit-rate":
|
|
2315
|
-
p(
|
|
2318
|
+
p(Ii, this, n), _(n) ? m(H, this, U).call(this, g.MAX_VIDEO_BITRATE, n) : m(H, this, W).call(this, g.MAX_VIDEO_BITRATE), h(R, this) && (h(R, this).maxVideoBitRate = n ? be(n) : void 0);
|
|
2316
2319
|
break;
|
|
2317
2320
|
case "max-initial-bit-rate":
|
|
2318
|
-
p(
|
|
2321
|
+
p(Li, this, n), _(n) ? m(H, this, U).call(this, g.MAX_INITIAL_BITRATE, n) : m(H, this, W).call(this, g.MAX_INITIAL_BITRATE);
|
|
2319
2322
|
break;
|
|
2320
2323
|
case "is-pip":
|
|
2321
|
-
_(n) ? m(H, this,
|
|
2324
|
+
_(n) ? m(H, this, oo).call(this) : m(H, this, so).call(this);
|
|
2322
2325
|
break;
|
|
2323
2326
|
case "is-airplaying":
|
|
2324
2327
|
if (_(n)) {
|
|
@@ -2332,17 +2335,17 @@ var Si = [
|
|
|
2332
2335
|
case "is-casting":
|
|
2333
2336
|
if (_(n)) {
|
|
2334
2337
|
var ee, d;
|
|
2335
|
-
(ee = h(
|
|
2338
|
+
(ee = h(Ri, this)) != null && ee.isFullscreen() && m(H, this, lo).call(this), (d = h(I, this)) == null || d.pause();
|
|
2336
2339
|
} else if (!document.hidden) {
|
|
2337
2340
|
var te;
|
|
2338
2341
|
(te = h(I, this)) == null || te.play();
|
|
2339
2342
|
}
|
|
2340
2343
|
break;
|
|
2341
2344
|
case "cast-receiver-id":
|
|
2342
|
-
p(
|
|
2345
|
+
p(Hi, this, n);
|
|
2343
2346
|
break;
|
|
2344
2347
|
case "cast-background":
|
|
2345
|
-
p(
|
|
2348
|
+
p(Ui, this, n);
|
|
2346
2349
|
break;
|
|
2347
2350
|
case "language":
|
|
2348
2351
|
h(I, this) && (h(I, this).language = n, _(n) ? m(H, this, U).call(this, g.LANGUAGE, n) : m(H, this, W).call(this, g.LANGUAGE));
|
|
@@ -2356,7 +2359,7 @@ var Si = [
|
|
|
2356
2359
|
case "authentication-token":
|
|
2357
2360
|
if (_(n)) {
|
|
2358
2361
|
var ne, re;
|
|
2359
|
-
(ne = h(I, this)) == null || ne.updateAuthenticationToken(n), (re = h(
|
|
2362
|
+
(ne = h(I, this)) == null || ne.updateAuthenticationToken(n), (re = h(Bi, this)) == null || re.updateAuthenticationToken(n), m(H, this, U).call(this, g.AUTHENTICATION_TOKEN, n);
|
|
2360
2363
|
} else m(H, this, W).call(this, g.AUTHENTICATION_TOKEN);
|
|
2361
2364
|
break;
|
|
2362
2365
|
case "volume":
|
|
@@ -2394,13 +2397,13 @@ var Si = [
|
|
|
2394
2397
|
g.USER_INTERACTING,
|
|
2395
2398
|
g.PAUSED,
|
|
2396
2399
|
g.HIDE_UI_ON_PAUSE
|
|
2397
|
-
].includes(e) && m(H, this,
|
|
2400
|
+
].includes(e) && m(H, this, ao).call(this);
|
|
2398
2401
|
}
|
|
2399
2402
|
}
|
|
2400
2403
|
connectListener(e) {
|
|
2401
|
-
|
|
2402
|
-
let n = h(
|
|
2403
|
-
switch (n ? n.push(e) : h(
|
|
2404
|
+
Mr(e).forEach((t) => {
|
|
2405
|
+
let n = h(Ei, this).get(t);
|
|
2406
|
+
switch (n ? n.push(e) : h(Ei, this).set(t, [e]), t) {
|
|
2404
2407
|
case g.PAUSED:
|
|
2405
2408
|
var r;
|
|
2406
2409
|
(((r = h(I, this)) == null ? void 0 : r.playbackState) === "paused" || this.hasAttribute(g.PAUSED)) && e.setAttribute(g.PAUSED, "");
|
|
@@ -2410,7 +2413,7 @@ var Si = [
|
|
|
2410
2413
|
((i = h(I, this)) != null && i.muted || this.hasAttribute(g.MUTED)) && e.setAttribute(g.MUTED, "");
|
|
2411
2414
|
break;
|
|
2412
2415
|
case g.MAX_VIDEO_BITRATE:
|
|
2413
|
-
h(
|
|
2416
|
+
h(Ii, this) && e.setAttribute(g.MAX_VIDEO_BITRATE, h(Ii, this));
|
|
2414
2417
|
break;
|
|
2415
2418
|
case g.SIZE_BASED_RESOLUTION_CAP_ENABLED:
|
|
2416
2419
|
{
|
|
@@ -2420,10 +2423,10 @@ var Si = [
|
|
|
2420
2423
|
}
|
|
2421
2424
|
break;
|
|
2422
2425
|
case g.CHANNEL_ID:
|
|
2423
|
-
h(
|
|
2426
|
+
h(Pi, this) && e.setAttribute(g.CHANNEL_ID, h(Pi, this));
|
|
2424
2427
|
break;
|
|
2425
2428
|
case g.CHANNEL_GROUP_ID:
|
|
2426
|
-
h(
|
|
2429
|
+
h(Fi, this) && e.setAttribute(g.CHANNEL_GROUP_ID, h(Fi, this));
|
|
2427
2430
|
break;
|
|
2428
2431
|
case g.AUTHENTICATION_TOKEN: {
|
|
2429
2432
|
let t = this.getAttribute("authentication-token");
|
|
@@ -2459,38 +2462,38 @@ var Si = [
|
|
|
2459
2462
|
});
|
|
2460
2463
|
}
|
|
2461
2464
|
disconnectListener(e) {
|
|
2462
|
-
|
|
2463
|
-
let n = h(
|
|
2464
|
-
n && h(
|
|
2465
|
+
Mr(e).forEach((t) => {
|
|
2466
|
+
let n = h(Ei, this).get(t);
|
|
2467
|
+
n && h(Ei, this).set(t, n.filter((t) => t !== e));
|
|
2465
2468
|
});
|
|
2466
2469
|
}
|
|
2467
2470
|
get instance() {
|
|
2468
2471
|
return h(I, this);
|
|
2469
2472
|
}
|
|
2470
2473
|
get fullscreen() {
|
|
2471
|
-
return m(H, this,
|
|
2474
|
+
return m(H, this, Ba).call(this);
|
|
2472
2475
|
}
|
|
2473
2476
|
get airPlay() {
|
|
2474
|
-
return h(
|
|
2477
|
+
return h(Bi, this);
|
|
2475
2478
|
}
|
|
2476
2479
|
get timelineMarkers() {
|
|
2477
|
-
return
|
|
2480
|
+
return Br(this.getAttribute(g.TIMELINE_MARKERS));
|
|
2478
2481
|
}
|
|
2479
2482
|
set timelineMarkers(e) {
|
|
2480
|
-
let t =
|
|
2483
|
+
let t = zr(e);
|
|
2481
2484
|
t.length === 0 ? this.removeAttribute(g.TIMELINE_MARKERS) : this.setAttribute(g.TIMELINE_MARKERS, JSON.stringify(t));
|
|
2482
2485
|
}
|
|
2483
2486
|
connect() {
|
|
2484
|
-
m(H, this,
|
|
2487
|
+
m(H, this, ka).call(this);
|
|
2485
2488
|
}
|
|
2486
2489
|
};
|
|
2487
|
-
function
|
|
2490
|
+
function ka() {
|
|
2488
2491
|
var e = this;
|
|
2489
2492
|
return t(function* () {
|
|
2490
2493
|
var t, n;
|
|
2491
|
-
if (!h(
|
|
2492
|
-
let r = h(L, e) === h(
|
|
2493
|
-
h(
|
|
2494
|
+
if (!h(Pi, e)) return;
|
|
2495
|
+
let r = h(L, e) === h(Mi, e);
|
|
2496
|
+
h(ki, e).stop(), yield (t = h(I, e)) == null ? void 0 : t.unload(), r && p(L, e, void 0);
|
|
2494
2497
|
let i = e.hasAttribute(g.PAUSED), a = e.hasAttribute(g.MUTED), o = be(e.getAttribute(g.VOLUME)), s = typeof o == "number" ? Math.max(0, Math.min(1, o)) : o, c = xe(e.getAttribute(g.MEDIA)), l = e.getAttribute(g.TEXT_TRACK) || void 0, u = e.getAttribute("edge-url") || void 0, ee = e.getAttribute("authentication-token") || void 0, d = be(e.getAttribute("max-video-bit-rate")), te = be(e.getAttribute("max-initial-bit-rate")), ne = Ce(e.getAttribute("max-size")), ie = be(e.getAttribute("min-buffer-time")), ae = be(e.getAttribute("max-buffer-time")), oe = b(e.getAttribute("burst-enabled")), se = b(e.getAttribute("mse-enabled")), ce = b(e.getAttribute("mse-opus-enabled")), f = b(e.getAttribute("background-play-enabled")), le = b(e.getAttribute("ios-background-play-enabled")), ue = b(e.getAttribute("media-session-enabled")), de = b(e.getAttribute("ios-wake-lock-enabled")), fe = b(e.getAttribute("stream-to-media-element-enabled")), pe = b(e.getAttribute("ios-media-element-enabled")), me = b(e.getAttribute("abr-enabled"), !0), he = b(e.getAttribute("size-based-resolution-cap-enabled")), _e = b(e.getAttribute("telemetry-enabled")), v = ke(e.getAttribute("video-codecs")), we = ve(e.getAttribute("poster")), Te = Se(e.getAttribute("advanced")), y = ye(e.getAttribute("log-level")), De = {
|
|
2495
2498
|
headers: Ee(e.getAttribute("drm-headers")),
|
|
2496
2499
|
queryParams: Ee(e.getAttribute("drm-queryparams")),
|
|
@@ -2504,9 +2507,9 @@ function Ea() {
|
|
|
2504
2507
|
}
|
|
2505
2508
|
}, Oe = Fe(e.getAttribute("webcodecs-hardware-acceleration")), Ae = Pe(e.getAttribute("decoders")), x = b(e.getAttribute("offscreen-canvas-enabled")), S = b(e.getAttribute("webtransport-enabled")), je = be(e.getAttribute("reconnect-retries")), Me = je === void 0 ? void 0 : (e) => e.reconnectRetries < je, Ne = e.getAttribute("language") || void 0;
|
|
2506
2509
|
p(I, e, new re({
|
|
2507
|
-
url: h(
|
|
2508
|
-
channelId: h(
|
|
2509
|
-
channelGroupId: h(
|
|
2510
|
+
url: h(Ni, e),
|
|
2511
|
+
channelId: h(Pi, e),
|
|
2512
|
+
channelGroupId: h(Fi, e),
|
|
2510
2513
|
edgeUrl: u,
|
|
2511
2514
|
authenticationToken: ee,
|
|
2512
2515
|
muted: a,
|
|
@@ -2541,116 +2544,114 @@ function Ea() {
|
|
|
2541
2544
|
decoders: Ae,
|
|
2542
2545
|
offscreenCanvasEnabled: x,
|
|
2543
2546
|
reconnectHandler: Me
|
|
2544
|
-
})), p(
|
|
2547
|
+
})), p(Mi, e, new yi(h(I, e))), h(L, e) || p(L, e, h(Mi, e)), m(H, e, Aa).call(e), p(Ai, e, (n = e.shadowRoot) == null ? void 0 : n.querySelector("#video")), h(Ai, e) && (h(I, e).attach(h(Ai, e)), h(qi, e).observe(h(Ai, e))), e.setAttribute(g.MEDIA, h(I, e).media);
|
|
2545
2548
|
let Ie = h(I, e);
|
|
2546
|
-
h(
|
|
2549
|
+
h(Zi, e).call(e, () => {
|
|
2547
2550
|
Ie.muted && m(H, e, U).call(e, g.MUTED, ""), Ie.abrEnabled ? m(H, e, U).call(e, g.ABR_ENABLED, "") : m(H, e, W).call(e, g.ABR_ENABLED), m(H, e, U).call(e, g.SIZE_BASED_RESOLUTION_CAP_ENABLED, Ie.sizeBasedResolutionCapEnabled ? "true" : "false"), m(H, e, U).call(e, g.VOLUME, Ie.volume.toString());
|
|
2548
2551
|
}), _(we) || m(H, e, U).call(e, g.POSTER_SRC, h(I, e).getThumbnailUrl());
|
|
2549
2552
|
let Le = b(e.getAttribute(g.AIRPLAY_ENABLED), !1), C = b(e.getAttribute(g.CAST_ENABLED), !0), Re = b(e.getAttribute(g.FULLSCREEN_ENABLED), !0), ze = b(e.getAttribute(g.PIP_ENABLED), !0), Be = b(e.getAttribute(g.VU_METER_ENABLED), !1), Ve = b(e.getAttribute(g.TIMESHIFT_ENABLED), !1);
|
|
2550
|
-
Le && m(H, e,
|
|
2553
|
+
Le && m(H, e, Ga).call(e, h(I, e)), C && m(H, e, Va).call(e, h(I, e)), Re && m(H, e, Ra).call(e, h(I, e)), ze && m(H, e, Ia).call(e, h(I, e)), i || h(I, e).play(), Be && m(H, e, Ka).call(e, h(I, e)), e.dispatchEvent(new CustomEvent("vindral-instance-ready", {
|
|
2551
2554
|
bubbles: !0,
|
|
2552
2555
|
composed: !0,
|
|
2553
2556
|
detail: h(I, e)
|
|
2554
|
-
})), Ve && (m(H, e,
|
|
2557
|
+
})), Ve && (m(H, e, Na).call(e), Re && m(H, e, za).call(e));
|
|
2555
2558
|
})();
|
|
2556
2559
|
}
|
|
2557
|
-
function
|
|
2558
|
-
h(I, this) && (h(I, this).on("rendition levels", h(
|
|
2560
|
+
function Aa() {
|
|
2561
|
+
h(I, this) && (h(I, this).on("rendition levels", h(Ji, this)), h(I, this).on("rendition level", h(Yi, this)), h(I, this).on("playback state", h(Qi, this)), h(I, this).on("volume state", h($i, this)), h(I, this).on("channel switch failed", h(ea, this)), h(I, this).on("channel switch", h(ta, this)), h(I, this).on("channels", h(na, this)), h(I, this).on("languages", h(ra, this)), h(I, this).on("text tracks", h(ia, this)), h(I, this).on("needs user input", h(aa, this)), h(I, this).on("is live", h(oa, this)), h(I, this).on("timeshift info", h(sa, this)));
|
|
2559
2562
|
}
|
|
2560
|
-
function
|
|
2561
|
-
h(I, this) && (h(I, this).off("playback state", h(
|
|
2563
|
+
function ja() {
|
|
2564
|
+
h(I, this) && (h(I, this).off("playback state", h(Qi, this)), h(I, this).off("volume state", h($i, this)), h(I, this).off("channel switch failed", h(ea, this)), h(I, this).off("channel switch", h(ta, this)), h(I, this).off("channels", h(na, this)), h(I, this).off("languages", h(ra, this)), h(I, this).off("text tracks", h(ia, this)), h(I, this).off("needs user input", h(aa, this)), h(I, this).off("is live", h(oa, this)), h(I, this).off("timeshift info", h(sa, this)));
|
|
2562
2565
|
}
|
|
2563
|
-
function
|
|
2564
|
-
h(R, this) && (h(R, this).addEventListener("playing", h(
|
|
2566
|
+
function Ma() {
|
|
2567
|
+
h(R, this) && (h(R, this).addEventListener("playing", h(ca, this)), h(R, this).addEventListener("pause", h(la, this)), h(R, this).addEventListener("ended", h(ua, this)), h(R, this).addEventListener("timeupdate", h(fa, this)), h(R, this).addEventListener("volumechange", h(pa, this)), h(R, this).addEventListener("hlsbuffering", h(ma, this)), h(R, this).addEventListener("hlsnotbuffering", h(ha, this)), h(R, this).addEventListener("timeshiftready", h(ga, this)));
|
|
2565
2568
|
}
|
|
2566
|
-
function
|
|
2569
|
+
function Na() {
|
|
2567
2570
|
var e, t, n, r;
|
|
2568
2571
|
let i = be(this.getAttribute(g.VOLUME)), a = i === void 0 ? (e = (t = h(L, this)) == null ? void 0 : t.volume) == null ? 1 : e : Math.max(0, Math.min(1, i)), o = b(this.getAttribute(g.MUTED), (n = (r = h(L, this)) == null ? void 0 : r.muted) == null ? !1 : n);
|
|
2569
|
-
m(H, this,
|
|
2572
|
+
m(H, this, Pa).call(this), p(R, this, new ni(h(ji, this), {
|
|
2570
2573
|
volume: a,
|
|
2571
2574
|
muted: o,
|
|
2572
|
-
maxVideoBitRate: h(
|
|
2573
|
-
})), h(R, this).addEventListener("durationchange", h(
|
|
2575
|
+
maxVideoBitRate: h(Ii, this) ? parseInt(h(Ii, this), 10) : void 0
|
|
2576
|
+
})), h(R, this).addEventListener("durationchange", h(da, this));
|
|
2574
2577
|
}
|
|
2575
|
-
function
|
|
2576
|
-
h(R, this) && (m(H, this,
|
|
2578
|
+
function Pa() {
|
|
2579
|
+
h(R, this) && (m(H, this, Fa).call(this), h(R, this).removeEventListener("durationchange", h(da, this)), h(R, this).cleanup(), h(L, this) === h(R, this) && p(L, this, void 0), p(R, this, void 0));
|
|
2577
2580
|
}
|
|
2578
|
-
function
|
|
2579
|
-
h(R, this) && (h(R, this).removeEventListener("playing", h(
|
|
2581
|
+
function Fa() {
|
|
2582
|
+
h(R, this) && (h(R, this).removeEventListener("playing", h(ca, this)), h(R, this).removeEventListener("pause", h(la, this)), h(R, this).removeEventListener("ended", h(ua, this)), h(R, this).removeEventListener("timeupdate", h(fa, this)), h(R, this).removeEventListener("volumechange", h(pa, this)), h(R, this).removeEventListener("hlsbuffering", h(ma, this)), h(R, this).removeEventListener("hlsnotbuffering", h(ha, this)), h(R, this).removeEventListener("timeshiftready", h(ga, this)));
|
|
2580
2583
|
}
|
|
2581
|
-
function
|
|
2582
|
-
e.mediaElement instanceof HTMLVideoElement && (p(z, this, new
|
|
2583
|
-
|
|
2584
|
-
e ? m(H, this, U).call(this, g.IS_PIP, "") : m(H, this, W).call(this, g.IS_PIP), h(Wi, this).setEnabled(!((t = h(z, this)) != null && t.isWebkitPresentationModeActive()));
|
|
2584
|
+
function Ia(e) {
|
|
2585
|
+
e.mediaElement instanceof HTMLVideoElement && (p(z, this, new dr(e.mediaElement)), h(z, this).isSupported() && (h(V, this).debug("PIP is supported"), m(H, this, U).call(this, g.PIP_AVAILABLE, "")), h(z, this).on("on picture in picture change", (e) => {
|
|
2586
|
+
e ? m(H, this, U).call(this, g.IS_PIP, "") : m(H, this, W).call(this, g.IS_PIP);
|
|
2585
2587
|
}));
|
|
2586
2588
|
}
|
|
2587
|
-
function
|
|
2589
|
+
function La() {
|
|
2588
2590
|
var e;
|
|
2589
2591
|
if (!h(z, this)) return;
|
|
2590
2592
|
let t = null;
|
|
2591
|
-
h(L, this) === h(R, this) && h(R, this) ? t = h(R, this).videoElement : ((e = h(I, this)) == null ? void 0 : e.mediaElement) instanceof HTMLVideoElement && (t = h(I, this).mediaElement), t && t !== h(z, this).videoElement && (h(V, this).debug("Updating PIP target to", h(L, this) === h(R, this) ? "HLS" : "Vindral"), h(z, this).unload(), p(z, this, new
|
|
2592
|
-
|
|
2593
|
-
e ? m(H, this, U).call(this, g.IS_PIP, "") : m(H, this, W).call(this, g.IS_PIP), h(Wi, this).setEnabled(!((t = h(z, this)) != null && t.isWebkitPresentationModeActive()));
|
|
2593
|
+
h(L, this) === h(R, this) && h(R, this) ? t = h(R, this).videoElement : ((e = h(I, this)) == null ? void 0 : e.mediaElement) instanceof HTMLVideoElement && (t = h(I, this).mediaElement), t && t !== h(z, this).videoElement && (h(V, this).debug("Updating PIP target to", h(L, this) === h(R, this) ? "HLS" : "Vindral"), h(z, this).unload(), p(z, this, new dr(t)), h(z, this).on("on picture in picture change", (e) => {
|
|
2594
|
+
e ? m(H, this, U).call(this, g.IS_PIP, "") : m(H, this, W).call(this, g.IS_PIP);
|
|
2594
2595
|
}));
|
|
2595
2596
|
}
|
|
2596
|
-
function
|
|
2597
|
-
let t =
|
|
2598
|
-
p(
|
|
2597
|
+
function Ra(e) {
|
|
2598
|
+
let t = !tr.isFullscreenApiSupported(this) && tr.isFullscreenApiSupported(e.mediaElement) ? e.mediaElement : this;
|
|
2599
|
+
p(Ri, this, new tr(t)), h(Ri, this).on("on fullscreen change", (e) => {
|
|
2599
2600
|
e ? m(H, this, U).call(this, g.FULLSCREEN, "") : m(H, this, W).call(this, g.FULLSCREEN);
|
|
2600
2601
|
});
|
|
2601
2602
|
}
|
|
2602
|
-
function
|
|
2603
|
+
function za() {
|
|
2603
2604
|
var e;
|
|
2604
|
-
h(R, this) && (p(
|
|
2605
|
+
h(R, this) && (p(zi, this, !tr.isFullscreenApiSupported(this) && tr.isFullscreenApiSupported((e = h(R, this)) == null ? void 0 : e.videoElement) ? new tr(h(R, this).videoElement) : new tr(this)), h(zi, this).on("on fullscreen change", (e) => {
|
|
2605
2606
|
e ? m(H, this, U).call(this, g.FULLSCREEN, "") : m(H, this, W).call(this, g.FULLSCREEN);
|
|
2606
2607
|
}));
|
|
2607
2608
|
}
|
|
2608
|
-
function
|
|
2609
|
-
return this.hasAttribute(g.TIMESHIFT_POSITION) ? h(
|
|
2609
|
+
function Ba() {
|
|
2610
|
+
return this.hasAttribute(g.TIMESHIFT_POSITION) ? h(zi, this) : h(Ri, this);
|
|
2610
2611
|
}
|
|
2611
|
-
function
|
|
2612
|
-
p(
|
|
2613
|
-
background: h(
|
|
2614
|
-
receiverApplicationId: h(
|
|
2612
|
+
function Va(e) {
|
|
2613
|
+
p(Vi, this, new je({
|
|
2614
|
+
background: h(Ui, this),
|
|
2615
|
+
receiverApplicationId: h(Hi, this),
|
|
2615
2616
|
options: e.getCastOptions()
|
|
2616
|
-
})), h(
|
|
2617
|
+
})), h(Vi, this).on("devices available", m(H, this, Ha).bind(this)), h(Vi, this).on("connected", m(H, this, Ua).bind(this)), h(Vi, this).on("resumed", m(H, this, Ua).bind(this)), h(Vi, this).on("disconnected", m(H, this, Wa).bind(this)), h(Vi, this).init().catch((e) => {
|
|
2617
2618
|
h(V, this).warn("Failed to initialize CastSender", e);
|
|
2618
2619
|
});
|
|
2619
2620
|
}
|
|
2620
|
-
function
|
|
2621
|
+
function Ha(e) {
|
|
2621
2622
|
e ? m(H, this, U).call(this, g.CAST_AVAILABLE, "") : m(H, this, W).call(this, g.CAST_AVAILABLE);
|
|
2622
2623
|
}
|
|
2623
|
-
function
|
|
2624
|
+
function Ua() {
|
|
2624
2625
|
var e, t;
|
|
2625
2626
|
m(H, this, U).call(this, g.IS_CASTING, "");
|
|
2626
|
-
let n = (e = (t = h(
|
|
2627
|
+
let n = (e = (t = h(Vi, this)) == null ? void 0 : t.getReceiverName()) == null ? "device" : e;
|
|
2627
2628
|
m(H, this, U).call(this, g.CAST_RECEIVER_NAME, n);
|
|
2628
2629
|
}
|
|
2629
|
-
function
|
|
2630
|
+
function Wa() {
|
|
2630
2631
|
m(H, this, W).call(this, g.IS_CASTING), m(H, this, W).call(this, g.CAST_RECEIVER_NAME);
|
|
2631
2632
|
}
|
|
2632
|
-
function
|
|
2633
|
+
function Ga(e) {
|
|
2633
2634
|
var t;
|
|
2634
|
-
(t = h(
|
|
2635
|
+
(t = h(Bi, this)) == null || t.unload();
|
|
2635
2636
|
let n = e.getCastOptions();
|
|
2636
|
-
p(
|
|
2637
|
+
p(Bi, this, new Hn({
|
|
2637
2638
|
url: n.url,
|
|
2638
2639
|
channelId: n.channelId,
|
|
2639
2640
|
authenticationToken: n.authenticationToken,
|
|
2640
2641
|
container: this
|
|
2641
|
-
})), h(
|
|
2642
|
+
})), h(Bi, this).once("available", () => {
|
|
2642
2643
|
m(H, this, U).call(this, g.AIRPLAY_AVAILABLE, "");
|
|
2643
|
-
}), h(
|
|
2644
|
+
}), h(Bi, this).on("connected", () => {
|
|
2644
2645
|
m(H, this, U).call(this, g.IS_AIRPLAYING, "");
|
|
2645
|
-
}), h(
|
|
2646
|
+
}), h(Bi, this).on("disconnected", () => {
|
|
2646
2647
|
m(H, this, W).call(this, g.IS_AIRPLAYING);
|
|
2647
2648
|
});
|
|
2648
2649
|
}
|
|
2649
|
-
function
|
|
2650
|
+
function Ka(e) {
|
|
2650
2651
|
var t;
|
|
2651
2652
|
if ((t = h(B, this)) == null || t.unload(), !a()) {
|
|
2652
|
-
if (e.audioNode) p(B, this, new
|
|
2653
|
-
else if (e.mediaElement instanceof HTMLMediaElement) p(B, this, new
|
|
2653
|
+
if (e.audioNode) p(B, this, new Hr(e.audioNode));
|
|
2654
|
+
else if (e.mediaElement instanceof HTMLMediaElement) p(B, this, new Hr(e.mediaElement));
|
|
2654
2655
|
else return;
|
|
2655
2656
|
h(B, this).on("on decibel change", (e) => {
|
|
2656
2657
|
m(H, this, U).call(this, g.VOLUME_LEVEL, JSON.stringify(e));
|
|
@@ -2660,37 +2661,37 @@ function Ua(e) {
|
|
|
2660
2661
|
})), (!h(B, this).isMediaElementSource || !this.hasAttribute(g.MUTED)) && h(B, this).start();
|
|
2661
2662
|
}
|
|
2662
2663
|
}
|
|
2663
|
-
function
|
|
2664
|
-
let e = () => (customElements.get("vindral-debug-panel") || import("./
|
|
2665
|
-
window._vindralDebug = e, p(
|
|
2664
|
+
function qa() {
|
|
2665
|
+
let e = () => (customElements.get("vindral-debug-panel") || import("./XEQIIc9P.js").then((e) => e.n).then(({ registerDebugComponents: e }) => e()), this.setAttribute(g.DEBUG_PANEL_OPEN, ""), h(I, this));
|
|
2666
|
+
window._vindralDebug = e, p(Ki, this, e);
|
|
2666
2667
|
}
|
|
2667
|
-
function
|
|
2668
|
+
function Ja() {
|
|
2668
2669
|
let e = window;
|
|
2669
|
-
h(
|
|
2670
|
+
h(Ki, this) && e._vindralDebug === h(Ki, this) && delete e._vindralDebug, p(Ki, this, null);
|
|
2670
2671
|
}
|
|
2671
|
-
function
|
|
2672
|
-
e.pointerType !== "mouse" && e.timeStamp - h(
|
|
2672
|
+
function Ya(e) {
|
|
2673
|
+
e.pointerType !== "mouse" && e.timeStamp - h(_a, this) < 250 || (m(H, this, ro).call(this), h(Oi, this) && clearTimeout(h(Oi, this)), e.target instanceof HTMLElement && ([this, h(Ai, this)].includes(e.target) || e.target.localName === "vindral-scroll-overlay") && m(H, this, io).call(this));
|
|
2673
2674
|
}
|
|
2674
|
-
function
|
|
2675
|
+
function Xa(e) {
|
|
2675
2676
|
let t = this.hasAttribute(g.USER_INTERACTING);
|
|
2676
|
-
e.pointerType === "touch" && e.target instanceof HTMLElement ? [this, h(
|
|
2677
|
+
e.pointerType === "touch" && e.target instanceof HTMLElement ? [this, h(Ai, this)].includes(e.target) && t ? m(H, this, no).call(this) : m(H, this, io).call(this) : e.composedPath().some((e) => e instanceof HTMLElement && ["vindral-play-button"].includes(e == null ? void 0 : e.localName)) && m(H, this, io).call(this);
|
|
2677
2678
|
}
|
|
2678
|
-
function
|
|
2679
|
+
function Za(e) {
|
|
2679
2680
|
switch (e) {
|
|
2680
2681
|
case "dblclick-fullscreen": return b(this.getAttribute(g.DOUBLE_CLICK_FULLSCREEN_ENABLED), !0);
|
|
2681
2682
|
default: return !0;
|
|
2682
2683
|
}
|
|
2683
2684
|
}
|
|
2684
|
-
function
|
|
2685
|
-
m(H, this,
|
|
2685
|
+
function Qa(e) {
|
|
2686
|
+
m(H, this, Za).call(this, "dblclick-fullscreen") && (!h(Ri, this) || e.target instanceof v || e.target instanceof He || e.target instanceof Ci || (this.hasAttribute(g.FULLSCREEN) ? this.removeAttribute(g.FULLSCREEN) : this.setAttribute(g.FULLSCREEN, "")));
|
|
2686
2687
|
}
|
|
2687
|
-
function
|
|
2688
|
-
this.hasAttribute(g.USER_INTERACTING) || m(H, this,
|
|
2688
|
+
function $a(e) {
|
|
2689
|
+
this.hasAttribute(g.USER_INTERACTING) || m(H, this, io).call(this);
|
|
2689
2690
|
}
|
|
2690
|
-
function
|
|
2691
|
+
function eo(e) {
|
|
2691
2692
|
var t;
|
|
2692
2693
|
let { metaKey: n, altKey: r, key: i } = e;
|
|
2693
|
-
if (n || r || !
|
|
2694
|
+
if (n || r || !Ti.includes(i)) return;
|
|
2694
2695
|
let a = (t = e.target) == null ? void 0 : t.keysUsed;
|
|
2695
2696
|
if (!(Array.isArray(a) && a.includes(i)) && !e.composedPath().some((e) => {
|
|
2696
2697
|
let t = e == null ? void 0 : e.keysUsed;
|
|
@@ -2708,28 +2709,28 @@ function Za(e) {
|
|
|
2708
2709
|
break;
|
|
2709
2710
|
}
|
|
2710
2711
|
}
|
|
2711
|
-
function
|
|
2712
|
+
function to() {
|
|
2712
2713
|
var e = this;
|
|
2713
2714
|
return t(function* () {
|
|
2714
|
-
if (!h(I, e) || !h(
|
|
2715
|
+
if (!h(I, e) || !h(Fi, e)) return;
|
|
2715
2716
|
let t = Date.now();
|
|
2716
|
-
if (h(
|
|
2717
|
+
if (h(wa, e) && t - h(wa, e) < 1e4) h(V, e).debug("Skipping channel update, last update was less than 10 seconds ago.");
|
|
2717
2718
|
else {
|
|
2718
|
-
p(
|
|
2719
|
-
let n = yield h(I, e).getApiClient().getChannels(h(
|
|
2719
|
+
p(wa, e, t);
|
|
2720
|
+
let n = yield h(I, e).getApiClient().getChannels(h(Fi, e));
|
|
2720
2721
|
m(H, e, U).call(e, g.CHANNELS, JSON.stringify(n));
|
|
2721
2722
|
}
|
|
2722
|
-
p(
|
|
2723
|
+
p(Wi, e, window.setTimeout(() => void m(H, e, to).call(e), 1e4));
|
|
2723
2724
|
})();
|
|
2724
2725
|
}
|
|
2725
|
-
function
|
|
2726
|
+
function no() {
|
|
2726
2727
|
!this.hasAttribute(g.USER_INTERACTING) || this.hasAttribute(g.UI_LOCKED) || (this.dispatchEvent(new CustomEvent("user-interacting", {
|
|
2727
2728
|
bubbles: !0,
|
|
2728
2729
|
composed: !0,
|
|
2729
2730
|
detail: { active: !1 }
|
|
2730
2731
|
})), this.removeAttribute(g.USER_INTERACTING));
|
|
2731
2732
|
}
|
|
2732
|
-
function
|
|
2733
|
+
function ro() {
|
|
2733
2734
|
this.hasAttribute(g.USER_INTERACTING) || requestAnimationFrame(() => {
|
|
2734
2735
|
this.setAttribute(g.USER_INTERACTING, ""), this.dispatchEvent(new CustomEvent("user-interacting", {
|
|
2735
2736
|
bubbles: !0,
|
|
@@ -2738,64 +2739,64 @@ function eo() {
|
|
|
2738
2739
|
}));
|
|
2739
2740
|
});
|
|
2740
2741
|
}
|
|
2741
|
-
function
|
|
2742
|
-
m(H, this,
|
|
2743
|
-
m(H, this,
|
|
2744
|
-
}, h(
|
|
2742
|
+
function io() {
|
|
2743
|
+
m(H, this, ro).call(this), h(Oi, this) && clearTimeout(h(Oi, this)), h(Di, this) && p(Oi, this, self.setTimeout(() => {
|
|
2744
|
+
m(H, this, no).call(this);
|
|
2745
|
+
}, h(Di, this)));
|
|
2745
2746
|
}
|
|
2746
|
-
function
|
|
2747
|
+
function ao() {
|
|
2747
2748
|
var e;
|
|
2748
2749
|
let t = getComputedStyle(this).getPropertyValue("--vindral-subtitle-offset") || "0px";
|
|
2749
2750
|
(e = h(I, this)) == null || (e = e.mediaElement) == null || e.style.setProperty("--vindral-subtitle-offset", t);
|
|
2750
2751
|
}
|
|
2751
|
-
function
|
|
2752
|
+
function oo() {
|
|
2752
2753
|
var e;
|
|
2753
|
-
m(H, this,
|
|
2754
|
+
m(H, this, La).call(this), m(H, this, uo).call(this), (e = h(z, this)) == null || e.request().catch((e) => {
|
|
2754
2755
|
h(V, this).warn("Failed to enter picture in picture:", e);
|
|
2755
2756
|
});
|
|
2756
2757
|
}
|
|
2757
|
-
function
|
|
2758
|
+
function so() {
|
|
2758
2759
|
var e;
|
|
2759
2760
|
(e = h(z, this)) == null || e.exit().catch((e) => {
|
|
2760
2761
|
h(V, this).warn("Failed to exit picture in picture:", e);
|
|
2761
2762
|
});
|
|
2762
2763
|
}
|
|
2763
|
-
function
|
|
2764
|
-
let e = m(H, this,
|
|
2764
|
+
function co() {
|
|
2765
|
+
let e = m(H, this, Ba).call(this);
|
|
2765
2766
|
if (!e) {
|
|
2766
2767
|
console.warn("No fullscreen target available"), this.setAttribute(g.FULLSCREEN_FALLBACK, ""), m(H, this, U).call(this, g.FULLSCREEN, "");
|
|
2767
2768
|
return;
|
|
2768
2769
|
}
|
|
2769
|
-
e != null && e.isFullscreenApiSupported() ? (m(H, this,
|
|
2770
|
-
h(
|
|
2770
|
+
e != null && e.isFullscreenApiSupported() ? (m(H, this, uo).call(this), e == null || e.request().then(() => {
|
|
2771
|
+
h(Ta, this).call(this);
|
|
2771
2772
|
}).catch((e) => {
|
|
2772
2773
|
h(V, this).warn("Failed to enter fullscreen:", e);
|
|
2773
2774
|
})) : (this.setAttribute(g.FULLSCREEN_FALLBACK, ""), m(H, this, U).call(this, g.FULLSCREEN, ""));
|
|
2774
2775
|
}
|
|
2775
|
-
function
|
|
2776
|
-
let e = m(H, this,
|
|
2776
|
+
function lo() {
|
|
2777
|
+
let e = m(H, this, Ba).call(this);
|
|
2777
2778
|
e != null && e.isFullscreenApiSupported() ? e == null || e.exit().then(() => {
|
|
2778
|
-
h(
|
|
2779
|
+
h(Ea, this).call(this);
|
|
2779
2780
|
}).catch((e) => {
|
|
2780
2781
|
h(V, this).warn("Failed to exit fullscreen:", e);
|
|
2781
2782
|
}) : (this.removeAttribute(g.FULLSCREEN_FALLBACK), m(H, this, W).call(this, g.FULLSCREEN));
|
|
2782
2783
|
}
|
|
2783
|
-
function
|
|
2784
|
+
function uo() {
|
|
2784
2785
|
h(I, this) && h(I, this).emitter.emit("ios-hack: reset size");
|
|
2785
2786
|
}
|
|
2786
|
-
function
|
|
2787
|
+
function fo() {
|
|
2787
2788
|
return this.hasAttribute(g.DEBUG_PANEL_OPEN);
|
|
2788
2789
|
}
|
|
2789
|
-
function
|
|
2790
|
-
m(H, this,
|
|
2790
|
+
function po() {
|
|
2791
|
+
m(H, this, fo).call(this) ? m(H, this, mo).call(this) : m(H, this, ho).call(this);
|
|
2791
2792
|
}
|
|
2792
|
-
function
|
|
2793
|
-
h(
|
|
2793
|
+
function mo() {
|
|
2794
|
+
h(Da, this) === null && (m(H, this, go).call(this), p(Da, this, window.setInterval(() => m(H, this, go).call(this), 1e3)));
|
|
2794
2795
|
}
|
|
2795
|
-
function
|
|
2796
|
-
h(
|
|
2796
|
+
function ho() {
|
|
2797
|
+
h(Da, this) && (clearInterval(h(Da, this)), p(Da, this, null)), this.removeAttribute(g.DRIFT), m(H, this, W).call(this, g.DRIFT), m(H, this, W).call(this, g.PLAYBACK_LATENCY), m(H, this, W).call(this, g.CONNECTION_STATE);
|
|
2797
2798
|
}
|
|
2798
|
-
function
|
|
2799
|
+
function go() {
|
|
2799
2800
|
if (!h(I, this)) return;
|
|
2800
2801
|
try {
|
|
2801
2802
|
let e = h(I, this).getStatistics().drift;
|
|
@@ -2811,13 +2812,13 @@ function po() {
|
|
|
2811
2812
|
}
|
|
2812
2813
|
function U(e, t) {
|
|
2813
2814
|
var n;
|
|
2814
|
-
(n = h(
|
|
2815
|
+
(n = h(Ei, this).get(e)) == null || n.forEach((n) => n.setAttribute(e, t));
|
|
2815
2816
|
}
|
|
2816
2817
|
function W(e) {
|
|
2817
2818
|
var t;
|
|
2818
|
-
(t = h(
|
|
2819
|
+
(t = h(Ei, this).get(e)) == null || t.forEach((t) => t.removeAttribute(e));
|
|
2819
2820
|
}
|
|
2820
|
-
e(
|
|
2821
|
+
e(Oa, "observedAttributes", [
|
|
2821
2822
|
...Ae,
|
|
2822
2823
|
"url",
|
|
2823
2824
|
"edge-url",
|
|
@@ -2861,8 +2862,8 @@ e(Ta, "observedAttributes", [
|
|
|
2861
2862
|
]);
|
|
2862
2863
|
//#endregion
|
|
2863
2864
|
//#region ../../libs/player-next/src/components/FullscreenButton.ts
|
|
2864
|
-
var
|
|
2865
|
-
|
|
2865
|
+
var _o, vo = document.createElement("template");
|
|
2866
|
+
vo.innerHTML = `
|
|
2866
2867
|
<style>
|
|
2867
2868
|
:host {
|
|
2868
2869
|
display: var(--fullscreen-button-display);
|
|
@@ -2886,10 +2887,10 @@ ho.innerHTML = `
|
|
|
2886
2887
|
</slot>
|
|
2887
2888
|
</slot>
|
|
2888
2889
|
`;
|
|
2889
|
-
var
|
|
2890
|
+
var yo = class extends v {
|
|
2890
2891
|
constructor() {
|
|
2891
2892
|
var e;
|
|
2892
|
-
super(), (e = this.shadowRoot) == null || e.appendChild(
|
|
2893
|
+
super(), (e = this.shadowRoot) == null || e.appendChild(vo.content.cloneNode(!0));
|
|
2893
2894
|
}
|
|
2894
2895
|
connectedCallback() {
|
|
2895
2896
|
super.connectedCallback(), this.setAttribute("aria-label", this.isFullscreen ? "Exit fullscreen" : "Fullscreen");
|
|
@@ -2914,48 +2915,48 @@ var go = class extends v {
|
|
|
2914
2915
|
}));
|
|
2915
2916
|
}
|
|
2916
2917
|
};
|
|
2917
|
-
|
|
2918
|
+
_o = yo, e(yo, "observedAttributes", [...y(_o, "observedAttributes", _o), g.FULLSCREEN]);
|
|
2918
2919
|
//#endregion
|
|
2919
2920
|
//#region ../../libs/player-next/src/components/LanguageMenu.ts
|
|
2920
|
-
var
|
|
2921
|
-
|
|
2921
|
+
var bo, xo = "\n <svg xmlns=\"http://www.w3.org/2000/svg\" width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><path stroke=\"none\" d=\"M0 0h24v24H0z\" fill=\"none\"/><path d=\"M4 5h7\" /><path d=\"M9 3v2c0 4.418 -2.239 8 -5 8\" /><path d=\"M5 9c0 2.144 2.952 3.908 6.7 4\" /><path d=\"M12 20l4 -9l4 9\" /><path d=\"M19.1 18h-6.2\" /></svg>\n", So = document.createElement("template");
|
|
2922
|
+
So.innerHTML = `
|
|
2922
2923
|
<style>
|
|
2923
2924
|
:host(:not([hidden])) {
|
|
2924
2925
|
display: var(--language-menu-display);
|
|
2925
2926
|
}
|
|
2926
2927
|
</style>
|
|
2927
2928
|
|
|
2928
|
-
<slot name="button">${
|
|
2929
|
+
<slot name="button">${xo}</slot>
|
|
2929
2930
|
<slot name="listbox" hidden>
|
|
2930
2931
|
<vindral-language-menu-list id="listbox" part="listbox"></vindral-language-menu-list>
|
|
2931
2932
|
</slot>
|
|
2932
2933
|
`;
|
|
2933
|
-
var
|
|
2934
|
+
var Co = /* @__PURE__ */ new WeakSet(), wo = class extends He {
|
|
2934
2935
|
constructor() {
|
|
2935
2936
|
var e, t, n;
|
|
2936
|
-
super(), S(this,
|
|
2937
|
+
super(), S(this, Co), (e = this.shadowRoot) == null || e.appendChild(So.content.cloneNode(!0)), this.listbox = (t = this.shadowRoot) == null ? void 0 : t.querySelector("[part=listbox]"), this.listboxSlot = (n = this.shadowRoot) == null ? void 0 : n.querySelector("slot[name=listbox]");
|
|
2937
2938
|
}
|
|
2938
2939
|
connectedCallback() {
|
|
2939
|
-
super.connectedCallback(), m(
|
|
2940
|
+
super.connectedCallback(), m(Co, this, To).call(this), this.setAttribute("aria-label", "Audio & Subtitles");
|
|
2940
2941
|
}
|
|
2941
2942
|
attributeChangedCallback(e, t, n) {
|
|
2942
|
-
super.attributeChangedCallback(e, t, n), (e === g.LANGUAGES || e === g.TEXT_TRACKS) && m(
|
|
2943
|
+
super.attributeChangedCallback(e, t, n), (e === g.LANGUAGES || e === g.TEXT_TRACKS) && m(Co, this, To).call(this);
|
|
2943
2944
|
}
|
|
2944
2945
|
};
|
|
2945
|
-
|
|
2946
|
-
function
|
|
2946
|
+
bo = wo;
|
|
2947
|
+
function To() {
|
|
2947
2948
|
let e = (e) => (e ? JSON.parse(e) : []).length < 2, t = e(this.getAttribute(g.LANGUAGES)), n = e(this.getAttribute(g.TEXT_TRACKS));
|
|
2948
2949
|
t && n ? this.setAttribute("hidden", "") : this.removeAttribute("hidden");
|
|
2949
2950
|
}
|
|
2950
|
-
e(
|
|
2951
|
-
...y(
|
|
2951
|
+
e(wo, "observedAttributes", [
|
|
2952
|
+
...y(bo, "observedAttributes", bo),
|
|
2952
2953
|
g.LANGUAGES,
|
|
2953
2954
|
g.TEXT_TRACKS
|
|
2954
2955
|
]);
|
|
2955
2956
|
//#endregion
|
|
2956
2957
|
//#region ../../libs/player-next/src/components/LanguageMenuList.ts
|
|
2957
|
-
var
|
|
2958
|
-
|
|
2958
|
+
var Eo = document.createElement("template");
|
|
2959
|
+
Eo.innerHTML = `
|
|
2959
2960
|
<style>
|
|
2960
2961
|
:host {
|
|
2961
2962
|
font: inherit;
|
|
@@ -3069,21 +3070,21 @@ Co.innerHTML = `
|
|
|
3069
3070
|
<div class="menu"></div>
|
|
3070
3071
|
</div>
|
|
3071
3072
|
`;
|
|
3072
|
-
var
|
|
3073
|
+
var Do = /* @__PURE__ */ new WeakMap(), Oo = /* @__PURE__ */ new WeakMap(), ko = /* @__PURE__ */ new WeakMap(), Ao = /* @__PURE__ */ new WeakMap(), jo = /* @__PURE__ */ new WeakMap(), G = /* @__PURE__ */ new WeakMap(), Mo = /* @__PURE__ */ new WeakMap(), No = /* @__PURE__ */ new WeakMap(), Po = /* @__PURE__ */ new WeakMap(), Fo = /* @__PURE__ */ new WeakMap(), Io = /* @__PURE__ */ new WeakMap(), Lo = /* @__PURE__ */ new WeakMap(), K = /* @__PURE__ */ new WeakSet(), Ro = class extends HTMLElement {
|
|
3073
3074
|
constructor() {
|
|
3074
|
-
super(), S(this, K), f(this,
|
|
3075
|
+
super(), S(this, K), f(this, Do, []), f(this, Oo, []), f(this, ko, void 0), f(this, Ao, void 0), f(this, jo, []), f(this, G, []), f(this, Mo, null), f(this, No, null), f(this, Po, null), f(this, Fo, null), f(this, Io, null), f(this, Lo, null), e(this, "handleEvent", (e) => {
|
|
3075
3076
|
switch (e.type) {
|
|
3076
3077
|
case "keydown":
|
|
3077
|
-
m(K, this,
|
|
3078
|
+
m(K, this, qo).call(this, e);
|
|
3078
3079
|
break;
|
|
3079
3080
|
}
|
|
3080
|
-
}), this.attachShadow({ mode: "open" }).appendChild(
|
|
3081
|
+
}), this.attachShadow({ mode: "open" }).appendChild(Eo.content.cloneNode(!0));
|
|
3081
3082
|
}
|
|
3082
3083
|
connectedCallback() {
|
|
3083
3084
|
let e = this.getRootNode();
|
|
3084
3085
|
if (e instanceof ShadowRoot) {
|
|
3085
3086
|
var t, n, r;
|
|
3086
|
-
p(
|
|
3087
|
+
p(Po, this, e.host.closest("vindral-controller")), (t = h(Po, this)) == null || t.connectListener(this), p(Mo, this, (n = this.shadowRoot) == null ? void 0 : n.querySelector("#languages .menu")), p(No, this, (r = this.shadowRoot) == null ? void 0 : r.querySelector("#text-tracks .menu")), m(K, this, zo).call(this), m(K, this, Bo).call(this), p(Fo, this, e.host), this.addEventListener("keydown", this);
|
|
3087
3088
|
}
|
|
3088
3089
|
}
|
|
3089
3090
|
disconnectedCallback() {
|
|
@@ -3093,16 +3094,16 @@ var wo = /* @__PURE__ */ new WeakMap(), To = /* @__PURE__ */ new WeakMap(), Eo =
|
|
|
3093
3094
|
t !== n && (e === g.LANGUAGES && n && (this.languages = JSON.parse(n)), e === g.TEXT_TRACKS && n && (this.textTracks = JSON.parse(n)), e === g.LANGUAGE && (this.language = n), e === g.TEXT_TRACK && (this.textTrack = n));
|
|
3094
3095
|
}
|
|
3095
3096
|
set languages(e) {
|
|
3096
|
-
p(
|
|
3097
|
+
p(Do, this, e), m(K, this, Ho).call(this), m(K, this, Wo).call(this);
|
|
3097
3098
|
}
|
|
3098
3099
|
set textTracks(e) {
|
|
3099
|
-
p(
|
|
3100
|
+
p(Oo, this, e), m(K, this, Vo).call(this), m(K, this, Go).call(this);
|
|
3100
3101
|
}
|
|
3101
3102
|
set language(e) {
|
|
3102
|
-
p(
|
|
3103
|
+
p(ko, this, e), m(K, this, Wo).call(this);
|
|
3103
3104
|
}
|
|
3104
3105
|
set textTrack(e) {
|
|
3105
|
-
p(
|
|
3106
|
+
p(Ao, this, e), m(K, this, Go).call(this);
|
|
3106
3107
|
}
|
|
3107
3108
|
get keysUsed() {
|
|
3108
3109
|
return [
|
|
@@ -3119,10 +3120,10 @@ var wo = /* @__PURE__ */ new WeakMap(), To = /* @__PURE__ */ new WeakMap(), Eo =
|
|
|
3119
3120
|
];
|
|
3120
3121
|
}
|
|
3121
3122
|
focus() {
|
|
3122
|
-
h(
|
|
3123
|
+
h(Io, this) ? h(Io, this).focus() : h(Lo, this) && h(Lo, this).focus();
|
|
3123
3124
|
}
|
|
3124
3125
|
};
|
|
3125
|
-
function
|
|
3126
|
+
function zo() {
|
|
3126
3127
|
new IntersectionObserver((e) => {
|
|
3127
3128
|
e.forEach((e) => {
|
|
3128
3129
|
if (e.intersectionRatio !== 1) if (e.intersectionRatio > 0) {
|
|
@@ -3131,55 +3132,55 @@ function Io() {
|
|
|
3131
3132
|
} else this.style.height = "auto";
|
|
3132
3133
|
});
|
|
3133
3134
|
}, {
|
|
3134
|
-
root: h(
|
|
3135
|
+
root: h(Po, this),
|
|
3135
3136
|
threshold: 0
|
|
3136
3137
|
}).observe(this);
|
|
3137
3138
|
}
|
|
3138
|
-
function
|
|
3139
|
-
h(
|
|
3139
|
+
function Bo() {
|
|
3140
|
+
h(Mo, this) && (m(K, this, Ho).call(this), m(K, this, Wo).call(this)), h(No, this) && (m(K, this, Vo).call(this), m(K, this, Go).call(this));
|
|
3140
3141
|
}
|
|
3141
|
-
function
|
|
3142
|
-
h(
|
|
3143
|
-
let e = m(K, this,
|
|
3144
|
-
h(
|
|
3142
|
+
function Vo() {
|
|
3143
|
+
h(No, this).innerHTML = "", p(G, this, []);
|
|
3144
|
+
let e = m(K, this, Uo).call(this, "Off", "textTrack", void 0);
|
|
3145
|
+
h(No, this).appendChild(e), h(G, this).push({
|
|
3145
3146
|
element: e,
|
|
3146
3147
|
value: void 0
|
|
3147
|
-
}), h(
|
|
3148
|
-
let t = m(K, this,
|
|
3149
|
-
h(
|
|
3148
|
+
}), h(Oo, this).forEach((e) => {
|
|
3149
|
+
let t = m(K, this, Uo).call(this, e, "textTrack", e);
|
|
3150
|
+
h(No, this).appendChild(t), h(G, this).push({
|
|
3150
3151
|
element: t,
|
|
3151
3152
|
value: e
|
|
3152
3153
|
});
|
|
3153
|
-
}), m(K, this,
|
|
3154
|
+
}), m(K, this, Go).call(this);
|
|
3154
3155
|
}
|
|
3155
|
-
function
|
|
3156
|
-
h(
|
|
3157
|
-
let t = m(K, this,
|
|
3158
|
-
h(
|
|
3156
|
+
function Ho() {
|
|
3157
|
+
h(Mo, this).innerHTML = "", p(jo, this, []), h(Do, this).forEach((e) => {
|
|
3158
|
+
let t = m(K, this, Uo).call(this, e, "language", e);
|
|
3159
|
+
h(Mo, this).appendChild(t), h(jo, this).push({
|
|
3159
3160
|
element: t,
|
|
3160
3161
|
value: e
|
|
3161
3162
|
});
|
|
3162
|
-
}), m(K, this,
|
|
3163
|
+
}), m(K, this, Wo).call(this);
|
|
3163
3164
|
}
|
|
3164
|
-
function
|
|
3165
|
+
function Uo(e, t, n) {
|
|
3165
3166
|
let r = document.createElement("div");
|
|
3166
|
-
return r.setAttribute("role", "menuitem"), r.textContent = e, r.addEventListener("click", () => m(K, this,
|
|
3167
|
+
return r.setAttribute("role", "menuitem"), r.textContent = e, r.addEventListener("click", () => m(K, this, Ko).call(this, n, t)), r;
|
|
3167
3168
|
}
|
|
3168
|
-
function
|
|
3169
|
-
h(
|
|
3170
|
-
let e = h(
|
|
3171
|
-
e && (e.element.setAttribute("aria-selected", "true"), e.element.tabIndex = 0, p(
|
|
3169
|
+
function Wo() {
|
|
3170
|
+
h(Io, this) && (h(Io, this).removeAttribute("aria-selected"), h(Io, this).tabIndex = -1);
|
|
3171
|
+
let e = h(jo, this).find((e) => e.value === h(ko, this));
|
|
3172
|
+
e && (e.element.setAttribute("aria-selected", "true"), e.element.tabIndex = 0, p(Io, this, e.element));
|
|
3172
3173
|
}
|
|
3173
|
-
function
|
|
3174
|
-
h(
|
|
3175
|
-
let e = h(G, this).find((e) => e.value === h(
|
|
3176
|
-
if (e) e.element.setAttribute("aria-selected", "true"), e.element.tabIndex = 0, p(
|
|
3174
|
+
function Go() {
|
|
3175
|
+
h(Lo, this) && (h(Lo, this).removeAttribute("aria-selected"), h(Lo, this).tabIndex = -1);
|
|
3176
|
+
let e = h(G, this).find((e) => e.value === h(Ao, this));
|
|
3177
|
+
if (e) e.element.setAttribute("aria-selected", "true"), e.element.tabIndex = 0, p(Lo, this, e.element);
|
|
3177
3178
|
else {
|
|
3178
3179
|
let e = h(G, this).find((e) => e.value === void 0);
|
|
3179
|
-
e && (e.element.setAttribute("aria-selected", "true"), e.element.tabIndex = 0, p(
|
|
3180
|
+
e && (e.element.setAttribute("aria-selected", "true"), e.element.tabIndex = 0, p(Lo, this, e.element));
|
|
3180
3181
|
}
|
|
3181
3182
|
}
|
|
3182
|
-
function
|
|
3183
|
+
function Ko(e, t) {
|
|
3183
3184
|
this.dispatchEvent(new Event("change", {
|
|
3184
3185
|
bubbles: !0,
|
|
3185
3186
|
composed: !0
|
|
@@ -3191,36 +3192,36 @@ function Uo(e, t) {
|
|
|
3191
3192
|
detail: e
|
|
3192
3193
|
}));
|
|
3193
3194
|
}
|
|
3194
|
-
function
|
|
3195
|
+
function qo(e) {
|
|
3195
3196
|
let { key: t, ctrlKey: n, altKey: r, metaKey: i } = e;
|
|
3196
3197
|
if (!(n || r || i) && this.keysUsed.includes(t)) if (e.preventDefault(), e.stopPropagation(), t === "Tab" || t === "Escape") {
|
|
3197
3198
|
var a;
|
|
3198
|
-
(a = h(
|
|
3199
|
+
(a = h(Fo, this)) == null || a.hide();
|
|
3199
3200
|
} else if (t === "Enter" || t === " ") {
|
|
3200
3201
|
var o;
|
|
3201
|
-
(o = m(K, this,
|
|
3202
|
-
} else m(K, this,
|
|
3202
|
+
(o = m(K, this, Xo).call(this)) == null || (o = o.element) == null || o.click();
|
|
3203
|
+
} else m(K, this, Jo).call(this, e);
|
|
3203
3204
|
}
|
|
3204
|
-
function
|
|
3205
|
+
function Jo(e) {
|
|
3205
3206
|
var t;
|
|
3206
|
-
let { key: n } = e, r = [...h(
|
|
3207
|
+
let { key: n } = e, r = [...h(jo, this), ...h(G, this)], i = (t = m(K, this, Xo).call(this)) == null ? r[0] : t;
|
|
3207
3208
|
if (!i) return;
|
|
3208
3209
|
let a = r.indexOf(i), o = Math.max(0, a);
|
|
3209
|
-
n === "ArrowDown" ? o++ : n === "ArrowUp" ? o-- : n === "ArrowLeft" ? o = m(K, this,
|
|
3210
|
+
n === "ArrowDown" ? o++ : n === "ArrowUp" ? o-- : n === "ArrowLeft" ? o = m(K, this, Yo).call(this, a, "left") : n === "ArrowRight" ? o = m(K, this, Yo).call(this, a, "right") : e.key === "Home" ? o = 0 : e.key === "End" && (o = r.length - 1), o < 0 && (o = r.length - 1), o > r.length - 1 && (o = 0);
|
|
3210
3211
|
let s = r[o];
|
|
3211
|
-
s && (m(K, this,
|
|
3212
|
+
s && (m(K, this, Zo).call(this, s.value), s.element.focus());
|
|
3212
3213
|
}
|
|
3213
|
-
function
|
|
3214
|
-
let n = h(
|
|
3214
|
+
function Yo(e, t) {
|
|
3215
|
+
let n = h(jo, this).length, r = h(G, this).length;
|
|
3215
3216
|
return t === "left" ? e < n ? n + r - 1 : e - n - 1 : e >= n ? 0 : e + n;
|
|
3216
3217
|
}
|
|
3217
|
-
function
|
|
3218
|
-
return [...h(
|
|
3218
|
+
function Xo() {
|
|
3219
|
+
return [...h(jo, this), ...h(G, this)].find((e) => e.element.tabIndex === 0);
|
|
3219
3220
|
}
|
|
3220
|
-
function
|
|
3221
|
-
for (let t of [...h(
|
|
3221
|
+
function Zo(e) {
|
|
3222
|
+
for (let t of [...h(jo, this), ...h(G, this)]) t.element.tabIndex = t.value === e ? 0 : -1;
|
|
3222
3223
|
}
|
|
3223
|
-
e(
|
|
3224
|
+
e(Ro, "observedAttributes", [
|
|
3224
3225
|
g.LANGUAGES,
|
|
3225
3226
|
g.TEXT_TRACKS,
|
|
3226
3227
|
g.LANGUAGE,
|
|
@@ -3228,12 +3229,12 @@ e(Fo, "observedAttributes", [
|
|
|
3228
3229
|
]);
|
|
3229
3230
|
//#endregion
|
|
3230
3231
|
//#region ../../libs/player-next/src/components/LiveButton.ts
|
|
3231
|
-
var
|
|
3232
|
-
|
|
3233
|
-
var
|
|
3232
|
+
var Qo, $o = document.createElement("template");
|
|
3233
|
+
$o.innerHTML = "\n <style>\n :host {\n display: var(--live-button-display, flex);\n color: var(--vindral-fg-strong, #eee);\n border: 1px solid transparent !important;\n font-size: 12px;\n font-weight: bold;\n cursor: pointer;\n transition: all 0.2s;\n min-width: 50px !important;\n text-align: center;\n align-items: center;\n justify-content: center;\n }\n\n .live-text {\n display: inline-block;\n vertical-align: middle;\n margin-left: 4px;\n }\n\n slot[name=\"icon\"] svg {\n width: 5px;\n height: 5px;\n flex-shrink: 0;\n }\n\n .live-dot {\n fill: var(--vindral-fg-subtle, #b4b4b4);\n transition: fill 0.2s;\n transform-origin: center;\n }\n\n /* Red pulsing dot when live */\n :host(:not([timeshift-position])) .live-dot {\n fill: #ff0000;\n animation: pulse-dot 2s ease-in-out infinite alternate;\n }\n\n @keyframes pulse-dot {\n 0% {\n opacity: 0.8;\n transform: scale(0.9);\n }\n 100% {\n opacity: 1;\n transform: scale(1);\n }\n }\n\n :host([disabled]) {\n cursor: default;\n opacity: 1;\n }\n\n :host([hidden]) {\n display: none !important;\n }\n </style>\n\n <slot name=\"icon\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" width=\"5\" height=\"5\" viewBox=\"0 0 5 5\" fill=\"currentColor\">\n <circle cx=\"2.5\" cy=\"2.5\" r=\"2.5\" class=\"live-dot\"/>\n </svg>\n</slot>\n <span class=\"live-text\">LIVE</span>\n";
|
|
3234
|
+
var es = class extends v {
|
|
3234
3235
|
constructor() {
|
|
3235
3236
|
var e;
|
|
3236
|
-
super(), (e = this.shadowRoot) == null || e.appendChild(
|
|
3237
|
+
super(), (e = this.shadowRoot) == null || e.appendChild($o.content.cloneNode(!0));
|
|
3237
3238
|
}
|
|
3238
3239
|
connectedCallback() {
|
|
3239
3240
|
super.connectedCallback(), this.updateState();
|
|
@@ -3264,15 +3265,15 @@ var Zo = class extends v {
|
|
|
3264
3265
|
}));
|
|
3265
3266
|
}
|
|
3266
3267
|
};
|
|
3267
|
-
|
|
3268
|
-
...y(
|
|
3268
|
+
Qo = es, e(es, "observedAttributes", [
|
|
3269
|
+
...y(Qo, "observedAttributes", Qo),
|
|
3269
3270
|
g.TIMESHIFT_POSITION,
|
|
3270
3271
|
g.DURATION
|
|
3271
3272
|
]);
|
|
3272
3273
|
//#endregion
|
|
3273
3274
|
//#region ../../libs/player-next/src/components/MuteButton.ts
|
|
3274
|
-
var
|
|
3275
|
-
|
|
3275
|
+
var ts, ns = document.createElement("template");
|
|
3276
|
+
ns.innerHTML = `
|
|
3276
3277
|
<style>
|
|
3277
3278
|
:host {
|
|
3278
3279
|
display: var(--mute-button-display);
|
|
@@ -3300,10 +3301,10 @@ $o.innerHTML = `
|
|
|
3300
3301
|
</slot>
|
|
3301
3302
|
</slot>
|
|
3302
3303
|
`;
|
|
3303
|
-
var
|
|
3304
|
+
var rs = class extends v {
|
|
3304
3305
|
constructor() {
|
|
3305
3306
|
var e;
|
|
3306
|
-
super(), (e = this.shadowRoot) == null || e.appendChild(
|
|
3307
|
+
super(), (e = this.shadowRoot) == null || e.appendChild(ns.content.cloneNode(!0));
|
|
3307
3308
|
}
|
|
3308
3309
|
connectedCallback() {
|
|
3309
3310
|
super.connectedCallback(), this.setAttribute("aria-label", this.muted ? "Unmute" : "Mute");
|
|
@@ -3328,11 +3329,11 @@ var es = class extends v {
|
|
|
3328
3329
|
}));
|
|
3329
3330
|
}
|
|
3330
3331
|
};
|
|
3331
|
-
|
|
3332
|
+
ts = rs, e(rs, "observedAttributes", [...y(ts, "observedAttributes", ts), g.MUTED]);
|
|
3332
3333
|
//#endregion
|
|
3333
3334
|
//#region ../../libs/player-next/src/components/PictureInPictureButton.ts
|
|
3334
|
-
var
|
|
3335
|
-
|
|
3335
|
+
var is, as = document.createElement("template");
|
|
3336
|
+
as.innerHTML = `
|
|
3336
3337
|
<style>
|
|
3337
3338
|
:host {
|
|
3338
3339
|
display: var(--pip-button-display);
|
|
@@ -3346,10 +3347,10 @@ ns.innerHTML = `
|
|
|
3346
3347
|
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="currentColor"><path stroke="none" d="M0 0h24v24H0z" fill="none"/><path d="M19 4a3 3 0 0 1 3 3v4a1 1 0 0 1 -2 0v-4a1 1 0 0 0 -1 -1h-14a1 1 0 0 0 -1 1v10a1 1 0 0 0 1 1h6a1 1 0 0 1 0 2h-6a3 3 0 0 1 -3 -3v-10a3 3 0 0 1 3 -3z" /><path d="M20 13a2 2 0 0 1 2 2v3a2 2 0 0 1 -2 2h-5a2 2 0 0 1 -2 -2v-3a2 2 0 0 1 2 -2z" /></svg>
|
|
3347
3348
|
</slot>
|
|
3348
3349
|
`;
|
|
3349
|
-
var
|
|
3350
|
+
var os = class extends v {
|
|
3350
3351
|
constructor() {
|
|
3351
3352
|
var e;
|
|
3352
|
-
super(), (e = this.shadowRoot) == null || e.appendChild(
|
|
3353
|
+
super(), (e = this.shadowRoot) == null || e.appendChild(as.content.cloneNode(!0));
|
|
3353
3354
|
}
|
|
3354
3355
|
connectedCallback() {
|
|
3355
3356
|
super.connectedCallback(), this.setAttribute("aria-label", this.isPictureInPictureActive ? "Exit picture-in-picture" : "Picture-in-picture");
|
|
@@ -3374,15 +3375,15 @@ var rs = class extends v {
|
|
|
3374
3375
|
}));
|
|
3375
3376
|
}
|
|
3376
3377
|
};
|
|
3377
|
-
|
|
3378
|
-
...y(
|
|
3378
|
+
is = os, e(os, "observedAttributes", [
|
|
3379
|
+
...y(is, "observedAttributes", is),
|
|
3379
3380
|
g.IS_PIP,
|
|
3380
3381
|
g.PIP_AVAILABLE
|
|
3381
3382
|
]);
|
|
3382
3383
|
//#endregion
|
|
3383
3384
|
//#region ../../libs/player-next/src/components/PlayButton.ts
|
|
3384
|
-
var
|
|
3385
|
-
|
|
3385
|
+
var ss, cs = document.createElement("template");
|
|
3386
|
+
cs.innerHTML = `
|
|
3386
3387
|
<style>
|
|
3387
3388
|
:host {
|
|
3388
3389
|
display: var(--play-button-display);
|
|
@@ -3406,10 +3407,10 @@ as.innerHTML = `
|
|
|
3406
3407
|
</slot>
|
|
3407
3408
|
</slot>
|
|
3408
3409
|
`;
|
|
3409
|
-
var
|
|
3410
|
+
var ls = class extends v {
|
|
3410
3411
|
constructor() {
|
|
3411
3412
|
var e;
|
|
3412
|
-
super(), (e = this.shadowRoot) == null || e.appendChild(
|
|
3413
|
+
super(), (e = this.shadowRoot) == null || e.appendChild(cs.content.cloneNode(!0));
|
|
3413
3414
|
}
|
|
3414
3415
|
connectedCallback() {
|
|
3415
3416
|
super.connectedCallback(), this.setAttribute("aria-label", this.paused ? "Play" : "Pause");
|
|
@@ -3434,7 +3435,7 @@ var os = class extends v {
|
|
|
3434
3435
|
}));
|
|
3435
3436
|
}
|
|
3436
3437
|
};
|
|
3437
|
-
|
|
3438
|
+
ss = ls, e(ls, "observedAttributes", [...y(ss, "observedAttributes", ss), g.PAUSED]);
|
|
3438
3439
|
//#endregion
|
|
3439
3440
|
//#region ../../libs/player-next/src/PlayerAttributes.ts
|
|
3440
3441
|
var q = {
|
|
@@ -3443,55 +3444,55 @@ var q = {
|
|
|
3443
3444
|
ADVANCED_RENDITION_MENU_ENABLED: "advanced-rendition-menu-enabled",
|
|
3444
3445
|
REFRESH_POSTER_ENABLED: "refresh-poster-enabled",
|
|
3445
3446
|
STREAM_POLL_ENABLED: "stream-poll-enabled"
|
|
3446
|
-
},
|
|
3447
|
+
}, us = Object.values(q), ds = /* @__PURE__ */ new WeakMap(), fs = /* @__PURE__ */ new WeakMap(), ps = /* @__PURE__ */ new WeakMap(), ms = /* @__PURE__ */ new WeakMap(), hs = /* @__PURE__ */ new WeakMap(), gs = /* @__PURE__ */ new WeakMap(), _s = /* @__PURE__ */ new WeakMap(), vs = /* @__PURE__ */ new WeakSet(), ys = class extends pe {
|
|
3447
3448
|
constructor(e) {
|
|
3448
|
-
super(), S(this,
|
|
3449
|
+
super(), S(this, vs), f(this, ds, void 0), f(this, fs, void 0), f(this, ps, !1), f(this, ms, !1), f(this, hs, !0), f(this, gs, null), f(this, _s, null), p(fs, this, e), p(ds, this, new de({
|
|
3449
3450
|
publicEndpoint: e.url,
|
|
3450
3451
|
tokenFactory: () => e.authenticationToken
|
|
3451
3452
|
}));
|
|
3452
3453
|
}
|
|
3453
3454
|
start(e = 5e3) {
|
|
3454
|
-
h(
|
|
3455
|
-
!h(
|
|
3455
|
+
h(_s, this) && clearInterval(h(_s, this)), p(ps, this, !1), p(ms, this, !1), m(vs, this, Cs).call(this), m(vs, this, bs).call(this), p(_s, this, window.setInterval(() => {
|
|
3456
|
+
!h(ms, this) && !h(fs, this).infiniteReconnect && !h(gs, this) && h(hs, this) && p(gs, this, window.setTimeout(() => m(vs, this, xs).call(this), 300 * 1e3)), !h(ms, this) && h(hs, this) && m(vs, this, bs).call(this);
|
|
3456
3457
|
}, e));
|
|
3457
3458
|
}
|
|
3458
3459
|
stop() {
|
|
3459
|
-
m(
|
|
3460
|
+
m(vs, this, Ss).call(this), h(_s, this) && (window.clearInterval(h(_s, this)), p(_s, this, null));
|
|
3460
3461
|
}
|
|
3461
3462
|
};
|
|
3462
|
-
function
|
|
3463
|
+
function bs() {
|
|
3463
3464
|
var e = this;
|
|
3464
3465
|
return t(function* () {
|
|
3465
|
-
if (h(
|
|
3466
|
-
p(
|
|
3466
|
+
if (h(ps, e)) return;
|
|
3467
|
+
p(ps, e, !0);
|
|
3467
3468
|
let t = "Stream is offline", n = "Please stand by";
|
|
3468
3469
|
try {
|
|
3469
|
-
let t = yield h(
|
|
3470
|
+
let t = yield h(ds, e).getChannel(h(fs, e).channelId);
|
|
3470
3471
|
if (t.isLive) {
|
|
3471
|
-
p(
|
|
3472
|
+
p(ms, e, !0), m(vs, e, Cs).call(e), e.emit("live", t), p(ps, e, !1);
|
|
3472
3473
|
return;
|
|
3473
3474
|
}
|
|
3474
3475
|
} catch (e) {
|
|
3475
3476
|
ue(e) && (e.status === 403 || e.status === 401) && (t = "Forbidden", n = "You do not have permission to view this stream");
|
|
3476
3477
|
}
|
|
3477
|
-
h(
|
|
3478
|
+
h(hs, e) && e.emit("error", {
|
|
3478
3479
|
title: t,
|
|
3479
3480
|
message: n
|
|
3480
|
-
}), p(
|
|
3481
|
+
}), p(ps, e, !1);
|
|
3481
3482
|
})();
|
|
3482
3483
|
}
|
|
3483
|
-
function
|
|
3484
|
-
this.stop(), p(
|
|
3484
|
+
function xs() {
|
|
3485
|
+
this.stop(), p(hs, this, !1), this.emit("timeout");
|
|
3485
3486
|
}
|
|
3486
|
-
function
|
|
3487
|
-
h(
|
|
3487
|
+
function Ss() {
|
|
3488
|
+
h(gs, this) && (window.clearTimeout(h(gs, this)), p(gs, this, null));
|
|
3488
3489
|
}
|
|
3489
|
-
function
|
|
3490
|
-
m(
|
|
3490
|
+
function Cs() {
|
|
3491
|
+
m(vs, this, Ss).call(this), p(hs, this, !0);
|
|
3491
3492
|
}
|
|
3492
3493
|
//#endregion
|
|
3493
3494
|
//#region ../../libs/player-next/src/utils/browser.ts
|
|
3494
|
-
var
|
|
3495
|
+
var ws = /\/Mobile|iP(hone|od|ad)|Android|BlackBerry|IEMobile|Kindle|NetFront|Silk-Accelerated|(hpw|web)OS|Fennec|Minimo|Opera M(obi|ini)|Blazer|Dolfin|Dolphin|Skyfire|Zune\//i, Ts = navigator.userAgent.toLowerCase(), Es = ws.test(Ts), Ds = (e) => Oa.observedAttributes.includes(e), Os = `
|
|
3495
3496
|
<style>
|
|
3496
3497
|
:host {
|
|
3497
3498
|
container-type: inline-size;
|
|
@@ -3501,7 +3502,7 @@ var xs = /\/Mobile|iP(hone|od|ad)|Android|BlackBerry|IEMobile|Kindle|NetFront|Si
|
|
|
3501
3502
|
display: flex;
|
|
3502
3503
|
justify-content: center;
|
|
3503
3504
|
|
|
3504
|
-
--vindral-volume-range-display: ${
|
|
3505
|
+
--vindral-volume-range-display: ${Es ? "none" : "flex"};
|
|
3505
3506
|
--vindral-airplay-button-display: none;
|
|
3506
3507
|
--vindral-play-overlay-display: none;
|
|
3507
3508
|
--vindral-grid-item-offline-display: none;
|
|
@@ -3582,10 +3583,10 @@ var xs = /\/Mobile|iP(hone|od|ad)|Android|BlackBerry|IEMobile|Kindle|NetFront|Si
|
|
|
3582
3583
|
--vindral-subtitle-offset: -48px;
|
|
3583
3584
|
}
|
|
3584
3585
|
</style>
|
|
3585
|
-
`,
|
|
3586
|
+
`, ks = (e) => {
|
|
3586
3587
|
let t = e ? "vindral-advanced-rendition-menu" : "vindral-rendition-levels-menu";
|
|
3587
3588
|
return `
|
|
3588
|
-
${
|
|
3589
|
+
${Os}
|
|
3589
3590
|
|
|
3590
3591
|
<vindral-controller>
|
|
3591
3592
|
<vindral-control-bar slot="top-bar">
|
|
@@ -3623,8 +3624,8 @@ var xs = /\/Mobile|iP(hone|od|ad)|Android|BlackBerry|IEMobile|Kindle|NetFront|Si
|
|
|
3623
3624
|
</vindral-center-overlay>
|
|
3624
3625
|
</vindral-controller>
|
|
3625
3626
|
`;
|
|
3626
|
-
},
|
|
3627
|
-
${
|
|
3627
|
+
}, As = `
|
|
3628
|
+
${Os}
|
|
3628
3629
|
|
|
3629
3630
|
<style>
|
|
3630
3631
|
#control-bar {
|
|
@@ -3648,52 +3649,52 @@ var xs = /\/Mobile|iP(hone|od|ad)|Android|BlackBerry|IEMobile|Kindle|NetFront|Si
|
|
|
3648
3649
|
<vindral-play-overlay id="play-overlay" hidden></vindral-play-overlay>
|
|
3649
3650
|
</vindral-center-overlay>
|
|
3650
3651
|
</vindral-controller>
|
|
3651
|
-
`,
|
|
3652
|
+
`, js = document.createElement("template"), Ms = /* @__PURE__ */ new WeakMap(), J = /* @__PURE__ */ new WeakMap(), Ns = /* @__PURE__ */ new WeakMap(), Ps = /* @__PURE__ */ new WeakMap(), Fs = /* @__PURE__ */ new WeakMap(), Is = /* @__PURE__ */ new WeakMap(), Ls = /* @__PURE__ */ new WeakMap(), Rs = /* @__PURE__ */ new WeakMap(), zs = /* @__PURE__ */ new WeakMap(), Y = /* @__PURE__ */ new WeakSet(), Bs = /* @__PURE__ */ new WeakMap(), Vs = /* @__PURE__ */ new WeakMap(), Hs = /* @__PURE__ */ new WeakMap(), Us = class extends HTMLElement {
|
|
3652
3653
|
constructor() {
|
|
3653
|
-
super(), S(this, Y), f(this,
|
|
3654
|
+
super(), S(this, Y), f(this, Ms, void 0), f(this, J, void 0), f(this, Ns, void 0), f(this, Ps, void 0), f(this, Fs, void 0), f(this, Is, void 0), f(this, Ls, /* @__PURE__ */ new Set()), f(this, Rs, () => {
|
|
3654
3655
|
Array.from(this.attributes).forEach((e) => {
|
|
3655
|
-
h(
|
|
3656
|
+
h(zs, this).call(this, e.name, e.value);
|
|
3656
3657
|
});
|
|
3657
|
-
}), f(this,
|
|
3658
|
-
|
|
3659
|
-
}), f(this,
|
|
3658
|
+
}), f(this, zs, (e, t) => {
|
|
3659
|
+
Ds(e) && (_(t) ? h(J, this).setAttribute(e, t) : h(J, this).removeAttribute(e));
|
|
3660
|
+
}), f(this, Bs, () => {
|
|
3660
3661
|
Array.from(this.children).forEach((e) => {
|
|
3661
|
-
h(
|
|
3662
|
+
h(Ls, this).add(e);
|
|
3662
3663
|
});
|
|
3663
|
-
}), f(this,
|
|
3664
|
+
}), f(this, Vs, () => {
|
|
3664
3665
|
let e = h(J, this).instance;
|
|
3665
3666
|
e && (e.on("is live", (e) => {
|
|
3666
|
-
e ? (this.removeAttribute(q.OFFLINE), m(Y, this,
|
|
3667
|
+
e ? (this.removeAttribute(q.OFFLINE), m(Y, this, Xs).call(this)) : (this.setAttribute(q.OFFLINE, ""), m(Y, this, Ys).call(this, "Stream is offline", "Please stand by"));
|
|
3667
3668
|
}), e.on("channels", (e) => {
|
|
3668
3669
|
let t = h(J, this).getAttribute("channel-id"), n = e.find((e) => e.channelId === t);
|
|
3669
|
-
n && m(Y, this,
|
|
3670
|
+
n && m(Y, this, qs).call(this, n);
|
|
3670
3671
|
}), e.on("channel switch", ({ channelId: t }) => {
|
|
3671
3672
|
let n = e.channels.find((e) => e.channelId === t);
|
|
3672
|
-
n && m(Y, this,
|
|
3673
|
+
n && m(Y, this, qs).call(this, n);
|
|
3673
3674
|
}), e.on("error", (e) => {
|
|
3674
3675
|
if (e.code() === "connection_failed") {
|
|
3675
|
-
m(Y, this,
|
|
3676
|
+
m(Y, this, Ys).call(this, "Stream is offline", "Please stand by");
|
|
3676
3677
|
return;
|
|
3677
3678
|
}
|
|
3678
|
-
e.isFatal() && (e.code() === "access_forbidden" ? m(Y, this,
|
|
3679
|
+
e.isFatal() && (e.code() === "access_forbidden" ? m(Y, this, Ys).call(this, "Forbidden", "You do not have permission to view this stream") : e.code() === "connection_failed_will_not_attempt_again" ? m(Y, this, Ys).call(this, "Stream is offline", "Please stand by") : m(Y, this, Ys).call(this, "An error occurred", e.message), h(Ps, this).removeAttribute("hidden"), this.setAttribute(q.OFFLINE, ""), h(J, this).dispatchEvent(new CustomEvent(x.EXIT_FULLSCREEN)), h(J, this).dispatchEvent(new CustomEvent(x.EXIT_PIP)));
|
|
3679
3680
|
}));
|
|
3680
|
-
}), f(this,
|
|
3681
|
-
h(J, this).connect(), h(
|
|
3682
|
-
}), p(
|
|
3681
|
+
}), f(this, Hs, () => {
|
|
3682
|
+
h(J, this).connect(), h(Ps, this).setAttribute("hidden", ""), m(Y, this, Xs).call(this), h(J, this).focus();
|
|
3683
|
+
}), p(Ms, this, this.attachShadow({ mode: "open" })), m(Y, this, Gs).call(this), p(J, this, h(Ms, this).querySelector("vindral-controller")), p(Ns, this, h(Ms, this).querySelector("#vindral-message")), p(Ps, this, h(Ms, this).querySelector("#play-overlay")), p(Fs, this, h(Ms, this).querySelector("#center-overlay"));
|
|
3683
3684
|
}
|
|
3684
3685
|
connectedCallback() {
|
|
3685
|
-
this.setAttribute(q.OFFLINE, ""), h(J, this).addEventListener("vindral-instance-ready", h(
|
|
3686
|
+
this.setAttribute(q.OFFLINE, ""), h(J, this).addEventListener("vindral-instance-ready", h(Vs, this)), m(Y, this, Ks).call(this);
|
|
3686
3687
|
}
|
|
3687
3688
|
disconnectedCallback() {
|
|
3688
3689
|
var e;
|
|
3689
|
-
h(J, this).removeEventListener("vindral-instance-ready", h(
|
|
3690
|
+
h(J, this).removeEventListener("vindral-instance-ready", h(Vs, this)), h(Ps, this).removeEventListener("click", h(Hs, this)), (e = h(Is, this)) == null || e.stop();
|
|
3690
3691
|
}
|
|
3691
3692
|
attributeChangedCallback(e, t, n) {
|
|
3692
|
-
if (t !== n) if (e === g.MEDIA || e === q.ADVANCED_RENDITION_MENU_ENABLED) m(Y, this,
|
|
3693
|
+
if (t !== n) if (e === g.MEDIA || e === q.ADVANCED_RENDITION_MENU_ENABLED) m(Y, this, Gs).call(this);
|
|
3693
3694
|
else if (e === q.REFRESH_POSTER_ENABLED) {
|
|
3694
|
-
let e = h(
|
|
3695
|
+
let e = h(Ms, this).querySelector("vindral-poster-overlay");
|
|
3695
3696
|
e && (e.disabled = b(this.getAttribute(q.REFRESH_POSTER_ENABLED), !1) === !1);
|
|
3696
|
-
} else h(
|
|
3697
|
+
} else h(zs, this).call(this, e, n);
|
|
3697
3698
|
}
|
|
3698
3699
|
get instance() {
|
|
3699
3700
|
return h(J, this).instance;
|
|
@@ -3708,64 +3709,64 @@ var xs = /\/Mobile|iP(hone|od|ad)|Android|BlackBerry|IEMobile|Kindle|NetFront|Si
|
|
|
3708
3709
|
h(J, this).timelineMarkers = e;
|
|
3709
3710
|
}
|
|
3710
3711
|
};
|
|
3711
|
-
function
|
|
3712
|
+
function Ws() {
|
|
3712
3713
|
let e = xe(this.getAttribute(g.MEDIA)), t = b(this.getAttribute(q.ADVANCED_RENDITION_MENU_ENABLED), !1);
|
|
3713
|
-
return e === "audio" ?
|
|
3714
|
+
return e === "audio" ? As : ks(t);
|
|
3714
3715
|
}
|
|
3715
|
-
function
|
|
3716
|
-
let e = h(
|
|
3717
|
-
this.isConnected && t && t.removeEventListener("vindral-instance-ready", h(
|
|
3718
|
-
let r =
|
|
3719
|
-
p(J, this, r.querySelector("vindral-controller")), p(
|
|
3716
|
+
function Gs() {
|
|
3717
|
+
let e = h(Ms, this).hasChildNodes(), t = e ? h(J, this) : void 0, n = e ? h(Ps, this) : void 0;
|
|
3718
|
+
this.isConnected && t && t.removeEventListener("vindral-instance-ready", h(Vs, this)), this.isConnected && n && h(Is, this) && n.removeEventListener("click", h(Hs, this)), js.innerHTML = m(Y, this, Ws).call(this);
|
|
3719
|
+
let r = js.content.cloneNode(!0);
|
|
3720
|
+
p(J, this, r.querySelector("vindral-controller")), p(Ns, this, r.querySelector("#vindral-message")), p(Ps, this, r.querySelector("#play-overlay")), p(Fs, this, r.querySelector("#center-overlay")), h(Bs, this).call(this), h(Ls, this).forEach((e) => {
|
|
3720
3721
|
h(J, this).appendChild(e);
|
|
3721
|
-
}), h(
|
|
3722
|
+
}), h(Rs, this).call(this), h(Ms, this).innerHTML = "", h(Ms, this).appendChild(r), this.isConnected && (h(J, this).addEventListener("vindral-instance-ready", h(Vs, this)), h(Is, this) && h(Ps, this).addEventListener("click", h(Hs, this)));
|
|
3722
3723
|
}
|
|
3723
|
-
function
|
|
3724
|
+
function Ks() {
|
|
3724
3725
|
var e;
|
|
3725
3726
|
if (b(this.getAttribute(q.STREAM_POLL_ENABLED), !0) === !1) return;
|
|
3726
3727
|
let t = this.getAttribute("url") || "https://lb.cdn.vindral.com", n = this.getAttribute("channel-id"), r = (e = this.getAttribute("authentication-token")) == null ? void 0 : e, i = this.hasAttribute("infinite-reconnect");
|
|
3727
3728
|
if (!n) {
|
|
3728
|
-
this.setAttribute(q.OFFLINE, ""), m(Y, this,
|
|
3729
|
+
this.setAttribute(q.OFFLINE, ""), m(Y, this, Ys).call(this, "Invalid options", "Please enter a channel id to start the stream");
|
|
3729
3730
|
return;
|
|
3730
3731
|
}
|
|
3731
|
-
p(
|
|
3732
|
+
p(Is, this, new ys({
|
|
3732
3733
|
url: t,
|
|
3733
3734
|
channelId: n,
|
|
3734
3735
|
authenticationToken: r,
|
|
3735
3736
|
infiniteReconnect: i
|
|
3736
|
-
})), h(
|
|
3737
|
-
h(J, this).connect(), this.removeAttribute("offline"), m(Y, this,
|
|
3738
|
-
}), h(
|
|
3739
|
-
m(Y, this,
|
|
3740
|
-
}), h(
|
|
3741
|
-
this.setAttribute(q.OFFLINE, ""), m(Y, this,
|
|
3742
|
-
}), h(
|
|
3743
|
-
}
|
|
3744
|
-
function
|
|
3737
|
+
})), h(Is, this).on("live", (e) => {
|
|
3738
|
+
h(J, this).connect(), this.removeAttribute("offline"), m(Y, this, Xs).call(this), m(Y, this, qs).call(this, e);
|
|
3739
|
+
}), h(Is, this).on("timeout", () => {
|
|
3740
|
+
m(Y, this, Xs).call(this), h(Ps, this).removeAttribute("hidden");
|
|
3741
|
+
}), h(Is, this).on("error", (e) => {
|
|
3742
|
+
this.setAttribute(q.OFFLINE, ""), m(Y, this, Ys).call(this, e.title, e.message);
|
|
3743
|
+
}), h(Ps, this).addEventListener("click", h(Hs, this)), this.hasAttribute("paused") && h(Is, this).start();
|
|
3744
|
+
}
|
|
3745
|
+
function qs(e) {
|
|
3745
3746
|
var t, n, r;
|
|
3746
3747
|
let i = ve(this.getAttribute("title"), !1);
|
|
3747
3748
|
i && Me({
|
|
3748
3749
|
title: typeof i == "string" ? i : e.name,
|
|
3749
|
-
poster: (t = (n = m(Y, this,
|
|
3750
|
+
poster: (t = (n = m(Y, this, Js).call(this)) == null ? (r = this.instance) == null ? void 0 : r.getThumbnailUrl() : n) == null ? e.thumbnailUrls[0] : t
|
|
3750
3751
|
});
|
|
3751
3752
|
}
|
|
3752
|
-
function
|
|
3753
|
+
function Js() {
|
|
3753
3754
|
let e = ve(this.getAttribute("poster"));
|
|
3754
3755
|
return _(e) ? e : void 0;
|
|
3755
3756
|
}
|
|
3756
|
-
function
|
|
3757
|
-
h(
|
|
3758
|
-
let n = m(Y, this,
|
|
3759
|
-
n ? h(
|
|
3757
|
+
function Ys(e, t) {
|
|
3758
|
+
h(Ns, this).setAttribute("title", e), h(Ns, this).setAttribute("description", t), h(Ns, this).removeAttribute("hidden");
|
|
3759
|
+
let n = m(Y, this, Js).call(this);
|
|
3760
|
+
n ? h(Fs, this).setAttribute("poster", n) : h(Fs, this).removeAttribute("poster"), h(Fs, this).setAttribute("backdrop", "");
|
|
3760
3761
|
}
|
|
3761
|
-
function
|
|
3762
|
-
h(
|
|
3762
|
+
function Xs() {
|
|
3763
|
+
h(Ns, this).setAttribute("hidden", ""), h(Fs, this).removeAttribute("backdrop");
|
|
3763
3764
|
}
|
|
3764
|
-
e(
|
|
3765
|
+
e(Us, "observedAttributes", [...Oa.observedAttributes, ...us]);
|
|
3765
3766
|
//#endregion
|
|
3766
3767
|
//#region ../../libs/player-next/src/components/PosterOverlay.ts
|
|
3767
|
-
var
|
|
3768
|
-
|
|
3768
|
+
var Zs = document.createElement("template");
|
|
3769
|
+
Zs.innerHTML = `
|
|
3769
3770
|
<style>
|
|
3770
3771
|
:host {
|
|
3771
3772
|
display: var(--poster-overlay-display);
|
|
@@ -3800,26 +3801,26 @@ Js.innerHTML = `
|
|
|
3800
3801
|
}
|
|
3801
3802
|
</style>
|
|
3802
3803
|
`;
|
|
3803
|
-
var
|
|
3804
|
+
var Qs = 6e3, $s = /* @__PURE__ */ new WeakMap(), ec = /* @__PURE__ */ new WeakMap(), tc = /* @__PURE__ */ new WeakMap(), nc = /* @__PURE__ */ new WeakMap(), rc = /* @__PURE__ */ new WeakSet(), ic = /* @__PURE__ */ new WeakMap(), ac = class extends HTMLElement {
|
|
3804
3805
|
constructor() {
|
|
3805
|
-
super(), S(this,
|
|
3806
|
-
!document.hidden && this.hasAttribute("intersecting") && this.paused && !this.disabled ? m(
|
|
3807
|
-
}), f(this,
|
|
3806
|
+
super(), S(this, rc), f(this, $s, null), f(this, ec, null), f(this, tc, null), f(this, nc, () => {
|
|
3807
|
+
!document.hidden && this.hasAttribute("intersecting") && this.paused && !this.disabled ? m(rc, this, oc).call(this) : m(rc, this, sc).call(this);
|
|
3808
|
+
}), f(this, ic, (e) => {
|
|
3808
3809
|
e.forEach((e) => {
|
|
3809
3810
|
e.isIntersecting ? this.setAttribute("intersecting", "") : this.removeAttribute("intersecting");
|
|
3810
3811
|
});
|
|
3811
|
-
}), this.attachShadow({ mode: "open" }).appendChild(
|
|
3812
|
+
}), this.attachShadow({ mode: "open" }).appendChild(Zs.content.cloneNode(!0));
|
|
3812
3813
|
}
|
|
3813
3814
|
connectedCallback() {
|
|
3814
3815
|
var e;
|
|
3815
|
-
p(
|
|
3816
|
+
p($s, this, this.closest("vindral-controller")), (e = h($s, this)) == null || e.connectListener(this), document.addEventListener("visibilitychange", h(nc, this)), p(tc, this, new IntersectionObserver(h(ic, this))), h(tc, this).observe(this);
|
|
3816
3817
|
}
|
|
3817
3818
|
disconnectedCallback() {
|
|
3818
3819
|
var e, t;
|
|
3819
|
-
(e = h(
|
|
3820
|
+
(e = h($s, this)) == null || e.disconnectListener(this), document.removeEventListener("visibilitychange", h(nc, this)), (t = h(tc, this)) == null || t.disconnect(), p(tc, this, null), m(rc, this, sc).call(this);
|
|
3820
3821
|
}
|
|
3821
3822
|
attributeChangedCallback(e, t, n) {
|
|
3822
|
-
t !== n && (e === g.POSTER_SRC && this.paused && !this.disabled && m(
|
|
3823
|
+
t !== n && (e === g.POSTER_SRC && this.paused && !this.disabled && m(rc, this, cc).call(this), (e === g.PAUSED || e === "disabled" || e === "intersecting") && h(nc, this).call(this));
|
|
3823
3824
|
}
|
|
3824
3825
|
get disabled() {
|
|
3825
3826
|
return this.hasAttribute("disabled");
|
|
@@ -3834,18 +3835,18 @@ var Ys = 6e3, Xs = /* @__PURE__ */ new WeakMap(), Zs = /* @__PURE__ */ new WeakM
|
|
|
3834
3835
|
return this.hasAttribute(g.PAUSED);
|
|
3835
3836
|
}
|
|
3836
3837
|
};
|
|
3837
|
-
function
|
|
3838
|
-
h(
|
|
3838
|
+
function oc() {
|
|
3839
|
+
h(ec, this) === null && (m(rc, this, sc).call(this), p(ec, this, window.setInterval(() => m(rc, this, cc).call(this), Qs)));
|
|
3839
3840
|
}
|
|
3840
|
-
function
|
|
3841
|
-
h(
|
|
3841
|
+
function sc() {
|
|
3842
|
+
h(ec, this) !== null && (clearInterval(h(ec, this)), p(ec, this, null)), this.style.backgroundImage = "url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAJCAQAAACRI2S5AAAAEElEQVR42mNkIAAYRxWAAQAG9gAKqv6+AwAAAABJRU5ErkJggg==')";
|
|
3842
3843
|
}
|
|
3843
|
-
function
|
|
3844
|
+
function cc() {
|
|
3844
3845
|
if (!this.posterSrc) return;
|
|
3845
3846
|
let e = new URL(this.posterSrc), t = new Image();
|
|
3846
3847
|
e.searchParams.set("t", Date.now().toString()), t.src = e.toString(), t.onload = () => this.style.backgroundImage = `url(${e.toString()})`;
|
|
3847
3848
|
}
|
|
3848
|
-
e(
|
|
3849
|
+
e(ac, "observedAttributes", [
|
|
3849
3850
|
g.POSTER_SRC,
|
|
3850
3851
|
g.PAUSED,
|
|
3851
3852
|
"disabled",
|
|
@@ -3853,70 +3854,70 @@ e(nc, "observedAttributes", [
|
|
|
3853
3854
|
]);
|
|
3854
3855
|
//#endregion
|
|
3855
3856
|
//#region ../../libs/player-next/src/components/RenditionLevelsMenu.ts
|
|
3856
|
-
var
|
|
3857
|
-
|
|
3857
|
+
var lc, uc = "\n<svg xmlns=\"http://www.w3.org/2000/svg\" class=\"icon icon-tabler icon-tabler-settings-filled\" width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" stroke-width=\"1.5\" stroke=\"#2c3e50\" fill=\"none\" stroke-linecap=\"round\" stroke-linejoin=\"round\">\n <path stroke=\"none\" d=\"M0 0h24v24H0z\" fill=\"none\"/>\n <path d=\"M14.647 4.081a.724 .724 0 0 0 1.08 .448c2.439 -1.485 5.23 1.305 3.745 3.744a.724 .724 0 0 0 .447 1.08c2.775 .673 2.775 4.62 0 5.294a.724 .724 0 0 0 -.448 1.08c1.485 2.439 -1.305 5.23 -3.744 3.745a.724 .724 0 0 0 -1.08 .447c-.673 2.775 -4.62 2.775 -5.294 0a.724 .724 0 0 0 -1.08 -.448c-2.439 1.485 -5.23 -1.305 -3.745 -3.744a.724 .724 0 0 0 -.447 -1.08c-2.775 -.673 -2.775 -4.62 0 -5.294a.724 .724 0 0 0 .448 -1.08c-1.485 -2.439 1.305 -5.23 3.744 -3.745a.722 .722 0 0 0 1.08 -.447c.673 -2.775 4.62 -2.775 5.294 0zm-2.647 4.919a3 3 0 1 0 0 6a3 3 0 0 0 0 -6z\" stroke-width=\"0\" fill=\"currentColor\" />\n</svg>\n", dc = document.createElement("template");
|
|
3858
|
+
dc.innerHTML = `
|
|
3858
3859
|
<style>
|
|
3859
3860
|
:host {
|
|
3860
3861
|
display: var(--rendition-menu-display);
|
|
3861
3862
|
}
|
|
3862
3863
|
</style>
|
|
3863
3864
|
|
|
3864
|
-
<slot name="button">${
|
|
3865
|
+
<slot name="button">${uc}</slot>
|
|
3865
3866
|
<slot name="listbox" hidden>
|
|
3866
3867
|
<vindral-rendition-levels-menu-list id="listbox" part="listbox"></vindral-rendition-levels-menu-list>
|
|
3867
3868
|
</slot>
|
|
3868
3869
|
`;
|
|
3869
|
-
var
|
|
3870
|
+
var fc = /* @__PURE__ */ new WeakSet(), pc = class extends He {
|
|
3870
3871
|
constructor() {
|
|
3871
3872
|
var e, t, n;
|
|
3872
|
-
super(), S(this,
|
|
3873
|
+
super(), S(this, fc), (e = this.shadowRoot) == null || e.appendChild(dc.content.cloneNode(!0)), this.listbox = (t = this.shadowRoot) == null ? void 0 : t.querySelector("[part=listbox]"), this.listboxSlot = (n = this.shadowRoot) == null ? void 0 : n.querySelector("slot[name=listbox]");
|
|
3873
3874
|
}
|
|
3874
3875
|
connectedCallback() {
|
|
3875
|
-
super.connectedCallback(), m(
|
|
3876
|
+
super.connectedCallback(), m(fc, this, mc).call(this), this.setAttribute("aria-label", "Quality");
|
|
3876
3877
|
}
|
|
3877
3878
|
attributeChangedCallback(e, t, n) {
|
|
3878
|
-
super.attributeChangedCallback(e, t, n), e === g.RENDITION_LEVELS && m(
|
|
3879
|
+
super.attributeChangedCallback(e, t, n), e === g.RENDITION_LEVELS && m(fc, this, mc).call(this);
|
|
3879
3880
|
}
|
|
3880
3881
|
};
|
|
3881
|
-
|
|
3882
|
-
function
|
|
3882
|
+
lc = pc;
|
|
3883
|
+
function mc() {
|
|
3883
3884
|
let e = this.getAttribute(g.RENDITION_LEVELS);
|
|
3884
3885
|
!e || e === "[]" ? this.setAttribute("disabled", "") : this.removeAttribute("disabled");
|
|
3885
3886
|
}
|
|
3886
|
-
e(
|
|
3887
|
+
e(pc, "observedAttributes", [...y(lc, "observedAttributes", lc), g.RENDITION_LEVELS]);
|
|
3887
3888
|
//#endregion
|
|
3888
3889
|
//#region ../../libs/player-next/src/components/RenditionLevelsMenuList.ts
|
|
3889
|
-
var
|
|
3890
|
-
|
|
3891
|
-
var
|
|
3890
|
+
var hc = document.createElement("template");
|
|
3891
|
+
hc.innerHTML = "\n <style>\n :host {\n font: inherit;\n cursor: default;\n padding: var(--padding-2) !important;\n padding-top: var(--padding-3) !important;\n border-radius: 0.25em;\n position: absolute;\n min-width: 140px !important;\n background: var(--bg-subtle);\n z-index: 1;\n overflow: auto;\n }\n\n :host([list-position=\"top\"]) {\n bottom: calc(100% + 0.5em);\n transform: translate(-50%);\n }\n\n :host([list-position=\"bottom\"]) {\n top: calc(100% + 0.5em);\n }\n\n :host::-webkit-scrollbar {\n width: 5px;\n padding-right: 5px;\n }\n\n :host::-webkit-scrollbar-thumb {\n background-color: var(--fg-extra-subtle);\n border-radius: 10px;\n border: 0;\n }\n\n :host::-webkit-scrollbar-track {\n border-radius: 10px;\n background-color: transparent;\n }\n\n .menu {\n display: grid;\n gap: var(--padding-1);\n }\n\n [role=\"menuitem\"] {\n flex: 1;\n position: relative;\n cursor: pointer;\n display: flex;\n flex-direction: column;\n justify-content: center;\n height: 44px;\n padding: 0 var(--padding-5);\n border-radius: 4px;\n font-size: 14px;\n font-style: normal;\n font-weight: 500;\n line-height: normal;\n white-space: nowrap;\n text-align: left;\n }\n\n [role=\"menuitem\"]:hover {\n background: var(--bg-component-hover);\n }\n\n [role=\"menuitem\"][aria-selected=\"true\"] {\n background: var(--bg-component-active);\n }\n\n [role=\"menuitem\"][aria-selected=\"true\"]::before {\n content: url(\"data:image/svg+xml,%0A%20%20%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2212%22%20height%3D%2212%22%20fill%3D%22%23fff%22%20viewBox%3D%220%200%2078.369%2078.369%22%20xml%3Aspace%3D%22preserve%22%3E%3Cpath%20d%3D%22M78.049%2019.015%2029.458%2067.606a1.094%201.094%200%200%201-1.548%200L.32%2040.015a1.094%201.094%200%200%201%200-1.547l6.704-6.704a1.095%201.095%200%200%201%201.548%200l20.113%2020.112%2041.113-41.113a1.095%201.095%200%200%201%201.548%200l6.703%206.704a1.094%201.094%200%200%201%200%201.548z%22%2F%3E%3C%2Fsvg%3E%0A\");\n position: absolute;\n left: calc(var(--padding-3) - var(--padding-1));\n top: calc(50% - 8px);\n }\n\n [role=\"menuitem\"]:focus-visible {\n box-shadow: inset 0 0 0 2px var(--fg-strong);\n outline: 0;\n }\n\n .menu-item-subtitle {\n font-size: 11px;\n opacity: 0.6;\n }\n\n .heading {\n text-transform: uppercase;\n margin-bottom: var(--padding-2);\n padding: 0 var(--padding-3);\n font-size: 11px;\n font-weight: bold;\n }\n </style>\n\n <slot>\n <div class=\"heading\">Max quality</div>\n <div class=\"menu\"></div>\n </slot>\n";
|
|
3892
|
+
var gc = /* @__PURE__ */ new WeakMap(), _c = /* @__PURE__ */ new WeakMap(), vc = /* @__PURE__ */ new WeakMap(), yc = /* @__PURE__ */ new WeakMap(), bc = /* @__PURE__ */ new WeakMap(), xc = /* @__PURE__ */ new WeakMap(), X = /* @__PURE__ */ new WeakSet(), Sc = class extends HTMLElement {
|
|
3892
3893
|
constructor() {
|
|
3893
|
-
super(), S(this, X), f(this,
|
|
3894
|
+
super(), S(this, X), f(this, gc, []), f(this, _c, 2 ** 53 - 1), f(this, vc, null), f(this, yc, []), f(this, bc, null), f(this, xc, null), e(this, "handleEvent", (e) => {
|
|
3894
3895
|
switch (e.type) {
|
|
3895
3896
|
case "keydown":
|
|
3896
|
-
m(X, this,
|
|
3897
|
+
m(X, this, Oc).call(this, e);
|
|
3897
3898
|
break;
|
|
3898
3899
|
}
|
|
3899
|
-
}), this.attachShadow({ mode: "open" }).appendChild(
|
|
3900
|
+
}), this.attachShadow({ mode: "open" }).appendChild(hc.content.cloneNode(!0));
|
|
3900
3901
|
}
|
|
3901
3902
|
connectedCallback() {
|
|
3902
3903
|
let e = this.getRootNode();
|
|
3903
3904
|
if (e instanceof ShadowRoot) {
|
|
3904
3905
|
var t;
|
|
3905
|
-
p(
|
|
3906
|
+
p(bc, this, e.host.closest("vindral-controller")), (t = h(bc, this)) == null || t.connectListener(this), m(X, this, Cc).call(this), m(X, this, wc).call(this), p(xc, this, e.host), this.addEventListener("keydown", this);
|
|
3906
3907
|
}
|
|
3907
3908
|
}
|
|
3908
3909
|
disconnectedCallback() {
|
|
3909
3910
|
var e;
|
|
3910
|
-
(e = h(
|
|
3911
|
+
(e = h(bc, this)) == null || e.disconnectListener(this), this.removeEventListener("keydown", this);
|
|
3911
3912
|
}
|
|
3912
3913
|
attributeChangedCallback(e, t, n) {
|
|
3913
3914
|
t !== n && (e === g.RENDITION_LEVELS && n && (this.list = JSON.parse(n)), e === g.MAX_VIDEO_BITRATE && n && (this.maxVideoBitrate = n ? parseInt(n, 10) : 2 ** 53 - 1));
|
|
3914
3915
|
}
|
|
3915
3916
|
set list(e) {
|
|
3916
|
-
p(
|
|
3917
|
+
p(gc, this, e), m(X, this, wc).call(this);
|
|
3917
3918
|
}
|
|
3918
3919
|
set maxVideoBitrate(e) {
|
|
3919
|
-
p(
|
|
3920
|
+
p(_c, this, e), m(X, this, Ec).call(this);
|
|
3920
3921
|
}
|
|
3921
3922
|
get keysUsed() {
|
|
3922
3923
|
return [
|
|
@@ -3932,10 +3933,10 @@ var pc = /* @__PURE__ */ new WeakMap(), mc = /* @__PURE__ */ new WeakMap(), hc =
|
|
|
3932
3933
|
}
|
|
3933
3934
|
focus() {
|
|
3934
3935
|
var e;
|
|
3935
|
-
(e = h(
|
|
3936
|
+
(e = h(vc, this)) == null || e.focus();
|
|
3936
3937
|
}
|
|
3937
3938
|
};
|
|
3938
|
-
function
|
|
3939
|
+
function Cc() {
|
|
3939
3940
|
new IntersectionObserver((e) => {
|
|
3940
3941
|
e.forEach((e) => {
|
|
3941
3942
|
if (e.intersectionRatio !== 1) if (e.intersectionRatio > 0) {
|
|
@@ -3944,50 +3945,50 @@ function bc() {
|
|
|
3944
3945
|
} else this.style.height = "auto";
|
|
3945
3946
|
});
|
|
3946
3947
|
}, {
|
|
3947
|
-
root: h(
|
|
3948
|
+
root: h(bc, this),
|
|
3948
3949
|
threshold: 0
|
|
3949
3950
|
}).observe(this);
|
|
3950
3951
|
}
|
|
3951
|
-
function
|
|
3952
|
+
function wc() {
|
|
3952
3953
|
var e;
|
|
3953
3954
|
let t = (e = this.shadowRoot) == null ? void 0 : e.querySelector(".menu");
|
|
3954
|
-
t && (p(
|
|
3955
|
+
t && (p(yc, this, []), t.innerHTML = "", h(gc, this).sort((e, t) => {
|
|
3955
3956
|
var n, r;
|
|
3956
3957
|
return (n = e.video) != null && n.bitRate && (r = t.video) != null && r.bitRate ? t.video.bitRate - e.video.bitRate : 0;
|
|
3957
3958
|
}).forEach((e) => {
|
|
3958
3959
|
var n, r, i, a, o, s, c, l;
|
|
3959
3960
|
let u = document.createElement("div");
|
|
3960
3961
|
u.setAttribute("role", "menuitem"), u.setAttribute("value", String((n = e.video) == null ? void 0 : n.height)), u.classList.add("menu-item"), u.tabIndex = -1;
|
|
3961
|
-
let ee = m(X, this,
|
|
3962
|
+
let ee = m(X, this, Tc).call(this, (r = e.video) == null ? void 0 : r.frameRate);
|
|
3962
3963
|
u.textContent = e.video ? me(e.video) : "";
|
|
3963
3964
|
let d = document.createElement("span");
|
|
3964
|
-
d.classList.add("menu-item-subtitle"), d.textContent = `${he(((i = (a = e.video) == null ? void 0 : a.bitRate) == null ? 0 : i) + ((o = (s = e.audio) == null ? void 0 : s.bitRate) == null ? 0 : o))}, ${ee}p`, u.appendChild(d), u.addEventListener("click", () => m(X, this,
|
|
3965
|
+
d.classList.add("menu-item-subtitle"), d.textContent = `${he(((i = (a = e.video) == null ? void 0 : a.bitRate) == null ? 0 : i) + ((o = (s = e.audio) == null ? void 0 : s.bitRate) == null ? 0 : o))}, ${ee}p`, u.appendChild(d), u.addEventListener("click", () => m(X, this, Dc).call(this, e)), h(yc, this).push({
|
|
3965
3966
|
el: u,
|
|
3966
3967
|
id: (c = (l = e.video) == null ? void 0 : l.id) == null ? -1 : c
|
|
3967
3968
|
}), t.appendChild(u);
|
|
3968
|
-
}), m(X, this,
|
|
3969
|
+
}), m(X, this, Ec).call(this));
|
|
3969
3970
|
}
|
|
3970
|
-
function
|
|
3971
|
+
function Tc(e) {
|
|
3971
3972
|
return e ? e[0] % e[1] === 0 ? (e[0] / e[1]).toString() : (e[0] / e[1]).toFixed(2) : "";
|
|
3972
3973
|
}
|
|
3973
|
-
function
|
|
3974
|
-
h(
|
|
3975
|
-
let e = h(
|
|
3974
|
+
function Ec() {
|
|
3975
|
+
h(vc, this) && (h(vc, this).removeAttribute("aria-selected"), h(vc, this).tabIndex = -1);
|
|
3976
|
+
let e = h(gc, this).sort((e, t) => {
|
|
3976
3977
|
var n, r;
|
|
3977
3978
|
return (n = e.video) != null && n.bitRate && (r = t.video) != null && r.bitRate ? t.video.bitRate - e.video.bitRate : 0;
|
|
3978
|
-
}), t = h(
|
|
3979
|
+
}), t = h(gc, this).filter((e) => {
|
|
3979
3980
|
var t;
|
|
3980
|
-
return ((t = e.video) == null ? void 0 : t.bitRate) && e.video.bitRate <= h(
|
|
3981
|
+
return ((t = e.video) == null ? void 0 : t.bitRate) && e.video.bitRate <= h(_c, this);
|
|
3981
3982
|
})[0] || e[e.length - 1];
|
|
3982
3983
|
if (t) {
|
|
3983
|
-
let e = h(
|
|
3984
|
+
let e = h(yc, this).find((e) => {
|
|
3984
3985
|
var n;
|
|
3985
3986
|
return e.id === ((n = t.video) == null ? void 0 : n.id);
|
|
3986
3987
|
});
|
|
3987
|
-
e && (e.el.tabIndex = 0, e.el.setAttribute("aria-selected", "true"), p(
|
|
3988
|
+
e && (e.el.tabIndex = 0, e.el.setAttribute("aria-selected", "true"), p(vc, this, e.el));
|
|
3988
3989
|
}
|
|
3989
3990
|
}
|
|
3990
|
-
function
|
|
3991
|
+
function Dc(e) {
|
|
3991
3992
|
this.dispatchEvent(new Event("change", {
|
|
3992
3993
|
bubbles: !0,
|
|
3993
3994
|
composed: !0
|
|
@@ -3997,36 +3998,36 @@ function wc(e) {
|
|
|
3997
3998
|
detail: e
|
|
3998
3999
|
}));
|
|
3999
4000
|
}
|
|
4000
|
-
function
|
|
4001
|
+
function Oc(e) {
|
|
4001
4002
|
let { key: t, ctrlKey: n, altKey: r, metaKey: i } = e;
|
|
4002
4003
|
if (!(n || r || i) && this.keysUsed.includes(t)) if (e.preventDefault(), e.stopPropagation(), t === "Tab" || t === "Escape") {
|
|
4003
4004
|
var a;
|
|
4004
|
-
(a = h(
|
|
4005
|
+
(a = h(xc, this)) == null || a.hide();
|
|
4005
4006
|
} else if (t === "Enter" || t === " ") {
|
|
4006
4007
|
var o;
|
|
4007
|
-
(o = m(X, this,
|
|
4008
|
-
} else m(X, this,
|
|
4008
|
+
(o = m(X, this, Ac).call(this)) == null || (o = o.el) == null || o.click();
|
|
4009
|
+
} else m(X, this, kc).call(this, e);
|
|
4009
4010
|
}
|
|
4010
|
-
function
|
|
4011
|
+
function kc(e) {
|
|
4011
4012
|
var t;
|
|
4012
|
-
let { key: n } = e, r = h(
|
|
4013
|
+
let { key: n } = e, r = h(yc, this), i = (t = m(X, this, Ac).call(this)) == null ? r[0] : t;
|
|
4013
4014
|
if (!i) return;
|
|
4014
4015
|
let a = r.indexOf(i), o = Math.max(0, a);
|
|
4015
4016
|
n === "ArrowDown" ? o++ : n === "ArrowUp" ? o-- : e.key === "Home" ? o = 0 : e.key === "End" && (o = r.length - 1), o < 0 && (o = r.length - 1), o > r.length - 1 && (o = 0);
|
|
4016
4017
|
let s = r[o];
|
|
4017
|
-
s && (m(X, this,
|
|
4018
|
+
s && (m(X, this, jc).call(this, s.id), s.el.focus());
|
|
4018
4019
|
}
|
|
4019
|
-
function
|
|
4020
|
-
return h(
|
|
4020
|
+
function Ac() {
|
|
4021
|
+
return h(yc, this).find((e) => e.el.tabIndex === 0);
|
|
4021
4022
|
}
|
|
4022
|
-
function
|
|
4023
|
-
for (let t of h(
|
|
4023
|
+
function jc(e) {
|
|
4024
|
+
for (let t of h(yc, this)) t.el.tabIndex = t.id === e ? 0 : -1;
|
|
4024
4025
|
}
|
|
4025
|
-
e(
|
|
4026
|
+
e(Sc, "observedAttributes", [g.RENDITION_LEVELS, g.MAX_VIDEO_BITRATE]);
|
|
4026
4027
|
//#endregion
|
|
4027
4028
|
//#region ../../libs/player-next/src/components/ScrollOverlay.ts
|
|
4028
|
-
var
|
|
4029
|
-
|
|
4029
|
+
var Mc = document.createElement("template");
|
|
4030
|
+
Mc.innerHTML = `
|
|
4030
4031
|
<style>
|
|
4031
4032
|
:host {
|
|
4032
4033
|
--scroll-overlay-offset: var(--vindral-scroll-overlay-offset, 0px);
|
|
@@ -4094,71 +4095,71 @@ kc.innerHTML = `
|
|
|
4094
4095
|
<div id="scroll-area"></div>
|
|
4095
4096
|
<slot id="content"></slot>
|
|
4096
4097
|
`;
|
|
4097
|
-
var
|
|
4098
|
+
var Nc = /* @__PURE__ */ new WeakMap(), Pc = /* @__PURE__ */ new WeakMap(), Fc = /* @__PURE__ */ new WeakMap(), Ic = /* @__PURE__ */ new WeakMap(), Lc = /* @__PURE__ */ new WeakMap(), Rc = /* @__PURE__ */ new WeakMap(), zc = /* @__PURE__ */ new WeakMap(), Z = /* @__PURE__ */ new WeakSet(), Bc = /* @__PURE__ */ new WeakMap(), Vc = class extends HTMLElement {
|
|
4098
4099
|
constructor() {
|
|
4099
|
-
super(), S(this, Z), f(this,
|
|
4100
|
+
super(), S(this, Z), f(this, Nc, null), f(this, Pc, null), f(this, Fc, !1), f(this, Ic, !1), f(this, Lc, !1), f(this, Rc, () => {
|
|
4100
4101
|
this.open && (this.open = !1);
|
|
4101
|
-
}), f(this,
|
|
4102
|
+
}), f(this, zc, null), e(this, "handleEvent", (e) => {
|
|
4102
4103
|
switch (e.type) {
|
|
4103
4104
|
case "touchstart":
|
|
4104
|
-
m(Z, this,
|
|
4105
|
+
m(Z, this, Uc).call(this, e);
|
|
4105
4106
|
break;
|
|
4106
4107
|
case "touchmove":
|
|
4107
|
-
m(Z, this,
|
|
4108
|
+
m(Z, this, Wc).call(this, e);
|
|
4108
4109
|
break;
|
|
4109
4110
|
case "touchend":
|
|
4110
|
-
m(Z, this,
|
|
4111
|
+
m(Z, this, Gc).call(this, e);
|
|
4111
4112
|
break;
|
|
4112
4113
|
}
|
|
4113
|
-
}), f(this,
|
|
4114
|
-
let e = h(
|
|
4114
|
+
}), f(this, Bc, () => {
|
|
4115
|
+
let e = h(Lc, this);
|
|
4115
4116
|
if (this.scrollTop === 0) {
|
|
4116
|
-
m(Z, this,
|
|
4117
|
+
m(Z, this, $c).call(this, e);
|
|
4117
4118
|
return;
|
|
4118
4119
|
}
|
|
4119
|
-
if (!e && !m(Z, this,
|
|
4120
|
-
m(Z, this,
|
|
4120
|
+
if (!e && !m(Z, this, Kc).call(this)) {
|
|
4121
|
+
m(Z, this, Zc).call(this), m(Z, this, $c).call(this);
|
|
4121
4122
|
return;
|
|
4122
4123
|
}
|
|
4123
|
-
!this.visible && this.scrollTop > 0 && !h(
|
|
4124
|
-
}), this.attachShadow({ mode: "open" }).appendChild(
|
|
4124
|
+
!this.visible && this.scrollTop > 0 && !h(Fc, this) ? m(Z, this, el).call(this) : !h(Fc, this) && m(Z, this, Jc).call(this) && (this.open || (this.open = !0), e && !this.hasAttribute("snap-touch") && this.setAttribute("snap-touch", ""));
|
|
4125
|
+
}), this.attachShadow({ mode: "open" }).appendChild(Mc.content.cloneNode(!0));
|
|
4125
4126
|
}
|
|
4126
4127
|
connectedCallback() {
|
|
4127
4128
|
let e = this.getRootNode();
|
|
4128
4129
|
if (e instanceof Document || e instanceof ShadowRoot) {
|
|
4129
4130
|
var t, n, r;
|
|
4130
|
-
p(
|
|
4131
|
+
p(Nc, this, e.querySelector("vindral-controller")), (t = h(Nc, this)) == null || t.connectListener(this), p(Pc, this, (n = this.shadowRoot) == null ? void 0 : n.querySelector("#scroll-area")), (r = h(Pc, this)) == null || r.addEventListener("click", h(Rc, this));
|
|
4131
4132
|
let s = this.hasAttribute("touch-enabled");
|
|
4132
|
-
if (p(
|
|
4133
|
+
if (p(Lc, this, d() && s), !h(Lc, this)) this.setAttribute("snap", "");
|
|
4133
4134
|
else {
|
|
4134
4135
|
var i, a, o;
|
|
4135
|
-
(i = h(
|
|
4136
|
+
(i = h(Nc, this)) == null || i.addEventListener("touchstart", this, { passive: !0 }), (a = h(Nc, this)) == null || a.addEventListener("touchmove", this, { passive: !1 }), (o = h(Nc, this)) == null || o.addEventListener("touchend", this, { passive: !0 });
|
|
4136
4137
|
}
|
|
4137
|
-
this.addEventListener("scroll", h(
|
|
4138
|
+
this.addEventListener("scroll", h(Bc, this));
|
|
4138
4139
|
}
|
|
4139
4140
|
}
|
|
4140
4141
|
disconnectedCallback() {
|
|
4141
4142
|
var e, t, n, r, i;
|
|
4142
|
-
(e = h(
|
|
4143
|
+
(e = h(Pc, this)) == null || e.removeEventListener("click", h(Rc, this)), this.removeEventListener("scroll", h(Bc, this)), (t = h(Nc, this)) == null || t.removeEventListener("touchstart", this), (n = h(Nc, this)) == null || n.removeEventListener("touchmove", this), (r = h(Nc, this)) == null || r.removeEventListener("touchend", this), (i = h(Nc, this)) == null || i.disconnectListener(this);
|
|
4143
4144
|
}
|
|
4144
4145
|
attributeChangedCallback(e, t, n) {
|
|
4145
|
-
if (t !== n && (e === g.USER_INTERACTING && n === null && m(Z, this,
|
|
4146
|
+
if (t !== n && (e === g.USER_INTERACTING && n === null && m(Z, this, qc).call(this) && setTimeout(() => {
|
|
4146
4147
|
this.open = !1;
|
|
4147
4148
|
}, 300), e === "open")) if (n !== null) {
|
|
4148
4149
|
var r;
|
|
4149
|
-
p(
|
|
4150
|
-
top: (r = h(
|
|
4150
|
+
p(Fc, this, !1), this.scrollTop > 0 && m(Z, this, el).call(this), this.scrollTo({
|
|
4151
|
+
top: (r = h(Pc, this)) == null ? void 0 : r.clientHeight,
|
|
4151
4152
|
behavior: "smooth"
|
|
4152
4153
|
});
|
|
4153
|
-
} else m(Z, this,
|
|
4154
|
+
} else m(Z, this, Qc).call(this);
|
|
4154
4155
|
}
|
|
4155
4156
|
set open(e) {
|
|
4156
4157
|
if (e) {
|
|
4157
4158
|
this.setAttribute("open", "");
|
|
4158
4159
|
return;
|
|
4159
4160
|
}
|
|
4160
|
-
let t = this.hasAttribute("open"), n = this.visible || m(Z, this,
|
|
4161
|
-
t ? this.removeAttribute("open") : n ? m(Z, this,
|
|
4161
|
+
let t = this.hasAttribute("open"), n = this.visible || m(Z, this, qc).call(this);
|
|
4162
|
+
t ? this.removeAttribute("open") : n ? m(Z, this, Qc).call(this) : (p(Fc, this, !1), this.removeAttribute("snap-touch"));
|
|
4162
4163
|
}
|
|
4163
4164
|
get open() {
|
|
4164
4165
|
return this.hasAttribute("open");
|
|
@@ -4170,78 +4171,78 @@ var Ac = /* @__PURE__ */ new WeakMap(), jc = /* @__PURE__ */ new WeakMap(), Mc =
|
|
|
4170
4171
|
return this.hasAttribute("visible");
|
|
4171
4172
|
}
|
|
4172
4173
|
};
|
|
4173
|
-
function
|
|
4174
|
-
return m(Z, this,
|
|
4174
|
+
function Hc() {
|
|
4175
|
+
return m(Z, this, Kc).call(this) || m(Z, this, Xc).call(this) || m(Z, this, qc).call(this);
|
|
4175
4176
|
}
|
|
4176
|
-
function
|
|
4177
|
+
function Uc(e) {
|
|
4177
4178
|
let t = e.touches[0];
|
|
4178
|
-
t && (p(
|
|
4179
|
+
t && (p(Ic, this, m(Z, this, Hc).call(this)), h(Ic, this) && (p(Fc, this, !1), p(zc, this, t.clientY)));
|
|
4179
4180
|
}
|
|
4180
|
-
function
|
|
4181
|
-
if (!(!h(
|
|
4182
|
-
let t = e.touches[0].clientY, n = h(
|
|
4181
|
+
function Wc(e) {
|
|
4182
|
+
if (!(!h(Ic, this) || h(zc, this) === null || this.hasAttribute("snap-touch") && this.open) && (e.preventDefault(), e.touches[0])) {
|
|
4183
|
+
let t = e.touches[0].clientY, n = h(zc, this) - t;
|
|
4183
4184
|
this.scrollTop = Math.max(0, n);
|
|
4184
4185
|
}
|
|
4185
4186
|
}
|
|
4186
|
-
function
|
|
4187
|
-
h(
|
|
4187
|
+
function Gc(e) {
|
|
4188
|
+
h(Ic, this) && !h(Fc, this) && m(Z, this, qc).call(this) && (!this.hasAttribute("snap-touch") || !this.open) && (this.open = !0), p(zc, this, null), p(Ic, this, !1);
|
|
4188
4189
|
}
|
|
4189
|
-
function
|
|
4190
|
+
function Kc() {
|
|
4190
4191
|
return this.hasAttribute(g.USER_INTERACTING);
|
|
4191
4192
|
}
|
|
4192
|
-
function
|
|
4193
|
+
function qc() {
|
|
4193
4194
|
return this.scrollTop > 0;
|
|
4194
4195
|
}
|
|
4195
|
-
function
|
|
4196
|
+
function Jc() {
|
|
4196
4197
|
var e;
|
|
4197
|
-
return Math.round(this.scrollTop) === this.scrollHeight - this.clientHeight || Math.round(this.scrollTop) === ((e = h(
|
|
4198
|
+
return Math.round(this.scrollTop) === this.scrollHeight - this.clientHeight || Math.round(this.scrollTop) === ((e = h(Pc, this)) == null ? void 0 : e.clientHeight);
|
|
4198
4199
|
}
|
|
4199
|
-
function
|
|
4200
|
+
function Yc() {
|
|
4200
4201
|
var e;
|
|
4201
|
-
let t = (e = h(
|
|
4202
|
+
let t = (e = h(Pc, this)) == null ? void 0 : e.clientHeight;
|
|
4202
4203
|
return !t || this.clientHeight <= 0 ? 0 : Math.max(this.clientHeight - t, 0);
|
|
4203
4204
|
}
|
|
4204
|
-
function
|
|
4205
|
+
function Xc() {
|
|
4205
4206
|
let e = getComputedStyle(this), t = Number.parseFloat(e.getPropertyValue("--vindral-scroll-overlay-offset"));
|
|
4206
|
-
return Number.isNaN(t) ? m(Z, this,
|
|
4207
|
+
return Number.isNaN(t) ? m(Z, this, Yc).call(this) > 0 : t > 0;
|
|
4207
4208
|
}
|
|
4208
|
-
function
|
|
4209
|
+
function Zc() {
|
|
4209
4210
|
let e = this.style.scrollBehavior;
|
|
4210
4211
|
this.style.scrollBehavior = "auto", this.scrollTo({
|
|
4211
4212
|
top: 0,
|
|
4212
4213
|
behavior: "auto"
|
|
4213
4214
|
}), this.style.scrollBehavior = e;
|
|
4214
4215
|
}
|
|
4215
|
-
function
|
|
4216
|
-
p(
|
|
4216
|
+
function Qc() {
|
|
4217
|
+
p(Fc, this, !0), this.removeAttribute("snap-touch"), m(Z, this, tl).call(this), this.scrollTo({
|
|
4217
4218
|
top: 0,
|
|
4218
4219
|
behavior: "smooth"
|
|
4219
4220
|
});
|
|
4220
4221
|
}
|
|
4221
|
-
function
|
|
4222
|
-
this.open = !1, e && this.removeAttribute("snap-touch"), p(
|
|
4222
|
+
function $c(e = !1) {
|
|
4223
|
+
this.open = !1, e && this.removeAttribute("snap-touch"), p(Fc, this, !1), m(Z, this, tl).call(this);
|
|
4223
4224
|
}
|
|
4224
|
-
function
|
|
4225
|
+
function el() {
|
|
4225
4226
|
this.visible || (this.visible = !0, this.dispatchEvent(new CustomEvent(x.LOCK_UI, {
|
|
4226
4227
|
bubbles: !0,
|
|
4227
4228
|
composed: !0
|
|
4228
4229
|
})));
|
|
4229
4230
|
}
|
|
4230
|
-
function
|
|
4231
|
+
function tl() {
|
|
4231
4232
|
this.visible && (this.visible = !1, this.dispatchEvent(new CustomEvent(x.UNLOCK_UI, {
|
|
4232
4233
|
bubbles: !0,
|
|
4233
4234
|
composed: !0
|
|
4234
4235
|
})));
|
|
4235
4236
|
}
|
|
4236
|
-
e(
|
|
4237
|
+
e(Vc, "observedAttributes", [
|
|
4237
4238
|
g.USER_INTERACTING,
|
|
4238
4239
|
"open",
|
|
4239
4240
|
"touch-enabled"
|
|
4240
4241
|
]);
|
|
4241
4242
|
//#endregion
|
|
4242
4243
|
//#region ../../libs/player-next/src/components/SeekBar.ts
|
|
4243
|
-
var
|
|
4244
|
-
|
|
4244
|
+
var nl = 1e3, rl = 8, il = document.createElement("template");
|
|
4245
|
+
il.innerHTML = `
|
|
4245
4246
|
<style>
|
|
4246
4247
|
:host {
|
|
4247
4248
|
--buffered: 0;
|
|
@@ -4316,53 +4317,53 @@ tl.innerHTML = `
|
|
|
4316
4317
|
<div id="markers"></div>
|
|
4317
4318
|
<div id="time-tooltip"></div>
|
|
4318
4319
|
`;
|
|
4319
|
-
var Q = /* @__PURE__ */ new WeakMap(),
|
|
4320
|
+
var Q = /* @__PURE__ */ new WeakMap(), al = /* @__PURE__ */ new WeakMap(), ol = /* @__PURE__ */ new WeakMap(), sl = /* @__PURE__ */ new WeakMap(), cl = /* @__PURE__ */ new WeakMap(), ll = /* @__PURE__ */ new WeakMap(), ul = /* @__PURE__ */ new WeakMap(), dl = /* @__PURE__ */ new WeakMap(), fl = /* @__PURE__ */ new WeakMap(), pl = /* @__PURE__ */ new WeakMap(), ml = /* @__PURE__ */ new WeakMap(), $ = /* @__PURE__ */ new WeakSet(), hl = /* @__PURE__ */ new WeakMap(), gl = /* @__PURE__ */ new WeakMap(), _l = /* @__PURE__ */ new WeakMap(), vl = /* @__PURE__ */ new WeakMap(), yl = /* @__PURE__ */ new WeakMap(), bl = /* @__PURE__ */ new WeakMap(), xl = class extends Ci {
|
|
4320
4321
|
constructor() {
|
|
4321
4322
|
var e, t, n, r;
|
|
4322
|
-
super(), S(this, $), f(this, Q, void 0), f(this,
|
|
4323
|
-
if (!m($, this,
|
|
4323
|
+
super(), S(this, $), f(this, Q, void 0), f(this, al, void 0), f(this, ol, void 0), f(this, sl, void 0), f(this, cl, []), f(this, ll, null), f(this, ul, !1), f(this, dl, null), f(this, fl, null), f(this, pl, !1), f(this, ml, !1), f(this, hl, (e) => {
|
|
4324
|
+
if (!m($, this, wl).call(this) || m($, this, Tl).call(this)) {
|
|
4324
4325
|
e.preventDefault();
|
|
4325
4326
|
return;
|
|
4326
4327
|
}
|
|
4327
|
-
p(
|
|
4328
|
+
p(ul, this, !0), p(fl, this, e.pointerId);
|
|
4328
4329
|
try {
|
|
4329
4330
|
this.setPointerCapture(e.pointerId);
|
|
4330
4331
|
} catch (e) {}
|
|
4331
|
-
m($, this,
|
|
4332
|
-
}), f(this,
|
|
4333
|
-
if (!(!m($, this,
|
|
4334
|
-
if (h(
|
|
4335
|
-
e.preventDefault(), m($, this,
|
|
4332
|
+
m($, this, Nl).call(this, e);
|
|
4333
|
+
}), f(this, gl, (e) => {
|
|
4334
|
+
if (!(!m($, this, wl).call(this) || m($, this, Tl).call(this))) {
|
|
4335
|
+
if (h(dl, this) && (cancelAnimationFrame(h(dl, this)), p(dl, this, null)), h(ul, this) && e.pointerId === h(fl, this)) {
|
|
4336
|
+
e.preventDefault(), m($, this, Nl).call(this, e);
|
|
4336
4337
|
return;
|
|
4337
4338
|
}
|
|
4338
|
-
p(
|
|
4339
|
+
p(dl, this, requestAnimationFrame(() => {
|
|
4339
4340
|
var t;
|
|
4340
|
-
if (e.pointerType !== "mouse" || h(
|
|
4341
|
-
h(
|
|
4341
|
+
if (e.pointerType !== "mouse" || h(ul, this) || !this.duration) {
|
|
4342
|
+
h(ol, this).style.opacity = "0", p(dl, this, null);
|
|
4342
4343
|
return;
|
|
4343
4344
|
}
|
|
4344
|
-
let n = m($, this,
|
|
4345
|
-
if (m($, this,
|
|
4345
|
+
let n = m($, this, Ml).call(this, e.clientX), r = m($, this, Al).call(this, n), i = (t = r == null ? void 0 : r.position) == null ? n : t;
|
|
4346
|
+
if (m($, this, Fl).call(this, i, r), i > this.range.valueAsNumber) {
|
|
4346
4347
|
let e = this.range.valueAsNumber * 100, t = (i - this.range.valueAsNumber) * 100;
|
|
4347
|
-
h(
|
|
4348
|
-
} else h(
|
|
4349
|
-
p(
|
|
4348
|
+
h(ol, this).style.transform = `translateX(${e}%) scaleX(${t / 100})`, h(ol, this).style.opacity = "1";
|
|
4349
|
+
} else h(ol, this).style.opacity = "0";
|
|
4350
|
+
p(dl, this, null);
|
|
4350
4351
|
}));
|
|
4351
4352
|
}
|
|
4352
|
-
}), f(this,
|
|
4353
|
-
if (e.pointerId === h(
|
|
4353
|
+
}), f(this, _l, (e) => {
|
|
4354
|
+
if (e.pointerId === h(fl, this)) {
|
|
4354
4355
|
try {
|
|
4355
4356
|
this.releasePointerCapture(e.pointerId);
|
|
4356
4357
|
} catch (e) {}
|
|
4357
|
-
p(
|
|
4358
|
+
p(ul, this, !1), p(fl, this, null), e.pointerType !== "mouse" && (h(al, this).style.opacity = "0"), h(ml, this) && m($, this, Rl).call(this) && (p(pl, this, !1), p(ml, this, !1));
|
|
4358
4359
|
}
|
|
4359
|
-
}), f(this,
|
|
4360
|
-
this.duration && !m($, this,
|
|
4361
|
-
}), f(this,
|
|
4362
|
-
h(
|
|
4363
|
-
}), f(this,
|
|
4364
|
-
if (m($, this,
|
|
4365
|
-
let t = m($, this,
|
|
4360
|
+
}), f(this, vl, () => {
|
|
4361
|
+
this.duration && !m($, this, Tl).call(this) && (h(al, this).style.opacity = "1");
|
|
4362
|
+
}), f(this, yl, () => {
|
|
4363
|
+
h(al, this).style.opacity = "0", h(ol, this).style.opacity = "0";
|
|
4364
|
+
}), f(this, bl, (e) => {
|
|
4365
|
+
if (m($, this, Tl).call(this) || !h(Q, this) || h(Q, this) <= 0 || !Number.isFinite(h(Q, this))) return;
|
|
4366
|
+
let t = m($, this, Sl).call(this);
|
|
4366
4367
|
if (t <= 0) return;
|
|
4367
4368
|
let n = this.range.valueAsNumber * t, r = n;
|
|
4368
4369
|
switch (e.preventDefault(), e.key) {
|
|
@@ -4370,46 +4371,46 @@ var Q = /* @__PURE__ */ new WeakMap(), nl = /* @__PURE__ */ new WeakMap(), rl =
|
|
|
4370
4371
|
r = Math.max(0, n - 5);
|
|
4371
4372
|
break;
|
|
4372
4373
|
case "ArrowRight":
|
|
4373
|
-
if (m($, this,
|
|
4374
|
+
if (m($, this, Rl).call(this)) return;
|
|
4374
4375
|
r = Math.min(t, n + 5);
|
|
4375
4376
|
break;
|
|
4376
4377
|
case "Home":
|
|
4377
4378
|
r = 0;
|
|
4378
4379
|
break;
|
|
4379
4380
|
case "End":
|
|
4380
|
-
if (m($, this,
|
|
4381
|
+
if (m($, this, Rl).call(this)) return;
|
|
4381
4382
|
r = t;
|
|
4382
4383
|
break;
|
|
4383
4384
|
default: return;
|
|
4384
4385
|
}
|
|
4385
4386
|
let i = Math.min(r / t, 1);
|
|
4386
|
-
m($, this,
|
|
4387
|
-
}), (e = this.shadowRoot) == null || e.appendChild(
|
|
4387
|
+
m($, this, Pl).call(this, i);
|
|
4388
|
+
}), (e = this.shadowRoot) == null || e.appendChild(il.content.cloneNode(!0)), p(al, this, (t = this.shadowRoot) == null ? void 0 : t.getElementById("time-tooltip")), p(ol, this, (n = this.shadowRoot) == null ? void 0 : n.getElementById("hover-preview")), p(sl, this, (r = this.shadowRoot) == null ? void 0 : r.getElementById("markers")), this.addEventListener("pointerdown", h(hl, this)), this.addEventListener("pointermove", h(gl, this)), this.addEventListener("pointerup", h(_l, this)), this.addEventListener("pointercancel", h(_l, this)), this.addEventListener("mouseenter", h(vl, this)), this.addEventListener("mouseleave", h(yl, this));
|
|
4388
4389
|
}
|
|
4389
4390
|
connectedCallback() {
|
|
4390
|
-
super.connectedCallback(), this.setAttribute("aria-label", "Seek video position"), this.setAttribute("role", "slider"), m($, this,
|
|
4391
|
+
super.connectedCallback(), this.setAttribute("aria-label", "Seek video position"), this.setAttribute("role", "slider"), m($, this, jl).call(this), this.addEventListener("keydown", h(bl, this)), m($, this, Rl).call(this) && (this.range.value = "1", m($, this, jl).call(this)), m($, this, El).call(this), m($, this, Ol).call(this);
|
|
4391
4392
|
}
|
|
4392
4393
|
disconnectedCallback() {
|
|
4393
|
-
super.disconnectedCallback(), m($, this,
|
|
4394
|
+
super.disconnectedCallback(), m($, this, kl).call(this), this.removeEventListener("pointerdown", h(hl, this)), this.removeEventListener("pointermove", h(gl, this)), this.removeEventListener("pointerup", h(_l, this)), this.removeEventListener("pointercancel", h(_l, this)), this.removeEventListener("mouseenter", h(vl, this)), this.removeEventListener("mouseleave", h(yl, this)), this.removeEventListener("keydown", h(bl, this)), p(fl, this, null);
|
|
4394
4395
|
}
|
|
4395
4396
|
attributeChangedCallback(e, t, n) {
|
|
4396
4397
|
if (super.attributeChangedCallback(e, t, n), t !== n) switch (e) {
|
|
4397
4398
|
case g.TIMESHIFT_POSITION:
|
|
4398
|
-
if (m($, this,
|
|
4399
|
-
h(
|
|
4399
|
+
if (m($, this, Rl).call(this)) {
|
|
4400
|
+
h(ul, this) ? p(ml, this, !0) : (p(pl, this, !1), p(ml, this, !1)), this.range.value = "1", m($, this, jl).call(this);
|
|
4400
4401
|
return;
|
|
4401
4402
|
}
|
|
4402
4403
|
if (h(Q, this)) {
|
|
4403
|
-
p(
|
|
4404
|
+
p(ml, this, !1);
|
|
4404
4405
|
let e = Math.max(parseFloat(n) / h(Q, this), 0);
|
|
4405
|
-
this.range.value = e.toString(), m($, this,
|
|
4406
|
+
this.range.value = e.toString(), m($, this, jl).call(this);
|
|
4406
4407
|
}
|
|
4407
4408
|
break;
|
|
4408
4409
|
case g.DURATION:
|
|
4409
|
-
p(Q, this, parseFloat(n) || 0), m($, this,
|
|
4410
|
+
p(Q, this, parseFloat(n) || 0), m($, this, jl).call(this), m($, this, El).call(this), m($, this, Ol).call(this);
|
|
4410
4411
|
break;
|
|
4411
4412
|
case g.TIMELINE_MARKERS:
|
|
4412
|
-
p(
|
|
4413
|
+
p(cl, this, Br(n)), m($, this, El).call(this), m($, this, Ol).call(this);
|
|
4413
4414
|
break;
|
|
4414
4415
|
}
|
|
4415
4416
|
}
|
|
@@ -4427,54 +4428,54 @@ var Q = /* @__PURE__ */ new WeakMap(), nl = /* @__PURE__ */ new WeakMap(), rl =
|
|
|
4427
4428
|
this.setAttribute(g.DURATION, e.toString());
|
|
4428
4429
|
}
|
|
4429
4430
|
};
|
|
4430
|
-
function
|
|
4431
|
+
function Sl() {
|
|
4431
4432
|
return h(Q, this) ? h(Q, this) : 1;
|
|
4432
4433
|
}
|
|
4433
|
-
function
|
|
4434
|
+
function Cl() {
|
|
4434
4435
|
let e = h(Q, this);
|
|
4435
4436
|
return e !== void 0 && e > 0 && Number.isFinite(e) ? e : void 0;
|
|
4436
4437
|
}
|
|
4437
|
-
function
|
|
4438
|
-
return m($, this,
|
|
4438
|
+
function wl() {
|
|
4439
|
+
return m($, this, Cl).call(this) !== void 0;
|
|
4439
4440
|
}
|
|
4440
|
-
function
|
|
4441
|
-
return h(
|
|
4441
|
+
function Tl() {
|
|
4442
|
+
return h(pl, this);
|
|
4442
4443
|
}
|
|
4443
|
-
function
|
|
4444
|
+
function El() {
|
|
4444
4445
|
var e;
|
|
4445
|
-
let t = Date.now(), n = (e = h(Q, this)) == null ? 0 : e, r = h(
|
|
4446
|
-
for (let e of h(
|
|
4447
|
-
let a =
|
|
4446
|
+
let t = Date.now(), n = (e = h(Q, this)) == null ? 0 : e, r = h(sl, this).children, i = 0;
|
|
4447
|
+
for (let e of h(cl, this)) {
|
|
4448
|
+
let a = Vr(e.time, t, n);
|
|
4448
4449
|
if (a === null) continue;
|
|
4449
4450
|
let o = r[i];
|
|
4450
|
-
o || (o = document.createElement("div"), o.className = "marker", h(
|
|
4451
|
+
o || (o = document.createElement("div"), o.className = "marker", h(sl, this).appendChild(o)), o.style.left = `${a * 100}%`, o.dataset.label = e.label, e.type ? o.dataset.type = e.type : delete o.dataset.type, i++;
|
|
4451
4452
|
}
|
|
4452
|
-
for (; h(
|
|
4453
|
+
for (; h(sl, this).children.length > i;) {
|
|
4453
4454
|
var a;
|
|
4454
|
-
(a = h(
|
|
4455
|
+
(a = h(sl, this).lastElementChild) == null || a.remove();
|
|
4455
4456
|
}
|
|
4456
4457
|
}
|
|
4457
|
-
function
|
|
4458
|
-
let e = m($, this,
|
|
4458
|
+
function Dl() {
|
|
4459
|
+
let e = m($, this, Cl).call(this);
|
|
4459
4460
|
if (e === void 0) return !1;
|
|
4460
4461
|
let t = Date.now() - e * 1e3;
|
|
4461
|
-
return h(
|
|
4462
|
+
return h(cl, this).some((e) => e.time >= t);
|
|
4462
4463
|
}
|
|
4463
|
-
function
|
|
4464
|
-
this.isConnected && m($, this,
|
|
4465
|
-
m($, this,
|
|
4466
|
-
},
|
|
4464
|
+
function Ol() {
|
|
4465
|
+
this.isConnected && m($, this, Dl).call(this) ? h(ll, this) === null && p(ll, this, window.setInterval(() => {
|
|
4466
|
+
m($, this, El).call(this), m($, this, Ol).call(this);
|
|
4467
|
+
}, nl)) : m($, this, kl).call(this);
|
|
4467
4468
|
}
|
|
4468
|
-
function
|
|
4469
|
-
h(
|
|
4469
|
+
function kl() {
|
|
4470
|
+
h(ll, this) !== null && (window.clearInterval(h(ll, this)), p(ll, this, null));
|
|
4470
4471
|
}
|
|
4471
|
-
function
|
|
4472
|
-
if (h(
|
|
4472
|
+
function Al(e) {
|
|
4473
|
+
if (h(cl, this).length === 0 || !h(Q, this)) return null;
|
|
4473
4474
|
let t = this.getBoundingClientRect().width;
|
|
4474
4475
|
if (!t) return null;
|
|
4475
|
-
let n =
|
|
4476
|
-
for (let t of h(
|
|
4477
|
-
let a =
|
|
4476
|
+
let n = rl / t, r = Date.now(), i = null;
|
|
4477
|
+
for (let t of h(cl, this)) {
|
|
4478
|
+
let a = Vr(t.time, r, h(Q, this));
|
|
4478
4479
|
if (a === null) continue;
|
|
4479
4480
|
let o = Math.abs(a - e);
|
|
4480
4481
|
o > n || (!i || o < Math.abs(i.position - e)) && (i = {
|
|
@@ -4484,59 +4485,59 @@ function Dl(e) {
|
|
|
4484
4485
|
}
|
|
4485
4486
|
return i;
|
|
4486
4487
|
}
|
|
4487
|
-
function
|
|
4488
|
-
let e = m($, this,
|
|
4489
|
-
!h(Q, this) || h(Q, this) <= 0 || !Number.isFinite(h(Q, this)) ? this.setAttribute("data-no-duration", "") : this.removeAttribute("data-no-duration"), h(
|
|
4488
|
+
function jl() {
|
|
4489
|
+
let e = m($, this, Sl).call(this);
|
|
4490
|
+
!h(Q, this) || h(Q, this) <= 0 || !Number.isFinite(h(Q, this)) ? this.setAttribute("data-no-duration", "") : this.removeAttribute("data-no-duration"), h(ul, this) || (this.updateBar(), this.setAttribute("aria-valuetext", `${m($, this, zl).call(this, this.range.valueAsNumber * e)} of ${m($, this, zl).call(this, e)}`), !h(ul, this) && !m($, this, Tl).call(this) && m($, this, Ll).call(this, this.range.valueAsNumber));
|
|
4490
4491
|
}
|
|
4491
|
-
function
|
|
4492
|
+
function Ml(e) {
|
|
4492
4493
|
let t = this.getBoundingClientRect(), n = (e - t.left) / t.width;
|
|
4493
4494
|
return Math.max(0, Math.min(1, n));
|
|
4494
4495
|
}
|
|
4495
|
-
function
|
|
4496
|
+
function Nl(e) {
|
|
4496
4497
|
var t;
|
|
4497
|
-
let n = m($, this,
|
|
4498
|
-
m($, this,
|
|
4498
|
+
let n = m($, this, Ml).call(this, e.clientX), r = m($, this, Al).call(this, n), i = (t = r == null ? void 0 : r.position) == null ? n : t;
|
|
4499
|
+
m($, this, Fl).call(this, i, r), h(ul, this) || (h(al, this).style.opacity = "1"), m($, this, Pl).call(this, i);
|
|
4499
4500
|
}
|
|
4500
|
-
function
|
|
4501
|
-
if (m($, this,
|
|
4502
|
-
let t = e * m($, this,
|
|
4503
|
-
this.range.value = e.toString(), this.updateBar(), m($, this,
|
|
4501
|
+
function Pl(e) {
|
|
4502
|
+
if (m($, this, Tl).call(this) || m($, this, Ll).call(this, e)) return;
|
|
4503
|
+
let t = e * m($, this, Sl).call(this);
|
|
4504
|
+
this.range.value = e.toString(), this.updateBar(), m($, this, Il).call(this, t);
|
|
4504
4505
|
}
|
|
4505
|
-
function
|
|
4506
|
+
function Fl(e, t) {
|
|
4506
4507
|
if (!h(Q, this) || !Number.isFinite(h(Q, this))) return;
|
|
4507
|
-
let n = e * h(Q, this), r = h(Q, this) - n, i = `-${m($, this,
|
|
4508
|
-
h(
|
|
4508
|
+
let n = e * h(Q, this), r = h(Q, this) - n, i = `-${m($, this, zl).call(this, r)}`;
|
|
4509
|
+
h(al, this).textContent = t ? `${t.marker.label}: ${i}` : i, h(al, this).style.left = `${Math.min(Math.max(e * 100, 2), 98)}%`;
|
|
4509
4510
|
}
|
|
4510
|
-
function
|
|
4511
|
+
function Il(e) {
|
|
4511
4512
|
this.dispatchEvent(new CustomEvent("seek", {
|
|
4512
4513
|
bubbles: !0,
|
|
4513
4514
|
composed: !0,
|
|
4514
4515
|
detail: e
|
|
4515
4516
|
}));
|
|
4516
4517
|
}
|
|
4517
|
-
function
|
|
4518
|
-
return h(
|
|
4518
|
+
function Ll(e) {
|
|
4519
|
+
return h(pl, this) || m($, this, Rl).call(this) || e < .999 ? !1 : (p(pl, this, !0), p(ml, this, !1), this.dispatchEvent(new CustomEvent(x.GO_LIVE, {
|
|
4519
4520
|
bubbles: !0,
|
|
4520
4521
|
composed: !0
|
|
4521
4522
|
})), !0);
|
|
4522
4523
|
}
|
|
4523
|
-
function
|
|
4524
|
+
function Rl() {
|
|
4524
4525
|
return !this.hasAttribute(g.TIMESHIFT_POSITION);
|
|
4525
4526
|
}
|
|
4526
|
-
function
|
|
4527
|
+
function zl(e) {
|
|
4527
4528
|
let t = Math.floor(e / 3600), n = Math.floor(e % 3600 / 60), r = Math.floor(e % 60);
|
|
4528
4529
|
return h(Q, this) && h(Q, this) >= 3600 ? `${t}:${n.toString().padStart(2, "0")}:${r.toString().padStart(2, "0")}` : `${n}:${r.toString().padStart(2, "0")}`;
|
|
4529
4530
|
}
|
|
4530
|
-
e(
|
|
4531
|
-
...
|
|
4531
|
+
e(xl, "observedAttributes", [
|
|
4532
|
+
...Ci.observedAttributes,
|
|
4532
4533
|
g.TIMESHIFT_POSITION,
|
|
4533
4534
|
g.DURATION,
|
|
4534
4535
|
g.TIMELINE_MARKERS
|
|
4535
4536
|
]);
|
|
4536
4537
|
//#endregion
|
|
4537
4538
|
//#region ../../libs/player-next/src/components/UserInputPlayOverlay.ts
|
|
4538
|
-
var
|
|
4539
|
-
|
|
4539
|
+
var Bl = document.createElement("template");
|
|
4540
|
+
Bl.innerHTML = `
|
|
4540
4541
|
<style>
|
|
4541
4542
|
:host {
|
|
4542
4543
|
display: var(--play-overlay-display);
|
|
@@ -4596,51 +4597,51 @@ Ll.innerHTML = `
|
|
|
4596
4597
|
</slot>
|
|
4597
4598
|
</slot>
|
|
4598
4599
|
`;
|
|
4599
|
-
var
|
|
4600
|
+
var Vl = /* @__PURE__ */ new WeakMap(), Hl = /* @__PURE__ */ new WeakMap(), Ul = /* @__PURE__ */ new WeakMap(), Wl = /* @__PURE__ */ new WeakMap(), Gl = class extends HTMLElement {
|
|
4600
4601
|
constructor() {
|
|
4601
|
-
super(), f(this,
|
|
4602
|
+
super(), f(this, Vl, null), f(this, Hl, () => {
|
|
4602
4603
|
this.dispatchEvent(new CustomEvent(x.REQUEST_USER_INPUT, {
|
|
4603
4604
|
bubbles: !0,
|
|
4604
4605
|
composed: !0
|
|
4605
4606
|
}));
|
|
4606
|
-
}), f(this,
|
|
4607
|
+
}), f(this, Ul, (e) => {
|
|
4607
4608
|
let { key: t } = e;
|
|
4608
4609
|
if (!this.keysUsed.includes(t)) {
|
|
4609
|
-
this.removeEventListener("keyup", h(
|
|
4610
|
+
this.removeEventListener("keyup", h(Ul, this));
|
|
4610
4611
|
return;
|
|
4611
4612
|
}
|
|
4612
4613
|
this.dispatchEvent(new CustomEvent(x.REQUEST_USER_INPUT, {
|
|
4613
4614
|
bubbles: !0,
|
|
4614
4615
|
composed: !0
|
|
4615
4616
|
}));
|
|
4616
|
-
}), f(this,
|
|
4617
|
+
}), f(this, Wl, (e) => {
|
|
4617
4618
|
let { metaKey: t, altKey: n, key: r } = e;
|
|
4618
4619
|
if (t || n || !this.keysUsed.includes(r)) {
|
|
4619
|
-
this.removeEventListener("keyup", h(
|
|
4620
|
+
this.removeEventListener("keyup", h(Ul, this));
|
|
4620
4621
|
return;
|
|
4621
4622
|
}
|
|
4622
|
-
this.addEventListener("keyup", h(
|
|
4623
|
-
}), this.attachShadow({ mode: "open" }).appendChild(
|
|
4623
|
+
this.addEventListener("keyup", h(Ul, this), { once: !0 });
|
|
4624
|
+
}), this.attachShadow({ mode: "open" }).appendChild(Bl.content.cloneNode(!0));
|
|
4624
4625
|
}
|
|
4625
4626
|
get keysUsed() {
|
|
4626
4627
|
return ["Enter", " "];
|
|
4627
4628
|
}
|
|
4628
4629
|
connectedCallback() {
|
|
4629
4630
|
var e;
|
|
4630
|
-
p(
|
|
4631
|
+
p(Vl, this, this.closest("vindral-controller")), (e = h(Vl, this)) == null || e.connectListener(this), this.setAttribute("aria-label", "Play"), this.setAttribute("role", "button"), this.enable();
|
|
4631
4632
|
}
|
|
4632
4633
|
enable() {
|
|
4633
|
-
this.addEventListener("click", h(
|
|
4634
|
+
this.addEventListener("click", h(Hl, this)), this.addEventListener("keydown", h(Wl, this)), this.tabIndex = 0;
|
|
4634
4635
|
}
|
|
4635
4636
|
disable() {
|
|
4636
|
-
this.removeEventListener("click", h(
|
|
4637
|
+
this.removeEventListener("click", h(Hl, this)), this.removeEventListener("keydown", h(Wl, this)), this.removeEventListener("keyup", h(Ul, this)), this.tabIndex = -1;
|
|
4637
4638
|
}
|
|
4638
4639
|
disconnectedCallback() {
|
|
4639
4640
|
var e;
|
|
4640
|
-
(e = h(
|
|
4641
|
+
(e = h(Vl, this)) == null || e.disconnectListener(this), this.disable();
|
|
4641
4642
|
}
|
|
4642
4643
|
};
|
|
4643
|
-
e(
|
|
4644
|
+
e(Gl, "observedAttributes", [
|
|
4644
4645
|
"hidden",
|
|
4645
4646
|
g.NEEDS_USER_INPUT_VIDEO,
|
|
4646
4647
|
g.NEEDS_USER_INPUT_AUDIO,
|
|
@@ -4648,68 +4649,68 @@ e(Hl, "observedAttributes", [
|
|
|
4648
4649
|
]);
|
|
4649
4650
|
//#endregion
|
|
4650
4651
|
//#region ../../libs/player-next/src/components/VindralCenterOverlay.ts
|
|
4651
|
-
var
|
|
4652
|
-
|
|
4653
|
-
var
|
|
4652
|
+
var Kl = document.createElement("template");
|
|
4653
|
+
Kl.innerHTML = "\n <style>\n :host {\n position: absolute;\n inset: 0;\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n gap: 16px;\n pointer-events: none;\n z-index: 1;\n }\n\n :host::before {\n content: \"\";\n position: absolute;\n inset: 0;\n z-index: -1;\n background-color: rgba(0, 0, 0, 0.3);\n background-image: var(--_backdrop-image, none);\n background-repeat: no-repeat;\n background-position: 50% 50%;\n background-size: contain;\n pointer-events: none;\n opacity: 0;\n transition: opacity 100ms;\n }\n\n :host([backdrop]:not([disable-backdrop]))::before {\n opacity: 1;\n }\n\n @media (prefers-reduced-motion: reduce) {\n :host::before {\n transition: none;\n }\n }\n </style>\n\n <slot></slot>\n";
|
|
4654
|
+
var ql = class extends HTMLElement {
|
|
4654
4655
|
constructor() {
|
|
4655
|
-
super(), this.attachShadow({ mode: "open" }).appendChild(
|
|
4656
|
+
super(), this.attachShadow({ mode: "open" }).appendChild(Kl.content.cloneNode(!0));
|
|
4656
4657
|
}
|
|
4657
4658
|
attributeChangedCallback(e, t, n) {
|
|
4658
4659
|
t !== n && e === "poster" && this.style.setProperty("--_backdrop-image", n ? `url("${n}")` : "none");
|
|
4659
4660
|
}
|
|
4660
4661
|
};
|
|
4661
|
-
e(
|
|
4662
|
+
e(ql, "observedAttributes", [
|
|
4662
4663
|
"backdrop",
|
|
4663
4664
|
"poster",
|
|
4664
4665
|
"disable-backdrop"
|
|
4665
4666
|
]);
|
|
4666
4667
|
//#endregion
|
|
4667
4668
|
//#region ../../libs/player-next/src/components/VindralMessage.ts
|
|
4668
|
-
var
|
|
4669
|
-
|
|
4670
|
-
var
|
|
4669
|
+
var Jl = document.createElement("template");
|
|
4670
|
+
Jl.innerHTML = "\n <style>\n :host {\n display: flex;\n flex-direction: column;\n align-items: center;\n max-width: 90%;\n color: var(--fg-strong);\n font-size: 20px;\n pointer-events: none;\n opacity: 1;\n transition:\n opacity 100ms,\n display 100ms allow-discrete;\n }\n\n :host([hidden]) {\n display: none;\n opacity: 0;\n }\n\n @starting-style {\n :host(:not([hidden])) {\n opacity: 0;\n }\n }\n\n @media (prefers-reduced-motion: reduce) {\n :host {\n transition: none;\n }\n }\n\n #title,\n #description {\n text-align: center;\n text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);\n margin: 0;\n }\n\n #title {\n margin-bottom: var(--padding-2);\n }\n\n @container (max-width: 600px) {\n :host {\n font-size: 15px;\n }\n }\n\n @container (max-width: 400px) {\n :host {\n font-size: 12px;\n }\n #title {\n margin-bottom: 0;\n }\n }\n\n @container (max-width: 150px) {\n :host {\n font-size: 10px;\n }\n #title,\n #description {\n font-size: 1.2em;\n margin: 0;\n }\n }\n </style>\n\n <h1 id=\"title\"></h1>\n <p id=\"description\"></p>\n";
|
|
4671
|
+
var Yl = /* @__PURE__ */ new WeakMap(), Xl = /* @__PURE__ */ new WeakMap(), Zl = class extends HTMLElement {
|
|
4671
4672
|
constructor() {
|
|
4672
|
-
super(), f(this,
|
|
4673
|
+
super(), f(this, Yl, void 0), f(this, Xl, void 0);
|
|
4673
4674
|
let e = this.attachShadow({ mode: "open" });
|
|
4674
|
-
e.appendChild(
|
|
4675
|
+
e.appendChild(Jl.content.cloneNode(!0)), p(Yl, this, e.querySelector("#title")), p(Xl, this, e.querySelector("#description"));
|
|
4675
4676
|
}
|
|
4676
4677
|
connectedCallback() {
|
|
4677
4678
|
this.hasAttribute("role") || (this.setAttribute("role", "alert"), this.setAttribute("aria-atomic", "true"));
|
|
4678
4679
|
}
|
|
4679
4680
|
attributeChangedCallback(e, t, n) {
|
|
4680
|
-
t !== n && (e === "title" ? h(
|
|
4681
|
+
t !== n && (e === "title" ? h(Yl, this).textContent = n : e === "description" && (h(Xl, this).textContent = n));
|
|
4681
4682
|
}
|
|
4682
4683
|
};
|
|
4683
|
-
e(
|
|
4684
|
+
e(Zl, "observedAttributes", [
|
|
4684
4685
|
"title",
|
|
4685
4686
|
"description",
|
|
4686
4687
|
"hidden"
|
|
4687
4688
|
]);
|
|
4688
4689
|
//#endregion
|
|
4689
4690
|
//#region ../../libs/player-next/src/components/VindralPlayOverlay.ts
|
|
4690
|
-
var
|
|
4691
|
-
|
|
4692
|
-
var
|
|
4691
|
+
var Ql = document.createElement("template");
|
|
4692
|
+
Ql.innerHTML = "\n <style>\n :host {\n display: flex;\n align-items: center;\n justify-content: center;\n pointer-events: none;\n opacity: 1;\n transition:\n opacity 100ms,\n display 100ms allow-discrete;\n }\n\n :host([hidden]) {\n display: none;\n opacity: 0;\n }\n\n @starting-style {\n :host(:not([hidden])) {\n opacity: 0;\n }\n }\n\n @media (prefers-reduced-motion: reduce) {\n :host {\n transition: none;\n }\n }\n\n :host(:focus-visible) {\n outline: none;\n outline: 0;\n }\n\n :host(:focus-visible) svg {\n outline: 0;\n }\n\n :host(:where(:focus)) svg {\n box-shadow: none;\n outline: 0;\n }\n\n :host(:active) svg {\n scale: 0.9;\n }\n\n slot#play {\n color: var(--fg-strong);\n pointer-events: auto;\n cursor: pointer;\n }\n\n slot#play > svg {\n width: var(--play-overlay-icon-size);\n height: var(--play-overlay-icon-size);\n }\n </style>\n\n <slot id=\"play\" name=\"icon\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"currentColor\"><path stroke=\"none\" d=\"M0 0h24v24H0z\" fill=\"none\"/><path d=\"M6 4v16a1 1 0 0 0 1.524 .852l13 -8a1 1 0 0 0 0 -1.704l-13 -8a1 1 0 0 0 -1.524 .852z\" /></svg>\n</slot>\n";
|
|
4693
|
+
var $l = /* @__PURE__ */ new WeakMap(), eu = class extends HTMLElement {
|
|
4693
4694
|
constructor() {
|
|
4694
|
-
super(), f(this,
|
|
4695
|
+
super(), f(this, $l, null), this.attachShadow({ mode: "open" }).appendChild(Ql.content.cloneNode(!0));
|
|
4695
4696
|
}
|
|
4696
4697
|
connectedCallback() {
|
|
4697
4698
|
var e;
|
|
4698
|
-
p(
|
|
4699
|
+
p($l, this, this.closest("vindral-controller")), (e = h($l, this)) == null || e.connectListener(this), this.setAttribute("aria-label", "Play"), this.setAttribute("role", "button"), this.tabIndex = 0;
|
|
4699
4700
|
}
|
|
4700
4701
|
disconnectedCallback() {
|
|
4701
4702
|
var e;
|
|
4702
|
-
(e = h(
|
|
4703
|
+
(e = h($l, this)) == null || e.disconnectListener(this);
|
|
4703
4704
|
}
|
|
4704
4705
|
attributeChangedCallback(e, t, n) {
|
|
4705
4706
|
t !== n && e === "hidden" && !_(n) && this.focus();
|
|
4706
4707
|
}
|
|
4707
4708
|
};
|
|
4708
|
-
e(
|
|
4709
|
+
e(eu, "observedAttributes", ["hidden"]);
|
|
4709
4710
|
//#endregion
|
|
4710
4711
|
//#region ../../libs/player-next/src/components/VolumeRange.ts
|
|
4711
|
-
var
|
|
4712
|
-
|
|
4712
|
+
var tu, nu = "Volume", ru = document.createElement("template");
|
|
4713
|
+
ru.innerHTML = `
|
|
4713
4714
|
<style>
|
|
4714
4715
|
:host {
|
|
4715
4716
|
display: var(--volume-range-display);
|
|
@@ -4734,29 +4735,29 @@ eu.innerHTML = `
|
|
|
4734
4735
|
transition-delay: 0s;
|
|
4735
4736
|
}
|
|
4736
4737
|
</style>
|
|
4737
|
-
<span class="tooltip" aria-hidden="true">${
|
|
4738
|
+
<span class="tooltip" aria-hidden="true">${nu}</span>
|
|
4738
4739
|
`;
|
|
4739
|
-
var
|
|
4740
|
+
var iu = (e) => `${Math.round(e * 100)}%`, au = /* @__PURE__ */ new WeakMap(), ou = /* @__PURE__ */ new WeakMap(), su = /* @__PURE__ */ new WeakMap(), cu = class extends Ci {
|
|
4740
4741
|
constructor() {
|
|
4741
4742
|
var e, t;
|
|
4742
|
-
super(), f(this,
|
|
4743
|
+
super(), f(this, au, void 0), f(this, ou, void 0), f(this, su, () => {
|
|
4743
4744
|
let e = this.range.valueAsNumber;
|
|
4744
4745
|
this.dispatchEvent(new CustomEvent(x.SET_VOLUME, {
|
|
4745
4746
|
bubbles: !0,
|
|
4746
4747
|
composed: !0,
|
|
4747
4748
|
detail: e
|
|
4748
4749
|
}));
|
|
4749
|
-
}), (e = this.shadowRoot) == null || e.appendChild(
|
|
4750
|
+
}), (e = this.shadowRoot) == null || e.appendChild(ru.content.cloneNode(!0)), p(au, this, (t = this.shadowRoot) == null ? void 0 : t.querySelector(".tooltip"));
|
|
4750
4751
|
}
|
|
4751
4752
|
connectedCallback() {
|
|
4752
|
-
super.connectedCallback(), this.range.addEventListener("input", h(
|
|
4753
|
+
super.connectedCallback(), this.range.addEventListener("input", h(su, this)), this.range.setAttribute("aria-label", nu), p(ou, this, De(this, h(au, this)));
|
|
4753
4754
|
}
|
|
4754
4755
|
disconnectedCallback() {
|
|
4755
4756
|
var e;
|
|
4756
|
-
super.disconnectedCallback(), this.range.removeEventListener("input", h(
|
|
4757
|
+
super.disconnectedCallback(), this.range.removeEventListener("input", h(su, this)), (e = h(ou, this)) == null || e.call(this);
|
|
4757
4758
|
}
|
|
4758
4759
|
attributeChangedCallback(e, t, n) {
|
|
4759
|
-
super.attributeChangedCallback(e, t, n), (e === g.MUTED || e === g.VOLUME) && (this.range.valueAsNumber = this.muted ? 0 : parseFloat(this.volume), this.range.setAttribute("aria-valuetext",
|
|
4760
|
+
super.attributeChangedCallback(e, t, n), (e === g.MUTED || e === g.VOLUME) && (this.range.valueAsNumber = this.muted ? 0 : parseFloat(this.volume), this.range.setAttribute("aria-valuetext", iu(this.range.valueAsNumber)), this.updateBar());
|
|
4760
4761
|
}
|
|
4761
4762
|
get volume() {
|
|
4762
4763
|
var e;
|
|
@@ -4766,15 +4767,15 @@ var tu = (e) => `${Math.round(e * 100)}%`, nu = /* @__PURE__ */ new WeakMap(), r
|
|
|
4766
4767
|
return this.hasAttribute(g.MUTED);
|
|
4767
4768
|
}
|
|
4768
4769
|
};
|
|
4769
|
-
|
|
4770
|
-
...y(
|
|
4770
|
+
tu = cu, e(cu, "observedAttributes", [
|
|
4771
|
+
...y(tu, "observedAttributes", tu),
|
|
4771
4772
|
g.MUTED,
|
|
4772
4773
|
g.VOLUME
|
|
4773
4774
|
]);
|
|
4774
4775
|
//#endregion
|
|
4775
4776
|
//#region ../../libs/player-next/src/registerComponents.ts
|
|
4776
|
-
function
|
|
4777
|
-
customElements.define("vindral-controller",
|
|
4777
|
+
function lu() {
|
|
4778
|
+
customElements.define("vindral-controller", Oa), customElements.define("vindral-control-bar", Vn), customElements.define("vindral-advanced-rendition-menu", Ye), customElements.define("vindral-advanced-rendition-menu-list", ct), customElements.define("vindral-play-button", ls), customElements.define("vindral-mute-button", rs), customElements.define("vindral-buffering-overlay", Ft), customElements.define("vindral-scroll-overlay", Vc), customElements.define("vindral-play-overlay", eu), customElements.define("vindral-user-input-play-overlay", Gl), customElements.define("vindral-fullscreen-button", yo), customElements.define("vindral-rendition-levels-menu", pc), customElements.define("vindral-rendition-levels-menu-list", Sc), customElements.define("vindral-channel-grid-button", Pn), customElements.define("vindral-channel-grid", on), customElements.define("vindral-channel-grid-item", Yt), customElements.define("vindral-pip-button", os), customElements.define("vindral-airplay-button", Ot), customElements.define("vindral-cast-button", zt), customElements.define("vindral-cast-overlay", Gt), customElements.define("vindral-buffering-icon", Mt), customElements.define("vindral-language-menu", wo), customElements.define("vindral-language-menu-list", Ro), customElements.define("vindral-center-overlay", ql), customElements.define("vindral-message", Zl), customElements.define("vindral-volume-range", cu), customElements.define("vindral-poster-overlay", ac), customElements.define("vindral-player", Us), customElements.define("vindral-seek-bar", xl), customElements.define("vindral-live-button", es);
|
|
4778
4779
|
}
|
|
4779
4780
|
//#endregion
|
|
4780
|
-
export {
|
|
4781
|
+
export { lu as t };
|