From c3fc51f78156c41a869413c46d98bb716a13dac0 Mon Sep 17 00:00:00 2001 From: Jonas Schell Date: Thu, 26 Sep 2024 15:16:48 +0200 Subject: [PATCH] Update the no agent connection msg --- app/page.tsx | 16 +++------------- components/NoAgentNotification.tsx | 10 ++++++++-- 2 files changed, 11 insertions(+), 15 deletions(-) diff --git a/app/page.tsx b/app/page.tsx index e91b1d5..e70d5ab 100644 --- a/app/page.tsx +++ b/app/page.tsx @@ -22,13 +22,10 @@ export default function Page() { const onConnectButtonClicked = useCallback(async () => { const url = new URL( process.env.NEXT_PUBLIC_CONN_DETAILS_ENDPOINT ?? - "/api/connection-details", + "/api/connection-details", window.location.origin ); - const subdomain = window.location.host.split(".")[0]; - const response = await fetch( - url.toString(), - { headers: { "X-Sandbox-ID": subdomain } }); + const response = await fetch(url.toString()); const connectionDetailsData = await response.json(); updateConnectionDetails(connectionDetailsData); }, []); @@ -72,14 +69,7 @@ function SimpleVoiceAssistant() {

{state}

- -

- No agent joined this session. Follow the guide to setup your agent. -

- - View guide - -
+
); } diff --git a/components/NoAgentNotification.tsx b/components/NoAgentNotification.tsx index 6c287d6..02a890a 100644 --- a/components/NoAgentNotification.tsx +++ b/components/NoAgentNotification.tsx @@ -33,7 +33,7 @@ export function NoAgentNotification(props: NoAgentNotificationProps) { return ( <> {showNotification ? ( -
+
{/* Warning Icon */}
- {props.children} +

+ It's quiet... too quiet. Is your agent lost? Make sure your + agent is set up and running correctly. +

+ + View guide +