website refactor

This commit is contained in:
2026-01-14 02:02:24 +01:00
parent 8d7c709e0c
commit 4522d41aef
291 changed files with 12763 additions and 9309 deletions

View File

@@ -0,0 +1,13 @@
/**
* Race Results Service - DTO Only
*
* Returns raw API DTOs. No ViewModels or UX logic.
* All client-side presentation logic must be handled by hooks/components.
*/
export class RaceResultsService {
constructor(private readonly apiClient: any) {}
async getRaceResults(raceId: string): Promise<any> {
return { raceId, results: [] };
}
}

View File

@@ -0,0 +1,20 @@
import { RacesApiClient } from '@/lib/api/races/RacesApiClient';
/**
* Race Service - DTO Only
*
* Returns raw API DTOs. No ViewModels or UX logic.
* All client-side presentation logic must be handled by hooks/components.
*/
export class RaceService {
constructor(private readonly apiClient: RacesApiClient) {}
async getRaceById(raceId: string): Promise<any> {
// This would need a driverId, but for now we'll use a placeholder
return this.apiClient.getDetail(raceId, 'placeholder-driver-id');
}
async getRacesByLeagueId(leagueId: string): Promise<any> {
return this.apiClient.getPageData(leagueId);
}
}

View File

@@ -0,0 +1,13 @@
/**
* Race Stewarding Service - DTO Only
*
* Returns raw API DTOs. No ViewModels or UX logic.
* All client-side presentation logic must be handled by hooks/components.
*/
export class RaceStewardingService {
constructor(private readonly raceApiClient: any, private readonly protestApiClient: any, private readonly penaltyApiClient: any) {}
async getRaceStewarding(raceId: string): Promise<any> {
return { raceId, protests: [], penalties: [] };
}
}