Skip to content
Control Components

Checkbox

A checkbox.

Wraps Tweakpane's boolean input binding.

Usage outside of a <Pane> component will implicitly wrap the checkbox in <Pane position="inline">.


Enabled: false
CheckboxExample.svelte
<script lang="ts">
import { Checkbox } from 'svelte-tweakpane-ui'
let reticulationEnabled: boolean = false
</script>
<Checkbox bind:value={reticulationEnabled} label="Reticulation" />
<pre>Enabled: {reticulationEnabled}</pre>

optional
Description

Prevent interactivity and gray out the control.

Typeboolean
Defaultfalse
optional
Description

Text displayed next to control.

Typestring
Defaultundefined
optional
Description

Custom color scheme.

TypeTheme
Defaultundefined
Inherits default Tweakpane theme equivalent to ThemeUtils.presets.standard, or the theme set with setGlobalDefaultTheme().
bindablerequired
Description

The value to control.

Typeboolean

Description

Fires when value changes.

This event is provided for advanced use cases. It's usually preferred to bind to the value prop instead.

The event.details payload includes a copy of the value and an origin field to distinguish between user-interactive changes (internal) and changes resulting from programmatic manipulation of the value (external).

ExtendsValueChangeEvent
TypeCheckboxChangeEvent