Download webui/src/components/ui/Switch.tsx from xjackkx/rg: direct link, hf CLI and curl.
- Browser
- Download file 387 Bytes
-
https://huggingface.co/spaces/xjackkx/rg/resolve/main/webui/src/components/ui/Switch.tsx
- Command line
-
hf download hf://spaces/xjackkx/rg/webui/src/components/ui/Switch.tsx
-
curl -L -o Switch.tsx https://huggingface.co/spaces/xjackkx/rg/resolve/main/webui/src/components/ui/Switch.tsx
387 Bytes
| import type { ComponentProps } from "react"; | |
| import "./Switch.css"; | |
| type SwitchProps = Omit<ComponentProps<"input">, "type" | "className">; | |
| export function Switch(props: SwitchProps) { | |
| return ( | |
| <label className="switch"> | |
| <input type="checkbox" className="switch-input" {...props} /> | |
| <span className="switch-slider"></span> | |
| </label> | |
| ); | |
| } | |