Keyframery

Install Keyframery by hand

Add Keyframery's animated UI SDK components to any React 19 and Tailwind CSS v4 app without the shadcn CLI: dependencies, motion tokens, helpers and files.

Keyframery's components are plain files. The CLI copies them and adds a block of CSS; this page does the same by hand. It works in any React 19 app with Tailwind CSS v4.

Set up Tailwind CSS and shadcn's theme

The components use shadcn's colour variables (--background, --primary, --muted and the rest), a cn helper in lib/utils.ts and the @/ import alias. If your app doesn't have them yet, follow shadcn's manual installation first.

Add the dependencies

npm install @ui-sdk/[email protected] @ui-sdk/[email protected] clsx tailwind-merge

UI SDK is pinned to the version the components are tested with.

Add the motion tokens

Paste this whole block into your global stylesheet, below @import "tailwindcss";. It's exactly what the CLI adds.

@layer base {
  :root {
    --kf-speed: 1;
    --ease-house: cubic-bezier(0.22, 1, 0.36, 1);
    --ease-spring: linear(0, 0.001 0.5%, 0.010 1.5%, 0.036 2.8%, 0.082 4.4%, 0.153 6.3%, 0.247 8.5%, 0.358 10.9%, 0.480 13.5%, 0.604 16.3%, 0.721 19.3%, 0.825 22.4%, 0.911 25.8%, 0.976 29.3%, 1.019 33.0%, 1.044 36.8%, 1.054 40.8%, 1.052 45.0%, 1.044 49.3%, 1.033 53.8%, 1.022 58.4%, 1.012 63.1%, 1.005 68.0%, 1.000 73.0%, 0.998 78.1%, 0.997 83.4%, 0.997 88.8%, 0.998 94.3%, 1);
    --ease-pop: linear(0, 0.002 0.5%, 0.019 1.5%, 0.066 2.8%, 0.150 4.4%, 0.276 6.3%, 0.435 8.5%, 0.612 10.9%, 0.789 13.5%, 0.945 16.3%, 1.064 19.3%, 1.136 22.4%, 1.163 25.8%, 1.151 29.3%, 1.114 33.0%, 1.067 36.8%, 1.023 40.8%, 0.992 45.0%, 0.976 49.3%, 0.974 53.8%, 0.980 58.4%, 0.989 63.1%, 0.997 68.0%, 1.003 73.0%, 1.004 78.1%, 1.004 83.4%, 1.002 88.8%, 1.000 94.3%, 1);
  }
  [data-motion="springy"] {
    --kf-speed: 1;
    --ease-spring: linear(0, 0.001 0.5%, 0.010 1.5%, 0.036 2.8%, 0.082 4.4%, 0.153 6.3%, 0.247 8.5%, 0.358 10.9%, 0.480 13.5%, 0.604 16.3%, 0.721 19.3%, 0.825 22.4%, 0.911 25.8%, 0.976 29.3%, 1.019 33.0%, 1.044 36.8%, 1.054 40.8%, 1.052 45.0%, 1.044 49.3%, 1.033 53.8%, 1.022 58.4%, 1.012 63.1%, 1.005 68.0%, 1.000 73.0%, 0.998 78.1%, 0.997 83.4%, 0.997 88.8%, 0.998 94.3%, 1);
    --ease-pop: linear(0, 0.002 0.5%, 0.019 1.5%, 0.066 2.8%, 0.150 4.4%, 0.276 6.3%, 0.435 8.5%, 0.612 10.9%, 0.789 13.5%, 0.945 16.3%, 1.064 19.3%, 1.136 22.4%, 1.163 25.8%, 1.151 29.3%, 1.114 33.0%, 1.067 36.8%, 1.023 40.8%, 0.992 45.0%, 0.976 49.3%, 0.974 53.8%, 0.980 58.4%, 0.989 63.1%, 0.997 68.0%, 1.003 73.0%, 1.004 78.1%, 1.004 83.4%, 1.002 88.8%, 1.000 94.3%, 1);
  }
  [data-motion="calm"] {
    --kf-speed: 1.35;
    --ease-spring: linear(0, 0.001 0.5%, 0.007 1.5%, 0.024 2.8%, 0.055 4.4%, 0.102 6.4%, 0.163 8.5%, 0.235 10.9%, 0.316 13.5%, 0.400 16.3%, 0.484 19.3%, 0.565 22.4%, 0.641 25.8%, 0.708 29.3%, 0.767 33.0%, 0.818 36.8%, 0.859 40.8%, 0.893 45.0%, 0.920 49.3%, 0.941 53.8%, 0.957 58.4%, 0.970 63.1%, 0.979 68.0%, 0.985 73.0%, 0.990 78.1%, 0.993 83.4%, 0.995 88.8%, 0.997 94.3%, 1);
    --ease-pop: linear(0, 0.001 0.5%, 0.006 1.5%, 0.022 2.8%, 0.052 4.4%, 0.099 6.4%, 0.161 8.5%, 0.237 10.9%, 0.325 13.5%, 0.419 16.3%, 0.515 19.3%, 0.609 22.4%, 0.697 25.8%, 0.775 29.3%, 0.841 33.0%, 0.896 36.8%, 0.938 40.8%, 0.970 45.0%, 0.991 49.3%, 1.005 53.8%, 1.012 58.4%, 1.015 63.1%, 1.015 68.0%, 1.013 73.0%, 1.011 78.1%, 1.008 83.4%, 1.005 88.8%, 1.003 94.3%, 1);
  }
  [data-motion="snappy"] {
    --kf-speed: 0.6;
    --ease-spring: linear(0, 0.001 0.5%, 0.007 1.5%, 0.022 2.8%, 0.052 4.4%, 0.098 6.4%, 0.159 8.5%, 0.234 10.9%, 0.319 13.5%, 0.410 16.3%, 0.502 19.3%, 0.592 22.4%, 0.676 25.8%, 0.752 29.3%, 0.816 33.0%, 0.870 36.8%, 0.913 40.8%, 0.946 45.0%, 0.969 49.3%, 0.986 53.8%, 0.996 58.4%, 1.002 63.1%, 1.005 68.0%, 1.006 73.0%, 1.006 78.1%, 1.005 83.4%, 1.004 88.8%, 1.003 94.3%, 1);
    --ease-pop: linear(0, 0.001 0.5%, 0.009 1.5%, 0.032 2.8%, 0.074 4.4%, 0.139 6.4%, 0.225 8.5%, 0.329 10.9%, 0.445 13.5%, 0.564 16.3%, 0.681 19.3%, 0.787 22.4%, 0.877 25.8%, 0.948 29.3%, 1.000 33.0%, 1.033 36.8%, 1.050 40.8%, 1.054 45.0%, 1.050 49.3%, 1.041 53.8%, 1.030 58.4%, 1.019 63.1%, 1.010 68.0%, 1.004 73.0%, 1.000 78.1%, 0.998 83.4%, 0.997 88.8%, 0.997 94.3%, 1);
  }
  [data-motion="playful"] {
    --kf-speed: 1.15;
    --ease-spring: linear(0, 0.001 0.5%, 0.010 1.5%, 0.033 2.8%, 0.079 4.4%, 0.149 6.4%, 0.243 8.5%, 0.359 10.9%, 0.489 13.5%, 0.624 16.3%, 0.756 19.3%, 0.875 22.4%, 0.974 25.8%, 1.047 29.3%, 1.095 33.0%, 1.117 36.8%, 1.118 40.8%, 1.104 45.0%, 1.080 49.3%, 1.054 53.8%, 1.029 58.4%, 1.009 63.1%, 0.995 68.0%, 0.988 73.0%, 0.986 78.1%, 0.987 83.4%, 0.991 88.8%, 0.995 94.3%, 1);
    --ease-pop: linear(0, 0.003 0.5%, 0.023 1.5%, 0.080 2.8%, 0.185 4.4%, 0.341 6.4%, 0.539 8.5%, 0.757 10.9%, 0.968 13.5%, 1.140 16.3%, 1.250 19.3%, 1.286 22.4%, 1.255 25.8%, 1.176 29.3%, 1.078 33.0%, 0.991 36.8%, 0.935 40.8%, 0.918 45.0%, 0.933 49.3%, 0.965 53.8%, 0.997 58.4%, 1.018 63.1%, 1.023 68.0%, 1.017 73.0%, 1.006 78.1%, 0.997 83.4%, 0.993 88.8%, 0.995 94.3%, 1);
  }
}

