CSSInject
Component for adding dynamic CSS styles
Easily inject custom CSS to you application.
CSSInject doesn't provide any helpers to easily add custom styles directly to some component. It's just a very simplistic way of attaching additional CSS to the same UI where the CSSInject component is attached. A new
Sample code
// Version 2 (for Vaadin 7) CSSInject css = new CSSInject(getUI()); css.setStyles(".custom-style { color: rgb(100, 200, 300); }"); // Version 1 (for Vaadin 6) CSSInject css = new CSSInject(); css.setValue(".custom-style { color: rgb(100, 200, 300); }"); mainLayout.addComponent(css);
Links
Compatibility
Was this helpful? Need more help?
Leave a comment or a question below. You can also join
the chat on Discord or
ask questions on StackOverflow.
Version
-Compatible with Vaadin 7.0.1 and very like with later versions also. -Separated the state class into the "shared" package
- Released
- 2013-01-18
- Maturity
- BETA
- License
- Apache License 2.0
Compatibility
- Framework
- Vaadin 7.0+
- Vaadin 6.3+ in 1.0
- Vaadin 6.2+ in 0.10
- Browser
- Internet Explorer
- Internet Explorer
- Internet Explorer
- Firefox
- Opera
- Safari
- Google Chrome
- Internet Explorer
- iOS Browser
- Android Browser
CSSInject - Vaadin Add-on Directory
Component for adding dynamic CSS stylesEasily inject custom CSS to you application.
CSSInject doesn't provide any helpers to easily add custom styles directly to some component. It's just a very simplistic way of attaching additional CSS to the same UI where the CSSInject component is attached. A new