Template:Yes/doc: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
(Used <code><nowiki> instead of <pre>. Listed parameters.)
(Dark mode. Can't use transparent color because class=wikitable still has a white base background.)
 
(8 intermediate revisions by 3 users not shown)
Line 1: Line 1:
This template is designed to be used in "comparison tables".
== Usage ==
==Usage==
This template is designed to be used in comparison tables.
__NOTOC__
 
=== Parameters ===
*{{Param}} – The first unnamed parameter overrides the displayed text;
*{{Param|align}} – Overrides the alignment of the text in the table cell;
*{{Param|style}} – Override any style attributes of the table cell.
 
=== Examples ===
{| cellpadding=5
|
{| class="standard-table"
|+ class = standard-table
! Table Cell Wikitext
! width="100" | Result
<includeonly>
|-
| {{T|{{PAGENAME}}}}
| {{ {{PAGENAME}} }}
|-
| {{T|{{PAGENAME}}|{{P|Text}}}}
| {{ {{PAGENAME}} |Text}}
|-
| {{T|{{PAGENAME}}|{{P|&#91;[Main Page]]}}}}
| {{ {{PAGENAME}} |[[Main Page]]}}
|-
| {{T|{{PAGENAME}}|{{P|align|left}}}}
| {{ {{PAGENAME}} |align=left}}
|-
| {{T|{{PAGENAME}}|{{P|style|color:#FFF}}}}
| {{ {{PAGENAME}} |style=color:#FFF}}
</includeonly>
|}
|
{| class="wikitable"
|+ style=color:#aaa| class = wikitable
! Table Cell Wikitext
! width="100" | Result
<includeonly>
|-
| {{T|{{PAGENAME}}}}
| {{ {{PAGENAME}} }}
|-
| {{T|{{PAGENAME}}|{{P|Text}}}}
| {{ {{PAGENAME}} |Text}}
|-
| {{T|{{PAGENAME}}|{{P|&#91;[Main Page]]}}}}
| {{ {{PAGENAME}} |[[Main Page]]}}
|-
| {{T|{{PAGENAME}}|{{P|align|left}}}}
| {{ {{PAGENAME}} |align=left}}
|-
| {{T|{{PAGENAME}}|{{P|style|color:#FFF}}}}
| {{ {{PAGENAME}} |style=color:#FFF}}
</includeonly>
|}
|
{|
|+ style=color:#aaa| no class
! Table Cell Wikitext
! width="100" | Result
<includeonly>
|-
| {{T|{{PAGENAME}}}}
| {{ {{PAGENAME}} }}
|-
| {{T|{{PAGENAME}}|{{P|Text}}}}
| {{ {{PAGENAME}} |Text}}
|-
| {{T|{{PAGENAME}}|{{P|&#91;[Main Page]]}}}}
| {{ {{PAGENAME}} |[[Main Page]]}}
|-
| {{T|{{PAGENAME}}|{{P|align|left}}}}
| {{ {{PAGENAME}} |align=left}}
|-
| {{T|{{PAGENAME}}|{{P|style|color:#FFF}}}}
| {{ {{PAGENAME}} |style=color:#FFF}}
</includeonly>
|}
|}
{{clr}}
 
== See Also ==
{| class="standard-table"
{| class="standard-table"
! Table Cell Wikitext
! Table Cell Wikitext
Line 6: Line 88:
! Indicates...
! Indicates...
! Color Code
! Color Code
! Template Link
|-
|-
| <code><nowiki>{{Yes}}</nowiki></code>
| {{T|Yes}}
| {{Yes}}
| {{Yes}}
| ''positive''
| ''positive''
|style=color:#90FF90| #90FF90
| #385038
| [[Template:Yes]]
|-
|-
| <code><nowiki>{{No}}</nowiki></code>
| {{T|No}}
| {{No}}
| {{No}}
| ''negative''
| ''negative''
|style=color:#FF9090| #FF9090
| #503838
| [[Template:No]]
|-
|-
| <code><nowiki>{{N/A}}</nowiki></code>
| {{T|N/A}}
| {{N/A}}
| {{N/A}}
| ''not applicable'' or<br>''not available''
| ''not applicable'' or<br>''not available''
|style=color:#FFFF90| #FFFF90
| #585838
| [[Template:N/A]]
|-
|-
| <code><nowiki>{{Both}}</nowiki></code>
| {{T|Both}}
| {{Both}}
| {{Both}}
| ''multiple possibilities''
| ''multiple possibilities''
|style=color:#BE90FF| #BE90FF
| #383850
| [[Template:Both]]
|}<includeonly>[[Category:Templates]]
|}
===Parameters===
*{{param|1}} - The first unnamed parameter overrides the displayed text.
*{{param|align}} - Overrides the alignment of the text in the table cell.
*{{param|style}} - Override any style attributes of the table cell.
===Examples===
{|
{| class="standard-table"
! Table Cell Wikitext
! width="100"| Result
|-
| <code><nowiki>{{Yes|:D}}</nowiki></code>
| {{Yes|:D}}
|-
| <code><nowiki>{{N/A|align=left}}</nowiki></code>
| {{N/A|align=left}}
|-
| <code><nowiki>{{No|style=color:#FFFFFF}}</nowiki></code>
| {{No|style=color:#FFFFFF}}
|}

Latest revision as of 00:08, 9 February 2025

Usage

This template is designed to be used in comparison tables.


Parameters

  • {{{1}}} – The first unnamed parameter overrides the displayed text;
  • {{{align}}} – Overrides the alignment of the text in the table cell;
  • {{{style}}} – Override any style attributes of the table cell.

Examples

class = standard-table
Table Cell Wikitext Result
class = wikitable
Table Cell Wikitext Result
no class
Table Cell Wikitext Result

See Also

Table Cell Wikitext Result Indicates... Color Code
{{Yes}} Yes positive #385038
{{No}} No negative #503838
{{N/A}} N/A not applicable or
not available
#585838
{{Both}} Both multiple possibilities #383850