diff --git a/apps/web/src/app/dashboard/agents/[id]/chat/page.tsx b/apps/web/src/app/dashboard/agents/[id]/chat/page.tsx index 1527690..94075ef 100644 --- a/apps/web/src/app/dashboard/agents/[id]/chat/page.tsx +++ b/apps/web/src/app/dashboard/agents/[id]/chat/page.tsx @@ -6,7 +6,7 @@ import { Icon } from '@tpmjs/ui/Icon/Icon'; import Link from 'next/link'; import { useParams, useRouter } from 'next/navigation'; import { useCallback, useEffect, useRef, useState } from 'react'; -import { AppHeader } from '~/components/AppHeader'; +import { DashboardLayout } from '~/components/dashboard/DashboardLayout'; interface Agent { id: string; @@ -413,24 +413,24 @@ export default function AgentChatPage(): React.ReactElement { if (isLoading) { return ( -
- -
-
-
-
-
+ +
+
-
+ ); } if (error && !agent) { return ( -
- -
-
+ +
+

Error

{error}

@@ -439,71 +439,65 @@ export default function AgentChatPage(): React.ReactElement {
-
+ ); } if (!agent) { return ( -
- -
+ +
-
+ ); } return ( -
- - -
- {/* Sidebar */} -
- {/* Agent Info */} -
- -
- -
-
-

{agent.name}

-

- {PROVIDER_DISPLAY_NAMES[agent.provider]} -

-
- -
- - {/* New Conversation Button */} -
- -
- + + + New Chat + + } + > +
+ {/* Conversations Sidebar */} +
{/* Conversations List */}
- {conversations.map((conv) => ( - - ))} + {conversations.length === 0 ? ( +

+ No conversations yet +

+ ) : ( + conversations.map((conv) => ( + + )) + )}
@@ -647,6 +641,6 @@ export default function AgentChatPage(): React.ReactElement {
-
+ ); } diff --git a/apps/web/src/components/dashboard/DashboardLayout.tsx b/apps/web/src/components/dashboard/DashboardLayout.tsx index 8adde59..988aec5 100644 --- a/apps/web/src/components/dashboard/DashboardLayout.tsx +++ b/apps/web/src/components/dashboard/DashboardLayout.tsx @@ -34,6 +34,8 @@ interface DashboardLayoutProps { showBackButton?: boolean; /** Custom back URL (defaults to parent route) */ backUrl?: string; + /** Whether to use full height layout (for chat interfaces) - removes padding and fills viewport */ + fullHeight?: boolean; } export function DashboardLayout({ @@ -43,6 +45,7 @@ export function DashboardLayout({ actions, showBackButton, backUrl, + fullHeight, }: DashboardLayoutProps): React.ReactElement { const pathname = usePathname(); const router = useRouter(); @@ -158,9 +161,13 @@ export function DashboardLayout({ {/* Main content */} -
+
{/* Content header */} -
+
@@ -198,7 +205,7 @@ export function DashboardLayout({
{/* Page content */} -
{children}
+
{children}