diff --git a/frontend/src/app/pages/Dashboard/canvas/DashboardCanvas.tsx b/frontend/src/app/pages/Dashboard/canvas/DashboardCanvas.tsx index 6e9a5866..95e75390 100644 --- a/frontend/src/app/pages/Dashboard/canvas/DashboardCanvas.tsx +++ b/frontend/src/app/pages/Dashboard/canvas/DashboardCanvas.tsx @@ -52,7 +52,6 @@ interface DashboardCanvasProps { canvas: Canvas; selection: Selection; sessions: Record; - sessionList: AgentSession[]; cards: Record; viewCards: Record; browserCards: Record; @@ -114,7 +113,6 @@ const DashboardCanvas: React.FC = ({ canvas, selection, sessions, - sessionList, cards, viewCards, browserCards, @@ -515,7 +513,7 @@ const DashboardCanvas: React.FC = ({ /> )} - {sessionList.length === 0 && Object.keys(viewCards).length === 0 && Object.keys(browserCards).length === 0 && Object.keys(workflowCards).length === 0 && !workflowsHub && !fullscreenCardId && ( + {canvasEmpty && !fullscreenCardId && ( )} diff --git a/frontend/src/app/pages/Dashboard/hooks/state/useDashboardController.ts b/frontend/src/app/pages/Dashboard/hooks/state/useDashboardController.ts index f7bfdf6d..d1c5905d 100644 --- a/frontend/src/app/pages/Dashboard/hooks/state/useDashboardController.ts +++ b/frontend/src/app/pages/Dashboard/hooks/state/useDashboardController.ts @@ -90,12 +90,16 @@ export function useDashboardController(dashboardId: string, isActive: boolean) { // Nudge the chat button while the canvas is empty; the first click dismisses it for this visit. const bounceDismissedRef = useRef(false); - // Truly-empty canvas: matches the empty-state hero's own render condition (fullscreen is handled + const settingsWindowOpen = useAppSelector((s) => !!s.dashboardLayout.settingsCard); + const marketplaceWindowOpen = useAppSelector((s) => !!s.dashboardLayout.marketplaceCard); + // Truly-empty canvas: IS the empty-state hero's render condition (fullscreen is handled // separately, it display:none's the whole overlay layer), so "pill hidden" always coincides with - // "hero shown" and a workflow-card-only canvas never ends up with no composer at all. + // "hero shown". The singleton windows (Settings, Marketplace, Run Monitor) count as content, + // otherwise the hero floats on top of an open window. const canvasEmpty = layoutInitialized && sessionList.length === 0 && Object.keys(viewCards).length === 0 && Object.keys(browserCards).length === 0 - && Object.keys(workflowCards).length === 0 && !workflowsHub; + && Object.keys(workflowCards).length === 0 && !workflowsHub + && !settingsWindowOpen && !marketplaceWindowOpen && !workflowsMonitorCard; useEffect(() => { setNewAgentBounce(canvasEmpty && !bounceDismissedRef.current); }, [canvasEmpty, setNewAgentBounce]); diff --git a/frontend/src/app/pages/Directory/MarketplaceAppCard.tsx b/frontend/src/app/pages/Directory/MarketplaceAppCard.tsx index 75dbcc51..4d521fa6 100644 --- a/frontend/src/app/pages/Directory/MarketplaceAppCard.tsx +++ b/frontend/src/app/pages/Directory/MarketplaceAppCard.tsx @@ -1,5 +1,4 @@ import React, { useCallback } from 'react'; -import StorefrontIcon from '@mui/icons-material/Storefront'; import { useAppDispatch, useAppSelector } from '@/shared/hooks'; import { closeMarketplaceCard, @@ -107,10 +106,6 @@ const MarketplaceAppCard: React.FC = ({ > -
- - Marketplace -
diff --git a/frontend/src/app/pages/Settings/SettingsAppCard.tsx b/frontend/src/app/pages/Settings/SettingsAppCard.tsx index b668c8c5..8bb28ded 100644 --- a/frontend/src/app/pages/Settings/SettingsAppCard.tsx +++ b/frontend/src/app/pages/Settings/SettingsAppCard.tsx @@ -1,5 +1,4 @@ import React, { useCallback } from 'react'; -import SettingsIcon from '@mui/icons-material/Settings'; import { useAppDispatch, useAppSelector } from '@/shared/hooks'; import { closeSettingsCard, @@ -109,10 +108,6 @@ const SettingsAppCard: React.FC = ({ > -
- - Settings -