EvilEyeButton

An obsidian pill with a burning evil eye behind its label that tracks the cursor across the page, focuses on hover, and blinks.

Preview

I see you

Props

Install

npx shadcn@latest add @evilbuttons/evil-eye-button

Usage

import { EvilEyeButton } from "@/components/evil-buttons/evil-eye-button";

export function ButtonDemo() {
  return <EvilEyeButton eyeColor="#38bdf8">I see you</EvilEyeButton>;
}

Props

The component spreads native button props and forwards its ref. Every eye prop updates live without rebuilding the shader.

PropTypeDefaultDescription
childrenReact.ReactNode-Button label. Falls back to label.
labelReact.ReactNode"I see you"Label used when no children are provided.
eyeColorstring"#ff6f37"Iris, glow, and hairline color, as hex.
intensitynumber1.3Brightness of the flames.
pupilSizenumber0.62Size of the slit pupil. Lower values make it tighter.
irisWidthnumber0.22Width of the iris ring.
glowIntensitynumber0.5Strength of the glow around the iris.
scalenumber1.7Size of the eye in the button. Higher values spread the flames wider.
noiseScalenumber0.8Scale of the flame noise.
pupilFollownumber0.8How far the pupil tracks the cursor, 0 to 1.
flameSpeednumber0.8Speed of the flames.
blinkbooleantrueBlink every few seconds on its own. It always blinks on press.
eyeClassNamestring-Extra classes for the eye layer behind the label.
labelClassNamestring-Extra classes for the label.
classNamestring-Extra classes merged onto the button.

Good to know

  • Self-contained WebGL, ported from React Bits' EvilEye.
  • The pupil follows the cursor across the whole page.

Search docs

Jump to a button documentation page