codify-schemas 1.0.20 → 1.0.22

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 CHANGED
@@ -1,229 +1,199 @@
1
- declare const ConfigFileSchema: {
2
- default: {
3
- $schema: string;
4
- $id: string;
5
- title: string;
6
- type: string;
7
- items: {
8
- $ref: string;
9
- };
10
- };
11
- };
1
+ import ConfigFileSchema from './config-file-schema.json';
12
2
  declare const ProjectSchema: {
13
- default: {
14
- $schema: string;
15
- $id: string;
16
- title: string;
17
- type: string;
18
- properties: {
19
- type: {
20
- description: string;
21
- type: string;
22
- const: string;
23
- };
24
- version: {
25
- description: string;
26
- type: string;
27
- pattern: string;
28
- };
29
- plugins: {
30
- type: string;
31
- patternProperties: {
32
- ".*": {
33
- type: string;
34
- };
3
+ $schema: string;
4
+ $id: string;
5
+ title: string;
6
+ type: string;
7
+ properties: {
8
+ type: {
9
+ description: string;
10
+ type: string;
11
+ const: string;
12
+ };
13
+ version: {
14
+ description: string;
15
+ type: string;
16
+ pattern: string;
17
+ };
18
+ plugins: {
19
+ type: string;
20
+ patternProperties: {
21
+ ".*": {
22
+ type: string;
35
23
  };
36
24
  };
37
- description: {
38
- description: string;
39
- type: string;
40
- };
41
25
  };
42
- additionalProperties: boolean;
43
- required: string[];
26
+ description: {
27
+ description: string;
28
+ type: string;
29
+ };
44
30
  };
31
+ additionalProperties: boolean;
32
+ required: string[];
45
33
  };
46
34
  declare const ResourceSchema: {
47
- default: {
48
- $schema: string;
49
- $id: string;
50
- title: string;
51
- type: string;
52
- properties: {
53
- type: {
54
- description: string;
55
- type: string;
56
- pattern: string;
57
- };
58
- name: {
59
- description: string;
60
- type: string;
61
- pattern: string;
62
- };
63
- dependsOn: {
35
+ $schema: string;
36
+ $id: string;
37
+ title: string;
38
+ type: string;
39
+ properties: {
40
+ type: {
41
+ description: string;
42
+ type: string;
43
+ pattern: string;
44
+ };
45
+ name: {
46
+ description: string;
47
+ type: string;
48
+ pattern: string;
49
+ };
50
+ dependsOn: {
51
+ type: string;
52
+ items: {
64
53
  type: string;
65
- items: {
66
- type: string;
67
- };
68
- uniqueItems: boolean;
69
54
  };
55
+ uniqueItems: boolean;
70
56
  };
71
- required: string[];
72
57
  };
58
+ required: string[];
73
59
  };
74
60
  declare const IpcMessageSchema: {
75
- default: {
76
- $schema: string;
77
- $id: string;
78
- title: string;
79
- type: string;
80
- properties: {
81
- cmd: {
82
- description: string;
83
- type: string;
84
- };
85
- status: {
86
- description: string;
87
- type: string;
88
- enum: string[];
89
- };
90
- data: {
91
- description: string;
92
- };
61
+ $schema: string;
62
+ $id: string;
63
+ title: string;
64
+ type: string;
65
+ properties: {
66
+ cmd: {
67
+ description: string;
68
+ type: string;
69
+ };
70
+ status: {
71
+ description: string;
72
+ type: string;
73
+ enum: string[];
74
+ };
75
+ data: {
76
+ description: string;
93
77
  };
94
- required: string[];
95
78
  };
79
+ required: string[];
96
80
  };
97
81
  declare const ApplyRequestDataSchema: {
98
- default: {
99
- $schema: string;
100
- $id: string;
101
- title: string;
102
- description: string;
103
- type: string;
104
- properties: {
105
- planId: {
106
- description: string;
107
- type: string;
108
- format: string;
109
- };
82
+ $schema: string;
83
+ $id: string;
84
+ title: string;
85
+ description: string;
86
+ type: string;
87
+ properties: {
88
+ planId: {
89
+ description: string;
90
+ type: string;
91
+ format: string;
110
92
  };
111
- required: string[];
112
- additionalProperties: boolean;
113
93
  };
94
+ required: string[];
95
+ additionalProperties: boolean;
114
96
  };
115
97
  declare const ApplyResponseDataSchema: {
116
- default: {
117
- $schema: string;
118
- $id: string;
119
- title: string;
120
- type: string;
121
- };
98
+ $schema: string;
99
+ $id: string;
100
+ title: string;
101
+ type: string;
122
102
  };
123
103
  declare const ErrorResponseDataSchema: {
124
- default: {
125
- $schema: string;
126
- $id: string;
127
- title: string;
128
- type: string;
129
- properties: {
130
- reason: {
131
- description: string;
132
- type: string;
133
- };
104
+ $schema: string;
105
+ $id: string;
106
+ title: string;
107
+ type: string;
108
+ properties: {
109
+ reason: {
110
+ description: string;
111
+ type: string;
134
112
  };
135
- required: string[];
136
- additionalProperties: boolean;
137
113
  };
114
+ required: string[];
115
+ additionalProperties: boolean;
138
116
  };
139
117
  declare const PlanRequestDataSchema: {
140
- default: {
141
- $schema: string;
142
- $id: string;
143
- title: string;
144
- $ref: string;
145
- };
118
+ $schema: string;
119
+ $id: string;
120
+ title: string;
121
+ $ref: string;
146
122
  };
147
123
  declare const PlanResponseDataSchema: {
148
- default: {
149
- $schema: string;
150
- $id: string;
151
- title: string;
152
- type: string;
153
- properties: {
154
- planId: {
155
- description: string;
156
- type: string;
157
- format: string;
158
- };
159
- operation: {
160
- description: string;
161
- type: string;
162
- enum: string[];
163
- };
164
- resourceType: {
165
- description: string;
166
- type: string;
167
- };
168
- resourceName: {
169
- description: string;
170
- type: string[];
171
- };
172
- parameters: {
173
- description: string;
174
- type: string;
175
- items: {
176
- type: string;
177
- properties: {
178
- name: {
179
- description: string;
180
- type: string;
181
- };
182
- operation: {
183
- description: string;
184
- type: string;
185
- enum: string[];
186
- };
187
- previousValue: {
188
- description: string;
189
- };
190
- newValue: {
191
- description: string;
192
- };
124
+ $schema: string;
125
+ $id: string;
126
+ title: string;
127
+ type: string;
128
+ properties: {
129
+ planId: {
130
+ description: string;
131
+ type: string;
132
+ format: string;
133
+ };
134
+ operation: {
135
+ description: string;
136
+ type: string;
137
+ enum: string[];
138
+ };
139
+ resourceType: {
140
+ description: string;
141
+ type: string;
142
+ };
143
+ resourceName: {
144
+ description: string;
145
+ type: string[];
146
+ };
147
+ parameters: {
148
+ description: string;
149
+ type: string;
150
+ items: {
151
+ type: string;
152
+ properties: {
153
+ name: {
154
+ description: string;
155
+ type: string;
156
+ };
157
+ operation: {
158
+ description: string;
159
+ type: string;
160
+ enum: string[];
161
+ };
162
+ previousValue: {
163
+ description: string;
164
+ };
165
+ newValue: {
166
+ description: string;
193
167
  };
194
- required: string[];
195
168
  };
169
+ required: string[];
196
170
  };
197
171
  };
198
- required: string[];
199
- additionalProperties: boolean;
200
172
  };
173
+ required: string[];
174
+ additionalProperties: boolean;
201
175
  };
202
176
  declare const ValidateRequestDataSchema: {
203
- default: {
204
- $schema: string;
205
- $id: string;
206
- title: string;
207
- type: string;
208
- properties: {
209
- configs: {
210
- type: string;
211
- items: {
212
- $ref: string;
213
- };
177
+ $schema: string;
178
+ $id: string;
179
+ title: string;
180
+ type: string;
181
+ properties: {
182
+ configs: {
183
+ type: string;
184
+ items: {
185
+ $ref: string;
214
186
  };
215
187
  };
216
- required: never[];
217
- additionalProperties: boolean;
218
188
  };
189
+ required: never[];
190
+ additionalProperties: boolean;
219
191
  };
220
192
  declare const ValidateResponseDataSchema: {
221
- default: {
222
- $schema: string;
223
- $id: string;
224
- title: string;
225
- type: string;
226
- };
193
+ $schema: string;
194
+ $id: string;
195
+ title: string;
196
+ type: string;
227
197
  };
228
198
  export { ConfigFileSchema, ProjectSchema, ResourceSchema, IpcMessageSchema, ApplyRequestDataSchema, ApplyResponseDataSchema, ErrorResponseDataSchema, PlanRequestDataSchema, PlanResponseDataSchema, ValidateRequestDataSchema, ValidateResponseDataSchema, };
229
199
  export * from './types/index.js';
package/dist/index.js CHANGED
@@ -1,36 +1,34 @@
1
- const ConfigFileSchema = await import('./config-file-schema.json', {
1
+ import ConfigFileSchema from './config-file-schema.json' assert { type: 'json' };
2
+ const ProjectSchema = (await import('./project-schema.json', {
2
3
  assert: { type: 'json' }
3
- });
4
- const ProjectSchema = await import('./project-schema.json', {
4
+ })).default;
5
+ const ResourceSchema = (await import('./resource-schema.json', {
5
6
  assert: { type: 'json' }
6
- });
7
- const ResourceSchema = await import('./resource-schema.json', {
7
+ })).default;
8
+ const IpcMessageSchema = (await import('./ipc-message-schema.json', {
8
9
  assert: { type: 'json' }
9
- });
10
- const IpcMessageSchema = await import('./ipc-message-schema.json', {
10
+ })).default;
11
+ const ApplyRequestDataSchema = (await import('./messages/apply-request-data-schema.json', {
11
12
  assert: { type: 'json' }
12
- });
13
- const ApplyRequestDataSchema = await import('./messages/apply-request-data-schema.json', {
13
+ })).default;
14
+ const ApplyResponseDataSchema = (await import('./messages/apply-response-data-schema.json', {
14
15
  assert: { type: 'json' }
15
- });
16
- const ApplyResponseDataSchema = await import('./messages/apply-response-data-schema.json', {
16
+ })).default;
17
+ const ErrorResponseDataSchema = (await import('./messages/error-response-data-schema.json', {
17
18
  assert: { type: 'json' }
18
- });
19
- const ErrorResponseDataSchema = await import('./messages/error-response-data-schema.json', {
19
+ })).default;
20
+ const PlanRequestDataSchema = (await import('./messages/plan-request-data-schema.json', {
20
21
  assert: { type: 'json' }
21
- });
22
- const PlanRequestDataSchema = await import('./messages/plan-request-data-schema.json', {
22
+ })).default;
23
+ const PlanResponseDataSchema = (await import('./messages/plan-response-data-schema.json', {
23
24
  assert: { type: 'json' }
24
- });
25
- const PlanResponseDataSchema = await import('./messages/plan-response-data-schema.json', {
25
+ })).default;
26
+ const ValidateRequestDataSchema = (await import('./messages/validate-request-data-schema.json', {
26
27
  assert: { type: 'json' }
27
- });
28
- const ValidateRequestDataSchema = await import('./messages/validate-request-data-schema.json', {
28
+ })).default;
29
+ const ValidateResponseDataSchema = (await import('./messages/validate-response-data-schema.json', {
29
30
  assert: { type: 'json' }
30
- });
31
- const ValidateResponseDataSchema = await import('./messages/validate-response-data-schema.json', {
32
- assert: { type: 'json' }
33
- });
31
+ })).default;
34
32
  export { ConfigFileSchema, ProjectSchema, ResourceSchema, IpcMessageSchema, ApplyRequestDataSchema, ApplyResponseDataSchema, ErrorResponseDataSchema, PlanRequestDataSchema, PlanResponseDataSchema, ValidateRequestDataSchema, ValidateResponseDataSchema, };
35
33
  export * from './types/index.js';
36
34
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,MAAM,gBAAgB,GAAG,MAAM,MAAM,CAAC,2BAA2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;IAC1F,MAAM,EAAE,EAAE,IAAI,EAAE,MAAM,EAAC;CACxB,CAAC,CAAC,CAAC,OAAO,CAAC;AACZ,MAAM,qBAAqB,GAAG,CAAC,MAAM,MAAM,CAAC,0CAA0C,EAAE;IACtF,MAAM,EAAE,EAAE,IAAI,EAAE,MAAM,EAAC;CACxB,CAAC,CAAC,CAAC,OAAO,CAAC;AACZ,MAAM,sBAAsB,GAAG,CAAC,MAAM,MAAM,CAAC,2CAA2C,EAAE;IACxF,MAAM,EAAE,EAAE,IAAI,EAAE,MAAM,EAAC;CACxB,CAAC,CAAC,CAAC,OAAO,CAAA;AACX,MAAM,yBAAyB,GAAG,CAAC,MAAM,MAAM,CAAC,8CAA8C,EAAE;IAC9F,MAAM,EAAE,EAAE,IAAI,EAAE,MAAM,EAAC;CACxB,CAAC,CAAC,CAAC,OAAO,CAAC;AACZ,MAAM,0BAA0B,GAAG,CAAC,MAAM,MAAM,CAAC,+CAA+C,EAAE;IAChG,MAAM,EAAE,EAAE,IAAI,EAAE,MAAM,EAAC;CACxB,CAAC,CAAC,CAAC,OAAO,CAAC;AAEZ,OAAO,EACL,gBAAgB,EAChB,aAAa,EACb,cAAc,EACd,gBAAgB,EAChB,sBAAsB,EACtB,uBAAuB,EACvB,uBAAuB,EACvB,qBAAqB,EACrB,sBAAsB,EACtB,yBAAyB,EACzB,0BAA0B,GAC3B,CAAA;AAED,cAAc,kBAAkB,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "codify-schemas",
3
- "version": "1.0.20",
3
+ "version": "1.0.22",
4
4
  "description": "",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
package/src/index.ts CHANGED
@@ -1,36 +1,35 @@
1
- const ConfigFileSchema = await import('./config-file-schema.json', {
1
+ // @ts-ignore
2
+ import ConfigFileSchema from './config-file-schema.json' assert { type: 'json'}
3
+ const ProjectSchema = (await import('./project-schema.json', {
2
4
  assert: { type: 'json'}
3
- })
4
- const ProjectSchema = await import('./project-schema.json', {
5
+ })).default;
6
+ const ResourceSchema = (await import('./resource-schema.json', {
5
7
  assert: { type: 'json'}
6
- })
7
- const ResourceSchema = await import('./resource-schema.json', {
8
+ })).default;
9
+ const IpcMessageSchema = (await import('./ipc-message-schema.json', {
8
10
  assert: { type: 'json'}
9
- })
10
- const IpcMessageSchema = await import('./ipc-message-schema.json', {
11
+ })).default;
12
+ const ApplyRequestDataSchema = (await import('./messages/apply-request-data-schema.json', {
11
13
  assert: { type: 'json'}
12
- })
13
- const ApplyRequestDataSchema = await import('./messages/apply-request-data-schema.json', {
14
+ })).default;
15
+ const ApplyResponseDataSchema = (await import('./messages/apply-response-data-schema.json', {
14
16
  assert: { type: 'json'}
15
- })
16
- const ApplyResponseDataSchema = await import('./messages/apply-response-data-schema.json', {
17
+ })).default;
18
+ const ErrorResponseDataSchema = (await import('./messages/error-response-data-schema.json', {
17
19
  assert: { type: 'json'}
18
- })
19
- const ErrorResponseDataSchema = await import('./messages/error-response-data-schema.json', {
20
+ })).default;
21
+ const PlanRequestDataSchema = (await import('./messages/plan-request-data-schema.json', {
20
22
  assert: { type: 'json'}
21
- })
22
- const PlanRequestDataSchema = await import('./messages/plan-request-data-schema.json', {
23
+ })).default;
24
+ const PlanResponseDataSchema = (await import('./messages/plan-response-data-schema.json', {
23
25
  assert: { type: 'json'}
24
- })
25
- const PlanResponseDataSchema = await import('./messages/plan-response-data-schema.json', {
26
+ })).default
27
+ const ValidateRequestDataSchema = (await import('./messages/validate-request-data-schema.json', {
26
28
  assert: { type: 'json'}
27
- })
28
- const ValidateRequestDataSchema = await import('./messages/validate-request-data-schema.json', {
29
+ })).default;
30
+ const ValidateResponseDataSchema = (await import('./messages/validate-response-data-schema.json', {
29
31
  assert: { type: 'json'}
30
- })
31
- const ValidateResponseDataSchema = await import('./messages/validate-response-data-schema.json', {
32
- assert: { type: 'json'}
33
- })
32
+ })).default;
34
33
 
35
34
  export {
36
35
  ConfigFileSchema,
package/tsconfig.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "compilerOptions": {
3
- "module": "Node16",
4
- "moduleResolution": "Node16",
3
+ "module": "NodeNext",
4
+ "moduleResolution": "NodeNext",
5
5
  "sourceMap": true,
6
6
  "esModuleInterop": true,
7
7
  "resolveJsonModule": true,