@oslokommune/punkt-elements
Version:
Komponentbiblioteket til Punkt, et designsystem laget av Oslo Origo
14 lines (13 loc) • 530 B
TypeScript
/** MIME / accept fallback for the thumbnail view (image-only upload mode). */
export declare const THUMBNAIL_ACCEPT = ".jpeg, .jpg, .png, .gif, .webp, .heic";
/**
* Resolve the display name for a file item, preferring the (possibly renamed)
* `attributes.targetFilename`, falling back to the underlying File, and finally
* a localized "unknown file" label.
*/
export declare function getDisplayFilename(item: {
file?: File | null;
attributes?: {
targetFilename?: string;
};
}, fallback?: string): string;