Installation

Fabric Kit components are copied into your project with the shadcn CLI, so the code is yours to read and change. They need React 19, and work with the Next.js App Router, Vite, or anything else that lets a component import its own .css file (the Next.js Pages Router doesn't). They take your app's font; they're designed with Geist.

1. Set up shadcn (once)

If your project doesn't have a components.json yet:

Terminal
npx shadcn@latest init

2. Add the theme (once)

Every colour, radius, focus ring and curve Fabric Kit uses, as --fabric-* variables. They're prefixed, so they never clash with your own theme. The CLI adds them to your global CSS.

Terminal
npx shadcn@latest add https://fabrickit.org/r/theme.json

3. Add components

Each component page has its command. For example:

Terminal
npx shadcn@latest add https://fabrickit.org/r/goo-slider.json

Light and dark

Components are dark by default. For light, put data-theme="light" on <html>, or on any element: everything inside it follows, and data-theme="dark" turns a part back. Switch it whenever you like; the components redraw in the new colours, the canvas effects included.

app/layout.tsx
<html data-theme="light">

Using next-themes? Have it set the attribute (not a class), with dark first:

app/layout.tsx
<ThemeProvider attribute="data-theme" defaultTheme="dark" themes={["dark", "light"]}>
  {children}
</ThemeProvider>

Optional: the @fabrickit name

Add the registry to your components.json and you can install by name, like npx shadcn@latest add @fabrickit/goo-slider.

components.json
{
  "registries": {
    "@fabrickit": "https://fabrickit.org/r/{name}.json"
  }
}