Fill out some more components + add application state enums

This commit is contained in:
Gabe Kangas
2022-04-29 15:09:53 -07:00
parent e5d3b0e4ee
commit 4997c7c5ac
18 changed files with 522 additions and 116 deletions

View File

@ -0,0 +1,17 @@
export enum AppState {
AppLoading,
ChatLoading,
Loading,
}
export enum ChatVisibilityState {
Hidden, // The chat is available but the user has hidden it
Visible, // The chat is available and visible
}
export enum ChatState {
Available, // Normal state
NotAvailable, // Chat features are not available
Loading, // Chat is connecting and loading history
Offline, // Chat is offline/disconnected for some reason
}

View File

@ -1 +1,9 @@
export interface ChatMessage {}
import { User } from './user';
export interface ChatMessage {
id: string;
type: string;
timestamp: Date;
user: User;
body: string;
}

9
web/interfaces/user.ts Normal file
View File

@ -0,0 +1,9 @@
export interface User {
id: string;
displayName: string;
displayColor: number;
createdAt: Date;
previousNames: string[];
nameChangedAt: Date;
scopes: string[];
}