Company logo
May 5, 2021

CommandBar Skins

Richard Freling's avatar

CommandBar Skins are themes for styling your CommandBar.

Enterprise customers now have access to "Skins" in their Editor. Skins will allow you to define multiple CommandBar themes using a bunch of CSS hooks.

To programmatically switch the theme for a user, use the following SDK call

window.CommandBar.setTheme("themeSlug"); where "themeSlug" is the slug of the theme you want to use. A common use for skins: creating a light mode and dark mode for CommandBar to match your app's light mode and dark mode.

How can I turn this on? 🛠

In the Editor: (1) go to the "Settings" tab; (2) go to the "Styles" section.

You will see one skin there corresponding to your existing theme, and you can add another by clicking "Create a new skin".