@streamlayer/react 1.24.5 → 1.24.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (166) hide show
  1. package/lib/cjs/advertisement.js +19607 -203
  2. package/lib/cjs/auth.js +4459 -1
  3. package/lib/cjs/bet-pack.js +15691 -1
  4. package/lib/cjs/index.js +19411 -1
  5. package/lib/cjs/insight.js +13509 -1
  6. package/lib/cjs/masters.js +20696 -1
  7. package/lib/cjs/notification.js +13087 -1
  8. package/lib/cjs/package.json +1 -0
  9. package/lib/cjs/pause-ad.js +8390 -1
  10. package/lib/cjs/points.js +7189 -1
  11. package/lib/cjs/polyfills.js +69 -0
  12. package/lib/cjs/polymarket.js +16394 -14
  13. package/lib/cjs/style.css +1 -0
  14. package/lib/cjs/useStreamLayerApp.js +4711 -1
  15. package/lib/dist/cjs/index.js +20696 -1
  16. package/lib/dist/es/index.js +20669 -10
  17. package/lib/dist/es/polyfills.js +92 -0
  18. package/lib/es/Question.js +66 -65
  19. package/lib/es/advertisement.js +3402 -3294
  20. package/lib/es/analytics.js +1 -1
  21. package/lib/es/bet-pack.js +1 -1
  22. package/lib/es/feature.js +192 -37
  23. package/lib/es/{index-DvqmgCor.js → index-D8wyDNJD.js} +1 -1
  24. package/lib/es/index.js +1 -1
  25. package/lib/es/index10.js +181 -7
  26. package/lib/es/index11.js +371 -181
  27. package/lib/es/index12.js +366 -2579
  28. package/lib/es/index13.js +789 -234
  29. package/lib/es/index14.js +293 -792
  30. package/lib/es/index15.js +2550 -305
  31. package/lib/es/index16.js +64 -66
  32. package/lib/es/index2.js +285 -279
  33. package/lib/es/index3.js +34 -4
  34. package/lib/es/index4.js +16 -17
  35. package/lib/es/index5.js +3 -19
  36. package/lib/es/index6.js +7 -5
  37. package/lib/es/index7.js +284 -5
  38. package/lib/es/index8.js +236 -281
  39. package/lib/es/index9.js +8 -179
  40. package/lib/es/insight.js +2 -2
  41. package/lib/es/masters2.js +199 -189
  42. package/lib/es/notification.js +27 -28
  43. package/lib/es/pause-ad.js +124 -149
  44. package/lib/es/points.js +23 -24
  45. package/lib/es/polymarket.js +3 -3
  46. package/lib/es/storage.js +4 -4
  47. package/lib/es/style.css +1 -0
  48. package/lib/es/useStreamLayerApp2.js +5579 -4475
  49. package/lib/source.css +1 -120
  50. package/package.json +126 -91
  51. package/lib/cjs/Question.js +0 -1
  52. package/lib/cjs/analytics.js +0 -1
  53. package/lib/cjs/feature.js +0 -1
  54. package/lib/cjs/gamification-feature.js +0 -1
  55. package/lib/cjs/gamification-feature2.js +0 -1
  56. package/lib/cjs/hooks-n9ax4LRT.js +0 -1
  57. package/lib/cjs/index-DvqmgCor.js +0 -5
  58. package/lib/cjs/index10.js +0 -1
  59. package/lib/cjs/index11.js +0 -1
  60. package/lib/cjs/index12.js +0 -1
  61. package/lib/cjs/index13.js +0 -1
  62. package/lib/cjs/index14.js +0 -4
  63. package/lib/cjs/index15.js +0 -1
  64. package/lib/cjs/index16.js +0 -5
  65. package/lib/cjs/index2.js +0 -1
  66. package/lib/cjs/index3.js +0 -1
  67. package/lib/cjs/index4.js +0 -5
  68. package/lib/cjs/index5.js +0 -1
  69. package/lib/cjs/index6.js +0 -1
  70. package/lib/cjs/index7.js +0 -1
  71. package/lib/cjs/index8.js +0 -1
  72. package/lib/cjs/index9.js +0 -7
  73. package/lib/cjs/masters2.js +0 -8
  74. package/lib/cjs/sl-types.js +0 -1
  75. package/lib/cjs/storage.js +0 -1
  76. package/lib/cjs/theme.js +0 -1
  77. package/lib/cjs/useStreamLayerApp2.js +0 -17
  78. package/lib/cjs/utils.js +0 -47
  79. package/lib/classic/app/advertisement.d.ts +0 -19
  80. package/lib/classic/app/app.d.ts +0 -23
  81. package/lib/classic/app/auth.d.ts +0 -4
  82. package/lib/classic/app/bet-pack.d.ts +0 -10
  83. package/lib/classic/app/insight.d.ts +0 -13
  84. package/lib/classic/app/masters.d.ts +0 -19
  85. package/lib/classic/app/notification.d.ts +0 -5
  86. package/lib/classic/app/pause-ad.d.ts +0 -27
  87. package/lib/classic/app/points.d.ts +0 -3
  88. package/lib/classic/app/polymarket.d.ts +0 -7
  89. package/lib/classic/app/useStreamLayerApp.d.ts +0 -1
  90. package/lib/classic/cjs/Question.js +0 -1
  91. package/lib/classic/cjs/advertisement.js +0 -203
  92. package/lib/classic/cjs/analytics.js +0 -1
  93. package/lib/classic/cjs/auth.js +0 -1
  94. package/lib/classic/cjs/bet-pack.js +0 -5
  95. package/lib/classic/cjs/feature.js +0 -1
  96. package/lib/classic/cjs/gamification-feature.js +0 -1
  97. package/lib/classic/cjs/hooks-n9ax4LRT.js +0 -1
  98. package/lib/classic/cjs/index-DvqmgCor.js +0 -5
  99. package/lib/classic/cjs/index.js +0 -1
  100. package/lib/classic/cjs/index10.js +0 -1
  101. package/lib/classic/cjs/index11.js +0 -1
  102. package/lib/classic/cjs/index12.js +0 -1
  103. package/lib/classic/cjs/index13.js +0 -4
  104. package/lib/classic/cjs/index2.js +0 -5
  105. package/lib/classic/cjs/index3.js +0 -1
  106. package/lib/classic/cjs/index4.js +0 -1
  107. package/lib/classic/cjs/index5.js +0 -1
  108. package/lib/classic/cjs/index6.js +0 -1
  109. package/lib/classic/cjs/index7.js +0 -7
  110. package/lib/classic/cjs/index8.js +0 -1
  111. package/lib/classic/cjs/index9.js +0 -1
  112. package/lib/classic/cjs/insight.js +0 -1
  113. package/lib/classic/cjs/notification.js +0 -1
  114. package/lib/classic/cjs/notification2.js +0 -1
  115. package/lib/classic/cjs/pause-ad.js +0 -1
  116. package/lib/classic/cjs/points.js +0 -1
  117. package/lib/classic/cjs/polymarket.js +0 -14
  118. package/lib/classic/cjs/sl-types.js +0 -1
  119. package/lib/classic/cjs/useStreamLayerApp.js +0 -1
  120. package/lib/classic/cjs/useStreamLayerApp2.js +0 -17
  121. package/lib/classic/cjs/utils.js +0 -47
  122. package/lib/classic/es/Question.js +0 -388
  123. package/lib/classic/es/advertisement.js +0 -38759
  124. package/lib/classic/es/analytics.js +0 -84
  125. package/lib/classic/es/auth.js +0 -11
  126. package/lib/classic/es/bet-pack.js +0 -3419
  127. package/lib/classic/es/feature.js +0 -59
  128. package/lib/classic/es/gamification-feature.js +0 -4
  129. package/lib/classic/es/hooks-n9ax4LRT.js +0 -97
  130. package/lib/classic/es/index-DvqmgCor.js +0 -3775
  131. package/lib/classic/es/index.js +0 -15
  132. package/lib/classic/es/index10.js +0 -2592
  133. package/lib/classic/es/index11.js +0 -317
  134. package/lib/classic/es/index12.js +0 -185
  135. package/lib/classic/es/index13.js +0 -820
  136. package/lib/classic/es/index2.js +0 -2597
  137. package/lib/classic/es/index3.js +0 -19
  138. package/lib/classic/es/index4.js +0 -6
  139. package/lib/classic/es/index5.js +0 -5
  140. package/lib/classic/es/index6.js +0 -285
  141. package/lib/classic/es/index7.js +0 -181
  142. package/lib/classic/es/index8.js +0 -7
  143. package/lib/classic/es/index9.js +0 -11
  144. package/lib/classic/es/insight.js +0 -79
  145. package/lib/classic/es/notification.js +0 -9
  146. package/lib/classic/es/notification2.js +0 -1127
  147. package/lib/classic/es/pause-ad.js +0 -257
  148. package/lib/classic/es/points.js +0 -77
  149. package/lib/classic/es/polymarket.js +0 -6617
  150. package/lib/classic/es/sl-types.js +0 -156
  151. package/lib/classic/es/useStreamLayerApp.js +0 -4
  152. package/lib/classic/es/useStreamLayerApp2.js +0 -11573
  153. package/lib/classic/es/utils.js +0 -76
  154. package/lib/classic/index.d.ts +0 -6
  155. package/lib/classic/masters.d.ts +0 -8
  156. package/lib/classic/source.css +0 -110
  157. package/lib/dist/cjs/gamification-feature.js +0 -1
  158. package/lib/dist/cjs/index-DvqmgCor.js +0 -5
  159. package/lib/dist/cjs/masters.js +0 -69
  160. package/lib/dist/es/gamification-feature.js +0 -4
  161. package/lib/dist/es/index-DvqmgCor.js +0 -3775
  162. package/lib/dist/es/masters.js +0 -22204
  163. package/lib/dist/index.d.ts +0 -1355
  164. package/lib/dist/source.css +0 -64
  165. package/lib/es/sl-types.js +0 -156
  166. package/lib/style.css +0 -1
