ChromeButton

Get this button for GPUI

A metallic pill whose border is a ring of flowing liquid chrome around a solid face that follows the light or dark theme, with pill, compact, and icon sizes.

Preview

Continue

Props

Install

npx shadcn@latest add @evilbuttons/chrome-button

Usage

import { ChromeButton } from "@/components/evil-buttons/chrome-button";

export function ButtonDemo() {
  return <ChromeButton onClick={() => console.log("Continue")}>Continue</ChromeButton>;
}

Props

The component spreads native button props and forwards its ref.

PropTypeDefaultDescription
childrenReact.ReactNode-Face content: label and icons. Falls back to label.
labelReact.ReactNode"Continue"Label used when no children are provided.
tone"auto" | "dark" | "light""auto"auto follows the theme: white face normally, dark face inside a .dark ancestor (shadcn's convention). dark and light force one.
size"default" | "sm" | "icon""default"Pill, compact pill, or a round icon-only button. Give icon buttons an aria-label.
speednumber1Speed multiplier for the metal flowing around the ring.
interactivebooleantrueSwirl the metal around the pointer and speed it up on hover, and send a shock front through it on press.
classNamestring-Extra classes merged onto the outer ring.

Good to know

  • Self-contained WebGL, no extra dependencies.
  • Only animates while on screen and the tab is visible.

Search docs

Jump to a button documentation page