diff --git a/app/src/pages/demo.tsx b/app/src/pages/demo.tsx index f53340b..69b5c80 100644 --- a/app/src/pages/demo.tsx +++ b/app/src/pages/demo.tsx @@ -47,6 +47,8 @@ const Demo: NextPage = ({ officers }) => { } const popOut = async (session) => { + notify(toastDispatch, "", "Loading call log...", ToastType.DEFAULT) + const messages = await (await fetch(process.env.NEXT_PUBLIC_API_URL + '/session/message/?sessionId=' + session.id, { method: 'GET', headers: { @@ -66,6 +68,7 @@ const Demo: NextPage = ({ officers }) => { console.log(session) setFocusSession(session) + notify(toastDispatch, "", "Loaded call log!", ToastType.SUCCESS) } const transfer = async () => { @@ -112,26 +115,30 @@ const Demo: NextPage = ({ officers }) => { { session ? <> - {focusSession ? -
- -
+
+ + {focusSession ? + <>

Caller: {focusSession.callerPhone} | {focusSession.startedAt}

-

Summary: {focusSession.summary}

- {focusSession.messages.map(msg => { - return ( -
-

{msg.role}: {msg.content}

-

-
- ); - })} -
- : null - } -
+

Summary: {focusSession.summary}

+
+ {focusSession.messages.map(msg => { + return ( +
+

{msg.role}: {msg.content}

+

+
+ ); + })} +
+ + : null + } +
+ +

Hey {session.user.name.split(' ')[0]}!

Can you give us your number real quick?