Files
gridpilot.gg/apps/website/lib/view-models/LeagueStatsViewModel.ts
Marc Mintel d97f50ed72
Some checks failed
Contract Testing / contract-tests (pull_request) Failing after 6m4s
Contract Testing / contract-snapshot (pull_request) Has been skipped
view data fixes
2026-01-23 11:59:49 +01:00

19 lines
495 B
TypeScript

/**
* View Model for League Statistics
*
* Represents the total number of leagues in a UI-ready format.
*/
import { ViewModel } from "../contracts/view-models/ViewModel";
export class LeagueStatsViewModel extends ViewModel {
totalLeagues: number;
constructor(dto: { totalLeagues: number }) {
this.totalLeagues = dto.totalLeagues;
}
/** UI-specific: Formatted total leagues display */
get formattedTotalLeagues(): string {
return this.totalLeagues.toLocaleString();
}
}