@halibegic/react-video-player 0.0.35 → 0.0.37

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.
@@ -2,7 +2,7 @@ var Fn = Object.defineProperty, Mn = Object.defineProperties;
2
2
  var Nn = Object.getOwnPropertyDescriptors;
3
3
  var be = Object.getOwnPropertySymbols;
4
4
  var pt = Object.prototype.hasOwnProperty, vt = Object.prototype.propertyIsEnumerable;
5
- var mt = (e, t, n) => t in e ? Fn(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n, j = (e, t) => {
5
+ var mt = (e, t, n) => t in e ? Fn(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n, P = (e, t) => {
6
6
  for (var n in t || (t = {}))
7
7
  pt.call(t, n) && mt(e, n, t[n]);
8
8
  if (be)
@@ -19,13 +19,13 @@ var ne = (e, t) => {
19
19
  t.indexOf(o) < 0 && vt.call(e, o) && (n[o] = e[o]);
20
20
  return n;
21
21
  };
22
- import St, { useLayoutEffect as Vn, useEffect as N, useRef as O, useState as X, createContext as bt, useContext as Pt, useCallback as U, forwardRef as Me } from "react";
23
- import { create as jt, useStore as Lt } from "zustand";
22
+ import St, { useLayoutEffect as Vn, useEffect as N, useRef as O, useState as X, createContext as bt, useContext as Lt, useCallback as B, forwardRef as Me } from "react";
23
+ import { create as Pt, useStore as jt } from "zustand";
24
24
  import An from "mitt";
25
25
  import re from "hls.js";
26
- import * as Pe from "@radix-ui/react-slider";
26
+ import * as Le from "@radix-ui/react-slider";
27
27
  import * as xe from "@radix-ui/react-popover";
28
- import * as je from "@radix-ui/react-scroll-area";
28
+ import * as Pe from "@radix-ui/react-scroll-area";
29
29
  function kt(e) {
30
30
  var t = this.constructor;
31
31
  return this.then(
@@ -128,7 +128,7 @@ function Nt(e, t) {
128
128
  e._handled = !0, F._immediateFn(function() {
129
129
  var n = e._state === 1 ? t.onFulfilled : t.onRejected;
130
130
  if (n === null) {
131
- (e._state === 1 ? qe : Te)(t.promise, e._value);
131
+ (e._state === 1 ? We : Te)(t.promise, e._value);
132
132
  return;
133
133
  }
134
134
  var o;
@@ -138,10 +138,10 @@ function Nt(e, t) {
138
138
  Te(t.promise, s);
139
139
  return;
140
140
  }
141
- qe(t.promise, o);
141
+ We(t.promise, o);
142
142
  });
143
143
  }
144
- function qe(e, t) {
144
+ function We(e, t) {
145
145
  try {
146
146
  if (t === e)
147
147
  throw new TypeError("A promise cannot be resolved with itself.");
@@ -171,7 +171,7 @@ function Ze(e) {
171
171
  Nt(e, e._deferreds[t]);
172
172
  e._deferreds = null;
173
173
  }
174
- function Bn(e, t, n) {
174
+ function Un(e, t, n) {
175
175
  this.onFulfilled = typeof e == "function" ? e : null, this.onRejected = typeof t == "function" ? t : null, this.promise = n;
176
176
  }
177
177
  function Vt(e, t) {
@@ -179,7 +179,7 @@ function Vt(e, t) {
179
179
  try {
180
180
  e(
181
181
  function(o) {
182
- n || (n = !0, qe(t, o));
182
+ n || (n = !0, We(t, o));
183
183
  },
184
184
  function(o) {
185
185
  n || (n = !0, Te(t, o));
@@ -195,7 +195,7 @@ F.prototype.catch = function(e) {
195
195
  };
196
196
  F.prototype.then = function(e, t) {
197
197
  var n = new this.constructor(Hn);
198
- return Nt(this, new Bn(e, t, n)), n;
198
+ return Nt(this, new Un(e, t, n)), n;
199
199
  };
200
200
  F.prototype.finally = kt;
201
201
  F.all = function(e) {
@@ -268,9 +268,9 @@ var ae = (function() {
268
268
  throw new Error("unable to locate global object");
269
269
  })();
270
270
  typeof ae.Promise != "function" ? ae.Promise = F : (ae.Promise.prototype.finally || (ae.Promise.prototype.finally = kt), ae.Promise.allSettled || (ae.Promise.allSettled = It), ae.Promise.any || (ae.Promise.any = Ft));
271
- var Le = { exports: {} }, ge = {};
271
+ var je = { exports: {} }, ge = {};
272
272
  var yt;
273
- function Un() {
273
+ function Bn() {
274
274
  if (yt) return ge;
275
275
  yt = 1;
276
276
  var e = St, t = Symbol.for("react.element"), n = Symbol.for("react.fragment"), o = Object.prototype.hasOwnProperty, s = e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, c = { key: !0, ref: !0, __self: !0, __source: !0 };
@@ -287,11 +287,11 @@ var we = {};
287
287
  var gt;
288
288
  function zn() {
289
289
  return gt || (gt = 1, process.env.NODE_ENV !== "production" && (function() {
290
- var e = St, t = Symbol.for("react.element"), n = Symbol.for("react.portal"), o = Symbol.for("react.fragment"), s = Symbol.for("react.strict_mode"), c = Symbol.for("react.profiler"), u = Symbol.for("react.provider"), i = Symbol.for("react.context"), l = Symbol.for("react.forward_ref"), d = Symbol.for("react.suspense"), g = Symbol.for("react.suspense_list"), y = Symbol.for("react.memo"), v = Symbol.for("react.lazy"), _ = Symbol.for("react.offscreen"), L = Symbol.iterator, S = "@@iterator";
291
- function P(r) {
290
+ var e = St, t = Symbol.for("react.element"), n = Symbol.for("react.portal"), o = Symbol.for("react.fragment"), s = Symbol.for("react.strict_mode"), c = Symbol.for("react.profiler"), u = Symbol.for("react.provider"), i = Symbol.for("react.context"), l = Symbol.for("react.forward_ref"), d = Symbol.for("react.suspense"), g = Symbol.for("react.suspense_list"), y = Symbol.for("react.memo"), v = Symbol.for("react.lazy"), _ = Symbol.for("react.offscreen"), j = Symbol.iterator, S = "@@iterator";
291
+ function L(r) {
292
292
  if (r === null || typeof r != "object")
293
293
  return null;
294
- var h = L && r[L] || r[S];
294
+ var h = j && r[j] || r[S];
295
295
  return typeof h == "function" ? h : null;
296
296
  }
297
297
  var M = e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
@@ -304,29 +304,29 @@ function zn() {
304
304
  }
305
305
  function k(r, h, m) {
306
306
  {
307
- var w = M.ReactDebugCurrentFrame, E = w.getStackAddendum();
308
- E !== "" && (h += "%s", m = m.concat([E]));
309
- var b = m.map(function(C) {
310
- return String(C);
307
+ var w = M.ReactDebugCurrentFrame, C = w.getStackAddendum();
308
+ C !== "" && (h += "%s", m = m.concat([C]));
309
+ var b = m.map(function(E) {
310
+ return String(E);
311
311
  });
312
312
  b.unshift("Warning: " + h), Function.prototype.apply.call(console[r], console, b);
313
313
  }
314
314
  }
315
- var T = !1, I = !1, p = !1, B = !1, J = !1, q;
316
- q = Symbol.for("react.module.reference");
315
+ var T = !1, I = !1, p = !1, H = !1, G = !1, W;
316
+ W = Symbol.for("react.module.reference");
317
317
  function V(r) {
318
- return !!(typeof r == "string" || typeof r == "function" || r === o || r === c || J || r === s || r === d || r === g || B || r === _ || T || I || p || typeof r == "object" && r !== null && (r.$$typeof === v || r.$$typeof === y || r.$$typeof === u || r.$$typeof === i || r.$$typeof === l || // This needs to include all possible module reference object
318
+ return !!(typeof r == "string" || typeof r == "function" || r === o || r === c || G || r === s || r === d || r === g || H || r === _ || T || I || p || typeof r == "object" && r !== null && (r.$$typeof === v || r.$$typeof === y || r.$$typeof === u || r.$$typeof === i || r.$$typeof === l || // This needs to include all possible module reference object
319
319
  // types supported by any Flight configuration anywhere since
320
320
  // we don't know which Flight build this will end up being used
321
321
  // with.
322
- r.$$typeof === q || r.getModuleId !== void 0));
322
+ r.$$typeof === W || r.getModuleId !== void 0));
323
323
  }
324
324
  function D(r, h, m) {
325
325
  var w = r.displayName;
326
326
  if (w)
327
327
  return w;
328
- var E = h.displayName || h.name || "";
329
- return E !== "" ? m + "(" + E + ")" : m;
328
+ var C = h.displayName || h.name || "";
329
+ return C !== "" ? m + "(" + C + ")" : m;
330
330
  }
331
331
  function Q(r) {
332
332
  return r.displayName || "Context";
@@ -366,9 +366,9 @@ function zn() {
366
366
  var w = r.displayName || null;
367
367
  return w !== null ? w : Z(r.type) || "Memo";
368
368
  case v: {
369
- var E = r, b = E._payload, C = E._init;
369
+ var C = r, b = C._payload, E = C._init;
370
370
  try {
371
- return Z(C(b));
371
+ return Z(E(b));
372
372
  } catch (x) {
373
373
  return null;
374
374
  }
@@ -376,14 +376,14 @@ function zn() {
376
376
  }
377
377
  return null;
378
378
  }
379
- var z = Object.assign, oe = 0, ue, te, W, ve, Ye, Xe, Ge;
379
+ var z = Object.assign, oe = 0, ue, te, q, ve, Ye, Xe, Ge;
380
380
  function Je() {
381
381
  }
382
382
  Je.__reactDisabledLog = !0;
383
383
  function an() {
384
384
  {
385
385
  if (oe === 0) {
386
- ue = console.log, te = console.info, W = console.warn, ve = console.error, Ye = console.group, Xe = console.groupCollapsed, Ge = console.groupEnd;
386
+ ue = console.log, te = console.info, q = console.warn, ve = console.error, Ye = console.group, Xe = console.groupCollapsed, Ge = console.groupEnd;
387
387
  var r = {
388
388
  configurable: !0,
389
389
  enumerable: !0,
@@ -419,7 +419,7 @@ function zn() {
419
419
  value: te
420
420
  }),
421
421
  warn: z({}, r, {
422
- value: W
422
+ value: q
423
423
  }),
424
424
  error: z({}, r, {
425
425
  value: ve
@@ -439,94 +439,94 @@ function zn() {
439
439
  }
440
440
  }
441
441
  var Ve = M.ReactCurrentDispatcher, Ae;
442
- function Ce(r, h, m) {
442
+ function Ee(r, h, m) {
443
443
  {
444
444
  if (Ae === void 0)
445
445
  try {
446
446
  throw Error();
447
- } catch (E) {
448
- var w = E.stack.trim().match(/\n( *(at )?)/);
447
+ } catch (C) {
448
+ var w = C.stack.trim().match(/\n( *(at )?)/);
449
449
  Ae = w && w[1] || "";
450
450
  }
451
451
  return `
452
452
  ` + Ae + r;
453
453
  }
454
454
  }
455
- var Oe = !1, Ee;
455
+ var Oe = !1, Ce;
456
456
  {
457
457
  var cn = typeof WeakMap == "function" ? WeakMap : Map;
458
- Ee = new cn();
458
+ Ce = new cn();
459
459
  }
460
460
  function Qe(r, h) {
461
461
  if (!r || Oe)
462
462
  return "";
463
463
  {
464
- var m = Ee.get(r);
464
+ var m = Ce.get(r);
465
465
  if (m !== void 0)
466
466
  return m;
467
467
  }
468
468
  var w;
469
469
  Oe = !0;
470
- var E = Error.prepareStackTrace;
470
+ var C = Error.prepareStackTrace;
471
471
  Error.prepareStackTrace = void 0;
472
472
  var b;
473
473
  b = Ve.current, Ve.current = null, an();
474
474
  try {
475
475
  if (h) {
476
- var C = function() {
476
+ var E = function() {
477
477
  throw Error();
478
478
  };
479
- if (Object.defineProperty(C.prototype, "props", {
479
+ if (Object.defineProperty(E.prototype, "props", {
480
480
  set: function() {
481
481
  throw Error();
482
482
  }
483
483
  }), typeof Reflect == "object" && Reflect.construct) {
484
484
  try {
485
- Reflect.construct(C, []);
486
- } catch (G) {
487
- w = G;
485
+ Reflect.construct(E, []);
486
+ } catch (J) {
487
+ w = J;
488
488
  }
489
- Reflect.construct(r, [], C);
489
+ Reflect.construct(r, [], E);
490
490
  } else {
491
491
  try {
492
- C.call();
493
- } catch (G) {
494
- w = G;
492
+ E.call();
493
+ } catch (J) {
494
+ w = J;
495
495
  }
496
- r.call(C.prototype);
496
+ r.call(E.prototype);
497
497
  }
498
498
  } else {
499
499
  try {
500
500
  throw Error();
501
- } catch (G) {
502
- w = G;
501
+ } catch (J) {
502
+ w = J;
503
503
  }
504
504
  r();
505
505
  }
506
- } catch (G) {
507
- if (G && w && typeof G.stack == "string") {
508
- for (var x = G.stack.split(`
506
+ } catch (J) {
507
+ if (J && w && typeof J.stack == "string") {
508
+ for (var x = J.stack.split(`
509
509
  `), Y = w.stack.split(`
510
- `), A = x.length - 1, H = Y.length - 1; A >= 1 && H >= 0 && x[A] !== Y[H]; )
511
- H--;
512
- for (; A >= 1 && H >= 0; A--, H--)
513
- if (x[A] !== Y[H]) {
514
- if (A !== 1 || H !== 1)
510
+ `), A = x.length - 1, $ = Y.length - 1; A >= 1 && $ >= 0 && x[A] !== Y[$]; )
511
+ $--;
512
+ for (; A >= 1 && $ >= 0; A--, $--)
513
+ if (x[A] !== Y[$]) {
514
+ if (A !== 1 || $ !== 1)
515
515
  do
516
- if (A--, H--, H < 0 || x[A] !== Y[H]) {
516
+ if (A--, $--, $ < 0 || x[A] !== Y[$]) {
517
517
  var ee = `
518
518
  ` + x[A].replace(" at new ", " at ");
519
- return r.displayName && ee.includes("<anonymous>") && (ee = ee.replace("<anonymous>", r.displayName)), typeof r == "function" && Ee.set(r, ee), ee;
519
+ return r.displayName && ee.includes("<anonymous>") && (ee = ee.replace("<anonymous>", r.displayName)), typeof r == "function" && Ce.set(r, ee), ee;
520
520
  }
521
- while (A >= 1 && H >= 0);
521
+ while (A >= 1 && $ >= 0);
522
522
  break;
523
523
  }
524
524
  }
525
525
  } finally {
526
- Oe = !1, Ve.current = b, ln(), Error.prepareStackTrace = E;
526
+ Oe = !1, Ve.current = b, ln(), Error.prepareStackTrace = C;
527
527
  }
528
- var fe = r ? r.displayName || r.name : "", ce = fe ? Ce(fe) : "";
529
- return typeof r == "function" && Ee.set(r, ce), ce;
528
+ var fe = r ? r.displayName || r.name : "", ce = fe ? Ee(fe) : "";
529
+ return typeof r == "function" && Ce.set(r, ce), ce;
530
530
  }
531
531
  function un(r, h, m) {
532
532
  return Qe(r, !1);
@@ -541,12 +541,12 @@ function zn() {
541
541
  if (typeof r == "function")
542
542
  return Qe(r, dn(r));
543
543
  if (typeof r == "string")
544
- return Ce(r);
544
+ return Ee(r);
545
545
  switch (r) {
546
546
  case d:
547
- return Ce("Suspense");
547
+ return Ee("Suspense");
548
548
  case g:
549
- return Ce("SuspenseList");
549
+ return Ee("SuspenseList");
550
550
  }
551
551
  if (typeof r == "object")
552
552
  switch (r.$$typeof) {
@@ -555,10 +555,10 @@ function zn() {
555
555
  case y:
556
556
  return Re(r.type, h, m);
557
557
  case v: {
558
- var w = r, E = w._payload, b = w._init;
558
+ var w = r, C = w._payload, b = w._init;
559
559
  try {
560
- return Re(b(E), h, m);
561
- } catch (C) {
560
+ return Re(b(C), h, m);
561
+ } catch (E) {
562
562
  }
563
563
  }
564
564
  }
@@ -572,22 +572,22 @@ function zn() {
572
572
  } else
573
573
  tt.setExtraStackFrame(null);
574
574
  }
575
- function fn(r, h, m, w, E) {
575
+ function fn(r, h, m, w, C) {
576
576
  {
577
577
  var b = Function.call.bind(ye);
578
- for (var C in r)
579
- if (b(r, C)) {
578
+ for (var E in r)
579
+ if (b(r, E)) {
580
580
  var x = void 0;
581
581
  try {
582
- if (typeof r[C] != "function") {
583
- var Y = Error((w || "React class") + ": " + m + " type `" + C + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof r[C] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
582
+ if (typeof r[E] != "function") {
583
+ var Y = Error((w || "React class") + ": " + m + " type `" + E + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof r[E] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
584
584
  throw Y.name = "Invariant Violation", Y;
585
585
  }
586
- x = r[C](h, C, w, m, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
586
+ x = r[E](h, E, w, m, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
587
587
  } catch (A) {
588
588
  x = A;
589
589
  }
590
- x && !(x instanceof Error) && (Se(E), R("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", w || "React class", m, C, typeof x), Se(null)), x instanceof Error && !(x.message in et) && (et[x.message] = !0, Se(E), R("Failed %s type: %s", m, x.message), Se(null));
590
+ x && !(x instanceof Error) && (Se(C), R("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", w || "React class", m, E, typeof x), Se(null)), x instanceof Error && !(x.message in et) && (et[x.message] = !0, Se(C), R("Failed %s type: %s", m, x.message), Se(null));
591
591
  }
592
592
  }
593
593
  }
@@ -662,7 +662,7 @@ function zn() {
662
662
  });
663
663
  }
664
664
  }
665
- var xn = function(r, h, m, w, E, b, C) {
665
+ var xn = function(r, h, m, w, C, b, E) {
666
666
  var x = {
667
667
  // This tag allows us to uniquely identify this as a React Element
668
668
  $$typeof: t,
@@ -670,7 +670,7 @@ function zn() {
670
670
  type: r,
671
671
  key: h,
672
672
  ref: m,
673
- props: C,
673
+ props: E,
674
674
  // Record the component responsible for creating this element.
675
675
  _owner: b
676
676
  };
@@ -688,25 +688,25 @@ function zn() {
688
688
  configurable: !1,
689
689
  enumerable: !1,
690
690
  writable: !1,
691
- value: E
691
+ value: C
692
692
  }), Object.freeze && (Object.freeze(x.props), Object.freeze(x)), x;
693
693
  };
694
- function Cn(r, h, m, w, E) {
694
+ function En(r, h, m, w, C) {
695
695
  {
696
- var b, C = {}, x = null, Y = null;
697
- m !== void 0 && (rt(m), x = "" + m), gn(h) && (rt(h.key), x = "" + h.key), yn(h) && (Y = h.ref, wn(h, E));
696
+ var b, E = {}, x = null, Y = null;
697
+ m !== void 0 && (rt(m), x = "" + m), gn(h) && (rt(h.key), x = "" + h.key), yn(h) && (Y = h.ref, wn(h, C));
698
698
  for (b in h)
699
- ye.call(h, b) && !vn.hasOwnProperty(b) && (C[b] = h[b]);
699
+ ye.call(h, b) && !vn.hasOwnProperty(b) && (E[b] = h[b]);
700
700
  if (r && r.defaultProps) {
701
701
  var A = r.defaultProps;
702
702
  for (b in A)
703
- C[b] === void 0 && (C[b] = A[b]);
703
+ E[b] === void 0 && (E[b] = A[b]);
704
704
  }
705
705
  if (x || Y) {
706
- var H = typeof r == "function" ? r.displayName || r.name || "Unknown" : r;
707
- x && Tn(C, H), Y && _n(C, H);
706
+ var $ = typeof r == "function" ? r.displayName || r.name || "Unknown" : r;
707
+ x && Tn(E, $), Y && _n(E, $);
708
708
  }
709
- return xn(r, x, Y, E, w, ot.current, C);
709
+ return xn(r, x, Y, C, w, ot.current, E);
710
710
  }
711
711
  }
712
712
  var $e = M.ReactCurrentOwner, at = M.ReactDebugCurrentFrame;
@@ -717,9 +717,9 @@ function zn() {
717
717
  } else
718
718
  at.setExtraStackFrame(null);
719
719
  }
720
- var Be;
721
- Be = !1;
722
- function Ue(r) {
720
+ var Ue;
721
+ Ue = !1;
722
+ function Be(r) {
723
723
  return typeof r == "object" && r !== null && r.$$typeof === t;
724
724
  }
725
725
  function lt() {
@@ -734,7 +734,7 @@ Check the render method of \`` + r + "`.";
734
734
  return "";
735
735
  }
736
736
  }
737
- function En(r) {
737
+ function Cn(r) {
738
738
  return "";
739
739
  }
740
740
  var ct = {};
@@ -770,15 +770,15 @@ Check the top-level render call using <` + m + ">.");
770
770
  if (He(r))
771
771
  for (var m = 0; m < r.length; m++) {
772
772
  var w = r[m];
773
- Ue(w) && ut(w, h);
773
+ Be(w) && ut(w, h);
774
774
  }
775
- else if (Ue(r))
775
+ else if (Be(r))
776
776
  r._store && (r._store.validated = !0);
777
777
  else if (r) {
778
- var E = P(r);
779
- if (typeof E == "function" && E !== r.entries)
780
- for (var b = E.call(r), C; !(C = b.next()).done; )
781
- Ue(C.value) && ut(C.value, h);
778
+ var C = L(r);
779
+ if (typeof C == "function" && C !== r.entries)
780
+ for (var b = C.call(r), E; !(E = b.next()).done; )
781
+ Be(E.value) && ut(E.value, h);
782
782
  }
783
783
  }
784
784
  }
@@ -799,10 +799,10 @@ Check the top-level render call using <` + m + ">.");
799
799
  if (m) {
800
800
  var w = Z(h);
801
801
  fn(m, r.props, "prop", w, r);
802
- } else if (h.PropTypes !== void 0 && !Be) {
803
- Be = !0;
804
- var E = Z(h);
805
- R("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", E || "Unknown");
802
+ } else if (h.PropTypes !== void 0 && !Ue) {
803
+ Ue = !0;
804
+ var C = Z(h);
805
+ R("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", C || "Unknown");
806
806
  }
807
807
  typeof h.getDefaultProps == "function" && !h.getDefaultProps.isReactClassApproved && R("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
808
808
  }
@@ -820,21 +820,21 @@ Check the top-level render call using <` + m + ">.");
820
820
  }
821
821
  }
822
822
  var ft = {};
823
- function ht(r, h, m, w, E, b) {
823
+ function ht(r, h, m, w, C, b) {
824
824
  {
825
- var C = V(r);
826
- if (!C) {
825
+ var E = V(r);
826
+ if (!E) {
827
827
  var x = "";
828
828
  (r === void 0 || typeof r == "object" && r !== null && Object.keys(r).length === 0) && (x += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
829
- var Y = En();
829
+ var Y = Cn();
830
830
  Y ? x += Y : x += lt();
831
831
  var A;
832
832
  r === null ? A = "null" : He(r) ? A = "array" : r !== void 0 && r.$$typeof === t ? (A = "<" + (Z(r.type) || "Unknown") + " />", x = " Did you accidentally export a JSX literal instead of a component?") : A = typeof r, R("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", A, x);
833
833
  }
834
- var H = Cn(r, h, m, E, b);
835
- if (H == null)
836
- return H;
837
- if (C) {
834
+ var $ = En(r, h, m, C, b);
835
+ if ($ == null)
836
+ return $;
837
+ if (E) {
838
838
  var ee = h.children;
839
839
  if (ee !== void 0)
840
840
  if (w)
@@ -848,11 +848,11 @@ Check the top-level render call using <` + m + ">.");
848
848
  dt(ee, r);
849
849
  }
850
850
  if (ye.call(h, "key")) {
851
- var ce = Z(r), G = Object.keys(h).filter(function(Dn) {
851
+ var ce = Z(r), J = Object.keys(h).filter(function(Dn) {
852
852
  return Dn !== "key";
853
- }), ze = G.length > 0 ? "{key: someKey, " + G.join(": ..., ") + ": ...}" : "{key: someKey}";
853
+ }), ze = J.length > 0 ? "{key: someKey, " + J.join(": ..., ") + ": ...}" : "{key: someKey}";
854
854
  if (!ft[ce + ze]) {
855
- var In = G.length > 0 ? "{" + G.join(": ..., ") + ": ...}" : "{}";
855
+ var In = J.length > 0 ? "{" + J.join(": ..., ") + ": ...}" : "{}";
856
856
  R(`A props object containing a "key" prop is being spread into JSX:
857
857
  let props = %s;
858
858
  <%s {...props} />
@@ -861,28 +861,29 @@ React keys must be passed directly to JSX without using spread:
861
861
  <%s key={someKey} {...props} />`, ze, ce, In, ce), ft[ce + ze] = !0;
862
862
  }
863
863
  }
864
- return r === o ? bn(H) : Sn(H), H;
864
+ return r === o ? bn($) : Sn($), $;
865
865
  }
866
866
  }
867
- function Pn(r, h, m) {
867
+ function Ln(r, h, m) {
868
868
  return ht(r, h, m, !0);
869
869
  }
870
- function jn(r, h, m) {
870
+ function Pn(r, h, m) {
871
871
  return ht(r, h, m, !1);
872
872
  }
873
- var Ln = jn, kn = Pn;
874
- we.Fragment = o, we.jsx = Ln, we.jsxs = kn;
873
+ var jn = Pn, kn = Ln;
874
+ we.Fragment = o, we.jsx = jn, we.jsxs = kn;
875
875
  })()), we;
876
876
  }
877
877
  var wt;
878
- function Wn() {
879
- return wt || (wt = 1, process.env.NODE_ENV === "production" ? Le.exports = Un() : Le.exports = zn()), Le.exports;
878
+ function qn() {
879
+ return wt || (wt = 1, process.env.NODE_ENV === "production" ? je.exports = Bn() : je.exports = zn()), je.exports;
880
880
  }
881
- var a = Wn();
882
- const qn = "_playerNotice_1m0i8_1", Zn = "_playerNoticeTitle_1m0i8_17", Kn = "_playerNoticeText_1m0i8_26", se = {
883
- playerNotice: qn,
881
+ var a = qn();
882
+ const Wn = "_playerNotice_lq5nz_1", Zn = "_playerNoticeTitle_lq5nz_17", Kn = "_playerNoticeText_lq5nz_26", Yn = "_playerNoticeLowZIndex_lq5nz_35", ie = {
883
+ playerNotice: Wn,
884
884
  playerNoticeTitle: Zn,
885
- playerNoticeText: Kn
885
+ playerNoticeText: Kn,
886
+ playerNoticeLowZIndex: Yn
886
887
  }, At = typeof window != "undefined" ? Vn : N;
887
888
  function Ke(e, t) {
888
889
  const n = O(e);
@@ -899,29 +900,29 @@ function Ke(e, t) {
899
900
  };
900
901
  }, [t]);
901
902
  }
902
- function Yn(e) {
903
+ function Xn(e) {
903
904
  const [, t] = X(0);
904
905
  Ke(() => t((n) => n + 1), e);
905
906
  }
906
- const Xn = () => jt((e) => ({
907
+ const Gn = () => Pt((e) => ({
907
908
  delay: 0,
908
909
  startDate: null,
909
910
  setDelay: (t) => e({ delay: t }),
910
911
  setStartDate: (t) => e({ startDate: t })
911
912
  })), Ot = bt(
912
913
  null
913
- ), Gn = ({ children: e }) => {
914
+ ), Jn = ({ children: e }) => {
914
915
  const t = O(
915
916
  null
916
917
  );
917
- return t.current || (t.current = Xn()), /* @__PURE__ */ a.jsx(Ot.Provider, { value: t.current, children: e });
918
- }, $ = (e) => {
919
- const t = Pt(Ot);
918
+ return t.current || (t.current = Gn()), /* @__PURE__ */ a.jsx(Ot.Provider, { value: t.current, children: e });
919
+ }, U = (e) => {
920
+ const t = Lt(Ot);
920
921
  if (!t)
921
922
  throw new Error("usePlayerStore must be used within PlayerStoreProvider");
922
- return Lt(t, e);
923
+ return jt(t, e);
923
924
  };
924
- function Jn(e, t, n) {
925
+ function Qn(e, t, n) {
925
926
  const o = {
926
927
  days: 86400,
927
928
  hours: 3600,
@@ -931,15 +932,15 @@ function Jn(e, t, n) {
931
932
  };
932
933
  return e * (o[t] / o[n]);
933
934
  }
934
- function Qn(e) {
935
- return Jn(e, "milliseconds", "seconds");
935
+ function er(e) {
936
+ return Qn(e, "milliseconds", "seconds");
936
937
  }
937
938
  const _e = (e) => {
938
939
  if (isNaN(e) || e === 1 / 0) return "0:00";
939
940
  const t = (c) => (c < 10 ? "0" : "") + c, n = Math.floor(e / 3600), o = Math.floor(e % 3600 / 60), s = Math.floor(e % 60);
940
941
  return n === 0 ? `${o}:${t(s)}` : `${n}:${t(o)}:${t(s)}`;
941
942
  };
942
- function er(e, t) {
943
+ function tr(e, t) {
943
944
  var n, o, s, c, u, i;
944
945
  if (typeof Intl != "undefined" && Intl.DateTimeFormat)
945
946
  try {
@@ -953,25 +954,25 @@ function er(e, t) {
953
954
  second: "2-digit",
954
955
  hour12: !1
955
956
  }).formatToParts(e), g = parseInt(
956
- ((n = d.find((P) => P.type === "year")) == null ? void 0 : n.value) || "0",
957
+ ((n = d.find((L) => L.type === "year")) == null ? void 0 : n.value) || "0",
957
958
  10
958
959
  ), y = parseInt(
959
- ((o = d.find((P) => P.type === "month")) == null ? void 0 : o.value) || "0",
960
+ ((o = d.find((L) => L.type === "month")) == null ? void 0 : o.value) || "0",
960
961
  10
961
962
  ) - 1, v = parseInt(
962
- ((s = d.find((P) => P.type === "day")) == null ? void 0 : s.value) || "0",
963
+ ((s = d.find((L) => L.type === "day")) == null ? void 0 : s.value) || "0",
963
964
  10
964
965
  ), _ = parseInt(
965
- ((c = d.find((P) => P.type === "hour")) == null ? void 0 : c.value) || "0",
966
+ ((c = d.find((L) => L.type === "hour")) == null ? void 0 : c.value) || "0",
966
967
  10
967
- ), L = parseInt(
968
- ((u = d.find((P) => P.type === "minute")) == null ? void 0 : u.value) || "0",
968
+ ), j = parseInt(
969
+ ((u = d.find((L) => L.type === "minute")) == null ? void 0 : u.value) || "0",
969
970
  10
970
971
  ), S = parseInt(
971
- ((i = d.find((P) => P.type === "second")) == null ? void 0 : i.value) || "0",
972
+ ((i = d.find((L) => L.type === "second")) == null ? void 0 : i.value) || "0",
972
973
  10
973
974
  );
974
- return new Date(g, y, v, _, L, S);
975
+ return new Date(g, y, v, _, j, S);
975
976
  } catch (l) {
976
977
  return console.warn(
977
978
  `Failed to convert date to timezone ${t}, returning original date:`,
@@ -987,23 +988,23 @@ function Ht(e) {
987
988
  const t = typeof window != "undefined" && ((n = window.navigator) == null ? void 0 : n.userAgent) || "";
988
989
  return e.test(t);
989
990
  }
990
- const $t = Ht(/iPhone|iPad|iPod/i), tr = Ht(/Tizen/i);
991
- function nr() {
991
+ const $t = Ht(/iPhone|iPad|iPod/i), nr = Ht(/Tizen/i);
992
+ function rr() {
992
993
  const e = document;
993
994
  return !!(e.fullscreenElement || e.mozFullScreenElement || e.webkitFullscreenElement || e.msFullscreenElement);
994
995
  }
995
- function rr(e) {
996
+ function or(e) {
996
997
  e.requestFullscreen ? e.requestFullscreen() : e.msRequestFullscreen ? e.msRequestFullscreen() : e.webkitRequestFullScreen ? e.webkitRequestFullScreen() : e.webkitEnterFullScreen ? e.webkitEnterFullScreen() : e.mozRequestFullScreen && e.mozRequestFullScreen();
997
998
  }
998
- function or(e) {
999
+ function ir(e) {
999
1000
  e.exitFullscreen ? e.exitFullscreen() : e.msExitFullscreen ? e.msExitFullscreen() : e.webkitExitFullscreen ? e.webkitExitFullscreen() : e.mozCancelFullScreen && e.mozCancelFullScreen();
1000
1001
  }
1001
- function ir(e, t) {
1002
+ function sr(e, t) {
1002
1003
  return e.addEventListener("fullscreenchange", t), e.addEventListener("webkitfullscreenchange", t), e.addEventListener("mozfullscreenchange", t), e.addEventListener("MSFullscreenChange", t), () => {
1003
1004
  e.removeEventListener("fullscreenchange", t), e.removeEventListener("webkitfullscreenchange", t), e.removeEventListener("mozfullscreenchange", t), e.removeEventListener("MSFullscreenChange", t);
1004
1005
  };
1005
1006
  }
1006
- const sr = () => An(), ar = (e, t) => ({
1007
+ const ar = () => An(), lr = (e, t) => ({
1007
1008
  currentTime: 0,
1008
1009
  duration: 0,
1009
1010
  isEnded: !1,
@@ -1115,7 +1116,7 @@ const sr = () => An(), ar = (e, t) => ({
1115
1116
  }));
1116
1117
  },
1117
1118
  getPauseTimeDiff: () => !t().isStarted || !t().pauseTime ? 0 : parseInt(
1118
- Qn(Date.now() - t().pauseTime).toFixed(0)
1119
+ er(Date.now() - t().pauseTime).toFixed(0)
1119
1120
  ),
1120
1121
  play: () => {
1121
1122
  const n = t().techRef.current;
@@ -1162,11 +1163,11 @@ const sr = () => An(), ar = (e, t) => ({
1162
1163
  isLoading: !1
1163
1164
  });
1164
1165
  }
1165
- }), lr = (e, t) => ({
1166
+ }), cr = (e, t) => ({
1166
1167
  isIdle: !1,
1167
1168
  setIsIdle: (n) => e({ isIdle: n }),
1168
1169
  resetIdle: () => t().eventEmitter.emit("resetIdle")
1169
- }), cr = (e) => ({
1170
+ }), ur = (e) => ({
1170
1171
  idleLocks: /* @__PURE__ */ new Set(),
1171
1172
  addIdleLock: (t) => e((n) => ({
1172
1173
  idleLocks: new Set(n.idleLocks).add(t)
@@ -1175,48 +1176,48 @@ const sr = () => An(), ar = (e, t) => ({
1175
1176
  const o = new Set(n.idleLocks);
1176
1177
  return o.delete(t), { idleLocks: o };
1177
1178
  })
1178
- }), ur = (e, t) => ({
1179
+ }), dr = (e, t) => ({
1179
1180
  level: null,
1180
1181
  levels: null,
1181
1182
  setLevels: (n) => e({ levels: n }),
1182
1183
  setLevel: (n) => {
1183
1184
  n && t().eventEmitter.emit("qualityChange", { level: n }), e({ level: n });
1184
1185
  }
1185
- }), dr = (e, t) => ({
1186
+ }), fr = (e, t) => ({
1186
1187
  isFullscreen: !1,
1187
1188
  isFullscreenReady: !1,
1188
1189
  exitFullscreen: () => {
1189
- t().eventEmitter.emit("fullscreenChange", { isFullscreen: !1 }), or(document), e({ isFullscreen: !1 });
1190
+ t().eventEmitter.emit("fullscreenChange", { isFullscreen: !1 }), ir(document), e({ isFullscreen: !1 });
1190
1191
  },
1191
1192
  requestFullscreen: () => {
1192
1193
  const n = t().techRef.current, o = t().containerRef.current;
1193
1194
  if (!n || !o) return;
1194
1195
  t().eventEmitter.emit("fullscreenChange", { isFullscreen: !0 });
1195
1196
  const s = $t ? n : o;
1196
- s && rr(s), e({ isFullscreen: !0 });
1197
+ s && or(s), e({ isFullscreen: !0 });
1197
1198
  },
1198
1199
  setIsFullscreen: (n) => e({ isFullscreen: n }),
1199
1200
  setIsFullscreenReady: (n) => e({ isFullscreenReady: n })
1200
- }), fr = (e) => ({
1201
+ }), hr = (e) => ({
1201
1202
  error: null,
1202
1203
  setError: (t) => e({ error: t })
1203
- }), hr = () => ({
1204
- eventEmitter: sr()
1205
- }), mr = (e) => () => j({}, e), pr = (e, t) => jt()((...n) => j(j(j(j(j(j(j(j({}, ar(...n)), lr(...n)), cr(...n)), dr(...n)), ur(...n)), fr(...n)), hr(...n)), mr({
1204
+ }), mr = () => ({
1205
+ eventEmitter: ar()
1206
+ }), pr = (e) => () => P({}, e), vr = (e, t) => Pt()((...n) => P(P(P(P(P(P(P(P({}, lr(...n)), cr(...n)), ur(...n)), fr(...n)), dr(...n)), hr(...n)), mr(...n)), pr({
1206
1207
  techRef: e,
1207
1208
  containerRef: t
1208
- })(...n))), Bt = bt(null);
1209
- function vr({ children: e }) {
1209
+ })(...n))), Ut = bt(null);
1210
+ function yr({ children: e }) {
1210
1211
  const t = O(null), n = O(null), o = O(null);
1211
- return t.current || (t.current = pr(n, o)), /* @__PURE__ */ a.jsx(Bt.Provider, { value: t.current, children: e });
1212
+ return t.current || (t.current = vr(n, o)), /* @__PURE__ */ a.jsx(Ut.Provider, { value: t.current, children: e });
1212
1213
  }
1213
1214
  const f = (e) => {
1214
- const t = Pt(Bt);
1215
+ const t = Lt(Ut);
1215
1216
  if (!t)
1216
1217
  throw new Error("usePlayerStore must be used within PlayerStoreProvider");
1217
- return Lt(t, e);
1218
+ return jt(t, e);
1218
1219
  };
1219
- function yr(e) {
1220
+ function gr(e) {
1220
1221
  const t = e.split(`
1221
1222
  `);
1222
1223
  for (const n of t) {
@@ -1224,12 +1225,12 @@ function yr(e) {
1224
1225
  if (o.startsWith("#EXT-X-PROGRAM-DATE-TIME:")) {
1225
1226
  const s = o.replace("#EXT-X-PROGRAM-DATE-TIME:", "").trim(), c = new Date(s);
1226
1227
  if (!isNaN(c.getTime()))
1227
- return er(c, "Europe/Sarajevo");
1228
+ return tr(c, "Europe/Sarajevo");
1228
1229
  }
1229
1230
  }
1230
1231
  return null;
1231
1232
  }
1232
- function gr(e, t) {
1233
+ function wr(e, t) {
1233
1234
  const n = e.split(`
1234
1235
  `);
1235
1236
  let o = !1;
@@ -1256,19 +1257,19 @@ function gr(e, t) {
1256
1257
  }
1257
1258
  return null;
1258
1259
  }
1259
- function wr(e) {
1260
+ function Tr(e) {
1260
1261
  return e.replace("playlist.m3u8", "playlist_fmp4_dvr.m3u8");
1261
1262
  }
1262
- async function Tr(e) {
1263
+ async function _r(e) {
1263
1264
  try {
1264
- const t = wr(e);
1265
+ const t = Tr(e);
1265
1266
  console.log("Converting to DVR URL:", t);
1266
1267
  const n = await fetch(t);
1267
1268
  if (!n.ok)
1268
1269
  throw new Error(
1269
1270
  `Failed to fetch master playlist: ${n.status} ${n.statusText}`
1270
1271
  );
1271
- const o = await n.text(), s = gr(
1272
+ const o = await n.text(), s = wr(
1272
1273
  o,
1273
1274
  t
1274
1275
  );
@@ -1280,68 +1281,68 @@ async function Tr(e) {
1280
1281
  throw new Error(
1281
1282
  `Failed to fetch chunklist: ${c.status} ${c.statusText}`
1282
1283
  );
1283
- const u = await c.text(), i = yr(u);
1284
+ const u = await c.text(), i = gr(u);
1284
1285
  return i ? console.log("Successfully detected start time:", i.toISOString()) : console.log(" No start time found in chunklist"), i;
1285
1286
  } catch (t) {
1286
1287
  return console.error("Error getting start time from HLS URL:", t), null;
1287
1288
  }
1288
1289
  }
1289
- function _r(n) {
1290
+ function xr(n) {
1290
1291
  var o = n, { url: e } = o, t = ne(o, ["url"]);
1291
- const [s, c] = X(!0), u = $((d) => d.startDate), i = $((d) => d.setStartDate), l = U(async () => {
1292
- const d = await Tr(e);
1292
+ const [s, c] = X(!0), u = U((d) => d.startDate), i = U((d) => d.setStartDate), l = B(async () => {
1293
+ const d = await _r(e);
1293
1294
  d && i(d);
1294
1295
  }, [e, i]);
1295
1296
  return N(() => {
1296
1297
  (async () => {
1297
1298
  c(!0), await l(), c(!1);
1298
1299
  })();
1299
- }, [l]), Ke(l, u ? null : 5e3), s ? null : /* @__PURE__ */ a.jsx(xr, j({}, t));
1300
+ }, [l]), Ke(l, u ? null : 5e3), s ? null : /* @__PURE__ */ a.jsx(Er, P({}, t));
1300
1301
  }
1301
- function xr({
1302
+ function Er({
1302
1303
  children: e,
1303
1304
  messages: t = {}
1304
1305
  }) {
1305
1306
  var u, i, l;
1306
- const n = $((d) => d.startDate), o = f((d) => d.isStarted);
1307
- return Yn(o ? null : 5e3), n ? Date.now() < n.getTime() ? /* @__PURE__ */ a.jsx(
1307
+ const n = U((d) => d.startDate), o = f((d) => d.isStarted);
1308
+ return Xn(o ? null : 5e3), n ? Date.now() < n.getTime() ? /* @__PURE__ */ a.jsx(
1308
1309
  Cr,
1309
1310
  {
1310
1311
  startDate: n,
1311
1312
  title: (i = t == null ? void 0 : t.eventNotStarted) != null ? i : "Event has not started yet.",
1312
1313
  message: (l = t == null ? void 0 : t.eventStartingSoon) != null ? l : "Starting in few seconds..."
1313
1314
  }
1314
- ) : /* @__PURE__ */ a.jsx(a.Fragment, { children: e }) : /* @__PURE__ */ a.jsx("div", { className: se.playerNotice, children: /* @__PURE__ */ a.jsx("h3", { className: se.playerNoticeTitle, children: (u = t == null ? void 0 : t.eventNotStarted) != null ? u : "Event has not started yet." }) });
1315
+ ) : /* @__PURE__ */ a.jsx(a.Fragment, { children: e }) : /* @__PURE__ */ a.jsx("div", { className: ie.playerNotice, children: /* @__PURE__ */ a.jsx("h3", { className: ie.playerNoticeTitle, children: (u = t == null ? void 0 : t.eventNotStarted) != null ? u : "Event has not started yet." }) });
1315
1316
  }
1316
1317
  function Cr({ startDate: e, title: t, message: n }) {
1317
1318
  const o = e.getTime() - Date.now(), s = Math.floor(o / (1e3 * 60 * 60)), c = Math.floor(
1318
1319
  o % (1e3 * 60 * 60) / (1e3 * 60)
1319
1320
  );
1320
- return s || c ? /* @__PURE__ */ a.jsxs("div", { className: se.playerNotice, children: [
1321
- /* @__PURE__ */ a.jsx("h3", { className: se.playerNoticeTitle, children: t }),
1322
- /* @__PURE__ */ a.jsxs("p", { className: se.playerNoticeText, children: [
1321
+ return s || c ? /* @__PURE__ */ a.jsxs("div", { className: ie.playerNotice, children: [
1322
+ /* @__PURE__ */ a.jsx("h3", { className: ie.playerNoticeTitle, children: t }),
1323
+ /* @__PURE__ */ a.jsxs("p", { className: ie.playerNoticeText, children: [
1323
1324
  "(",
1324
1325
  s > 0 ? `${s}h ${c}m` : `${c}m`,
1325
1326
  ")"
1326
1327
  ] })
1327
- ] }) : /* @__PURE__ */ a.jsx("div", { className: se.playerNotice, children: /* @__PURE__ */ a.jsx("h3", { className: se.playerNoticeTitle, children: n }) });
1328
+ ] }) : /* @__PURE__ */ a.jsx("div", { className: ie.playerNotice, children: /* @__PURE__ */ a.jsx("h3", { className: ie.playerNoticeTitle, children: n }) });
1328
1329
  }
1329
- function Ut({ callback: e }) {
1330
+ function Bt({ callback: e }) {
1330
1331
  const t = f((n) => n.eventEmitter);
1331
1332
  return N(() => {
1332
- const n = () => e("play", void 0), o = () => e("pause", void 0), s = () => e("ended", void 0), c = () => e("seeking", void 0), u = () => e("seeked", void 0), i = (S) => e("volumeChange", S), l = (S) => e("fullscreenChange", S), d = (S) => e("qualityChange", S), g = (S) => e("loadedMetadata", S), y = () => e("loadStart", void 0), v = () => e("playing", void 0), _ = () => e("waiting", void 0), L = () => e("error", void 0);
1333
- return t.on("play", n), t.on("pause", o), t.on("ended", s), t.on("seeking", c), t.on("seeked", u), t.on("volumeChange", i), t.on("fullscreenChange", l), t.on("qualityChange", d), t.on("loadedMetadata", g), t.on("loadStart", y), t.on("playing", v), t.on("waiting", _), t.on("error", L), () => {
1334
- t.off("play", n), t.off("pause", o), t.off("ended", s), t.off("seeking", c), t.off("seeked", u), t.off("volumeChange", i), t.off("fullscreenChange", l), t.off("qualityChange", d), t.off("loadedMetadata", g), t.off("loadStart", y), t.off("playing", v), t.off("waiting", _), t.off("error", L);
1333
+ const n = () => e("play", void 0), o = () => e("pause", void 0), s = () => e("ended", void 0), c = () => e("seeking", void 0), u = () => e("seeked", void 0), i = (S) => e("volumeChange", S), l = (S) => e("fullscreenChange", S), d = (S) => e("qualityChange", S), g = (S) => e("loadedMetadata", S), y = () => e("loadStart", void 0), v = () => e("playing", void 0), _ = () => e("waiting", void 0), j = () => e("error", void 0);
1334
+ return t.on("play", n), t.on("pause", o), t.on("ended", s), t.on("seeking", c), t.on("seeked", u), t.on("volumeChange", i), t.on("fullscreenChange", l), t.on("qualityChange", d), t.on("loadedMetadata", g), t.on("loadStart", y), t.on("playing", v), t.on("waiting", _), t.on("error", j), () => {
1335
+ t.off("play", n), t.off("pause", o), t.off("ended", s), t.off("seeking", c), t.off("seeked", u), t.off("volumeChange", i), t.off("fullscreenChange", l), t.off("qualityChange", d), t.off("loadedMetadata", g), t.off("loadStart", y), t.off("playing", v), t.off("waiting", _), t.off("error", j);
1335
1336
  };
1336
1337
  }, [e, t]), null;
1337
1338
  }
1338
1339
  const zt = (e, t = 0) => parseInt(
1339
1340
  Math.max(0, (Date.now() - (e + t * 1e3)) / 1e3).toFixed(0)
1340
- ), Wt = (e, t) => Math.max(0, (Date.now() - e - t * 1e3) / 1e3), Er = (e, t) => Math.max(0, (t - e) / 1e3), Rr = (e, t = 0) => {
1341
+ ), qt = (e, t) => Math.max(0, (Date.now() - e - t * 1e3) / 1e3), Rr = (e, t) => Math.max(0, (t - e) / 1e3), Sr = (e, t = 0) => {
1341
1342
  const o = t < 0 ? 0 : t, s = ["bytes", "kb", "mb", "gb", "tb", "pb", "eb", "zb", "yb"], c = Math.floor(Math.log(e) / Math.log(1024));
1342
1343
  return `${parseFloat((e / Math.pow(1024, c)).toFixed(o))}${s[c]}`;
1343
1344
  };
1344
- function Sr({
1345
+ function br({
1345
1346
  isAuto: e,
1346
1347
  level: t,
1347
1348
  levels: n
@@ -1359,26 +1360,26 @@ function Sr({
1359
1360
  const { bitrate: u, height: i, index: l } = c;
1360
1361
  s.push({
1361
1362
  sid: `quality-level-${l}`,
1362
- label: i ? `${i}p` : Rr(u),
1363
+ label: i ? `${i}p` : Sr(u),
1363
1364
  value: l,
1364
1365
  selected: o === 1 || !e && l === t
1365
1366
  });
1366
1367
  }), s;
1367
1368
  }
1368
- function br({ callback: e }) {
1369
- const t = $((c) => c.delay), n = $((c) => c.startDate), o = n ? n.getTime() : 0, s = f((c) => c.eventEmitter);
1369
+ function Lr({ callback: e }) {
1370
+ const t = U((c) => c.delay), n = U((c) => c.startDate), o = n ? n.getTime() : 0, s = f((c) => c.eventEmitter);
1370
1371
  return N(() => {
1371
1372
  const c = () => e("timeUpdate", {
1372
- currentTime: Wt(o, t),
1373
+ currentTime: qt(o, t),
1373
1374
  duration: -1
1374
1375
  });
1375
1376
  return s.on("timeUpdate", c), () => {
1376
1377
  s.off("timeUpdate", c);
1377
1378
  };
1378
- }, [e, s]), /* @__PURE__ */ a.jsx(Ut, { callback: e });
1379
+ }, [e, s]), /* @__PURE__ */ a.jsx(Bt, { callback: e });
1379
1380
  }
1380
- function qt() {
1381
- const e = f((i) => i.exitFullscreen), t = f((i) => i.isFullscreen), n = f((i) => i.isFullscreenReady), o = f((i) => i.requestFullscreen), s = f((i) => i.setVolume), c = f((i) => i.volume), u = U(
1381
+ function Wt() {
1382
+ const e = f((i) => i.exitFullscreen), t = f((i) => i.isFullscreen), n = f((i) => i.isFullscreenReady), o = f((i) => i.requestFullscreen), s = f((i) => i.setVolume), c = f((i) => i.volume), u = B(
1382
1383
  (i) => {
1383
1384
  let l = !1;
1384
1385
  if (!(i.target instanceof HTMLInputElement || i.ctrlKey)) {
@@ -1413,7 +1414,7 @@ function qt() {
1413
1414
  }), [u]), null;
1414
1415
  }
1415
1416
  function Pr() {
1416
- const e = $((i) => i.delay), t = f((i) => i.isPlaying), n = f((i) => i.pause), o = f((i) => i.getPauseTimeDiff), s = f((i) => i.play), c = $((i) => i.setDelay), u = U(
1417
+ const e = U((i) => i.delay), t = f((i) => i.isPlaying), n = f((i) => i.pause), o = f((i) => i.getPauseTimeDiff), s = f((i) => i.play), c = U((i) => i.setDelay), u = B(
1417
1418
  (i) => {
1418
1419
  let l = !1;
1419
1420
  if (!(i.target instanceof HTMLInputElement || i.ctrlKey)) {
@@ -1441,39 +1442,39 @@ function Pr() {
1441
1442
  );
1442
1443
  return N(() => (document.addEventListener("keydown", u), () => {
1443
1444
  document.removeEventListener("keydown", u);
1444
- }), [u]), /* @__PURE__ */ a.jsx(qt, {});
1445
+ }), [u]), /* @__PURE__ */ a.jsx(Wt, {});
1445
1446
  }
1446
1447
  function Zt({ children: e }) {
1447
- return /* @__PURE__ */ a.jsx(vr, { children: e });
1448
+ return /* @__PURE__ */ a.jsx(yr, { children: e });
1448
1449
  }
1449
1450
  function jr({ children: e }) {
1450
- return /* @__PURE__ */ a.jsx(Gn, { children: /* @__PURE__ */ a.jsx(Zt, { children: e }) });
1451
+ return /* @__PURE__ */ a.jsx(Jn, { children: /* @__PURE__ */ a.jsx(Zt, { children: e }) });
1451
1452
  }
1452
- function Lr({ url: e, isLive: t, messages: n }) {
1453
- const o = O(null), s = f((T) => T.level), c = f((T) => T.levels), u = f((T) => T.setLevel), i = f((T) => T.setLevels), l = f((T) => T.techRef), d = f((T) => T.setError), g = O(0), y = O(null), v = 50, _ = 1e4, L = U(
1453
+ function kr({ url: e, isLive: t, messages: n }) {
1454
+ const o = O(null), s = f((T) => T.level), c = f((T) => T.levels), u = f((T) => T.setLevel), i = f((T) => T.setLevels), l = f((T) => T.techRef), d = f((T) => T.setError), g = O(0), y = O(null), v = 50, _ = 1e4, j = B(
1454
1455
  (T) => {
1455
1456
  if (o.current && (o.current.nextLevel = T, u(null), c)) {
1456
- const I = c.map((p) => he(j({}, p), {
1457
+ const I = c.map((p) => he(P({}, p), {
1457
1458
  selected: p.value === T
1458
1459
  }));
1459
1460
  i(I);
1460
1461
  }
1461
1462
  },
1462
1463
  [c, u, i, o]
1463
- ), S = U(() => {
1464
+ ), S = B(() => {
1464
1465
  o.current && (console.log("[Player][HLS] MEDIA_ATTACHED"), o.current.loadSource(e));
1465
- }, [e]), P = U(() => {
1466
+ }, [e]), L = B(() => {
1466
1467
  if (!o.current) return;
1467
1468
  console.log("[Player][HLS] MANIFEST_LOADED"), d(null), y.current && (clearTimeout(y.current), y.current = null), g.current = 0;
1468
1469
  const T = o.current.levels, I = o.current.currentLevel, p = o.current.autoLevelEnabled;
1469
1470
  i(
1470
- Sr({
1471
- levels: T.map((B, J) => {
1472
- const { bitrate: q, height: V, width: D } = B;
1471
+ br({
1472
+ levels: T.map((H, G) => {
1473
+ const { bitrate: W, height: V, width: D } = H;
1473
1474
  return {
1474
- bitrate: q,
1475
+ bitrate: W,
1475
1476
  height: V,
1476
- index: J,
1477
+ index: G,
1477
1478
  width: D
1478
1479
  };
1479
1480
  }),
@@ -1481,10 +1482,10 @@ function Lr({ url: e, isLive: t, messages: n }) {
1481
1482
  isAuto: p
1482
1483
  })
1483
1484
  );
1484
- }, [d, i]), M = U(
1485
+ }, [d, i]), M = B(
1485
1486
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
1486
1487
  (T, I) => {
1487
- var p;
1488
+ var p, H;
1488
1489
  if (console.error("[Player][HLS] ERROR", T, I), !!o.current && I.fatal)
1489
1490
  switch (I.type) {
1490
1491
  case re.ErrorTypes.NETWORK_ERROR:
@@ -1492,14 +1493,18 @@ function Lr({ url: e, isLive: t, messages: n }) {
1492
1493
  if (o.current)
1493
1494
  try {
1494
1495
  console.log("[Player][HLS] Retrying stream..."), o.current.loadSource(e);
1495
- } catch (B) {
1496
- console.error("[Player][HLS] Retry failed:", B);
1496
+ } catch (G) {
1497
+ console.error("[Player][HLS] Retry failed:", G);
1497
1498
  }
1498
1499
  }, _)), d({
1499
1500
  message: (p = n == null ? void 0 : n.eventFinished) != null ? p : "Live event will be back shortly.",
1500
- code: "MANIFEST_LOAD_ERROR",
1501
+ code: "LIVE_MANIFEST_LOAD_ERROR",
1501
1502
  tech: "hls"
1502
- })) : o.current.startLoad();
1503
+ })) : (d({
1504
+ message: (H = n == null ? void 0 : n.unableToPlay) != null ? H : "Unable to play the video. Please try again later.",
1505
+ code: "NETWORK_ERROR",
1506
+ tech: "hls"
1507
+ }), o.current.startLoad());
1503
1508
  break;
1504
1509
  case re.ErrorTypes.MEDIA_ERROR:
1505
1510
  o.current.recoverMediaError();
@@ -1507,35 +1512,35 @@ function Lr({ url: e, isLive: t, messages: n }) {
1507
1512
  }
1508
1513
  },
1509
1514
  [t, e, d]
1510
- ), R = U(() => {
1515
+ ), R = B(() => {
1511
1516
  if (!l.current) return;
1512
1517
  let T = {
1513
1518
  startLevel: -1,
1514
1519
  maxBufferSize: 30 * 1024 * 1024
1515
1520
  // 30MB
1516
1521
  };
1517
- tr ? (T.backBufferLength = -1, T.enableWorker = !1) : t ? T.backBufferLength = 10 : T.backBufferLength = 60;
1522
+ nr ? (T.backBufferLength = -1, T.enableWorker = !1) : t ? T.backBufferLength = 10 : T.backBufferLength = 60;
1518
1523
  try {
1519
- console.log("[Player][HLS] URL", e), console.log("[Player][HLS] Config", JSON.stringify(T)), console.log("[Player][HLS] Version", re.version), o.current = new re(T), o.current.attachMedia(l.current), o.current.on(re.Events.MEDIA_ATTACHED, S), o.current.on(re.Events.MANIFEST_LOADED, P), o.current.on(re.Events.ERROR, M);
1524
+ console.log("[Player][HLS] URL", e), console.log("[Player][HLS] Config", JSON.stringify(T)), console.log("[Player][HLS] Version", re.version), o.current = new re(T), o.current.attachMedia(l.current), o.current.on(re.Events.MEDIA_ATTACHED, S), o.current.on(re.Events.MANIFEST_LOADED, L), o.current.on(re.Events.ERROR, M);
1520
1525
  } catch (I) {
1521
1526
  throw new Error(`Error initializing Hls: ${I}`);
1522
1527
  }
1523
1528
  }, [
1524
- P,
1529
+ L,
1525
1530
  S,
1526
1531
  M,
1527
1532
  t,
1528
1533
  l,
1529
1534
  e
1530
- ]), k = U(() => {
1531
- o.current && (o.current.off(re.Events.MEDIA_ATTACHED, S), o.current.off(re.Events.MANIFEST_LOADED, P), o.current.off(re.Events.ERROR, M), o.current.destroy(), o.current = null), y.current && (clearTimeout(y.current), y.current = null), g.current = 0;
1532
- }, [P, S, M]);
1535
+ ]), k = B(() => {
1536
+ o.current && (o.current.off(re.Events.MEDIA_ATTACHED, S), o.current.off(re.Events.MANIFEST_LOADED, L), o.current.off(re.Events.ERROR, M), o.current.destroy(), o.current = null), y.current && (clearTimeout(y.current), y.current = null), g.current = 0;
1537
+ }, [L, S, M]);
1533
1538
  return N(() => {
1534
- s !== null && L(s);
1535
- }, [s, L]), N(() => (re.isSupported() && R(), k), [k, R]), null;
1539
+ s !== null && j(s);
1540
+ }, [s, j]), N(() => (re.isSupported() && R(), k), [k, R]), null;
1536
1541
  }
1537
- const kr = "_playerVideo_wc0sm_1", Ir = {
1538
- playerVideo: kr
1542
+ const Ir = "_playerVideo_wc0sm_1", Dr = {
1543
+ playerVideo: Ir
1539
1544
  };
1540
1545
  function Kt({
1541
1546
  url: e,
@@ -1543,7 +1548,9 @@ function Kt({
1543
1548
  isMuted: n = !1,
1544
1549
  messages: o = {}
1545
1550
  }) {
1546
- const s = f((p) => p.handleDurationChange), c = f((p) => p.handleEnd), u = f((p) => p.handleLoadedMetadata), i = f((p) => p.handleLoadStart), l = f((p) => p.handlePause), d = f((p) => p.handlePlay), g = f((p) => p.handlePlaying), y = f((p) => p.handleSeeked), v = f((p) => p.handleSeeking), _ = f((p) => p.handleTimeUpdate), L = f((p) => p.handleWaiting), S = f((p) => p.handleVolumeChange), P = f((p) => p.handleError), M = f((p) => p.techRef), R = O(null), k = () => t ? {} : {
1551
+ const s = f((p) => p.handleDurationChange), c = f((p) => p.handleEnd), u = f((p) => p.handleLoadedMetadata), i = f((p) => p.handleLoadStart), l = f((p) => p.handlePause), d = f((p) => p.handlePlay), g = f((p) => p.handlePlaying), y = f((p) => p.handleSeeked), v = f((p) => p.handleSeeking), _ = f((p) => p.handleTimeUpdate), j = f((p) => p.handleWaiting), S = f((p) => p.handleVolumeChange), L = f((p) => p.handleError), M = f((p) => p.techRef), R = O(null), k = () => t ? {
1552
+ onTimeUpdate: T
1553
+ } : {
1547
1554
  onDurationChange: s,
1548
1555
  onSeeked: y,
1549
1556
  onSeeking: v,
@@ -1552,12 +1559,12 @@ function Kt({
1552
1559
  (!R.current || Date.now() - R.current >= 1e3) && (_(), R.current = Date.now());
1553
1560
  }, I = k();
1554
1561
  return /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
1555
- /* @__PURE__ */ a.jsx(Lr, { isLive: t, url: e, messages: o }),
1562
+ /* @__PURE__ */ a.jsx(kr, { isLive: t, url: e, messages: o }),
1556
1563
  /* @__PURE__ */ a.jsx(
1557
1564
  "video",
1558
- j({
1565
+ P({
1559
1566
  ref: M,
1560
- className: Ir.playerVideo,
1567
+ className: Dr.playerVideo,
1561
1568
  playsInline: !0,
1562
1569
  autoPlay: !0,
1563
1570
  controls: !1,
@@ -1565,21 +1572,21 @@ function Kt({
1565
1572
  preload: "auto",
1566
1573
  crossOrigin: "anonymous",
1567
1574
  onEnded: c,
1568
- onError: P,
1575
+ onError: L,
1569
1576
  onLoadedMetadata: u,
1570
1577
  onLoadStart: i,
1571
1578
  onPause: l,
1572
1579
  onPlay: d,
1573
1580
  onPlaying: g,
1574
- onWaiting: L,
1581
+ onWaiting: j,
1575
1582
  onVolumeChange: S,
1576
1583
  tabIndex: -1
1577
1584
  }, I)
1578
1585
  )
1579
1586
  ] });
1580
1587
  }
1581
- function Dr({ url: e, messages: t = {} }) {
1582
- const [n, o] = X(null), s = $((u) => u.delay), c = U(async () => {
1588
+ function Fr({ url: e, messages: t = {} }) {
1589
+ const [n, o] = X(null), s = U((u) => u.delay), c = B(async () => {
1583
1590
  o(
1584
1591
  s ? e.replace("-live", "-catchup").replace("playlist.m3u8", `playlist_fmp4_dvr_timeshift-${s}.m3u8`) : e
1585
1592
  );
@@ -1588,7 +1595,7 @@ function Dr({ url: e, messages: t = {} }) {
1588
1595
  c();
1589
1596
  }, [c]), n ? /* @__PURE__ */ a.jsx(Kt, { url: n, isLive: !0, messages: t }) : null;
1590
1597
  }
1591
- function Fr(e, {
1598
+ function Mr(e, {
1592
1599
  defaultValue: t = !1,
1593
1600
  initializeWithValue: n = !0
1594
1601
  } = {}) {
@@ -1605,13 +1612,13 @@ function Fr(e, {
1605
1612
  };
1606
1613
  }, [e]), s;
1607
1614
  }
1608
- const Mr = "_playbackButton_lgsgw_1", Nr = "_seekIndicator_lgsgw_23", Vr = "_seekIndicatorLeft_lgsgw_49", Ar = "_seekIndicatorRight_lgsgw_53", Or = "_seekIndicatorVisible_lgsgw_57", me = {
1609
- playbackButton: Mr,
1610
- seekIndicator: Nr,
1611
- seekIndicatorLeft: Vr,
1612
- seekIndicatorRight: Ar,
1613
- seekIndicatorVisible: Or
1614
- }, Hr = 10;
1615
+ const Nr = "_playbackButton_lgsgw_1", Vr = "_seekIndicator_lgsgw_23", Ar = "_seekIndicatorLeft_lgsgw_49", Or = "_seekIndicatorRight_lgsgw_53", Hr = "_seekIndicatorVisible_lgsgw_57", me = {
1616
+ playbackButton: Nr,
1617
+ seekIndicator: Vr,
1618
+ seekIndicatorLeft: Ar,
1619
+ seekIndicatorRight: Or,
1620
+ seekIndicatorVisible: Hr
1621
+ }, $r = 10;
1615
1622
  function Yt(i) {
1616
1623
  var l = i, {
1617
1624
  className: e,
@@ -1628,9 +1635,9 @@ function Yt(i) {
1628
1635
  "maxForwardTime",
1629
1636
  "maxBackwardTime"
1630
1637
  ]);
1631
- return Fr("(min-width: 1024px)") ? /* @__PURE__ */ a.jsx($r, j({ className: e, onClick: t }, u)) : /* @__PURE__ */ a.jsx(
1638
+ return Mr("(min-width: 1024px)") ? /* @__PURE__ */ a.jsx(Ur, P({ className: e, onClick: t }, u)) : /* @__PURE__ */ a.jsx(
1632
1639
  Br,
1633
- j({
1640
+ P({
1634
1641
  className: e,
1635
1642
  maxForwardTime: s,
1636
1643
  maxBackwardTime: c,
@@ -1639,7 +1646,7 @@ function Yt(i) {
1639
1646
  }, u)
1640
1647
  );
1641
1648
  }
1642
- function $r(o) {
1649
+ function Ur(o) {
1643
1650
  var s = o, { className: e, onClick: t } = s, n = ne(s, ["className", "onClick"]);
1644
1651
  const c = O(null), u = f((_) => _.exitFullscreen), i = f((_) => _.isFullscreen), l = f((_) => _.requestFullscreen), d = (_) => {
1645
1652
  v() ? (y(), i ? u() : l()) : g(_);
@@ -1654,7 +1661,7 @@ function $r(o) {
1654
1661
  y();
1655
1662
  }, []), /* @__PURE__ */ a.jsx(
1656
1663
  "button",
1657
- j({
1664
+ P({
1658
1665
  onClick: d,
1659
1666
  className: [me.playbackButton, e].filter(Boolean).join(" "),
1660
1667
  "aria-label": "Player gestures"
@@ -1679,49 +1686,49 @@ function Br(u) {
1679
1686
  single: null,
1680
1687
  indicator: null,
1681
1688
  accumulate: null
1682
- }), g = O(null), y = O(0), v = O(null), [_, L] = X({ visible: !1, direction: null, time: 0 }), S = f((p) => p.isIdle), P = f((p) => p.setIsIdle), M = f((p) => p.resetIdle), R = (p, B) => p < B / 2 ? "backward" : "forward", k = (p) => {
1689
+ }), g = O(null), y = O(0), v = O(null), [_, j] = X({ visible: !1, direction: null, time: 0 }), S = f((p) => p.isIdle), L = f((p) => p.setIsIdle), M = f((p) => p.resetIdle), R = (p, H) => p < H / 2 ? "backward" : "forward", k = (p) => {
1683
1690
  if (!g.current) return;
1684
- const B = p.changedTouches[0];
1685
- if (!B) return;
1686
- const J = Date.now(), q = g.current.getBoundingClientRect(), V = B.clientX - q.left, D = B.clientY - q.top;
1687
- if (V < 0 || V > q.width || D < 0 || D > q.height)
1691
+ const H = p.changedTouches[0];
1692
+ if (!H) return;
1693
+ const G = Date.now(), W = g.current.getBoundingClientRect(), V = H.clientX - W.left, D = H.clientY - W.top;
1694
+ if (V < 0 || V > W.width || D < 0 || D > W.height)
1688
1695
  return;
1689
- const Q = l.current, Z = Q ? J - Q.time : 1 / 0, z = R(V, q.width), oe = v.current !== null && v.current === z && Q !== null && Z < 700 && Math.abs(V - Q.x) < 100;
1696
+ const Q = l.current, Z = Q ? G - Q.time : 1 / 0, z = R(V, W.width), oe = v.current !== null && v.current === z && Q !== null && Z < 700 && Math.abs(V - Q.x) < 100;
1690
1697
  if (Q !== null && v.current === null && Z < 300 && Math.abs(V - Q.x) < 50 || oe) {
1691
1698
  p.preventDefault(), p.stopPropagation(), d.current.single && (window.clearTimeout(d.current.single), d.current.single = null), M(), (v.current === null || v.current !== z) && (y.current = 0, v.current = z);
1692
1699
  const te = z === "backward" ? n : t;
1693
1700
  y.current = Math.min(
1694
- y.current + Hr,
1701
+ y.current + $r,
1695
1702
  te != null ? te : 1 / 0
1696
1703
  ), T(z, y.current), d.current.accumulate && window.clearTimeout(d.current.accumulate), d.current.accumulate = window.setTimeout(() => {
1697
- const W = y.current;
1698
- W > 0 && (v.current === "backward" ? s == null || s(W) : o == null || o(W), y.current = 0, v.current = null, l.current = null, I(), M()), d.current.accumulate = null;
1699
- }, 500), l.current = { time: J, x: V };
1704
+ const q = y.current;
1705
+ q > 0 && (v.current === "backward" ? s == null || s(q) : o == null || o(q), M()), y.current = 0, v.current = null, l.current = null, I(), d.current.accumulate = null;
1706
+ }, 500), l.current = { time: G, x: V };
1700
1707
  } else {
1701
- l.current = { time: J, x: V }, d.current.single && window.clearTimeout(d.current.single);
1708
+ l.current = { time: G, x: V }, d.current.single && window.clearTimeout(d.current.single);
1702
1709
  const te = v.current !== null ? 700 : 350;
1703
1710
  d.current.single = window.setTimeout(() => {
1704
1711
  if (v.current === null) {
1705
1712
  d.current.single = null;
1706
- const W = S;
1707
- P(!W), W && M();
1713
+ const q = S;
1714
+ L(!q), q && M();
1708
1715
  }
1709
1716
  l.current = null;
1710
1717
  }, te);
1711
1718
  }
1712
- }, T = (p, B) => {
1713
- L({ visible: !0, direction: p, time: B }), d.current.indicator && window.clearTimeout(d.current.indicator), d.current.indicator = window.setTimeout(() => {
1719
+ }, T = (p, H) => {
1720
+ H !== 0 && (j({ visible: !0, direction: p, time: H }), d.current.indicator && window.clearTimeout(d.current.indicator), d.current.indicator = window.setTimeout(() => {
1714
1721
  I();
1715
- }, 700);
1722
+ }, 700));
1716
1723
  }, I = () => {
1717
- L({ visible: !1, direction: null, time: 0 }), d.current.indicator && (window.clearTimeout(d.current.indicator), d.current.indicator = null);
1724
+ j({ visible: !1, direction: null, time: 0 }), d.current.indicator && (window.clearTimeout(d.current.indicator), d.current.indicator = null);
1718
1725
  };
1719
1726
  return N(() => () => {
1720
1727
  d.current.single && window.clearTimeout(d.current.single), d.current.indicator && window.clearTimeout(d.current.indicator), d.current.accumulate && window.clearTimeout(d.current.accumulate);
1721
1728
  }, []), /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
1722
1729
  /* @__PURE__ */ a.jsx(
1723
1730
  "button",
1724
- j({
1731
+ P({
1725
1732
  ref: g,
1726
1733
  onTouchEnd: k,
1727
1734
  className: [me.playbackButton, e].filter(Boolean).join(" "),
@@ -1740,8 +1747,8 @@ function Br(u) {
1740
1747
  )
1741
1748
  ] });
1742
1749
  }
1743
- function Ur() {
1744
- const e = f((l) => l.isPlaying), t = f((l) => l.pause), n = f((l) => l.getPauseTimeDiff), o = f((l) => l.play), s = $((l) => l.delay), c = $((l) => l.setDelay), u = $((l) => l.startDate), i = u ? u.getTime() : 0;
1750
+ function zr() {
1751
+ const e = f((l) => l.isPlaying), t = f((l) => l.pause), n = f((l) => l.getPauseTimeDiff), o = f((l) => l.play), s = U((l) => l.delay), c = U((l) => l.setDelay), u = U((l) => l.startDate), i = u ? u.getTime() : 0;
1745
1752
  return /* @__PURE__ */ a.jsx(
1746
1753
  Yt,
1747
1754
  {
@@ -1766,28 +1773,28 @@ function Ur() {
1766
1773
  }
1767
1774
  );
1768
1775
  }
1769
- const zr = "_playerButton_izwqq_1", Wr = "_playerButtonCircle_izwqq_42", Tt = {
1770
- playerButton: zr,
1776
+ const qr = "_playerButton_izwqq_1", Wr = "_playerButtonCircle_izwqq_42", Tt = {
1777
+ playerButton: qr,
1771
1778
  playerButtonCircle: Wr
1772
1779
  }, le = Me(
1773
1780
  (s, o) => {
1774
1781
  var c = s, { shape: e = "circle", className: t } = c, n = ne(c, ["shape", "className"]);
1775
1782
  const u = e === "circle" ? Tt.playerButtonCircle : "", i = [Tt.playerButton, u, t].filter(Boolean).join(" ");
1776
- return /* @__PURE__ */ a.jsx("button", j({ ref: o, className: i }, n));
1783
+ return /* @__PURE__ */ a.jsx("button", P({ ref: o, className: i }, n));
1777
1784
  }
1778
1785
  );
1779
1786
  le.displayName = "PlayerButton";
1780
- const qr = "_liveIndicator_1jczn_1", Zr = "_liveIndicatorHasDelay_1jczn_9", Kr = "_liveIndicatorNoDelay_1jczn_13", ke = {
1781
- liveIndicator: qr,
1782
- liveIndicatorHasDelay: Zr,
1783
- liveIndicatorNoDelay: Kr
1787
+ const Zr = "_liveIndicator_1jczn_1", Kr = "_liveIndicatorHasDelay_1jczn_9", Yr = "_liveIndicatorNoDelay_1jczn_13", ke = {
1788
+ liveIndicator: Zr,
1789
+ liveIndicatorHasDelay: Kr,
1790
+ liveIndicatorNoDelay: Yr
1784
1791
  };
1785
- function Yr(n) {
1792
+ function Xr(n) {
1786
1793
  var o = n, { message: e } = o, t = ne(o, ["message"]);
1787
- const s = $((l) => l.delay), c = $((l) => l.setDelay), u = () => {
1794
+ const s = U((l) => l.delay), c = U((l) => l.setDelay), u = () => {
1788
1795
  s && c(0);
1789
1796
  }, i = s ? `${ke.liveIndicator} ${ke.liveIndicatorHasDelay}` : `${ke.liveIndicator} ${ke.liveIndicatorNoDelay}`;
1790
- return /* @__PURE__ */ a.jsxs(le, he(j({ onClick: u, shape: "square" }, t), { children: [
1797
+ return /* @__PURE__ */ a.jsxs(le, he(P({ onClick: u, shape: "square" }, t), { children: [
1791
1798
  /* @__PURE__ */ a.jsx("div", { className: i }),
1792
1799
  e || "Live"
1793
1800
  ] }));
@@ -1814,8 +1821,8 @@ function Gt() {
1814
1821
  }
1815
1822
  );
1816
1823
  }
1817
- function Xr() {
1818
- const e = f((i) => i.isPlaying), t = f((i) => i.pause), n = f((i) => i.getPauseTimeDiff), o = f((i) => i.play), s = $((i) => i.delay), c = $((i) => i.setDelay), u = () => {
1824
+ function Gr() {
1825
+ const e = f((i) => i.isPlaying), t = f((i) => i.pause), n = f((i) => i.getPauseTimeDiff), o = f((i) => i.play), s = U((i) => i.delay), c = U((i) => i.setDelay), u = () => {
1819
1826
  if (e)
1820
1827
  t();
1821
1828
  else {
@@ -1825,22 +1832,22 @@ function Xr() {
1825
1832
  };
1826
1833
  return /* @__PURE__ */ a.jsx(le, { onClick: u, children: e ? /* @__PURE__ */ a.jsx(Xt, {}) : /* @__PURE__ */ a.jsx(Gt, {}) });
1827
1834
  }
1828
- const Gr = "_progressSlider_hwzgf_1", Jr = "_tipContainer_hwzgf_7", Qr = "_tipContainerVisible_hwzgf_17", eo = "_tipContainerHidden_hwzgf_22", to = "_tipContent_hwzgf_27", ie = {
1829
- progressSlider: Gr,
1830
- tipContainer: Jr,
1831
- tipContainerVisible: Qr,
1832
- tipContainerHidden: eo,
1833
- tipContent: to
1834
- }, no = "_sliderRoot_aeak6_1", ro = "_sliderTrack_aeak6_18", oo = "_sliderRange_aeak6_28", io = "_sliderThumb_aeak6_37", Ie = {
1835
- sliderRoot: no,
1836
- sliderTrack: ro,
1837
- sliderRange: oo,
1838
- sliderThumb: io
1835
+ const Jr = "_progressSlider_hwzgf_1", Qr = "_tipContainer_hwzgf_7", eo = "_tipContainerVisible_hwzgf_17", to = "_tipContainerHidden_hwzgf_22", no = "_tipContent_hwzgf_27", se = {
1836
+ progressSlider: Jr,
1837
+ tipContainer: Qr,
1838
+ tipContainerVisible: eo,
1839
+ tipContainerHidden: to,
1840
+ tipContent: no
1841
+ }, ro = "_sliderRoot_aeak6_1", oo = "_sliderTrack_aeak6_18", io = "_sliderRange_aeak6_28", so = "_sliderThumb_aeak6_37", Ie = {
1842
+ sliderRoot: ro,
1843
+ sliderTrack: oo,
1844
+ sliderRange: io,
1845
+ sliderThumb: so
1839
1846
  }, Ne = Me((c, s) => {
1840
1847
  var u = c, { max: e = 100, min: t = 0, className: n } = u, o = ne(u, ["max", "min", "className"]);
1841
1848
  return /* @__PURE__ */ a.jsxs(
1842
- Pe.Root,
1843
- he(j({
1849
+ Le.Root,
1850
+ he(P({
1844
1851
  ref: s,
1845
1852
  min: t,
1846
1853
  max: e,
@@ -1853,8 +1860,8 @@ const Gr = "_progressSlider_hwzgf_1", Jr = "_tipContainer_hwzgf_7", Qr = "_tipCo
1853
1860
  )
1854
1861
  }, o), {
1855
1862
  children: [
1856
- /* @__PURE__ */ a.jsx(Pe.Track, { className: Ie.sliderTrack, children: /* @__PURE__ */ a.jsx(Pe.Range, { className: Ie.sliderRange }) }),
1857
- /* @__PURE__ */ a.jsx(Pe.Thumb, { className: Ie.sliderThumb })
1863
+ /* @__PURE__ */ a.jsx(Le.Track, { className: Ie.sliderTrack, children: /* @__PURE__ */ a.jsx(Le.Range, { className: Ie.sliderRange }) }),
1864
+ /* @__PURE__ */ a.jsx(Le.Thumb, { className: Ie.sliderThumb })
1858
1865
  ]
1859
1866
  })
1860
1867
  );
@@ -1872,46 +1879,46 @@ function Fe(e) {
1872
1879
  } : t;
1873
1880
  }
1874
1881
  const _t = "vod-player-progress-bar";
1875
- function so() {
1876
- const e = O(null), t = O(null), [n, o] = X(0), [s, c] = X(0), [u, i] = X(!1), [l, d] = X(-1), [g, y] = X(-1), v = $((D) => D.delay), _ = $((D) => D.startDate), L = _ ? _.getTime() : 0, S = (/* @__PURE__ */ new Date()).getTime(), P = $((D) => D.setDelay), M = f((D) => D.isPlaying), R = f((D) => D.addIdleLock), k = f((D) => D.removeIdleLock), T = U(() => {
1877
- o(Wt(L, v)), c(Er(L, S));
1878
- }, [v, S, L]), I = parseFloat(
1882
+ function ao() {
1883
+ const e = O(null), t = O(null), [n, o] = X(0), [s, c] = X(0), [u, i] = X(!1), [l, d] = X(-1), [g, y] = X(-1), v = U((D) => D.delay), _ = U((D) => D.startDate), j = _ ? _.getTime() : 0, S = (/* @__PURE__ */ new Date()).getTime(), L = U((D) => D.setDelay), M = f((D) => D.isPlaying), R = f((D) => D.addIdleLock), k = f((D) => D.removeIdleLock), T = B(() => {
1884
+ o(qt(j, v)), c(Rr(j, S));
1885
+ }, [v, S, j]), I = parseFloat(
1879
1886
  (s ? (g !== -1 ? g : n) / s * 100 : 0).toFixed(1)
1880
1887
  ), p = (D) => {
1881
1888
  y(s * (D[0] / 100)), R(_t);
1882
- }, B = () => {
1889
+ }, H = () => {
1883
1890
  if (g !== -1) {
1884
- const D = zt(L, g);
1885
- P(D), y(-1), k(_t);
1891
+ const D = zt(j, g);
1892
+ L(D), y(-1), k(_t);
1886
1893
  }
1887
- }, J = () => i(!0), q = () => i(!1), V = U(
1894
+ }, G = () => i(!0), W = () => i(!1), V = B(
1888
1895
  (D) => {
1889
1896
  const Q = e.current, Z = t.current;
1890
1897
  if (Q && Z) {
1891
1898
  const z = Fe(Q), oe = Fe(Z), ue = (D.pageX || D.clientX) - z.left, te = ue / z.width;
1892
1899
  if (te < 0) return;
1893
- let W = ue - oe.width / 2;
1894
- W < 0 && (W = 0), W > z.width - oe.width && (W = -1), Z.style.left = W > -1 ? `${W}px` : "auto", Z.style.right = W > -1 ? "auto" : "0px";
1900
+ let q = ue - oe.width / 2;
1901
+ q < 0 && (q = 0), q > z.width - oe.width && (q = -1), Z.style.left = q > -1 ? `${q}px` : "auto", Z.style.right = q > -1 ? "auto" : "0px";
1895
1902
  const ve = s - te * s;
1896
1903
  d(ve > 0 ? ve : 0);
1897
1904
  }
1898
- J();
1905
+ G();
1899
1906
  },
1900
1907
  [s]
1901
1908
  );
1902
1909
  return Ke(() => T(), M ? 1e3 : null), N(() => {
1903
1910
  T();
1904
- }, [T]), /* @__PURE__ */ a.jsxs("div", { className: ie.progressSlider, children: [
1911
+ }, [T]), /* @__PURE__ */ a.jsxs("div", { className: se.progressSlider, children: [
1905
1912
  /* @__PURE__ */ a.jsx(
1906
1913
  Ne,
1907
1914
  {
1908
1915
  ref: e,
1909
1916
  value: [I],
1910
- onPointerLeave: q,
1911
- onPointerDown: q,
1917
+ onPointerLeave: W,
1918
+ onPointerDown: W,
1912
1919
  onPointerMove: V,
1913
1920
  onValueChange: p,
1914
- onValueCommit: B,
1921
+ onValueCommit: H,
1915
1922
  step: 0.1
1916
1923
  }
1917
1924
  ),
@@ -1919,13 +1926,13 @@ function so() {
1919
1926
  "div",
1920
1927
  {
1921
1928
  ref: t,
1922
- className: `${ie.tipContainer} ${u ? ie.tipContainerVisible : ie.tipContainerHidden}`,
1923
- children: /* @__PURE__ */ a.jsx("p", { className: ie.tipContent, children: `-${_e(l)}` })
1929
+ className: `${se.tipContainer} ${u ? se.tipContainerVisible : se.tipContainerHidden}`,
1930
+ children: /* @__PURE__ */ a.jsx("p", { className: se.tipContent, children: `-${_e(l)}` })
1924
1931
  }
1925
1932
  )
1926
1933
  ] });
1927
1934
  }
1928
- function ao() {
1935
+ function lo() {
1929
1936
  return /* @__PURE__ */ a.jsx(
1930
1937
  "svg",
1931
1938
  {
@@ -1936,24 +1943,32 @@ function ao() {
1936
1943
  }
1937
1944
  );
1938
1945
  }
1939
- function lo() {
1940
- const e = $((s) => s.startDate), t = $((s) => s.setDelay), n = e ? e.getTime() : 0, o = () => t(zt(n));
1941
- return /* @__PURE__ */ a.jsx(le, { onClick: o, children: /* @__PURE__ */ a.jsx(ao, {}) });
1946
+ function co() {
1947
+ const e = U((s) => s.startDate), t = U((s) => s.setDelay), n = e ? e.getTime() : 0, o = () => t(zt(n));
1948
+ return /* @__PURE__ */ a.jsx(le, { onClick: o, children: /* @__PURE__ */ a.jsx(lo, {}) });
1942
1949
  }
1943
1950
  function Jt() {
1944
- const e = f((t) => t.error);
1945
- return e ? /* @__PURE__ */ a.jsx("div", { className: se.playerNotice, children: /* @__PURE__ */ a.jsx("h3", { className: se.playerNoticeTitle, children: e.message }) }) : null;
1946
- }
1947
- const co = "_playerContainer_1fn8l_1", uo = "_controlsBottom_1fn8l_29", fo = "_controlsContainer_1fn8l_45", ho = "_controlsRow_1fn8l_61", mo = "_controlsSection_1fn8l_68", po = "_controlsSectionStart_1fn8l_78", vo = "_controlsSectionEnd_1fn8l_82", K = {
1948
- playerContainer: co,
1949
- controlsBottom: uo,
1950
- controlsContainer: fo,
1951
- controlsRow: ho,
1952
- controlsSection: mo,
1953
- controlsSectionStart: po,
1954
- controlsSectionEnd: vo
1951
+ const e = f((n) => n.error);
1952
+ if (!e) return null;
1953
+ const t = e.code === "LIVE_MANIFEST_LOAD_ERROR";
1954
+ return /* @__PURE__ */ a.jsx(
1955
+ "div",
1956
+ {
1957
+ className: `${ie.playerNotice} ${t ? ie.playerNoticeLowZIndex : ""}`,
1958
+ children: /* @__PURE__ */ a.jsx("h3", { className: ie.playerNoticeTitle, children: e.message })
1959
+ }
1960
+ );
1961
+ }
1962
+ const uo = "_playerContainer_1fn8l_1", fo = "_controlsBottom_1fn8l_29", ho = "_controlsContainer_1fn8l_45", mo = "_controlsRow_1fn8l_61", po = "_controlsSection_1fn8l_68", vo = "_controlsSectionStart_1fn8l_78", yo = "_controlsSectionEnd_1fn8l_82", K = {
1963
+ playerContainer: uo,
1964
+ controlsBottom: fo,
1965
+ controlsContainer: ho,
1966
+ controlsRow: mo,
1967
+ controlsSection: po,
1968
+ controlsSectionStart: vo,
1969
+ controlsSectionEnd: yo
1955
1970
  };
1956
- function yo() {
1971
+ function go() {
1957
1972
  return /* @__PURE__ */ a.jsx(
1958
1973
  "svg",
1959
1974
  {
@@ -1964,7 +1979,7 @@ function yo() {
1964
1979
  }
1965
1980
  );
1966
1981
  }
1967
- function go() {
1982
+ function wo() {
1968
1983
  return /* @__PURE__ */ a.jsx(
1969
1984
  "svg",
1970
1985
  {
@@ -1976,9 +1991,9 @@ function go() {
1976
1991
  );
1977
1992
  }
1978
1993
  function Qt() {
1979
- const e = f((d) => d.containerRef), t = f((d) => d.exitFullscreen), n = f((d) => d.isFullscreen), o = f((d) => d.requestFullscreen), s = f((d) => d.setIsFullscreen), c = f((d) => d.setIsFullscreenReady), u = f((d) => d.techRef), i = U(
1994
+ const e = f((d) => d.containerRef), t = f((d) => d.exitFullscreen), n = f((d) => d.isFullscreen), o = f((d) => d.requestFullscreen), s = f((d) => d.setIsFullscreen), c = f((d) => d.setIsFullscreenReady), u = f((d) => d.techRef), i = B(
1980
1995
  (d) => {
1981
- d.stopPropagation(), s(nr());
1996
+ d.stopPropagation(), s(rr());
1982
1997
  },
1983
1998
  [s]
1984
1999
  ), l = () => {
@@ -1987,21 +2002,21 @@ function Qt() {
1987
2002
  return N(() => {
1988
2003
  const d = $t ? u.current : e.current;
1989
2004
  if (d)
1990
- return ir(d, i);
2005
+ return sr(d, i);
1991
2006
  }, [e, i, u]), N(() => {
1992
2007
  c(!0);
1993
- }, [c]), /* @__PURE__ */ a.jsx(le, { onClick: l, children: n ? /* @__PURE__ */ a.jsx(go, {}) : /* @__PURE__ */ a.jsx(yo, {}) });
2008
+ }, [c]), /* @__PURE__ */ a.jsx(le, { onClick: l, children: n ? /* @__PURE__ */ a.jsx(wo, {}) : /* @__PURE__ */ a.jsx(go, {}) });
1994
2009
  }
1995
- const wo = "_idleCheckContainer_iz9tu_1", To = "_idleCheckContainerIdle_iz9tu_10", _o = "_idleCheckContainerActive_iz9tu_15", We = {
1996
- idleCheckContainer: wo,
1997
- idleCheckContainerIdle: To,
1998
- idleCheckContainerActive: _o
1999
- }, xo = 5 * 1e3;
2010
+ const To = "_idleCheckContainer_iz9tu_1", _o = "_idleCheckContainerIdle_iz9tu_10", xo = "_idleCheckContainerActive_iz9tu_15", qe = {
2011
+ idleCheckContainer: To,
2012
+ idleCheckContainerIdle: _o,
2013
+ idleCheckContainerActive: xo
2014
+ }, Eo = 5 * 1e3;
2000
2015
  function en({ children: e }) {
2001
- const t = O(null), n = f((v) => v.isIdle), o = f((v) => v.setIsIdle), s = O(null), u = f((v) => v.idleLocks).size, i = f((v) => v.eventEmitter), l = U(() => {
2016
+ const t = O(null), n = f((v) => v.isIdle), o = f((v) => v.setIsIdle), s = O(null), u = f((v) => v.idleLocks).size, i = f((v) => v.eventEmitter), l = B(() => {
2002
2017
  s.current !== null && (window.clearTimeout(s.current), s.current = null);
2003
- }, []), d = U(() => {
2004
- l(), s.current = window.setTimeout(() => o(!0), xo);
2018
+ }, []), d = B(() => {
2019
+ l(), s.current = window.setTimeout(() => o(!0), Eo);
2005
2020
  }, [l]);
2006
2021
  N(() => (o(!1), d(), () => {
2007
2022
  l();
@@ -2010,11 +2025,11 @@ function en({ children: e }) {
2010
2025
  if (!v) return;
2011
2026
  const _ = (S) => {
2012
2027
  n && (S.stopPropagation(), o(!1), d());
2013
- }, L = () => {
2028
+ }, j = () => {
2014
2029
  n && o(!1), d();
2015
2030
  };
2016
- return v.addEventListener("click", _), v.addEventListener("mousemove", L), () => {
2017
- v.removeEventListener("click", _), v.removeEventListener("mousemove", L);
2031
+ return v.addEventListener("click", _), v.addEventListener("mousemove", j), () => {
2032
+ v.removeEventListener("click", _), v.removeEventListener("mousemove", j);
2018
2033
  };
2019
2034
  }, [t, n, o, d]), N(() => {
2020
2035
  const v = () => {
@@ -2024,16 +2039,16 @@ function en({ children: e }) {
2024
2039
  i.off("resetIdle", v);
2025
2040
  };
2026
2041
  }, [i, o, d]);
2027
- const g = n && !u, y = `${We.idleCheckContainer} ${g ? We.idleCheckContainerIdle : We.idleCheckContainerActive}`;
2042
+ const g = n && !u, y = `${qe.idleCheckContainer} ${g ? qe.idleCheckContainerIdle : qe.idleCheckContainerActive}`;
2028
2043
  return /* @__PURE__ */ a.jsx("div", { ref: t, className: y, children: e });
2029
2044
  }
2030
- const Co = "_spinner_oo4hi_10", Eo = {
2045
+ const Co = "_spinner_oo4hi_10", Ro = {
2031
2046
  spinner: Co
2032
2047
  };
2033
- function Ro(e) {
2034
- return /* @__PURE__ */ a.jsx("div", j({ className: Eo.spinner }, e));
2048
+ function So(e) {
2049
+ return /* @__PURE__ */ a.jsx("div", P({ className: Ro.spinner }, e));
2035
2050
  }
2036
- function So(e, t = 500) {
2051
+ function bo(e, t = 500) {
2037
2052
  const [n, o] = X(e);
2038
2053
  return N(() => {
2039
2054
  const s = window.setTimeout(() => o(e), t);
@@ -2042,13 +2057,13 @@ function So(e, t = 500) {
2042
2057
  };
2043
2058
  }, [e, t]), n;
2044
2059
  }
2045
- const bo = "_loadingContainer_v9v7r_1", Po = {
2046
- loadingContainer: bo
2060
+ const Lo = "_loadingContainer_v9v7r_1", Po = {
2061
+ loadingContainer: Lo
2047
2062
  };
2048
2063
  function tn(n) {
2049
2064
  var o = n, { style: e } = o, t = ne(o, ["style"]);
2050
2065
  const s = f((u) => u.isLoading);
2051
- return So(s, 100) ? /* @__PURE__ */ a.jsx("div", he(j({ className: Po.loadingContainer, style: e }, t), { children: /* @__PURE__ */ a.jsx(Ro, {}) })) : null;
2066
+ return bo(s, 100) ? /* @__PURE__ */ a.jsx("div", he(P({ className: Po.loadingContainer, style: e }, t), { children: /* @__PURE__ */ a.jsx(So, {}) })) : null;
2052
2067
  }
2053
2068
  function jo() {
2054
2069
  return /* @__PURE__ */ a.jsx(
@@ -2061,7 +2076,7 @@ function jo() {
2061
2076
  }
2062
2077
  );
2063
2078
  }
2064
- function Lo() {
2079
+ function ko() {
2065
2080
  return /* @__PURE__ */ a.jsx(
2066
2081
  "svg",
2067
2082
  {
@@ -2072,18 +2087,18 @@ function Lo() {
2072
2087
  }
2073
2088
  );
2074
2089
  }
2075
- const ko = "_dropdownMenuContent_11aiz_1", Io = "_dropdownMenuItem_11aiz_82", Do = "_scrollAreaRoot_11aiz_124", Fo = "_scrollAreaViewport_11aiz_132", Mo = "_scrollAreaScrollbar_11aiz_140", No = "_scrollAreaThumb_11aiz_167", pe = {
2076
- dropdownMenuContent: ko,
2077
- dropdownMenuItem: Io,
2078
- scrollAreaRoot: Do,
2079
- scrollAreaViewport: Fo,
2080
- scrollAreaScrollbar: Mo,
2081
- scrollAreaThumb: No
2082
- }, Vo = xe.Root, Ao = xe.Trigger, Oo = xe.Portal, nn = Me((c, s) => {
2090
+ const Io = "_dropdownMenuContent_11aiz_1", Do = "_dropdownMenuItem_11aiz_82", Fo = "_scrollAreaRoot_11aiz_124", Mo = "_scrollAreaViewport_11aiz_132", No = "_scrollAreaScrollbar_11aiz_140", Vo = "_scrollAreaThumb_11aiz_167", pe = {
2091
+ dropdownMenuContent: Io,
2092
+ dropdownMenuItem: Do,
2093
+ scrollAreaRoot: Fo,
2094
+ scrollAreaViewport: Mo,
2095
+ scrollAreaScrollbar: No,
2096
+ scrollAreaThumb: Vo
2097
+ }, Ao = xe.Root, Oo = xe.Trigger, Ho = xe.Portal, nn = Me((c, s) => {
2083
2098
  var u = c, { sideOffset: e = 4, className: t, children: n } = u, o = ne(u, ["sideOffset", "className", "children"]);
2084
2099
  return /* @__PURE__ */ a.jsx(
2085
2100
  xe.Content,
2086
- he(j({
2101
+ he(P({
2087
2102
  ref: s,
2088
2103
  sideOffset: e,
2089
2104
  className: [pe.dropdownMenuContent, t].filter(Boolean).join(" "),
@@ -2095,19 +2110,19 @@ const ko = "_dropdownMenuContent_11aiz_1", Io = "_dropdownMenuItem_11aiz_82", Do
2095
2110
  }
2096
2111
  }, o), {
2097
2112
  children: /* @__PURE__ */ a.jsxs(
2098
- je.Root,
2113
+ Pe.Root,
2099
2114
  {
2100
2115
  className: pe.scrollAreaRoot,
2101
2116
  type: "always",
2102
2117
  scrollHideDelay: 0,
2103
2118
  children: [
2104
- /* @__PURE__ */ a.jsx(je.Viewport, { className: pe.scrollAreaViewport, children: n }),
2119
+ /* @__PURE__ */ a.jsx(Pe.Viewport, { className: pe.scrollAreaViewport, children: n }),
2105
2120
  /* @__PURE__ */ a.jsx(
2106
- je.Scrollbar,
2121
+ Pe.Scrollbar,
2107
2122
  {
2108
2123
  className: pe.scrollAreaScrollbar,
2109
2124
  orientation: "vertical",
2110
- children: /* @__PURE__ */ a.jsx(je.Thumb, { className: pe.scrollAreaThumb })
2125
+ children: /* @__PURE__ */ a.jsx(Pe.Thumb, { className: pe.scrollAreaThumb })
2111
2126
  }
2112
2127
  )
2113
2128
  ]
@@ -2126,7 +2141,7 @@ const rn = Me((s, o) => {
2126
2141
  };
2127
2142
  return /* @__PURE__ */ a.jsx(xe.Close, { asChild: !0, children: /* @__PURE__ */ a.jsx(
2128
2143
  "div",
2129
- j({
2144
+ P({
2130
2145
  ref: o,
2131
2146
  className: [pe.dropdownMenuItem, e].filter(Boolean).join(" "),
2132
2147
  role: "menuitem",
@@ -2139,15 +2154,15 @@ const rn = Me((s, o) => {
2139
2154
  rn.displayName = "PlayerMenuItem";
2140
2155
  const xt = "settings";
2141
2156
  function on() {
2142
- const [e, t] = X(!1), n = f((l) => l.containerRef), o = f((l) => l.addIdleLock), s = f((l) => l.removeIdleLock), c = f((l) => l.levels), u = f((l) => l.setLevel), i = U(
2157
+ const [e, t] = X(!1), n = f((l) => l.containerRef), o = f((l) => l.addIdleLock), s = f((l) => l.removeIdleLock), c = f((l) => l.levels), u = f((l) => l.setLevel), i = B(
2143
2158
  (l) => {
2144
2159
  t(l), l ? o(xt) : s(xt);
2145
2160
  },
2146
2161
  [o, s]
2147
2162
  );
2148
- return /* @__PURE__ */ a.jsxs(Vo, { open: e, onOpenChange: i, children: [
2149
- /* @__PURE__ */ a.jsx(Ao, { asChild: !0, children: /* @__PURE__ */ a.jsx(le, { children: /* @__PURE__ */ a.jsx(Lo, {}) }) }),
2150
- /* @__PURE__ */ a.jsx(Oo, { container: n.current, children: /* @__PURE__ */ a.jsx(nn, { side: "top", align: "end", children: c == null ? void 0 : c.map((l) => /* @__PURE__ */ a.jsxs(
2163
+ return /* @__PURE__ */ a.jsxs(Ao, { open: e, onOpenChange: i, children: [
2164
+ /* @__PURE__ */ a.jsx(Oo, { asChild: !0, children: /* @__PURE__ */ a.jsx(le, { children: /* @__PURE__ */ a.jsx(ko, {}) }) }),
2165
+ /* @__PURE__ */ a.jsx(Ho, { container: n.current, children: /* @__PURE__ */ a.jsx(nn, { side: "top", align: "end", children: c == null ? void 0 : c.map((l) => /* @__PURE__ */ a.jsxs(
2151
2166
  rn,
2152
2167
  {
2153
2168
  onClick: () => u(l.value),
@@ -2160,7 +2175,7 @@ function on() {
2160
2175
  )) }) })
2161
2176
  ] });
2162
2177
  }
2163
- function Ho() {
2178
+ function $o() {
2164
2179
  return /* @__PURE__ */ a.jsx(
2165
2180
  "svg",
2166
2181
  {
@@ -2171,7 +2186,7 @@ function Ho() {
2171
2186
  }
2172
2187
  );
2173
2188
  }
2174
- function $o() {
2189
+ function Uo() {
2175
2190
  return /* @__PURE__ */ a.jsx(
2176
2191
  "svg",
2177
2192
  {
@@ -2193,19 +2208,19 @@ function Bo() {
2193
2208
  }
2194
2209
  );
2195
2210
  }
2196
- const Uo = "_volumeContainer_4d6jg_1", zo = "_volumeSlider_4d6jg_8", Ct = {
2197
- volumeContainer: Uo,
2198
- volumeSlider: zo
2199
- }, Et = "volume";
2211
+ const zo = "_volumeContainer_4d6jg_1", qo = "_volumeSlider_4d6jg_8", Et = {
2212
+ volumeContainer: zo,
2213
+ volumeSlider: qo
2214
+ }, Ct = "volume";
2200
2215
  function sn() {
2201
2216
  const e = f((i) => i.setVolume), t = f((i) => i.volume), n = f((i) => i.addIdleLock), o = f((i) => i.removeIdleLock), s = (i) => {
2202
- e(i[0]), n(Et);
2217
+ e(i[0]), n(Ct);
2203
2218
  }, c = () => {
2204
- o(Et);
2219
+ o(Ct);
2205
2220
  }, u = () => e(t ? 0 : 100);
2206
- return /* @__PURE__ */ a.jsxs("div", { className: Ct.volumeContainer, children: [
2207
- /* @__PURE__ */ a.jsx(le, { onClick: u, className: "shrink-0", children: t ? t > 50 ? /* @__PURE__ */ a.jsx(Ho, {}) : /* @__PURE__ */ a.jsx($o, {}) : /* @__PURE__ */ a.jsx(Bo, {}) }),
2208
- /* @__PURE__ */ a.jsx("div", { className: Ct.volumeSlider, children: /* @__PURE__ */ a.jsx(
2221
+ return /* @__PURE__ */ a.jsxs("div", { className: Et.volumeContainer, children: [
2222
+ /* @__PURE__ */ a.jsx(le, { onClick: u, className: "shrink-0", children: t ? t > 50 ? /* @__PURE__ */ a.jsx($o, {}) : /* @__PURE__ */ a.jsx(Uo, {}) : /* @__PURE__ */ a.jsx(Bo, {}) }),
2223
+ /* @__PURE__ */ a.jsx("div", { className: Et.volumeSlider, children: /* @__PURE__ */ a.jsx(
2209
2224
  Ne,
2210
2225
  {
2211
2226
  value: [t],
@@ -2215,8 +2230,8 @@ function sn() {
2215
2230
  ) })
2216
2231
  ] });
2217
2232
  }
2218
- function ai(e) {
2219
- return /* @__PURE__ */ a.jsx(jr, { children: /* @__PURE__ */ a.jsx(Wo, j({}, e)) });
2233
+ function li(e) {
2234
+ return /* @__PURE__ */ a.jsx(jr, { children: /* @__PURE__ */ a.jsx(Wo, P({}, e)) });
2220
2235
  }
2221
2236
  function Wo({ url: e, messages: t, onEvent: n }) {
2222
2237
  const o = f((s) => s.containerRef);
@@ -2227,7 +2242,7 @@ function Wo({ url: e, messages: t, onEvent: n }) {
2227
2242
  className: K.playerContainer,
2228
2243
  children: [
2229
2244
  /* @__PURE__ */ a.jsxs(
2230
- _r,
2245
+ xr,
2231
2246
  {
2232
2247
  url: e,
2233
2248
  messages: {
@@ -2236,7 +2251,7 @@ function Wo({ url: e, messages: t, onEvent: n }) {
2236
2251
  },
2237
2252
  children: [
2238
2253
  /* @__PURE__ */ a.jsx(
2239
- Dr,
2254
+ Fr,
2240
2255
  {
2241
2256
  url: e,
2242
2257
  messages: {
@@ -2247,17 +2262,17 @@ function Wo({ url: e, messages: t, onEvent: n }) {
2247
2262
  /* @__PURE__ */ a.jsx(Jt, {}),
2248
2263
  /* @__PURE__ */ a.jsx(tn, {}),
2249
2264
  /* @__PURE__ */ a.jsxs(en, { children: [
2250
- /* @__PURE__ */ a.jsx(Ur, {}),
2265
+ /* @__PURE__ */ a.jsx(zr, {}),
2251
2266
  /* @__PURE__ */ a.jsx("div", { className: K.controlsBottom, children: /* @__PURE__ */ a.jsxs("div", { className: K.controlsContainer, children: [
2252
- /* @__PURE__ */ a.jsx(so, {}),
2267
+ /* @__PURE__ */ a.jsx(ao, {}),
2253
2268
  /* @__PURE__ */ a.jsxs("div", { className: K.controlsRow, children: [
2254
2269
  /* @__PURE__ */ a.jsxs(
2255
2270
  "div",
2256
2271
  {
2257
2272
  className: `${K.controlsSection} ${K.controlsSectionStart}`,
2258
2273
  children: [
2259
- /* @__PURE__ */ a.jsx(Xr, {}),
2260
- /* @__PURE__ */ a.jsx(lo, {}),
2274
+ /* @__PURE__ */ a.jsx(Gr, {}),
2275
+ /* @__PURE__ */ a.jsx(co, {}),
2261
2276
  /* @__PURE__ */ a.jsx(sn, {})
2262
2277
  ]
2263
2278
  }
@@ -2267,7 +2282,7 @@ function Wo({ url: e, messages: t, onEvent: n }) {
2267
2282
  {
2268
2283
  className: `${K.controlsSection} ${K.controlsSectionEnd}`,
2269
2284
  children: [
2270
- /* @__PURE__ */ a.jsx(Yr, { message: t == null ? void 0 : t.live }),
2285
+ /* @__PURE__ */ a.jsx(Xr, { message: t == null ? void 0 : t.live }),
2271
2286
  /* @__PURE__ */ a.jsx(on, {}),
2272
2287
  /* @__PURE__ */ a.jsx(Qt, {})
2273
2288
  ]
@@ -2280,12 +2295,12 @@ function Wo({ url: e, messages: t, onEvent: n }) {
2280
2295
  }
2281
2296
  ),
2282
2297
  /* @__PURE__ */ a.jsx(Pr, {}),
2283
- n && /* @__PURE__ */ a.jsx(br, { callback: n })
2298
+ n && /* @__PURE__ */ a.jsx(Lr, { callback: n })
2284
2299
  ]
2285
2300
  }
2286
2301
  );
2287
2302
  }
2288
- function qo() {
2303
+ function Zo() {
2289
2304
  const e = f((u) => u.isPlaying), t = f((u) => u.pause), n = f((u) => u.play), o = f((u) => u.currentTime), s = f((u) => u.duration), c = f((u) => u.seek);
2290
2305
  return /* @__PURE__ */ a.jsx(
2291
2306
  Yt,
@@ -2306,34 +2321,34 @@ function qo() {
2306
2321
  }
2307
2322
  );
2308
2323
  }
2309
- function Zo() {
2324
+ function Ko() {
2310
2325
  const e = f((s) => s.isPlaying), t = f((s) => s.pause), n = f((s) => s.play), o = () => {
2311
2326
  e ? t() : n();
2312
2327
  };
2313
2328
  return /* @__PURE__ */ a.jsx(le, { onClick: o, children: e ? /* @__PURE__ */ a.jsx(Xt, {}) : /* @__PURE__ */ a.jsx(Gt, {}) });
2314
2329
  }
2315
2330
  const Rt = "vod-player-progress-bar";
2316
- function Ko() {
2331
+ function Yo() {
2317
2332
  const e = O(null), t = O(null), [n, o] = X(!1), [s, c] = X(-1), [u, i] = X(-1), l = f((k) => k.currentTime), d = f((k) => k.duration), g = f((k) => k.seek), y = f((k) => k.addIdleLock), v = f((k) => k.removeIdleLock), _ = parseFloat(
2318
2333
  (d ? (u !== -1 ? u : l) / d * 100 : 0).toFixed(1)
2319
- ), L = (k) => {
2334
+ ), j = (k) => {
2320
2335
  i(d * (k[0] / 100)), y(Rt);
2321
2336
  }, S = () => {
2322
2337
  u !== -1 && (g(u), i(-1), v(Rt));
2323
- }, P = () => o(!0), M = () => o(!1), R = U(
2338
+ }, L = () => o(!0), M = () => o(!1), R = B(
2324
2339
  (k) => {
2325
2340
  const T = e.current, I = t.current;
2326
2341
  if (T && I) {
2327
- const p = Fe(T), B = Fe(I), J = (k.pageX || k.clientX) - p.left, q = J / p.width;
2328
- if (q < 0) return;
2329
- let V = J - B.width / 2;
2330
- V < 0 && (V = 0), V > p.width - B.width && (V = -1), I.style.left = V > -1 ? `${V}px` : "auto", I.style.right = V > -1 ? "auto" : "0px", c(q * d);
2342
+ const p = Fe(T), H = Fe(I), G = (k.pageX || k.clientX) - p.left, W = G / p.width;
2343
+ if (W < 0) return;
2344
+ let V = G - H.width / 2;
2345
+ V < 0 && (V = 0), V > p.width - H.width && (V = -1), I.style.left = V > -1 ? `${V}px` : "auto", I.style.right = V > -1 ? "auto" : "0px", c(W * d);
2331
2346
  }
2332
- P();
2347
+ L();
2333
2348
  },
2334
2349
  [d]
2335
2350
  );
2336
- return /* @__PURE__ */ a.jsxs("div", { className: ie.progressSlider, children: [
2351
+ return /* @__PURE__ */ a.jsxs("div", { className: se.progressSlider, children: [
2337
2352
  /* @__PURE__ */ a.jsx(
2338
2353
  Ne,
2339
2354
  {
@@ -2342,7 +2357,7 @@ function Ko() {
2342
2357
  onPointerLeave: M,
2343
2358
  onPointerDown: M,
2344
2359
  onPointerMove: R,
2345
- onValueChange: L,
2360
+ onValueChange: j,
2346
2361
  onValueCommit: S,
2347
2362
  step: 0.1
2348
2363
  }
@@ -2351,18 +2366,18 @@ function Ko() {
2351
2366
  "div",
2352
2367
  {
2353
2368
  ref: t,
2354
- className: `${ie.tipContainer} ${n ? ie.tipContainerVisible : ie.tipContainerHidden}`,
2355
- children: /* @__PURE__ */ a.jsx("p", { className: ie.tipContent, children: _e(s) })
2369
+ className: `${se.tipContainer} ${n ? se.tipContainerVisible : se.tipContainerHidden}`,
2370
+ children: /* @__PURE__ */ a.jsx("p", { className: se.tipContent, children: _e(s) })
2356
2371
  }
2357
2372
  )
2358
2373
  ] });
2359
2374
  }
2360
- const Yo = "_remainingTimeContainer_1yyhb_1", Xo = "_remainingTime_1yyhb_1", Go = "_remainingSeparator_1yyhb_17", De = {
2361
- remainingTimeContainer: Yo,
2362
- remainingTime: Xo,
2363
- remainingSeparator: Go
2375
+ const Xo = "_remainingTimeContainer_1yyhb_1", Go = "_remainingTime_1yyhb_1", Jo = "_remainingSeparator_1yyhb_17", De = {
2376
+ remainingTimeContainer: Xo,
2377
+ remainingTime: Go,
2378
+ remainingSeparator: Jo
2364
2379
  };
2365
- function Jo() {
2380
+ function Qo() {
2366
2381
  const e = f((n) => n.currentTime), t = f((n) => n.duration);
2367
2382
  return /* @__PURE__ */ a.jsxs("div", { className: De.remainingTimeContainer, children: [
2368
2383
  /* @__PURE__ */ a.jsx("p", { className: De.remainingTime, children: _e(e) }),
@@ -2370,17 +2385,17 @@ function Jo() {
2370
2385
  /* @__PURE__ */ a.jsx("p", { className: De.remainingTime, children: _e(t) })
2371
2386
  ] });
2372
2387
  }
2373
- function Qo({ callback: e }) {
2388
+ function ei({ callback: e }) {
2374
2389
  const t = f((n) => n.eventEmitter);
2375
2390
  return N(() => {
2376
2391
  const n = (o) => e("timeUpdate", o);
2377
2392
  return t.on("timeUpdate", n), () => {
2378
2393
  t.off("timeUpdate", n);
2379
2394
  };
2380
- }, [e, t]), /* @__PURE__ */ a.jsx(Ut, { callback: e });
2395
+ }, [e, t]), /* @__PURE__ */ a.jsx(Bt, { callback: e });
2381
2396
  }
2382
- function ei() {
2383
- const e = f((i) => i.currentTime), t = f((i) => i.duration), n = f((i) => i.isPlaying), o = f((i) => i.pause), s = f((i) => i.play), c = f((i) => i.seek), u = U(
2397
+ function ti() {
2398
+ const e = f((i) => i.currentTime), t = f((i) => i.duration), n = f((i) => i.isPlaying), o = f((i) => i.pause), s = f((i) => i.play), c = f((i) => i.seek), u = B(
2384
2399
  (i) => {
2385
2400
  let l = !1;
2386
2401
  if (!(i.target instanceof HTMLInputElement || i.ctrlKey)) {
@@ -2402,37 +2417,37 @@ function ei() {
2402
2417
  );
2403
2418
  return N(() => (document.addEventListener("keydown", u), () => {
2404
2419
  document.removeEventListener("keydown", u);
2405
- }), [u]), /* @__PURE__ */ a.jsx(qt, {});
2420
+ }), [u]), /* @__PURE__ */ a.jsx(Wt, {});
2406
2421
  }
2407
- function li(e) {
2408
- return /* @__PURE__ */ a.jsx(Zt, { children: /* @__PURE__ */ a.jsx(ti, j({}, e)) });
2422
+ function ci(e) {
2423
+ return /* @__PURE__ */ a.jsx(Zt, { children: /* @__PURE__ */ a.jsx(ni, P({}, e)) });
2409
2424
  }
2410
- function ti({ url: e, onEvent: t, startTime: n }) {
2411
- const o = f((c) => c.setStartTime), s = f((c) => c.containerRef);
2425
+ function ni({ url: e, messages: t, onEvent: n, startTime: o }) {
2426
+ const s = f((u) => u.setStartTime), c = f((u) => u.containerRef);
2412
2427
  return N(() => {
2413
- n && o(n);
2414
- }, [n, o]), /* @__PURE__ */ a.jsxs(
2428
+ o && s(o);
2429
+ }, [o, s]), /* @__PURE__ */ a.jsxs(
2415
2430
  "div",
2416
2431
  {
2417
- ref: s,
2432
+ ref: c,
2418
2433
  className: K.playerContainer,
2419
2434
  children: [
2420
- /* @__PURE__ */ a.jsx(Kt, { url: e, isLive: !1 }),
2435
+ /* @__PURE__ */ a.jsx(Kt, { url: e, isLive: !1, messages: t }),
2421
2436
  /* @__PURE__ */ a.jsx(Jt, {}),
2422
2437
  /* @__PURE__ */ a.jsx(tn, {}),
2423
2438
  /* @__PURE__ */ a.jsxs(en, { children: [
2424
- /* @__PURE__ */ a.jsx(qo, {}),
2439
+ /* @__PURE__ */ a.jsx(Zo, {}),
2425
2440
  /* @__PURE__ */ a.jsx("div", { className: K.controlsBottom, children: /* @__PURE__ */ a.jsxs("div", { className: K.controlsContainer, children: [
2426
- /* @__PURE__ */ a.jsx(Ko, {}),
2441
+ /* @__PURE__ */ a.jsx(Yo, {}),
2427
2442
  /* @__PURE__ */ a.jsxs("div", { className: K.controlsRow, children: [
2428
2443
  /* @__PURE__ */ a.jsxs(
2429
2444
  "div",
2430
2445
  {
2431
2446
  className: `${K.controlsSection} ${K.controlsSectionStart}`,
2432
2447
  children: [
2433
- /* @__PURE__ */ a.jsx(Zo, {}),
2448
+ /* @__PURE__ */ a.jsx(Ko, {}),
2434
2449
  /* @__PURE__ */ a.jsx(sn, {}),
2435
- /* @__PURE__ */ a.jsx(Jo, {})
2450
+ /* @__PURE__ */ a.jsx(Qo, {})
2436
2451
  ]
2437
2452
  }
2438
2453
  ),
@@ -2449,14 +2464,14 @@ function ti({ url: e, onEvent: t, startTime: n }) {
2449
2464
  ] })
2450
2465
  ] }) })
2451
2466
  ] }),
2452
- /* @__PURE__ */ a.jsx(ei, {}),
2453
- t && /* @__PURE__ */ a.jsx(Qo, { callback: t })
2467
+ /* @__PURE__ */ a.jsx(ti, {}),
2468
+ n && /* @__PURE__ */ a.jsx(ei, { callback: n })
2454
2469
  ]
2455
2470
  }
2456
2471
  );
2457
2472
  }
2458
2473
  export {
2459
- ai as LivePlayer,
2460
- li as VodPlayer
2474
+ li as LivePlayer,
2475
+ ci as VodPlayer
2461
2476
  };
2462
2477
  //# sourceMappingURL=react-video-player.es.js.map