css - How to change Polymer(1.0) paper-toolbar background colour? -
yesterday decided try polymer 1.0 , i'm facing difficulties when trying styling paper-toolbar.
the documentation says background colour can changed using: --paper-toolbar-background
but how can use on css?
i tried following:
paper-toolbar { --paper-toolbar-background: #e5e5e5; }
also this:
paper-toolbar { --paper-toolbar { background: #e5e5e5; } }
but neither worked. correct way it?
thanks.
if styling on main page, have apply styles using <style is='custom-style'>
. make custom css properties work.
applying relatively easy. paper-toolbar
provides 2 custom properties , 1 mixin. --paper-toolbar-background
property changes background color of toolbar while --paper-toolbar-color
changes foreground color. --paper-toolbar
mixin applied toolbar.
to use these properties same applying styles in elements. example
<style is="custom-style"> paper-toolbar { --paper-toolbar-background: #00f; /* changes background blue*/ --paper-toolbar-color: #0f0; /* changes foreground color green */ --paper-toolbar: { font-size: 40px; /* change default font size */ }; /* notice semicolon here */ } </style>
Comments
Post a Comment