ScalesCmsWeb.CmsMediaLibraryLive.MediaLibraryUtils
(scales_cms v0.2.0)
Copy Markdown
Shared utility functions for the CMS Media Library. Contains common logic used by both the Index and Modal components.
Summary
Functions
Returns the accepted file types based on the filter type.
Converts a client MIME type to a media type string.
Lists media items based on query and type filters.
Returns a human-readable string of supported formats based on the filter type. Generated dynamically from the accepted types definitions.
Returns the CSS classes for a media type badge.
Returns upload configuration options for allow_upload.
Converts an upload error atom to a human-readable error message.
Functions
Returns the accepted file types based on the filter type.
Converts a client MIME type to a media type string.
Lists media items based on query and type filters.
Returns a human-readable string of supported formats based on the filter type. Generated dynamically from the accepted types definitions.
Returns the CSS classes for a media type badge.
Returns upload configuration options for allow_upload.
Converts an upload error atom to a human-readable error message.