Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Where is the default stylesheet for Chrome extension popups and options pages?

Popups and Options Pages for Chrome extensions have an additional user agent stylesheet that adds styles similar to Chrome's own chrome://settings and other pages. The styles are mentioned in explaining how to declare your V2 options page:

chrome_style (boolean) - optional

If true, a Chrome user agent stylesheet will be applied to your options page. The default value is false, but we recommend you enable it for a consistent UI with Chrome.

Is that stylesheet a stable API?

Where is that stylesheet?

like image 337
Ross Allen Avatar asked Jan 12 '17 20:01

Ross Allen


People also ask

Where are Chrome extension settings stored?

When extensions are installed into Chrome they are extracted into the C:\Users\[login_name]\AppData\Local\Google\Chrome\User Data\Default\Extensions folder. Each extension will be stored in its own folder named after the ID of the extension.

Where is the Chrome extension menu?

On your computer, open Chrome . At the top right, click Extensions .


1 Answers

I found the answer in Chromium source. The following two stylesheets are added to Options Pages with chrome_style:true:

  • extension.css: https://chromium.googlesource.com/chromium/src/+/master/extensions/renderer/resources/extension.css
  • extension_fonts.css: https://chromium.googlesource.com/chromium/src/+/master/extensions/renderer/resources/extension_fonts.css
like image 148
Ross Allen Avatar answered Nov 15 '22 06:11

Ross Allen