Skip to content

Commit 0ca1d79

Browse files
committed
fix the issue of the empty space appearing in the bottom after scrolling
Signed-off-by: kiranscaria <kiranscaria@outlook.com>
1 parent 0093dc8 commit 0ca1d79

File tree

5 files changed

+280
-217
lines changed

5 files changed

+280
-217
lines changed

agentneo/ui/dist/index.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@
88
<meta name="description" content="Agentic Observability & Evaluation Framework" />
99
<link rel="apple-touch-icon" href="/assets/favicon-Btggvy49.svg" />
1010
<title>AgentNeo</title>
11-
<script type="module" crossorigin src="/assets/index-C80hgr9A.js"></script>
12-
<link rel="stylesheet" crossorigin href="/assets/index-DsQokelJ.css">
11+
<script type="module" crossorigin src="/assets/index-cCwUJCMx.js"></script>
12+
<link rel="stylesheet" crossorigin href="/assets/index-CDU8SMcO.css">
1313
</head>
1414

1515
<body>

agentneo/ui/src/pages/Analysis.tsx

Lines changed: 58 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -24,21 +24,24 @@ const Analysis: React.FC = () => {
2424
} = useProject();
2525

2626
return (
27-
<div className="flex h-screen bg-gray-100 dark:bg-gray-900">
27+
<div className="flex h-screen overflow-hidden bg-gray-100 dark:bg-gray-900">
2828
<Sidebar />
29-
<div className="flex-1 overflow-y-auto">
30-
<div className="p-8">
31-
<div className="flex items-center justify-between mb-6">
29+
30+
{/* Main content container with flex column layout */}
31+
<div className="flex-1 flex flex-col min-h-0">
32+
{/* Fixed header section */}
33+
<div className="flex-shrink-0 p-8 bg-gray-100 dark:bg-gray-900 border-b border-gray-200 dark:border-gray-800">
34+
<div className="flex flex-col sm:flex-row justify-between items-start sm:items-center gap-4">
3235
<div className="flex items-center">
3336
<PieChart className="mr-2 h-8 w-8 text-indigo-600 dark:text-indigo-400" />
3437
<h1 className="text-3xl font-bold text-gray-800 dark:text-white">Analytics</h1>
3538
</div>
36-
<div className="flex space-x-4">
39+
<div className="flex flex-col sm:flex-row gap-4 w-full sm:w-auto">
3740
<Select
3841
value={selectedProject?.toString() || ''}
3942
onValueChange={(value) => setSelectedProject(Number(value))}
4043
>
41-
<SelectTrigger className="w-[200px]">
44+
<SelectTrigger className="w-full sm:w-[200px]">
4245
<SelectValue placeholder="Select project" />
4346
</SelectTrigger>
4447
<SelectContent>
@@ -54,7 +57,7 @@ const Analysis: React.FC = () => {
5457
onValueChange={setSelectedTraceId}
5558
disabled={!selectedProject}
5659
>
57-
<SelectTrigger className="w-[200px]">
60+
<SelectTrigger className="w-full sm:w-[200px]">
5861
<SelectValue placeholder="Select trace" />
5962
</SelectTrigger>
6063
<SelectContent>
@@ -67,27 +70,55 @@ const Analysis: React.FC = () => {
6770
</Select>
6871
</div>
6972
</div>
70-
<div className="space-y-6">
71-
{selectedProject && (
72-
<>
73-
<PerformanceMetrics />
74-
<div className="grid grid-cols-1 lg:grid-cols-2 gap-6">
75-
<LLMUsageAnalysis />
76-
<ToolPerformanceAnalysis /> {/* Removed projectId prop */}
77-
</div>
78-
<div className="grid grid-cols-1 lg:grid-cols-2 gap-6">
79-
<ErrorAnalysis />
80-
<TimeAnalysis />
73+
</div>
74+
75+
{/* Scrollable content area */}
76+
<div className="flex-1 overflow-y-auto min-h-0">
77+
<div className="p-8">
78+
<div className="space-y-6 max-w-full">
79+
{selectedProject ? (
80+
<>
81+
{/* Performance Metrics Section */}
82+
<div className="w-full">
83+
<PerformanceMetrics />
84+
</div>
85+
86+
{/* LLM Usage and Tool Performance Grid */}
87+
<div className="grid grid-cols-1 lg:grid-cols-2 gap-6">
88+
<div className="h-full">
89+
<LLMUsageAnalysis />
90+
</div>
91+
<div className="h-full">
92+
<ToolPerformanceAnalysis />
93+
</div>
94+
</div>
95+
96+
{/* Error and Time Analysis Grid */}
97+
<div className="grid grid-cols-1 lg:grid-cols-2 gap-6">
98+
<div className="h-full">
99+
<ErrorAnalysis />
100+
</div>
101+
<div className="h-full">
102+
<TimeAnalysis />
103+
</div>
104+
</div>
105+
106+
{/* Full Width Sections */}
107+
<div className="w-full">
108+
<TracePerformanceComparison />
109+
</div>
110+
<div className="w-full">
111+
<TopPerformanceCriteria />
112+
</div>
113+
</>
114+
) : (
115+
<div className="flex items-center justify-center min-h-[200px] bg-white dark:bg-gray-800 rounded-lg shadow">
116+
<div className="text-center text-gray-500 dark:text-gray-400">
117+
Please select a project to view analytics
118+
</div>
81119
</div>
82-
<TracePerformanceComparison />
83-
<TopPerformanceCriteria />
84-
</>
85-
)}
86-
{!selectedProject && (
87-
<div className="text-center p-8 text-gray-500">
88-
Please select a project to view analytics
89-
</div>
90-
)}
120+
)}
121+
</div>
91122
</div>
92123
</div>
93124
</div>

0 commit comments

Comments
 (0)