Class ThemeRegistryServiceInternal

RbThemeRegistryService is an injectable service that allows for registering and unregistering themes, as well as providing access to the currently registered themes. It also provides an observable of themes that can be used to notify subscribers of changes to the registered themes.

Constructors

Properties

Accessors

Methods

Constructors

Properties

#dictionary: Map<string, Theme> = ...

The internal dictionary that holds the registered themes.

#themes$: any = ...

The subject that emits an updated array of registered themes whenever a change occurs.

themes$: any = ...

The observable that emits the collection of registered themes when it changes.

Accessors

Methods

  • Returns whether a theme with the given ID is currently registered.

    Parameters

    • id: null | string

      The ID of the theme to check.

    Returns boolean

  • Registers a new theme and emits the changed collection of themes.

    If a theme with the same ID is already registered, the registered theme will be merged with the new one.

    Themes without ID will be ignored.

    Parameters

    • theme: undefined | null | Theme

      The new theme to register

    Returns void