website refactor

This commit is contained in:
2026-01-12 01:01:49 +01:00
parent 5ca6023a5a
commit fefd8d1cd6
294 changed files with 4628 additions and 4991 deletions

View File

@@ -1,4 +1,5 @@
import { LeagueScoringConfigDTO } from '@/lib/types/generated/LeagueScoringConfigDTO';
import type { LeagueScoringChampionshipDTO } from '@/lib/types/generated/LeagueScoringChampionshipDTO';
/**
* LeagueScoringConfigViewModel
@@ -9,21 +10,12 @@ export class LeagueScoringConfigViewModel {
readonly gameName: string;
readonly scoringPresetName?: string;
readonly dropPolicySummary?: string;
readonly championships?: Array<{
id: string;
name: string;
type: 'driver' | 'team' | 'nations' | 'trophy' | string;
sessionTypes: string[];
pointsPreview: Array<{ sessionType: string; position: number; points: number }>;
bonusSummary: string[];
dropPolicyDescription?: string;
}>;
readonly championships?: LeagueScoringChampionshipDTO[];
constructor(dto: LeagueScoringConfigDTO) {
this.gameName = dto.gameName;
// These would be mapped from extended properties if available
this.scoringPresetName = (dto as any).scoringPresetName;
this.dropPolicySummary = (dto as any).dropPolicySummary;
this.championships = (dto as any).championships;
this.scoringPresetName = dto.scoringPresetName;
this.dropPolicySummary = dto.dropPolicySummary;
this.championships = dto.championships;
}
}