@opndev/tennis-match-center 0.0.4 → 0.0.5
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/Changes +9 -0
- package/lib/index.mjs +1 -1
- package/lib/knockout-draw.mjs +4 -0
- package/lib/knockout-planner.mjs +5 -1
- package/package.json +1 -1
package/Changes
CHANGED
|
@@ -1,5 +1,14 @@
|
|
|
1
1
|
Revision history for @opndev/tennis-match-center
|
|
2
2
|
|
|
3
|
+
0.0.5 2026-10-12 14:29:04Z
|
|
4
|
+
|
|
5
|
+
* After dark a knockout round takes the lowest lit courts. Courts shut
|
|
6
|
+
for the dark counted as busy, which drew the round up the row to sit
|
|
7
|
+
beside them.
|
|
8
|
+
|
|
9
|
+
* A round is never cut into uneven quarters or eighths. Ten matches
|
|
10
|
+
halve 5/5 and no longer go 3/3/3/1.
|
|
11
|
+
|
|
3
12
|
0.0.4 2026-10-10 14:39:58Z
|
|
4
13
|
|
|
5
14
|
* Auto-fill only adds. The Planning board hands the planner the cells
|
package/lib/index.mjs
CHANGED
package/lib/knockout-draw.mjs
CHANGED
package/lib/knockout-planner.mjs
CHANGED
|
@@ -66,7 +66,11 @@ function holdCourts(item, pool, day, where, row) {
|
|
|
66
66
|
}
|
|
67
67
|
|
|
68
68
|
const at = court => row.indexOf(court)
|
|
69
|
-
const
|
|
69
|
+
const slot = where.slots[where.slotIndex]
|
|
70
|
+
const usable = new Set(day.usable(row, slot))
|
|
71
|
+
const busy = new Set(
|
|
72
|
+
row.filter(court => usable.has(court) && !pool.includes(court)).map(at)
|
|
73
|
+
)
|
|
70
74
|
// Where the draw played its last round: one that has to move moves
|
|
71
75
|
// as little as it can.
|
|
72
76
|
const were = (item.draw.lastCourts ?? []).map(id => row.findIndex(c => c.id === id))
|
package/package.json
CHANGED