component:content

This commit is contained in:
lovebird 2025-03-12 08:57:03 +01:00
parent 86983b62d0
commit b3ef5683f0
3 changed files with 896 additions and 853 deletions

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long

View File

@ -131,12 +131,16 @@ export const AuthorSchema = z.object({
url: z.string(),
})
export const ContentSchema = z.object({
body: z.string().optional(),
features: z.string().optional(),
highlights: z.string().optional(),
specs: z.string().optional(),
license: z.string().optional()
license: z.string().optional(),
resources: z.string().optional(),
readme: z.string().optional(),
shared: z.string().optional()
})
export const VersionSchema = z.object({
@ -252,7 +256,7 @@ export const ComponentConfigSchema = z.object({
product_dimensions: z.string().optional(),
production: ProductionSchema.optional(),
score: z.number().optional()
}).passthrough()
}).merge(ContentSchema).passthrough()
export type IComponentConfig = z.infer<typeof ComponentConfigSchema>
export type ICADNodeSchema = z.infer<typeof CADMetaSchema>