24 lines
616 B
TypeScript
24 lines
616 B
TypeScript
/**
|
|
* Team card view model
|
|
* UI representation of a team on the landing page.
|
|
*/
|
|
import { ViewModel } from "../contracts/view-models/ViewModel";
|
|
import type { TeamCardViewData } from "@/lib/view-data/TeamCardViewData";
|
|
|
|
export class TeamCardViewModel extends ViewModel {
|
|
readonly id: string;
|
|
readonly name: string;
|
|
readonly tag: string;
|
|
readonly description: string;
|
|
readonly logoUrl?: string;
|
|
|
|
constructor(data: TeamCardViewData) {
|
|
super();
|
|
this.id = data.id;
|
|
this.name = data.name;
|
|
this.tag = data.tag;
|
|
this.description = data.description;
|
|
this.logoUrl = data.logoUrl;
|
|
}
|
|
}
|