hububb-models 1.0.25 → 1.0.27
Sign up to get free protection for your applications and to get access to all the features.
package/package.json
CHANGED
@@ -1,10 +1,14 @@
|
|
1
1
|
import { Timestamp } from "@firebase/firestore-types";
|
2
|
-
|
2
|
+
interface Attachment {
|
3
|
+
id: string;
|
4
|
+
url: string;
|
5
|
+
}
|
6
|
+
|
3
7
|
export interface Message {
|
4
|
-
id
|
5
|
-
attachments
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
}
|
8
|
+
id: string;
|
9
|
+
attachments: Attachment[];
|
10
|
+
body: string;
|
11
|
+
contentType: string;
|
12
|
+
createdAt: Timestamp;
|
13
|
+
authorId: string;
|
14
|
+
}
|
@@ -1,10 +1,15 @@
|
|
1
1
|
import { Timestamp } from "@firebase/firestore-types";
|
2
2
|
|
3
|
-
|
4
|
-
id
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
3
|
+
interface Attachment {
|
4
|
+
id: string;
|
5
|
+
url: string;
|
6
|
+
}
|
7
|
+
|
8
|
+
export interface Message {
|
9
|
+
id: string;
|
10
|
+
attachments: Attachment[];
|
11
|
+
body: string;
|
12
|
+
contentType: string;
|
13
|
+
createdAt: Timestamp;
|
14
|
+
authorId: string;
|
15
|
+
}
|
@@ -1,15 +1,18 @@
|
|
1
1
|
import { Timestamp } from "@firebase/firestore-types"
|
2
|
+
import { Message } from "./message";
|
2
3
|
|
3
|
-
export interface
|
4
|
-
id
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
unreadCount?:number
|
4
|
+
export interface Contact {
|
5
|
+
id: string;
|
6
|
+
avatar: string;
|
7
|
+
lastActivity?: number;
|
8
|
+
fullName: string;
|
9
9
|
}
|
10
|
-
interface
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
10
|
+
export interface Thread {
|
11
|
+
id?: string;
|
12
|
+
messages: Message[];
|
13
|
+
lastMessage?: Message;
|
14
|
+
participantIds: string[];
|
15
|
+
participants?: Contact[];
|
16
|
+
type: "ONE_TO_ONE" | "GROUP";
|
17
|
+
unreadCount?: number;
|
15
18
|
}
|
@@ -1,15 +1,20 @@
|
|
1
1
|
import { Timestamp } from "@firebase/firestore-types"
|
2
|
+
import { Message } from "./message";
|
2
3
|
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
4
|
+
|
5
|
+
|
6
|
+
export interface Contact {
|
7
|
+
id: string;
|
8
|
+
avatar: string;
|
9
|
+
lastActivity?: number;
|
10
|
+
fullName: string;
|
9
11
|
}
|
10
|
-
interface
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
12
|
+
export interface Thread {
|
13
|
+
id?: string;
|
14
|
+
messages: Message[];
|
15
|
+
lastMessage?: Message;
|
16
|
+
participantIds: string[];
|
17
|
+
participants?: Contact[];
|
18
|
+
type: "ONE_TO_ONE" | "GROUP";
|
19
|
+
unreadCount?: number;
|
15
20
|
}
|