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

Материал из Guild Wars 2 wiki
Перейти к: навигация, поиск
Строка 1: Строка 1:
<includeonly>{{#show: {{{1|}}}
+
<includeonly>{{#if: {{{icon|}}} | {{Game update icon result format|Skill|File:{{{icon}}}|{{{1}}}|{{{name|{{{1}}}}}}}} | {{#show: {{{1|}}}
 
| ?Has context
 
| ?Has context
 
| ?Has game icon
 
| ?Has game icon
Строка 9: Строка 9:
 
| template = Game update icon result format
 
| template = Game update icon result format
 
| default=[[{{{1|}}}]]
 
| default=[[{{{1|}}}]]
 +
}}
 
}}</includeonly><noinclude>
 
}}</includeonly><noinclude>
 
A template that provides skill and trait icons for game update pages. Format template: {{tl|Game update icon result format}}.
 
A template that provides skill and trait icons for game update pages. Format template: {{tl|Game update icon result format}}.
Строка 18: Строка 19:
 
;1 ''(unnamed parameter)''
 
;1 ''(unnamed parameter)''
 
:skill or trait page name.
 
:skill or trait page name.
 +
;icon
 +
:Optional. Specify a valid filename without the "File:" prefix.
 +
;name
 +
:Optional. Only applies if ''icon'' is also specified.
  
 
== Example ==
 
== Example ==

Версия 21:38, 4 сентября 2018

A template that provides skill and trait icons for game update pages. Format template: {{Game update icon result format}}.

Содержание

Usage

{{Game update icon|<page name>}}

Parameters

1 (unnamed parameter)
skill or trait page name.
icon
Optional. Specify a valid filename without the "File:" prefix.
name
Optional. Only applies if icon is also specified.

Example

{{Game update icon|Retribution (trait)}}
Retribution (trait).png
 Retribution

Notes

// Scripts to use when viewing game updates
if (mw.config.get('wgPageName').substring(0, 12) == 'Game_updates') {
    $('li .skillicon, li .effecticon, li .traiticon').each(function(){
      $(this).parent('li').addClass('patchnote');
    });
}
.patchnote { line-height: 2.7em; }
.patchnote .skillicon img, .patchnote .traiticon img { background-color: black; }