Шаблон:Trait icon — различия между версиями

Материал из Guild Wars 2 wiki
Перейти к: навигация, поиск
(Отмена правки 65682, сделанной участником Blood (обс.))
(возвращение inline-icon-addition)
Строка 3: Строка 3:
 
{{#vardefine:smw_name|{{#show:{{{1|}}}|?Has canonical name|default={{{1|Trait}}}}}}}
 
{{#vardefine:smw_name|{{#show:{{{1|}}}|?Has canonical name|default={{{1|Trait}}}}}}}
 
{{#vardefine:smw_line|{{#show:{{{1|}}}|?Is in trait line|default={{#var:smw_name}}}}}}
 
{{#vardefine:smw_line|{{#show:{{{1|}}}|?Is in trait line|default={{#var:smw_name}}}}}}
}}<span {{#ifexpr: {{{size|25}}} > 25||class="inline-icon"}}>[[{{#var:smw_icon}}|{{{size|25}}}px|link={{{1}}}|{{{2|{{#var:smw_line}}}}}]]</span>&nbsp;[[{{{1|Trait}}}|{{{2|{{#var:smw_name}}}}}]]</includeonly><noinclude>
+
}}<span {{#ifexpr: {{{size|25}}} > 25||class="inline-icon"}}>[[{{#var:smw_icon}}|{{{size|25}}}px|class=inline-icon-addition|link={{{1}}}|{{{2|{{#var:smw_line}}}}}]]</span>&nbsp;[[{{{1|Trait}}}|{{{2|{{#var:smw_name}}}}}]]</includeonly><noinclude>
  
 
== Description ==
 
== Description ==

Версия 14:16, 2 марта 2017


Description

{{trait icon|<trait name>}}

Displays a link to the trait name (canonical name) and the trait tier icon. The tooltip of the icon displays the trait line and the tooltip of the link displays the article name.

Parameters

unnamed parameter 1
Trait name. Defaults to "Trait".
unnamed parameter 2
Link text. Defaults to canonical name.
size
Size of icon to display, in px. Defaults to "25" px.

Examples

  • Persisting Flames Persisting Flames is produced from {{trait icon|Persisting Flames}}
  • Zephyr's Speed (ranger) Zephyr's Speed is produced from {{trait icon|Zephyr's Speed (ranger)}}
  • ZOOM! ZOOM! is produced from {{trait icon|Zephyr's Speed (ranger)|ZOOM!}}
  • Example Example is produced from {{trait icon|Nonexistent page|Example}}