pocketbase-zod-schema 0.2.3 → 0.2.5

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.
Files changed (71) hide show
  1. package/CHANGELOG.md +14 -0
  2. package/README.md +209 -24
  3. package/dist/cli/index.cjs +34 -0
  4. package/dist/cli/index.cjs.map +1 -1
  5. package/dist/cli/index.d.cts +3 -1
  6. package/dist/cli/index.d.ts +3 -1
  7. package/dist/cli/index.js +34 -0
  8. package/dist/cli/index.js.map +1 -1
  9. package/dist/cli/migrate.cjs +34 -0
  10. package/dist/cli/migrate.cjs.map +1 -1
  11. package/dist/cli/migrate.js +34 -0
  12. package/dist/cli/migrate.js.map +1 -1
  13. package/dist/cli/utils/index.d.cts +3 -1
  14. package/dist/cli/utils/index.d.ts +3 -1
  15. package/dist/fields-YjcpBXVp.d.cts +348 -0
  16. package/dist/fields-YjcpBXVp.d.ts +348 -0
  17. package/dist/index.cjs +833 -694
  18. package/dist/index.cjs.map +1 -1
  19. package/dist/index.d.cts +3 -4
  20. package/dist/index.d.ts +3 -4
  21. package/dist/index.js +818 -687
  22. package/dist/index.js.map +1 -1
  23. package/dist/migration/analyzer.cjs +34 -0
  24. package/dist/migration/analyzer.cjs.map +1 -1
  25. package/dist/migration/analyzer.d.cts +2 -1
  26. package/dist/migration/analyzer.d.ts +2 -1
  27. package/dist/migration/analyzer.js +34 -0
  28. package/dist/migration/analyzer.js.map +1 -1
  29. package/dist/migration/diff.d.cts +3 -1
  30. package/dist/migration/diff.d.ts +3 -1
  31. package/dist/migration/generator.d.cts +3 -1
  32. package/dist/migration/generator.d.ts +3 -1
  33. package/dist/migration/index.cjs +36 -0
  34. package/dist/migration/index.cjs.map +1 -1
  35. package/dist/migration/index.d.cts +2 -1
  36. package/dist/migration/index.d.ts +2 -1
  37. package/dist/migration/index.js +35 -1
  38. package/dist/migration/index.js.map +1 -1
  39. package/dist/migration/snapshot.cjs.map +1 -1
  40. package/dist/migration/snapshot.d.cts +3 -1
  41. package/dist/migration/snapshot.d.ts +3 -1
  42. package/dist/migration/snapshot.js.map +1 -1
  43. package/dist/migration/utils/index.cjs +16 -0
  44. package/dist/migration/utils/index.cjs.map +1 -1
  45. package/dist/migration/utils/index.d.cts +2 -2
  46. package/dist/migration/utils/index.d.ts +2 -2
  47. package/dist/migration/utils/index.js +15 -1
  48. package/dist/migration/utils/index.js.map +1 -1
  49. package/dist/mutator.cjs +2 -98
  50. package/dist/mutator.cjs.map +1 -1
  51. package/dist/mutator.d.cts +4 -31
  52. package/dist/mutator.d.ts +4 -31
  53. package/dist/mutator.js +2 -98
  54. package/dist/mutator.js.map +1 -1
  55. package/dist/schema.cjs +200 -78
  56. package/dist/schema.cjs.map +1 -1
  57. package/dist/schema.d.cts +1 -1
  58. package/dist/schema.d.ts +1 -1
  59. package/dist/schema.js +186 -72
  60. package/dist/schema.js.map +1 -1
  61. package/dist/{types-z1Dkjg8m.d.ts → types-LFBGHl9Y.d.ts} +2 -2
  62. package/dist/{types-BbTgmg6H.d.cts → types-mhQXWNi3.d.cts} +2 -2
  63. package/package.json +1 -6
  64. package/dist/types.cjs +0 -4
  65. package/dist/types.cjs.map +0 -1
  66. package/dist/types.d.cts +0 -14
  67. package/dist/types.d.ts +0 -14
  68. package/dist/types.js +0 -3
  69. package/dist/types.js.map +0 -1
  70. package/dist/user-BnFWg5tw.d.cts +0 -161
  71. package/dist/user-BnFWg5tw.d.ts +0 -161
