Component

Switch

A toggle switch control with Neo-Brutalism styling.

Preview

Installation

pnpm dlx brutx@latest add switch

Usage

import { Switch } from "@/components/ui/switch"
import { Label } from "@/components/ui/label"

const [enabled, setEnabled] = React.useState(false);

<div className="flex items-center gap-3">
  <Switch
    id="setting"
    checked={enabled}
    onCheckedChange={setEnabled}
  />
  <Label htmlFor="setting">Enable Feature</Label>
</div>

Disabled State