Toggle Sidebar B
header.lightDarkMode D

Table Switch

Switch sized for use inside TableData rows. Tracks state in a shared useState keyed by itemId + statusKey so multiple instances on the same page stay in sync.

Default

Drop into a row cell. itemId is required so each row has its own state.

API Reference

Props, events, and slots for each sub-component.

TableSwitch

Props

PropTypeDefaultDescription
modelValuebooleanChecked state. Supports v-model.
itemIdstring | numberRequired. Stable id of the row. Used as part of the shared-state key.
statusKeystring"default"Namespace for the shared state. Use one per status column when you have multiple toggles per row.
disabledbooleanfalseDisable input.

Events

EventDescription
update:modelValueFires with the new checked state. Enables v-model.