This page demonstrates the power of CssUserAgent. This feature applies User-Agent specific CSS classes to the <body> tag to allow browser-specific CSS variation without resorting to CSS hacks. Since these are performed once at startup, CSS may be statically defined without the need to mix browser-specific logic into the presentation.
Multiple classes are created for each user-agent, allowing the web developer to target browser classes on differing levels of granularity. The general pattern is browser name followed by version number:
ua-browsernameua-browsername-majorua-browsername-major-minorua-browsername-major-minor-buildua-browsername-major-minor-build-revisionSome browsers have multiple listings if the rendering engine is significant. For instance, Gecko-based browsers (such as Firefox, Mozilla, Netscape, Camino, SeaMonkey) also define Gecko CSS classes, to target all browsers of a specific Gecko version at once.
Below is an example of a number of browser labels which display differently under the presence of different CssUserAgent classes.