@marcoappio/marco-config 2.0.451 → 2.0.452
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/zero/index.d.ts +157 -84
- package/dist/zero/index.d.ts.map +1 -1
- package/dist/zero/mutators/threadMutators/threadMutators.d.ts +3 -1
- package/dist/zero/mutators/threadMutators/threadMutators.d.ts.map +1 -1
- package/dist/zero/mutators/threadMutators/threadMutators.js +31 -24
- package/dist/zero/mutators/threadMutators/threadMutators.test.js +12 -12
- package/dist/zero/queries/getAccounts.d.ts +24 -13
- package/dist/zero/queries/getAccounts.d.ts.map +1 -1
- package/dist/zero/queries/getContacts.d.ts +23 -13
- package/dist/zero/queries/getContacts.d.ts.map +1 -1
- package/dist/zero/queries/getDrafts.d.ts +23 -13
- package/dist/zero/queries/getDrafts.d.ts.map +1 -1
- package/dist/zero/queries/getThreads.d.ts +24 -13
- package/dist/zero/queries/getThreads.d.ts.map +1 -1
- package/dist/zero/queries/getUser.d.ts +24 -13
- package/dist/zero/queries/getUser.d.ts.map +1 -1
- package/dist/zero/queries/index.d.ts +23 -13
- package/dist/zero/queries/index.d.ts.map +1 -1
- package/dist/zero/schema.d.ts +39 -19
- package/dist/zero/schema.d.ts.map +1 -1
- package/dist/zero/schema.js +4 -2
- package/package.json +1 -1
package/dist/zero/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/zero/index.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,SAAS
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/zero/index.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,SAAS;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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../../types';
|
|
3
4
|
import { type AuthData, type HandlerMap } from '../../../types';
|
|
4
5
|
import type { ZeroMutatorSchemas } from '../../../zero/mutatorSchemas';
|
|
6
|
+
import type { MarcoZeroSchema } from '../../../zero/schema';
|
|
5
7
|
export type ThreadMutatorCallbacks = {
|
|
6
8
|
[K in keyof ZeroMutatorSchemas['thread']]?: (args: v.InferOutput<ZeroMutatorSchemas['thread'][K]['delta']>) => Promise<void>;
|
|
7
9
|
};
|
|
8
|
-
export declare const setSystemLabel: (tx:
|
|
10
|
+
export declare const setSystemLabel: (tx: Transaction<MarcoZeroSchema>, threadId: string, targetSpecialUse: LabelSpecialUse) => Promise<IMAPSourceLocation[]>;
|
|
9
11
|
export declare const createThreadMutators: (_authData: AuthData | undefined, callbacks?: ThreadMutatorCallbacks) => HandlerMap<ZeroMutatorSchemas["thread"]>;
|
|
10
12
|
//# sourceMappingURL=threadMutators.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"threadMutators.d.ts","sourceRoot":"","sources":["../../../../src/zero/mutators/threadMutators/threadMutators.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,CAAC,MAAM,SAAS,CAAA;AAEjC,OAAO,KAAK,EAAE,kBAAkB,EAAE,eAAe,EAAE,MAAM,qBAAqB,CAAA;AAC9E,OAAO,EAAE,KAAK,QAAQ,EAAE,KAAK,UAAU,EAAiB,MAAM,qBAAqB,CAAA;AACnF,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,mCAAmC,CAAA;
|
|
1
|
+
{"version":3,"file":"threadMutators.d.ts","sourceRoot":"","sources":["../../../../src/zero/mutators/threadMutators/threadMutators.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAA;AACjD,OAAO,KAAK,KAAK,CAAC,MAAM,SAAS,CAAA;AAEjC,OAAO,KAAK,EAAE,kBAAkB,EAAE,eAAe,EAAE,MAAM,qBAAqB,CAAA;AAC9E,OAAO,EAAE,KAAK,QAAQ,EAAE,KAAK,UAAU,EAAiB,MAAM,qBAAqB,CAAA;AACnF,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,mCAAmC,CAAA;AAC3E,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAA;AAEhE,MAAM,MAAM,sBAAsB,GAAG;KAClC,CAAC,IAAI,MAAM,kBAAkB,CAAC,QAAQ,CAAC,CAAC,CAAC,EAAE,CAC1C,IAAI,EAAE,CAAC,CAAC,WAAW,CAAC,kBAAkB,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,KAC1D,OAAO,CAAC,IAAI,CAAC;CACnB,CAAA;AAED,eAAO,MAAM,cAAc,OACrB,WAAW,CAAC,eAAe,CAAC,YACtB,MAAM,oBACE,eAAe,KAChC,OAAO,CAAC,kBAAkB,EAAE,CAoE9B,CAAA;AAED,eAAO,MAAM,oBAAoB,cACpB,QAAQ,GAAG,SAAS,cACnB,sBAAsB,KACjC,UAAU,CAAC,kBAAkB,CAAC,QAAQ,CAAC,CAoLxC,CAAA"}
|
|
@@ -4,49 +4,53 @@ export const setSystemLabel = async (tx, threadId, targetSpecialUse) => {
|
|
|
4
4
|
if (!thread) {
|
|
5
5
|
throw new Error(MutationError.ENTITY_NOT_FOUND);
|
|
6
6
|
}
|
|
7
|
-
const { accountId } = thread;
|
|
8
7
|
const targetLabel = await tx.query.accountLabel
|
|
9
|
-
.where('accountId', accountId)
|
|
8
|
+
.where('accountId', thread.accountId)
|
|
10
9
|
.where('specialUse', targetSpecialUse)
|
|
11
10
|
.one()
|
|
12
11
|
.run();
|
|
13
12
|
if (!targetLabel) {
|
|
14
13
|
throw new Error(MutationError.ENTITY_NOT_FOUND);
|
|
15
14
|
}
|
|
16
|
-
const
|
|
15
|
+
const threadLabels = await tx.query.threadLabel.where('threadId', threadId).run();
|
|
17
16
|
const sourceLocations = [];
|
|
17
|
+
const labelsToDelete = [];
|
|
18
18
|
let hasTarget = false;
|
|
19
|
-
for (const label of
|
|
19
|
+
for (const label of threadLabels) {
|
|
20
20
|
if (label.labelId === targetLabel.id) {
|
|
21
21
|
hasTarget = true;
|
|
22
|
+
continue;
|
|
22
23
|
}
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
label.uidValidity !== null &&
|
|
27
|
-
label.uidValidity !== undefined) {
|
|
28
|
-
sourceLocations.push({
|
|
29
|
-
labelId: label.labelId,
|
|
30
|
-
threadMessageId: label.threadMessageId,
|
|
31
|
-
uid: label.uid,
|
|
32
|
-
uidValidity: label.uidValidity,
|
|
33
|
-
});
|
|
34
|
-
}
|
|
35
|
-
await tx.mutate.threadLabel.delete({
|
|
36
|
-
accountId,
|
|
24
|
+
labelsToDelete.push(label);
|
|
25
|
+
if (label.uid > 0 && label.uidValidity > 0) {
|
|
26
|
+
sourceLocations.push({
|
|
37
27
|
labelId: label.labelId,
|
|
38
28
|
threadMessageId: label.threadMessageId,
|
|
29
|
+
uid: label.uid,
|
|
30
|
+
uidValidity: label.uidValidity,
|
|
39
31
|
});
|
|
40
32
|
}
|
|
41
33
|
}
|
|
34
|
+
for (const label of labelsToDelete) {
|
|
35
|
+
await tx.mutate.threadLabel.delete({
|
|
36
|
+
accountId: thread.accountId,
|
|
37
|
+
labelId: label.labelId,
|
|
38
|
+
threadMessageId: label.threadMessageId,
|
|
39
|
+
});
|
|
40
|
+
}
|
|
42
41
|
if (!hasTarget) {
|
|
43
42
|
const messages = await tx.query.threadMessage.where('threadId', threadId).run();
|
|
44
|
-
|
|
43
|
+
const baseTimestamp = Date.now();
|
|
44
|
+
for (let i = 0; i < messages.length; i++) {
|
|
45
|
+
const message = messages[i];
|
|
45
46
|
await tx.mutate.threadLabel.insert({
|
|
46
|
-
accountId,
|
|
47
|
+
accountId: thread.accountId,
|
|
47
48
|
labelId: targetLabel.id,
|
|
49
|
+
lastSyncedAt: 0,
|
|
48
50
|
threadId,
|
|
49
51
|
threadMessageId: message.id,
|
|
52
|
+
uid: -(baseTimestamp + i),
|
|
53
|
+
uidValidity: targetLabel.uidValidity ?? 0,
|
|
50
54
|
});
|
|
51
55
|
}
|
|
52
56
|
}
|
|
@@ -68,6 +72,8 @@ export const createThreadMutators = (_authData, callbacks) => ({
|
|
|
68
72
|
throw new Error(MutationError.ENTITY_NOT_FOUND);
|
|
69
73
|
}
|
|
70
74
|
const messages = await tx.query.threadMessage.where('threadId', threadId).run();
|
|
75
|
+
const baseTimestamp = Date.now();
|
|
76
|
+
let insertIndex = 0;
|
|
71
77
|
for (const message of messages) {
|
|
72
78
|
const existing = await tx.query.threadLabel
|
|
73
79
|
.where('threadMessageId', message.id)
|
|
@@ -78,9 +84,13 @@ export const createThreadMutators = (_authData, callbacks) => ({
|
|
|
78
84
|
await tx.mutate.threadLabel.insert({
|
|
79
85
|
accountId: thread.accountId,
|
|
80
86
|
labelId: label.id,
|
|
87
|
+
lastSyncedAt: 0,
|
|
81
88
|
threadId,
|
|
82
89
|
threadMessageId: message.id,
|
|
90
|
+
uid: -(baseTimestamp + insertIndex),
|
|
91
|
+
uidValidity: label.uidValidity ?? 0,
|
|
83
92
|
});
|
|
93
|
+
insertIndex++;
|
|
84
94
|
}
|
|
85
95
|
}
|
|
86
96
|
}
|
|
@@ -114,10 +124,7 @@ export const createThreadMutators = (_authData, callbacks) => ({
|
|
|
114
124
|
throw new Error(MutationError.ENTITY_NOT_FOUND);
|
|
115
125
|
}
|
|
116
126
|
for (const existing of existingLabels) {
|
|
117
|
-
if (existing.uid
|
|
118
|
-
existing.uid !== undefined &&
|
|
119
|
-
existing.uidValidity !== null &&
|
|
120
|
-
existing.uidValidity !== undefined) {
|
|
127
|
+
if (existing.uid > 0 && existing.uidValidity > 0) {
|
|
121
128
|
allSourceLocations.push({
|
|
122
129
|
labelId: existing.labelId,
|
|
123
130
|
threadMessageId: existing.threadMessageId,
|
|
@@ -56,18 +56,18 @@ describe('threadMutators', () => {
|
|
|
56
56
|
threadIds: ['test-thread-id-1'],
|
|
57
57
|
});
|
|
58
58
|
expect(threadLabelInsert).toHaveBeenCalledTimes(2);
|
|
59
|
-
expect(threadLabelInsert).toHaveBeenCalledWith({
|
|
59
|
+
expect(threadLabelInsert).toHaveBeenCalledWith(expect.objectContaining({
|
|
60
60
|
accountId: 'test-account-id-1',
|
|
61
61
|
labelId: 'test-label-id-1',
|
|
62
62
|
threadId: 'test-thread-id-1',
|
|
63
63
|
threadMessageId: 'test-message-id-1',
|
|
64
|
-
});
|
|
65
|
-
expect(threadLabelInsert).toHaveBeenCalledWith({
|
|
64
|
+
}));
|
|
65
|
+
expect(threadLabelInsert).toHaveBeenCalledWith(expect.objectContaining({
|
|
66
66
|
accountId: 'test-account-id-1',
|
|
67
67
|
labelId: 'test-label-id-1',
|
|
68
68
|
threadId: 'test-thread-id-1',
|
|
69
69
|
threadMessageId: 'test-message-id-2',
|
|
70
|
-
});
|
|
70
|
+
}));
|
|
71
71
|
});
|
|
72
72
|
});
|
|
73
73
|
describe('delete', () => {
|
|
@@ -257,12 +257,12 @@ describe('threadMutators', () => {
|
|
|
257
257
|
labelId: 'test-inbox-label-id',
|
|
258
258
|
threadMessageId: 'test-message-id-1',
|
|
259
259
|
});
|
|
260
|
-
expect(threadLabelInsert).toHaveBeenCalledWith({
|
|
260
|
+
expect(threadLabelInsert).toHaveBeenCalledWith(expect.objectContaining({
|
|
261
261
|
accountId: 'test-account-id-1',
|
|
262
262
|
labelId: 'test-archive-label-id',
|
|
263
263
|
threadId: 'test-thread-id-1',
|
|
264
264
|
threadMessageId: 'test-message-id-1',
|
|
265
|
-
});
|
|
265
|
+
}));
|
|
266
266
|
});
|
|
267
267
|
});
|
|
268
268
|
describe('setFlagged', () => {
|
|
@@ -346,12 +346,12 @@ describe('threadMutators', () => {
|
|
|
346
346
|
labelId: 'test-archive-label-id',
|
|
347
347
|
threadMessageId: 'test-message-id-1',
|
|
348
348
|
});
|
|
349
|
-
expect(threadLabelInsert).toHaveBeenCalledWith({
|
|
349
|
+
expect(threadLabelInsert).toHaveBeenCalledWith(expect.objectContaining({
|
|
350
350
|
accountId: 'test-account-id-1',
|
|
351
351
|
labelId: 'test-inbox-label-id',
|
|
352
352
|
threadId: 'test-thread-id-1',
|
|
353
353
|
threadMessageId: 'test-message-id-1',
|
|
354
|
-
});
|
|
354
|
+
}));
|
|
355
355
|
});
|
|
356
356
|
});
|
|
357
357
|
describe('setSeen', () => {
|
|
@@ -431,12 +431,12 @@ describe('threadMutators', () => {
|
|
|
431
431
|
sourceLocations: [],
|
|
432
432
|
threadIds: ['test-thread-id-1'],
|
|
433
433
|
});
|
|
434
|
-
expect(threadLabelInsert).toHaveBeenCalledWith({
|
|
434
|
+
expect(threadLabelInsert).toHaveBeenCalledWith(expect.objectContaining({
|
|
435
435
|
accountId: 'test-account-id-1',
|
|
436
436
|
labelId: 'test-spam-label-id',
|
|
437
437
|
threadId: 'test-thread-id-1',
|
|
438
438
|
threadMessageId: 'test-message-id-1',
|
|
439
|
-
});
|
|
439
|
+
}));
|
|
440
440
|
});
|
|
441
441
|
});
|
|
442
442
|
describe('setTrash', () => {
|
|
@@ -489,12 +489,12 @@ describe('threadMutators', () => {
|
|
|
489
489
|
sourceLocations: [],
|
|
490
490
|
threadIds: ['test-thread-id-1'],
|
|
491
491
|
});
|
|
492
|
-
expect(threadLabelInsert).toHaveBeenCalledWith({
|
|
492
|
+
expect(threadLabelInsert).toHaveBeenCalledWith(expect.objectContaining({
|
|
493
493
|
accountId: 'test-account-id-1',
|
|
494
494
|
labelId: 'test-trash-label-id',
|
|
495
495
|
threadId: 'test-thread-id-1',
|
|
496
496
|
threadMessageId: 'test-message-id-1',
|
|
497
|
-
});
|
|
497
|
+
}));
|
|
498
498
|
});
|
|
499
499
|
});
|
|
500
500
|
});
|
|
@@ -237,6 +237,13 @@ export declare const getAccounts: import("@rocicorp/zero").SyncedQuery<"getAccou
|
|
|
237
237
|
} & {
|
|
238
238
|
serverName: string;
|
|
239
239
|
};
|
|
240
|
+
readonly uidValidity: {
|
|
241
|
+
type: "number";
|
|
242
|
+
optional: false;
|
|
243
|
+
customType: number;
|
|
244
|
+
} & {
|
|
245
|
+
serverName: string;
|
|
246
|
+
};
|
|
240
247
|
};
|
|
241
248
|
primaryKey: readonly [string, ...string[]];
|
|
242
249
|
} & {
|
|
@@ -511,6 +518,13 @@ export declare const getAccounts: import("@rocicorp/zero").SyncedQuery<"getAccou
|
|
|
511
518
|
} & {
|
|
512
519
|
serverName: string;
|
|
513
520
|
};
|
|
521
|
+
readonly lastSyncedAt: {
|
|
522
|
+
type: "number";
|
|
523
|
+
optional: false;
|
|
524
|
+
customType: number;
|
|
525
|
+
} & {
|
|
526
|
+
serverName: string;
|
|
527
|
+
};
|
|
514
528
|
readonly threadId: {
|
|
515
529
|
type: "string";
|
|
516
530
|
optional: false;
|
|
@@ -525,19 +539,15 @@ export declare const getAccounts: import("@rocicorp/zero").SyncedQuery<"getAccou
|
|
|
525
539
|
} & {
|
|
526
540
|
serverName: string;
|
|
527
541
|
};
|
|
528
|
-
readonly uid:
|
|
542
|
+
readonly uid: {
|
|
529
543
|
type: "number";
|
|
530
544
|
optional: false;
|
|
531
545
|
customType: number;
|
|
532
|
-
}, "optional"> & {
|
|
533
|
-
optional: true;
|
|
534
546
|
};
|
|
535
|
-
readonly uidValidity:
|
|
547
|
+
readonly uidValidity: {
|
|
536
548
|
type: "number";
|
|
537
549
|
optional: false;
|
|
538
550
|
customType: number;
|
|
539
|
-
}, "optional"> & {
|
|
540
|
-
optional: true;
|
|
541
551
|
} & {
|
|
542
552
|
serverName: string;
|
|
543
553
|
};
|
|
@@ -760,7 +770,7 @@ export declare const getAccounts: import("@rocicorp/zero").SyncedQuery<"getAccou
|
|
|
760
770
|
}];
|
|
761
771
|
labels: [{
|
|
762
772
|
readonly sourceField: string[];
|
|
763
|
-
readonly destField: ("id" | "accountId" | "path" | "specialUse")[];
|
|
773
|
+
readonly destField: ("id" | "accountId" | "path" | "specialUse" | "uidValidity")[];
|
|
764
774
|
readonly destSchema: "accountLabel";
|
|
765
775
|
readonly cardinality: "many";
|
|
766
776
|
}];
|
|
@@ -800,7 +810,7 @@ export declare const getAccounts: import("@rocicorp/zero").SyncedQuery<"getAccou
|
|
|
800
810
|
}];
|
|
801
811
|
threads: [{
|
|
802
812
|
readonly sourceField: string[];
|
|
803
|
-
readonly destField: ("accountId" | "labelId" | "
|
|
813
|
+
readonly destField: ("accountId" | "uidValidity" | "labelId" | "lastSyncedAt" | "threadId" | "threadMessageId" | "uid")[];
|
|
804
814
|
readonly destSchema: "threadLabel";
|
|
805
815
|
readonly cardinality: "many";
|
|
806
816
|
}, {
|
|
@@ -861,12 +871,12 @@ export declare const getAccounts: import("@rocicorp/zero").SyncedQuery<"getAccou
|
|
|
861
871
|
}];
|
|
862
872
|
labels: [{
|
|
863
873
|
readonly sourceField: string[];
|
|
864
|
-
readonly destField: ("accountId" | "labelId" | "
|
|
874
|
+
readonly destField: ("accountId" | "uidValidity" | "labelId" | "lastSyncedAt" | "threadId" | "threadMessageId" | "uid")[];
|
|
865
875
|
readonly destSchema: "threadLabel";
|
|
866
876
|
readonly cardinality: "many";
|
|
867
877
|
}, {
|
|
868
878
|
readonly sourceField: string[];
|
|
869
|
-
readonly destField: ("id" | "accountId" | "path" | "specialUse")[];
|
|
879
|
+
readonly destField: ("id" | "accountId" | "path" | "specialUse" | "uidValidity")[];
|
|
870
880
|
readonly destSchema: "accountLabel";
|
|
871
881
|
readonly cardinality: "many";
|
|
872
882
|
}];
|
|
@@ -886,7 +896,7 @@ export declare const getAccounts: import("@rocicorp/zero").SyncedQuery<"getAccou
|
|
|
886
896
|
readonly threadLabel: {
|
|
887
897
|
label: [{
|
|
888
898
|
readonly sourceField: string[];
|
|
889
|
-
readonly destField: ("id" | "accountId" | "path" | "specialUse")[];
|
|
899
|
+
readonly destField: ("id" | "accountId" | "path" | "specialUse" | "uidValidity")[];
|
|
890
900
|
readonly destSchema: "accountLabel";
|
|
891
901
|
readonly cardinality: "one";
|
|
892
902
|
}];
|
|
@@ -912,12 +922,12 @@ export declare const getAccounts: import("@rocicorp/zero").SyncedQuery<"getAccou
|
|
|
912
922
|
}];
|
|
913
923
|
labels: [{
|
|
914
924
|
readonly sourceField: string[];
|
|
915
|
-
readonly destField: ("accountId" | "labelId" | "
|
|
925
|
+
readonly destField: ("accountId" | "uidValidity" | "labelId" | "lastSyncedAt" | "threadId" | "threadMessageId" | "uid")[];
|
|
916
926
|
readonly destSchema: "threadLabel";
|
|
917
927
|
readonly cardinality: "many";
|
|
918
928
|
}, {
|
|
919
929
|
readonly sourceField: string[];
|
|
920
|
-
readonly destField: ("id" | "accountId" | "path" | "specialUse")[];
|
|
930
|
+
readonly destField: ("id" | "accountId" | "path" | "specialUse" | "uidValidity")[];
|
|
921
931
|
readonly destSchema: "accountLabel";
|
|
922
932
|
readonly cardinality: "many";
|
|
923
933
|
}];
|
|
@@ -984,6 +994,7 @@ export declare const getAccounts: import("@rocicorp/zero").SyncedQuery<"getAccou
|
|
|
984
994
|
readonly id: string;
|
|
985
995
|
readonly path: string;
|
|
986
996
|
readonly specialUse: "ARCHIVE" | "INBOX" | "SENT" | "SPAM" | "TRASH" | null;
|
|
997
|
+
readonly uidValidity: number;
|
|
987
998
|
}[];
|
|
988
999
|
}>>;
|
|
989
1000
|
//# sourceMappingURL=getAccounts.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getAccounts.d.ts","sourceRoot":"","sources":["../../../src/zero/queries/getAccounts.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,qBAAqB,CAAA;AAGlE,eAAO,MAAM,WAAW
|
|
1
|
+
{"version":3,"file":"getAccounts.d.ts","sourceRoot":"","sources":["../../../src/zero/queries/getAccounts.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,qBAAqB,CAAA;AAGlE,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;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@rocicorp/zero").SyncedQuery<"getConta
|
|
|
246
246
|
} & {
|
|
247
247
|
serverName: string;
|
|
248
248
|
};
|
|
249
|
+
readonly uidValidity: {
|
|
250
|
+
type: "number";
|
|
251
|
+
optional: false;
|
|
252
|
+
customType: number;
|
|
253
|
+
} & {
|
|
254
|
+
serverName: string;
|
|
255
|
+
};
|
|
249
256
|
};
|
|
250
257
|
primaryKey: readonly [string, ...string[]];
|
|
251
258
|
} & {
|
|
@@ -520,6 +527,13 @@ export declare const getContacts: import("@rocicorp/zero").SyncedQuery<"getConta
|
|
|
520
527
|
} & {
|
|
521
528
|
serverName: string;
|
|
522
529
|
};
|
|
530
|
+
readonly lastSyncedAt: {
|
|
531
|
+
type: "number";
|
|
532
|
+
optional: false;
|
|
533
|
+
customType: number;
|
|
534
|
+
} & {
|
|
535
|
+
serverName: string;
|
|
536
|
+
};
|
|
523
537
|
readonly threadId: {
|
|
524
538
|
type: "string";
|
|
525
539
|
optional: false;
|
|
@@ -534,19 +548,15 @@ export declare const getContacts: import("@rocicorp/zero").SyncedQuery<"getConta
|
|
|
534
548
|
} & {
|
|
535
549
|
serverName: string;
|
|
536
550
|
};
|
|
537
|
-
readonly uid:
|
|
551
|
+
readonly uid: {
|
|
538
552
|
type: "number";
|
|
539
553
|
optional: false;
|
|
540
554
|
customType: number;
|
|
541
|
-
}, "optional"> & {
|
|
542
|
-
optional: true;
|
|
543
555
|
};
|
|
544
|
-
readonly uidValidity:
|
|
556
|
+
readonly uidValidity: {
|
|
545
557
|
type: "number";
|
|
546
558
|
optional: false;
|
|
547
559
|
customType: number;
|
|
548
|
-
}, "optional"> & {
|
|
549
|
-
optional: true;
|
|
550
560
|
} & {
|
|
551
561
|
serverName: string;
|
|
552
562
|
};
|
|
@@ -769,7 +779,7 @@ export declare const getContacts: import("@rocicorp/zero").SyncedQuery<"getConta
|
|
|
769
779
|
}];
|
|
770
780
|
labels: [{
|
|
771
781
|
readonly sourceField: string[];
|
|
772
|
-
readonly destField: ("id" | "accountId" | "path" | "specialUse")[];
|
|
782
|
+
readonly destField: ("id" | "accountId" | "path" | "specialUse" | "uidValidity")[];
|
|
773
783
|
readonly destSchema: "accountLabel";
|
|
774
784
|
readonly cardinality: "many";
|
|
775
785
|
}];
|
|
@@ -809,7 +819,7 @@ export declare const getContacts: import("@rocicorp/zero").SyncedQuery<"getConta
|
|
|
809
819
|
}];
|
|
810
820
|
threads: [{
|
|
811
821
|
readonly sourceField: string[];
|
|
812
|
-
readonly destField: ("accountId" | "labelId" | "
|
|
822
|
+
readonly destField: ("accountId" | "uidValidity" | "labelId" | "lastSyncedAt" | "threadId" | "threadMessageId" | "uid")[];
|
|
813
823
|
readonly destSchema: "threadLabel";
|
|
814
824
|
readonly cardinality: "many";
|
|
815
825
|
}, {
|
|
@@ -870,12 +880,12 @@ export declare const getContacts: import("@rocicorp/zero").SyncedQuery<"getConta
|
|
|
870
880
|
}];
|
|
871
881
|
labels: [{
|
|
872
882
|
readonly sourceField: string[];
|
|
873
|
-
readonly destField: ("accountId" | "labelId" | "
|
|
883
|
+
readonly destField: ("accountId" | "uidValidity" | "labelId" | "lastSyncedAt" | "threadId" | "threadMessageId" | "uid")[];
|
|
874
884
|
readonly destSchema: "threadLabel";
|
|
875
885
|
readonly cardinality: "many";
|
|
876
886
|
}, {
|
|
877
887
|
readonly sourceField: string[];
|
|
878
|
-
readonly destField: ("id" | "accountId" | "path" | "specialUse")[];
|
|
888
|
+
readonly destField: ("id" | "accountId" | "path" | "specialUse" | "uidValidity")[];
|
|
879
889
|
readonly destSchema: "accountLabel";
|
|
880
890
|
readonly cardinality: "many";
|
|
881
891
|
}];
|
|
@@ -895,7 +905,7 @@ export declare const getContacts: import("@rocicorp/zero").SyncedQuery<"getConta
|
|
|
895
905
|
readonly threadLabel: {
|
|
896
906
|
label: [{
|
|
897
907
|
readonly sourceField: string[];
|
|
898
|
-
readonly destField: ("id" | "accountId" | "path" | "specialUse")[];
|
|
908
|
+
readonly destField: ("id" | "accountId" | "path" | "specialUse" | "uidValidity")[];
|
|
899
909
|
readonly destSchema: "accountLabel";
|
|
900
910
|
readonly cardinality: "one";
|
|
901
911
|
}];
|
|
@@ -921,12 +931,12 @@ export declare const getContacts: import("@rocicorp/zero").SyncedQuery<"getConta
|
|
|
921
931
|
}];
|
|
922
932
|
labels: [{
|
|
923
933
|
readonly sourceField: string[];
|
|
924
|
-
readonly destField: ("accountId" | "labelId" | "
|
|
934
|
+
readonly destField: ("accountId" | "uidValidity" | "labelId" | "lastSyncedAt" | "threadId" | "threadMessageId" | "uid")[];
|
|
925
935
|
readonly destSchema: "threadLabel";
|
|
926
936
|
readonly cardinality: "many";
|
|
927
937
|
}, {
|
|
928
938
|
readonly sourceField: string[];
|
|
929
|
-
readonly destField: ("id" | "accountId" | "path" | "specialUse")[];
|
|
939
|
+
readonly destField: ("id" | "accountId" | "path" | "specialUse" | "uidValidity")[];
|
|
930
940
|
readonly destSchema: "accountLabel";
|
|
931
941
|
readonly cardinality: "many";
|
|
932
942
|
}];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getContacts.d.ts","sourceRoot":"","sources":["../../../src/zero/queries/getContacts.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,qBAAqB,CAAA;AAMlE,KAAK,eAAe,GAAG;IACrB,KAAK,EAAE,MAAM,CAAA;IACb,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,KAAK,CAAC,EAAE;QACN,YAAY,CAAC,EAAE,MAAM,CAAA;QACrB,GAAG,CAAC,EAAE,MAAM,EAAE,CAAA;QACd,IAAI,CAAC,EAAE,MAAM,CAAA;KACd,CAAA;CACF,CAAA;AAiBD,eAAO,MAAM,WAAW
|
|
1
|
+
{"version":3,"file":"getContacts.d.ts","sourceRoot":"","sources":["../../../src/zero/queries/getContacts.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,qBAAqB,CAAA;AAMlE,KAAK,eA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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BvB,CAAA"}
|
|
@@ -243,6 +243,13 @@ export declare const getDrafts: import("@rocicorp/zero").SyncedQuery<"getDrafts"
|
|
|
243
243
|
} & {
|
|
244
244
|
serverName: string;
|
|
245
245
|
};
|
|
246
|
+
readonly uidValidity: {
|
|
247
|
+
type: "number";
|
|
248
|
+
optional: false;
|
|
249
|
+
customType: number;
|
|
250
|
+
} & {
|
|
251
|
+
serverName: string;
|
|
252
|
+
};
|
|
246
253
|
};
|
|
247
254
|
primaryKey: readonly [string, ...string[]];
|
|
248
255
|
} & {
|
|
@@ -517,6 +524,13 @@ export declare const getDrafts: import("@rocicorp/zero").SyncedQuery<"getDrafts"
|
|
|
517
524
|
} & {
|
|
518
525
|
serverName: string;
|
|
519
526
|
};
|
|
527
|
+
readonly lastSyncedAt: {
|
|
528
|
+
type: "number";
|
|
529
|
+
optional: false;
|
|
530
|
+
customType: number;
|
|
531
|
+
} & {
|
|
532
|
+
serverName: string;
|
|
533
|
+
};
|
|
520
534
|
readonly threadId: {
|
|
521
535
|
type: "string";
|
|
522
536
|
optional: false;
|
|
@@ -531,19 +545,15 @@ export declare const getDrafts: import("@rocicorp/zero").SyncedQuery<"getDrafts"
|
|
|
531
545
|
} & {
|
|
532
546
|
serverName: string;
|
|
533
547
|
};
|
|
534
|
-
readonly uid:
|
|
548
|
+
readonly uid: {
|
|
535
549
|
type: "number";
|
|
536
550
|
optional: false;
|
|
537
551
|
customType: number;
|
|
538
|
-
}, "optional"> & {
|
|
539
|
-
optional: true;
|
|
540
552
|
};
|
|
541
|
-
readonly uidValidity:
|
|
553
|
+
readonly uidValidity: {
|
|
542
554
|
type: "number";
|
|
543
555
|
optional: false;
|
|
544
556
|
customType: number;
|
|
545
|
-
}, "optional"> & {
|
|
546
|
-
optional: true;
|
|
547
557
|
} & {
|
|
548
558
|
serverName: string;
|
|
549
559
|
};
|
|
@@ -766,7 +776,7 @@ export declare const getDrafts: import("@rocicorp/zero").SyncedQuery<"getDrafts"
|
|
|
766
776
|
}];
|
|
767
777
|
labels: [{
|
|
768
778
|
readonly sourceField: string[];
|
|
769
|
-
readonly destField: ("id" | "accountId" | "path" | "specialUse")[];
|
|
779
|
+
readonly destField: ("id" | "accountId" | "path" | "specialUse" | "uidValidity")[];
|
|
770
780
|
readonly destSchema: "accountLabel";
|
|
771
781
|
readonly cardinality: "many";
|
|
772
782
|
}];
|
|
@@ -806,7 +816,7 @@ export declare const getDrafts: import("@rocicorp/zero").SyncedQuery<"getDrafts"
|
|
|
806
816
|
}];
|
|
807
817
|
threads: [{
|
|
808
818
|
readonly sourceField: string[];
|
|
809
|
-
readonly destField: ("accountId" | "labelId" | "
|
|
819
|
+
readonly destField: ("accountId" | "uidValidity" | "labelId" | "lastSyncedAt" | "threadId" | "threadMessageId" | "uid")[];
|
|
810
820
|
readonly destSchema: "threadLabel";
|
|
811
821
|
readonly cardinality: "many";
|
|
812
822
|
}, {
|
|
@@ -867,12 +877,12 @@ export declare const getDrafts: import("@rocicorp/zero").SyncedQuery<"getDrafts"
|
|
|
867
877
|
}];
|
|
868
878
|
labels: [{
|
|
869
879
|
readonly sourceField: string[];
|
|
870
|
-
readonly destField: ("accountId" | "labelId" | "
|
|
880
|
+
readonly destField: ("accountId" | "uidValidity" | "labelId" | "lastSyncedAt" | "threadId" | "threadMessageId" | "uid")[];
|
|
871
881
|
readonly destSchema: "threadLabel";
|
|
872
882
|
readonly cardinality: "many";
|
|
873
883
|
}, {
|
|
874
884
|
readonly sourceField: string[];
|
|
875
|
-
readonly destField: ("id" | "accountId" | "path" | "specialUse")[];
|
|
885
|
+
readonly destField: ("id" | "accountId" | "path" | "specialUse" | "uidValidity")[];
|
|
876
886
|
readonly destSchema: "accountLabel";
|
|
877
887
|
readonly cardinality: "many";
|
|
878
888
|
}];
|
|
@@ -892,7 +902,7 @@ export declare const getDrafts: import("@rocicorp/zero").SyncedQuery<"getDrafts"
|
|
|
892
902
|
readonly threadLabel: {
|
|
893
903
|
label: [{
|
|
894
904
|
readonly sourceField: string[];
|
|
895
|
-
readonly destField: ("id" | "accountId" | "path" | "specialUse")[];
|
|
905
|
+
readonly destField: ("id" | "accountId" | "path" | "specialUse" | "uidValidity")[];
|
|
896
906
|
readonly destSchema: "accountLabel";
|
|
897
907
|
readonly cardinality: "one";
|
|
898
908
|
}];
|
|
@@ -918,12 +928,12 @@ export declare const getDrafts: import("@rocicorp/zero").SyncedQuery<"getDrafts"
|
|
|
918
928
|
}];
|
|
919
929
|
labels: [{
|
|
920
930
|
readonly sourceField: string[];
|
|
921
|
-
readonly destField: ("accountId" | "labelId" | "
|
|
931
|
+
readonly destField: ("accountId" | "uidValidity" | "labelId" | "lastSyncedAt" | "threadId" | "threadMessageId" | "uid")[];
|
|
922
932
|
readonly destSchema: "threadLabel";
|
|
923
933
|
readonly cardinality: "many";
|
|
924
934
|
}, {
|
|
925
935
|
readonly sourceField: string[];
|
|
926
|
-
readonly destField: ("id" | "accountId" | "path" | "specialUse")[];
|
|
936
|
+
readonly destField: ("id" | "accountId" | "path" | "specialUse" | "uidValidity")[];
|
|
927
937
|
readonly destSchema: "accountLabel";
|
|
928
938
|
readonly cardinality: "many";
|
|
929
939
|
}];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getDrafts.d.ts","sourceRoot":"","sources":["../../../src/zero/queries/getDrafts.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,qBAAqB,CAAA;AAClE,OAAO,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAA;AAMpD,KAAK,aAAa,GAAG;IACnB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,KAAK,EAAE,MAAM,CAAA;IACb,MAAM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