Using variables in CSS via GWT

<ui:style>
@def corporateTextColor #426;
@eval corporateBackgroundColor my.company.Resource.INSTANCE.constant().red();

.aCSSclass {
color: corporateTextColor;
background: corporateBackgroundColor;
/* certain CSS property definitions */
}
.anotherCSSclass {
color: corporateTextColor;
background: corporateBackgroundColor;
/* certain CSS property definitions */
}
</ui:style>


Comments

Popular posts from this blog

Tuning ext4 for performance with emphasis on SSD usage

Java 8: Default Interface Implementations, The Diamond Problem, Multiple Inheritance, and Precedence

Tuning ext3 for performance without losing its data integrity potential