Feature grid
A section of features: hairline-topped cells with an optional icon in an accent square. Server-component friendly.
Why Pixelbits
A quiet base, with detail where it counts.
Effects on interaction
Hover, focus, open and loading get pixels. Nothing moves at rest.Tiny bundles
One entry per component; Button is about 2 kB.Platform first
Native dialog, popover and form inputs.
demos/feature-grid.tsx
import { FeatureGrid } from "pixelbits/blocks/feature-grid";
const icon = (
<svg
viewBox="0 0 24 24"
fill="none"
stroke="currentColor"
strokeWidth="1.5"
aria-hidden="true"
>
<path d="M4 4h6v6H4zM14 4h6v6h-6zM4 14h6v6H4zM14 14h6v6h-6z" />
</svg>
);
export default function Demo() {
return (
<FeatureGrid
className="py-4 sm:py-4"
title="Why Pixelbits"
description="A quiet base, with detail where it counts."
features={[
{
icon,
title: "Effects on interaction",
description:
"Hover, focus, open and loading get pixels. Nothing moves at rest.",
},
{
icon,
title: "Tiny bundles",
description: "One entry per component; Button is about 2 kB.",
},
{
icon,
title: "Platform first",
description: "Native dialog, popover and form inputs.",
},
]}
/>
);
}Installation
npm: import
import { FeatureGrid } from "pixelbits/feature-grid";shadcn: copy the source
npx shadcn add https://pixelbits.ali-moradi-develop.com/r/block-feature-grid.jsonAPI
<FeatureGrid>
A section of features: hairline-topped cells with an optional icon in an accent square. Server-component friendly.
Example
<FeatureGrid title="Why Pixelbits" features={[{ title: "Tiny", description: "Button is 2 kB." }]} />| Prop | Type | Default | Description |
|---|---|---|---|
| title | ReactNode | — | Section heading (an |
| description | ReactNode | — | Text under the heading. |
| features* | Feature[] | — | The features. |
| columns | 2 | 3 | 4 | 3 | Columns on wide screens (two on tablets, one on phones). |
Also accepts every prop of Omit<HTMLAttributes<HTMLElement>, "title">.