2023-11-24 22:44:10 -07:00
|
|
|
// type BetterEnum<T> = T[keyof T];
|
2023-11-21 20:59:49 -07:00
|
|
|
|
|
|
|
export interface PresenceItem {
|
2023-11-22 12:27:30 -07:00
|
|
|
id: string;
|
|
|
|
userId: string;
|
|
|
|
userFullName: string;
|
|
|
|
userImageUrl: string;
|
|
|
|
roomId: string;
|
|
|
|
value: string;
|
2023-11-21 20:59:49 -07:00
|
|
|
isAdmin: boolean;
|
|
|
|
isVIP: boolean;
|
|
|
|
}
|
|
|
|
|
|
|
|
export type RoomsResponse =
|
|
|
|
| {
|
|
|
|
id: string;
|
|
|
|
createdAt: Date;
|
|
|
|
roomName: string;
|
|
|
|
}[]
|
|
|
|
| {
|
|
|
|
roomName: string | null;
|
|
|
|
id: string;
|
|
|
|
created_at: Date | null;
|
|
|
|
userId: string;
|
|
|
|
storyName: string | null;
|
|
|
|
visible: boolean;
|
|
|
|
scale: string;
|
|
|
|
}[]
|
|
|
|
| null
|
|
|
|
| undefined;
|
|
|
|
|
|
|
|
export type RoomResponse =
|
|
|
|
| {
|
|
|
|
id: string;
|
|
|
|
created_at: Date | null;
|
|
|
|
userId: string;
|
|
|
|
roomName: string | null;
|
|
|
|
storyName: string | null;
|
|
|
|
visible: boolean;
|
|
|
|
scale: string | null;
|
|
|
|
logs: {
|
|
|
|
id: string;
|
|
|
|
created_at: Date | null;
|
|
|
|
userId: string;
|
|
|
|
roomId: string;
|
|
|
|
roomName: string | null;
|
|
|
|
storyName: string | null;
|
|
|
|
scale: string | null;
|
|
|
|
votes: unknown;
|
|
|
|
}[];
|
|
|
|
}
|
|
|
|
| undefined
|
|
|
|
| null;
|
|
|
|
|
|
|
|
export type VoteResponse =
|
|
|
|
| {
|
|
|
|
id: string;
|
|
|
|
value: string;
|
|
|
|
created_at: Date | null;
|
|
|
|
userId: string;
|
|
|
|
roomId: string;
|
|
|
|
}[]
|
|
|
|
| null
|
|
|
|
| undefined;
|