This commit is contained in:
2025-12-04 11:54:42 +01:00
parent 9d5caa87f3
commit b7d5551ea7
223 changed files with 5473 additions and 885 deletions

View File

@@ -0,0 +1,17 @@
import type { FeedItemType } from '../value-objects/FeedItemType';
export interface FeedItem {
id: string;
timestamp: Date;
type: FeedItemType;
actorFriendId?: string;
actorDriverId?: string;
leagueId?: string;
raceId?: string;
teamId?: string;
position?: number;
headline: string;
body?: string;
ctaLabel?: string;
ctaHref?: string;
}

View File

@@ -0,0 +1,6 @@
import type { FeedItem } from '../entities/FeedItem';
export interface IFeedRepository {
getFeedForDriver(driverId: string, limit?: number): Promise<FeedItem[]>;
getGlobalFeed(limit?: number): Promise<FeedItem[]>;
}

View File

@@ -0,0 +1,7 @@
import type { Driver } from '@gridpilot/racing/domain/entities/Driver';
export interface ISocialGraphRepository {
getFriends(driverId: string): Promise<Driver[]>;
getFriendIds(driverId: string): Promise<string[]>;
getSuggestedFriends(driverId: string, limit?: number): Promise<Driver[]>;
}

View File

@@ -0,0 +1,8 @@
export type FeedItemType =
| 'friend-joined-league'
| 'friend-joined-team'
| 'friend-finished-race'
| 'friend-new-personal-best'
| 'new-race-scheduled'
| 'new-result-posted'
| 'league-highlight';