Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

The Light Theme on the Topology View:. The theme name is 'light'.

The Dark Theme on the Topology View:. The theme name is 'dark'.

Image Added

NameSummary
initInitializes the ThemeService and sets the current theme.
themeGets or sets the current theme.
toggleThemeToggle the current theme to the next theme in the theme list.
addListenerAdd a listener to a theme event.
removeListenerRemove a theme event listener.

Function Descriptions

init

Initializes the ThemeService and sets the current theme. You probably won't have to call this because the ThemeService is initialized in onos.js.

Example UsageArgumentsReturn Value
ts.init();nonenone

theme

Gets or sets the current theme. This function is getter/setter.

Example UsageArgumentsReturn Value
ts.theme(x);

x - undefined or a string of the name of theme you want to set the current theme to

if x is undefined - a string of the name of the current theme

if x is a string - no return value

toggleTheme

addListener

removeListener

 

 Image Removed