Template:Yesno/doc

From Brighter Shores Wiki
Revision as of 23:25, 1 November 2024 by BlackHawk (talk | contribs) (Created page with "{{Documentation}} {{TemplateData|<templatedata> { "description": "Normalizes boolean template arguments.", "format": "inline", "params": { "1": { "label": "Input", "description": "The value to normalize", "autovalue": "{{{parameter|¬}}}", "required": true, "type": "string" }, "true": { "label": "Truthy output", "description": "Output on a truthy value (e.g.: case‑insensitive 'yes', 'y', 'true', or '1')", "default": "1", "type": "st...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
This is a documentation subpage for Template:Yesno.
It contains usage information, categories, and other content that is not part of the original template page.

Template data

Show/hide template's data

The following information is used by extensions and applications, such as VisualEditor, to help users implement this template onto pages. Please ensure that it is up-to-date.

Normalizes boolean template arguments.

Template parameters

This template prefers inline formatting of parameters.

ParameterDescriptionTypeStatus
Input1

The value to normalize

Auto value
{{{parameter|¬}}}
Stringrequired
Truthy outputtrue

Output on a truthy value (e.g.: case‑insensitive 'yes', 'y', 'true', or '1')

Default
1
Stringoptional
Falsy outputfalse

Output on a falsy value (e.g.: case‑insensitive 'no', 'n', 'false', or '0')

Stringoptional
Blank outputblank

Output when the input parameter is defined but its value is empty

Default
{{{false}}}
Stringoptional
Undefined output¬

Output when the input parameter is either '¬' or entirely missing (undefined)

Auto value
¬
Stringoptional
Definite outputdef

Output when the input value is specified but isn't any of the preceding values

Default
{{{true}}}
Stringoptional

Based on wikipedia:commons:Data:Templatedata/yesno.tab

See also