@mjsz-vbr-elements/core 2.3.8 → 2.4.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/{AdditionalStandingsText-DbEQVH0C.js → AdditionalStandingsText-DlP-tdH1.js} +548 -458
- package/dist/columns.js +1 -1
- package/dist/components.js +13 -12
- package/dist/composables.js +23 -23
- package/dist/constants.js +1 -1
- package/dist/{convert-BEp1U263.js → convert-BUiKPu9l.js} +111 -101
- package/dist/datetime-Df9jKQTx.js +1303 -0
- package/dist/index.iife.js +4 -4
- package/dist/index.iife.js.br +0 -0
- package/dist/index.iife.js.gz +0 -0
- package/dist/index.js +101 -88
- package/dist/{useAdditionalText-B4_ntvb_.js → useAdditionalText-Bi2CUi4-.js} +90 -90
- package/dist/utils.js +60 -48
- package/package.json +3 -2
- package/dist/datetime-C3O51pdW.js +0 -1224
package/dist/columns.js
CHANGED
package/dist/components.js
CHANGED
|
@@ -1,25 +1,26 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* name: @mjsz-vbr-elements/core
|
|
3
|
-
* version: v2.
|
|
3
|
+
* version: v2.4.0 - 06/06/2024, 12:35:57
|
|
4
4
|
* (c) 2024
|
|
5
5
|
* description: Data visualization for MJSZ VBR
|
|
6
6
|
* author: Ákos Stegner <akos.stegner@gmail.com>
|
|
7
7
|
*/
|
|
8
|
-
import {
|
|
8
|
+
import { n as s, c as r, b as o, d as t, e as i, m as l, g as n, I as c, _ as d, k as S, a as b, j as g, f as T, h as m, i as v, l as I } from "./AdditionalStandingsText-DlP-tdH1.js";
|
|
9
9
|
export {
|
|
10
10
|
s as AdditionalStandingsText,
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
l as
|
|
16
|
-
n as
|
|
11
|
+
r as BaseSelect,
|
|
12
|
+
o as DataTable,
|
|
13
|
+
t as ErrorNotice,
|
|
14
|
+
i as ErrorProvider,
|
|
15
|
+
l as FetchMoreObserver,
|
|
16
|
+
n as FloatingPanel,
|
|
17
|
+
c as I18NProvider,
|
|
17
18
|
d as Image,
|
|
18
|
-
|
|
19
|
-
|
|
19
|
+
S as LoadingIndicator,
|
|
20
|
+
b as Paginator,
|
|
20
21
|
g as ResponsiveTable,
|
|
21
22
|
T as ScheduleTable,
|
|
22
|
-
|
|
23
|
-
|
|
23
|
+
m as SeasonSelector,
|
|
24
|
+
v as StatisticsTable,
|
|
24
25
|
I as TimezoneSelector
|
|
25
26
|
};
|
package/dist/composables.js
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* name: @mjsz-vbr-elements/core
|
|
3
|
-
* version: v2.
|
|
3
|
+
* version: v2.4.0 - 06/06/2024, 12:35:57
|
|
4
4
|
* (c) 2024
|
|
5
5
|
* description: Data visualization for MJSZ VBR
|
|
6
6
|
* author: Ákos Stegner <akos.stegner@gmail.com>
|
|
7
7
|
*/
|
|
8
|
-
import { k as S, l as D, n as h, m as I, p as
|
|
9
|
-
import { c as
|
|
10
|
-
import { unref as u, ref as
|
|
8
|
+
import { k as S, l as D, n as h, m as I, p as T, q as b } from "./useAdditionalText-Bi2CUi4-.js";
|
|
9
|
+
import { c as H, i as tt, h as et, u as nt, b as rt, a as it, d as st, e as at, f as ot, g as ut, v as ct } from "./useAdditionalText-Bi2CUi4-.js";
|
|
10
|
+
import { unref as u, ref as E, watch as P, nextTick as B } from "vue";
|
|
11
11
|
import { VBR_API_BASE_URL as C } from "./constants.js";
|
|
12
|
-
import {
|
|
13
|
-
var
|
|
12
|
+
import { Q as x, T as y, C as g, S as _, J as V, I as A, i as v, f as M } from "./datetime-Df9jKQTx.js";
|
|
13
|
+
var O = /* @__PURE__ */ function() {
|
|
14
14
|
function e(t, n) {
|
|
15
15
|
this.xf = n, this.f = t, this.found = !1;
|
|
16
16
|
}
|
|
@@ -20,12 +20,12 @@ var M = /* @__PURE__ */ function() {
|
|
|
20
20
|
return this.f(n) && (this.found = !0, t = y(this.xf["@@transducer/step"](t, n))), t;
|
|
21
21
|
}, e;
|
|
22
22
|
}();
|
|
23
|
-
function
|
|
23
|
+
function R(e) {
|
|
24
24
|
return function(t) {
|
|
25
|
-
return new
|
|
25
|
+
return new O(e, t);
|
|
26
26
|
};
|
|
27
27
|
}
|
|
28
|
-
var
|
|
28
|
+
var F = /* @__PURE__ */ g(/* @__PURE__ */ _(["find"], R, function(t, n) {
|
|
29
29
|
for (var r = 0, i = n.length; r < i; ) {
|
|
30
30
|
if (t(n[r]))
|
|
31
31
|
return n[r];
|
|
@@ -77,8 +77,8 @@ const K = async (e, t, n) => {
|
|
|
77
77
|
}, L = (e) => Object.keys(e).map((t) => t + "=" + e[t]).join("&"), $ = (e) => {
|
|
78
78
|
var t;
|
|
79
79
|
return e || ((t = window.__MJSZ_VBR_WIDGET__) != null && t.apiKey ? window.__MJSZ_VBR_WIDGET__.apiKey : "");
|
|
80
|
-
},
|
|
81
|
-
const { initial: t = 1, items: n = [], limit: r, auto: i = !1 } = e, o =
|
|
80
|
+
}, Q = (e = {}) => {
|
|
81
|
+
const { initial: t = 1, items: n = [], limit: r, auto: i = !1 } = e, o = E(u(t)), s = (a) => v(a, "day");
|
|
82
82
|
return S(n, () => {
|
|
83
83
|
if (!i)
|
|
84
84
|
return;
|
|
@@ -90,7 +90,7 @@ const K = async (e, t, n) => {
|
|
|
90
90
|
o.value = a;
|
|
91
91
|
}
|
|
92
92
|
};
|
|
93
|
-
},
|
|
93
|
+
}, W = ({ options: e = {}, transform: t = (i) => i, onError: n = h, onSuccess: r = h }) => {
|
|
94
94
|
const { path: i, apiKey: o, params: s, resetOnExecute: d = !1, immediate: c = !1 } = e, {
|
|
95
95
|
state: a,
|
|
96
96
|
error: f,
|
|
@@ -109,9 +109,9 @@ const K = async (e, t, n) => {
|
|
|
109
109
|
execute: m
|
|
110
110
|
};
|
|
111
111
|
};
|
|
112
|
-
function
|
|
112
|
+
function Z(e = !1, t = h, n = h) {
|
|
113
113
|
const r = I();
|
|
114
|
-
|
|
114
|
+
P(r, (i) => {
|
|
115
115
|
if (u(e)) {
|
|
116
116
|
if (i === "visible")
|
|
117
117
|
return t();
|
|
@@ -119,20 +119,20 @@ function z(e = !1, t = h, n = h) {
|
|
|
119
119
|
}
|
|
120
120
|
});
|
|
121
121
|
}
|
|
122
|
-
const
|
|
122
|
+
const z = (e = {}) => {
|
|
123
123
|
const { items: t = [], element: n, offset: r = 0, enabled: i = !0 } = e, o = (c) => v(c, "day"), s = () => {
|
|
124
124
|
var p;
|
|
125
125
|
if (d(), !u(i))
|
|
126
126
|
return;
|
|
127
|
-
const c =
|
|
127
|
+
const c = F(w(o, "gameDate"))(u(t));
|
|
128
128
|
if (!c)
|
|
129
129
|
return;
|
|
130
|
-
const a =
|
|
130
|
+
const a = M(c.gameDate, "YYYY-MM-DD"), f = b(n).querySelector(`div[data-gamedate="${a}"]`);
|
|
131
131
|
if (!f)
|
|
132
132
|
return;
|
|
133
133
|
const l = getComputedStyle(f).getPropertyValue("--vbr-widget-sticky-top-offset") || 0, m = (((p = f.getBoundingClientRect()) == null ? void 0 : p.top) ?? 0) - u(r) - parseFloat(l);
|
|
134
134
|
window.scrollTo(0, m);
|
|
135
|
-
}, { stop: d } =
|
|
135
|
+
}, { stop: d } = T(
|
|
136
136
|
() => ({
|
|
137
137
|
items: u(t),
|
|
138
138
|
element: u(n)
|
|
@@ -143,7 +143,7 @@ const H = (e = {}) => {
|
|
|
143
143
|
);
|
|
144
144
|
};
|
|
145
145
|
export {
|
|
146
|
-
|
|
146
|
+
H as createI18n,
|
|
147
147
|
K as fetchVBRData,
|
|
148
148
|
tt as i18n,
|
|
149
149
|
et as useAdditionalText,
|
|
@@ -153,10 +153,10 @@ export {
|
|
|
153
153
|
st as useI18n,
|
|
154
154
|
at as useLazyLoadingState,
|
|
155
155
|
ot as useMainClass,
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
156
|
+
Q as usePage,
|
|
157
|
+
z as useScrollToGameDate,
|
|
158
|
+
W as useServices,
|
|
159
159
|
ut as useSort,
|
|
160
|
-
|
|
160
|
+
Z as useVisibilityChange,
|
|
161
161
|
ct as validateColumnsName
|
|
162
162
|
};
|
package/dist/constants.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* name: @mjsz-vbr-elements/core
|
|
3
|
-
* version: v2.
|
|
3
|
+
* version: v2.4.0 - 06/06/2024, 12:35:57
|
|
4
4
|
* (c) 2024
|
|
5
5
|
* description: Data visualization for MJSZ VBR
|
|
6
6
|
* author: Ákos Stegner <akos.stegner@gmail.com>
|
|
7
7
|
*/
|
|
8
|
-
import { SORT_STATE_ORIGINAL as
|
|
9
|
-
import { p,
|
|
8
|
+
import { SORT_STATE_ORIGINAL as j, SORT_STATE_ASCEND as F } from "./constants.js";
|
|
9
|
+
import { C as p, L as S, D as v, I as h, _ as f, w as g, x as R, M as O, J as c, N as T, O as M, K as N, P as U, Q as G, R as k, S as H, T as X, U as q, V as K, B as A, F as Y, H as J, f as m, c as C, b as Q, a as V } from "./datetime-Df9jKQTx.js";
|
|
10
10
|
var Z = /* @__PURE__ */ p(function(e, r) {
|
|
11
11
|
if (e === r)
|
|
12
12
|
return r;
|
|
@@ -14,38 +14,38 @@ var Z = /* @__PURE__ */ p(function(e, r) {
|
|
|
14
14
|
if (o > l != l > o)
|
|
15
15
|
return l > o ? l : o;
|
|
16
16
|
}
|
|
17
|
-
var
|
|
18
|
-
if (
|
|
19
|
-
return
|
|
17
|
+
var s = n(e, r);
|
|
18
|
+
if (s !== void 0)
|
|
19
|
+
return s;
|
|
20
20
|
var u = n(typeof e, typeof r);
|
|
21
21
|
if (u !== void 0)
|
|
22
22
|
return u === typeof e ? e : r;
|
|
23
|
-
var
|
|
24
|
-
return i !== void 0 && i ===
|
|
23
|
+
var a = S(e), i = n(a, S(r));
|
|
24
|
+
return i !== void 0 && i === a ? e : r;
|
|
25
25
|
}), z = /* @__PURE__ */ p(function(e, r) {
|
|
26
26
|
return v(h(e), r);
|
|
27
27
|
}), w = /* @__PURE__ */ f(function(e) {
|
|
28
28
|
return g(e) ? !0 : !e || typeof e != "object" || R(e) ? !1 : e.length === 0 ? !0 : e.length > 0 ? e.hasOwnProperty(0) && e.hasOwnProperty(e.length - 1) : !1;
|
|
29
29
|
}), D = typeof Symbol < "u" ? Symbol.iterator : "@@iterator";
|
|
30
30
|
function ee(t, e, r) {
|
|
31
|
-
return function(
|
|
32
|
-
if (w(
|
|
33
|
-
return t(
|
|
34
|
-
if (
|
|
31
|
+
return function(s, u, a) {
|
|
32
|
+
if (w(a))
|
|
33
|
+
return t(s, u, a);
|
|
34
|
+
if (a == null)
|
|
35
35
|
return u;
|
|
36
|
-
if (typeof
|
|
37
|
-
return e(
|
|
38
|
-
if (
|
|
39
|
-
return r(
|
|
40
|
-
if (typeof
|
|
41
|
-
return r(
|
|
42
|
-
if (typeof
|
|
43
|
-
return e(
|
|
36
|
+
if (typeof a["fantasy-land/reduce"] == "function")
|
|
37
|
+
return e(s, u, a, "fantasy-land/reduce");
|
|
38
|
+
if (a[D] != null)
|
|
39
|
+
return r(s, u, a[D]());
|
|
40
|
+
if (typeof a.next == "function")
|
|
41
|
+
return r(s, u, a);
|
|
42
|
+
if (typeof a.reduce == "function")
|
|
43
|
+
return e(s, u, a, "reduce");
|
|
44
44
|
throw new TypeError("reduce: list must be array or iterable");
|
|
45
45
|
};
|
|
46
46
|
}
|
|
47
47
|
function te(t, e, r) {
|
|
48
|
-
for (var n = 0,
|
|
48
|
+
for (var n = 0, s = r.length; n < s; ) {
|
|
49
49
|
if (e = t["@@transducer/step"](e, r[n]), e && e["@@transducer/reduced"]) {
|
|
50
50
|
e = e["@@transducer/value"];
|
|
51
51
|
break;
|
|
@@ -69,10 +69,10 @@ function ne(t, e, r) {
|
|
|
69
69
|
}
|
|
70
70
|
return t["@@transducer/result"](e);
|
|
71
71
|
}
|
|
72
|
-
function
|
|
72
|
+
function se(t, e, r, n) {
|
|
73
73
|
return t["@@transducer/result"](r[n](re(t["@@transducer/step"], t), e));
|
|
74
74
|
}
|
|
75
|
-
var
|
|
75
|
+
var x = /* @__PURE__ */ ee(te, se, ne), ae = /* @__PURE__ */ function() {
|
|
76
76
|
function t(e) {
|
|
77
77
|
this.f = e;
|
|
78
78
|
}
|
|
@@ -84,11 +84,11 @@ var E = /* @__PURE__ */ ee(te, ae, ne), se = /* @__PURE__ */ function() {
|
|
|
84
84
|
return this.f(e, r);
|
|
85
85
|
}, t;
|
|
86
86
|
}();
|
|
87
|
-
function
|
|
88
|
-
return new
|
|
87
|
+
function E(t) {
|
|
88
|
+
return new ae(t);
|
|
89
89
|
}
|
|
90
90
|
var $ = /* @__PURE__ */ c(function(t, e, r) {
|
|
91
|
-
return
|
|
91
|
+
return x(typeof t == "function" ? E(t) : t, e, r);
|
|
92
92
|
}), I = /* @__PURE__ */ f(function(e) {
|
|
93
93
|
return function() {
|
|
94
94
|
return e;
|
|
@@ -103,30 +103,30 @@ var $ = /* @__PURE__ */ c(function(t, e, r) {
|
|
|
103
103
|
return !1;
|
|
104
104
|
});
|
|
105
105
|
}), y = /* @__PURE__ */ c(function(e, r, n) {
|
|
106
|
-
var
|
|
107
|
-
return
|
|
106
|
+
var s = e(r), u = e(n);
|
|
107
|
+
return s < u ? -1 : s > u ? 1 : 0;
|
|
108
108
|
});
|
|
109
109
|
function ie(t, e, r) {
|
|
110
110
|
if (M(t) && g(r)) {
|
|
111
111
|
var n = [].concat(r);
|
|
112
112
|
return n[t] = e, n;
|
|
113
113
|
}
|
|
114
|
-
var
|
|
114
|
+
var s = {};
|
|
115
115
|
for (var u in r)
|
|
116
|
-
|
|
117
|
-
return
|
|
116
|
+
s[u] = r[u];
|
|
117
|
+
return s[t] = e, s;
|
|
118
118
|
}
|
|
119
119
|
var ce = /* @__PURE__ */ f(function(e) {
|
|
120
120
|
return e == null;
|
|
121
121
|
}), oe = /* @__PURE__ */ c(function t(e, r, n) {
|
|
122
122
|
if (e.length === 0)
|
|
123
123
|
return r;
|
|
124
|
-
var
|
|
124
|
+
var s = e[0];
|
|
125
125
|
if (e.length > 1) {
|
|
126
|
-
var u = !ce(n) && N(
|
|
126
|
+
var u = !ce(n) && N(s, n) && typeof n[s] == "object" ? n[s] : M(e[1]) ? [] : {};
|
|
127
127
|
r = t(Array.prototype.slice.call(e, 1), r, u);
|
|
128
128
|
}
|
|
129
|
-
return ie(
|
|
129
|
+
return ie(s, r, n);
|
|
130
130
|
}), le = /* @__PURE__ */ c(function(e, r, n) {
|
|
131
131
|
return oe([e], r, n);
|
|
132
132
|
});
|
|
@@ -137,15 +137,15 @@ function B(t, e, r) {
|
|
|
137
137
|
if (r || (r = new he()), fe(t))
|
|
138
138
|
return t;
|
|
139
139
|
var n = function(u) {
|
|
140
|
-
var
|
|
141
|
-
if (
|
|
142
|
-
return
|
|
140
|
+
var a = r.get(t);
|
|
141
|
+
if (a)
|
|
142
|
+
return a;
|
|
143
143
|
r.set(t, u);
|
|
144
144
|
for (var i in t)
|
|
145
145
|
Object.prototype.hasOwnProperty.call(t, i) && (u[i] = t[i]);
|
|
146
146
|
return u;
|
|
147
147
|
};
|
|
148
|
-
switch (
|
|
148
|
+
switch (U(t)) {
|
|
149
149
|
case "Object":
|
|
150
150
|
return n(Object.create(Object.getPrototypeOf(t)));
|
|
151
151
|
case "Array":
|
|
@@ -179,8 +179,8 @@ var he = /* @__PURE__ */ function() {
|
|
|
179
179
|
this.map = {}, this.length = 0;
|
|
180
180
|
}
|
|
181
181
|
return t.prototype.set = function(e, r) {
|
|
182
|
-
var n = this.hash(e),
|
|
183
|
-
|
|
182
|
+
var n = this.hash(e), s = this.map[n];
|
|
183
|
+
s || (this.map[n] = s = []), s.push([e, r]), this.length += 1;
|
|
184
184
|
}, t.prototype.hash = function(e) {
|
|
185
185
|
var r = [];
|
|
186
186
|
for (var n in e)
|
|
@@ -189,19 +189,19 @@ var he = /* @__PURE__ */ function() {
|
|
|
189
189
|
}, t.prototype.get = function(e) {
|
|
190
190
|
if (this.length <= 180) {
|
|
191
191
|
for (var r in this.map)
|
|
192
|
-
for (var
|
|
193
|
-
var
|
|
194
|
-
if (
|
|
195
|
-
return
|
|
192
|
+
for (var a = this.map[r], n = 0; n < a.length; n += 1) {
|
|
193
|
+
var s = a[n];
|
|
194
|
+
if (s[0] === e)
|
|
195
|
+
return s[1];
|
|
196
196
|
}
|
|
197
197
|
return;
|
|
198
198
|
}
|
|
199
|
-
var u = this.hash(e),
|
|
200
|
-
if (
|
|
201
|
-
for (var n = 0; n <
|
|
202
|
-
var
|
|
203
|
-
if (
|
|
204
|
-
return
|
|
199
|
+
var u = this.hash(e), a = this.map[u];
|
|
200
|
+
if (a)
|
|
201
|
+
for (var n = 0; n < a.length; n += 1) {
|
|
202
|
+
var s = a[n];
|
|
203
|
+
if (s[0] === e)
|
|
204
|
+
return s[1];
|
|
205
205
|
}
|
|
206
206
|
}, t;
|
|
207
207
|
}();
|
|
@@ -238,10 +238,10 @@ function L() {
|
|
|
238
238
|
var ge = /* @__PURE__ */ f(function(e) {
|
|
239
239
|
return T(e.length, e);
|
|
240
240
|
}), Te = /* @__PURE__ */ function() {
|
|
241
|
-
function t(e, r, n,
|
|
242
|
-
this.valueFn = e, this.valueAcc = r, this.keyFn = n, this.xf =
|
|
241
|
+
function t(e, r, n, s) {
|
|
242
|
+
this.valueFn = e, this.valueAcc = r, this.keyFn = n, this.xf = s, this.inputs = {};
|
|
243
243
|
}
|
|
244
|
-
return t.prototype["@@transducer/init"] =
|
|
244
|
+
return t.prototype["@@transducer/init"] = G.init, t.prototype["@@transducer/result"] = function(e) {
|
|
245
245
|
var r;
|
|
246
246
|
for (r in this.inputs)
|
|
247
247
|
if (N(r, this.inputs) && (e = this.xf["@@transducer/step"](e, this.inputs[r]), e["@@transducer/reduced"])) {
|
|
@@ -259,54 +259,54 @@ function Ne(t, e, r) {
|
|
|
259
259
|
return new Te(t, e, r, n);
|
|
260
260
|
};
|
|
261
261
|
}
|
|
262
|
-
var _e = /* @__PURE__ */ k(4, [], /* @__PURE__ */ H([], Ne, function(e, r, n,
|
|
263
|
-
var u =
|
|
264
|
-
var o = n(i), l = e(N(o,
|
|
265
|
-
return l && l["@@transducer/reduced"] ?
|
|
262
|
+
var _e = /* @__PURE__ */ k(4, [], /* @__PURE__ */ H([], Ne, function(e, r, n, s) {
|
|
263
|
+
var u = E(function(a, i) {
|
|
264
|
+
var o = n(i), l = e(N(o, a) ? a[o] : B(r), i);
|
|
265
|
+
return l && l["@@transducer/reduced"] ? X(a) : (a[o] = l, a);
|
|
266
266
|
});
|
|
267
|
-
return
|
|
267
|
+
return x(u, {}, s);
|
|
268
268
|
})), Se = /* @__PURE__ */ c(function(e, r, n) {
|
|
269
|
-
var
|
|
270
|
-
return
|
|
269
|
+
var s = e(r), u = e(n);
|
|
270
|
+
return s > u ? -1 : s < u ? 1 : 0;
|
|
271
271
|
}), Ae = /* @__PURE__ */ p(/* @__PURE__ */ _("groupBy", /* @__PURE__ */ _e(function(t, e) {
|
|
272
272
|
return t.push(e), t;
|
|
273
273
|
}, []))), De = /* @__PURE__ */ c(function(e, r, n) {
|
|
274
274
|
return T(Math.max(e.length, r.length, n.length), function() {
|
|
275
275
|
return e.apply(this, arguments) ? r.apply(this, arguments) : n.apply(this, arguments);
|
|
276
276
|
});
|
|
277
|
-
}), Ie = /* @__PURE__ */ p(
|
|
277
|
+
}), Ie = /* @__PURE__ */ p(q), be = /* @__PURE__ */ p(function(e, r) {
|
|
278
278
|
return function(n) {
|
|
279
|
-
return function(
|
|
279
|
+
return function(s) {
|
|
280
280
|
return v(function(u) {
|
|
281
|
-
return r(u,
|
|
282
|
-
}, n(e(
|
|
281
|
+
return r(u, s);
|
|
282
|
+
}, n(e(s)));
|
|
283
283
|
};
|
|
284
284
|
};
|
|
285
285
|
}), Re = /* @__PURE__ */ f(function(e) {
|
|
286
286
|
return be(h(e), le(e));
|
|
287
|
-
}),
|
|
287
|
+
}), P = function(t) {
|
|
288
288
|
return {
|
|
289
289
|
value: t,
|
|
290
290
|
map: function(e) {
|
|
291
|
-
return
|
|
291
|
+
return P(e(t));
|
|
292
292
|
}
|
|
293
293
|
};
|
|
294
294
|
}, Oe = /* @__PURE__ */ c(function(e, r, n) {
|
|
295
|
-
return e(function(
|
|
296
|
-
return
|
|
295
|
+
return e(function(s) {
|
|
296
|
+
return P(r(s));
|
|
297
297
|
})(n).value;
|
|
298
298
|
}), Me = /* @__PURE__ */ c(function(e, r, n) {
|
|
299
299
|
return n.replace(e, r);
|
|
300
300
|
}), Ce = /* @__PURE__ */ p(function(e, r) {
|
|
301
301
|
return Array.prototype.slice.call(r, 0).sort(e);
|
|
302
|
-
}),
|
|
303
|
-
return Array.prototype.slice.call(r, 0).sort(function(n,
|
|
304
|
-
for (var u = 0,
|
|
305
|
-
u = e[
|
|
302
|
+
}), W = /* @__PURE__ */ p(function(e, r) {
|
|
303
|
+
return Array.prototype.slice.call(r, 0).sort(function(n, s) {
|
|
304
|
+
for (var u = 0, a = 0; u === 0 && a < e.length; )
|
|
305
|
+
u = e[a](n, s), a += 1;
|
|
306
306
|
return u;
|
|
307
307
|
});
|
|
308
308
|
}), b = /* @__PURE__ */ K(0, "toLowerCase");
|
|
309
|
-
const
|
|
309
|
+
const je = (t, e = "body") => {
|
|
310
310
|
if (!t)
|
|
311
311
|
return;
|
|
312
312
|
if (typeof e != "string") {
|
|
@@ -318,17 +318,17 @@ const We = (t, e = "body") => {
|
|
|
318
318
|
};
|
|
319
319
|
class Fe extends Error {
|
|
320
320
|
constructor(e, r = {}) {
|
|
321
|
-
const { key: n, cause:
|
|
322
|
-
super(e), this.name = "WidgetError", this.key = n, this.cause =
|
|
321
|
+
const { key: n, cause: s } = r;
|
|
322
|
+
super(e), this.name = "WidgetError", this.key = n, this.cause = s;
|
|
323
323
|
}
|
|
324
324
|
}
|
|
325
|
-
const
|
|
325
|
+
const Ue = {
|
|
326
326
|
message: "Undefined Column name Message",
|
|
327
327
|
options: {
|
|
328
328
|
key: "undefined-column",
|
|
329
329
|
cause: {}
|
|
330
330
|
}
|
|
331
|
-
},
|
|
331
|
+
}, Ge = {
|
|
332
332
|
message: "Invalid season name",
|
|
333
333
|
options: {
|
|
334
334
|
key: "invalid-season-name",
|
|
@@ -341,31 +341,31 @@ const Ge = {
|
|
|
341
341
|
value() {
|
|
342
342
|
return {
|
|
343
343
|
rows: this.result,
|
|
344
|
-
totalItems: this.filteredRowsLength,
|
|
345
|
-
|
|
344
|
+
totalItems: this.isFiltered ? this.filteredRowsLength : t.length,
|
|
345
|
+
currentItems: this.currentItems
|
|
346
346
|
};
|
|
347
347
|
},
|
|
348
348
|
filter(e, r = [], n = !1) {
|
|
349
349
|
if (e) {
|
|
350
|
-
const
|
|
350
|
+
const s = r.map(
|
|
351
351
|
(i) => n ? d(Y(i), A(e)) : d(h(i), b, Ie(b(e)))
|
|
352
|
-
), u = ge((i) => i.name ? Oe(Re("name"), Me(",", ""), i) : i),
|
|
353
|
-
this.isFiltered = !0, this.filteredRowsLength =
|
|
352
|
+
), u = ge((i) => i.name ? Oe(Re("name"), Me(",", ""), i) : i), a = J(d(u, ue([...s])), this.result);
|
|
353
|
+
this.isFiltered = !0, this.filteredRowsLength = a.length, this.result = a;
|
|
354
354
|
}
|
|
355
355
|
return this;
|
|
356
356
|
},
|
|
357
357
|
sorted(e) {
|
|
358
358
|
if (!e.sortTarget)
|
|
359
359
|
return this;
|
|
360
|
-
if (e.orders[0].direction ===
|
|
360
|
+
if (e.orders[0].direction === j)
|
|
361
361
|
return this;
|
|
362
362
|
const r = De(A(F), I(y), I(Se));
|
|
363
|
-
return this.result =
|
|
363
|
+
return this.result = W(e.orders.map((n) => L(r(n.direction), h)(n.target)))(this.result), this;
|
|
364
364
|
},
|
|
365
365
|
addIndex(e = null) {
|
|
366
|
-
return this.result.reduce((r, n,
|
|
367
|
-
const u = r[r.length - 1] || [],
|
|
368
|
-
return n.index =
|
|
366
|
+
return this.result.reduce((r, n, s) => {
|
|
367
|
+
const u = r[r.length - 1] || [], a = e && u[e] === n[e];
|
|
368
|
+
return n.index = a ? u.index : s + 1, n.indexClass = a ? "is-duplicated" : null, r.push(n), r;
|
|
369
369
|
}, []), this;
|
|
370
370
|
},
|
|
371
371
|
addContinuousIndex() {
|
|
@@ -378,8 +378,11 @@ const Ge = {
|
|
|
378
378
|
if (!r)
|
|
379
379
|
return this;
|
|
380
380
|
e = Number(e), r = Number(r);
|
|
381
|
-
const n = (e - 1) * r,
|
|
382
|
-
return this.result = this.result.slice(n,
|
|
381
|
+
const n = (e - 1) * r, s = n + r;
|
|
382
|
+
return this.result = this.result.slice(n, s), this;
|
|
383
|
+
},
|
|
384
|
+
more(e, r) {
|
|
385
|
+
return this.result = this.result.slice(Number(e), Number(r)), this;
|
|
383
386
|
},
|
|
384
387
|
playerName() {
|
|
385
388
|
return this.result = this.result.map((e) => ({
|
|
@@ -408,9 +411,9 @@ const Ge = {
|
|
|
408
411
|
return this.result = this.result.map((r) => (e.map((n) => r[n] ? r[`${n}Sec`] = C(r[n]) : r), r)), this;
|
|
409
412
|
},
|
|
410
413
|
groupByDays() {
|
|
411
|
-
return this.result = Ae((e) => m(e.gameDate, "YYYY-MM-DD"))(this.result), this;
|
|
414
|
+
return this.currentItems = this.result.length, this.result = Ae((e) => m(e.gameDate, "YYYY-MM-DD"))(this.result), this;
|
|
412
415
|
}
|
|
413
|
-
}), He = (t, ...e) => v(L(...e))(t),
|
|
416
|
+
}), He = (t, ...e) => v(L(...e))(t), Xe = (t) => {
|
|
414
417
|
var e, r, n;
|
|
415
418
|
return {
|
|
416
419
|
...t,
|
|
@@ -420,7 +423,7 @@ const Ge = {
|
|
|
420
423
|
name: (n = t.player) != null && n.nationality.includes("hu") ? `${t.player.lastName} ${t.player.firstName}` : `${t.player.lastName}, ${t.player.firstName}`
|
|
421
424
|
}
|
|
422
425
|
};
|
|
423
|
-
},
|
|
426
|
+
}, qe = (t) => {
|
|
424
427
|
var e;
|
|
425
428
|
return {
|
|
426
429
|
...t,
|
|
@@ -448,7 +451,13 @@ const Ge = {
|
|
|
448
451
|
...e,
|
|
449
452
|
[t]: (r = e[t]) == null ? void 0 : r.toUpperCase()
|
|
450
453
|
};
|
|
451
|
-
}, ze = (t = []) => (e) => (t.map((r) => e[r] ? e[`${r}Sec`] = C(e[r]) : e), e), we = (t = []) => (e) => (t.map((r) => e[r] ? e[`${r}Min`] = Q(e[r]) : e), e), et = (t = []) => (e) => (t.map((r) => e[`${r}Min`] = V(e[r])), e),
|
|
454
|
+
}, ze = (t = []) => (e) => (t.map((r) => e[r] ? e[`${r}Sec`] = C(e[r]) : e), e), we = (t = []) => (e) => (t.map((r) => e[r] ? e[`${r}Min`] = Q(e[r]) : e), e), et = (t = []) => (e) => (t.map((r) => e[`${r}Min`] = V(e[r])), e), tt = (t) => {
|
|
455
|
+
var e, r;
|
|
456
|
+
return {
|
|
457
|
+
...t,
|
|
458
|
+
periodResults: ((r = (e = t.result) == null ? void 0 : e.match(/\(.*?\)/)) == null ? void 0 : r[0]) ?? ""
|
|
459
|
+
};
|
|
460
|
+
}, xe = (t, e) => new Date(t.gameDate).getTime() - new Date(e.gameDate).getTime(), rt = W([xe, y(h("id")), y(h("gameId"))]), Ee = (t) => (e, r) => e[t].localeCompare(r[t], "hu"), nt = Ce(Ee("name"));
|
|
452
461
|
function $e(t) {
|
|
453
462
|
var e;
|
|
454
463
|
return [t.isHomeGame ? null : "@", (e = t.opponent) == null ? void 0 : e.shortName].join(" ");
|
|
@@ -461,7 +470,7 @@ function Le(t) {
|
|
|
461
470
|
const e = t.gameResult.split(":"), r = e[0] > e[1], n = e[0] < e[1];
|
|
462
471
|
return r && t.isOvertime ? "OTW" : r && t.isShootout ? "SOW" : r ? "W" : n && t.isOvertime ? "OTL" : n && t.isShootout ? "SOL" : n ? "L" : "D";
|
|
463
472
|
}
|
|
464
|
-
const
|
|
473
|
+
const st = (t) => t.map((e) => {
|
|
465
474
|
var r, n;
|
|
466
475
|
return {
|
|
467
476
|
phaseId: e.phaseId,
|
|
@@ -475,8 +484,8 @@ const nt = (t) => t.map((e) => {
|
|
|
475
484
|
};
|
|
476
485
|
});
|
|
477
486
|
export {
|
|
478
|
-
|
|
479
|
-
|
|
487
|
+
Ge as I,
|
|
488
|
+
Ue as U,
|
|
480
489
|
Fe as W,
|
|
481
490
|
Ye as a,
|
|
482
491
|
Je as b,
|
|
@@ -487,12 +496,13 @@ export {
|
|
|
487
496
|
Ke as g,
|
|
488
497
|
et as h,
|
|
489
498
|
tt as i,
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
499
|
+
rt as j,
|
|
500
|
+
st as k,
|
|
501
|
+
nt as l,
|
|
502
|
+
je as m,
|
|
503
|
+
Xe as p,
|
|
494
504
|
He as r,
|
|
495
505
|
Ve as s,
|
|
496
|
-
|
|
506
|
+
qe as t,
|
|
497
507
|
Ze as u
|
|
498
508
|
};
|