diff --git a/packages/cli-dashboard/src/components/siteReport/components/layout.tsx b/packages/cli-dashboard/src/components/siteReport/components/layout.tsx index 0b3884cad..9cc564e4d 100644 --- a/packages/cli-dashboard/src/components/siteReport/components/layout.tsx +++ b/packages/cli-dashboard/src/components/siteReport/components/layout.tsx @@ -42,8 +42,9 @@ interface LayoutProps { const Layout = ({ selectedSite }: LayoutProps) => { const [data, setData] = useState(TABS); - const { tabCookies } = useContentStore(({ state }) => ({ + const { tabCookies, technologyData } = useContentStore(({ state }) => ({ tabCookies: state.tabCookies, + technologyData: state.technologies, })); const frameUrls = useMemo( @@ -113,13 +114,17 @@ const Layout = ({ selectedSite }: LayoutProps) => { ); - _data['technologies'].panel = ( - - ); + if (technologyData && technologyData.length > 0) { + _data['technologies'].panel = ( + + ); + } else { + delete _data['technologies']; + } return _data; }); - }, [frameUrls, selectedItemKey, selectedSite]); + }, [frameUrls, selectedItemKey, selectedSite, technologyData]); useEffect(() => { if (selectedItemKey === null) {