Редактирование: Шаблон:Vendor table header

Материал из Guild Wars 2 wiki
Перейти к: навигация, поиск

Внимание! Вы не авторизовались на сайте. Ваш IP-адрес будет публично видимым, если вы будете вносить любые правки. Если вы войдёте или создадите учётную запись, правки вместо этого будут связаны с вашим именем пользователя, а также у вас появятся другие преимущества.

Правка может быть отменена. Пожалуйста, просмотрите сравнение версий, чтобы убедиться, что это именно те изменения, которые вас интересуют, и нажмите «Записать страницу», чтобы изменения вступили в силу.

На этой странице невозможны семантические аннотации в тексте из-за ограничений пространства имён. Детали относительно того, как разрешить пространство имен, находятся в справочной странице конфигурации.

Текущая версия Ваш текст
Строка 1: Строка 1:
{{#if: {{{requirement|}}} | <nowiki/>
+
{| {{STDT|npc}}
* {{vendor table notes|header=true|requirement={{#vardefineecho:vendor requirement|{{{requirement}}}}}}} | {{#vardefine:vendor requirement|}}
+
! Item {{#arraymap:showType,showRarity,showLevel,showFacts | , | @@@ | <!-- Define column headers inline -->
}}<nowiki/>
+
   {{#vardefine:@@@| {{#ifeq:{{{@@@|true}}}|false|false|true}} }}       <!-- Define column header variables -->
{| {{STDT|npc sortable {{{class|}}} }} style="display: table" {{#vardefine:vendor historical status|{{#show:{{#titleparts:{{PAGENAME}}}}|?Is historical|default=false}}}} {{#vardefine:vendor availability status|{{#show:{{#titleparts:{{PAGENAME}}}}|?Has availability|default=Current}}}} {{#vardefine:vendor_section|{{{section|General}}}}} {{#ifeq: {{{no subobjects|false}}} |true| {{#vardefine:suppress VTR subobjects|+}} | {{#ifeq: {{#var:suppress VTR subobjects}} |Template:Inventory - no subobjects| {{#vardefine:suppress VTR subobjects|+}} | {{#vardefine:suppress VTR subobjects|}} }} }} {{#vardefine:vendor location|{{{location|{{#show: {{PAGENAME}}|?Located in|valuesep=;|link=none|default=|limit=250|searchlabel=}}}}}}}
+
   {{#ifeq: {{#var:@@@}} | true | !! {{#replace:@@@|show|}} }}         <!-- Variable names match header names -->
! {{#if:{{{itemWidth|}}}  |style="min-width:{{{itemWidth}}}"  }} {{!}} Предмет    {{#vardefine:showType   |{{{showType|true}}}  }}{{#ifeq: {{#var:showType}}  |true|
+
|}}
!! {{#if:{{{typeWidth|}}}  |style="min-width:{{{typeWidth}}}"  }} {{!}} Тип}}   {{#vardefine:showRarity  |{{{showRarity|true}}} }}{{#ifeq: {{#var:showRarity}}|true|
+
! Cost<noinclude>
!! {{#if:{{{rarityWidth|}}}|style="min-width:{{{rarityWidth}}}"}} {{!}} Редкость}} {{#vardefine:showLevel  |{{{showLevel|true}}} }}{{#ifeq: {{#var:showLevel}} |true|
 
!! {{#if:{{{levelWidth|}}} |style="min-width:{{{levelWidth}}}" }} {{!}} Уровень}}  {{#vardefine:showPrefix  |{{{showPrefix|false}}}}}{{#ifeq: {{#var:showPrefix}}|true|
 
!! {{#if:{{{prefixWidth|}}}|style="min-width:{{{prefixWidth}}}"}} {{!}} Префикс}} {{#vardefine:showFacts   |{{{showFacts|true}}}  }}{{#ifeq: {{#var:showFacts}} |true|
 
!! {{#if:{{{factsWidth|}}} |style="min-width:{{{factsWidth}}}" }} {{!}} Факты}}  {{#vardefine:showCostText|{{#ifeq:{{{showCostText|false}}}|true|+}}}}
 
!! {{#if:{{{costWidth|}}}  |style="min-width:{{{costWidth}}}"  }} {{!}} Цена    {{#vardefine:showTP      |{{{showTP|false}}}    }}{{#ifeq: {{#var:showTP}}    |true|
 
!! {{#if:{{{TPWidth|}}}    |style="min-width:{{{TPWidth}}}"    }} data-sort-type="number" {{!}} TP price}}{{#vardefine:showNotes|{{{showNotes|false}}}}}{{#ifeq: {{#var:showNotes}}|true|
 
!! {{#if:{{{notesWidth|}}} |style="min-width:{{{notesWidth}}}" }} {{!}} Примечания}}<noinclude>
 
|-
 
| || || || || ||
 
 
|}
 
|}
  
Строка 20: Строка 11:
 
<pre>
 
<pre>
 
{{vendor table header
 
{{vendor table header
| section =
 
 
| showType =
 
| showType =
 
| showRarity =
 
| showRarity =
 
| showLevel =
 
| showLevel =
 
| showFacts =
 
| showFacts =
| showTP =
 
 
}}
 
}}
 
</pre>
 
</pre>
  
 
== Parameters ==
 
== Parameters ==
;section
 
: Optional. The name of the section (tab) the vendor item is located in.
 
;location
 
: Optional. The locations the vendor is located in, separated by ";". Defaults to locations set in the NPC infobox. New NPCs may require a [https://meta.wikimedia.org/wiki/Help:Dummy_edit#Null_edit null edit] to set this property correctly.
 
 
;showType
 
;showType
 
: Default true. Show the type of item. This can be item type or any item subtypes such as armor type.
 
: Default true. Show the type of item. This can be item type or any item subtypes such as armor type.
 
;showRarity
 
;showRarity
: Default true. Show the [[Item#Rarity|rarity]] of the item.
+
: Default true. Show the [[rarity]] of the item.
 
;showLevel
 
;showLevel
 
: Default true. Show the required level to equip or use the item.
 
: Default true. Show the required level to equip or use the item.
;showPrefix
 
: Default false. Show the prefix of the item, in plaintext.
 
 
;showFacts
 
;showFacts
 
: Default true. Show the item facts of the item, this is usually any attribute bonuses or other effects.
 
: Default true. Show the item facts of the item, this is usually any attribute bonuses or other effects.
;showTP
 
: Default false. Show the TP Price.
 
;showCostText
 
: Default false. Show the text description for item prices given with irregular currencies.
 
;showNotes
 
: Default false. If enabled it shows the requirements to purchase an item in an extra column (use if several items have an requirement), otherwise the requirements will be shown below the item.
 
;no subobjects
 
: Default false. If set to true this parameter will prevent subobjects from {{tl|Vendor table row}} being stored for the current vendor table.
 
;requirement
 
: Optional. Set to display the given requirement above the table. Will also add the requirement to each item in the table.
 
;class
 
: Optional. Additional CSS classes to pass to the underlying [[Template:STDT]]. Note this is ''in addition'' to the default "npc sortable" classes. Useful if you want, for instance, collapsible or expandable tables.
 
  
[[Category:Vendor formatting templates]]
+
== Other ==
 +
<nowiki>{{</nowiki>[[Template:Inventory/Table Header|Inventory/Table Header]]<nowiki>}}</nowiki>
 +
<nowiki>{{</nowiki>[[Template:Inventory/Item|Inventory/Item]]| item 1 <nowiki>}}</nowiki>
 +
<nowiki>{{</nowiki>[[Template:Inventory/Armor|Inventory/Armor]]| item 2 <nowiki>}}</nowiki>
 +
<nowiki>{{</nowiki>[[Template:Inventory/Weapon|Inventory/Weapon]]| item 3 <nowiki>}}</nowiki>
 +
<nowiki>{{</nowiki>[[Template:Inventory/Accessory|Inventory/Accessory]]| item 4 <nowiki>}}</nowiki>
 +
<nowiki>{{</nowiki>[[Template:Inventory/Recipe|Inventory/Recipe]]| item 5 <nowiki>}}</nowiki>
 +
 
 +
[[Category:Table formatting templates]]
 
</noinclude>
 
</noinclude>

Пожалуйста, учтите, что любой ваш вклад в проект «Guild Wars 2 wiki» может быть отредактирован или удалён другими участниками. Если вы не хотите, чтобы кто-либо изменял ваши тексты, не помещайте их сюда.
Вы также подтверждаете, что являетесь автором вносимых дополнений, или скопировали их из источника, допускающего свободное распространение и изменение своего содержимого (см. Guild Wars 2 wiki:Авторские права). НЕ РАЗМЕЩАЙТЕ БЕЗ РАЗРЕШЕНИЯ ОХРАНЯЕМЫЕ АВТОРСКИМ ПРАВОМ МАТЕРИАЛЫ!

Чтобы изменить эту страницу, пожалуйста, ответьте на приведённый ниже вопрос (подробнее):

Отменить | Справка по редактированию (в новом окне)