hububb-saas-shared 1.0.44 → 1.0.45
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +0 -1
- package/dist/index.js +0 -1
- package/dist/schemas/thread/index.d.ts +39 -39
- package/package.json +2 -3
- package/dist/helpers/index.d.ts +0 -3
- package/dist/helpers/index.js +0 -39
package/dist/index.d.ts
CHANGED
package/dist/index.js
CHANGED
|
@@ -16,4 +16,3 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
17
|
__exportStar(require("./types"), exports);
|
|
18
18
|
__exportStar(require("./schemas"), exports);
|
|
19
|
-
__exportStar(require("./helpers"), exports);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export declare const ChatMessageSchema: import("zod").ZodObject<{
|
|
2
2
|
id: import("zod").ZodString;
|
|
3
|
-
createdAt: import("zod").ZodType<
|
|
3
|
+
createdAt: import("zod").ZodType<import("@firebase/firestore-types").Timestamp, import("zod").ZodTypeDef, import("@firebase/firestore-types").Timestamp>;
|
|
4
4
|
threadId: import("zod").ZodString;
|
|
5
5
|
authorId: import("zod").ZodString;
|
|
6
6
|
author: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
@@ -45,19 +45,19 @@ export declare const ChatMessageSchema: import("zod").ZodObject<{
|
|
|
45
45
|
}>>;
|
|
46
46
|
contentType: import("zod").ZodString;
|
|
47
47
|
body: import("zod").ZodString;
|
|
48
|
-
seen: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodType<
|
|
49
|
-
lastSeen: import("zod").ZodOptional<import("zod").ZodType<
|
|
48
|
+
seen: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodType<import("@firebase/firestore-types").Timestamp, import("zod").ZodTypeDef, import("@firebase/firestore-types").Timestamp>>;
|
|
49
|
+
lastSeen: import("zod").ZodOptional<import("zod").ZodType<import("@firebase/firestore-types").Timestamp, import("zod").ZodTypeDef, import("@firebase/firestore-types").Timestamp>>;
|
|
50
50
|
source: import("zod").ZodOptional<import("zod").ZodString>;
|
|
51
51
|
externalMessageId: import("zod").ZodOptional<import("zod").ZodString>;
|
|
52
52
|
attachments: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodString, "many">>;
|
|
53
53
|
}, "strip", import("zod").ZodTypeAny, {
|
|
54
54
|
id: string;
|
|
55
55
|
body: string;
|
|
56
|
-
createdAt:
|
|
56
|
+
createdAt: import("@firebase/firestore-types").Timestamp;
|
|
57
57
|
threadId: string;
|
|
58
|
-
contentType: string;
|
|
59
58
|
authorId: string;
|
|
60
|
-
|
|
59
|
+
contentType: string;
|
|
60
|
+
seen: Record<string, import("@firebase/firestore-types").Timestamp>;
|
|
61
61
|
source?: string | undefined;
|
|
62
62
|
attachments?: string[] | undefined;
|
|
63
63
|
author?: {
|
|
@@ -74,16 +74,16 @@ export declare const ChatMessageSchema: import("zod").ZodObject<{
|
|
|
74
74
|
userRoleId: number;
|
|
75
75
|
stripeCustomerId?: string | undefined;
|
|
76
76
|
} | undefined;
|
|
77
|
-
lastSeen?:
|
|
77
|
+
lastSeen?: import("@firebase/firestore-types").Timestamp | undefined;
|
|
78
78
|
externalMessageId?: string | undefined;
|
|
79
79
|
}, {
|
|
80
80
|
id: string;
|
|
81
81
|
body: string;
|
|
82
|
-
createdAt:
|
|
82
|
+
createdAt: import("@firebase/firestore-types").Timestamp;
|
|
83
83
|
threadId: string;
|
|
84
|
-
contentType: string;
|
|
85
84
|
authorId: string;
|
|
86
|
-
|
|
85
|
+
contentType: string;
|
|
86
|
+
seen: Record<string, import("@firebase/firestore-types").Timestamp>;
|
|
87
87
|
source?: string | undefined;
|
|
88
88
|
attachments?: string[] | undefined;
|
|
89
89
|
author?: {
|
|
@@ -100,16 +100,16 @@ export declare const ChatMessageSchema: import("zod").ZodObject<{
|
|
|
100
100
|
userRoleId: number;
|
|
101
101
|
stripeCustomerId?: string | undefined;
|
|
102
102
|
} | undefined;
|
|
103
|
-
lastSeen?:
|
|
103
|
+
lastSeen?: import("@firebase/firestore-types").Timestamp | undefined;
|
|
104
104
|
externalMessageId?: string | undefined;
|
|
105
105
|
}>;
|
|
106
106
|
export declare const ChatThreadSchema: import("zod").ZodObject<{
|
|
107
107
|
id: import("zod").ZodOptional<import("zod").ZodString>;
|
|
108
|
-
createdAt: import("zod").ZodType<
|
|
109
|
-
updatedAt: import("zod").ZodType<
|
|
108
|
+
createdAt: import("zod").ZodType<import("@firebase/firestore-types").Timestamp, import("zod").ZodTypeDef, import("@firebase/firestore-types").Timestamp>;
|
|
109
|
+
updatedAt: import("zod").ZodType<import("@firebase/firestore-types").Timestamp, import("zod").ZodTypeDef, import("@firebase/firestore-types").Timestamp>;
|
|
110
110
|
lastMessage: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
111
111
|
id: import("zod").ZodString;
|
|
112
|
-
createdAt: import("zod").ZodType<
|
|
112
|
+
createdAt: import("zod").ZodType<import("@firebase/firestore-types").Timestamp, import("zod").ZodTypeDef, import("@firebase/firestore-types").Timestamp>;
|
|
113
113
|
threadId: import("zod").ZodString;
|
|
114
114
|
authorId: import("zod").ZodString;
|
|
115
115
|
author: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
@@ -154,19 +154,19 @@ export declare const ChatThreadSchema: import("zod").ZodObject<{
|
|
|
154
154
|
}>>;
|
|
155
155
|
contentType: import("zod").ZodString;
|
|
156
156
|
body: import("zod").ZodString;
|
|
157
|
-
seen: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodType<
|
|
158
|
-
lastSeen: import("zod").ZodOptional<import("zod").ZodType<
|
|
157
|
+
seen: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodType<import("@firebase/firestore-types").Timestamp, import("zod").ZodTypeDef, import("@firebase/firestore-types").Timestamp>>;
|
|
158
|
+
lastSeen: import("zod").ZodOptional<import("zod").ZodType<import("@firebase/firestore-types").Timestamp, import("zod").ZodTypeDef, import("@firebase/firestore-types").Timestamp>>;
|
|
159
159
|
source: import("zod").ZodOptional<import("zod").ZodString>;
|
|
160
160
|
externalMessageId: import("zod").ZodOptional<import("zod").ZodString>;
|
|
161
161
|
attachments: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodString, "many">>;
|
|
162
162
|
}, "strip", import("zod").ZodTypeAny, {
|
|
163
163
|
id: string;
|
|
164
164
|
body: string;
|
|
165
|
-
createdAt:
|
|
165
|
+
createdAt: import("@firebase/firestore-types").Timestamp;
|
|
166
166
|
threadId: string;
|
|
167
|
-
contentType: string;
|
|
168
167
|
authorId: string;
|
|
169
|
-
|
|
168
|
+
contentType: string;
|
|
169
|
+
seen: Record<string, import("@firebase/firestore-types").Timestamp>;
|
|
170
170
|
source?: string | undefined;
|
|
171
171
|
attachments?: string[] | undefined;
|
|
172
172
|
author?: {
|
|
@@ -183,16 +183,16 @@ export declare const ChatThreadSchema: import("zod").ZodObject<{
|
|
|
183
183
|
userRoleId: number;
|
|
184
184
|
stripeCustomerId?: string | undefined;
|
|
185
185
|
} | undefined;
|
|
186
|
-
lastSeen?:
|
|
186
|
+
lastSeen?: import("@firebase/firestore-types").Timestamp | undefined;
|
|
187
187
|
externalMessageId?: string | undefined;
|
|
188
188
|
}, {
|
|
189
189
|
id: string;
|
|
190
190
|
body: string;
|
|
191
|
-
createdAt:
|
|
191
|
+
createdAt: import("@firebase/firestore-types").Timestamp;
|
|
192
192
|
threadId: string;
|
|
193
|
-
contentType: string;
|
|
194
193
|
authorId: string;
|
|
195
|
-
|
|
194
|
+
contentType: string;
|
|
195
|
+
seen: Record<string, import("@firebase/firestore-types").Timestamp>;
|
|
196
196
|
source?: string | undefined;
|
|
197
197
|
attachments?: string[] | undefined;
|
|
198
198
|
author?: {
|
|
@@ -209,7 +209,7 @@ export declare const ChatThreadSchema: import("zod").ZodObject<{
|
|
|
209
209
|
userRoleId: number;
|
|
210
210
|
stripeCustomerId?: string | undefined;
|
|
211
211
|
} | undefined;
|
|
212
|
-
lastSeen?:
|
|
212
|
+
lastSeen?: import("@firebase/firestore-types").Timestamp | undefined;
|
|
213
213
|
externalMessageId?: string | undefined;
|
|
214
214
|
}>>;
|
|
215
215
|
participantIds: import("zod").ZodArray<import("zod").ZodString, "many">;
|
|
@@ -258,7 +258,7 @@ export declare const ChatThreadSchema: import("zod").ZodObject<{
|
|
|
258
258
|
externalThreadId: import("zod").ZodOptional<import("zod").ZodString>;
|
|
259
259
|
externalSource: import("zod").ZodOptional<import("zod").ZodString>;
|
|
260
260
|
title: import("zod").ZodOptional<import("zod").ZodString>;
|
|
261
|
-
seenBy: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodType<
|
|
261
|
+
seenBy: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodType<import("@firebase/firestore-types").Timestamp, import("zod").ZodTypeDef, import("@firebase/firestore-types").Timestamp>>;
|
|
262
262
|
isImportant: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
263
263
|
needsAttention: import("zod").ZodArray<import("zod").ZodString, "many">;
|
|
264
264
|
needsAttentionMap: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodBoolean>;
|
|
@@ -266,10 +266,10 @@ export declare const ChatThreadSchema: import("zod").ZodObject<{
|
|
|
266
266
|
tags: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodString, "many">>;
|
|
267
267
|
}, "strip", import("zod").ZodTypeAny, {
|
|
268
268
|
type: "ONE_TO_ONE" | "GROUP";
|
|
269
|
-
createdAt:
|
|
270
|
-
updatedAt:
|
|
269
|
+
createdAt: import("@firebase/firestore-types").Timestamp;
|
|
270
|
+
updatedAt: import("@firebase/firestore-types").Timestamp;
|
|
271
271
|
participantIds: string[];
|
|
272
|
-
seenBy: Record<string,
|
|
272
|
+
seenBy: Record<string, import("@firebase/firestore-types").Timestamp>;
|
|
273
273
|
needsAttention: string[];
|
|
274
274
|
needsAttentionMap: Record<string, boolean>;
|
|
275
275
|
id?: string | undefined;
|
|
@@ -279,11 +279,11 @@ export declare const ChatThreadSchema: import("zod").ZodObject<{
|
|
|
279
279
|
lastMessage?: {
|
|
280
280
|
id: string;
|
|
281
281
|
body: string;
|
|
282
|
-
createdAt:
|
|
282
|
+
createdAt: import("@firebase/firestore-types").Timestamp;
|
|
283
283
|
threadId: string;
|
|
284
|
-
contentType: string;
|
|
285
284
|
authorId: string;
|
|
286
|
-
|
|
285
|
+
contentType: string;
|
|
286
|
+
seen: Record<string, import("@firebase/firestore-types").Timestamp>;
|
|
287
287
|
source?: string | undefined;
|
|
288
288
|
attachments?: string[] | undefined;
|
|
289
289
|
author?: {
|
|
@@ -300,7 +300,7 @@ export declare const ChatThreadSchema: import("zod").ZodObject<{
|
|
|
300
300
|
userRoleId: number;
|
|
301
301
|
stripeCustomerId?: string | undefined;
|
|
302
302
|
} | undefined;
|
|
303
|
-
lastSeen?:
|
|
303
|
+
lastSeen?: import("@firebase/firestore-types").Timestamp | undefined;
|
|
304
304
|
externalMessageId?: string | undefined;
|
|
305
305
|
} | undefined;
|
|
306
306
|
participants?: {
|
|
@@ -323,10 +323,10 @@ export declare const ChatThreadSchema: import("zod").ZodObject<{
|
|
|
323
323
|
tags?: string[] | undefined;
|
|
324
324
|
}, {
|
|
325
325
|
type: "ONE_TO_ONE" | "GROUP";
|
|
326
|
-
createdAt:
|
|
327
|
-
updatedAt:
|
|
326
|
+
createdAt: import("@firebase/firestore-types").Timestamp;
|
|
327
|
+
updatedAt: import("@firebase/firestore-types").Timestamp;
|
|
328
328
|
participantIds: string[];
|
|
329
|
-
seenBy: Record<string,
|
|
329
|
+
seenBy: Record<string, import("@firebase/firestore-types").Timestamp>;
|
|
330
330
|
needsAttention: string[];
|
|
331
331
|
needsAttentionMap: Record<string, boolean>;
|
|
332
332
|
id?: string | undefined;
|
|
@@ -336,11 +336,11 @@ export declare const ChatThreadSchema: import("zod").ZodObject<{
|
|
|
336
336
|
lastMessage?: {
|
|
337
337
|
id: string;
|
|
338
338
|
body: string;
|
|
339
|
-
createdAt:
|
|
339
|
+
createdAt: import("@firebase/firestore-types").Timestamp;
|
|
340
340
|
threadId: string;
|
|
341
|
-
contentType: string;
|
|
342
341
|
authorId: string;
|
|
343
|
-
|
|
342
|
+
contentType: string;
|
|
343
|
+
seen: Record<string, import("@firebase/firestore-types").Timestamp>;
|
|
344
344
|
source?: string | undefined;
|
|
345
345
|
attachments?: string[] | undefined;
|
|
346
346
|
author?: {
|
|
@@ -357,7 +357,7 @@ export declare const ChatThreadSchema: import("zod").ZodObject<{
|
|
|
357
357
|
userRoleId: number;
|
|
358
358
|
stripeCustomerId?: string | undefined;
|
|
359
359
|
} | undefined;
|
|
360
|
-
lastSeen?:
|
|
360
|
+
lastSeen?: import("@firebase/firestore-types").Timestamp | undefined;
|
|
361
361
|
externalMessageId?: string | undefined;
|
|
362
362
|
} | undefined;
|
|
363
363
|
participants?: {
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"type": "commonjs",
|
|
3
3
|
"name": "hububb-saas-shared",
|
|
4
|
-
"version": "1.0.
|
|
4
|
+
"version": "1.0.45",
|
|
5
5
|
"description": "This is a shared package for the hububb saas project",
|
|
6
6
|
"types": "./dist/index.d.ts",
|
|
7
7
|
"main": "./dist/index.js",
|
|
@@ -9,8 +9,7 @@
|
|
|
9
9
|
"dist/index.js",
|
|
10
10
|
"dist/index.d.ts",
|
|
11
11
|
"dist/types/**",
|
|
12
|
-
"dist/schemas/**"
|
|
13
|
-
"dist/helpers/**"
|
|
12
|
+
"dist/schemas/**"
|
|
14
13
|
],
|
|
15
14
|
"scripts": {
|
|
16
15
|
"test": "echo \"Error: no test specified\" && exit 1",
|
package/dist/helpers/index.d.ts
DELETED
package/dist/helpers/index.js
DELETED
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
-
}) : function(o, v) {
|
|
16
|
-
o["default"] = v;
|
|
17
|
-
});
|
|
18
|
-
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
-
var ownKeys = function(o) {
|
|
20
|
-
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
-
var ar = [];
|
|
22
|
-
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
-
return ar;
|
|
24
|
-
};
|
|
25
|
-
return ownKeys(o);
|
|
26
|
-
};
|
|
27
|
-
return function (mod) {
|
|
28
|
-
if (mod && mod.__esModule) return mod;
|
|
29
|
-
var result = {};
|
|
30
|
-
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
-
__setModuleDefault(result, mod);
|
|
32
|
-
return result;
|
|
33
|
-
};
|
|
34
|
-
})();
|
|
35
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
36
|
-
exports.firestoreTimestampSchema = void 0;
|
|
37
|
-
const admin = __importStar(require("firebase-admin"));
|
|
38
|
-
const zod_1 = require("zod");
|
|
39
|
-
exports.firestoreTimestampSchema = zod_1.z.instanceof(admin.firestore.Timestamp);
|