A list of basic components
Style any element as a label, simply add .label
class, if you want some flavour, add .label .label-primary
.
Useful to use as .add-on
in .input-append
<a class="label" href="#"> label </a>
<a class="label label-default" href="#"> default </a>
<a class="label label-primary" href="#"> primary </a>
<a class="label label-info" href="#"> info </a>
<a class="label label-success" href="#"> success </a>
<a class="label label-warning" href="#"> warning </a>
<a class="label label-danger" href="#"> danger </a>
<a class="label label-alt" href="#"> alternative </a>
<a class="label label-inverse" href="#"> inverse </a>
Highlight elements using a badge, simply add .badge
class, if you want some flavour, add .badge .badge-primary
Is auto collapsible using:empty
but will not collapse on IE8 because has no:empty
support. For a better practice just print or not when has notifications
<a class="badge" href="#"> badge </a>
<a class="badge badge-default" href="#"> default </a>
<a class="badge badge-primary" href="#"> primary </a>
<a class="badge badge-info" href="#"> info </a>
<a class="badge badge-success" href="#"> success </a>
<a class="badge badge-warning" href="#"> warning </a>
<a class="badge badge-danger" href="#"> danger </a>
<a class="badge badge-alt" href="#"> alternative </a>
<a class="badge badge-inverse" href="#"> inverse </a>
For displaying notifications you can use it on a<sup>
or<sub>
tag
<span class="label">
Example
<sup class="badge badge-danger" href="#">2</sup>
</span>
<span class="label">
Example
<span class="badge badge-danger " href="#">2</span>
</span>
<span class="label">
Example
<sub class="badge badge-danger" href="#">2</sub>
</span>
Style any element as a message, simply add .message
class, if you want some flavour, add .message .message-primary
<div class="message" > message </div>
<div class="message message-default" > default </div>
<div class="message message-primary" > primary </div>
<div class="message message-info" > info </div>
<div class="message message-success" > success </div>
<div class="message message-warning" > warning </div>
<div class="message message-danger" > danger </div>
<div class="message message-alt" > alternative </div>
<div class="message message-inverse" > inverse </div>