Overview
UI components are the building blocks of the portfolio. They’re located insrc/components/ui/ and provide consistent styling across the site.
Button
A versatile button component with multiple variants and sizes.Props
Button style variant:
"primary"- Red gradient background"secondary"- White background with border"outline"- Red border with transparent background"ghost"- No background, text only
Button size:
"sm"- Small (px-4 py-2)"md"- Medium (px-6 py-3)"lg"- Large (px-8 py-4)"xl"- Extra large (px-10 py-5)
If provided, renders as an
<a> tag instead of <button>Link target (only used when
href is provided)Additional CSS classes
Usage
Styling
Buttons include:- Rounded corners (
rounded-full) - Scale animation on hover (
hover:scale-105) - Smooth transitions (300ms)
- Shadow effects
Badge
Small labels for displaying categories, tags, or status.Props
Badge color variant:
"primary"- Red badge"secondary"- Gray badge"success"- Green badge"warning"- Orange badge"danger"- Red badge
Badge size:
"xs"- Extra small"sm"- Small"md"- Medium
Additional CSS classes
Usage
Styling
Badges feature:- Rounded pill shape (
rounded-full) - Medium font weight
- Compact padding
- Background and text color coordination
Card
A flexible container component with hover effects.Props
If provided, renders as clickable link
Link target (only used when
href is provided)Card style variant:
"default"- White background with shadow"flat"- White background with border
Additional CSS classes
Usage
Features
- Lift animation on hover (
hover:-translate-y-1) - Shadow enhancement on hover
- Smooth transitions (300ms)
- Rounded corners (
rounded-2xl)
Icon
Wrapper for Iconify icons with consistent sizing.Props
Iconify icon name (e.g.,
"mdi:github", "mdi:arrow-right")Icon size in pixels
Additional CSS classes
Usage
Icon Libraries
The portfolio uses Material Design Icons (MDI) via Iconify:- Browse icons at Iconify Icon Sets
- Prefix:
mdi:(e.g.,mdi:github,mdi:calendar)
Section
A full-width section container with consistent spacing.Props
Background color class (e.g.,
"bg-white", "bg-red-50", "bg-gradient-to-r from-red-500 to-red-700")Vertical padding class
Additional CSS classes
Usage
Features
- Automatic container with max-width
- Horizontal padding (
px-4) - Centered content
- Full-width backgrounds
SectionHeader
A centered section title with optional subtitle.Props
Section title
Optional subtitle text
Additional CSS classes
Usage
Styling
- Centered text alignment
- Large title (4xl-5xl responsive)
- Red color for title (
text-red-700) - Gray subtitle (
text-gray-600) - Max-width subtitle (2xl)
- Bottom margin (
mb-16)
StatCard
Displays a statistic with an icon, value, and label.Props
Iconify icon name
The statistic value (e.g., “50+”, “1000”)
Description of the statistic
Usage
Features
- Circular icon background with gradient
- Large value display
- Hover shadow effect
- Centered layout
Timeline
Displays items in a vertical timeline with a gradient line.Props
Array of timeline items
Usage
Features
- Gradient timeline line (blue to pink)
- Circular markers at each item
- Named slot for custom item rendering
- Responsive spacing
Common Patterns
Combining Components
Related Components
Card Components
Specialized cards using these UI primitives
Sections
Full-page section components
