sidebarAction
Gets and sets properties of an extension's sidebar.
A sidebar is a pane that is displayed at the left-hand or right-hand side of the browser window, next to the web page. The browser provides a UI that enables the user to see the currently available sidebars and to select a sidebar to display. Using the sidebar_action
manifest.json key, an extension can define its own sidebar. Using the sidebarAction
API described here, an extension can get and set the sidebar's properties.
The sidebarAction
API is closely modeled on the browserAction
API.
The sidebarAction API is based on Opera's sidebarAction API. However, note that the following are not yet supported: setBadgeText()
, getBadgeText()
, setBadgeBackgroundColor()
, getBadgeBackgroundColor()
, onFocus
, onBlur
.
Types
Functions
-
Closes the sidebar.
-
Gets the sidebar's panel.
-
Gets the sidebar's title.
-
Checks whether the sidebar is open or not.
-
Opens the sidebar.
-
Sets the sidebar's icon.
-
Sets the sidebar's panel.
-
Sets the sidebar's title. This will be displayed in any UI provided by the browser to list sidebars, such as a menu.
-
Toggles the visibility of the sidebar.
Browser compatibility
BCD tables only load in the browser
Example add-ons
Note: This API is based on Opera's chrome.sidebarAction
API.