This is an old revision of the document!
Buttons
Examples
<btn type="primary">Primary</btn> ...
Link button
<btn type="success" size="lg" icon="glyphicon glyphicon-edit">[[:wiki:welcome]]</btn>
Sizes
Fancy larger or smaller buttons? Add size=“lg”
, size=“sm”
, or size=“xs”
for additional sizes.
<btn type="primary" size="lg">Large button</btn> <btn type="default" size="lg">Large button</btn> <btn type="primary">Default button</btn> <btn type="default">Default button</btn> <btn type="primary" size="sm">Small button</btn> <btn type="default" size="sm">Small button</btn> <btn type="primary" size="xs">Extra small button</btn> <btn type="default" size="xs">Extra small button</btn>
Block
Create block level buttons—those that span the full width of a parent – by adding block=“true”
option.
<btn type="primary" size="lg" block="true">Block level button</btn> <btn type="default" size="lg" block="true">Block level button</btn>
Options
Attribute | Default Value | Allowed Values | Description |
---|---|---|---|
type | default | default , primary , success , info , warning , danger , link | Type of button |
icon | optional | Font icon class (eg. Glyphicon or Font-Awesome) | |
size | optional | Allowed values: lg , sm |
|
block | optional | true , false | Block level buttons |
collapse | optional | Target element selector to collapse (see Collapse) |