BT-09Buttons
Pull Cord
A lamp switch you pull on a swinging cord, built with React and a rope simulation.
no extra packages
PROPay Button and more like it are in Kokonut UI Pro
Installation
Pull Cord is a free, open-source React component in the Kokonut UI Buttons collection. Add it with the shadcn CLI, which copies the source into components/kokonutui/pull-cord.tsx, so the code is yours to change.
npx shadcn@latest add @kokonutui/pull-cordUsage
import PullCord from "@/components/kokonutui/pull-cord";
export default function Example() {
return <PullCord />;
}Props
checkedbooleanControlled state.
defaultCheckedbooleanDefault trueInitial state when uncontrolled.
onCheckedChange(checked: boolean) => voidlabelstringDefault "Desk lamp"Accessible name of the switch.
classNamestringExtra classes for the root element.
Dependencies
| Needs | Version | Comes from |
|---|---|---|
cn from lib/utils.ts | shadcn init | |
| React | 19 | Your app |
| Tailwind CSS | 4 | Your app |
No provider, font or global CSS to set up: the file works as soon as it lands.

