CssClassAppender

You can add Css Classes to components by using the CssClassAppender Behavior. It has constructors that either expect a String, a CssClass or an IModel of a CssClass. The CssClass is an interface that is implemented by many Enums that provide refactoring safe Css Classes.

General

Alignment

Text alignment can be achieved by using the TextAlignment Enumeration.

Example

label.add(new CssClassAppender(TextAlignment.JUSTIFY));

Results

Transformation

Initialism

This is awesomeness.

Blockquote

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer posuere erat a ante.

Someone famous in Source Title

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer posuere erat a ante.

Someone famous in Source Title

Contextual Colors

Contextual Background