From 92c3b9c5026be6b8ba20ce154647a33dd3170fc3 Mon Sep 17 00:00:00 2001 From: sabaimran Date: Thu, 7 Nov 2024 16:02:53 -0800 Subject: [PATCH] Add function to get an icon from a file type --- src/interface/web/app/common/iconUtils.tsx | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/interface/web/app/common/iconUtils.tsx b/src/interface/web/app/common/iconUtils.tsx index b6391d1b..4fad417e 100644 --- a/src/interface/web/app/common/iconUtils.tsx +++ b/src/interface/web/app/common/iconUtils.tsx @@ -49,6 +49,7 @@ import { Gavel, Broadcast, KeyReturn, + FilePdf, } from "@phosphor-icons/react"; import { Markdown, OrgMode, Pdf, Word } from "@/app/components/logo/fileLogo"; @@ -216,6 +217,13 @@ export function getIconForSlashCommand(command: string, customClassName: string return ; } +export function getIconFromFileType(fileType: string) { + if (fileType == "pdf") { + return ; + } + return ; +} + function getIconFromIconName( iconName: string, color: string = "gray",