Skip to main content

Module files

Module files 

Source
Expand description

File descriptor helpers — MIME / extension → preview kind, plus the serde_json::Value shape the file-preview macros consume.

⚠ A first-class File / Image ORM field type is deferred. For now you store file paths in Text columns and emit a descriptor JSON string for the admin to render. This module owns the descriptor shape so other plugins (and user code) can construct one without re-implementing the MIME table.

Functions§

file_descriptor
Build a file descriptor JSON value.
resolve_preview_kind
Resolve the preview_kind from a MIME type and file extension.