Blog Card

Blog post card with two layouts: a full desktop card and a compact mobile tile. Used by BlogGrid on both the /blog page and blog-related sections.

Card layout (desktop)

Tile layout (mobile)

Two-up grid

Props

PropTypeDefaultDescription
post*BlogPost-Blog post data (matches the Sanity blogPost type).
layout"card" | "tile""card""card" renders the full desktop card with large image; "tile" is the compact mobile layout with a square thumbnail.
indexnumber0Position in the list — drives the staggered fade-in delay (index * 0.1s for card, index * 0.08s for tile).
classNamestring-Additional classes merged onto the outer article. Used to set column width in grids.

Import

tsx
import { BlogCard } from '@/components/ui/BlogCard'

Usage

tsx
{/* Desktop grid */}
<BlogCard post={post} index={index} />

{/* Mobile tiles */}
<BlogCard post={post} layout="tile" index={index} />