CardGrid. A deterministic grid of related navigation cards.
- Article structure
- Static
- Stability · Initial
- ::postkit-card-grid
Explore Postkit
Choose the path that matches your publishing workflow.
Usage.
<CardGrid
title="Explore Postkit"
description="Choose the path that matches your publishing workflow."
columns="3"
items='[{"title":"Author content","description":"Markdown, MDX, and portable documents.","href":"#component-preview"},{"title":"Compose a theme","description":"Inherit from Chakra and override by recipe.","href":"#component-preview"},{"title":"Ship anywhere","description":"Use the adapter for your preferred framework.","href":"#component-preview"}]'
/>Props. Always in step with the code.
| Prop | Type | Default | Description |
|---|---|---|---|
| itemsRequired | JSON string | None | A JSON array of titled cards. |
| title | string | None | The grid heading. |
| description | string | None | Supporting copy for the grid. |
| columns | "1" | "2" | "3" | "4" | "2" | The preferred desktop column count. |
| Appearance | |||
| size | "sm" | "md" | "lg" | "md" | The component density and type scale. |
| variant | "outline" | "subtle" | "plain" | "subtle" | The component visual treatment. |
Every component also takes unstyled and the part-styling props. Change a default for your whole site with defaults in createPostkit. Part styles
Anatomy. Every part is yours to restyle.
Every part
- root
- header
- title
- description
- grid
- card
- image
- cardBody
- cardTitle
- cardDescription
- meta
- link
Renderers. One component, everywhere you publish.
- Headless @postkit/reactSupported
- Chakra @postkit/chakraSupported
- Email @postkit/emailAs text
- Astro @postkit/astroStatic
- Web components @postkit/elementsPlanned