18 lines
394 B
TypeScript
18 lines
394 B
TypeScript
import { RaceStatsDTO } from '../types/generated';
|
|
|
|
/**
|
|
* Race stats view model
|
|
* Represents race statistics for display
|
|
*/
|
|
export class RaceStatsViewModel {
|
|
totalRaces: number;
|
|
|
|
constructor(dto: RaceStatsDTO) {
|
|
this.totalRaces = dto.totalRaces;
|
|
}
|
|
|
|
/** UI-specific: Formatted total races */
|
|
get formattedTotalRaces(): string {
|
|
return this.totalRaces.toLocaleString();
|
|
}
|
|
} |