@timothyw/pat-common 1.0.88 → 1.0.89
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/types/api/account/update-user-types.d.ts +1 -10
- package/dist/types/api/account/update-user-types.js +1 -1
- package/dist/types/models/auth-data.d.ts +1 -1
- package/dist/types/models/habit-data.d.ts +2 -2
- package/dist/types/models/item-data.d.ts +1 -1
- package/dist/types/models/person-data.d.ts +3 -3
- package/dist/types/models/task-data.d.ts +2 -2
- package/dist/types/models/thought-data.d.ts +1 -1
- package/dist/types/models/user-data.d.ts +3 -3
- package/dist/types/models/user-data.js +1 -1
- package/package.json +1 -1
- package/src/types/api/account/update-user-types.ts +1 -1
- package/src/types/models/auth-data.ts +1 -1
- package/src/types/models/habit-data.ts +2 -2
- package/src/types/models/item-data.ts +1 -1
- package/src/types/models/person-data.ts +3 -3
- package/src/types/models/task-data.ts +2 -2
- package/src/types/models/thought-data.ts +1 -1
- package/src/types/models/user-data.ts +1 -1
|
@@ -1,9 +1,7 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
2
|
import { UserData } from "../../models";
|
|
3
3
|
export declare const updateUserRequestSchema: z.ZodObject<{
|
|
4
|
-
|
|
5
|
-
createdAt: z.ZodOptional<z.ZodDate>;
|
|
6
|
-
updatedAt: z.ZodOptional<z.ZodDate>;
|
|
4
|
+
name: z.ZodOptional<z.ZodString>;
|
|
7
5
|
sandbox: z.ZodOptional<z.ZodObject<{
|
|
8
6
|
discordId: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
9
7
|
devices: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
@@ -24,7 +22,6 @@ export declare const updateUserRequestSchema: z.ZodObject<{
|
|
|
24
22
|
pushToken?: string | undefined;
|
|
25
23
|
}[] | undefined;
|
|
26
24
|
}>>;
|
|
27
|
-
name: z.ZodOptional<z.ZodString>;
|
|
28
25
|
timezone: z.ZodOptional<z.ZodEffects<z.ZodString, string, string>>;
|
|
29
26
|
config: z.ZodOptional<z.ZodObject<{
|
|
30
27
|
modules: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
@@ -80,9 +77,6 @@ export declare const updateUserRequestSchema: z.ZodObject<{
|
|
|
80
77
|
}[] | undefined;
|
|
81
78
|
}>>;
|
|
82
79
|
}, "strict", z.ZodTypeAny, {
|
|
83
|
-
id?: import("../..").UserId | undefined;
|
|
84
|
-
createdAt?: Date | undefined;
|
|
85
|
-
updatedAt?: Date | undefined;
|
|
86
80
|
name?: string | undefined;
|
|
87
81
|
sandbox?: {
|
|
88
82
|
discordId?: string | undefined;
|
|
@@ -105,9 +99,6 @@ export declare const updateUserRequestSchema: z.ZodObject<{
|
|
|
105
99
|
}[] | undefined;
|
|
106
100
|
} | undefined;
|
|
107
101
|
}, {
|
|
108
|
-
id?: string | undefined;
|
|
109
|
-
createdAt?: Date | undefined;
|
|
110
|
-
updatedAt?: Date | undefined;
|
|
111
102
|
name?: string | undefined;
|
|
112
103
|
sandbox?: {
|
|
113
104
|
discordId?: string | undefined;
|
|
@@ -3,6 +3,6 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.updateUserRequestSchema = void 0;
|
|
4
4
|
const models_1 = require("../../models");
|
|
5
5
|
exports.updateUserRequestSchema = models_1.userDataSchema
|
|
6
|
-
|
|
6
|
+
.omit({ _id: true, createdAt: true, updatedAt: true })
|
|
7
7
|
.deepPartial()
|
|
8
8
|
.strict();
|
|
@@ -13,7 +13,7 @@ export declare enum HabitEntryStatus {
|
|
|
13
13
|
INCOMPLETE = "incomplete"
|
|
14
14
|
}
|
|
15
15
|
export interface HabitEntryData {
|
|
16
|
-
|
|
16
|
+
_id: HabitEntryId;
|
|
17
17
|
habitId: HabitId;
|
|
18
18
|
userId: UserId;
|
|
19
19
|
date: DateOnlyString;
|
|
@@ -22,7 +22,7 @@ export interface HabitEntryData {
|
|
|
22
22
|
updatedAt: Date;
|
|
23
23
|
}
|
|
24
24
|
export interface HabitData {
|
|
25
|
-
|
|
25
|
+
_id: HabitId;
|
|
26
26
|
userId: UserId;
|
|
27
27
|
name: string;
|
|
28
28
|
description?: string | null;
|
|
@@ -4,7 +4,7 @@ export interface PersonProperty {
|
|
|
4
4
|
value: string;
|
|
5
5
|
}
|
|
6
6
|
export interface PersonNoteData {
|
|
7
|
-
|
|
7
|
+
_id: PersonNoteId;
|
|
8
8
|
personId: PersonId;
|
|
9
9
|
userId: UserId;
|
|
10
10
|
content: string;
|
|
@@ -12,7 +12,7 @@ export interface PersonNoteData {
|
|
|
12
12
|
updatedAt: Date;
|
|
13
13
|
}
|
|
14
14
|
export interface PersonData {
|
|
15
|
-
|
|
15
|
+
_id: PersonId;
|
|
16
16
|
userId: UserId;
|
|
17
17
|
createdAt: Date;
|
|
18
18
|
updatedAt: Date;
|
|
@@ -21,7 +21,7 @@ export interface PersonData {
|
|
|
21
21
|
noteIds: PersonNoteId[];
|
|
22
22
|
}
|
|
23
23
|
export interface Person {
|
|
24
|
-
|
|
24
|
+
_id: PersonId;
|
|
25
25
|
userId: UserId;
|
|
26
26
|
createdAt: Date;
|
|
27
27
|
updatedAt: Date;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { TaskId, TaskListId, UserId } from "../id-types";
|
|
2
2
|
export interface TaskData {
|
|
3
|
-
|
|
3
|
+
_id: TaskId;
|
|
4
4
|
userId: UserId;
|
|
5
5
|
createdAt: Date;
|
|
6
6
|
updatedAt: Date;
|
|
@@ -10,7 +10,7 @@ export interface TaskData {
|
|
|
10
10
|
taskListId: TaskListId;
|
|
11
11
|
}
|
|
12
12
|
export interface TaskListData {
|
|
13
|
-
|
|
13
|
+
_id: TaskListId;
|
|
14
14
|
userId: UserId;
|
|
15
15
|
createdAt: Date;
|
|
16
16
|
updatedAt: Date;
|
|
@@ -11,7 +11,7 @@ declare const moduleSchema: z.ZodObject<{
|
|
|
11
11
|
visible: boolean;
|
|
12
12
|
}>;
|
|
13
13
|
export declare const userDataSchema: z.ZodObject<{
|
|
14
|
-
|
|
14
|
+
_id: z.ZodEffects<z.ZodString, import("../id-types").UserId, string>;
|
|
15
15
|
createdAt: z.ZodDate;
|
|
16
16
|
updatedAt: z.ZodDate;
|
|
17
17
|
sandbox: z.ZodObject<{
|
|
@@ -90,7 +90,7 @@ export declare const userDataSchema: z.ZodObject<{
|
|
|
90
90
|
}[];
|
|
91
91
|
}>;
|
|
92
92
|
}, "strip", z.ZodTypeAny, {
|
|
93
|
-
|
|
93
|
+
_id: string & {
|
|
94
94
|
readonly __brand: "UserId";
|
|
95
95
|
};
|
|
96
96
|
createdAt: Date;
|
|
@@ -117,7 +117,7 @@ export declare const userDataSchema: z.ZodObject<{
|
|
|
117
117
|
}[];
|
|
118
118
|
};
|
|
119
119
|
}, {
|
|
120
|
-
|
|
120
|
+
_id: string;
|
|
121
121
|
createdAt: Date;
|
|
122
122
|
updatedAt: Date;
|
|
123
123
|
name: string;
|
|
@@ -12,7 +12,7 @@ const deviceSchema = zod_1.z.object({
|
|
|
12
12
|
pushToken: zod_1.z.string()
|
|
13
13
|
});
|
|
14
14
|
exports.userDataSchema = zod_1.z.object({
|
|
15
|
-
|
|
15
|
+
_id: id_types_1.userIdSchema,
|
|
16
16
|
createdAt: zod_1.z.date(),
|
|
17
17
|
updatedAt: zod_1.z.date(),
|
|
18
18
|
sandbox: zod_1.z.object({
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@ import { z } from "zod";
|
|
|
2
2
|
import { UserData, userDataSchema } from "../../models";
|
|
3
3
|
|
|
4
4
|
export const updateUserRequestSchema = userDataSchema
|
|
5
|
-
|
|
5
|
+
.omit({ _id: true, createdAt: true, updatedAt: true })
|
|
6
6
|
.deepPartial()
|
|
7
7
|
.strict();
|
|
8
8
|
|
|
@@ -16,7 +16,7 @@ export enum HabitEntryStatus {
|
|
|
16
16
|
}
|
|
17
17
|
|
|
18
18
|
export interface HabitEntryData {
|
|
19
|
-
|
|
19
|
+
_id: HabitEntryId;
|
|
20
20
|
habitId: HabitId;
|
|
21
21
|
userId: UserId;
|
|
22
22
|
date: DateOnlyString;
|
|
@@ -26,7 +26,7 @@ export interface HabitEntryData {
|
|
|
26
26
|
}
|
|
27
27
|
|
|
28
28
|
export interface HabitData {
|
|
29
|
-
|
|
29
|
+
_id: HabitId;
|
|
30
30
|
userId: UserId;
|
|
31
31
|
name: string;
|
|
32
32
|
description?: string | null;
|
|
@@ -6,7 +6,7 @@ export interface PersonProperty {
|
|
|
6
6
|
}
|
|
7
7
|
|
|
8
8
|
export interface PersonNoteData {
|
|
9
|
-
|
|
9
|
+
_id: PersonNoteId;
|
|
10
10
|
personId: PersonId;
|
|
11
11
|
userId: UserId;
|
|
12
12
|
content: string;
|
|
@@ -15,7 +15,7 @@ export interface PersonNoteData {
|
|
|
15
15
|
}
|
|
16
16
|
|
|
17
17
|
export interface PersonData {
|
|
18
|
-
|
|
18
|
+
_id: PersonId;
|
|
19
19
|
userId: UserId;
|
|
20
20
|
createdAt: Date;
|
|
21
21
|
updatedAt: Date;
|
|
@@ -25,7 +25,7 @@ export interface PersonData {
|
|
|
25
25
|
}
|
|
26
26
|
|
|
27
27
|
export interface Person {
|
|
28
|
-
|
|
28
|
+
_id: PersonId;
|
|
29
29
|
userId: UserId;
|
|
30
30
|
createdAt: Date;
|
|
31
31
|
updatedAt: Date;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { TaskId, TaskListId, UserId } from "../id-types";
|
|
2
2
|
|
|
3
3
|
export interface TaskData {
|
|
4
|
-
|
|
4
|
+
_id: TaskId;
|
|
5
5
|
userId: UserId;
|
|
6
6
|
createdAt: Date;
|
|
7
7
|
updatedAt: Date;
|
|
@@ -12,7 +12,7 @@ export interface TaskData {
|
|
|
12
12
|
}
|
|
13
13
|
|
|
14
14
|
export interface TaskListData {
|
|
15
|
-
|
|
15
|
+
_id: TaskListId;
|
|
16
16
|
userId: UserId;
|
|
17
17
|
createdAt: Date;
|
|
18
18
|
updatedAt: Date;
|