Template:Infobox3cols/doc: Difference between revisions
Jump to navigation
Jump to search
mNo edit summary |
mNo edit summary |
||
Line 1: | Line 1: | ||
{{Documentation subpage}} | {{Documentation subpage}} | ||
{{ | {{Lua|Module:Infobox3cols}} | ||
This is a fork of {{tl|infobox}} which provides an option for up to three | This is a fork of {{tl|infobox}} which provides an option for up to three {{code|data}} attributes per row, in addition to a label: data''x''a, data''x''b and data''x''c. | ||
{{clear}} | {{clear}} | ||
== Usage == | == Usage == | ||
<pre> | <pre> | ||
{{Infobox3cols | {{|Infobox3cols | ||
| child = | | child = | ||
| bodyclass = | | bodyclass = | ||
| bodystyle = | | bodystyle = | ||
| title = | | title = | ||
| titleclass = | | titleclass = | ||
| titlestyle = | | titlestyle = | ||
| above = | | above = | ||
| abovestyle = | | abovestyle = | ||
| aboveclass = | | aboveclass = | ||
| aboverowclass = | | aboverowclass = | ||
| subheader = | | subheader = | ||
| subheaderstyle = | | subheaderstyle = | ||
| subheaderclass = | | subheaderclass = | ||
| subheaderrowclass1 = | | subheaderrowclass1 = | ||
| subheader2 = | | subheader2 = | ||
| subheaderrowclass2 = | | subheaderrowclass2 = | ||
| image = | | image = | ||
| image1 = | | image1 = | ||
| caption = | | caption = | ||
| caption1 = | | caption1 = | ||
| captionstyle = | | captionstyle = | ||
| imagestyle = | | imagestyle = | ||
| imageclass = | | imageclass = | ||
| imagerowclass1 = | | imagerowclass1 = | ||
| image2 = | | image2 = | ||
| caption2 = | | caption2 = | ||
| imagerowclass2 = | | imagerowclass2 = | ||
| headerstyle = | | headerstyle = | ||
| labelstyle = | | labelstyle = | ||
| datastyle = | | datastyle = | ||
| datastylea = | | datastylea = | ||
| datastyleb = | | datastyleb = | ||
| datastylec = | | datastylec = | ||
| header1 = | | header1 = | ||
| label1 = | | label1 = | ||
| data1 = | | data1 = | ||
| data1a = | | data1a = | ||
| data1b = | | data1b = | ||
| data1c = | | data1c = | ||
| class1 = | | class1 = | ||
| rowclass1 = | | rowclass1 = | ||
| header2 = | | header2 = | ||
| rowclass2 = | | rowclass2 = | ||
| label2 = | | label2 = | ||
| data2 = | | data2 = | ||
| class2 = | | class2 = | ||
| data2a = | | data2a = | ||
| data2b = | | data2b = | ||
| class2a = | | class2a = | ||
| class2b = | | class2b = | ||
| class2c = | | class2c = | ||
| data2c = | | data2c = | ||
... | | ... | ||
| below = | | below = | ||
| belowstyle = | | belowstyle = | ||
| belowclass = | | belowclass = | ||
| belowrowclass = | | belowrowclass = | ||
| name = | | name = | ||
}} | }} | ||
</pre> | </pre> | ||
== Parameter | == Parameter Precedence == | ||
The bulk of the infobox is generated by blocks of numbered parameters: | The bulk of the infobox is generated by blocks of numbered parameters: {{code|headerX}}, {{code|labelX}}, {{code|dataX}}, {{code|dataXa}}, {{code|dataXb}}, and {{code|dataXc}}. The following examples demonstrate the order in which these parameters are used. | ||
{| | {| | ||
Line 82: | Line 81: | ||
! Code !! Result | ! Code !! Result | ||
|- style="vertical-align:top" | |- style="vertical-align:top" | ||
| | | | ||
{{infobox3cols | {{tj|infobox3cols | ||
| header1 | | header1: header1 | ||
| label1 | | label1: label1 | ||
| data1 | | data1: data1 | ||
| data1a | | data1a: data1a | ||
| data1b | | data1b: data1b | ||
| data1c | | data1c: data1c | ||
}} | }} | ||
| | | | ||
{{infobox3cols | {{infobox3cols | ||
| header1 = header1 | | header1 = header1 | ||
| label1 = label1 | | label1 = label1 | ||
| data1 = data1 | | data1 = data1 | ||
| data1a = data1a | | data1a = data1a | ||
| data1b = data1b | | data1b = data1b | ||
| data1c = data1c | | data1c = data1c | ||
}} | }} | ||
|} | |} | ||
Line 106: | Line 105: | ||
! Code !! Result | ! Code !! Result | ||
|- style="vertical-align:top" | |- style="vertical-align:top" | ||
| | | | ||
{{infobox3cols | {{tj|infobox3cols | ||
| header1 | | header1: | ||
| label1 | | label1: label1 | ||
| data1 | | data1: data1 | ||
| data1a | | data1a: data1a | ||
| data1b | | data1b: data1b | ||
| data1c | | data1c: data1c | ||
}} | }} | ||
| | | | ||
{{infobox3cols | {{infobox3cols | ||
| header1 = | | header1 = | ||
| label1 = label1 | | label1 = label1 | ||
| data1 = data1 | | data1 = data1 | ||
| data1a = data1a | | data1a = data1a | ||
| data1b = data1b | | data1b = data1b | ||
| data1c = data1c | | data1c = data1c | ||
}} | }} | ||
|} | |} | ||
Line 130: | Line 129: | ||
! Code !! Result | ! Code !! Result | ||
|- style="vertical-align:top" | |- style="vertical-align:top" | ||
| | | | ||
{{infobox3cols | {{tj|infobox3cols | ||
| header1 | | header1: | ||
| label1 | | label1: | ||
| data1 | | data1: data1 | ||
| data1a | | data1a: data1a | ||
| data1b | | data1b: data1b | ||
| data1c | | data1c: data1c | ||
}} | }} | ||
| | | | ||
{{infobox3cols | {{infobox3cols | ||
| header1 = | | header1 = | ||
| label1 = | | label1 = | ||
| data1 = data1 | | data1 = data1 | ||
| data1a = data1a | | data1a = data1a | ||
| data1b = data1b | | data1b = data1b | ||
| data1c = data1c | | data1c = data1c | ||
}} | }} | ||
|} | |} | ||
Line 154: | Line 153: | ||
! Code !! Result | ! Code !! Result | ||
|- style="vertical-align:top" | |- style="vertical-align:top" | ||
| | | | ||
{{infobox3cols | {{tj|infobox3cols | ||
| header1 | | header1: | ||
| label1 | | label1: label1 | ||
| data1 | | data1: | ||
| data1a | | data1a: data1a | ||
| data1b | | data1b: data1b | ||
| data1c | | data1c: data1c | ||
}} | }} | ||
| | | | ||
{{infobox3cols | {{infobox3cols | ||
| header1 = | | header1 = | ||
| label1 = label1 | | label1 = label1 | ||
| data1 = | | data1 = | ||
| data1a = data1a | | data1a = data1a | ||
| data1b = data1b | | data1b = data1b | ||
| data1c = data1c | | data1c = data1c | ||
}} | }} | ||
|} | |} | ||
Line 178: | Line 177: | ||
! Code !! Result | ! Code !! Result | ||
|- style="vertical-align:top" | |- style="vertical-align:top" | ||
| | | | ||
{{infobox3cols | {{tj|infobox3cols | ||
| header1 | | header1: | ||
| label1 | | label1: label1 | ||
| data1 | | data1: | ||
| data1a | | data1a: | ||
| data1b | | data1b: data1b | ||
| data1c | | data1c: data1c | ||
}} | }} | ||
| | | | ||
{{infobox3cols | {{infobox3cols | ||
| header1 = | | header1 = | ||
| label1 = label1 | | label1 = label1 | ||
| data1 = | | data1 = | ||
| data1a = | | data1a = | ||
| data1b = data1b | | data1b = data1b | ||
| data1c = data1c | | data1c = data1c | ||
}} | }} | ||
|} | |} | ||
Line 202: | Line 201: | ||
! Code !! Result | ! Code !! Result | ||
|- style="vertical-align:top" | |- style="vertical-align:top" | ||
| | | | ||
{{infobox3cols | {{tj|infobox3cols | ||
| header1 | | header1: | ||
| label1 | | label1: label1 | ||
| data1 | | data1: | ||
| data1a | | data1a: | ||
| data1b | | data1b: | ||
| data1c | | data1c: data1c | ||
}} | }} | ||
| | | | ||
{{infobox3cols | {{infobox3cols | ||
| header1 = | | header1 = | ||
| label1 = label1 | | label1 = label1 | ||
| data1 = | | data1 = | ||
| data1a = | | data1a = | ||
| data1b = | | data1b = | ||
| data1c = data1c | | data1c = data1c | ||
}} | }} | ||
|} | |} | ||
Line 226: | Line 225: | ||
! Code !! Result | ! Code !! Result | ||
|- style="vertical-align:top" | |- style="vertical-align:top" | ||
| | | | ||
{{infobox3cols | {{tj|infobox3cols | ||
| header1 | | header1: | ||
| label1 | | label1: | ||
| data1 | | data1: | ||
| data1a | | data1a: data1a | ||
| data1b | | data1b: data1b | ||
| data1c | | data1c: data1c | ||
}} | }} | ||
| | | | ||
{{infobox3cols | {{infobox3cols | ||
| header1 = | | header1 = | ||
| label1 = | | label1 = | ||
| data1 = | | data1 = | ||
| data1a = data1a | | data1a = data1a | ||
| data1b = data1b | | data1b = data1b | ||
| data1c = data1c | | data1c = data1c | ||
}} | }} | ||
|} | |} | ||
<includeonly> | <includeonly>{{sandbox other||{{testcases other|| | ||
<!-- Categories below this line, please --> | <!-- Categories below this line, please --> | ||
[[Category:Templates]] | [[Category:Templates]] | ||
</includeonly> | [[Category:Utility Templates]] | ||
}}}}</includeonly> |
Revision as of 06:15, 15 June 2023
It contains usage information, categories and other content that is not part of the original template page.
|
This template uses Lua: |
This is a fork of {{infobox}} which provides an option for up to three data
attributes per row, in addition to a label: dataxa, dataxb and dataxc.
Usage
{{|Infobox3cols | child = | bodyclass = | bodystyle = | title = | titleclass = | titlestyle = | above = | abovestyle = | aboveclass = | aboverowclass = | subheader = | subheaderstyle = | subheaderclass = | subheaderrowclass1 = | subheader2 = | subheaderrowclass2 = | image = | image1 = | caption = | caption1 = | captionstyle = | imagestyle = | imageclass = | imagerowclass1 = | image2 = | caption2 = | imagerowclass2 = | headerstyle = | labelstyle = | datastyle = | datastylea = | datastyleb = | datastylec = | header1 = | label1 = | data1 = | data1a = | data1b = | data1c = | class1 = | rowclass1 = | header2 = | rowclass2 = | label2 = | data2 = | class2 = | data2a = | data2b = | class2a = | class2b = | class2c = | data2c = | ... | below = | belowstyle = | belowclass = | belowrowclass = | name = }}
Parameter Precedence
The bulk of the infobox is generated by blocks of numbered parameters: headerX
, labelX
, dataX
, dataXa
, dataXb
, and dataXc
. The following examples demonstrate the order in which these parameters are used.
Code | Result | ||||
---|---|---|---|---|---|
{{infobox3cols
| header1 = header1 | label1 = label1 | data1 = data1 | data1a = data1a | data1b = data1b | data1c = data1c }} |
|
Code | Result | ||||
---|---|---|---|---|---|
{{infobox3cols
| header1 = | label1 = label1 | data1 = data1 | data1a = data1a | data1b = data1b | data1c = data1c }} |
|
Code | Result | ||||
---|---|---|---|---|---|
{{infobox3cols
| header1 = | label1 = | data1 = data1 | data1a = data1a | data1b = data1b | data1c = data1c }} |
|
Code | Result | ||||
---|---|---|---|---|---|
{{infobox3cols
| header1 = | label1 = label1 | data1 = | data1a = data1a | data1b = data1b | data1c = data1c }} |
|
Code | Result | ||||
---|---|---|---|---|---|
{{infobox3cols
| header1 = | label1 = label1 | data1 = | data1a = | data1b = data1b | data1c = data1c }} |
|
Code | Result | |||
---|---|---|---|---|
|
Code | Result |
---|---|
{{infobox3cols
| header1 = | label1 = | data1 = | data1a = data1a | data1b = data1b | data1c = data1c }} |
|