Skip to main content
Version: v4

ThemeService

The ThemeService can be used to change the theme of the chat UI and to customize the theme. Our theming guide gives a complete overview about the topic.

Properties

theme$

theme$: BehaviorSubject<string>

A Subject that can be used to get or set the currently active theme.

Defined in

lib/theme.service.ts:16


themeVersion

themeVersion: "1" | "2"

Stream chat theme version - this is used internally by some UI components of the SDK, integrators shouldn't need to use this variable

Defined in

lib/theme.service.ts:20

Accessors

customDarkThemeVariables

get customDarkThemeVariables(): undefined | { [key: string]: string; }

A getter that returns the currently set custom dark theme variables.

deprecated Only use with theme v1

Returns

undefined | { [key: string]: string; }

An object where the keys are theme variables, and the values are the currently set CSS values.

Defined in

lib/theme.service.ts:103

set customDarkThemeVariables(variables): void

A setter that can be used to overwrite the values of the CSS theme variables of the dark theme.

deprecated Only use with theme v1

Parameters

NameTypeDescription
variablesundefined | { [key: string]: string; }An object where the keys are theme variables, and the values are CSS values.

Returns

void

An object where the keys are theme variables, and the values are the currently set CSS values.

Defined in

lib/theme.service.ts:112


customLightThemeVariables

get customLightThemeVariables(): undefined | { [key: string]: string; }

A getter that returns the currently set custom light theme variables.

deprecated Only use with theme v1

Returns

undefined | { [key: string]: string; }

An object where the keys are theme variables, and the values are the currently set CSS values.

Defined in

lib/theme.service.ts:76

set customLightThemeVariables(variables): void

A setter that can be used to overwrite the values of the CSS theme variables of the light theme.

deprecated Only use with theme v1

Parameters

NameTypeDescription
variablesundefined | { [key: string]: string; }An object where the keys are theme variables, and the values are CSS values.

Returns

void

An object where the keys are theme variables, and the values are the currently set CSS values.

Defined in

lib/theme.service.ts:85

Did you find this page helpful?