Add React frontend and clean up legacy HTTP backend

This commit is contained in:
tim
2026-06-15 22:20:56 +02:00
parent b8e2d15e27
commit beaf142ee4
40 changed files with 8328 additions and 437 deletions
+53
View File
@@ -0,0 +1,53 @@
export type CardColor = 'HEARTS' | 'LEAVES' | 'ACORNS' | 'BELLS';
export type CardValue = 'C7' | 'C8' | 'C9' | 'C10' | 'LOWER' | 'UPPER' | 'KING' | 'ACE';
export interface Card {
color: CardColor;
value: CardValue;
}
export interface PlayerInfo {
order: number;
name: string;
connected: boolean;
}
export interface MyPlayer {
order: number;
name: string;
token: string;
gid: string;
}
export interface StashData {
first_player: number;
cards: Record<string, Card>;
}
export interface GameStatusDetail {
active_player?: number;
active_round_guesses?: Record<string, number>;
active_round_stashes?: number[];
active_stash?: StashData;
previous_stash?: StashData;
standings: number[][][];
}
export interface GameStatusPayload {
gid: string;
completed: boolean;
players: PlayerInfo[];
series_number: number;
round_number: number;
cards_in_round: number;
status: GameStatusDetail;
}
export interface GameInfo {
gid: string;
name: string;
started: boolean;
players: PlayerInfo[];
}
export type Hand = Record<string, Card>;