User:Goraf/PluginCard: Difference between revisions

From Miranda NG
Jump to navigation Jump to search
(copy for further changes)
 
(+includeonly to not parse it // looking for error with mw.title.new(nill))
 
(42 intermediate revisions by 2 users not shown)
Line 1: Line 1:
<!--Localisation
<includeonly><onlyinclude><!-- use #titleparts instead of MagicWords if pagetitle will change -->{{
-->{{Localization/PluginCard|{{{1}}}}}<!--
  #vardefine:PluginFileName | {{BASEPAGENAMEE}}
-->{{DISPLAYTITLE:{{{name|}}} }}{| class="infobox bordered plugincard " cellpadding="4" style="margin: 0 0 10px 10px; width: 22em; font-size: 90%; float: right;clear: right; box-shadow:1px 1px 3px #999;"
}}{{
| align="center" colspan=2 bgcolor="#ccccff" style="font-size:110%;" | '''''{{{name|{{BASEPAGENAME}}}}}'''''
  #if: {{#varexists:PluginLang}}
{{#ifeq:{{{screenshot|}}}|***| | {{!}}-
  | {{PageLang | {{#var:PluginLang}} }} <!-- from ResolveLang pages -->
{{!}} align="center" colspan="2" {{!}} {{#if:{{{screenshot|}}}|[[Image:{{{screenshot}}}{{!}}border{{!}}{{{name}}}{{!}}200px]]|''{{#hashvalue: localisation |noimage|No image}}''}}}}
  | {{#vardefine:PluginLang | {{SUBPAGENAME}} }}{{PageLang | {{SUBPAGENAME}} }} <!-- remove the first one after transition to PageLang -->
{{RowColor|#ccccff|'''{{#hashvalue:localisation|filename|Filename}}'''|{{{dll|{{BASEPAGENAME}}.dll}}}}}
}}<!-- Language localisation ...
<!--am-->{{#if:{{{author|}}}| {{RowColor|#ccccff|'''{{#hashvalue: localisation |plugin-author|Plugin author}}'''|{{Developer|{{{author|}}}}}}}}}
  -->{{Localization/PluginCard|{{#var:PageLang}} }}<!--
{{#if:{{{authors|}}}|{{RowColor|#ccccff|'''{{#hashvalue: localisation |plugin-authors|Plugin authors}}'''|{{{authors|}}}}}|}}<!--/am-->
and default values
|- valign="top"
  -->{{Localization/PluginCard|}}<!--
{{#if:{{{requirements|}}}|{{RowColor|#ccccff|'''{{#hashvalue: localisation |systemreq|System <br/>requirements}}'''|{{{requirements|}}}}}|}}
Load information about plugin
|-
  -->{{PluginInfo|}}<!--
{{#if:{{{homepage|}}}|[{{{homepage|}}} '''{{#hashvalue: localisation |homepage|Homepage}}''']<br/>|}}
Page title
{{#vardefine:pluginName|{{lc:{{#if:{{{basename|}}}|{{{basename}}}|{{#if:{{{dll|}}}|{{#replace:{{{dll|}}}|.dll|}}|{{BASEPAGENAME}}}}}}}}}}
  -->{{DISPLAYTITLE: {{
|-
      #if: {{{name|}}}
| align="center" colspan="2" bgcolor="#ccccff" style="font-size:110%;" |
      | {{{name}}}
'''{{#hashvalue:localisation |download-title|Download links}}:'''
      | {{#hashvalue:{{#var:PluginFileName}} |name |{{#var:PluginFileName}} }}
{{#if:{{{hideDownloadLinks|}}}| |
      }}
{{!}}-
    }}<!--
{{RowColor|#fff|{{#hashvalue: localisation |download-stable|Stable version}}:| {{#if:{{{hide-s32|}}}| |[http://miranda-ng.org/distr/stable/x32/Plugins/{{#var:pluginName}}.zip x32],}} {{#if:{{{hide-s64|}}}| |[http://miranda-ng.org/distr/stable/x64/Plugins/{{#var:pluginName}}.zip x64]}}}}
Check if Plugin:PluginName page exist if not display warning and add creation link
{{!}}-
-->{{#ifexist: Plugin:{{#var:PluginFileName}}
{{RowColor|#fff|{{#hashvalue: localisation |download-current|Current version}}:| {{#if:{{{hide-l32|}}}| |[http://miranda-ng.org/distr/x32/Plugins/{{#var:pluginName}}.zip x32],}} {{#if:{{{hide-l64|}}}| |[http://miranda-ng.org/distr/x64/Plugins/{{#var:pluginName}}.zip x64]}}}}}}
  |
{{!}}-
  | {{Warning|Page <tt>Plugin:{{#var:PluginFileName}}</tt> doesn't exist. Please create it using the link below. Content will be generated automatically. You only need to save the changes.
{{#if:{{{additionalLinks|}}}|
}}<span class="plainlinks createlinks">[{{fullurl:Plugin:{{#var:PluginFileName}} | action=edit&preload=Template:PluginPage/preload&summary=Plugin:{{#var:PluginFileName}} }} '''Create page''']</span>{{clear}}<br/>
{{!}}-
}}
{{RowColor|#fff|{{#hashvalue: localisation |links-other|Other}}:| {{{additionalLinks|}}}}}
 
|}}
{{Infobox
|}<includeonly>{{Languages}}
| name          =
[[Category:{{#hashvalue: localisation |cat-lang|Plugins:English}}]][[Category:Plugins]]
| child          = {{{child|}}}
{{#if:{{{screenshot|}}}| |[[Category:Todo:{{#hashvalue: localisation |cat-todo|Screenshot required}}]]}}
| subbox        = {{{subbox|}}}
</includeonly>
| bodystyle      =
<noinclude>{{Languages/Template|by=PluginCard/by|cz=PluginCard/cz|de=PluginCard/de|en=PluginCard/en|fr=PluginCard/fr|pl=PluginCard/pl|ru=PluginCard}}
 
{{-}}
| titlestyle    =
Использование:
| abovestyle    = background-color:#ccccff;
<pre>{{PluginCard
| subheaderstyle =
| language code (English if empty or incorrect code)
| title          =
| name = Название плагина
| above          = {{
| author = Автор плагина
  #if: {{{name|}}}
| authors = Авторы плагина
  | {{{name}}}
| screenshot = (н) Скриншот плагина (Поставьте *** (три звезды) если плагину не требуется скриншот)
  | {{#hashvalue:{{#var:PluginFileName}} |name |{{#var:PluginFileName}} }}
| requirements = (н) Системные требования (к примеру, необходимые runtime библиотеки)
| dll = (н) Имя dll плагина (перечисление)
| basename = (н) Имя dll плагина, без расширения (предпочтительный вариант)
| langpackru = (н) Перевод плагина (имя файла без .txt в SVN русского лангпака)
| additionalLinks = (н) Дополнительные ссылки на скачивание, показываемые в карточке плагина
| hideDownloadLinks = (н) Не показывать дефолтные ссылки на скачивание
| hide-s32 = (н) Не показывать ссылку на стейбл-32
| hide-s64 = (н) Не показывать ссылку на стейбл-64
| hide-l32 = (н) Не показывать ссылку на лейтест-32
| hide-l64 = (н) Не показывать ссылку на лейтест-64
}}
}}
</pre>
| subheader      =


</noinclude>
|  imagestyle  =
| captionstyle  =
|  image        =
| caption        =
|  image2      =
| caption2      =
 
| headerstyle    =
|  labelstyle    = background-color:#ccccff; text-align:right;
|  datastyle    =
 
<!-- Filename -->
| header1  =
|  label1  = {{#hashvalue:localisation|filename |{{#hashvalue:defaultL |filename}} }}
|  data1  = {{#if: {{#hashvalue:{{#var:PluginFileName}} |filename}}
    | {{#hashvalue:{{#var:PluginFileName}} |filename}}
    | {{#var:PluginFileName}}
  }}.dll
 
<!-- Author -->
| header2  =
|  label2  = {{#hashvalue: localisation |plugin-author |{{#hashvalue:defaultL |plugin-author}} }}
|  data2  = {{#if: {{{author|}}}
    | {{Developer|{{{author|}}} }}
    | {{#if: {{#hashvalue:{{#var:PluginFileName}} |author}}
      | {{Developer|{{#hashvalue:{{#var:PluginFileName}} |author}} }}
      |k
      }}
  }}
 
<!-- Authors -->
| header3  =
|  label3  = {{#hashvalue: localisation |plugin-authors |{{#hashvalue:defaultL |plugin-authors}} }}
|  data3  = {{#if: {{{authors|}}}
    | {{Developer|{{{authors|}}} }}
    | {{#if: {{#hashvalue:{{#var:PluginFileName}} |authors}}
      | {{Developer|{{#hashvalue:{{#var:PluginFileName}} |authors}} }}
      |k
      }}
  }}
 
<!-- Requirements -->
| header4  =
|  label4  = {{#hashvalue: localisation |systemreq |{{#hashvalue:defaultL |systemreq}}}}
|  data4  = {{#if: {{{requirements|}}}
    | {{Developer|{{{requirements|}}} }}
    | {{#if: {{#hashvalue:{{#var:PluginFileName}} |requirements}}
      | {{Developer|{{#hashvalue:{{#var:PluginFileName}} |requirements}} }}
      |k
      }}
  }}
 
<!-- Homepage -->
| header5  =
|  label5  =
|  data5  = {{#if: {{{homepage|}}}
    | [{{{homepage|}}} {{#hashvalue: localisation |homepage |{{#hashvalue:defaultL |homepage}} }}]
    | {{#if: {{#hashvalue:{{#var:PluginFileName}} |homepage}}
      | [{{#hashvalue:{{#var:PluginFileName}} |homepage}} {{#hashvalue: localisation |homepage |{{#hashvalue:defaultL |homepage}} }}]
      |
      }}
  }}
 
<!-- Download links -->
| header6  =
|  label6  =
|  data6  = {{Infobox | subbox = yes
    | headerstyle = font-size:110%; background-color:#ccccff;
    | labelstyle  = font-weight:normal; text-align:right; width:60%;
 
    | header1 = {{#hashvalue:localisation |download-title |{{#hashvalue:defaultL |download-title}}}}
 
    <!-- stable -->
    |  label2 = {{#hashvalue: localisation |download-stable |{{#hashvalue:defaultL |download-stable}} }}:
    |  data2 = stable
 
    <!-- development -->
    |  label3 = {{#hashvalue: localisation |download-current |{{#hashvalue:defaultL |download-current}} }}:
    |  data3 = Data 3-3
 
    <!-- additional -->
    |  label4 = {{#hashvalue: localisation |links-other |{{#hashvalue:defaultL |links-other}} }}:
    |  data4 = Data 3-3
  }}
 
| belowstyle    =
| below          =
}}</onlyinclude>
</includeonly>

Latest revision as of 16:31, 26 May 2018