@utility ease-house {
  transition-timing-function: var(--ease-house);
}

@utility ease-spring {
  transition-timing-function: var(--ease-spring);
}

@utility ease-pop {
  transition-timing-function: var(--ease-pop);
}

Add the shared helpers

Every component imports its speed prop and KeyframeryProvider from this file. Save it as lib/keyframery.tsx.

Copy the components

Every component page has a Manual tab with its files: the styled component, its primitive and, for some, a core file. Copy them to the paths shown, under components/keyframery/.

components/keyframery/tabs.tsx
components/keyframery/primitives/tabs.tsx

If your aliases differ from @/components and @/lib, change the imports at the top of each file.

Add a preset (optional)

Build one at Keyframery Create and press Copy CSS. Paste it into your global stylesheet after the motion tokens. If the preset uses a font, install it from Fontsource as the copied CSS says, for example:

npm install @fontsource-variable/inter
@import "@fontsource-variable/inter";

That's it

Import a component and use it:

import { Tabs, TabsList, TabsPanel, TabsPanels, TabsTab } from "@/components/keyframery/tabs"

Something not moving? Check that the motion tokens are in the stylesheet your app loads. More in Troubleshooting.

Questions

When should I install by hand?

When your app can't use the shadcn CLI, or you want to see every line before it lands. The result is the same files and CSS the CLI writes.

Can I use a preset without the CLI?

Yes. On Keyframery Create, Copy CSS gives you the preset as plain CSS to paste into your global stylesheet.

On this page