From ccbe11e20cfee1e01eaffbd33352437de5d93da8 Mon Sep 17 00:00:00 2001 From: Florian Rupp Date: Tue, 9 May 2023 23:29:55 +0200 Subject: [PATCH] add support for dashboard-icons svg format --- src/components/resolvedicon.jsx | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/src/components/resolvedicon.jsx b/src/components/resolvedicon.jsx index a37997d33..fa9fa68d9 100644 --- a/src/components/resolvedicon.jsx +++ b/src/components/resolvedicon.jsx @@ -57,7 +57,27 @@ export default function ResolvedIcon({ icon, width = 32, height = 32, alt = "log ); } + // fallback to dashboard-icons + if (icon.endsWith(".svg")) { + const iconName = icon.replace(".svg", ""); + return ( + {alt} + ); + } + const iconName = icon.replace(".png", ""); return (