From 9b5bf901d573892d22dedb9a62abd0e963495cf8 Mon Sep 17 00:00:00 2001 From: Sean Edmunds Date: Tue, 30 Dec 2025 11:12:39 -0600 Subject: [PATCH] Icon bug fix --- .../homepage/components/Search/Search.tsx | 24 +++++++++---------- 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/src/pages/homepage/components/Search/Search.tsx b/src/pages/homepage/components/Search/Search.tsx index 71919f6..75c3416 100644 --- a/src/pages/homepage/components/Search/Search.tsx +++ b/src/pages/homepage/components/Search/Search.tsx @@ -390,20 +390,20 @@ export default function Search({ }; const renderItem: any = (item: any) => { - const Icon = item.option.icon + const Icon = item.option.prefix ? allIcons[ - item.option.icon - ? item.option.icon - : item.option.prefix === '/g' - ? 'FaGoogle' - : (providers.find((p: Provider) => p.prefix === item.option.prefix)?.icon ?? - '') + item.option.prefix === '/g' + ? 'FaGoogle' + : (providers.find((p: Provider) => p.prefix === item.option.prefix)?.icon ?? + '') ] - : item.option.type === 'SSH' - ? allIcons.FaTerminal - : item.option.type === 'RDP' - ? allIcons.FaComputer - : allIcons.FaDesktop; + : item.option.icon + ? allIcons[item.option.icon] + : item.option.type && item.option.type === 'SSH' + ? allIcons.FaTerminal + : item.option.type === 'RDP' + ? allIcons.FaComputer + : allIcons.FaDesktop; return (searchValue as string).startsWith('!') ? (