api client refactor

This commit is contained in:
2025-12-17 18:01:47 +01:00
parent bab55955e1
commit 4177644b18
190 changed files with 6403 additions and 1624 deletions

View File

@@ -0,0 +1,27 @@
import { SponsorDto } from '../dtos';
export class SponsorViewModel implements SponsorDto {
id: string;
name: string;
logoUrl?: string;
websiteUrl?: string;
constructor(dto: SponsorDto) {
Object.assign(this, dto);
}
/** UI-specific: Display name */
get displayName(): string {
return this.name;
}
/** UI-specific: Whether has website */
get hasWebsite(): boolean {
return !!this.websiteUrl;
}
/** UI-specific: Website link text */
get websiteLinkText(): string {
return 'Visit Website';
}
}