@devix-technologies/react-gjirafa-vp-player 1.0.7 → 1.0.9

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.
@@ -1,5 +1,5 @@
1
1
  import * as H from "react";
2
- import mt, { forwardRef as yt, useContext as et, useState as D, useEffect as xe, useRef as Be, useMemo as tt, createContext as gt, useCallback as ze } from "react";
2
+ import mt, { forwardRef as yt, useContext as et, useState as U, useEffect as xe, useRef as Be, useMemo as tt, createContext as gt, useCallback as ze } from "react";
3
3
  var he = { exports: {} }, se = {};
4
4
  /**
5
5
  * @license React
@@ -10,10 +10,10 @@ var he = { exports: {} }, se = {};
10
10
  * This source code is licensed under the MIT license found in the
11
11
  * LICENSE file in the root directory of this source tree.
12
12
  */
13
- var De;
13
+ var Ue;
14
14
  function vt() {
15
- if (De) return se;
16
- De = 1;
15
+ if (Ue) return se;
16
+ Ue = 1;
17
17
  var e = Symbol.for("react.transitional.element"), t = Symbol.for("react.fragment");
18
18
  function r(n, a, i) {
19
19
  var s = null;
@@ -42,13 +42,13 @@ var ce = {};
42
42
  * This source code is licensed under the MIT license found in the
43
43
  * LICENSE file in the root directory of this source tree.
44
44
  */
45
- var Ue;
45
+ var De;
46
46
  function bt() {
47
- return Ue || (Ue = 1, process.env.NODE_ENV !== "production" && function() {
47
+ return De || (De = 1, process.env.NODE_ENV !== "production" && function() {
48
48
  function e(o) {
49
49
  if (o == null) return null;
50
50
  if (typeof o == "function")
51
- return o.$$typeof === T ? null : o.displayName || o.name || null;
51
+ return o.$$typeof === x ? null : o.displayName || o.name || null;
52
52
  if (typeof o == "string") return o;
53
53
  switch (o) {
54
54
  case d:
@@ -59,30 +59,30 @@ function bt() {
59
59
  return "StrictMode";
60
60
  case R:
61
61
  return "Suspense";
62
- case _:
62
+ case T:
63
63
  return "SuspenseList";
64
- case B:
64
+ case V:
65
65
  return "Activity";
66
66
  }
67
67
  if (typeof o == "object")
68
68
  switch (typeof o.tag == "number" && console.error(
69
69
  "Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."
70
70
  ), o.$$typeof) {
71
- case b:
71
+ case v:
72
72
  return "Portal";
73
73
  case S:
74
74
  return (o.displayName || "Context") + ".Provider";
75
- case v:
75
+ case w:
76
76
  return (o._context.displayName || "Context") + ".Consumer";
77
- case E:
78
- var x = o.render;
79
- return o = o.displayName, o || (o = x.displayName || x.name || "", o = o !== "" ? "ForwardRef(" + o + ")" : "ForwardRef"), o;
80
- case p:
81
- return x = o.displayName || null, x !== null ? x : e(o.type) || "Memo";
82
- case C:
83
- x = o._payload, o = o._init;
77
+ case A:
78
+ var b = o.render;
79
+ return o = o.displayName, o || (o = b.displayName || b.name || "", o = o !== "" ? "ForwardRef(" + o + ")" : "ForwardRef"), o;
80
+ case f:
81
+ return b = o.displayName || null, b !== null ? b : e(o.type) || "Memo";
82
+ case P:
83
+ b = o._payload, o = o._init;
84
84
  try {
85
- return e(o(x));
85
+ return e(o(b));
86
86
  } catch {
87
87
  }
88
88
  }
@@ -94,15 +94,15 @@ function bt() {
94
94
  function r(o) {
95
95
  try {
96
96
  t(o);
97
- var x = !1;
97
+ var b = !1;
98
98
  } catch {
99
- x = !0;
99
+ b = !0;
100
100
  }
101
- if (x) {
102
- x = console;
103
- var A = x.error, N = typeof Symbol == "function" && Symbol.toStringTag && o[Symbol.toStringTag] || o.constructor.name || "Object";
104
- return A.call(
105
- x,
101
+ if (b) {
102
+ b = console;
103
+ var I = b.error, N = typeof Symbol == "function" && Symbol.toStringTag && o[Symbol.toStringTag] || o.constructor.name || "Object";
104
+ return I.call(
105
+ b,
106
106
  "The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",
107
107
  N
108
108
  ), t(o);
@@ -110,17 +110,17 @@ function bt() {
110
110
  }
111
111
  function n(o) {
112
112
  if (o === d) return "<>";
113
- if (typeof o == "object" && o !== null && o.$$typeof === C)
113
+ if (typeof o == "object" && o !== null && o.$$typeof === P)
114
114
  return "<...>";
115
115
  try {
116
- var x = e(o);
117
- return x ? "<" + x + ">" : "<...>";
116
+ var b = e(o);
117
+ return b ? "<" + b + ">" : "<...>";
118
118
  } catch {
119
119
  return "<...>";
120
120
  }
121
121
  }
122
122
  function a() {
123
- var o = I.A;
123
+ var o = C.A;
124
124
  return o === null ? null : o.getOwner();
125
125
  }
126
126
  function i() {
@@ -128,20 +128,20 @@ function bt() {
128
128
  }
129
129
  function s(o) {
130
130
  if (G.call(o, "key")) {
131
- var x = Object.getOwnPropertyDescriptor(o, "key").get;
132
- if (x && x.isReactWarning) return !1;
131
+ var b = Object.getOwnPropertyDescriptor(o, "key").get;
132
+ if (b && b.isReactWarning) return !1;
133
133
  }
134
134
  return o.key !== void 0;
135
135
  }
136
- function c(o, x) {
137
- function A() {
136
+ function c(o, b) {
137
+ function I() {
138
138
  Z || (Z = !0, console.error(
139
139
  "%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)",
140
- x
140
+ b
141
141
  ));
142
142
  }
143
- A.isReactWarning = !0, Object.defineProperty(o, "key", {
144
- get: A,
143
+ I.isReactWarning = !0, Object.defineProperty(o, "key", {
144
+ get: I,
145
145
  configurable: !0
146
146
  });
147
147
  }
@@ -151,14 +151,14 @@ function bt() {
151
151
  "Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release."
152
152
  )), o = this.props.ref, o !== void 0 ? o : null;
153
153
  }
154
- function m(o, x, A, N, K, U, _e, Se) {
155
- return A = U.ref, o = {
156
- $$typeof: w,
154
+ function m(o, b, I, N, K, D, _e, Se) {
155
+ return I = D.ref, o = {
156
+ $$typeof: k,
157
157
  type: o,
158
- key: x,
159
- props: U,
158
+ key: b,
159
+ props: D,
160
160
  _owner: K
161
- }, (A !== void 0 ? A : null) !== null ? Object.defineProperty(o, "ref", {
161
+ }, (I !== void 0 ? I : null) !== null ? Object.defineProperty(o, "ref", {
162
162
  enumerable: !1,
163
163
  get: u
164
164
  }) : Object.defineProperty(o, "ref", { enumerable: !1, value: null }), o._store = {}, Object.defineProperty(o._store, "validated", {
@@ -183,22 +183,22 @@ function bt() {
183
183
  value: Se
184
184
  }), Object.freeze && (Object.freeze(o.props), Object.freeze(o)), o;
185
185
  }
186
- function l(o, x, A, N, K, U, _e, Se) {
187
- var L = x.children;
186
+ function l(o, b, I, N, K, D, _e, Se) {
187
+ var L = b.children;
188
188
  if (L !== void 0)
189
189
  if (N)
190
190
  if (z(L)) {
191
191
  for (N = 0; N < L.length; N++)
192
- f(L[N]);
192
+ p(L[N]);
193
193
  Object.freeze && Object.freeze(L);
194
194
  } else
195
195
  console.error(
196
196
  "React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead."
197
197
  );
198
- else f(L);
199
- if (G.call(x, "key")) {
198
+ else p(L);
199
+ if (G.call(b, "key")) {
200
200
  L = e(o);
201
- var ee = Object.keys(x).filter(function(ht) {
201
+ var ee = Object.keys(b).filter(function(ht) {
202
202
  return ht !== "key";
203
203
  });
204
204
  N = 0 < ee.length ? "{key: someKey, " + ee.join(": ..., ") + ": ...}" : "{key: someKey}", oe[L + N] || (ee = 0 < ee.length ? "{" + ee.join(": ..., ") + ": ...}" : "{}", console.error(
@@ -214,29 +214,29 @@ React keys must be passed directly to JSX without using spread:
214
214
  L
215
215
  ), oe[L + N] = !0);
216
216
  }
217
- if (L = null, A !== void 0 && (r(A), L = "" + A), s(x) && (r(x.key), L = "" + x.key), "key" in x) {
218
- A = {};
219
- for (var Re in x)
220
- Re !== "key" && (A[Re] = x[Re]);
221
- } else A = x;
217
+ if (L = null, I !== void 0 && (r(I), L = "" + I), s(b) && (r(b.key), L = "" + b.key), "key" in b) {
218
+ I = {};
219
+ for (var Re in b)
220
+ Re !== "key" && (I[Re] = b[Re]);
221
+ } else I = b;
222
222
  return L && c(
223
- A,
223
+ I,
224
224
  typeof o == "function" ? o.displayName || o.name || "Unknown" : o
225
225
  ), m(
226
226
  o,
227
227
  L,
228
- U,
228
+ D,
229
229
  K,
230
230
  a(),
231
- A,
231
+ I,
232
232
  _e,
233
233
  Se
234
234
  );
235
235
  }
236
- function f(o) {
237
- typeof o == "object" && o !== null && o.$$typeof === w && o._store && (o._store.validated = 1);
236
+ function p(o) {
237
+ typeof o == "object" && o !== null && o.$$typeof === k && o._store && (o._store.validated = 1);
238
238
  }
239
- var g = mt, w = Symbol.for("react.transitional.element"), b = Symbol.for("react.portal"), d = Symbol.for("react.fragment"), h = Symbol.for("react.strict_mode"), y = Symbol.for("react.profiler"), v = Symbol.for("react.consumer"), S = Symbol.for("react.context"), E = Symbol.for("react.forward_ref"), R = Symbol.for("react.suspense"), _ = Symbol.for("react.suspense_list"), p = Symbol.for("react.memo"), C = Symbol.for("react.lazy"), B = Symbol.for("react.activity"), T = Symbol.for("react.client.reference"), I = g.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, G = Object.prototype.hasOwnProperty, z = Array.isArray, X = console.createTask ? console.createTask : function() {
239
+ var g = mt, k = Symbol.for("react.transitional.element"), v = Symbol.for("react.portal"), d = Symbol.for("react.fragment"), h = Symbol.for("react.strict_mode"), y = Symbol.for("react.profiler"), w = Symbol.for("react.consumer"), S = Symbol.for("react.context"), A = Symbol.for("react.forward_ref"), R = Symbol.for("react.suspense"), T = Symbol.for("react.suspense_list"), f = Symbol.for("react.memo"), P = Symbol.for("react.lazy"), V = Symbol.for("react.activity"), x = Symbol.for("react.client.reference"), C = g.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, G = Object.prototype.hasOwnProperty, z = Array.isArray, X = console.createTask ? console.createTask : function() {
240
240
  return null;
241
241
  };
242
242
  g = {
@@ -248,29 +248,29 @@ React keys must be passed directly to JSX without using spread:
248
248
  g,
249
249
  i
250
250
  )(), ie = X(n(i)), oe = {};
251
- ce.Fragment = d, ce.jsx = function(o, x, A, N, K) {
252
- var U = 1e4 > I.recentlyCreatedOwnerStacks++;
251
+ ce.Fragment = d, ce.jsx = function(o, b, I, N, K) {
252
+ var D = 1e4 > C.recentlyCreatedOwnerStacks++;
253
253
  return l(
254
254
  o,
255
- x,
256
- A,
255
+ b,
256
+ I,
257
257
  !1,
258
258
  N,
259
259
  K,
260
- U ? Error("react-stack-top-frame") : J,
261
- U ? X(n(o)) : ie
260
+ D ? Error("react-stack-top-frame") : J,
261
+ D ? X(n(o)) : ie
262
262
  );
263
- }, ce.jsxs = function(o, x, A, N, K) {
264
- var U = 1e4 > I.recentlyCreatedOwnerStacks++;
263
+ }, ce.jsxs = function(o, b, I, N, K) {
264
+ var D = 1e4 > C.recentlyCreatedOwnerStacks++;
265
265
  return l(
266
266
  o,
267
- x,
268
- A,
267
+ b,
268
+ I,
269
269
  !0,
270
270
  N,
271
271
  K,
272
- U ? Error("react-stack-top-frame") : J,
273
- U ? X(n(o)) : ie
272
+ D ? Error("react-stack-top-frame") : J,
273
+ D ? X(n(o)) : ie
274
274
  );
275
275
  };
276
276
  }()), ce;
@@ -329,7 +329,7 @@ var Pt = /* @__PURE__ */ function() {
329
329
  return (a = n.parentNode) == null ? void 0 : a.removeChild(n);
330
330
  }), this.tags = [], this.ctr = 0;
331
331
  }, e;
332
- }(), F = "-ms-", we = "-moz-", k = "-webkit-", rt = "comm", Le = "rule", Fe = "decl", Et = "@import", nt = "@keyframes", _t = "@layer", St = Math.abs, ke = String.fromCharCode, Rt = Object.assign;
332
+ }(), F = "-ms-", we = "-moz-", E = "-webkit-", rt = "comm", Le = "rule", Fe = "decl", Et = "@import", nt = "@keyframes", _t = "@layer", St = Math.abs, ke = String.fromCharCode, Rt = Object.assign;
333
333
  function Tt(e, t) {
334
334
  return $(e, 0) ^ 45 ? (((t << 2 ^ $(e, 0)) << 2 ^ $(e, 1)) << 2 ^ $(e, 2)) << 2 ^ $(e, 3) : 0;
335
335
  }
@@ -339,7 +339,7 @@ function at(e) {
339
339
  function At(e, t) {
340
340
  return (e = t.exec(e)) ? e[0] : e;
341
341
  }
342
- function P(e, t, r) {
342
+ function _(e, t, r) {
343
343
  return e.replace(t, r);
344
344
  }
345
345
  function je(e, t) {
@@ -363,7 +363,7 @@ function me(e, t) {
363
363
  function Ct(e, t) {
364
364
  return e.map(t).join("");
365
365
  }
366
- var Pe = 1, re = 1, it = 0, V = 0, O = 0, ae = "";
366
+ var Pe = 1, re = 1, it = 0, M = 0, O = 0, ae = "";
367
367
  function Ee(e, t, r, n, a, i, s) {
368
368
  return { value: e, root: t, parent: r, type: n, props: a, children: i, line: Pe, column: re, length: s, return: "" };
369
369
  }
@@ -374,16 +374,16 @@ function It() {
374
374
  return O;
375
375
  }
376
376
  function Ot() {
377
- return O = V > 0 ? $(ae, --V) : 0, re--, O === 10 && (re = 1, Pe--), O;
377
+ return O = M > 0 ? $(ae, --M) : 0, re--, O === 10 && (re = 1, Pe--), O;
378
378
  }
379
- function M() {
380
- return O = V < it ? $(ae, V++) : 0, re++, O === 10 && (re = 1, Pe++), O;
379
+ function B() {
380
+ return O = M < it ? $(ae, M++) : 0, re++, O === 10 && (re = 1, Pe++), O;
381
381
  }
382
382
  function q() {
383
- return $(ae, V);
383
+ return $(ae, M);
384
384
  }
385
385
  function ge() {
386
- return V;
386
+ return M;
387
387
  }
388
388
  function pe(e, t) {
389
389
  return ue(ae, e, t);
@@ -427,30 +427,30 @@ function de(e) {
427
427
  return 0;
428
428
  }
429
429
  function ot(e) {
430
- return Pe = re = 1, it = W(ae = e), V = 0, [];
430
+ return Pe = re = 1, it = W(ae = e), M = 0, [];
431
431
  }
432
432
  function st(e) {
433
433
  return ae = "", e;
434
434
  }
435
435
  function ve(e) {
436
- return at(pe(V - 1, $e(e === 91 ? e + 2 : e === 40 ? e + 1 : e)));
436
+ return at(pe(M - 1, $e(e === 91 ? e + 2 : e === 40 ? e + 1 : e)));
437
437
  }
438
438
  function jt(e) {
439
439
  for (; (O = q()) && O < 33; )
440
- M();
440
+ B();
441
441
  return de(e) > 2 || de(O) > 3 ? "" : " ";
442
442
  }
443
443
  function $t(e, t) {
444
- for (; --t && M() && !(O < 48 || O > 102 || O > 57 && O < 65 || O > 70 && O < 97); )
444
+ for (; --t && B() && !(O < 48 || O > 102 || O > 57 && O < 65 || O > 70 && O < 97); )
445
445
  ;
446
- return pe(e, ge() + (t < 6 && q() == 32 && M() == 32));
446
+ return pe(e, ge() + (t < 6 && q() == 32 && B() == 32));
447
447
  }
448
448
  function $e(e) {
449
- for (; M(); )
449
+ for (; B(); )
450
450
  switch (O) {
451
451
  // ] ) " '
452
452
  case e:
453
- return V;
453
+ return M;
454
454
  // " '
455
455
  case 34:
456
456
  case 39:
@@ -462,135 +462,135 @@ function $e(e) {
462
462
  break;
463
463
  // \
464
464
  case 92:
465
- M();
465
+ B();
466
466
  break;
467
467
  }
468
- return V;
468
+ return M;
469
469
  }
470
470
  function Nt(e, t) {
471
- for (; M() && e + O !== 57; )
471
+ for (; B() && e + O !== 57; )
472
472
  if (e + O === 84 && q() === 47)
473
473
  break;
474
- return "/*" + pe(t, V - 1) + "*" + ke(e === 47 ? e : M());
474
+ return "/*" + pe(t, M - 1) + "*" + ke(e === 47 ? e : B());
475
475
  }
476
476
  function Lt(e) {
477
477
  for (; !de(q()); )
478
- M();
479
- return pe(e, V);
478
+ B();
479
+ return pe(e, M);
480
480
  }
481
481
  function Ft(e) {
482
482
  return st(be("", null, null, null, [""], e = ot(e), 0, [0], e));
483
483
  }
484
484
  function be(e, t, r, n, a, i, s, c, u) {
485
- for (var m = 0, l = 0, f = s, g = 0, w = 0, b = 0, d = 1, h = 1, y = 1, v = 0, S = "", E = a, R = i, _ = n, p = S; h; )
486
- switch (b = v, v = M()) {
485
+ for (var m = 0, l = 0, p = s, g = 0, k = 0, v = 0, d = 1, h = 1, y = 1, w = 0, S = "", A = a, R = i, T = n, f = S; h; )
486
+ switch (v = w, w = B()) {
487
487
  // (
488
488
  case 40:
489
- if (b != 108 && $(p, f - 1) == 58) {
490
- je(p += P(ve(v), "&", "&\f"), "&\f") != -1 && (y = -1);
489
+ if (v != 108 && $(f, p - 1) == 58) {
490
+ je(f += _(ve(w), "&", "&\f"), "&\f") != -1 && (y = -1);
491
491
  break;
492
492
  }
493
493
  // " ' [
494
494
  case 34:
495
495
  case 39:
496
496
  case 91:
497
- p += ve(v);
497
+ f += ve(w);
498
498
  break;
499
499
  // \t \n \r \s
500
500
  case 9:
501
501
  case 10:
502
502
  case 13:
503
503
  case 32:
504
- p += jt(b);
504
+ f += jt(v);
505
505
  break;
506
506
  // \
507
507
  case 92:
508
- p += $t(ge() - 1, 7);
508
+ f += $t(ge() - 1, 7);
509
509
  continue;
510
510
  // /
511
511
  case 47:
512
512
  switch (q()) {
513
513
  case 42:
514
514
  case 47:
515
- me(Vt(Nt(M(), ge()), t, r), u);
515
+ me(Vt(Nt(B(), ge()), t, r), u);
516
516
  break;
517
517
  default:
518
- p += "/";
518
+ f += "/";
519
519
  }
520
520
  break;
521
521
  // {
522
522
  case 123 * d:
523
- c[m++] = W(p) * y;
523
+ c[m++] = W(f) * y;
524
524
  // } ; \0
525
525
  case 125 * d:
526
526
  case 59:
527
527
  case 0:
528
- switch (v) {
528
+ switch (w) {
529
529
  // \0 }
530
530
  case 0:
531
531
  case 125:
532
532
  h = 0;
533
533
  // ;
534
534
  case 59 + l:
535
- y == -1 && (p = P(p, /\f/g, "")), w > 0 && W(p) - f && me(w > 32 ? qe(p + ";", n, r, f - 1) : qe(P(p, " ", "") + ";", n, r, f - 2), u);
535
+ y == -1 && (f = _(f, /\f/g, "")), k > 0 && W(f) - p && me(k > 32 ? qe(f + ";", n, r, p - 1) : qe(_(f, " ", "") + ";", n, r, p - 2), u);
536
536
  break;
537
537
  // @ ;
538
538
  case 59:
539
- p += ";";
539
+ f += ";";
540
540
  // { rule/at-rule
541
541
  default:
542
- if (me(_ = Ye(p, t, r, m, l, a, c, S, E = [], R = [], f), i), v === 123)
542
+ if (me(T = Ye(f, t, r, m, l, a, c, S, A = [], R = [], p), i), w === 123)
543
543
  if (l === 0)
544
- be(p, t, _, _, E, i, f, c, R);
544
+ be(f, t, T, T, A, i, p, c, R);
545
545
  else
546
- switch (g === 99 && $(p, 3) === 110 ? 100 : g) {
546
+ switch (g === 99 && $(f, 3) === 110 ? 100 : g) {
547
547
  // d l m s
548
548
  case 100:
549
549
  case 108:
550
550
  case 109:
551
551
  case 115:
552
- be(e, _, _, n && me(Ye(e, _, _, 0, 0, a, c, S, a, E = [], f), R), a, R, f, c, n ? E : R);
552
+ be(e, T, T, n && me(Ye(e, T, T, 0, 0, a, c, S, a, A = [], p), R), a, R, p, c, n ? A : R);
553
553
  break;
554
554
  default:
555
- be(p, _, _, _, [""], R, 0, c, R);
555
+ be(f, T, T, T, [""], R, 0, c, R);
556
556
  }
557
557
  }
558
- m = l = w = 0, d = y = 1, S = p = "", f = s;
558
+ m = l = k = 0, d = y = 1, S = f = "", p = s;
559
559
  break;
560
560
  // :
561
561
  case 58:
562
- f = 1 + W(p), w = b;
562
+ p = 1 + W(f), k = v;
563
563
  default:
564
564
  if (d < 1) {
565
- if (v == 123)
565
+ if (w == 123)
566
566
  --d;
567
- else if (v == 125 && d++ == 0 && Ot() == 125)
567
+ else if (w == 125 && d++ == 0 && Ot() == 125)
568
568
  continue;
569
569
  }
570
- switch (p += ke(v), v * d) {
570
+ switch (f += ke(w), w * d) {
571
571
  // &
572
572
  case 38:
573
- y = l > 0 ? 1 : (p += "\f", -1);
573
+ y = l > 0 ? 1 : (f += "\f", -1);
574
574
  break;
575
575
  // ,
576
576
  case 44:
577
- c[m++] = (W(p) - 1) * y, y = 1;
577
+ c[m++] = (W(f) - 1) * y, y = 1;
578
578
  break;
579
579
  // @
580
580
  case 64:
581
- q() === 45 && (p += ve(M())), g = q(), l = f = W(S = p += Lt(ge())), v++;
581
+ q() === 45 && (f += ve(B())), g = q(), l = p = W(S = f += Lt(ge())), w++;
582
582
  break;
583
583
  // -
584
584
  case 45:
585
- b === 45 && W(p) == 2 && (d = 0);
585
+ v === 45 && W(f) == 2 && (d = 0);
586
586
  }
587
587
  }
588
588
  return i;
589
589
  }
590
590
  function Ye(e, t, r, n, a, i, s, c, u, m, l) {
591
- for (var f = a - 1, g = a === 0 ? i : [""], w = Ve(g), b = 0, d = 0, h = 0; b < n; ++b)
592
- for (var y = 0, v = ue(e, f + 1, f = St(d = s[b])), S = e; y < w; ++y)
593
- (S = at(d > 0 ? g[y] + " " + v : P(v, /&\f/g, g[y]))) && (u[h++] = S);
591
+ for (var p = a - 1, g = a === 0 ? i : [""], k = Ve(g), v = 0, d = 0, h = 0; v < n; ++v)
592
+ for (var y = 0, w = ue(e, p + 1, p = St(d = s[v])), S = e; y < k; ++y)
593
+ (S = at(d > 0 ? g[y] + " " + w : _(w, /&\f/g, g[y]))) && (u[h++] = S);
594
594
  return Ee(e, t, r, a === 0 ? Le : c, u, m, l);
595
595
  }
596
596
  function Vt(e, t, r) {
@@ -639,16 +639,16 @@ function ct(e) {
639
639
  return t[r] === void 0 && (t[r] = e(r)), t[r];
640
640
  };
641
641
  }
642
- var Dt = function(t, r, n) {
642
+ var Ut = function(t, r, n) {
643
643
  for (var a = 0, i = 0; a = i, i = q(), a === 38 && i === 12 && (r[n] = 1), !de(i); )
644
- M();
645
- return pe(t, V);
646
- }, Ut = function(t, r) {
644
+ B();
645
+ return pe(t, M);
646
+ }, Dt = function(t, r) {
647
647
  var n = -1, a = 44;
648
648
  do
649
649
  switch (de(a)) {
650
650
  case 0:
651
- a === 38 && q() === 12 && (r[n] = 1), t[n] += Dt(V - 1, r, n);
651
+ a === 38 && q() === 12 && (r[n] = 1), t[n] += Ut(M - 1, r, n);
652
652
  break;
653
653
  case 2:
654
654
  t[n] += ve(a);
@@ -662,10 +662,10 @@ var Dt = function(t, r, n) {
662
662
  default:
663
663
  t[n] += ke(a);
664
664
  }
665
- while (a = M());
665
+ while (a = B());
666
666
  return t;
667
667
  }, Wt = function(t, r) {
668
- return st(Ut(ot(t), r));
668
+ return st(Dt(ot(t), r));
669
669
  }, He = /* @__PURE__ */ new WeakMap(), Yt = function(t) {
670
670
  if (!(t.type !== "rule" || !t.parent || // positive .length indicates that this rule contains pseudo
671
671
  // negative .length indicates that this rule has been already prefixed
@@ -691,7 +691,7 @@ function lt(e, t) {
691
691
  switch (Tt(e, t)) {
692
692
  // color-adjust
693
693
  case 5103:
694
- return k + "print-" + e + e;
694
+ return E + "print-" + e + e;
695
695
  // animation, animation-(delay|direction|duration|fill-mode|iteration-count|name|play-state|timing-function)
696
696
  case 5737:
697
697
  case 4201:
@@ -721,58 +721,58 @@ function lt(e, t) {
721
721
  case 5365:
722
722
  case 5621:
723
723
  case 3829:
724
- return k + e + e;
724
+ return E + e + e;
725
725
  // appearance, user-select, transform, hyphens, text-size-adjust
726
726
  case 5349:
727
727
  case 4246:
728
728
  case 4810:
729
729
  case 6968:
730
730
  case 2756:
731
- return k + e + we + e + F + e + e;
731
+ return E + e + we + e + F + e + e;
732
732
  // flex, flex-direction
733
733
  case 6828:
734
734
  case 4268:
735
- return k + e + F + e + e;
735
+ return E + e + F + e + e;
736
736
  // order
737
737
  case 6165:
738
- return k + e + F + "flex-" + e + e;
738
+ return E + e + F + "flex-" + e + e;
739
739
  // align-items
740
740
  case 5187:
741
- return k + e + P(e, /(\w+).+(:[^]+)/, k + "box-$1$2" + F + "flex-$1$2") + e;
741
+ return E + e + _(e, /(\w+).+(:[^]+)/, E + "box-$1$2" + F + "flex-$1$2") + e;
742
742
  // align-self
743
743
  case 5443:
744
- return k + e + F + "flex-item-" + P(e, /flex-|-self/, "") + e;
744
+ return E + e + F + "flex-item-" + _(e, /flex-|-self/, "") + e;
745
745
  // align-content
746
746
  case 4675:
747
- return k + e + F + "flex-line-pack" + P(e, /align-content|flex-|-self/, "") + e;
747
+ return E + e + F + "flex-line-pack" + _(e, /align-content|flex-|-self/, "") + e;
748
748
  // flex-shrink
749
749
  case 5548:
750
- return k + e + F + P(e, "shrink", "negative") + e;
750
+ return E + e + F + _(e, "shrink", "negative") + e;
751
751
  // flex-basis
752
752
  case 5292:
753
- return k + e + F + P(e, "basis", "preferred-size") + e;
753
+ return E + e + F + _(e, "basis", "preferred-size") + e;
754
754
  // flex-grow
755
755
  case 6060:
756
- return k + "box-" + P(e, "-grow", "") + k + e + F + P(e, "grow", "positive") + e;
756
+ return E + "box-" + _(e, "-grow", "") + E + e + F + _(e, "grow", "positive") + e;
757
757
  // transition
758
758
  case 4554:
759
- return k + P(e, /([^-])(transform)/g, "$1" + k + "$2") + e;
759
+ return E + _(e, /([^-])(transform)/g, "$1" + E + "$2") + e;
760
760
  // cursor
761
761
  case 6187:
762
- return P(P(P(e, /(zoom-|grab)/, k + "$1"), /(image-set)/, k + "$1"), e, "") + e;
762
+ return _(_(_(e, /(zoom-|grab)/, E + "$1"), /(image-set)/, E + "$1"), e, "") + e;
763
763
  // background, background-image
764
764
  case 5495:
765
765
  case 3959:
766
- return P(e, /(image-set\([^]*)/, k + "$1$`$1");
766
+ return _(e, /(image-set\([^]*)/, E + "$1$`$1");
767
767
  // justify-content
768
768
  case 4968:
769
- return P(P(e, /(.+:)(flex-)?(.*)/, k + "box-pack:$3" + F + "flex-pack:$3"), /s.+-b[^;]+/, "justify") + k + e + e;
769
+ return _(_(e, /(.+:)(flex-)?(.*)/, E + "box-pack:$3" + F + "flex-pack:$3"), /s.+-b[^;]+/, "justify") + E + e + e;
770
770
  // (margin|padding)-inline-(start|end)
771
771
  case 4095:
772
772
  case 3583:
773
773
  case 4068:
774
774
  case 2532:
775
- return P(e, /(.+)-inline(.+)/, k + "$1$2") + e;
775
+ return _(e, /(.+)-inline(.+)/, E + "$1$2") + e;
776
776
  // (min|max)?(width|height|inline-size|block-size)
777
777
  case 8116:
778
778
  case 7059:
@@ -792,10 +792,10 @@ function lt(e, t) {
792
792
  if ($(e, t + 4) !== 45) break;
793
793
  // (f)ill-available, (f)it-content
794
794
  case 102:
795
- return P(e, /(.+:)(.+)-([^]+)/, "$1" + k + "$2-$3$1" + we + ($(e, t + 3) == 108 ? "$3" : "$2-$3")) + e;
795
+ return _(e, /(.+:)(.+)-([^]+)/, "$1" + E + "$2-$3$1" + we + ($(e, t + 3) == 108 ? "$3" : "$2-$3")) + e;
796
796
  // (s)tretch
797
797
  case 115:
798
- return ~je(e, "stretch") ? lt(P(e, "stretch", "fill-available"), t) + e : e;
798
+ return ~je(e, "stretch") ? lt(_(e, "stretch", "fill-available"), t) + e : e;
799
799
  }
800
800
  break;
801
801
  // position: sticky
@@ -806,10 +806,10 @@ function lt(e, t) {
806
806
  switch ($(e, W(e) - 3 - (~je(e, "!important") && 10))) {
807
807
  // stic(k)y
808
808
  case 107:
809
- return P(e, ":", ":" + k) + e;
809
+ return _(e, ":", ":" + E) + e;
810
810
  // (inline-)?fl(e)x
811
811
  case 101:
812
- return P(e, /(.+:)([^;!]+)(;|!.+)?/, "$1" + k + ($(e, 14) === 45 ? "inline-" : "") + "box$3$1" + k + "$2$3$1" + F + "$2box$3") + e;
812
+ return _(e, /(.+:)([^;!]+)(;|!.+)?/, "$1" + E + ($(e, 14) === 45 ? "inline-" : "") + "box$3$1" + E + "$2$3$1" + F + "$2box$3") + e;
813
813
  }
814
814
  break;
815
815
  // writing-mode
@@ -817,15 +817,15 @@ function lt(e, t) {
817
817
  switch ($(e, t + 11)) {
818
818
  // vertical-l(r)
819
819
  case 114:
820
- return k + e + F + P(e, /[svh]\w+-[tblr]{2}/, "tb") + e;
820
+ return E + e + F + _(e, /[svh]\w+-[tblr]{2}/, "tb") + e;
821
821
  // vertical-r(l)
822
822
  case 108:
823
- return k + e + F + P(e, /[svh]\w+-[tblr]{2}/, "tb-rl") + e;
823
+ return E + e + F + _(e, /[svh]\w+-[tblr]{2}/, "tb-rl") + e;
824
824
  // horizontal(-)tb
825
825
  case 45:
826
- return k + e + F + P(e, /[svh]\w+-[tblr]{2}/, "lr") + e;
826
+ return E + e + F + _(e, /[svh]\w+-[tblr]{2}/, "lr") + e;
827
827
  }
828
- return k + e + F + e + e;
828
+ return E + e + F + e + e;
829
829
  }
830
830
  return e;
831
831
  }
@@ -836,7 +836,7 @@ var Ht = function(t, r, n, a) {
836
836
  break;
837
837
  case nt:
838
838
  return te([le(t, {
839
- value: P(t.value, "@", "@" + k)
839
+ value: _(t.value, "@", "@" + E)
840
840
  })], a);
841
841
  case Le:
842
842
  if (t.length) return Ct(t.props, function(i) {
@@ -845,16 +845,16 @@ var Ht = function(t, r, n, a) {
845
845
  case ":read-only":
846
846
  case ":read-write":
847
847
  return te([le(t, {
848
- props: [P(i, /:(read-\w+)/, ":" + we + "$1")]
848
+ props: [_(i, /:(read-\w+)/, ":" + we + "$1")]
849
849
  })], a);
850
850
  // :placeholder
851
851
  case "::placeholder":
852
852
  return te([le(t, {
853
- props: [P(i, /:(plac\w+)/, ":" + k + "input-$1")]
853
+ props: [_(i, /:(plac\w+)/, ":" + E + "input-$1")]
854
854
  }), le(t, {
855
- props: [P(i, /:(plac\w+)/, ":" + we + "$1")]
855
+ props: [_(i, /:(plac\w+)/, ":" + we + "$1")]
856
856
  }), le(t, {
857
- props: [P(i, /:(plac\w+)/, F + "input-$1")]
857
+ props: [_(i, /:(plac\w+)/, F + "input-$1")]
858
858
  })], a);
859
859
  }
860
860
  return "";
@@ -882,16 +882,16 @@ var Ht = function(t, r, n, a) {
882
882
  );
883
883
  var u, m = [Yt, qt];
884
884
  {
885
- var l, f = [Mt, zt(function(d) {
885
+ var l, p = [Mt, zt(function(d) {
886
886
  l.insert(d);
887
- })], g = Bt(m.concat(a, f)), w = function(h) {
887
+ })], g = Bt(m.concat(a, p)), k = function(h) {
888
888
  return te(Ft(h), g);
889
889
  };
890
- u = function(h, y, v, S) {
891
- l = v, w(h ? h + "{" + y.styles + "}" : y.styles), S && (b.inserted[y.name] = !0);
890
+ u = function(h, y, w, S) {
891
+ l = w, k(h ? h + "{" + y.styles + "}" : y.styles), S && (v.inserted[y.name] = !0);
892
892
  };
893
893
  }
894
- var b = {
894
+ var v = {
895
895
  key: r,
896
896
  sheet: new Pt({
897
897
  key: r,
@@ -906,7 +906,7 @@ var Ht = function(t, r, n, a) {
906
906
  registered: {},
907
907
  insert: u
908
908
  };
909
- return b.sheet.hydrate(c), b;
909
+ return v.sheet.hydrate(c), v;
910
910
  }, Kt = !0;
911
911
  function Jt(e, t, r) {
912
912
  var n = "";
@@ -1068,8 +1068,8 @@ function fe(e, t, r) {
1068
1068
  var l = r;
1069
1069
  if (t == null)
1070
1070
  return l;
1071
- var f = t[l];
1072
- return f !== void 0 ? f : l;
1071
+ var p = t[l];
1072
+ return p !== void 0 ? p : l;
1073
1073
  }
1074
1074
  function nr(e, t, r) {
1075
1075
  var n = "";
@@ -1121,9 +1121,9 @@ function ar(e, t, r) {
1121
1121
  Ke.lastIndex = 0;
1122
1122
  for (var m = "", l; (l = Ke.exec(a)) !== null; )
1123
1123
  m += "-" + l[1];
1124
- var f = Qt(a) + m;
1124
+ var p = Qt(a) + m;
1125
1125
  return {
1126
- name: f,
1126
+ name: p,
1127
1127
  styles: a,
1128
1128
  next: Y
1129
1129
  };
@@ -1178,44 +1178,44 @@ var cr = function(t) {
1178
1178
  r !== void 0 && (i = r.label, s = r.target);
1179
1179
  var c = Ze(t, r, n), u = c || Je(a), m = !u("as");
1180
1180
  return function() {
1181
- var l = arguments, f = n && t.__emotion_styles !== void 0 ? t.__emotion_styles.slice(0) : [];
1182
- if (i !== void 0 && f.push("label:" + i + ";"), l[0] == null || l[0].raw === void 0)
1183
- f.push.apply(f, l);
1181
+ var l = arguments, p = n && t.__emotion_styles !== void 0 ? t.__emotion_styles.slice(0) : [];
1182
+ if (i !== void 0 && p.push("label:" + i + ";"), l[0] == null || l[0].raw === void 0)
1183
+ p.push.apply(p, l);
1184
1184
  else {
1185
1185
  var g = l[0];
1186
- f.push(g[0]);
1187
- for (var w = l.length, b = 1; b < w; b++)
1188
- f.push(l[b], g[b]);
1186
+ p.push(g[0]);
1187
+ for (var k = l.length, v = 1; v < k; v++)
1188
+ p.push(l[v], g[v]);
1189
1189
  }
1190
- var d = cr(function(h, y, v) {
1191
- var S = m && h.as || a, E = "", R = [], _ = h;
1190
+ var d = cr(function(h, y, w) {
1191
+ var S = m && h.as || a, A = "", R = [], T = h;
1192
1192
  if (h.theme == null) {
1193
- _ = {};
1194
- for (var p in h)
1195
- _[p] = h[p];
1196
- _.theme = H.useContext(lr);
1193
+ T = {};
1194
+ for (var f in h)
1195
+ T[f] = h[f];
1196
+ T.theme = H.useContext(lr);
1197
1197
  }
1198
- typeof h.className == "string" ? E = Jt(y.registered, R, h.className) : h.className != null && (E = h.className + " ");
1199
- var C = ar(f.concat(R), y.registered, _);
1200
- E += y.key + "-" + C.name, s !== void 0 && (E += " " + s);
1201
- var B = m && c === void 0 ? Je(S) : u, T = {};
1202
- for (var I in h)
1203
- m && I === "as" || B(I) && (T[I] = h[I]);
1204
- return T.className = E, v && (T.ref = v), /* @__PURE__ */ H.createElement(H.Fragment, null, /* @__PURE__ */ H.createElement(hr, {
1198
+ typeof h.className == "string" ? A = Jt(y.registered, R, h.className) : h.className != null && (A = h.className + " ");
1199
+ var P = ar(p.concat(R), y.registered, T);
1200
+ A += y.key + "-" + P.name, s !== void 0 && (A += " " + s);
1201
+ var V = m && c === void 0 ? Je(S) : u, x = {};
1202
+ for (var C in h)
1203
+ m && C === "as" || V(C) && (x[C] = h[C]);
1204
+ return x.className = A, w && (x.ref = w), /* @__PURE__ */ H.createElement(H.Fragment, null, /* @__PURE__ */ H.createElement(hr, {
1205
1205
  cache: y,
1206
- serialized: C,
1206
+ serialized: P,
1207
1207
  isStringTag: typeof S == "string"
1208
- }), /* @__PURE__ */ H.createElement(S, T));
1208
+ }), /* @__PURE__ */ H.createElement(S, x));
1209
1209
  });
1210
- return d.displayName = i !== void 0 ? i : "Styled(" + (typeof a == "string" ? a : a.displayName || a.name || "Component") + ")", d.defaultProps = t.defaultProps, d.__emotion_real = d, d.__emotion_base = a, d.__emotion_styles = f, d.__emotion_forwardProp = c, Object.defineProperty(d, "toString", {
1210
+ return d.displayName = i !== void 0 ? i : "Styled(" + (typeof a == "string" ? a : a.displayName || a.name || "Component") + ")", d.defaultProps = t.defaultProps, d.__emotion_real = d, d.__emotion_base = a, d.__emotion_styles = p, d.__emotion_forwardProp = c, Object.defineProperty(d, "toString", {
1211
1211
  value: function() {
1212
1212
  return "." + s;
1213
1213
  }
1214
1214
  }), d.withComponent = function(h, y) {
1215
- var v = e(h, Oe({}, r, y, {
1215
+ var w = e(h, Oe({}, r, y, {
1216
1216
  shouldForwardProp: Ze(d, y, !0)
1217
1217
  }));
1218
- return v.apply(void 0, f);
1218
+ return w.apply(void 0, p);
1219
1219
  }, d;
1220
1220
  };
1221
1221
  }, yr = [
@@ -1434,16 +1434,16 @@ const gr = ne.div`
1434
1434
  width: min(70vw, 960px); /* Responsive width for desktop, capped at 960px */
1435
1435
  }
1436
1436
  `, xr = (e, t) => `https://vp-api.gjirafa.tech/api/v2/projects/${e}/videos?search=${t}`, wr = (e, t) => `https://vp-api.gjirafa.tech/api/projects/${e}/playlists/${t}/videos`, kr = (e) => `https://host.vpplayer.tech/player/${e}/vpplayer.js`, Me = (e, t) => `vp-player-${e || "default"}-${t || ""}`, Ae = /* @__PURE__ */ new Map(), Pr = (e, t) => {
1437
- const [r, n] = D(!1), [a, i] = D(null);
1437
+ const [r, n] = U(!1), [a, i] = U(null);
1438
1438
  return xe(() => {
1439
1439
  let s = null, c, u = 0;
1440
1440
  const m = 3;
1441
1441
  let l;
1442
1442
  try {
1443
1443
  l = t || kr(e || "latest");
1444
- } catch (w) {
1445
- const b = w instanceof Error ? w.message : String(w);
1446
- i(`Failed to resolve script URL: ${b}`), n(!1);
1444
+ } catch (k) {
1445
+ const v = k instanceof Error ? k.message : String(k);
1446
+ i(`Failed to resolve script URL: ${v}`), n(!1);
1447
1447
  return;
1448
1448
  }
1449
1449
  if (Ae.get(l)) {
@@ -1468,74 +1468,74 @@ const gr = ne.div`
1468
1468
  };
1469
1469
  }, [e, t]), { isLoaded: r, error: a };
1470
1470
  }, Er = {}, ye = /* @__PURE__ */ new Map(), _r = 3e4, Ce = 5, Sr = ({ projectId: e, videoId: t, playlistId: r, videoUrl: n, apiKey: a }) => {
1471
- const [i, s] = D(null), [c, u] = D(null), [m, l] = D(!1), [f, g] = D(null), w = a || (typeof Er < "u" ? "1CFC4B619E9342B6BAC4879BA8C30CF216C4BA9D3F084B11825F4AB2D5CF845E" : void 0);
1471
+ const [i, s] = U(null), [c, u] = U(null), [m, l] = U(!1), [p, g] = U(null), k = a || (typeof Er < "u" ? "1CFC4B619E9342B6BAC4879BA8C30CF216C4BA9D3F084B11825F4AB2D5CF845E" : void 0);
1472
1472
  return xe(() => {
1473
- const b = t ? `video:${t}` : r ? `playlist:${r}` : null;
1473
+ const v = t ? `video:${t}` : r ? `playlist:${r}` : null;
1474
1474
  if (!e || n || !t && !r) {
1475
1475
  s(n || null), u(null), l(!1), g(null);
1476
1476
  return;
1477
1477
  }
1478
- if (!w) {
1478
+ if (!k) {
1479
1479
  l(!1), g("No API key provided");
1480
1480
  return;
1481
1481
  }
1482
- if (b && ye.has(b)) {
1483
- const E = ye.get(b);
1484
- s(E.url), u(E.playlist), l(!1), g(null);
1482
+ if (v && ye.has(v)) {
1483
+ const A = ye.get(v);
1484
+ s(A.url), u(A.playlist), l(!1), g(null);
1485
1485
  return;
1486
1486
  }
1487
1487
  let d = !0;
1488
1488
  const h = new AbortController(), y = h.signal, S = setTimeout(async () => {
1489
- var R, _;
1489
+ var R, T;
1490
1490
  if (!d)
1491
1491
  return;
1492
1492
  l(!0), g(null);
1493
- let E = 0;
1494
- for (; E < Ce && d; )
1493
+ let A = 0;
1494
+ for (; A < Ce && d; )
1495
1495
  try {
1496
- const p = t && !r ? xr(e, t) : wr(e, r), C = setTimeout(() => h.abort(), _r), B = await fetch(p, {
1496
+ const f = t && !r ? xr(e, t) : wr(e, r), P = setTimeout(() => h.abort(), _r), V = await fetch(f, {
1497
1497
  method: "GET",
1498
1498
  headers: {
1499
- "api-key": w,
1499
+ "api-key": k,
1500
1500
  Accept: "application/json",
1501
1501
  "Cache-Control": "no-cache"
1502
1502
  // Prevent caching issues
1503
1503
  },
1504
1504
  signal: y
1505
1505
  });
1506
- if (clearTimeout(C), !B.ok)
1507
- throw new Error(`Fetch failed with status ${B.status}`);
1508
- const T = await B.json();
1506
+ if (clearTimeout(P), !V.ok)
1507
+ throw new Error(`Fetch failed with status ${V.status}`);
1508
+ const x = await V.json();
1509
1509
  if (!d)
1510
1510
  return;
1511
1511
  if (t && !r) {
1512
- const I = (_ = (R = T.result) == null ? void 0 : R.items) == null ? void 0 : _.find((G) => G.mediaId === t);
1513
- if (!(I != null && I.playbackUrl))
1512
+ const C = (T = (R = x.result) == null ? void 0 : R.items) == null ? void 0 : T.find((G) => G.mediaId === t);
1513
+ if (!(C != null && C.playbackUrl))
1514
1514
  throw new Error("Invalid video data");
1515
- s(I.playbackUrl), u(null), b && ye.set(b, { url: I.playbackUrl, playlist: null });
1515
+ s(C.playbackUrl), u(null), v && ye.set(v, { url: C.playbackUrl, playlist: null });
1516
1516
  } else {
1517
- if (!Array.isArray(T.result))
1517
+ if (!Array.isArray(x.result))
1518
1518
  throw new Error("Invalid playlist format");
1519
- u(T.result), s(null), b && ye.set(b, { url: null, playlist: T.result });
1519
+ u(x.result), s(null), v && ye.set(v, { url: null, playlist: x.result });
1520
1520
  }
1521
1521
  break;
1522
- } catch (p) {
1522
+ } catch (f) {
1523
1523
  if (y.aborted) {
1524
1524
  d && g("Request timed out");
1525
1525
  break;
1526
1526
  }
1527
- if (E++, E >= Ce) {
1528
- const C = p instanceof Error ? p.message : String(p);
1529
- d && g(`Failed after ${Ce} attempts: ${C}`);
1527
+ if (A++, A >= Ce) {
1528
+ const P = f instanceof Error ? f.message : String(f);
1529
+ d && g(`Failed after ${Ce} attempts: ${P}`);
1530
1530
  } else
1531
- await new Promise((C) => setTimeout(C, 2e3));
1531
+ await new Promise((P) => setTimeout(P, 2e3));
1532
1532
  }
1533
1533
  d && l(!1);
1534
1534
  }, 100);
1535
1535
  return () => {
1536
1536
  d = !1, clearTimeout(S), h.abort();
1537
1537
  };
1538
- }, [w, e, t, r, n]), { fetchedPlaybackUrl: i, fetchedPlaylist: c, isLoading: m, error: f };
1538
+ }, [k, e, t, r, n]), { fetchedPlaybackUrl: i, fetchedPlaylist: c, isLoading: m, error: p };
1539
1539
  }, Rr = {
1540
1540
  projectId: "vp-player-projectId",
1541
1541
  video: {
@@ -1599,7 +1599,7 @@ const gr = ne.div`
1599
1599
  isVerticalPlayer: i
1600
1600
  // Distinguish between VP Player types
1601
1601
  }) => {
1602
- var l, f, g, w, b, d, h, y;
1602
+ var l, p, g, k, v, d, h, y, w, S, A, R, T, f;
1603
1603
  const s = { ...Rr, ...a }, c = { ...s.config, ...a.config };
1604
1604
  if (e)
1605
1605
  return {
@@ -1622,57 +1622,59 @@ const gr = ne.div`
1622
1622
  config: c
1623
1623
  };
1624
1624
  if (r && r.length > 0) {
1625
- const v = ((f = (l = a == null ? void 0 : a.video) == null ? void 0 : l.playlist) == null ? void 0 : f.playlistVideoIndex) ?? ((g = a == null ? void 0 : a.config) == null ? void 0 : g.playlistVideoIndex) ?? 0;
1626
- if (i) {
1627
- const S = Math.min(Number(v), r.length - 1), E = ((w = r[S]) == null ? void 0 : w.hlsUrl) ?? void 0;
1628
- return {
1629
- ...s,
1630
- projectId: n || "vp-player-projectId",
1631
- video: {
1632
- ...s.video,
1633
- // Set the correct video file for the desired index
1634
- file: E,
1635
- playlist: {
1636
- state: !0,
1637
- playlistId: "",
1638
- // Will be set by API
1639
- // IMPORTANT: Based on docs, here should be an int, but we use string, cause it works
1640
- // TODO: this should require some added work in the future
1641
- playlistVideoIndex: String(v),
1642
- videos: r.map((_, p) => ({
1643
- videoId: String(p),
1644
- title: _.title,
1645
- file: _.hlsUrl,
1646
- thumbnailUrl: _.thumbnailUrl,
1647
- duration: _.duration
1648
- }))
1649
- }
1650
- },
1651
- config: c
1652
- };
1653
- } else
1654
- return {
1655
- ...s,
1656
- projectId: n || "vp-player-projectId",
1657
- video: {
1658
- ...s.video,
1659
- file: ((b = r[Number(v)]) == null ? void 0 : b.hlsUrl) || ((d = r[0]) == null ? void 0 : d.hlsUrl) || "",
1660
- playlist: {
1661
- state: !0,
1662
- playlistVideoIndex: String(v),
1663
- videos: r.map((E, R) => ({
1664
- videoId: String(R),
1665
- title: E.title,
1666
- file: E.hlsUrl,
1667
- thumbnailUrl: E.thumbnailUrl,
1668
- duration: E.duration
1669
- }))
1670
- }
1671
- },
1672
- config: c
1673
- };
1625
+ const P = ((p = (l = a == null ? void 0 : a.video) == null ? void 0 : l.playlist) == null ? void 0 : p.playlistVideoIndex) ?? ((g = a == null ? void 0 : a.config) == null ? void 0 : g.playlistVideoIndex) ?? 0;
1626
+ return i ? {
1627
+ ...s,
1628
+ projectId: n || "vp-player-projectId",
1629
+ video: {
1630
+ ...s.video,
1631
+ // Set first video file (index 0) to avoid VP Player duplication
1632
+ file: (k = r[0]) == null ? void 0 : k.hlsUrl,
1633
+ title: (v = r[0]) == null ? void 0 : v.title,
1634
+ thumbnail: (d = r[0]) == null ? void 0 : d.thumbnailUrl,
1635
+ playlist: {
1636
+ state: !0,
1637
+ playlistId: "",
1638
+ // Will be set by API
1639
+ // Use original playlistVideoIndex - VP Player will navigate to it
1640
+ playlistVideoIndex: Number(P),
1641
+ // Remove first video from playlist to avoid duplication (already in file)
1642
+ videos: r.slice(1).map((x, C) => ({
1643
+ videoId: String(C + 1),
1644
+ // Keep original IDs
1645
+ title: x.title,
1646
+ file: x.hlsUrl,
1647
+ thumbnailUrl: x.thumbnailUrl,
1648
+ duration: x.duration
1649
+ }))
1650
+ }
1651
+ },
1652
+ config: c
1653
+ } : {
1654
+ ...s,
1655
+ projectId: n || "vp-player-projectId",
1656
+ video: {
1657
+ ...s.video,
1658
+ file: ((h = r[Number(P)]) == null ? void 0 : h.hlsUrl) || ((y = r[0]) == null ? void 0 : y.hlsUrl) || "",
1659
+ title: ((w = r[Number(P)]) == null ? void 0 : w.title) || ((S = r[0]) == null ? void 0 : S.title),
1660
+ thumbnail: ((A = r[Number(P)]) == null ? void 0 : A.thumbnailUrl) || ((R = r[0]) == null ? void 0 : R.thumbnailUrl),
1661
+ playlist: {
1662
+ state: !0,
1663
+ // playlistVideoIndex: String(userPlaylistVideoIndex), this has been bug, fixed, now int
1664
+ playlistVideoIndex: Number(P),
1665
+ videos: r.map((x, C) => ({
1666
+ videoId: String(C),
1667
+ title: x.title,
1668
+ file: x.hlsUrl,
1669
+ thumbnailUrl: x.thumbnailUrl,
1670
+ duration: x.duration
1671
+ }))
1672
+ }
1673
+ },
1674
+ config: c
1675
+ };
1674
1676
  }
1675
- const u = ((h = a == null ? void 0 : a.video) == null ? void 0 : h.playlist) || s.video.playlist, m = (y = a == null ? void 0 : a.video) == null ? void 0 : y.file;
1677
+ const u = ((T = a == null ? void 0 : a.video) == null ? void 0 : T.playlist) || s.video.playlist, m = (f = a == null ? void 0 : a.video) == null ? void 0 : f.file;
1676
1678
  if (m)
1677
1679
  return {
1678
1680
  ...s,
@@ -1685,16 +1687,17 @@ const gr = ne.div`
1685
1687
  config: c
1686
1688
  };
1687
1689
  if (u != null && u.videos && u.videos.length > 0) {
1688
- const v = u.videos[Number(u.playlistVideoIndex) || 0];
1690
+ const P = u.videos[Number(u.playlistVideoIndex) || 0];
1689
1691
  return {
1690
1692
  ...s,
1691
1693
  video: {
1692
1694
  ...s.video,
1693
- file: (v == null ? void 0 : v.file) || "",
1695
+ file: (P == null ? void 0 : P.file) || "",
1694
1696
  playlist: {
1695
1697
  ...u,
1696
1698
  state: u.state ?? !0,
1697
- playlistVideoIndex: u.playlistVideoIndex ?? 0,
1699
+ // playlistVideoIndex: playlist.playlistVideoIndex ?? 0, this has been bug, fixed, now int
1700
+ playlistVideoIndex: Number(u.playlistVideoIndex || 0),
1698
1701
  videos: u.videos
1699
1702
  }
1700
1703
  },
@@ -1711,44 +1714,44 @@ const gr = ne.div`
1711
1714
  const t = /https:\/\/host\.vpplayer\.tech\/player\/([^/]+)\/([^/]+)(?:\/[^/]+)?\.js/, r = e.match(t);
1712
1715
  return r ? r[2] : void 0;
1713
1716
  }, Cr = ({ playerId: e, videoId: t, version: r, videoUrl: n, projectId: a, playlistId: i, scriptUrl: s, config: c = {}, apiKey: u, isReels: m = !1 }) => {
1714
- const l = Be(null), f = Be(null), { isLoaded: g, error: w } = Pr(r, s), b = t || Ar(s), [d, h] = D(null), { fetchedPlaybackUrl: y, fetchedPlaylist: v, isLoading: S, error: E } = Sr({
1717
+ const l = Be(null), p = Be(null), { isLoaded: g, error: k } = Pr(r, s), v = t || Ar(s), [d, h] = U(null), { fetchedPlaybackUrl: y, fetchedPlaylist: w, isLoading: S, error: A } = Sr({
1715
1718
  projectId: a,
1716
- videoId: b,
1719
+ videoId: v,
1717
1720
  playlistId: i,
1718
1721
  videoUrl: n,
1719
1722
  apiKey: u
1720
- }), R = Me(e, b), _ = tt(() => {
1721
- const p = c.config || {}, C = m && !p.size ? { sizeType: "RESPONSIVE", aspectRatio: "9:16" } : p.size || { sizeType: "FIXED", width: "100%" };
1723
+ }), R = Me(e, v), T = tt(() => {
1724
+ const f = c.config || {}, P = m && !f.size ? { sizeType: "RESPONSIVE", aspectRatio: "9:16" } : f.size || { sizeType: "FIXED", width: "100%" };
1722
1725
  return {
1723
1726
  ...c,
1724
1727
  config: {
1725
- ...p,
1726
- size: C
1728
+ ...f,
1729
+ size: P
1727
1730
  }
1728
1731
  };
1729
1732
  }, [c, m]);
1730
1733
  return xe(() => {
1731
- if (w) {
1732
- h(w);
1734
+ if (k) {
1735
+ h(k);
1733
1736
  return;
1734
1737
  }
1735
1738
  if (!g || S && !n)
1736
1739
  return;
1737
- let p = !0;
1738
- const B = setTimeout(async () => {
1740
+ let f = !0;
1741
+ const V = setTimeout(async () => {
1739
1742
  try {
1740
- const T = s == null ? void 0 : s.includes("vertical-player");
1743
+ const x = s == null ? void 0 : s.includes("vertical-player");
1741
1744
  if (document.querySelectorAll('[id*="player"]').forEach((Q) => {
1742
1745
  var ie, oe;
1743
1746
  const J = Q.id;
1744
1747
  if (J !== R)
1745
1748
  try {
1746
- const o = T ? (ie = window.vpVerticalPlayer) == null ? void 0 : ie.call(window, J) : (oe = window.vpPlayer) == null ? void 0 : oe.call(window, J);
1749
+ const o = x ? (ie = window.vpVerticalPlayer) == null ? void 0 : ie.call(window, J) : (oe = window.vpPlayer) == null ? void 0 : oe.call(window, J);
1747
1750
  o != null && o.destroy && o.destroy();
1748
1751
  } catch (o) {
1749
1752
  console.warn(`Failed to destroy existing player ${J}:`, o);
1750
1753
  }
1751
- }), await new Promise((Q) => setTimeout(Q, 100)), !p || !l.current)
1754
+ }), await new Promise((Q) => setTimeout(Q, 100)), !f || !l.current)
1752
1755
  return;
1753
1756
  if (!document.getElementById(R)) {
1754
1757
  h("DOM element not found after cleanup.");
@@ -1758,67 +1761,67 @@ const gr = ne.div`
1758
1761
  h("VP Player script not loaded.");
1759
1762
  return;
1760
1763
  }
1761
- const z = T ? window.vpVerticalPlayer : window.vpPlayer;
1764
+ const z = x ? window.vpVerticalPlayer : window.vpPlayer;
1762
1765
  if (!z) {
1763
- h(`VP ${T ? "Vertical " : ""}Player script not loaded.`);
1766
+ h(`VP ${x ? "Vertical " : ""}Player script not loaded.`);
1764
1767
  return;
1765
1768
  }
1766
1769
  const X = Tr({
1767
1770
  videoUrl: n,
1768
1771
  fetchedPlaybackUrl: y ?? void 0,
1769
- fetchedPlaylist: v ?? void 0,
1772
+ fetchedPlaylist: w ?? void 0,
1770
1773
  projectId: a,
1771
- config: _,
1772
- isVerticalPlayer: T
1774
+ config: T,
1775
+ isVerticalPlayer: x
1773
1776
  // Pass player type to config builder
1774
1777
  }), Z = z(R);
1775
1778
  if (!Z) {
1776
- h(`Failed to create VP ${T ? "Vertical " : ""}Player instance.`);
1779
+ h(`Failed to create VP ${x ? "Vertical " : ""}Player instance.`);
1777
1780
  return;
1778
1781
  }
1779
- p && l.current && (Z.setup(X), f.current = Z, h(null));
1780
- } catch (T) {
1781
- if (p) {
1782
- const I = T instanceof Error ? T.message : String(T);
1783
- h(I), console.error("VP Player initialization error:", T);
1782
+ f && l.current && (Z.setup(X), p.current = Z, h(null));
1783
+ } catch (x) {
1784
+ if (f) {
1785
+ const C = x instanceof Error ? x.message : String(x);
1786
+ h(C), console.error("VP Player initialization error:", x);
1784
1787
  }
1785
1788
  }
1786
1789
  }, 150);
1787
1790
  return () => {
1788
- p = !1, clearTimeout(B);
1791
+ f = !1, clearTimeout(V);
1789
1792
  };
1790
1793
  }, [
1791
1794
  g,
1792
1795
  S,
1793
1796
  n,
1794
1797
  y,
1795
- v,
1798
+ w,
1796
1799
  a,
1797
- _,
1800
+ T,
1798
1801
  R,
1799
- w,
1802
+ k,
1800
1803
  s
1801
1804
  ]), xe(() => () => {
1802
- if (f.current) {
1805
+ if (p.current) {
1803
1806
  try {
1804
- f.current.destroy && f.current.destroy();
1805
- } catch (C) {
1806
- console.warn(`Failed to destroy player ${R}:`, C);
1807
+ p.current.destroy && p.current.destroy();
1808
+ } catch (P) {
1809
+ console.warn(`Failed to destroy player ${R}:`, P);
1807
1810
  }
1808
- f.current = null;
1811
+ p.current = null;
1809
1812
  }
1810
- const p = document.getElementById(R);
1811
- p && (p.innerHTML = "");
1813
+ const f = document.getElementById(R);
1814
+ f && (f.innerHTML = "");
1812
1815
  }, [R]), {
1813
1816
  playerRef: l,
1814
- playerInstanceRef: f,
1817
+ playerInstanceRef: p,
1815
1818
  isScriptLoaded: g,
1816
1819
  isLoading: S,
1817
- error: E || d || w
1820
+ error: A || d || k
1818
1821
  };
1819
- }, Ir = ({ playerId: e, videoId: t, version: r, videoUrl: n, projectId: a, playlistId: i, scriptUrl: s, config: c = {}, apiKey: u, isReels: m = !1, hiddenClasses: l = [], onClose: f, className: g }) => {
1820
- var B, T, I, G;
1821
- const { playerRef: w, playerInstanceRef: b, isScriptLoaded: d, isLoading: h, error: y } = Cr({
1822
+ }, Ir = ({ playerId: e, videoId: t, version: r, videoUrl: n, projectId: a, playlistId: i, scriptUrl: s, config: c = {}, apiKey: u, isReels: m = !1, hiddenClasses: l = [], onClose: p, className: g }) => {
1823
+ var V, x, C, G;
1824
+ const { playerRef: k, playerInstanceRef: v, isScriptLoaded: d, isLoading: h, error: y } = Cr({
1822
1825
  playerId: e,
1823
1826
  videoId: t,
1824
1827
  version: r,
@@ -1829,16 +1832,16 @@ const gr = ne.div`
1829
1832
  config: c,
1830
1833
  apiKey: u,
1831
1834
  isReels: m
1832
- }), [v, S] = D(!0), E = () => m && S(!0), R = () => {
1835
+ }), [w, S] = U(!0), A = () => m && S(!0), R = () => {
1833
1836
  var z, X;
1834
- S(!1), (X = (z = b.current) == null ? void 0 : z.play) == null || X.call(z), f == null || f();
1835
- }, _ = (T = (B = c == null ? void 0 : c.config) == null ? void 0 : B.size) != null && T.width ? typeof c.config.size.width == "number" ? `${c.config.size.width}px` : c.config.size.width : void 0, p = (G = (I = c == null ? void 0 : c.config) == null ? void 0 : I.size) != null && G.height ? typeof c.config.size.height == "number" ? `${c.config.size.height}px` : c.config.size.height : void 0, C = Me(e, t);
1836
- return y ? j.jsxs(Ne, { type: "error", children: ["An error occurred: ", y] }) : h || !d ? j.jsx(Ne, { type: "loading", children: "Loading..." }) : j.jsxs(j.Fragment, { children: [m && !v ? j.jsx("div", { onClick: E }) : null, !m && j.jsx("div", { children: j.jsx(Qe, { id: C, ref: w, width: _ || "100%", height: p || "auto", $hiddenClasses: l, className: g }) }, C), m && v && j.jsx(vr, { onClick: R, className: g, children: j.jsx(br, { className: g, onClick: (z) => z.stopPropagation(), children: j.jsx("div", { children: j.jsx(Qe, { id: C, ref: w, width: "100%", height: "auto", $hiddenClasses: l, className: g }) }, C) }) })] });
1837
+ S(!1), (X = (z = v.current) == null ? void 0 : z.play) == null || X.call(z), p == null || p();
1838
+ }, T = (x = (V = c == null ? void 0 : c.config) == null ? void 0 : V.size) != null && x.width ? typeof c.config.size.width == "number" ? `${c.config.size.width}px` : c.config.size.width : void 0, f = (G = (C = c == null ? void 0 : c.config) == null ? void 0 : C.size) != null && G.height ? typeof c.config.size.height == "number" ? `${c.config.size.height}px` : c.config.size.height : void 0, P = Me(e, t);
1839
+ return y ? j.jsxs(Ne, { type: "error", children: ["An error occurred: ", y] }) : h || !d ? j.jsx(Ne, { type: "loading", children: "Loading..." }) : j.jsxs(j.Fragment, { children: [m && !w ? j.jsx("div", { onClick: A }) : null, !m && j.jsx("div", { children: j.jsx(Qe, { id: P, ref: k, width: T || "100%", height: f || "auto", $hiddenClasses: l, className: g }) }, P), m && w && j.jsx(vr, { onClick: R, className: g, children: j.jsx(br, { className: g, onClick: (z) => z.stopPropagation(), children: j.jsx("div", { children: j.jsx(Qe, { id: P, ref: k, width: "100%", height: "auto", $hiddenClasses: l, className: g }) }, P) }) })] });
1837
1840
  }, pt = gt(void 0), jr = ({ children: e }) => {
1838
- const [t, r] = D(!1), [n, a] = D(null), [i, s] = D(null), c = ze((l) => {
1841
+ const [t, r] = U(!1), [n, a] = U(null), [i, s] = U(null), c = ze((l) => {
1839
1842
  try {
1840
- const f = Me(l.playerId, l.videoId);
1841
- a({ ...l, playerId: f }), r(!0), s(null);
1843
+ const p = Me(l.playerId, l.videoId);
1844
+ a({ ...l, playerId: p }), r(!0), s(null);
1842
1845
  } catch {
1843
1846
  s("Failed to show player.");
1844
1847
  }
@@ -1929,14 +1932,14 @@ const gr = ne.div`
1929
1932
  }
1930
1933
  }
1931
1934
  };
1932
- }, Mr = "http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/BigBuckBunny.mp4", Br = "http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/ElephantsDream.mp4", zr = "https://videos.pexels.com/video-files/4678261/4678261-hd_1080_1920_25fps.mp4", Dr = "https://images.pexels.com/videos/4678261/pexels-photo-4678261.jpeg?auto=compress&cs=tinysrgb&w=600", Ur = "https://pubads.g.doubleclick.net/gampad/ads?sz=640x480&iu=/124319096/external/single_ad_samples&ciu_szs=300x250&impl=s&gdfp_req=1&env=vp&output=vast&unviewed_position_start=1&cust_params=deployment%3Ddevsite%26sample_ct%3Dlinear&correlator=", Wr = "https://pubads.g.doubleclick.net/gampad/ads?sz=640x480&iu=/124319096/external/single_ad_samples&ciu_szs=300x250&impl=s&gdfp_req=1&env=vp&output=vast&unviewed_position_start=1&cust_params=deployment%3Ddevsite%26sample_ct%3Dskippablelinear&correlator=";
1935
+ }, Mr = "http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/BigBuckBunny.mp4", Br = "http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/ElephantsDream.mp4", zr = "https://videos.pexels.com/video-files/4678261/4678261-hd_1080_1920_25fps.mp4", Ur = "https://images.pexels.com/videos/4678261/pexels-photo-4678261.jpeg?auto=compress&cs=tinysrgb&w=600", Dr = "https://pubads.g.doubleclick.net/gampad/ads?sz=640x480&iu=/124319096/external/single_ad_samples&ciu_szs=300x250&impl=s&gdfp_req=1&env=vp&output=vast&unviewed_position_start=1&cust_params=deployment%3Ddevsite%26sample_ct%3Dlinear&correlator=", Wr = "https://pubads.g.doubleclick.net/gampad/ads?sz=640x480&iu=/124319096/external/single_ad_samples&ciu_szs=300x250&impl=s&gdfp_req=1&env=vp&output=vast&unviewed_position_start=1&cust_params=deployment%3Ddevsite%26sample_ct%3Dskippablelinear&correlator=";
1933
1936
  export {
1934
- Ur as AD_TAG_LINEAR_URL,
1937
+ Dr as AD_TAG_LINEAR_URL,
1935
1938
  Wr as AD_TAG_SKIPPABLE_LINEAR_URL,
1936
1939
  Mr as BIG_BUCK_BUNNY_URL,
1937
1940
  Br as ELEPHANTS_DREAM_URL,
1938
1941
  vr as Overlay,
1939
- Dr as PEXELS_THUMBNAIL_URL,
1942
+ Ur as PEXELS_THUMBNAIL_URL,
1940
1943
  zr as PEXELS_VERTICAL_VIDEO_URL,
1941
1944
  Qe as PlayerContainer,
1942
1945
  br as PlayerWrapper,