Template:Area inline: Difference between revisions

From bg3.wiki
Jump to navigation Jump to search
mNo edit summary
mNo edit summary
(7 intermediate revisions by 2 users not shown)
Line 1: Line 1:
<includeonly>{{#cargo_query: tables = areas
<includeonly>{{#cargo_query: tables = areas
| fields = _pageName=page, name, icon, CONCAT('true') = inline, CONCAT('{{#replace:{{{2|}}}|'|\'}}') = altname, CONCAT('{{#if:{{{w|}}}|{{{w}}}|25}}') = w,
| fields = _pageName=page, name, icon, CONCAT('true') = inline, CONCAT('{{#replace:{{{2|}}}|'|\'}}') = altname, CONCAT('{{#if:{{{w|}}}|{{{w}}}|25}}') = w,
| where = _pageName = "{{#replace:{{{1}}}|&#39;|\'}}"
| where = name = "{{#replace:{{{1}}}|&#39;|\'}}" OR _pageName = "{{#replace:{{{1}}}|&#39;|\'}}"
| format = template
| format = template
| template = Area/Format
| template = Area full/format
| named args = yes
| named args = yes
| limit = 1
| limit = 1
| order by = _ID
| order by = _ID
| more results text=
| more results text=
| default = [[{{{1}}}|{{{2|{{{1}}}}}}]][[Category:Pages with unknown areas]]
| default = [[{{{1}}}|{{{2|{{{1}}}}}}]]{{Main namespace only|[[Category:Pages with unknown areas]]}}
}}</includeonly><noinclude>{{documentation|content=
}}</includeonly><noinclude>{{documentation|content=
{{shortcut|Area}}
Similar to [[Template:Area full]], but exclusively supports inline usage.
Similar to [[Template:Area full]], but exclusively supports inline usage.
Example: <code><nowiki>{{Area|Acid (surface)}}</nowiki></code>
Result: {{Area inline|Acid (surface)}}


If provided, the second parameter changes the display name of the condition.
If provided, the second parameter changes the display name of the condition.


Example: <code><nowiki>{{Area|Fire (surface)|Fiery}}</nowiki></code>
== Examples ==
 
{{Template demo
Result: {{Area inline|Fire (surface)|Fiery}}
| style = table
 
| <nowiki>{{Area|Acid}}</nowiki>
[[Category:Condition templates]]
| <nowiki>{{Area|Fire|Fiery}}</nowiki>
}}


== See also ==
== See also ==
* {{t link|area}}
* {{t link|area full}}
* {{t link|area full}}


== Template data ==
== Template data ==
<templatedata>
<templatedata>
{
{
    "description": "Display compact/inline information for a surface or area.",
    "format": "inline",
"params": {
"params": {
"1": {
"1": {
"label": "Area name",
"label": "Area name",
"type": "string",
            "description": "The name of the surface. This should correspond with the page name for that surface.",
"type": "wiki-page-name",
"required": true
"required": true
},
},
"2": {
"2": {
"label": "altname",
"label": "altname",
"description": "Alternative display name",
"description": "Alternative display name.",
"type": "string"
"type": "string"
}
}
Line 46: Line 45:
"format": "inline"
"format": "inline"
}
}
</templatedata>}}</noinclude>
</templatedata>}}
[[Category:Templates]]
[[Category:Condition templates]]
[[Category:Cargo templates]]
</noinclude>

Revision as of 11:20, 19 January 2025

Template documentation
Shortcut

Similar to Template:Area full, but exclusively supports inline usage.

If provided, the second parameter changes the display name of the condition.

Examples

Markup Renders as
{{Area|Acid}}
Acid Acid
{{Area|Fire|Fiery}}
Fire Fiery

See also

Template data

Display compact/inline information for a surface or area.

Template parameters

This template prefers inline formatting of parameters.

ParameterDescriptionTypeStatus
Area name1

The name of the surface. This should correspond with the page name for that surface.

Page namerequired
altname2

Alternative display name.

Stringoptional