Button

Button is a neobrutalist React component from Cruise UI. The core action: a thick ink border and a hard shadow it drops into when pressed. Install it with npx shadcn@latest add @cruiseui/button.

Install

Terminal

npx shadcn@latest add @cruiseui/button

First time? Installation shows the one-off components.json setup (the @cruiseui registry) and how to turn the theme on.

Example

Corners

When to use it

When to use

Any action people take: submit a form, open a dialog, go to the next step.

When not to

Moving to another page in running text (use a link). Picking one of a few views (use a Button group).

Props

CruiseButton

PropTypeDefaultDescription
variant?CruiseButtonVariant"primary"—
size?CruiseButtonSize——

Also takes every native <button> attribute.

CruiseButtonGroup

PropTypeDefaultDescription
childrenReactNode——
align?"start" | "end""start"—
className?string——

Accessibility

  • A real <button> (or an <a> for links via cruiseButtonClasses), so Enter and Space work.
  • Visible 3px focus outline; at least 44px tall.
  • Disabled buttons keep their label and use the disabled style, not just a faded colour.