No edit summary |
No edit summary |
||
| (2 intermediate revisions by the same user not shown) | |||
| Line 1: | Line 1: | ||
<includeonly>[[Category:Table Template]]</includeonly> | <includeonly>[[Category:Table Template]]</includeonly> | ||
{{Template|TableSlim}} is intended for use alongside other {{Category|Table Template}}s. It sets up a table with no header and no embedded formatting. | {{Template|TableSlim}} is intended for use alongside other {{Category|Table Template}}s. It sets up a table with no header and no embedded formatting, different from {{Template|TableTop}}. It is typically embeded inside {{Category|Box Template}}s that provide structured data. | ||
==Usage== | ==Usage== | ||
It accepts {{parameter| | It accepts one {{parameter|optional}}: | ||
* {{code|width}}, either a pixel value (include "px") or a percentage. | |||
==Return== | ==Return== | ||
The table starts with {{Code|<nowiki><table style="border-collapse: collapse;"></nowiki>}}. For example, {{code|<nowiki>{{TableSlim}}{{TableMid|A1|B1|C1}}{{TableMid|A2|B2|C2}}{{TableEnd}}</nowiki>}} produces: {{Return|{{TableSlim}}{{TableMid|A1|B1|C1}}{{TableMid|A2|B2|C2}}{{TableEnd}}}} | The table starts with {{Code|<nowiki><table style="border-collapse: collapse;"></nowiki>}}. | ||
For example, {{code|<nowiki>{{TableSlim}}{{TableMid|A1|B1|C1}}{{TableMid|A2|B2|C2}}{{TableEnd}}</nowiki>}} produces: {{Return|{{TableSlim}}{{TableMid|A1|B1|C1}}{{TableMid|A2|B2|C2}}{{TableEnd}}}} | |||
Meanwhile, {{code|<nowiki>{{TableTop|A|B|C}}{{TableMid|A1|B1|C1}}{{TableMid|A2|B2|C2}}{{TableEnd}}</nowiki>}} produces: {{Return|{{TableTop|A|B|C}}{{TableMid|A1|B1|C1}}{{TableMid|A2|B2|C2}}{{TableEnd}}}} | Meanwhile, {{code|<nowiki>{{TableTop|A|B|C}}{{TableMid|A1|B1|C1}}{{TableMid|A2|B2|C2}}{{TableEnd}}</nowiki>}} produces: {{Return|{{TableTop|A|B|C}}{{TableMid|A1|B1|C1}}{{TableMid|A2|B2|C2}}{{TableEnd}}}} | ||
For example, {{code|<nowiki>{{TableSlim|width=100%}}{{TableMid|A1|B1|C1}}{{TableMid|A2|B2|C2}}{{TableEnd}}</nowiki>}} produces: {{Return|{{TableSlim|width=100%}}{{TableMid|A1|B1|C1}}{{TableMid|A2|B2|C2}}{{TableEnd}}}} | |||
Latest revision as of 10:44, 27 January 2023
Template:TableSlim is intended for use alongside other Table Templates. It sets up a table with no header and no embedded formatting, different from Template:TableTop. It is typically embeded inside Box Templates that provide structured data.
Usage
It accepts one optional parameter:
width, either a pixel value (include "px") or a percentage.
Return
The table starts with <table style="border-collapse: collapse;">.
For example, {{TableSlim}}{{TableMid|A1|B1|C1}}{{TableMid|A2|B2|C2}}{{TableEnd}} produces:
| A1 | B1 | C1 |
| A2 | B2 | C2 |
Meanwhile, {{TableTop|A|B|C}}{{TableMid|A1|B1|C1}}{{TableMid|A2|B2|C2}}{{TableEnd}} produces:
| A | B | C |
|---|---|---|
| A1 | B1 | C1 |
| A2 | B2 | C2 |
For example, {{TableSlim|width=100%}}{{TableMid|A1|B1|C1}}{{TableMid|A2|B2|C2}}{{TableEnd}} produces:
| A1 | B1 | C1 |
| A2 | B2 | C2 |
