19 lines
495 B
TypeScript
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();
|
|
}
|
|
} |