diff options
Diffstat (limited to 'subprojects/frontend/src/xtext/xtextServiceResults.ts')
-rw-r--r-- | subprojects/frontend/src/xtext/xtextServiceResults.ts | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/subprojects/frontend/src/xtext/xtextServiceResults.ts b/subprojects/frontend/src/xtext/xtextServiceResults.ts index 792c7de3..c5bc1320 100644 --- a/subprojects/frontend/src/xtext/xtextServiceResults.ts +++ b/subprojects/frontend/src/xtext/xtextServiceResults.ts | |||
@@ -162,7 +162,7 @@ export const RelationMetadata = z.object({ | |||
162 | 162 | ||
163 | export type RelationMetadata = z.infer<typeof RelationMetadata>; | 163 | export type RelationMetadata = z.infer<typeof RelationMetadata>; |
164 | 164 | ||
165 | export const SemanticsSuccessResult = z.object({ | 165 | export const SemanticsModelResult = z.object({ |
166 | nodes: NodeMetadata.array(), | 166 | nodes: NodeMetadata.array(), |
167 | relations: RelationMetadata.array(), | 167 | relations: RelationMetadata.array(), |
168 | partialInterpretation: z.record( | 168 | partialInterpretation: z.record( |
@@ -171,13 +171,13 @@ export const SemanticsSuccessResult = z.object({ | |||
171 | ), | 171 | ), |
172 | }); | 172 | }); |
173 | 173 | ||
174 | export type SemanticsSuccessResult = z.infer<typeof SemanticsSuccessResult>; | 174 | export type SemanticsModelResult = z.infer<typeof SemanticsModelResult>; |
175 | 175 | ||
176 | export const SemanticsResult = z.union([ | 176 | export const SemanticsResult = z.object({ |
177 | z.object({ error: z.string() }), | 177 | model: SemanticsModelResult.optional(), |
178 | z.object({ issues: Issue.array() }), | 178 | error: z.string().min(1).optional(), |
179 | SemanticsSuccessResult, | 179 | issues: Issue.array().optional(), |
180 | ]); | 180 | }); |
181 | 181 | ||
182 | export type SemanticsResult = z.infer<typeof SemanticsResult>; | 182 | export type SemanticsResult = z.infer<typeof SemanticsResult>; |
183 | 183 | ||
@@ -190,7 +190,7 @@ export const ModelGenerationResult = z.union([ | |||
190 | uuid: z.string().min(1), | 190 | uuid: z.string().min(1), |
191 | error: z.string(), | 191 | error: z.string(), |
192 | }), | 192 | }), |
193 | SemanticsSuccessResult.extend({ | 193 | SemanticsModelResult.extend({ |
194 | uuid: z.string().min(1), | 194 | uuid: z.string().min(1), |
195 | }), | 195 | }), |
196 | ]); | 196 | ]); |