@@ -1,161 +0,0 @@
1
- import { z } from 'zod';
2
-
3
- declare const ProjectInputSchema: z.ZodObject<{
4
- title: z.ZodString;
5
- content: z.ZodString;
6
- status: z.ZodEnum<["draft", "active", "complete", "fail"]>;
7
- summary: z.ZodOptional<z.ZodString>;
8
- OwnerUser: z.ZodString;
9
- SubscriberUsers: z.ZodArray<z.ZodString, "many">;
10
- } & {
11
- imageFiles: z.ZodArray<z.ZodType<File, z.ZodTypeDef, File>, "many">;
12
- }, "strip", z.ZodTypeAny, {
13
- status: "draft" | "active" | "complete" | "fail";
14
- title: string;
15
- content: string;
16
- OwnerUser: string;
17
- SubscriberUsers: string[];
18
- imageFiles: File[];
19
- summary?: string | undefined;
20
- }, {
21
- status: "draft" | "active" | "complete" | "fail";
22
- title: string;
23
- content: string;
24
- OwnerUser: string;
25
- SubscriberUsers: string[];
26
- imageFiles: File[];
27
- summary?: string | undefined;
28
- }>;
29
- declare const ProjectSchema: z.ZodObject<Omit<{
30
- title: z.ZodString;
31
- content: z.ZodString;
32
- status: z.ZodEnum<["draft", "active", "complete", "fail"]>;
33
- summary: z.ZodOptional<z.ZodString>;
34
- OwnerUser: z.ZodString;
35
- SubscriberUsers: z.ZodArray<z.ZodString, "many">;
36
- } & {
37
- imageFiles: z.ZodArray<z.ZodType<File, z.ZodTypeDef, File>, "many">;
38
- }, "imageFiles"> & {
39
- thumbnailURL: z.ZodOptional<z.ZodString>;
40
- imageFiles: z.ZodArray<z.ZodString, "many">;
41
- id: z.ZodString;
42
- collectionId: z.ZodString;
43
- collectionName: z.ZodString;
44
- expand: z.ZodRecord<z.ZodString, z.ZodAny>;
45
- created: z.ZodString;
46
- updated: z.ZodString;
47
- }, "strip", z.ZodTypeAny, {
48
- status: "draft" | "active" | "complete" | "fail";
49
- collectionName: string;
50
- title: string;
51
- content: string;
52
- OwnerUser: string;
53
- SubscriberUsers: string[];
54
- imageFiles: string[];
55
- id: string;
56
- collectionId: string;
57
- expand: Record<string, any>;
58
- created: string;
59
- updated: string;
60
- summary?: string | undefined;
61
- thumbnailURL?: string | undefined;
62
- }, {
63
- status: "draft" | "active" | "complete" | "fail";
64
- collectionName: string;
65
- title: string;
66
- content: string;
67
- OwnerUser: string;
68
- SubscriberUsers: string[];
69
- imageFiles: string[];
70
- id: string;
71
- collectionId: string;
72
- expand: Record<string, any>;
73
- created: string;
74
- updated: string;
75
- summary?: string | undefined;
76
- thumbnailURL?: string | undefined;
77
- }>;
78
- declare const ProjectCollection: z.ZodObject<any, z.UnknownKeysParam, z.ZodTypeAny, {
79
- [x: string]: any;
80
- }, {
81
- [x: string]: any;
82
- }>;
83
-
84
- /** -- User Collections -- */
85
- declare const UserInputSchema: z.ZodObject<{
86
- name: z.ZodOptional<z.ZodString>;
87
- email: z.ZodString;
88
- password: z.ZodString;
89
- passwordConfirm: z.ZodString;
90
- avatar: z.ZodOptional<z.ZodType<File, z.ZodTypeDef, File>>;
91
- }, "strip", z.ZodTypeAny, {
92
- email: string;
93
- password: string;
94
- passwordConfirm: string;
95
- name?: string | undefined;
96
- avatar?: File | undefined;
97
- }, {
98
- email: string;
99
- password: string;
100
- passwordConfirm: string;
101
- name?: string | undefined;
102
- avatar?: File | undefined;
103
- }>;
104
- declare const UserCollectionSchema: z.ZodObject<{
105
- name: z.ZodOptional<z.ZodString>;
106
- email: z.ZodString;
107
- password: z.ZodString;
108
- avatar: z.ZodOptional<z.ZodType<File, z.ZodTypeDef, File>>;
109
- }, "strip", z.ZodTypeAny, {
110
- email: string;
111
- password: string;
112
- name?: string | undefined;
113
- avatar?: File | undefined;
114
- }, {
115
- email: string;
116
- password: string;
117
- name?: string | undefined;
118
- avatar?: File | undefined;
119
- }>;
120
- declare const UserSchema: z.ZodObject<{
121
- name: z.ZodOptional<z.ZodString>;
122
- email: z.ZodString;
123
- password: z.ZodString;
124
- avatar: z.ZodOptional<z.ZodType<File, z.ZodTypeDef, File>>;
125
- } & {
126
- id: z.ZodString;
127
- collectionId: z.ZodString;
128
- collectionName: z.ZodString;
129
- expand: z.ZodRecord<z.ZodString, z.ZodAny>;
130
- created: z.ZodString;
131
- updated: z.ZodString;
132
- }, "strip", z.ZodTypeAny, {
133
- collectionName: string;
134
- id: string;
135
- collectionId: string;
136
- expand: Record<string, any>;
137
- created: string;
138
- updated: string;
139
- email: string;
140
- password: string;
141
- name?: string | undefined;
142
- avatar?: File | undefined;
143
- }, {
144
- collectionName: string;
145
- id: string;
146
- collectionId: string;
147
- expand: Record<string, any>;
148
- created: string;
149
- updated: string;
150
- email: string;
151
- password: string;
152
- name?: string | undefined;
153
- avatar?: File | undefined;
154
- }>;
155
- declare const UserCollection: z.ZodObject<any, z.UnknownKeysParam, z.ZodTypeAny, {
156
- [x: string]: any;
157
- }, {
158
- [x: string]: any;
159
- }>;
160
-
161
- export { ProjectCollection as P, UserCollection as U, ProjectInputSchema as a, ProjectSchema as b, UserInputSchema as c, UserCollectionSchema as d, UserSchema as e };