website refactor
This commit is contained in:
@@ -65,6 +65,28 @@ export interface SponsorshipSlot {
|
||||
benefits: string[];
|
||||
}
|
||||
|
||||
export interface NextRaceInfo {
|
||||
id: string;
|
||||
name: string;
|
||||
date: string;
|
||||
track?: string;
|
||||
car?: string;
|
||||
}
|
||||
|
||||
export interface SeasonProgress {
|
||||
completedRaces: number;
|
||||
totalRaces: number;
|
||||
percentage: number;
|
||||
}
|
||||
|
||||
export interface RecentResult {
|
||||
raceId: string;
|
||||
raceName: string;
|
||||
position: number;
|
||||
points: number;
|
||||
finishedAt: string;
|
||||
}
|
||||
|
||||
export interface LeagueDetailViewData extends ViewData {
|
||||
// Basic info
|
||||
leagueId: string;
|
||||
@@ -104,4 +126,14 @@ export interface LeagueDetailViewData extends ViewData {
|
||||
metrics: SponsorMetric[];
|
||||
slots: SponsorshipSlot[];
|
||||
} | null;
|
||||
|
||||
// New fields for enhanced league pages
|
||||
nextRace?: NextRaceInfo;
|
||||
seasonProgress?: SeasonProgress;
|
||||
recentResults?: RecentResult[];
|
||||
|
||||
// Admin fields
|
||||
walletBalance?: number;
|
||||
pendingProtestsCount?: number;
|
||||
pendingJoinRequestsCount?: number;
|
||||
}
|
||||
|
||||
@@ -13,6 +13,12 @@ export interface StandingEntryData {
|
||||
penaltyPoints: number;
|
||||
bonusPoints: number;
|
||||
teamName?: string;
|
||||
// New fields from Phase 3
|
||||
positionChange: number;
|
||||
lastRacePoints: number;
|
||||
droppedRaceIds: string[];
|
||||
wins: number;
|
||||
podiums: number;
|
||||
}
|
||||
|
||||
export interface DriverData {
|
||||
@@ -39,4 +45,6 @@ export interface LeagueStandingsViewData {
|
||||
leagueId: string;
|
||||
currentDriverId: string | null;
|
||||
isAdmin: boolean;
|
||||
// New fields for team standings toggle
|
||||
isTeamChampionship?: boolean;
|
||||
}
|
||||
@@ -11,5 +11,14 @@ export interface LeagueScheduleViewData {
|
||||
isUpcoming: boolean;
|
||||
status: 'scheduled' | 'completed';
|
||||
strengthOfField?: number;
|
||||
// Registration info
|
||||
isUserRegistered?: boolean;
|
||||
canRegister?: boolean;
|
||||
// Admin info
|
||||
canEdit?: boolean;
|
||||
canReschedule?: boolean;
|
||||
}>;
|
||||
// User permissions
|
||||
currentDriverId?: string;
|
||||
isAdmin: boolean;
|
||||
}
|
||||
Reference in New Issue
Block a user