The tournament the user has to check in to right now, null when none has check-in open. Cached site-wide rather than resolved per user: the header asks on every page load, while the answer only moves as tournaments approach their start.
exporttypeMatchPlayed = {
id: number;
vsSeed: number;
result: "win" | "loss";
/** Maps won by the team and by its opponent. */
score: [team: number, opponent: number];
bracketIdx: number;
};
Teams sharing 1st place of the top division (the only one when the tournament isn't split into divisions). Several when the tournament ends with co-winners.
Re-numbers placements of sorted standings keeping ties grouped ([1, 1, 3, 3, 5]), for after filtering or merging. offset shifts every placement down, for appending below another bracket's standings.
SPR (Seed Performance Rating) of every team in the standings, keyed by tournament team id. Seeds are ranked among the given standings only, so a division's standings are compared to its own seed order. See https://web.archive.org/web/20250513034545/https://www.pgstats.com/articles/introducing-spr-and-uf
Standings of a finalized tournament from the per-user results persisted at finalization. Null when those can't back the standings (no rows, a team no longer in the tournament, a division label the progression no longer produces) so the caller can fall back to {@link tournamentStandings}.
Standings aggregated across brackets: e.g. in RR → SE the top teams come from the SE bracket and the teams that missed it are ordered by their group performance. Type single with overall standings for one starting bracket, multi with standings per division for several.
In how many modes one stage may appear in a team's picks. Grows from 2 as the pool gets tight relative to the picks and turns off (equals the mode count) when it can't be satisfied.
@example
// 4 modes × 2 picks from the SendouQ pool (25 distinct stages) stageRepeatCap({ teamPick, pool }); // 2 // 4 modes × 4 picks from 8 stages stageRepeatCap({ teamPick, pool }); // 3
exportfunctionstageRepeatCap({
teamPick,
pool,
}: {
teamPick: TeamPickSettings;
pool: MapPool;
})
Validates a team's picks against the tournament's team pick settings and effective pool. Statuses with an explanation come before "PICKING" so a mistake shows while still picking.