import type { CollectionConfig } from "payload"; export const Media: CollectionConfig = { slug: "media", access: { read: () => true }, admin: { useAsTitle: "alt", group: "System", }, upload: { staticDir: "media", imageSizes: [ { name: "thumb", width: 400, height: 400, position: "centre" }, { name: "card", width: 800, height: undefined, position: "centre" }, { name: "hero", width: 1600, height: undefined, position: "centre" }, { name: "og", width: 1200, height: 630, position: "centre" }, ], adminThumbnail: "thumb", mimeTypes: ["image/*"], }, fields: [ { name: "alt", type: "text", required: true }, { name: "credit", type: "text" }, ], };