A modern, animated React component that displays content in a bento-style grid of cards with parallax pointer motion and full customization. Perfect for dashboards, feature highlights, marketing, and beautiful layouts.
Inspired by modern bento grid layouts in leading UIs.
You can install the BentoGrid component with the following CLI command, or copy the implementation manually:
1npx shadcn@latest add http://localhost:3000/r/bento-grid.jsonTo use the BentoGrid component, import it in your code:
1import BentoGrid from '@/components/BentoGrid';The BentoGrid component does not accept any props. All grid items and their layout are defined directly inside the component source itself; you can edit or replace the gridItems array in the component file to customize content or layout.
| Prop | Type | Default | Description | Required |
|---|---|---|---|---|
— | — | — | All bento items and layout are defined in the gridItems array (see source). | — |
1const gridItems = [
2 {
3 className: "...", // Tailwind, span, and responsive classes
4 heading: "Heading text...",
5 desc: "Description for this grid cell.",
6 },
7 // ...add or change items!
8];1<BentoGrid />To create your own items or layout, just amend or replace the gridItems array in your BentoGrid source file.
hr className="border-0 border-t border-dotted border-neutral-200 dark:border-neutral-800 my-6" />
className.dark: variants for instant adaptation.<BentoGrid /> anywhere, with no props required.grid-cols-3/grid-rows-2 on the root grid for more or fewer cells.MAX_OFFSET, spring stiffness, or damping for a more/less lively effect.gridItems entry can have any React node—swap titles, rich content, actions, or even nested layouts.motion.dev installed and properly imported..col-span/.row-span classes match.gridItems in the source code as needed to change displayed content and layout.