mimetype
This commit is contained in:
@@ -32,8 +32,8 @@ import '../styles/workspace/workspace-cards.css';
|
||||
type Identifier = string | number;
|
||||
|
||||
type TagLike = { id?: Identifier | null; label?: string; color?: string | null } | null;
|
||||
type DocumentLinkLike = { url?: string | null; contentType?: string | null };
|
||||
type OverlaySource = { url: string; alt?: string | null; contentType?: string | null };
|
||||
type DocumentLinkLike = { url?: string | null; mimeType?: string | null };
|
||||
type OverlaySource = { url: string; alt?: string | null; mimeType?: string | null };
|
||||
|
||||
export interface DeskDocument {
|
||||
id?: Identifier | null;
|
||||
@@ -68,7 +68,7 @@ interface OverlayOriginTransform {
|
||||
interface OverlayDisplay {
|
||||
url: string;
|
||||
alt?: string | null;
|
||||
contentType?: string | null;
|
||||
mimeType?: string | null;
|
||||
}
|
||||
|
||||
interface DocumentSizeInfo {
|
||||
@@ -565,7 +565,7 @@ const DesktopWorkspace: React.FC<DesktopWorkspaceProps> = ({
|
||||
};
|
||||
}
|
||||
|
||||
const docContentType = doc?.content_type ?? null;
|
||||
const docMimeType = doc?.mime_type ?? null;
|
||||
|
||||
const applyEntry = (entry?: DocumentLinkLike | null) => {
|
||||
if (!entry?.url) {
|
||||
@@ -575,7 +575,7 @@ const DesktopWorkspace: React.FC<DesktopWorkspaceProps> = ({
|
||||
setOverlaySource({
|
||||
url: entry.url,
|
||||
alt: doc.title,
|
||||
contentType: docContentType || undefined,
|
||||
mimeType: docMimeType || undefined,
|
||||
});
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user