@sudobility/gaming-components 1.1.0 → 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.esm.js CHANGED
@@ -1,792 +1,506 @@
1
- import ne, { useRef as K, useState as E, useEffect as ee } from "react";
2
- import { cn as f } from "@sudobility/components";
3
- var z = { exports: {} }, L = {};
4
- var X;
5
- function oe() {
6
- if (X) return L;
7
- X = 1;
8
- var o = Symbol.for("react.transitional.element"), s = Symbol.for("react.fragment");
9
- function t(i, m, h) {
10
- var p = null;
11
- if (h !== void 0 && (p = "" + h), m.key !== void 0 && (p = "" + m.key), "key" in m) {
12
- h = {};
13
- for (var l in m)
14
- l !== "key" && (h[l] = m[l]);
15
- } else h = m;
16
- return m = h.ref, {
1
+ import er from "react";
2
+ import { cn as d } from "@sudobility/components";
3
+ var h = { exports: {} }, y = {};
4
+ var I;
5
+ function ar() {
6
+ if (I) return y;
7
+ I = 1;
8
+ var o = Symbol.for("react.transitional.element"), t = Symbol.for("react.fragment");
9
+ function a(l, c, g) {
10
+ var f = null;
11
+ if (g !== void 0 && (f = "" + g), c.key !== void 0 && (f = "" + c.key), "key" in c) {
12
+ g = {};
13
+ for (var m in c)
14
+ m !== "key" && (g[m] = c[m]);
15
+ } else g = c;
16
+ return c = g.ref, {
17
17
  $$typeof: o,
18
- type: i,
19
- key: p,
20
- ref: m !== void 0 ? m : null,
21
- props: h
18
+ type: l,
19
+ key: f,
20
+ ref: c !== void 0 ? c : null,
21
+ props: g
22
22
  };
23
23
  }
24
- return L.Fragment = s, L.jsx = t, L.jsxs = t, L;
24
+ return y.Fragment = t, y.jsx = a, y.jsxs = a, y;
25
25
  }
26
- var M = {};
27
- var Z;
28
- function se() {
29
- return Z || (Z = 1, process.env.NODE_ENV !== "production" && (function() {
30
- function o(e) {
31
- if (e == null) return null;
32
- if (typeof e == "function")
33
- return e.$$typeof === re ? null : e.displayName || e.name || null;
34
- if (typeof e == "string") return e;
35
- switch (e) {
36
- case j:
26
+ var p = {};
27
+ var F;
28
+ function or() {
29
+ return F || (F = 1, process.env.NODE_ENV !== "production" && (function() {
30
+ function o(r) {
31
+ if (r == null) return null;
32
+ if (typeof r == "function")
33
+ return r.$$typeof === Q ? null : r.displayName || r.name || null;
34
+ if (typeof r == "string") return r;
35
+ switch (r) {
36
+ case _:
37
37
  return "Fragment";
38
- case O:
38
+ case J:
39
39
  return "Profiler";
40
- case A:
40
+ case q:
41
41
  return "StrictMode";
42
- case c:
42
+ case B:
43
43
  return "Suspense";
44
- case v:
44
+ case X:
45
45
  return "SuspenseList";
46
- case V:
46
+ case Z:
47
47
  return "Activity";
48
48
  }
49
- if (typeof e == "object")
50
- switch (typeof e.tag == "number" && console.error(
49
+ if (typeof r == "object")
50
+ switch (typeof r.tag == "number" && console.error(
51
51
  "Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."
52
- ), e.$$typeof) {
53
- case U:
52
+ ), r.$$typeof) {
53
+ case W:
54
54
  return "Portal";
55
- case C:
56
- return e.displayName || "Context";
57
- case S:
58
- return (e._context.displayName || "Context") + ".Consumer";
59
- case a:
60
- var n = e.render;
61
- return e = e.displayName, e || (e = n.displayName || n.name || "", e = e !== "" ? "ForwardRef(" + e + ")" : "ForwardRef"), e;
62
- case T:
63
- return n = e.displayName || null, n !== null ? n : o(e.type) || "Memo";
64
- case x:
65
- n = e._payload, e = e._init;
55
+ case z:
56
+ return r.displayName || "Context";
57
+ case V:
58
+ return (r._context.displayName || "Context") + ".Consumer";
59
+ case G:
60
+ var e = r.render;
61
+ return r = r.displayName, r || (r = e.displayName || e.name || "", r = r !== "" ? "ForwardRef(" + r + ")" : "ForwardRef"), r;
62
+ case H:
63
+ return e = r.displayName || null, e !== null ? e : o(r.type) || "Memo";
64
+ case E:
65
+ e = r._payload, r = r._init;
66
66
  try {
67
- return o(e(n));
67
+ return o(r(e));
68
68
  } catch {
69
69
  }
70
70
  }
71
71
  return null;
72
72
  }
73
- function s(e) {
74
- return "" + e;
73
+ function t(r) {
74
+ return "" + r;
75
75
  }
76
- function t(e) {
76
+ function a(r) {
77
77
  try {
78
- s(e);
79
- var n = !1;
78
+ t(r);
79
+ var e = !1;
80
80
  } catch {
81
- n = !0;
81
+ e = !0;
82
82
  }
83
- if (n) {
84
- n = console;
85
- var d = n.error, u = typeof Symbol == "function" && Symbol.toStringTag && e[Symbol.toStringTag] || e.constructor.name || "Object";
86
- return d.call(
87
- n,
83
+ if (e) {
84
+ e = console;
85
+ var n = e.error, i = typeof Symbol == "function" && Symbol.toStringTag && r[Symbol.toStringTag] || r.constructor.name || "Object";
86
+ return n.call(
87
+ e,
88
88
  "The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",
89
- u
90
- ), s(e);
89
+ i
90
+ ), t(r);
91
91
  }
92
92
  }
93
- function i(e) {
94
- if (e === j) return "<>";
95
- if (typeof e == "object" && e !== null && e.$$typeof === x)
93
+ function l(r) {
94
+ if (r === _) return "<>";
95
+ if (typeof r == "object" && r !== null && r.$$typeof === E)
96
96
  return "<...>";
97
97
  try {
98
- var n = o(e);
99
- return n ? "<" + n + ">" : "<...>";
98
+ var e = o(r);
99
+ return e ? "<" + e + ">" : "<...>";
100
100
  } catch {
101
101
  return "<...>";
102
102
  }
103
103
  }
104
- function m() {
105
- var e = $.A;
106
- return e === null ? null : e.getOwner();
104
+ function c() {
105
+ var r = w.A;
106
+ return r === null ? null : r.getOwner();
107
107
  }
108
- function h() {
108
+ function g() {
109
109
  return Error("react-stack-top-frame");
110
110
  }
111
- function p(e) {
112
- if (q.call(e, "key")) {
113
- var n = Object.getOwnPropertyDescriptor(e, "key").get;
114
- if (n && n.isReactWarning) return !1;
111
+ function f(r) {
112
+ if (C.call(r, "key")) {
113
+ var e = Object.getOwnPropertyDescriptor(r, "key").get;
114
+ if (e && e.isReactWarning) return !1;
115
115
  }
116
- return e.key !== void 0;
116
+ return r.key !== void 0;
117
117
  }
118
- function l(e, n) {
119
- function d() {
120
- B || (B = !0, console.error(
118
+ function m(r, e) {
119
+ function n() {
120
+ P || (P = !0, console.error(
121
121
  "%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)",
122
- n
122
+ e
123
123
  ));
124
124
  }
125
- d.isReactWarning = !0, Object.defineProperty(e, "key", {
126
- get: d,
125
+ n.isReactWarning = !0, Object.defineProperty(r, "key", {
126
+ get: n,
127
127
  configurable: !0
128
128
  });
129
129
  }
130
- function N() {
131
- var e = o(this.type);
132
- return W[e] || (W[e] = !0, console.error(
130
+ function D() {
131
+ var r = o(this.type);
132
+ return A[r] || (A[r] = !0, console.error(
133
133
  "Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release."
134
- )), e = this.props.ref, e !== void 0 ? e : null;
134
+ )), r = this.props.ref, r !== void 0 ? r : null;
135
135
  }
136
- function w(e, n, d, u, F, I) {
137
- var g = d.ref;
138
- return e = {
139
- $$typeof: R,
140
- type: e,
141
- key: n,
142
- props: d,
143
- _owner: u
144
- }, (g !== void 0 ? g : null) !== null ? Object.defineProperty(e, "ref", {
136
+ function M(r, e, n, i, k, R) {
137
+ var s = n.ref;
138
+ return r = {
139
+ $$typeof: O,
140
+ type: r,
141
+ key: e,
142
+ props: n,
143
+ _owner: i
144
+ }, (s !== void 0 ? s : null) !== null ? Object.defineProperty(r, "ref", {
145
145
  enumerable: !1,
146
- get: N
147
- }) : Object.defineProperty(e, "ref", { enumerable: !1, value: null }), e._store = {}, Object.defineProperty(e._store, "validated", {
146
+ get: D
147
+ }) : Object.defineProperty(r, "ref", { enumerable: !1, value: null }), r._store = {}, Object.defineProperty(r._store, "validated", {
148
148
  configurable: !1,
149
149
  enumerable: !1,
150
150
  writable: !0,
151
151
  value: 0
152
- }), Object.defineProperty(e, "_debugInfo", {
152
+ }), Object.defineProperty(r, "_debugInfo", {
153
153
  configurable: !1,
154
154
  enumerable: !1,
155
155
  writable: !0,
156
156
  value: null
157
- }), Object.defineProperty(e, "_debugStack", {
157
+ }), Object.defineProperty(r, "_debugStack", {
158
158
  configurable: !1,
159
159
  enumerable: !1,
160
160
  writable: !0,
161
- value: F
162
- }), Object.defineProperty(e, "_debugTask", {
161
+ value: k
162
+ }), Object.defineProperty(r, "_debugTask", {
163
163
  configurable: !1,
164
164
  enumerable: !1,
165
165
  writable: !0,
166
- value: I
167
- }), Object.freeze && (Object.freeze(e.props), Object.freeze(e)), e;
166
+ value: R
167
+ }), Object.freeze && (Object.freeze(r.props), Object.freeze(r)), r;
168
168
  }
169
- function k(e, n, d, u, F, I) {
170
- var g = n.children;
171
- if (g !== void 0)
172
- if (u)
173
- if (te(g)) {
174
- for (u = 0; u < g.length; u++)
175
- _(g[u]);
176
- Object.freeze && Object.freeze(g);
169
+ function S(r, e, n, i, k, R) {
170
+ var s = e.children;
171
+ if (s !== void 0)
172
+ if (i)
173
+ if (K(s)) {
174
+ for (i = 0; i < s.length; i++)
175
+ U(s[i]);
176
+ Object.freeze && Object.freeze(s);
177
177
  } else
178
178
  console.error(
179
179
  "React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead."
180
180
  );
181
- else _(g);
182
- if (q.call(n, "key")) {
183
- g = o(e);
184
- var P = Object.keys(n).filter(function(ae) {
185
- return ae !== "key";
181
+ else U(s);
182
+ if (C.call(e, "key")) {
183
+ s = o(r);
184
+ var b = Object.keys(e).filter(function(rr) {
185
+ return rr !== "key";
186
186
  });
187
- u = 0 < P.length ? "{key: someKey, " + P.join(": ..., ") + ": ...}" : "{key: someKey}", G[g + u] || (P = 0 < P.length ? "{" + P.join(": ..., ") + ": ...}" : "{}", console.error(
187
+ i = 0 < b.length ? "{key: someKey, " + b.join(": ..., ") + ": ...}" : "{key: someKey}", $[s + i] || (b = 0 < b.length ? "{" + b.join(": ..., ") + ": ...}" : "{}", console.error(
188
188
  `A props object containing a "key" prop is being spread into JSX:
189
189
  let props = %s;
190
190
  <%s {...props} />
191
191
  React keys must be passed directly to JSX without using spread:
192
192
  let props = %s;
193
193
  <%s key={someKey} {...props} />`,
194
- u,
195
- g,
196
- P,
197
- g
198
- ), G[g + u] = !0);
194
+ i,
195
+ s,
196
+ b,
197
+ s
198
+ ), $[s + i] = !0);
199
199
  }
200
- if (g = null, d !== void 0 && (t(d), g = "" + d), p(n) && (t(n.key), g = "" + n.key), "key" in n) {
201
- d = {};
202
- for (var D in n)
203
- D !== "key" && (d[D] = n[D]);
204
- } else d = n;
205
- return g && l(
206
- d,
207
- typeof e == "function" ? e.displayName || e.name || "Unknown" : e
208
- ), w(
209
- e,
210
- g,
211
- d,
212
- m(),
213
- F,
214
- I
200
+ if (s = null, n !== void 0 && (a(n), s = "" + n), f(e) && (a(e.key), s = "" + e.key), "key" in e) {
201
+ n = {};
202
+ for (var T in e)
203
+ T !== "key" && (n[T] = e[T]);
204
+ } else n = e;
205
+ return s && m(
206
+ n,
207
+ typeof r == "function" ? r.displayName || r.name || "Unknown" : r
208
+ ), M(
209
+ r,
210
+ s,
211
+ n,
212
+ c(),
213
+ k,
214
+ R
215
215
  );
216
216
  }
217
- function _(e) {
218
- b(e) ? e._store && (e._store.validated = 1) : typeof e == "object" && e !== null && e.$$typeof === x && (e._payload.status === "fulfilled" ? b(e._payload.value) && e._payload.value._store && (e._payload.value._store.validated = 1) : e._store && (e._store.validated = 1));
217
+ function U(r) {
218
+ j(r) ? r._store && (r._store.validated = 1) : typeof r == "object" && r !== null && r.$$typeof === E && (r._payload.status === "fulfilled" ? j(r._payload.value) && r._payload.value._store && (r._payload.value._store.validated = 1) : r._store && (r._store.validated = 1));
219
219
  }
220
- function b(e) {
221
- return typeof e == "object" && e !== null && e.$$typeof === R;
220
+ function j(r) {
221
+ return typeof r == "object" && r !== null && r.$$typeof === O;
222
222
  }
223
- var y = ne, R = Symbol.for("react.transitional.element"), U = Symbol.for("react.portal"), j = Symbol.for("react.fragment"), A = Symbol.for("react.strict_mode"), O = Symbol.for("react.profiler"), S = Symbol.for("react.consumer"), C = Symbol.for("react.context"), a = Symbol.for("react.forward_ref"), c = Symbol.for("react.suspense"), v = Symbol.for("react.suspense_list"), T = Symbol.for("react.memo"), x = Symbol.for("react.lazy"), V = Symbol.for("react.activity"), re = Symbol.for("react.client.reference"), $ = y.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, q = Object.prototype.hasOwnProperty, te = Array.isArray, Y = console.createTask ? console.createTask : function() {
223
+ var v = er, O = Symbol.for("react.transitional.element"), W = Symbol.for("react.portal"), _ = Symbol.for("react.fragment"), q = Symbol.for("react.strict_mode"), J = Symbol.for("react.profiler"), V = Symbol.for("react.consumer"), z = Symbol.for("react.context"), G = Symbol.for("react.forward_ref"), B = Symbol.for("react.suspense"), X = Symbol.for("react.suspense_list"), H = Symbol.for("react.memo"), E = Symbol.for("react.lazy"), Z = Symbol.for("react.activity"), Q = Symbol.for("react.client.reference"), w = v.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, C = Object.prototype.hasOwnProperty, K = Array.isArray, x = console.createTask ? console.createTask : function() {
224
224
  return null;
225
225
  };
226
- y = {
227
- react_stack_bottom_frame: function(e) {
228
- return e();
226
+ v = {
227
+ react_stack_bottom_frame: function(r) {
228
+ return r();
229
229
  }
230
230
  };
231
- var B, W = {}, H = y.react_stack_bottom_frame.bind(
232
- y,
233
- h
234
- )(), J = Y(i(h)), G = {};
235
- M.Fragment = j, M.jsx = function(e, n, d) {
236
- var u = 1e4 > $.recentlyCreatedOwnerStacks++;
237
- return k(
231
+ var P, A = {}, N = v.react_stack_bottom_frame.bind(
232
+ v,
233
+ g
234
+ )(), Y = x(l(g)), $ = {};
235
+ p.Fragment = _, p.jsx = function(r, e, n) {
236
+ var i = 1e4 > w.recentlyCreatedOwnerStacks++;
237
+ return S(
238
+ r,
238
239
  e,
239
240
  n,
240
- d,
241
241
  !1,
242
- u ? Error("react-stack-top-frame") : H,
243
- u ? Y(i(e)) : J
242
+ i ? Error("react-stack-top-frame") : N,
243
+ i ? x(l(r)) : Y
244
244
  );
245
- }, M.jsxs = function(e, n, d) {
246
- var u = 1e4 > $.recentlyCreatedOwnerStacks++;
247
- return k(
245
+ }, p.jsxs = function(r, e, n) {
246
+ var i = 1e4 > w.recentlyCreatedOwnerStacks++;
247
+ return S(
248
+ r,
248
249
  e,
249
250
  n,
250
- d,
251
251
  !0,
252
- u ? Error("react-stack-top-frame") : H,
253
- u ? Y(i(e)) : J
252
+ i ? Error("react-stack-top-frame") : N,
253
+ i ? x(l(r)) : Y
254
254
  );
255
255
  };
256
- })()), M;
256
+ })()), p;
257
257
  }
258
- var Q;
259
- function le() {
260
- return Q || (Q = 1, process.env.NODE_ENV === "production" ? z.exports = oe() : z.exports = se()), z.exports;
258
+ var L;
259
+ function tr() {
260
+ return L || (L = 1, process.env.NODE_ENV === "production" ? h.exports = ar() : h.exports = or()), h.exports;
261
261
  }
262
- var r = le();
263
- const de = ({
262
+ var u = tr();
263
+ const ir = ({
264
264
  className: o,
265
- children: s,
266
- disabled: t = !1,
267
- onClick: i
268
- }) => /* @__PURE__ */ r.jsx(
265
+ children: t,
266
+ disabled: a
267
+ }) => /* @__PURE__ */ u.jsx(
269
268
  "div",
270
269
  {
271
- className: f(
270
+ className: d(
272
271
  "p-4 rounded-lg border transition-colors",
273
272
  "bg-white dark:bg-gray-900",
274
273
  "border-gray-200 dark:border-gray-700",
275
274
  "text-gray-900 dark:text-white",
276
- t && "opacity-50 cursor-not-allowed",
277
- "hover:bg-gray-50 dark:hover:bg-gray-800",
275
+ a && "opacity-50 cursor-not-allowed",
278
276
  o
279
277
  ),
280
- onClick: t ? void 0 : i,
281
278
  role: "region",
282
- "aria-label": "UachievementUbadge",
283
- children: s || "UachievementUbadge Component"
279
+ "aria-label": "SustainabilityScore",
280
+ children: t || "SustainabilityScore Component"
284
281
  }
285
- ), ue = ({
282
+ ), sr = ({
286
283
  className: o,
287
- children: s,
288
- disabled: t = !1,
289
- onClick: i
290
- }) => /* @__PURE__ */ r.jsx(
284
+ children: t,
285
+ disabled: a = !1,
286
+ onClick: l
287
+ }) => /* @__PURE__ */ u.jsx(
291
288
  "div",
292
289
  {
293
- className: f(
290
+ className: d(
294
291
  "p-4 rounded-lg border transition-colors",
295
292
  "bg-white dark:bg-gray-900",
296
293
  "border-gray-200 dark:border-gray-700",
297
294
  "text-gray-900 dark:text-white",
298
- t && "opacity-50 cursor-not-allowed",
295
+ a && "opacity-50 cursor-not-allowed",
299
296
  "hover:bg-gray-50 dark:hover:bg-gray-800",
300
297
  o
301
298
  ),
302
- onClick: t ? void 0 : i,
299
+ onClick: a ? void 0 : l,
303
300
  role: "region",
304
- "aria-label": "UachievementUunlock",
305
- children: s || "UachievementUunlock Component"
301
+ "aria-label": "UachievementUbadge",
302
+ children: t || "UachievementUbadge Component"
306
303
  }
307
- ), ge = ({
308
- src: o,
309
- title: s,
310
- artist: t,
311
- artwork: i,
312
- autoPlay: m = !1,
313
- loop: h = !1,
314
- className: p
315
- }) => {
316
- const l = K(null), [N, w] = E(m), [k, _] = E(0), [b, y] = E(0), [R, U] = E(1);
317
- ee(() => {
318
- const a = l.current;
319
- if (!a) return;
320
- const c = () => _(a.currentTime), v = () => y(a.duration), T = () => w(!0), x = () => w(!1), V = () => w(!1);
321
- return a.addEventListener("timeupdate", c), a.addEventListener("loadedmetadata", v), a.addEventListener("play", T), a.addEventListener("pause", x), a.addEventListener("ended", V), () => {
322
- a.removeEventListener("timeupdate", c), a.removeEventListener("loadedmetadata", v), a.removeEventListener("play", T), a.removeEventListener("pause", x), a.removeEventListener("ended", V);
323
- };
324
- }, []);
325
- const j = () => {
326
- l.current && (N ? l.current.pause() : l.current.play());
327
- }, A = (a) => {
328
- const c = parseFloat(a.target.value);
329
- _(c), l.current && (l.current.currentTime = c);
330
- }, O = (a) => {
331
- const c = parseFloat(a.target.value);
332
- U(c), l.current && (l.current.volume = c);
333
- }, S = (a) => {
334
- const c = Math.floor(a / 60), v = Math.floor(a % 60);
335
- return `${c}:${v.toString().padStart(2, "0")}`;
336
- }, C = b > 0 ? k / b * 100 : 0;
337
- return /* @__PURE__ */ r.jsxs(
338
- "div",
339
- {
340
- className: f(
341
- "bg-white dark:bg-gray-900 rounded-lg p-6 shadow-lg",
342
- p
343
- ),
344
- children: [
345
- /* @__PURE__ */ r.jsx("audio", { ref: l, src: o, autoPlay: m, loop: h }),
346
- /* @__PURE__ */ r.jsxs("div", { className: "flex items-center gap-4 mb-4", children: [
347
- i && /* @__PURE__ */ r.jsx("div", { className: "w-16 h-16 rounded-lg overflow-hidden flex-shrink-0 bg-gray-200 dark:bg-gray-700", children: /* @__PURE__ */ r.jsx(
348
- "img",
349
- {
350
- src: i,
351
- alt: s || "Album artwork",
352
- className: "w-full h-full object-cover"
353
- }
354
- ) }),
355
- /* @__PURE__ */ r.jsxs("div", { className: "flex-1 min-w-0", children: [
356
- s && /* @__PURE__ */ r.jsx("h4", { className: "font-semibold text-gray-900 dark:text-white truncate", children: s }),
357
- t && /* @__PURE__ */ r.jsx("p", { className: "text-sm text-gray-600 dark:text-gray-400 truncate", children: t })
358
- ] })
359
- ] }),
360
- /* @__PURE__ */ r.jsxs("div", { className: "mb-4", children: [
361
- /* @__PURE__ */ r.jsx(
362
- "input",
363
- {
364
- type: "range",
365
- min: "0",
366
- max: b || 0,
367
- value: k,
368
- onChange: A,
369
- className: "w-full accent-blue-500"
370
- }
371
- ),
372
- /* @__PURE__ */ r.jsxs("div", { className: "flex justify-between text-xs text-gray-600 dark:text-gray-400 mt-1", children: [
373
- /* @__PURE__ */ r.jsx("span", { children: S(k) }),
374
- /* @__PURE__ */ r.jsx("span", { children: S(b) })
375
- ] })
376
- ] }),
377
- /* @__PURE__ */ r.jsxs("div", { className: "flex items-center justify-between", children: [
378
- /* @__PURE__ */ r.jsxs("div", { className: "flex items-center gap-4", children: [
379
- /* @__PURE__ */ r.jsx(
380
- "button",
381
- {
382
- onClick: j,
383
- className: "w-10 h-10 rounded-full bg-blue-500 text-white flex items-center justify-center hover:bg-blue-600 transition-colors",
384
- children: N ? /* @__PURE__ */ r.jsx("svg", { className: "w-5 h-5", fill: "currentColor", viewBox: "0 0 24 24", children: /* @__PURE__ */ r.jsx("path", { d: "M6 4h4v16H6V4zm8 0h4v16h-4V4z" }) }) : /* @__PURE__ */ r.jsx(
385
- "svg",
386
- {
387
- className: "w-5 h-5 ml-0.5",
388
- fill: "currentColor",
389
- viewBox: "0 0 24 24",
390
- children: /* @__PURE__ */ r.jsx("path", { d: "M8 5v14l11-7z" })
391
- }
392
- )
393
- }
394
- ),
395
- /* @__PURE__ */ r.jsxs("div", { className: "flex items-center gap-2", children: [
396
- /* @__PURE__ */ r.jsx(
397
- "svg",
398
- {
399
- className: "w-4 h-4 text-gray-600 dark:text-gray-400",
400
- fill: "currentColor",
401
- viewBox: "0 0 24 24",
402
- children: /* @__PURE__ */ r.jsx("path", { d: "M3 9v6h4l5 5V4L7 9H3zm13.5 3c0-1.77-1.02-3.29-2.5-4.03v8.05c1.48-.73 2.5-2.25 2.5-4.02z" })
403
- }
404
- ),
405
- /* @__PURE__ */ r.jsx(
406
- "input",
407
- {
408
- type: "range",
409
- min: "0",
410
- max: "1",
411
- step: "0.1",
412
- value: R,
413
- onChange: O,
414
- className: "w-24 accent-blue-500"
415
- }
416
- )
417
- ] })
418
- ] }),
419
- /* @__PURE__ */ r.jsxs("span", { className: "text-sm text-gray-600 dark:text-gray-400", children: [
420
- C.toFixed(0),
421
- "%"
422
- ] })
423
- ] })
424
- ]
425
- }
426
- );
427
- }, me = ({
304
+ ), cr = ({
428
305
  className: o,
429
- children: s,
430
- disabled: t = !1,
431
- onClick: i
432
- }) => /* @__PURE__ */ r.jsx(
306
+ children: t,
307
+ disabled: a = !1,
308
+ onClick: l
309
+ }) => /* @__PURE__ */ u.jsx(
433
310
  "div",
434
311
  {
435
- className: f(
312
+ className: d(
436
313
  "p-4 rounded-lg border transition-colors",
437
314
  "bg-white dark:bg-gray-900",
438
315
  "border-gray-200 dark:border-gray-700",
439
316
  "text-gray-900 dark:text-white",
440
- t && "opacity-50 cursor-not-allowed",
317
+ a && "opacity-50 cursor-not-allowed",
441
318
  "hover:bg-gray-50 dark:hover:bg-gray-800",
442
319
  o
443
320
  ),
444
- onClick: t ? void 0 : i,
321
+ onClick: a ? void 0 : l,
445
322
  role: "region",
446
- "aria-label": "UgameUcontrols",
447
- children: s || "UgameUcontrols Component"
323
+ "aria-label": "UachievementUunlock",
324
+ children: t || "UachievementUunlock Component"
448
325
  }
449
- ), fe = ({
326
+ ), dr = ({
450
327
  className: o,
451
- children: s,
452
- disabled: t
453
- }) => /* @__PURE__ */ r.jsx(
328
+ children: t,
329
+ disabled: a = !1,
330
+ onClick: l
331
+ }) => /* @__PURE__ */ u.jsx(
454
332
  "div",
455
333
  {
456
- className: f(
334
+ className: d(
457
335
  "p-4 rounded-lg border transition-colors",
458
336
  "bg-white dark:bg-gray-900",
459
337
  "border-gray-200 dark:border-gray-700",
460
338
  "text-gray-900 dark:text-white",
461
- t && "opacity-50 cursor-not-allowed",
339
+ a && "opacity-50 cursor-not-allowed",
340
+ "hover:bg-gray-50 dark:hover:bg-gray-800",
462
341
  o
463
342
  ),
343
+ onClick: a ? void 0 : l,
464
344
  role: "region",
465
- "aria-label": "LeadScorer",
466
- children: s || "LeadScorer Component"
345
+ "aria-label": "UgameUcontrols",
346
+ children: t || "UgameUcontrols Component"
467
347
  }
468
- ), he = ({
348
+ ), ur = ({
469
349
  className: o,
470
- children: s,
471
- disabled: t = !1,
472
- onClick: i
473
- }) => /* @__PURE__ */ r.jsx(
350
+ children: t,
351
+ disabled: a
352
+ }) => /* @__PURE__ */ u.jsx(
474
353
  "div",
475
354
  {
476
- className: f(
355
+ className: d(
477
356
  "p-4 rounded-lg border transition-colors",
478
357
  "bg-white dark:bg-gray-900",
479
358
  "border-gray-200 dark:border-gray-700",
480
359
  "text-gray-900 dark:text-white",
481
- t && "opacity-50 cursor-not-allowed",
482
- "hover:bg-gray-50 dark:hover:bg-gray-800",
360
+ a && "opacity-50 cursor-not-allowed",
483
361
  o
484
362
  ),
485
- onClick: t ? void 0 : i,
486
363
  role: "region",
487
- "aria-label": "UleaderboardUpodium",
488
- children: s || "UleaderboardUpodium Component"
364
+ "aria-label": "LeadScorer",
365
+ children: t || "LeadScorer Component"
489
366
  }
490
- ), ve = ({
367
+ ), gr = ({
491
368
  className: o,
492
- children: s,
493
- disabled: t
494
- }) => /* @__PURE__ */ r.jsx(
369
+ children: t,
370
+ disabled: a = !1,
371
+ onClick: l
372
+ }) => /* @__PURE__ */ u.jsx(
495
373
  "div",
496
374
  {
497
- className: f(
375
+ className: d(
498
376
  "p-4 rounded-lg border transition-colors",
499
377
  "bg-white dark:bg-gray-900",
500
378
  "border-gray-200 dark:border-gray-700",
501
379
  "text-gray-900 dark:text-white",
502
- t && "opacity-50 cursor-not-allowed",
380
+ a && "opacity-50 cursor-not-allowed",
381
+ "hover:bg-gray-50 dark:hover:bg-gray-800",
503
382
  o
504
383
  ),
384
+ onClick: a ? void 0 : l,
505
385
  role: "region",
506
- "aria-label": "PlayerStats",
507
- children: s || "PlayerStats Component"
386
+ "aria-label": "UleaderboardUpodium",
387
+ children: t || "UleaderboardUpodium Component"
508
388
  }
509
- ), be = ({
389
+ ), br = ({
510
390
  className: o,
511
- children: s,
512
- disabled: t
513
- }) => /* @__PURE__ */ r.jsx(
391
+ children: t,
392
+ disabled: a
393
+ }) => /* @__PURE__ */ u.jsx(
514
394
  "div",
515
395
  {
516
- className: f(
396
+ className: d(
517
397
  "p-4 rounded-lg border transition-colors",
518
398
  "bg-white dark:bg-gray-900",
519
399
  "border-gray-200 dark:border-gray-700",
520
400
  "text-gray-900 dark:text-white",
521
- t && "opacity-50 cursor-not-allowed",
401
+ a && "opacity-50 cursor-not-allowed",
522
402
  o
523
403
  ),
524
404
  role: "region",
525
- "aria-label": "PodcastPlayer",
526
- children: s || "PodcastPlayer Component"
405
+ "aria-label": "PlayerStats",
406
+ children: t || "PlayerStats Component"
527
407
  }
528
- ), pe = ({
408
+ ), fr = ({
529
409
  className: o,
530
- children: s,
531
- disabled: t
532
- }) => /* @__PURE__ */ r.jsx(
410
+ children: t,
411
+ disabled: a
412
+ }) => /* @__PURE__ */ u.jsx(
533
413
  "div",
534
414
  {
535
- className: f(
415
+ className: d(
536
416
  "p-4 rounded-lg border transition-colors",
537
417
  "bg-white dark:bg-gray-900",
538
418
  "border-gray-200 dark:border-gray-700",
539
419
  "text-gray-900 dark:text-white",
540
- t && "opacity-50 cursor-not-allowed",
420
+ a && "opacity-50 cursor-not-allowed",
541
421
  o
542
422
  ),
543
423
  role: "region",
544
424
  "aria-label": "ScoreBoard",
545
- children: s || "ScoreBoard Component"
425
+ children: t || "ScoreBoard Component"
546
426
  }
547
- ), ye = ({
427
+ ), mr = ({
548
428
  className: o,
549
- children: s,
550
- disabled: t = !1,
551
- onClick: i
552
- }) => /* @__PURE__ */ r.jsx(
429
+ children: t,
430
+ disabled: a = !1,
431
+ onClick: l
432
+ }) => /* @__PURE__ */ u.jsx(
553
433
  "div",
554
434
  {
555
- className: f(
435
+ className: d(
556
436
  "p-4 rounded-lg border transition-colors",
557
437
  "bg-white dark:bg-gray-900",
558
438
  "border-gray-200 dark:border-gray-700",
559
439
  "text-gray-900 dark:text-white",
560
- t && "opacity-50 cursor-not-allowed",
440
+ a && "opacity-50 cursor-not-allowed",
561
441
  "hover:bg-gray-50 dark:hover:bg-gray-800",
562
442
  o
563
443
  ),
564
- onClick: t ? void 0 : i,
444
+ onClick: a ? void 0 : l,
565
445
  role: "region",
566
446
  "aria-label": "UscoreUdisplay",
567
- children: s || "UscoreUdisplay Component"
447
+ children: t || "UscoreUdisplay Component"
568
448
  }
569
- ), xe = ({
449
+ ), yr = ({
570
450
  className: o,
571
- children: s,
572
- disabled: t = !1,
573
- onClick: i
574
- }) => /* @__PURE__ */ r.jsx(
451
+ children: t,
452
+ disabled: a = !1,
453
+ onClick: l
454
+ }) => /* @__PURE__ */ u.jsx(
575
455
  "div",
576
456
  {
577
- className: f(
457
+ className: d(
578
458
  "p-4 rounded-lg border transition-colors",
579
459
  "bg-white dark:bg-gray-900",
580
460
  "border-gray-200 dark:border-gray-700",
581
461
  "text-gray-900 dark:text-white",
582
- t && "opacity-50 cursor-not-allowed",
462
+ a && "opacity-50 cursor-not-allowed",
583
463
  "hover:bg-gray-50 dark:hover:bg-gray-800",
584
464
  o
585
465
  ),
586
- onClick: t ? void 0 : i,
466
+ onClick: a ? void 0 : l,
587
467
  role: "region",
588
468
  "aria-label": "UscratchUcard",
589
- children: s || "UscratchUcard Component"
469
+ children: t || "UscratchUcard Component"
590
470
  }
591
- ), we = ({
471
+ ), pr = ({
592
472
  className: o,
593
- children: s,
594
- disabled: t
595
- }) => /* @__PURE__ */ r.jsx(
473
+ children: t,
474
+ disabled: a = !1,
475
+ onClick: l
476
+ }) => /* @__PURE__ */ u.jsx(
596
477
  "div",
597
478
  {
598
- className: f(
479
+ className: d(
599
480
  "p-4 rounded-lg border transition-colors",
600
481
  "bg-white dark:bg-gray-900",
601
482
  "border-gray-200 dark:border-gray-700",
602
483
  "text-gray-900 dark:text-white",
603
- t && "opacity-50 cursor-not-allowed",
604
- o
605
- ),
606
- role: "region",
607
- "aria-label": "SignatureRequest",
608
- children: s || "SignatureRequest Component"
609
- }
610
- ), ke = ({
611
- className: o,
612
- children: s,
613
- disabled: t = !1,
614
- onClick: i
615
- }) => /* @__PURE__ */ r.jsx(
616
- "div",
617
- {
618
- className: f(
619
- "p-4 rounded-lg border transition-colors",
620
- "bg-white dark:bg-gray-900",
621
- "border-gray-200 dark:border-gray-700",
622
- "text-gray-900 dark:text-white",
623
- t && "opacity-50 cursor-not-allowed",
484
+ a && "opacity-50 cursor-not-allowed",
624
485
  "hover:bg-gray-50 dark:hover:bg-gray-800",
625
486
  o
626
487
  ),
627
- onClick: t ? void 0 : i,
488
+ onClick: a ? void 0 : l,
628
489
  role: "region",
629
490
  "aria-label": "UspinUwheel",
630
- children: s || "UspinUwheel Component"
631
- }
632
- ), je = ({
633
- className: o,
634
- children: s,
635
- disabled: t
636
- }) => /* @__PURE__ */ r.jsx(
637
- "div",
638
- {
639
- className: f(
640
- "p-4 rounded-lg border transition-colors",
641
- "bg-white dark:bg-gray-900",
642
- "border-gray-200 dark:border-gray-700",
643
- "text-gray-900 dark:text-white",
644
- t && "opacity-50 cursor-not-allowed",
645
- o
646
- ),
647
- role: "region",
648
- "aria-label": "SustainabilityScore",
649
- children: s || "SustainabilityScore Component"
491
+ children: t || "UspinUwheel Component"
650
492
  }
651
- ), Ee = ({
652
- src: o,
653
- poster: s,
654
- autoPlay: t = !1,
655
- loop: i = !1,
656
- muted: m = !1,
657
- controls: h = !0,
658
- className: p
659
- }) => {
660
- const l = K(null), [N, w] = E(t), [k, _] = E(1), [b, y] = E(0), [R, U] = E(0);
661
- ee(() => {
662
- const a = l.current;
663
- if (!a) return;
664
- const c = () => y(a.currentTime), v = () => U(a.duration), T = () => w(!0), x = () => w(!1);
665
- return a.addEventListener("timeupdate", c), a.addEventListener("loadedmetadata", v), a.addEventListener("play", T), a.addEventListener("pause", x), () => {
666
- a.removeEventListener("timeupdate", c), a.removeEventListener("loadedmetadata", v), a.removeEventListener("play", T), a.removeEventListener("pause", x);
667
- };
668
- }, []);
669
- const j = () => {
670
- l.current && (N ? l.current.pause() : l.current.play());
671
- }, A = (a) => {
672
- const c = parseFloat(a.target.value);
673
- _(c), l.current && (l.current.volume = c);
674
- }, O = (a) => {
675
- const c = parseFloat(a.target.value);
676
- y(c), l.current && (l.current.currentTime = c);
677
- }, S = () => {
678
- l.current && (document.fullscreenElement ? document.exitFullscreen() : l.current.requestFullscreen());
679
- }, C = (a) => {
680
- const c = Math.floor(a / 60), v = Math.floor(a % 60);
681
- return `${c}:${v.toString().padStart(2, "0")}`;
682
- };
683
- return /* @__PURE__ */ r.jsxs("div", { className: f("relative group", p), children: [
684
- /* @__PURE__ */ r.jsx(
685
- "video",
686
- {
687
- ref: l,
688
- src: o,
689
- poster: s,
690
- autoPlay: t,
691
- loop: i,
692
- muted: m,
693
- className: "w-full rounded-lg",
694
- onClick: j
695
- }
696
- ),
697
- h && /* @__PURE__ */ r.jsxs("div", { className: "absolute bottom-0 left-0 right-0 bg-gradient-to-t from-black/70 to-transparent p-4 opacity-0 group-hover:opacity-100 transition-opacity", children: [
698
- /* @__PURE__ */ r.jsx(
699
- "input",
700
- {
701
- type: "range",
702
- min: "0",
703
- max: R || 0,
704
- value: b,
705
- onChange: O,
706
- className: "w-full mb-2 accent-white"
707
- }
708
- ),
709
- /* @__PURE__ */ r.jsxs("div", { className: "flex items-center justify-between gap-4", children: [
710
- /* @__PURE__ */ r.jsxs("div", { className: "flex items-center gap-3", children: [
711
- /* @__PURE__ */ r.jsx(
712
- "button",
713
- {
714
- onClick: j,
715
- className: "text-white hover:text-gray-300 transition-colors",
716
- children: N ? /* @__PURE__ */ r.jsx(
717
- "svg",
718
- {
719
- className: "w-6 h-6",
720
- fill: "currentColor",
721
- viewBox: "0 0 24 24",
722
- children: /* @__PURE__ */ r.jsx("path", { d: "M6 4h4v16H6V4zm8 0h4v16h-4V4z" })
723
- }
724
- ) : /* @__PURE__ */ r.jsx(
725
- "svg",
726
- {
727
- className: "w-6 h-6",
728
- fill: "currentColor",
729
- viewBox: "0 0 24 24",
730
- children: /* @__PURE__ */ r.jsx("path", { d: "M8 5v14l11-7z" })
731
- }
732
- )
733
- }
734
- ),
735
- /* @__PURE__ */ r.jsxs("div", { className: "flex items-center gap-2", children: [
736
- /* @__PURE__ */ r.jsx(
737
- "svg",
738
- {
739
- className: "w-4 h-4 text-white",
740
- fill: "currentColor",
741
- viewBox: "0 0 24 24",
742
- children: /* @__PURE__ */ r.jsx("path", { d: "M3 9v6h4l5 5V4L7 9H3zm13.5 3c0-1.77-1.02-3.29-2.5-4.03v8.05c1.48-.73 2.5-2.25 2.5-4.02z" })
743
- }
744
- ),
745
- /* @__PURE__ */ r.jsx(
746
- "input",
747
- {
748
- type: "range",
749
- min: "0",
750
- max: "1",
751
- step: "0.1",
752
- value: k,
753
- onChange: A,
754
- className: "w-20 accent-white"
755
- }
756
- )
757
- ] }),
758
- /* @__PURE__ */ r.jsxs("span", { className: "text-white text-sm", children: [
759
- C(b),
760
- " / ",
761
- C(R)
762
- ] })
763
- ] }),
764
- /* @__PURE__ */ r.jsx(
765
- "button",
766
- {
767
- onClick: S,
768
- className: "text-white hover:text-gray-300 transition-colors",
769
- children: /* @__PURE__ */ r.jsx("svg", { className: "w-5 h-5", fill: "currentColor", viewBox: "0 0 24 24", children: /* @__PURE__ */ r.jsx("path", { d: "M7 14H5v5h5v-2H7v-3zm-2-4h2V7h3V5H5v5zm12 7h-3v2h5v-5h-2v3zM14 5v2h3v3h2V5h-5z" }) })
770
- }
771
- )
772
- ] })
773
- ] })
774
- ] });
775
- };
493
+ );
776
494
  export {
777
- ge as AudioPlayer,
778
- fe as LeadScorer,
779
- ve as PlayerStats,
780
- be as PodcastPlayer,
781
- pe as ScoreBoard,
782
- we as SignatureRequest,
783
- je as SustainabilityScore,
784
- de as UachievementUbadge,
785
- ue as UachievementUunlock,
786
- me as UgameUcontrols,
787
- he as UleaderboardUpodium,
788
- ye as UscoreUdisplay,
789
- xe as UscratchUcard,
790
- ke as UspinUwheel,
791
- Ee as VideoPlayer
495
+ ur as LeadScorer,
496
+ br as PlayerStats,
497
+ fr as ScoreBoard,
498
+ ir as SustainabilityScore,
499
+ sr as UachievementUbadge,
500
+ cr as UachievementUunlock,
501
+ dr as UgameUcontrols,
502
+ gr as UleaderboardUpodium,
503
+ mr as UscoreUdisplay,
504
+ yr as UscratchUcard,
505
+ pr as UspinUwheel
792
506
  };