fansunited-frontend-components 0.0.95 → 0.0.96
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/Betslip.d.ts +1 -2
- package/Betslip.d.ts.map +1 -1
- package/Betslip.js +4 -3
- package/ChanceGame.js +165 -163
- package/ChanceGameComponent.d.ts +1 -1
- package/ChanceGameComponent.d.ts.map +1 -1
- package/ClassicQuizPlay.d.ts +1 -1
- package/ClassicQuizPlay.d.ts.map +1 -1
- package/ClassicQuizPlay.js +4 -3
- package/CollectLead.d.ts +1 -1
- package/CollectLead.d.ts.map +1 -1
- package/CollectLead.js +37 -36
- package/CompetitionStatistics.d.ts +1 -2
- package/CompetitionStatistics.d.ts.map +1 -1
- package/CompetitionStatistics.js +458 -451
- package/CompetitorCard.d.ts +1 -2
- package/CompetitorCard.d.ts.map +1 -1
- package/CompetitorCard.js +1235 -1226
- package/Discussion.d.ts +1 -1
- package/Discussion.d.ts.map +1 -1
- package/Discussion.js +4 -3
- package/EitherOrPlay.d.ts +1 -1
- package/EitherOrPlay.d.ts.map +1 -1
- package/EitherOrPlay.js +4 -3
- package/EventCard.d.ts +1 -2
- package/EventCard.d.ts.map +1 -1
- package/EventCard.js +1249 -1244
- package/EventGamePlay.d.ts +1 -1
- package/EventGamePlay.d.ts.map +1 -1
- package/EventGamePlay.js +4 -3
- package/Leaderboard.d.ts +1 -1
- package/Leaderboard.d.ts.map +1 -1
- package/Leaderboard.js +482 -449
- package/List.d.ts +1 -2
- package/List.d.ts.map +1 -1
- package/List.js +258 -254
- package/MatchQuizPlay.d.ts +1 -1
- package/MatchQuizPlay.d.ts.map +1 -1
- package/MatchQuizPlay.js +4 -3
- package/Odds.d.ts +1 -2
- package/Odds.d.ts.map +1 -1
- package/Odds.js +35 -34
- package/PersonalityQuizPlay.d.ts +1 -1
- package/PersonalityQuizPlay.d.ts.map +1 -1
- package/PersonalityQuizPlay.js +4 -3
- package/PickThePair.js +102 -100
- package/PickThePairComponent.d.ts +1 -1
- package/PickThePairComponent.d.ts.map +1 -1
- package/PlayerOfTheMatch.d.ts +1 -2
- package/PlayerOfTheMatch.d.ts.map +1 -1
- package/PlayerOfTheMatch.js +1096 -1085
- package/PollVote.d.ts +1 -1
- package/PollVote.d.ts.map +1 -1
- package/PollVote.js +4 -3
- package/Predictor.d.ts +1 -2
- package/Predictor.d.ts.map +1 -1
- package/Predictor.js +4553 -4525
- package/README.md +1 -1
- package/Standings.d.ts +1 -2
- package/Standings.d.ts.map +1 -1
- package/Standings.js +404 -394
- package/TopX.d.ts +1 -2
- package/TopX.d.ts.map +1 -1
- package/TopX.js +5296 -5286
- package/chunks/{ChanceGameEmbedVariant-C3NGwvTF.js → ChanceGameEmbedVariant-CVys-3Zh.js} +1 -1
- package/chunks/{OddsSkeleton-Bav8FHHN.js → OddsSkeleton-ClJE2xhR.js} +5 -5
- package/chunks/{OddsStrip-CviVfQI4.js → OddsStrip-BnSp5TXa.js} +3 -3
- package/chunks/{PickOneOfX-a6Dv0-rR.js → PickOneOfX-DaJtkbCw.js} +6 -6
- package/chunks/index-Aq5MbUB9.js +4 -0
- package/chunks/index-BBQm_8LD.js +4 -0
- package/chunks/index-BC_sWWgc.js +4 -0
- package/chunks/index-DXKDJ1Vp.js +4 -0
- package/chunks/index-DjT5NrbA.js +4 -0
- package/chunks/index-DvLRehH6.js +4 -0
- package/chunks/index-aIMaxR-p.js +4 -0
- package/chunks/{main-Dj4Manb5.js → main-52Wff7qC.js} +1763 -1757
- package/chunks/{main-dwV_55lz.js → main-65WcUqAl.js} +615 -615
- package/chunks/{main-gexg6lc-.js → main-B58mi9jx.js} +349 -334
- package/chunks/{main-Dys2_Jt2.js → main-BIdXUTZS.js} +842 -827
- package/chunks/{main-CFwRpvUi.js → main-DD-NEzC7.js} +818 -817
- package/chunks/{main-DjiQz1dv.js → main-DUnfJPzY.js} +311 -311
- package/chunks/{main-eAQMCxQ7.js → main-DpCBqqg_.js} +322 -321
- package/chunks/{main-D9tFZv2q.js → main-Drznt1ak.js} +283 -282
- package/chunks/withVersionStamp-B6nArAj4.js +16 -0
- package/index.d.ts.map +1 -1
- package/index.js +45 -50
- package/package.json +57 -49
- package/withVersionStamp.d.ts +4 -0
- package/withVersionStamp.d.ts.map +1 -0
- package/chunks/3dicons-bookmark-fav-dynamic-color-BkMV51tL.js +0 -4
- package/chunks/3dicons-crow-dynamic-color-BnvCj9i8.js +0 -4
- package/chunks/3dicons-fire-dynamic-color-rNRL0kAe.js +0 -4
- package/chunks/3dicons-flag-dynamic-color-BscQxNXn.js +0 -4
- package/chunks/3dicons-medal-dynamic-color-CsR036OL.js +0 -4
- package/chunks/3dicons-rocket-dynamic-color-EiHCJ2rb.js +0 -4
- package/chunks/3dicons-target-dynamic-color-ChQzHpwv.js +0 -4
- package/chunks/3dicons-thumb-down-dynamic-color-NQLnsNFt.js +0 -4
- package/chunks/index-B1d9q8fX.js +0 -4
- package/chunks/index-BP0pvFJ4.js +0 -4
- package/chunks/index-CHZyL_g_.js +0 -4
- package/chunks/index-CeCUdRmF.js +0 -4
- package/chunks/index-Ckyyw-I8.js +0 -4
- package/chunks/index-DGvCP5G8.js +0 -4
- package/chunks/index-yjMVOgwO.js +0 -4
package/Standings.js
CHANGED
|
@@ -1,16 +1,17 @@
|
|
|
1
1
|
import { jsxs as C, jsx as r, Fragment as _ } from "react/jsx-runtime";
|
|
2
|
-
import E, { useState as N, useEffect as ge, useMemo as G, useRef as
|
|
3
|
-
import { Box as
|
|
2
|
+
import E, { useState as N, useEffect as ge, useMemo as G, useRef as ve } from "react";
|
|
3
|
+
import { Box as S, Typography as L, Chip as Ee, Sheet as he, Table as Pe, Tabs as ye, TabList as xe, Tab as Se, TabPanel as be } from "@mui/joy";
|
|
4
4
|
import { useTranslation as Y } from "react-i18next";
|
|
5
|
-
import { hexToRgb as ee, extractSdkErrorMessage as
|
|
6
|
-
import { MatchFilters as de } from "fansunited-sdk-esm";
|
|
7
|
-
import
|
|
8
|
-
import { createPortal as
|
|
9
|
-
import { CacheProvider as
|
|
10
|
-
|
|
5
|
+
import { hexToRgb as ee, useDisableCache as Ce, extractSdkErrorMessage as Fe, useColors as D, useFontFamily as P, useSpacingScale as $, toIntlLocale as q, bidiIsolate as V, useCornerRadius as j, useConstantContext as Ke, ConstantsContext as Ae, useIsRtl as Oe, InlineSpinner as Ne, Spinner as ze, getLanguageDirection as Ie, initializeI18n as Me, applyDirectionToMount as $e, widgetCacheKey as Ue, createWidgetCache as We, ContainerProvider as Be, ThemeProvider as _e, ConstantsProvider as He } from "fansunited-frontend-core";
|
|
6
|
+
import { MatchFilters as de } from "fansunited-sdk-esm/models";
|
|
7
|
+
import Ge from "@mui/icons-material/EmojiEvents";
|
|
8
|
+
import { createPortal as we } from "react-dom";
|
|
9
|
+
import { CacheProvider as je } from "@emotion/react";
|
|
10
|
+
import { w as Ze } from "./chunks/withVersionStamp-B6nArAj4.js";
|
|
11
|
+
const Ve = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " ").trim().replace(
|
|
11
12
|
/\S+/g,
|
|
12
13
|
(n) => n.charAt(0).toUpperCase() + n.slice(1).toLowerCase()
|
|
13
|
-
),
|
|
14
|
+
), Ye = [
|
|
14
15
|
"championsLeague",
|
|
15
16
|
"championsLeagueQual",
|
|
16
17
|
"europaLeague",
|
|
@@ -28,10 +29,10 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
28
29
|
"championshipGroup",
|
|
29
30
|
"europaClGroup",
|
|
30
31
|
"relegationGroup"
|
|
31
|
-
], te = (e) => e.toLowerCase().replace(/[^a-z0-9]/g, ""),
|
|
32
|
+
], te = (e) => e.toLowerCase().replace(/[^a-z0-9]/g, ""), Qe = Ye.reduce(
|
|
32
33
|
(e, t) => (e[te(t)] = t, e),
|
|
33
34
|
{}
|
|
34
|
-
),
|
|
35
|
+
), ke = (e) => Qe[te(e)] ?? null, Xe = {
|
|
35
36
|
championsLeague: "primary",
|
|
36
37
|
championshipGroup: "primary",
|
|
37
38
|
playOffs: "primary",
|
|
@@ -49,43 +50,43 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
49
50
|
relegationPlayOffs: "warning",
|
|
50
51
|
relegationGroup: "warning",
|
|
51
52
|
relegation: "danger"
|
|
52
|
-
},
|
|
53
|
+
}, qe = {
|
|
53
54
|
primary: 0,
|
|
54
55
|
success: 1,
|
|
55
56
|
warning: 2,
|
|
56
57
|
danger: 3
|
|
57
|
-
},
|
|
58
|
+
}, Je = (e, t) => t === 0 ? e : `rgba(${ee(e)}, ${Math.max(0.25, 1 - t * 0.25)})`, et = (e, t) => {
|
|
58
59
|
const n = te(e);
|
|
59
60
|
return n.includes("relegation") ? n.includes("playoff") || n.includes("group") ? "warning" : "danger" : t ? "primary" : "success";
|
|
60
|
-
},
|
|
61
|
+
}, tt = (e, t, n) => {
|
|
61
62
|
const o = /* @__PURE__ */ new Map();
|
|
62
|
-
if (e.forEach((
|
|
63
|
-
if (!
|
|
64
|
-
const
|
|
65
|
-
|
|
63
|
+
if (e.forEach((d, u) => {
|
|
64
|
+
if (!d) return;
|
|
65
|
+
const p = o.get(d);
|
|
66
|
+
p ? p.push(u) : o.set(d, [u]);
|
|
66
67
|
}), !o.size) return [];
|
|
67
|
-
const a = (
|
|
68
|
-
const u = o.get(
|
|
69
|
-
return u.reduce((
|
|
68
|
+
const a = (d) => {
|
|
69
|
+
const u = o.get(d) ?? [];
|
|
70
|
+
return u.reduce((p, h) => p + h, 0) / u.length;
|
|
70
71
|
}, l = Array.from(o.keys()).sort(
|
|
71
|
-
(
|
|
72
|
-
),
|
|
73
|
-
const
|
|
74
|
-
return
|
|
75
|
-
}),
|
|
76
|
-
const
|
|
77
|
-
return
|
|
72
|
+
(d, u) => a(d) - a(u)
|
|
73
|
+
), c = l.map((d) => ke(d)), i = l.map((d, u) => {
|
|
74
|
+
const p = c[u];
|
|
75
|
+
return p ? Xe[p] : et(d, u === 0);
|
|
76
|
+
}), f = /* @__PURE__ */ new Map(), s = l.map((d, u) => {
|
|
77
|
+
const p = i[u], h = f.get(p) ?? 0;
|
|
78
|
+
return f.set(p, h + 1), Je(t[p], h);
|
|
78
79
|
});
|
|
79
|
-
return l.map((
|
|
80
|
-
const
|
|
80
|
+
return l.map((d, u) => {
|
|
81
|
+
const p = c[u], h = p ? n == null ? void 0 : n[p] : void 0;
|
|
81
82
|
return {
|
|
82
|
-
key:
|
|
83
|
-
color: h ??
|
|
84
|
-
label:
|
|
85
|
-
tierRank:
|
|
83
|
+
key: d,
|
|
84
|
+
color: h ?? s[u],
|
|
85
|
+
label: Ve(d),
|
|
86
|
+
tierRank: qe[i[u]]
|
|
86
87
|
};
|
|
87
|
-
}).sort((
|
|
88
|
-
},
|
|
88
|
+
}).sort((d, u) => d.tierRank - u.tierRank).map(({ key: d, color: u, label: p }) => ({ key: d, color: u, label: p }));
|
|
89
|
+
}, nt = (e, t) => {
|
|
89
90
|
var n;
|
|
90
91
|
if (!e) return [];
|
|
91
92
|
if (t) {
|
|
@@ -93,7 +94,7 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
93
94
|
return o && o.type === "standing" ? [o] : [];
|
|
94
95
|
}
|
|
95
96
|
return (e.stages ?? []).filter((o) => o.type === "standing");
|
|
96
|
-
},
|
|
97
|
+
}, Le = (e) => {
|
|
97
98
|
var t;
|
|
98
99
|
return ((t = e == null ? void 0 : e.find((n) => n.key === "LOGO")) == null ? void 0 : t.value) ?? null;
|
|
99
100
|
}, M = (e, t) => {
|
|
@@ -102,10 +103,10 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
102
103
|
return ((a = o.key) == null ? void 0 : a.toLowerCase()) === t;
|
|
103
104
|
});
|
|
104
105
|
return n && Number(n.value) || 0;
|
|
105
|
-
},
|
|
106
|
+
}, ot = (e, t) => e.some((n) => {
|
|
106
107
|
var o;
|
|
107
108
|
return ((o = n.key) == null ? void 0 : o.toLowerCase()) === t;
|
|
108
|
-
}),
|
|
109
|
+
}), rt = (e) => {
|
|
109
110
|
const t = M(e, "goals_for"), n = M(e, "goals_against"), o = M(e, "played"), a = M(e, "won");
|
|
110
111
|
return {
|
|
111
112
|
played: o,
|
|
@@ -119,189 +120,197 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
119
120
|
points: M(e, "points"),
|
|
120
121
|
winPercentage: o > 0 ? a / o : 0
|
|
121
122
|
};
|
|
122
|
-
},
|
|
123
|
+
}, at = (e, t) => t == null ? null : e === t ? "same" : e < t ? "up" : "down", st = (e, t) => {
|
|
123
124
|
var a;
|
|
124
125
|
const n = e.competitorModel, o = e.rank ?? 0;
|
|
125
126
|
return {
|
|
126
127
|
competitorId: e.competitorId,
|
|
127
128
|
rank: o,
|
|
128
129
|
lastRank: e.lastRank,
|
|
129
|
-
rankChange:
|
|
130
|
+
rankChange: at(o, e.lastRank),
|
|
130
131
|
teamName: (n == null ? void 0 : n.name) ?? t,
|
|
131
132
|
teamShortName: (n == null ? void 0 : n.shortName) ?? null,
|
|
132
|
-
logoUrl:
|
|
133
|
-
stats:
|
|
133
|
+
logoUrl: Le(n == null ? void 0 : n.assets),
|
|
134
|
+
stats: rt(e.stats ?? []),
|
|
134
135
|
zoneKey: ((a = e.rules) == null ? void 0 : a[0]) ?? null
|
|
135
136
|
};
|
|
136
|
-
},
|
|
137
|
+
}, lt = (e, t, n) => {
|
|
137
138
|
if (t == null && n == null) return e;
|
|
138
|
-
const o = e.map((
|
|
139
|
+
const o = e.map((f) => f.rank ?? 0);
|
|
139
140
|
if (!o.length) return e;
|
|
140
|
-
const a = Math.min(...o), l = Math.max(...o),
|
|
141
|
-
return e.filter((
|
|
142
|
-
const
|
|
143
|
-
return
|
|
141
|
+
const a = Math.min(...o), l = Math.max(...o), c = Math.max(t ?? a, a), i = Math.min(n ?? l, l);
|
|
142
|
+
return e.filter((f) => {
|
|
143
|
+
const s = f.rank ?? 0;
|
|
144
|
+
return s >= c && s <= i;
|
|
144
145
|
});
|
|
145
|
-
},
|
|
146
|
-
const
|
|
147
|
-
i.map((
|
|
146
|
+
}, it = (e, t, n, o, a, l) => {
|
|
147
|
+
const c = lt(e.standings ?? [], a, l), i = c.map((d) => st(d, o)), f = tt(
|
|
148
|
+
i.map((d) => d.zoneKey),
|
|
148
149
|
t,
|
|
149
150
|
n
|
|
150
|
-
),
|
|
151
|
-
(
|
|
151
|
+
), s = c.some(
|
|
152
|
+
(d) => ot(d.stats ?? [], "points")
|
|
152
153
|
);
|
|
153
|
-
return { id: e.id, name: e.name, rows: i, zones:
|
|
154
|
-
},
|
|
154
|
+
return { id: e.id, name: e.name, rows: i, zones: f, hasPoints: s };
|
|
155
|
+
}, ct = (e) => e ? {
|
|
155
156
|
name: e.name ?? null,
|
|
156
157
|
year: e.year ?? null,
|
|
157
158
|
startDate: e.startDate ?? null,
|
|
158
159
|
endDate: e.endDate ?? null
|
|
159
|
-
} : null,
|
|
160
|
-
var
|
|
161
|
-
const i = e.groups ?? [],
|
|
162
|
-
(
|
|
160
|
+
} : null, dt = (e, t, n, o, a, l, c) => {
|
|
161
|
+
var s;
|
|
162
|
+
const i = e.groups ?? [], f = a && a.length ? i.filter(
|
|
163
|
+
(d) => d.id !== null && a.includes(d.id)
|
|
163
164
|
) : i;
|
|
164
165
|
return {
|
|
165
166
|
id: e.id,
|
|
166
|
-
name: ((
|
|
167
|
+
name: ((s = e.stageNameModel) == null ? void 0 : s.name) ?? null,
|
|
167
168
|
startDate: e.startDate ?? null,
|
|
168
169
|
endDate: e.endDate ?? null,
|
|
169
|
-
groups:
|
|
170
|
-
(
|
|
171
|
-
|
|
170
|
+
groups: f.map(
|
|
171
|
+
(d) => it(
|
|
172
|
+
d,
|
|
172
173
|
t,
|
|
173
174
|
n,
|
|
174
175
|
o,
|
|
175
176
|
l,
|
|
176
|
-
|
|
177
|
+
c
|
|
177
178
|
)
|
|
178
179
|
)
|
|
179
180
|
};
|
|
180
|
-
},
|
|
181
|
-
const
|
|
182
|
-
(
|
|
183
|
-
|
|
181
|
+
}, ut = (e, t, n, o, a, l, c, i) => {
|
|
182
|
+
const s = nt(e.season, i).map(
|
|
183
|
+
(d) => dt(
|
|
184
|
+
d,
|
|
184
185
|
t,
|
|
185
186
|
n,
|
|
186
187
|
o,
|
|
187
188
|
a,
|
|
188
189
|
l,
|
|
189
|
-
|
|
190
|
+
c
|
|
190
191
|
)
|
|
191
192
|
);
|
|
192
193
|
return {
|
|
193
194
|
competitionId: e.id,
|
|
194
195
|
competitionName: e.name ?? e.shortName ?? e.id,
|
|
195
196
|
sport: e.sport ?? null,
|
|
196
|
-
logoUrl:
|
|
197
|
-
season:
|
|
198
|
-
stageFound:
|
|
199
|
-
stages:
|
|
197
|
+
logoUrl: Le(e.assets),
|
|
198
|
+
season: ct(e.season),
|
|
199
|
+
stageFound: s.length > 0,
|
|
200
|
+
stages: s
|
|
200
201
|
};
|
|
201
|
-
},
|
|
202
|
-
const [
|
|
202
|
+
}, mt = (e, t, n, o, a, l, c, i, f) => {
|
|
203
|
+
const [s, d] = N(null), [u, p] = N(!0), [h, b] = N(null), x = Ce();
|
|
203
204
|
return ge(() => {
|
|
204
205
|
if (!e || !t) return;
|
|
205
|
-
let
|
|
206
|
-
return
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
206
|
+
let m = !1;
|
|
207
|
+
return p(!0), b(null), t.sports.getCompetitionById(
|
|
208
|
+
e,
|
|
209
|
+
c ? { seasonId: c } : void 0,
|
|
210
|
+
x
|
|
211
|
+
).then((w) => {
|
|
212
|
+
m || d(w);
|
|
213
|
+
}).catch((w) => {
|
|
214
|
+
m || b(Fe(w, t));
|
|
210
215
|
}).finally(() => {
|
|
211
|
-
|
|
216
|
+
m || p(!1);
|
|
212
217
|
}), () => {
|
|
213
|
-
|
|
218
|
+
m = !0;
|
|
214
219
|
};
|
|
215
|
-
}, [e, t,
|
|
216
|
-
|
|
220
|
+
}, [e, t, c, x]), { data: G(() => s ? ut(
|
|
221
|
+
s,
|
|
217
222
|
n,
|
|
218
223
|
a,
|
|
219
224
|
o,
|
|
220
225
|
l,
|
|
221
226
|
i == null ? void 0 : i.startRank,
|
|
222
227
|
i == null ? void 0 : i.endRank,
|
|
223
|
-
|
|
228
|
+
f
|
|
224
229
|
) : null, [
|
|
225
|
-
|
|
230
|
+
s,
|
|
226
231
|
n,
|
|
227
232
|
a,
|
|
228
233
|
o,
|
|
229
234
|
l,
|
|
230
235
|
i == null ? void 0 : i.startRank,
|
|
231
236
|
i == null ? void 0 : i.endRank,
|
|
232
|
-
|
|
237
|
+
f
|
|
233
238
|
]), loading: u, error: h };
|
|
234
|
-
},
|
|
235
|
-
var
|
|
236
|
-
const n = e.homeTeam.id === t, o = e.scores, a = Number(((
|
|
239
|
+
}, pt = 50, ft = (e, t) => e > t ? "win" : e < t ? "loss" : "draw", gt = (e, t) => {
|
|
240
|
+
var f, s;
|
|
241
|
+
const n = e.homeTeam.id === t, o = e.scores, a = Number(((f = o == null ? void 0 : o.ftScore) == null ? void 0 : f.homeGoals) ?? 0), l = Number(((s = o == null ? void 0 : o.ftScore) == null ? void 0 : s.awayGoals) ?? 0), c = n ? a : l, i = n ? l : a;
|
|
237
242
|
return {
|
|
238
|
-
result:
|
|
243
|
+
result: ft(c, i),
|
|
239
244
|
isHome: n,
|
|
240
245
|
opponentId: n ? e.awayTeam.id : e.homeTeam.id,
|
|
241
|
-
teamScore:
|
|
246
|
+
teamScore: c,
|
|
242
247
|
opponentScore: i,
|
|
243
248
|
kickoffAt: e.kickoffAt
|
|
244
249
|
};
|
|
245
|
-
}, ue = 12,
|
|
250
|
+
}, ue = 12, ht = (e, t) => {
|
|
246
251
|
const n = new Date(e);
|
|
247
252
|
return n.setUTCHours(n.getUTCHours() + t), n.toISOString().replace(/\.\d{3}Z$/, "Z");
|
|
248
253
|
}, me = (e, t) => {
|
|
249
254
|
if (!e) return null;
|
|
250
255
|
const a = `${e.slice(0, 10)}T${t === "start" ? "00:00:00" : "23:59:59"}Z`;
|
|
251
|
-
return
|
|
256
|
+
return ht(
|
|
252
257
|
a,
|
|
253
258
|
t === "start" ? -ue : ue
|
|
254
259
|
);
|
|
255
|
-
},
|
|
260
|
+
}, yt = (e) => e.map(
|
|
256
261
|
(t) => `${t.stageId}:${t.teamIds.join(",")}:${t.fromDate ?? ""}:${t.toDate ?? ""}`
|
|
257
|
-
).join("|"),
|
|
258
|
-
var
|
|
259
|
-
const
|
|
262
|
+
).join("|"), xt = async (e, t, n, o) => {
|
|
263
|
+
var f, s;
|
|
264
|
+
const a = {
|
|
260
265
|
competitionIds: [n],
|
|
261
266
|
status: "finished",
|
|
262
267
|
sortField: "date",
|
|
263
268
|
sortOrder: "desc",
|
|
264
|
-
limit:
|
|
269
|
+
limit: pt,
|
|
265
270
|
fromDate: me(t.fromDate, "start"),
|
|
266
271
|
toDate: me(t.toDate, "end")
|
|
267
|
-
},
|
|
268
|
-
new de({ ...
|
|
269
|
-
|
|
270
|
-
|
|
272
|
+
}, l = await e.football.getMatches(
|
|
273
|
+
new de({ ...a, page: 1 }),
|
|
274
|
+
o
|
|
275
|
+
), c = [...l.data ?? []], i = ((s = (f = l.meta) == null ? void 0 : f.pagination) == null ? void 0 : s.numberOfPages) ?? 1;
|
|
276
|
+
return i > 1 && (await Promise.all(
|
|
271
277
|
Array.from(
|
|
272
|
-
{ length:
|
|
273
|
-
(
|
|
278
|
+
{ length: i - 1 },
|
|
279
|
+
(u, p) => e.football.getMatches(
|
|
280
|
+
new de({ ...a, page: p + 2 }),
|
|
281
|
+
o
|
|
282
|
+
).then((h) => h.data ?? []).catch(() => [])
|
|
274
283
|
)
|
|
275
|
-
)).forEach((
|
|
276
|
-
},
|
|
277
|
-
const [a, l] = N({}), [
|
|
284
|
+
)).forEach((u) => c.push(...u)), c;
|
|
285
|
+
}, St = (e, t, n, o) => {
|
|
286
|
+
const [a, l] = N({}), [c, i] = N(!1), f = Ce(), s = yt(t);
|
|
278
287
|
return ge(() => {
|
|
279
288
|
if (!o || !t.length) {
|
|
280
289
|
l({}), i(!1);
|
|
281
290
|
return;
|
|
282
291
|
}
|
|
283
|
-
let
|
|
292
|
+
let d = !1;
|
|
284
293
|
return i(!0), Promise.all(
|
|
285
294
|
t.map(
|
|
286
|
-
(
|
|
287
|
-
() => [
|
|
295
|
+
(u) => xt(e, u, n, f).then((p) => [u.stageId, u.teamIds, p]).catch(
|
|
296
|
+
() => [u.stageId, u.teamIds, []]
|
|
288
297
|
)
|
|
289
298
|
)
|
|
290
|
-
).then((
|
|
291
|
-
if (
|
|
292
|
-
const
|
|
293
|
-
|
|
294
|
-
const
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
(
|
|
298
|
-
).slice(0, 5).map((
|
|
299
|
-
}),
|
|
300
|
-
}), l(
|
|
299
|
+
).then((u) => {
|
|
300
|
+
if (d) return;
|
|
301
|
+
const p = {};
|
|
302
|
+
u.forEach(([h, b, x]) => {
|
|
303
|
+
const g = {};
|
|
304
|
+
b.forEach((m) => {
|
|
305
|
+
g[m] = x.filter(
|
|
306
|
+
(w) => w.homeTeam.id === m || w.awayTeam.id === m
|
|
307
|
+
).slice(0, 5).map((w) => gt(w, m));
|
|
308
|
+
}), p[h] = g;
|
|
309
|
+
}), l(p), i(!1);
|
|
301
310
|
}), () => {
|
|
302
|
-
|
|
311
|
+
d = !0;
|
|
303
312
|
};
|
|
304
|
-
}, [e,
|
|
313
|
+
}, [e, s, n, o, f]), { formByStageAndTeam: a, loading: c };
|
|
305
314
|
}, pe = (e, t) => {
|
|
306
315
|
if (!e) return null;
|
|
307
316
|
const n = new Date(e);
|
|
@@ -310,32 +319,32 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
310
319
|
month: "short",
|
|
311
320
|
year: "numeric"
|
|
312
321
|
});
|
|
313
|
-
},
|
|
322
|
+
}, bt = ({
|
|
314
323
|
title: e,
|
|
315
324
|
logoUrl: t,
|
|
316
325
|
season: n,
|
|
317
326
|
language: o
|
|
318
327
|
}) => {
|
|
319
|
-
const a = D(), l = P(),
|
|
328
|
+
const a = D(), l = P(), c = $(), i = pe((n == null ? void 0 : n.startDate) ?? null, o), f = pe((n == null ? void 0 : n.endDate) ?? null, o), s = i && f ? `${i} – ${f}` : null, d = (n == null ? void 0 : n.year) ?? (n == null ? void 0 : n.name) ?? null;
|
|
320
329
|
return /* @__PURE__ */ C(
|
|
321
|
-
|
|
330
|
+
S,
|
|
322
331
|
{
|
|
323
332
|
sx: {
|
|
324
333
|
display: "flex",
|
|
325
334
|
alignItems: "center",
|
|
326
|
-
gap:
|
|
335
|
+
gap: c.sm,
|
|
327
336
|
// Matches the group/stage tabs' and ZoneLegend's own padding so the header,
|
|
328
337
|
// the tab pills, and the legend all read as the same consistent band.
|
|
329
|
-
paddingLeft:
|
|
330
|
-
paddingRight:
|
|
331
|
-
paddingTop:
|
|
332
|
-
paddingBottom:
|
|
338
|
+
paddingLeft: c.md,
|
|
339
|
+
paddingRight: c.md,
|
|
340
|
+
paddingTop: c.sm,
|
|
341
|
+
paddingBottom: c.sm,
|
|
333
342
|
borderBottom: `1px solid ${a.outlineEnabledBorder}`,
|
|
334
343
|
backgroundColor: a.surface
|
|
335
344
|
},
|
|
336
345
|
children: [
|
|
337
346
|
t ? /* @__PURE__ */ r(
|
|
338
|
-
|
|
347
|
+
S,
|
|
339
348
|
{
|
|
340
349
|
component: "img",
|
|
341
350
|
src: t,
|
|
@@ -343,7 +352,7 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
343
352
|
sx: { width: 36, height: 36, objectFit: "contain", flexShrink: 0 }
|
|
344
353
|
}
|
|
345
354
|
) : /* @__PURE__ */ r(
|
|
346
|
-
|
|
355
|
+
S,
|
|
347
356
|
{
|
|
348
357
|
sx: {
|
|
349
358
|
width: 36,
|
|
@@ -357,26 +366,26 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
357
366
|
overflow: "hidden"
|
|
358
367
|
},
|
|
359
368
|
children: /* @__PURE__ */ r(
|
|
360
|
-
|
|
369
|
+
Ge,
|
|
361
370
|
{
|
|
362
371
|
sx: { fontSize: "1.25em", color: a.textSecondary }
|
|
363
372
|
}
|
|
364
373
|
)
|
|
365
374
|
}
|
|
366
375
|
),
|
|
367
|
-
/* @__PURE__ */ C(
|
|
376
|
+
/* @__PURE__ */ C(S, { sx: { minWidth: 0 }, children: [
|
|
368
377
|
/* @__PURE__ */ C(
|
|
369
|
-
|
|
378
|
+
S,
|
|
370
379
|
{
|
|
371
380
|
sx: {
|
|
372
381
|
display: "flex",
|
|
373
382
|
alignItems: "center",
|
|
374
|
-
gap:
|
|
383
|
+
gap: c.xs,
|
|
375
384
|
flexWrap: "wrap"
|
|
376
385
|
},
|
|
377
386
|
children: [
|
|
378
387
|
/* @__PURE__ */ r(
|
|
379
|
-
|
|
388
|
+
L,
|
|
380
389
|
{
|
|
381
390
|
sx: {
|
|
382
391
|
fontFamily: l.primary,
|
|
@@ -387,8 +396,8 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
387
396
|
children: e
|
|
388
397
|
}
|
|
389
398
|
),
|
|
390
|
-
|
|
391
|
-
|
|
399
|
+
d && /* @__PURE__ */ r(
|
|
400
|
+
Ee,
|
|
392
401
|
{
|
|
393
402
|
size: "sm",
|
|
394
403
|
sx: {
|
|
@@ -398,14 +407,14 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
398
407
|
color: a.palette.primary.plainColor,
|
|
399
408
|
backgroundColor: `rgba(${ee(a.palette.primary.plainColor)}, 0.08)`
|
|
400
409
|
},
|
|
401
|
-
children:
|
|
410
|
+
children: d
|
|
402
411
|
}
|
|
403
412
|
)
|
|
404
413
|
]
|
|
405
414
|
}
|
|
406
415
|
),
|
|
407
|
-
|
|
408
|
-
|
|
416
|
+
s && /* @__PURE__ */ r(
|
|
417
|
+
L,
|
|
409
418
|
{
|
|
410
419
|
sx: {
|
|
411
420
|
fontFamily: l.secondary,
|
|
@@ -413,7 +422,7 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
413
422
|
color: a.textSecondary,
|
|
414
423
|
marginTop: "2px"
|
|
415
424
|
},
|
|
416
|
-
children:
|
|
425
|
+
children: s
|
|
417
426
|
}
|
|
418
427
|
)
|
|
419
428
|
] })
|
|
@@ -461,7 +470,7 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
461
470
|
shortLabelKey: "standings.columns.form",
|
|
462
471
|
fullLabelKey: "standings.columns.form"
|
|
463
472
|
}
|
|
464
|
-
],
|
|
473
|
+
], Ct = [
|
|
465
474
|
{
|
|
466
475
|
key: "goalsFor",
|
|
467
476
|
shortLabelKey: "standings.columns.goalsForShort",
|
|
@@ -477,27 +486,27 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
477
486
|
shortLabelKey: "standings.columns.goalsDifferenceShort",
|
|
478
487
|
fullLabelKey: "standings.columns.goalsDifference"
|
|
479
488
|
}
|
|
480
|
-
],
|
|
489
|
+
], wt = [
|
|
481
490
|
...J.slice(0, 5),
|
|
482
|
-
...
|
|
491
|
+
...Ct,
|
|
483
492
|
...J.slice(5)
|
|
484
|
-
],
|
|
493
|
+
], kt = {
|
|
485
494
|
hockey: ["drawn", "form"],
|
|
486
495
|
// No ties, no goal-based scoring (points are the score itself, not a standings-only
|
|
487
496
|
// stat), and no match-event data yet — leaves just played/won/lost/points.
|
|
488
497
|
basketball: ["drawn", "form", "goals", "goalsFor", "goalsAgainst", "goalsDifference"]
|
|
489
|
-
},
|
|
498
|
+
}, Lt = (e, t, n = !0) => {
|
|
490
499
|
const o = new Set(
|
|
491
|
-
t ?
|
|
500
|
+
t ? kt[t.toLowerCase()] ?? [] : []
|
|
492
501
|
);
|
|
493
|
-
return o.add(n ? "winPercentage" : "points"), (!e || e.length === 0 ? J :
|
|
494
|
-
},
|
|
502
|
+
return o.add(n ? "winPercentage" : "points"), (!e || e.length === 0 ? J : wt.filter((l) => e.includes(l.key))).filter((l) => !o.has(l.key));
|
|
503
|
+
}, Rt = ({ rankChange: e }) => {
|
|
495
504
|
const t = D();
|
|
496
505
|
if (e === null || e === "same")
|
|
497
506
|
return /* @__PURE__ */ r(_, {});
|
|
498
507
|
const n = e === "up" ? "▲" : "▼", o = e === "up" ? t.palette.success.plainColor : t.palette.danger.plainColor;
|
|
499
508
|
return /* @__PURE__ */ r(
|
|
500
|
-
|
|
509
|
+
S,
|
|
501
510
|
{
|
|
502
511
|
component: "span",
|
|
503
512
|
sx: {
|
|
@@ -509,10 +518,10 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
509
518
|
children: n
|
|
510
519
|
}
|
|
511
520
|
);
|
|
512
|
-
},
|
|
513
|
-
const o = D(), a = P(), l = $(),
|
|
521
|
+
}, Dt = ({ row: e, highlighted: t, compact: n }) => {
|
|
522
|
+
const o = D(), a = P(), l = $(), c = n ? 22 : 28, i = (e.teamShortName ?? e.teamName).slice(0, 2).toUpperCase();
|
|
514
523
|
return /* @__PURE__ */ C(
|
|
515
|
-
|
|
524
|
+
S,
|
|
516
525
|
{
|
|
517
526
|
sx: {
|
|
518
527
|
display: "flex",
|
|
@@ -530,24 +539,24 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
530
539
|
},
|
|
531
540
|
children: [
|
|
532
541
|
e.logoUrl ? /* @__PURE__ */ r(
|
|
533
|
-
|
|
542
|
+
S,
|
|
534
543
|
{
|
|
535
544
|
component: "img",
|
|
536
545
|
src: e.logoUrl,
|
|
537
546
|
alt: e.teamName,
|
|
538
547
|
sx: {
|
|
539
|
-
width:
|
|
540
|
-
height:
|
|
548
|
+
width: c,
|
|
549
|
+
height: c,
|
|
541
550
|
objectFit: "contain",
|
|
542
551
|
flexShrink: 0
|
|
543
552
|
}
|
|
544
553
|
}
|
|
545
554
|
) : /* @__PURE__ */ r(
|
|
546
|
-
|
|
555
|
+
S,
|
|
547
556
|
{
|
|
548
557
|
sx: {
|
|
549
|
-
width:
|
|
550
|
-
height:
|
|
558
|
+
width: c,
|
|
559
|
+
height: c,
|
|
551
560
|
display: "flex",
|
|
552
561
|
alignItems: "center",
|
|
553
562
|
justifyContent: "center",
|
|
@@ -564,7 +573,7 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
564
573
|
}
|
|
565
574
|
),
|
|
566
575
|
/* @__PURE__ */ r(
|
|
567
|
-
|
|
576
|
+
L,
|
|
568
577
|
{
|
|
569
578
|
sx: {
|
|
570
579
|
fontFamily: a.primary,
|
|
@@ -582,10 +591,10 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
582
591
|
]
|
|
583
592
|
}
|
|
584
593
|
);
|
|
585
|
-
},
|
|
594
|
+
}, Tt = ({ stats: e }) => {
|
|
586
595
|
const t = D(), n = P(), o = e.goalsDifference > 0 ? t.palette.success.plainColor : e.goalsDifference < 0 ? t.palette.danger.plainColor : t.textSecondary, a = e.goalsDifference > 0 ? V(`+${e.goalsDifference}`) : V(e.goalsDifference);
|
|
587
596
|
return /* @__PURE__ */ C(
|
|
588
|
-
|
|
597
|
+
S,
|
|
589
598
|
{
|
|
590
599
|
sx: {
|
|
591
600
|
display: "flex",
|
|
@@ -596,7 +605,7 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
596
605
|
},
|
|
597
606
|
children: [
|
|
598
607
|
/* @__PURE__ */ C(
|
|
599
|
-
|
|
608
|
+
L,
|
|
600
609
|
{
|
|
601
610
|
sx: {
|
|
602
611
|
fontFamily: n.secondary,
|
|
@@ -611,7 +620,7 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
611
620
|
}
|
|
612
621
|
),
|
|
613
622
|
/* @__PURE__ */ r(
|
|
614
|
-
|
|
623
|
+
L,
|
|
615
624
|
{
|
|
616
625
|
sx: {
|
|
617
626
|
fontFamily: n.primary,
|
|
@@ -625,7 +634,7 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
625
634
|
]
|
|
626
635
|
}
|
|
627
636
|
);
|
|
628
|
-
}, fe = 200,
|
|
637
|
+
}, fe = 200, vt = (e, t) => {
|
|
629
638
|
const n = new Date(e);
|
|
630
639
|
if (Number.isNaN(n.getTime())) return "";
|
|
631
640
|
const o = n.toLocaleDateString(q(t), {
|
|
@@ -637,39 +646,39 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
637
646
|
minute: "2-digit"
|
|
638
647
|
});
|
|
639
648
|
return `${o} · ${a}`;
|
|
640
|
-
},
|
|
649
|
+
}, Et = ({
|
|
641
650
|
teamName: e,
|
|
642
651
|
teamLogoUrl: t,
|
|
643
652
|
matches: n,
|
|
644
653
|
loading: o
|
|
645
654
|
}) => {
|
|
646
|
-
const { t: a, i18n: l } = Y("common"),
|
|
655
|
+
const { t: a, i18n: l } = Y("common"), c = D(), i = P(), f = j(), { shadowRootElement: s } = Ke(Ae), d = Oe(), [u, p] = N(null), h = ve([]), b = [...n].reverse();
|
|
647
656
|
if (o)
|
|
648
|
-
return /* @__PURE__ */ r(
|
|
657
|
+
return /* @__PURE__ */ r(S, { sx: { display: "flex", justifyContent: "center" }, children: /* @__PURE__ */ r(Ne, {}) });
|
|
649
658
|
if (!b.length)
|
|
650
659
|
return /* @__PURE__ */ r(
|
|
651
|
-
|
|
660
|
+
L,
|
|
652
661
|
{
|
|
653
662
|
sx: {
|
|
654
663
|
fontFamily: i.secondary,
|
|
655
664
|
fontSize: "0.75em",
|
|
656
|
-
color:
|
|
665
|
+
color: c.textSecondary,
|
|
657
666
|
textAlign: "center"
|
|
658
667
|
},
|
|
659
668
|
children: a("standings.formNotAvailable")
|
|
660
669
|
}
|
|
661
670
|
);
|
|
662
|
-
const
|
|
671
|
+
const x = (T) => T === "win" ? c.palette.success.plainColor : T === "loss" ? c.palette.danger.plainColor : c.palette.neutral.plainColor, g = (T) => {
|
|
663
672
|
const y = h.current[T];
|
|
664
|
-
y &&
|
|
665
|
-
}, m = u ? b[u.index] : null,
|
|
673
|
+
y && p({ index: T, rect: y.getBoundingClientRect() });
|
|
674
|
+
}, m = u ? b[u.index] : null, w = u ? u.rect.left + u.rect.width / 2 : 0, R = typeof window < "u" ? Math.max(
|
|
666
675
|
fe / 2 + 8,
|
|
667
|
-
Math.min(
|
|
668
|
-
) :
|
|
676
|
+
Math.min(w, window.innerWidth - fe / 2 - 8)
|
|
677
|
+
) : w, k = d && typeof window < "u" ? window.innerWidth - R : R, F = u ? u.rect.top - 8 : 0, z = {
|
|
669
678
|
fontFamily: i.primary,
|
|
670
679
|
fontWeight: 600,
|
|
671
680
|
fontSize: "0.8125em",
|
|
672
|
-
color:
|
|
681
|
+
color: c.textPrimary,
|
|
673
682
|
whiteSpace: "nowrap"
|
|
674
683
|
}, I = {
|
|
675
684
|
width: 16,
|
|
@@ -678,13 +687,13 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
678
687
|
flexShrink: 0
|
|
679
688
|
};
|
|
680
689
|
return /* @__PURE__ */ C(
|
|
681
|
-
|
|
690
|
+
S,
|
|
682
691
|
{
|
|
683
692
|
sx: { display: "flex", gap: "3px", justifyContent: "center" },
|
|
684
|
-
onMouseLeave: () =>
|
|
693
|
+
onMouseLeave: () => p(null),
|
|
685
694
|
children: [
|
|
686
695
|
b.map((T, y) => /* @__PURE__ */ r(
|
|
687
|
-
|
|
696
|
+
S,
|
|
688
697
|
{
|
|
689
698
|
component: "span",
|
|
690
699
|
ref: (K) => {
|
|
@@ -693,26 +702,26 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
693
702
|
sx: { display: "inline-flex", cursor: "pointer" },
|
|
694
703
|
onMouseEnter: () => g(y),
|
|
695
704
|
children: /* @__PURE__ */ r(
|
|
696
|
-
|
|
705
|
+
S,
|
|
697
706
|
{
|
|
698
707
|
sx: {
|
|
699
708
|
width: 9,
|
|
700
709
|
height: 9,
|
|
701
710
|
borderRadius: "50%",
|
|
702
|
-
backgroundColor:
|
|
711
|
+
backgroundColor: x(T.result)
|
|
703
712
|
}
|
|
704
713
|
}
|
|
705
714
|
)
|
|
706
715
|
},
|
|
707
716
|
y
|
|
708
717
|
)),
|
|
709
|
-
u && m &&
|
|
718
|
+
u && m && we(
|
|
710
719
|
/* @__PURE__ */ r(
|
|
711
|
-
|
|
720
|
+
S,
|
|
712
721
|
{
|
|
713
722
|
sx: {
|
|
714
723
|
position: "fixed",
|
|
715
|
-
left: `${
|
|
724
|
+
left: `${k}px`,
|
|
716
725
|
top: `${F}px`,
|
|
717
726
|
transform: "translate(-50%, -100%)",
|
|
718
727
|
zIndex: 9999,
|
|
@@ -722,9 +731,9 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
722
731
|
gap: "4px",
|
|
723
732
|
padding: "8px 12px",
|
|
724
733
|
width: "max-content",
|
|
725
|
-
borderRadius:
|
|
726
|
-
backgroundColor:
|
|
727
|
-
border: `1px solid ${
|
|
734
|
+
borderRadius: f.sm,
|
|
735
|
+
backgroundColor: c.surface,
|
|
736
|
+
border: `1px solid ${c.outlineEnabledBorder}`,
|
|
728
737
|
boxShadow: "0 6px 20px rgba(0, 0, 0, 0.16)",
|
|
729
738
|
fontSize: "1em",
|
|
730
739
|
pointerEvents: "none"
|
|
@@ -733,28 +742,28 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
733
742
|
const T = m.isHome ? e : m.opponentName, y = m.isHome ? m.opponentName : e, K = m.isHome ? t : m.opponentLogoUrl, U = m.isHome ? m.opponentLogoUrl : t, H = m.isHome ? m.teamScore : m.opponentScore, Q = m.isHome ? m.opponentScore : m.teamScore;
|
|
734
743
|
return /* @__PURE__ */ C(_, { children: [
|
|
735
744
|
/* @__PURE__ */ r(
|
|
736
|
-
|
|
745
|
+
L,
|
|
737
746
|
{
|
|
738
747
|
sx: {
|
|
739
748
|
fontFamily: i.secondary,
|
|
740
749
|
fontSize: "0.6875em",
|
|
741
|
-
color:
|
|
750
|
+
color: c.textSecondary,
|
|
742
751
|
whiteSpace: "nowrap"
|
|
743
752
|
},
|
|
744
|
-
children:
|
|
753
|
+
children: vt(m.kickoffAt, l.language)
|
|
745
754
|
}
|
|
746
755
|
),
|
|
747
|
-
/* @__PURE__ */ C(
|
|
748
|
-
/* @__PURE__ */ r(
|
|
749
|
-
K && /* @__PURE__ */ r(
|
|
756
|
+
/* @__PURE__ */ C(S, { sx: { display: "flex", alignItems: "center", gap: "6px" }, children: [
|
|
757
|
+
/* @__PURE__ */ r(L, { sx: z, children: T }),
|
|
758
|
+
K && /* @__PURE__ */ r(S, { component: "img", src: K, sx: I }),
|
|
750
759
|
/* @__PURE__ */ C(
|
|
751
|
-
|
|
760
|
+
L,
|
|
752
761
|
{
|
|
753
762
|
sx: {
|
|
754
763
|
fontFamily: i.primary,
|
|
755
764
|
fontWeight: 700,
|
|
756
765
|
fontSize: "0.8125em",
|
|
757
|
-
color:
|
|
766
|
+
color: c.textPrimary,
|
|
758
767
|
whiteSpace: "nowrap"
|
|
759
768
|
},
|
|
760
769
|
children: [
|
|
@@ -764,33 +773,33 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
764
773
|
]
|
|
765
774
|
}
|
|
766
775
|
),
|
|
767
|
-
U && /* @__PURE__ */ r(
|
|
768
|
-
/* @__PURE__ */ r(
|
|
776
|
+
U && /* @__PURE__ */ r(S, { component: "img", src: U, sx: I }),
|
|
777
|
+
/* @__PURE__ */ r(L, { sx: z, children: y })
|
|
769
778
|
] })
|
|
770
779
|
] });
|
|
771
780
|
})()
|
|
772
781
|
}
|
|
773
782
|
),
|
|
774
|
-
|
|
783
|
+
s ?? document.body
|
|
775
784
|
)
|
|
776
785
|
]
|
|
777
786
|
}
|
|
778
787
|
);
|
|
779
|
-
},
|
|
788
|
+
}, Pt = ({
|
|
780
789
|
row: e,
|
|
781
790
|
zone: t,
|
|
782
791
|
columns: n,
|
|
783
792
|
showRankChange: o,
|
|
784
793
|
highlighted: a,
|
|
785
794
|
compact: l,
|
|
786
|
-
isLast:
|
|
795
|
+
isLast: c = !1,
|
|
787
796
|
form: i,
|
|
788
|
-
formLoading:
|
|
797
|
+
formLoading: f
|
|
789
798
|
}) => {
|
|
790
|
-
const
|
|
791
|
-
fontFamily:
|
|
799
|
+
const s = D(), d = P(), u = c ? "none" : `1px solid ${s.outlineEnabledBorder}`, p = {
|
|
800
|
+
fontFamily: d.secondary,
|
|
792
801
|
fontSize: l ? "0.6875em" : "0.75em",
|
|
793
|
-
color:
|
|
802
|
+
color: s.textBody,
|
|
794
803
|
textAlign: "center"
|
|
795
804
|
}, h = (m) => {
|
|
796
805
|
switch (m) {
|
|
@@ -814,16 +823,16 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
814
823
|
default:
|
|
815
824
|
return e.stats.points;
|
|
816
825
|
}
|
|
817
|
-
}, b = (m) => m.toFixed(3).replace(/^0(?=\.)/, ""),
|
|
826
|
+
}, b = (m) => m.toFixed(3).replace(/^0(?=\.)/, ""), x = (m) => m > 0 ? s.palette.success.plainColor : m < 0 ? s.palette.danger.plainColor : s.textSecondary, g = (m) => m > 0 ? V(`+${m}`) : V(m);
|
|
818
827
|
return /* @__PURE__ */ C(
|
|
819
828
|
"tr",
|
|
820
829
|
{
|
|
821
830
|
style: a ? {
|
|
822
|
-
backgroundColor: `rgba(${ee(
|
|
831
|
+
backgroundColor: `rgba(${ee(s.palette.primary.plainColor)}, 0.08)`
|
|
823
832
|
} : void 0,
|
|
824
833
|
children: [
|
|
825
834
|
/* @__PURE__ */ r("td", { style: { width: 4, padding: 0, borderBottom: u }, children: /* @__PURE__ */ r(
|
|
826
|
-
|
|
835
|
+
S,
|
|
827
836
|
{
|
|
828
837
|
sx: {
|
|
829
838
|
width: "4px",
|
|
@@ -834,7 +843,7 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
834
843
|
}
|
|
835
844
|
) }),
|
|
836
845
|
/* @__PURE__ */ r("td", { style: { padding: "10px 4px", textAlign: "center", borderBottom: u }, children: /* @__PURE__ */ C(
|
|
837
|
-
|
|
846
|
+
S,
|
|
838
847
|
{
|
|
839
848
|
sx: {
|
|
840
849
|
display: "inline-grid",
|
|
@@ -844,36 +853,36 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
844
853
|
},
|
|
845
854
|
children: [
|
|
846
855
|
/* @__PURE__ */ r(
|
|
847
|
-
|
|
856
|
+
L,
|
|
848
857
|
{
|
|
849
858
|
sx: {
|
|
850
|
-
fontFamily:
|
|
859
|
+
fontFamily: d.primary,
|
|
851
860
|
fontWeight: 700,
|
|
852
861
|
fontSize: l ? "0.6875em" : "0.8125em",
|
|
853
|
-
color:
|
|
862
|
+
color: s.textPrimary,
|
|
854
863
|
textAlign: "right"
|
|
855
864
|
},
|
|
856
865
|
children: e.rank
|
|
857
866
|
}
|
|
858
867
|
),
|
|
859
|
-
o && /* @__PURE__ */ r(
|
|
868
|
+
o && /* @__PURE__ */ r(Rt, { rankChange: e.rankChange })
|
|
860
869
|
]
|
|
861
870
|
}
|
|
862
871
|
) }),
|
|
863
|
-
/* @__PURE__ */ r("td", { style: { padding: "10px 6px", textAlign: "start", borderBottom: u }, children: /* @__PURE__ */ r(
|
|
872
|
+
/* @__PURE__ */ r("td", { style: { padding: "10px 6px", textAlign: "start", borderBottom: u }, children: /* @__PURE__ */ r(Dt, { row: e, highlighted: a, compact: l }) }),
|
|
864
873
|
n.map((m) => {
|
|
865
874
|
if (m.key === "goals")
|
|
866
|
-
return /* @__PURE__ */ r("td", { style: { padding: "8px 6px", borderBottom: u }, children: /* @__PURE__ */ r(
|
|
875
|
+
return /* @__PURE__ */ r("td", { style: { padding: "8px 6px", borderBottom: u }, children: /* @__PURE__ */ r(Tt, { stats: e.stats }) }, m.key);
|
|
867
876
|
if (m.key === "goalsDifference") {
|
|
868
877
|
const R = e.stats.goalsDifference;
|
|
869
878
|
return /* @__PURE__ */ r("td", { style: { padding: "10px 6px", borderBottom: u }, children: /* @__PURE__ */ r(
|
|
870
|
-
|
|
879
|
+
L,
|
|
871
880
|
{
|
|
872
881
|
sx: {
|
|
873
|
-
fontFamily:
|
|
882
|
+
fontFamily: d.primary,
|
|
874
883
|
fontSize: l ? "0.6875em" : "0.75em",
|
|
875
884
|
fontWeight: 700,
|
|
876
|
-
color:
|
|
885
|
+
color: x(R),
|
|
877
886
|
textAlign: "center"
|
|
878
887
|
},
|
|
879
888
|
children: g(R)
|
|
@@ -882,25 +891,25 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
882
891
|
}
|
|
883
892
|
if (m.key === "form")
|
|
884
893
|
return /* @__PURE__ */ r("td", { style: { padding: "10px 6px", borderBottom: u }, children: /* @__PURE__ */ r(
|
|
885
|
-
|
|
894
|
+
Et,
|
|
886
895
|
{
|
|
887
896
|
teamName: e.teamName,
|
|
888
897
|
teamLogoUrl: e.logoUrl,
|
|
889
898
|
matches: i ?? [],
|
|
890
|
-
loading: !!
|
|
899
|
+
loading: !!f
|
|
891
900
|
}
|
|
892
901
|
) }, m.key);
|
|
893
|
-
const
|
|
902
|
+
const w = m.key === "points" || m.key === "winPercentage";
|
|
894
903
|
return /* @__PURE__ */ r("td", { style: { padding: "10px 6px", borderBottom: u }, children: /* @__PURE__ */ r(
|
|
895
|
-
|
|
904
|
+
L,
|
|
896
905
|
{
|
|
897
|
-
sx:
|
|
898
|
-
fontFamily:
|
|
906
|
+
sx: w ? {
|
|
907
|
+
fontFamily: d.primary,
|
|
899
908
|
fontWeight: 700,
|
|
900
909
|
fontSize: l ? "0.75em" : "0.875em",
|
|
901
|
-
color:
|
|
910
|
+
color: s.palette.primary.plainColor,
|
|
902
911
|
textAlign: "center"
|
|
903
|
-
} :
|
|
912
|
+
} : p,
|
|
904
913
|
children: m.key === "winPercentage" ? b(h(m.key)) : h(m.key)
|
|
905
914
|
}
|
|
906
915
|
) }, m.key);
|
|
@@ -908,7 +917,7 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
908
917
|
]
|
|
909
918
|
}
|
|
910
919
|
);
|
|
911
|
-
},
|
|
920
|
+
}, Ft = ({ colSpan: e }) => {
|
|
912
921
|
const t = D();
|
|
913
922
|
return /* @__PURE__ */ r("tr", { children: /* @__PURE__ */ r(
|
|
914
923
|
"td",
|
|
@@ -922,10 +931,10 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
922
931
|
}
|
|
923
932
|
}
|
|
924
933
|
) });
|
|
925
|
-
},
|
|
934
|
+
}, Re = ({ zones: e, zoneLabels: t }) => {
|
|
926
935
|
const { t: n } = Y("common"), o = D(), a = P(), l = $();
|
|
927
936
|
return e.length ? /* @__PURE__ */ r(
|
|
928
|
-
|
|
937
|
+
S,
|
|
929
938
|
{
|
|
930
939
|
sx: {
|
|
931
940
|
display: "flex",
|
|
@@ -936,39 +945,39 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
936
945
|
backgroundColor: o.surface,
|
|
937
946
|
fontSize: "1em"
|
|
938
947
|
},
|
|
939
|
-
children: e.map((
|
|
940
|
-
const i =
|
|
948
|
+
children: e.map((c) => {
|
|
949
|
+
const i = ke(c.key), s = (i ? t == null ? void 0 : t[i] : void 0) ?? (i ? n(`standings.rules.${i}`, c.label) : c.label);
|
|
941
950
|
return /* @__PURE__ */ C(
|
|
942
|
-
|
|
951
|
+
S,
|
|
943
952
|
{
|
|
944
953
|
sx: { display: "flex", alignItems: "center", gap: "6px" },
|
|
945
954
|
children: [
|
|
946
955
|
/* @__PURE__ */ r(
|
|
947
|
-
|
|
956
|
+
S,
|
|
948
957
|
{
|
|
949
958
|
sx: {
|
|
950
959
|
width: 9,
|
|
951
960
|
height: 9,
|
|
952
961
|
borderRadius: "50%",
|
|
953
962
|
flexShrink: 0,
|
|
954
|
-
backgroundColor:
|
|
963
|
+
backgroundColor: c.color
|
|
955
964
|
}
|
|
956
965
|
}
|
|
957
966
|
),
|
|
958
967
|
/* @__PURE__ */ r(
|
|
959
|
-
|
|
968
|
+
L,
|
|
960
969
|
{
|
|
961
970
|
sx: {
|
|
962
971
|
fontFamily: a.secondary,
|
|
963
972
|
fontSize: "0.6875em",
|
|
964
973
|
color: o.textSecondary
|
|
965
974
|
},
|
|
966
|
-
children:
|
|
975
|
+
children: s
|
|
967
976
|
}
|
|
968
977
|
)
|
|
969
978
|
]
|
|
970
979
|
},
|
|
971
|
-
|
|
980
|
+
c.key
|
|
972
981
|
);
|
|
973
982
|
})
|
|
974
983
|
}
|
|
@@ -980,22 +989,22 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
980
989
|
showLegend: o = !0,
|
|
981
990
|
highlightedCompetitorIds: a,
|
|
982
991
|
compact: l = !1,
|
|
983
|
-
groupLabel:
|
|
992
|
+
groupLabel: c,
|
|
984
993
|
zoneLabels: i,
|
|
985
|
-
formByTeamId:
|
|
986
|
-
formLoading:
|
|
987
|
-
sport:
|
|
994
|
+
formByTeamId: f,
|
|
995
|
+
formLoading: s,
|
|
996
|
+
sport: d
|
|
988
997
|
}) => {
|
|
989
|
-
const { t: u } = Y("common"),
|
|
998
|
+
const { t: u } = Y("common"), p = D(), h = P(), b = j(), x = Lt(t, d, e.hasPoints), g = new Map(e.zones.map((k) => [k.key, k])), m = 3 + x.length, w = {
|
|
990
999
|
backgroundColor: "transparent",
|
|
991
|
-
borderBottom: `1px solid ${
|
|
1000
|
+
borderBottom: `1px solid ${p.outlineEnabledBorder}`,
|
|
992
1001
|
padding: 0
|
|
993
|
-
}, R = (
|
|
1002
|
+
}, R = (k = "center") => ({
|
|
994
1003
|
display: "flex",
|
|
995
1004
|
alignItems: "center",
|
|
996
|
-
justifyContent:
|
|
1005
|
+
justifyContent: k === "left" ? "flex-start" : "center",
|
|
997
1006
|
padding: l ? "0.375em" : "0.625em 0.375em",
|
|
998
|
-
color:
|
|
1007
|
+
color: p.textSecondary,
|
|
999
1008
|
fontFamily: h.primary,
|
|
1000
1009
|
fontWeight: 600,
|
|
1001
1010
|
fontSize: "0.625em",
|
|
@@ -1009,14 +1018,14 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
1009
1018
|
variant: "outlined",
|
|
1010
1019
|
sx: {
|
|
1011
1020
|
fontSize: "1em",
|
|
1012
|
-
borderRadius:
|
|
1021
|
+
borderRadius: c ? b.md : `0 0 ${b.md} ${b.md}`,
|
|
1013
1022
|
overflow: "hidden",
|
|
1014
|
-
backgroundColor:
|
|
1015
|
-
borderColor:
|
|
1023
|
+
backgroundColor: p.surface,
|
|
1024
|
+
borderColor: p.outlineEnabledBorder
|
|
1016
1025
|
},
|
|
1017
1026
|
children: [
|
|
1018
|
-
/* @__PURE__ */ r(
|
|
1019
|
-
|
|
1027
|
+
/* @__PURE__ */ r(S, { sx: { overflowX: "auto" }, children: /* @__PURE__ */ C(
|
|
1028
|
+
Pe,
|
|
1020
1029
|
{
|
|
1021
1030
|
variant: "plain",
|
|
1022
1031
|
borderAxis: "none",
|
|
@@ -1036,13 +1045,13 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
1036
1045
|
},
|
|
1037
1046
|
children: [
|
|
1038
1047
|
/* @__PURE__ */ r("thead", { children: /* @__PURE__ */ C("tr", { children: [
|
|
1039
|
-
|
|
1048
|
+
c ? /* @__PURE__ */ r(
|
|
1040
1049
|
"th",
|
|
1041
1050
|
{
|
|
1042
1051
|
colSpan: 3,
|
|
1043
|
-
style: { ...
|
|
1052
|
+
style: { ...w, minWidth: l ? 90 : 160 },
|
|
1044
1053
|
children: /* @__PURE__ */ r(
|
|
1045
|
-
|
|
1054
|
+
S,
|
|
1046
1055
|
{
|
|
1047
1056
|
sx: {
|
|
1048
1057
|
...R("left"),
|
|
@@ -1050,16 +1059,16 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
1050
1059
|
letterSpacing: "normal",
|
|
1051
1060
|
fontSize: "0.6875em",
|
|
1052
1061
|
fontWeight: 700,
|
|
1053
|
-
color:
|
|
1062
|
+
color: p.textPrimary
|
|
1054
1063
|
},
|
|
1055
|
-
children:
|
|
1064
|
+
children: c
|
|
1056
1065
|
}
|
|
1057
1066
|
)
|
|
1058
1067
|
}
|
|
1059
1068
|
) : /* @__PURE__ */ C(_, { children: [
|
|
1060
|
-
/* @__PURE__ */ r("th", { style: { ...
|
|
1061
|
-
/* @__PURE__ */ r("th", { style:
|
|
1062
|
-
|
|
1069
|
+
/* @__PURE__ */ r("th", { style: { ...w, width: 4, padding: 0 } }),
|
|
1070
|
+
/* @__PURE__ */ r("th", { style: w, title: u("leaderboard.position"), children: /* @__PURE__ */ r(S, { sx: R(), children: /* @__PURE__ */ C(
|
|
1071
|
+
S,
|
|
1063
1072
|
{
|
|
1064
1073
|
sx: {
|
|
1065
1074
|
display: "inline-grid",
|
|
@@ -1072,62 +1081,62 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
1072
1081
|
]
|
|
1073
1082
|
}
|
|
1074
1083
|
) }) }),
|
|
1075
|
-
/* @__PURE__ */ r("th", { style: { ...
|
|
1084
|
+
/* @__PURE__ */ r("th", { style: { ...w, minWidth: l ? 90 : 160 }, children: /* @__PURE__ */ r(S, { sx: R("left"), children: u("standings.columns.team") }) })
|
|
1076
1085
|
] }),
|
|
1077
|
-
|
|
1086
|
+
x.map((k) => /* @__PURE__ */ r(
|
|
1078
1087
|
"th",
|
|
1079
1088
|
{
|
|
1080
|
-
style:
|
|
1081
|
-
title: u(
|
|
1082
|
-
children: /* @__PURE__ */ r(
|
|
1089
|
+
style: w,
|
|
1090
|
+
title: u(k.fullLabelKey),
|
|
1091
|
+
children: /* @__PURE__ */ r(S, { sx: R(), children: u(k.shortLabelKey) })
|
|
1083
1092
|
},
|
|
1084
|
-
|
|
1093
|
+
k.key
|
|
1085
1094
|
))
|
|
1086
1095
|
] }) }),
|
|
1087
|
-
/* @__PURE__ */ r("tbody", { children: e.rows.map((
|
|
1088
|
-
const z = F > 0 ? e.rows[F - 1].zoneKey : null, I = F > 0 && z !==
|
|
1096
|
+
/* @__PURE__ */ r("tbody", { children: e.rows.map((k, F) => {
|
|
1097
|
+
const z = F > 0 ? e.rows[F - 1].zoneKey : null, I = F > 0 && z !== k.zoneKey;
|
|
1089
1098
|
return /* @__PURE__ */ C(E.Fragment, { children: [
|
|
1090
|
-
I && /* @__PURE__ */ r(
|
|
1099
|
+
I && /* @__PURE__ */ r(Ft, { colSpan: m }),
|
|
1091
1100
|
/* @__PURE__ */ r(
|
|
1092
|
-
|
|
1101
|
+
Pt,
|
|
1093
1102
|
{
|
|
1094
|
-
row:
|
|
1095
|
-
zone:
|
|
1096
|
-
columns:
|
|
1103
|
+
row: k,
|
|
1104
|
+
zone: k.zoneKey ? g.get(k.zoneKey) : void 0,
|
|
1105
|
+
columns: x,
|
|
1097
1106
|
showRankChange: n,
|
|
1098
|
-
highlighted: !!(a != null && a.includes(
|
|
1107
|
+
highlighted: !!(a != null && a.includes(k.competitorId)),
|
|
1099
1108
|
compact: l,
|
|
1100
1109
|
isLast: F === e.rows.length - 1,
|
|
1101
|
-
form:
|
|
1102
|
-
formLoading:
|
|
1110
|
+
form: f == null ? void 0 : f[k.competitorId],
|
|
1111
|
+
formLoading: s
|
|
1103
1112
|
}
|
|
1104
1113
|
)
|
|
1105
|
-
] },
|
|
1114
|
+
] }, k.competitorId);
|
|
1106
1115
|
}) })
|
|
1107
1116
|
]
|
|
1108
1117
|
}
|
|
1109
1118
|
) }),
|
|
1110
|
-
o && /* @__PURE__ */ r(
|
|
1119
|
+
o && /* @__PURE__ */ r(Re, { zones: e.zones, zoneLabels: i })
|
|
1111
1120
|
]
|
|
1112
1121
|
}
|
|
1113
1122
|
);
|
|
1114
|
-
},
|
|
1123
|
+
}, Kt = ({
|
|
1115
1124
|
groups: e,
|
|
1116
1125
|
columns: t,
|
|
1117
1126
|
showRankChange: n,
|
|
1118
1127
|
showLegend: o,
|
|
1119
1128
|
highlightedCompetitorIds: a,
|
|
1120
1129
|
zoneLabels: l,
|
|
1121
|
-
formByTeamId:
|
|
1130
|
+
formByTeamId: c,
|
|
1122
1131
|
formLoading: i,
|
|
1123
|
-
sport:
|
|
1132
|
+
sport: f
|
|
1124
1133
|
}) => {
|
|
1125
|
-
const
|
|
1134
|
+
const s = D(), d = P(), u = j(), p = $(), [h, b] = N(0);
|
|
1126
1135
|
return /* @__PURE__ */ C(
|
|
1127
1136
|
ye,
|
|
1128
1137
|
{
|
|
1129
1138
|
value: h,
|
|
1130
|
-
onChange: (
|
|
1139
|
+
onChange: (x, g) => b(g),
|
|
1131
1140
|
sx: { fontSize: "1em", backgroundColor: "transparent" },
|
|
1132
1141
|
children: [
|
|
1133
1142
|
/* @__PURE__ */ r(
|
|
@@ -1143,20 +1152,20 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
1143
1152
|
gap: "0.25em",
|
|
1144
1153
|
// Matches SeasonHeader's and ZoneLegend's own padding so the header, the tab
|
|
1145
1154
|
// bar, and the legend all read as the same consistent band.
|
|
1146
|
-
paddingLeft:
|
|
1147
|
-
paddingRight:
|
|
1148
|
-
paddingTop:
|
|
1149
|
-
paddingBottom:
|
|
1155
|
+
paddingLeft: p.md,
|
|
1156
|
+
paddingRight: p.md,
|
|
1157
|
+
paddingTop: p.sm,
|
|
1158
|
+
paddingBottom: p.sm,
|
|
1150
1159
|
"--ListItem-radius": "0px"
|
|
1151
1160
|
},
|
|
1152
|
-
children: e.map((
|
|
1161
|
+
children: e.map((x, g) => /* @__PURE__ */ r(
|
|
1153
1162
|
Se,
|
|
1154
1163
|
{
|
|
1155
1164
|
variant: "plain",
|
|
1156
1165
|
color: "neutral",
|
|
1157
1166
|
disableIndicator: !0,
|
|
1158
1167
|
sx: {
|
|
1159
|
-
fontFamily:
|
|
1168
|
+
fontFamily: d.primary,
|
|
1160
1169
|
fontWeight: 700,
|
|
1161
1170
|
fontSize: "0.75em",
|
|
1162
1171
|
textTransform: "uppercase",
|
|
@@ -1172,25 +1181,25 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
1172
1181
|
lineHeight: 1,
|
|
1173
1182
|
minHeight: "auto",
|
|
1174
1183
|
minBlockSize: "auto",
|
|
1175
|
-
color: g === h ?
|
|
1184
|
+
color: g === h ? s.palette.primary.onPrimary : s.textSecondary,
|
|
1176
1185
|
// Joy's default selected/hover state fills the tab with its own soft
|
|
1177
1186
|
// background — override with higher specificity ("&&") so the active
|
|
1178
1187
|
// pill uses the primary colour solidly, matching the design.
|
|
1179
1188
|
"&&": {
|
|
1180
|
-
backgroundColor: g === h ?
|
|
1189
|
+
backgroundColor: g === h ? s.palette.primary.plainColor : "transparent"
|
|
1181
1190
|
},
|
|
1182
1191
|
"&&:hover": {
|
|
1183
|
-
backgroundColor: g === h ?
|
|
1184
|
-
color: g === h ?
|
|
1192
|
+
backgroundColor: g === h ? s.palette.primary.plainColor : s.surfaceVariant,
|
|
1193
|
+
color: g === h ? s.palette.primary.onPrimary : s.palette.primary.plainColor
|
|
1185
1194
|
}
|
|
1186
1195
|
},
|
|
1187
|
-
children:
|
|
1196
|
+
children: x.name ?? `#${g + 1}`
|
|
1188
1197
|
},
|
|
1189
|
-
|
|
1198
|
+
x.id ?? x.name ?? g
|
|
1190
1199
|
))
|
|
1191
1200
|
}
|
|
1192
1201
|
),
|
|
1193
|
-
e.map((
|
|
1202
|
+
e.map((x, g) => /* @__PURE__ */ r(
|
|
1194
1203
|
be,
|
|
1195
1204
|
{
|
|
1196
1205
|
value: g,
|
|
@@ -1198,29 +1207,29 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
1198
1207
|
children: /* @__PURE__ */ r(
|
|
1199
1208
|
ne,
|
|
1200
1209
|
{
|
|
1201
|
-
group:
|
|
1210
|
+
group: x,
|
|
1202
1211
|
columns: t,
|
|
1203
1212
|
showRankChange: n,
|
|
1204
1213
|
showLegend: o,
|
|
1205
1214
|
highlightedCompetitorIds: a,
|
|
1206
1215
|
zoneLabels: l,
|
|
1207
|
-
formByTeamId:
|
|
1216
|
+
formByTeamId: c,
|
|
1208
1217
|
formLoading: i,
|
|
1209
|
-
sport:
|
|
1218
|
+
sport: f
|
|
1210
1219
|
}
|
|
1211
1220
|
)
|
|
1212
1221
|
},
|
|
1213
|
-
|
|
1222
|
+
x.id ?? x.name ?? g
|
|
1214
1223
|
))
|
|
1215
1224
|
]
|
|
1216
1225
|
}
|
|
1217
1226
|
);
|
|
1218
|
-
},
|
|
1227
|
+
}, At = [
|
|
1219
1228
|
"won",
|
|
1220
1229
|
"drawn",
|
|
1221
1230
|
"lost",
|
|
1222
1231
|
"points"
|
|
1223
|
-
],
|
|
1232
|
+
], Ot = ({
|
|
1224
1233
|
group: e,
|
|
1225
1234
|
columns: t,
|
|
1226
1235
|
highlightedCompetitorIds: n,
|
|
@@ -1231,7 +1240,7 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
1231
1240
|
ne,
|
|
1232
1241
|
{
|
|
1233
1242
|
group: e,
|
|
1234
|
-
columns: t ??
|
|
1243
|
+
columns: t ?? At,
|
|
1235
1244
|
showLegend: !1,
|
|
1236
1245
|
highlightedCompetitorIds: n,
|
|
1237
1246
|
groupLabel: e.name ?? void 0,
|
|
@@ -1240,26 +1249,26 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
1240
1249
|
sport: l,
|
|
1241
1250
|
compact: !0
|
|
1242
1251
|
}
|
|
1243
|
-
),
|
|
1252
|
+
), Nt = (e) => {
|
|
1244
1253
|
const t = /* @__PURE__ */ new Set(), n = [];
|
|
1245
1254
|
return e.forEach((o) => {
|
|
1246
1255
|
o.zones.forEach((a) => {
|
|
1247
1256
|
t.has(a.key) || (t.add(a.key), n.push(a));
|
|
1248
1257
|
});
|
|
1249
1258
|
}), n;
|
|
1250
|
-
},
|
|
1259
|
+
}, De = ({
|
|
1251
1260
|
groups: e,
|
|
1252
1261
|
groupsView: t,
|
|
1253
1262
|
columns: n,
|
|
1254
1263
|
showRankChange: o,
|
|
1255
1264
|
showLegend: a,
|
|
1256
1265
|
highlightedCompetitorIds: l,
|
|
1257
|
-
zoneLabels:
|
|
1266
|
+
zoneLabels: c,
|
|
1258
1267
|
formByTeamId: i,
|
|
1259
|
-
formLoading:
|
|
1260
|
-
sport:
|
|
1268
|
+
formLoading: f,
|
|
1269
|
+
sport: s
|
|
1261
1270
|
}) => {
|
|
1262
|
-
const
|
|
1271
|
+
const d = $();
|
|
1263
1272
|
return e.length <= 1 ? /* @__PURE__ */ r(
|
|
1264
1273
|
ne,
|
|
1265
1274
|
{
|
|
@@ -1268,68 +1277,68 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
1268
1277
|
showRankChange: o,
|
|
1269
1278
|
showLegend: a,
|
|
1270
1279
|
highlightedCompetitorIds: l,
|
|
1271
|
-
zoneLabels:
|
|
1280
|
+
zoneLabels: c,
|
|
1272
1281
|
formByTeamId: i,
|
|
1273
|
-
formLoading:
|
|
1274
|
-
sport:
|
|
1282
|
+
formLoading: f,
|
|
1283
|
+
sport: s
|
|
1275
1284
|
}
|
|
1276
1285
|
) : t === "detailed" ? /* @__PURE__ */ r(
|
|
1277
|
-
|
|
1286
|
+
Kt,
|
|
1278
1287
|
{
|
|
1279
1288
|
groups: e,
|
|
1280
1289
|
columns: n,
|
|
1281
1290
|
showRankChange: o,
|
|
1282
1291
|
showLegend: a,
|
|
1283
1292
|
highlightedCompetitorIds: l,
|
|
1284
|
-
zoneLabels:
|
|
1293
|
+
zoneLabels: c,
|
|
1285
1294
|
formByTeamId: i,
|
|
1286
|
-
formLoading:
|
|
1287
|
-
sport:
|
|
1295
|
+
formLoading: f,
|
|
1296
|
+
sport: s
|
|
1288
1297
|
}
|
|
1289
1298
|
) : /* @__PURE__ */ C(_, { children: [
|
|
1290
1299
|
/* @__PURE__ */ r(
|
|
1291
|
-
|
|
1300
|
+
S,
|
|
1292
1301
|
{
|
|
1293
1302
|
sx: {
|
|
1294
1303
|
display: "grid",
|
|
1295
1304
|
gridTemplateColumns: "repeat(auto-fill, minmax(200px, 1fr))",
|
|
1296
|
-
gap:
|
|
1297
|
-
padding:
|
|
1305
|
+
gap: d.sm,
|
|
1306
|
+
padding: d.sm
|
|
1298
1307
|
},
|
|
1299
|
-
children: e.map((u,
|
|
1300
|
-
|
|
1308
|
+
children: e.map((u, p) => /* @__PURE__ */ r(
|
|
1309
|
+
Ot,
|
|
1301
1310
|
{
|
|
1302
1311
|
group: u,
|
|
1303
1312
|
columns: n,
|
|
1304
1313
|
highlightedCompetitorIds: l,
|
|
1305
1314
|
formByTeamId: i,
|
|
1306
|
-
formLoading:
|
|
1307
|
-
sport:
|
|
1315
|
+
formLoading: f,
|
|
1316
|
+
sport: s
|
|
1308
1317
|
},
|
|
1309
|
-
u.id ?? u.name ??
|
|
1318
|
+
u.id ?? u.name ?? p
|
|
1310
1319
|
))
|
|
1311
1320
|
}
|
|
1312
1321
|
),
|
|
1313
|
-
a && /* @__PURE__ */ r(
|
|
1322
|
+
a && /* @__PURE__ */ r(Re, { zones: Nt(e), zoneLabels: c })
|
|
1314
1323
|
] });
|
|
1315
|
-
},
|
|
1324
|
+
}, zt = ({
|
|
1316
1325
|
stages: e,
|
|
1317
1326
|
groupsView: t,
|
|
1318
1327
|
columns: n,
|
|
1319
1328
|
showRankChange: o,
|
|
1320
1329
|
showLegend: a,
|
|
1321
1330
|
highlightedCompetitorIds: l,
|
|
1322
|
-
zoneLabels:
|
|
1331
|
+
zoneLabels: c,
|
|
1323
1332
|
formByStageId: i,
|
|
1324
|
-
formLoading:
|
|
1325
|
-
sport:
|
|
1333
|
+
formLoading: f,
|
|
1334
|
+
sport: s
|
|
1326
1335
|
}) => {
|
|
1327
|
-
const
|
|
1336
|
+
const d = D(), u = P(), p = j(), h = $(), [b, x] = N(0);
|
|
1328
1337
|
return /* @__PURE__ */ C(
|
|
1329
1338
|
ye,
|
|
1330
1339
|
{
|
|
1331
1340
|
value: b,
|
|
1332
|
-
onChange: (g, m) =>
|
|
1341
|
+
onChange: (g, m) => x(m),
|
|
1333
1342
|
sx: { fontSize: "1em", backgroundColor: "transparent" },
|
|
1334
1343
|
children: [
|
|
1335
1344
|
/* @__PURE__ */ r(
|
|
@@ -1365,7 +1374,7 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
1365
1374
|
letterSpacing: "0.025em",
|
|
1366
1375
|
whiteSpace: "nowrap",
|
|
1367
1376
|
flex: "0 0 auto",
|
|
1368
|
-
borderRadius:
|
|
1377
|
+
borderRadius: p.full,
|
|
1369
1378
|
padding: "0.375em 0.75em",
|
|
1370
1379
|
// Joy's Tab/ListItemButton bases apply their own line-height and a
|
|
1371
1380
|
// --ListItem/--Tab minHeight that padding alone doesn't override —
|
|
@@ -1374,16 +1383,16 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
1374
1383
|
lineHeight: 1,
|
|
1375
1384
|
minHeight: "auto",
|
|
1376
1385
|
minBlockSize: "auto",
|
|
1377
|
-
color: m === b ?
|
|
1386
|
+
color: m === b ? d.palette.primary.onPrimary : d.textSecondary,
|
|
1378
1387
|
// Joy's default selected/hover state fills the tab with its own soft
|
|
1379
1388
|
// background — override with higher specificity ("&&") so the active
|
|
1380
1389
|
// pill uses the primary colour solidly, matching the design.
|
|
1381
1390
|
"&&": {
|
|
1382
|
-
backgroundColor: m === b ?
|
|
1391
|
+
backgroundColor: m === b ? d.palette.primary.plainColor : "transparent"
|
|
1383
1392
|
},
|
|
1384
1393
|
"&&:hover": {
|
|
1385
|
-
backgroundColor: m === b ?
|
|
1386
|
-
color: m === b ?
|
|
1394
|
+
backgroundColor: m === b ? d.palette.primary.plainColor : d.surfaceVariant,
|
|
1395
|
+
color: m === b ? d.palette.primary.onPrimary : d.palette.primary.plainColor
|
|
1387
1396
|
}
|
|
1388
1397
|
},
|
|
1389
1398
|
children: g.name ?? `#${m + 1}`
|
|
@@ -1398,7 +1407,7 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
1398
1407
|
value: m,
|
|
1399
1408
|
sx: { padding: 0, fontSize: "1em" },
|
|
1400
1409
|
children: /* @__PURE__ */ r(
|
|
1401
|
-
|
|
1410
|
+
De,
|
|
1402
1411
|
{
|
|
1403
1412
|
groups: g.groups,
|
|
1404
1413
|
groupsView: t,
|
|
@@ -1406,10 +1415,10 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
1406
1415
|
showRankChange: o,
|
|
1407
1416
|
showLegend: a,
|
|
1408
1417
|
highlightedCompetitorIds: l,
|
|
1409
|
-
zoneLabels:
|
|
1418
|
+
zoneLabels: c,
|
|
1410
1419
|
formByTeamId: (i == null ? void 0 : i[g.id]) ?? {},
|
|
1411
|
-
formLoading:
|
|
1412
|
-
sport:
|
|
1420
|
+
formLoading: f,
|
|
1421
|
+
sport: s
|
|
1413
1422
|
}
|
|
1414
1423
|
)
|
|
1415
1424
|
},
|
|
@@ -1418,48 +1427,48 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
1418
1427
|
]
|
|
1419
1428
|
}
|
|
1420
1429
|
);
|
|
1421
|
-
},
|
|
1430
|
+
}, It = ({
|
|
1422
1431
|
entityId: e,
|
|
1423
1432
|
sdk: t,
|
|
1424
1433
|
language: n,
|
|
1425
1434
|
stageId: o,
|
|
1426
1435
|
showHeader: a = !0,
|
|
1427
1436
|
showRankChange: l = !0,
|
|
1428
|
-
showLegend:
|
|
1437
|
+
showLegend: c = !0,
|
|
1429
1438
|
highlightedCompetitorIds: i,
|
|
1430
|
-
zoneColors:
|
|
1431
|
-
zoneLabels:
|
|
1432
|
-
columns:
|
|
1439
|
+
zoneColors: f,
|
|
1440
|
+
zoneLabels: s,
|
|
1441
|
+
columns: d,
|
|
1433
1442
|
groupsView: u = "overview",
|
|
1434
|
-
groupIds:
|
|
1443
|
+
groupIds: p,
|
|
1435
1444
|
seasonId: h,
|
|
1436
1445
|
range: b
|
|
1437
1446
|
}) => {
|
|
1438
1447
|
var ce;
|
|
1439
|
-
const { t:
|
|
1448
|
+
const { t: x } = Y("common"), g = D(), m = P(), w = j(), R = $(), { success: k, primary: F, warning: z, danger: I } = g.palette, T = G(
|
|
1440
1449
|
() => ({
|
|
1441
|
-
success:
|
|
1450
|
+
success: k.plainColor,
|
|
1442
1451
|
primary: F.plainColor,
|
|
1443
1452
|
warning: z.plainColor,
|
|
1444
1453
|
danger: I.plainColor
|
|
1445
1454
|
}),
|
|
1446
1455
|
[
|
|
1447
|
-
|
|
1456
|
+
k.plainColor,
|
|
1448
1457
|
F.plainColor,
|
|
1449
1458
|
z.plainColor,
|
|
1450
1459
|
I.plainColor
|
|
1451
1460
|
]
|
|
1452
|
-
), { data: y, loading: K, error: U } =
|
|
1461
|
+
), { data: y, loading: K, error: U } = mt(
|
|
1453
1462
|
e,
|
|
1454
1463
|
t,
|
|
1455
1464
|
T,
|
|
1456
|
-
|
|
1457
|
-
p,
|
|
1465
|
+
x("standings.unknownTeam"),
|
|
1458
1466
|
f,
|
|
1467
|
+
p,
|
|
1459
1468
|
h,
|
|
1460
1469
|
b,
|
|
1461
1470
|
o
|
|
1462
|
-
), H = !
|
|
1471
|
+
), H = !d || d.includes("form"), Q = ((ce = y == null ? void 0 : y.sport) == null ? void 0 : ce.toLowerCase()) === "football", Te = G(() => !y || !H ? [] : y.stages.map((v) => {
|
|
1463
1472
|
var W, O;
|
|
1464
1473
|
const A = /* @__PURE__ */ new Set();
|
|
1465
1474
|
return v.groups.forEach(
|
|
@@ -1488,8 +1497,8 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
1488
1497
|
})
|
|
1489
1498
|
)
|
|
1490
1499
|
), v;
|
|
1491
|
-
}, [y]), { formByStageAndTeam: re, loading: ae } =
|
|
1492
|
-
const v =
|
|
1500
|
+
}, [y]), { formByStageAndTeam: re, loading: ae } = St(t, Te, e, H && Q), se = G(() => {
|
|
1501
|
+
const v = x("standings.unknownTeam");
|
|
1493
1502
|
return Object.fromEntries(
|
|
1494
1503
|
Object.entries(re).map(([A, W]) => [
|
|
1495
1504
|
A,
|
|
@@ -1508,7 +1517,7 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
1508
1517
|
)
|
|
1509
1518
|
])
|
|
1510
1519
|
);
|
|
1511
|
-
}, [re, oe,
|
|
1520
|
+
}, [re, oe, x]), le = !y || y.stages.every(
|
|
1512
1521
|
(v) => v.groups.every((A) => A.rows.length === 0)
|
|
1513
1522
|
), ie = {
|
|
1514
1523
|
fontFamily: m.secondary,
|
|
@@ -1524,18 +1533,18 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
1524
1533
|
sx: {
|
|
1525
1534
|
fontSize: "1em",
|
|
1526
1535
|
fontFamily: m.primary,
|
|
1527
|
-
borderRadius:
|
|
1536
|
+
borderRadius: w.md,
|
|
1528
1537
|
overflow: "hidden",
|
|
1529
1538
|
backgroundColor: g.surface,
|
|
1530
1539
|
borderColor: g.outlineEnabledBorder
|
|
1531
1540
|
},
|
|
1532
1541
|
children: [
|
|
1533
|
-
K && /* @__PURE__ */ r(
|
|
1534
|
-
!K && U && /* @__PURE__ */ r(
|
|
1535
|
-
!K && !U && le && /* @__PURE__ */ r(
|
|
1542
|
+
K && /* @__PURE__ */ r(ze, { my: 10 }),
|
|
1543
|
+
!K && U && /* @__PURE__ */ r(L, { sx: ie, children: x("standings.loadFailed") }),
|
|
1544
|
+
!K && !U && le && /* @__PURE__ */ r(L, { sx: ie, children: x("standings.noStandingsAvailable") }),
|
|
1536
1545
|
!K && !U && y && !le && /* @__PURE__ */ C(_, { children: [
|
|
1537
1546
|
a && /* @__PURE__ */ r(
|
|
1538
|
-
|
|
1547
|
+
bt,
|
|
1539
1548
|
{
|
|
1540
1549
|
title: y.competitionName,
|
|
1541
1550
|
logoUrl: y.logoUrl,
|
|
@@ -1544,29 +1553,29 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
1544
1553
|
}
|
|
1545
1554
|
),
|
|
1546
1555
|
y.stages.length > 1 ? /* @__PURE__ */ r(
|
|
1547
|
-
|
|
1556
|
+
zt,
|
|
1548
1557
|
{
|
|
1549
1558
|
stages: y.stages,
|
|
1550
1559
|
groupsView: u,
|
|
1551
|
-
columns:
|
|
1560
|
+
columns: d,
|
|
1552
1561
|
showRankChange: l,
|
|
1553
|
-
showLegend:
|
|
1562
|
+
showLegend: c,
|
|
1554
1563
|
highlightedCompetitorIds: i,
|
|
1555
|
-
zoneLabels:
|
|
1564
|
+
zoneLabels: s,
|
|
1556
1565
|
formByStageId: se,
|
|
1557
1566
|
formLoading: ae,
|
|
1558
1567
|
sport: y.sport
|
|
1559
1568
|
}
|
|
1560
1569
|
) : /* @__PURE__ */ r(
|
|
1561
|
-
|
|
1570
|
+
De,
|
|
1562
1571
|
{
|
|
1563
1572
|
groups: y.stages[0].groups,
|
|
1564
1573
|
groupsView: u,
|
|
1565
|
-
columns:
|
|
1574
|
+
columns: d,
|
|
1566
1575
|
showRankChange: l,
|
|
1567
|
-
showLegend:
|
|
1576
|
+
showLegend: c,
|
|
1568
1577
|
highlightedCompetitorIds: i,
|
|
1569
|
-
zoneLabels:
|
|
1578
|
+
zoneLabels: s,
|
|
1570
1579
|
formByTeamId: se[y.stages[0].id] ?? {},
|
|
1571
1580
|
formLoading: ae,
|
|
1572
1581
|
sport: y.sport
|
|
@@ -1576,59 +1585,60 @@ const je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " "
|
|
|
1576
1585
|
]
|
|
1577
1586
|
}
|
|
1578
1587
|
);
|
|
1579
|
-
},
|
|
1580
|
-
const [t, n] = E.useState(!1), [o, a] = E.useState(!1), l =
|
|
1588
|
+
}, Mt = (e) => {
|
|
1589
|
+
const [t, n] = E.useState(!1), [o, a] = E.useState(!1), l = Ie(e.language), c = E.useRef(
|
|
1581
1590
|
`$standings-shadow-root-${Math.random().toString(36).substring(2, 11)}`
|
|
1582
|
-
), i = E.useRef(null),
|
|
1591
|
+
), i = E.useRef(null), f = E.useRef(null), s = E.useRef(null), [d, u] = E.useState(null);
|
|
1583
1592
|
E.useEffect(() => {
|
|
1584
|
-
|
|
1593
|
+
Me(e.language || "en").finally(() => a(!0));
|
|
1585
1594
|
}, [e.language]), E.useEffect(() => {
|
|
1586
1595
|
if (!i.current) return;
|
|
1587
|
-
i.current.shadowRoot ? (
|
|
1588
|
-
|
|
1589
|
-
),
|
|
1590
|
-
const
|
|
1596
|
+
i.current.shadowRoot ? (f.current = i.current.shadowRoot, s.current = f.current.getElementById(
|
|
1597
|
+
c.current
|
|
1598
|
+
), s.current || (s.current = document.createElement("div"), s.current.id = c.current, s.current.style.height = "100%", f.current.appendChild(s.current))) : (f.current = i.current.attachShadow({ mode: "open" }), s.current = document.createElement("div"), s.current.id = c.current, s.current.style.height = "100%", f.current.appendChild(s.current)), $e(s.current, l);
|
|
1599
|
+
const x = Ue("standings", l);
|
|
1591
1600
|
return u(
|
|
1592
|
-
(g) => (g == null ? void 0 : g.key) ===
|
|
1601
|
+
(g) => (g == null ? void 0 : g.key) === x ? g : We(
|
|
1593
1602
|
"standings",
|
|
1594
|
-
|
|
1603
|
+
f.current,
|
|
1595
1604
|
l
|
|
1596
1605
|
)
|
|
1597
1606
|
), n(!0), () => {
|
|
1598
1607
|
n(!1);
|
|
1599
1608
|
};
|
|
1600
1609
|
}, [l]);
|
|
1601
|
-
const
|
|
1610
|
+
const p = e.themeOptions, h = /* @__PURE__ */ r(S, { ref: i, lang: e.language || "en", sx: { height: "100%", display: "block" } }), b = t && o && s.current && d ? we(
|
|
1602
1611
|
// Keyed on the cache, not on `direction`: it must change in the same
|
|
1603
1612
|
// render that adopts the new cache, or CssVarsProvider writes its CSS
|
|
1604
1613
|
// variables into the outgoing cache and never repeats.
|
|
1605
|
-
/* @__PURE__ */ r(
|
|
1606
|
-
|
|
1614
|
+
/* @__PURE__ */ r(je, { value: d, children: /* @__PURE__ */ r(Be, { containerRef: i, children: /* @__PURE__ */ r(
|
|
1615
|
+
_e,
|
|
1607
1616
|
{
|
|
1608
|
-
customTheme:
|
|
1609
|
-
mode:
|
|
1610
|
-
shadowRootElement:
|
|
1617
|
+
customTheme: p,
|
|
1618
|
+
mode: p == null ? void 0 : p.mode,
|
|
1619
|
+
shadowRootElement: s.current,
|
|
1611
1620
|
direction: l,
|
|
1612
1621
|
children: /* @__PURE__ */ r(
|
|
1613
|
-
|
|
1622
|
+
He,
|
|
1614
1623
|
{
|
|
1615
|
-
shadowRootElement:
|
|
1624
|
+
shadowRootElement: s.current,
|
|
1616
1625
|
leadPhoneCountryCode: null,
|
|
1617
1626
|
language: e.language,
|
|
1618
1627
|
optionsLayout: null,
|
|
1619
1628
|
direction: l,
|
|
1629
|
+
disableCache: e.disableCache ?? !1,
|
|
1620
1630
|
children: e.children
|
|
1621
1631
|
}
|
|
1622
1632
|
)
|
|
1623
1633
|
}
|
|
1624
|
-
) }) },
|
|
1625
|
-
|
|
1634
|
+
) }) }, d.key),
|
|
1635
|
+
s.current
|
|
1626
1636
|
) : null;
|
|
1627
1637
|
return /* @__PURE__ */ C(_, { children: [
|
|
1628
1638
|
h,
|
|
1629
1639
|
b
|
|
1630
1640
|
] });
|
|
1631
|
-
},
|
|
1641
|
+
}, $t = (e) => /* @__PURE__ */ r(Mt, { ...e, children: /* @__PURE__ */ r(It, { ...e }) }), Qt = Ze($t);
|
|
1632
1642
|
export {
|
|
1633
|
-
|
|
1643
|
+
Qt as Standings
|
|
1634
1644
|
};
|