Media & Documents (Content Model)
Two related subsystems handle files: the media library for images used by content, and documents for downloadable files. They behave differently by design — images ride along inside pages, while documents are delivered by the CMS itself.
Media
- Every upload becomes a library record with metadata: original name, MIME type, size, alt text, caption, credit, and folder.
- Images are processed at upload — resized and derivative sizes generated; the file itself keeps its name across replacements, so all references remain valid when you swap an image for a new version.
- Each save creates a media revision; content integrity checks run on the store.
- Media deletion is a soft delete into Trash, and the periodic purge removes rows whose files are gone from disk.
Documents
Documents are downloadable files (PDFs, ZIPs, etc.) with their own publishing lifecycle:
- Title, slug, language, description, publish windows, and folder organization.
- Extra metadata captured per document type (page count, author, creation date, dimensions, color mode — useful for picture assets and reports).
- Download counts per document.
- Documents carry their own tag vocabulary (separate from post tags, with optional colors).
- Scheduled publish and unpublish windows work like page scheduling.
- A
[form:slug]-style embed isn’t how docs surface: links to them come from the document block type or direct links from body content.