127+ Primitives

Grid Card

Cards

Interactive feature card and section featuring a top-right flickering canvas grid corner accent with diagonal mask fading, spring hover physics, icon scale/rotation variants, and dynamic hover-accelerated flicker rates.

CanvasFramer MotionHover VariantsA11y Ready
/r/grid-card.json

Installation

Install directly into your project using the shadcn CLI or copy the source code manually.

Requires:framer-motionlucide-reactclsxtailwind-merge
$npx shadcn@latest add "https://boseui.site/r/grid-card.json"

Props

TypeScript props supported by <GridCard />.

10 props
PropTypeDefaultDescription
iconReact.ReactNodeundefinedIcon element rendered in the soft-bordered top container.
titlestringundefinedMain feature card title.
descriptionstringundefinedExplanatory descriptive text.
hrefstringundefinedOptional target link destination rendering the card as an interactive link.
gridColorstring"currentColor"Color string for the flickering grid corner squares.
squareSizenumber3Dimension of each square cell in the flickering grid.
gridGapnumber5Spacing between adjacent grid squares in pixels.
restFlickerChancenumber0.1Flickering rate when card is at rest.
hoverFlickerChancenumber0.6Flickering rate when card is hovered.
classNamestringundefinedAdditional Tailwind CSS classes merged into the card.

Key Features

  • Top-right diagonal corner accent powered by FlickeringGrid with linear-gradient alpha mask clipping.
  • Interactive hover physics: on hover, flickerChance ramps up from 0.1 to 0.6 and maxOpacity increases from 0.15 to 0.4.
  • Parent-child hover variant system: icon container scales to 1.1 with slight rotation while link arrow shifts 4px to the right.
  • Responsive FeatureSection layout: 1 column on mobile, 2 on md, 3 on lg with staggerChildren entrance animations.
  • Accessible link semantics: renders as an accessible interactive card when href is provided, complete with focus-visible rings.

Keyboard & Accessibility

  • Decorative canvas marked pointer-events-none and aria-hidden='true'.
  • Keyboard accessible with focus-visible ring when href is supplied.
  • Respects prefers-reduced-motion media query by bypassing spring transforms.