@mjsz-vbr-elements/core 2.32.0 → 2.33.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,12 +1,12 @@
1
1
  /**
2
2
  * name: @mjsz-vbr-elements/core
3
- * version: v2.32.0 - 11/11/2025, 12:46:30
3
+ * version: v2.33.1 - 25/11/2025, 22:37:44
4
4
  * (c) 2025
5
5
  * description: Data visualization for MJSZ VBR
6
6
  * author: Ákos Stegner <akos.stegner@gmail.com>
7
7
  */
8
8
  import { SORT_STATE_ORIGINAL as de, SORT_STATE_ASCEND as ye } from "./constants.js";
9
- import { E as m, K as $, G as l, x as u, L as h, M as B, N as J, O as z, _ as f, P as A, J as ve, Q as K, R as ge, S as Ne, T as Q, U as Te, V as L, W as Se, X as _e, Y as Ie, Z as be, $ as Oe, a0 as Ae, a1 as G, C as Re, a2 as O, a3 as Ce, z as g, u as Ee, I as j, H as Pe, w as S, F as R, f as N, c as V, b as De, a as $e, v as je } from "./datetime-bWwGbGlR.js";
9
+ import { G as m, L as $, v as l, z as u, M as h, N as B, O as J, P as z, _ as f, Q as A, K as ve, R as K, S as ge, T as Ne, U as Q, V as Te, W as L, X as Se, Y as _e, Z as Ie, $ as be, a0 as Oe, a1 as Ae, a2 as G, E as Re, a3 as O, a4 as Ee, A as g, u as Pe, J as j, I as Ce, x as S, H as R, f as N, c as V, b as De, a as $e, w as je } from "./datetime-B_IKGlWy.js";
10
10
  var Z = /* @__PURE__ */ m(function(e, r) {
11
11
  if (e === r)
12
12
  return r;
@@ -14,12 +14,12 @@ var Z = /* @__PURE__ */ m(function(e, r) {
14
14
  if (d > p != p > d)
15
15
  return p > d ? p : d;
16
16
  }
17
- var s = n(e, r);
18
- if (s !== void 0)
19
- return s;
20
- var a = n(typeof e, typeof r);
17
+ var a = n(e, r);
21
18
  if (a !== void 0)
22
- return a === typeof e ? e : r;
19
+ return a;
20
+ var s = n(typeof e, typeof r);
21
+ if (s !== void 0)
22
+ return s === typeof e ? e : r;
23
23
  var i = $(e), c = n(i, $(r));
24
24
  return c !== void 0 && c === i ? e : r;
25
25
  }), w = /* @__PURE__ */ m(function(e, r) {
@@ -28,24 +28,24 @@ var Z = /* @__PURE__ */ m(function(e, r) {
28
28
  return B(e) ? !0 : !e || typeof e != "object" || J(e) ? !1 : e.length === 0 ? !0 : e.length > 0 ? e.hasOwnProperty(0) && e.hasOwnProperty(e.length - 1) : !1;
29
29
  }), U = typeof Symbol < "u" ? Symbol.iterator : "@@iterator";
30
30
  function Le(t, e, r) {
31
- return function(s, a, i) {
31
+ return function(a, s, i) {
32
32
  if (Be(i))
33
- return t(s, a, i);
33
+ return t(a, s, i);
34
34
  if (i == null)
35
- return a;
35
+ return s;
36
36
  if (typeof i["fantasy-land/reduce"] == "function")
37
- return e(s, a, i, "fantasy-land/reduce");
37
+ return e(a, s, i, "fantasy-land/reduce");
38
38
  if (i[U] != null)
39
- return r(s, a, i[U]());
39
+ return r(a, s, i[U]());
40
40
  if (typeof i.next == "function")
41
- return r(s, a, i);
41
+ return r(a, s, i);
42
42
  if (typeof i.reduce == "function")
43
- return e(s, a, i, "reduce");
43
+ return e(a, s, i, "reduce");
44
44
  throw new TypeError("reduce: list must be array or iterable");
45
45
  };
46
46
  }
47
47
  function Ge(t, e, r) {
48
- for (var n = 0, s = r.length; n < s; ) {
48
+ for (var n = 0, a = r.length; n < a; ) {
49
49
  if (e = t["@@transducer/step"](e, r[n]), e && e["@@transducer/reduced"]) {
50
50
  e = e["@@transducer/value"];
51
51
  break;
@@ -112,53 +112,53 @@ var M = /* @__PURE__ */ f(function(t, e, r) {
112
112
  return !1;
113
113
  });
114
114
  }), re = /* @__PURE__ */ h(function(e) {
115
- for (var r = ve(e), n = r.length, s = [], a = 0; a < n; )
116
- s[a] = e[r[a]], a += 1;
117
- return s;
115
+ for (var r = ve(e), n = r.length, a = [], s = 0; s < n; )
116
+ a[s] = e[r[s]], s += 1;
117
+ return a;
118
118
  }), _ = /* @__PURE__ */ f(function(e, r, n) {
119
- var s = e(r), a = e(n);
120
- return s < a ? -1 : s > a ? 1 : 0;
119
+ var a = e(r), s = e(n);
120
+ return a < s ? -1 : a > s ? 1 : 0;
121
121
  }), ne = /* @__PURE__ */ h(function(e) {
122
122
  return A(e.length, e);
123
123
  });
124
124
  function qe(t, e, r) {
125
125
  if (K(t) && B(r)) {
126
- var n = t < 0 ? r.length + t : t, s = [].concat(r);
127
- return s[n] = e, s;
126
+ var n = t < 0 ? r.length + t : t, a = [].concat(r);
127
+ return a[n] = e, a;
128
128
  }
129
- var a = {};
129
+ var s = {};
130
130
  for (var i in r)
131
- a[i] = r[i];
132
- return a[t] = e, a;
131
+ s[i] = r[i];
132
+ return s[t] = e, s;
133
133
  }
134
134
  var He = /* @__PURE__ */ h(function(e) {
135
135
  return e == null;
136
136
  }), Xe = /* @__PURE__ */ f(function t(e, r, n) {
137
137
  if (e.length === 0)
138
138
  return r;
139
- var s = e[0];
139
+ var a = e[0];
140
140
  if (e.length > 1) {
141
- var a = ge(s, n);
142
- (He(a) || typeof a != "object") && (a = K(e[1]) ? [] : {}), r = t(Array.prototype.slice.call(e, 1), r, a);
141
+ var s = ge(a, n);
142
+ (He(s) || typeof s != "object") && (s = K(e[1]) ? [] : {}), r = t(Array.prototype.slice.call(e, 1), r, s);
143
143
  }
144
- return qe(s, r, n);
144
+ return qe(a, r, n);
145
145
  }), Ye = /* @__PURE__ */ f(function(e, r, n) {
146
146
  return Xe([e], r, n);
147
147
  });
148
- function se(t) {
148
+ function ae(t) {
149
149
  return new RegExp(t.source, t.flags ? t.flags : (t.global ? "g" : "") + (t.ignoreCase ? "i" : "") + (t.multiline ? "m" : "") + (t.sticky ? "y" : "") + (t.unicode ? "u" : "") + (t.dotAll ? "s" : ""));
150
150
  }
151
151
  function x(t, e, r) {
152
152
  if (r || (r = new ze()), Je(t))
153
153
  return t;
154
- var n = function(a) {
154
+ var n = function(s) {
155
155
  var i = r.get(t);
156
156
  if (i)
157
157
  return i;
158
- r.set(t, a);
158
+ r.set(t, s);
159
159
  for (var c in t)
160
- Object.prototype.hasOwnProperty.call(t, c) && (a[c] = e ? x(t[c], !0, r) : t[c]);
161
- return a;
160
+ Object.prototype.hasOwnProperty.call(t, c) && (s[c] = e ? x(t[c], !0, r) : t[c]);
161
+ return s;
162
162
  };
163
163
  switch (Ne(t)) {
164
164
  case "Object":
@@ -168,7 +168,7 @@ function x(t, e, r) {
168
168
  case "Date":
169
169
  return new Date(t.valueOf());
170
170
  case "RegExp":
171
- return se(t);
171
+ return ae(t);
172
172
  case "Int8Array":
173
173
  case "Uint8Array":
174
174
  case "Uint8ClampedArray":
@@ -194,8 +194,8 @@ var ze = /* @__PURE__ */ function() {
194
194
  this.map = {}, this.length = 0;
195
195
  }
196
196
  return t.prototype.set = function(e, r) {
197
- var n = this.hash(e), s = this.map[n];
198
- s || (this.map[n] = s = []), s.push([e, r]), this.length += 1;
197
+ var n = this.hash(e), a = this.map[n];
198
+ a || (this.map[n] = a = []), a.push([e, r]), this.length += 1;
199
199
  }, t.prototype.hash = function(e) {
200
200
  var r = [];
201
201
  for (var n in e)
@@ -205,18 +205,18 @@ var ze = /* @__PURE__ */ function() {
205
205
  if (this.length <= 180) {
206
206
  for (var r in this.map)
207
207
  for (var i = this.map[r], n = 0; n < i.length; n += 1) {
208
- var s = i[n];
209
- if (s[0] === e)
210
- return s[1];
208
+ var a = i[n];
209
+ if (a[0] === e)
210
+ return a[1];
211
211
  }
212
212
  return;
213
213
  }
214
- var a = this.hash(e), i = this.map[a];
214
+ var s = this.hash(e), i = this.map[s];
215
215
  if (i)
216
216
  for (var n = 0; n < i.length; n += 1) {
217
- var s = i[n];
218
- if (s[0] === e)
219
- return s[1];
217
+ var a = i[n];
218
+ if (a[0] === e)
219
+ return a[1];
220
220
  }
221
221
  }, t;
222
222
  }();
@@ -242,19 +242,19 @@ function T() {
242
242
  throw new Error("pipe requires at least one argument");
243
243
  return z(arguments[0].length, M(Ke, arguments[0], Ve(arguments)));
244
244
  }
245
- var C = /* @__PURE__ */ h(function(e) {
245
+ var E = /* @__PURE__ */ h(function(e) {
246
246
  return J(e) ? e.split("").reverse().join("") : Array.prototype.slice.call(e, 0).reverse();
247
247
  });
248
248
  function o() {
249
249
  if (arguments.length === 0)
250
250
  throw new Error("compose requires at least one argument");
251
- return T.apply(this, C(arguments));
251
+ return T.apply(this, E(arguments));
252
252
  }
253
- var ae = /* @__PURE__ */ h(function(t) {
253
+ var se = /* @__PURE__ */ h(function(t) {
254
254
  return Q(0, t);
255
255
  }), Ze = /* @__PURE__ */ function() {
256
- function t(e, r, n, s) {
257
- this.valueFn = e, this.valueAcc = r, this.keyFn = n, this.xf = s, this.inputs = {};
256
+ function t(e, r, n, a) {
257
+ this.valueFn = e, this.valueAcc = r, this.keyFn = n, this.xf = a, this.inputs = {};
258
258
  }
259
259
  return t.prototype["@@transducer/init"] = Te.init, t.prototype["@@transducer/result"] = function(e) {
260
260
  var r;
@@ -274,15 +274,15 @@ function we(t, e, r) {
274
274
  return new Ze(t, e, r, n);
275
275
  };
276
276
  }
277
- var ie = /* @__PURE__ */ Se(4, [], /* @__PURE__ */ _e([], we, function(e, r, n, s) {
278
- var a = te(function(i, c) {
277
+ var ie = /* @__PURE__ */ Se(4, [], /* @__PURE__ */ _e([], we, function(e, r, n, a) {
278
+ var s = te(function(i, c) {
279
279
  var d = n(c), p = e(L(d, i) ? i[d] : x(r, !1), c);
280
280
  return p && p["@@transducer/reduced"] ? Ie(i) : (i[d] = p, i);
281
281
  });
282
- return ee(a, {}, s);
282
+ return ee(s, {}, a);
283
283
  })), y = /* @__PURE__ */ f(function(e, r, n) {
284
- var s = e(r), a = e(n);
285
- return s > a ? -1 : s < a ? 1 : 0;
284
+ var a = e(r), s = e(n);
285
+ return a > s ? -1 : a < s ? 1 : 0;
286
286
  }), et = /* @__PURE__ */ h(function(t) {
287
287
  return Q(-1, t);
288
288
  }), I = /* @__PURE__ */ m(/* @__PURE__ */ F("groupBy", /* @__PURE__ */ ie(function(t, e) {
@@ -294,38 +294,38 @@ var ie = /* @__PURE__ */ Se(4, [], /* @__PURE__ */ _e([], we, function(e, r, n,
294
294
  }), rt = /* @__PURE__ */ m(be), q = /* @__PURE__ */ ie(function(t, e) {
295
295
  return e;
296
296
  }, null), nt = /* @__PURE__ */ f(function(e, r, n) {
297
- return Oe(function(s) {
298
- return Ae(e, s, n);
297
+ return Oe(function(a) {
298
+ return Ae(e, a, n);
299
299
  }, r);
300
300
  });
301
- function st(t) {
301
+ function at(t) {
302
302
  if (t == null)
303
303
  throw new TypeError("Cannot convert undefined or null to object");
304
304
  for (var e = Object(t), r = 1, n = arguments.length; r < n; ) {
305
- var s = arguments[r];
306
- if (s != null)
307
- for (var a in s)
308
- L(a, s) && (e[a] = s[a]);
305
+ var a = arguments[r];
306
+ if (a != null)
307
+ for (var s in a)
308
+ L(s, a) && (e[s] = a[s]);
309
309
  r += 1;
310
310
  }
311
311
  return e;
312
312
  }
313
- const at = typeof Object.assign == "function" ? Object.assign : st;
313
+ const st = typeof Object.assign == "function" ? Object.assign : at;
314
314
  var ue = /* @__PURE__ */ G(1, "join"), it = /* @__PURE__ */ m(function(e, r) {
315
315
  return function(n) {
316
- return function(s) {
317
- return l(function(a) {
318
- return r(a, s);
319
- }, n(e(s)));
316
+ return function(a) {
317
+ return l(function(s) {
318
+ return r(s, a);
319
+ }, n(e(a)));
320
320
  };
321
321
  };
322
322
  }), oe = /* @__PURE__ */ h(function(e) {
323
323
  return it(u(e), Ye(e));
324
324
  }), ut = /* @__PURE__ */ m(function(e, r) {
325
- return at({}, r, e);
325
+ return st({}, r, e);
326
326
  }), ot = /* @__PURE__ */ f(function(e, r, n) {
327
- return Re(function(s, a, i) {
328
- return e(a, i);
327
+ return Re(function(a, s, i) {
328
+ return e(s, i);
329
329
  }, r, n);
330
330
  }), ce = function(t) {
331
331
  return {
@@ -335,31 +335,31 @@ var ue = /* @__PURE__ */ G(1, "join"), it = /* @__PURE__ */ m(function(e, r) {
335
335
  }
336
336
  };
337
337
  }, le = /* @__PURE__ */ f(function(e, r, n) {
338
- return e(function(s) {
339
- return ce(r(s));
338
+ return e(function(a) {
339
+ return ce(r(a));
340
340
  })(n).value;
341
341
  }), fe = /* @__PURE__ */ f(function(e, r, n) {
342
- return O(Ce(r, n), e);
342
+ return O(Ee(r, n), e);
343
343
  }), pe = /* @__PURE__ */ m(function(e, r) {
344
- for (var n = {}, s = 0; s < e.length; )
345
- e[s] in r && (n[e[s]] = r[e[s]]), s += 1;
344
+ for (var n = {}, a = 0; a < e.length; )
345
+ e[a] in r && (n[e[a]] = r[e[a]]), a += 1;
346
346
  return n;
347
- }), E = /* @__PURE__ */ f(function(e, r, n) {
348
- return O(e, u(r, n));
349
347
  }), P = /* @__PURE__ */ f(function(e, r, n) {
348
+ return O(e, u(r, n));
349
+ }), C = /* @__PURE__ */ f(function(e, r, n) {
350
350
  return n.replace(e, r);
351
351
  }), W = /* @__PURE__ */ m(function(e, r) {
352
352
  return Array.prototype.slice.call(r, 0).sort(e);
353
353
  }), v = /* @__PURE__ */ m(function(e, r) {
354
- return Array.prototype.slice.call(r, 0).sort(function(n, s) {
355
- var a = e(n), i = e(s);
356
- return a < i ? -1 : a > i ? 1 : 0;
354
+ return Array.prototype.slice.call(r, 0).sort(function(n, a) {
355
+ var s = e(n), i = e(a);
356
+ return s < i ? -1 : s > i ? 1 : 0;
357
357
  });
358
358
  }), D = /* @__PURE__ */ m(function(e, r) {
359
- return Array.prototype.slice.call(r, 0).sort(function(n, s) {
360
- for (var a = 0, i = 0; a === 0 && i < e.length; )
361
- a = e[i](n, s), i += 1;
362
- return a;
359
+ return Array.prototype.slice.call(r, 0).sort(function(n, a) {
360
+ for (var s = 0, i = 0; s === 0 && i < e.length; )
361
+ s = e[i](n, a), i += 1;
362
+ return s;
363
363
  });
364
364
  });
365
365
  function ct(t) {
@@ -368,31 +368,13 @@ function ct(t) {
368
368
  var lt = /* @__PURE__ */ m(function(e, r) {
369
369
  if (!ct(e))
370
370
  throw new TypeError("‘test’ requires a value of type RegExp as its first argument; received " + $(e));
371
- return se(e).test(r);
371
+ return ae(e).test(r);
372
372
  }), H = /* @__PURE__ */ G(0, "toLowerCase"), ft = /* @__PURE__ */ G(0, "toUpperCase");
373
- function Ot(t, e = "body") {
374
- if (!t)
375
- return;
376
- if (typeof e != "string") {
377
- e?.append(t);
378
- return;
379
- }
380
- document.querySelector(e)?.append(t);
381
- }
382
- function At(t, e = () => ({})) {
383
- return t.slice().sort((r, n) => {
384
- const s = e(r), a = e(n);
385
- if (s === null || a === null)
386
- return 0;
387
- const i = s.compareDocumentPosition(a);
388
- return i & Node.DOCUMENT_POSITION_FOLLOWING ? -1 : i & Node.DOCUMENT_POSITION_PRECEDING ? 1 : 0;
389
- });
390
- }
391
373
  let pt = 0;
392
374
  function mt() {
393
375
  return ++pt;
394
376
  }
395
- function Rt(t = []) {
377
+ function Ot(t = []) {
396
378
  return {
397
379
  result: [...t],
398
380
  filteredRowsLength: 0,
@@ -406,9 +388,9 @@ function Rt(t = []) {
406
388
  },
407
389
  filter(e, r = [], n = !1) {
408
390
  if (e) {
409
- const s = r.map(
391
+ const a = r.map(
410
392
  (c) => n ? T(S(c), O(e)) : T(u(c), H, rt(H(e)))
411
- ), a = ne((c) => c.name ? le(oe("name"), P(",", ""), c) : c), i = R(T(a, ke([...s])), this.result);
393
+ ), s = ne((c) => c.name ? le(oe("name"), C(",", ""), c) : c), i = R(T(s, ke([...a])), this.result);
412
394
  this.isFiltered = !0, this.filteredRowsLength = i.length, this.result = i;
413
395
  }
414
396
  return this;
@@ -422,9 +404,9 @@ function Rt(t = []) {
422
404
  return this.result = D(e.orders.map((n) => o(r(n.direction), u)(n.target)))(this.result), this;
423
405
  },
424
406
  addIndex(e = null) {
425
- return this.result.reduce((r, n, s) => {
426
- const a = r[r.length - 1] || [], i = e && a[e] === n[e];
427
- return n.index = i ? a.index : s + 1, n.indexClass = i ? "is-duplicated" : null, r.push(n), r;
407
+ return this.result.reduce((r, n, a) => {
408
+ const s = r[r.length - 1] || [], i = e && s[e] === n[e];
409
+ return n.index = i ? s.index : a + 1, n.indexClass = i ? "is-duplicated" : null, r.push(n), r;
428
410
  }, []), this;
429
411
  },
430
412
  addContinuousIndex() {
@@ -437,8 +419,8 @@ function Rt(t = []) {
437
419
  if (!r)
438
420
  return this;
439
421
  e = Number(e), r = Number(r);
440
- const n = (e - 1) * r, s = n + r;
441
- return this.result = this.result.slice(n, s), this;
422
+ const n = (e - 1) * r, a = n + r;
423
+ return this.result = this.result.slice(n, a), this;
442
424
  },
443
425
  more(e, r) {
444
426
  return this.result = this.result.slice(Number(e), Number(r)), this;
@@ -480,7 +462,7 @@ function Rt(t = []) {
480
462
  }
481
463
  };
482
464
  }
483
- const Ct = (t, ...e) => l(o(...e))(t);
465
+ const At = (t, ...e) => l(o(...e))(t);
484
466
  function b(t) {
485
467
  return {
486
468
  ...t,
@@ -501,32 +483,32 @@ function me(t) {
501
483
  ...t?.team?.id && { teamName: t.team.longName }
502
484
  };
503
485
  }
504
- function Et(t = "", e = "hu") {
486
+ function Rt(t = "", e = "hu") {
505
487
  return (r) => ({
506
488
  ...r,
507
489
  gameDateDate: N(r.gameDate, "L dddd", t, e),
508
490
  gameDateTime: N(r.gameDate, "HH:mm", t, e)
509
491
  });
510
492
  }
511
- function Pt(t) {
493
+ function Et(t) {
512
494
  return (e) => ({
513
495
  ...e,
514
496
  gameResult: gt(e)
515
497
  });
516
498
  }
517
- function Dt(t) {
499
+ function Pt(t) {
518
500
  return {
519
501
  ...t,
520
502
  opponent: vt(t)
521
503
  };
522
504
  }
523
- function $t(t) {
505
+ function Ct(t) {
524
506
  return {
525
507
  ...t,
526
508
  resultType: Nt(t)
527
509
  };
528
510
  }
529
- function jt(t) {
511
+ function Dt(t) {
530
512
  return {
531
513
  ...t,
532
514
  rowClasses: t.optional ? "is-optional" : ""
@@ -538,22 +520,22 @@ function ht(t = []) {
538
520
  [t]: e[t]?.toUpperCase()
539
521
  });
540
522
  }
541
- function Bt(t = []) {
523
+ function $t(t = []) {
542
524
  return (e) => (t.map((r) => e[r] ? e[`${r}Sec`] = V(e[r]) : e), e);
543
525
  }
544
- function Lt(t = []) {
526
+ function jt(t = []) {
545
527
  return (e) => (t.map((r) => e[r] ? e[`${r}Min`] = De(e[r]) : e), e);
546
528
  }
547
- function Gt(t = []) {
529
+ function Bt(t = []) {
548
530
  return (e) => (t.map((r) => e[`${r}Min`] = $e(e[r])), e);
549
531
  }
550
- function Mt(t) {
532
+ function Lt(t) {
551
533
  return {
552
534
  ...t,
553
535
  periodResults: t.result?.match(/\(.*?\)/)?.[0] ?? ""
554
536
  };
555
537
  }
556
- const dt = (t, e) => new Date(t.gameDate).getTime() - new Date(e.gameDate).getTime(), xt = D([dt, _(u("id")), _(u("gameId"))]), yt = (t) => (e, r) => e[t].localeCompare(r[t], "hu"), X = W(yt("name"));
538
+ const dt = (t, e) => new Date(t.gameDate).getTime() - new Date(e.gameDate).getTime(), Gt = D([dt, _(u("id")), _(u("gameId"))]), yt = (t) => (e, r) => e[t].localeCompare(r[t], "hu"), X = W(yt("name"));
557
539
  function vt(t) {
558
540
  return [t.isHomeGame ? null : "@", t.opponent?.shortName].join(" ");
559
541
  }
@@ -565,7 +547,7 @@ function Nt(t) {
565
547
  const e = t.gameResult.split(":"), r = e[0] > e[1], n = e[0] < e[1];
566
548
  return r && t.isOvertime ? "OTW" : r && t.isShootout ? "SOW" : r ? "W" : n && t.isOvertime ? "OTL" : n && t.isShootout ? "SOL" : n ? "L" : "D";
567
549
  }
568
- function Ft(t) {
550
+ function Mt(t) {
569
551
  return t.map((e) => ({
570
552
  phaseId: e.phaseId,
571
553
  phaseName: Object.values({
@@ -580,43 +562,43 @@ function Ft(t) {
580
562
  function Tt(t) {
581
563
  return t.player ? t.player.nationality.includes("hu") ? `${t.player.lastName} ${t.player.firstName}` : `${t.player.lastName}, ${t.player.firstName}` : `${t.lastName} ${t.firstName}`;
582
564
  }
583
- const Wt = o(
565
+ const xt = o(
584
566
  W(y(u("seasonName"))),
585
567
  l(pe(["championshipId", "seasonName"]))
586
- ), Ut = (t) => W(_(u("teamName")), t), kt = o(v(u("sectionId")), g(o(Ee, u("phases")))), qt = o(u("sectionId"), ae), Ht = o(u("phaseName"), ae), Xt = v(u("phaseId")), Yt = (t) => o(v(u("name")), l(o(b, me)))(t), Jt = o(u("phaseName"), et), zt = o(ft, P("_", "-")), Kt = o(g(lt(/-:-/)), j(",")), Qt = o(l(j(":")), l(Pe), j(","), P(/^\(|\)$/g, "")), Vt = D([y(u("startingFive"))]), Zt = o(
568
+ ), Ft = (t) => W(_(u("teamName")), t), Wt = o(v(u("sectionId")), g(o(Pe, u("phases")))), Ut = o(u("sectionId"), se), kt = o(u("phaseName"), se), qt = v(u("phaseId")), Ht = o(v(u("name")), l(o(b, me))), Xt = o(u("phaseName"), et), Yt = o(ft, C("_", "-")), Jt = o(g(lt(/-:-/)), j(",")), zt = o(l(j(":")), l(Ce), j(","), C(/^\(|\)$/g, "")), Kt = D([y(u("startingFive"))]), Qt = o(
587
569
  ue(", "),
588
570
  l((t) => `${t.lastName} ${t.firstName}`),
589
571
  g((t) => !t)
590
- ), wt = o(I(u("eventPeriod")), C, g(E("Period", "type"))), er = I(u("row")), tr = (t, e) => R(Ue([fe(e, ["team", "id"]), E("Gól", "type")]), C(t)), rr = o(l(b), pe(["headCoach", "secondCoach"])), nr = o(C, l((t) => ({ ...t, eventId: t.eventId ? t.eventId : mt() }))), sr = (t) => v(u("eventTimeSec"), Object.values(t));
591
- function ar(t, e) {
592
- const r = (s) => {
593
- const a = ["first_referee", "second_referee", "first_line_judge", "second_line_judge"].indexOf(s.role);
594
- return a > -1 ? a : 4;
595
- }, n = (s) => ({ ...b(s), role: e(`role.${s.role}`) });
572
+ ), Vt = o(I(u("eventPeriod")), E, g(P("Period", "type"))), Zt = I(u("row")), wt = (t, e) => R(Ue([fe(e, ["team", "id"]), P("Gól", "type")]), E(t)), er = o(l(b), pe(["headCoach", "secondCoach"])), tr = o(E, l((t) => ({ ...t, eventId: t.eventId ? t.eventId : mt() }))), rr = (t) => v(u("eventTimeSec"), Object.values(t));
573
+ function nr(t, e) {
574
+ const r = (a) => {
575
+ const s = ["first_referee", "second_referee", "first_line_judge", "second_line_judge"].indexOf(a.role);
576
+ return s > -1 ? s : 4;
577
+ }, n = (a) => ({ ...b(a), role: e(`role.${a.role}`) });
596
578
  return I(u("type"), l(n, v(r, Object.values(t))));
597
579
  }
598
- const ir = D([
580
+ const ar = D([
599
581
  y(u("points")),
600
582
  _(u("gamesPlayed")),
601
583
  y(u("w")),
602
584
  y(u("gd")),
603
585
  y(u("gf"))
604
- ]), ur = (t, e) => g(E(t, "championshipId"), e), or = (t, e) => R(E(t, "championshipId"), e), cr = o(g((t) => ["Rájátszás", "Újrajátszandó"].includes(t.phaseName)), S([0, "phases"])), lr = o(
586
+ ]), sr = (t, e) => g(P(t, "championshipId"), e), ir = (t, e) => R(P(t, "championshipId"), e), ur = o(g((t) => ["Rájátszás", "Újrajátszandó"].includes(t.phaseName)), S([0, "phases"])), or = o(
605
587
  I(St),
606
588
  v((t) => ["ld", "rd", "d"].includes(t.position?.toLowerCase()) ? 1 : ["lw", "rw", "c"].includes(t.position?.toLowerCase()) ? 2 : 0),
607
589
  v(_t),
608
590
  l(o(b, me, ht(["position"])))
609
591
  );
610
- function fr({ goalieStats: t, fieldPlayers: e, playersPenalty: r }) {
611
- const n = l(S(["player", "playerId"]))(t), a = g((p) => n.includes(p.player.playerId), r), i = nt((p, he) => p.player.playerId === he, r, n), c = Y(e, a), d = Y(t, i);
592
+ function cr({ goalieStats: t, fieldPlayers: e, playersPenalty: r }) {
593
+ const n = l(S(["player", "playerId"]))(t), s = g((p) => n.includes(p.player.playerId), r), i = nt((p, he) => p.player.playerId === he, r, n), c = Y(e, s), d = Y(t, i);
612
594
  return {
613
595
  fieldPlayers: X(c),
614
596
  goalies: X(d)
615
597
  };
616
598
  }
617
- const pr = ne((t, e) => T(R(fe(e, ["team", "id"])), l(b))(t));
618
- function mr(t) {
619
- const e = t.city ? le(oe("city"), P(/$/, ",")) : () => ({});
599
+ const lr = ne((t, e) => T(R(fe(e, ["team", "id"])), l(b))(t));
600
+ function fr(t) {
601
+ const e = t.city ? le(oe("city"), C(/$/, ",")) : () => ({});
620
602
  return o(ue(" "), re, e, je(["type"]))(t);
621
603
  }
622
604
  function St(t) {
@@ -628,10 +610,28 @@ function _t(t) {
628
610
  function Y(t, e) {
629
611
  return re(ot(ut, q(S(["player", "playerId"]), t), q(S(["player", "playerId"]), e)));
630
612
  }
613
+ function pr(t, e = "body") {
614
+ if (!t)
615
+ return;
616
+ if (typeof e != "string") {
617
+ e?.append(t);
618
+ return;
619
+ }
620
+ document.querySelector(e)?.append(t);
621
+ }
622
+ function mr(t, e = () => ({})) {
623
+ return t.slice().sort((r, n) => {
624
+ const a = e(r), s = e(n);
625
+ if (a === null || s === null)
626
+ return 0;
627
+ const i = a.compareDocumentPosition(s);
628
+ return i & Node.DOCUMENT_POSITION_FOLLOWING ? -1 : i & Node.DOCUMENT_POSITION_PRECEDING ? 1 : 0;
629
+ });
630
+ }
631
631
  class hr extends Error {
632
632
  constructor(e, r = {}) {
633
- const { key: n, cause: s } = r;
634
- super(e), this.name = "WidgetError", this.key = n, this.cause = s;
633
+ const { key: n, cause: a } = r;
634
+ super(e), this.name = "WidgetError", this.key = n, this.cause = a;
635
635
  }
636
636
  }
637
637
  const dr = {
@@ -649,63 +649,63 @@ const dr = {
649
649
  };
650
650
  export {
651
651
  pe as $,
652
- Kt as A,
653
- Qt as B,
654
- Vt as C,
655
- Zt as D,
656
- wt as E,
657
- er as F,
658
- tr as G,
659
- rr as H,
660
- nr as I,
661
- sr as J,
662
- ar as K,
663
- ir as L,
664
- ur as M,
665
- or as N,
666
- cr as O,
667
- lr as P,
668
- fr as Q,
669
- pr as R,
670
- mr as S,
671
- Ot as T,
672
- At as U,
652
+ Jt as A,
653
+ zt as B,
654
+ Kt as C,
655
+ Qt as D,
656
+ Vt as E,
657
+ Zt as F,
658
+ wt as G,
659
+ er as H,
660
+ tr as I,
661
+ rr as J,
662
+ nr as K,
663
+ ar as L,
664
+ sr as M,
665
+ ir as N,
666
+ ur as O,
667
+ or as P,
668
+ cr as Q,
669
+ lr as R,
670
+ fr as S,
671
+ pr as T,
672
+ mr as U,
673
673
  dr as V,
674
674
  hr as W,
675
675
  yr as X,
676
- ae as Y,
676
+ se as Y,
677
677
  et as Z,
678
678
  ut as _,
679
- Pt as a,
679
+ Et as a,
680
680
  T as a0,
681
- E as a1,
682
- C as a2,
681
+ P as a1,
682
+ E as a2,
683
683
  v as a3,
684
684
  x as a4,
685
685
  M as a5,
686
- Dt as b,
687
- Rt as c,
688
- $t as d,
689
- Bt as e,
690
- Lt as f,
691
- Et as g,
692
- Gt as h,
693
- Mt as i,
694
- xt as j,
695
- Ft as k,
686
+ Pt as b,
687
+ Ot as c,
688
+ Ct as d,
689
+ $t as e,
690
+ jt as f,
691
+ Rt as g,
692
+ Bt as h,
693
+ Lt as i,
694
+ Gt as j,
695
+ Mt as k,
696
696
  X as l,
697
- Wt as m,
698
- Ut as n,
699
- kt as o,
697
+ xt as m,
698
+ Ft as n,
699
+ Wt as o,
700
700
  b as p,
701
- qt as q,
702
- Ct as r,
703
- jt as s,
701
+ Ut as q,
702
+ At as r,
703
+ Dt as s,
704
704
  me as t,
705
705
  ht as u,
706
- Ht as v,
707
- Xt as w,
708
- Yt as x,
709
- Jt as y,
710
- zt as z
706
+ kt as v,
707
+ qt as w,
708
+ Ht as x,
709
+ Xt as y,
710
+ Yt as z
711
711
  };