Skip to content

UtilityThemeSwitcher ​

Light, dark or system theme, written as data-theme on the page and remembered.

ts
import { UtilityThemeSwitcher } from '@zairakai/vue-components/Utility'

Usage ​

vue
<UtilityThemeSwitcher />

Props ​

NameTypeDefaultDescription
idstring
classstring
modelValuestringundefined"light", "dark" or "system".
storageKeystring'zk-theme'Where the choice is remembered. Empty for nowhere.
attributestring'data-theme'Where the theme is written, as the data-theme attribute. The page itself by default.
modesarray['light', 'dark', 'system']
labelsobject{ light: 'Light', dark: 'Dark', system: 'System' }
labelstring'Theme'

Events ​

NameDescription
update:modelValue
change

Slots ​

NameDescription
mode

See Theming for the class hooks and the data-* state of the components.

Documentation of 1.4.4 , built from 8e9b054 on 1.4.4 by pipeline #2989941079 on 2026-10-26.