@sensiblestats/widget-react 0.139.0 → 0.140.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/CHANGELOG.md +11 -0
- package/dist/index.cjs +535 -450
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +241 -156
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
package/dist/index.cjs
CHANGED
|
@@ -38,7 +38,7 @@ __export(index_exports, {
|
|
|
38
38
|
module.exports = __toCommonJS(index_exports);
|
|
39
39
|
|
|
40
40
|
// src/StatsWidget.tsx
|
|
41
|
-
var
|
|
41
|
+
var import_react112 = require("react");
|
|
42
42
|
var import_widget_sdk38 = require("@sensiblestats/widget-sdk");
|
|
43
43
|
|
|
44
44
|
// src/strings/tag.ts
|
|
@@ -1338,7 +1338,7 @@ function parseOddsFormat(value) {
|
|
|
1338
1338
|
}
|
|
1339
1339
|
|
|
1340
1340
|
// src/version.generated.ts
|
|
1341
|
-
var WIDGET_REACT_VERSION = "0.
|
|
1341
|
+
var WIDGET_REACT_VERSION = "0.140.0";
|
|
1342
1342
|
|
|
1343
1343
|
// src/config.ts
|
|
1344
1344
|
function hostTag(cfg) {
|
|
@@ -2589,6 +2589,7 @@ var MAX_ODDS = 1e4;
|
|
|
2589
2589
|
function slipPickFields(selection, label, line) {
|
|
2590
2590
|
const fields = {};
|
|
2591
2591
|
if (((0, import_widget_sdk4.sportOf)(selection.sport) === void 0 || (0, import_widget_sdk4.toWireSport)(selection.sport) !== void 0) && Number.isSafeInteger(selection.matchId) && selection.matchId > 0) fields.matchId = selection.matchId;
|
|
2592
|
+
if (Number.isSafeInteger(selection.matchOddsId) && selection.matchOddsId > 0) fields.matchOddsId = selection.matchOddsId;
|
|
2592
2593
|
if (label && label.trim() && label.length <= MAX_SELECTION) fields.selection = label;
|
|
2593
2594
|
if (line && line.trim() && line.length <= MAX_LINE) fields.line = line;
|
|
2594
2595
|
const odds = selection.oddsDecimal;
|
|
@@ -2966,6 +2967,7 @@ function toSlipEvent(name, entry) {
|
|
|
2966
2967
|
entityId: entry.market,
|
|
2967
2968
|
marketDeveloperName: entry.market,
|
|
2968
2969
|
matchId: entry.matchId,
|
|
2970
|
+
matchOddsId: entry.id,
|
|
2969
2971
|
selection: entry.selection,
|
|
2970
2972
|
line: entry.line,
|
|
2971
2973
|
odds: entry.odds,
|
|
@@ -3378,6 +3380,7 @@ function applyEvent(state, event) {
|
|
|
3378
3380
|
greetingDashboard: event.data.dashboard ?? void 0,
|
|
3379
3381
|
greetingDashboards: event.data.dashboards ?? void 0,
|
|
3380
3382
|
defaultSport: event.data.defaultSport ?? void 0,
|
|
3383
|
+
greeting: event.data.greeting,
|
|
3381
3384
|
clubFanDashboard: event.data.clubFanDashboard ?? void 0
|
|
3382
3385
|
}))
|
|
3383
3386
|
};
|
|
@@ -5617,7 +5620,7 @@ function useFavourites({ conversation, sport, operatorUserId, anonymousUserId, e
|
|
|
5617
5620
|
}
|
|
5618
5621
|
|
|
5619
5622
|
// src/components/dashboard/GreetingDashboard.tsx
|
|
5620
|
-
var
|
|
5623
|
+
var import_react44 = require("react");
|
|
5621
5624
|
|
|
5622
5625
|
// src/eventLogContext.ts
|
|
5623
5626
|
var import_react18 = require("react");
|
|
@@ -5633,6 +5636,50 @@ function useSportScope() {
|
|
|
5633
5636
|
return (0, import_react19.useContext)(SportScopeContext);
|
|
5634
5637
|
}
|
|
5635
5638
|
|
|
5639
|
+
// src/greetingEvents.ts
|
|
5640
|
+
var import_react20 = require("react");
|
|
5641
|
+
function latestGreetingMeta(messages) {
|
|
5642
|
+
for (let i = messages.length - 1; i >= 0; i--) {
|
|
5643
|
+
const m = messages[i];
|
|
5644
|
+
if (m && m.role === "assistant" && m.isGreeting) return m.greeting;
|
|
5645
|
+
}
|
|
5646
|
+
return void 0;
|
|
5647
|
+
}
|
|
5648
|
+
var sentByOwner = /* @__PURE__ */ new WeakMap();
|
|
5649
|
+
function sendGreetingOnce(log, owner, meta, surface) {
|
|
5650
|
+
let sent = sentByOwner.get(owner);
|
|
5651
|
+
if (!sent) {
|
|
5652
|
+
sent = /* @__PURE__ */ new Set();
|
|
5653
|
+
sentByOwner.set(owner, sent);
|
|
5654
|
+
}
|
|
5655
|
+
const key = `${meta.greetingId}:${surface}:${meta.sport}`;
|
|
5656
|
+
if (sent.has(key)) return;
|
|
5657
|
+
sent.add(key);
|
|
5658
|
+
log({
|
|
5659
|
+
name: "greeting_shown",
|
|
5660
|
+
greeting: {
|
|
5661
|
+
greetingId: meta.greetingId,
|
|
5662
|
+
surface,
|
|
5663
|
+
case: meta.case,
|
|
5664
|
+
sport: meta.sport,
|
|
5665
|
+
market: meta.market ?? null,
|
|
5666
|
+
marketStep: meta.marketStep,
|
|
5667
|
+
matchStep: meta.matchStep,
|
|
5668
|
+
matchId: meta.matchId ?? null,
|
|
5669
|
+
competitionId: meta.competitionId ?? null,
|
|
5670
|
+
chooserShown: meta.chooserShown
|
|
5671
|
+
}
|
|
5672
|
+
});
|
|
5673
|
+
}
|
|
5674
|
+
function useBubbleGreetingShown(log, owner, popupText, meta, confirmedShown) {
|
|
5675
|
+
(0, import_react20.useEffect)(() => {
|
|
5676
|
+
const text2 = confirmedShown === void 0 || confirmedShown === popupText ? popupText : null;
|
|
5677
|
+
if (!log || !text2 || !meta) return;
|
|
5678
|
+
sendGreetingOnce((e) => log.log(e), owner, meta, "bubble");
|
|
5679
|
+
}, [log, owner, popupText, meta, confirmedShown]);
|
|
5680
|
+
}
|
|
5681
|
+
var GreetingEventsContext = (0, import_react20.createContext)(null);
|
|
5682
|
+
|
|
5636
5683
|
// src/assets/logo.ts
|
|
5637
5684
|
var SS_LOGO_DATA_URI = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAjoAAAI6CAYAAAAuSOLAAAAAAXNSR0IArs4c6QAAAJplWElmTU0AKgAAAAgAAwESAAMAAAABAAEAAAExAAIAAAA9AAAAModpAA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iMG772bgdk1RMBAMBCEAAAhCAAAQgAAEIQAACEIAABCAAAQhAAAIQgAAEIAABCEAAAhCAAAQgAAEIQAACEIAABCAAAQhAAAIQgAAEIAABCEAAAhCAAAQgAAEIQAACEIBAqgT+PwQUc6J1VOHQAAAAAElFTkSuQmCC";
|
|
5638
5685
|
|
|
@@ -5766,10 +5813,10 @@ function DashboardTile({ tile, onTap, oddsLabel, badgePlacement = "meta" }) {
|
|
|
5766
5813
|
}
|
|
5767
5814
|
|
|
5768
5815
|
// src/components/dashboard/SportSwitch.tsx
|
|
5769
|
-
var
|
|
5816
|
+
var import_react21 = require("react");
|
|
5770
5817
|
var import_jsx_runtime3 = require("react/jsx-runtime");
|
|
5771
5818
|
function SportSwitch({ sports, selected, onSelect, liveLabel: liveLabel3, groupLabel, tag: tag2 }) {
|
|
5772
|
-
const refs = (0,
|
|
5819
|
+
const refs = (0, import_react21.useRef)([]);
|
|
5773
5820
|
if (sports.length < 2) return null;
|
|
5774
5821
|
const focusAt = (i) => refs.current[(i + sports.length) % sports.length]?.focus();
|
|
5775
5822
|
const onKeyDown = (e, i) => {
|
|
@@ -5818,36 +5865,41 @@ function SportSwitch({ sports, selected, onSelect, liveLabel: liveLabel3, groupL
|
|
|
5818
5865
|
}
|
|
5819
5866
|
|
|
5820
5867
|
// src/personalGreetingContext.ts
|
|
5821
|
-
var
|
|
5868
|
+
var import_react22 = require("react");
|
|
5822
5869
|
function useSessionHolds() {
|
|
5823
|
-
const [dismissed, setDismissed] = (0,
|
|
5824
|
-
const [followed, setFollowed] = (0,
|
|
5825
|
-
return (0,
|
|
5870
|
+
const [dismissed, setDismissed] = (0, import_react22.useState)(/* @__PURE__ */ new Set());
|
|
5871
|
+
const [followed, setFollowed] = (0, import_react22.useState)(/* @__PURE__ */ new Set());
|
|
5872
|
+
return (0, import_react22.useMemo)(() => ({
|
|
5826
5873
|
dismissed,
|
|
5827
5874
|
followed,
|
|
5828
5875
|
dismiss: (key) => setDismissed((prev) => prev.has(key) ? prev : new Set(prev).add(key)),
|
|
5829
5876
|
follow: (key) => setFollowed((prev) => prev.has(key) ? prev : new Set(prev).add(key))
|
|
5830
5877
|
}), [dismissed, followed]);
|
|
5831
5878
|
}
|
|
5832
|
-
var PersonalGreetingContext = (0,
|
|
5879
|
+
var PersonalGreetingContext = (0, import_react22.createContext)(null);
|
|
5833
5880
|
function usePersonalGreeting() {
|
|
5834
|
-
return (0,
|
|
5881
|
+
return (0, import_react22.useContext)(PersonalGreetingContext);
|
|
5835
5882
|
}
|
|
5836
5883
|
|
|
5837
5884
|
// src/components/dashboard/v8/AskCards.tsx
|
|
5885
|
+
var import_react23 = require("react");
|
|
5838
5886
|
var import_jsx_runtime4 = require("react/jsx-runtime");
|
|
5839
5887
|
function AskCards({ asks, ui, ofYours, onAct }) {
|
|
5888
|
+
const events = (0, import_react23.useContext)(GreetingEventsContext);
|
|
5840
5889
|
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)("section", { className: "ss-w-v8-sec ss-w-v8-asks", children: [
|
|
5841
5890
|
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("h3", { className: "ss-w-v8-sec-title", children: ofYours ? ui.v8AskYours : ui.v8AskOr }),
|
|
5842
|
-
asks.map((ask, i) => /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("button", { type: "button", className: "ss-w-v8-ask", onClick: () =>
|
|
5891
|
+
asks.map((ask, i) => /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("button", { type: "button", className: "ss-w-v8-ask", onClick: () => {
|
|
5892
|
+
events?.askTap(i);
|
|
5893
|
+
onAct?.(toActionVM({ ...ask }));
|
|
5894
|
+
}, children: ask.actionLabel }, `${ask.actionLabel}:${i}`))
|
|
5843
5895
|
] });
|
|
5844
5896
|
}
|
|
5845
5897
|
|
|
5846
5898
|
// src/components/dashboard/v8/CardLine.tsx
|
|
5847
|
-
var
|
|
5899
|
+
var import_react38 = require("react");
|
|
5848
5900
|
|
|
5849
5901
|
// src/useBuilderGrid.ts
|
|
5850
|
-
var
|
|
5902
|
+
var import_react24 = require("react");
|
|
5851
5903
|
|
|
5852
5904
|
// src/builderMemory.ts
|
|
5853
5905
|
var GRID_TTL_MS = 5 * 6e4;
|
|
@@ -5937,18 +5989,18 @@ function forget(memory3, key, flight) {
|
|
|
5937
5989
|
if (flights?.get(key) === flight) flights.delete(key);
|
|
5938
5990
|
}
|
|
5939
5991
|
function useBuilderGrid({ conversation, locale, memory: memory3, initial: initial2 }) {
|
|
5940
|
-
const [seed] = (0,
|
|
5941
|
-
const [grid, setGrid] = (0,
|
|
5942
|
-
const [status2, setStatus] = (0,
|
|
5943
|
-
const [confirmed, setConfirmed] = (0,
|
|
5944
|
-
const [answered, setAnswered] = (0,
|
|
5945
|
-
const seq = (0,
|
|
5946
|
-
const mounted = (0,
|
|
5947
|
-
const hung = (0,
|
|
5948
|
-
const waiting = (0,
|
|
5949
|
-
const memoryRef = (0,
|
|
5992
|
+
const [seed] = (0, import_react24.useState)(() => memory3 && conversation && initial2 ? memory3.cachedGrid(gridKey(locale, initial2)) : void 0);
|
|
5993
|
+
const [grid, setGrid] = (0, import_react24.useState)(seed ?? null);
|
|
5994
|
+
const [status2, setStatus] = (0, import_react24.useState)(seed ? "ready" : "idle");
|
|
5995
|
+
const [confirmed, setConfirmed] = (0, import_react24.useState)(false);
|
|
5996
|
+
const [answered, setAnswered] = (0, import_react24.useState)(seed && initial2 ? { req: initial2, locale } : null);
|
|
5997
|
+
const seq = (0, import_react24.useRef)(0);
|
|
5998
|
+
const mounted = (0, import_react24.useRef)(true);
|
|
5999
|
+
const hung = (0, import_react24.useRef)(void 0);
|
|
6000
|
+
const waiting = (0, import_react24.useRef)(null);
|
|
6001
|
+
const memoryRef = (0, import_react24.useRef)(memory3);
|
|
5950
6002
|
memoryRef.current = memory3;
|
|
5951
|
-
const stopWaiting = (0,
|
|
6003
|
+
const stopWaiting = (0, import_react24.useCallback)((release, keep) => {
|
|
5952
6004
|
window.clearTimeout(hung.current);
|
|
5953
6005
|
const w = waiting.current;
|
|
5954
6006
|
waiting.current = null;
|
|
@@ -5956,14 +6008,14 @@ function useBuilderGrid({ conversation, locale, memory: memory3, initial: initia
|
|
|
5956
6008
|
w.flight.waiters -= 1;
|
|
5957
6009
|
if (release && w.key !== keep && w.flight.waiters <= 0 && memoryRef.current) forget(memoryRef.current, w.key, w.flight);
|
|
5958
6010
|
}, []);
|
|
5959
|
-
(0,
|
|
6011
|
+
(0, import_react24.useEffect)(() => {
|
|
5960
6012
|
mounted.current = true;
|
|
5961
6013
|
return () => {
|
|
5962
6014
|
mounted.current = false;
|
|
5963
6015
|
stopWaiting(true);
|
|
5964
6016
|
};
|
|
5965
6017
|
}, [stopWaiting]);
|
|
5966
|
-
const request = (0,
|
|
6018
|
+
const request = (0, import_react24.useCallback)(async (req) => {
|
|
5967
6019
|
if (!conversation) return;
|
|
5968
6020
|
const mine = ++seq.current;
|
|
5969
6021
|
const key = memory3 ? gridKey(locale, req) : null;
|
|
@@ -6039,26 +6091,26 @@ function useBuilderGrid({ conversation, locale, memory: memory3, initial: initia
|
|
|
6039
6091
|
}
|
|
6040
6092
|
|
|
6041
6093
|
// src/components/AddToSlipButton.tsx
|
|
6042
|
-
var
|
|
6094
|
+
var import_react29 = require("react");
|
|
6043
6095
|
|
|
6044
6096
|
// src/slipAdd.ts
|
|
6045
|
-
var
|
|
6097
|
+
var import_react27 = require("react");
|
|
6046
6098
|
var import_widget_sdk16 = require("@sensiblestats/widget-sdk");
|
|
6047
6099
|
|
|
6048
6100
|
// src/trackingContext.ts
|
|
6049
|
-
var
|
|
6101
|
+
var import_react25 = require("react");
|
|
6050
6102
|
var noop = () => {
|
|
6051
6103
|
};
|
|
6052
|
-
var TrackingContext = (0,
|
|
6104
|
+
var TrackingContext = (0, import_react25.createContext)(noop);
|
|
6053
6105
|
function useTrack() {
|
|
6054
|
-
return (0,
|
|
6106
|
+
return (0, import_react25.useContext)(TrackingContext);
|
|
6055
6107
|
}
|
|
6056
6108
|
|
|
6057
6109
|
// src/slipStateContext.ts
|
|
6058
|
-
var
|
|
6059
|
-
var SlipStateContext = (0,
|
|
6110
|
+
var import_react26 = require("react");
|
|
6111
|
+
var SlipStateContext = (0, import_react26.createContext)(null);
|
|
6060
6112
|
function useSlipState() {
|
|
6061
|
-
return (0,
|
|
6113
|
+
return (0, import_react26.useContext)(SlipStateContext);
|
|
6062
6114
|
}
|
|
6063
6115
|
|
|
6064
6116
|
// src/slipAdd.ts
|
|
@@ -6090,7 +6142,7 @@ function useSlipAdd(slip, ui) {
|
|
|
6090
6142
|
const handler = slip.onAddToSlip;
|
|
6091
6143
|
const rawLabels = !!ui?.rawBettingLabels;
|
|
6092
6144
|
const operatorFormat = ui?.oddsFormat ?? "decimal";
|
|
6093
|
-
return (0,
|
|
6145
|
+
return (0, import_react27.useCallback)(async (selection, { marketDeveloperName, selectionLabel, line, fact }) => {
|
|
6094
6146
|
if (!handler) return { kind: "failed" };
|
|
6095
6147
|
const display = slipDisplay({ ...selection.display, market: marketDeveloperName, selection: selectionLabel, line });
|
|
6096
6148
|
const out = toHostSelection(display ? { ...selection, display } : selection, operatorFormat);
|
|
@@ -6148,11 +6200,11 @@ function useSlipAdd(slip, ui) {
|
|
|
6148
6200
|
}
|
|
6149
6201
|
|
|
6150
6202
|
// src/components/Toast.tsx
|
|
6151
|
-
var
|
|
6203
|
+
var import_react28 = require("react");
|
|
6152
6204
|
var import_jsx_runtime5 = require("react/jsx-runtime");
|
|
6153
6205
|
var DISMISS_MS = 4e3;
|
|
6154
6206
|
function Toast({ toast, onDismiss }) {
|
|
6155
|
-
(0,
|
|
6207
|
+
(0, import_react28.useEffect)(() => {
|
|
6156
6208
|
if (!toast) return;
|
|
6157
6209
|
const timer = setTimeout(onDismiss, DISMISS_MS);
|
|
6158
6210
|
return () => clearTimeout(timer);
|
|
@@ -6164,10 +6216,10 @@ function Toast({ toast, onDismiss }) {
|
|
|
6164
6216
|
// src/components/AddToSlipButton.tsx
|
|
6165
6217
|
var import_jsx_runtime6 = require("react/jsx-runtime");
|
|
6166
6218
|
function SlipButton({ selection, marketDeveloperName, selectionLabel, line, slip, ui, price, ariaLabel, hold, fact }) {
|
|
6167
|
-
const [pending, setPending] = (0,
|
|
6168
|
-
const [settledLocal, setSettledLocal] = (0,
|
|
6169
|
-
const [toast, setToast] = (0,
|
|
6170
|
-
const dismiss = (0,
|
|
6219
|
+
const [pending, setPending] = (0, import_react29.useState)(false);
|
|
6220
|
+
const [settledLocal, setSettledLocal] = (0, import_react29.useState)(false);
|
|
6221
|
+
const [toast, setToast] = (0, import_react29.useState)(null);
|
|
6222
|
+
const dismiss = (0, import_react29.useCallback)(() => setToast(null), []);
|
|
6171
6223
|
const add = useSlipAdd(slip, ui);
|
|
6172
6224
|
const slipState = useSlipState();
|
|
6173
6225
|
const { oddsFormat } = useOddsSettings();
|
|
@@ -6273,11 +6325,11 @@ function oldestQuote(legs) {
|
|
|
6273
6325
|
}
|
|
6274
6326
|
|
|
6275
6327
|
// src/components/MarketOddsCardList.tsx
|
|
6276
|
-
var
|
|
6328
|
+
var import_react37 = require("react");
|
|
6277
6329
|
var import_widget_sdk21 = require("@sensiblestats/widget-sdk");
|
|
6278
6330
|
|
|
6279
6331
|
// src/nflKickoff.ts
|
|
6280
|
-
var
|
|
6332
|
+
var import_react30 = require("react");
|
|
6281
6333
|
var import_widget_sdk18 = require("@sensiblestats/widget-sdk");
|
|
6282
6334
|
var MAX_TIMEOUT_MS = 2147483647;
|
|
6283
6335
|
var isNfl = (sport) => (0, import_widget_sdk18.sportOf)(sport) === "americanfootball";
|
|
@@ -6305,9 +6357,9 @@ function guardLegsPreMatch(slip, legs, ui) {
|
|
|
6305
6357
|
};
|
|
6306
6358
|
}
|
|
6307
6359
|
function useNextKickoffRender(kickoffs) {
|
|
6308
|
-
const [tick, setTick] = (0,
|
|
6360
|
+
const [tick, setTick] = (0, import_react30.useState)(0);
|
|
6309
6361
|
const key = kickoffs.map((k) => k ?? "").join("|");
|
|
6310
|
-
(0,
|
|
6362
|
+
(0, import_react30.useEffect)(() => {
|
|
6311
6363
|
const now = Date.now();
|
|
6312
6364
|
const upcoming = key.split("|").map((k) => k ? Date.parse(k) : NaN).filter((ms) => ms > now);
|
|
6313
6365
|
if (upcoming.length === 0) return;
|
|
@@ -6343,14 +6395,14 @@ function OddsMovementBadge({
|
|
|
6343
6395
|
}
|
|
6344
6396
|
|
|
6345
6397
|
// src/components/Crest.tsx
|
|
6346
|
-
var
|
|
6398
|
+
var import_react31 = require("react");
|
|
6347
6399
|
var import_jsx_runtime8 = require("react/jsx-runtime");
|
|
6348
6400
|
function initials(name) {
|
|
6349
6401
|
return (name ?? "").trim().slice(0, 1).toUpperCase() || "?";
|
|
6350
6402
|
}
|
|
6351
6403
|
function Crest({ url, name, kind, abbr }) {
|
|
6352
6404
|
const cls = kind === "comp" ? "ss-w-bi-comp-logo" : "ss-w-bi-crest";
|
|
6353
|
-
const [failed, setFailed] = (0,
|
|
6405
|
+
const [failed, setFailed] = (0, import_react31.useState)(false);
|
|
6354
6406
|
if (url && !failed) {
|
|
6355
6407
|
return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("img", { className: cls, src: url, alt: "", "aria-hidden": "true", onError: () => setFailed(true) });
|
|
6356
6408
|
}
|
|
@@ -6359,7 +6411,7 @@ function Crest({ url, name, kind, abbr }) {
|
|
|
6359
6411
|
}
|
|
6360
6412
|
|
|
6361
6413
|
// src/components/PinToggle.tsx
|
|
6362
|
-
var
|
|
6414
|
+
var import_react32 = require("react");
|
|
6363
6415
|
var import_widget_sdk19 = require("@sensiblestats/widget-sdk");
|
|
6364
6416
|
var import_jsx_runtime9 = require("react/jsx-runtime");
|
|
6365
6417
|
var PIN_GLYPHS = {
|
|
@@ -6368,8 +6420,8 @@ var PIN_GLYPHS = {
|
|
|
6368
6420
|
bookmark: { viewBox: "0 0 24 24", strokeWidth: 2, d: "M7 3h10a1.5 1.5 0 0 1 1.5 1.5V21l-6.5-3.6L5.5 21V4.5A1.5 1.5 0 0 1 7 3z" }
|
|
6369
6421
|
};
|
|
6370
6422
|
function PinToggle({ pin, monitor, ui, market }) {
|
|
6371
|
-
const [toast, setToast] = (0,
|
|
6372
|
-
const dismiss = (0,
|
|
6423
|
+
const [toast, setToast] = (0, import_react32.useState)(null);
|
|
6424
|
+
const dismiss = (0, import_react32.useCallback)(() => setToast(null), []);
|
|
6373
6425
|
const log = useEventLog();
|
|
6374
6426
|
if (!monitor || !monitor.enabled) return null;
|
|
6375
6427
|
const key = pinKey(pin);
|
|
@@ -6438,11 +6490,11 @@ function PinToggle({ pin, monitor, ui, market }) {
|
|
|
6438
6490
|
}
|
|
6439
6491
|
|
|
6440
6492
|
// src/components/PriceHistoryButton.tsx
|
|
6441
|
-
var
|
|
6493
|
+
var import_react33 = require("react");
|
|
6442
6494
|
var import_jsx_runtime10 = require("react/jsx-runtime");
|
|
6443
6495
|
function PriceHistoryButton({ selection, monitor, ui, displayLabel }) {
|
|
6444
|
-
const [toast, setToast] = (0,
|
|
6445
|
-
const dismiss = (0,
|
|
6496
|
+
const [toast, setToast] = (0, import_react33.useState)(null);
|
|
6497
|
+
const dismiss = (0, import_react33.useCallback)(() => setToast(null), []);
|
|
6446
6498
|
const log = useEventLog();
|
|
6447
6499
|
if (!monitor || !monitor.enabled) return null;
|
|
6448
6500
|
const name = displayLabel ?? joinSelection(selection.selectionLabel ?? void 0, selection.line ?? void 0);
|
|
@@ -6469,19 +6521,19 @@ function PriceHistoryButton({ selection, monitor, ui, displayLabel }) {
|
|
|
6469
6521
|
}
|
|
6470
6522
|
|
|
6471
6523
|
// src/components/LiveFactBlock.tsx
|
|
6472
|
-
var
|
|
6524
|
+
var import_react35 = require("react");
|
|
6473
6525
|
|
|
6474
6526
|
// src/useFactView.ts
|
|
6475
|
-
var
|
|
6527
|
+
var import_react34 = require("react");
|
|
6476
6528
|
var DWELL_MS = 1e3;
|
|
6477
6529
|
var seen = /* @__PURE__ */ new Set();
|
|
6478
6530
|
function useFactView(ref, fact, entity2) {
|
|
6479
6531
|
const log = useEventLog();
|
|
6480
|
-
const entityRef = (0,
|
|
6532
|
+
const entityRef = (0, import_react34.useRef)(entity2);
|
|
6481
6533
|
entityRef.current = entity2;
|
|
6482
6534
|
const id = fact?.id;
|
|
6483
6535
|
const factKey = fact?.factKey;
|
|
6484
|
-
(0,
|
|
6536
|
+
(0, import_react34.useEffect)(() => {
|
|
6485
6537
|
if (id === void 0 || factKey === void 0 || seen.has(id) || !log) return;
|
|
6486
6538
|
const el = ref.current;
|
|
6487
6539
|
if (!el) return;
|
|
@@ -6529,10 +6581,10 @@ function evidenceText(f, ui) {
|
|
|
6529
6581
|
return parts2.length > 0 ? parts2.join(" \xB7 ") : void 0;
|
|
6530
6582
|
}
|
|
6531
6583
|
function LiveFactBlock({ facts, match, ui, slip, onAsk }) {
|
|
6532
|
-
const [expanded, setExpanded] = (0,
|
|
6584
|
+
const [expanded, setExpanded] = (0, import_react35.useState)(false);
|
|
6533
6585
|
const { oddsFormat } = useOddsSettings();
|
|
6534
6586
|
const log = useEventLog();
|
|
6535
|
-
const sectionRef = (0,
|
|
6587
|
+
const sectionRef = (0, import_react35.useRef)(null);
|
|
6536
6588
|
const current = facts.find((f) => f.marketState);
|
|
6537
6589
|
const earlier = facts.filter((f) => f.marketState && f !== current);
|
|
6538
6590
|
const background = facts.filter((f) => !f.marketState).slice(0, BACKGROUND_MAX);
|
|
@@ -6617,7 +6669,7 @@ function LiveFactBlock({ facts, match, ui, slip, onAsk }) {
|
|
|
6617
6669
|
}
|
|
6618
6670
|
|
|
6619
6671
|
// src/components/AllMarketsButton.tsx
|
|
6620
|
-
var
|
|
6672
|
+
var import_react36 = require("react");
|
|
6621
6673
|
var import_widget_sdk20 = require("@sensiblestats/widget-sdk");
|
|
6622
6674
|
var import_jsx_runtime12 = require("react/jsx-runtime");
|
|
6623
6675
|
function allMarketsCount(vm, monitor) {
|
|
@@ -6626,8 +6678,8 @@ function allMarketsCount(vm, monitor) {
|
|
|
6626
6678
|
}
|
|
6627
6679
|
function AllMarketsButton({ vm, count: count2, monitor, ui, surface }) {
|
|
6628
6680
|
const log = useEventLog();
|
|
6629
|
-
const [toast, setToast] = (0,
|
|
6630
|
-
const dismiss = (0,
|
|
6681
|
+
const [toast, setToast] = (0, import_react36.useState)(null);
|
|
6682
|
+
const dismiss = (0, import_react36.useCallback)(() => setToast(null), []);
|
|
6631
6683
|
const onClick = () => {
|
|
6632
6684
|
if (monitor.pinMatch({ matchId: vm.matchId, marketDeveloperName: vm.marketDeveloperName }) === "match_limit") {
|
|
6633
6685
|
setToast({ kind: "error", text: ui.matchLimitToast });
|
|
@@ -6692,7 +6744,7 @@ function fmtHhMm(iso, tag2, clock3, timeZone) {
|
|
|
6692
6744
|
return formatTime(iso, tag2, clock3, { timeZone });
|
|
6693
6745
|
}
|
|
6694
6746
|
function MarketOddsCard({ vm, ui, slip, monitor, inSlipIds, hideHeader, pinRef }) {
|
|
6695
|
-
const [open, setOpen] = (0,
|
|
6747
|
+
const [open, setOpen] = (0, import_react37.useState)(false);
|
|
6696
6748
|
useNextKickoffRender(isNfl(vm.sport) ? [vm.kickoffUtc] : []);
|
|
6697
6749
|
const kickoffFallback = vm.kickoffUtc ? ui.bettingKickoff(vm.kickoffUtc) : void 0;
|
|
6698
6750
|
const kickoff = vm.kickoffLabel ?? (kickoffFallback ? `${kickoffFallback.dayLabel} ${kickoffFallback.time}` : void 0);
|
|
@@ -6703,9 +6755,9 @@ function MarketOddsCard({ vm, ui, slip, monitor, inSlipIds, hideHeader, pinRef }
|
|
|
6703
6755
|
const asOfMs = live ? new Date(live.asOfUtc).getTime() : NaN;
|
|
6704
6756
|
const isStale = live != null && !isClosed && (vm.awaitingLiveUpdate === true || Date.now() - asOfMs > STALE_AFTER_MS);
|
|
6705
6757
|
const staleTime = isStale && live ? fmtHhMm(live.asOfUtc, ui.locale, clockOf(ui), ui.timeZone) : null;
|
|
6706
|
-
const [, setStaleTick] = (0,
|
|
6758
|
+
const [, setStaleTick] = (0, import_react37.useState)(0);
|
|
6707
6759
|
const watchStale = live != null && !isClosed && !isStale;
|
|
6708
|
-
(0,
|
|
6760
|
+
(0, import_react37.useEffect)(() => {
|
|
6709
6761
|
if (!watchStale) return;
|
|
6710
6762
|
const id = window.setTimeout(() => setStaleTick((n) => n + 1), Math.max(0, asOfMs + STALE_AFTER_MS - Date.now()) + 1);
|
|
6711
6763
|
return () => window.clearTimeout(id);
|
|
@@ -6844,7 +6896,7 @@ var asOf = (iso, ui) => {
|
|
|
6844
6896
|
function CardLine({ card, ui, slip, sport, marketKey, conversation, operatorUserId, anonymousUserId }) {
|
|
6845
6897
|
const matchId = card.matchId;
|
|
6846
6898
|
const canAdd2 = !!slip.onAddToSlip;
|
|
6847
|
-
const ask = (0,
|
|
6899
|
+
const ask = (0, import_react38.useMemo)(() => canAdd2 && marketKey && matchId ? {
|
|
6848
6900
|
sport,
|
|
6849
6901
|
marketKey,
|
|
6850
6902
|
matchIds: [matchId],
|
|
@@ -6855,7 +6907,7 @@ function CardLine({ card, ui, slip, sport, marketKey, conversation, operatorUser
|
|
|
6855
6907
|
...anonymousUserId ? { anonymousUserId } : {}
|
|
6856
6908
|
} : null, [canAdd2, sport, marketKey, matchId, operatorUserId, anonymousUserId]);
|
|
6857
6909
|
const { grid, answeredFor, request } = useBuilderGrid({ conversation, locale: ui.hostTag, initial: ask });
|
|
6858
|
-
(0,
|
|
6910
|
+
(0, import_react38.useEffect)(() => {
|
|
6859
6911
|
if (ask) void request(ask);
|
|
6860
6912
|
}, [request, ask]);
|
|
6861
6913
|
useNextKickoffRender([card.startsAtUtc]);
|
|
@@ -6894,16 +6946,16 @@ function CardLine({ card, ui, slip, sport, marketKey, conversation, operatorUser
|
|
|
6894
6946
|
}
|
|
6895
6947
|
|
|
6896
6948
|
// src/components/dashboard/v8/Pic.tsx
|
|
6897
|
-
var
|
|
6949
|
+
var import_react39 = require("react");
|
|
6898
6950
|
var import_jsx_runtime15 = require("react/jsx-runtime");
|
|
6899
6951
|
function Pic({ src, kind = "team" }) {
|
|
6900
|
-
const [failed, setFailed] = (0,
|
|
6952
|
+
const [failed, setFailed] = (0, import_react39.useState)(null);
|
|
6901
6953
|
if (!src || failed === src) return null;
|
|
6902
6954
|
return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("img", { className: kind === "player" ? "ss-w-v8-pic ss-w-v8-pic--player" : "ss-w-v8-pic", src, alt: "", "aria-hidden": "true", onError: () => setFailed(src) });
|
|
6903
6955
|
}
|
|
6904
6956
|
|
|
6905
6957
|
// src/components/dashboard/v8/FactPrice.tsx
|
|
6906
|
-
var
|
|
6958
|
+
var import_react40 = require("react");
|
|
6907
6959
|
|
|
6908
6960
|
// src/components/dashboard/v8/factLeg.ts
|
|
6909
6961
|
var isProp = (key) => key.toLowerCase().startsWith("prop_");
|
|
@@ -6934,7 +6986,7 @@ var import_jsx_runtime16 = require("react/jsx-runtime");
|
|
|
6934
6986
|
function FactPrice({ reference, ui, slip, conversation, memory: memory3, stars, enabled, operatorUserId, anonymousUserId }) {
|
|
6935
6987
|
const { sport, marketKey, matchId } = reference;
|
|
6936
6988
|
const canAdd2 = !!slip.onAddToSlip;
|
|
6937
|
-
const ask = (0,
|
|
6989
|
+
const ask = (0, import_react40.useMemo)(() => enabled && canAdd2 && marketKey && matchId ? {
|
|
6938
6990
|
sport,
|
|
6939
6991
|
marketKey,
|
|
6940
6992
|
matchIds: [matchId],
|
|
@@ -6946,7 +6998,7 @@ function FactPrice({ reference, ui, slip, conversation, memory: memory3, stars,
|
|
|
6946
6998
|
...anonymousUserId ? { anonymousUserId } : {}
|
|
6947
6999
|
} : null, [enabled, canAdd2, sport, marketKey, matchId, operatorUserId, anonymousUserId]);
|
|
6948
7000
|
const { grid, answeredFor, confirmed, request } = useBuilderGrid({ conversation, locale: ui.hostTag, memory: memory3, initial: ask });
|
|
6949
|
-
(0,
|
|
7001
|
+
(0, import_react40.useEffect)(() => {
|
|
6950
7002
|
if (ask) void request(ask);
|
|
6951
7003
|
}, [request, ask]);
|
|
6952
7004
|
const settled = answeredFor === ask;
|
|
@@ -7015,7 +7067,7 @@ function FavouritesInvite({ ui, sport, onOpen }) {
|
|
|
7015
7067
|
}
|
|
7016
7068
|
|
|
7017
7069
|
// src/components/dashboard/v8/useFollow.ts
|
|
7018
|
-
var
|
|
7070
|
+
var import_react41 = require("react");
|
|
7019
7071
|
|
|
7020
7072
|
// src/favouriteKinds.ts
|
|
7021
7073
|
function favouriteKinds(sport) {
|
|
@@ -7034,7 +7086,7 @@ function favouriteKindLabel(ui, sport, kind) {
|
|
|
7034
7086
|
var isFavouriteKind = (kind) => kind === "team" || kind === "player" || kind === "competition";
|
|
7035
7087
|
var keyOf2 = (sport, t) => `${sport}:${t.kind}:${t.id}`;
|
|
7036
7088
|
function useFollow(controller, ui, holds, sport) {
|
|
7037
|
-
const [notice, setNotice] = (0,
|
|
7089
|
+
const [notice, setNotice] = (0, import_react41.useState)(null);
|
|
7038
7090
|
const isOpen = (t) => isFavouriteKind(t.kind) && !holds.followed.has(keyOf2(sport, t)) && !controller.isStarred(t.kind, t.id);
|
|
7039
7091
|
const follow = async (t) => {
|
|
7040
7092
|
if (!isFavouriteKind(t.kind)) return;
|
|
@@ -7201,15 +7253,20 @@ function GuessCard({ guess, ui, controller, holds, sport, conversation, operator
|
|
|
7201
7253
|
}
|
|
7202
7254
|
|
|
7203
7255
|
// src/components/dashboard/v8/IdleTeams.tsx
|
|
7256
|
+
var import_react42 = require("react");
|
|
7204
7257
|
var import_jsx_runtime22 = require("react/jsx-runtime");
|
|
7205
|
-
function IdleTeams({ teams, ui, onAct }) {
|
|
7258
|
+
function IdleTeams({ teams, ui, onAct, slotBase }) {
|
|
7259
|
+
const events = (0, import_react42.useContext)(GreetingEventsContext);
|
|
7206
7260
|
return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(import_jsx_runtime22.Fragment, { children: teams.map((t, i) => /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("div", { className: "ss-w-v8-idle", children: [
|
|
7207
7261
|
/* @__PURE__ */ (0, import_jsx_runtime22.jsx)(Pic, { src: t.imagePath }),
|
|
7208
7262
|
/* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("div", { className: "ss-w-v8-idle-text", children: [
|
|
7209
7263
|
/* @__PURE__ */ (0, import_jsx_runtime22.jsx)("b", { children: t.label }),
|
|
7210
7264
|
/* @__PURE__ */ (0, import_jsx_runtime22.jsx)("span", { children: ui.v8NoGame })
|
|
7211
7265
|
] }),
|
|
7212
|
-
/* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("button", { type: "button", className: "ss-w-v8-idle-ask", "aria-label": `${ui.v8Ask}: ${t.label}`, onClick: () =>
|
|
7266
|
+
/* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("button", { type: "button", className: "ss-w-v8-idle-ask", "aria-label": `${ui.v8Ask}: ${t.label}`, onClick: () => {
|
|
7267
|
+
if (slotBase !== void 0) events?.cardTap(slotBase + i);
|
|
7268
|
+
onAct?.(toActionVM({ actionLabel: t.actionLabel, actionValue: t.actionValue }));
|
|
7269
|
+
}, children: [
|
|
7213
7270
|
ui.v8Ask,
|
|
7214
7271
|
" \u2192"
|
|
7215
7272
|
] })
|
|
@@ -7217,13 +7274,15 @@ function IdleTeams({ teams, ui, onAct }) {
|
|
|
7217
7274
|
}
|
|
7218
7275
|
|
|
7219
7276
|
// src/components/dashboard/v8/MatchCard.tsx
|
|
7277
|
+
var import_react43 = require("react");
|
|
7220
7278
|
var import_jsx_runtime23 = require("react/jsx-runtime");
|
|
7221
|
-
function MatchCard({ card, ui, slip, sport, marketKey, conversation, operatorUserId, anonymousUserId }) {
|
|
7279
|
+
function MatchCard({ card, ui, slip, sport, marketKey, conversation, operatorUserId, anonymousUserId, slot }) {
|
|
7280
|
+
const events = (0, import_react43.useContext)(GreetingEventsContext);
|
|
7222
7281
|
if (!teamCardHasContent(card)) return null;
|
|
7223
7282
|
const pair = !!(card.homeLabel && card.awayLabel);
|
|
7224
7283
|
const title = card.homeLabel && card.awayLabel ? `${card.homeLabel} - ${card.awayLabel}` : card.label;
|
|
7225
7284
|
const sub = [kickoffText(ui, card.startsAtUtc), card.competitionLabel].filter(Boolean).join(" \xB7 ");
|
|
7226
|
-
return /* @__PURE__ */ (0, import_jsx_runtime23.jsxs)("article", { className: "ss-w-v8-card ss-w-v8-team", children: [
|
|
7285
|
+
return /* @__PURE__ */ (0, import_jsx_runtime23.jsxs)("article", { className: "ss-w-v8-card ss-w-v8-team", onClickCapture: slot === void 0 ? void 0 : () => events?.cardTap(slot), children: [
|
|
7227
7286
|
/* @__PURE__ */ (0, import_jsx_runtime23.jsxs)("header", { className: "ss-w-v8-card-head", children: [
|
|
7228
7287
|
/* @__PURE__ */ (0, import_jsx_runtime23.jsxs)("b", { className: "ss-w-v8-card-name", children: [
|
|
7229
7288
|
pair ? /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(Pic, { src: card.homeTeamImagePath }) : /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(Pic, { src: card.imagePath }),
|
|
@@ -7395,6 +7454,7 @@ function PersonalGreeting({ personal, ui, slip, sport, starsElsewhere = false, o
|
|
|
7395
7454
|
teamCards.map((c, i) => /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
|
|
7396
7455
|
MatchCard,
|
|
7397
7456
|
{
|
|
7457
|
+
slot: i,
|
|
7398
7458
|
card: c,
|
|
7399
7459
|
ui,
|
|
7400
7460
|
slip,
|
|
@@ -7406,7 +7466,7 @@ function PersonalGreeting({ personal, ui, slip, sport, starsElsewhere = false, o
|
|
|
7406
7466
|
},
|
|
7407
7467
|
`t:${c.teamId}:${i}`
|
|
7408
7468
|
)),
|
|
7409
|
-
/* @__PURE__ */ (0, import_jsx_runtime27.jsx)(IdleTeams, { teams: idleTeams, ui, onAct }),
|
|
7469
|
+
/* @__PURE__ */ (0, import_jsx_runtime27.jsx)(IdleTeams, { teams: idleTeams, ui, onAct, slotBase: teamCards.length }),
|
|
7410
7470
|
playerCards.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("h3", { className: "ss-w-v8-sec-title", children: ui.v8YourPlayers }) : null,
|
|
7411
7471
|
playerCards.map((c, i) => /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(PlayerCard, { card: c, ui }, `p:${c.playerId}:${i}`))
|
|
7412
7472
|
] }, "cards") : null;
|
|
@@ -7488,16 +7548,28 @@ function switchSets(dashboards) {
|
|
|
7488
7548
|
function initialSport(sets, defaultSport) {
|
|
7489
7549
|
return (sets?.some((s) => s.sport === defaultSport) ? defaultSport : sets?.[0]?.sport) ?? "";
|
|
7490
7550
|
}
|
|
7491
|
-
function GreetingDashboard({ dashboard, dashboards, defaultSport, onTap, onSportChange, ui, slip, onAct }) {
|
|
7551
|
+
function GreetingDashboard({ dashboard, dashboards, defaultSport, greeting, onTap, onSportChange, ui, slip, onAct }) {
|
|
7492
7552
|
const log = useEventLog();
|
|
7493
7553
|
const { oddsFormat } = useOddsSettings();
|
|
7494
7554
|
const scope = useSportScope();
|
|
7495
7555
|
const sets = switchSets(dashboards);
|
|
7496
|
-
const [selected, setSelected] = (0,
|
|
7556
|
+
const [selected, setSelected] = (0, import_react44.useState)(() => initialSport(sets, defaultSport));
|
|
7497
7557
|
const active = sets?.find((s) => s.sport === selected) ?? null;
|
|
7498
7558
|
const shown2 = active ? active.dashboard : dashboard;
|
|
7499
7559
|
const personal = shown2.personal;
|
|
7500
7560
|
const starsElsewhere = (sets ?? []).some((s) => (s.dashboard.personal?.ribbon?.stars.length ?? 0) > 0);
|
|
7561
|
+
const meta = active ? active.greeting ?? (greeting?.sport === active.sport ? greeting : void 0) : greeting;
|
|
7562
|
+
(0, import_react44.useEffect)(() => {
|
|
7563
|
+
if (log && meta) sendGreetingOnce((e) => log.log(e), log, meta, "panel");
|
|
7564
|
+
}, [log, meta]);
|
|
7565
|
+
const events = (0, import_react44.useMemo)(() => {
|
|
7566
|
+
if (!log || !meta) return null;
|
|
7567
|
+
const send = (name, slot) => {
|
|
7568
|
+
if (!Number.isInteger(slot) || slot < 0 || slot > 19) return;
|
|
7569
|
+
log.log({ name, greeting: { greetingId: meta.greetingId, case: meta.case, sport: meta.sport, market: meta.market ?? null, slot } });
|
|
7570
|
+
};
|
|
7571
|
+
return { cardTap: (slot) => send("greeting_card_tap", slot), askTap: (slot) => send("greeting_ask_tap", slot) };
|
|
7572
|
+
}, [log, meta]);
|
|
7501
7573
|
const select = (sport) => {
|
|
7502
7574
|
if (sport === selected) return;
|
|
7503
7575
|
setSelected(sport);
|
|
@@ -7507,7 +7579,7 @@ function GreetingDashboard({ dashboard, dashboards, defaultSport, onTap, onSport
|
|
|
7507
7579
|
};
|
|
7508
7580
|
const layout = layoutClass(shown2.layout);
|
|
7509
7581
|
const badgePlacement = layout === LAYOUT_CLASSES.goal ? "end" : "meta";
|
|
7510
|
-
return /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)("div", { className: `ss-w-dash ${layout}`, children: [
|
|
7582
|
+
return /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(GreetingEventsContext.Provider, { value: events, children: /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)("div", { className: `ss-w-dash ${layout}`, children: [
|
|
7511
7583
|
sets ? /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(SportSwitch, { sports: sets, selected, onSelect: select, liveLabel: ui.liveLabel, groupLabel: ui.sportGroupLabel, tag: ui.locale }) : null,
|
|
7512
7584
|
/* @__PURE__ */ (0, import_jsx_runtime28.jsxs)("div", { className: "ss-w-dash-head", children: [
|
|
7513
7585
|
/* @__PURE__ */ (0, import_jsx_runtime28.jsx)("span", { className: "ss-w-dash-title", children: shown2.title }),
|
|
@@ -7524,37 +7596,37 @@ function GreetingDashboard({ dashboard, dashboards, defaultSport, onTap, onSport
|
|
|
7524
7596
|
`${t.title}-${i}`
|
|
7525
7597
|
)) }),
|
|
7526
7598
|
shown2.footerTip ? /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("span", { className: "ss-w-dash-foot", children: shown2.footerTip }) : null
|
|
7527
|
-
] });
|
|
7599
|
+
] }) });
|
|
7528
7600
|
}
|
|
7529
7601
|
|
|
7530
7602
|
// src/useScheduleSport.ts
|
|
7531
|
-
var
|
|
7603
|
+
var import_react45 = require("react");
|
|
7532
7604
|
function useScheduleSport(offered) {
|
|
7533
|
-
const [chosen, setChosen] = (0,
|
|
7605
|
+
const [chosen, setChosen] = (0, import_react45.useState)("all");
|
|
7534
7606
|
const sport = chosen === "all" || offered.includes(chosen) ? chosen : "all";
|
|
7535
|
-
(0,
|
|
7607
|
+
(0, import_react45.useEffect)(() => {
|
|
7536
7608
|
if (sport !== chosen) setChosen("all");
|
|
7537
7609
|
}, [sport, chosen]);
|
|
7538
|
-
const setSport = (0,
|
|
7610
|
+
const setSport = (0, import_react45.useCallback)((s) => setChosen(s), []);
|
|
7539
7611
|
return { sport, setSport, offered };
|
|
7540
7612
|
}
|
|
7541
7613
|
|
|
7542
7614
|
// src/useMatchesDay.ts
|
|
7543
|
-
var
|
|
7615
|
+
var import_react47 = require("react");
|
|
7544
7616
|
|
|
7545
7617
|
// src/useScheduleDay.ts
|
|
7546
|
-
var
|
|
7618
|
+
var import_react46 = require("react");
|
|
7547
7619
|
var EMPTY = [];
|
|
7548
7620
|
function useScheduleDay(opts) {
|
|
7549
7621
|
const { localDate, today, todayGroups, enabled, resetKey, timeZone } = opts;
|
|
7550
|
-
const getRef = (0,
|
|
7622
|
+
const getRef = (0, import_react46.useRef)(opts.getSchedule);
|
|
7551
7623
|
getRef.current = opts.getSchedule;
|
|
7552
|
-
const daysRef = (0,
|
|
7553
|
-
const [fetched, setFetched] = (0,
|
|
7554
|
-
const [retryKey, setRetryKey] = (0,
|
|
7555
|
-
const [seenDate, setSeenDate] = (0,
|
|
7556
|
-
const [seenReset, setSeenReset] = (0,
|
|
7557
|
-
const [seenZone, setSeenZone] = (0,
|
|
7624
|
+
const daysRef = (0, import_react46.useRef)(/* @__PURE__ */ new Map());
|
|
7625
|
+
const [fetched, setFetched] = (0, import_react46.useState)({ status: "idle", groups: EMPTY });
|
|
7626
|
+
const [retryKey, setRetryKey] = (0, import_react46.useState)(0);
|
|
7627
|
+
const [seenDate, setSeenDate] = (0, import_react46.useState)(localDate);
|
|
7628
|
+
const [seenReset, setSeenReset] = (0, import_react46.useState)(resetKey);
|
|
7629
|
+
const [seenZone, setSeenZone] = (0, import_react46.useState)(timeZone);
|
|
7558
7630
|
if (seenDate !== localDate) {
|
|
7559
7631
|
setSeenDate(localDate);
|
|
7560
7632
|
setFetched({ status: "idle", groups: EMPTY });
|
|
@@ -7566,7 +7638,7 @@ function useScheduleDay(opts) {
|
|
|
7566
7638
|
setFetched({ status: "idle", groups: EMPTY });
|
|
7567
7639
|
}
|
|
7568
7640
|
const isToday = localDate === today;
|
|
7569
|
-
(0,
|
|
7641
|
+
(0, import_react46.useEffect)(() => {
|
|
7570
7642
|
if (!enabled || isToday || daysRef.current.has(localDate)) return;
|
|
7571
7643
|
let cancelled = false;
|
|
7572
7644
|
setFetched({ status: "loading", groups: EMPTY });
|
|
@@ -7588,7 +7660,7 @@ function useScheduleDay(opts) {
|
|
|
7588
7660
|
cancelled = true;
|
|
7589
7661
|
};
|
|
7590
7662
|
}, [localDate, isToday, enabled, retryKey, resetKey, timeZone]);
|
|
7591
|
-
const retry = (0,
|
|
7663
|
+
const retry = (0, import_react46.useCallback)(() => {
|
|
7592
7664
|
setRetryKey((k) => k + 1);
|
|
7593
7665
|
}, []);
|
|
7594
7666
|
if (isToday) return { status: "ready", groups: todayGroups, retry };
|
|
@@ -7601,7 +7673,7 @@ function useScheduleDay(opts) {
|
|
|
7601
7673
|
// src/useMatchesDay.ts
|
|
7602
7674
|
function useMatchesDay({ discovery, day, sport, getSchedule, enabled, timeZone }) {
|
|
7603
7675
|
const { localDate: today, matchDays } = discovery;
|
|
7604
|
-
const chips = (0,
|
|
7676
|
+
const chips = (0, import_react47.useMemo)(() => buildDayChips(today, matchDays, sport), [today, matchDays, sport]);
|
|
7605
7677
|
const selected = chips.some((c) => c.date === day) ? day : today;
|
|
7606
7678
|
const loaded = useScheduleDay({
|
|
7607
7679
|
localDate: selected,
|
|
@@ -7615,8 +7687,8 @@ function useMatchesDay({ discovery, day, sport, getSchedule, enabled, timeZone }
|
|
|
7615
7687
|
return { ...loaded, chips, selected };
|
|
7616
7688
|
}
|
|
7617
7689
|
function useMatchesDayPick(today) {
|
|
7618
|
-
const [pick, setPick] = (0,
|
|
7619
|
-
const setDay = (0,
|
|
7690
|
+
const [pick, setPick] = (0, import_react47.useState)(null);
|
|
7691
|
+
const setDay = (0, import_react47.useCallback)((d) => setPick({ day: d, madeOn: today }), [today]);
|
|
7620
7692
|
return [pick !== null && pick.madeOn === today ? pick.day : today, setDay];
|
|
7621
7693
|
}
|
|
7622
7694
|
|
|
@@ -7703,15 +7775,19 @@ var WIRE_TO_PUBLIC = {
|
|
|
7703
7775
|
match_view: null,
|
|
7704
7776
|
popup_opened: null,
|
|
7705
7777
|
fact_view: null,
|
|
7706
|
-
fact_ask: null
|
|
7778
|
+
fact_ask: null,
|
|
7779
|
+
greeting_shown: null,
|
|
7780
|
+
greeting_cta_click: null,
|
|
7781
|
+
greeting_card_tap: null,
|
|
7782
|
+
greeting_ask_tap: null
|
|
7707
7783
|
};
|
|
7708
7784
|
|
|
7709
7785
|
// src/popupTelemetry.ts
|
|
7710
|
-
var
|
|
7786
|
+
var import_react48 = require("react");
|
|
7711
7787
|
function usePopupTelemetry(log, isOpen, popupText, dismissPopup, confirmedShown) {
|
|
7712
|
-
const shownRef = (0,
|
|
7713
|
-
const closedTextRef = (0,
|
|
7714
|
-
(0,
|
|
7788
|
+
const shownRef = (0, import_react48.useRef)(/* @__PURE__ */ new Set());
|
|
7789
|
+
const closedTextRef = (0, import_react48.useRef)(null);
|
|
7790
|
+
(0, import_react48.useEffect)(() => {
|
|
7715
7791
|
if (isOpen) {
|
|
7716
7792
|
if (closedTextRef.current) log?.log({ name: "popup_opened" });
|
|
7717
7793
|
closedTextRef.current = null;
|
|
@@ -7724,26 +7800,26 @@ function usePopupTelemetry(log, isOpen, popupText, dismissPopup, confirmedShown)
|
|
|
7724
7800
|
log?.log({ name: "popup_shown" });
|
|
7725
7801
|
}
|
|
7726
7802
|
}, [log, isOpen, popupText, confirmedShown]);
|
|
7727
|
-
return (0,
|
|
7803
|
+
return (0, import_react48.useCallback)(() => {
|
|
7728
7804
|
log?.log({ name: "popup_dismissed" });
|
|
7729
7805
|
dismissPopup();
|
|
7730
7806
|
}, [log, dismissPopup]);
|
|
7731
7807
|
}
|
|
7732
7808
|
|
|
7733
7809
|
// src/mobileBinding.ts
|
|
7734
|
-
var
|
|
7810
|
+
var import_react49 = require("react");
|
|
7735
7811
|
var CLEARED = { text: null, asks: [] };
|
|
7736
7812
|
function useMobileBinding(args) {
|
|
7737
7813
|
const { binding, panelOpen, popupText, asks } = args;
|
|
7738
|
-
const latest = (0,
|
|
7814
|
+
const latest = (0, import_react49.useRef)(args);
|
|
7739
7815
|
latest.current = args;
|
|
7740
|
-
const bindingRef = (0,
|
|
7816
|
+
const bindingRef = (0, import_react49.useRef)(binding);
|
|
7741
7817
|
bindingRef.current = binding;
|
|
7742
|
-
const backRef = (0,
|
|
7743
|
-
const [confirmedShown, setConfirmedShown] = (0,
|
|
7818
|
+
const backRef = (0, import_react49.useRef)(null);
|
|
7819
|
+
const [confirmedShown, setConfirmedShown] = (0, import_react49.useState)(null);
|
|
7744
7820
|
const teaserKey = panelOpen || !popupText ? "" : JSON.stringify([popupText, asks.map((a) => a.label)]);
|
|
7745
|
-
const reported = (0,
|
|
7746
|
-
(0,
|
|
7821
|
+
const reported = (0, import_react49.useRef)({ binding: void 0, key: "" });
|
|
7822
|
+
(0, import_react49.useEffect)(() => {
|
|
7747
7823
|
if (!binding) return;
|
|
7748
7824
|
const prev = reported.current;
|
|
7749
7825
|
if (prev.binding === binding && prev.key === teaserKey) return;
|
|
@@ -7751,7 +7827,7 @@ function useMobileBinding(args) {
|
|
|
7751
7827
|
if (teaserKey === "" && prev.binding !== binding) return;
|
|
7752
7828
|
binding.onTeaser(teaserKey === "" ? CLEARED : { text: popupText, asks: asks.map((a, index) => ({ index, label: a.label })) });
|
|
7753
7829
|
}, [binding, teaserKey]);
|
|
7754
|
-
(0,
|
|
7830
|
+
(0, import_react49.useEffect)(() => {
|
|
7755
7831
|
if (!binding) return;
|
|
7756
7832
|
binding.onHandle({
|
|
7757
7833
|
open: () => latest.current.open(),
|
|
@@ -7768,8 +7844,8 @@ function useMobileBinding(args) {
|
|
|
7768
7844
|
});
|
|
7769
7845
|
return () => binding.onHandle(null);
|
|
7770
7846
|
}, [binding]);
|
|
7771
|
-
const onCloseRequested = (0,
|
|
7772
|
-
const onRegisterBack = (0,
|
|
7847
|
+
const onCloseRequested = (0, import_react49.useCallback)(() => bindingRef.current?.onCloseRequested(), []);
|
|
7848
|
+
const onRegisterBack = (0, import_react49.useCallback)((fn) => {
|
|
7773
7849
|
backRef.current = fn;
|
|
7774
7850
|
}, []);
|
|
7775
7851
|
if (!binding) return { confirmedShown: void 0, onCloseRequested: void 0, onRegisterBack: void 0 };
|
|
@@ -7777,10 +7853,10 @@ function useMobileBinding(args) {
|
|
|
7777
7853
|
}
|
|
7778
7854
|
|
|
7779
7855
|
// src/openTelemetry.ts
|
|
7780
|
-
var
|
|
7856
|
+
var import_react50 = require("react");
|
|
7781
7857
|
function useOpenTelemetry(log, isOpen) {
|
|
7782
|
-
const openLoggedRef = (0,
|
|
7783
|
-
(0,
|
|
7858
|
+
const openLoggedRef = (0, import_react50.useRef)(false);
|
|
7859
|
+
(0, import_react50.useEffect)(() => {
|
|
7784
7860
|
if (!isOpen) {
|
|
7785
7861
|
openLoggedRef.current = false;
|
|
7786
7862
|
return;
|
|
@@ -7792,13 +7868,13 @@ function useOpenTelemetry(log, isOpen) {
|
|
|
7792
7868
|
}
|
|
7793
7869
|
|
|
7794
7870
|
// src/components/ChatFab.tsx
|
|
7795
|
-
var
|
|
7871
|
+
var import_react52 = require("react");
|
|
7796
7872
|
|
|
7797
7873
|
// src/components/BrandMark.tsx
|
|
7798
|
-
var
|
|
7874
|
+
var import_react51 = require("react");
|
|
7799
7875
|
var import_jsx_runtime29 = require("react/jsx-runtime");
|
|
7800
7876
|
function BrandMark({ logoUrl, className }) {
|
|
7801
|
-
const [failed, setFailed] = (0,
|
|
7877
|
+
const [failed, setFailed] = (0, import_react51.useState)(false);
|
|
7802
7878
|
if (!logoUrl || failed) return /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(SsMark, { className });
|
|
7803
7879
|
return /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("img", { className, src: logoUrl, alt: "", "aria-hidden": "true", onError: () => setFailed(true) });
|
|
7804
7880
|
}
|
|
@@ -7832,13 +7908,13 @@ function GreetingBubble({ text: text2, onOpen, onDismiss, dismissLabel, asks })
|
|
|
7832
7908
|
|
|
7833
7909
|
// src/components/ChatFab.tsx
|
|
7834
7910
|
var import_jsx_runtime31 = require("react/jsx-runtime");
|
|
7835
|
-
function ChatFab({ label, busy = false, greeting, popupText, logoUrl, onOpen, onDismissPopup, dismissLabel, introAllowed = false, onIntroStart, asks }) {
|
|
7911
|
+
function ChatFab({ label, busy = false, greeting, popupText, logoUrl, onOpen, onDismissPopup, dismissLabel, introAllowed = false, onIntroStart, asks, onBubbleClick }) {
|
|
7836
7912
|
const bubble = popupText ?? greeting;
|
|
7837
7913
|
const hidden = busy && !label;
|
|
7838
7914
|
const track = useTrack();
|
|
7839
|
-
const [intro, setIntro] = (0,
|
|
7840
|
-
const armedRef = (0,
|
|
7841
|
-
(0,
|
|
7915
|
+
const [intro, setIntro] = (0, import_react52.useState)(false);
|
|
7916
|
+
const armedRef = (0, import_react52.useRef)(introAllowed);
|
|
7917
|
+
(0, import_react52.useEffect)(() => {
|
|
7842
7918
|
if (armedRef.current && bubble) {
|
|
7843
7919
|
armedRef.current = false;
|
|
7844
7920
|
setIntro(true);
|
|
@@ -7848,6 +7924,7 @@ function ChatFab({ label, busy = false, greeting, popupText, logoUrl, onOpen, on
|
|
|
7848
7924
|
return /* @__PURE__ */ (0, import_jsx_runtime31.jsxs)("div", { className: intro ? "ss-w-fab-wrap ss-w-intro" : "ss-w-fab-wrap", children: [
|
|
7849
7925
|
bubble ? /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(GreetingBubble, { text: bubble, onOpen: () => {
|
|
7850
7926
|
track({ name: "bubble_click" });
|
|
7927
|
+
if (popupText) onBubbleClick?.();
|
|
7851
7928
|
onOpen();
|
|
7852
7929
|
}, onDismiss: popupText ? onDismissPopup : void 0, dismissLabel, asks: popupText ? asks : void 0 }) : null,
|
|
7853
7930
|
/* @__PURE__ */ (0, import_jsx_runtime31.jsx)("button", { type: "button", className: "ss-w-fab", "aria-label": label, "aria-busy": busy || void 0, "aria-hidden": hidden || void 0, tabIndex: hidden ? -1 : void 0, onClick: () => {
|
|
@@ -7858,10 +7935,10 @@ function ChatFab({ label, busy = false, greeting, popupText, logoUrl, onOpen, on
|
|
|
7858
7935
|
}
|
|
7859
7936
|
|
|
7860
7937
|
// src/components/ChatPanel.tsx
|
|
7861
|
-
var
|
|
7938
|
+
var import_react111 = require("react");
|
|
7862
7939
|
|
|
7863
7940
|
// src/components/ChatHeader.tsx
|
|
7864
|
-
var
|
|
7941
|
+
var import_react53 = require("react");
|
|
7865
7942
|
var import_jsx_runtime32 = require("react/jsx-runtime");
|
|
7866
7943
|
function ChatHeader({
|
|
7867
7944
|
onClose,
|
|
@@ -7877,18 +7954,18 @@ function ChatHeader({
|
|
|
7877
7954
|
onOpenFavourites,
|
|
7878
7955
|
favouritesLabel
|
|
7879
7956
|
}) {
|
|
7880
|
-
const [menuOpen, setMenuOpen] = (0,
|
|
7881
|
-
const wrapRef = (0,
|
|
7882
|
-
const kebabRef = (0,
|
|
7883
|
-
const firstItemRef = (0,
|
|
7957
|
+
const [menuOpen, setMenuOpen] = (0, import_react53.useState)(false);
|
|
7958
|
+
const wrapRef = (0, import_react53.useRef)(null);
|
|
7959
|
+
const kebabRef = (0, import_react53.useRef)(null);
|
|
7960
|
+
const firstItemRef = (0, import_react53.useRef)(null);
|
|
7884
7961
|
const hasNew = !!(canReset && onNewConversation);
|
|
7885
7962
|
const hasSettings = !!onOpenSettings;
|
|
7886
7963
|
const hasFavourites = !!onOpenFavourites;
|
|
7887
7964
|
const hasMenu = hasFavourites || hasNew || hasSettings;
|
|
7888
|
-
(0,
|
|
7965
|
+
(0, import_react53.useEffect)(() => {
|
|
7889
7966
|
if (menuOpen) firstItemRef.current?.focus();
|
|
7890
7967
|
}, [menuOpen]);
|
|
7891
|
-
(0,
|
|
7968
|
+
(0, import_react53.useEffect)(() => {
|
|
7892
7969
|
if (!menuOpen) return;
|
|
7893
7970
|
const onPointer = (e) => {
|
|
7894
7971
|
if (!(wrapRef.current && e.composedPath().includes(wrapRef.current))) setMenuOpen(false);
|
|
@@ -7976,10 +8053,10 @@ function ChatHeader({
|
|
|
7976
8053
|
}
|
|
7977
8054
|
|
|
7978
8055
|
// src/components/MessageList.tsx
|
|
7979
|
-
var
|
|
8056
|
+
var import_react67 = require("react");
|
|
7980
8057
|
|
|
7981
8058
|
// src/components/ChatMessage.tsx
|
|
7982
|
-
var
|
|
8059
|
+
var import_react66 = require("react");
|
|
7983
8060
|
|
|
7984
8061
|
// src/components/Markdown.tsx
|
|
7985
8062
|
var import_react_markdown = __toESM(require("react-markdown"), 1);
|
|
@@ -7997,7 +8074,7 @@ function Markdown({ text: text2 }) {
|
|
|
7997
8074
|
}
|
|
7998
8075
|
|
|
7999
8076
|
// src/components/EntityCardList.tsx
|
|
8000
|
-
var
|
|
8077
|
+
var import_react54 = require("react");
|
|
8001
8078
|
var import_jsx_runtime34 = require("react/jsx-runtime");
|
|
8002
8079
|
var MAX_VISIBLE = 3;
|
|
8003
8080
|
var RECORD_RE = /^(\d+)-(\d+)-(\d+)$/;
|
|
@@ -8100,7 +8177,7 @@ function ScopeTabs({ scopes, active, onSelect }) {
|
|
|
8100
8177
|
)) });
|
|
8101
8178
|
}
|
|
8102
8179
|
function EntityCardItem({ c }) {
|
|
8103
|
-
const [active, setActive] = (0,
|
|
8180
|
+
const [active, setActive] = (0, import_react54.useState)(0);
|
|
8104
8181
|
const hasBody = c.scopes.length > 0;
|
|
8105
8182
|
if (!hasBody) {
|
|
8106
8183
|
return /* @__PURE__ */ (0, import_jsx_runtime34.jsx)("div", { className: "ss-w-ecard ss-w-ecard-bare", "data-kind": c.kind, children: /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(CardHeader, { c, showScopeCrest: false }) });
|
|
@@ -8115,7 +8192,7 @@ function EntityCardItem({ c }) {
|
|
|
8115
8192
|
] });
|
|
8116
8193
|
}
|
|
8117
8194
|
function EntityCardList({ cards, disabled, showLessLabel, showMoreLabel }) {
|
|
8118
|
-
const [expanded, setExpanded] = (0,
|
|
8195
|
+
const [expanded, setExpanded] = (0, import_react54.useState)(false);
|
|
8119
8196
|
if (cards.length === 0) return null;
|
|
8120
8197
|
const visible = expanded ? cards : cards.slice(0, MAX_VISIBLE);
|
|
8121
8198
|
const overflow = cards.length - MAX_VISIBLE;
|
|
@@ -8216,17 +8293,17 @@ function BettingInsightList({ insights, ui, slip, monitor }) {
|
|
|
8216
8293
|
}
|
|
8217
8294
|
|
|
8218
8295
|
// src/components/AddAllToSlipButton.tsx
|
|
8219
|
-
var
|
|
8296
|
+
var import_react55 = require("react");
|
|
8220
8297
|
var import_jsx_runtime36 = require("react/jsx-runtime");
|
|
8221
8298
|
function AddAllToSlipButton({ legs, slip, ui, labels, combo, chatCombo, sizeless, hold, onStartedGame }) {
|
|
8222
8299
|
const add = useSlipAdd(slip, ui);
|
|
8223
8300
|
const slipState = useSlipState();
|
|
8224
8301
|
const log = useEventLog();
|
|
8225
8302
|
const track = useTrack();
|
|
8226
|
-
const [pending, setPending] = (0,
|
|
8227
|
-
const [settledLocal, setSettledLocal] = (0,
|
|
8228
|
-
const [toast, setToast] = (0,
|
|
8229
|
-
const dismiss = (0,
|
|
8303
|
+
const [pending, setPending] = (0, import_react55.useState)(false);
|
|
8304
|
+
const [settledLocal, setSettledLocal] = (0, import_react55.useState)({});
|
|
8305
|
+
const [toast, setToast] = (0, import_react55.useState)(null);
|
|
8306
|
+
const dismiss = (0, import_react55.useCallback)(() => setToast(null), []);
|
|
8230
8307
|
if (!slip.onAddToSlip || legs.length < 2) return null;
|
|
8231
8308
|
const settled = slipState ? slipState.settled : settledLocal;
|
|
8232
8309
|
const open = legs.filter((leg) => !settled[slipKey(leg)]);
|
|
@@ -8299,10 +8376,10 @@ function AddAllToSlipButton({ legs, slip, ui, labels, combo, chatCombo, sizeless
|
|
|
8299
8376
|
}
|
|
8300
8377
|
|
|
8301
8378
|
// src/presetToolsContext.ts
|
|
8302
|
-
var
|
|
8303
|
-
var PresetToolsContext = (0,
|
|
8379
|
+
var import_react56 = require("react");
|
|
8380
|
+
var PresetToolsContext = (0, import_react56.createContext)(null);
|
|
8304
8381
|
function usePresetTools() {
|
|
8305
|
-
return (0,
|
|
8382
|
+
return (0, import_react56.useContext)(PresetToolsContext);
|
|
8306
8383
|
}
|
|
8307
8384
|
|
|
8308
8385
|
// src/components/ComboCardList.tsx
|
|
@@ -8928,7 +9005,7 @@ function NbaInsightList({ insights, ui, slip, monitor }) {
|
|
|
8928
9005
|
}
|
|
8929
9006
|
|
|
8930
9007
|
// src/components/NflInsightList.tsx
|
|
8931
|
-
var
|
|
9008
|
+
var import_react57 = require("react");
|
|
8932
9009
|
|
|
8933
9010
|
// src/strings/types.ts
|
|
8934
9011
|
var fillNfl = (template, values) => template.replace(/\{(\w+)\}/g, (whole, key) => key in values ? String(values[key]) : whole);
|
|
@@ -8939,7 +9016,7 @@ var oneDecimal2 = (n, ui) => formatNumber(n, ui.locale, { minimumFractionDigits:
|
|
|
8939
9016
|
var cap = (text2, ui) => text2 ? upperCase(text2.charAt(0), ui.locale) + text2.slice(1) : text2;
|
|
8940
9017
|
var lineNumber = (line) => Number(line.replace("\u2212", "-").replace(",", "."));
|
|
8941
9018
|
function Badge({ abbr, url }) {
|
|
8942
|
-
const [failed, setFailed] = (0,
|
|
9019
|
+
const [failed, setFailed] = (0, import_react57.useState)(false);
|
|
8943
9020
|
if (url && !failed) {
|
|
8944
9021
|
return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("img", { className: "ss-w-nfl-badge ss-w-nfl-badge--img", src: url, alt: "", "aria-hidden": "true", onError: () => setFailed(true) });
|
|
8945
9022
|
}
|
|
@@ -9550,7 +9627,7 @@ function TennisInsightList({ insights, ui }) {
|
|
|
9550
9627
|
}
|
|
9551
9628
|
|
|
9552
9629
|
// src/components/CompactOddsList.tsx
|
|
9553
|
-
var
|
|
9630
|
+
var import_react58 = require("react");
|
|
9554
9631
|
var import_widget_sdk23 = require("@sensiblestats/widget-sdk");
|
|
9555
9632
|
|
|
9556
9633
|
// src/compactList.ts
|
|
@@ -9672,11 +9749,11 @@ function Row({ row, columns, ui, slip, monitor, rowRef }) {
|
|
|
9672
9749
|
] });
|
|
9673
9750
|
}
|
|
9674
9751
|
function CompactOddsList({ list, ui, slip, monitor }) {
|
|
9675
|
-
const [shown2, setShown] = (0,
|
|
9752
|
+
const [shown2, setShown] = (0, import_react58.useState)(COMPACT_PAGE);
|
|
9676
9753
|
const hidden = list.rowCount - shown2;
|
|
9677
|
-
const [focusIndex, setFocusIndex] = (0,
|
|
9678
|
-
const focusRef = (0,
|
|
9679
|
-
(0,
|
|
9754
|
+
const [focusIndex, setFocusIndex] = (0, import_react58.useState)(null);
|
|
9755
|
+
const focusRef = (0, import_react58.useRef)(null);
|
|
9756
|
+
(0, import_react58.useEffect)(() => {
|
|
9680
9757
|
if (focusIndex !== null) focusRef.current?.focus();
|
|
9681
9758
|
}, [focusIndex]);
|
|
9682
9759
|
let left = shown2;
|
|
@@ -9911,7 +9988,7 @@ function FixtureCard({ card, ui }) {
|
|
|
9911
9988
|
}
|
|
9912
9989
|
|
|
9913
9990
|
// src/components/dashboard/CountdownCard.tsx
|
|
9914
|
-
var
|
|
9991
|
+
var import_react59 = require("react");
|
|
9915
9992
|
var import_jsx_runtime45 = require("react/jsx-runtime");
|
|
9916
9993
|
var DAY_MS3 = 864e5;
|
|
9917
9994
|
function remainingSegments(kickoffUnix, nowMs, withSeconds) {
|
|
@@ -9930,12 +10007,12 @@ function remainingSegments(kickoffUnix, nowMs, withSeconds) {
|
|
|
9930
10007
|
function CountdownCard({ card, ui }) {
|
|
9931
10008
|
const { data } = card;
|
|
9932
10009
|
const unitLabel = { d: data.daysUnit, h: data.hoursUnit, m: data.minutesUnit, s: data.secondsUnit };
|
|
9933
|
-
const [nowMs, setNowMs] = (0,
|
|
9934
|
-
const [reduced] = (0,
|
|
10010
|
+
const [nowMs, setNowMs] = (0, import_react59.useState)(() => Date.now());
|
|
10011
|
+
const [reduced] = (0, import_react59.useState)(
|
|
9935
10012
|
() => typeof window !== "undefined" && window.matchMedia("(prefers-reduced-motion: reduce)").matches
|
|
9936
10013
|
);
|
|
9937
10014
|
const withinDay = data.kickoffUnix * 1e3 - nowMs < DAY_MS3;
|
|
9938
|
-
(0,
|
|
10015
|
+
(0, import_react59.useEffect)(() => {
|
|
9939
10016
|
if (reduced) return;
|
|
9940
10017
|
const id = window.setInterval(() => setNowMs(Date.now()), withinDay ? 1e3 : 6e4);
|
|
9941
10018
|
return () => window.clearInterval(id);
|
|
@@ -9943,7 +10020,7 @@ function CountdownCard({ card, ui }) {
|
|
|
9943
10020
|
const segments = remainingSegments(data.kickoffUnix, nowMs, withinDay && !reduced);
|
|
9944
10021
|
return /* @__PURE__ */ (0, import_jsx_runtime45.jsx)("div", { className: "ss-w-fandash-card ss-w-fandash-countdown", children: /* @__PURE__ */ (0, import_jsx_runtime45.jsxs)("div", { className: "ss-w-fandash-countdown-top", children: [
|
|
9945
10022
|
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)("span", { className: "ss-w-fandash-eyebrow", children: card.title ?? ui.countdownTitle }),
|
|
9946
|
-
segments ? /* @__PURE__ */ (0, import_jsx_runtime45.jsx)("span", { className: "ss-w-fandash-countdown-clock", children: segments.map((s, i) => /* @__PURE__ */ (0, import_jsx_runtime45.jsxs)(
|
|
10023
|
+
segments ? /* @__PURE__ */ (0, import_jsx_runtime45.jsx)("span", { className: "ss-w-fandash-countdown-clock", children: segments.map((s, i) => /* @__PURE__ */ (0, import_jsx_runtime45.jsxs)(import_react59.Fragment, { children: [
|
|
9947
10024
|
i > 0 ? /* @__PURE__ */ (0, import_jsx_runtime45.jsx)("span", { className: "ss-w-fandash-countdown-colon", children: ":" }) : null,
|
|
9948
10025
|
/* @__PURE__ */ (0, import_jsx_runtime45.jsxs)("span", { className: "ss-w-fandash-countdown-seg", children: [
|
|
9949
10026
|
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)("span", { className: "ss-w-fandash-countdown-value", children: s.value }),
|
|
@@ -9954,7 +10031,7 @@ function CountdownCard({ card, ui }) {
|
|
|
9954
10031
|
}
|
|
9955
10032
|
|
|
9956
10033
|
// src/components/dashboard/InjuriesCard.tsx
|
|
9957
|
-
var
|
|
10034
|
+
var import_react60 = require("react");
|
|
9958
10035
|
var import_jsx_runtime46 = require("react/jsx-runtime");
|
|
9959
10036
|
var SHOWN = 3;
|
|
9960
10037
|
function ColHead({ name, crestUrl }) {
|
|
@@ -9977,7 +10054,7 @@ function InjuryList({ rows, emptyLabel, limit }) {
|
|
|
9977
10054
|
}
|
|
9978
10055
|
function InjuriesCard({ card, ui }) {
|
|
9979
10056
|
const { data } = card;
|
|
9980
|
-
const [expanded, setExpanded] = (0,
|
|
10057
|
+
const [expanded, setExpanded] = (0, import_react60.useState)(false);
|
|
9981
10058
|
const hidden = Math.max(0, data.ours.length - SHOWN) + Math.max(0, data.theirs.length - SHOWN);
|
|
9982
10059
|
const limit = expanded ? void 0 : SHOWN;
|
|
9983
10060
|
const { showMore, showLess } = ui;
|
|
@@ -10082,7 +10159,7 @@ function LinksCard({ card }) {
|
|
|
10082
10159
|
}
|
|
10083
10160
|
|
|
10084
10161
|
// src/components/dashboard/PostMatchResultCard.tsx
|
|
10085
|
-
var
|
|
10162
|
+
var import_react61 = require("react");
|
|
10086
10163
|
var import_jsx_runtime52 = require("react/jsx-runtime");
|
|
10087
10164
|
function initials3(name) {
|
|
10088
10165
|
return name.trim().slice(0, 3).toUpperCase();
|
|
@@ -10092,7 +10169,7 @@ function PostMatchCrest({
|
|
|
10092
10169
|
name,
|
|
10093
10170
|
side
|
|
10094
10171
|
}) {
|
|
10095
|
-
const [failed, setFailed] = (0,
|
|
10172
|
+
const [failed, setFailed] = (0, import_react61.useState)(false);
|
|
10096
10173
|
const cls = `ss-w-fandash-postmatch-crest ss-w-fandash-postmatch-crest--${side}`;
|
|
10097
10174
|
if (url && !failed) {
|
|
10098
10175
|
return /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("img", { className: cls, src: url, alt: "", "aria-hidden": "true", onError: () => setFailed(true) });
|
|
@@ -10291,10 +10368,10 @@ function RestingFormCard({ card }) {
|
|
|
10291
10368
|
}
|
|
10292
10369
|
|
|
10293
10370
|
// src/components/dashboard/LiveScoreCard.tsx
|
|
10294
|
-
var
|
|
10371
|
+
var import_react63 = require("react");
|
|
10295
10372
|
|
|
10296
10373
|
// src/useLiveClock.ts
|
|
10297
|
-
var
|
|
10374
|
+
var import_react62 = require("react");
|
|
10298
10375
|
var TICK_MS = 6e4;
|
|
10299
10376
|
var MAX_LIVE_TICK_MINUTES = 15;
|
|
10300
10377
|
function computeDisplayMinute(minute, clockRunning, receivedAtMs) {
|
|
@@ -10303,10 +10380,10 @@ function computeDisplayMinute(minute, clockRunning, receivedAtMs) {
|
|
|
10303
10380
|
return minute + Math.min(Math.max(0, elapsedMinutes), MAX_LIVE_TICK_MINUTES);
|
|
10304
10381
|
}
|
|
10305
10382
|
function useLiveClock(minute, clockRunning, receivedAtMs) {
|
|
10306
|
-
const [displayMinute, setDisplayMinute] = (0,
|
|
10383
|
+
const [displayMinute, setDisplayMinute] = (0, import_react62.useState)(
|
|
10307
10384
|
() => computeDisplayMinute(minute, clockRunning, receivedAtMs)
|
|
10308
10385
|
);
|
|
10309
|
-
(0,
|
|
10386
|
+
(0, import_react62.useEffect)(() => {
|
|
10310
10387
|
setDisplayMinute(computeDisplayMinute(minute, clockRunning, receivedAtMs));
|
|
10311
10388
|
if (!clockRunning) return;
|
|
10312
10389
|
const id = window.setInterval(() => {
|
|
@@ -10323,7 +10400,7 @@ function initials5(name) {
|
|
|
10323
10400
|
return name.trim().slice(0, 3).toUpperCase();
|
|
10324
10401
|
}
|
|
10325
10402
|
function LiveCrest({ url, name, side }) {
|
|
10326
|
-
const [failed, setFailed] = (0,
|
|
10403
|
+
const [failed, setFailed] = (0, import_react63.useState)(false);
|
|
10327
10404
|
const cls = `ss-w-fandash-live-crest ss-w-fandash-live-crest--${side}`;
|
|
10328
10405
|
if (url && !failed) {
|
|
10329
10406
|
return /* @__PURE__ */ (0, import_jsx_runtime61.jsx)("img", { className: cls, src: url, alt: "", "aria-hidden": "true", onError: () => setFailed(true) });
|
|
@@ -10345,7 +10422,7 @@ function LiveScoreCard({
|
|
|
10345
10422
|
}) {
|
|
10346
10423
|
const { data } = card;
|
|
10347
10424
|
const seedKey = `${data.minute}:${data.homeScore}:${data.awayScore}`;
|
|
10348
|
-
const seedRef = (0,
|
|
10425
|
+
const seedRef = (0, import_react63.useRef)(null);
|
|
10349
10426
|
if (!seedRef.current || seedRef.current.key !== seedKey) {
|
|
10350
10427
|
seedRef.current = { key: seedKey, receivedAtMs: Date.now() };
|
|
10351
10428
|
}
|
|
@@ -10391,7 +10468,7 @@ function LiveScoreCard({
|
|
|
10391
10468
|
}
|
|
10392
10469
|
|
|
10393
10470
|
// src/components/dashboard/LiveTimelineCard.tsx
|
|
10394
|
-
var
|
|
10471
|
+
var import_react64 = require("react");
|
|
10395
10472
|
var import_jsx_runtime62 = require("react/jsx-runtime");
|
|
10396
10473
|
var SHOWN2 = 3;
|
|
10397
10474
|
function EventIcon({ type }) {
|
|
@@ -10433,7 +10510,7 @@ function EventRow({ e }) {
|
|
|
10433
10510
|
] });
|
|
10434
10511
|
}
|
|
10435
10512
|
function LiveTimelineCard({ card, ui }) {
|
|
10436
|
-
const [expanded, setExpanded] = (0,
|
|
10513
|
+
const [expanded, setExpanded] = (0, import_react64.useState)(false);
|
|
10437
10514
|
const events = card.data.events;
|
|
10438
10515
|
if (!events || events.length === 0) return null;
|
|
10439
10516
|
const sorted = [...events].sort((a, b) => b.minute - a.minute);
|
|
@@ -10457,7 +10534,7 @@ function LiveTimelineCard({ card, ui }) {
|
|
|
10457
10534
|
}
|
|
10458
10535
|
|
|
10459
10536
|
// src/components/dashboard/MomentumWave.tsx
|
|
10460
|
-
var
|
|
10537
|
+
var import_react65 = require("react");
|
|
10461
10538
|
var import_jsx_runtime63 = require("react/jsx-runtime");
|
|
10462
10539
|
var WIDTH = 270;
|
|
10463
10540
|
var HEIGHT = 56;
|
|
@@ -10482,7 +10559,7 @@ function MomentumWave({
|
|
|
10482
10559
|
}) {
|
|
10483
10560
|
if (points.length === 0) return null;
|
|
10484
10561
|
const { area, line, lastLeftPct, lastTopPx } = buildPaths(points);
|
|
10485
|
-
const clipId = (0,
|
|
10562
|
+
const clipId = (0, import_react65.useId)();
|
|
10486
10563
|
const topClipId = `${clipId}-top`;
|
|
10487
10564
|
const bottomClipId = `${clipId}-bottom`;
|
|
10488
10565
|
const topClass = clubIsHome ? "ss-w-fandash-live-mom-home" : "ss-w-fandash-live-mom-away";
|
|
@@ -10632,7 +10709,7 @@ function FanDashboardCard({ card, onTap, ui, goalEvents }) {
|
|
|
10632
10709
|
// src/components/ChatMessage.tsx
|
|
10633
10710
|
var import_jsx_runtime66 = require("react/jsx-runtime");
|
|
10634
10711
|
function ChatMessage({ message, disabled, onAct, onTap, ui, slip, monitor, onGreetingSport }) {
|
|
10635
|
-
const [sport, setSport] = (0,
|
|
10712
|
+
const [sport, setSport] = (0, import_react66.useState)(null);
|
|
10636
10713
|
if (message.role === "user") {
|
|
10637
10714
|
return /* @__PURE__ */ (0, import_jsx_runtime66.jsx)("div", { className: "ss-w-msg ss-w-user", "data-msg-id": message.id, children: /* @__PURE__ */ (0, import_jsx_runtime66.jsx)("div", { className: "ss-w-bubble", children: message.text }) });
|
|
10638
10715
|
}
|
|
@@ -10645,7 +10722,7 @@ function ChatMessage({ message, disabled, onAct, onTap, ui, slip, monitor, onGre
|
|
|
10645
10722
|
const actions = setChips ? setChips.map((c) => toActionVM({ ...c })) : message.actions;
|
|
10646
10723
|
return /* @__PURE__ */ (0, import_jsx_runtime66.jsxs)("div", { className: "ss-w-msg ss-w-bot", "data-msg-id": message.id, children: [
|
|
10647
10724
|
message.text && !message.greetingDashboard && !message.clubFanDashboard ? /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(Markdown, { text: message.text }) : null,
|
|
10648
|
-
message.greetingDashboard && !message.clubFanDashboard ? /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(GreetingDashboard, { dashboard: message.greetingDashboard, dashboards: message.greetingDashboards, defaultSport: message.defaultSport, onTap, onSportChange: (s) => {
|
|
10725
|
+
message.greetingDashboard && !message.clubFanDashboard ? /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(GreetingDashboard, { dashboard: message.greetingDashboard, dashboards: message.greetingDashboards, defaultSport: message.defaultSport, greeting: message.greeting, onTap, onSportChange: (s) => {
|
|
10649
10726
|
setSport(s);
|
|
10650
10727
|
onGreetingSport?.(s);
|
|
10651
10728
|
}, ui, slip, onAct }) : null,
|
|
@@ -10686,11 +10763,11 @@ function turnAnchor(messages) {
|
|
|
10686
10763
|
function MessageList({ controller, ui, slip, onDashboardTap, monitor, onGreetingSport }) {
|
|
10687
10764
|
const { state, send } = controller;
|
|
10688
10765
|
const { oddsFormat } = useOddsSettings();
|
|
10689
|
-
const listRef = (0,
|
|
10690
|
-
const endRef = (0,
|
|
10691
|
-
const pinnedRef = (0,
|
|
10692
|
-
const anchoredTurnRef = (0,
|
|
10693
|
-
(0,
|
|
10766
|
+
const listRef = (0, import_react67.useRef)(null);
|
|
10767
|
+
const endRef = (0, import_react67.useRef)(null);
|
|
10768
|
+
const pinnedRef = (0, import_react67.useRef)(true);
|
|
10769
|
+
const anchoredTurnRef = (0, import_react67.useRef)(null);
|
|
10770
|
+
(0, import_react67.useEffect)(() => {
|
|
10694
10771
|
const anchor = turnAnchor(state.messages);
|
|
10695
10772
|
const list = listRef.current;
|
|
10696
10773
|
if (anchor && anchor.turnId !== anchoredTurnRef.current) {
|
|
@@ -10749,13 +10826,13 @@ function MessageList({ controller, ui, slip, onDashboardTap, monitor, onGreeting
|
|
|
10749
10826
|
}
|
|
10750
10827
|
|
|
10751
10828
|
// src/components/ChatInput.tsx
|
|
10752
|
-
var
|
|
10829
|
+
var import_react68 = require("react");
|
|
10753
10830
|
var import_jsx_runtime69 = require("react/jsx-runtime");
|
|
10754
|
-
var ChatInput = (0,
|
|
10755
|
-
const [value, setValue] = (0,
|
|
10756
|
-
const textareaRef = (0,
|
|
10757
|
-
const stopRef = (0,
|
|
10758
|
-
const textBoxWantsFocusRef = (0,
|
|
10831
|
+
var ChatInput = (0, import_react68.forwardRef)(function ChatInput2({ placeholder, streaming, onSend, onStop, stopLabel, sendLabel, disabled = false }, ref) {
|
|
10832
|
+
const [value, setValue] = (0, import_react68.useState)("");
|
|
10833
|
+
const textareaRef = (0, import_react68.useRef)(null);
|
|
10834
|
+
const stopRef = (0, import_react68.useRef)(null);
|
|
10835
|
+
const textBoxWantsFocusRef = (0, import_react68.useRef)(false);
|
|
10759
10836
|
const submit = () => {
|
|
10760
10837
|
if (disabled) return;
|
|
10761
10838
|
const t = value.trim();
|
|
@@ -10769,7 +10846,7 @@ var ChatInput = (0, import_react64.forwardRef)(function ChatInput2({ placeholder
|
|
|
10769
10846
|
submit();
|
|
10770
10847
|
}
|
|
10771
10848
|
};
|
|
10772
|
-
(0,
|
|
10849
|
+
(0, import_react68.useImperativeHandle)(ref, () => ({
|
|
10773
10850
|
focus() {
|
|
10774
10851
|
const box = textareaRef.current;
|
|
10775
10852
|
if (box && !box.disabled) {
|
|
@@ -10781,7 +10858,7 @@ var ChatInput = (0, import_react64.forwardRef)(function ChatInput2({ placeholder
|
|
|
10781
10858
|
stopRef.current?.focus();
|
|
10782
10859
|
}
|
|
10783
10860
|
}), []);
|
|
10784
|
-
(0,
|
|
10861
|
+
(0, import_react68.useEffect)(() => {
|
|
10785
10862
|
if (streaming || disabled || !textBoxWantsFocusRef.current) return;
|
|
10786
10863
|
textBoxWantsFocusRef.current = false;
|
|
10787
10864
|
const box = textareaRef.current;
|
|
@@ -10812,7 +10889,7 @@ var ChatInput = (0, import_react64.forwardRef)(function ChatInput2({ placeholder
|
|
|
10812
10889
|
});
|
|
10813
10890
|
|
|
10814
10891
|
// src/components/TabBar.tsx
|
|
10815
|
-
var
|
|
10892
|
+
var import_react69 = require("react");
|
|
10816
10893
|
var import_jsx_runtime70 = require("react/jsx-runtime");
|
|
10817
10894
|
var TIGHT_LEVELS = [0, 1, 2, 3, 4, 5, 6];
|
|
10818
10895
|
function TabBar({ monitor, ui, matchCount, trendsCount, liveCount, hasSchedule, hasBuilder = false, gamesEnabled, clubEnabled }) {
|
|
@@ -10834,16 +10911,16 @@ function TabBar({ monitor, ui, matchCount, trendsCount, liveCount, hasSchedule,
|
|
|
10834
10911
|
...gamesEnabled ? [{ tab: "games", label: ui.tabGames, count: 0, dot: false }] : []
|
|
10835
10912
|
];
|
|
10836
10913
|
const track = useTrack();
|
|
10837
|
-
const listRef = (0,
|
|
10914
|
+
const listRef = (0, import_react69.useRef)(null);
|
|
10838
10915
|
const activeTab = monitor.activeTab;
|
|
10839
|
-
(0,
|
|
10916
|
+
(0, import_react69.useEffect)(() => {
|
|
10840
10917
|
const el = listRef.current?.querySelector("[data-on]");
|
|
10841
10918
|
if (!el || typeof el.scrollIntoView !== "function") return;
|
|
10842
10919
|
const reduce = typeof window.matchMedia === "function" && window.matchMedia("(prefers-reduced-motion: reduce)").matches;
|
|
10843
10920
|
el.scrollIntoView({ block: "nearest", inline: "nearest", behavior: reduce ? "auto" : "smooth" });
|
|
10844
10921
|
}, [activeTab]);
|
|
10845
10922
|
const labelSignature = tabs.map((t) => `${t.tab}:${t.label}:${t.count}`).join("|");
|
|
10846
|
-
(0,
|
|
10923
|
+
(0, import_react69.useLayoutEffect)(() => {
|
|
10847
10924
|
const strip = listRef.current;
|
|
10848
10925
|
if (!strip) return;
|
|
10849
10926
|
const measure = () => {
|
|
@@ -10891,7 +10968,7 @@ function TabBar({ monitor, ui, matchCount, trendsCount, liveCount, hasSchedule,
|
|
|
10891
10968
|
}
|
|
10892
10969
|
|
|
10893
10970
|
// src/components/MonitorTabs.tsx
|
|
10894
|
-
var
|
|
10971
|
+
var import_react81 = require("react");
|
|
10895
10972
|
|
|
10896
10973
|
// src/components/MarketAccordion.tsx
|
|
10897
10974
|
var import_widget_sdk24 = require("@sensiblestats/widget-sdk");
|
|
@@ -10953,7 +11030,7 @@ function MarketAccordion({ match, monitor, ui, slip }) {
|
|
|
10953
11030
|
}
|
|
10954
11031
|
|
|
10955
11032
|
// src/components/MonitorFormH2H.tsx
|
|
10956
|
-
var
|
|
11033
|
+
var import_react70 = require("react");
|
|
10957
11034
|
var import_jsx_runtime72 = require("react/jsx-runtime");
|
|
10958
11035
|
function resultClass2(result) {
|
|
10959
11036
|
if (result === "W") return "ss-w-h2h-result--win";
|
|
@@ -10969,7 +11046,7 @@ function FormDots({ form, ui }) {
|
|
|
10969
11046
|
return /* @__PURE__ */ (0, import_jsx_runtime72.jsx)("div", { className: "ss-w-h2h-dots", children: form.map((m, i) => /* @__PURE__ */ (0, import_jsx_runtime72.jsx)("span", { className: `ss-w-h2h-result ${resultClass2(m.result)}`, children: resultLabel(m.result, ui) }, i)) });
|
|
10970
11047
|
}
|
|
10971
11048
|
function MonitorFormH2H({ formAndH2H, homeTeamName, awayTeamName, ui }) {
|
|
10972
|
-
const [expanded, setExpanded] = (0,
|
|
11049
|
+
const [expanded, setExpanded] = (0, import_react70.useState)(false);
|
|
10973
11050
|
const { homeForm, awayForm, h2h, homeShortCode, awayShortCode } = formAndH2H;
|
|
10974
11051
|
if (homeForm.length === 0 && awayForm.length === 0 && !h2h) {
|
|
10975
11052
|
return /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(import_jsx_runtime72.Fragment, {});
|
|
@@ -11196,7 +11273,7 @@ function MonitorSkeleton({ pin, monitor, ui }) {
|
|
|
11196
11273
|
}
|
|
11197
11274
|
|
|
11198
11275
|
// src/components/NbaMonitorCard.tsx
|
|
11199
|
-
var
|
|
11276
|
+
var import_react74 = require("react");
|
|
11200
11277
|
|
|
11201
11278
|
// src/sportLabel.ts
|
|
11202
11279
|
var CODE = { football: "football", basketball: "nba", nba: "nba", americanfootball: "nfl", nfl: "nfl", tennis: "tennis" };
|
|
@@ -11206,7 +11283,7 @@ var sportLabel = (ui, sport) => {
|
|
|
11206
11283
|
};
|
|
11207
11284
|
|
|
11208
11285
|
// src/components/NbaFormSection.tsx
|
|
11209
|
-
var
|
|
11286
|
+
var import_react71 = require("react");
|
|
11210
11287
|
|
|
11211
11288
|
// src/components/NbaFormRest.tsx
|
|
11212
11289
|
var import_jsx_runtime75 = require("react/jsx-runtime");
|
|
@@ -11305,8 +11382,8 @@ function Row2({ game, abbr, tonight, ui }) {
|
|
|
11305
11382
|
] });
|
|
11306
11383
|
}
|
|
11307
11384
|
function NbaFormSection({ match, monitor, ui }) {
|
|
11308
|
-
const [open, setOpen] = (0,
|
|
11309
|
-
const [side, setSide] = (0,
|
|
11385
|
+
const [open, setOpen] = (0, import_react71.useState)(false);
|
|
11386
|
+
const [side, setSide] = (0, import_react71.useState)("away");
|
|
11310
11387
|
const form = useNbaForm(match, monitor);
|
|
11311
11388
|
const b = match.basketball;
|
|
11312
11389
|
if (!form || !b || !form.home && !form.away) return null;
|
|
@@ -11348,10 +11425,10 @@ function NbaFormSection({ match, monitor, ui }) {
|
|
|
11348
11425
|
}
|
|
11349
11426
|
|
|
11350
11427
|
// src/components/NbaPropsSection.tsx
|
|
11351
|
-
var
|
|
11428
|
+
var import_react73 = require("react");
|
|
11352
11429
|
|
|
11353
11430
|
// src/components/PropsPieces.tsx
|
|
11354
|
-
var
|
|
11431
|
+
var import_react72 = require("react");
|
|
11355
11432
|
var import_jsx_runtime77 = require("react/jsx-runtime");
|
|
11356
11433
|
var livePlayer = (bundle, p) => bundle.live === true || !p.live && !p.nflLive ? p : { ...p, live: null, nflLive: null };
|
|
11357
11434
|
var hasLiveLine = (p) => p.live != null || p.nflLive != null;
|
|
@@ -11364,9 +11441,9 @@ function preKickoff(match) {
|
|
|
11364
11441
|
return Number.isFinite(kickoff) && Date.now() < kickoff;
|
|
11365
11442
|
}
|
|
11366
11443
|
function usePreKickoff(match) {
|
|
11367
|
-
const [, setTick] = (0,
|
|
11444
|
+
const [, setTick] = (0, import_react72.useState)(0);
|
|
11368
11445
|
const pre = preKickoff(match);
|
|
11369
|
-
(0,
|
|
11446
|
+
(0, import_react72.useEffect)(() => {
|
|
11370
11447
|
if (!pre || !match.kickoffUtc) return;
|
|
11371
11448
|
const wait = Math.min(Math.max(Date.parse(match.kickoffUtc) - Date.now(), 0), MAX_TIMER_MS);
|
|
11372
11449
|
const id = setTimeout(() => setTick((t) => t + 1), wait);
|
|
@@ -11380,7 +11457,7 @@ function usePropsOpen(match, monitor, descriptor) {
|
|
|
11380
11457
|
const pre = descriptor.sport === "basketball" ? match.phase === "preMatch" : beforeKickoff;
|
|
11381
11458
|
const live = match.phase === "live";
|
|
11382
11459
|
const open = pre || live;
|
|
11383
|
-
(0,
|
|
11460
|
+
(0, import_react72.useEffect)(() => {
|
|
11384
11461
|
if (!open) return;
|
|
11385
11462
|
if (sport) monitor.loadPlayerProps?.(match.matchId, sport);
|
|
11386
11463
|
else monitor.loadPlayerProps?.(match.matchId);
|
|
@@ -11458,7 +11535,7 @@ function PropBars({ bars, line, title, wide, ui, note }) {
|
|
|
11458
11535
|
function PropPlayerPanel({ player: given, bundle, descriptor, ui, slip }) {
|
|
11459
11536
|
const player = livePlayer(bundle, given);
|
|
11460
11537
|
const stats = descriptor.stats.map((k) => player.stats.find((s) => s.stat === k)).filter((s) => s != null);
|
|
11461
|
-
const [picked, setPicked] = (0,
|
|
11538
|
+
const [picked, setPicked] = (0, import_react72.useState)(null);
|
|
11462
11539
|
const active = stats.find((s) => s.stat === picked) ?? stats[0];
|
|
11463
11540
|
const sample = active?.games?.length ?? 0;
|
|
11464
11541
|
const hitsOf = (price, text2) => descriptor.showHits && sample > 0 && price.hits != null ? text2(price.hits) : null;
|
|
@@ -11507,8 +11584,8 @@ function PropPlayerPanel({ player: given, bundle, descriptor, ui, slip }) {
|
|
|
11507
11584
|
] });
|
|
11508
11585
|
}
|
|
11509
11586
|
function PropRoster({ bundle, players, side, descriptor, ui, slip }) {
|
|
11510
|
-
const [openId, setOpenId] = (0,
|
|
11511
|
-
const [brokenShots, setBrokenShots] = (0,
|
|
11587
|
+
const [openId, setOpenId] = (0, import_react72.useState)(null);
|
|
11588
|
+
const [brokenShots, setBrokenShots] = (0, import_react72.useState)(/* @__PURE__ */ new Set());
|
|
11512
11589
|
return /* @__PURE__ */ (0, import_jsx_runtime77.jsx)("div", { className: "ss-w-props-list", children: players.map((given) => {
|
|
11513
11590
|
const p = livePlayer(bundle, given);
|
|
11514
11591
|
const isOpen = openId === p.playerId;
|
|
@@ -11554,12 +11631,12 @@ function PropRoster({ bundle, players, side, descriptor, ui, slip }) {
|
|
|
11554
11631
|
}
|
|
11555
11632
|
var BOX_QUIET_MS = 12e4;
|
|
11556
11633
|
function StatsClock({ boxAsOfUtc, match, live, atBreak: atBreak2, ago, ui }) {
|
|
11557
|
-
const [tick, setTick] = (0,
|
|
11634
|
+
const [tick, setTick] = (0, import_react72.useState)(0);
|
|
11558
11635
|
const time = clock2(boxAsOfUtc, ui);
|
|
11559
11636
|
const at2 = time === "" ? Number.NaN : Date.parse(boxAsOfUtc);
|
|
11560
11637
|
const valid = !Number.isNaN(at2);
|
|
11561
11638
|
const onBreak = atBreak(match);
|
|
11562
|
-
(0,
|
|
11639
|
+
(0, import_react72.useEffect)(() => {
|
|
11563
11640
|
if (!valid || onBreak) return;
|
|
11564
11641
|
const age2 = Date.now() - at2;
|
|
11565
11642
|
const wait = age2 < BOX_QUIET_MS ? BOX_QUIET_MS - age2 : 6e4 - age2 % 6e4;
|
|
@@ -11620,12 +11697,12 @@ var nbaDescriptor = (ui, match) => ({
|
|
|
11620
11697
|
tenGameBars: false
|
|
11621
11698
|
});
|
|
11622
11699
|
function StatsClock2({ bundle, match, ui }) {
|
|
11623
|
-
const [tick, setTick] = (0,
|
|
11700
|
+
const [tick, setTick] = (0, import_react73.useState)(0);
|
|
11624
11701
|
const at2 = bundle.live === true && bundle.boxAsOfUtc ? Date.parse(bundle.boxAsOfUtc) : Number.NaN;
|
|
11625
11702
|
const time = clock2(bundle.boxAsOfUtc, ui);
|
|
11626
11703
|
const valid = !Number.isNaN(at2) && time !== "";
|
|
11627
11704
|
const onBreak = atBreak(match);
|
|
11628
|
-
(0,
|
|
11705
|
+
(0, import_react73.useEffect)(() => {
|
|
11629
11706
|
if (!valid || onBreak) return;
|
|
11630
11707
|
const age2 = Date.now() - at2;
|
|
11631
11708
|
const wait = age2 < BOX_QUIET_MS2 ? BOX_QUIET_MS2 - age2 : 6e4 - age2 % 6e4;
|
|
@@ -11639,7 +11716,7 @@ function StatsClock2({ bundle, match, ui }) {
|
|
|
11639
11716
|
return /* @__PURE__ */ (0, import_jsx_runtime78.jsx)("span", { className: "ss-w-props-asof ss-w-props-asof--live", children: ui.nba.propsStatsLive(time) });
|
|
11640
11717
|
}
|
|
11641
11718
|
function NbaPropsSection({ match, monitor, ui, slip }) {
|
|
11642
|
-
const [side, setSide] = (0,
|
|
11719
|
+
const [side, setSide] = (0, import_react73.useState)("home");
|
|
11643
11720
|
const descriptor = nbaDescriptor(ui, match);
|
|
11644
11721
|
const { bundle, live, open } = usePropsOpen(match, monitor, descriptor);
|
|
11645
11722
|
if (!open || !bundle || bundle.players.length === 0 || (bundle.live ?? false) !== live) return null;
|
|
@@ -11677,7 +11754,7 @@ function city(teamName, nickname) {
|
|
|
11677
11754
|
return name.slice(0, name.length - nickname.length).trim() || null;
|
|
11678
11755
|
}
|
|
11679
11756
|
function BadgeCrest({ url, abbreviation }) {
|
|
11680
|
-
const [failed, setFailed] = (0,
|
|
11757
|
+
const [failed, setFailed] = (0, import_react74.useState)(false);
|
|
11681
11758
|
if (url && !failed) {
|
|
11682
11759
|
return /* @__PURE__ */ (0, import_jsx_runtime79.jsx)("img", { className: "ss-w-nbamon-badge ss-w-nbamon-badge--img", src: url, alt: "", "aria-hidden": "true", onError: () => setFailed(true) });
|
|
11683
11760
|
}
|
|
@@ -11795,7 +11872,7 @@ function NbaMonitorCard({ match, monitor, ui, slip }) {
|
|
|
11795
11872
|
}
|
|
11796
11873
|
|
|
11797
11874
|
// src/components/NflFormSection.tsx
|
|
11798
|
-
var
|
|
11875
|
+
var import_react75 = require("react");
|
|
11799
11876
|
var import_jsx_runtime80 = require("react/jsx-runtime");
|
|
11800
11877
|
var outcomeOf = (g) => g.teamScore > g.opponentScore ? "win" : g.teamScore < g.opponentScore ? "loss" : "tie";
|
|
11801
11878
|
var signedSpread2 = (v) => v > 0 ? `+${v}` : String(v);
|
|
@@ -11847,7 +11924,7 @@ function H2hRow({ game, home, ui }) {
|
|
|
11847
11924
|
] });
|
|
11848
11925
|
}
|
|
11849
11926
|
function NflFormSection({ match, monitor, ui }) {
|
|
11850
|
-
const [segment, setSegment] = (0,
|
|
11927
|
+
const [segment, setSegment] = (0, import_react75.useState)("away");
|
|
11851
11928
|
const { live, open } = usePropsOpen(match, monitor, { sport: "americanfootball" });
|
|
11852
11929
|
const bundle = monitor.playerProps?.[monitorMatchKey("americanfootball", match.matchId)]?.bundle;
|
|
11853
11930
|
const form = bundle?.form;
|
|
@@ -11880,7 +11957,7 @@ function NflFormSection({ match, monitor, ui }) {
|
|
|
11880
11957
|
}
|
|
11881
11958
|
|
|
11882
11959
|
// src/components/NflPropsSection.tsx
|
|
11883
|
-
var
|
|
11960
|
+
var import_react76 = require("react");
|
|
11884
11961
|
var import_jsx_runtime81 = require("react/jsx-runtime");
|
|
11885
11962
|
var TRENDS_SHOWN = 3;
|
|
11886
11963
|
var SCORERS_SHOWN = 8;
|
|
@@ -11953,7 +12030,7 @@ function ShowMore({ label, onClick }) {
|
|
|
11953
12030
|
return /* @__PURE__ */ (0, import_jsx_runtime81.jsx)("button", { type: "button", className: "ss-w-props-more", onClick, children: label });
|
|
11954
12031
|
}
|
|
11955
12032
|
function Trends({ bundle, facts, descriptor, ui, slip }) {
|
|
11956
|
-
const [all, setAll] = (0,
|
|
12033
|
+
const [all, setAll] = (0, import_react76.useState)(false);
|
|
11957
12034
|
const shown2 = all ? facts : facts.slice(0, TRENDS_SHOWN);
|
|
11958
12035
|
return /* @__PURE__ */ (0, import_jsx_runtime81.jsxs)("section", { className: "ss-w-props ss-w-props-trends", lang: ui.locale, children: [
|
|
11959
12036
|
/* @__PURE__ */ (0, import_jsx_runtime81.jsx)("div", { className: "ss-w-props-head", children: ui.nfl.propsTrends }),
|
|
@@ -11986,7 +12063,7 @@ function Trends({ bundle, facts, descriptor, ui, slip }) {
|
|
|
11986
12063
|
] });
|
|
11987
12064
|
}
|
|
11988
12065
|
function Scorers({ bundle, scorers, abbreviations, descriptor, ui, slip }) {
|
|
11989
|
-
const [all, setAll] = (0,
|
|
12066
|
+
const [all, setAll] = (0, import_react76.useState)(false);
|
|
11990
12067
|
const shown2 = all ? scorers : scorers.slice(0, SCORERS_SHOWN);
|
|
11991
12068
|
const cell2 = (name, column, price, stat) => price && stat ? /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(PropPrice, { price, label: "", ariaName: `${name}, ${column}`, player: name, stat, bundle, descriptor, ui, slip }) : /* @__PURE__ */ (0, import_jsx_runtime81.jsx)("span", { className: "ss-w-props-scorer-none", children: "\u2014" });
|
|
11992
12069
|
return /* @__PURE__ */ (0, import_jsx_runtime81.jsxs)("div", { className: "ss-w-props-scorers", children: [
|
|
@@ -12016,7 +12093,7 @@ function Scorers({ bundle, scorers, abbreviations, descriptor, ui, slip }) {
|
|
|
12016
12093
|
] });
|
|
12017
12094
|
}
|
|
12018
12095
|
function NflPropsSection({ match, monitor, ui, slip }) {
|
|
12019
|
-
const [tab, setTab] = (0,
|
|
12096
|
+
const [tab, setTab] = (0, import_react76.useState)(null);
|
|
12020
12097
|
const descriptor = nflDescriptor(ui);
|
|
12021
12098
|
const { bundle, live, open } = usePropsOpen(match, monitor, descriptor);
|
|
12022
12099
|
if (!open || !bundle || bundle.players.length === 0 || (bundle.live ?? false) !== live) return null;
|
|
@@ -12202,14 +12279,14 @@ function NflMonitorCard({ match, monitor, ui, slip }) {
|
|
|
12202
12279
|
}
|
|
12203
12280
|
|
|
12204
12281
|
// src/components/TennisMonitorCard.tsx
|
|
12205
|
-
var
|
|
12282
|
+
var import_react79 = require("react");
|
|
12206
12283
|
var import_widget_sdk27 = require("@sensiblestats/widget-sdk");
|
|
12207
12284
|
|
|
12208
12285
|
// src/components/TennisFixtureRow.tsx
|
|
12209
12286
|
var import_widget_sdk26 = require("@sensiblestats/widget-sdk");
|
|
12210
12287
|
|
|
12211
12288
|
// src/components/FixtureRow.tsx
|
|
12212
|
-
var
|
|
12289
|
+
var import_react77 = require("react");
|
|
12213
12290
|
var import_widget_sdk25 = require("@sensiblestats/widget-sdk");
|
|
12214
12291
|
var import_jsx_runtime85 = require("react/jsx-runtime");
|
|
12215
12292
|
function splitAtFirstSpace(label) {
|
|
@@ -12223,7 +12300,7 @@ function kickoffLabel(kickoffUnix, tag2, clock3, timeZone) {
|
|
|
12223
12300
|
return formatTime(kickoffUnix * 1e3, tag2, clock3, { timeZone });
|
|
12224
12301
|
}
|
|
12225
12302
|
function Side2({ name, crest, abbr, away = false }) {
|
|
12226
|
-
const [failed, setFailed] = (0,
|
|
12303
|
+
const [failed, setFailed] = (0, import_react77.useState)(false);
|
|
12227
12304
|
return /* @__PURE__ */ (0, import_jsx_runtime85.jsxs)("span", { className: away ? "ss-w-drow-side ss-w-drow-side--away" : "ss-w-drow-side", children: [
|
|
12228
12305
|
crest && !failed ? /* @__PURE__ */ (0, import_jsx_runtime85.jsx)("img", { className: abbr ? "ss-w-drow-crest ss-w-drow-crest--wide" : "ss-w-drow-crest", src: crest, alt: "", onError: () => setFailed(true) }) : abbr ? /* @__PURE__ */ (0, import_jsx_runtime85.jsx)("span", { className: "ss-w-drow-crest ss-w-drow-crest--abbr", children: abbr }) : null,
|
|
12229
12306
|
/* @__PURE__ */ (0, import_jsx_runtime85.jsx)("span", { className: "ss-w-drow-nm", children: name })
|
|
@@ -12465,7 +12542,7 @@ function TennisLiveScoreboard({ t, score, live, ui }) {
|
|
|
12465
12542
|
}
|
|
12466
12543
|
|
|
12467
12544
|
// src/components/TennisStatsTables.tsx
|
|
12468
|
-
var
|
|
12545
|
+
var import_react78 = require("react");
|
|
12469
12546
|
var import_jsx_runtime88 = require("react/jsx-runtime");
|
|
12470
12547
|
function formatStat(row, value, locale) {
|
|
12471
12548
|
if (value == null) return "\u2013";
|
|
@@ -12503,8 +12580,8 @@ function Tables({ table, labels, names, locale }) {
|
|
|
12503
12580
|
] });
|
|
12504
12581
|
}
|
|
12505
12582
|
function TennisStatsTables({ serveReturn, today, labels, names, ui, resetKey }) {
|
|
12506
|
-
const [tab, setTab] = (0,
|
|
12507
|
-
(0,
|
|
12583
|
+
const [tab, setTab] = (0, import_react78.useState)("match");
|
|
12584
|
+
(0, import_react78.useEffect)(() => {
|
|
12508
12585
|
setTab("match");
|
|
12509
12586
|
}, [resetKey]);
|
|
12510
12587
|
const sets = serveReturn.sets.filter((s) => s.table.serve.length + s.table.return.length > 0);
|
|
@@ -12535,7 +12612,7 @@ function TennisStatsTables({ serveReturn, today, labels, names, ui, resetKey })
|
|
|
12535
12612
|
] }),
|
|
12536
12613
|
today.rows.map((r) => {
|
|
12537
12614
|
const f = (v) => formatStat({ kind: "pct" }, v, locale);
|
|
12538
|
-
return /* @__PURE__ */ (0, import_jsx_runtime88.jsxs)(
|
|
12615
|
+
return /* @__PURE__ */ (0, import_jsx_runtime88.jsxs)(import_react78.Fragment, { children: [
|
|
12539
12616
|
/* @__PURE__ */ (0, import_jsx_runtime88.jsx)("span", { className: "ss-w-ts-l", children: r.label }),
|
|
12540
12617
|
/* @__PURE__ */ (0, import_jsx_runtime88.jsxs)("span", { className: "ss-w-ts-today-v ss-w-ts-today-v--a", children: [
|
|
12541
12618
|
f(r.p1Today),
|
|
@@ -12670,7 +12747,7 @@ function HeadToHead({ t, ui }) {
|
|
|
12670
12747
|
] });
|
|
12671
12748
|
}
|
|
12672
12749
|
function TennisMonitorCard({ match, monitor, ui, slip, onAsk }) {
|
|
12673
|
-
const lastTables = (0,
|
|
12750
|
+
const lastTables = (0, import_react79.useRef)(null);
|
|
12674
12751
|
const t = match.tennis;
|
|
12675
12752
|
if (!t) return /* @__PURE__ */ (0, import_jsx_runtime89.jsx)(UnavailableCard, { match, monitor, ui, sport: "tennis" });
|
|
12676
12753
|
const preMatch = match.phase === "preMatch";
|
|
@@ -12750,7 +12827,7 @@ function TennisMonitorCard({ match, monitor, ui, slip, onAsk }) {
|
|
|
12750
12827
|
}
|
|
12751
12828
|
|
|
12752
12829
|
// src/components/ScoreboardStrip.tsx
|
|
12753
|
-
var
|
|
12830
|
+
var import_react80 = require("react");
|
|
12754
12831
|
var import_widget_sdk28 = require("@sensiblestats/widget-sdk");
|
|
12755
12832
|
var import_jsx_runtime90 = require("react/jsx-runtime");
|
|
12756
12833
|
function nbaStatus(m, ui) {
|
|
@@ -12845,8 +12922,8 @@ function rowsFor(m) {
|
|
|
12845
12922
|
];
|
|
12846
12923
|
}
|
|
12847
12924
|
function useStripScroll(selectedKey) {
|
|
12848
|
-
const stripRef = (0,
|
|
12849
|
-
(0,
|
|
12925
|
+
const stripRef = (0, import_react80.useRef)(null);
|
|
12926
|
+
(0, import_react80.useEffect)(() => {
|
|
12850
12927
|
const strip = stripRef.current;
|
|
12851
12928
|
const pressed = strip?.querySelector('[aria-pressed="true"]');
|
|
12852
12929
|
if (!strip || !pressed) return;
|
|
@@ -13020,7 +13097,7 @@ function OddsLiveStrip({ m, ui }) {
|
|
|
13020
13097
|
] });
|
|
13021
13098
|
}
|
|
13022
13099
|
function MatchesPanel({ monitor, ui, slip, onAsk, discovery }) {
|
|
13023
|
-
const seedIndex = (0,
|
|
13100
|
+
const seedIndex = (0, import_react81.useMemo)(() => buildSeedIndex(discovery?.groups ?? []), [discovery?.groups]);
|
|
13024
13101
|
const tiles = orderTiles(
|
|
13025
13102
|
monitor.pins,
|
|
13026
13103
|
monitor.snapshot,
|
|
@@ -13092,7 +13169,7 @@ function TrendsPanel({ monitor, ui, slip }) {
|
|
|
13092
13169
|
}
|
|
13093
13170
|
|
|
13094
13171
|
// src/components/LivePanel.tsx
|
|
13095
|
-
var
|
|
13172
|
+
var import_react84 = require("react");
|
|
13096
13173
|
var import_widget_sdk35 = require("@sensiblestats/widget-sdk");
|
|
13097
13174
|
|
|
13098
13175
|
// src/scheduleView.ts
|
|
@@ -13267,20 +13344,20 @@ function LeagueGroup({ view, open, onToggle, disambiguate, rowCap, onShowAll, on
|
|
|
13267
13344
|
}
|
|
13268
13345
|
|
|
13269
13346
|
// src/components/MatchSheet.tsx
|
|
13270
|
-
var
|
|
13347
|
+
var import_react83 = require("react");
|
|
13271
13348
|
var import_widget_sdk33 = require("@sensiblestats/widget-sdk");
|
|
13272
13349
|
|
|
13273
13350
|
// src/useModalDialog.ts
|
|
13274
|
-
var
|
|
13351
|
+
var import_react82 = require("react");
|
|
13275
13352
|
var FOCUSABLE = 'button:not([disabled]), [href], input:not([disabled]), select:not([disabled]), textarea:not([disabled]), [tabindex]:not([tabindex="-1"])';
|
|
13276
13353
|
function useModalDialog(onClose, opts = {}) {
|
|
13277
|
-
const dialogRef = (0,
|
|
13278
|
-
const onCloseRef = (0,
|
|
13354
|
+
const dialogRef = (0, import_react82.useRef)(null);
|
|
13355
|
+
const onCloseRef = (0, import_react82.useRef)(onClose);
|
|
13279
13356
|
onCloseRef.current = onClose;
|
|
13280
|
-
const openerRef = (0,
|
|
13357
|
+
const openerRef = (0, import_react82.useRef)(opts.opener);
|
|
13281
13358
|
openerRef.current = opts.opener;
|
|
13282
13359
|
const restore = opts.restoreFocus ?? true;
|
|
13283
|
-
(0,
|
|
13360
|
+
(0, import_react82.useEffect)(() => {
|
|
13284
13361
|
const dialog = dialogRef.current;
|
|
13285
13362
|
const root = dialog?.getRootNode();
|
|
13286
13363
|
const focusedAtMount = root?.activeElement ?? null;
|
|
@@ -13291,7 +13368,7 @@ function useModalDialog(onClose, opts = {}) {
|
|
|
13291
13368
|
if (target instanceof HTMLElement) target.focus({ preventScroll: true });
|
|
13292
13369
|
};
|
|
13293
13370
|
}, []);
|
|
13294
|
-
(0,
|
|
13371
|
+
(0, import_react82.useEffect)(() => {
|
|
13295
13372
|
const onKey = (e) => {
|
|
13296
13373
|
if (e.key !== "Escape") return;
|
|
13297
13374
|
e.stopPropagation();
|
|
@@ -13332,8 +13409,8 @@ function kickoffDate(kickoffUnix, lang, timeZone) {
|
|
|
13332
13409
|
function MatchSheet({ match, league, state, stale, ui, monitor, onAsk, onClose, opener }) {
|
|
13333
13410
|
const { dialogRef, onKeyDown } = useModalDialog(onClose, { opener });
|
|
13334
13411
|
const log = useEventLog();
|
|
13335
|
-
const titleId = (0,
|
|
13336
|
-
const [limitHit, setLimitHit] = (0,
|
|
13412
|
+
const titleId = (0, import_react83.useId)();
|
|
13413
|
+
const [limitHit, setLimitHit] = (0, import_react83.useState)(false);
|
|
13337
13414
|
const pinSport = (0, import_widget_sdk33.slipSportOf)(match.sport);
|
|
13338
13415
|
const tour = pinSport === "tennis" && isKnownTour(match.tour) ? match.tour : void 0;
|
|
13339
13416
|
const followable = pinSport !== "tennis" || tour !== void 0;
|
|
@@ -13434,10 +13511,10 @@ var OPEN_TOP_GROUPS = 2;
|
|
|
13434
13511
|
var QUIET_ROWS = 4;
|
|
13435
13512
|
function LivePanel({ discovery, ui, monitor, sport, offered, onSport, league, onLeague, onSeeAll, onAsk }) {
|
|
13436
13513
|
const { groups, states, stale } = discovery;
|
|
13437
|
-
const [mine, setMine] = (0,
|
|
13438
|
-
const [toggled, setToggled] = (0,
|
|
13439
|
-
const [sheet, setSheet] = (0,
|
|
13440
|
-
const pinnedKeys = (0,
|
|
13514
|
+
const [mine, setMine] = (0, import_react84.useState)(false);
|
|
13515
|
+
const [toggled, setToggled] = (0, import_react84.useState)(/* @__PURE__ */ new Map());
|
|
13516
|
+
const [sheet, setSheet] = (0, import_react84.useState)(null);
|
|
13517
|
+
const pinnedKeys = (0, import_react84.useMemo)(
|
|
13441
13518
|
() => new Set(monitor.pins.filter((p) => p.kind === "match").map((p) => (0, import_widget_sdk35.matchKey)(p.sport, p.matchId, p.tour))),
|
|
13442
13519
|
[monitor.pins]
|
|
13443
13520
|
);
|
|
@@ -13543,20 +13620,20 @@ function LivePanel({ discovery, ui, monitor, sport, offered, onSport, league, on
|
|
|
13543
13620
|
}
|
|
13544
13621
|
|
|
13545
13622
|
// src/components/ScheduleMatchesPanel.tsx
|
|
13546
|
-
var
|
|
13623
|
+
var import_react88 = require("react");
|
|
13547
13624
|
var import_widget_sdk37 = require("@sensiblestats/widget-sdk");
|
|
13548
13625
|
|
|
13549
13626
|
// src/useTennisRowPrices.ts
|
|
13550
|
-
var
|
|
13627
|
+
var import_react85 = require("react");
|
|
13551
13628
|
var import_widget_sdk36 = require("@sensiblestats/widget-sdk");
|
|
13552
13629
|
var TENNIS_PRICE_POLL_MS = 6e4;
|
|
13553
13630
|
function useTennisRowPrices(a) {
|
|
13554
|
-
const [state, setState] = (0,
|
|
13555
|
-
const getPricesRef = (0,
|
|
13631
|
+
const [state, setState] = (0, import_react85.useState)({ byId: null, stale: false });
|
|
13632
|
+
const getPricesRef = (0, import_react85.useRef)(a.getPrices);
|
|
13556
13633
|
getPricesRef.current = a.getPrices;
|
|
13557
|
-
const latest = (0,
|
|
13634
|
+
const latest = (0, import_react85.useRef)(0);
|
|
13558
13635
|
const idsKey = a.keys.filter((k) => isKnownTour(k.tour)).slice(0, MAX_TENNIS_KEYS).map((k) => `${k.tour}:${k.matchId}`).sort().join(",");
|
|
13559
|
-
(0,
|
|
13636
|
+
(0, import_react85.useEffect)(() => {
|
|
13560
13637
|
if (!a.enabled || idsKey === "") {
|
|
13561
13638
|
latest.current++;
|
|
13562
13639
|
setState((prev) => prev.byId === null && !prev.stale ? prev : { byId: null, stale: false });
|
|
@@ -13594,11 +13671,11 @@ function useTennisRowPrices(a) {
|
|
|
13594
13671
|
}
|
|
13595
13672
|
|
|
13596
13673
|
// src/components/DayStrip.tsx
|
|
13597
|
-
var
|
|
13674
|
+
var import_react86 = require("react");
|
|
13598
13675
|
var import_jsx_runtime99 = require("react/jsx-runtime");
|
|
13599
13676
|
function DayStrip({ chips, selected, onSelect, ui, locale }) {
|
|
13600
|
-
const listRef = (0,
|
|
13601
|
-
(0,
|
|
13677
|
+
const listRef = (0, import_react86.useRef)(null);
|
|
13678
|
+
(0, import_react86.useEffect)(() => {
|
|
13602
13679
|
const el = listRef.current?.querySelector('[aria-pressed="true"]');
|
|
13603
13680
|
if (!el || typeof el.scrollIntoView !== "function") return;
|
|
13604
13681
|
const reduce = typeof window.matchMedia === "function" && window.matchMedia("(prefers-reduced-motion: reduce)").matches;
|
|
@@ -13627,7 +13704,7 @@ function DayStrip({ chips, selected, onSelect, ui, locale }) {
|
|
|
13627
13704
|
}
|
|
13628
13705
|
|
|
13629
13706
|
// src/components/games/ui/SearchField.tsx
|
|
13630
|
-
var
|
|
13707
|
+
var import_react87 = require("react");
|
|
13631
13708
|
|
|
13632
13709
|
// src/components/games/ui/icons.tsx
|
|
13633
13710
|
var import_jsx_runtime100 = require("react/jsx-runtime");
|
|
@@ -13666,8 +13743,8 @@ var IconFlame = ({ size = 16 }) => svg(size, /* @__PURE__ */ (0, import_jsx_runt
|
|
|
13666
13743
|
// src/components/games/ui/SearchField.tsx
|
|
13667
13744
|
var import_jsx_runtime101 = require("react/jsx-runtime");
|
|
13668
13745
|
function SearchField({ id, label, labelHidden = false, placeholder, value, onChange, disabled, inputRef, onKeyDown, clearLabel }) {
|
|
13669
|
-
const localRef = (0,
|
|
13670
|
-
const setInputRef = (0,
|
|
13746
|
+
const localRef = (0, import_react87.useRef)(null);
|
|
13747
|
+
const setInputRef = (0, import_react87.useCallback)((node) => {
|
|
13671
13748
|
localRef.current = node;
|
|
13672
13749
|
if (typeof inputRef === "function") inputRef(node);
|
|
13673
13750
|
else if (inputRef) inputRef.current = node;
|
|
@@ -13713,18 +13790,18 @@ var TOP_ROW_CAP = 3;
|
|
|
13713
13790
|
var SKELETON_ROWS = 3;
|
|
13714
13791
|
function ScheduleMatchesPanel({ discovery, ui, monitor, sport, offered, onSport, day, onDay, loaded, onOpenLive, onAsk, locale, getTennisPrices, slip }) {
|
|
13715
13792
|
const { localDate: today, states, stale } = discovery;
|
|
13716
|
-
const searchId = (0,
|
|
13717
|
-
const [query, setQuery] = (0,
|
|
13718
|
-
const [toggled, setToggled] = (0,
|
|
13719
|
-
const [expanded, setExpanded] = (0,
|
|
13720
|
-
const listRef = (0,
|
|
13721
|
-
const [sheet, setSheet] = (0,
|
|
13793
|
+
const searchId = (0, import_react88.useId)();
|
|
13794
|
+
const [query, setQuery] = (0, import_react88.useState)("");
|
|
13795
|
+
const [toggled, setToggled] = (0, import_react88.useState)(/* @__PURE__ */ new Map());
|
|
13796
|
+
const [expanded, setExpanded] = (0, import_react88.useState)(/* @__PURE__ */ new Set());
|
|
13797
|
+
const listRef = (0, import_react88.useRef)(null);
|
|
13798
|
+
const [sheet, setSheet] = (0, import_react88.useState)(null);
|
|
13722
13799
|
const { chips, selected } = loaded;
|
|
13723
|
-
(0,
|
|
13800
|
+
(0, import_react88.useEffect)(() => {
|
|
13724
13801
|
if (selected !== day) onDay(selected);
|
|
13725
13802
|
}, [day, selected, onDay]);
|
|
13726
13803
|
const isToday = selected === today;
|
|
13727
|
-
const pinnedKeys = (0,
|
|
13804
|
+
const pinnedKeys = (0, import_react88.useMemo)(
|
|
13728
13805
|
() => new Set(monitor.pins.filter((p) => p.kind === "match").map((p) => (0, import_widget_sdk37.matchKey)(p.sport, p.matchId, p.tour))),
|
|
13729
13806
|
[monitor.pins]
|
|
13730
13807
|
);
|
|
@@ -13862,7 +13939,7 @@ function ScheduleMatchesPanel({ discovery, ui, monitor, sport, offered, onSport,
|
|
|
13862
13939
|
}
|
|
13863
13940
|
|
|
13864
13941
|
// src/components/GamesPanel.tsx
|
|
13865
|
-
var
|
|
13942
|
+
var import_react103 = require("react");
|
|
13866
13943
|
|
|
13867
13944
|
// src/components/GamesLoginWall.tsx
|
|
13868
13945
|
var import_jsx_runtime103 = require("react/jsx-runtime");
|
|
@@ -13871,7 +13948,7 @@ function GamesLoginWall({ ui }) {
|
|
|
13871
13948
|
}
|
|
13872
13949
|
|
|
13873
13950
|
// src/components/GamesHub.tsx
|
|
13874
|
-
var
|
|
13951
|
+
var import_react89 = require("react");
|
|
13875
13952
|
|
|
13876
13953
|
// src/components/games/ui/gameMeta.ts
|
|
13877
13954
|
function prettifyGameId(gameId) {
|
|
@@ -14022,8 +14099,8 @@ function pickHeroGame(games) {
|
|
|
14022
14099
|
}
|
|
14023
14100
|
var tileKey = (g) => `${g.gameId}-${g.gameDay}-${g.fixtureId}`;
|
|
14024
14101
|
function GamesHub({ games, myWeeklyRow, weeklyPrize, onOpen, ui }) {
|
|
14025
|
-
const [, setTick] = (0,
|
|
14026
|
-
(0,
|
|
14102
|
+
const [, setTick] = (0, import_react89.useState)(0);
|
|
14103
|
+
(0, import_react89.useEffect)(() => {
|
|
14027
14104
|
const id = setInterval(() => setTick((t) => t + 1), 6e4);
|
|
14028
14105
|
return () => clearInterval(id);
|
|
14029
14106
|
}, []);
|
|
@@ -14083,10 +14160,10 @@ function GamesHub({ games, myWeeklyRow, weeklyPrize, onOpen, ui }) {
|
|
|
14083
14160
|
}
|
|
14084
14161
|
|
|
14085
14162
|
// src/components/GameScreenHost.tsx
|
|
14086
|
-
var
|
|
14163
|
+
var import_react101 = require("react");
|
|
14087
14164
|
|
|
14088
14165
|
// src/useGamePlay.ts
|
|
14089
|
-
var
|
|
14166
|
+
var import_react90 = require("react");
|
|
14090
14167
|
function toSubmitResult(payload) {
|
|
14091
14168
|
return {
|
|
14092
14169
|
// 'pending' means the play is recorded but awaiting resolution (fixture games)
|
|
@@ -14098,17 +14175,17 @@ function toSubmitResult(payload) {
|
|
|
14098
14175
|
};
|
|
14099
14176
|
}
|
|
14100
14177
|
function useGamePlay(conversation, { gameId, gameDay, fixtureId, locale, refresh }) {
|
|
14101
|
-
const [result, setResult] = (0,
|
|
14102
|
-
const [submitting, setSubmitting] = (0,
|
|
14103
|
-
const [rawStatus, setRawStatus] = (0,
|
|
14104
|
-
const inFlightRef = (0,
|
|
14105
|
-
const convRef = (0,
|
|
14178
|
+
const [result, setResult] = (0, import_react90.useState)(null);
|
|
14179
|
+
const [submitting, setSubmitting] = (0, import_react90.useState)(false);
|
|
14180
|
+
const [rawStatus, setRawStatus] = (0, import_react90.useState)(null);
|
|
14181
|
+
const inFlightRef = (0, import_react90.useRef)(false);
|
|
14182
|
+
const convRef = (0, import_react90.useRef)(conversation);
|
|
14106
14183
|
convRef.current = conversation;
|
|
14107
|
-
const optsRef = (0,
|
|
14184
|
+
const optsRef = (0, import_react90.useRef)({ gameId, gameDay, fixtureId, locale, refresh });
|
|
14108
14185
|
optsRef.current = { gameId, gameDay, fixtureId, locale, refresh };
|
|
14109
|
-
const resultRef = (0,
|
|
14186
|
+
const resultRef = (0, import_react90.useRef)(null);
|
|
14110
14187
|
resultRef.current = result;
|
|
14111
|
-
const refetch = (0,
|
|
14188
|
+
const refetch = (0, import_react90.useCallback)(async () => {
|
|
14112
14189
|
const conv = convRef.current;
|
|
14113
14190
|
if (!conv) return;
|
|
14114
14191
|
const opts = optsRef.current;
|
|
@@ -14124,7 +14201,7 @@ function useGamePlay(conversation, { gameId, gameDay, fixtureId, locale, refresh
|
|
|
14124
14201
|
} catch {
|
|
14125
14202
|
}
|
|
14126
14203
|
}, []);
|
|
14127
|
-
const submit = (0,
|
|
14204
|
+
const submit = (0, import_react90.useCallback)(async (answerJson) => {
|
|
14128
14205
|
const conv = convRef.current;
|
|
14129
14206
|
if (!conv || inFlightRef.current) return;
|
|
14130
14207
|
inFlightRef.current = true;
|
|
@@ -14151,14 +14228,14 @@ function useGamePlay(conversation, { gameId, gameDay, fixtureId, locale, refresh
|
|
|
14151
14228
|
setSubmitting(false);
|
|
14152
14229
|
}
|
|
14153
14230
|
}, [refetch]);
|
|
14154
|
-
const hydrate = (0,
|
|
14231
|
+
const hydrate = (0, import_react90.useCallback)(() => {
|
|
14155
14232
|
void refetch();
|
|
14156
14233
|
}, [refetch]);
|
|
14157
14234
|
return { result, submitting, submit, hydrate, rawStatus };
|
|
14158
14235
|
}
|
|
14159
14236
|
|
|
14160
14237
|
// src/components/games/MysteryTigerGame.tsx
|
|
14161
|
-
var
|
|
14238
|
+
var import_react92 = require("react");
|
|
14162
14239
|
|
|
14163
14240
|
// src/components/games/nationFlags.ts
|
|
14164
14241
|
var FLAGS = {
|
|
@@ -14369,7 +14446,7 @@ function isNationCode(flag) {
|
|
|
14369
14446
|
}
|
|
14370
14447
|
|
|
14371
14448
|
// src/components/games/PlayerAvatar.tsx
|
|
14372
|
-
var
|
|
14449
|
+
var import_react91 = require("react");
|
|
14373
14450
|
var import_jsx_runtime108 = require("react/jsx-runtime");
|
|
14374
14451
|
function initialsOf(name) {
|
|
14375
14452
|
const parts2 = name.trim().split(/\s+/).filter(Boolean);
|
|
@@ -14387,7 +14464,7 @@ function PlayerAvatar({
|
|
|
14387
14464
|
imagePath,
|
|
14388
14465
|
className
|
|
14389
14466
|
}) {
|
|
14390
|
-
const [failed, setFailed] = (0,
|
|
14467
|
+
const [failed, setFailed] = (0, import_react91.useState)(false);
|
|
14391
14468
|
const showImage = Boolean(imagePath) && !isPlaceholderImage(imagePath) && !failed;
|
|
14392
14469
|
return /* @__PURE__ */ (0, import_jsx_runtime108.jsx)("div", { className, "aria-hidden": "true", children: showImage ? /* @__PURE__ */ (0, import_jsx_runtime108.jsx)("img", { src: imagePath, alt: "", loading: "lazy", onError: () => setFailed(true) }) : /* @__PURE__ */ (0, import_jsx_runtime108.jsx)("span", { className: "ss-w-av-initials", children: initialsOf(name) }) });
|
|
14393
14470
|
}
|
|
@@ -14631,8 +14708,8 @@ function MysteryTigerGame({
|
|
|
14631
14708
|
onBack
|
|
14632
14709
|
}) {
|
|
14633
14710
|
const t = ui.games.mysteryTiger;
|
|
14634
|
-
const [query, setQuery] = (0,
|
|
14635
|
-
const inputId = (0,
|
|
14711
|
+
const [query, setQuery] = (0, import_react92.useState)("");
|
|
14712
|
+
const inputId = (0, import_react92.useId)();
|
|
14636
14713
|
const clientState = parseClientState(result?.clientStateJson);
|
|
14637
14714
|
const guessResults = clientState?.guessResults ?? [];
|
|
14638
14715
|
const alreadyGuessedIds = new Set(guessResults.map((g) => g.playerId));
|
|
@@ -14893,13 +14970,13 @@ function HigherOrLowerGame({
|
|
|
14893
14970
|
}
|
|
14894
14971
|
|
|
14895
14972
|
// src/components/games/CareerPathGame.tsx
|
|
14896
|
-
var
|
|
14973
|
+
var import_react94 = require("react");
|
|
14897
14974
|
|
|
14898
14975
|
// src/components/games/ui/CrestShield.tsx
|
|
14899
|
-
var
|
|
14976
|
+
var import_react93 = require("react");
|
|
14900
14977
|
var import_jsx_runtime119 = require("react/jsx-runtime");
|
|
14901
14978
|
function CrestShield({ src, name, size = 28 }) {
|
|
14902
|
-
const [failed, setFailed] = (0,
|
|
14979
|
+
const [failed, setFailed] = (0, import_react93.useState)(false);
|
|
14903
14980
|
if (src && !isPlaceholderImage(src) && !failed) {
|
|
14904
14981
|
return /* @__PURE__ */ (0, import_jsx_runtime119.jsx)("img", { className: "ss-g-crest", src, alt: name, width: size, height: size, loading: "lazy", onError: () => setFailed(true) });
|
|
14905
14982
|
}
|
|
@@ -14931,8 +15008,8 @@ function CareerPathGame({
|
|
|
14931
15008
|
}) {
|
|
14932
15009
|
const s = ui.games.careerPath;
|
|
14933
15010
|
const title = gameTitle({ gameId: "career-path" }, ui.games.titles);
|
|
14934
|
-
const [query, setQuery] = (0,
|
|
14935
|
-
const inputId = (0,
|
|
15011
|
+
const [query, setQuery] = (0, import_react94.useState)("");
|
|
15012
|
+
const inputId = (0, import_react94.useId)();
|
|
14936
15013
|
const clientState = parseClientState3(result?.clientStateJson);
|
|
14937
15014
|
const alreadyGuessedIds = new Set(clientState?.guessResults.map((g) => g.playerId) ?? []);
|
|
14938
15015
|
const isOver = result?.alreadyPlayed === true || clientState?.solved === true || clientState?.failed === true;
|
|
@@ -15038,7 +15115,7 @@ function CareerPathGame({
|
|
|
15038
15115
|
}
|
|
15039
15116
|
|
|
15040
15117
|
// src/components/games/BeatTheGridGame.tsx
|
|
15041
|
-
var
|
|
15118
|
+
var import_react95 = __toESM(require("react"), 1);
|
|
15042
15119
|
|
|
15043
15120
|
// src/components/games/ui/OptionList.tsx
|
|
15044
15121
|
var import_jsx_runtime121 = require("react/jsx-runtime");
|
|
@@ -15127,10 +15204,10 @@ function SearchSheet({
|
|
|
15127
15204
|
ui
|
|
15128
15205
|
}) {
|
|
15129
15206
|
const s = ui.games.beatTheGrid;
|
|
15130
|
-
const [query, setQuery] = (0,
|
|
15131
|
-
const inputId = (0,
|
|
15132
|
-
const inputRef = (0,
|
|
15133
|
-
(0,
|
|
15207
|
+
const [query, setQuery] = (0, import_react95.useState)("");
|
|
15208
|
+
const inputId = (0, import_react95.useId)();
|
|
15209
|
+
const inputRef = (0, import_react95.useRef)(null);
|
|
15210
|
+
(0, import_react95.useEffect)(() => {
|
|
15134
15211
|
inputRef.current?.focus();
|
|
15135
15212
|
}, [row, col]);
|
|
15136
15213
|
const filtered = playerPool.filter(
|
|
@@ -15195,7 +15272,7 @@ function BeatTheGridGame({
|
|
|
15195
15272
|
}) {
|
|
15196
15273
|
const s = ui.games.beatTheGrid;
|
|
15197
15274
|
const title = gameTitle({ gameId: "beat-the-grid" }, ui.games.titles);
|
|
15198
|
-
const [activeCell, setActiveCell] = (0,
|
|
15275
|
+
const [activeCell, setActiveCell] = (0, import_react95.useState)(null);
|
|
15199
15276
|
const clientState = parseClientState4(result?.clientStateJson);
|
|
15200
15277
|
const filledCells = clientState?.cells ?? [];
|
|
15201
15278
|
const isLocked2 = result?.alreadyPlayed === true || clientState?.isComplete === true;
|
|
@@ -15269,7 +15346,7 @@ function BeatTheGridGame({
|
|
|
15269
15346
|
/* @__PURE__ */ (0, import_jsx_runtime122.jsx)("span", { "aria-hidden": "true", children: abbr }),
|
|
15270
15347
|
/* @__PURE__ */ (0, import_jsx_runtime122.jsx)("span", { className: "ss-g-sr", children: rowLabel })
|
|
15271
15348
|
] });
|
|
15272
|
-
return /* @__PURE__ */ (0, import_jsx_runtime122.jsxs)(
|
|
15349
|
+
return /* @__PURE__ */ (0, import_jsx_runtime122.jsxs)(import_react95.default.Fragment, { children: [
|
|
15273
15350
|
/* @__PURE__ */ (0, import_jsx_runtime122.jsx)("div", { className: "ss-g-btg-rowhdr", "data-meta": rowMeta ? "true" : void 0, children: rowHeaderContent }),
|
|
15274
15351
|
cols.map((colLabel, colIdx) => {
|
|
15275
15352
|
const filled = findCellResult(filledCells, rowIdx, colIdx);
|
|
@@ -15350,7 +15427,7 @@ function BeatTheGridGame({
|
|
|
15350
15427
|
}
|
|
15351
15428
|
|
|
15352
15429
|
// src/components/games/GuessTheXiGame.tsx
|
|
15353
|
-
var
|
|
15430
|
+
var import_react96 = require("react");
|
|
15354
15431
|
|
|
15355
15432
|
// src/components/games/ui/PitchSvg.tsx
|
|
15356
15433
|
var import_jsx_runtime123 = require("react/jsx-runtime");
|
|
@@ -15439,8 +15516,8 @@ function GuessTheXiGame({
|
|
|
15439
15516
|
onBack
|
|
15440
15517
|
}) {
|
|
15441
15518
|
const t = ui.games.guessTheXi;
|
|
15442
|
-
const [query, setQuery] = (0,
|
|
15443
|
-
const inputId = (0,
|
|
15519
|
+
const [query, setQuery] = (0, import_react96.useState)("");
|
|
15520
|
+
const inputId = (0, import_react96.useId)();
|
|
15444
15521
|
const clientState = parseClientState5(result?.clientStateJson);
|
|
15445
15522
|
const isOver = result?.alreadyPlayed === true || clientState?.status === "solved" || clientState?.status === "failed";
|
|
15446
15523
|
const solved = clientState?.status === "solved";
|
|
@@ -15582,7 +15659,7 @@ function GuessTheXiGame({
|
|
|
15582
15659
|
}
|
|
15583
15660
|
|
|
15584
15661
|
// src/components/games/DailyQuizGame.tsx
|
|
15585
|
-
var
|
|
15662
|
+
var import_react97 = require("react");
|
|
15586
15663
|
var import_jsx_runtime125 = require("react/jsx-runtime");
|
|
15587
15664
|
function parseClientState6(json) {
|
|
15588
15665
|
if (!json) return null;
|
|
@@ -15623,8 +15700,8 @@ function DailyQuizGame({
|
|
|
15623
15700
|
}) {
|
|
15624
15701
|
const s = ui.games.dailyQuiz;
|
|
15625
15702
|
const title = gameTitle({ gameId: "daily-quiz" }, ui.games.titles);
|
|
15626
|
-
const [selections, setSelections] = (0,
|
|
15627
|
-
const [page, setPage] = (0,
|
|
15703
|
+
const [selections, setSelections] = (0, import_react97.useState)(/* @__PURE__ */ new Map());
|
|
15704
|
+
const [page, setPage] = (0, import_react97.useState)(0);
|
|
15628
15705
|
const clientState = parseClientState6(result?.clientStateJson);
|
|
15629
15706
|
const results2 = clientState?.results ?? [];
|
|
15630
15707
|
const isRevealed = results2.length > 0 || result?.alreadyPlayed === true;
|
|
@@ -15734,7 +15811,7 @@ function DailyQuizGame({
|
|
|
15734
15811
|
}
|
|
15735
15812
|
|
|
15736
15813
|
// src/components/games/MatchdayPredictorGame.tsx
|
|
15737
|
-
var
|
|
15814
|
+
var import_react98 = require("react");
|
|
15738
15815
|
var import_jsx_runtime126 = require("react/jsx-runtime");
|
|
15739
15816
|
var SCORER_SEARCH_THRESHOLD = 9;
|
|
15740
15817
|
function parseClientState7(json) {
|
|
@@ -15830,12 +15907,12 @@ function MatchdayPredictorGame({
|
|
|
15830
15907
|
onBack
|
|
15831
15908
|
}) {
|
|
15832
15909
|
const t = ui.games.predictor;
|
|
15833
|
-
const [homeScore, setHomeScore] = (0,
|
|
15834
|
-
const [awayScore, setAwayScore] = (0,
|
|
15835
|
-
const [firstScorerPlayerId, setFirstScorerPlayerId] = (0,
|
|
15836
|
-
const [lastEdited, setLastEdited] = (0,
|
|
15837
|
-
const [query, setQuery] = (0,
|
|
15838
|
-
const searchId = (0,
|
|
15910
|
+
const [homeScore, setHomeScore] = (0, import_react98.useState)(0);
|
|
15911
|
+
const [awayScore, setAwayScore] = (0, import_react98.useState)(0);
|
|
15912
|
+
const [firstScorerPlayerId, setFirstScorerPlayerId] = (0, import_react98.useState)(null);
|
|
15913
|
+
const [lastEdited, setLastEdited] = (0, import_react98.useState)("home");
|
|
15914
|
+
const [query, setQuery] = (0, import_react98.useState)("");
|
|
15915
|
+
const searchId = (0, import_react98.useId)();
|
|
15839
15916
|
const clientState = parseClientState7(result?.clientStateJson);
|
|
15840
15917
|
const alreadyPlayed = result?.alreadyPlayed === true;
|
|
15841
15918
|
const header = /* @__PURE__ */ (0, import_jsx_runtime126.jsx)(
|
|
@@ -16002,7 +16079,7 @@ function MatchdayPredictorGame({
|
|
|
16002
16079
|
}
|
|
16003
16080
|
|
|
16004
16081
|
// src/components/games/StartingXiGame.tsx
|
|
16005
|
-
var
|
|
16082
|
+
var import_react99 = require("react");
|
|
16006
16083
|
var import_jsx_runtime127 = require("react/jsx-runtime");
|
|
16007
16084
|
var POINTS_PER_STARTER = 8;
|
|
16008
16085
|
var XI_SIZE = 11;
|
|
@@ -16046,10 +16123,10 @@ function StartingXiGame({
|
|
|
16046
16123
|
lockAtUtc
|
|
16047
16124
|
}) {
|
|
16048
16125
|
const t = ui.games.startingXi;
|
|
16049
|
-
const [slotPlayers, setSlotPlayers] = (0,
|
|
16050
|
-
const [active, setActive] = (0,
|
|
16051
|
-
const [query, setQuery] = (0,
|
|
16052
|
-
const searchId = (0,
|
|
16126
|
+
const [slotPlayers, setSlotPlayers] = (0, import_react99.useState)(() => Array(XI_SIZE).fill(null));
|
|
16127
|
+
const [active, setActive] = (0, import_react99.useState)(0);
|
|
16128
|
+
const [query, setQuery] = (0, import_react99.useState)("");
|
|
16129
|
+
const searchId = (0, import_react99.useId)();
|
|
16053
16130
|
const clientState = parseClientState8(result?.clientStateJson);
|
|
16054
16131
|
const alreadyPlayed = result?.alreadyPlayed === true;
|
|
16055
16132
|
const header = /* @__PURE__ */ (0, import_jsx_runtime127.jsx)(
|
|
@@ -16188,7 +16265,7 @@ function StartingXiGame({
|
|
|
16188
16265
|
}
|
|
16189
16266
|
|
|
16190
16267
|
// src/components/games/StatLadderGame.tsx
|
|
16191
|
-
var
|
|
16268
|
+
var import_react100 = require("react");
|
|
16192
16269
|
var import_jsx_runtime128 = require("react/jsx-runtime");
|
|
16193
16270
|
function ladderClue(ladder) {
|
|
16194
16271
|
const mystery = ladder.find((r) => r.rank === 2);
|
|
@@ -16225,9 +16302,9 @@ function StatLadderGame({
|
|
|
16225
16302
|
onBack
|
|
16226
16303
|
}) {
|
|
16227
16304
|
const t = ui.games.statLadder;
|
|
16228
|
-
const [query, setQuery] = (0,
|
|
16229
|
-
const [selectedId, setSelectedId] = (0,
|
|
16230
|
-
const searchId = (0,
|
|
16305
|
+
const [query, setQuery] = (0, import_react100.useState)("");
|
|
16306
|
+
const [selectedId, setSelectedId] = (0, import_react100.useState)(null);
|
|
16307
|
+
const searchId = (0, import_react100.useId)();
|
|
16231
16308
|
const clientState = parseClientState9(result?.clientStateJson);
|
|
16232
16309
|
const revealed = clientState != null;
|
|
16233
16310
|
const header = /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(GameHeader, { title: gameTitle({ gameId: "stat-ladder" }, ui.games.titles), eyebrow: t.eyebrow, onBack, backLabel: ui.back });
|
|
@@ -16433,8 +16510,8 @@ function GameScreenHost({
|
|
|
16433
16510
|
ui
|
|
16434
16511
|
}) {
|
|
16435
16512
|
const { gameId, fixtureId, gameDay = "", lockAtUtc = null } = selected;
|
|
16436
|
-
const [configJson, setConfigJson] = (0,
|
|
16437
|
-
(0,
|
|
16513
|
+
const [configJson, setConfigJson] = (0, import_react101.useState)(null);
|
|
16514
|
+
(0, import_react101.useEffect)(() => {
|
|
16438
16515
|
setConfigJson(null);
|
|
16439
16516
|
if (!conversation) return;
|
|
16440
16517
|
let cancelled = false;
|
|
@@ -16457,12 +16534,12 @@ function GameScreenHost({
|
|
|
16457
16534
|
fixtureId: fixtureId || void 0,
|
|
16458
16535
|
locale: ui.hostTag
|
|
16459
16536
|
});
|
|
16460
|
-
(0,
|
|
16537
|
+
(0, import_react101.useEffect)(() => {
|
|
16461
16538
|
if (conversation) hydrate();
|
|
16462
16539
|
}, [conversation, gameId]);
|
|
16463
|
-
const hydrateRef = (0,
|
|
16540
|
+
const hydrateRef = (0, import_react101.useRef)(hydrate);
|
|
16464
16541
|
hydrateRef.current = hydrate;
|
|
16465
|
-
(0,
|
|
16542
|
+
(0, import_react101.useEffect)(() => {
|
|
16466
16543
|
if (!FIXTURE_GAME_IDS.has(gameId)) return;
|
|
16467
16544
|
if (rawStatus !== "pending") return;
|
|
16468
16545
|
const timerId = setInterval(() => {
|
|
@@ -16575,7 +16652,7 @@ function GameScreenHost({
|
|
|
16575
16652
|
}
|
|
16576
16653
|
|
|
16577
16654
|
// src/components/Leaderboard.tsx
|
|
16578
|
-
var
|
|
16655
|
+
var import_react102 = require("react");
|
|
16579
16656
|
|
|
16580
16657
|
// src/components/LeaderboardRow.tsx
|
|
16581
16658
|
var import_jsx_runtime131 = require("react/jsx-runtime");
|
|
@@ -16662,7 +16739,7 @@ function Leaderboard({
|
|
|
16662
16739
|
ui,
|
|
16663
16740
|
onPlay
|
|
16664
16741
|
}) {
|
|
16665
|
-
const [segment, setSegment] = (0,
|
|
16742
|
+
const [segment, setSegment] = (0, import_react102.useState)("weekly");
|
|
16666
16743
|
const myRow = segment === "weekly" ? data.myWeeklyRow : data.myAllTimeRow;
|
|
16667
16744
|
const offBoard = myRow !== null && myRow !== void 0 && myRow.rank === -1;
|
|
16668
16745
|
const isEmpty = segment === "weekly" ? data.weeklyTop.length === 0 : data.allTimeTop.length === 0;
|
|
@@ -16767,9 +16844,9 @@ function GamesPanel({
|
|
|
16767
16844
|
leaderboardLoading,
|
|
16768
16845
|
refreshHub
|
|
16769
16846
|
}) {
|
|
16770
|
-
const [selected, setSelected] = (0,
|
|
16771
|
-
const [segment, setSegment] = (0,
|
|
16772
|
-
(0,
|
|
16847
|
+
const [selected, setSelected] = (0, import_react103.useState)(null);
|
|
16848
|
+
const [segment, setSegment] = (0, import_react103.useState)("play");
|
|
16849
|
+
(0, import_react103.useEffect)(() => {
|
|
16773
16850
|
ensureGamesFonts();
|
|
16774
16851
|
}, []);
|
|
16775
16852
|
if (!loggedIn) return /* @__PURE__ */ (0, import_jsx_runtime135.jsx)(GamesLoginWall, { ui });
|
|
@@ -16833,10 +16910,10 @@ function GamesPanel({
|
|
|
16833
16910
|
}
|
|
16834
16911
|
|
|
16835
16912
|
// src/components/FavouritesPanel.tsx
|
|
16836
|
-
var
|
|
16913
|
+
var import_react106 = require("react");
|
|
16837
16914
|
|
|
16838
16915
|
// src/components/FavouriteChips.tsx
|
|
16839
|
-
var
|
|
16916
|
+
var import_react104 = require("react");
|
|
16840
16917
|
var import_jsx_runtime136 = require("react/jsx-runtime");
|
|
16841
16918
|
async function toggleWithNotice(controller, kind, id, onNotice) {
|
|
16842
16919
|
const outcome = await controller.toggle(kind, id);
|
|
@@ -16883,12 +16960,12 @@ function Group({ title, entities, sport, ui, controller, onNotice }) {
|
|
|
16883
16960
|
] });
|
|
16884
16961
|
}
|
|
16885
16962
|
function FavouriteChips({ controller, ui, sport, sportLabel: sportLabel2, onNotice }) {
|
|
16886
|
-
const [confirming, setConfirming] = (0,
|
|
16963
|
+
const [confirming, setConfirming] = (0, import_react104.useState)(false);
|
|
16887
16964
|
const data = controller.data;
|
|
16888
|
-
(0,
|
|
16965
|
+
(0, import_react104.useEffect)(() => {
|
|
16889
16966
|
setConfirming(false);
|
|
16890
16967
|
}, [sport]);
|
|
16891
|
-
(0,
|
|
16968
|
+
(0, import_react104.useEffect)(() => {
|
|
16892
16969
|
if (!confirming) return;
|
|
16893
16970
|
const onPointerDown = (e) => {
|
|
16894
16971
|
if (!(e.target instanceof Element) || !e.target.closest("[data-fav-confirm]")) setConfirming(false);
|
|
@@ -16942,21 +17019,21 @@ function FavouriteChips({ controller, ui, sport, sportLabel: sportLabel2, onNoti
|
|
|
16942
17019
|
}
|
|
16943
17020
|
|
|
16944
17021
|
// src/components/FavouritesSearch.tsx
|
|
16945
|
-
var
|
|
17022
|
+
var import_react105 = require("react");
|
|
16946
17023
|
var import_jsx_runtime137 = require("react/jsx-runtime");
|
|
16947
17024
|
var MIN_LETTERS = 2;
|
|
16948
17025
|
var MAX_LENGTH = 64;
|
|
16949
17026
|
var DEBOUNCE_MS = 250;
|
|
16950
17027
|
function FavouritesSearch({ controller, ui, sport, onNotice }) {
|
|
16951
|
-
const [query, setQuery] = (0,
|
|
16952
|
-
const [answer, setAnswer] = (0,
|
|
16953
|
-
const controllerRef = (0,
|
|
17028
|
+
const [query, setQuery] = (0, import_react105.useState)("");
|
|
17029
|
+
const [answer, setAnswer] = (0, import_react105.useState)(null);
|
|
17030
|
+
const controllerRef = (0, import_react105.useRef)(controller);
|
|
16954
17031
|
controllerRef.current = controller;
|
|
16955
17032
|
const trimmed = query.trim();
|
|
16956
17033
|
const queryKey = `${sport}|${trimmed}`;
|
|
16957
17034
|
const results2 = answer?.key === queryKey ? answer.rows : [];
|
|
16958
17035
|
const settled = answer?.key === queryKey;
|
|
16959
|
-
(0,
|
|
17036
|
+
(0, import_react105.useEffect)(() => {
|
|
16960
17037
|
setAnswer(null);
|
|
16961
17038
|
if (trimmed.length < MIN_LETTERS) return;
|
|
16962
17039
|
let cancelled = false;
|
|
@@ -17019,13 +17096,13 @@ function FavouritesSearch({ controller, ui, sport, onNotice }) {
|
|
|
17019
17096
|
// src/components/FavouritesPanel.tsx
|
|
17020
17097
|
var import_jsx_runtime138 = require("react/jsx-runtime");
|
|
17021
17098
|
function FavouritesPanel({ controller, ui, sport, sports, onSportChange }) {
|
|
17022
|
-
const [notice, setNotice] = (0,
|
|
17023
|
-
const refreshRef = (0,
|
|
17099
|
+
const [notice, setNotice] = (0, import_react106.useState)(null);
|
|
17100
|
+
const refreshRef = (0, import_react106.useRef)(controller.refresh);
|
|
17024
17101
|
refreshRef.current = controller.refresh;
|
|
17025
|
-
(0,
|
|
17102
|
+
(0, import_react106.useEffect)(() => {
|
|
17026
17103
|
void refreshRef.current();
|
|
17027
17104
|
}, []);
|
|
17028
|
-
(0,
|
|
17105
|
+
(0, import_react106.useEffect)(() => {
|
|
17029
17106
|
setNotice(null);
|
|
17030
17107
|
}, [sport]);
|
|
17031
17108
|
const sportLabel2 = sports.find((s) => s.sport === sport)?.label ?? sportLabel(ui, sport);
|
|
@@ -17051,11 +17128,11 @@ function FavouritesPanel({ controller, ui, sport, sports, onSportChange }) {
|
|
|
17051
17128
|
}
|
|
17052
17129
|
|
|
17053
17130
|
// src/components/PresetTools.tsx
|
|
17054
|
-
var
|
|
17131
|
+
var import_react107 = require("react");
|
|
17055
17132
|
var import_jsx_runtime139 = require("react/jsx-runtime");
|
|
17056
17133
|
function PresetToolModal({ title, closeLabel, onClose, children, footer, className }) {
|
|
17057
17134
|
const { dialogRef, onKeyDown } = useModalDialog(onClose, { restoreFocus: false });
|
|
17058
|
-
const titleId = (0,
|
|
17135
|
+
const titleId = (0, import_react107.useId)();
|
|
17059
17136
|
return /* @__PURE__ */ (0, import_jsx_runtime139.jsx)("div", { className: className ? `ss-w-tool-backdrop ${className}` : "ss-w-tool-backdrop", children: /* @__PURE__ */ (0, import_jsx_runtime139.jsxs)("div", { ref: dialogRef, className: "ss-w-tool", role: "dialog", "aria-modal": "true", "aria-labelledby": titleId, tabIndex: -1, onKeyDown, children: [
|
|
17060
17137
|
/* @__PURE__ */ (0, import_jsx_runtime139.jsxs)("div", { className: "ss-w-tool-head", children: [
|
|
17061
17138
|
/* @__PURE__ */ (0, import_jsx_runtime139.jsx)("h2", { id: titleId, className: "ss-w-tool-title", children: title }),
|
|
@@ -17105,9 +17182,9 @@ function BuildComboTool({ grid, strings, streaming, formatKickoff, initialTotal,
|
|
|
17105
17182
|
const totalOptions = comboTotals(grid);
|
|
17106
17183
|
const totals = totalOptions.map((o) => o.value);
|
|
17107
17184
|
const legChoices = comboLegChoices(grid);
|
|
17108
|
-
const [total, setTotal] = (0,
|
|
17109
|
-
const [legs, setLegs] = (0,
|
|
17110
|
-
const [announcement, setAnnouncement] = (0,
|
|
17185
|
+
const [total, setTotal] = (0, import_react107.useState)(() => nearest(totals, initialTotal));
|
|
17186
|
+
const [legs, setLegs] = (0, import_react107.useState)(() => legsForTotal(grid, nearest(totals, initialTotal), clampLegs(legChoices, initialLegs)));
|
|
17187
|
+
const [announcement, setAnnouncement] = (0, import_react107.useState)("");
|
|
17111
17188
|
const cell2 = findCombo(grid, total, legs);
|
|
17112
17189
|
const minLegs = legChoices[0] ?? legs;
|
|
17113
17190
|
const maxLegs = legChoices[legChoices.length - 1] ?? legs;
|
|
@@ -17146,7 +17223,7 @@ function FavouritesSheet({ ui, controller, sport, sports, onSportChange, onClose
|
|
|
17146
17223
|
}
|
|
17147
17224
|
|
|
17148
17225
|
// src/components/dashboard/v8/SentenceBuilder.tsx
|
|
17149
|
-
var
|
|
17226
|
+
var import_react108 = require("react");
|
|
17150
17227
|
var import_jsx_runtime141 = require("react/jsx-runtime");
|
|
17151
17228
|
var TOTALS = ["any", "3", "5", "10", "20", "50"];
|
|
17152
17229
|
var BASE_LEGS = [1, 2, 3, 4];
|
|
@@ -17172,8 +17249,8 @@ function SentenceBuilder({ preset, ui, conversation, memory: memory3, slip, spor
|
|
|
17172
17249
|
const opening = openingGames(preset);
|
|
17173
17250
|
const gamesOptions = opening.options;
|
|
17174
17251
|
const marketOptions = usableMarkets(preset);
|
|
17175
|
-
const [fingerprint] = (0,
|
|
17176
|
-
const [saved] = (0,
|
|
17252
|
+
const [fingerprint] = (0, import_react108.useState)(() => JSON.stringify(preset));
|
|
17253
|
+
const [saved] = (0, import_react108.useState)(() => {
|
|
17177
17254
|
const kept = memory3?.savedView(sport);
|
|
17178
17255
|
return kept && kept.fingerprint === fingerprint ? kept : null;
|
|
17179
17256
|
});
|
|
@@ -17187,9 +17264,9 @@ function SentenceBuilder({ preset, ui, conversation, memory: memory3, slip, spor
|
|
|
17187
17264
|
// The server never widens by itself: an all-games preset with no ids asks for it.
|
|
17188
17265
|
widen: opening.option ? opening.option.matchIds.length === 0 : preset.gamesScope === "all" && preset.matchIds.length === 0
|
|
17189
17266
|
};
|
|
17190
|
-
const [view, setView] = (0,
|
|
17191
|
-
const autoWidened = (0,
|
|
17192
|
-
const [widenedNote, setWidenedNote] = (0,
|
|
17267
|
+
const [view, setView] = (0, import_react108.useState)(() => saved?.view ?? openingView);
|
|
17268
|
+
const autoWidened = (0, import_react108.useRef)(false);
|
|
17269
|
+
const [widenedNote, setWidenedNote] = (0, import_react108.useState)(saved?.widenedNote ?? false);
|
|
17193
17270
|
const requestFor = (v) => ({
|
|
17194
17271
|
sport,
|
|
17195
17272
|
...v.marketKey !== null ? { marketKey: v.marketKey } : {},
|
|
@@ -17201,10 +17278,10 @@ function SentenceBuilder({ preset, ui, conversation, memory: memory3, slip, spor
|
|
|
17201
17278
|
...operatorUserId ? { operatorUserId } : {},
|
|
17202
17279
|
...anonymousUserId ? { anonymousUserId } : {}
|
|
17203
17280
|
});
|
|
17204
|
-
const [first] = (0,
|
|
17281
|
+
const [first] = (0, import_react108.useState)(() => requestFor(view));
|
|
17205
17282
|
const { grid, status: status2, confirmed, request } = useBuilderGrid({ conversation, locale: ui.hostTag, memory: memory3, initial: first });
|
|
17206
|
-
const lastRequest = (0,
|
|
17207
|
-
(0,
|
|
17283
|
+
const lastRequest = (0, import_react108.useRef)(first);
|
|
17284
|
+
(0, import_react108.useEffect)(() => {
|
|
17208
17285
|
void request(lastRequest.current);
|
|
17209
17286
|
}, [request]);
|
|
17210
17287
|
const send = (req) => {
|
|
@@ -17237,14 +17314,14 @@ function SentenceBuilder({ preset, ui, conversation, memory: memory3, slip, spor
|
|
|
17237
17314
|
const rows = ready && grid.status === "ok" ? legsOf(grid, sport) : null;
|
|
17238
17315
|
const rowSlip = rows ? guardLegsPreMatch(slip, rows, ui) : slip;
|
|
17239
17316
|
useNextKickoffRender(rows ? rows.map((l) => l.kickoffUtc) : []);
|
|
17240
|
-
const [startedNote, setStartedNote] = (0,
|
|
17317
|
+
const [startedNote, setStartedNote] = (0, import_react108.useState)(false);
|
|
17241
17318
|
const anyStarted = rows !== null && rows.some((l) => !preMatchOpen(l.kickoffUtc, Date.now()));
|
|
17242
|
-
(0,
|
|
17319
|
+
(0, import_react108.useEffect)(() => {
|
|
17243
17320
|
if (startedNote && status2 === "ready" && !anyStarted) setStartedNote(false);
|
|
17244
17321
|
}, [startedNote, status2, anyStarted]);
|
|
17245
17322
|
const market = rows?.[0]?.market;
|
|
17246
|
-
const [seen2, setSeen] = (0,
|
|
17247
|
-
(0,
|
|
17323
|
+
const [seen2, setSeen] = (0, import_react108.useState)(null);
|
|
17324
|
+
(0, import_react108.useEffect)(() => {
|
|
17248
17325
|
if (market) setSeen(market);
|
|
17249
17326
|
}, [market]);
|
|
17250
17327
|
const marketName = view.marketKey === null ? null : marketOptions?.find((m) => m.key === view.marketKey)?.label ?? market ?? seen2;
|
|
@@ -17257,14 +17334,14 @@ function SentenceBuilder({ preset, ui, conversation, memory: memory3, slip, spor
|
|
|
17257
17334
|
const quotedAt = rows ? oldestQuote(rows) : null;
|
|
17258
17335
|
const combo = ready && grid.total !== null ? { sport, totalChosen: view.total, totalActual: grid.total } : void 0;
|
|
17259
17336
|
const canWiden = gamesOptions === null || allGames !== null;
|
|
17260
|
-
(0,
|
|
17337
|
+
(0, import_react108.useEffect)(() => {
|
|
17261
17338
|
if (!empty2 || !singles || widened || !canWiden || autoWidened.current) return;
|
|
17262
17339
|
autoWidened.current = true;
|
|
17263
17340
|
const next = { ...view, widen: true, matchIds: [], gamesId: allGames ? allGames.id : view.gamesId };
|
|
17264
17341
|
commit(next, true);
|
|
17265
17342
|
send(requestFor(next));
|
|
17266
17343
|
}, [empty2, singles, widened, canWiden, view]);
|
|
17267
|
-
(0,
|
|
17344
|
+
(0, import_react108.useEffect)(() => {
|
|
17268
17345
|
if (coolOff) onCoolOff?.(sport);
|
|
17269
17346
|
}, [coolOff, onCoolOff, sport]);
|
|
17270
17347
|
if (coolOff) return null;
|
|
@@ -17669,10 +17746,10 @@ function Squad({ squad, loading, ui, view, onToggleView, stats, statsLoading, se
|
|
|
17669
17746
|
}
|
|
17670
17747
|
|
|
17671
17748
|
// src/components/PlayerPhoto.tsx
|
|
17672
|
-
var
|
|
17749
|
+
var import_react109 = require("react");
|
|
17673
17750
|
var import_jsx_runtime147 = require("react/jsx-runtime");
|
|
17674
17751
|
function PlayerPhoto({ photoUrl, jerseyNumber, size }) {
|
|
17675
|
-
const [failed, setFailed] = (0,
|
|
17752
|
+
const [failed, setFailed] = (0, import_react109.useState)(false);
|
|
17676
17753
|
const box = { width: size, height: size };
|
|
17677
17754
|
if (photoUrl && !failed) {
|
|
17678
17755
|
return /* @__PURE__ */ (0, import_jsx_runtime147.jsx)("img", { className: "ss-w-pd-photo", style: box, src: photoUrl, alt: "", "aria-hidden": "true", onError: () => setFailed(true) });
|
|
@@ -17707,7 +17784,7 @@ function MiniPitch({ positionCode }) {
|
|
|
17707
17784
|
}
|
|
17708
17785
|
|
|
17709
17786
|
// src/components/PerformanceBars.tsx
|
|
17710
|
-
var
|
|
17787
|
+
var import_react110 = require("react");
|
|
17711
17788
|
var import_jsx_runtime149 = require("react/jsx-runtime");
|
|
17712
17789
|
var GROUPS = ["shooting", "passing", "possession", "defending"];
|
|
17713
17790
|
function finite4(v) {
|
|
@@ -17753,7 +17830,7 @@ function unrankedLine(ui, reason) {
|
|
|
17753
17830
|
}
|
|
17754
17831
|
}
|
|
17755
17832
|
function PerformanceBars({ performance, competitionName, strings }) {
|
|
17756
|
-
const [mode, setMode] = (0,
|
|
17833
|
+
const [mode, setMode] = (0, import_react110.useState)("total");
|
|
17757
17834
|
const labelled = performance.metrics.filter((m) => Object.prototype.hasOwnProperty.call(strings.perfMetric, m.key));
|
|
17758
17835
|
if (!labelled.some((m) => valueOf(m, "total") !== null || valueOf(m, "per90") !== null)) return null;
|
|
17759
17836
|
const subtitle = !performance.ranked ? unrankedLine(strings, performance.unrankedReason) : competitionName ? strings.perfRankedAgainst(competitionName, performance.positionGroup) : null;
|
|
@@ -17962,8 +18039,8 @@ function SettingsSheet({ ui, onClose }) {
|
|
|
17962
18039
|
var import_jsx_runtime152 = require("react/jsx-runtime");
|
|
17963
18040
|
var FULLSCREEN_QUERY = "(max-width: 639px)";
|
|
17964
18041
|
function useIsModal() {
|
|
17965
|
-
const [modal, setModal] = (0,
|
|
17966
|
-
(0,
|
|
18042
|
+
const [modal, setModal] = (0, import_react111.useState)(false);
|
|
18043
|
+
(0, import_react111.useEffect)(() => {
|
|
17967
18044
|
if (typeof window === "undefined" || typeof window.matchMedia !== "function") return;
|
|
17968
18045
|
const mql = window.matchMedia(FULLSCREEN_QUERY);
|
|
17969
18046
|
const sync = () => setModal(mql.matches);
|
|
@@ -17977,12 +18054,12 @@ var HIDDEN_LAYER_STYLE = { position: "absolute", inset: 0, visibility: "hidden",
|
|
|
17977
18054
|
var SQUAD_LAYER_STYLE = { display: "flex", flexDirection: "column", flex: 1, minHeight: 0 };
|
|
17978
18055
|
function ChatPanel({ controller, ui, slip, onDashboardTap, monitor, discovery, schedule, gamesResult, leaderboardResult, clubFixturesResult, clubStandingsResult, clubSquadResult, clubSquadStatsResult, clubPlayerDetailResult, loggedIn, conversation, presetGrid, favouritesEnabled, favourites, builder, onCloseRequested, onRegisterBack }) {
|
|
17979
18056
|
const { state, close, stop, send, reset } = controller;
|
|
17980
|
-
const [squadView, setSquadView] = (0,
|
|
17981
|
-
const [selectedPlayerId, setSelectedPlayerId] = (0,
|
|
18057
|
+
const [squadView, setSquadView] = (0, import_react111.useState)("roster");
|
|
18058
|
+
const [selectedPlayerId, setSelectedPlayerId] = (0, import_react111.useState)(null);
|
|
17982
18059
|
const clearPlayerDetail = clubPlayerDetailResult?.clear;
|
|
17983
18060
|
const fetchPlayerDetail = clubPlayerDetailResult?.fetch;
|
|
17984
|
-
const squadLayerRef = (0,
|
|
17985
|
-
const squadScrollRef = (0,
|
|
18061
|
+
const squadLayerRef = (0, import_react111.useRef)(null);
|
|
18062
|
+
const squadScrollRef = (0, import_react111.useRef)(null);
|
|
17986
18063
|
const selectPlayer = (playerId) => {
|
|
17987
18064
|
squadScrollRef.current = squadLayerRef.current?.querySelector(".ss-w-mon-list")?.scrollTop ?? null;
|
|
17988
18065
|
setSelectedPlayerId(playerId);
|
|
@@ -17992,7 +18069,7 @@ function ChatPanel({ controller, ui, slip, onDashboardTap, monitor, discovery, s
|
|
|
17992
18069
|
setSelectedPlayerId(null);
|
|
17993
18070
|
clearPlayerDetail?.();
|
|
17994
18071
|
};
|
|
17995
|
-
(0,
|
|
18072
|
+
(0, import_react111.useLayoutEffect)(() => {
|
|
17996
18073
|
if (selectedPlayerId !== null || squadScrollRef.current === null) return;
|
|
17997
18074
|
const list = squadLayerRef.current?.querySelector(".ss-w-mon-list");
|
|
17998
18075
|
if (list) list.scrollTop = squadScrollRef.current;
|
|
@@ -18005,7 +18082,7 @@ function ChatPanel({ controller, ui, slip, onDashboardTap, monitor, discovery, s
|
|
|
18005
18082
|
const hasBuilder = !clubBrand && (builderOptions?.length ?? 0) > 0;
|
|
18006
18083
|
const tabs = monitor ?? (hasBuilder ? tabState : void 0);
|
|
18007
18084
|
const activeTab = tabs?.activeTab;
|
|
18008
|
-
(0,
|
|
18085
|
+
(0, import_react111.useEffect)(() => {
|
|
18009
18086
|
if (activeTab === "squad" || selectedPlayerId === null) return;
|
|
18010
18087
|
setSelectedPlayerId(null);
|
|
18011
18088
|
clearPlayerDetail?.();
|
|
@@ -18014,11 +18091,11 @@ function ChatPanel({ controller, ui, slip, onDashboardTap, monitor, discovery, s
|
|
|
18014
18091
|
const favouritesOpen = favouritesOffered && (favourites?.open ?? false);
|
|
18015
18092
|
const favouritesAskedOpen = favourites?.open ?? false;
|
|
18016
18093
|
const setFavouritesOpen = favourites?.onOpenChange;
|
|
18017
|
-
(0,
|
|
18094
|
+
(0, import_react111.useEffect)(() => {
|
|
18018
18095
|
if (favouritesAskedOpen && !favouritesOffered) setFavouritesOpen?.(false);
|
|
18019
18096
|
}, [favouritesAskedOpen, favouritesOffered, setFavouritesOpen]);
|
|
18020
18097
|
const storedTab = tabState?.activeTab;
|
|
18021
|
-
(0,
|
|
18098
|
+
(0, import_react111.useEffect)(() => {
|
|
18022
18099
|
const unreachable = storedTab === "builder" ? !hasBuilder : !monitor && storedTab !== void 0 && storedTab !== "chat";
|
|
18023
18100
|
if (unreachable) setMonitorTab?.("chat");
|
|
18024
18101
|
}, [storedTab, hasBuilder, monitor, setMonitorTab]);
|
|
@@ -18027,12 +18104,12 @@ function ChatPanel({ controller, ui, slip, onDashboardTap, monitor, discovery, s
|
|
|
18027
18104
|
const closeTab = tabs?.activeTab ?? "chat";
|
|
18028
18105
|
const lastMessage = state.messages[state.messages.length - 1];
|
|
18029
18106
|
const answering = state.isStreaming && !(lastMessage?.role === "assistant" && lastMessage.isGreeting);
|
|
18030
|
-
const closeWith = (0,
|
|
18107
|
+
const closeWith = (0, import_react111.useCallback)((method) => {
|
|
18031
18108
|
track({ name: "widget_close", method, tab: closeTab, answering });
|
|
18032
18109
|
if (onCloseRequested) onCloseRequested();
|
|
18033
18110
|
else close();
|
|
18034
18111
|
}, [track, closeTab, answering, close, onCloseRequested]);
|
|
18035
|
-
(0,
|
|
18112
|
+
(0, import_react111.useEffect)(() => {
|
|
18036
18113
|
const onKey = (e) => {
|
|
18037
18114
|
if (e.key === "Escape") closeWith("escape");
|
|
18038
18115
|
};
|
|
@@ -18048,80 +18125,80 @@ function ChatPanel({ controller, ui, slip, onDashboardTap, monitor, discovery, s
|
|
|
18048
18125
|
tabs?.setActiveTab("chat");
|
|
18049
18126
|
send(text2, { grounding, source });
|
|
18050
18127
|
};
|
|
18051
|
-
(0,
|
|
18128
|
+
(0, import_react111.useEffect)(() => {
|
|
18052
18129
|
if (monitor && monitor.activeTab !== "chat" && state.isStreaming) monitor.markChatActivity();
|
|
18053
18130
|
}, [monitor, state.isStreaming, state.messages.length]);
|
|
18054
18131
|
const onChatTab = !tabs || tabs.activeTab === "chat";
|
|
18055
|
-
const inputRef = (0,
|
|
18056
|
-
const limitRef = (0,
|
|
18057
|
-
const typedSendRef = (0,
|
|
18058
|
-
const focusAfterCloseRef = (0,
|
|
18059
|
-
const [tool, setTool] = (0,
|
|
18060
|
-
const panelRef = (0,
|
|
18132
|
+
const inputRef = (0, import_react111.useRef)(null);
|
|
18133
|
+
const limitRef = (0, import_react111.useRef)(null);
|
|
18134
|
+
const typedSendRef = (0, import_react111.useRef)(false);
|
|
18135
|
+
const focusAfterCloseRef = (0, import_react111.useRef)(null);
|
|
18136
|
+
const [tool, setTool] = (0, import_react111.useState)(null);
|
|
18137
|
+
const panelRef = (0, import_react111.useRef)(null);
|
|
18061
18138
|
const settings = useOddsSettings();
|
|
18062
|
-
const [settingsOpen, setSettingsOpen] = (0,
|
|
18139
|
+
const [settingsOpen, setSettingsOpen] = (0, import_react111.useState)(false);
|
|
18063
18140
|
const hasSettings = settings.oddsOffered || !settings.themeLocked;
|
|
18064
|
-
const openSettings = (0,
|
|
18141
|
+
const openSettings = (0, import_react111.useCallback)(() => {
|
|
18065
18142
|
setTool(null);
|
|
18066
18143
|
setFavouritesOpen?.(false);
|
|
18067
18144
|
setSettingsOpen(true);
|
|
18068
18145
|
}, [setFavouritesOpen]);
|
|
18069
|
-
const closeSettings = (0,
|
|
18146
|
+
const closeSettings = (0, import_react111.useCallback)(() => {
|
|
18070
18147
|
setSettingsOpen(false);
|
|
18071
18148
|
panelRef.current?.querySelector(".ss-w-kebab")?.focus();
|
|
18072
18149
|
}, []);
|
|
18073
|
-
const openFavourites = (0,
|
|
18074
|
-
const closeFavourites = (0,
|
|
18150
|
+
const openFavourites = (0, import_react111.useCallback)(() => setFavouritesOpen?.(true), [setFavouritesOpen]);
|
|
18151
|
+
const closeFavourites = (0, import_react111.useCallback)(() => {
|
|
18075
18152
|
setFavouritesOpen?.(false);
|
|
18076
18153
|
panelRef.current?.querySelector(".ss-w-kebab")?.focus();
|
|
18077
18154
|
}, [setFavouritesOpen]);
|
|
18078
|
-
(0,
|
|
18155
|
+
(0, import_react111.useEffect)(() => {
|
|
18079
18156
|
if (!favouritesOpen) return;
|
|
18080
18157
|
setTool(null);
|
|
18081
18158
|
setSettingsOpen(false);
|
|
18082
18159
|
}, [favouritesOpen]);
|
|
18083
18160
|
const paused = isPaused(state.limit);
|
|
18084
|
-
(0,
|
|
18161
|
+
(0, import_react111.useEffect)(() => {
|
|
18085
18162
|
if (paused) setTool(null);
|
|
18086
18163
|
}, [paused]);
|
|
18087
|
-
(0,
|
|
18164
|
+
(0, import_react111.useEffect)(() => {
|
|
18088
18165
|
if (!paused) return;
|
|
18089
18166
|
if (typedSendRef.current) limitRef.current?.focus();
|
|
18090
18167
|
typedSendRef.current = false;
|
|
18091
18168
|
}, [paused]);
|
|
18092
|
-
const openTool = (0,
|
|
18169
|
+
const openTool = (0, import_react111.useCallback)((next) => {
|
|
18093
18170
|
setTool(next);
|
|
18094
18171
|
}, []);
|
|
18095
|
-
const toolsValue = (0,
|
|
18172
|
+
const toolsValue = (0, import_react111.useMemo)(
|
|
18096
18173
|
() => presetGrid && !paused ? { openBuilder: (total, legs) => openTool({ total, legs }), changeLabel: ui.presets.changeCombo } : null,
|
|
18097
18174
|
[presetGrid, paused, openTool, ui.presets.changeCombo]
|
|
18098
18175
|
);
|
|
18099
|
-
const closeTool = (0,
|
|
18176
|
+
const closeTool = (0, import_react111.useCallback)(() => {
|
|
18100
18177
|
focusAfterCloseRef.current = "composer";
|
|
18101
18178
|
setTool(null);
|
|
18102
18179
|
}, []);
|
|
18103
|
-
const sendAsk = (0,
|
|
18180
|
+
const sendAsk = (0, import_react111.useCallback)((ask) => {
|
|
18104
18181
|
focusAfterCloseRef.current = "composer";
|
|
18105
18182
|
setTool(null);
|
|
18106
18183
|
tabs?.setActiveTab("chat");
|
|
18107
18184
|
send(ask.message, { displayText: ask.displayText, preset: ask.preset, source: "preset" });
|
|
18108
18185
|
}, [tabs, send]);
|
|
18109
|
-
const formatKickoff = (0,
|
|
18186
|
+
const formatKickoff = (0, import_react111.useCallback)((kickoffUtc) => {
|
|
18110
18187
|
const k = ui.bettingKickoff(kickoffUtc);
|
|
18111
18188
|
return `${k.dayLabel} ${k.time}`;
|
|
18112
18189
|
}, [ui]);
|
|
18113
|
-
(0,
|
|
18190
|
+
(0, import_react111.useEffect)(() => {
|
|
18114
18191
|
if (tool) return;
|
|
18115
18192
|
const target = focusAfterCloseRef.current;
|
|
18116
18193
|
focusAfterCloseRef.current = null;
|
|
18117
18194
|
if (target === "composer") inputRef.current?.focus();
|
|
18118
18195
|
}, [tool]);
|
|
18119
|
-
(0,
|
|
18196
|
+
(0, import_react111.useEffect)(() => {
|
|
18120
18197
|
if (!tool || onChatTab && presetGrid) return;
|
|
18121
18198
|
focusAfterCloseRef.current = "composer";
|
|
18122
18199
|
setTool(null);
|
|
18123
18200
|
}, [tool, onChatTab, presetGrid]);
|
|
18124
|
-
const backRef = (0,
|
|
18201
|
+
const backRef = (0, import_react111.useRef)(() => false);
|
|
18125
18202
|
backRef.current = () => {
|
|
18126
18203
|
if (favouritesOpen) {
|
|
18127
18204
|
closeFavourites();
|
|
@@ -18145,7 +18222,7 @@ function ChatPanel({ controller, ui, slip, onDashboardTap, monitor, discovery, s
|
|
|
18145
18222
|
}
|
|
18146
18223
|
return false;
|
|
18147
18224
|
};
|
|
18148
|
-
(0,
|
|
18225
|
+
(0, import_react111.useEffect)(() => {
|
|
18149
18226
|
if (!onRegisterBack) return;
|
|
18150
18227
|
onRegisterBack(() => backRef.current());
|
|
18151
18228
|
return () => onRegisterBack(null);
|
|
@@ -21104,6 +21181,7 @@ var WIDGET_CSS = `.ss-w-root { all: revert; }
|
|
|
21104
21181
|
|
|
21105
21182
|
// src/StatsWidget.tsx
|
|
21106
21183
|
var import_jsx_runtime154 = require("react/jsx-runtime");
|
|
21184
|
+
var NO_OWNER = {};
|
|
21107
21185
|
function buildClient(props) {
|
|
21108
21186
|
try {
|
|
21109
21187
|
if ("client" in props && props.client) {
|
|
@@ -21128,12 +21206,12 @@ function injectStyles(root) {
|
|
|
21128
21206
|
function StatsWidget(props) {
|
|
21129
21207
|
const injectedClient = "client" in props ? props.client : void 0;
|
|
21130
21208
|
const cfg = props.config;
|
|
21131
|
-
const built = (0,
|
|
21132
|
-
const trackingRef = (0,
|
|
21133
|
-
const track = (0,
|
|
21134
|
-
const eventTextRef = (0,
|
|
21209
|
+
const built = (0, import_react112.useMemo)(() => buildClient(props), [injectedClient, cfg?.operatorId, cfg?.publicKey, cfg?.baseUrl]);
|
|
21210
|
+
const trackingRef = (0, import_react112.useRef)({ envelope: { operatorId: "", widgetVersion: WIDGET_REACT_VERSION } });
|
|
21211
|
+
const track = (0, import_react112.useMemo)(() => createTracker(() => trackingRef.current), []);
|
|
21212
|
+
const eventTextRef = (0, import_react112.useRef)(false);
|
|
21135
21213
|
eventTextRef.current = cfg?.eventText === true;
|
|
21136
|
-
const logger = (0,
|
|
21214
|
+
const logger = (0, import_react112.useMemo)(() => {
|
|
21137
21215
|
if (!built) return null;
|
|
21138
21216
|
const raw = built.client.createEventLogger({
|
|
21139
21217
|
operatorUserId: cfg?.userContext?.operatorUserId,
|
|
@@ -21143,27 +21221,27 @@ function StatsWidget(props) {
|
|
|
21143
21221
|
}, [built?.client, track]);
|
|
21144
21222
|
const widgetStrings = useWidgetStrings(cfg, built?.conversation ?? null);
|
|
21145
21223
|
const stringsPending = widgetStrings.strings === void 0;
|
|
21146
|
-
const ui = (0,
|
|
21224
|
+
const ui = (0, import_react112.useMemo)(
|
|
21147
21225
|
() => normalizeUi(props.config ?? { operatorId: "", publicKey: "" }, widgetStrings.strings ?? BUNDLED),
|
|
21148
21226
|
[props.config, widgetStrings.strings]
|
|
21149
21227
|
);
|
|
21150
21228
|
const oddsSettings = useOddsSettingsState(ui, built?.conversation, cfg?.operatorId || "default");
|
|
21151
|
-
const rootRef = (0,
|
|
21152
|
-
const introDoneRef = (0,
|
|
21153
|
-
const markIntroDone = (0,
|
|
21229
|
+
const rootRef = (0, import_react112.useRef)(null);
|
|
21230
|
+
const introDoneRef = (0, import_react112.useRef)(false);
|
|
21231
|
+
const markIntroDone = (0, import_react112.useCallback)(() => {
|
|
21154
21232
|
introDoneRef.current = true;
|
|
21155
21233
|
}, []);
|
|
21156
21234
|
const language = injectedClient ? void 0 : hostTag(cfg);
|
|
21157
21235
|
const threadLanguage = familyOf(language);
|
|
21158
21236
|
const convStorageKey = `ss-w-conv:${cfg?.operatorId ?? ""}:${cfg?.userContext?.operatorUserId ?? "anon"}${threadLanguage ? `:lang=${threadLanguage}` : ""}`;
|
|
21159
|
-
const sportScope = (0,
|
|
21237
|
+
const sportScope = (0, import_react112.useMemo)(
|
|
21160
21238
|
() => ({ operatorId: cfg?.operatorId ?? "", operatorUserId: cfg?.userContext?.operatorUserId, anonymousUserId: cfg?.userContext?.anonymousUserId }),
|
|
21161
21239
|
[cfg?.operatorId, cfg?.userContext?.operatorUserId, cfg?.userContext?.anonymousUserId]
|
|
21162
21240
|
);
|
|
21163
|
-
const chatTracking = (0,
|
|
21241
|
+
const chatTracking = (0, import_react112.useMemo)(() => ({ track, eventText: () => eventTextRef.current }), [track]);
|
|
21164
21242
|
const controller = useChatStream(built?.conversation ?? emptyConversation(), ui.starters, built ? ui.greetingMessage : void 0, convStorageKey, cfg?.page, sportScope, language, chatTracking, injectedClient ? oddsSettings.userOddsFormat : oddsSettings.oddsFormat);
|
|
21165
21243
|
const panelOpen = controller.state.isOpen && !stringsPending;
|
|
21166
|
-
const liveCardWatches = (0,
|
|
21244
|
+
const liveCardWatches = (0, import_react112.useMemo)(() => {
|
|
21167
21245
|
const seen2 = /* @__PURE__ */ new Set();
|
|
21168
21246
|
const out = [];
|
|
21169
21247
|
for (const msg of controller.state.messages) {
|
|
@@ -21189,19 +21267,19 @@ function StatsWidget(props) {
|
|
|
21189
21267
|
});
|
|
21190
21268
|
const operatorUserId = cfg?.userContext?.operatorUserId;
|
|
21191
21269
|
const anonymousUserId = cfg?.userContext?.anonymousUserId;
|
|
21192
|
-
const getSchedule = (0,
|
|
21270
|
+
const getSchedule = (0, import_react112.useCallback)(
|
|
21193
21271
|
(localDate, utcOffsetMinutes) => built ? built.conversation.getSchedule(localDate, utcOffsetMinutes, operatorUserId, anonymousUserId) : Promise.resolve(null),
|
|
21194
21272
|
[built, operatorUserId, anonymousUserId]
|
|
21195
21273
|
);
|
|
21196
|
-
const getStates = (0,
|
|
21274
|
+
const getStates = (0, import_react112.useCallback)(
|
|
21197
21275
|
(matchIds, nbaGameIds, nflGameIds, tennisMatches) => built ? built.conversation.getStates(matchIds, nbaGameIds, nflGameIds, requestTag, tennisMatches) : Promise.resolve(null),
|
|
21198
21276
|
[built, requestTag]
|
|
21199
21277
|
);
|
|
21200
|
-
const getTennisPrices = (0,
|
|
21278
|
+
const getTennisPrices = (0, import_react112.useCallback)(
|
|
21201
21279
|
(keys) => built ? built.conversation.getStates([], [], [], requestTag, [], keys).then((p) => p?.tennisPrices ?? null) : Promise.resolve(null),
|
|
21202
21280
|
[built, requestTag]
|
|
21203
21281
|
);
|
|
21204
|
-
const pinnedMatchIds = (0,
|
|
21282
|
+
const pinnedMatchIds = (0, import_react112.useMemo)(
|
|
21205
21283
|
() => footballMatchPinIds(monitor.pins),
|
|
21206
21284
|
[monitor.pins]
|
|
21207
21285
|
);
|
|
@@ -21215,13 +21293,13 @@ function StatsWidget(props) {
|
|
|
21215
21293
|
pinnedMatchIds,
|
|
21216
21294
|
timeZone: ui.timeZone
|
|
21217
21295
|
});
|
|
21218
|
-
const offeredSports = (0,
|
|
21296
|
+
const offeredSports = (0, import_react112.useMemo)(() => {
|
|
21219
21297
|
const seen2 = new Set(discovery.matchDays.map((d) => d.sport));
|
|
21220
21298
|
for (const g of discovery.groups) seen2.add(g.sport ?? "football");
|
|
21221
21299
|
return [...seen2];
|
|
21222
21300
|
}, [discovery.matchDays, discovery.groups]);
|
|
21223
21301
|
const scheduleSport = useScheduleSport(offeredSports);
|
|
21224
|
-
const [liveLeague, setLiveLeague] = (0,
|
|
21302
|
+
const [liveLeague, setLiveLeague] = (0, import_react112.useState)(null);
|
|
21225
21303
|
const [matchesDay, setMatchesDay] = useMatchesDayPick(discovery.localDate);
|
|
21226
21304
|
const matchesLoaded = useMatchesDay({
|
|
21227
21305
|
discovery,
|
|
@@ -21231,8 +21309,8 @@ function StatsWidget(props) {
|
|
|
21231
21309
|
enabled: panelOpen && monitor.activeTab === "matches",
|
|
21232
21310
|
timeZone: ui.timeZone
|
|
21233
21311
|
});
|
|
21234
|
-
const prevLiveSnapshotRef = (0,
|
|
21235
|
-
(0,
|
|
21312
|
+
const prevLiveSnapshotRef = (0, import_react112.useRef)(monitor.snapshot);
|
|
21313
|
+
(0, import_react112.useEffect)(() => {
|
|
21236
21314
|
const snap = monitor.snapshot;
|
|
21237
21315
|
if (!snap || snap === prevLiveSnapshotRef.current) return;
|
|
21238
21316
|
prevLiveSnapshotRef.current = snap;
|
|
@@ -21272,14 +21350,14 @@ function StatsWidget(props) {
|
|
|
21272
21350
|
const clubSquadResult = useClubSquad(built?.conversation ?? null, { activeTab: monitor.activeTab, enabled: clubFixturesResult.enabled });
|
|
21273
21351
|
const clubSquadStatsResult = useClubSquadStats(built?.conversation ?? null, { activeTab: monitor.activeTab, enabled: clubFixturesResult.enabled });
|
|
21274
21352
|
const clubPlayerDetailResult = useClubPlayerDetail(built?.conversation ?? null);
|
|
21275
|
-
const [favSportPick, setFavSportPick] = (0,
|
|
21276
|
-
const latestGreeting = (0,
|
|
21353
|
+
const [favSportPick, setFavSportPick] = (0, import_react112.useState)(null);
|
|
21354
|
+
const latestGreeting = (0, import_react112.useMemo)(() => {
|
|
21277
21355
|
for (const m of [...controller.state.messages].reverse()) {
|
|
21278
21356
|
if (m.role === "assistant" && m.defaultSport !== void 0) return m;
|
|
21279
21357
|
}
|
|
21280
21358
|
return null;
|
|
21281
21359
|
}, [controller.state.messages]);
|
|
21282
|
-
const favSportOptions = (0,
|
|
21360
|
+
const favSportOptions = (0, import_react112.useMemo)(
|
|
21283
21361
|
() => (switchSets(latestGreeting?.greetingDashboards) ?? []).map((set) => ({ sport: set.sport, label: set.label })),
|
|
21284
21362
|
[latestGreeting]
|
|
21285
21363
|
);
|
|
@@ -21288,20 +21366,20 @@ function StatsWidget(props) {
|
|
|
21288
21366
|
const favSport = [favSportPick, rememberedSport, latestGreeting?.defaultSport].find(offered) ?? "football";
|
|
21289
21367
|
const favSports = favSportOptions.length > 0 ? favSportOptions : [{ sport: favSport, label: sportLabel(ui, favSport) }];
|
|
21290
21368
|
const hasFavouritesIdentity = !!(operatorUserId || anonymousUserId);
|
|
21291
|
-
const [builderSportPick, setBuilderSportPick] = (0,
|
|
21292
|
-
const builderGreeting = (0,
|
|
21369
|
+
const [builderSportPick, setBuilderSportPick] = (0, import_react112.useState)(null);
|
|
21370
|
+
const builderGreeting = (0, import_react112.useMemo)(
|
|
21293
21371
|
() => [...controller.state.messages].reverse().find((m) => m.role === "assistant" && (m.greetingDashboard !== void 0 || m.greetingDashboards !== void 0)) ?? null,
|
|
21294
21372
|
[controller.state.messages]
|
|
21295
21373
|
);
|
|
21296
|
-
const [coolOff, setCoolOff] = (0,
|
|
21297
|
-
const onBuilderCoolOff = (0,
|
|
21374
|
+
const [coolOff, setCoolOff] = (0, import_react112.useState)(null);
|
|
21375
|
+
const onBuilderCoolOff = (0, import_react112.useCallback)((sport) => {
|
|
21298
21376
|
if (!builderGreeting) return;
|
|
21299
21377
|
setCoolOff((prev) => {
|
|
21300
21378
|
const sports = prev?.greeting === builderGreeting ? prev.sports : [];
|
|
21301
21379
|
return sports.includes(sport) ? prev : { greeting: builderGreeting, sports: [...sports, sport] };
|
|
21302
21380
|
});
|
|
21303
21381
|
}, [builderGreeting]);
|
|
21304
|
-
const builderOptions = (0,
|
|
21382
|
+
const builderOptions = (0, import_react112.useMemo)(() => {
|
|
21305
21383
|
const greeting = builderGreeting;
|
|
21306
21384
|
if (!greeting) return [];
|
|
21307
21385
|
const cooled = coolOff?.greeting === greeting ? coolOff.sports : [];
|
|
@@ -21314,7 +21392,7 @@ function StatsWidget(props) {
|
|
|
21314
21392
|
return options.filter((o) => !cooled.includes(o.sport));
|
|
21315
21393
|
}, [builderGreeting, coolOff, ui]);
|
|
21316
21394
|
const builderSport = [builderSportPick, rememberedSport, latestGreeting?.defaultSport].find((s) => !!s && builderOptions.some((o) => o.sport === s)) ?? builderOptions[0]?.sport ?? "";
|
|
21317
|
-
const [panelEverOpened, setPanelEverOpened] = (0,
|
|
21395
|
+
const [panelEverOpened, setPanelEverOpened] = (0, import_react112.useState)(panelOpen);
|
|
21318
21396
|
if (panelOpen && !panelEverOpened) setPanelEverOpened(true);
|
|
21319
21397
|
const favourites = useFavourites({
|
|
21320
21398
|
conversation: built?.conversation ?? null,
|
|
@@ -21326,16 +21404,16 @@ function StatsWidget(props) {
|
|
|
21326
21404
|
onChanged: discovery.refreshSchedule
|
|
21327
21405
|
});
|
|
21328
21406
|
const favouritesEnabled = hasFavouritesIdentity && favourites.status !== "refused";
|
|
21329
|
-
const [favouritesOpen, setFavouritesOpen] = (0,
|
|
21407
|
+
const [favouritesOpen, setFavouritesOpen] = (0, import_react112.useState)(false);
|
|
21330
21408
|
if (!panelOpen && favouritesOpen) setFavouritesOpen(false);
|
|
21331
|
-
const getPricePresets = (0,
|
|
21409
|
+
const getPricePresets = (0, import_react112.useCallback)(
|
|
21332
21410
|
(locale) => built ? built.conversation.getPricePresets(locale, { pool: "open" }) : Promise.resolve(null),
|
|
21333
21411
|
[built]
|
|
21334
21412
|
);
|
|
21335
21413
|
const presetGrid = usePresetGrid({ getPricePresets, isOpen: panelOpen, locale: ui.hostTag });
|
|
21336
21414
|
const markLiveActivity = monitor.markLiveActivity;
|
|
21337
|
-
const prevLiveCountRef = (0,
|
|
21338
|
-
(0,
|
|
21415
|
+
const prevLiveCountRef = (0, import_react112.useRef)(0);
|
|
21416
|
+
(0, import_react112.useEffect)(() => {
|
|
21339
21417
|
const rose = prevLiveCountRef.current === 0 && discovery.liveCount > 0;
|
|
21340
21418
|
prevLiveCountRef.current = discovery.liveCount;
|
|
21341
21419
|
if (rose) markLiveActivity();
|
|
@@ -21349,7 +21427,7 @@ function StatsWidget(props) {
|
|
|
21349
21427
|
closePanel: controller.close
|
|
21350
21428
|
});
|
|
21351
21429
|
const markAdded = hostEvents.markAdded;
|
|
21352
|
-
const slip = (0,
|
|
21430
|
+
const slip = (0, import_react112.useMemo)(
|
|
21353
21431
|
() => {
|
|
21354
21432
|
const handler = props.config?.onAddToSlip;
|
|
21355
21433
|
return {
|
|
@@ -21369,7 +21447,7 @@ function StatsWidget(props) {
|
|
|
21369
21447
|
},
|
|
21370
21448
|
[props.config?.onAddToSlip, props.config?.slipSports, controller.state.conversationId, markAdded]
|
|
21371
21449
|
);
|
|
21372
|
-
const onDashboardTap = (0,
|
|
21450
|
+
const onDashboardTap = (0, import_react112.useMemo)(
|
|
21373
21451
|
() => built ? createDashboardTapSignal((input) => built.conversation.sendSignal(input), logger) : void 0,
|
|
21374
21452
|
[built, logger]
|
|
21375
21453
|
);
|
|
@@ -21383,7 +21461,7 @@ function StatsWidget(props) {
|
|
|
21383
21461
|
log: logger
|
|
21384
21462
|
})
|
|
21385
21463
|
}));
|
|
21386
|
-
const dismissPopupRef = (0,
|
|
21464
|
+
const dismissPopupRef = (0, import_react112.useRef)(() => {
|
|
21387
21465
|
});
|
|
21388
21466
|
const mobile = useMobileBinding({
|
|
21389
21467
|
binding: props.mobile,
|
|
@@ -21396,11 +21474,17 @@ function StatsWidget(props) {
|
|
|
21396
21474
|
});
|
|
21397
21475
|
const dismissPopup = usePopupTelemetry(logger, panelOpen, controller.state.popupText, controller.dismissPopup, mobile.confirmedShown);
|
|
21398
21476
|
dismissPopupRef.current = dismissPopup;
|
|
21477
|
+
const greetingMeta = latestGreetingMeta(controller.state.messages);
|
|
21478
|
+
useBubbleGreetingShown(logger, logger ?? NO_OWNER, controller.state.popupText, props.mobile ? void 0 : greetingMeta, mobile.confirmedShown);
|
|
21479
|
+
const onBubbleClick = (0, import_react112.useCallback)(() => {
|
|
21480
|
+
if (!logger || !greetingMeta) return;
|
|
21481
|
+
logger.log({ name: "greeting_cta_click", greeting: { greetingId: greetingMeta.greetingId, case: greetingMeta.case, sport: greetingMeta.sport, market: greetingMeta.market ?? null } });
|
|
21482
|
+
}, [logger, greetingMeta]);
|
|
21399
21483
|
useOpenTelemetry(logger, panelOpen);
|
|
21400
|
-
const onControlRef = (0,
|
|
21484
|
+
const onControlRef = (0, import_react112.useRef)(props.onControl);
|
|
21401
21485
|
onControlRef.current = props.onControl;
|
|
21402
21486
|
const { open: openPanel, close: closePanel } = controller;
|
|
21403
|
-
(0,
|
|
21487
|
+
(0, import_react112.useEffect)(() => {
|
|
21404
21488
|
onControlRef.current?.({ open: openPanel, close: closePanel });
|
|
21405
21489
|
return () => onControlRef.current?.(null);
|
|
21406
21490
|
}, [openPanel, closePanel]);
|
|
@@ -21417,11 +21501,11 @@ function StatsWidget(props) {
|
|
|
21417
21501
|
page: cfg?.page
|
|
21418
21502
|
}
|
|
21419
21503
|
};
|
|
21420
|
-
(0,
|
|
21504
|
+
(0, import_react112.useEffect)(() => {
|
|
21421
21505
|
if (!logger) return;
|
|
21422
21506
|
logger.setIdentity({ operatorUserId, anonymousUserId, conversationId });
|
|
21423
21507
|
}, [logger, operatorUserId, anonymousUserId, conversationId]);
|
|
21424
|
-
(0,
|
|
21508
|
+
(0, import_react112.useEffect)(() => {
|
|
21425
21509
|
if (!logger) return;
|
|
21426
21510
|
logger.resume();
|
|
21427
21511
|
const onHide = () => {
|
|
@@ -21439,15 +21523,15 @@ function StatsWidget(props) {
|
|
|
21439
21523
|
logger.dispose();
|
|
21440
21524
|
};
|
|
21441
21525
|
}, [logger]);
|
|
21442
|
-
(0,
|
|
21526
|
+
(0, import_react112.useEffect)(() => {
|
|
21443
21527
|
if (!built || !ui.injectStyles || widgetStrings.state === "unavailable") return;
|
|
21444
21528
|
const node = rootRef.current?.getRootNode();
|
|
21445
21529
|
if (node) injectStyles(node);
|
|
21446
21530
|
}, [built, ui.injectStyles, widgetStrings.state]);
|
|
21447
21531
|
const holds = useSessionHolds();
|
|
21448
21532
|
const builderConversation = built?.conversation ?? null;
|
|
21449
|
-
const builderMemory = (0,
|
|
21450
|
-
const personalGreeting = (0,
|
|
21533
|
+
const builderMemory = (0, import_react112.useMemo)(() => createBuilderMemory(), [builderConversation, controller.state.threadEpoch]);
|
|
21534
|
+
const personalGreeting = (0, import_react112.useMemo)(() => ({
|
|
21451
21535
|
favourites: favouritesEnabled && monitor.enabled ? favourites : null,
|
|
21452
21536
|
conversation: built?.conversation ?? null,
|
|
21453
21537
|
openFavourites: () => setFavouritesOpen(true),
|
|
@@ -21509,7 +21593,8 @@ function StatsWidget(props) {
|
|
|
21509
21593
|
dismissLabel: ui.dismissGreeting,
|
|
21510
21594
|
introAllowed: !introDoneRef.current,
|
|
21511
21595
|
onIntroStart: markIntroDone,
|
|
21512
|
-
asks
|
|
21596
|
+
asks,
|
|
21597
|
+
onBubbleClick
|
|
21513
21598
|
}
|
|
21514
21599
|
) }) }) }) }) }) });
|
|
21515
21600
|
}
|