Navigation
Inputs & Forms
Selection
Containers & Overlays
Toggle Button
Starts an action, in different colors, styles and sizes, with optional icons.
Overview
A ToggleButton switches a state on and off, like a checkbox in the shape of a button. Icon and label can change in the active state.
"use client";import {useState} from "react";import {IconEye, IconEyeOff, ToggleButton} from "@brynlabs/fusion-ui";export const ToggleButtonExample = () => {const [active, setActive] = useState(false);return (<ToggleButtonactive={active}onChange={setActive}color={"primary"}primaryIcon={active ? <IconEyeOff /> : <IconEye />}>{active ? "Hide" : "Show"}</ToggleButton>);};
Playground
color
size
import { ToggleButton } from "@brynlabs/fusion-ui"
<ToggleButtonactive={true}color={"primary"}size={"regular"}disabled={false}loading={false}></ToggleButton>

