@adrekic/zod-fieldsjson 0.0.1 → 0.0.2-schema-improvements.1
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/conditions/base.d.ts +3 -3
- package/dist/conditions/boolean.d.ts +3 -3
- package/dist/conditions/checkbox-list.d.ts +3 -3
- package/dist/conditions/date.d.ts +3 -3
- package/dist/conditions/index.d.ts +51 -51
- package/dist/conditions/multi-select.d.ts +3 -3
- package/dist/conditions/multi-string.d.ts +3 -3
- package/dist/conditions/number.d.ts +3 -3
- package/dist/conditions/otp.d.ts +3 -3
- package/dist/conditions/pass-fail.d.ts +3 -3
- package/dist/conditions/radio.d.ts +3 -3
- package/dist/conditions/rating.d.ts +3 -3
- package/dist/conditions/scan.d.ts +3 -3
- package/dist/conditions/select.d.ts +3 -3
- package/dist/conditions/string.d.ts +3 -3
- package/dist/conditions/text.d.ts +3 -3
- package/dist/conditions/time.d.ts +3 -3
- package/dist/conditions/upload.d.ts +3 -3
- package/dist/conditions/url.d.ts +3 -3
- package/dist/elements/base.d.ts +1 -1
- package/dist/elements/index.d.ts +212 -214
- package/dist/elements/section.d.ts +185 -186
- package/dist/fields/base.d.ts +14 -14
- package/dist/fields/boolean.d.ts +4 -4
- package/dist/fields/checkbox-list.d.ts +4 -4
- package/dist/fields/date.d.ts +4 -4
- package/dist/fields/index.d.ts +78 -79
- package/dist/fields/multi-select.d.ts +4 -4
- package/dist/fields/multi-string.d.ts +6 -6
- package/dist/fields/number.d.ts +4 -4
- package/dist/fields/otp.d.ts +5 -8
- package/dist/fields/pass-fail.d.ts +4 -4
- package/dist/fields/radio.d.ts +4 -4
- package/dist/fields/rating.d.ts +5 -5
- package/dist/fields/scan.d.ts +4 -4
- package/dist/fields/select.d.ts +4 -4
- package/dist/fields/string.d.ts +6 -6
- package/dist/fields/text.d.ts +6 -6
- package/dist/fields/time.d.ts +4 -4
- package/dist/fields/upload.d.ts +6 -6
- package/dist/fields/url.d.ts +4 -4
- package/dist/index.cjs +1 -1
- package/dist/index.js +60 -69
- package/dist/schema.d.ts +134 -135
- package/package.json +3 -3
package/dist/schema.d.ts
CHANGED
|
@@ -1,155 +1,155 @@
|
|
|
1
1
|
import * as z from "zod/v4";
|
|
2
2
|
export declare const JSONFieldSchemaSchema: z.ZodArray<z.ZodObject<{
|
|
3
|
-
label: z.
|
|
4
|
-
description: z.ZodOptional<z.
|
|
5
|
-
conditions: z.ZodRecord<z.ZodString, z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
3
|
+
label: z.ZodOptional<z.ZodString>;
|
|
4
|
+
description: z.ZodOptional<z.ZodString>;
|
|
5
|
+
conditions: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
6
6
|
id: z.ZodString;
|
|
7
7
|
type: z.ZodLiteral<"boolean">;
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
8
|
+
field: z.ZodString;
|
|
9
|
+
value: z.ZodType<boolean, unknown, z.core.$ZodTypeInternals<boolean, unknown>>;
|
|
10
|
+
modifier: z.ZodLiteral<"equals" | "notEquals">;
|
|
11
11
|
}, z.core.$strip>, z.ZodObject<{
|
|
12
12
|
id: z.ZodString;
|
|
13
13
|
type: z.ZodLiteral<"checkbox-list">;
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
14
|
+
field: z.ZodString;
|
|
15
|
+
value: z.ZodType<string[], unknown, z.core.$ZodTypeInternals<string[], unknown>>;
|
|
16
|
+
modifier: z.ZodLiteral<"equals" | "notEquals" | "every" | "some" | "none">;
|
|
17
17
|
}, z.core.$strip>, z.ZodObject<{
|
|
18
18
|
id: z.ZodString;
|
|
19
19
|
type: z.ZodLiteral<"date">;
|
|
20
|
-
|
|
21
|
-
|
|
20
|
+
field: z.ZodString;
|
|
21
|
+
value: z.ZodType<string | {
|
|
22
22
|
from: string | null;
|
|
23
23
|
to: string | null;
|
|
24
24
|
}, unknown, z.core.$ZodTypeInternals<string | {
|
|
25
25
|
from: string | null;
|
|
26
26
|
to: string | null;
|
|
27
27
|
}, unknown>>;
|
|
28
|
-
|
|
28
|
+
modifier: z.ZodLiteral<"equals" | "notEquals" | "in" | "before" | "after" | "notIn">;
|
|
29
29
|
}, z.core.$strip>, z.ZodObject<{
|
|
30
30
|
id: z.ZodString;
|
|
31
31
|
type: z.ZodLiteral<"multi-select">;
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
32
|
+
field: z.ZodString;
|
|
33
|
+
value: z.ZodType<string[], unknown, z.core.$ZodTypeInternals<string[], unknown>>;
|
|
34
|
+
modifier: z.ZodLiteral<"equals" | "notEquals" | "every" | "some" | "none">;
|
|
35
35
|
}, z.core.$strip>, z.ZodObject<{
|
|
36
36
|
id: z.ZodString;
|
|
37
37
|
type: z.ZodLiteral<"multi-string">;
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
38
|
+
field: z.ZodString;
|
|
39
|
+
value: z.ZodType<string[], unknown, z.core.$ZodTypeInternals<string[], unknown>>;
|
|
40
|
+
modifier: z.ZodLiteral<"equals" | "notEquals" | "every" | "some" | "none">;
|
|
41
41
|
}, z.core.$strip>, z.ZodObject<{
|
|
42
42
|
id: z.ZodString;
|
|
43
43
|
type: z.ZodLiteral<"number">;
|
|
44
|
-
|
|
45
|
-
|
|
44
|
+
field: z.ZodString;
|
|
45
|
+
value: z.ZodType<number | {
|
|
46
46
|
from: number | null;
|
|
47
47
|
to: number | null;
|
|
48
48
|
}, unknown, z.core.$ZodTypeInternals<number | {
|
|
49
49
|
from: number | null;
|
|
50
50
|
to: number | null;
|
|
51
51
|
}, unknown>>;
|
|
52
|
-
|
|
52
|
+
modifier: z.ZodLiteral<"equals" | "notEquals" | "lessThan" | "lessThanOrEquals" | "greaterThan" | "greaterThanOrEquals" | "inRange" | "notInRange">;
|
|
53
53
|
}, z.core.$strip>, z.ZodObject<{
|
|
54
54
|
id: z.ZodString;
|
|
55
55
|
type: z.ZodLiteral<"otp">;
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
56
|
+
field: z.ZodString;
|
|
57
|
+
value: z.ZodType<string, unknown, z.core.$ZodTypeInternals<string, unknown>>;
|
|
58
|
+
modifier: z.ZodLiteral<"equals" | "notEquals" | "includes" | "excludes">;
|
|
59
59
|
}, z.core.$strip>, z.ZodObject<{
|
|
60
60
|
id: z.ZodString;
|
|
61
61
|
type: z.ZodLiteral<"pass-fail">;
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
62
|
+
field: z.ZodString;
|
|
63
|
+
value: z.ZodType<"pass" | "fail" | "na" | ("pass" | "fail" | "na")[], unknown, z.core.$ZodTypeInternals<"pass" | "fail" | "na" | ("pass" | "fail" | "na")[], unknown>>;
|
|
64
|
+
modifier: z.ZodLiteral<"equals" | "notEquals" | "includes" | "excludes">;
|
|
65
65
|
}, z.core.$strip>, z.ZodObject<{
|
|
66
66
|
id: z.ZodString;
|
|
67
67
|
type: z.ZodLiteral<"radio">;
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
68
|
+
field: z.ZodString;
|
|
69
|
+
value: z.ZodType<string | string[], unknown, z.core.$ZodTypeInternals<string | string[], unknown>>;
|
|
70
|
+
modifier: z.ZodLiteral<"equals" | "notEquals" | "includes" | "excludes">;
|
|
71
71
|
}, z.core.$strip>, z.ZodObject<{
|
|
72
72
|
id: z.ZodString;
|
|
73
73
|
type: z.ZodLiteral<"rating">;
|
|
74
|
-
|
|
75
|
-
|
|
74
|
+
field: z.ZodString;
|
|
75
|
+
value: z.ZodType<number | {
|
|
76
76
|
from: number | null;
|
|
77
77
|
to: number | null;
|
|
78
78
|
}, unknown, z.core.$ZodTypeInternals<number | {
|
|
79
79
|
from: number | null;
|
|
80
80
|
to: number | null;
|
|
81
81
|
}, unknown>>;
|
|
82
|
-
|
|
82
|
+
modifier: z.ZodLiteral<"equals" | "notEquals" | "lessThan" | "lessThanOrEquals" | "greaterThan" | "greaterThanOrEquals" | "inRange" | "notInRange">;
|
|
83
83
|
}, z.core.$strip>, z.ZodObject<{
|
|
84
84
|
id: z.ZodString;
|
|
85
85
|
type: z.ZodLiteral<"qr">;
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
86
|
+
field: z.ZodString;
|
|
87
|
+
value: z.ZodType<string, unknown, z.core.$ZodTypeInternals<string, unknown>>;
|
|
88
|
+
modifier: z.ZodLiteral<"equals" | "notEquals" | "includes" | "excludes">;
|
|
89
89
|
}, z.core.$strip>, z.ZodObject<{
|
|
90
90
|
id: z.ZodString;
|
|
91
91
|
type: z.ZodLiteral<"select">;
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
92
|
+
field: z.ZodString;
|
|
93
|
+
value: z.ZodType<string | string[], unknown, z.core.$ZodTypeInternals<string | string[], unknown>>;
|
|
94
|
+
modifier: z.ZodLiteral<"equals" | "notEquals" | "includes" | "excludes">;
|
|
95
95
|
}, z.core.$strip>, z.ZodObject<{
|
|
96
96
|
id: z.ZodString;
|
|
97
97
|
type: z.ZodLiteral<"string">;
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
98
|
+
field: z.ZodString;
|
|
99
|
+
value: z.ZodType<string, unknown, z.core.$ZodTypeInternals<string, unknown>>;
|
|
100
|
+
modifier: z.ZodLiteral<"equals" | "notEquals" | "includes" | "excludes">;
|
|
101
101
|
}, z.core.$strip>, z.ZodObject<{
|
|
102
102
|
id: z.ZodString;
|
|
103
103
|
type: z.ZodLiteral<"text">;
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
104
|
+
field: z.ZodString;
|
|
105
|
+
value: z.ZodType<string, unknown, z.core.$ZodTypeInternals<string, unknown>>;
|
|
106
|
+
modifier: z.ZodLiteral<"equals" | "notEquals" | "includes" | "excludes">;
|
|
107
107
|
}, z.core.$strip>, z.ZodObject<{
|
|
108
108
|
id: z.ZodString;
|
|
109
109
|
type: z.ZodLiteral<"time">;
|
|
110
|
-
|
|
111
|
-
|
|
110
|
+
field: z.ZodString;
|
|
111
|
+
value: z.ZodType<`T${string}:${string}:00+${string}:${string}` | `T${string}:${string}:00-${string}:${string}` | {
|
|
112
112
|
from: `T${string}:${string}:00+${string}:${string}` | `T${string}:${string}:00-${string}:${string}` | null;
|
|
113
113
|
to: `T${string}:${string}:00+${string}:${string}` | `T${string}:${string}:00-${string}:${string}` | null;
|
|
114
114
|
}, unknown, z.core.$ZodTypeInternals<`T${string}:${string}:00+${string}:${string}` | `T${string}:${string}:00-${string}:${string}` | {
|
|
115
115
|
from: `T${string}:${string}:00+${string}:${string}` | `T${string}:${string}:00-${string}:${string}` | null;
|
|
116
116
|
to: `T${string}:${string}:00+${string}:${string}` | `T${string}:${string}:00-${string}:${string}` | null;
|
|
117
117
|
}, unknown>>;
|
|
118
|
-
|
|
118
|
+
modifier: z.ZodLiteral<"equals" | "notEquals" | "in" | "before" | "after" | "notIn">;
|
|
119
119
|
}, z.core.$strip>, z.ZodObject<{
|
|
120
120
|
id: z.ZodString;
|
|
121
121
|
type: z.ZodLiteral<"upload">;
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
122
|
+
field: z.ZodString;
|
|
123
|
+
value: z.ZodType<boolean, unknown, z.core.$ZodTypeInternals<boolean, unknown>>;
|
|
124
|
+
modifier: z.ZodLiteral<"equals" | "notEquals">;
|
|
125
125
|
}, z.core.$strip>, z.ZodObject<{
|
|
126
126
|
id: z.ZodString;
|
|
127
127
|
type: z.ZodLiteral<"url">;
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
}, z.core.$strip>], "type"
|
|
128
|
+
field: z.ZodString;
|
|
129
|
+
value: z.ZodType<string, unknown, z.core.$ZodTypeInternals<string, unknown>>;
|
|
130
|
+
modifier: z.ZodLiteral<"equals" | "notEquals" | "includes" | "excludes">;
|
|
131
|
+
}, z.core.$strip>], "type">>>>;
|
|
132
132
|
fields: z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
133
|
-
label: z.ZodString
|
|
134
|
-
description: z.ZodOptional<z.
|
|
135
|
-
required: z.ZodBoolean
|
|
136
|
-
|
|
133
|
+
label: z.ZodOptional<z.ZodString>;
|
|
134
|
+
description: z.ZodOptional<z.ZodString>;
|
|
135
|
+
required: z.ZodOptional<z.ZodBoolean>;
|
|
136
|
+
id: z.ZodString;
|
|
137
137
|
type: z.ZodLiteral<"boolean">;
|
|
138
138
|
}, z.core.$strip>, z.ZodObject<{
|
|
139
139
|
options: z.ZodArray<z.ZodObject<{
|
|
140
140
|
value: z.ZodString;
|
|
141
141
|
label: z.ZodString;
|
|
142
142
|
}, z.core.$strip>>;
|
|
143
|
-
label: z.ZodString
|
|
144
|
-
description: z.ZodOptional<z.
|
|
145
|
-
required: z.ZodBoolean
|
|
146
|
-
|
|
143
|
+
label: z.ZodOptional<z.ZodString>;
|
|
144
|
+
description: z.ZodOptional<z.ZodString>;
|
|
145
|
+
required: z.ZodOptional<z.ZodBoolean>;
|
|
146
|
+
id: z.ZodString;
|
|
147
147
|
type: z.ZodLiteral<"checkbox-list">;
|
|
148
148
|
}, z.core.$strip>, z.ZodObject<{
|
|
149
|
-
label: z.ZodString
|
|
150
|
-
description: z.ZodOptional<z.
|
|
151
|
-
required: z.ZodBoolean
|
|
152
|
-
|
|
149
|
+
label: z.ZodOptional<z.ZodString>;
|
|
150
|
+
description: z.ZodOptional<z.ZodString>;
|
|
151
|
+
required: z.ZodOptional<z.ZodBoolean>;
|
|
152
|
+
id: z.ZodString;
|
|
153
153
|
type: z.ZodLiteral<"date">;
|
|
154
154
|
}, z.core.$strip>, z.ZodObject<{
|
|
155
155
|
placeholder: z.ZodOptional<z.ZodString>;
|
|
@@ -157,67 +157,66 @@ export declare const JSONFieldSchemaSchema: z.ZodArray<z.ZodObject<{
|
|
|
157
157
|
value: z.ZodString;
|
|
158
158
|
label: z.ZodString;
|
|
159
159
|
}, z.core.$strip>>;
|
|
160
|
-
label: z.ZodString
|
|
161
|
-
description: z.ZodOptional<z.
|
|
162
|
-
required: z.ZodBoolean
|
|
163
|
-
|
|
160
|
+
label: z.ZodOptional<z.ZodString>;
|
|
161
|
+
description: z.ZodOptional<z.ZodString>;
|
|
162
|
+
required: z.ZodOptional<z.ZodBoolean>;
|
|
163
|
+
id: z.ZodString;
|
|
164
164
|
type: z.ZodLiteral<"multi-select">;
|
|
165
165
|
}, z.core.$strip>, z.ZodObject<{
|
|
166
|
-
|
|
167
|
-
|
|
166
|
+
minLength: z.ZodOptional<z.ZodInt>;
|
|
167
|
+
maxLength: z.ZodOptional<z.ZodInt>;
|
|
168
168
|
placeholder: z.ZodOptional<z.ZodString>;
|
|
169
|
-
label: z.ZodString
|
|
170
|
-
description: z.ZodOptional<z.
|
|
171
|
-
required: z.ZodBoolean
|
|
172
|
-
|
|
169
|
+
label: z.ZodOptional<z.ZodString>;
|
|
170
|
+
description: z.ZodOptional<z.ZodString>;
|
|
171
|
+
required: z.ZodOptional<z.ZodBoolean>;
|
|
172
|
+
id: z.ZodString;
|
|
173
173
|
type: z.ZodLiteral<"multi-string">;
|
|
174
174
|
}, z.core.$strip>, z.ZodObject<{
|
|
175
175
|
minimum: z.ZodOptional<z.ZodNumber>;
|
|
176
176
|
maximum: z.ZodOptional<z.ZodNumber>;
|
|
177
177
|
integers: z.ZodOptional<z.ZodBoolean>;
|
|
178
178
|
placeholder: z.ZodOptional<z.ZodString>;
|
|
179
|
-
label: z.ZodString
|
|
180
|
-
description: z.ZodOptional<z.
|
|
181
|
-
required: z.ZodBoolean
|
|
182
|
-
|
|
179
|
+
label: z.ZodOptional<z.ZodString>;
|
|
180
|
+
description: z.ZodOptional<z.ZodString>;
|
|
181
|
+
required: z.ZodOptional<z.ZodBoolean>;
|
|
182
|
+
id: z.ZodString;
|
|
183
183
|
type: z.ZodLiteral<"number">;
|
|
184
184
|
}, z.core.$strip>, z.ZodObject<{
|
|
185
|
-
length: z.
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
identifier: z.ZodString;
|
|
185
|
+
length: z.ZodInt;
|
|
186
|
+
label: z.ZodOptional<z.ZodString>;
|
|
187
|
+
description: z.ZodOptional<z.ZodString>;
|
|
188
|
+
required: z.ZodOptional<z.ZodBoolean>;
|
|
189
|
+
id: z.ZodString;
|
|
191
190
|
type: z.ZodLiteral<"otp">;
|
|
192
191
|
}, z.core.$strip>, z.ZodObject<{
|
|
193
192
|
showNotesAndFilesOn: z.ZodArray<z.ZodLiteral<"pass" | "fail" | "na">>;
|
|
194
|
-
label: z.ZodString
|
|
195
|
-
description: z.ZodOptional<z.
|
|
196
|
-
required: z.ZodBoolean
|
|
197
|
-
|
|
193
|
+
label: z.ZodOptional<z.ZodString>;
|
|
194
|
+
description: z.ZodOptional<z.ZodString>;
|
|
195
|
+
required: z.ZodOptional<z.ZodBoolean>;
|
|
196
|
+
id: z.ZodString;
|
|
198
197
|
type: z.ZodLiteral<"pass-fail">;
|
|
199
198
|
}, z.core.$strip>, z.ZodObject<{
|
|
200
199
|
options: z.ZodArray<z.ZodObject<{
|
|
201
200
|
value: z.ZodString;
|
|
202
201
|
label: z.ZodString;
|
|
203
202
|
}, z.core.$strip>>;
|
|
204
|
-
label: z.ZodString
|
|
205
|
-
description: z.ZodOptional<z.
|
|
206
|
-
required: z.ZodBoolean
|
|
207
|
-
|
|
203
|
+
label: z.ZodOptional<z.ZodString>;
|
|
204
|
+
description: z.ZodOptional<z.ZodString>;
|
|
205
|
+
required: z.ZodOptional<z.ZodBoolean>;
|
|
206
|
+
id: z.ZodString;
|
|
208
207
|
type: z.ZodLiteral<"radio">;
|
|
209
208
|
}, z.core.$strip>, z.ZodObject<{
|
|
210
|
-
maxRating: z.
|
|
211
|
-
label: z.ZodString
|
|
212
|
-
description: z.ZodOptional<z.
|
|
213
|
-
required: z.ZodBoolean
|
|
214
|
-
|
|
209
|
+
maxRating: z.ZodInt;
|
|
210
|
+
label: z.ZodOptional<z.ZodString>;
|
|
211
|
+
description: z.ZodOptional<z.ZodString>;
|
|
212
|
+
required: z.ZodOptional<z.ZodBoolean>;
|
|
213
|
+
id: z.ZodString;
|
|
215
214
|
type: z.ZodLiteral<"rating">;
|
|
216
215
|
}, z.core.$strip>, z.ZodObject<{
|
|
217
|
-
label: z.ZodString
|
|
218
|
-
description: z.ZodOptional<z.
|
|
219
|
-
required: z.ZodBoolean
|
|
220
|
-
|
|
216
|
+
label: z.ZodOptional<z.ZodString>;
|
|
217
|
+
description: z.ZodOptional<z.ZodString>;
|
|
218
|
+
required: z.ZodOptional<z.ZodBoolean>;
|
|
219
|
+
id: z.ZodString;
|
|
221
220
|
type: z.ZodLiteral<"qr">;
|
|
222
221
|
}, z.core.$strip>, z.ZodObject<{
|
|
223
222
|
placeholder: z.ZodOptional<z.ZodString>;
|
|
@@ -225,53 +224,53 @@ export declare const JSONFieldSchemaSchema: z.ZodArray<z.ZodObject<{
|
|
|
225
224
|
value: z.ZodString;
|
|
226
225
|
label: z.ZodString;
|
|
227
226
|
}, z.core.$strip>>;
|
|
228
|
-
label: z.ZodString
|
|
229
|
-
description: z.ZodOptional<z.
|
|
230
|
-
required: z.ZodBoolean
|
|
231
|
-
|
|
227
|
+
label: z.ZodOptional<z.ZodString>;
|
|
228
|
+
description: z.ZodOptional<z.ZodString>;
|
|
229
|
+
required: z.ZodOptional<z.ZodBoolean>;
|
|
230
|
+
id: z.ZodString;
|
|
232
231
|
type: z.ZodLiteral<"select">;
|
|
233
232
|
}, z.core.$strip>, z.ZodObject<{
|
|
234
|
-
|
|
235
|
-
|
|
233
|
+
minLength: z.ZodOptional<z.ZodInt>;
|
|
234
|
+
maxLength: z.ZodOptional<z.ZodInt>;
|
|
236
235
|
placeholder: z.ZodOptional<z.ZodString>;
|
|
237
|
-
label: z.ZodString
|
|
238
|
-
description: z.ZodOptional<z.
|
|
239
|
-
required: z.ZodBoolean
|
|
240
|
-
|
|
236
|
+
label: z.ZodOptional<z.ZodString>;
|
|
237
|
+
description: z.ZodOptional<z.ZodString>;
|
|
238
|
+
required: z.ZodOptional<z.ZodBoolean>;
|
|
239
|
+
id: z.ZodString;
|
|
241
240
|
type: z.ZodLiteral<"string">;
|
|
242
241
|
}, z.core.$strip>, z.ZodObject<{
|
|
243
|
-
|
|
244
|
-
|
|
242
|
+
minLength: z.ZodOptional<z.ZodInt>;
|
|
243
|
+
maxLength: z.ZodOptional<z.ZodInt>;
|
|
245
244
|
placeholder: z.ZodOptional<z.ZodString>;
|
|
246
|
-
label: z.ZodString
|
|
247
|
-
description: z.ZodOptional<z.
|
|
248
|
-
required: z.ZodBoolean
|
|
249
|
-
|
|
245
|
+
label: z.ZodOptional<z.ZodString>;
|
|
246
|
+
description: z.ZodOptional<z.ZodString>;
|
|
247
|
+
required: z.ZodOptional<z.ZodBoolean>;
|
|
248
|
+
id: z.ZodString;
|
|
250
249
|
type: z.ZodLiteral<"text">;
|
|
251
250
|
}, z.core.$strip>, z.ZodObject<{
|
|
252
|
-
label: z.ZodString
|
|
253
|
-
description: z.ZodOptional<z.
|
|
254
|
-
required: z.ZodBoolean
|
|
255
|
-
|
|
251
|
+
label: z.ZodOptional<z.ZodString>;
|
|
252
|
+
description: z.ZodOptional<z.ZodString>;
|
|
253
|
+
required: z.ZodOptional<z.ZodBoolean>;
|
|
254
|
+
id: z.ZodString;
|
|
256
255
|
type: z.ZodLiteral<"time">;
|
|
257
256
|
}, z.core.$strip>, z.ZodObject<{
|
|
258
257
|
extensions: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
label: z.ZodString
|
|
262
|
-
description: z.ZodOptional<z.
|
|
263
|
-
required: z.ZodBoolean
|
|
264
|
-
|
|
258
|
+
maxSize: z.ZodOptional<z.ZodInt>;
|
|
259
|
+
maxFiles: z.ZodOptional<z.ZodInt>;
|
|
260
|
+
label: z.ZodOptional<z.ZodString>;
|
|
261
|
+
description: z.ZodOptional<z.ZodString>;
|
|
262
|
+
required: z.ZodOptional<z.ZodBoolean>;
|
|
263
|
+
id: z.ZodString;
|
|
265
264
|
type: z.ZodLiteral<"upload">;
|
|
266
265
|
}, z.core.$strip>, z.ZodObject<{
|
|
267
266
|
placeholder: z.ZodOptional<z.ZodString>;
|
|
268
|
-
label: z.ZodString
|
|
269
|
-
description: z.ZodOptional<z.
|
|
270
|
-
required: z.ZodBoolean
|
|
271
|
-
|
|
267
|
+
label: z.ZodOptional<z.ZodString>;
|
|
268
|
+
description: z.ZodOptional<z.ZodString>;
|
|
269
|
+
required: z.ZodOptional<z.ZodBoolean>;
|
|
270
|
+
id: z.ZodString;
|
|
272
271
|
type: z.ZodLiteral<"url">;
|
|
273
272
|
}, z.core.$strip>], "type">>;
|
|
274
|
-
|
|
273
|
+
id: z.ZodString;
|
|
275
274
|
type: z.ZodLiteral<"section">;
|
|
276
275
|
}, z.core.$strip>>;
|
|
277
276
|
export type JSONFieldSchemaSchemaType = z.infer<typeof JSONFieldSchemaSchema>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@adrekic/zod-fieldsjson",
|
|
3
|
-
"version": "0.0.1",
|
|
3
|
+
"version": "0.0.2-schema-improvements.1",
|
|
4
4
|
"license": "UNLICENSED",
|
|
5
5
|
"files": [
|
|
6
6
|
"dist"
|
|
@@ -29,10 +29,10 @@
|
|
|
29
29
|
"format": "oxfmt",
|
|
30
30
|
"format:check": "yarn format --check",
|
|
31
31
|
"test": "vitest --typecheck --config ./vitest.config.ts",
|
|
32
|
-
"generate-
|
|
32
|
+
"generate-schemas": "npx tsx scripts/generate-schemas.ts"
|
|
33
33
|
},
|
|
34
34
|
"devDependencies": {
|
|
35
|
-
"@adrekic/fieldsjson": "
|
|
35
|
+
"@adrekic/fieldsjson": "0.0.2-schema-improvements.2",
|
|
36
36
|
"@types/node": "24.1.0",
|
|
37
37
|
"oxfmt": "0.61.0",
|
|
38
38
|
"oxlint": "1.76.0",
|