Module:List/doc: Difference between revisions
Streetclaw (talk | contribs) No edit summary |
m Fixed grammar error. |
||
(One intermediate revision by one other user not shown) | |||
Line 1: | Line 1: | ||
List template. Based on [https://www.mediawiki.org/wiki/Module:List MediaWiki List Module] | |||
== About == | == About == | ||
Creates a list | Creates a list in a specified format. | ||
== Parameter == | == Parameter == |
Latest revision as of 15:41, 2 September 2020
List template. Based on MediaWiki List Module
About
Creates a list in a specified format.
Parameter
Do not use named parameter for 1
... x
. The first Parameter will be automatically marked as 1
, the second as 2
and so on.
Parameter | Description | Type | Status | |
---|---|---|---|---|
listType | 1
|
List type
Default:
Example: {{#invoke:list|bulleted|a|b|c}}
{{#invoke:list|unbulleted|a|b|c}}
{{#invoke:list|horizontal|a|b|c}}
{{#invoke:list|ordered|a|b|c}}
{{#invoke:list|horizontal_ordered|a|b|c}}
|
[ "bulleted" | "unbulleted" | "horizontal" | "ordered" | "horizontal_ordered" ] | Required |
listEntries | 2...x
|
List entries
Default:
Example: no example |
WikiCode | Optional |
olStart | start
|
Start entry. <ol start="">MDN (ol). Requires listType [ "ordered" | "horizontal_ordered" ]
Default:
Example: {{#invoke:list|ordered|a|b|c|start=5}}
{{#invoke:list|ordered|a|b|c|start=-5}}
|
SignedNumber | Optional |
olType | type
|
Ordered list type. <ol type="">MDN (ol). Requires listType [ "ordered" | "horizontal_ordered" ]. It's recommended to use style ,class or param list_style_type instead
Default:
Example: {{#invoke:list|ordered|a|b|c|type=i}}
{{#invoke:list|ordered|a|b|c|type=a}}
|
[ "1" | "a" | "A" | "i" | "I" ] | Optional |
cssType | list_style_type
|
Recommended list style type. Uses the css attribute list-style-type
Default:
Example: {{#invoke:list|ordered|a|b|c|list_style_type=lower-alpha}}
{{#invoke:list|ordered|a|b|c|list_style_type=lower-greek}}
{{#invoke:list|ordered|a|b|c|list_style_type=decimal-leading-zero}}
|
MDN (list-style-type) | Optional |
divClass | class
|
class attribute for the <div>...</div>surrounding the list Default:
Example: no example |
String | Optional |
divStyle | style
|
style attribute for the <div>...</div>surrounding the list Default:
Example: no example |
String | Optional |
listStyle | list_style
|
style attribute for the list
Default:
Example: no example |
String | Optional |
itemStyle | item_style
|
style attribute for the list items
Default:
Example: no example |
String | Optional |
itemXStyle | item1_style...itemX_style
|
style attribute for item x in list
Default:
Example: no example |
String | Optional |
itemXValue | item1_value...itemX_value
|
value attribute for item x in list
Default:
Example: no example |
String | Optional |
listIndent | indent
|
Set margin-left for list (intent * 1.6 em )
Default:
Example: no example |
String | Optional |
See Template:TemplateData and Template:TemplateData/entry for more information about the parameter list and DDNCode for more information about types and the DDN Notation
Examples
- First item
- Second item
- Third item
{{#invoke:list|bulleted|First item|Second item|Third item|item1_style=background-color:yellow;|item2_style=background-color:silver;color:black;}}