Template:Dotlist
A helper template to generate dot-seperated list.
You can use {{dotlist/options}} to change default value for some parameters.
Usage
- Unnamed Parameters
Every unnamed parameter will output as an item of list.
- title =
(Optional) An extra title before list.
- bold = n
(Optional) If set, title will display in normal weight (not in bold).
- dot = n
(Optional) If set, title will display a Em Space ( , 
) instead of a dot betweeen items.
- paren = y/yes
(Optional) The list itself(excluding title) will be in parentheses. See examples below.
- inline = y/yes
(Optional) If set, dotlist will output as a display: inline element. By default it's a normal <div> element.
- space = l/xl/xxl/xxxl/xxxxl
(Optional) You can use them to increase the space between items.
- class =
(Optional) Custom css class(es). You can use class = l/xl/xxl/xxxl/xxxxl
to increase the space between items.
- css or style =
(Optional) Custom css rules. Note: if you set default css with {{dotlist/options}}(by css= or style=), then css= will override default css, but style= will not(appended instead).
For example:
{{dotlist/options|css=color:red; padding:1em;}} {{dotlist|css=margin:1em;}}
, the resulting css is:margin:1em;
.{{dotlist/options|css=color:red; padding:1em;}} {{dotlist|style=text-align:center;}}
, the resulting css is:color:red; padding:1em; text-align:center;
.{{dotlist/options|css=color:red; padding:1em;}} {{dotlist|css=margin:1em;|style=text-align:center;}}
, the resulting css is:margin:1em; text-align:center;
.
Examples
|
before list: after
|
|
before
|
|
before
|
|
before list: after
|
|
before list: after
|
|
before list: after
|
Dotlists can be nested.
|
before list: after
|
parentheses for sub-dotlist, and with no bold title.
|
before list: after
|
Alternative API style
There is another API style which is easier to use with DPL/cargo:
{{dotlist/start}}{{dotlist/item|item1}}{{dotlist/item|item2}}{{dotlist/item|item3}}{{dotlist/end}}
- item1
- item2
- item3
All parameters of {{dotlist}} are available on {{dotlist/start}}, and paren
is also available on {{dotlist/end}}.