Theme

Color mode (light / dark / auto).

Access:

app.theme
app.getModule('theme')
app.invoke('theme.method', …)

set#

Sets color theme mode and applies it to host/document.

Parameters:

  • theme (string) — color mode (auto, light, dark)
app.theme.set('dark');

get#

Returns resolved current color theme (light/dark).

Returns: string

app.theme.get();

syncElement#

Applies the current rx-data-theme attribute to an element (for floating UI outside the main container).

Parameters:

  • el (HTMLElement | string) — DOM element
app.theme.syncElement(panelEl);