From 7f47a479db3ab4180ccf57bb5a27f586d7732001 Mon Sep 17 00:00:00 2001 From: Marcus Aurelius Date: Tue, 14 Jan 2025 15:26:19 -0500 Subject: [PATCH] Add hosted media field --- carbon-projects/schemas/objects/hostedFile.ts | 5 +++-- carbon-projects/schemas/project.ts | 9 ++++++++- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/carbon-projects/schemas/objects/hostedFile.ts b/carbon-projects/schemas/objects/hostedFile.ts index 3c25ec15df..997a368cd8 100644 --- a/carbon-projects/schemas/objects/hostedFile.ts +++ b/carbon-projects/schemas/objects/hostedFile.ts @@ -19,7 +19,8 @@ export default defineType({ }, { type: "string", - title: "MIME Type", + title: "MIME Type (e.g. application/pdf)", + description: "Reference: https://developer.mozilla.org/en-US/docs/Web/HTTP/MIME_types/Common_types", name: "mimetype", }, { @@ -29,7 +30,7 @@ export default defineType({ }, { type: "number", - title: "File size", + title: "File size (in bytes)", name: "size", }, ], diff --git a/carbon-projects/schemas/project.ts b/carbon-projects/schemas/project.ts index 935b737a2d..b21e49a67a 100644 --- a/carbon-projects/schemas/project.ts +++ b/carbon-projects/schemas/project.ts @@ -315,11 +315,18 @@ export default defineType({ }), defineField({ name: "externalDocuments", - description: "External PDF documents associated with this project", + description: "External documents (e.g. PDFs, Word documents) associated with this project", group: "media", type: "array", of: [{ type: "externalFile" }], }), + defineField({ + name: "hostedMedia", + description: "Media hosted in this CMS and associated captions", + group: "media", + type: "array", + of: [{ type: "captionImage" }], + }), defineField({ name: "hostedDocuments", description: