Watchful Eye Toggle
A soft eye opens and closes; the pupil tracks when open.
Try it: Click or press Space — lids open/close; move to track.
Installation
Install with the shadcn CLI:
npx shadcn@latest add https://www.framekitui.live/r/watchful-eye-toggle.jsonOr, with the @framekit namespace registered: npx shadcn@latest add @framekit/watchful-eye-toggle. You can also copy the source into components/ui/watchful-eye-toggle.tsx (view on GitHub).
Usage
import { WatchfulEyeToggle } from '@/components/ui/watchful-eye-toggle'Props
| Prop | Type | Default | Notes |
|---|---|---|---|
checked | boolean | — | Controlled on/off state. |
defaultChecked | boolean | false | Uncontrolled initial state. |
onCheckedChange | (checked: boolean) => void | — | Fires when the value flips. |
disabled | boolean | false | Disables pointer and keyboard. |
Related Toggles components
- Day Night Capsule
Illustrated mini sky that morphs day↔night.
- Pull-Cord Lamp Toggle
A pendant lamp switched by its pull cord: drag the bead down until it clicks, the cord snaps back elastically and sways, the shade rocks on its wire and the bulb warms into a cone of light with…
- Glass Orb Switch
Translucent glass sphere slides on a dark track.
- Theme Reveal Toggle
A sky-to-night switch: the sun rolls behind a crescent, clouds give way to stars, and the theme change blooms out of the switch as a circular View Transition reveal. Instant swap under reduced motion.
- Cosmic Sparkle Toggle
OFF/ON pill with a glowing star badge and halo.
- Weather Vane Toggle
Vane pivots; grain shifts with wind.