feat(race-setup): list sessions in running order and move them with up/down (1.49.0)

This commit is contained in:
larssand committed 2026-11-01 20:13:15 +01:00
1 parent e199f3aa1a
commit bb0fa7ede4
14 files changed
+104 -14

No files matched your search

+2 -2
View File
@@ -192,8 +192,8 @@ export function getSeriesRoundStatus(sessions = []) {
// The one thing to do next in a round, for the button on its row: run the seeding practice,
// make qualifying, run the next heat, make finals, run the next final. A session already
// running is shown first.
export function getSeriesRoundNextStep(sessions = []) {
const ordered = orderSessionsForRunning(sessions);
export function getSeriesRoundNextStep(sessions = [], manualOrder = []) {
const ordered = orderSessionsForRunning(sessions, manualOrder);
const live = ordered.find((session) => ["running", "paused"].includes(session.status));
if (live) return { kind: "live", session: live };
const ready = (type) => ordered.find((session) => session.type === type && session.status === "ready");