@sensiblestats/widget-react 0.48.1 → 0.48.2
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 +6 -0
- package/dist/index.cjs +5 -4
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +5 -4
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
# @sensiblestats/widget-react
|
|
2
2
|
|
|
3
|
+
## 0.48.2
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- A match that finished more than three and a half hours ago now shows FT and its score instead of its kickoff time and a dash. The Today tab stopped asking about a match once a fixed window after kickoff elapsed, so on a cold load the earliest of the day's matches never had a state at all.
|
|
8
|
+
|
|
3
9
|
## 0.48.1
|
|
4
10
|
|
|
5
11
|
### Patch Changes
|
package/dist/index.cjs
CHANGED
|
@@ -1535,14 +1535,15 @@ function writeSchedule(operatorId, localDate, payload, nowMs) {
|
|
|
1535
1535
|
}
|
|
1536
1536
|
|
|
1537
1537
|
// src/dueSet.ts
|
|
1538
|
-
var
|
|
1538
|
+
var TERMINAL_PHASES = /* @__PURE__ */ new Set(["fullTime", "postponed"]);
|
|
1539
1539
|
function dueMatchIds(groups, states, nowMs) {
|
|
1540
1540
|
const due = /* @__PURE__ */ new Set();
|
|
1541
1541
|
for (const group of groups) {
|
|
1542
1542
|
for (const match of group.matches) {
|
|
1543
|
-
|
|
1544
|
-
|
|
1545
|
-
if (
|
|
1543
|
+
if (nowMs - match.kickoffUnix * 1e3 < 0) continue;
|
|
1544
|
+
const phase = states[match.matchId]?.phase;
|
|
1545
|
+
if (phase !== void 0 && TERMINAL_PHASES.has(phase)) continue;
|
|
1546
|
+
due.add(match.matchId);
|
|
1546
1547
|
}
|
|
1547
1548
|
}
|
|
1548
1549
|
return [...due];
|