Skip to content
Entangle UI v0.13.0

UseThemeReturn

Defined in: src/hooks/useTheme/useTheme.types.ts:38

getToken: (path) => string

Defined in: src/hooks/useTheme/useTheme.types.ts:52

Resolve a single token to its current CSS-var value, e.g. '#007acc'.

Falls back to the dark-theme default when the underlying CSS variable is unset or when no DOM is available (SSR). Returns an empty string only for paths that don’t resolve to a leaf in the theme contract. Repeated calls for the same path are cached for the life of the hook instance.

string

string


getVar: (path) => string

Defined in: src/hooks/useTheme/useTheme.types.ts:62

Get the var(--etui-...) reference for a token, e.g. 'var(--etui-color-accent-primary)'. Useful for inline styles that must follow theme changes automatically.

SSR-safe — the returned string is constructed from the contract and works identically in browser and server rendering. Returns an empty string only for paths that don’t resolve to a leaf in the contract.

string

string


values: object

Defined in: src/hooks/useTheme/useTheme.types.ts:42

Resolved theme values — CSS variable values read from :root.

borderRadius: object

lg: string = '6px'

md: string = '4px'

none: string = '0px'

sm: string = '2px'

colors: object

accent: object

error: string = '#f44336'

primary: string = '#007acc'

secondary: string = '#005a9e'

success: string = '#4caf50'

warning: string = '#ff9800'

backdrop: string = 'rgba(0, 0, 0, 0.6)'

background: object

elevated: string = '#404040'

inset: string = 'rgba(0, 0, 0, 0.2)'

primary: string = '#1a1a1a'

secondary: string = '#2d2d2d'

tertiary: string = '#3a3a3a'

border: object

default: string = '#4a4a4a'

error: string = '#f44336'

focus: string = '#007acc'

success: string = '#4caf50'

surface: object

active: string = '#404040'

default: string = '#2d2d2d'

disabled: string = '#1f1f1f'

hover: string = '#363636'

row: string = 'transparent'

rowHover: string = 'rgba(255, 255, 255, 0.03)'

whiteOverlay: string = 'rgba(255, 255, 255, 0.1)'

text: object

disabled: string = '#555555'

muted: string = '#888888'

primary: string = '#ffffff'

secondary: string = '#cccccc'

demo: object

canvas: object

gradientEnd: string = '#091010'

gradientMid: string = '#031a1a'

gradientStart: string = '#061f21'

shadows: object

focus: string = '0 0 0 2px rgba(0, 122, 204, 0.4)'

lg: string = '0 4px 8px rgba(0, 0, 0, 0.4)'

md: string = '0 2px 4px rgba(0, 0, 0, 0.3)'

separatorBottom: string = '0 1px 2px rgba(0, 0, 0, 0.18)'

separatorLeft: string = '-1px 0 2px rgba(0, 0, 0, 0.18)'

separatorRight: string = '1px 0 2px rgba(0, 0, 0, 0.18)'

sm: string = '0 1px 2px rgba(0, 0, 0, 0.2)'

thumb: string = '0 0 2px rgba(0, 0, 0, 0.5)'

xl: string = '0 8px 16px rgba(0, 0, 0, 0.5)'

shell: object

dock: object

borderBarBg: string = '#2d2d2d'

borderBarSize: string = '28px'

dropOverlay: string = 'rgba(0, 122, 204, 0.2)'

splitterColor: string = '#4a4a4a'

splitterHoverColor: string = '#007acc'

splitterSize: string = '4px'

tabActiveBg: string = '#1a1a1a'

tabActiveText: string = '#ffffff'

tabBg: string = '#2d2d2d'

tabHeight: string = '28px'

tabHoverBg: string = '#363636'

tabText: string = '#cccccc'

menuBar: object

activeBg: string = '#005a9e'

bg: string = '#2d2d2d'

height: string = '28px'

hoverBg: string = '#363636'

shortcutText: string = '#888888'

text: string = '#ffffff'

statusBar: object

bg: string = '#007acc'

height: string = '22px'

heightMd: string = '26px'

text: string = '#ffffff'

toolbar: object

bg: string = '#2d2d2d'

height: object

md: string = '40px'

sm: string = '32px'

separator: string = '#4a4a4a'

spacing: object

lg: string = '12px'

md: string = '8px'

sm: string = '4px'

xl: string = '16px'

xs: string = '2px'

xxl: string = '24px'

xxxl: string = '32px'

transitions: object

fast: string = '100ms ease-out'

normal: string = '200ms ease-out'

slow: string = '300ms ease-out'

typography: object

fontFamily: object

mono: string = 'SF Mono, Monaco, Consolas, "Liberation Mono", "Courier New", monospace'

sans: string = '-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif'

fontSize: object

lg: string = '14px'

md: string = '12px'

sm: string = '11px'

xl: string = '16px'

xs: string = '10px'

xxs: string = '9px'

fontWeight: object

medium: string = '500'

normal: string = '400'

semibold: string = '600'

lineHeight: object

normal: string = '1.4'

relaxed: string = '1.6'

tight: string = '1.2'

zIndex: object

base: string = '1'

dropdown: string = '1000'

modal: string = '1100'

popover: string = '1000'

tooltip: string = '1000'


variant: ThemeVariant

Defined in: src/hooks/useTheme/useTheme.types.ts:40

Current root-theme variant. See ThemeVariant for detection rules.