@@ -6,6 +6,7 @@ import { api } from '@/client/trpc';
6
6
import { Button } from '@/components/ui/button' ;
7
7
import { ScrollArea , ScrollBar } from '@/components/ui/scroll-area' ;
8
8
import { Skeleton } from '@/components/ui/skeleton' ;
9
+ import { Table , TableBody , TableCell , TableHead , TableHeader , TableRow } from '@/components/ui/table' ;
9
10
import { Textarea } from '@/components/ui/textarea' ;
10
11
import { languageOptions } from '@/constants/app' ;
11
12
import { cn } from '@/lib/utils/cn' ;
@@ -171,32 +172,34 @@ export function OutputDetails() {
171
172
172
173
if ( ! output . status || ! output . memory || ! output . time ) return null ;
173
174
174
- if ( processing )
175
- return (
176
- < div className = 'text-sm text-muted-foreground mt-3 space-y-1' >
177
- < div className = 'flex items-center justify-start gap-3' >
178
- Status: < Skeleton className = 'h-4 w-20' />
179
- </ div >
180
- < div className = 'flex items-center justify-start gap-3' >
181
- Memory: < Skeleton className = 'h-4 w-20' />
182
- </ div >
183
- < div className = 'flex items-center justify-start gap-3' >
184
- Time: < Skeleton className = 'h-4 w-20' />
185
- </ div >
186
- </ div >
187
- ) ;
188
-
189
175
return (
190
- < div className = 'text-sm text-muted-foreground mt-3 space-y-1' >
191
- < p >
192
- Status: < span className = 'font-medium' > { output . status . description } </ span >
193
- </ p >
194
- < p >
195
- Memory: < span className = 'font-medium' > { output . memory } </ span >
196
- </ p >
197
- < p >
198
- Time: < span className = 'font-medium' > { output . time } </ span >
199
- </ p >
176
+ < div className = 'text-muted-foreground mt-3 border rounded-lg overflow-hidden' >
177
+ < Table className = 'table-fixed' >
178
+ < TableHeader >
179
+ < TableRow className = 'bg-muted/50 text-sm' >
180
+ < TableHead className = 'text-center' > Performance</ TableHead >
181
+ < TableHead className = 'text-center' > Result</ TableHead >
182
+ </ TableRow >
183
+ </ TableHeader >
184
+ < TableBody className = 'text-xs' >
185
+ < TableRow >
186
+ < TableCell className = 'text-center p-3' > Status</ TableCell >
187
+ < TableCell className = 'font-medium text-center p-3' >
188
+ { processing ? < Skeleton className = 'h-4 w-20 mx-auto' /> : output . status . description }
189
+ </ TableCell >
190
+ </ TableRow >
191
+ < TableRow >
192
+ < TableCell className = 'text-center p-3' > Memory</ TableCell >
193
+ < TableCell className = 'font-medium text-center p-3 justify-center' >
194
+ { processing ? < Skeleton className = 'h-4 w-20 mx-auto' /> : output . memory }
195
+ </ TableCell >
196
+ </ TableRow >
197
+ < TableRow >
198
+ < TableCell className = 'text-center p-3' > Time</ TableCell >
199
+ < TableCell className = 'font-medium text-center p-3' > { processing ? < Skeleton className = 'h-4 w-20 mx-auto' /> : output . time } </ TableCell >
200
+ </ TableRow >
201
+ </ TableBody >
202
+ </ Table >
200
203
</ div >
201
204
) ;
202
205
}
0 commit comments