Usage
Describe the section and where it goes:
/shadcnpro-create-block A pricing section with a usage slider: the price updates as you drag from 1,000 to 100,000 tracked hours. It goes under the hero on /pricing.The agent searches the blocks first. If one is close, it installs and adapts it, which is usually less work than a new one. If nothing fits, it writes the section and tells you why no block did.
What the skill does
- Searches the registry for a block that already does the job.
- Reads your project: the UI library, the icon library and the components you have.
- Reads two installed blocks in full, one from the same family and one with a similar layout, as its reference for spacing, heading sizes and code style.
- Opens every component it plans to use and checks its exports and props.
- Writes one file,
components/blocks/<name>.tsx. - Checks it: types, lint, a search for hard-coded styling, then the block in the browser next to an installed one, and by keyboard.
What makes it match
A visitor shouldn't be able to tell which sections you installed and which one the agent wrote. So the new block follows the conventions of the others:
- The same anatomy. A full-width
<section>that owns its vertical padding, with a centered container that sets the width. - Theme tokens only.
bg-background,text-muted-foreground,border-borderand the radius and shadow scale. Nobg-white, no gray scales, no hex values. That is what makes a block follow your brand and dark mode without a singledark:class. - Content at the top. Text and lists sit in typed constants at the top of the file, and the markup maps over them.
- Mobile first, then
sm:andmd:for wider screens. - Accessible. Headings in order, labels on inputs,
alttext on images, and a focus ring on everything you can click. - Your content. No lorem ipsum, and no invented customers or numbers.
If a design needs a color your theme doesn't have, the agent adds a token to your stylesheet instead of hard-coding the color.
Written for your UI library
shadcn/ui builds on Radix UI, Base UI or React Aria, and they differ in details:
| Radix UI | Base UI | React Aria | |
|---|---|---|---|
| A button that is a link | asChild | buttonVariants() on the link | LinkButton |
| A custom trigger | asChild | render | Nested trigger |
| Button events | onClick | onClick | onPress |
The skill writes for the library in your components.json, and the component files in your project decide the details.
Where the file goes
New blocks sit next to the installed ones in components/blocks/, named by what they do, such as pricing-usage-slider.tsx. The name has no number, so it can never collide with a block from the registry.
The agent imports only what your project already has, and asks before it adds a package.
Related skills
/shadcnpro-choose-blocksfinds the block that may already exist./shadcnpro-create-pagebuilds whole pages from blocks./shadcnpro-generate-codewrites a section from a Figma frame instead of a description.