Components

Toggle ​

Toggles represent a binary pressed or unpressed state and are especially useful in formatting toolbars and compact setting controls.

Basic Usage ​

A single toggle works well for compact on or off actions with a clear visual pressed state.

Variants ​

Use visual variants to fit the same interaction into different toolbar hierarchies.

Sizes ​

Size changes help the same toggle fit both dense and prominent control rows.

Pressed ​

Pressed examples make it clear how the control should behave when selected.

Disabled ​

Disabled examples show how the control should read when unavailable.

API ​

Slots ​

NameDescription
(default)Button label or icon content

Props ​

NameDescription
ariaLabelType string | null
Default null
disabledType boolean
Default false
pressedType boolean
Default false
sizeType PkToggleSize
Default default
valueType string
variantType PkToggleVariant
Default default

Events ​

NameDescription
onChange—
onPkPressedChange—

CSS Parts ​

NameDescriptionCSS selector
baseToggle button element::part(base)
Edit this page
Last updated: Sep 9, 2026, 7:18 PM