"use client"
import { Description } from "@/components/ui/field"
import { Switch, SwitchLabel } from "@/components/ui/switch"
export default function SwitchUncontrolledDemo() {
return (
<Switch defaultSelected>
{({ isSelected }) => (
<>
<SwitchLabel>Dark mode</SwitchLabel>
<Description>Dark mode is {isSelected ? "enabled" : "disabled"}.</Description>
</>
)}
</Switch>
)
}
npx shadcn@latest add @intentui/switch-uncontrolled-demoUsage varies by registry entry. Refer to the registry docs or source files below for details.