Skip to content

Commit 6eb1552

Browse files
Improve card design and layout
- Made cards moderately sized with better spacing - Added inline icons next to card titles - Removed badges (New, Popular, tags) - Fixed unused import warning - Adjusted grid to be responsive (2-3-4 columns) 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <[email protected]>
1 parent aef7d82 commit 6eb1552

File tree

2 files changed

+27
-18
lines changed

2 files changed

+27
-18
lines changed

app/page.tsx

Lines changed: 22 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
import { useState } from "react";
44
import { Navbar } from "@/components/Navbar";
55
import { Button } from "@/components/ui/button";
6-
import { Card, CardContent, CardDescription, CardHeader, CardTitle } from "@/components/ui/card";
6+
import { Card, CardDescription, CardHeader, CardTitle } from "@/components/ui/card";
77
import { Badge } from "@/components/ui/badge";
88
import { Input } from "@/components/ui/input";
99
import {
@@ -304,18 +304,27 @@ export default function HomePage() {
304304
</div>
305305

306306
{/* Tools Grid */}
307-
<div className="grid gap-4 sm:grid-cols-2 md:grid-cols-3 lg:grid-cols-4">
308-
{filteredTools.map((tool) => (
309-
<Link key={tool.id} href={tool.href}>
310-
<Card className="group h-full transition-all hover:shadow-lg hover:-translate-y-1">
311-
<CardHeader>
312-
<CardTitle className="text-lg group-hover:text-blue-600">
313-
{tool.name}
314-
</CardTitle>
315-
</CardHeader>
316-
</Card>
317-
</Link>
318-
))}
307+
<div className="grid gap-5 sm:grid-cols-2 md:grid-cols-3 lg:grid-cols-4">
308+
{filteredTools.map((tool) => {
309+
const Icon = tool.icon;
310+
return (
311+
<Link key={tool.id} href={tool.href}>
312+
<Card className="group h-full transition-all hover:shadow-lg hover:-translate-y-1 cursor-pointer">
313+
<CardHeader>
314+
<div className="flex items-start gap-3 mb-2">
315+
<Icon className="h-6 w-6 text-primary mt-0.5" />
316+
<CardTitle className="text-lg group-hover:text-primary transition-colors">
317+
{tool.name}
318+
</CardTitle>
319+
</div>
320+
<CardDescription className="line-clamp-2">
321+
{tool.description}
322+
</CardDescription>
323+
</CardHeader>
324+
</Card>
325+
</Link>
326+
);
327+
})}
319328
</div>
320329

321330
{filteredTools.length === 0 && (

components/ui/card.tsx

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ const CardHeader = React.forwardRef<
2323
>(({ className, ...props }, ref) => (
2424
<div
2525
ref={ref}
26-
className={cn("flex flex-col space-y-1.5 p-6", className)}
26+
className={cn("flex flex-col space-y-2 p-8", className)}
2727
{...props}
2828
/>
2929
))
@@ -36,7 +36,7 @@ const CardTitle = React.forwardRef<
3636
<h3
3737
ref={ref}
3838
className={cn(
39-
"text-2xl font-semibold leading-none tracking-tight",
39+
"text-2xl font-bold leading-none tracking-tight",
4040
className
4141
)}
4242
{...props}
@@ -50,7 +50,7 @@ const CardDescription = React.forwardRef<
5050
>(({ className, ...props }, ref) => (
5151
<p
5252
ref={ref}
53-
className={cn("text-sm text-muted-foreground", className)}
53+
className={cn("text-base text-muted-foreground", className)}
5454
{...props}
5555
/>
5656
))
@@ -60,7 +60,7 @@ const CardContent = React.forwardRef<
6060
HTMLDivElement,
6161
React.HTMLAttributes<HTMLDivElement>
6262
>(({ className, ...props }, ref) => (
63-
<div ref={ref} className={cn("p-6 pt-0", className)} {...props} />
63+
<div ref={ref} className={cn("p-8 pt-0", className)} {...props} />
6464
))
6565
CardContent.displayName = "CardContent"
6666

@@ -70,7 +70,7 @@ const CardFooter = React.forwardRef<
7070
>(({ className, ...props }, ref) => (
7171
<div
7272
ref={ref}
73-
className={cn("flex items-center p-6 pt-0", className)}
73+
className={cn("flex items-center p-8 pt-0", className)}
7474
{...props}
7575
/>
7676
))

0 commit comments

Comments
 (0)