package/lib/es/index15.js CHANGED
@@ -1,317 +1,2562 @@
1
- import { jsxs as O, jsx as e, Fragment as re } from "react/jsx-runtime";
2
- import { s as n, c as X } from "./sl-types.js";
3
- import { useState as h, useEffect as b, useCallback as A, forwardRef as le, useRef as V } from "react";
4
- import { B as f } from "./index8.js";
5
- import { G as ce, d as ue, b as ie } from "./index9.js";
6
- import { C as de } from "./useStreamLayerApp2.js";
7
- const pe = /* @__PURE__ */ n("div")({
8
- name: "CloseIconWrap",
9
- class: "c3v6bv6",
10
- propsAsIs: !1
11
- }), me = /* @__PURE__ */ n("div")({
12
- name: "TimerWrap",
13
- class: "teuhmro",
14
- propsAsIs: !1
15
- }), fe = () => f, ye = /* @__PURE__ */ n(fe())({
16
- name: "Icon",
17
- class: "i17rfxv5",
18
- propsAsIs: !0
19
- }), Xe = ({
20
- close: t,
21
- className: a,
22
- timerClassName: o,
23
- skipIcon: l,
24
- isPlaying: i = !0,
25
- duration: c = 0,
26
- autoClose: d
27
- }) => {
28
- const [p, y] = h(c === 0);
29
- b(() => {
30
- y(!c);
31
- }, [c]);
32
- const M = A(() => {
33
- d === de.ENABLED ? t?.() : y(!0);
34
- }, [d, t]);
35
- return p ? /* @__PURE__ */ O(pe, {
36
- "data-a": "intr",
37
- onClick: t,
38
- className: a,
39
- style: l ? {
40
- width: "auto"
41
- } : {},
42
- children: [l && /* @__PURE__ */ e("span", {
43
- "data-a": "intr",
44
- children: "Skip"
45
- }), /* @__PURE__ */ e(ye, {
46
- "data-a": "intr",
47
- name: l ? "iconSkip" : "icon-cross"
48
- })]
49
- }) : /* @__PURE__ */ e(me, {
50
- children: /* @__PURE__ */ e(ce, {
51
- className: o,
52
- isPlaying: i,
53
- duration: c,
54
- onTimerExpired: M
55
- })
56
- });
57
- }, ge = /* @__PURE__ */ n("div")({
58
- name: "Container",
59
- class: "c1bgb86j",
60
- propsAsIs: !1
61
- }), Ie = /* @__PURE__ */ n("video")({
62
- name: "Player",
63
- class: "p6703cq",
64
- propsAsIs: !1
65
- }), he = /* @__PURE__ */ n("img")({
66
- name: "Poster",
67
- class: "p12ow7zo",
68
- propsAsIs: !1
69
- }), T = /* @__PURE__ */ n("div")({
70
- name: "Control",
71
- class: "cdpal9o",
72
- propsAsIs: !1
73
- }), be = "t1xke4ml", Pe = "h1yzxv57", ve = /* @__PURE__ */ n("div")({
74
- name: "VideoControls",
75
- class: "vxo8xch",
76
- propsAsIs: !1
77
- }), U = /* @__PURE__ */ n("button")({
78
- name: "ControlBtn",
79
- class: "coyuzu0",
80
- propsAsIs: !1
81
- }), Ae = () => U, Me = /* @__PURE__ */ n(Ae())({
82
- name: "MuteIcon",
83
- class: "musmi9a",
84
- propsAsIs: !0
85
- }), Ce = () => U, ke = /* @__PURE__ */ n(Ce())({
86
- name: "PauseIcon",
87
- class: "p1qe7rum",
88
- propsAsIs: !0
89
- }), we = () => U, Se = /* @__PURE__ */ n(we())({
90
- name: "PlayIcon",
91
- class: "psevery",
92
- propsAsIs: !0
93
- }), Z = /* @__PURE__ */ n("button")({
94
- name: "WebOSIconButton",
95
- class: "w1q3u7py",
96
- propsAsIs: !1
97
- }), xe = () => Z, R = /* @__PURE__ */ n(xe())({
98
- name: "WebOSIconButtonAnimation",
99
- class: "wdlqvum",
100
- propsAsIs: !0
101
- }), Be = () => R, We = /* @__PURE__ */ n(Be())({
102
- name: "WebOSIconButtonPlay",
103
- class: "w1ylz9ea",
104
- propsAsIs: !0
105
- }), Ee = () => R, Ne = /* @__PURE__ */ n(Ee())({
106
- name: "WebOSIconButtonPause",
107
- class: "w1iylt55",
108
- propsAsIs: !0
109
- }), Ve = () => R, Te = /* @__PURE__ */ n(Ve())({
110
- name: "WebOSIconButtonMute",
111
- class: "w8h4h7",
112
- propsAsIs: !0
113
- }), Oe = () => R, Re = /* @__PURE__ */ n(Oe())({
114
- name: "WebOSIconButtonUnmute",
115
- class: "w12l12kt",
116
- propsAsIs: !0
117
- }), $e = (t) => {
118
- for (const a of t)
119
- a.isIntersecting ? a.target instanceof HTMLVideoElement && a.target.autoplay && a.target.play() : a.target instanceof HTMLVideoElement && !a.target.paused && a.target.pause();
120
- }, Y = new IntersectionObserver($e, { threshold: 0.5 }), H = /* @__PURE__ */ new Set(), je = (t) => {
121
- Y.observe(t), H.add(t);
122
- }, qe = (t) => {
123
- Y.unobserve(t), H.delete(t);
124
- }, ze = () => {
125
- for (const t of H)
126
- t instanceof HTMLVideoElement && !t.paused && t.pause();
127
- };
128
- function Fe(...t) {
129
- return A(
130
- // eslint-disable-next-line @typescript-eslint/no-explicit-any
131
- (a) => {
132
- for (const o of t)
133
- o !== null && (typeof o == "function" ? o(a) : o && (o.current = a));
134
- },
135
- // Re-run the callback if the array of refs changes
136
- // eslint-disable-next-line react-hooks/exhaustive-deps
137
- [...t]
1
+ import { c as Oe } from "./index3.js";
2
+ import Au from "react";
3
+ var Ke = { exports: {} }, Ne, ra;
4
+ function le() {
5
+ if (ra) return Ne;
6
+ ra = 1;
7
+ function r(e) {
8
+ var t = typeof e;
9
+ return e != null && (t == "object" || t == "function");
10
+ }
11
+ return Ne = r, Ne;
12
+ }
13
+ var Be, ta;
14
+ function nu() {
15
+ if (ta) return Be;
16
+ ta = 1;
17
+ var r = typeof Oe == "object" && Oe && Oe.Object === Object && Oe;
18
+ return Be = r, Be;
19
+ }
20
+ var je, na;
21
+ function ie() {
22
+ if (na) return je;
23
+ na = 1;
24
+ var r = nu(), e = typeof self == "object" && self && self.Object === Object && self, t = r || e || Function("return this")();
25
+ return je = t, je;
26
+ }
27
+ var ke, aa;
28
+ function wu() {
29
+ if (aa) return ke;
30
+ aa = 1;
31
+ var r = ie(), e = function() {
32
+ return r.Date.now();
33
+ };
34
+ return ke = e, ke;
35
+ }
36
+ var He, ia;
37
+ function Tu() {
38
+ if (ia) return He;
39
+ ia = 1;
40
+ var r = /\s/;
41
+ function e(t) {
42
+ for (var n = t.length; n-- && r.test(t.charAt(n)); )
43
+ ;
44
+ return n;
45
+ }
46
+ return He = e, He;
47
+ }
48
+ var Ge, sa;
49
+ function xu() {
50
+ if (sa) return Ge;
51
+ sa = 1;
52
+ var r = Tu(), e = /^\s+/;
53
+ function t(n) {
54
+ return n && n.slice(0, r(n) + 1).replace(e, "");
55
+ }
56
+ return Ge = t, Ge;
57
+ }
58
+ var Ue, ua;
59
+ function Ce() {
60
+ if (ua) return Ue;
61
+ ua = 1;
62
+ var r = ie(), e = r.Symbol;
63
+ return Ue = e, Ue;
64
+ }
65
+ var ze, oa;
66
+ function Su() {
67
+ if (oa) return ze;
68
+ oa = 1;
69
+ var r = Ce(), e = Object.prototype, t = e.hasOwnProperty, n = e.toString, a = r ? r.toStringTag : void 0;
70
+ function i(s) {
71
+ var o = t.call(s, a), l = s[a];
72
+ try {
73
+ s[a] = void 0;
74
+ var h = !0;
75
+ } catch {
76
+ }
77
+ var m = n.call(s);
78
+ return h && (o ? s[a] = l : delete s[a]), m;
79
+ }
80
+ return ze = i, ze;
81
+ }
82
+ var We, ca;
83
+ function Ou() {
84
+ if (ca) return We;
85
+ ca = 1;
86
+ var r = Object.prototype, e = r.toString;
87
+ function t(n) {
88
+ return e.call(n);
89
+ }
90
+ return We = t, We;
91
+ }
92
+ var $e, fa;
93
+ function Fe() {
94
+ if (fa) return $e;
95
+ fa = 1;
96
+ var r = Ce(), e = Su(), t = Ou(), n = "[object Null]", a = "[object Undefined]", i = r ? r.toStringTag : void 0;
97
+ function s(o) {
98
+ return o == null ? o === void 0 ? a : n : i && i in Object(o) ? e(o) : t(o);
99
+ }
100
+ return $e = s, $e;
101
+ }
102
+ var Ye, la;
103
+ function he() {
104
+ if (la) return Ye;
105
+ la = 1;
106
+ function r(e) {
107
+ return e != null && typeof e == "object";
108
+ }
109
+ return Ye = r, Ye;
110
+ }
111
+ var Je, da;
112
+ function Re() {
113
+ if (da) return Je;
114
+ da = 1;
115
+ var r = Fe(), e = he(), t = "[object Symbol]";
116
+ function n(a) {
117
+ return typeof a == "symbol" || e(a) && r(a) == t;
118
+ }
119
+ return Je = n, Je;
120
+ }
121
+ var Xe, ha;
122
+ function Ku() {
123
+ if (ha) return Xe;
124
+ ha = 1;
125
+ var r = xu(), e = le(), t = Re(), n = NaN, a = /^[-+]0x[0-9a-f]+$/i, i = /^0b[01]+$/i, s = /^0o[0-7]+$/i, o = parseInt;
126
+ function l(h) {
127
+ if (typeof h == "number")
128
+ return h;
129
+ if (t(h))
130
+ return n;
131
+ if (e(h)) {
132
+ var m = typeof h.valueOf == "function" ? h.valueOf() : h;
133
+ h = e(m) ? m + "" : m;
134
+ }
135
+ if (typeof h != "string")
136
+ return h === 0 ? h : +h;
137
+ h = r(h);
138
+ var _ = i.test(h);
139
+ return _ || s.test(h) ? o(h.slice(2), _ ? 2 : 8) : a.test(h) ? n : +h;
140
+ }
141
+ return Xe = l, Xe;
142
+ }
143
+ var Ze, va;
144
+ function au() {
145
+ if (va) return Ze;
146
+ va = 1;
147
+ var r = le(), e = wu(), t = Ku(), n = "Expected a function", a = Math.max, i = Math.min;
148
+ function s(o, l, h) {
149
+ var m, _, O, E, L, K, b = 0, d = !1, p = !1, q = !0;
150
+ if (typeof o != "function")
151
+ throw new TypeError(n);
152
+ l = t(l) || 0, r(h) && (d = !!h.leading, p = "maxWait" in h, O = p ? a(t(h.maxWait) || 0, l) : O, q = "trailing" in h ? !!h.trailing : q);
153
+ function g(w) {
154
+ var U = m, J = _;
155
+ return m = _ = void 0, b = w, E = o.apply(J, U), E;
156
+ }
157
+ function P(w) {
158
+ return b = w, L = setTimeout(N, l), d ? g(w) : E;
159
+ }
160
+ function x(w) {
161
+ var U = w - K, J = w - b, te = l - U;
162
+ return p ? i(te, O - J) : te;
163
+ }
164
+ function F(w) {
165
+ var U = w - K, J = w - b;
166
+ return K === void 0 || U >= l || U < 0 || p && J >= O;
167
+ }
168
+ function N() {
169
+ var w = e();
170
+ if (F(w))
171
+ return R(w);
172
+ L = setTimeout(N, x(w));
173
+ }
174
+ function R(w) {
175
+ return L = void 0, q && m ? g(w) : (m = _ = void 0, E);
176
+ }
177
+ function S() {
178
+ L !== void 0 && clearTimeout(L), b = 0, m = K = _ = L = void 0;
179
+ }
180
+ function M() {
181
+ return L === void 0 ? E : R(e());
182
+ }
183
+ function H() {
184
+ var w = e(), U = F(w);
185
+ if (m = arguments, _ = this, K = w, U) {
186
+ if (L === void 0)
187
+ return P(K);
188
+ if (p)
189
+ return clearTimeout(L), L = setTimeout(N, l), g(K);
190
+ }
191
+ return L === void 0 && (L = setTimeout(N, l)), E;
192
+ }
193
+ return H.cancel = S, H.flush = M, H;
194
+ }
195
+ return Ze = s, Ze;
196
+ }
197
+ var Qe, pa;
198
+ function iu() {
199
+ if (pa) return Qe;
200
+ pa = 1;
201
+ var r = Fe(), e = le(), t = "[object AsyncFunction]", n = "[object Function]", a = "[object GeneratorFunction]", i = "[object Proxy]";
202
+ function s(o) {
203
+ if (!e(o))
204
+ return !1;
205
+ var l = r(o);
206
+ return l == n || l == a || l == t || l == i;
207
+ }
208
+ return Qe = s, Qe;
209
+ }
210
+ var Ve, ya;
211
+ function Eu() {
212
+ if (ya) return Ve;
213
+ ya = 1;
214
+ var r = ie(), e = r["__core-js_shared__"];
215
+ return Ve = e, Ve;
216
+ }
217
+ var er, ga;
218
+ function Pu() {
219
+ if (ga) return er;
220
+ ga = 1;
221
+ var r = Eu(), e = (function() {
222
+ var n = /[^.]+$/.exec(r && r.keys && r.keys.IE_PROTO || "");
223
+ return n ? "Symbol(src)_1." + n : "";
224
+ })();
225
+ function t(n) {
226
+ return !!e && e in n;
227
+ }
228
+ return er = t, er;
229
+ }
230
+ var rr, _a;
231
+ function su() {
232
+ if (_a) return rr;
233
+ _a = 1;
234
+ var r = Function.prototype, e = r.toString;
235
+ function t(n) {
236
+ if (n != null) {
237
+ try {
238
+ return e.call(n);
239
+ } catch {
240
+ }
241
+ try {
242
+ return n + "";
243
+ } catch {
244
+ }
245
+ }
246
+ return "";
247
+ }
248
+ return rr = t, rr;
249
+ }
250
+ var tr, ba;
251
+ function Mu() {
252
+ if (ba) return tr;
253
+ ba = 1;
254
+ var r = iu(), e = Pu(), t = le(), n = su(), a = /[\\^$.*+?()[\]{}|]/g, i = /^\[object .+?Constructor\]$/, s = Function.prototype, o = Object.prototype, l = s.toString, h = o.hasOwnProperty, m = RegExp(
255
+ "^" + l.call(h).replace(a, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"
138
256
  );
257
+ function _(O) {
258
+ if (!t(O) || e(O))
259
+ return !1;
260
+ var E = r(O) ? m : i;
261
+ return E.test(n(O));
262
+ }
263
+ return tr = _, tr;
264
+ }
265
+ var nr, ma;
266
+ function Iu() {
267
+ if (ma) return nr;
268
+ ma = 1;
269
+ function r(e, t) {
270
+ return e?.[t];
271
+ }
272
+ return nr = r, nr;
273
+ }
274
+ var ar, qa;
275
+ function de() {
276
+ if (qa) return ar;
277
+ qa = 1;
278
+ var r = Mu(), e = Iu();
279
+ function t(n, a) {
280
+ var i = e(n, a);
281
+ return r(i) ? i : void 0;
282
+ }
283
+ return ar = t, ar;
284
+ }
285
+ var ir, Ca;
286
+ function Ee() {
287
+ if (Ca) return ir;
288
+ Ca = 1;
289
+ var r = de(), e = r(Object, "create");
290
+ return ir = e, ir;
291
+ }
292
+ var sr, Fa;
293
+ function Du() {
294
+ if (Fa) return sr;
295
+ Fa = 1;
296
+ var r = Ee();
297
+ function e() {
298
+ this.__data__ = r ? r(null) : {}, this.size = 0;
299
+ }
300
+ return sr = e, sr;
301
+ }
302
+ var ur, Ra;
303
+ function Lu() {
304
+ if (Ra) return ur;
305
+ Ra = 1;
306
+ function r(e) {
307
+ var t = this.has(e) && delete this.__data__[e];
308
+ return this.size -= t ? 1 : 0, t;
309
+ }
310
+ return ur = r, ur;
311
+ }
312
+ var or, Aa;
313
+ function Nu() {
314
+ if (Aa) return or;
315
+ Aa = 1;
316
+ var r = Ee(), e = "__lodash_hash_undefined__", t = Object.prototype, n = t.hasOwnProperty;
317
+ function a(i) {
318
+ var s = this.__data__;
319
+ if (r) {
320
+ var o = s[i];
321
+ return o === e ? void 0 : o;
322
+ }
323
+ return n.call(s, i) ? s[i] : void 0;
324
+ }
325
+ return or = a, or;
326
+ }
327
+ var cr, wa;
328
+ function Bu() {
329
+ if (wa) return cr;
330
+ wa = 1;
331
+ var r = Ee(), e = Object.prototype, t = e.hasOwnProperty;
332
+ function n(a) {
333
+ var i = this.__data__;
334
+ return r ? i[a] !== void 0 : t.call(i, a);
335
+ }
336
+ return cr = n, cr;
337
+ }
338
+ var fr, Ta;
339
+ function ju() {
340
+ if (Ta) return fr;
341
+ Ta = 1;
342
+ var r = Ee(), e = "__lodash_hash_undefined__";
343
+ function t(n, a) {
344
+ var i = this.__data__;
345
+ return this.size += this.has(n) ? 0 : 1, i[n] = r && a === void 0 ? e : a, this;
346
+ }
347
+ return fr = t, fr;
348
+ }
349
+ var lr, xa;
350
+ function ku() {
351
+ if (xa) return lr;
352
+ xa = 1;
353
+ var r = Du(), e = Lu(), t = Nu(), n = Bu(), a = ju();
354
+ function i(s) {
355
+ var o = -1, l = s == null ? 0 : s.length;
356
+ for (this.clear(); ++o < l; ) {
357
+ var h = s[o];
358
+ this.set(h[0], h[1]);
359
+ }
360
+ }
361
+ return i.prototype.clear = r, i.prototype.delete = e, i.prototype.get = t, i.prototype.has = n, i.prototype.set = a, lr = i, lr;
362
+ }
363
+ var dr, Sa;
364
+ function Hu() {
365
+ if (Sa) return dr;
366
+ Sa = 1;
367
+ function r() {
368
+ this.__data__ = [], this.size = 0;
369
+ }
370
+ return dr = r, dr;
371
+ }
372
+ var hr, Oa;
373
+ function Nn() {
374
+ if (Oa) return hr;
375
+ Oa = 1;
376
+ function r(e, t) {
377
+ return e === t || e !== e && t !== t;
378
+ }
379
+ return hr = r, hr;
380
+ }
381
+ var vr, Ka;
382
+ function Pe() {
383
+ if (Ka) return vr;
384
+ Ka = 1;
385
+ var r = Nn();
386
+ function e(t, n) {
387
+ for (var a = t.length; a--; )
388
+ if (r(t[a][0], n))
389
+ return a;
390
+ return -1;
391
+ }
392
+ return vr = e, vr;
393
+ }
394
+ var pr, Ea;
395
+ function Gu() {
396
+ if (Ea) return pr;
397
+ Ea = 1;
398
+ var r = Pe(), e = Array.prototype, t = e.splice;
399
+ function n(a) {
400
+ var i = this.__data__, s = r(i, a);
401
+ if (s < 0)
402
+ return !1;
403
+ var o = i.length - 1;
404
+ return s == o ? i.pop() : t.call(i, s, 1), --this.size, !0;
405
+ }
406
+ return pr = n, pr;
407
+ }
408
+ var yr, Pa;
409
+ function Uu() {
410
+ if (Pa) return yr;
411
+ Pa = 1;
412
+ var r = Pe();
413
+ function e(t) {
414
+ var n = this.__data__, a = r(n, t);
415
+ return a < 0 ? void 0 : n[a][1];
416
+ }
417
+ return yr = e, yr;
418
+ }
419
+ var gr, Ma;
420
+ function zu() {
421
+ if (Ma) return gr;
422
+ Ma = 1;
423
+ var r = Pe();
424
+ function e(t) {
425
+ return r(this.__data__, t) > -1;
426
+ }
427
+ return gr = e, gr;
428
+ }
429
+ var _r, Ia;
430
+ function Wu() {
431
+ if (Ia) return _r;
432
+ Ia = 1;
433
+ var r = Pe();
434
+ function e(t, n) {
435
+ var a = this.__data__, i = r(a, t);
436
+ return i < 0 ? (++this.size, a.push([t, n])) : a[i][1] = n, this;
437
+ }
438
+ return _r = e, _r;
439
+ }
440
+ var br, Da;
441
+ function Me() {
442
+ if (Da) return br;
443
+ Da = 1;
444
+ var r = Hu(), e = Gu(), t = Uu(), n = zu(), a = Wu();
445
+ function i(s) {
446
+ var o = -1, l = s == null ? 0 : s.length;
447
+ for (this.clear(); ++o < l; ) {
448
+ var h = s[o];
449
+ this.set(h[0], h[1]);
450
+ }
451
+ }
452
+ return i.prototype.clear = r, i.prototype.delete = e, i.prototype.get = t, i.prototype.has = n, i.prototype.set = a, br = i, br;
453
+ }
454
+ var mr, La;
455
+ function Bn() {
456
+ if (La) return mr;
457
+ La = 1;
458
+ var r = de(), e = ie(), t = r(e, "Map");
459
+ return mr = t, mr;
460
+ }
461
+ var qr, Na;
462
+ function $u() {
463
+ if (Na) return qr;
464
+ Na = 1;
465
+ var r = ku(), e = Me(), t = Bn();
466
+ function n() {
467
+ this.size = 0, this.__data__ = {
468
+ hash: new r(),
469
+ map: new (t || e)(),
470
+ string: new r()
471
+ };
472
+ }
473
+ return qr = n, qr;
474
+ }
475
+ var Cr, Ba;
476
+ function Yu() {
477
+ if (Ba) return Cr;
478
+ Ba = 1;
479
+ function r(e) {
480
+ var t = typeof e;
481
+ return t == "string" || t == "number" || t == "symbol" || t == "boolean" ? e !== "__proto__" : e === null;
482
+ }
483
+ return Cr = r, Cr;
484
+ }
485
+ var Fr, ja;
486
+ function Ie() {
487
+ if (ja) return Fr;
488
+ ja = 1;
489
+ var r = Yu();
490
+ function e(t, n) {
491
+ var a = t.__data__;
492
+ return r(n) ? a[typeof n == "string" ? "string" : "hash"] : a.map;
493
+ }
494
+ return Fr = e, Fr;
495
+ }
496
+ var Rr, ka;
497
+ function Ju() {
498
+ if (ka) return Rr;
499
+ ka = 1;
500
+ var r = Ie();
501
+ function e(t) {
502
+ var n = r(this, t).delete(t);
503
+ return this.size -= n ? 1 : 0, n;
504
+ }
505
+ return Rr = e, Rr;
506
+ }
507
+ var Ar, Ha;
508
+ function Xu() {
509
+ if (Ha) return Ar;
510
+ Ha = 1;
511
+ var r = Ie();
512
+ function e(t) {
513
+ return r(this, t).get(t);
514
+ }
515
+ return Ar = e, Ar;
516
+ }
517
+ var wr, Ga;
518
+ function Zu() {
519
+ if (Ga) return wr;
520
+ Ga = 1;
521
+ var r = Ie();
522
+ function e(t) {
523
+ return r(this, t).has(t);
524
+ }
525
+ return wr = e, wr;
526
+ }
527
+ var Tr, Ua;
528
+ function Qu() {
529
+ if (Ua) return Tr;
530
+ Ua = 1;
531
+ var r = Ie();
532
+ function e(t, n) {
533
+ var a = r(this, t), i = a.size;
534
+ return a.set(t, n), this.size += a.size == i ? 0 : 1, this;
535
+ }
536
+ return Tr = e, Tr;
537
+ }
538
+ var xr, za;
539
+ function jn() {
540
+ if (za) return xr;
541
+ za = 1;
542
+ var r = $u(), e = Ju(), t = Xu(), n = Zu(), a = Qu();
543
+ function i(s) {
544
+ var o = -1, l = s == null ? 0 : s.length;
545
+ for (this.clear(); ++o < l; ) {
546
+ var h = s[o];
547
+ this.set(h[0], h[1]);
548
+ }
549
+ }
550
+ return i.prototype.clear = r, i.prototype.delete = e, i.prototype.get = t, i.prototype.has = n, i.prototype.set = a, xr = i, xr;
551
+ }
552
+ var Sr, Wa;
553
+ function Vu() {
554
+ if (Wa) return Sr;
555
+ Wa = 1;
556
+ var r = "__lodash_hash_undefined__";
557
+ function e(t) {
558
+ return this.__data__.set(t, r), this;
559
+ }
560
+ return Sr = e, Sr;
561
+ }
562
+ var Or, $a;
563
+ function eo() {
564
+ if ($a) return Or;
565
+ $a = 1;
566
+ function r(e) {
567
+ return this.__data__.has(e);
568
+ }
569
+ return Or = r, Or;
570
+ }
571
+ var Kr, Ya;
572
+ function uu() {
573
+ if (Ya) return Kr;
574
+ Ya = 1;
575
+ var r = jn(), e = Vu(), t = eo();
576
+ function n(a) {
577
+ var i = -1, s = a == null ? 0 : a.length;
578
+ for (this.__data__ = new r(); ++i < s; )
579
+ this.add(a[i]);
580
+ }
581
+ return n.prototype.add = n.prototype.push = e, n.prototype.has = t, Kr = n, Kr;
582
+ }
583
+ var Er, Ja;
584
+ function ro() {
585
+ if (Ja) return Er;
586
+ Ja = 1;
587
+ function r(e, t, n, a) {
588
+ for (var i = e.length, s = n + (a ? 1 : -1); a ? s-- : ++s < i; )
589
+ if (t(e[s], s, e))
590
+ return s;
591
+ return -1;
592
+ }
593
+ return Er = r, Er;
594
+ }
595
+ var Pr, Xa;
596
+ function to() {
597
+ if (Xa) return Pr;
598
+ Xa = 1;
599
+ function r(e) {
600
+ return e !== e;
601
+ }
602
+ return Pr = r, Pr;
603
+ }
604
+ var Mr, Za;
605
+ function no() {
606
+ if (Za) return Mr;
607
+ Za = 1;
608
+ function r(e, t, n) {
609
+ for (var a = n - 1, i = e.length; ++a < i; )
610
+ if (e[a] === t)
611
+ return a;
612
+ return -1;
613
+ }
614
+ return Mr = r, Mr;
615
+ }
616
+ var Ir, Qa;
617
+ function ao() {
618
+ if (Qa) return Ir;
619
+ Qa = 1;
620
+ var r = ro(), e = to(), t = no();
621
+ function n(a, i, s) {
622
+ return i === i ? t(a, i, s) : r(a, e, s);
623
+ }
624
+ return Ir = n, Ir;
625
+ }
626
+ var Dr, Va;
627
+ function io() {
628
+ if (Va) return Dr;
629
+ Va = 1;
630
+ var r = ao();
631
+ function e(t, n) {
632
+ var a = t == null ? 0 : t.length;
633
+ return !!a && r(t, n, 0) > -1;
634
+ }
635
+ return Dr = e, Dr;
636
+ }
637
+ var Lr, ei;
638
+ function so() {
639
+ if (ei) return Lr;
640
+ ei = 1;
641
+ function r(e, t, n) {
642
+ for (var a = -1, i = e == null ? 0 : e.length; ++a < i; )
643
+ if (n(t, e[a]))
644
+ return !0;
645
+ return !1;
646
+ }
647
+ return Lr = r, Lr;
648
+ }
649
+ var Nr, ri;
650
+ function kn() {
651
+ if (ri) return Nr;
652
+ ri = 1;
653
+ function r(e, t) {
654
+ for (var n = -1, a = e == null ? 0 : e.length, i = Array(a); ++n < a; )
655
+ i[n] = t(e[n], n, e);
656
+ return i;
657
+ }
658
+ return Nr = r, Nr;
659
+ }
660
+ var Br, ti;
661
+ function Hn() {
662
+ if (ti) return Br;
663
+ ti = 1;
664
+ function r(e) {
665
+ return function(t) {
666
+ return e(t);
667
+ };
668
+ }
669
+ return Br = r, Br;
670
+ }
671
+ var jr, ni;
672
+ function ou() {
673
+ if (ni) return jr;
674
+ ni = 1;
675
+ function r(e, t) {
676
+ return e.has(t);
677
+ }
678
+ return jr = r, jr;
679
+ }
680
+ var kr, ai;
681
+ function uo() {
682
+ if (ai) return kr;
683
+ ai = 1;
684
+ var r = uu(), e = io(), t = so(), n = kn(), a = Hn(), i = ou(), s = 200;
685
+ function o(l, h, m, _) {
686
+ var O = -1, E = e, L = !0, K = l.length, b = [], d = h.length;
687
+ if (!K)
688
+ return b;
689
+ m && (h = n(h, a(m))), _ ? (E = t, L = !1) : h.length >= s && (E = i, L = !1, h = new r(h));
690
+ e:
691
+ for (; ++O < K; ) {
692
+ var p = l[O], q = m == null ? p : m(p);
693
+ if (p = _ || p !== 0 ? p : 0, L && q === q) {
694
+ for (var g = d; g--; )
695
+ if (h[g] === q)
696
+ continue e;
697
+ b.push(p);
698
+ } else E(h, q, _) || b.push(p);
699
+ }
700
+ return b;
701
+ }
702
+ return kr = o, kr;
703
+ }
704
+ var Hr, ii;
705
+ function cu() {
706
+ if (ii) return Hr;
707
+ ii = 1;
708
+ function r(e, t) {
709
+ for (var n = -1, a = t.length, i = e.length; ++n < a; )
710
+ e[i + n] = t[n];
711
+ return e;
712
+ }
713
+ return Hr = r, Hr;
714
+ }
715
+ var Gr, si;
716
+ function oo() {
717
+ if (si) return Gr;
718
+ si = 1;
719
+ var r = Fe(), e = he(), t = "[object Arguments]";
720
+ function n(a) {
721
+ return e(a) && r(a) == t;
722
+ }
723
+ return Gr = n, Gr;
724
+ }
725
+ var Ur, ui;
726
+ function Gn() {
727
+ if (ui) return Ur;
728
+ ui = 1;
729
+ var r = oo(), e = he(), t = Object.prototype, n = t.hasOwnProperty, a = t.propertyIsEnumerable, i = r(/* @__PURE__ */ (function() {
730
+ return arguments;
731
+ })()) ? r : function(s) {
732
+ return e(s) && n.call(s, "callee") && !a.call(s, "callee");
733
+ };
734
+ return Ur = i, Ur;
735
+ }
736
+ var zr, oi;
737
+ function re() {
738
+ if (oi) return zr;
739
+ oi = 1;
740
+ var r = Array.isArray;
741
+ return zr = r, zr;
742
+ }
743
+ var Wr, ci;
744
+ function co() {
745
+ if (ci) return Wr;
746
+ ci = 1;
747
+ var r = Ce(), e = Gn(), t = re(), n = r ? r.isConcatSpreadable : void 0;
748
+ function a(i) {
749
+ return t(i) || e(i) || !!(n && i && i[n]);
750
+ }
751
+ return Wr = a, Wr;
752
+ }
753
+ var $r, fi;
754
+ function fu() {
755
+ if (fi) return $r;
756
+ fi = 1;
757
+ var r = cu(), e = co();
758
+ function t(n, a, i, s, o) {
759
+ var l = -1, h = n.length;
760
+ for (i || (i = e), o || (o = []); ++l < h; ) {
761
+ var m = n[l];
762
+ a > 0 && i(m) ? a > 1 ? t(m, a - 1, i, s, o) : r(o, m) : s || (o[o.length] = m);
763
+ }
764
+ return o;
765
+ }
766
+ return $r = t, $r;
767
+ }
768
+ var Yr, li;
769
+ function Ae() {
770
+ if (li) return Yr;
771
+ li = 1;
772
+ function r(e) {
773
+ return e;
774
+ }
775
+ return Yr = r, Yr;
776
+ }
777
+ var Jr, di;
778
+ function fo() {
779
+ if (di) return Jr;
780
+ di = 1;
781
+ function r(e, t, n) {
782
+ switch (n.length) {
783
+ case 0:
784
+ return e.call(t);
785
+ case 1:
786
+ return e.call(t, n[0]);
787
+ case 2:
788
+ return e.call(t, n[0], n[1]);
789
+ case 3:
790
+ return e.call(t, n[0], n[1], n[2]);
791
+ }
792
+ return e.apply(t, n);
793
+ }
794
+ return Jr = r, Jr;
795
+ }
796
+ var Xr, hi;
797
+ function lo() {
798
+ if (hi) return Xr;
799
+ hi = 1;
800
+ var r = fo(), e = Math.max;
801
+ function t(n, a, i) {
802
+ return a = e(a === void 0 ? n.length - 1 : a, 0), function() {
803
+ for (var s = arguments, o = -1, l = e(s.length - a, 0), h = Array(l); ++o < l; )
804
+ h[o] = s[a + o];
805
+ o = -1;
806
+ for (var m = Array(a + 1); ++o < a; )
807
+ m[o] = s[o];
808
+ return m[a] = i(h), r(n, this, m);
809
+ };
810
+ }
811
+ return Xr = t, Xr;
812
+ }
813
+ var Zr, vi;
814
+ function ho() {
815
+ if (vi) return Zr;
816
+ vi = 1;
817
+ function r(e) {
818
+ return function() {
819
+ return e;
820
+ };
821
+ }
822
+ return Zr = r, Zr;
823
+ }
824
+ var Qr, pi;
825
+ function vo() {
826
+ if (pi) return Qr;
827
+ pi = 1;
828
+ var r = de(), e = (function() {
829
+ try {
830
+ var t = r(Object, "defineProperty");
831
+ return t({}, "", {}), t;
832
+ } catch {
833
+ }
834
+ })();
835
+ return Qr = e, Qr;
836
+ }
837
+ var Vr, yi;
838
+ function po() {
839
+ if (yi) return Vr;
840
+ yi = 1;
841
+ var r = ho(), e = vo(), t = Ae(), n = e ? function(a, i) {
842
+ return e(a, "toString", {
843
+ configurable: !0,
844
+ enumerable: !1,
845
+ value: r(i),
846
+ writable: !0
847
+ });
848
+ } : t;
849
+ return Vr = n, Vr;
850
+ }
851
+ var et, gi;
852
+ function yo() {
853
+ if (gi) return et;
854
+ gi = 1;
855
+ var r = 800, e = 16, t = Date.now;
856
+ function n(a) {
857
+ var i = 0, s = 0;
858
+ return function() {
859
+ var o = t(), l = e - (o - s);
860
+ if (s = o, l > 0) {
861
+ if (++i >= r)
862
+ return arguments[0];
863
+ } else
864
+ i = 0;
865
+ return a.apply(void 0, arguments);
866
+ };
867
+ }
868
+ return et = n, et;
869
+ }
870
+ var rt, _i;
871
+ function go() {
872
+ if (_i) return rt;
873
+ _i = 1;
874
+ var r = po(), e = yo(), t = e(r);
875
+ return rt = t, rt;
876
+ }
877
+ var tt, bi;
878
+ function lu() {
879
+ if (bi) return tt;
880
+ bi = 1;
881
+ var r = Ae(), e = lo(), t = go();
882
+ function n(a, i) {
883
+ return t(e(a, i, r), a + "");
884
+ }
885
+ return tt = n, tt;
886
+ }
887
+ var nt, mi;
888
+ function Un() {
889
+ if (mi) return nt;
890
+ mi = 1;
891
+ var r = 9007199254740991;
892
+ function e(t) {
893
+ return typeof t == "number" && t > -1 && t % 1 == 0 && t <= r;
894
+ }
895
+ return nt = e, nt;
896
+ }
897
+ var at, qi;
898
+ function we() {
899
+ if (qi) return at;
900
+ qi = 1;
901
+ var r = iu(), e = Un();
902
+ function t(n) {
903
+ return n != null && e(n.length) && !r(n);
904
+ }
905
+ return at = t, at;
906
+ }
907
+ var it, Ci;
908
+ function _o() {
909
+ if (Ci) return it;
910
+ Ci = 1;
911
+ var r = we(), e = he();
912
+ function t(n) {
913
+ return e(n) && r(n);
914
+ }
915
+ return it = t, it;
916
+ }
917
+ var st, Fi;
918
+ function bo() {
919
+ if (Fi) return st;
920
+ Fi = 1;
921
+ var r = uo(), e = fu(), t = lu(), n = _o(), a = t(function(i, s) {
922
+ return n(i) ? r(i, e(s, 1, n, !0)) : [];
923
+ });
924
+ return st = a, st;
925
+ }
926
+ var ut, Ri;
927
+ function du() {
928
+ if (Ri) return ut;
929
+ Ri = 1;
930
+ function r(e, t) {
931
+ for (var n = -1, a = e == null ? 0 : e.length, i = 0, s = []; ++n < a; ) {
932
+ var o = e[n];
933
+ t(o, n, e) && (s[i++] = o);
934
+ }
935
+ return s;
936
+ }
937
+ return ut = r, ut;
938
+ }
939
+ var ot, Ai;
940
+ function mo() {
941
+ if (Ai) return ot;
942
+ Ai = 1;
943
+ function r(e) {
944
+ return function(t, n, a) {
945
+ for (var i = -1, s = Object(t), o = a(t), l = o.length; l--; ) {
946
+ var h = o[e ? l : ++i];
947
+ if (n(s[h], h, s) === !1)
948
+ break;
949
+ }
950
+ return t;
951
+ };
952
+ }
953
+ return ot = r, ot;
954
+ }
955
+ var ct, wi;
956
+ function qo() {
957
+ if (wi) return ct;
958
+ wi = 1;
959
+ var r = mo(), e = r();
960
+ return ct = e, ct;
961
+ }
962
+ var ft, Ti;
963
+ function Co() {
964
+ if (Ti) return ft;
965
+ Ti = 1;
966
+ function r(e, t) {
967
+ for (var n = -1, a = Array(e); ++n < e; )
968
+ a[n] = t(n);
969
+ return a;
970
+ }
971
+ return ft = r, ft;
972
+ }
973
+ var me = { exports: {} }, lt, xi;
974
+ function Fo() {
975
+ if (xi) return lt;
976
+ xi = 1;
977
+ function r() {
978
+ return !1;
979
+ }
980
+ return lt = r, lt;
981
+ }
982
+ me.exports;
983
+ var Si;
984
+ function hu() {
985
+ return Si || (Si = 1, (function(r, e) {
986
+ var t = ie(), n = Fo(), a = e && !e.nodeType && e, i = a && !0 && r && !r.nodeType && r, s = i && i.exports === a, o = s ? t.Buffer : void 0, l = o ? o.isBuffer : void 0, h = l || n;
987
+ r.exports = h;
988
+ })(me, me.exports)), me.exports;
989
+ }
990
+ var dt, Oi;
991
+ function zn() {
992
+ if (Oi) return dt;
993
+ Oi = 1;
994
+ var r = 9007199254740991, e = /^(?:0|[1-9]\d*)$/;
995
+ function t(n, a) {
996
+ var i = typeof n;
997
+ return a = a ?? r, !!a && (i == "number" || i != "symbol" && e.test(n)) && n > -1 && n % 1 == 0 && n < a;
998
+ }
999
+ return dt = t, dt;
1000
+ }
1001
+ var ht, Ki;
1002
+ function Ro() {
1003
+ if (Ki) return ht;
1004
+ Ki = 1;
1005
+ var r = Fe(), e = Un(), t = he(), n = "[object Arguments]", a = "[object Array]", i = "[object Boolean]", s = "[object Date]", o = "[object Error]", l = "[object Function]", h = "[object Map]", m = "[object Number]", _ = "[object Object]", O = "[object RegExp]", E = "[object Set]", L = "[object String]", K = "[object WeakMap]", b = "[object ArrayBuffer]", d = "[object DataView]", p = "[object Float32Array]", q = "[object Float64Array]", g = "[object Int8Array]", P = "[object Int16Array]", x = "[object Int32Array]", F = "[object Uint8Array]", N = "[object Uint8ClampedArray]", R = "[object Uint16Array]", S = "[object Uint32Array]", M = {};
1006
+ M[p] = M[q] = M[g] = M[P] = M[x] = M[F] = M[N] = M[R] = M[S] = !0, M[n] = M[a] = M[b] = M[i] = M[d] = M[s] = M[o] = M[l] = M[h] = M[m] = M[_] = M[O] = M[E] = M[L] = M[K] = !1;
1007
+ function H(w) {
1008
+ return t(w) && e(w.length) && !!M[r(w)];
1009
+ }
1010
+ return ht = H, ht;
1011
+ }
1012
+ var qe = { exports: {} };
1013
+ qe.exports;
1014
+ var Ei;
1015
+ function Ao() {
1016
+ return Ei || (Ei = 1, (function(r, e) {
1017
+ var t = nu(), n = e && !e.nodeType && e, a = n && !0 && r && !r.nodeType && r, i = a && a.exports === n, s = i && t.process, o = (function() {
1018
+ try {
1019
+ var l = a && a.require && a.require("util").types;
1020
+ return l || s && s.binding && s.binding("util");
1021
+ } catch {
1022
+ }
1023
+ })();
1024
+ r.exports = o;
1025
+ })(qe, qe.exports)), qe.exports;
1026
+ }
1027
+ var vt, Pi;
1028
+ function vu() {
1029
+ if (Pi) return vt;
1030
+ Pi = 1;
1031
+ var r = Ro(), e = Hn(), t = Ao(), n = t && t.isTypedArray, a = n ? e(n) : r;
1032
+ return vt = a, vt;
1033
+ }
1034
+ var pt, Mi;
1035
+ function wo() {
1036
+ if (Mi) return pt;
1037
+ Mi = 1;
1038
+ var r = Co(), e = Gn(), t = re(), n = hu(), a = zn(), i = vu(), s = Object.prototype, o = s.hasOwnProperty;
1039
+ function l(h, m) {
1040
+ var _ = t(h), O = !_ && e(h), E = !_ && !O && n(h), L = !_ && !O && !E && i(h), K = _ || O || E || L, b = K ? r(h.length, String) : [], d = b.length;
1041
+ for (var p in h)
1042
+ (m || o.call(h, p)) && !(K && // Safari 9 has enumerable `arguments.length` in strict mode.
1043
+ (p == "length" || // Node.js 0.10 has enumerable non-index properties on buffers.
1044
+ E && (p == "offset" || p == "parent") || // PhantomJS 2 has enumerable non-index properties on typed arrays.
1045
+ L && (p == "buffer" || p == "byteLength" || p == "byteOffset") || // Skip index properties.
1046
+ a(p, d))) && b.push(p);
1047
+ return b;
1048
+ }
1049
+ return pt = l, pt;
1050
+ }
1051
+ var yt, Ii;
1052
+ function To() {
1053
+ if (Ii) return yt;
1054
+ Ii = 1;
1055
+ var r = Object.prototype;
1056
+ function e(t) {
1057
+ var n = t && t.constructor, a = typeof n == "function" && n.prototype || r;
1058
+ return t === a;
1059
+ }
1060
+ return yt = e, yt;
1061
+ }
1062
+ var gt, Di;
1063
+ function xo() {
1064
+ if (Di) return gt;
1065
+ Di = 1;
1066
+ function r(e, t) {
1067
+ return function(n) {
1068
+ return e(t(n));
1069
+ };
1070
+ }
1071
+ return gt = r, gt;
1072
+ }
1073
+ var _t, Li;
1074
+ function So() {
1075
+ if (Li) return _t;
1076
+ Li = 1;
1077
+ var r = xo(), e = r(Object.keys, Object);
1078
+ return _t = e, _t;
1079
+ }
1080
+ var bt, Ni;
1081
+ function Oo() {
1082
+ if (Ni) return bt;
1083
+ Ni = 1;
1084
+ var r = To(), e = So(), t = Object.prototype, n = t.hasOwnProperty;
1085
+ function a(i) {
1086
+ if (!r(i))
1087
+ return e(i);
1088
+ var s = [];
1089
+ for (var o in Object(i))
1090
+ n.call(i, o) && o != "constructor" && s.push(o);
1091
+ return s;
1092
+ }
1093
+ return bt = a, bt;
1094
+ }
1095
+ var mt, Bi;
1096
+ function Wn() {
1097
+ if (Bi) return mt;
1098
+ Bi = 1;
1099
+ var r = wo(), e = Oo(), t = we();
1100
+ function n(a) {
1101
+ return t(a) ? r(a) : e(a);
1102
+ }
1103
+ return mt = n, mt;
1104
+ }
1105
+ var qt, ji;
1106
+ function $n() {
1107
+ if (ji) return qt;
1108
+ ji = 1;
1109
+ var r = qo(), e = Wn();
1110
+ function t(n, a) {
1111
+ return n && r(n, a, e);
1112
+ }
1113
+ return qt = t, qt;
1114
+ }
1115
+ var Ct, ki;
1116
+ function Ko() {
1117
+ if (ki) return Ct;
1118
+ ki = 1;
1119
+ var r = we();
1120
+ function e(t, n) {
1121
+ return function(a, i) {
1122
+ if (a == null)
1123
+ return a;
1124
+ if (!r(a))
1125
+ return t(a, i);
1126
+ for (var s = a.length, o = n ? s : -1, l = Object(a); (n ? o-- : ++o < s) && i(l[o], o, l) !== !1; )
1127
+ ;
1128
+ return a;
1129
+ };
1130
+ }
1131
+ return Ct = e, Ct;
139
1132
  }
140
- const Le = ie(ge), Ue = ({ loading: t, autoPlay: a, played: o, playing: l, isMuted: i, unmute: c, mute: d, togglePlaying: p }) => !t && !a && !o ? /* @__PURE__ */ e(T, { children: l ? /* @__PURE__ */ e(f, { name: "icon-pause" }) : /* @__PURE__ */ e(f, { name: "icon-play" }) }) : o ? /* @__PURE__ */ O(ve, { children: [
141
- l ? /* @__PURE__ */ e(ke, { onClick: p }) : /* @__PURE__ */ e(Se, { onClick: p }),
142
- /* @__PURE__ */ e(Me, { className: X(!i && "muted"), onClick: i ? c : d })
143
- ] }) : null, He = ({
144
- loading: t,
145
- autoPlay: a,
146
- playMuted: o,
147
- playing: l,
148
- played: i,
149
- unmute: c,
150
- mute: d,
151
- isMuted: p,
152
- hasNotPausedVideo: y,
153
- hasInteractedWithAudio: M
154
- }) => /* @__PURE__ */ O(re, { children: [
155
- !t && !(a && o) && /* @__PURE__ */ e(T, { "data-control-btn": "true", children: l ? y ? null : /* @__PURE__ */ e(We, { children: /* @__PURE__ */ e(f, { name: "icon-play" }) }) : i ? /* @__PURE__ */ e(Ne, { children: /* @__PURE__ */ e(f, { name: "icon-pause" }) }) : /* @__PURE__ */ e(Z, { "data-control-icon": "true", children: /* @__PURE__ */ e(f, { name: "icon-play" }) }) }),
156
- !t && a && o && M && /* @__PURE__ */ e(T, { children: p ? /* @__PURE__ */ e(Te, { onClick: c, children: /* @__PURE__ */ e(f, { name: "iconMute" }) }) : /* @__PURE__ */ e(Re, { onClick: d, children: /* @__PURE__ */ e(f, { name: "iconUnMute" }) }) })
157
- ] }), Ze = le(
158
- ({
159
- poster: t,
160
- source: a,
161
- aspectRatio: o,
162
- controlVideo: l,
163
- onReplay: i,
164
- onPlay: c,
165
- onPause: d,
166
- onEnd: p,
167
- onRender: y,
168
- onMute: M,
169
- onQuartile: $,
170
- autoPlay: C,
171
- playMuted: k,
172
- className: ee,
173
- muted: w,
174
- webos: x,
175
- hasNotPausedVideo: te
176
- }, ae) => {
177
- const u = V(null), se = Fe(u, ae), j = V(!1), q = V(!1), m = V(/* @__PURE__ */ new Set()), [D, G] = h(!1), [B, W] = h(!1), [z, K] = h(!1), [Q, E] = h(!0), [F, N] = h(k), [L, ne] = h(!1);
178
- b(() => {
179
- a && (N(k), G(!1));
180
- }, [a]);
181
- const P = A(() => {
182
- l?.({ muted: !1 });
183
- }, [l]), _ = A(() => {
184
- l?.({ muted: !0 });
185
- }, [l]), v = A((s) => {
186
- s?.stopPropagation(), u.current && (u.current.muted = !0), N(!0);
187
- }, []), S = A(
188
- (s) => {
189
- s?.stopPropagation(), u.current && (u.current.muted = !1), N(!1), L || ne(!0);
190
- },
191
- [L]
192
- );
193
- b(() => {
194
- w !== void 0 && (w ? v() : S());
195
- }, [v, w, S]);
196
- const J = (s) => {
197
- s.stopPropagation?.();
198
- const r = u?.current;
199
- if (r)
200
- if (B)
201
- r.pause();
202
- else {
203
- const g = u?.current;
204
- if (!g)
205
- return;
206
- ze(), g.play().catch((I) => console.log(I)), E(!1);
1133
+ var Ft, Hi;
1134
+ function Yn() {
1135
+ if (Hi) return Ft;
1136
+ Hi = 1;
1137
+ var r = $n(), e = Ko(), t = e(r);
1138
+ return Ft = t, Ft;
1139
+ }
1140
+ var Rt, Gi;
1141
+ function Eo() {
1142
+ if (Gi) return Rt;
1143
+ Gi = 1;
1144
+ var r = Yn();
1145
+ function e(t, n) {
1146
+ var a = [];
1147
+ return r(t, function(i, s, o) {
1148
+ n(i, s, o) && a.push(i);
1149
+ }), a;
1150
+ }
1151
+ return Rt = e, Rt;
1152
+ }
1153
+ var At, Ui;
1154
+ function Po() {
1155
+ if (Ui) return At;
1156
+ Ui = 1;
1157
+ var r = Me();
1158
+ function e() {
1159
+ this.__data__ = new r(), this.size = 0;
1160
+ }
1161
+ return At = e, At;
1162
+ }
1163
+ var wt, zi;
1164
+ function Mo() {
1165
+ if (zi) return wt;
1166
+ zi = 1;
1167
+ function r(e) {
1168
+ var t = this.__data__, n = t.delete(e);
1169
+ return this.size = t.size, n;
1170
+ }
1171
+ return wt = r, wt;
1172
+ }
1173
+ var Tt, Wi;
1174
+ function Io() {
1175
+ if (Wi) return Tt;
1176
+ Wi = 1;
1177
+ function r(e) {
1178
+ return this.__data__.get(e);
1179
+ }
1180
+ return Tt = r, Tt;
1181
+ }
1182
+ var xt, $i;
1183
+ function Do() {
1184
+ if ($i) return xt;
1185
+ $i = 1;
1186
+ function r(e) {
1187
+ return this.__data__.has(e);
1188
+ }
1189
+ return xt = r, xt;
1190
+ }
1191
+ var St, Yi;
1192
+ function Lo() {
1193
+ if (Yi) return St;
1194
+ Yi = 1;
1195
+ var r = Me(), e = Bn(), t = jn(), n = 200;
1196
+ function a(i, s) {
1197
+ var o = this.__data__;
1198
+ if (o instanceof r) {
1199
+ var l = o.__data__;
1200
+ if (!e || l.length < n - 1)
1201
+ return l.push([i, s]), this.size = ++o.size, this;
1202
+ o = this.__data__ = new t(l);
1203
+ }
1204
+ return o.set(i, s), this.size = o.size, this;
1205
+ }
1206
+ return St = a, St;
1207
+ }
1208
+ var Ot, Ji;
1209
+ function pu() {
1210
+ if (Ji) return Ot;
1211
+ Ji = 1;
1212
+ var r = Me(), e = Po(), t = Mo(), n = Io(), a = Do(), i = Lo();
1213
+ function s(o) {
1214
+ var l = this.__data__ = new r(o);
1215
+ this.size = l.size;
1216
+ }
1217
+ return s.prototype.clear = e, s.prototype.delete = t, s.prototype.get = n, s.prototype.has = a, s.prototype.set = i, Ot = s, Ot;
1218
+ }
1219
+ var Kt, Xi;
1220
+ function No() {
1221
+ if (Xi) return Kt;
1222
+ Xi = 1;
1223
+ function r(e, t) {
1224
+ for (var n = -1, a = e == null ? 0 : e.length; ++n < a; )
1225
+ if (t(e[n], n, e))
1226
+ return !0;
1227
+ return !1;
1228
+ }
1229
+ return Kt = r, Kt;
1230
+ }
1231
+ var Et, Zi;
1232
+ function yu() {
1233
+ if (Zi) return Et;
1234
+ Zi = 1;
1235
+ var r = uu(), e = No(), t = ou(), n = 1, a = 2;
1236
+ function i(s, o, l, h, m, _) {
1237
+ var O = l & n, E = s.length, L = o.length;
1238
+ if (E != L && !(O && L > E))
1239
+ return !1;
1240
+ var K = _.get(s), b = _.get(o);
1241
+ if (K && b)
1242
+ return K == o && b == s;
1243
+ var d = -1, p = !0, q = l & a ? new r() : void 0;
1244
+ for (_.set(s, o), _.set(o, s); ++d < E; ) {
1245
+ var g = s[d], P = o[d];
1246
+ if (h)
1247
+ var x = O ? h(P, g, d, o, s, _) : h(g, P, d, s, o, _);
1248
+ if (x !== void 0) {
1249
+ if (x)
1250
+ continue;
1251
+ p = !1;
1252
+ break;
1253
+ }
1254
+ if (q) {
1255
+ if (!e(o, function(F, N) {
1256
+ if (!t(q, N) && (g === F || m(g, F, l, h, _)))
1257
+ return q.push(N);
1258
+ })) {
1259
+ p = !1;
1260
+ break;
207
1261
  }
208
- }, oe = () => {
209
- u?.current?.load(), E(!0);
1262
+ } else if (!(g === P || m(g, P, l, h, _))) {
1263
+ p = !1;
1264
+ break;
1265
+ }
1266
+ }
1267
+ return _.delete(s), _.delete(o), p;
1268
+ }
1269
+ return Et = i, Et;
1270
+ }
1271
+ var Pt, Qi;
1272
+ function Bo() {
1273
+ if (Qi) return Pt;
1274
+ Qi = 1;
1275
+ var r = ie(), e = r.Uint8Array;
1276
+ return Pt = e, Pt;
1277
+ }
1278
+ var Mt, Vi;
1279
+ function jo() {
1280
+ if (Vi) return Mt;
1281
+ Vi = 1;
1282
+ function r(e) {
1283
+ var t = -1, n = Array(e.size);
1284
+ return e.forEach(function(a, i) {
1285
+ n[++t] = [i, a];
1286
+ }), n;
1287
+ }
1288
+ return Mt = r, Mt;
1289
+ }
1290
+ var It, es;
1291
+ function ko() {
1292
+ if (es) return It;
1293
+ es = 1;
1294
+ function r(e) {
1295
+ var t = -1, n = Array(e.size);
1296
+ return e.forEach(function(a) {
1297
+ n[++t] = a;
1298
+ }), n;
1299
+ }
1300
+ return It = r, It;
1301
+ }
1302
+ var Dt, rs;
1303
+ function Ho() {
1304
+ if (rs) return Dt;
1305
+ rs = 1;
1306
+ var r = Ce(), e = Bo(), t = Nn(), n = yu(), a = jo(), i = ko(), s = 1, o = 2, l = "[object Boolean]", h = "[object Date]", m = "[object Error]", _ = "[object Map]", O = "[object Number]", E = "[object RegExp]", L = "[object Set]", K = "[object String]", b = "[object Symbol]", d = "[object ArrayBuffer]", p = "[object DataView]", q = r ? r.prototype : void 0, g = q ? q.valueOf : void 0;
1307
+ function P(x, F, N, R, S, M, H) {
1308
+ switch (N) {
1309
+ case p:
1310
+ if (x.byteLength != F.byteLength || x.byteOffset != F.byteOffset)
1311
+ return !1;
1312
+ x = x.buffer, F = F.buffer;
1313
+ case d:
1314
+ return !(x.byteLength != F.byteLength || !M(new e(x), new e(F)));
1315
+ case l:
1316
+ case h:
1317
+ case O:
1318
+ return t(+x, +F);
1319
+ case m:
1320
+ return x.name == F.name && x.message == F.message;
1321
+ case E:
1322
+ case K:
1323
+ return x == F + "";
1324
+ case _:
1325
+ var w = a;
1326
+ case L:
1327
+ var U = R & s;
1328
+ if (w || (w = i), x.size != F.size && !U)
1329
+ return !1;
1330
+ var J = H.get(x);
1331
+ if (J)
1332
+ return J == F;
1333
+ R |= o, H.set(x, F);
1334
+ var te = n(w(x), w(F), R, S, M, H);
1335
+ return H.delete(x), te;
1336
+ case b:
1337
+ if (g)
1338
+ return g.call(x) == g.call(F);
1339
+ }
1340
+ return !1;
1341
+ }
1342
+ return Dt = P, Dt;
1343
+ }
1344
+ var Lt, ts;
1345
+ function Go() {
1346
+ if (ts) return Lt;
1347
+ ts = 1;
1348
+ var r = cu(), e = re();
1349
+ function t(n, a, i) {
1350
+ var s = a(n);
1351
+ return e(n) ? s : r(s, i(n));
1352
+ }
1353
+ return Lt = t, Lt;
1354
+ }
1355
+ var Nt, ns;
1356
+ function Uo() {
1357
+ if (ns) return Nt;
1358
+ ns = 1;
1359
+ function r() {
1360
+ return [];
1361
+ }
1362
+ return Nt = r, Nt;
1363
+ }
1364
+ var Bt, as;
1365
+ function zo() {
1366
+ if (as) return Bt;
1367
+ as = 1;
1368
+ var r = du(), e = Uo(), t = Object.prototype, n = t.propertyIsEnumerable, a = Object.getOwnPropertySymbols, i = a ? function(s) {
1369
+ return s == null ? [] : (s = Object(s), r(a(s), function(o) {
1370
+ return n.call(s, o);
1371
+ }));
1372
+ } : e;
1373
+ return Bt = i, Bt;
1374
+ }
1375
+ var jt, is;
1376
+ function Wo() {
1377
+ if (is) return jt;
1378
+ is = 1;
1379
+ var r = Go(), e = zo(), t = Wn();
1380
+ function n(a) {
1381
+ return r(a, t, e);
1382
+ }
1383
+ return jt = n, jt;
1384
+ }
1385
+ var kt, ss;
1386
+ function $o() {
1387
+ if (ss) return kt;
1388
+ ss = 1;
1389
+ var r = Wo(), e = 1, t = Object.prototype, n = t.hasOwnProperty;
1390
+ function a(i, s, o, l, h, m) {
1391
+ var _ = o & e, O = r(i), E = O.length, L = r(s), K = L.length;
1392
+ if (E != K && !_)
1393
+ return !1;
1394
+ for (var b = E; b--; ) {
1395
+ var d = O[b];
1396
+ if (!(_ ? d in s : n.call(s, d)))
1397
+ return !1;
1398
+ }
1399
+ var p = m.get(i), q = m.get(s);
1400
+ if (p && q)
1401
+ return p == s && q == i;
1402
+ var g = !0;
1403
+ m.set(i, s), m.set(s, i);
1404
+ for (var P = _; ++b < E; ) {
1405
+ d = O[b];
1406
+ var x = i[d], F = s[d];
1407
+ if (l)
1408
+ var N = _ ? l(F, x, d, s, i, m) : l(x, F, d, i, s, m);
1409
+ if (!(N === void 0 ? x === F || h(x, F, o, l, m) : N)) {
1410
+ g = !1;
1411
+ break;
1412
+ }
1413
+ P || (P = d == "constructor");
1414
+ }
1415
+ if (g && !P) {
1416
+ var R = i.constructor, S = s.constructor;
1417
+ R != S && "constructor" in i && "constructor" in s && !(typeof R == "function" && R instanceof R && typeof S == "function" && S instanceof S) && (g = !1);
1418
+ }
1419
+ return m.delete(i), m.delete(s), g;
1420
+ }
1421
+ return kt = a, kt;
1422
+ }
1423
+ var Ht, us;
1424
+ function Yo() {
1425
+ if (us) return Ht;
1426
+ us = 1;
1427
+ var r = de(), e = ie(), t = r(e, "DataView");
1428
+ return Ht = t, Ht;
1429
+ }
1430
+ var Gt, os;
1431
+ function Jo() {
1432
+ if (os) return Gt;
1433
+ os = 1;
1434
+ var r = de(), e = ie(), t = r(e, "Promise");
1435
+ return Gt = t, Gt;
1436
+ }
1437
+ var Ut, cs;
1438
+ function Xo() {
1439
+ if (cs) return Ut;
1440
+ cs = 1;
1441
+ var r = de(), e = ie(), t = r(e, "Set");
1442
+ return Ut = t, Ut;
1443
+ }
1444
+ var zt, fs;
1445
+ function Zo() {
1446
+ if (fs) return zt;
1447
+ fs = 1;
1448
+ var r = de(), e = ie(), t = r(e, "WeakMap");
1449
+ return zt = t, zt;
1450
+ }
1451
+ var Wt, ls;
1452
+ function Qo() {
1453
+ if (ls) return Wt;
1454
+ ls = 1;
1455
+ var r = Yo(), e = Bn(), t = Jo(), n = Xo(), a = Zo(), i = Fe(), s = su(), o = "[object Map]", l = "[object Object]", h = "[object Promise]", m = "[object Set]", _ = "[object WeakMap]", O = "[object DataView]", E = s(r), L = s(e), K = s(t), b = s(n), d = s(a), p = i;
1456
+ return (r && p(new r(new ArrayBuffer(1))) != O || e && p(new e()) != o || t && p(t.resolve()) != h || n && p(new n()) != m || a && p(new a()) != _) && (p = function(q) {
1457
+ var g = i(q), P = g == l ? q.constructor : void 0, x = P ? s(P) : "";
1458
+ if (x)
1459
+ switch (x) {
1460
+ case E:
1461
+ return O;
1462
+ case L:
1463
+ return o;
1464
+ case K:
1465
+ return h;
1466
+ case b:
1467
+ return m;
1468
+ case d:
1469
+ return _;
1470
+ }
1471
+ return g;
1472
+ }), Wt = p, Wt;
1473
+ }
1474
+ var $t, ds;
1475
+ function Vo() {
1476
+ if (ds) return $t;
1477
+ ds = 1;
1478
+ var r = pu(), e = yu(), t = Ho(), n = $o(), a = Qo(), i = re(), s = hu(), o = vu(), l = 1, h = "[object Arguments]", m = "[object Array]", _ = "[object Object]", O = Object.prototype, E = O.hasOwnProperty;
1479
+ function L(K, b, d, p, q, g) {
1480
+ var P = i(K), x = i(b), F = P ? m : a(K), N = x ? m : a(b);
1481
+ F = F == h ? _ : F, N = N == h ? _ : N;
1482
+ var R = F == _, S = N == _, M = F == N;
1483
+ if (M && s(K)) {
1484
+ if (!s(b))
1485
+ return !1;
1486
+ P = !0, R = !1;
1487
+ }
1488
+ if (M && !R)
1489
+ return g || (g = new r()), P || o(K) ? e(K, b, d, p, q, g) : t(K, b, F, d, p, q, g);
1490
+ if (!(d & l)) {
1491
+ var H = R && E.call(K, "__wrapped__"), w = S && E.call(b, "__wrapped__");
1492
+ if (H || w) {
1493
+ var U = H ? K.value() : K, J = w ? b.value() : b;
1494
+ return g || (g = new r()), q(U, J, d, p, g);
1495
+ }
1496
+ }
1497
+ return M ? (g || (g = new r()), n(K, b, d, p, q, g)) : !1;
1498
+ }
1499
+ return $t = L, $t;
1500
+ }
1501
+ var Yt, hs;
1502
+ function gu() {
1503
+ if (hs) return Yt;
1504
+ hs = 1;
1505
+ var r = Vo(), e = he();
1506
+ function t(n, a, i, s, o) {
1507
+ return n === a ? !0 : n == null || a == null || !e(n) && !e(a) ? n !== n && a !== a : r(n, a, i, s, t, o);
1508
+ }
1509
+ return Yt = t, Yt;
1510
+ }
1511
+ var Jt, vs;
1512
+ function ec() {
1513
+ if (vs) return Jt;
1514
+ vs = 1;
1515
+ var r = pu(), e = gu(), t = 1, n = 2;
1516
+ function a(i, s, o, l) {
1517
+ var h = o.length, m = h, _ = !l;
1518
+ if (i == null)
1519
+ return !m;
1520
+ for (i = Object(i); h--; ) {
1521
+ var O = o[h];
1522
+ if (_ && O[2] ? O[1] !== i[O[0]] : !(O[0] in i))
1523
+ return !1;
1524
+ }
1525
+ for (; ++h < m; ) {
1526
+ O = o[h];
1527
+ var E = O[0], L = i[E], K = O[1];
1528
+ if (_ && O[2]) {
1529
+ if (L === void 0 && !(E in i))
1530
+ return !1;
1531
+ } else {
1532
+ var b = new r();
1533
+ if (l)
1534
+ var d = l(L, K, E, i, s, b);
1535
+ if (!(d === void 0 ? e(K, L, t | n, l, b) : d))
1536
+ return !1;
1537
+ }
1538
+ }
1539
+ return !0;
1540
+ }
1541
+ return Jt = a, Jt;
1542
+ }
1543
+ var Xt, ps;
1544
+ function _u() {
1545
+ if (ps) return Xt;
1546
+ ps = 1;
1547
+ var r = le();
1548
+ function e(t) {
1549
+ return t === t && !r(t);
1550
+ }
1551
+ return Xt = e, Xt;
1552
+ }
1553
+ var Zt, ys;
1554
+ function rc() {
1555
+ if (ys) return Zt;
1556
+ ys = 1;
1557
+ var r = _u(), e = Wn();
1558
+ function t(n) {
1559
+ for (var a = e(n), i = a.length; i--; ) {
1560
+ var s = a[i], o = n[s];
1561
+ a[i] = [s, o, r(o)];
1562
+ }
1563
+ return a;
1564
+ }
1565
+ return Zt = t, Zt;
1566
+ }
1567
+ var Qt, gs;
1568
+ function bu() {
1569
+ if (gs) return Qt;
1570
+ gs = 1;
1571
+ function r(e, t) {
1572
+ return function(n) {
1573
+ return n == null ? !1 : n[e] === t && (t !== void 0 || e in Object(n));
1574
+ };
1575
+ }
1576
+ return Qt = r, Qt;
1577
+ }
1578
+ var Vt, _s;
1579
+ function tc() {
1580
+ if (_s) return Vt;
1581
+ _s = 1;
1582
+ var r = ec(), e = rc(), t = bu();
1583
+ function n(a) {
1584
+ var i = e(a);
1585
+ return i.length == 1 && i[0][2] ? t(i[0][0], i[0][1]) : function(s) {
1586
+ return s === a || r(s, a, i);
210
1587
  };
211
- return b(() => () => {
212
- P();
213
- }, [P]), b(() => {
214
- const s = u.current;
215
- return s ? (q.current = s.muted, N(s.muted), je(s), () => {
216
- qe(s);
217
- }) : () => {
218
- };
219
- }, []), b(() => {
220
- y?.();
221
- }, [y]), b(() => {
222
- m.current.clear(), j.current = !1;
223
- }, [a]), /* @__PURE__ */ O(
224
- Le,
225
- {
226
- webos: x,
227
- onClick: C && k ? F ? S : v : J,
228
- "data-a": "intr",
229
- autoFocus: !0,
230
- options: { focusKey: "video-play-btn" },
231
- className: X(B && !x && be, C && Pe, ee),
232
- style: o ? { aspectRatio: o } : {},
233
- children: [
234
- /* @__PURE__ */ e(
235
- Ie,
236
- {
237
- ref: se,
238
- src: a,
239
- autoPlay: C,
240
- onPlay: () => {
241
- G(!0), j.current && (i?.(), m.current.clear()), W(!0), E(!1), c?.(), k ? v() : _();
242
- },
243
- onTimeUpdate: (s) => {
244
- const r = s.target.duration, g = s.target.currentTime;
245
- if (r && g) {
246
- const I = Math.floor(g / r * 100);
247
- I >= 25 && I < 50 && !m.current.has(25) ? ($?.(25), m.current.add(25)) : I >= 50 && I < 75 && !m.current.has(50) ? ($?.(50), m.current.add(50)) : I >= 75 && !m.current.has(75) && ($?.(75), m.current.add(75));
1588
+ }
1589
+ return Vt = n, Vt;
1590
+ }
1591
+ var en, bs;
1592
+ function Jn() {
1593
+ if (bs) return en;
1594
+ bs = 1;
1595
+ var r = re(), e = Re(), t = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, n = /^\w*$/;
1596
+ function a(i, s) {
1597
+ if (r(i))
1598
+ return !1;
1599
+ var o = typeof i;
1600
+ return o == "number" || o == "symbol" || o == "boolean" || i == null || e(i) ? !0 : n.test(i) || !t.test(i) || s != null && i in Object(s);
1601
+ }
1602
+ return en = a, en;
1603
+ }
1604
+ var rn, ms;
1605
+ function nc() {
1606
+ if (ms) return rn;
1607
+ ms = 1;
1608
+ var r = jn(), e = "Expected a function";
1609
+ function t(n, a) {
1610
+ if (typeof n != "function" || a != null && typeof a != "function")
1611
+ throw new TypeError(e);
1612
+ var i = function() {
1613
+ var s = arguments, o = a ? a.apply(this, s) : s[0], l = i.cache;
1614
+ if (l.has(o))
1615
+ return l.get(o);
1616
+ var h = n.apply(this, s);
1617
+ return i.cache = l.set(o, h) || l, h;
1618
+ };
1619
+ return i.cache = new (t.Cache || r)(), i;
1620
+ }
1621
+ return t.Cache = r, rn = t, rn;
1622
+ }
1623
+ var tn, qs;
1624
+ function ac() {
1625
+ if (qs) return tn;
1626
+ qs = 1;
1627
+ var r = nc(), e = 500;
1628
+ function t(n) {
1629
+ var a = r(n, function(s) {
1630
+ return i.size === e && i.clear(), s;
1631
+ }), i = a.cache;
1632
+ return a;
1633
+ }
1634
+ return tn = t, tn;
1635
+ }
1636
+ var nn, Cs;
1637
+ function ic() {
1638
+ if (Cs) return nn;
1639
+ Cs = 1;
1640
+ var r = ac(), e = /[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g, t = /\\(\\)?/g, n = r(function(a) {
1641
+ var i = [];
1642
+ return a.charCodeAt(0) === 46 && i.push(""), a.replace(e, function(s, o, l, h) {
1643
+ i.push(l ? h.replace(t, "$1") : o || s);
1644
+ }), i;
1645
+ });
1646
+ return nn = n, nn;
1647
+ }
1648
+ var an, Fs;
1649
+ function sc() {
1650
+ if (Fs) return an;
1651
+ Fs = 1;
1652
+ var r = Ce(), e = kn(), t = re(), n = Re(), a = r ? r.prototype : void 0, i = a ? a.toString : void 0;
1653
+ function s(o) {
1654
+ if (typeof o == "string")
1655
+ return o;
1656
+ if (t(o))
1657
+ return e(o, s) + "";
1658
+ if (n(o))
1659
+ return i ? i.call(o) : "";
1660
+ var l = o + "";
1661
+ return l == "0" && 1 / o == -1 / 0 ? "-0" : l;
1662
+ }
1663
+ return an = s, an;
1664
+ }
1665
+ var sn, Rs;
1666
+ function mu() {
1667
+ if (Rs) return sn;
1668
+ Rs = 1;
1669
+ var r = sc();
1670
+ function e(t) {
1671
+ return t == null ? "" : r(t);
1672
+ }
1673
+ return sn = e, sn;
1674
+ }
1675
+ var un, As;
1676
+ function qu() {
1677
+ if (As) return un;
1678
+ As = 1;
1679
+ var r = re(), e = Jn(), t = ic(), n = mu();
1680
+ function a(i, s) {
1681
+ return r(i) ? i : e(i, s) ? [i] : t(n(i));
1682
+ }
1683
+ return un = a, un;
1684
+ }
1685
+ var on, ws;
1686
+ function De() {
1687
+ if (ws) return on;
1688
+ ws = 1;
1689
+ var r = Re();
1690
+ function e(t) {
1691
+ if (typeof t == "string" || r(t))
1692
+ return t;
1693
+ var n = t + "";
1694
+ return n == "0" && 1 / t == -1 / 0 ? "-0" : n;
1695
+ }
1696
+ return on = e, on;
1697
+ }
1698
+ var cn, Ts;
1699
+ function Xn() {
1700
+ if (Ts) return cn;
1701
+ Ts = 1;
1702
+ var r = qu(), e = De();
1703
+ function t(n, a) {
1704
+ a = r(a, n);
1705
+ for (var i = 0, s = a.length; n != null && i < s; )
1706
+ n = n[e(a[i++])];
1707
+ return i && i == s ? n : void 0;
1708
+ }
1709
+ return cn = t, cn;
1710
+ }
1711
+ var fn, xs;
1712
+ function uc() {
1713
+ if (xs) return fn;
1714
+ xs = 1;
1715
+ var r = Xn();
1716
+ function e(t, n, a) {
1717
+ var i = t == null ? void 0 : r(t, n);
1718
+ return i === void 0 ? a : i;
1719
+ }
1720
+ return fn = e, fn;
1721
+ }
1722
+ var ln, Ss;
1723
+ function oc() {
1724
+ if (Ss) return ln;
1725
+ Ss = 1;
1726
+ function r(e, t) {
1727
+ return e != null && t in Object(e);
1728
+ }
1729
+ return ln = r, ln;
1730
+ }
1731
+ var dn, Os;
1732
+ function cc() {
1733
+ if (Os) return dn;
1734
+ Os = 1;
1735
+ var r = qu(), e = Gn(), t = re(), n = zn(), a = Un(), i = De();
1736
+ function s(o, l, h) {
1737
+ l = r(l, o);
1738
+ for (var m = -1, _ = l.length, O = !1; ++m < _; ) {
1739
+ var E = i(l[m]);
1740
+ if (!(O = o != null && h(o, E)))
1741
+ break;
1742
+ o = o[E];
1743
+ }
1744
+ return O || ++m != _ ? O : (_ = o == null ? 0 : o.length, !!_ && a(_) && n(E, _) && (t(o) || e(o)));
1745
+ }
1746
+ return dn = s, dn;
1747
+ }
1748
+ var hn, Ks;
1749
+ function fc() {
1750
+ if (Ks) return hn;
1751
+ Ks = 1;
1752
+ var r = oc(), e = cc();
1753
+ function t(n, a) {
1754
+ return n != null && e(n, a, r);
1755
+ }
1756
+ return hn = t, hn;
1757
+ }
1758
+ var vn, Es;
1759
+ function lc() {
1760
+ if (Es) return vn;
1761
+ Es = 1;
1762
+ var r = gu(), e = uc(), t = fc(), n = Jn(), a = _u(), i = bu(), s = De(), o = 1, l = 2;
1763
+ function h(m, _) {
1764
+ return n(m) && a(_) ? i(s(m), _) : function(O) {
1765
+ var E = e(O, m);
1766
+ return E === void 0 && E === _ ? t(O, m) : r(_, E, o | l);
1767
+ };
1768
+ }
1769
+ return vn = h, vn;
1770
+ }
1771
+ var pn, Ps;
1772
+ function dc() {
1773
+ if (Ps) return pn;
1774
+ Ps = 1;
1775
+ function r(e) {
1776
+ return function(t) {
1777
+ return t?.[e];
1778
+ };
1779
+ }
1780
+ return pn = r, pn;
1781
+ }
1782
+ var yn, Ms;
1783
+ function hc() {
1784
+ if (Ms) return yn;
1785
+ Ms = 1;
1786
+ var r = Xn();
1787
+ function e(t) {
1788
+ return function(n) {
1789
+ return r(n, t);
1790
+ };
1791
+ }
1792
+ return yn = e, yn;
1793
+ }
1794
+ var gn, Is;
1795
+ function vc() {
1796
+ if (Is) return gn;
1797
+ Is = 1;
1798
+ var r = dc(), e = hc(), t = Jn(), n = De();
1799
+ function a(i) {
1800
+ return t(i) ? r(n(i)) : e(i);
1801
+ }
1802
+ return gn = a, gn;
1803
+ }
1804
+ var _n, Ds;
1805
+ function Zn() {
1806
+ if (Ds) return _n;
1807
+ Ds = 1;
1808
+ var r = tc(), e = lc(), t = Ae(), n = re(), a = vc();
1809
+ function i(s) {
1810
+ return typeof s == "function" ? s : s == null ? t : typeof s == "object" ? n(s) ? e(s[0], s[1]) : r(s) : a(s);
1811
+ }
1812
+ return _n = i, _n;
1813
+ }
1814
+ var bn, Ls;
1815
+ function pc() {
1816
+ if (Ls) return bn;
1817
+ Ls = 1;
1818
+ var r = du(), e = Eo(), t = Zn(), n = re();
1819
+ function a(i, s) {
1820
+ var o = n(i) ? r : e;
1821
+ return o(i, t(s, 3));
1822
+ }
1823
+ return bn = a, bn;
1824
+ }
1825
+ var mn, Ns;
1826
+ function yc() {
1827
+ if (Ns) return mn;
1828
+ Ns = 1;
1829
+ function r(e, t, n) {
1830
+ var a;
1831
+ return n(e, function(i, s, o) {
1832
+ if (t(i, s, o))
1833
+ return a = s, !1;
1834
+ }), a;
1835
+ }
1836
+ return mn = r, mn;
1837
+ }
1838
+ var qn, Bs;
1839
+ function gc() {
1840
+ if (Bs) return qn;
1841
+ Bs = 1;
1842
+ var r = yc(), e = $n(), t = Zn();
1843
+ function n(a, i) {
1844
+ return r(a, t(i, 3), e);
1845
+ }
1846
+ return qn = n, qn;
1847
+ }
1848
+ var Cn, js;
1849
+ function _c() {
1850
+ if (js) return Cn;
1851
+ js = 1;
1852
+ function r(e) {
1853
+ return e && e.length ? e[0] : void 0;
1854
+ }
1855
+ return Cn = r, Cn;
1856
+ }
1857
+ var Fn, ks;
1858
+ function bc() {
1859
+ return ks || (ks = 1, Fn = _c()), Fn;
1860
+ }
1861
+ var Rn, Hs;
1862
+ function mc() {
1863
+ if (Hs) return Rn;
1864
+ Hs = 1;
1865
+ function r(e, t) {
1866
+ for (var n = -1, a = e == null ? 0 : e.length; ++n < a && t(e[n], n, e) !== !1; )
1867
+ ;
1868
+ return e;
1869
+ }
1870
+ return Rn = r, Rn;
1871
+ }
1872
+ var An, Gs;
1873
+ function Cu() {
1874
+ if (Gs) return An;
1875
+ Gs = 1;
1876
+ var r = Ae();
1877
+ function e(t) {
1878
+ return typeof t == "function" ? t : r;
1879
+ }
1880
+ return An = e, An;
1881
+ }
1882
+ var wn, Us;
1883
+ function qc() {
1884
+ if (Us) return wn;
1885
+ Us = 1;
1886
+ var r = mc(), e = Yn(), t = Cu(), n = re();
1887
+ function a(i, s) {
1888
+ var o = n(i) ? r : e;
1889
+ return o(i, t(s));
1890
+ }
1891
+ return wn = a, wn;
1892
+ }
1893
+ var Tn, zs;
1894
+ function Cc() {
1895
+ if (zs) return Tn;
1896
+ zs = 1;
1897
+ var r = $n(), e = Cu();
1898
+ function t(n, a) {
1899
+ return n && r(n, e(a));
1900
+ }
1901
+ return Tn = t, Tn;
1902
+ }
1903
+ var xn, Ws;
1904
+ function Fc() {
1905
+ if (Ws) return xn;
1906
+ Ws = 1;
1907
+ function r() {
1908
+ }
1909
+ return xn = r, xn;
1910
+ }
1911
+ var Sn, $s;
1912
+ function Rc() {
1913
+ if ($s) return Sn;
1914
+ $s = 1;
1915
+ var r = Yn(), e = we();
1916
+ function t(n, a) {
1917
+ var i = -1, s = e(n) ? Array(n.length) : [];
1918
+ return r(n, function(o, l, h) {
1919
+ s[++i] = a(o, l, h);
1920
+ }), s;
1921
+ }
1922
+ return Sn = t, Sn;
1923
+ }
1924
+ var On, Ys;
1925
+ function Ac() {
1926
+ if (Ys) return On;
1927
+ Ys = 1;
1928
+ function r(e, t) {
1929
+ var n = e.length;
1930
+ for (e.sort(t); n--; )
1931
+ e[n] = e[n].value;
1932
+ return e;
1933
+ }
1934
+ return On = r, On;
1935
+ }
1936
+ var Kn, Js;
1937
+ function wc() {
1938
+ if (Js) return Kn;
1939
+ Js = 1;
1940
+ var r = Re();
1941
+ function e(t, n) {
1942
+ if (t !== n) {
1943
+ var a = t !== void 0, i = t === null, s = t === t, o = r(t), l = n !== void 0, h = n === null, m = n === n, _ = r(n);
1944
+ if (!h && !_ && !o && t > n || o && l && m && !h && !_ || i && l && m || !a && m || !s)
1945
+ return 1;
1946
+ if (!i && !o && !_ && t < n || _ && a && s && !i && !o || h && a && s || !l && s || !m)
1947
+ return -1;
1948
+ }
1949
+ return 0;
1950
+ }
1951
+ return Kn = e, Kn;
1952
+ }
1953
+ var En, Xs;
1954
+ function Tc() {
1955
+ if (Xs) return En;
1956
+ Xs = 1;
1957
+ var r = wc();
1958
+ function e(t, n, a) {
1959
+ for (var i = -1, s = t.criteria, o = n.criteria, l = s.length, h = a.length; ++i < l; ) {
1960
+ var m = r(s[i], o[i]);
1961
+ if (m) {
1962
+ if (i >= h)
1963
+ return m;
1964
+ var _ = a[i];
1965
+ return m * (_ == "desc" ? -1 : 1);
1966
+ }
1967
+ }
1968
+ return t.index - n.index;
1969
+ }
1970
+ return En = e, En;
1971
+ }
1972
+ var Pn, Zs;
1973
+ function xc() {
1974
+ if (Zs) return Pn;
1975
+ Zs = 1;
1976
+ var r = kn(), e = Xn(), t = Zn(), n = Rc(), a = Ac(), i = Hn(), s = Tc(), o = Ae(), l = re();
1977
+ function h(m, _, O) {
1978
+ _.length ? _ = r(_, function(K) {
1979
+ return l(K) ? function(b) {
1980
+ return e(b, K.length === 1 ? K[0] : K);
1981
+ } : K;
1982
+ }) : _ = [o];
1983
+ var E = -1;
1984
+ _ = r(_, i(t));
1985
+ var L = n(m, function(K, b, d) {
1986
+ var p = r(_, function(q) {
1987
+ return q(K);
1988
+ });
1989
+ return { criteria: p, index: ++E, value: K };
1990
+ });
1991
+ return a(L, function(K, b) {
1992
+ return s(K, b, O);
1993
+ });
1994
+ }
1995
+ return Pn = h, Pn;
1996
+ }
1997
+ var Mn, Qs;
1998
+ function Sc() {
1999
+ if (Qs) return Mn;
2000
+ Qs = 1;
2001
+ var r = Nn(), e = we(), t = zn(), n = le();
2002
+ function a(i, s, o) {
2003
+ if (!n(o))
2004
+ return !1;
2005
+ var l = typeof s;
2006
+ return (l == "number" ? e(o) && t(s, o.length) : l == "string" && s in o) ? r(o[s], i) : !1;
2007
+ }
2008
+ return Mn = a, Mn;
2009
+ }
2010
+ var In, Vs;
2011
+ function Oc() {
2012
+ if (Vs) return In;
2013
+ Vs = 1;
2014
+ var r = fu(), e = xc(), t = lu(), n = Sc(), a = t(function(i, s) {
2015
+ if (i == null)
2016
+ return [];
2017
+ var o = s.length;
2018
+ return o > 1 && n(i, s[0], s[1]) ? s = [] : o > 2 && n(s[0], s[1], s[2]) && (s = [s[0]]), e(i, r(s, 1), []);
2019
+ });
2020
+ return In = a, In;
2021
+ }
2022
+ var Dn, eu;
2023
+ function Kc() {
2024
+ if (eu) return Dn;
2025
+ eu = 1;
2026
+ var r = au(), e = le(), t = "Expected a function";
2027
+ function n(a, i, s) {
2028
+ var o = !0, l = !0;
2029
+ if (typeof a != "function")
2030
+ throw new TypeError(t);
2031
+ return e(s) && (o = "leading" in s ? !!s.leading : o, l = "trailing" in s ? !!s.trailing : l), r(a, i, {
2032
+ leading: o,
2033
+ maxWait: i,
2034
+ trailing: l
2035
+ });
2036
+ }
2037
+ return Dn = n, Dn;
2038
+ }
2039
+ var Ln, ru;
2040
+ function Ec() {
2041
+ if (ru) return Ln;
2042
+ ru = 1;
2043
+ var r = mu(), e = 0;
2044
+ function t(n) {
2045
+ var a = ++e;
2046
+ return r(n) + a;
2047
+ }
2048
+ return Ln = t, Ln;
2049
+ }
2050
+ var Pc = Ke.exports, tu;
2051
+ function Mc() {
2052
+ return tu || (tu = 1, (function(r, e) {
2053
+ (function(t, n) {
2054
+ r.exports = n(au(), bo(), pc(), gc(), bc(), qc(), Cc(), Fc(), Oc(), Kc(), Ec(), Au);
2055
+ })(Pc, (function(t, n, a, i, s, o, l, h, m, _, O, E) {
2056
+ return (function() {
2057
+ var L = { 654: function(b, d, p) {
2058
+ var q, g = this && this.__assign || function() {
2059
+ return g = Object.assign || function(y) {
2060
+ for (var u, c = 1, f = arguments.length; c < f; c++) for (var v in u = arguments[c]) Object.prototype.hasOwnProperty.call(u, v) && (y[v] = u[v]);
2061
+ return y;
2062
+ }, g.apply(this, arguments);
2063
+ }, P = this && this.__createBinding || (Object.create ? function(y, u, c, f) {
2064
+ f === void 0 && (f = c);
2065
+ var v = Object.getOwnPropertyDescriptor(u, c);
2066
+ v && !("get" in v ? !u.__esModule : v.writable || v.configurable) || (v = { enumerable: !0, get: function() {
2067
+ return u[c];
2068
+ } }), Object.defineProperty(y, f, v);
2069
+ } : function(y, u, c, f) {
2070
+ f === void 0 && (f = c), y[f] = u[c];
2071
+ }), x = this && this.__setModuleDefault || (Object.create ? function(y, u) {
2072
+ Object.defineProperty(y, "default", { enumerable: !0, value: u });
2073
+ } : function(y, u) {
2074
+ y.default = u;
2075
+ }), F = this && this.__importStar || function(y) {
2076
+ if (y && y.__esModule) return y;
2077
+ var u = {};
2078
+ if (y != null) for (var c in y) c !== "default" && Object.prototype.hasOwnProperty.call(y, c) && P(u, y, c);
2079
+ return x(u, y), u;
2080
+ }, N = this && this.__spreadArray || function(y, u, c) {
2081
+ if (c || arguments.length === 2) for (var f, v = 0, C = u.length; v < C; v++) !f && v in u || (f || (f = Array.prototype.slice.call(u, 0, v)), f[v] = u[v]);
2082
+ return y.concat(f || Array.prototype.slice.call(u));
2083
+ }, R = this && this.__importDefault || function(y) {
2084
+ return y && y.__esModule ? y : { default: y };
2085
+ };
2086
+ Object.defineProperty(d, "__esModule", { value: !0 }), d.updateRtl = d.doesFocusableExist = d.getCurrentFocusKey = d.updateAllLayouts = d.resume = d.pause = d.navigateByDirection = d.setFocus = d.setKeyMap = d.destroy = d.setThrottle = d.init = d.SpatialNavigation = d.ROOT_FOCUS_KEY = void 0;
2087
+ var S = R(p(150)), M = R(p(117)), H = R(p(747)), w = R(p(23)), U = R(p(842)), J = R(p(682)), te = R(p(784)), ve = R(p(432)), Le = R(p(67)), Te = R(p(35)), Q = R(p(119)), pe = F(p(964)), ue = "left", oe = "right", ce = "up", ne = "down", ye = "enter", ge = ((q = {}).left = [37, "ArrowLeft"], q.up = [38, "ArrowUp"], q.right = [39, "ArrowRight"], q.down = [40, "ArrowDown"], q.enter = [13, "Enter"], q);
2088
+ d.ROOT_FOCUS_KEY = "SN:ROOT";
2089
+ var _e = ["#0FF", "#FF0", "#F0F"], xe = { leading: !0, trailing: !1 }, Se = (function() {
2090
+ function y() {
2091
+ this.focusableComponents = {}, this.focusKey = null, this.parentsHavingFocusedChild = [], this.domNodeFocusOptions = {}, this.enabled = !1, this.nativeMode = !1, this.throttle = 0, this.throttleKeypresses = !1, this.useGetBoundingClientRect = !1, this.shouldFocusDOMNode = !1, this.shouldUseNativeEvents = !1, this.writingDirection = Q.default.LTR, this.pressedKeys = {}, this.paused = !1, this.keyDownEventListener = null, this.keyUpEventListener = null, this.keyMap = ge, this.pause = this.pause.bind(this), this.resume = this.resume.bind(this), this.setFocus = this.setFocus.bind(this), this.updateAllLayouts = this.updateAllLayouts.bind(this), this.navigateByDirection = this.navigateByDirection.bind(this), this.init = this.init.bind(this), this.setThrottle = this.setThrottle.bind(this), this.destroy = this.destroy.bind(this), this.setKeyMap = this.setKeyMap.bind(this), this.getCurrentFocusKey = this.getCurrentFocusKey.bind(this), this.doesFocusableExist = this.doesFocusableExist.bind(this), this.updateRtl = this.updateRtl.bind(this), this.setFocusDebounced = (0, S.default)(this.setFocus, 300, { leading: !1, trailing: !0 }), this.debug = !1, this.visualDebugger = null, this.logIndex = 0, this.distanceCalculationMethod = "corners";
2092
+ }
2093
+ return y.getCutoffCoordinate = function(u, c, f, v, C) {
2094
+ var A = u ? v.top : C === Q.default.LTR ? v.left : v.right, T = u ? v.bottom : C === Q.default.LTR ? v.right : v.left;
2095
+ return c ? f ? A : T : f ? T : A;
2096
+ }, y.getRefCorners = function(u, c, f) {
2097
+ var v = { a: { x: 0, y: 0 }, b: { x: 0, y: 0 } };
2098
+ switch (u) {
2099
+ case ce:
2100
+ var C = c ? f.bottom : f.top;
2101
+ v.a = { x: f.left, y: C }, v.b = { x: f.right, y: C };
2102
+ break;
2103
+ case ne:
2104
+ C = c ? f.top : f.bottom, v.a = { x: f.left, y: C }, v.b = { x: f.right, y: C };
2105
+ break;
2106
+ case ue:
2107
+ var A = c ? f.right : f.left;
2108
+ v.a = { x: A, y: f.top }, v.b = { x: A, y: f.bottom };
2109
+ break;
2110
+ case oe:
2111
+ A = c ? f.left : f.right, v.a = { x: A, y: f.top }, v.b = { x: A, y: f.bottom };
2112
+ }
2113
+ return v;
2114
+ }, y.isAdjacentSlice = function(u, c, f) {
2115
+ var v = u.a, C = u.b, A = c.a, T = c.b, I = f ? "x" : "y", G = v[I], k = C[I], j = A[I], B = T[I], D = 0.2 * (k - G);
2116
+ return Math.max(0, Math.min(k, B) - Math.max(G, j)) >= D;
2117
+ }, y.getPrimaryAxisDistance = function(u, c, f) {
2118
+ var v = u.a, C = c.a, A = f ? "y" : "x";
2119
+ return Math.abs(C[A] - v[A]);
2120
+ }, y.getSecondaryAxisDistance = function(u, c, f, v, C) {
2121
+ if (C) return C(u, c, f, v);
2122
+ var A = u.a, T = u.b, I = c.a, G = c.b, k = f ? "x" : "y", j = A[k], B = T[k], D = I[k], Y = G[k];
2123
+ if (v === "center") {
2124
+ var W = (j + B) / 2, X = (D + Y) / 2;
2125
+ return Math.abs(W - X);
2126
+ }
2127
+ if (v === "edges") {
2128
+ var se = Math.min(j, B), z = Math.min(D, Y), V = Math.max(j, B), fe = Math.max(D, Y), ae = Math.abs(se - z), ee = Math.abs(V - fe);
2129
+ return Math.min(ae, ee);
2130
+ }
2131
+ var be = [Math.abs(D - j), Math.abs(D - B), Math.abs(Y - j), Math.abs(Y - B)];
2132
+ return Math.min.apply(Math, be);
2133
+ }, y.prototype.sortSiblingsByPriority = function(u, c, f, v) {
2134
+ var C = this, A = f === ne || f === ce, T = y.getRefCorners(f, !1, c);
2135
+ return (0, ve.default)(u, (function(I) {
2136
+ var G = y.getRefCorners(f, !0, I.layout), k = y.isAdjacentSlice(T, G, A), j = k ? y.getPrimaryAxisDistance : y.getSecondaryAxisDistance, B = k ? y.getSecondaryAxisDistance : y.getPrimaryAxisDistance, D = j(T, G, A, C.distanceCalculationMethod, C.customDistanceCalculationFunction), Y = B(T, G, A, C.distanceCalculationMethod, C.customDistanceCalculationFunction), W = 5 * D + Y, X = (W + 1) / (k ? 5 : 1);
2137
+ return C.log("smartNavigate", "distance (primary, secondary, total weighted) for ".concat(I.focusKey, " relative to ").concat(v, " is"), D, Y, W), C.log("smartNavigate", "priority for ".concat(I.focusKey, " relative to ").concat(v, " is"), X), C.visualDebugger && (C.visualDebugger.drawPoint(G.a.x, G.a.y, "yellow", 6), C.visualDebugger.drawPoint(G.b.x, G.b.y, "yellow", 6)), X;
2138
+ }));
2139
+ }, y.prototype.init = function(u) {
2140
+ var c = this, f = u === void 0 ? {} : u, v = f.debug, C = v !== void 0 && v, A = f.visualDebug, T = A !== void 0 && A, I = f.nativeMode, G = I !== void 0 && I, k = f.throttle, j = k === void 0 ? 0 : k, B = f.throttleKeypresses, D = B !== void 0 && B, Y = f.useGetBoundingClientRect, W = Y !== void 0 && Y, X = f.shouldFocusDOMNode, se = X !== void 0 && X, z = f.domNodeFocusOptions, V = z === void 0 ? {} : z, fe = f.shouldUseNativeEvents, ae = fe !== void 0 && fe, ee = f.rtl, be = ee !== void 0 && ee, $ = f.distanceCalculationMethod, Z = $ === void 0 ? "corners" : $, Qn = f.customDistanceCalculationFunction, Fu = Qn === void 0 ? void 0 : Qn;
2141
+ if (!this.enabled && (this.domNodeFocusOptions = V, this.enabled = !0, this.nativeMode = G, this.throttleKeypresses = D, this.useGetBoundingClientRect = W, this.shouldFocusDOMNode = se && !G, this.shouldUseNativeEvents = ae, this.writingDirection = be ? Q.default.RTL : Q.default.LTR, this.distanceCalculationMethod = Z, this.customDistanceCalculationFunction = Fu, this.debug = C, !this.nativeMode && (Number.isInteger(j) && j > 0 && (this.throttle = j), this.bindEventHandlers(), T))) {
2142
+ this.visualDebugger = new Te.default(this.writingDirection);
2143
+ var Vn = function() {
2144
+ requestAnimationFrame((function() {
2145
+ c.visualDebugger.clearLayouts(), (0, te.default)(c.focusableComponents, (function(ea, Ru) {
2146
+ c.visualDebugger.drawLayout(ea.layout, Ru, ea.parentFocusKey);
2147
+ })), Vn();
2148
+ }));
2149
+ };
2150
+ Vn();
2151
+ }
2152
+ }, y.prototype.setThrottle = function(u) {
2153
+ var c = u === void 0 ? {} : u, f = c.throttle, v = f === void 0 ? 0 : f, C = c.throttleKeypresses, A = C !== void 0 && C;
2154
+ this.throttleKeypresses = A, this.nativeMode || (this.unbindEventHandlers(), Number.isInteger(v) && (this.throttle = v), this.bindEventHandlers());
2155
+ }, y.prototype.destroy = function() {
2156
+ this.enabled && (this.enabled = !1, this.nativeMode = !1, this.throttle = 0, this.throttleKeypresses = !1, this.focusKey = null, this.parentsHavingFocusedChild = [], this.focusableComponents = {}, this.paused = !1, this.keyMap = ge, this.unbindEventHandlers());
2157
+ }, y.prototype.getEventType = function(u) {
2158
+ return (0, w.default)(this.getKeyMap(), (function(c) {
2159
+ return c.includes(u);
2160
+ }));
2161
+ }, y.getKeyCode = function(u) {
2162
+ return u.keyCode || u.code || u.key;
2163
+ }, y.prototype.bindEventHandlers = function() {
2164
+ var u = this;
2165
+ typeof window < "u" && window.addEventListener && (this.keyDownEventListener = function(c) {
2166
+ if (u.paused !== !0) {
2167
+ u.debug && (u.logIndex += 1);
2168
+ var f = y.getKeyCode(c), v = u.getEventType(f);
2169
+ if (v) {
2170
+ u.pressedKeys[v] = u.pressedKeys[v] ? u.pressedKeys[v] + 1 : 1, u.shouldUseNativeEvents || (c.preventDefault(), c.stopPropagation());
2171
+ var C = { pressedKeys: u.pressedKeys };
2172
+ if (v === ye && u.focusKey) u.onEnterPress(C);
2173
+ else {
2174
+ var A = u.onArrowPress(v, C) === !1;
2175
+ if (u.visualDebugger && u.visualDebugger.clear(), A) u.log("keyDownEventListener", "default navigation prevented");
2176
+ else {
2177
+ var T = (0, w.default)(u.getKeyMap(), (function(I) {
2178
+ return I.includes(f);
2179
+ }));
2180
+ u.smartNavigate(T, null, { event: c });
2181
+ }
2182
+ }
2183
+ }
248
2184
  }
249
- },
250
- onVolumeChange: (s) => {
251
- const r = s.target.muted;
252
- q.current !== r && (M?.(r), q.current = r, (r !== w || w === void 0) && (r ? P() : _()));
253
- },
254
- onError: async (s) => {
255
- try {
256
- if (s.target instanceof HTMLVideoElement) {
257
- K(!0);
258
- const r = await (await fetch(s.target.src)).blob(), g = URL.createObjectURL(r);
259
- s.target.src = g;
2185
+ }, this.throttle && (this.keyDownEventListenerThrottled = (0, Le.default)(this.keyDownEventListener.bind(this), this.throttle, xe)), this.keyUpEventListener = function(c) {
2186
+ var f = y.getKeyCode(c), v = u.getEventType(f);
2187
+ delete u.pressedKeys[v], u.throttle && !u.throttleKeypresses && u.keyDownEventListenerThrottled.cancel(), v === ye && u.focusKey && u.onEnterRelease(), !u.focusKey || v !== ue && v !== oe && v !== ce && v !== ne || u.onArrowRelease(v);
2188
+ }, window.addEventListener("keyup", this.keyUpEventListener), window.addEventListener("keydown", this.throttle ? this.keyDownEventListenerThrottled : this.keyDownEventListener));
2189
+ }, y.prototype.unbindEventHandlers = function() {
2190
+ if (typeof window < "u" && window.removeEventListener) {
2191
+ window.removeEventListener("keyup", this.keyUpEventListener), this.keyUpEventListener = null;
2192
+ var u = this.throttle ? this.keyDownEventListenerThrottled : this.keyDownEventListener;
2193
+ window.removeEventListener("keydown", u), this.keyDownEventListener = null;
2194
+ }
2195
+ }, y.prototype.onEnterPress = function(u) {
2196
+ var c = this.focusableComponents[this.focusKey];
2197
+ c ? c.focusable ? c.onEnterPress && c.onEnterPress(u) : this.log("onEnterPress", "componentNotFocusable") : this.log("onEnterPress", "noComponent");
2198
+ }, y.prototype.onEnterRelease = function() {
2199
+ var u = this.focusableComponents[this.focusKey];
2200
+ u ? u.focusable ? u.onEnterRelease && u.onEnterRelease() : this.log("onEnterRelease", "componentNotFocusable") : this.log("onEnterRelease", "noComponent");
2201
+ }, y.prototype.onArrowPress = function(u, c) {
2202
+ var f = this.focusableComponents[this.focusKey];
2203
+ if (f) return f && f.onArrowPress && f.onArrowPress(u, c);
2204
+ this.log("onArrowPress", "noComponent");
2205
+ }, y.prototype.onArrowRelease = function(u) {
2206
+ var c = this.focusableComponents[this.focusKey];
2207
+ c ? c.focusable ? c.onArrowRelease && c.onArrowRelease(u) : this.log("onArrowRelease", "componentNotFocusable") : this.log("onArrowRelease", "noComponent");
2208
+ }, y.prototype.navigateByDirection = function(u, c) {
2209
+ if (this.paused !== !0 && this.enabled && !this.nativeMode) {
2210
+ var f = [ne, ce, ue, oe];
2211
+ f.includes(u) ? (this.log("navigateByDirection", "direction", u), this.smartNavigate(u, null, c)) : this.log("navigateByDirection", "Invalid direction. You passed: `".concat(u, "`, but you can use only these: "), f);
2212
+ }
2213
+ }, y.prototype.smartNavigate = function(u, c, f) {
2214
+ var v = this;
2215
+ if (!this.nativeMode) {
2216
+ var C = u === ne || u === ce, A = u === ne || (this.writingDirection === Q.default.LTR ? u === oe : u === ue);
2217
+ this.log("smartNavigate", "direction", u), this.log("smartNavigate", "fromParentFocusKey", c), this.log("smartNavigate", "this.focusKey", this.focusKey), c || (0, te.default)(this.focusableComponents, (function(z) {
2218
+ z.layoutUpdated = !1;
2219
+ }));
2220
+ var T = this.focusableComponents[c || this.focusKey];
2221
+ if (c || T) {
2222
+ if (this.log("smartNavigate", "currentComponent", T ? T.focusKey : void 0, T ? T.node : void 0, T), T) {
2223
+ this.updateLayout(T.focusKey);
2224
+ var I = T.parentFocusKey, G = T.focusKey, k = T.layout, j = y.getCutoffCoordinate(C, A, !1, k, this.writingDirection), B = (0, H.default)(this.focusableComponents, (function(z) {
2225
+ if (z.parentFocusKey === I && z.focusable) {
2226
+ v.updateLayout(z.focusKey);
2227
+ var V = y.getCutoffCoordinate(C, A, !0, z.layout, v.writingDirection);
2228
+ return C || v.writingDirection === Q.default.LTR ? A ? V >= j : V <= j : A ? V <= j : V >= j;
2229
+ }
2230
+ return !1;
2231
+ }));
2232
+ if (this.debug && (this.log("smartNavigate", "currentCutoffCoordinate", j), this.log("smartNavigate", "siblings", "".concat(B.length, " elements:"), B.map((function(z) {
2233
+ return z.focusKey;
2234
+ })).join(", "), B.map((function(z) {
2235
+ return z.node;
2236
+ })), B.map((function(z) {
2237
+ return z;
2238
+ })))), this.visualDebugger) {
2239
+ var D = y.getRefCorners(u, !1, k);
2240
+ this.visualDebugger.drawPoint(D.a.x, D.a.y), this.visualDebugger.drawPoint(D.b.x, D.b.y);
2241
+ }
2242
+ var Y = this.sortSiblingsByPriority(B, k, u, G), W = (0, U.default)(Y);
2243
+ if (this.log("smartNavigate", "nextComponent", W ? W.focusKey : void 0, W ? W.node : void 0, W), W) this.setFocus(W.focusKey, f);
2244
+ else {
2245
+ var X = this.focusableComponents[I], se = X?.isFocusBoundary ? X.focusBoundaryDirections || [u] : [];
2246
+ X && se.includes(u) || this.smartNavigate(u, I, f);
2247
+ }
260
2248
  }
261
- } catch (r) {
262
- console.error("video fallback fetch failed", r), W(!0), E(!0);
263
- } finally {
264
- K(!1), P();
2249
+ } else this.setFocus(this.getForcedFocusKey());
2250
+ }
2251
+ }, y.prototype.saveLastFocusedChildKey = function(u, c) {
2252
+ u && (this.log("saveLastFocusedChildKey", "".concat(u.focusKey, " lastFocusedChildKey set"), c), u.lastFocusedChildKey = c);
2253
+ }, y.prototype.log = function(u, c) {
2254
+ for (var f = [], v = 2; v < arguments.length; v++) f[v - 2] = arguments[v];
2255
+ this.debug && console.log.apply(console, N(["%c".concat(u, "%c").concat(c), "background: ".concat(_e[this.logIndex % _e.length], "; color: black; padding: 1px 5px;"), "background: #333; color: #BADA55; padding: 1px 5px;"], f, !1));
2256
+ }, y.prototype.getCurrentFocusKey = function() {
2257
+ return this.focusKey;
2258
+ }, y.prototype.getForcedFocusKey = function() {
2259
+ var u, c = (0, H.default)(this.focusableComponents, (function(v) {
2260
+ return v.focusable && v.forceFocus;
2261
+ })), f = this.sortSiblingsByPriority(c, { x: 0, y: 0, width: 0, height: 0, left: 0, top: 0, right: 0, bottom: 0, node: null }, "down", d.ROOT_FOCUS_KEY);
2262
+ return (u = (0, U.default)(f)) === null || u === void 0 ? void 0 : u.focusKey;
2263
+ }, y.prototype.getNextFocusKey = function(u) {
2264
+ var c = this, f = this.focusableComponents[u];
2265
+ if (!f || this.nativeMode) return u;
2266
+ var v = (0, H.default)(this.focusableComponents, (function(I) {
2267
+ return I.parentFocusKey === u && I.focusable;
2268
+ }));
2269
+ if (v.length > 0) {
2270
+ var C = f.lastFocusedChildKey, A = f.preferredChildFocusKey;
2271
+ if (this.log("getNextFocusKey", "lastFocusedChildKey is", C), this.log("getNextFocusKey", "preferredChildFocusKey is", A), C && f.saveLastFocusedChild && this.isParticipatingFocusableComponent(C)) return this.log("getNextFocusKey", "lastFocusedChildKey will be focused", C), this.getNextFocusKey(C);
2272
+ if (A && this.isParticipatingFocusableComponent(A)) return this.log("getNextFocusKey", "preferredChildFocusKey will be focused", A), this.getNextFocusKey(A);
2273
+ v.forEach((function(I) {
2274
+ return c.updateLayout(I.focusKey);
2275
+ }));
2276
+ var T = (function(I, G) {
2277
+ var k = G === Q.default.LTR ? function(B) {
2278
+ var D = B.layout;
2279
+ return Math.abs(D.left) + Math.abs(D.top);
2280
+ } : function(B) {
2281
+ var D = B.layout;
2282
+ return Math.abs(window.innerWidth - D.right) + Math.abs(D.top);
2283
+ }, j = (0, ve.default)(I, k);
2284
+ return (0, U.default)(j);
2285
+ })(v, this.writingDirection).focusKey;
2286
+ return this.log("getNextFocusKey", "childKey will be focused", T), this.getNextFocusKey(T);
2287
+ }
2288
+ return this.log("getNextFocusKey", "targetFocusKey", u), u;
2289
+ }, y.prototype.addFocusable = function(u) {
2290
+ var c = u.focusKey, f = u.node, v = u.parentFocusKey, C = u.onEnterPress, A = u.onEnterRelease, T = u.onArrowPress, I = u.onArrowRelease, G = u.onFocus, k = u.onBlur, j = u.saveLastFocusedChild, B = u.trackChildren, D = u.onUpdateFocus, Y = u.onUpdateHasFocusedChild, W = u.preferredChildFocusKey, X = u.autoRestoreFocus, se = u.forceFocus, z = u.focusable, V = u.isFocusBoundary, fe = u.focusBoundaryDirections;
2291
+ if (this.focusableComponents[c] = { focusKey: c, node: f, parentFocusKey: v, onEnterPress: C, onEnterRelease: A, onArrowPress: T, onArrowRelease: I, onFocus: G, onBlur: k, onUpdateFocus: D, onUpdateHasFocusedChild: Y, saveLastFocusedChild: j, trackChildren: B, preferredChildFocusKey: W, focusable: z, isFocusBoundary: V, focusBoundaryDirections: fe, autoRestoreFocus: X, forceFocus: se, lastFocusedChildKey: null, layout: { x: 0, y: 0, width: 0, height: 0, left: 0, top: 0, right: 0, bottom: 0, node: f }, layoutUpdated: !1 }, f || console.warn('Component added without a node reference. This will result in its coordinates being empty and may cause lost focus. Check the "ref" passed to "useFocusable": ', this.focusableComponents[c]), !this.nativeMode) {
2292
+ this.updateLayout(c), this.log("addFocusable", "Component added: ", this.focusableComponents[c]), c === this.focusKey && this.setFocus(W || c);
2293
+ for (var ae = this.focusableComponents[this.focusKey]; ae; ) {
2294
+ if (ae.parentFocusKey === c) {
2295
+ this.updateParentsHasFocusedChild(this.focusKey, {}), this.updateParentsLastFocusedChild(this.focusKey);
2296
+ break;
2297
+ }
2298
+ ae = this.focusableComponents[ae.parentFocusKey];
2299
+ }
2300
+ }
2301
+ }, y.prototype.removeFocusable = function(u) {
2302
+ var c = u.focusKey, f = this.focusableComponents[c];
2303
+ if (f) {
2304
+ var v = f.parentFocusKey;
2305
+ (0, f.onUpdateFocus)(!1), this.log("removeFocusable", "Component removed: ", f), delete this.focusableComponents[c];
2306
+ var C = this.parentsHavingFocusedChild.includes(c);
2307
+ this.parentsHavingFocusedChild = this.parentsHavingFocusedChild.filter((function(I) {
2308
+ return I !== c;
2309
+ }));
2310
+ var A = this.focusableComponents[v], T = c === this.focusKey;
2311
+ if (A && A.lastFocusedChildKey === c && (A.lastFocusedChildKey = null), this.nativeMode) return;
2312
+ (T || C) && A && A.autoRestoreFocus && (this.log("removeFocusable", "Component removed: ", T ? "Leaf component" : "Container component", "Auto restoring focus to: ", v), this.setFocusDebounced(v));
2313
+ }
2314
+ }, y.prototype.getNodeLayoutByFocusKey = function(u) {
2315
+ var c = this.focusableComponents[u];
2316
+ return c ? (this.updateLayout(c.focusKey), c.layout) : null;
2317
+ }, y.prototype.setCurrentFocusedKey = function(u, c) {
2318
+ var f, v, C, A;
2319
+ if (this.isFocusableComponent(this.focusKey) && u !== this.focusKey) {
2320
+ var T = this.focusableComponents[this.focusKey];
2321
+ T.onUpdateFocus(!1), T.onBlur(this.getNodeLayoutByFocusKey(this.focusKey), c), (v = (f = T.node) === null || f === void 0 ? void 0 : f.removeAttribute) === null || v === void 0 || v.call(f, "data-focused"), this.log("setCurrentFocusedKey", "onBlur", T);
2322
+ }
2323
+ if (this.focusKey = u, this.isFocusableComponent(this.focusKey)) {
2324
+ var I = this.focusableComponents[this.focusKey];
2325
+ this.shouldFocusDOMNode && I.node && I.node.focus(this.domNodeFocusOptions), (A = (C = I.node) === null || C === void 0 ? void 0 : C.setAttribute) === null || A === void 0 || A.call(C, "data-focused", "true"), I.onUpdateFocus(!0), I.onFocus(this.getNodeLayoutByFocusKey(this.focusKey), c), this.log("setCurrentFocusedKey", "onFocus", I);
2326
+ }
2327
+ }, y.prototype.updateParentsHasFocusedChild = function(u, c) {
2328
+ for (var f = this, v = [], C = this.focusableComponents[u]; C; ) {
2329
+ var A = C.parentFocusKey, T = this.focusableComponents[A];
2330
+ if (T) {
2331
+ var I = T.focusKey;
2332
+ v.push(I);
265
2333
  }
266
- },
267
- onPause: () => {
268
- W(!1), d?.(), P();
269
- },
270
- onEnded: () => {
271
- W(!1), j.current = !0, oe(), p?.(), P();
272
- },
273
- style: { visibility: Q ? "hidden" : "visible" },
274
- controls: !1,
275
- playsInline: !0
2334
+ C = T;
2335
+ }
2336
+ var G = (0, M.default)(this.parentsHavingFocusedChild, v), k = (0, M.default)(v, this.parentsHavingFocusedChild);
2337
+ (0, J.default)(G, (function(j) {
2338
+ var B = f.focusableComponents[j];
2339
+ B && B.trackChildren && B.onUpdateHasFocusedChild(!1), f.onIntermediateNodeBecameBlurred(j, c);
2340
+ })), (0, J.default)(k, (function(j) {
2341
+ var B = f.focusableComponents[j];
2342
+ B && B.trackChildren && B.onUpdateHasFocusedChild(!0), f.onIntermediateNodeBecameFocused(j, c);
2343
+ })), this.parentsHavingFocusedChild = v;
2344
+ }, y.prototype.updateParentsLastFocusedChild = function(u) {
2345
+ for (var c = this.focusableComponents[u]; c; ) {
2346
+ var f = c.parentFocusKey, v = this.focusableComponents[f];
2347
+ v && this.saveLastFocusedChildKey(v, c.focusKey), c = v;
2348
+ }
2349
+ }, y.prototype.getKeyMap = function() {
2350
+ return this.keyMap;
2351
+ }, y.prototype.setKeyMap = function(u) {
2352
+ this.keyMap = g(g({}, this.getKeyMap()), (function(c) {
2353
+ var f = {};
2354
+ return Object.entries(c).forEach((function(v) {
2355
+ var C = v[0], A = v[1];
2356
+ f[C] = Array.isArray(A) ? A : [A];
2357
+ })), f;
2358
+ })(u));
2359
+ }, y.prototype.isFocusableComponent = function(u) {
2360
+ return !!this.focusableComponents[u];
2361
+ }, y.prototype.isParticipatingFocusableComponent = function(u) {
2362
+ return this.isFocusableComponent(u) && this.focusableComponents[u].focusable;
2363
+ }, y.prototype.onIntermediateNodeBecameFocused = function(u, c) {
2364
+ this.isParticipatingFocusableComponent(u) && this.focusableComponents[u].onFocus(this.getNodeLayoutByFocusKey(u), c);
2365
+ }, y.prototype.onIntermediateNodeBecameBlurred = function(u, c) {
2366
+ this.isParticipatingFocusableComponent(u) && this.focusableComponents[u].onBlur(this.getNodeLayoutByFocusKey(u), c);
2367
+ }, y.prototype.pause = function() {
2368
+ this.paused = !0;
2369
+ }, y.prototype.resume = function() {
2370
+ this.paused = !1;
2371
+ }, y.prototype.setFocus = function(u, c) {
2372
+ if (c === void 0 && (c = {}), this.setFocusDebounced.cancel(), this.enabled) {
2373
+ this.log("setFocus", "focusKey", u), u && u !== d.ROOT_FOCUS_KEY || (u = this.getForcedFocusKey());
2374
+ var f = this.getNextFocusKey(u);
2375
+ this.log("setFocus", "newFocusKey", f), this.setCurrentFocusedKey(f, c), this.updateParentsHasFocusedChild(f, c), this.updateParentsLastFocusedChild(f);
2376
+ }
2377
+ }, y.prototype.updateAllLayouts = function() {
2378
+ var u = this;
2379
+ this.enabled && !this.nativeMode && (0, te.default)(this.focusableComponents, (function(c, f) {
2380
+ u.updateLayout(f);
2381
+ }));
2382
+ }, y.prototype.updateLayout = function(u) {
2383
+ var c = this.focusableComponents[u];
2384
+ if (c && !this.nativeMode && !c.layoutUpdated) {
2385
+ var f = c.node, v = this.useGetBoundingClientRect ? (0, pe.getBoundingClientRect)(f) : (0, pe.default)(f);
2386
+ c.layout = g(g({}, v), { node: f });
2387
+ }
2388
+ }, y.prototype.updateFocusable = function(u, c) {
2389
+ var f = c.node, v = c.preferredChildFocusKey, C = c.focusable, A = c.isFocusBoundary, T = c.focusBoundaryDirections, I = c.onEnterPress, G = c.onEnterRelease, k = c.onArrowPress, j = c.onFocus, B = c.onBlur;
2390
+ if (!this.nativeMode) {
2391
+ var D = this.focusableComponents[u];
2392
+ D && (D.preferredChildFocusKey = v, D.focusable = C, D.isFocusBoundary = A, D.focusBoundaryDirections = T, D.onEnterPress = I, D.onEnterRelease = G, D.onArrowPress = k, D.onFocus = j, D.onBlur = B, f && (D.node = f));
2393
+ }
2394
+ }, y.prototype.isNativeMode = function() {
2395
+ return this.nativeMode;
2396
+ }, y.prototype.doesFocusableExist = function(u) {
2397
+ return !!this.focusableComponents[u];
2398
+ }, y.prototype.updateRtl = function(u) {
2399
+ this.writingDirection = u ? Q.default.RTL : Q.default.LTR;
2400
+ }, y;
2401
+ })();
2402
+ d.SpatialNavigation = new Se(), d.init = d.SpatialNavigation.init, d.setThrottle = d.SpatialNavigation.setThrottle, d.destroy = d.SpatialNavigation.destroy, d.setKeyMap = d.SpatialNavigation.setKeyMap, d.setFocus = d.SpatialNavigation.setFocus, d.navigateByDirection = d.SpatialNavigation.navigateByDirection, d.pause = d.SpatialNavigation.pause, d.resume = d.SpatialNavigation.resume, d.updateAllLayouts = d.SpatialNavigation.updateAllLayouts, d.getCurrentFocusKey = d.SpatialNavigation.getCurrentFocusKey, d.doesFocusableExist = d.SpatialNavigation.doesFocusableExist, d.updateRtl = d.SpatialNavigation.updateRtl;
2403
+ }, 35: function(b, d, p) {
2404
+ var q = this && this.__importDefault || function(R) {
2405
+ return R && R.__esModule ? R : { default: R };
2406
+ };
2407
+ Object.defineProperty(d, "__esModule", { value: !0 });
2408
+ var g = q(p(119)), P = typeof window < "u" && window.document, x = P ? window.innerWidth : 0, F = P ? window.innerHeight : 0, N = (function() {
2409
+ function R(S) {
2410
+ P && (this.debugCtx = R.createCanvas("sn-debug", "1010", S), this.layoutsCtx = R.createCanvas("sn-layouts", "1000", S), this.writingDirection = S);
276
2411
  }
277
- ),
278
- /* @__PURE__ */ e(he, { src: t, style: { visibility: Q ? "visible" : "hidden" } }),
279
- !x && /* @__PURE__ */ e(
280
- Ue,
281
- {
282
- loading: z,
283
- autoPlay: C,
284
- played: D,
285
- playing: B,
286
- isMuted: F,
287
- unmute: S,
288
- mute: v,
289
- togglePlaying: J
2412
+ return R.createCanvas = function(S, M, H) {
2413
+ var w = document.querySelector("#".concat(S)) || document.createElement("canvas");
2414
+ w.setAttribute("id", S), w.setAttribute("dir", H === g.default.LTR ? "ltr" : "rtl");
2415
+ var U = w.getContext("2d");
2416
+ return w.style.zIndex = M, w.style.position = "fixed", w.style.top = "0", w.style.left = "0", document.body.appendChild(w), w.width = x, w.height = F, U;
2417
+ }, R.prototype.clear = function() {
2418
+ P && this.debugCtx.clearRect(0, 0, x, F);
2419
+ }, R.prototype.clearLayouts = function() {
2420
+ P && this.layoutsCtx.clearRect(0, 0, x, F);
2421
+ }, R.prototype.drawLayout = function(S, M, H) {
2422
+ if (P) {
2423
+ this.layoutsCtx.strokeStyle = "green", this.layoutsCtx.strokeRect(S.left, S.top, S.width, S.height), this.layoutsCtx.font = "8px monospace", this.layoutsCtx.fillStyle = "red";
2424
+ var w = this.writingDirection === g.default.LTR ? "left" : "right", U = S[w];
2425
+ this.layoutsCtx.fillText(M, U, S.top + 10), this.layoutsCtx.fillText(H, U, S.top + 25), this.layoutsCtx.fillText("".concat(w, ": ").concat(U), U, S.top + 40), this.layoutsCtx.fillText("top: ".concat(S.top), U, S.top + 55);
2426
+ }
2427
+ }, R.prototype.drawPoint = function(S, M, H, w) {
2428
+ H === void 0 && (H = "blue"), w === void 0 && (w = 10), P && (this.debugCtx.strokeStyle = H, this.debugCtx.lineWidth = 3, this.debugCtx.strokeRect(S - w / 2, M - w / 2, w, w));
2429
+ }, R;
2430
+ })();
2431
+ d.default = N;
2432
+ }, 119: function(b, d) {
2433
+ var p;
2434
+ Object.defineProperty(d, "__esModule", { value: !0 }), (function(q) {
2435
+ q[q.LTR = 0] = "LTR", q[q.RTL = 1] = "RTL";
2436
+ })(p || (p = {})), d.default = p;
2437
+ }, 607: function(b, d, p) {
2438
+ var q = this && this.__createBinding || (Object.create ? function(P, x, F, N) {
2439
+ N === void 0 && (N = F);
2440
+ var R = Object.getOwnPropertyDescriptor(x, F);
2441
+ R && !("get" in R ? !x.__esModule : R.writable || R.configurable) || (R = { enumerable: !0, get: function() {
2442
+ return x[F];
2443
+ } }), Object.defineProperty(P, N, R);
2444
+ } : function(P, x, F, N) {
2445
+ N === void 0 && (N = F), P[N] = x[F];
2446
+ }), g = this && this.__exportStar || function(P, x) {
2447
+ for (var F in P) F === "default" || Object.prototype.hasOwnProperty.call(x, F) || q(x, P, F);
2448
+ };
2449
+ Object.defineProperty(d, "__esModule", { value: !0 }), g(p(79), d), g(p(445), d), g(p(654), d);
2450
+ }, 964: function(b, d) {
2451
+ Object.defineProperty(d, "__esModule", { value: !0 }), d.getBoundingClientRect = void 0;
2452
+ var p = function(q) {
2453
+ for (var g = q.offsetParent, P = q.offsetHeight, x = q.offsetWidth, F = q.offsetLeft, N = q.offsetTop; g && g.nodeType === 1; ) F += g.offsetLeft - g.scrollLeft, N += g.offsetTop - g.scrollTop, g = g.offsetParent;
2454
+ return { height: P, left: F, top: N, width: x };
2455
+ };
2456
+ d.default = function(q) {
2457
+ var g = q && q.parentElement;
2458
+ if (q && g) {
2459
+ var P = p(g), x = p(q), F = x.height, N = x.left, R = x.top, S = x.width;
2460
+ return { x: N - P.left, y: R - P.top, width: S, height: F, left: N, top: R, get right() {
2461
+ return this.left + this.width;
2462
+ }, get bottom() {
2463
+ return this.top + this.height;
2464
+ } };
290
2465
  }
291
- ),
292
- x && /* @__PURE__ */ e(
293
- He,
294
- {
295
- loading: z,
296
- autoPlay: C,
297
- playMuted: k,
298
- playing: B,
299
- played: D,
300
- unmute: S,
301
- mute: v,
302
- isMuted: F,
303
- hasNotPausedVideo: te,
304
- hasInteractedWithAudio: L
2466
+ return { x: 0, y: 0, width: 0, height: 0, left: 0, top: 0, right: 0, bottom: 0 };
2467
+ }, d.getBoundingClientRect = function(q) {
2468
+ if (q && q.getBoundingClientRect) {
2469
+ var g = q.getBoundingClientRect();
2470
+ return { x: g.x, y: g.y, width: g.width, height: g.height, left: g.left, top: g.top, get right() {
2471
+ return this.left + this.width;
2472
+ }, get bottom() {
2473
+ return this.top + this.height;
2474
+ } };
305
2475
  }
306
- ),
307
- z && /* @__PURE__ */ e(T, { children: /* @__PURE__ */ e(ue, {}) })
308
- ]
309
- }
310
- );
311
- }
312
- );
2476
+ return { x: 0, y: 0, width: 0, height: 0, left: 0, top: 0, right: 0, bottom: 0 };
2477
+ };
2478
+ }, 445: function(b, d, p) {
2479
+ Object.defineProperty(d, "__esModule", { value: !0 }), d.useFocusContext = d.FocusContext = void 0;
2480
+ var q = p(156), g = p(654);
2481
+ d.FocusContext = (0, q.createContext)(g.ROOT_FOCUS_KEY), d.FocusContext.displayName = "FocusContext", d.useFocusContext = function() {
2482
+ return (0, q.useContext)(d.FocusContext);
2483
+ };
2484
+ }, 79: function(b, d, p) {
2485
+ var q = this && this.__importDefault || function(R) {
2486
+ return R && R.__esModule ? R : { default: R };
2487
+ };
2488
+ Object.defineProperty(d, "__esModule", { value: !0 }), d.useFocusable = void 0;
2489
+ var g = p(156), P = q(p(604)), x = q(p(461)), F = p(654), N = p(445);
2490
+ d.useFocusable = function(R) {
2491
+ var S = R === void 0 ? {} : R, M = S.focusable, H = M === void 0 || M, w = S.saveLastFocusedChild, U = w === void 0 || w, J = S.trackChildren, te = J !== void 0 && J, ve = S.autoRestoreFocus, Le = ve === void 0 || ve, Te = S.forceFocus, Q = Te !== void 0 && Te, pe = S.isFocusBoundary, ue = pe !== void 0 && pe, oe = S.focusBoundaryDirections, ce = S.focusKey, ne = S.preferredChildFocusKey, ye = S.onEnterPress, ge = ye === void 0 ? P.default : ye, _e = S.onEnterRelease, xe = _e === void 0 ? P.default : _e, Se = S.onArrowPress, y = Se === void 0 ? function() {
2492
+ return !0;
2493
+ } : Se, u = S.onArrowRelease, c = u === void 0 ? P.default : u, f = S.onFocus, v = f === void 0 ? P.default : f, C = S.onBlur, A = C === void 0 ? P.default : C, T = S.extraProps, I = (0, g.useCallback)((function($) {
2494
+ ge(T, $);
2495
+ }), [ge, T]), G = (0, g.useCallback)((function() {
2496
+ xe(T);
2497
+ }), [xe, T]), k = (0, g.useCallback)((function($, Z) {
2498
+ return y($, T, Z);
2499
+ }), [T, y]), j = (0, g.useCallback)((function($) {
2500
+ c($, T);
2501
+ }), [c, T]), B = (0, g.useCallback)((function($, Z) {
2502
+ v($, T, Z);
2503
+ }), [T, v]), D = (0, g.useCallback)((function($, Z) {
2504
+ A($, T, Z);
2505
+ }), [T, A]), Y = (0, g.useRef)(null), W = (0, g.useState)(!1), X = W[0], se = W[1], z = (0, g.useState)(!1), V = z[0], fe = z[1], ae = (0, N.useFocusContext)(), ee = (0, g.useMemo)((function() {
2506
+ return ce || (0, x.default)("sn:focusable-item-");
2507
+ }), [ce]), be = (0, g.useCallback)((function($) {
2508
+ $ === void 0 && ($ = {}), F.SpatialNavigation.setFocus(ee, $);
2509
+ }), [ee]);
2510
+ return (0, g.useEffect)((function() {
2511
+ var $ = Y.current;
2512
+ return F.SpatialNavigation.addFocusable({ focusKey: ee, node: $, parentFocusKey: ae, preferredChildFocusKey: ne, onEnterPress: I, onEnterRelease: G, onArrowPress: k, onArrowRelease: j, onFocus: B, onBlur: D, onUpdateFocus: function(Z) {
2513
+ return Z === void 0 && (Z = !1), se(Z);
2514
+ }, onUpdateHasFocusedChild: function(Z) {
2515
+ return Z === void 0 && (Z = !1), fe(Z);
2516
+ }, saveLastFocusedChild: U, trackChildren: te, isFocusBoundary: ue, focusBoundaryDirections: oe, autoRestoreFocus: Le, forceFocus: Q, focusable: H }), function() {
2517
+ F.SpatialNavigation.removeFocusable({ focusKey: ee });
2518
+ };
2519
+ }), []), (0, g.useEffect)((function() {
2520
+ var $ = Y.current;
2521
+ F.SpatialNavigation.updateFocusable(ee, { node: $, preferredChildFocusKey: ne, focusable: H, isFocusBoundary: ue, focusBoundaryDirections: oe, onEnterPress: I, onEnterRelease: G, onArrowPress: k, onArrowRelease: j, onFocus: B, onBlur: D });
2522
+ }), [ee, ne, H, ue, oe, I, G, k, j, B, D]), { ref: Y, focusSelf: be, focused: X, hasFocusedChild: V, focusKey: ee };
2523
+ };
2524
+ }, 150: function(b) {
2525
+ b.exports = t;
2526
+ }, 117: function(b) {
2527
+ b.exports = n;
2528
+ }, 747: function(b) {
2529
+ b.exports = a;
2530
+ }, 23: function(b) {
2531
+ b.exports = i;
2532
+ }, 842: function(b) {
2533
+ b.exports = s;
2534
+ }, 682: function(b) {
2535
+ b.exports = o;
2536
+ }, 784: function(b) {
2537
+ b.exports = l;
2538
+ }, 604: function(b) {
2539
+ b.exports = h;
2540
+ }, 432: function(b) {
2541
+ b.exports = m;
2542
+ }, 67: function(b) {
2543
+ b.exports = _;
2544
+ }, 461: function(b) {
2545
+ b.exports = O;
2546
+ }, 156: function(b) {
2547
+ b.exports = E;
2548
+ } }, K = {};
2549
+ return (function b(d) {
2550
+ var p = K[d];
2551
+ if (p !== void 0) return p.exports;
2552
+ var q = K[d] = { exports: {} };
2553
+ return L[d].call(q.exports, q, q.exports, b), q.exports;
2554
+ })(607);
2555
+ })();
2556
+ }));
2557
+ })(Ke)), Ke.exports;
2558
+ }
2559
+ var Lc = Mc();
313
2560
  export {
314
- Ze as F,
315
- ze as I,
316
- Xe as y
2561
+ Lc as d
317
2562
  };