Add-ons

theme.reset()

Resets any theme that was applied using the theme.update() method.

Note that this will always reset the theme back to the original default theme, even if the user had selected a different theme before this extension's theme was applied.

Syntax

browser.theme.reset()

Parameters

None.

Browser compatibility

ChromeEdgeFirefoxFirefox for AndroidOpera
Basic Support No No56 No No

Examples

This code applies a theme, then removes it when the user clicks a browser action:

browser.theme.update(themes.night);

browser.browserAction.onClicked.addListener(() => {
  browser.theme.reset();
});

 

Document Tags and Contributors

 Contributors to this page: wbamberg
 Last updated by: wbamberg,