feat: adds admin.upload.collections[collection-name].fields to the RTE to save specific data on upload elements

This commit is contained in:
Jarrod Flesch
2022-01-19 11:21:08 -05:00
parent 7c7b546812
commit 3adf44a241
15 changed files with 655 additions and 204 deletions

View File

@@ -263,6 +263,11 @@ export const richText = baseField.keys({
),
),
hideGutter: joi.boolean().default(false),
upload: joi.object({
collections: joi.object().pattern(joi.string(), joi.object().keys({
fields: joi.array().items(joi.link('#field')),
})),
}),
}),
});

View File

@@ -223,6 +223,13 @@ export type RichTextField = FieldBase & {
elements?: RichTextElement[];
leaves?: RichTextLeaf[];
hideGutter?: boolean;
upload?: {
collections: {
[collection: string]: {
fields: Field[];
}
}
}
}
}