diff --git a/admin/inertia/components/chat/ChatSidebar.tsx b/admin/inertia/components/chat/ChatSidebar.tsx index b43c3ca..c6adf0a 100644 --- a/admin/inertia/components/chat/ChatSidebar.tsx +++ b/admin/inertia/components/chat/ChatSidebar.tsx @@ -117,18 +117,17 @@ export default function ChatSidebar({ Project NOMAD Logo { - if (isInModal) { - window.open('/chat', '_blank') - } else { - router.visit('/home') - } + // /chat is served by the admin app itself, so navigate in place rather than + // spawning a window. Popping out broke anyone running NOMAD as an installed + // web app or in kiosk mode, who then had a stray window to get back out of. + router.visit(isInModal ? '/chat' : '/home') }} - icon={isInModal ? 'IconExternalLink' : 'IconHome'} + icon={isInModal ? 'IconArrowRight' : 'IconHome'} variant="outline" size="sm" fullWidth > - {isInModal ? 'Open in New Tab' : 'Back to Home'} + {isInModal ? 'Open Full Chat' : 'Back to Home'} {