nice flow and quick working without creating a new conversation

This commit is contained in:
talksik
2022-05-30 08:08:36 -05:00
parent 1e3d26f664
commit cf5e16eeb9
4 changed files with 208 additions and 103 deletions
@@ -1,4 +1,5 @@
import { FieldValue, serverTimestamp, Timestamp } from 'firebase/firestore';
import { User } from './user.model';
export default class Conversation {
id: string;
@@ -9,6 +10,8 @@ export default class Conversation {
public members: MemberMap,
public userCache: User[],
public name: string | null = null,
public lastUpdatedDate = Timestamp.now(),
@@ -20,8 +23,8 @@ export default class Conversation {
}
export type MemberMap = {
[memberId: string]: ConversationMember
}
[memberId: string]: ConversationMember;
};
export class ConversationMember {
constructor(
@@ -44,4 +47,4 @@ export enum MemberState {
priority = 'priority',
inbox = 'inbox',
// deleted = "deleted"
}
}