harden media

This commit is contained in:
2025-12-31 15:39:28 +01:00
parent 92226800df
commit 8260bf7baf
413 changed files with 8361 additions and 1544 deletions

View File

@@ -21,12 +21,14 @@ export type Friendship = {
friendId: string;
};
import { MediaReference } from '@core/domain/media/MediaReference';
export interface DemoTeamDTO {
id: string;
name: string;
tag: string;
description: string;
logoUrl: string;
logoRef: MediaReference;
primaryLeagueId: string;
memberCount: number;
}
@@ -172,7 +174,7 @@ export function createLeagues(ownerIds: string[]): League[] {
return leagues;
}
export function createTeams(leagues: League[], getTeamLogo: (id: string) => string): DemoTeamDTO[] {
export function createTeams(leagues: League[]): DemoTeamDTO[] {
const teams: DemoTeamDTO[] = [];
const teamCount = 24 + faker.number.int({ min: 0, max: 12 });
@@ -188,7 +190,7 @@ export function createTeams(leagues: League[], getTeamLogo: (id: string) => stri
name,
tag,
description: faker.lorem.sentence(),
logoUrl: getTeamLogo(id),
logoRef: MediaReference.systemDefault('logo'),
primaryLeagueId: primaryLeague.id,
memberCount,
});