Profile Card
User profile card with cover gradient banner, overlapping avatar, follow and message buttons. Social app and team directory pattern. Fixed width card component for React dashboards and community products.
Dependencies
react
npm install react react-domexport function ProfileCard() {
return (
<div className="w-72 overflow-hidden rounded-2xl border border-zinc-200 bg-white shadow-lg">
<div className="h-20 bg-gradient-to-r from-sky-400 to-indigo-500" />
<div className="-mt-8 px-5 pb-5">
<div className="h-16 w-16 rounded-full border-4 border-white bg-zinc-200" />
<h3 className="mt-3 font-semibold text-zinc-900">Jordan Lee</h3>
<p className="text-sm text-zinc-500">Product designer</p>
<div className="mt-4 flex gap-2">
<button className="flex-1 rounded-lg bg-zinc-900 py-2 text-xs font-semibold text-white">Follow</button>
<button className="flex-1 rounded-lg border border-zinc-200 py-2 text-xs font-semibold">Message</button>
</div>
</div>
</div>
);
}
Please implement this code in the current project and add it to (Your Desired Section, e.g. homepage hero, pricing page, dashboard). Change the primary accent color to (YOUR HEX CODE COLOR, e.g. #6366F1).
Requirements:
- Use React + Tailwind CSS (match the project's existing setup)
- Install dependencies if needed: npm install react react-dom
- Keep the layout responsive on mobile and desktop
- Replace placeholder copy with content that fits the project
The UI code:
export function ProfileCard() {
return (
<div className="w-72 overflow-hidden rounded-2xl border border-zinc-200 bg-white shadow-lg">
<div className="h-20 bg-gradient-to-r from-sky-400 to-indigo-500" />
<div className="-mt-8 px-5 pb-5">
<div className="h-16 w-16 rounded-full border-4 border-white bg-zinc-200" />
<h3 className="mt-3 font-semibold text-zinc-900">Jordan Lee</h3>
<p className="text-sm text-zinc-500">Product designer</p>
<div className="mt-4 flex gap-2">
<button className="flex-1 rounded-lg bg-zinc-900 py-2 text-xs font-semibold text-white">Follow</button>
<button className="flex-1 rounded-lg border border-zinc-200 py-2 text-xs font-semibold">Message</button>
</div>
</div>
</div>
);
}
Replace (Your Desired Section) and (YOUR HEX CODE COLOR) before pasting into Cursor, Copilot, or ChatGPT.